:root {
    /* Cor extraída visualmente dos elementos gráficos (Cartões e Envelope) */
    --nortrest-blue: #006f8e;
    --nortrest-dark: #2c3e50;
    --nortrest-gradient: linear-gradient(135deg, #008caf 0%, #005f7a 100%);
}

/* Scroll suave ao clicar nos links do menu */
html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: #444;
    padding-top: 76px; /* Ajuste para navbar maior com logo */
}

/* NAVBAR */
.navbar {
    border-bottom: 1px solid #eee;
}

.nav-link {
    color: var(--nortrest-dark) !important;
    font-size: 0.95rem;
    transition: color 0.3s;
}

.nav-link:hover, .nav-link.active {
    color: var(--nortrest-blue) !important;
}

/* BOTÕES PERSONALIZADOS */
.btn-nortrest {
    background: var(--nortrest-gradient);
    border: none;
    color: white;
    box-shadow: 0 4px 6px rgba(0, 111, 142, 0.3);
    transition: transform 0.2s, box-shadow 0.2s;
}

.btn-nortrest:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 111, 142, 0.4);
    color: white;
}

/* =========================
   CAROUSEL / SLIDER (FINAL)
   ========================= */

#heroCarousel {
    width: 50%;          /* Ajustado para 60% (estava 50%) */
    margin: 30px auto;   /* Centra no ecrã e dá espaço em cima */
    border: 1px solid #ddd; /* Opcional: moldura fina */
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.carousel-item {
    /* Removemos as alturas fixas e paddings */
    height: auto !important;
    background: none !important;
}

.carousel-item img {
    width: 100%;       /* A imagem ocupa 100% da largura do slider */
    height: auto;      /* A altura ajusta-se sozinha */
    object-fit: contain; 
}

/* Ajuste para telemóveis - Ocupar mais largura */
@media (max-width: 768px) {
    #heroCarousel {
        width: 95%; /* No telemóvel aumentamos a largura do slider */
    }
}

/* TÍTULOS E TEXTOS */
.text-nortrest {
    color: var(--nortrest-blue);
}

.nortrest-divider {
    height: 4px;
    width: 60px;
    background: var(--nortrest-gradient);
    border-radius: 2px;
}

/* CARTÕES DE SERVIÇO */
.card {
    transition: all 0.3s ease;
}
.shadow-hover:hover {
    transform: translateY(-10px);
    box-shadow: 0 1rem 3rem rgba(0,0,0,.1) !important;
}

.icon-circle {
    width: 80px;
    height: 80px;
    background-color: #f0f8ff;
    color: var(--nortrest-blue);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    margin-bottom: 1rem;
}

/* FOOTER - Estilo baseado no Envelope Azul */
footer#contactos {
    background-color: var(--nortrest-blue); 
    background-image: linear-gradient(160deg, #007ca6 0%, #005670 100%);
    color: white;
}

/* Estilo para inputs dentro do Footer */
footer input.form-control,
footer textarea.form-control {
    background-color: rgba(255, 255, 255, 0.9); /* Ligeira transparência */
    border: none;
}

footer input.form-control:focus,
footer textarea.form-control:focus {
    background-color: #ffffff; 
    box-shadow: 0 0 0 0.25rem rgba(0, 111, 142, 0.5); 
}

/* LINKS DO FOOTER (Novo) */
.footer-link {
    transition: color 0.3s ease;
}

.footer-link:hover {
    color: #00d2ff !important; /* Azul ciano brilhante no hover */
    text-decoration: underline !important;
}

.text-nortrest-light {
    color: #008caf; /* Tom mais claro para os ícones do footer */
}

/* =========================
   SLIDER DE PARCEIROS (A CORES)
   ========================= */

.logos {
    overflow: hidden;
    white-space: nowrap;
    position: relative;
    padding: 25px 0; 
}

.logos:hover .logos-slide {
    animation-play-state: paused;
}

.logos-slide {
    display: inline-block;
    animation: 35s slide infinite linear;
}

.logos-slide img {
    height: 55px; 
    margin: 0 45px; 
    
    /* Logos a cores */
    transition: transform 0.3s ease; 
    cursor: pointer;
}

/* Quando passa o rato, faz apenas um ligeiro zoom */
.logos-slide img:hover {
    transform: scale(1.1);
}

@keyframes slide {
    from { transform: translateX(0); }
    to { transform: translateX(-100%); }
}

/* Ajuste para telemóveis */
@media (max-width: 768px) {
    .logos-slide img {
        height: 40px;
        margin: 0 25px;
    }
}

/* =========================
   BOTÕES "FANTASMA" (Só aparecem no Hover)
   ========================= */

/* 1. Por defeito, os botões estão invisíveis */
.carousel-control-prev,
.carousel-control-next {
    width: 5%;
    opacity: 0; 
    transition: opacity 0.3s ease; 
}

/* 2. Quando o rato passa por cima, aparecem */
#heroCarousel:hover .carousel-control-prev,
#heroCarousel:hover .carousel-control-next {
    opacity: 1; 
}

/* 3. Estilo das setas */
.carousel-control-prev-icon,
.carousel-control-next-icon {
    width: 2rem;
    height: 2rem;
    background-color: rgba(0,0,0,0.5); 
    border-radius: 50%;
    background-size: 50%;
}

/* =========================
   AVISO DE COOKIES
   ========================= */

.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: var(--nortrest-dark); 
    color: white;
    padding: 15px 0;
    box-shadow: 0 -4px 10px rgba(0,0,0,0.1);
    z-index: 9999; 
    border-top: 3px solid var(--nortrest-blue); 
}

/* Classe utilitária para esconder o banner */
.d-none {
    display: none !important;
}
