/*
Theme Name: SX v3.2 — Síntese Exogenética
Theme URI: https://casteloweb.com
Author: Prof. Luiz Guilherme Farias Castelo
Author URI: https://casteloweb.com
Description: Tema oficial da Síntese Exogenética v3.2 — A Teoria Formal da Consciência, Informação e Geometria do Real. Design espacial com suporte a MathJax, Three.js e Oráculo D.A.N.N.Y.
Version: 3.2
License: CC BY-NC-ND 4.0
License URI: https://creativecommons.org/licenses/by-nc-nd/4.0/
Text Domain: sx-theme
Tags: dark, science, philosophy, custom-menu, custom-logo, one-column
*/

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

:root {
    --bg:       #050a15;
    --bg2:      #0b1221;
    --bg3:      rgba(11,18,33,0.85);
    --gold:     #c9a84c;
    --gold2:    #e8c97a;
    --gold3:    rgba(201,168,76,0.12);
    --blue:     #3b6fd4;
    --blue2:    #2251b8;
    --text:     #e2e8f0;
    --muted:    #94a3b8;
    --faint:    rgba(221,227,239,0.06);
    --border:   rgba(201,168,76,0.18);
    --border2:  rgba(221,227,239,0.07);
    --radius:   14px;
    --fs:       1.08rem;
    --serif:    'Playfair Display', Georgia, serif;
    --sans:     'DM Sans', system-ui, sans-serif;
    --mono:     'JetBrains Mono', monospace;
}

html { scroll-behavior: smooth; font-size: var(--fs); transition: background-color 0.3s ease; }
body {
    background: var(--bg);
    color: var(--text);
    font-family: var(--sans);
    font-weight: 400;
    line-height: 1.75;
    overflow-x: hidden;
    transition: color 0.3s ease, background-color 0.3s ease;
}
::selection { background: var(--gold); color: #000; }
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--gold); border-radius: 4px; }

/* ========== TYPOGRAPHY ========== */
h1, h2, h3, h4 { font-family: var(--serif); line-height: 1.2; font-weight: 700; transition: color 0.3s; }
h1 { font-size: clamp(2.6rem, 6.5vw, 6rem); font-weight: 900; }
h2 { font-size: clamp(2rem, 4vw, 3.2rem); }
h3 { font-size: clamp(1.3rem, 2.5vw, 1.8rem); }
h4 { font-size: 1.15rem; font-family: var(--mono); font-weight: 700; letter-spacing: .04em; }
p  { color: var(--muted); line-height: 1.9; margin-bottom: 1.2rem; font-size: 1.05rem; transition: color 0.3s; }
strong { color: var(--text); font-weight: 600; }
em { color: var(--gold2); font-style: italic; font-weight: 500; letter-spacing: 0.02em; }
a  { color: var(--gold); text-decoration: none; transition: color .2s; }
a:hover { color: var(--gold2); }

.text-gold   { color: var(--gold); }
.text-gold2  { color: var(--gold2); }
.text-blue   { color: var(--blue); }
.text-muted  { color: var(--muted); }
.font-mono   { font-family: var(--mono); }
.font-serif  { font-family: var(--serif); }
.italic      { font-style: italic; }
.text-center { text-align: center; }
.text-justify{ text-align: justify; }
.text-sm     { font-size: .9rem; }
.text-xs     { font-size: .8rem; }

/* ========== LAYOUT ========== */
.container     { max-width: 1360px; margin: 0 auto; padding: 0 clamp(1rem, 4vw, 3rem); }
.container-wide{ max-width: 1500px; margin: 0 auto; padding: 0 clamp(1rem, 4vw, 3rem); }
.section       { padding: clamp(4rem, 10vw, 8rem) 0; position: relative; }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2.5rem; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2rem; }

@media (max-width: 900px) {
    .grid-2 { grid-template-columns: 1fr; }
    .grid-3 { grid-template-columns: 1fr; }
    .grid-4 { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 600px) { .grid-4 { grid-template-columns: 1fr; } }

/* ========== CARDS & GLASS ========== */
.glass {
    background: var(--bg3);
    border: 1px solid var(--border2);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: var(--radius);
    transition: border-color .3s, box-shadow .3s, background 0.3s;
}
.glass:hover { border-color: var(--border); box-shadow: 0 0 40px rgba(201,168,76,.06); }
.glass-gold  { border-color: var(--border) !important; }
.card { padding: 2.5rem; border-radius: var(--radius); }

/* ========== BADGE ========== */
.badge {
    display: inline-block;
    padding: .35rem 1rem;
    border: 1px solid var(--border);
    border-radius: 999px;
    font-family: var(--mono);
    font-size: .8rem;
    color: var(--gold);
    background: var(--gold3);
    letter-spacing: .06em;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 1.2rem;
}
.badge-blue {
    border-color: rgba(59,111,212,.3);
    color: #7ca4e8;
    background: rgba(59,111,212,.08);
}

/* ========== DIVIDERS ========== */
.divider { width: 80px; height: 3px; background: var(--gold); margin: 1.5rem 0 2rem 0; border-radius: 2px; }
.divider-center { margin-left: auto; margin-right: auto; }

/* ========== BUTTONS ========== */
.btn {
    display: inline-flex; align-items: center; gap: .5rem;
    padding: 1rem 2.5rem;
    border-radius: 999px;
    font-family: var(--sans);
    font-weight: 600; font-size: 1rem;
    cursor: pointer; transition: all .25s;
    border: none; text-decoration: none;
}
.btn-gold { background: var(--gold); color: #000; }
.btn-gold:hover { background: var(--gold2); transform: translateY(-2px); box-shadow: 0 8px 24px rgba(201,168,76,.3); color: #000; }
.btn-outline { background: transparent; border: 1.5px solid var(--gold); color: var(--gold); }
.btn-outline:hover { background: var(--gold3); transform: translateY(-2px); color: var(--gold2); }

/* ========== SPACE BACKGROUND ========== */
.bg-space {
    position: fixed; inset: 0; z-index: -3; pointer-events: none;
    background-color: var(--bg);
    background-image:
        radial-gradient(circle at 15% 25%, #ffffff 1px, transparent 1px),
        radial-gradient(circle at 75% 15%, #ffeaa7 1.5px, transparent 1.5px),
        radial-gradient(circle at 45% 65%, #ffffff 1px, transparent 1px),
        radial-gradient(circle at 85% 80%, #ffffff 1.5px, transparent 1.5px),
        radial-gradient(circle at 25% 85%, #ffeaa7 1px, transparent 1px),
        radial-gradient(circle at 5% 5%, #ffffff 1.5px, transparent 1.5px),
        radial-gradient(circle at 95% 95%, #ffffff 1px, transparent 1px);
    background-size: 250px 250px, 350px 350px, 400px 400px, 150px 150px, 300px 300px, 200px 200px, 500px 500px;
    opacity: 0.5;
    transition: opacity 0.5s ease;
}
html:not(.dark) .bg-space { opacity: 0; }

.bg-stars {
    position: fixed; top: 0; left: 0; width: 100vw; height: 100vh;
    background-image:
        radial-gradient(1px 1px at 20px 30px, #ffffff, rgba(0,0,0,0)),
        radial-gradient(1.5px 1.5px at 150px 180px, #ffffff, rgba(0,0,0,0)),
        radial-gradient(1px 1px at 80px 250px, #e8c97a, rgba(0,0,0,0)),
        radial-gradient(1.5px 1.5px at 300px 70px, #ffffff, rgba(0,0,0,0)),
        radial-gradient(2px 2px at 220px 350px, #ffffff, rgba(0,0,0,0)),
        radial-gradient(1px 1px at 380px 140px, #e8c97a, rgba(0,0,0,0));
    background-repeat: repeat;
    background-size: 400px 400px;
    z-index: -2; opacity: 0.6;
    pointer-events: none;
    animation: drift 150s linear infinite;
}
html:not(.dark) .bg-stars { opacity: 0; }
@keyframes drift { from { transform: translateY(0); } to { transform: translateY(-400px); } }

#earth-canvas { position: fixed; top: 0; left: 0; width: 100%; height: 100vh; z-index: -1; opacity: 0.6; pointer-events: none; }

.bg-noise {
    position: fixed; inset: 0; pointer-events: none; z-index: 1; opacity: .03;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
}

/* ========== NAV ========== */
#topnav {
    position: fixed; top: 0; width: 100%; z-index: 1000;
    background: rgba(5,10,21,.88);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border2);
    transition: background .3s;
}
body.admin-bar #topnav { top: 32px; }
@media screen and (max-width: 782px) { body.admin-bar #topnav { top: 46px; } }

.nav-inner {
    display: flex; align-items: center; justify-content: space-between;
    height: 70px;
    max-width: 1500px; margin: 0 auto;
    padding: 0 clamp(1.5rem, 4vw, 3rem);
}
.nav-logo {
    font-family: var(--mono); font-weight: 700; font-size: 1.35rem;
    color: var(--gold); letter-spacing: .04em; cursor: pointer; user-select: none;
    text-decoration: none;
}
.nav-logo span { color: var(--muted); font-size: .75rem; vertical-align: super; }
.nav-links { display: flex; align-items: center; gap: 2rem; list-style: none; }
.nav-links a, .nav-links button {
    font-size: .9rem; font-weight: 500; color: var(--muted);
    background: none; border: none; cursor: pointer;
    font-family: var(--sans); transition: color .2s; padding: 0;
    text-decoration: none;
}
.nav-links a:hover, .nav-links button:hover { color: var(--gold); }
.nav-links .current-menu-item > a { color: var(--gold); }
.nav-controls { display: flex; align-items: center; gap: .8rem; }
.nav-btn {
    background: none; border: 1px solid var(--border2); border-radius: 8px;
    color: var(--muted); cursor: pointer; padding: .4rem .8rem;
    font-size: .9rem; font-family: var(--mono); transition: all .2s;
}
.nav-btn:hover { border-color: var(--gold); color: var(--gold); }
#hamburger { display: none; flex-direction: column; gap: 6px; cursor: pointer; padding: 6px; background: none; border: none; }
#hamburger span { display: block; width: 24px; height: 2px; background: var(--muted); border-radius: 2px; transition: all .3s; }

@media (max-width: 900px) {
    .nav-links {
        display: none; flex-direction: column; position: absolute;
        top: 70px; left: 0; right: 0; background: var(--bg);
        padding: 1.5rem 2rem; gap: 1.5rem; border-bottom: 1px solid var(--border2);
    }
    .nav-links.open { display: flex; }
    #hamburger { display: flex; }
}

/* ========== LANG SWITCHER ========== */
.lang-switcher { position: relative; }
.lang-btn {
    background: none; border: 1px solid var(--border2); border-radius: 8px;
    color: var(--muted); cursor: pointer; padding: .4rem .8rem;
    font-size: .85rem; font-family: var(--sans); font-weight: 500;
    transition: all .2s; display: flex; align-items: center; gap: 0.4rem;
}
.lang-btn:hover { border-color: var(--gold); color: var(--gold); }
.lang-arrow { font-size: 0.7rem; transition: transform 0.2s; margin-left: 0.2rem; }
.lang-switcher.open .lang-arrow { transform: rotate(180deg); }
.lang-dropdown {
    position: absolute; top: calc(100% + 10px); right: 0;
    background: var(--bg3); backdrop-filter: blur(16px);
    border: 1px solid var(--border2); border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.4);
    display: flex; flex-direction: column; min-width: 140px;
    opacity: 0; pointer-events: none; transform: translateY(-10px);
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1); z-index: 1000; overflow: hidden;
}
.lang-switcher.open .lang-dropdown { opacity: 1; pointer-events: all; transform: translateY(0); }
.lang-option {
    background: none; border: none; padding: 0.8rem 1.2rem;
    color: var(--muted); cursor: pointer; text-align: left;
    display: flex; align-items: center; gap: 0.8rem;
    font-size: 0.9rem; font-family: var(--sans); font-weight: 500;
    transition: background 0.2s, color 0.2s;
    border-bottom: 1px solid var(--border2);
}
.lang-option:last-child { border-bottom: none; }
.lang-option:hover { background: var(--faint); color: var(--text); }
.lang-option.active { background: var(--gold3); color: var(--gold); border-left: 2px solid var(--gold); padding-left: calc(1.2rem - 2px); }

/* ========== FONT SIZE ========== */
#font-size-ctrl { display: flex; align-items: center; gap: .4rem; }
#font-size-ctrl button {
    background: none; border: 1px solid var(--border2); border-radius: 6px;
    color: var(--muted); cursor: pointer; padding: .35rem .6rem;
    font-size: .9rem; font-family: var(--mono); transition: all .2s; line-height: 1;
}
#font-size-ctrl button:hover { border-color: var(--gold); color: var(--gold); }

/* ========== HERO ========== */
#hero {
    min-height: 100vh;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    text-align: center;
    padding: 9rem 1.5rem 6rem;
    position: relative; overflow: hidden;
}
.hero-bg {
    position: absolute; inset: 0; z-index: 1; pointer-events: none;
    background:
        radial-gradient(ellipse 70% 50% at 50% -10%, rgba(59,111,212,.15) 0%, transparent 65%),
        radial-gradient(ellipse 40% 40% at 80% 80%, rgba(201,168,76,.05) 0%, transparent 60%);
}
.hero-grid-overlay {
    position: absolute; inset: 0; z-index: 1; opacity: .04; pointer-events: none;
    background-image: linear-gradient(var(--border2) 1px, transparent 1px), linear-gradient(90deg, var(--border2) 1px, transparent 1px);
    background-size: 64px 64px;
}
.hero-content { position: relative; z-index: 2; max-width: 1000px; }
.hero-eyebrow {
    font-family: var(--mono); font-size: .85rem; letter-spacing: .25em;
    color: var(--gold); text-transform: uppercase; margin-bottom: 2rem;
    display: flex; align-items: center; justify-content: center; gap: 1rem;
}
.hero-eyebrow::before, .hero-eyebrow::after { content: ''; display: inline-block; width: 40px; height: 1px; background: var(--gold); opacity: .5; }
.hero-title { margin-bottom: 1.8rem; }
.hero-title .line1 { display: block; color: var(--text); }
.hero-title .line2 { display: block; color: var(--gold); font-style: italic; }
.hero-sub { font-size: clamp(1.1rem, 2.2vw, 1.35rem); color: var(--muted); max-width: 720px; margin: 0 auto 1.5rem; line-height: 1.75; }
.hero-quote { font-family: var(--serif); font-style: italic; font-weight: 500; font-size: clamp(1rem, 1.8vw, 1.25rem); color: var(--muted); margin: 0 auto 3rem; opacity: .9; max-width: 600px; }
.hero-buttons { display: flex; align-items: center; justify-content: center; gap: 1.2rem; flex-wrap: wrap; margin-bottom: 5rem; }
.hero-stats { display: flex; align-items: center; justify-content: center; gap: 4rem; flex-wrap: wrap; padding-top: 2.5rem; border-top: 1px solid var(--border2); }
.hero-stat { text-align: center; }
.hero-stat-num { font-family: var(--mono); font-size: 1.8rem; color: var(--gold); font-weight: 700; display: block; }
.hero-stat-lbl { font-size: .8rem; color: var(--muted); text-transform: uppercase; letter-spacing: .1em; margin-top: 0.3rem; }

/* ========== SECTION HEADERS ========== */
.section-header { margin-bottom: 4rem; }
.section-header h2 { margin-bottom: 1rem; }
.section-header p { max-width: 700px; font-size: 1.1rem; }
.section-header.center { text-align: center; }
.section-header.center .divider { margin-left: auto; margin-right: auto; }
.section-header.center p { margin-left: auto; margin-right: auto; }

/* ========== BLOCK ROWS ========== */
.block-row {
    display: grid; grid-template-columns: 1fr 1fr;
    gap: clamp(3rem, 6vw, 6rem);
    align-items: center;
    margin-bottom: clamp(5rem, 10vw, 10rem);
}
.block-row.reverse .block-visual { order: -1; }
@media (max-width: 900px) {
    .block-row { grid-template-columns: 1fr; }
    .block-row.reverse .block-visual { order: 0; }
}
.block-visual { min-height: 320px; border-radius: var(--radius); display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 3rem; }
.block-visual .big-eq { font-family: var(--mono); font-size: clamp(2rem, 5vw, 4rem); color: var(--gold); font-weight: 700; margin-bottom: .8rem; }
.block-visual .eq-label { font-size: .8rem; font-family: var(--mono); color: var(--muted); letter-spacing: .12em; text-transform: uppercase; }

/* ========== AMI BOX ========== */
.ami-box {
    background: #f8fafc; color: #0f172a;
    border: 2px solid #e2e8f0; border-radius: var(--radius);
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    padding: 3.5rem; min-height: 320px; box-shadow: 0 20px 60px rgba(0,0,0,.3);
}
.ami-box .ami-num { font-family: var(--mono); font-size: clamp(3rem, 7vw, 5.5rem); font-weight: 900; color: #0f172a; line-height: 1; }
.ami-box .ami-unit { font-size: clamp(1.8rem, 4vw, 3.5rem); color: #2563eb; }
.ami-box .ami-sub { font-size: .85rem; color: #475569; text-transform: uppercase; letter-spacing: .12em; font-weight: 700; margin-top: .8rem; font-family: var(--mono); }

/* ========== SÍNTESE PAGE ========== */
.sintese-wrap { max-width: 1100px; margin: 0 auto; padding: 4rem clamp(1rem, 4vw, 2rem); }
.sintese-lead {
    font-family: var(--serif); font-size: clamp(1.15rem, 2.5vw, 1.45rem);
    color: var(--text); line-height: 1.85;
    border-left: 4px solid var(--gold); padding: 2rem 2.5rem;
    background: var(--gold3); border-radius: 0 var(--radius) var(--radius) 0; margin-bottom: 3.5rem;
}
.sintese-body h3 { font-size: clamp(1.4rem, 2.5vw, 1.8rem); color: var(--gold2); margin-top: 4rem; margin-bottom: 1.2rem; border-bottom: 1px solid var(--border); padding-bottom: .8rem; }
.sintese-body h4 { color: var(--text); font-size: 1.15rem; margin-top: 2rem; margin-bottom: .8rem; font-family: var(--mono); }
.sintese-body p { font-size: 1.05rem; line-height: 1.95; text-align: justify; color: var(--muted); }
.sintese-body strong { color: var(--text); }
.blockquote-sx {
    border-left: 4px solid var(--gold); padding: 1.8rem 2.5rem;
    background: var(--gold3); border-radius: 0 var(--radius) var(--radius) 0;
    margin: 2.5rem 0; font-family: var(--serif); font-style: italic; font-weight: 500;
    font-size: 1.15rem; color: var(--text); line-height: 1.8;
}
.blockquote-sx footer { font-size: .9rem; font-family: var(--sans); font-style: normal; color: var(--gold); margin-top: 1rem; font-weight: 700; }

/* ========== AXIOM TABLE ========== */
.ax-table { width: 100%; border-collapse: collapse; margin: 2.5rem 0; font-size: .95rem; }
.ax-table thead tr { background: var(--gold3); border-bottom: 2px solid var(--border); }
.ax-table thead th { padding: 1rem 1.2rem; text-align: left; font-family: var(--mono); font-size: .85rem; color: var(--gold); text-transform: uppercase; letter-spacing: .08em; font-weight: 700; }
.ax-table tbody tr { border-bottom: 1px solid var(--border2); transition: background .2s; }
.ax-table tbody tr:hover { background: var(--faint); }
.ax-table tbody td { padding: 1rem 1.2rem; vertical-align: top; color: var(--muted); line-height: 1.7; }
.ax-table tbody td:first-child { font-family: var(--mono); color: var(--gold2); white-space: nowrap; font-weight: 700; }
.ax-table tbody td strong { color: var(--text); }

/* ========== EQ BLOCKS ========== */
.eq-block {
    background: rgba(0,0,0,.4); border: 1px solid var(--border2);
    border-radius: var(--radius); padding: 2rem 2.5rem;
    margin: 2rem 0; overflow-x: auto; text-align: center;
}
html:not(.dark) .eq-block { background: rgba(0,0,0,0.03); }
.eq-block .eq-name { font-family: var(--mono); font-size: .8rem; color: var(--gold); text-transform: uppercase; letter-spacing: .12em; margin-bottom: 1rem; font-weight: 700; }
.eq-block .eq-desc { font-size: .9rem; color: var(--muted); margin-top: 1rem; font-style: italic; font-weight: 500; }

/* ========== PILAR CARDS ========== */
.pilar-card { padding: 2.5rem; border-radius: var(--radius); display: flex; flex-direction: column; transition: transform .3s, box-shadow .3s; }
.pilar-card:hover { transform: translateY(-6px); box-shadow: 0 16px 48px rgba(0,0,0,.4); }
.pilar-icon { font-size: 2.5rem; margin-bottom: 1.2rem; }
.pilar-card h3 { font-size: 1.25rem; color: var(--text); margin-bottom: .8rem; }
.pilar-card p  { font-size: .95rem; color: var(--muted); flex-grow: 1; }
.pilar-card .pilar-link { font-family: var(--mono); font-size: .85rem; color: var(--gold); margin-top: 1.2rem; cursor: pointer; font-weight: 700; transition: color .2s; text-decoration: none; display: inline-block; }
.pilar-card .pilar-link:hover { color: var(--gold2); }

/* ========== KARDASHEV TABLE ========== */
.kard-table { width: 100%; border-collapse: collapse; margin: 2.5rem 0; font-size: .95rem; }
.kard-table thead tr { background: rgba(59,111,212,.12); border-bottom: 2px solid rgba(59,111,212,.3); }
.kard-table thead th { padding: 1rem 1.2rem; text-align: left; font-family: var(--mono); font-size: .85rem; color: #7ca4e8; text-transform: uppercase; letter-spacing: .08em; font-weight: 700; }
.kard-table tbody tr { border-bottom: 1px solid var(--border2); transition: background .2s; }
.kard-table tbody tr:hover { background: var(--faint); }
.kard-table tbody tr.current { background: rgba(201,168,76,.07); border-left: 3px solid var(--gold); }
.kard-table tbody td { padding: 1rem 1.2rem; color: var(--muted); line-height: 1.7; }
.kard-table tbody td:first-child { font-family: var(--mono); font-weight: 700; color: var(--gold2); }
.kard-table tbody td strong { color: var(--text); }

/* ========== MATH PAGE ========== */
.math-card { padding: 2.5rem; border-radius: var(--radius); margin-bottom: 2.5rem; }
.math-card h3 { font-family: var(--mono); font-size: 1.15rem; color: var(--blue); margin-bottom: 1rem; }

/* ========== FÍSICA PAGE ========== */
.fisica-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 2.5rem; margin-top: 3rem; }
@media (max-width: 700px) { .fisica-grid { grid-template-columns: 1fr; } }
.fisica-item { padding: 2rem; border-radius: var(--radius); }
.fisica-item h4 { color: var(--gold2); margin-bottom: 1rem; font-size: 1.1rem; }

/* ========== PROJECT PAGE ========== */
.project-hero {
    background: linear-gradient(135deg, rgba(59,111,212,.1) 0%, rgba(201,168,76,.05) 100%);
    border: 1px solid rgba(59,111,212,.2);
    border-radius: var(--radius); padding: 3.5rem; margin-bottom: 3.5rem;
}
.project-hero h2 { color: #7ca4e8; }
.project-hero .divider { background: #7ca4e8; }

/* ========== EBOOKS PAGE ========== */
.ebook-card { padding: 3rem; border-radius: var(--radius); display: flex; flex-direction: column; }
.ebook-card h3 { color: var(--text); margin-bottom: 1rem; }
.ebook-card .ebook-meta { font-family: var(--mono); font-size: .8rem; color: var(--gold); margin-bottom: 1.2rem; letter-spacing: .08em; text-transform: uppercase; font-weight: 700; }
.ebook-card p { font-size: 1rem; flex-grow: 1; }
.ebook-card .btn { margin-top: 2rem; align-self: flex-start; }

/* ========== BIO PAGE ========== */
.bio-avatar {
    width: 100%; aspect-ratio: 1; border-radius: var(--radius);
    background: linear-gradient(135deg, rgba(201,168,76,.08), rgba(59,111,212,.08));
    border: 1px solid var(--border);
    display: flex; align-items: center; justify-content: center;
    font-size: 8rem; color: var(--muted);
}

/* ========== MAPA SX ========== */
#mapa-sx {
    position: relative; display: flex; flex-direction: column; align-items: center;
    background: radial-gradient(circle at center, var(--bg2) 0%, var(--bg) 70%);
    padding: 5rem 0; margin-bottom: 6rem; border-radius: var(--radius);
    overflow: hidden; border: 1px solid var(--border2);
}
.mapa-bg-lines { position: absolute; top: 0; left: 0; width: 100%; height: 100%; pointer-events: none; z-index: 1; }
.mapa-bg-lines line { stroke: var(--blue); stroke-width: 1.5; stroke-dasharray: 6 6; opacity: 0.35; animation: energy-flow 25s linear infinite; }
@keyframes energy-flow { to { stroke-dashoffset: 1000; } }
.hub {
    position: relative; z-index: 2;
    border: 2px solid var(--blue); background: var(--bg3); backdrop-filter: blur(8px);
    border-radius: 50%; width: 180px; height: 180px;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    text-align: center; box-shadow: 0 0 20px rgba(59,111,212, 0.4);
    animation: pulse-hub 3s infinite;
}
.hub h2 { font-size: 1.15rem; color: var(--text); margin-bottom: 0.3rem; font-family: var(--mono); }
.hub p { font-size: 0.85rem; color: #7ca4e8; margin: 0; font-family: var(--sans); }
.nodes { position: relative; z-index: 2; display: grid; grid-template-columns: repeat(2, 220px); gap: 3rem; margin-top: 4rem; }
@media (max-width: 700px) { .nodes { grid-template-columns: 1fr; gap: 1.5rem; } }
.node {
    background: var(--bg2); display: flex; align-items: center; justify-content: center; gap: 12px;
    text-align: center; padding: 1.2rem;
    border: 1px solid rgba(59,111,212, 0.4); border-radius: 12px;
    text-decoration: none; color: #7ca4e8;
    font-family: var(--mono); font-weight: 700; font-size: 0.95rem; text-transform: uppercase;
    transition: all 0.3s ease;
}
.node svg { width: 22px; height: 22px; fill: currentColor; }
.node:hover { background-color: rgba(59,111,212, 0.15); color: #fff; border-color: var(--blue); box-shadow: 0 0 20px rgba(59,111,212, 0.5); transform: translateY(-4px); }
@keyframes pulse-hub { 0% { box-shadow: 0 0 10px rgba(59,111,212, 0.3); } 50% { box-shadow: 0 0 35px rgba(59,111,212, 0.8); } 100% { box-shadow: 0 0 10px rgba(59,111,212, 0.3); } }

/* ========== ORACLE ========== */
#oracle-toggle {
    position: fixed; bottom: 2rem; right: 2rem; z-index: 900;
    width: 64px; height: 64px; background: var(--blue); border-radius: 50%;
    border: none; cursor: pointer; display: flex; align-items: center; justify-content: center;
    box-shadow: 0 8px 30px rgba(59,111,212,.5); transition: all .25s; font-size: 1.8rem; color: #fff;
}
#oracle-toggle:hover { background: var(--blue2); transform: scale(1.05); }
#oracle-panel {
    position: fixed; bottom: 6rem; right: 2rem; z-index: 900;
    width: clamp(320px, 90vw, 420px); height: 560px; border-radius: 18px;
    background: var(--bg2); border: 1px solid var(--border2);
    box-shadow: 0 20px 60px rgba(0,0,0,.6);
    display: flex; flex-direction: column; overflow: hidden;
    transform: translateY(20px); opacity: 0; pointer-events: none; transition: all .3s ease;
}
#oracle-panel.open { transform: translateY(0); opacity: 1; pointer-events: all; }
.oracle-header { padding: 1.2rem 1.5rem; background: rgba(0,0,0,.2); border-bottom: 1px solid var(--border2); display: flex; align-items: center; justify-content: space-between; }
.oracle-header-info h4 { font-family: var(--mono); font-size: .85rem; color: var(--text); letter-spacing: .1em; margin: 0; }
.oracle-header-info span { font-size: .7rem; color: var(--blue); text-transform: uppercase; letter-spacing: .12em; font-weight: 700; }
.oracle-close { background: none; border: none; color: var(--muted); cursor: pointer; font-size: 1.2rem; transition: color .2s; }
.oracle-close:hover { color: #e55; }
#oracle-msgs { flex-grow: 1; overflow-y: auto; padding: 1.2rem; display: flex; flex-direction: column; gap: 1rem; background: var(--bg); }
.msg { max-width: 85%; padding: .85rem 1.2rem; border-radius: 12px; font-size: .95rem; line-height: 1.6; }
.msg-bot { align-self: flex-start; background: var(--bg2); color: var(--text); border-left: 3px solid var(--blue); }
.msg-user { align-self: flex-end; background: var(--blue); color: #fff; }
.typing span { animation: blink 1s infinite; font-size: 1.5rem; line-height: 10px; }
.typing span:nth-child(2) { animation-delay: .2s; }
.typing span:nth-child(3) { animation-delay: .4s; }
@keyframes blink { 0%, 100% { opacity: .2; } 50% { opacity: 1; } }
.oracle-input-row { padding: 1rem 1.2rem; border-top: 1px solid var(--border2); background: rgba(0,0,0,.1); display: flex; gap: .8rem; }
#oracle-input { flex-grow: 1; background: var(--bg); border: 1px solid var(--border2); border-radius: 8px; padding: .7rem 1rem; color: var(--text); font-family: var(--sans); font-size: .95rem; outline: none; transition: border-color .2s; }
#oracle-input:focus { border-color: var(--blue); }
#oracle-send { background: var(--blue); border: none; border-radius: 8px; color: #fff; padding: .7rem 1.2rem; cursor: pointer; font-size: 1.1rem; transition: background .2s; }
#oracle-send:hover { background: var(--blue2); }

/* ========== FOOTER ========== */
#site-footer { padding: 4rem 0 3rem; border-top: 1px solid var(--border2); text-align: center; }
.footer-logo { font-family: var(--serif); font-size: 1.8rem; color: var(--gold); font-weight: 700; margin-bottom: 1rem; }
.cc-icons { font-size: 1.5rem; margin-bottom: 1rem; opacity: .7; }
#site-footer p { font-size: .9rem; color: var(--muted); line-height: 1.9; }

/* ========== MISC ========== */
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }
.mt-1{margin-top:.5rem}.mt-2{margin-top:1rem}.mt-3{margin-top:1.5rem}.mt-4{margin-top:2rem}.mt-5{margin-top:2.5rem}.mt-6{margin-top:3rem}.mt-8{margin-top:4rem}
.mb-1{margin-bottom:.5rem}.mb-2{margin-bottom:1rem}.mb-4{margin-bottom:2rem}
ul.sx-list { list-style: none; padding-left: 0; }
ul.sx-list li { padding: .6rem 0; padding-left: 1.6rem; position: relative; color: var(--muted); font-size: 1rem; }
ul.sx-list li::before { content: '▸'; position: absolute; left: 0; color: var(--gold); font-size: .9rem; top: .7rem; }
ul.sx-list li strong { color: var(--text); }
.reveal { opacity: 0; transform: translateY(20px); transition: opacity .6s ease, transform .6s ease; }
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ========== WP ALIGNMENT HELPERS ========== */
.alignleft { float: left; margin: 0 1.5rem 1rem 0; }
.alignright { float: right; margin: 0 0 1rem 1.5rem; }
.aligncenter { display: block; margin: 0 auto 1rem; }
.wp-block-image img { max-width: 100%; height: auto; border-radius: var(--radius); }
.entry-content { padding-top: 5rem; }

/* ========== SX PAGE WRAPPER ========== */
.sx-page { padding-top: 70px; min-height: 100vh; }
