html[data-theme="light"]{
  --bg:#f6f6f3;
  --surface:#ffffff;
  --surface2:#eeeeea;
  --surface3:#e4e4df;
  --border:#d7d7d0;
  --border2:#b9b9af;
  --text:#171717;
  --accent:#111111;
  --accent-dim:#2a2a2a;
  --bright:#111111;
  --muted:#6f6f68;
  --muted2:#3f3f3a;
  --glow:none;
  --glow-sm:none;
}

html:not([data-theme="light"]){
  --muted:#249044;
  --muted2:#42c85e;
}

html[data-theme="light"] body{
  background:var(--bg);
}

html[data-theme="light"] body::after{
  background:repeating-linear-gradient(0deg,transparent,transparent 2px,rgba(0,0,0,.025) 2px,rgba(0,0,0,.025) 4px);
}

html[data-theme="light"] body::before{
  background:radial-gradient(ellipse at 50% 50%,transparent 68%,rgba(0,0,0,.08) 100%);
}

html[data-theme="light"] #matrix-rain{
  opacity:.16;
}

#matrix-rain{
  position:fixed;
  inset:0;
  width:100%;
  height:100%;
  z-index:0;
  opacity:.22;
  pointer-events:none;
}

html[data-theme="light"] nav,
html[data-theme="light"] .topbar{
  background:rgba(246,246,243,.94);
  border-bottom-color:var(--border);
}

html[data-theme="light"] .auth-card,
html[data-theme="light"] .terminal,
html[data-theme="light"] .mockup,
html[data-theme="light"] #tweaks-panel{
  box-shadow:0 18px 60px rgba(0,0,0,.12);
}

html[data-theme="light"] .btn-primary,
html[data-theme="light"] .btn-submit,
html[data-theme="light"] .billing-option.active,
html[data-theme="light"] .tog.on,
html[data-theme="light"] .best-badge{
  background:#111111;
  color:#ffffff;
}

html[data-theme="light"] .btn-primary:hover,
html[data-theme="light"] .btn-submit:hover{
  background:#2a2a2a;
  box-shadow:none;
}

html[data-theme="light"] .tog.on .save-pill{
  color:#ffffff;
  border-color:rgba(255,255,255,.55);
  background:rgba(255,255,255,.14);
}

html[data-theme="light"] .btn-ghost:hover,
html[data-theme="light"] .btn-outline:hover,
html[data-theme="light"] .btn-outline-accent:hover,
html[data-theme="light"] .auth-footer a:hover,
html[data-theme="light"] .nav-links a:hover,
html[data-theme="light"] .nav-tab.active,
html[data-theme="light"] .nav-tab:hover{
  color:#000000;
  text-shadow:none;
}

html[data-theme="light"] .status-active,
html[data-theme="light"] .alert-success,
html[data-theme="light"] .msg.success,
html[data-theme="light"] .ref-reward-box{
  background:#f1f1ed;
  border-color:var(--border2);
}

.theme-switcher{
  position:relative;
  z-index:300;
  display:inline-flex;
  align-items:center;
  gap:3px;
  background:var(--surface2);
  border:1px solid var(--border2);
  border-radius:var(--radius, 8px);
  padding:3px;
  font-family:var(--font, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif);
}

.brand-lockup{
  display:inline-flex;
  align-items:center;
  gap:9px;
}

.brand-mark{
  display:inline-block;
  width:24px;
  height:24px;
  flex:0 0 24px;
  color:var(--bright, var(--accent));
  filter:drop-shadow(0 0 5px rgba(0,255,65,.32));
}

.brand-mark svg{
  display:block;
  width:100%;
  height:100%;
}

html[data-theme="light"] .brand-mark{
  filter:none;
}

.brand-mark.auth-mark{
  width:42px;
  height:42px;
  margin:0 auto 12px;
}

.brand-mark.foot-mark{
  width:20px;
  height:20px;
}


.theme-switcher.theme-floating{
  position:fixed;
  top:14px;
  right:14px;
}

.links .theme-switcher{
  align-self:center;
  flex:0 0 auto;
  font-size:15px;
  letter-spacing:0;
  text-transform:none;
}

.mobile-menu-panel{
  display:contents;
}

.nav-menu-toggle{
  display:none;
  align-items:center;
  justify-content:center;
  width:40px;
  height:40px;
  flex:0 0 40px;
  margin-left:auto;
  border:1px solid var(--border2);
  border-radius:var(--radius, 2px);
  background:var(--surface2);
  color:var(--bright, var(--accent));
  cursor:pointer;
}

.nav-menu-toggle span,
.nav-menu-toggle::before,
.nav-menu-toggle::after{
  content:"";
  display:block;
  width:18px;
  height:2px;
  background:currentColor;
  box-shadow:var(--glow-sm, none);
  transition:transform .16s, opacity .16s;
}

.nav-menu-toggle{
  flex-direction:column;
  gap:4px;
}

nav.nav-menu-open > .nav-menu-toggle span{
  opacity:0;
}

nav.nav-menu-open > .nav-menu-toggle::before{
  transform:translateY(6px) rotate(45deg);
}

nav.nav-menu-open > .nav-menu-toggle::after{
  transform:translateY(-6px) rotate(-45deg);
}

@media(max-width:1024px){
  nav.has-mobile-menu{
    overflow:visible;
    flex-direction:row;
    align-items:center;
    justify-content:space-between;
    gap:0;
  }

  nav.has-mobile-menu > .nav-menu-toggle{
    display:inline-flex;
  }

  nav.has-mobile-menu > .mobile-menu-panel{
    display:none;
  }

  nav.has-mobile-menu.nav-menu-open > .mobile-menu-panel{
    position:absolute;
    top:100%;
    left:0;
    right:0;
    z-index:260;
    display:flex;
    flex-direction:column;
    gap:10px;
    padding:12px 6% 14px;
    background:var(--bg);
    border-bottom:1px solid var(--border);
    box-shadow:0 18px 42px rgba(0,0,0,.48);
  }

  html[data-theme="light"] nav.has-mobile-menu.nav-menu-open > .mobile-menu-panel{
    background:rgba(246,246,243,.98);
    box-shadow:0 18px 42px rgba(0,0,0,.14);
  }

  nav.has-mobile-menu.nav-menu-open > .mobile-menu-panel .nav-links,
  nav.has-mobile-menu.nav-menu-open > .mobile-menu-panel .nav-actions,
  nav.has-mobile-menu.nav-menu-open > .mobile-menu-panel .nav-tabs,
  nav.has-mobile-menu.nav-menu-open > .mobile-menu-panel .nav-right,
  nav.has-mobile-menu.nav-menu-open > .mobile-menu-panel .links{
    display:flex;
    width:100%;
    height:auto;
    flex:0 0 auto;
    flex-direction:column;
    align-items:stretch;
    gap:8px;
    margin:0;
    padding:0;
    font-size:.82em;
  }

  nav.has-mobile-menu.nav-menu-open > .mobile-menu-panel a,
  nav.has-mobile-menu.nav-menu-open > .mobile-menu-panel button{
    min-height:40px;
  }

  nav.has-mobile-menu.nav-menu-open > .mobile-menu-panel .nav-tab{
    justify-content:flex-start;
    border:1px solid var(--border);
    border-radius:var(--radius, 2px);
    padding:10px 12px;
  }

  nav.has-mobile-menu.nav-menu-open > .mobile-menu-panel .nav-tab.active{
    border-color:var(--bright, var(--accent));
  }

  nav.has-mobile-menu.nav-menu-open > .mobile-menu-panel .theme-switcher{
    width:100%;
  }

  nav.has-mobile-menu.nav-menu-open > .mobile-menu-panel .theme-option{
    flex:1;
  }
}

.theme-option{
  border:0;
  background:transparent;
  color:var(--muted2);
  border-radius:var(--radius, 8px);
  padding:6px 9px;
  min-width:54px;
  font:inherit;
  font-size:.68em;
  line-height:1;
  letter-spacing:1px;
  text-transform:uppercase;
  cursor:pointer;
}

.theme-option:hover{
  color:var(--bright, var(--accent));
}

.theme-option.active{
  background:var(--bright, var(--accent));
  color:var(--bg);
}

html[data-theme="light"] .theme-option.active{
  background:#111111;
  color:#ffffff;
}

@media(max-width:640px){
  .theme-switcher:not(.theme-floating){
    gap:2px;
  }
  .theme-option{
    min-width:42px;
    padding:6px 7px;
    font-size:.62em;
  }
}
