:root{
  --bg:#000000;
  --panel:#0f1013;
  --text:#e9eaee;
  --muted:#b5b7bd;
  --red:#ff2a2a;
  --red-dim:#d91f1f;
  --red-neon: rgba(255,42,42,.5);
}

*{box-sizing:border-box}
html,body{
  margin:0;
  background:var(--bg); /* use var so theme can switch */
  color:var(--text);
  font-family: system-ui,-apple-system,Segoe UI,Roboto,Ubuntu,Cantarell,Inter,Arial,sans-serif;
  line-height:1.6;
  transition: background-color .2s ease, color .2s ease;
}
html{scroll-behavior:smooth}

/* Header */
.site-header{position:sticky;top:0;background:rgba(8,8,10,.9);backdrop-filter:saturate(120%) blur(6px); border-bottom:1px solid rgba(255,42,42,.2); z-index:10}
.header-inner{display:flex;align-items:center;gap:1rem; padding: .75rem 1rem; max-width:1200px; margin:0 auto}
.header-logo{width:100%;height:80px;object-fit:contain;display:block}
.brand{display:flex;align-items:center;gap:.75rem;text-decoration:none}
.brand-text{font-weight:800;letter-spacing:.5px;color:var(--text)}

.site-nav{margin-left:auto;display:flex;gap:1rem;align-items:center}
.site-nav a{color:var(--muted);text-decoration:none;padding:.25rem .5rem;border-radius:.5rem}
.site-nav a:hover{color:var(--text);box-shadow:0 0 0 1px rgba(255,42,42,.25),0 0 12px var(--red-neon) inset}
.nav-toggle{display:none;background:transparent;border:1px solid rgba(255,42,42,.35);color:var(--text);border-radius:.5rem;padding:.3rem .6rem}

/* Layout */
.container{max-width:1200px;margin:0 auto;padding:0 1rem}
main#content{padding:2rem 0}
section{margin:3rem 0}
.card{background:var(--panel); border:1px solid rgba(255,42,42,.18); border-radius:14px; padding:1rem; box-shadow: 0 0 0 1px rgba(255,42,42,.08) inset, 0 10px 25px -10px rgba(0,0,0,.6); transition: background-color .2s ease, border-color .2s ease, box-shadow .2s ease}
h1,h2,h3{line-height:1.25;margin:0 0 .6rem}
h1{font-size:clamp(2rem,3.5vw,2.6rem)}
h2{font-size:clamp(1.3rem,2.5vw,1.8rem)}
h3{font-size:clamp(1.1rem,2vw,1.3rem)}

.btn{display:inline-flex;align-items:center;gap:.5rem;padding:.6rem .9rem;border-radius:.8rem;background:linear-gradient(180deg,var(--red),var(--red-dim)); color:#fff; text-decoration:none; box-shadow:0 0 18px rgba(255,42,42,.35), 0 0 0 1px rgba(255,42,42,.4) inset}
.btn:hover{filter:saturate(1.1) brightness(1.05)}

/* Footer */
.site-footer{border-top:1px solid rgba(255,42,42,.2); margin-top:2rem}
.site-footer .container{padding:1.5rem 1rem; color:var(--muted)}

/* Intro overlay */
#intro-screen{position:fixed;inset:0;display:none;align-items:center;justify-content:center;background:#000;z-index:9999;opacity:1;transition:opacity 1.0s ease}
#intro-screen img{max-width:62vw;height:auto}
@media (max-width: 640px){#intro-screen img{max-width:72vw}}
@media (prefers-reduced-motion: reduce){#intro-screen{transition:none}}

/* Responsive nav */
@media (max-width:920px){
  .site-nav{display:none; position:absolute; right:1rem; top:70px; background:rgba(16,16,20,.95); border:1px solid rgba(255,42,42,.25); border-radius:10px; padding:.6rem; flex-direction:column; min-width:200px}
  .site-nav.open{display:flex}
  .nav-toggle{display:inline-block; margin-left:auto}
}

/* Utilities */
.grid{display:grid; gap:1rem}
.two-col{grid-template-columns: 1.2fr .9fr}
@media (max-width: 900px){ .two-col{grid-template-columns: 1fr} }
.media{ aspect-ratio: 16/9; overflow:hidden; border-radius:12px; border: 1px solid rgba(255,42,42,.25)}
.media img{width:100%; height:100%; object-fit:cover; display:block}
hr{border:0;border-top:1px solid rgba(255, 42, 42,.2); margin:2rem 0}
a { color: #ff6666; }
a:hover { color: #ffa3a3; }

/* Header controls */
.controls{display:flex; gap:.5rem; margin-left:.75rem}
.btn-ghost{border:1px solid rgba(255,42,42,.35); background:transparent; color:var(--text);
  border-radius:.5rem; padding:.35rem .6rem; font-size:.9rem; cursor:pointer}
.btn-ghost:hover{box-shadow:0 0 0 1px rgba(255,42,42,.45), 0 0 10px rgba(255,42,42,.25) inset}

/* Contact layout & form */
.contact-grid{display:grid;grid-template-columns: 1.4fr .9fr; gap:1.2rem; align-items:stretch}
@media (max-width: 980px){ .contact-grid{grid-template-columns:1fr} }

.contact-form.card{padding:1.25rem 1.25rem 1.5rem; border-radius:16px}
.contact-form .form-grid{display:grid;grid-template-columns:1fr 1fr;gap:1rem}
.contact-form .form-grid .full{grid-column:1/-1}

.contact-form label{display:block;font-weight:600;color:var(--text)}
.contact-form input,.contact-form textarea, .contact-form select{
  width:100%;
  margin-top:.35rem;
  padding:14px 14px;
  font-size:1rem;
  border-radius:12px;
  border:1px solid rgba(255,42,42,.35);
  background:rgba(255,255,255,0.02);
  color:var(--text);
  outline:none;
  transition: box-shadow .2s ease, border-color .2s ease, background .2s ease;
}
.contact-form textarea{min-height:140px; resize:vertical}
.contact-form input:focus,.contact-form textarea:focus,.contact-form select:focus{
  border-color: var(--red);
  box-shadow: 0 0 0 2px rgba(255,42,42,.18), 0 0 18px rgba(255,42,42,.25);
  background: rgba(255,255,255,0.04);
}
.contact-form .btn.primary{width:100%; justify-content:center; font-weight:700}

@media (max-width:720px){ .header-logo{height:72px} }

/* Bubble grid */
.bubble-grid{display:grid; gap:1rem}
.bubble{
  border:1px solid rgba(255,42,42,.28);
  background: rgba(16,16,20,.85);
  border-radius: 14px;
  padding: .75rem 1rem;
  overflow: hidden;
  transition: box-shadow .2s ease, background .2s ease;
}
.bubble .fact-head{
  all: unset;
  display:flex; align-items:center; gap:.6rem; cursor:pointer; width:100%;
}
.bubble .fact-head h4{ margin:.1rem 0; font-size:1.05rem; color:var(--red); }
.bubble .badge{
  display:inline-block; font-size:.75rem; padding:.15rem .4rem; border:1px solid rgba(255,42,42,.4);
  border-radius:.35rem; color:#ffb3b3; letter-spacing:.3px;
}
.bubble .fact-body{ display:none; margin-top:.5rem; }
.bubble.open .fact-body,
.bubble:focus-within .fact-body,
.bubble:hover .fact-body{ display:block; }
.bubble:hover{
  box-shadow: 0 0 18px rgba(255,42,42,.28), inset 0 0 10px rgba(255,42,42,.18);
  background: rgba(16,16,20,.92);
}
.bubble ul{ margin: .5rem 0 .2rem 1.2rem }
.bubble a{ color:#ff8a8a; text-decoration:none }
.bubble a:hover{ color:#ffbaba; text-decoration:underline }

/* ---------- Light Theme Overrides ---------- */
:root[data-theme='light']{
  --bg:#f7f8fb;
  --panel:#ffffff;
  --text:#14161a;
  --muted:#3c414a;
  --red:#e02222;
  --red-dim:#bb1b1b;
}
:root[data-theme='light'] .site-header{ background: rgba(255,255,255,.85); border-bottom-color: rgba(224,34,34,.2); }
:root[data-theme='light'] .card{ box-shadow: 0 0 0 1px rgba(224,34,34,.08) inset, 0 10px 25px -10px rgba(0,0,0,.08); }
:root[data-theme='light'] .site-nav a:hover{ box-shadow:0 0 0 1px rgba(224,34,34,.25),0 0 12px rgba(224,34,34,.2) inset; }


/* Light theme overrides for bubbles */
:root[data-theme='light'] .bubble{
  background:#ffffff;
  border-color:rgba(224,34,34,.28);
}
:root[data-theme='light'] .bubble .fact-head h4{ color:var(--red); }
:root[data-theme='light'] .bubble .fact-body{ color:#222; }
:root[data-theme='light'] .bubble a{ color:#c00; }
:root[data-theme='light'] .bubble a:hover{ color:#600; }


/* --- Light Theme Contrast Fixes --- */
:root[data-theme='light'] a { color:#b41414; }
:root[data-theme='light'] a:hover { color:#e05252; }

:root[data-theme='light'] .bubble{
  background: rgba(255,255,255,.92);
  border-color: rgba(224,34,34,.25);
}
:root[data-theme='light'] .bubble:hover{
  background: rgba(255,255,255,.98);
  box-shadow: 0 0 18px rgba(224,34,34,.15), inset 0 0 10px rgba(224,34,34,.08);
}
:root[data-theme='light'] .bubble .badge{
  color:#7a1212;
  border-color: rgba(224,34,34,.35);
}
:root[data-theme='light'] .bubble .fact-head h4{
  color:#b41414;
}
:root[data-theme='light'] .bubble a{
  color:#b41414;
}
:root[data-theme='light'] .bubble a:hover{
  color:#e02222;
}

/* Mobile nav panel when open */
@media (max-width:920px){
  :root[data-theme='light'] .site-nav{
    background: rgba(255,255,255,.95);
    border-color: rgba(224,34,34,.25);
  }
}

/* Cards already follow --panel; ensure text uses --text in form elements */
:root[data-theme='light'] .contact-form label,
:root[data-theme='light'] .contact-form input,
:root[data-theme='light'] .contact-form textarea,
:root[data-theme='light'] .contact-form select{
  color: var(--text);
}

