:root {
    --color-blue: #33498d;
    --color-yellow: #dcd110;
    --color-green: #4ade80;

    --color-red: #ef4444;

    --color-accent: #d15f34;
    --color-bg: #05070a;
    --font-main: 'Inter', sans-serif;
    --font-display: 'Outfit', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
html, body {
    max-width: 100%;
    overflow-x: hidden;
}

body {
    background-color: var(--color-bg);
    color: #fff;
    font-family: var(--font-main);
    height: 100dvh;
    display: flex;
    flex-direction: column;
}

.stars-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100dvh;
    background: url('assets/img/bg.jpg') no-repeat center center;
    background-size: cover;
    z-index: -1;
    overflow: hidden;
}

.star {
    position: absolute;
    border-radius: 50%;
    opacity: 0.2;
    pointer-events: none;
    animation: twinkle var(--duration) infinite ease-in-out var(--delay);
}

@keyframes twinkle {

    0%,
    100% {
        opacity: 0.2;
        transform: scale(0.8);
    }

    50% {
        opacity: 0.9;
        transform: scale(1.2);
        box-shadow: 0 0 8px rgba(255, 255, 255, 0.8);
    }
}

.main-header {
    position: absolute;
    top: 30px;
    left: 0;
    width: 100%;
    display: flex;
    justify-content: center;
    z-index: 100;
}

.discreet-logo {
    height: 100px;

    filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.2));
}

.cosmic-stage {
    flex: 1;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.celestial {
    position: absolute;
    pointer-events: none;
    z-index: 5;
}

.sol-pulsar {
    top: 19px;

    left: 20px;
    height: 190px;

    animation: pulse 5s infinite ease-in-out;
}

.lua-alinhada {
    top: 19px;
    right: 20px;
    height: 190px;
}

.planetary-center {
    position: relative;
    height: 65vh;
    max-height: 750px;
    aspect-ratio: 1 / 1;
    width: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    margin-top: clamp(40px, 10vh, 85px);

}

.layer-terra {
    height: 100%;
    width: auto;
    filter: drop-shadow(0 0 50px rgba(51, 73, 141, 0.4));

    opacity: 0;
    animation: earthRise 1.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.overlay-container {
    position: absolute;
    width: 90%;

    aspect-ratio: 1 / 1;
    display: none;
    align-items: center;
    justify-content: center;

    opacity: 0;
    animation: bgFadeRotate 1.5s cubic-bezier(0.16, 1, 0.3, 1) 0.8s forwards;
}

.layer-esfera-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0.9;
}

.interaction-group {
    position: absolute;
    width: 70%;

    z-index: 20;
    margin-top: -40px;

}

.triangular-nav {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;

    width: 100%;
}

.tri-row {
    display: flex;
    justify-content: center;
    width: 100%;
    gap: 0;
}

.tri-top {
    margin-top: 0px;
}

.tri-bottom {
    margin-top: -8%;

}

.sphere-item {
    position: relative;
    width: 50%;
    aspect-ratio: 1 / 1;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: var(--color-blue);
    transition: transform 0.4s ease;
    flex-shrink: 0;

    opacity: 0;
}

#link-quem-somos {
    position: relative;
    top: -5px;
    animation: spherePop 0.8s cubic-bezier(0.16, 1, 0.3, 1) 1.8s forwards;
}

#link-campanha {
    animation: spherePop 0.8s cubic-bezier(0.16, 1, 0.3, 1) 2.1s forwards;
}

#link-semana {
    animation: spherePop 0.8s cubic-bezier(0.16, 1, 0.3, 1) 2.4s forwards;
}

.sphere-item img {
    width: 100%;
    height: auto;
    display: block;
}

.sphere-text {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-family: var(--font-display);
    font-size: 1rem;
    font-weight: 700;
    text-align: center;
    text-transform: uppercase;
    line-height: 1.1;
    padding: 10%;
    pointer-events: none;
}

.mobile-br {
    display: none;
}

.desktop-only {
    display: inline;
}

.slogan-pulsar {
    display: block;
    color: var(--color-blue);
    animation: sloganPulse 3s infinite ease-in-out;
    margin-top: 5px;
}

.sphere-item:hover {
    transform: scale(1.07);
    z-index: 30;
}

.sphere-item:hover img {
    filter: drop-shadow(0 0 12px var(--color-yellow));
}

#link-campanha:hover img {
    filter: drop-shadow(0 0 12px var(--color-green));
}

#link-semana:hover img {
    filter: drop-shadow(0 0 12px var(--color-red));
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 0.8;
    }

    50% {
        transform: scale(1.05);
        opacity: 1;
    }
}

@keyframes earthRise {
    from {
        opacity: 0;
        transform: translateY(30vh);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes bgFadeRotate {
    from {
        opacity: 0;
        transform: rotate(-15deg) scale(0.85);
    }

    to {
        opacity: 1;
        transform: rotate(0deg) scale(1);
    }
}

@keyframes spherePop {
    from {
        opacity: 0;
        transform: scale(0.5);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes sloganPulse {

    0%,
    100% {
        transform: scale(1);
        text-shadow: 0 0 5px rgba(51, 73, 141, 0.2);
        opacity: 0.9;
    }

    50% {
        transform: scale(1.05);
        text-shadow: 0 0 15px rgba(51, 73, 141, 0.6);
        opacity: 1;
    }
}

.page-header {

    pointer-events: none;

    transition: opacity 0.3s ease;

}

.page-header>* {
    pointer-events: auto;

}

.back-btn {
    position: absolute;
    left: 5%;
    top: 50%;
    transform: translateY(-50%);
    color: var(--color-yellow);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.back-btn:hover {
    color: #fff;
    text-shadow: 0 0 10px var(--color-yellow);
}

.content-stage {
    overflow-y: auto;
    flex: 1;

    width: 100%;
    padding-top: 150px;

}

.content-container {
    max-width: 1600px;
    margin: 0 auto;
    padding: 20px 5%;
}

.content-stage::-webkit-scrollbar {
    width: 8px;
}

.content-stage::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
}

.content-stage::-webkit-scrollbar-thumb {
    background: var(--color-blue);
    border-radius: 4px;
}

.hero-section,
.initiatives-section,
.proclamation-section,
.activities-section,
.partners-section {
    margin-bottom: 80px;
    animation: earthRise 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    opacity: 0;
}

.initiatives-section {
    animation-delay: 0.2s;
}

.proclamation-section {
    animation-delay: 0.4s;
}

.activities-section {
    animation-delay: 0.6s;
}

.glow-title {
    font-family: var(--font-display);
    font-size: 3.5rem;
    color: #fff;
    text-align: center;
    margin-bottom: 40px;
    text-shadow: 0 0 20px rgba(255, 255, 255, 0.4);
}

.section-title {
    font-family: var(--font-display);
    font-size: 2.2rem;
    color: var(--color-yellow);
    margin-bottom: 40px;
    text-align: center;
    text-transform: uppercase;
}

.hero-text {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    line-height: 1.8;
    font-size: 1.1rem;
    color: #ddd;
}

.hero-text p {
    margin-bottom: 20px;
    text-shadow: 0 0 15px rgba(0, 0, 0, 0.8), 0 2px 4px rgba(0, 0, 0, 0.9);

}

.highlight-box {
    background: rgba(51, 73, 141, 0.15);
    border: 1px solid rgba(51, 73, 141, 0.5);
    border-radius: 12px;
    padding: 30px;
    margin-top: 30px;
    backdrop-filter: blur(5px);
}

.highlight-box p {
    margin-bottom: 0;
    color: #fff;
    font-size: 1.2rem;
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 350px), 1fr));
    gap: 30px;
    max-width: 1200px;

    margin: 0 auto;
}

.card-item,
.proclamation-card {
    background: rgba(51, 73, 141, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(5px);
    border-radius: 16px;
    padding: 30px;
    text-align: center;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
}

.card-item:hover,
.proclamation-card:hover {
    background: rgba(255, 255, 255, 0.08);
    transform: translateY(-10px);
    border-color: rgba(255, 255, 255, 0.3);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.5), 0 0 20px rgba(51, 73, 141, 0.4);
}

.card-logo {
    height: 140px;
    width: 100%;
    background-color: #ffffff;

    border-radius: 12px;

    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    padding: 15px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);

    transition: all 0.3s ease;
}

.card-logo img {
    max-height: 100%;
    max-width: 100%;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.card-item:hover .card-logo {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6), 0 0 15px rgba(255, 255, 255, 0.2);
}

.card-item:hover .card-logo img {
    transform: scale(1.05);
}

.card-item h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: #fff;
    margin-bottom: 20px;
    line-height: 1.4;
}

.btn-explore {
    display: inline-block;
    padding: 10px 24px;
    border-radius: 30px;
    border: 1px solid var(--color-yellow);
    color: var(--color-yellow);
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    transition: all 0.3s ease;
}

.card-item:hover .btn-explore,
.proclamation-card:hover .btn-explore {
    background: var(--color-yellow);
    color: var(--color-bg);
}

.proclamation-card {
    max-width: 800px;
    margin: 0 auto;
    padding: 40px;
    background: linear-gradient(135deg, rgba(51, 73, 141, 0.25), rgba(5, 7, 10, 0.2));
    border: 1px solid rgba(51, 73, 141, 0.4);
}

.carta-preview h3 {
    font-size: 1.5rem;
    color: var(--color-yellow);
    margin-bottom: 15px;
}

.carta-preview p {
    color: #ccc;
    margin-bottom: 30px;
    font-style: italic;
}

.activities-container {
    max-width: 900px;
    margin: 0 auto;
    background: rgba(51, 73, 141, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(5px);
    border-radius: 16px;
    padding: 40px;
}

.activities-list {
    list-style: none;
    padding: 0;
}

.activities-list li {
    position: relative;
    padding-left: 30px;
    margin-bottom: 15px;
    line-height: 1.6;
    color: #ddd;
}

.activities-list li::before {
    content: '✦';
    position: absolute;
    left: 0;
    color: var(--color-yellow);
    font-size: 1.2rem;
}

.partners-grid {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 40px;
    flex-wrap: wrap;
}

.partner-link {
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #ffffff;
    border-radius: 12px;
    padding: 15px 25px;
    height: 100px;
    min-width: 180px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
    transition: all 0.3s ease;
    text-decoration: none;
}

.partner-link img {
    max-height: 60px;
    max-width: 100%;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.partner-link:hover {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6), 0 0 15px rgba(255, 255, 255, 0.2);
}

.partner-link:hover img {
    transform: scale(1.05);
}

.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(10px);
    z-index: 900;
    opacity: 0;
    pointer-events: none;
    transition: all 0.4s ease;
}

.modal-content {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -45%) scale(0.95);
    width: 90%;
    max-width: 600px;
    max-height: 85vh;
    background: transparent;
    border: 1px solid rgba(51, 73, 141, 0.6);
    border-radius: 20px;
    padding: 40px;
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.8), inset 0 0 20px rgba(255, 255, 255, 0.02);
    display: flex;
    flex-direction: column;
    overflow: hidden;

}

.modal-content::before {
    content: '';
    position: absolute;
    top: -30px;
    left: -30px;
    right: -30px;
    bottom: -30px;

    background: url('assets/img/Background\ Estrelas\ 3.png') center/cover fixed;
    filter: blur(15px);
    z-index: -2;
}

.modal-content::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(8, 15, 40, 0.85);

    z-index: -1;
}

.modal-content>* {
    position: relative;
    z-index: 1;
}

.modal-large {
    max-width: 900px;
}

.modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.modal-content.active {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
    pointer-events: auto;
}

.close-btn {
    position: absolute;
    top: 20px;
    right: 25px;
    background: none;
    border: none;
    color: #aaa;
    font-size: 2rem;
    cursor: pointer;
    transition: color 0.3s ease;
    line-height: 1;
}

.close-btn:hover {
    color: #fff;
}

.modal-content h2 {
    font-family: var(--font-display);
    color: var(--color-yellow);
    margin-bottom: 25px;
    font-size: 1.8rem;
    padding-right: 30px;

}

.modal-body {
    overflow-y: auto;
    padding-right: 15px;
}

.modal-body::-webkit-scrollbar {
    width: 6px;
}

.modal-body::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
}

.modal-body::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 10px;
}

.modal-body p {
    color: #ccc;
    line-height: 1.7;
    margin-bottom: 20px;
    font-size: 1.05rem;
}

.modal-body h3 {
    color: #fff;
    margin: 30px 0 15px 0;
    font-size: 1.3rem;
}

.modal-body ul,
.modal-body ol {
    color: #ccc;
    line-height: 1.7;
    margin-bottom: 20px;
    padding-left: 20px;
}

.modal-body li {
    margin-bottom: 10px;
}

.tabs-nav {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 30px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 15px;
}

.tab-btn {
    background: none;
    border: none;
    color: #888;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    padding: 8px 15px;
    transition: all 0.3s ease;
    border-bottom: 2px solid transparent;
}

.tab-btn:hover {
    color: #ccc;
}

.tab-btn.active {
    color: var(--color-yellow);
    border-bottom: 2px solid var(--color-yellow);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
    animation: fadeInTab 0.4s ease forwards;
}

@keyframes fadeInTab {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.signatories {
    margin-top: 40px;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
}

.sign-logos {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 30px;
    margin-top: 20px;
}

.sign-logos img {
    height: 60px;
    object-fit: contain;
}

.btn-external {
    display: inline-block;
    padding: 12px 30px;
    background: var(--color-blue);
    color: #fff;
    text-decoration: none;
    border-radius: 30px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-external:hover {
    background: #4762b3;
    transform: scale(1.05);
    box-shadow: 0 10px 20px rgba(51, 73, 141, 0.4);
}

.page-footer {
    text-align: center;
    padding: 20px;
    color: rgba(255, 255, 255, 0.4);
    font-size: 0.8rem;
}

@media (max-width: 768px) {
    .planetary-center {
        width: 90vw;
        height: auto;
        margin-top: 50px;
    }

    .interaction-group {
        width: 78%;
    }

    .discreet-logo {
        height: 80px;
    }

    .main-header.page-header {
        padding: 0 15px;
        justify-content: center;
    }

    .main-header.page-header .back-btn {
        position: absolute;
        left: 15px;
        top: 50%;
        transform: translateY(-50%);
        font-size: 0.8rem;
    }
    .sphere-text {
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        text-align: center;
        font-size: 0.7rem;
        padding: 10%;
        line-height: 1.2;
        position: absolute;
        inset: 0;
        transform: none; /* Reset desktop/previous */
    }

    /* Forçar etiquetas em uma linha */
    #link-quem-somos .sphere-label,
    #link-campanha .sphere-label {
        white-space: nowrap;
    }

    #link-quem-somos .mobile-br,
    #link-campanha .mobile-br,
    #link-campanha br {
        display: none !important;
    }

    .mobile-br {
        display: block !important;
    }

    .desktop-only {
        display: none !important;
    }

    .sphere-text br {
        display: none;
    }

    .sphere-text br.mobile-br {
        display: block !important;
    }

    #link-quem-somos br.mobile-br {
        display: none !important;
    }

    .slogan-pulsar {
        display: inline;
        animation: none;
        margin-top: 0 !important;
    }

    .sol-pulsar {
        top: 20px;
        height: 70px;
        left: 15px;
    }

    .lua-alinhada {
        top: 20px;
        height: 70px;
        right: 15px;
    }

    .glow-title {
        font-size: 1.8rem;
    }

    .section-title {
        font-size: 1.5rem;
    }
}

@media (max-width: 360px) {
    .main-header {
        top: 15px;
    }

    .discreet-logo {
        height: 60px;
    }

    .sol-pulsar, .lua-alinhada {
        height: 55px;
        top: 15px;
    }

    .glow-title {
        font-size: 1.4rem;
    }

    .section-title {
        font-size: 1.2rem;
    }

    .back-btn {
        font-size: 0.7rem;
        letter-spacing: 0;
    }

    .content-stage {
        padding-top: 100px;
    }

    .hero-text {
        font-size: 0.85rem;
    }
}

/* Dispositivos Ultra-Pequenos / Antigos */
@media (max-width: 320px) {
    :root {
        font-size: 14px; /* Redução base */
    }

    .glow-title {
        font-size: 1.2rem;
    }

    .section-title {
        font-size: 1.0rem;
    }

    .hero-text {
        font-size: 0.75rem;
        line-height: 1.4;
    }

    .card-item, .proclamation-card {
        padding: 15px;
    }

    .sphere-text {
        font-size: 0.6rem !important;
    }

    .slogan-pulsar {
        font-size: 0.5rem;
    }
}
/* Salvaguarda Anti-Burrice: Forçar encaixe em telas curtas */
@media (max-height: 700px) {
    .planetary-center {
        height: 55vh;
        margin-top: 30px;
    }

    .sphere-text {
        font-size: clamp(0.5rem, 1.8vh, 0.8rem) !important;
    }

    .sphere-label {
        font-size: 0.9em;
    }

    .slogan-pulsar {
        font-size: 0.8em;
    }

    .discreet-logo {
        height: 70px;
    }

    .sol-pulsar, .lua-alinhada {
        height: 60px;
    }

    .main-header {
        top: 15px;
    }

    .page-footer {
        padding: 10px;
    }
}

@media (max-height: 500px) {
    .planetary-center {
        height: 45vh;
        margin-top: 20px;
    }

    .sphere-text {
        font-size: clamp(0.4rem, 1.6vh, 0.6rem) !important;
    }

    .discreet-logo {
        height: 50px;
    }

    .sol-pulsar, .lua-alinhada {
        display: none; /* Esconde elementos decorativos se o espaço for crítico */
    }
}

/* Bloqueio de Orientação Landscape */
.orientation-lock {
    display: none;
    position: fixed;
    inset: 0;
    background: #05070a;
    z-index: 9999;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 30px;
    font-family: var(--font-display);
}

.lock-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.rotate-icon {
    font-size: 4rem;
    animation: rotateDevice 2s infinite ease-in-out;
}

.orientation-lock p {
    color: var(--color-yellow);
    font-size: 1.2rem;
    line-height: 1.4;
    max-width: 300px;
}

@keyframes rotateDevice {
    0%, 100% { transform: rotate(0deg); }
    50% { transform: rotate(90deg); }
}

@media screen and (max-width: 950px) and (orientation: landscape) {
    .orientation-lock {
        display: flex;
    }
    
    /* Esconde o resto do conteúdo para evitar renderização pesada */
    .main-header, .cosmic-stage, .content-stage, .page-footer {
        display: none !important;
    }
}
