/* ======================================================= */
/* 1. CONFIGURAÇÕES BÁSICAS E BOOTSTRAP FIXES */
/* ======================================================= */

html {
    font-size: 14px;
    position: relative;
    min-height: 100%;
    /* Garante que o HTML não tenha overflow horizontal */
    overflow-x: hidden;
}

@media (min-width: 768px) {
    html {
        font-size: 16px;
    }
}

/* O body precisa de padding-bottom para compensar o footer sticky */
body {
    overflow-x: hidden;
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
    box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

/* Variáveis para altura da Navbar (Ajuste se necessário) */
:root {
    --navbar-height: 100px;
    --navbar-height-mobile: 80px;
    --logo-desktop-height: 150px;
    --logo-mobile-height: 60px;
}


/* ======================================================= */
/* 2. NAVBAR (CABECALHO) */
/* (As regras abaixo não mudaram, apenas a ordem para clareza) */
/* ======================================================= */

.custom-bg {
    background-color: #003366;
}

.custom-active-link {
    color: #FFC107 !important;
    font-weight: bold;
}

.navbar .navbar-nav .nav-link:not(.custom-active-link) {
    color: white !important;
}

.navbar-toggler-icon { /* SVG para ícone branco */
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='%23fff' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") !important;
}

.custom-logo {
    width: var(--logo-mobile-height);
    height: var(--logo-mobile-height);
}

@media (min-width: 992px) {
    .custom-logo {
        width: var(--logo-desktop-height);
        height: var(--logo-desktop-height);
    }

    #titulo-desktop {
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
        z-index: 1000;
        width: fit-content;
    }

    .navbar-collapse {
        display: flex;
        justify-content: flex-end;
        width: 100%;
    }
}






/* ======================================================= */
/* 3. CARROSSEL - TELA CHEIA (FULL WIDTH & FULL VH) - AJUSTE FINAL E FLEXÍVEL */
/* ======================================================= */

#heroCarousel {
    width: 100vw;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    /* MANTIDO: margin-top: 0 para que não haja espaço entre a Navbar e o carrossel. */
    margin-top: 0 !important;
    /* AJUSTE AQUI: Usamos uma altura mínima em PX para estabilizar, 
       garantindo que a imagem ocupe um espaço decente. */
    min-height: 350px;
    margin-bottom: 50px;
}

/* O restante das regras de altura e imagem permanecem boas: */
.carousel-inner,
.carousel-item {
    height: 100%;
    width: 100%;
}

.custom-hero-img {
    height: 70vh; /* altura responsiva, ocupa 70% da tela */
    object-fit: cover; /* mantém proporção e corta excesso */
    object-position: center; /* centraliza a imagem */
}




@media (min-width: 992px) { /* Desktop */
    #heroCarousel {
        /* Altura total no desktop permanece a mesma. */
        height: calc(100vh - var(--navbar-height));
        min-height: 550px;
    }
}

/* Re-exibe o caption no desktop */
@media (min-width: 768px) { /* A partir do tablet (md) */
    .carousel-caption {
        display: block !important; /* Volta a exibir o caption */
        bottom: 30% !important;
        left: 50%;
        transform: translateX(-50%);
        width: 80%;
        font-size: initial; /* Reseta o tamanho da fonte */
        padding: initial; /* Reseta o padding */
        background-color: initial; 
    }
}

.carousel-caption h1 {
    font-size: 3rem;
}

.carousel-caption p {
    font-size: 1.25rem;
}





/* ====================diretoria card=================================== */

.rounded-circle {
    object-fit: cover;
    border: 4px solid #003366; /* borda azul institucional */
}





/* orgãos */
.orgao-card {
    border-radius: 12px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
}

.orgao-card:hover {
        transform: translateY(-8px);
        box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

    .orgao-card:active {
        transform: scale(0.97);
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    }





/* ======================================================= */
/* 4. FOOTER (RODAPÉ STICKY) */
/* ======================================================= */

.custom-footer-bg {
    background-color: #171717;
    position: relative; /* deixa ele natural */
    width: 100%;
    padding: 40px 20px;
}

    .custom-footer-bg h5 {
        color: #fff;
        margin-bottom: 1rem;
    }

    .custom-footer-bg p,
    .custom-footer-bg ul li {
        color: #ddd;
        font-size: 0.95rem;
    }


/* =====================clube page================================== */


.clube-container {
    padding: 2rem;
    text-align: center;
}

    .clube-container .titulo {
        font-size: 2rem;
        margin-bottom: 1.5rem;
        color: #333;
        font-weight: bold;
    }

.grid-clube {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
}

    .grid-clube .card {
        border-radius: 12px;
        overflow: hidden;
        box-shadow: 0 2px 8px rgba(0,0,0,0.15);
        transition: transform 0.2s;
        background: #fff;
    }

        .grid-clube .card img {
            width: 100%;
            height: 100%;
            object-fit: cover;
        }

        .grid-clube .card:hover {
            transform: scale(1.03);
        }



/* =====================clube modal================================== */


.modal-content {
    background: transparent;
    border: none;
    box-shadow: none;
    text-align: center;
}

.modal img {
    max-height: 80vh;
    object-fit: contain;
}






/* ===================== Diretoria page================================== */


.diretoria-section h2 {
    font-size: 2rem;
    color: #222;
}

.diretoria-card {
    background: #fff;
    border-radius: 12px;
    text-align: center;
    padding: 20px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

    .diretoria-card:hover {
        transform: translateY(-5px);
        box-shadow: 0 6px 20px rgba(0,0,0,0.15);
    }

.diretoria-img {
    width: 120px;
    height: 120px;
    object-fit: cover;
    border-radius: 50%;
    margin: 0 auto;
    border: 4px solid #eee;
}

.diretoria-card h5 {
    font-size: 1rem;
    font-weight: bold;
    margin-top: 15px;
    color: #333;
}

.diretoria-card .cargo {
    font-size: 0.9rem;
    font-weight: 500;
    color: #666;
    margin-bottom: 0;
}





/* ===================== section enddrecos ================================== */
.endereco-section {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    background: #f8f9fa;
    border-top: 2px solid #ddd;
}

.container-endereco {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    max-width: 1100px;
    width: 100%;
    justify-content: space-between;
    align-items: flex-start;
}

.info-endereco {
    flex: 1 1 300px;
}

    .info-endereco h3 {
        margin-bottom: 10px;
        font-size: 1.4rem;
        color: #222;
    }

    .info-endereco p {
        margin: 5px 0;
        color: #444;
    }

.mapa-endereco {
    flex: 1 1 400px;
    min-width: 300px;
}









@media (max-width: 768px) {
    .custom-footer-bg {
        text-align: center; /* centraliza no mobile */
    }

        .custom-footer-bg h5 {
            margin-top: 20px;
        }
}




/* Layout com sticky footer */
html, body {
    height: 100%;
    margin: 0;
    display: flex;
    flex-direction: column;
}

main {
    flex: 1; /* força o main a ocupar o espaço restante */
}

.custom-footer-bg {
    background-color: #171717;
    width: 100%;
    padding: 20px;
    color: #ddd;
    margin-top: auto; /* joga o footer pro final */
}


/* Limita descrição para 3 linhas */
.text-truncate-3 {
    display: -webkit-box;
    -webkit-line-clamp: 3; /* quantidade de linhas */
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.detalhe-container p {
    word-wrap: break-word; /* Força quebra de palavras longas */
    white-space: normal; /* Permite múltiplas linhas */
    overflow-wrap: anywhere; /* Navegadores modernos */
}


