/* --- VARIÁVEIS --- */
:root {
    --primary: #0A4D68;       /* Deep Ocean Blue */
    --primary-dark: #06384d;
    --accent: #047857;        /* Emerald */
    --secondary: #D97706;     /* Warm Amber */
    
    --bg-body: #FAFAF9;       /* Stone 50 */
    --bg-card: #FFFFFF;
    
    --bg-calc-item: #FFFFFF;
    --bg-calc-item-hover: #FAFAF9;
    --border-calc: #E7E5E4;
    
    --text-main: #1C1917;     /* Stone 900 */
    --text-muted: #57534E;    /* Stone 600 */
    
    --border-subtle: #E7E5E4; /* Stone 200 */
    
    --container-width: 1200px;
    --header-height: 90px;
}

/* Dark Mode */
[data-theme="dark"] {
    --bg-body: #0C0A09;
    --bg-card: #1C1917;
    
    --bg-calc-item: #292524; 
    --bg-calc-item-hover: #44403C; 
    --border-calc: #44403C;
    
    --text-main: #F5F5F4;
    --text-muted: #A8A29E;
    --primary: #38BDF8; 
    --accent: #34D399;
    --border-subtle: #292524;
}

/* --- GLOBAL --- */
* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: 'Source Sans 3', sans-serif;
    background-color: var(--bg-body);
    color: var(--text-main);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    transition: background-color 0.5s ease, color 0.5s ease;
    overflow-x: hidden; /* Evita rolagem horizontal indesejada no mobile */
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    color: var(--primary);
    letter-spacing: -0.02em;
}

a { text-decoration: none; color: inherit; transition: 0.3s ease; }
ul { list-style: none; }
img { max-width: 100%; height: auto; display: block; } /* height auto evita distorção */

/* ------------------------------------------------------------------ */
/* --- PERFORMANCE & ACESSIBILIDADE --- */
/* ------------------------------------------------------------------ */

/* Evita que o conteúdo do HERO atrase LCP por animações de opacity/transform */
.hero .animate-fade-in {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
}

/* O card flutuante não deve começar invisível (evita “pintar” tarde) */
.personal-card-float {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
}

/* Desliga animações/transições quando o usuário prefere reduzir movimento */
@media (prefers-reduced-motion: reduce) {
    * {
        animation: none !important;
        transition: none !important;
        scroll-behavior: auto !important;
    }
    .hero {
        background-attachment: scroll !important;
    }
}

/* Renderiza abaixo da dobra sob demanda (Chromium) — acelera FCP/LCP e reduz trabalho inicial */
@supports (content-visibility: auto) {
    .methodology-section,
    .featured-section,
    .quizzes-section,
    .newsletter-section,
    footer {
        content-visibility: auto;
        contain-intrinsic-size: 1200px;
    }
}

/* --- ANIMAÇÕES --- */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes rotate-scale {
    0% { transform: rotate(0) scale(1); }
    50% { transform: rotate(180deg) scale(1.2); }
    100% { transform: rotate(360deg) scale(1); }
}

.animate-fade-in {
    animation: fadeInUp 0.8s ease-out forwards;
}

.animate-theme-switch i, 
.animate-theme-switch svg { 
    animation: rotate-scale 0.5s ease-in-out;
}

.delay-100 { animation-delay: 0.1s; }
.delay-200 { animation-delay: 0.2s; }
.delay-300 { animation-delay: 0.3s; }

/* --- LAYOUT --- */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 24px;
    width: 100%; /* Garante fluidez */
}

/* --- HEADER & NAV --- */
.top-bar {
    background-color: #0A4D68;
    color: #fff;
    padding: 8px 0;
    font-size: 0.85rem;
    position: relative;
    z-index: 1002;
}

.top-bar .container {
    display: flex;
    justify-content: flex-end; /* Mantém alinhado à direita */
    gap: 20px;
}

/* Seletor de idioma e tema no mobile */
@media (max-width: 480px) {
    .top-bar .container {
        justify-content: space-between; /* Distribui espaço em telas muito pequenas */
    }
}

.main-header {
    position: absolute;
    top: 40px;
    width: 100%;
    z-index: 1000;
    height: var(--header-height);
    border-bottom: 1px solid rgba(255,255,255,0.15);
    background: linear-gradient(to bottom, rgba(0,0,0,0.4), transparent);
    transition: all 0.3s ease;
}

.main-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
    margin: 0 auto; /* Corrigido de 0 */
}

.logo {
    font-family: 'Playfair Display', serif;
    font-size: 2rem;
    font-weight: 700; 
    color: #fff;
    display: flex;
    align-items: center;
    gap: 12px;
    letter-spacing: -0.03em;
}

.nav-menu { display: flex; gap: 32px; }
.nav-link {
    font-family: 'Source Sans 3', sans-serif;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -4px;
    left: 0;
    background-color: var(--secondary);
    transition: width 0.3s;
}
.nav-link:hover::after { width: 100%; }
.nav-link:hover { color: #fff; }

.btn-outline-white {
    border: 1px solid rgba(255,255,255,0.4);
    color: #fff;
    padding: 8px 24px;
    border-radius: 2px;
    text-transform: uppercase;
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.05em;
}
.btn-outline-white:hover {
    background-color: #fff;
    color: var(--primary);
    border-color: #fff;
}

/* --- HERO SECTION --- */
.hero {
    min-height: 800px; 

    /* Mantém seu visual atual, mas com base performance-friendly */
    background-color: #0A4D68;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;

    background-image:
        linear-gradient(
            to right,
            rgba(10, 77, 104, 0.95) 0%,
            rgba(10, 77, 104, 0.7) 40%,
            rgba(0,0,0,0.1) 100%
        ),
        url('../img/cabeçario.webp');

    display: flex;
    align-items: flex-start;
    position: relative;
    padding-top: 150px;
    color: #fff;
}

/* Parallax só no desktop e só se não for “reduzir movimento” */
@media (min-width: 769px) and (prefers-reduced-motion: no-preference) {
    .hero { background-attachment: fixed; }
}

/* Desativa parallax em mobile (melhora performance e evita bugs no iOS) */
@media (max-width: 768px) {
    .hero {
        background-attachment: scroll;
        min-height: auto; /* Altura flexível */
        height: auto;
        padding-bottom: 60px; /* Espaço extra embaixo */
    }
}

.hero .container {
    display: flex; 
    justify-content: space-between;
    align-items: flex-start;
    position: relative; 
    width: 100%;
}

.hero-content {
    max-width: 650px;
    margin-top: 0; 
}

/* CARD FLUTUANTE DE PERSONAL */
.personal-card-float {
    position: absolute;
    top: -30px; 
    right: 0; /* Alinhado à direita do container */
    
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    
    background: rgba(255, 255, 255, 0.08); 
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 4px;
    padding: 15px 25px; 
    
    color: #fff;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);

    z-index: 20;
    min-width: 320px; 
}

.personal-card-float:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.3);
    transform: translateY(2px);
}

.p-info { text-align: left; }

.p-name {
    font-family: 'Playfair Display', serif;
    font-size: 1.1rem;
    font-weight: 700;
    color: #fff;
    margin: 0;
    line-height: 1.1;
    display: flex;
    align-items: center;
    gap: 8px;
}

.p-status-dot {
    width: 6px;
    height: 6px;
    background-color: #4ade80;
    border-radius: 50%;
    display: inline-block;
    box-shadow: 0 0 6px #4ade80;
}

.p-cref {
    font-family: 'Source Sans 3', sans-serif;
    font-size: 0.75rem;
    color: rgba(255,255,255,0.7);
    letter-spacing: 0.05em;
    display: block;
    margin-top: 3px;
}

.p-btn-small {
    background-color: var(--secondary);
    color: #fff;
    border: none;
    padding: 8px 16px;
    border-radius: 2px;
    font-family: 'Source Sans 3', sans-serif;
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}

.p-btn-small:hover {
    background-color: #d97706;
    transform: translateY(-1px);
}

.science-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background-color: rgba(4, 120, 87, 0.2);
    color: #6EE7B7; 
    border: 1px solid #059669;
    padding: 6px 16px;
    border-radius: 50px;
    font-family: 'Source Sans 3', sans-serif;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 30px;
    backdrop-filter: blur(4px);
}

.hero h1 {
    font-family: 'Playfair Display', serif;
    font-size: 5.5rem; 
    color: #fff;
    line-height: 1.1;
    margin-bottom: 24px;
    font-weight: 700;
    text-shadow: 0 2px 10px rgba(0,0,0,0.3); 
}

.hero p {
    font-family: 'Source Sans 3', sans-serif;
    font-size: 1.35rem;
    font-weight: 300;
    color: rgba(255,255,255,0.9);
    margin-bottom: 20px;
    max-width: 600px;
    line-height: 1.6;
}

.hero-note {
    color: #7DD3FC; 
    font-size: 0.95rem;
    font-style: italic;
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 25px; 
}

.btn-hero {
    background-color: var(--secondary); 
    color: #fff;
    padding: 16px 40px;
    border-radius: 2px;
    font-family: 'Source Sans 3', sans-serif;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 10px 20px rgba(0,0,0,0.2);
}
.btn-hero:hover {
    background-color: #B45309;
    transform: translateY(-2px);
}

/* --- CALCULADORAS --- */
.calculators-bar {
    background-color: var(--bg-card);
    max-width: var(--container-width);
    margin: -80px auto 60px; /* Margem negativa para sobrepor Hero */
    position: relative;
    z-index: 10;
    border-radius: 2px; 
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
    padding: 50px;
    border-top: none; 
}

.calc-header {
    text-align: center;
    margin-bottom: 45px;
    position: relative;
}

.calc-header::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background-color: var(--accent);
    margin: 20px auto 0;
}

.calc-header h2 {
    font-size: 2.2rem;
    color: var(--primary);
    margin-bottom: 10px;
    letter-spacing: -0.02em;
}

.calc-header p {
    font-family: 'Source Sans 3', sans-serif;
    color: var(--text-muted);
    font-size: 1.15rem;
    font-weight: 300;
}

.calc-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr); 
    gap: 30px;
}

.calc-item {
    display: flex;
    align-items: center; 
    text-align: left;
    padding: 25px;
    background-color: var(--bg-calc-item);
    border: 1px solid var(--border-calc);
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    cursor: pointer;
    position: relative;
    overflow: hidden;
    text-decoration: none; 
}

.calc-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background-color: var(--primary);
    transform: scaleY(0);
    transition: transform 0.3s ease;
    transform-origin: bottom;
}

.calc-item:hover::before { transform: scaleY(1); }

.calc-item:hover {
    border-color: rgba(10, 77, 104, 0.3);
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    background-color: var(--bg-calc-item-hover);
}

.calc-icon-wrapper {
    width: 56px;
    height: 56px;
    background-color: rgba(10, 77, 104, 0.04);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    margin-right: 20px;
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.calc-item:hover .calc-icon-wrapper {
    background-color: var(--primary);
    color: #fff;
}

.calc-info h3 {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    color: var(--text-main);
    font-size: 1.25rem;
    margin-bottom: 4px;
    line-height: 1.2;
}

.calc-info span {
    font-family: 'Source Sans 3', sans-serif;
    font-size: 0.9rem;
    color: var(--text-muted);
    font-weight: 400;
    letter-spacing: 0.02em;
}

/* --- METHODOLOGY --- */
.methodology-section {
    padding: 70px 0;
    background-color: #fff;
    border-bottom: 1px solid var(--border-subtle);
    position: relative;
}

[data-theme="dark"] .methodology-section { background-color: #1a1a1a; }

.methodology-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 1px;
    height: 30px;
    background-color: var(--accent);
}

.method-header {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 50px;
}

.section-badge {
    font-family: 'Source Sans 3', sans-serif;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--accent);
    font-weight: 700;
    display: inline-block;
    margin-bottom: 10px;
    background-color: rgba(4, 120, 87, 0.08);
    padding: 5px 10px;
    border-radius: 2px;
}

.method-header h2 {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 8px;
    line-height: 1.1;
}

.method-subtitle {
    font-family: 'Playfair Display', serif;
    font-size: 1.3rem;
    color: var(--text-muted);
    font-style: italic;
    margin-top: 10px;
}

.method-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-bottom: 40px;
    max-width: 1000px;
    margin-left: auto;
    margin-right: auto;
}

.method-card {
    text-align: center;
    padding: 10px;
    transition: transform 0.3s;
}

.method-card:hover { transform: translateY(-3px); }

.method-icon-box {
    width: 60px;
    height: 60px;
    background-color: rgba(10, 77, 104, 0.03);
    color: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    border: 1px solid rgba(10, 77, 104, 0.1);
    position: relative;
}

[data-theme="dark"] .method-icon-box {
    background-color: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
}

.method-icon-box::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 1px solid var(--primary);
    opacity: 0.2;
    transform: scale(1.2);
    transition: transform 0.3s;
}

.method-card:hover .method-icon-box::after {
    transform: scale(1.3);
    opacity: 0.4;
}

.method-card h3 {
    font-size: 1.2rem;
    margin-bottom: 10px;
    color: var(--text-main);
    font-weight: 700;
}

.method-card p {
    font-family: 'Source Sans 3', sans-serif;
    font-size: 0.95rem;
    color: var(--text-muted);
    line-height: 1.5;
}

.method-seal {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    margin-top: 40px;
    opacity: 0.7;
}

.seal-line {
    height: 1px;
    background-color: var(--border-subtle);
    flex-grow: 1;
    max-width: 100px;
}

.seal-content {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: 'Source Sans 3', sans-serif;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.15em;
    color: var(--primary);
}

/* --- ARTIGOS --- */
.featured-section {
    padding: 40px 0 80px;
    background-color: var(--bg-body);
}

.section-header-left {
    margin-bottom: 50px;
    border-left: 4px solid var(--primary);
    padding-left: 20px;
}
.section-header-left h2 {
    font-size: 2.8rem;
    color: var(--text-main);
}
.section-header-left p {
    font-family: 'Source Sans 3', sans-serif;
    font-size: 1.1rem;
    color: var(--text-muted);
}

.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

@media (min-width: 1024px) {
     .articles-grid { grid-template-columns: repeat(3, 1fr); }
}

.article-card {
    background-color: var(--bg-card);
    border: 1px solid var(--border-subtle);
    transition: transform 0.3s, box-shadow 0.3s;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.article-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.08);
    border-color: var(--primary);
}

.card-img-container {
    height: 220px;
    overflow: hidden;
    position: relative;
    flex-shrink: 0;
}

.card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.article-card:hover .card-img { transform: scale(1.05); }

.card-content {
    padding: 25px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.card-category {
    font-family: 'Source Sans 3', sans-serif;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--accent);
    margin-bottom: 12px;
}

.card-title {
    font-size: 1.5rem;
    line-height: 1.3;
    margin-bottom: 12px;
    color: var(--text-main);
}

.card-excerpt {
    font-family: 'Source Sans 3', sans-serif;
    font-size: 1rem;
    color: var(--text-muted);
    margin-bottom: 20px;
    flex-grow: 1;
}

.card-footer {
    border-top: 1px solid var(--border-subtle);
    padding-top: 20px;
    font-size: 0.85rem;
    color: var(--text-muted);
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
}

/* --- QUIZZES --- */
.quizzes-section {
    padding: 80px 0;
    background-color: #fff;
    border-top: 1px solid var(--border-subtle);
}

.quiz-header {
    text-align: center;
    margin-bottom: 50px;
}

.quiz-header h2 {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 15px;
}

.quiz-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.quiz-card {
    background-color: var(--bg-body);
    border: 2px dashed var(--border-subtle);
    border-radius: 4px;
    padding: 30px;
    text-align: center;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.quiz-card:hover {
    border-color: var(--accent);
    background-color: #fff;
    box-shadow: 0 10px 25px rgba(0,0,0,0.05);
    transform: translateY(-5px);
}

.quiz-icon {
    width: 60px;
    height: 60px;
    background-color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    color: var(--accent);
    border: 1px solid var(--border-subtle);
    box-shadow: 0 4px 6px rgba(0,0,0,0.02);
}

.quiz-card h3 {
    font-family: 'Playfair Display', serif;
    font-size: 1.4rem;
    margin-bottom: 10px;
    color: var(--text-main);
}

.quiz-card p {
    font-family: 'Source Sans 3', sans-serif;
    font-size: 0.95rem;
    color: var(--text-muted);
    margin-bottom: 25px;
    line-height: 1.5;
}

.btn-quiz {
    background-color: transparent;
    color: var(--primary);
    border: 1px solid var(--primary);
    padding: 8px 20px;
    border-radius: 2px;
    font-family: 'Source Sans 3', sans-serif;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 0.05em;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-block;
    text-decoration: none;
}

.btn-quiz:hover {
    background-color: var(--primary);
    color: #fff;
}

/* --- NEWSLETTER --- */
.newsletter-section {
    background-color: var(--primary);
    color: #fff;
    padding: 80px 0;
    text-align: center;
    margin-top: 40px;
}

.newsletter-content {
    max-width: 600px;
    margin: 0 auto;
}

.newsletter-content h2 {
    color: #fff;
    font-size: 2.5rem;
    margin-bottom: 15px;
}

.newsletter-form {
    display: flex;
    gap: 10px;
    margin-top: 30px;
    justify-content: center;
}

.newsletter-input {
    padding: 15px 20px;
    border-radius: 2px;
    border: none;
    width: 100%;
    max-width: 350px;
    font-family: 'Source Sans 3', sans-serif;
}

.btn-subscribe {
    background-color: var(--secondary);
    color: #fff;
    border: none;
    padding: 15px 30px;
    font-weight: 700;
    text-transform: uppercase;
    cursor: pointer;
    border-radius: 2px;
}

/* --- FOOTER --- */
footer {
    background-color: #1C1917;
    color: #A8A29E;
    padding: 80px 0 0;
    font-size: 0.95rem;
    font-family: 'Source Sans 3', sans-serif;
    border-top: 4px solid var(--accent);
}

.footer-grid {
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); 
    gap: 50px;
    padding-bottom: 60px;
}

/* Corrigido: seu HTML usa <footer> (não existe .footer no markup) */
footer h4 {
    color: #fff;
    font-family: 'Playfair Display', serif;
    font-size: 1.3rem;
    margin-bottom: 25px;
    letter-spacing: 0.05em;
    position: relative;
}

footer h4::after {
    content: '';
    display: block;
    width: 30px;
    height: 2px;
    background-color: var(--accent);
    margin-top: 10px;
}

footer ul li { margin-bottom: 12px; }

footer ul li a { 
    color: #A8A29E; 
    transition: 0.2s;
    display: inline-block;
}

footer ul li a:hover { 
    color: #fff; 
    transform: translateX(5px); 
}

.footer-bottom {
    border-top: 1px solid #333;
    padding: 30px 0;
    text-align: center;
    font-size: 0.85rem;
    background-color: #151312;
}

/* ------------------------------------------------------------------ */
/* --- AJUSTES DE RESPONSIVIDADE (CRÍTICO PARA MOBILE) --- */
/* ------------------------------------------------------------------ */

@media (max-width: 1024px) {
    /* Ajustes para Tablets */
    .hero h1 { font-size: 4rem; }
    
    .calc-grid, .method-grid, .quiz-grid {
        grid-template-columns: repeat(2, 1fr); /* 2 colunas no tablet */
    }
}

@media (max-width: 900px) {
    /* Ajustes Gerais Mobile */
    .hero .container {
        flex-direction: column;
        align-items: flex-start;
        padding-top: 40px;
    }

    .hero-content {
        margin-top: 20px;
        margin-bottom: 40px;
    }

    /* O Card de personal agora fica abaixo do texto */
    .personal-card-float {
        position: relative; 
        top: auto;
        right: auto;
        width: 100%;
        max-width: 100%; 
        margin-top: 10px;
        box-sizing: border-box; /* Garante que padding não quebre a largura */
    }
    
    /* MENU MOBILE VISÍVEL */
    .main-header {
        position: relative; /* Deixa de ser absoluto no mobile para empurrar o conteúdo */
        top: 0;
        background: var(--primary); /* Fundo sólido para leitura */
        height: auto;
        padding: 15px 0;
    }

    .main-header .container {
        flex-direction: column; /* Empilha logo e menu */
        padding: 0 20px;
        gap: 15px;
    }

    .nav-menu { 
        display: flex; /* Garante visibilidade */
        flex-wrap: wrap; /* Permite quebra de linha se muitos itens */
        justify-content: center;
        gap: 15px;
        width: 100%;
    }

    .nav-link {
        font-size: 0.9rem;
    }

    .hero h1 { font-size: 3rem; } /* Título menor */
    
    .newsletter-form { flex-direction: column; align-items: center; }
    
    /* Reseta margem negativa da barra de calculadoras */
    .calculators-bar { 
        margin: 0 auto 60px; 
        padding: 30px 20px;
    }
    
    /* Grids viram 1 coluna no celular */
    .calc-grid,
    .method-grid,
    .quiz-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .section-header-left h2 { font-size: 2rem; }
}

@media (max-width: 480px) {
    /* Celulares Pequenos */
    .hero h1 { font-size: 2.5rem; }
    
    /* Personal Card vira coluna se precisar */
    .personal-card-float {
        flex-direction: column;
        text-align: center;
        gap: 15px;
    }
    
    .p-info { text-align: center; }
    .p-name { justify-content: center; }
    
    .top-bar .container {
        justify-content: space-between;
    }
}
