:root{color-scheme:light}body{margin:0;padding:0;font:14px -apple-system,BlinkMacSystemFont,sans-serif;background:#faf9f5;color:#141413}img{max-width:100%}[hidden]:not([hidden=until-found i]){display:none!important}

  @import url('https://fonts.googleapis.com/css2?family=Rajdhani:wght@500;600;700&family=Manrope:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500;600&display=swap');

  :root{
    --bg:#eef1f5; --surface:#ffffff; --surface-2:#f4f6f9; --surface-3:#eaeef3;
    --border:#dbe0e8; --border-strong:#c4cbd6; --text:#171b22; --muted:#5a6270; --muted-2:#838ba0;
    --accent:#0074F6; --accent-ink:#ffffff; --accent-soft:#e3efff;
    --link:#00265B; --link-soft:#e1e8f5; --node:#00265B; --node-soft:#dfe6f3; --ok:#1f8f5a; --err:#d1394a;
    --shadow: 0 1px 2px rgba(20,23,28,.05), 0 10px 24px -14px rgba(20,23,28,.14);
    --grid-line: rgba(20,25,35,.05);
    color-scheme: light;
  }
  :root[data-theme="dark"]{ color-scheme: dark; }
  @media (prefers-color-scheme: dark){ :root:not([data-theme="light"]){ color-scheme: dark; } }
  @media (prefers-color-scheme: dark){
    :root:not([data-theme="light"]){
      --bg:#242424; --surface:#333333; --surface-2:#3a3a3a; --surface-3:#2c2c2c;
      --border:#474747; --border-strong:#5c5c5c; --text:#f8f8f6; --muted:#b8b8b3; --muted-2:#8c8c86;
      --accent:#3B93FF; --accent-ink:#00132e; --accent-soft:#10315c;
      --link:#7FB6FF; --link-soft:#1b2b45; --node:#7FA8E8; --node-soft:#1b2b45; --ok:#3ecf8e; --err:#ff6b7a;
      --shadow: 0 1px 2px rgba(0,0,0,.35), 0 14px 30px -16px rgba(0,0,0,.6);
      --grid-line: rgba(255,255,255,.05);
    }
  }
  :root[data-theme="dark"]{
    --bg:#242424; --surface:#333333; --surface-2:#3a3a3a; --surface-3:#2c2c2c;
    --border:#474747; --border-strong:#5c5c5c; --text:#f8f8f6; --muted:#b8b8b3; --muted-2:#8c8c86;
    --accent:#3B93FF; --accent-ink:#00132e; --accent-soft:#10315c;
    --link:#7FB6FF; --link-soft:#1b2b45; --node:#7FA8E8; --node-soft:#1b2b45; --ok:#3ecf8e; --err:#ff6b7a;
    --shadow: 0 1px 2px rgba(0,0,0,.35), 0 14px 30px -16px rgba(0,0,0,.6);
    --grid-line: rgba(255,255,255,.05);
  }

  *{ box-sizing:border-box; }
  body{ background:var(--bg); color:var(--text); font-family:'Manrope', ui-sans-serif, system-ui, sans-serif; -webkit-font-smoothing:antialiased; }
  h1,h2,h3{ font-family:'Rajdhani','Manrope',sans-serif; font-weight:700; letter-spacing:.005em; text-wrap:balance; margin:0; }
  .mono{ font-family:'JetBrains Mono', ui-monospace, monospace; }
  a{ color:inherit; text-decoration:none; }
  button{ font:inherit; }
  .wrap{ max-width:1280px; margin:0 auto; padding:0 22px; }

  .route-strip{ height:5px; position:relative; overflow:hidden; background:repeating-linear-gradient(90deg, var(--accent) 0 10px, transparent 10px 18px); }
  .route-strip .runner{ position:absolute; top:0; left:-6%; width:6%; height:100%; background:linear-gradient(90deg, transparent, rgba(255,255,255,.9), transparent); animation: run 5.5s linear infinite; }
  @media (prefers-reduced-motion: reduce){ .route-strip .runner{ animation:none; display:none; } }
  @keyframes run{ to{ left:106%; } }

  header.site{ background:var(--surface); border-bottom:1px solid var(--border); }
  .topbar{ display:flex; align-items:center; justify-content:space-between; padding:8px 0; font-size:.76rem; color:var(--muted-2); border-bottom:1px solid var(--border); }
  .topbar .ticker{ display:flex; gap:16px; align-items:center; }
  .topbar .ticker b{ color:var(--accent); font-weight:700; }
  .topbar .right-links{ display:flex; gap:14px; align-items:center; }
  .topbar .right-links a:hover{ color:var(--accent); }
  .topbar-divider{ width:1px; height:12px; background:var(--border-strong); }
  .auth-link{ font-weight:700; color:var(--text); }
  .auth-link.accent{ color:var(--accent); }
  .theme-toggle{ display:inline-flex; align-items:center; justify-content:center; width:25px; height:25px; border-radius:6px; border:1px solid var(--border); background:var(--surface-2); cursor:pointer; color:var(--muted); }
  .theme-toggle:hover{ color:var(--accent); border-color:var(--accent); }
  .theme-toggle svg{ width:13px; height:13px; }

  .mainbar{ display:flex; align-items:center; gap:26px; padding:15px 0; }
  .logo{ display:flex; align-items:center; gap:10px; flex-shrink:0; }
  .logo-badge{ width:42px; height:42px; border-radius:8px; background:linear-gradient(160deg, var(--accent), #00265B); color:#fff; display:flex; align-items:center; justify-content:center; font-family:'Rajdhani',sans-serif; font-weight:700; font-size:1rem; box-shadow:var(--shadow); position:relative; }
  .logo-badge:after{ content:""; position:absolute; inset:-3px; border:1px solid var(--border-strong); border-radius:11px; opacity:.5; }
  .logo-text{ line-height:1.05; }
  .logo-text .name{ font-family:'Rajdhani',sans-serif; font-weight:700; font-size:1.28rem; }
  .logo-text .tag{ font-size:.66rem; color:var(--muted); letter-spacing:.09em; text-transform:uppercase; }
  .search{ flex:1; max-width:420px; display:flex; align-items:center; gap:8px; background:var(--surface-2); border:1px solid var(--border); border-radius:8px; padding:9px 14px; color:var(--muted); font-size:.85rem; }
  .search svg{ flex-shrink:0; opacity:.6; }
  .mainbar-actions{ display:flex; align-items:center; gap:9px; margin-left:auto; }
  .btn{ display:inline-flex; align-items:center; gap:7px; padding:9px 16px; border-radius:7px; font-weight:700; font-size:.83rem; border:1px solid transparent; cursor:pointer; font-family:'Rajdhani',sans-serif; letter-spacing:.02em; }
  .btn-accent{ background:var(--accent); color:var(--accent-ink); }
  .btn-ghost{ background:transparent; border-color:var(--border-strong); color:var(--text); }
  .btn-block{ width:100%; justify-content:center; }
  .avatar{ width:36px; height:36px; border-radius:7px; background:var(--node-soft); color:var(--node); display:flex; align-items:center; justify-content:center; font-weight:700; font-family:'Rajdhani',sans-serif; border:1px solid var(--border); }

  nav.crumbs{ display:flex; gap:1px; padding:0 0 13px; font-family:'Rajdhani',sans-serif; font-weight:600; font-size:.91rem; }
  nav.crumbs a{ padding:7px 13px; border-radius:6px; color:var(--muted); }
  nav.crumbs a.active{ background:var(--accent-soft); color:var(--accent); }
  nav.crumbs a:hover{ color:var(--text); }
  nav.crumbs a.crumb-highlight{ margin-left:auto; display:inline-flex; align-items:center; gap:6px; background:var(--node-soft); color:var(--node); font-weight:700; }
  nav.crumbs a.crumb-highlight:hover{ background:var(--node); color:#fff; }

  .breadcrumb{ display:flex; align-items:center; gap:6px; margin:16px 0 14px; font-size:.78rem; color:var(--muted-2); flex-wrap:wrap; }
  .breadcrumb a:hover{ color:var(--accent); }
  .breadcrumb .sep{ opacity:.6; }
  .breadcrumb .here{ color:var(--text); font-weight:700; }

  .foot-grid{ display:grid; grid-template-columns:1.4fr 1fr 1fr 1fr; gap:24px; margin-bottom:20px; }
  .foot-col h4{ font-family:'Rajdhani',sans-serif; font-size:.8rem; text-transform:uppercase; letter-spacing:.06em; color:var(--muted); margin-bottom:9px; }
  .foot-col a{ display:block; padding:3px 0; }
  .foot-col a:hover{ color:var(--accent); }
  footer{ margin-top:44px; border-top:1px solid var(--border); padding:28px 0 24px; color:var(--muted-2); font-size:.79rem; }
  .foot-bottom{ display:flex; justify-content:space-between; border-top:1px solid var(--border); padding-top:15px; font-size:.73rem; flex-wrap:wrap; gap:6px; }

  /* ---- forms ---- */
  .form-group{ margin-bottom:16px; }
  .form-row{ display:grid; grid-template-columns:1fr 1fr; gap:14px; }
  .form-label{ display:block; font-family:'Rajdhani',sans-serif; font-weight:700; font-size:.82rem; margin-bottom:6px; }
  .form-input{ width:100%; font:inherit; font-size:.86rem; color:var(--text); background:var(--surface-2); border:1px solid var(--border-strong); border-radius:7px; padding:10px 13px; outline:none; transition:border-color .15s ease; }
  .form-input:focus{ border-color:var(--accent); }
  .form-check{ display:flex; align-items:flex-start; gap:9px; font-size:.81rem; color:var(--muted); line-height:1.4; }
  .form-check input{ margin-top:3px; flex-shrink:0; accent-color:var(--accent); }
  .form-check a{ color:var(--link); font-weight:700; }

  /* ---- auth pages (split-screen, livened up) ---- */
  .auth-shell{ margin:32px auto 60px; max-width:920px; display:grid; grid-template-columns:1fr 1fr; border-radius:14px; overflow:hidden; border:1px solid var(--border); box-shadow:var(--shadow); background:var(--surface); }
  .auth-visual{ position:relative; overflow:hidden; padding:36px 32px; display:flex; flex-direction:column; justify-content:space-between; color:#fff; background:linear-gradient(155deg, var(--accent), #00265B); }
  .auth-visual:before{ content:""; position:absolute; inset:0; background-image:linear-gradient(rgba(255,255,255,.08) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.08) 1px, transparent 1px); background-size:22px 22px; }
  .auth-visual-badge{ position:relative; z-index:1; display:inline-flex; align-items:center; gap:8px; font-family:'Rajdhani',sans-serif; font-weight:700; font-size:.72rem; text-transform:uppercase; letter-spacing:.08em; background:rgba(255,255,255,.16); border:1px solid rgba(255,255,255,.3); border-radius:20px; padding:6px 13px; width:fit-content; }
  .auth-visual h2{ position:relative; z-index:1; font-size:1.55rem; line-height:1.25; margin:20px 0 10px; }
  .auth-visual p{ position:relative; z-index:1; font-size:.85rem; opacity:.92; line-height:1.55; max-width:32ch; }
  .auth-visual-quote{ position:relative; z-index:1; margin-top:22px; padding:14px 16px; border-radius:10px; background:rgba(255,255,255,.14); border:1px solid rgba(255,255,255,.25); font-size:.8rem; line-height:1.5; }
  .auth-visual-quote b{ display:block; margin-top:8px; font-family:'Rajdhani',sans-serif; font-weight:700; font-size:.74rem; opacity:.9; }
  .auth-visual-stats{ position:relative; z-index:1; display:flex; gap:20px; margin-top:20px; }
  .avs b{ display:block; font-family:'JetBrains Mono',monospace; font-size:1.2rem; }
  .avs span{ font-size:.6rem; text-transform:uppercase; letter-spacing:.05em; opacity:.85; }
  .auth-visual-orbit{ position:absolute; right:-46px; bottom:-46px; width:190px; height:190px; border-radius:50%; border:1.5px dashed rgba(255,255,255,.3); z-index:0; }
  .auth-visual-orbit:before{ content:""; position:absolute; inset:22px; border-radius:50%; border:1.5px dashed rgba(255,255,255,.2); }
  .auth-visual-dot{ position:absolute; width:7px; height:7px; border-radius:50%; background:#fff; z-index:1; box-shadow:0 0 0 4px rgba(255,255,255,.2); }
  .auth-panel{ padding:36px 34px 32px; }
  .auth-head{ text-align:left; margin-bottom:20px; }
  .auth-head .logo-badge{ margin:0 0 12px; }
  .auth-head h1{ font-size:1.4rem; margin-bottom:5px; }
  .auth-head p{ font-size:.83rem; color:var(--muted); }
  .auth-divider{ display:flex; align-items:center; gap:12px; margin:20px 0; color:var(--muted-2); font-size:.72rem; font-weight:700; text-transform:uppercase; letter-spacing:.05em; }
  .auth-divider:before, .auth-divider:after{ content:""; flex:1; height:1px; background:var(--border); }
  .social-row{ display:flex; flex-direction:column; gap:9px; }
  .social-btn{ display:flex; align-items:center; justify-content:center; gap:9px; padding:10px 14px; border-radius:7px; border:1px solid var(--border-strong); background:var(--surface-2); font-weight:700; font-size:.83rem; cursor:pointer; color:var(--text); }
  .social-btn:hover{ border-color:var(--accent); color:var(--accent); }
  .auth-foot{ text-align:center; margin-top:20px; font-size:.83rem; color:var(--muted); }
  .auth-foot a{ font-weight:700; color:var(--link); }
  .auth-forgot{ text-align:right; margin-top:-8px; margin-bottom:16px; }
  .auth-forgot a{ font-size:.76rem; color:var(--link); font-weight:600; }
  @media (max-width:860px){ .auth-shell{ grid-template-columns:1fr; max-width:460px; } .auth-visual{ display:none; } }

  html, body{ max-width:100%; overflow-x:hidden; }
  .hamburger{ display:none; align-items:center; justify-content:center; width:36px; height:36px; border-radius:7px; border:1px solid var(--border-strong); background:var(--surface-2); color:var(--text); cursor:pointer; flex-shrink:0; }
  .hamburger:hover{ border-color:var(--accent); color:var(--accent); }
  .hamburger svg{ width:18px; height:18px; }
  .mobile-drawer-overlay{ position:fixed; inset:0; background:rgba(10,12,16,.5); z-index:60; opacity:0; pointer-events:none; transition:opacity .18s ease; }
  .mobile-drawer-overlay.open{ opacity:1; pointer-events:auto; }
  .mobile-drawer{ position:fixed; top:0; right:0; bottom:0; width:82%; max-width:320px; background:var(--surface); z-index:61; box-shadow:-8px 0 24px rgba(0,0,0,.2); transform:translateX(100%); transition:transform .2s ease; display:flex; flex-direction:column; overflow-y:auto; }
  .mobile-drawer.open{ transform:translateX(0); }
  .mobile-drawer-head{ display:flex; align-items:center; justify-content:space-between; padding:14px 16px; border-bottom:1px solid var(--border); }
  .mobile-drawer-head .logo-text .name{ font-family:'Rajdhani',sans-serif; font-weight:700; font-size:1.05rem; }
  .mobile-drawer-close{ display:flex; align-items:center; justify-content:center; width:32px; height:32px; border-radius:7px; border:1px solid var(--border-strong); background:var(--surface-2); color:var(--text); cursor:pointer; }
  .mobile-drawer-close:hover{ color:var(--accent); border-color:var(--accent); }
  .mobile-drawer-search{ margin:14px 16px 4px; display:flex; align-items:center; gap:8px; background:var(--surface-2); border:1px solid var(--border); border-radius:8px; padding:9px 12px; color:var(--muted); font-size:.85rem; }
  .mobile-drawer-search svg{ flex-shrink:0; opacity:.6; }
  .mobile-drawer-nav{ display:flex; flex-direction:column; padding:10px 8px; font-family:'Rajdhani',sans-serif; font-weight:600; font-size:.98rem; }
  .mobile-drawer-nav a{ padding:11px 12px; border-radius:7px; color:var(--text); }
  .mobile-drawer-nav a.active{ background:var(--accent-soft); color:var(--accent); }
  .mobile-drawer-actions{ display:flex; flex-direction:column; gap:9px; padding:14px 16px; border-top:1px solid var(--border); margin-top:auto; }
  .mobile-drawer-actions .btn{ width:100%; justify-content:center; }
  .mobile-drawer-auth{ display:flex; gap:14px; padding:0 16px 16px; font-size:.82rem; }
  .mobile-drawer-auth a{ font-weight:700; }
  .mobile-drawer-auth a.accent{ color:var(--accent); }
  body.drawer-open{ overflow:hidden; }

  @media (max-width:900px){
    .hamburger{ display:inline-flex; }
    nav.crumbs{ display:none; }
  }
  @media (max-width:680px){
    .topbar .ticker{ display:none; }
    .topbar .right-links a:not(.auth-link){ display:none; }
    .topbar .right-links{ gap:10px; }
    .mainbar{ flex-wrap:wrap; gap:10px 12px; }
    .search{ order:3; flex:1 1 100%; max-width:100%; }
    .mainbar-actions{ margin-left:0; }
  }
