/* =====================================================
   THE BIOZYGOTIC FRAMEWORK™ — GLOBAL DESIGN SYSTEM
   Humanistic Warmth meets Mathematical Rigor
   ===================================================== */

:root {
    --primary-terracotta: #D17742;
    --secondary-blue: #5B8DBE;
    --neutral-gray: #6B6760;
    --accent-sage: #8A9A7F;
    --bg-cream: #F5F1E8;
    --text-dark: #2C2A28;
    --danger-red: #C84B31;
    --warning-yellow: #E5A93B;
    --thrive-green: #6B8E23;

    --font-head: 'Merriweather', serif;
    --font-body: 'Lato', sans-serif;
    --font-mono: 'Fira Mono', monospace;

    --radius-sm: 6px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --shadow-sm: 0 2px 10px rgba(0,0,0,0.05);
    --shadow-md: 0 5px 25px rgba(0,0,0,0.07);
    --shadow-lg: 0 10px 40px rgba(0,0,0,0.1);
}

/* ── RESET ───────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
    font-family: var(--font-body);
    color: var(--text-dark);
    background-color: var(--bg-cream);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
    font-family: var(--font-head);
    color: var(--primary-terracotta);
    line-height: 1.3;
    margin-bottom: 1rem;
}

p { margin-bottom: 1.2rem; }
p:last-child { margin-bottom: 0; }

a { color: var(--primary-terracotta); }

img { max-width: 100%; height: auto; display: block; }

/* ── LAYOUT ──────────────────────────────────────── */
.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 5%;
}

.section {
    padding: 5rem 5%;
    max-width: 1100px;
    margin: 0 auto;
}

.section-full {
    padding: 5rem 5%;
}

.text-center { text-align: center; }

/* ── NAVIGATION ──────────────────────────────────── */
nav {
    background-color: white;
    padding: 0 5%;
    height: 80px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-logo a {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.nav-logo img { height: 56px; width: auto; }

.nav-logo-text {
    color: var(--primary-terracotta);
    font-family: var(--font-head);
    font-size: 1.4rem;
    font-weight: 700;
    letter-spacing: 1px;
}

.nav-links { display: flex; align-items: center; gap: 0.25rem; }

.nav-links a {
    text-decoration: none;
    color: var(--neutral-gray);
    font-weight: 700;
    font-size: 0.9rem;
    padding: 0.5rem 0.75rem;
    border-radius: var(--radius-sm);
    transition: color 0.2s ease, background 0.2s ease;
}

.nav-links a:hover { color: var(--primary-terracotta); background: rgba(209,119,66,0.07); }
.nav-links a.active { color: var(--primary-terracotta); }

/* Mobile nav toggle */
.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    background: none;
    border: none;
    padding: 4px;
}
.nav-toggle span {
    display: block; width: 24px; height: 2px;
    background: var(--neutral-gray); border-radius: 2px;
    transition: all 0.3s ease;
}

/* ── CARDS & BLOCKS ──────────────────────────────── */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.card {
    background: white;
    padding: 2.5rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    border-top: 4px solid var(--primary-terracotta);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.content-block {
    background: white;
    padding: 3rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    margin-bottom: 3rem;
}

.highlight-block {
    border-left: 6px solid var(--secondary-blue);
    background: rgba(91,141,190,0.04);
}

/* ── BUTTONS ─────────────────────────────────────── */
.btn {
    display: inline-block;
    padding: 0.85rem 2rem;
    border-radius: var(--radius-sm);
    text-decoration: none;
    font-weight: 700;
    font-size: 0.95rem;
    transition: all 0.25s ease;
    cursor: pointer;
    border: 2px solid transparent;
    font-family: var(--font-body);
}

.btn-primary {
    background: var(--primary-terracotta);
    color: white;
    border-color: var(--primary-terracotta);
}
.btn-primary:hover {
    background: #b86435;
    border-color: #b86435;
    box-shadow: 0 4px 14px rgba(209,119,66,0.35);
    transform: translateY(-1px);
}

.btn-outline {
    background: transparent;
    border-color: var(--primary-terracotta);
    color: var(--primary-terracotta);
}
.btn-outline:hover {
    background: var(--primary-terracotta);
    color: white;
}

.btn-blue {
    background: var(--secondary-blue);
    color: white;
    border-color: var(--secondary-blue);
}
.btn-blue:hover { background: #4a7aab; }

/* ── GRIDS ───────────────────────────────────────── */
.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
}

/* ── FOOTER ──────────────────────────────────────── */
footer {
    background-color: var(--text-dark);
    color: white;
    text-align: center;
    padding: 4rem 5% 2.5rem;
    margin-top: 5rem;
}

footer .footer-brand {
    font-family: var(--font-head);
    font-size: 1.2rem;
    color: var(--primary-terracotta);
    font-weight: 700;
    margin-bottom: 0.4rem;
}

footer .footer-tagline { color: #d1cec9; margin-bottom: 1.5rem; }

footer .footer-disclaimer {
    font-size: 0.82rem;
    color: #9ca3af;
    font-style: italic;
    max-width: 560px;
    margin: 0 auto 2rem;
    line-height: 1.6;
}

footer .footer-copy {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 1.5rem;
    font-size: 0.82rem;
    color: var(--accent-sage);
    margin: 0;
}

/* ── UTILITY ─────────────────────────────────────── */
.val-display {
    font-family: var(--font-mono);
    color: var(--primary-terracotta);
    font-weight: bold;
}

.severity-badge {
    display: inline-block;
    padding: 0.2rem 0.6rem;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 900;
    text-transform: uppercase;
}

.feature-list { list-style: none; padding-left: 0; }
.feature-list li {
    padding-left: 2rem;
    margin-bottom: 0.9rem;
    position: relative;
    line-height: 1.5;
}
.feature-list li::before {
    content: "→";
    position: absolute;
    left: 0;
    color: var(--primary-terracotta);
    font-weight: bold;
}

.audience-icon { font-size: 2.5rem; margin-bottom: 1rem; }

/* ── PAGE HERO (index) ───────────────────────────── */
.hero {
    min-height: 88vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 4rem 5%;
    position: relative;
}

.compact-equation {
    font-family: var(--font-mono);
    font-size: clamp(1.8rem, 4.5vw, 3.2rem);
    color: var(--primary-terracotta);
    font-weight: 300;
    letter-spacing: 2px;
    margin-bottom: 0.5rem;
    opacity: 0;
    transform: translateY(20px);
}

.equation-subtitle {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2.5rem;
    opacity: 0;
    transform: translateY(10px);
    flex-wrap: wrap;
}

.eq-pill {
    font-size: 0.8rem;
    color: var(--primary-terracotta);
    font-weight: bold;
    text-decoration: none;
    border: 1px solid var(--primary-terracotta);
    padding: 0.3rem 0.9rem;
    border-radius: 20px;
    transition: all 0.3s ease;
}
.eq-pill:hover { background: var(--primary-terracotta); color: white; }

.is-visible {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    color: var(--neutral-gray);
    font-size: 0.85rem;
    gap: 0.4rem;
    animation: bounce 2.5s infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50%       { transform: translateY(-8px); }
}

/* ── FRAMEWORK PAGE ──────────────────────────────── */
.hero-header {
    text-align: center;
    padding: 5rem 10% 3rem;
    max-width: 900px;
    margin: 0 auto;
}

.equation-explorer {
    background: white;
    padding: 3rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    text-align: center;
    margin-bottom: 3rem;
}

.eq-display {
    font-family: 'Times New Roman', serif;
    font-size: clamp(2rem, 4vw, 3rem);
    color: var(--text-dark);
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 2rem;
}

.eq-symbol { cursor: help; transition: all 0.2s ease; position: relative; }
.eq-symbol:hover { color: var(--primary-terracotta); transform: scale(1.1); }

.tooltip {
    visibility: hidden;
    width: 260px;
    background: var(--text-dark);
    color: white;
    text-align: center;
    border-radius: var(--radius-sm);
    padding: 12px;
    position: absolute;
    z-index: 10;
    bottom: 130%;
    left: 50%;
    transform: translateX(-50%);
    opacity: 0;
    transition: opacity 0.3s;
    font-family: var(--font-body);
    font-size: 0.88rem;
    line-height: 1.5;
    font-weight: normal;
    pointer-events: none;
}
.eq-symbol:hover .tooltip { visibility: visible; opacity: 1; }

.vocab-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.vocab-card {
    background: var(--bg-cream);
    padding: 1.5rem;
    border-radius: var(--radius-md);
    border-top: 4px solid var(--primary-terracotta);
}

table { width: 100%; border-collapse: collapse; margin: 1.5rem 0; }
th { background: var(--text-dark); color: white; text-align: left; padding: 1rem 1.2rem; font-family: var(--font-body); }
td { padding: 0.9rem 1.2rem; border-bottom: 1px solid var(--bg-cream); }
tr:hover td { background: rgba(245,241,232,0.5); }

/* Tabs (framework page) */
.tab-buttons {
    display: flex;
    gap: 10px;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    justify-content: center;
}
.tab-btn {
    padding: 0.7rem 1.5rem;
    background: white;
    border: 2px solid #e0d9cc;
    border-radius: var(--radius-md);
    cursor: pointer;
    font-family: var(--font-head);
    font-weight: bold;
    font-size: 0.9rem;
    color: var(--neutral-gray);
    transition: all 0.25s ease;
}
.tab-btn:hover { border-color: var(--primary-terracotta); color: var(--primary-terracotta); }
.tab-btn.active { background: var(--primary-terracotta); color: white; border-color: var(--primary-terracotta); }

.tab-content { display: none; background: white; padding: 2.5rem; border-radius: var(--radius-md); box-shadow: var(--shadow-sm); }
.tab-content.active { display: block; animation: fadeIn 0.4s ease; }

@keyframes fadeIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }

/* ── CONTACT PAGE ────────────────────────────────── */
.contact-section { padding: 5rem 5%; max-width: 1100px; margin: 0 auto; }
.contact-content { display: grid; grid-template-columns: 2fr 1fr; gap: 3rem; margin-bottom: 4rem; }
.contact-card {
    background: white;
    padding: 3rem;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    text-align: center;
    border-top: 4px solid var(--primary-terracotta);
    margin-bottom: 2rem;
}
.contact-card h2 { color: var(--text-dark); margin-top: 0; }
.email-link {
    display: inline-block;
    background: var(--bg-cream);
    color: var(--primary-terracotta);
    font-family: var(--font-mono);
    font-size: 1.2rem;
    font-weight: bold;
    padding: 1rem 2rem;
    border-radius: var(--radius-sm);
    text-decoration: none;
    border: 2px solid #e0d5c5;
    transition: all 0.3s ease;
}
.email-link:hover {
    background: var(--primary-terracotta);
    color: white;
    border-color: var(--primary-terracotta);
    transform: translateY(-2px);
    box-shadow: 0 4px 14px rgba(209,119,66,0.25);
}
.social-card {
    background: var(--text-dark);
    color: white;
    padding: 2.5rem;
    border-radius: var(--radius-md);
    text-align: center;
    border-top: 4px solid var(--secondary-blue);
}
.social-card h3 { color: white; margin-top: 0; }
.info-box {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    border-left: 4px solid var(--secondary-blue);
    margin-bottom: 1.5rem;
}
.info-box h3 { color: var(--secondary-blue); margin-top: 0; }
.faq-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }
.faq-item { background: var(--bg-cream); padding: 1.5rem; border-radius: var(--radius-sm); }
.faq-item h3 { color: var(--text-dark); font-size: 1rem; margin-bottom: 0.5rem; }
.faq-item p { color: var(--neutral-gray); font-size: 0.92rem; }
.faq-item a { color: var(--primary-terracotta); font-weight: bold; }

/* ── CTA DARK BLOCK ──────────────────────────────── */
.cta-dark {
    background: var(--text-dark);
    color: white;
    padding: 4rem 3rem;
    border-radius: var(--radius-lg);
    text-align: center;
    margin-bottom: 3rem;
}
.cta-dark h2 { color: white; }
.cta-dark p { color: #aaa; max-width: 620px; margin: 0 auto 2rem; }

/* ── RESEARCH PAGE ───────────────────────────────── */
.under-design {
    min-height: 60vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 4rem 5%;
}
