/* ============================================================
   BotNexus — shared styles
   Tokens: dark navy base, indigo/blue accent, condensed display type
   ============================================================ */

:root{
  --bg:            #08090d;
  --bg-alt:        #0c0e14;
  --surface:       #12141c;
  --surface-2:     #171a24;
  --border:        rgba(255,255,255,0.08);
  --border-soft:   rgba(255,255,255,0.05);

  --text:          #f2f3f8;
  --text-muted:    #9aa0b4;
  --text-faint:    #666c80;

  --accent:        #6d5bf9;
  --accent-2:      #4f7dff;
  --accent-grad:   linear-gradient(120deg, #6d5bf9 0%, #4f7dff 100%);
  --accent-soft:   rgba(109,91,249,0.14);
  --accent-line:   rgba(109,91,249,0.35);

  --amber:         #ffb454;
  --green:         #34d399;
  --red:           #f2777a;

  --radius-sm:     10px;
  --radius-md:     16px;
  --radius-lg:     22px;

  --font-display:  "Space Grotesk", "Inter", system-ui, sans-serif;
  --font-body:     "Inter", system-ui, sans-serif;
  --font-mono:     "JetBrains Mono", ui-monospace, monospace;
}

*, *::before, *::after{ box-sizing: border-box; }

html{ scroll-behavior: smooth; }

body{
  margin:0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* subtle ambient backdrop */
body::before{
  content:"";
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(700px 420px at 12% -5%, rgba(109,91,249,0.16), transparent 60%),
    radial-gradient(600px 500px at 92% 8%, rgba(79,125,255,0.10), transparent 60%),
    var(--bg);
}
body::after{
  content:"";
  position: fixed;
  inset:0;
  z-index:-1;
  background-image:
    linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(900px 600px at 50% 0%, black, transparent 75%);
}

a{ color: inherit; text-decoration: none; }
img{ max-width: 100%; display:block; }
ul{ margin:0; padding:0; }

.wrap{
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 28px;
}

/* ---------- eyebrow / pill badge ---------- */
.pill{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding: 7px 16px;
  border-radius: 999px;
  background: var(--accent-soft);
  border: 1px solid var(--accent-line);
  color: #b7aeff;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

/* ---------- buttons ---------- */
.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap: 8px;
  padding: 13px 22px;
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 15px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease, border-color .15s ease;
  white-space: nowrap;
}
.btn-primary{
  background: var(--accent-grad);
  color: #fff;
  box-shadow: 0 8px 24px -8px rgba(109,91,249,0.6);
}
.btn-primary:hover{ transform: translateY(-1px); box-shadow: 0 12px 28px -8px rgba(109,91,249,0.75); }

.btn-ghost{
  background: var(--surface-2);
  color: var(--text);
  border-color: var(--border);
}
.btn-ghost:hover{ border-color: rgba(255,255,255,0.2); background:#1c1f2b; }

.btn-sm{ padding: 9px 16px; font-size: 13px; }

/* ============================================================
   NAV
   ============================================================ */
.nav{
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(14px);
  background: rgba(8,9,13,0.72);
  border-bottom: 1px solid var(--border-soft);
}
.nav-inner{
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding: 14px 28px;
  max-width: 1120px;
  margin: 0 auto;
}
.brand{
  display:flex;
  align-items:center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 18px;
  letter-spacing: -0.01em;
}
.brand img{
  width: 34px;
  height: 34px;
  border-radius: 9px;
  background: #fff;
  padding: 3px;
}
.brand .bn-b{ color: var(--text); }
.brand .bn-nexus{ color: #8ea1ff; }

.nav-links{
  display:flex;
  align-items:center;
  gap: 28px;
  font-size: 14.5px;
  font-weight: 500;
  color: var(--text-muted);
}
.nav-links a:hover{ color: var(--text); }
.nav-cta{ display:flex; align-items:center; gap:12px; }

.nav-toggle{ display:none; }

@media (max-width: 780px){
  .nav-links{ display:none; }
}

/* ============================================================
   HERO
   ============================================================ */
.hero{
  padding: 84px 0 56px;
}
.hero-inner{
  max-width: 760px;
}
.hero h1{
  font-family: var(--font-display);
  font-size: clamp(38px, 6vw, 58px);
  line-height: 1.06;
  letter-spacing: -0.02em;
  margin: 22px 0 20px;
  font-weight: 700;
}
.hero h1 .accent-text{
  background: var(--accent-grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero p.lead{
  color: var(--text-muted);
  font-size: 17.5px;
  max-width: 560px;
  margin: 0 0 32px;
}
.hero-ctas{
  display:flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 40px;
}

/* stat row */
.stat-row{
  display:flex;
  gap: 0;
  flex-wrap: wrap;
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: var(--radius-md);
  overflow: hidden;
  margin-bottom: 28px;
}
.stat{
  flex: 1 1 140px;
  padding: 20px 24px;
  border-right: 1px solid var(--border);
}
.stat:last-child{ border-right: none; }
.stat .num{
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 700;
  color: var(--text);
  display:flex;
  align-items:baseline;
  gap: 6px;
}
.stat .num .dot{ width:8px; height:8px; border-radius:50%; background: var(--green); box-shadow: 0 0 10px var(--green); }
.stat .label{
  color: var(--text-faint);
  font-size: 13px;
  margin-top: 4px;
}

/* help card, styled after reference dashboard */
.help-card{
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: var(--radius-md);
  padding: 24px 26px;
}
.help-card h3{
  font-family: var(--font-display);
  font-size: 18px;
  margin: 0 0 8px;
}
.help-card p{
  color: var(--text-muted);
  font-size: 14.5px;
  margin: 0;
}
.help-card a.inline-link{
  color: #9cb0ff;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.help-card .fine{
  display:block;
  margin-top: 14px;
  color: var(--text-faint);
  font-size: 12.5px;
}

/* ============================================================
   SECTION HEADER
   ============================================================ */
.section{ padding: 76px 0; }
.section-head{
  max-width: 620px;
  margin: 0 0 44px;
}
.section-head .pill{ margin-bottom: 18px; }
.section-head h2{
  font-family: var(--font-display);
  font-size: clamp(28px, 4vw, 36px);
  letter-spacing: -0.01em;
  margin: 0 0 12px;
  font-weight: 700;
}
.section-head p{
  color: var(--text-muted);
  font-size: 16px;
  margin: 0;
}

/* ============================================================
   MODULE GRID
   ============================================================ */
.module-grid{
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
@media (max-width: 900px){ .module-grid{ grid-template-columns: repeat(2,1fr); } }
@media (max-width: 620px){ .module-grid{ grid-template-columns: 1fr; } }

.module-card{
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 22px;
  transition: border-color .15s ease, transform .15s ease, background .15s ease;
}
.module-card:hover{
  border-color: var(--accent-line);
  background: var(--surface-2);
  transform: translateY(-2px);
}
.module-icon{
  width: 42px;
  height: 42px;
  border-radius: 11px;
  background: var(--accent-soft);
  border: 1px solid var(--accent-line);
  display:flex;
  align-items:center;
  justify-content:center;
  font-size: 20px;
  margin-bottom: 14px;
}
.module-card h3{
  font-family: var(--font-display);
  font-size: 16.5px;
  margin: 0 0 6px;
  font-weight: 600;
}
.module-card p{
  color: var(--text-muted);
  font-size: 13.8px;
  margin: 0;
  line-height: 1.55;
}

/* ============================================================
   COMMAND CONSOLE
   ============================================================ */
.console{
  background: #0b0c11;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
}
.console-bar{
  display:flex;
  align-items:center;
  gap: 8px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-soft);
  background: var(--surface);
}
.console-bar span{
  width: 10px; height:10px; border-radius:50%;
  background: #3a3d4a;
}
.console-bar span:nth-child(1){ background:#f2777a44; }
.console-bar span:nth-child(2){ background:#ffb45444; }
.console-bar span:nth-child(3){ background:#34d39944; }
.console-title{
  margin-left: 8px;
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: var(--text-faint);
}
.console-body{
  padding: 22px 24px 26px;
  font-family: var(--font-mono);
  font-size: 14px;
  line-height: 2;
}
.console-body .cmd{ color: #8ea1ff; }
.console-body .arg{ color: var(--amber); }
.console-body .cmt{ color: var(--text-faint); margin-left: 10px; }

/* ============================================================
   CREDIT / STUDIO BANNER
   ============================================================ */
.credit-banner{
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--border);
}
.credit-banner img{ width:100%; height:auto; display:block; }

/* ============================================================
   FOOTER
   ============================================================ */
.footer-banner{
  width:100%;
  border-top: 1px solid var(--border-soft);
}
.footer-banner img{
  width: 100%;
  height: 56px;
  object-fit: cover;
  display:block;
}
footer.site-footer{
  background: var(--bg-alt);
  padding: 52px 0 28px;
}
.footer-grid{
  display:grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 32px;
  padding-bottom: 36px;
  border-bottom: 1px solid var(--border-soft);
}
@media (max-width: 780px){
  .footer-grid{ grid-template-columns: 1fr 1fr; }
}
.footer-brand .brand{ margin-bottom: 12px; }
.footer-brand p{
  color: var(--text-muted);
  font-size: 13.5px;
  max-width: 260px;
}
.footer-col h4{
  font-family: var(--font-display);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-faint);
  margin: 0 0 14px;
}
.footer-col ul{ list-style:none; display:flex; flex-direction:column; gap:10px; }
.footer-col a{
  color: var(--text-muted);
  font-size: 14px;
}
.footer-col a:hover{ color: var(--text); }
.footer-bottom{
  display:flex;
  align-items:center;
  justify-content:space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 24px;
  color: var(--text-faint);
  font-size: 13px;
}

/* ============================================================
   LEGAL PAGES (Terms / Privacy)
   ============================================================ */
.legal-hero{
  padding: 64px 0 32px;
  border-bottom: 1px solid var(--border-soft);
}
.legal-hero h1{
  font-family: var(--font-display);
  font-size: clamp(32px, 5vw, 44px);
  margin: 18px 0 10px;
  letter-spacing: -0.01em;
}
.legal-hero .updated{
  color: var(--text-faint);
  font-size: 14px;
}
.legal-body{
  padding: 52px 0 88px;
  display:grid;
  grid-template-columns: 240px 1fr;
  gap: 48px;
  align-items: start;
}
@media (max-width: 860px){
  .legal-body{ grid-template-columns: 1fr; }
  .legal-toc{ display:none; }
}
.legal-toc{
  position: sticky;
  top: 96px;
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: var(--radius-md);
  padding: 18px;
}
.legal-toc h4{
  font-family: var(--font-display);
  font-size: 12.5px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-faint);
  margin: 0 0 12px;
}
.legal-toc ul{ list-style:none; display:flex; flex-direction:column; gap:9px; }
.legal-toc a{
  font-size: 13.6px;
  color: var(--text-muted);
  display:block;
}
.legal-toc a:hover{ color: #b7aeff; }

.legal-content{
  max-width: 720px;
}
.legal-content section{
  margin-bottom: 40px;
  scroll-margin-top: 96px;
}
.legal-content h2{
  font-family: var(--font-display);
  font-size: 21px;
  margin: 0 0 14px;
  display:flex;
  align-items:center;
  gap: 10px;
}
.legal-content h2 .num{
  color: #8ea1ff;
  font-family: var(--font-mono);
  font-size: 15px;
  font-weight: 400;
}
.legal-content p{
  color: var(--text-muted);
  font-size: 15px;
  margin: 0 0 14px;
}
.legal-content ul{
  list-style: none;
  display:flex;
  flex-direction: column;
  gap: 8px;
  margin: 0 0 14px;
  padding: 0;
}
.legal-content ul li{
  color: var(--text-muted);
  font-size: 15px;
  padding-left: 20px;
  position: relative;
}
.legal-content ul li::before{
  content:"";
  position:absolute;
  left:0; top: 9px;
  width:6px; height:6px;
  border-radius:50%;
  background: var(--accent-2);
}
.legal-content code, .legal-content pre{
  font-family: var(--font-mono);
  background: #0b0c11;
  border: 1px solid var(--border);
  border-radius: 8px;
  color: #8ea1ff;
}
.legal-content code{ padding: 2px 7px; font-size: 13.5px; }
.legal-content pre{
  padding: 14px 16px;
  margin: 0 0 14px;
  overflow-x: auto;
  font-size: 13.5px;
}
.legal-content blockquote{
  margin: 0 0 14px;
  padding: 14px 18px;
  border-left: 3px solid var(--accent);
  background: var(--accent-soft);
  border-radius: 0 10px 10px 0;
  color: #dcd9ff;
  font-size: 14.5px;
  font-style: italic;
}
.legal-content a{
  color: #9cb0ff;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.legal-content strong{ color: var(--text); }
