/* estilos/css.css - Versão ajustada (inclui correções contra margem branca à direita) */

* {
    box-sizing: border-box;
}

/* ===== base e correção do fundo ===== */
html {
    width: 100%;
    height: 100%;
    background: #000; /* fallback para evitar branco caso algo falhe */
}

body {
    min-height: 100%;
    width: 100%;
    margin: 0;
    padding: 0;
    font-family: 'Sen', sans-serif;
    overflow-y: scroll;
    overflow-x: hidden; /* reforçado */
    color: #eee;

    /* background ajustado (sem fixed para evitar "margem" fantasmas) */
    background-image: url('../imagens/fundo_tech.png');
    background-size: cover;
    background-attachment: scroll; /* FIX: evita bugs de pintura que criam faixa branca */
    background-position: center;
    background-repeat: no-repeat;
}

main {
    padding-top: 55px;
}

nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
}

nav ul {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    background: rgba(0, 0, 50, 0.7);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding: 10px 5px;
    margin: 0;
    gap: 5px;
}

nav ul li {
    flex: 1;
    text-align: center;
    white-space: nowrap;
    min-width: 0; /* permite shrink em flex children */
}

nav ul li a {
    color: white;
    text-decoration: none;
    padding: 5px;
    font-size: 0.9em;
    display: inline-block;
}

nav ul li a:hover {
    background-color: lightskyblue;
    color: whitesmoke;
    box-shadow: 0 0 10px whitesmoke;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.mainHeader {
    text-align: center;
    padding: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    scroll-snap-align: start;
}

.tituloDecor {
    position: relative;
    display: inline-block;
    padding: 50px 60px;
    color: transparent;
    background: linear-gradient(90deg, #ffffff 0%, #00ffff 100%);
    -webkit-background-clip: text;
    background-clip: text;
    font-weight: bold;
    font-size: 3.5em;
    z-index: 1;
    filter: drop-shadow(0 0 5px rgba(0, 0, 0, 0.8));
    text-shadow: none;
}

.tituloDecor::before {
    content: "";
    position: absolute;
    top: -10px;
    left: -40px;
    right: -40px;
    bottom: -10px;
    background: linear-gradient(135deg, #ff0080, #7928ca);
    z-index: -1;
    filter: blur(25px);
    opacity: 0.6;
    border-radius: 15px;
    animation: pulseGlow 7s infinite;
    box-sizing: border-box;
    max-width: calc(100% + 80px); /* evita vazamento lateral do pseudo-element */
    pointer-events: none;
}

@keyframes pulseGlow {
    0%,
    100% {
        transform: scale(1);
        opacity: 0.4;
    }
    50% {
        transform: scale(1.05);
        opacity: 0.7;
    }
}

.mainHeader p {
    padding-top: 40px;
    color: #e0e0e0;
    font-size: 1.2em;
    max-width: 800px;
    margin: 0 auto;
    line-height: 1.6;
}

.container {
    width: 70vw;
    margin: 0 auto;
    padding: 0;
    text-align: center;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    scroll-snap-align: start;
    max-width: 100%;
}

.imgCheia {
    width: 50%;
    height: auto;
    border-radius: 15px;
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: block;
    margin: 0 auto 20px auto;
    max-width: 100%;
}

.imgCheia:hover {
    transform: scale(1.05);
    box-shadow: 0 12px 25px rgba(0, 0, 0, 0.35);
}

.txt {
    padding: 40px;
    background: rgba(20, 20, 35, 0.6);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    color: #eee;
    text-align: center;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    scroll-snap-align: start;
    margin: 20px;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    max-width: 100%;
}

.txt p {
    padding: 0 50px;
    line-height: 1.8;
    font-size: 1.1em;
    text-align: center;
    color: #ddd;
}

h2,
h3 {
    color: #00d2ff;
    text-shadow: 0 0 10px rgba(0, 210, 255, 0.3);
}

.carrosselCont {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-top: 10px;
    margin-bottom: -70px;
    min-width: 0;
}

.carrosselVideos {
    width: 420px;
    min-height: 300px;
    position: relative;
    overflow: hidden;
    border-radius: 10px;
    padding: 15px;
    line-height: 0;
    max-width: 100%;
    box-sizing: border-box;
}

.slide {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: absolute;
    width: 100%;
    top: 0;
    left: 0;
    opacity: 0;
    transform: scale(0.95);
    transition: opacity 0.6s ease-in-out, transform 0.6s ease-in-out;
    padding: 0;
    margin: 0;
    line-height: 0;
    overflow: hidden;
}

.slide.ativo {
    opacity: 1;
    transform: scale(1);
    z-index: 1;
}

.slide video {
    display: block;
    width: 100%;
    height: 225px;
    object-fit: cover;
    border-radius: 8px;
    background-color: black;
    margin: 0;
    padding: 0;
    max-width: 100%;
}

.slide p {
    margin-top: 20px;
    color: black;
    font-weight: 600;
    font-size: large;
}

.btnAnt,
.btnProx {
    background-color: transparent;
    color: #00d2ff;
    border: none;
    font-size: 3rem;
    cursor: pointer;
    transition: transform 0.2s, color 0.3s;
    margin-bottom: 100px;
    text-shadow: 0 0 15px rgba(0, 210, 255, 0.6);
}

.btnAnt:hover,
.btnProx:hover {
    transform: scale(1.2);
    color: navy;
}

.contato {
    background: rgba(40, 0, 0, 0.6);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 100, 100, 0.2);
    color: white;
    border-radius: 20px;
    padding: 40px 20px;
    text-align: center;
    margin: 20px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    scroll-snap-align: start;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    max-width: 100%;
}

.contato h2 {
    margin-bottom: 40px;
    color: #00d2ff;
    text-shadow: 0 0 10px rgba(0, 210, 255, 0.3);
}

caption {
    color: white;
    margin-bottom: 20px;
}

table {
    width: 100%;
    border-radius: 10px;
    border-collapse: separate;
    background: rgba(255, 255, 255, 0.05);
    color: #eee;
    backdrop-filter: blur(5px);
}

table,
th,
td {
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 12px;
    text-align: center;
}

.formCont {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 40px 20px;
    margin: 0 auto 150px auto;
    max-width: 600px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    scroll-snap-align: start;
    border-radius: 20px;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    text-align: left;
    box-sizing: border-box;
}

.formCont h2 {
    text-align: center;
    color: #00d2ff;
    margin-bottom: 30px;
}

.formCont label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #ddd;
}

.formCont button,
.formCont input,
.formCont select {
    width: 100%;
    padding: 10px;
    margin-bottom: 20px;
    border: 1px solid #ccc;
    border-radius: 8px;
    font-size: 1em;
    box-sizing: border-box;
}

.formCont button {
    background: linear-gradient(135deg, #00d2ff 0%, #3a7bd5 100%);
    color: white;
    font-weight: bold;
    border: none;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 210, 255, 0.4);
}

.formCont button:hover {
    background: linear-gradient(135deg, #3a7bd5 0%, #00d2ff 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 210, 255, 0.6);
}

footer {
    text-align: center;
    padding: 20px;
    background-color: navy;
    color: white;
}

.emailLink {
    color: lightblue;
    text-decoration: underline;
}

#topBtn {
    display: none;
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 100;
    background-color: maroon;
    color: white;
    border: none;
    padding: 10px 15px;
    border-radius: 5px;
    cursor: pointer;
    transition: opacity 0.3s ease, transform 0.3s ease;
}

#topBtn:hover {
    transform: scale(1.1);
}

.fadeIn {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fadeIn.visible {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 768px) {
    nav ul {
        gap: 10px;
        flex-direction: row;
        flex-wrap: wrap;
        padding: 5px;
    }

    nav ul li {
        width: auto;
        flex: 1 1 auto;
        text-align: center;
        margin-bottom: 5px;
        min-width: 0;
    }

    .contato {
        padding: 60px 10px;
    }

    .contato h2 {
        margin-bottom: 30px;
    }

    .txt p {
        padding: 0 15px;
        font-size: 1.0em;
    }

    .formCont input,
    .formCont select {
        font-size: 0.9em;
    }

    .slide video {
        height: 200px;
    }

    table,
    th,
    td {
        font-size: 0.8em;
        padding: 4px;
    }

    .imgCheia {
        width: 80%;
    }
}

/* Members Section Styles */
.membros-grid {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
    padding: 20px;
    min-width: 0;
}

.membro-card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    padding: 20px;
    width: 250px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-sizing: border-box;
    min-width: 0;
}

.membro-card:hover {
    transform: translateY(-10px);
}

.img-membro {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 15px;
    border: 3px solid maroon;
    max-width: 100%;
}

.membro-card h3 {
    color: #00d2ff;
    margin-bottom: 5px;
}

.membro-card p {
    font-size: 0.9em;
    padding: 0 10px;
    color: #ccc;
    line-height: 1.4;
}

@media (max-width: 768px) {
    .membros-grid {
        flex-direction: column;
        align-items: center;
    }
}

/* --- SWOT Button (kept) --- */
.btn-swot {
    margin-top: 12px;
    padding: 8px 12px;
    border: none;
    background-color: #1e90ff;
    color: #fff;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 700;
    font-size: 0.95em;
    transition: transform 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease;
    box-shadow: 0 4px 12px rgba(30,144,255,0.18);
}

.btn-swot:hover,
.btn-swot:focus {
    transform: translateY(-2px);
    outline: none;
    background-color: #0f7acc;
    box-shadow: 0 6px 18px rgba(30,144,255,0.28);
}

.btn-swot:focus {
    box-shadow: 0 0 0 3px rgba(30,144,255,0.16);
}

/* compact inline preview */
.swot-mini {
    margin-top: 10px;
    font-size: 0.85em;
    color: #ddd;
}

/* ===================== Modal Styles ===================== */

/* Prevent background scroll when modal open */
.modal-open {
    overflow: hidden;
}

/* overlay */
.modal {
    position: fixed;
    inset: 0;
    display: none; /* hidden by default */
    align-items: center;
    justify-content: center;
    z-index: 2000;
}

/* show modal */
.modal.open {
    display: flex;
}

/* semi-transparent overlay background */
.modal-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    transition: opacity 0.25s ease;
}

/* modal box */
.modal-content {
    position: relative;
    z-index: 2100;
    width: 820px;
    max-width: calc(100% - 40px);
    background: linear-gradient(180deg, rgba(20,20,35,0.95), rgba(12,12,25,0.95));
    border-radius: 12px;
    padding: 22px 24px;
    color: #eaf6ff;
    box-shadow: 0 12px 40px rgba(0,0,0,0.6);
    transform: translateY(12px);
    transition: transform 0.22s ease, opacity 0.22s ease;
    max-height: 80vh;
    overflow: auto;
    border: 1px solid rgba(255,255,255,0.06);
    box-sizing: border-box;
}

/* modal header */
.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 8px;
}

.modal-header h3 {
    margin: 0;
    color: #00d2ff;
    font-size: 1.25em;
}

/* close button */
.modal-close {
    border: none;
    background: transparent;
    color: #dfefff;
    font-weight: 700;
    font-size: 1.05em;
    cursor: pointer;
    padding: 6px 8px;
    border-radius: 6px;
    transition: background 0.18s ease, transform 0.12s ease;
}

.modal-close:hover,
.modal-close:focus {
    background: rgba(255,255,255,0.03);
    transform: translateY(-2px);
    outline: none;
    box-shadow: 0 6px 18px rgba(0,0,0,0.4);
}

/* modal body */
.modal-body p {
    margin: 10px 0;
    line-height: 1.6;
    color: #dfefff;
    font-size: 0.98em;
}

/* 2-column grid inside modal for desktop */
.modal-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-top: 12px;
}

.modal-grid .box {
    background: rgba(255,255,255,0.02);
    padding: 12px;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.04);
}

/* labels inside boxes */
.modal-grid .box strong {
    display: block;
    margin-bottom: 8px;
    color: #00d2ff;
}

/* small note/footer inside modal */
.modal-footer {
    margin-top: 14px;
    font-size: 0.9em;
    color: #cfefff;
    text-align: right;
}

/* responsive modal */
@media (max-width: 820px) {
    .modal-content {
        width: calc(100% - 24px);
        padding: 16px;
    }
    .modal-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .membro-card {
        width: 90%;
    }
}

/* ===== Patch final: proteções extras contra overflow lateral ===== */

/* garante que blocos não virem beyond 100% width */
body,
main,
section,
header,
footer {
    max-width: 100%;
    overflow-x: hidden;
}

/* imagens e vídeos nunca extrapolam */
img, video {
    max-width: 100%;
    height: auto;
    display: block;
}

/* reduz padding horizontal em telas pequenas para evitar "vazamentos" */
@media (max-width: 820px) {
    .tituloDecor { padding-left: 24px; padding-right: 24px; }
    .txt { padding-left: 18px; padding-right: 18px; }
}

/* Helpers extra (não obrigatórios): se quiser usar, adicione class "vw-fix" em elementos problemáticos */
[class*="vw-fix"], .vw-fix {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}
