:root{
  --bg:#0b0d12;
  --bg-soft:#11141b;
  --panel:#171b24;
  --panel-2:#1d2230;
  --panel-3:#22283a;
  --text:#f7f7f2;
  --muted:#a6adba;
  --accent:#f6d04f;
  --accent-2:#ffcf3a;
  --accent-3:#ffd96d;
  --danger:#ff6b6b;
  --success:#4cd4a1;
  --radius:18px;
  --shadow:0 14px 40px rgba(0,0,0,.35);
  --glow:0 0 0 1px rgba(246,208,79,.22),0 12px 26px rgba(246,208,79,.12);
}
*{box-sizing:border-box}
html,body{margin:0;padding:0}
button{cursor:pointer}
body{
  font-family:'Manrope',system-ui,-apple-system,Segoe UI,Arial,sans-serif;
  color:var(--text);
  background:radial-gradient(1200px 800px at 10% -20%,#1d2233 0%,#0b0d12 55%) fixed;
  min-height:100vh;
}
body.site{min-height:100vh;display:flex;flex-direction:column;overflow-x:hidden}
body.site main{flex:1}
img{max-width:100%;display:block}
a{color:inherit;text-decoration:none}
p,li,code{overflow-wrap:anywhere}

.container{width:min(1200px,92vw);margin:0 auto}

.nav{
  position:sticky;top:0;z-index:20;
  backdrop-filter:blur(14px);
  background:rgba(11,13,18,.7);
  border-bottom:1px solid rgba(255,255,255,.06);
}
.nav-inner{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:16px 0}
.brand{display:flex;align-items:center;gap:12px;font-weight:700;letter-spacing:.2px}
.brand-mark{width:40px;height:40px;border-radius:12px;background:transparent;display:grid;place-items:center;overflow:hidden;box-shadow:none}
.brand-mark img{width:100%;height:100%;object-fit:cover}
.nav-links{display:flex;gap:22px;color:var(--muted);font-weight:600}
.nav-links a:hover{color:var(--text)}
.nav-actions{display:flex;gap:12px;align-items:center}
.nav-actions > *{min-width:0}
.nav-toggle{
  display:none;
  width:44px;
  height:44px;
  border-radius:12px;
  border:1px solid rgba(255,255,255,.14);
  background:linear-gradient(180deg,var(--panel-2),var(--panel));
  color:var(--text);
  align-items:center;
  justify-content:center;
  cursor:pointer;
  font-size:20px;
}

.button{
  padding:11px 16px;border-radius:14px;border:1px solid rgba(255,255,255,.14);
  background:linear-gradient(180deg,var(--panel-2),var(--panel));
  color:var(--text);font-weight:700;transition:.18s ease;cursor:pointer;
}
.button:hover{transform:translateY(-2px);box-shadow:0 14px 28px rgba(0,0,0,.32)}
.button.primary{background:linear-gradient(120deg,var(--accent),var(--accent-3));color:#241d00;border:none}
.button.ghost{background:transparent;border-color:rgba(255,255,255,.2)}
.button:disabled{
  cursor:not-allowed;
  opacity:.55;
  transform:none;
  box-shadow:none;
}

.hero{padding:70px 0 40px}
.hero-grid{display:grid;grid-template-columns:1.1fr .9fr;gap:32px;align-items:center}
.hero h1{font-family:'Sora',sans-serif;font-size:46px;line-height:1.05;margin:0 0 16px}
.hero p{color:var(--muted);font-size:18px;margin:0}
.hero-full{
  position:relative;
  min-height:calc(100vh - 74px);
  display:flex;
  align-items:center;
  padding:92px 0 170px;
  background:
    radial-gradient(1200px 600px at 90% 8%,rgba(255,255,255,.28),transparent 58%),
    radial-gradient(900px 520px at -6% 10%,rgba(255,255,255,.26),transparent 54%),
    linear-gradient(135deg,#ffd96b 0%,#f6c343 38%,#e8b12c 100%);
  overflow:hidden;
}
.hero-full::after{
  content:"";
  position:absolute;
  left:0;
  right:0;
  bottom:-2px;
  height:124px;
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 140' preserveAspectRatio='none'%3E%3Cpath fill='%230b0d12' d='M0,96L60,90.7C120,85,240,75,360,69.3C480,64,600,64,720,80C840,96,960,128,1080,133.3C1200,139,1320,117,1380,106.7L1440,96L1440,160L1380,160C1320,160,1200,160,1080,160C960,160,840,160,720,160C600,160,480,160,360,160C240,160,120,160,60,160L0,160Z'/%3E%3C/svg%3E")
    center bottom / 100% 100% no-repeat;
  pointer-events:none;
}
.hero-full .hero-grid{
  width:100%;
  position:relative;
  z-index:1;
  max-width:1060px;
  margin:0 auto;
  grid-template-columns:1fr .92fr;
  gap:44px;
}
.hero-copy{padding-left:10px}
.hero-full h1{
  color:#2a1c00;
  font-size:58px;
  line-height:1.02;
  letter-spacing:-.5px;
  max-width:700px;
}
.hero-full p{color:#5a430b}
.hero-subline{
  font-size:20px;
  line-height:1.5;
  max-width:640px;
}
.hero-badges{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  margin-top:18px;
}
.hero-badge{
  padding:7px 12px;
  border-radius:999px;
  border:1px solid rgba(60,42,0,.24);
  background:rgba(255,255,255,.34);
  color:#3c2a00;
  font-size:13px;
  font-weight:700;
}
.hero-actions{margin-top:24px}
.hero-micro{
  margin-top:14px;
  color:#6d5416;
  font-size:14px;
  font-weight:600;
}
.hero-full .button{
  border-color:rgba(42,28,0,.2);
  background:rgba(255,255,255,.42);
  color:#2a1c00;
}
.hero-full .button.primary{
  background:linear-gradient(120deg,#241d00,#3a2a00);
  color:#fbe8a4;
}
.hero-card-highlight{
  background:linear-gradient(180deg,rgba(255,255,255,.48),rgba(255,255,255,.27));
  border:1px solid rgba(60,42,0,.22);
  box-shadow:0 18px 36px rgba(60,42,0,.22);
}
.hero-card-highlight h3{color:#111}
.hero-mini-note{
  margin-top:14px;
  font-size:13px;
  color:#5d4510;
}
.hero-card-highlight p{color:#5a430b}
.hero-card-highlight .stat{
  background:rgba(255,255,255,.5);
  border:1px solid rgba(60,42,0,.14);
  color:#2a1c00;
}
.hero-card-highlight .stat strong{color:#2a1c00}

.hero-card{
  background:linear-gradient(180deg,rgba(255,255,255,.06),rgba(255,255,255,.02));
  border-radius:var(--radius);padding:24px;border:1px solid rgba(255,255,255,.08);box-shadow:var(--shadow)
}
.stat-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;margin-top:18px}
.stat{background:var(--panel-2);padding:16px;border-radius:14px;display:grid;gap:6px;border:1px solid rgba(255,255,255,.06)}
.stat strong{font-size:22px}

.section{padding:40px 0}
.section h2{font-family:'Sora',sans-serif;font-size:30px;margin:0 0 18px}
body.home .section{padding:78px 0}

.trust-marquee{
  position:relative;
  overflow:hidden;
  border-radius:16px;
  margin:0 0 26px;
}
.hero-trust-label{
  margin:0;
  font-size:12px;
  letter-spacing:.4px;
  font-weight:800;
  text-transform:uppercase;
  color:#8f97a7;
}
.trust-marquee::before,
.trust-marquee::after{
  content:"";
  position:absolute;
  top:0;
  bottom:0;
  width:80px;
  z-index:2;
  pointer-events:none;
}
.trust-marquee::before{
  left:0;
  background:linear-gradient(90deg,#0b0d12 0%,rgba(11,13,18,0) 100%);
}
.trust-marquee::after{
  right:0;
  background:linear-gradient(270deg,#0b0d12 0%,rgba(11,13,18,0) 100%);
}
.trust-track{
  display:flex;
  align-items:center;
  gap:12px;
  width:max-content;
  padding:12px 14px;
  animation:trust-scroll 48s linear infinite;
  will-change:transform;
}
.trust-item{
  display:inline-flex;
  align-items:center;
  gap:10px;
  min-width:max-content;
  padding:9px 12px 9px 9px;
  border-radius:12px;
  background:rgba(16,19,27,.8);
}
.trust-icon{
  width:34px;
  height:34px;
  border-radius:10px;
  display:grid;
  place-items:center;
  background:linear-gradient(125deg,var(--accent),var(--accent-3));
  color:#241d00;
  font-weight:800;
  font-family:'Sora',sans-serif;
  overflow:hidden;
}
.trust-icon.has-image{
  background:var(--panel-2);
}
.trust-icon img{
  width:100%;
  height:100%;
  object-fit:cover;
}
.trust-name{
  font-size:14px;
  font-weight:700;
  color:#f0f2f7;
}
.trust-section{
  padding-top:24px !important;
  padding-bottom:30px !important;
}
.trust-section .container{
  width:min(1440px,98vw);
}
.trust-header{
  display:flex;
  align-items:center;
  justify-content:space-between;
  margin-bottom:10px;
}
@keyframes trust-scroll{
  from{transform:translateX(0)}
  to{transform:translateX(calc(-50% - 6px))}
}
.grid-3{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:20px}
.card{background:var(--panel);border-radius:var(--radius);padding:20px;border:1px solid rgba(255,255,255,.06);box-shadow:var(--shadow)}
.card h3{margin:0 0 8px;font-size:18px}
.card p{margin:0;color:var(--muted)}

.split-grid{display:grid;grid-template-columns:1.15fr .85fr;gap:24px;align-items:stretch}
.stack{display:grid;gap:16px}
.feature-rail{display:grid;gap:16px}
.feature-hero{
  background:linear-gradient(135deg,rgba(246,208,79,.18),rgba(246,208,79,.04));
  border:1px solid rgba(246,208,79,.28);
  box-shadow:var(--glow);
}
.twitch-showcase{
  display:grid;
  grid-template-columns:.95fr 1.05fr;
  align-items:center;
  gap:18px;
}
.twitch-section .container{
  padding-top:38px;
}
.twitch-section h2{
  margin-bottom:26px;
}
.twitch-section{padding-bottom:110px}
.twitch-section + .section{padding-top:104px}
.twitch-copy{
  padding:18px 8px 0 4px;
  max-width:520px;
  transform:translateY(8px);
}
.twitch-copy h2{margin:0 0 12px}
.twitch-copy p{margin:0 0 10px;color:var(--text);line-height:1.55}
.twitch-copy p.muted{color:var(--muted)}
.twitch-kicker{
  display:inline-flex;
  margin-bottom:10px;
  padding:5px 10px;
  border-radius:999px;
  font-size:12px;
  letter-spacing:.3px;
  font-weight:700;
  color:#ffe7a0;
  border:1px solid rgba(246,208,79,.4);
  background:rgba(246,208,79,.11);
}
.twitch-bullets{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  margin-top:14px;
}
.twitch-preview-wrap{
  position:relative;
  min-height:340px;
  transform:translateY(6px);
}
.twitch-preview-wrap::before{
  content:"";
  position:absolute;
  inset:34px 10px 12px 52px;
  border-radius:26px;
  background:
    radial-gradient(65% 80% at 25% 10%,rgba(255,95,184,.25),transparent 70%),
    radial-gradient(75% 90% at 80% 80%,rgba(120,78,255,.2),transparent 74%),
    linear-gradient(145deg,rgba(18,12,28,.85),rgba(20,14,35,.45));
}
.twitch-preview-image{
  position:absolute;
  right:8%;
  top:20px;
  width:min(460px,78%);
  border-radius:14px;
  border:1px solid rgba(255,255,255,.2);
  box-shadow:0 20px 34px rgba(0,0,0,.35);
  transform:rotate(-1.2deg);
  z-index:2;
}
.pill-row{display:flex;gap:10px;flex-wrap:wrap;margin-top:14px}
.pill{
  padding:6px 12px;border-radius:999px;background:rgba(246,208,79,.14);
  border:1px solid rgba(246,208,79,.35);color:var(--accent);font-weight:600
}
.steps{
  position:relative;
  overflow-x:visible;
  overflow-y:visible;
}
.steps-card{
  background:var(--panel);border-radius:var(--radius);border:1px solid rgba(255,255,255,.08);
  box-shadow:var(--shadow);padding:18px;display:grid;gap:12px
}
.step-row{
  display:grid;grid-template-columns:36px 1fr;gap:12px;align-items:start;
  padding:12px;border-radius:14px;background:var(--panel-2);border:1px solid rgba(255,255,255,.06)
}
.step-num{
  width:36px;height:36px;border-radius:12px;display:grid;place-items:center;
  background:linear-gradient(120deg,var(--accent),var(--accent-3));color:#241d00;font-weight:800
}
.floating-bot{
  position:absolute;right:6%;top:-12px;width:140px;height:140px;border-radius:36px;
  background:radial-gradient(circle at 30% 30%,rgba(246,208,79,.35),rgba(246,208,79,.05));
  border:1px solid rgba(255,255,255,.08);display:grid;place-items:center;
  box-shadow:var(--shadow);transform:rotate(-6deg)
}
.floating-bot img{width:92px;height:92px;border-radius:24px;object-fit:contain;filter:drop-shadow(0 10px 20px rgba(0,0,0,.3))}
.floating-bot .placeholder{
  width:92px;height:92px;border-radius:24px;background:var(--panel-3);
  display:grid;place-items:center;font-weight:700;color:var(--muted)
}

/* Home layout rhythm */
body.home .hero-grid > :first-child{transform:translateY(-10px)}
body.home .hero-grid > :last-child{transform:translateY(14px)}
body.home .grid-3 .card{transition:transform .2s ease}
body.home .grid-3 .card:nth-child(odd){transform:translateY(8px)}
body.home .grid-3 .card:nth-child(even){transform:translateY(-6px)}
body.home .feature-hero{transform:translateY(-6px)}
body.home .feature-rail .card:first-child{transform:translateX(10px)}
body.home .feature-rail .card:last-child{transform:translateX(-8px)}
body.home .steps .hero-card{transform:translateY(10px)}
body.home .steps .steps-card{transform:translateX(-6px)}
.modules-chaos{
  gap:10px 12px;
  grid-auto-rows:1fr;
  align-items:start;
}
.modules-chaos .card{
  min-height:118px;
  height:118px;
  display:flex;
  flex-direction:column;
  justify-content:space-between;
  transition:box-shadow .25s ease;
}
.modules-chaos .chaos-1{transform:translate(-2px,-4px);z-index:2}
.modules-chaos .chaos-2{transform:translate(2px,-1px);z-index:2}
.modules-chaos .chaos-3{transform:translate(0,-4px);z-index:2}
.modules-chaos .chaos-4{transform:translate(-10px,-9px);z-index:1}
.modules-chaos .chaos-5{transform:translate(10px,4px);z-index:3}
.modules-chaos .chaos-6{transform:translate(4px,-9px);z-index:2}
.modules-chaos .chaos-7{transform:translate(0,-5px);z-index:1}
.modules-chaos .card:hover{
  box-shadow:0 10px 22px rgba(0,0,0,.28);
}
.feature-wall{
  display:grid;
  grid-template-columns:repeat(12,minmax(0,1fr));
  gap:14px;
  align-items:start;
}
.feature-tile{
  position:relative;
  overflow:hidden;
  border-radius:18px;
  border:1px solid rgba(255,255,255,.16);
  box-shadow:0 14px 30px rgba(0,0,0,.3);
  min-height:170px;
  background:#10131a;
}
.feature-tile img{
  width:100%;
  height:100%;
  min-height:170px;
  object-fit:cover;
  filter:saturate(1.05) contrast(1.03);
}
.feature-caption{
  position:absolute;
  left:10px;
  right:10px;
  bottom:10px;
  padding:10px 12px;
  border-radius:12px;
  background:linear-gradient(180deg,rgba(10,12,18,.25),rgba(10,12,18,.82));
  border:1px solid rgba(255,255,255,.2);
  display:grid;
  gap:3px;
}
.feature-caption strong{font-size:14px}
.feature-caption span{font-size:12px;color:#d1d4dc}
.feature-tile.disorder-1{grid-column:span 7;transform:translateY(-8px) rotate(-1deg)}
.feature-tile.disorder-2{grid-column:span 5;transform:translateY(6px) rotate(1.3deg)}
.feature-tile.disorder-3{grid-column:span 4;transform:translate(8px,-5px) rotate(-1.6deg)}
.feature-tile.disorder-4{grid-column:span 4;transform:translateY(9px) rotate(.8deg)}
.feature-tile.disorder-5{grid-column:span 4;transform:translate(-8px,-7px) rotate(-.7deg)}
.module-chaos-wall{
  display:flex;
  flex-wrap:wrap;
  align-items:flex-start;
  gap:0;
  margin-top:8px;
}
.module-sections{
  display:grid;
  gap:42px;
  margin-top:18px;
}
.module-section{
  display:grid;
  grid-template-columns:minmax(260px,.78fr) 1fr;
  align-items:center;
  gap:26px;
  padding:8px 0 30px;
  border-bottom:1px solid rgba(255,255,255,.08);
}
.module-section.is-reverse .module-section-copy{order:2}
.module-section.is-reverse .chaos-item{order:1}
.module-section:last-child{border-bottom:none;padding-bottom:8px}
.module-section-copy{
  max-width:460px;
}
.module-section-copy h3{
  margin:0 0 10px;
  font-family:'Sora',sans-serif;
  font-size:30px;
  line-height:1.06;
}
.module-section-copy p{
  margin:0;
  color:var(--muted);
  line-height:1.55;
  max-width:420px;
}
.module-mini-pills{
  margin-top:12px;
  display:flex;
  flex-wrap:wrap;
  gap:8px;
}
.module-mini-pills span{
  padding:5px 10px;
  border-radius:999px;
  border:1px solid rgba(246,208,79,.35);
  background:rgba(246,208,79,.12);
  color:#f7e3a2;
  font-size:12px;
  font-weight:700;
}
.chaos-item{
  margin:0;
  display:inline-flex;
  flex-direction:column;
  gap:8px;
  justify-self:start;
}
.chaos-item img{
  width:min(var(--w),94vw);
  height:auto;
  border-radius:16px;
  box-shadow:0 12px 28px rgba(0,0,0,.34);
}
.chaos-item figcaption{
  max-width:min(var(--w),94vw);
  color:var(--muted);
  font-size:14px;
  line-height:1.35;
}
.chaos-item figcaption strong{
  display:block;
  color:var(--text);
  font-size:16px;
  margin-bottom:3px;
}
.module-section-a .chaos-item{transform:translate(8px,8px) rotate(-1deg)}
.module-section-b .chaos-item{transform:translate(-16px,2px) rotate(1.1deg)}
.module-section-c .chaos-item{transform:translate(18px,-2px) rotate(-0.8deg)}
.module-section-d .chaos-item{transform:translate(-8px,6px) rotate(0.9deg)}
.module-section-e .chaos-item{transform:translate(12px,2px) rotate(-0.6deg)}
.chaos-suggest-stack{
  position:relative;
  width:min(477px,94vw);
  min-height:390px;
}
.chaos-suggest-stack img{
  position:absolute;
}
.chaos-suggest-stack img:first-child{
  left:0;
  top:0;
  width:min(477px,94vw);
}
.chaos-suggest-stack img:last-child{
  right:-20px;
  bottom:8px;
  width:min(321px,70vw);
  transform:rotate(2.1deg);
}
body.home .hero-full .hero-grid > :first-child,
body.home .hero-full .hero-grid > :last-child{transform:none}

.footer{padding:32px 0;color:var(--muted);text-align:center;border-top:1px solid rgba(255,255,255,.06);margin-top:auto}

/* Dashboard */
body.dash{overflow:hidden;background:radial-gradient(1200px 800px at -10% 0%,#242a3b 0%,#0b0d12 55%) fixed}
.app{display:grid;grid-template-columns:86px minmax(0,1fr);height:100dvh}

.guildbar{
  background:rgba(14,16,22,.95);border-right:1px solid rgba(255,255,255,.06);
  padding:16px 10px;display:flex;flex-direction:column;gap:14px;overflow-y:auto;overflow-x:hidden
}
.guildbar::-webkit-scrollbar{width:8px}
.guildbar::-webkit-scrollbar-track{background:rgba(255,255,255,.04);border-radius:999px}
.guildbar::-webkit-scrollbar-thumb{background:linear-gradient(180deg,#f4c94a,#d7a92e);border-radius:999px}
.guildbar::-webkit-scrollbar-thumb:hover{background:linear-gradient(180deg,#ffd86d,#d6a430)}

.guild{
  width:58px;height:58px;border-radius:20px;background:transparent;
  border:1px solid transparent;display:grid;place-items:center;
  position:relative;transition:.2s ease;cursor:pointer;color:var(--text);font-weight:700;font-family:'Sora',sans-serif
}
.guild:not(.has-icon){background:var(--panel-2);border-color:rgba(255,255,255,.08)}
.guild img{width:100%;height:100%;object-fit:cover;border-radius:16px}
.guild.has-icon{padding:4px}
.guild.active{
  background:linear-gradient(120deg,var(--accent),var(--accent-3));
  border-color:rgba(255,255,255,.35);
  box-shadow:0 0 0 1px rgba(246,208,79,.2),0 10px 24px rgba(246,208,79,.22);
  transform:translateY(-1px)
}
.guild:hover{border-color:rgba(255,255,255,.25)}
.guild-home{
  text-decoration:none;
  font-size:20px;
  background:var(--panel-2);
  border-color:rgba(255,255,255,.08);
  box-shadow:none;
}
.guildbar-divider{
  height:1px;
  width:100%;
  background:rgba(255,255,255,.08);
  margin:2px 0 2px;
}
.guild::after{
  content:attr(data-tooltip);position:absolute;left:70px;top:50%;transform:translateY(-50%);
  background:rgba(10,12,18,.92);color:var(--text);padding:6px 10px;border-radius:10px;
  white-space:nowrap;opacity:0;pointer-events:none;transition:.2s ease;border:1px solid rgba(255,255,255,.08);
}
.guild:hover::after{opacity:1}

.main{display:flex;flex-direction:column;min-width:0;height:100dvh}
.topbar{
  display:grid;grid-template-columns:minmax(0,1fr) auto minmax(0,1fr);align-items:center;gap:16px;
  padding:16px 22px;border-bottom:1px solid rgba(255,255,255,.06);
  background:rgba(12,14,20,.8);backdrop-filter:blur(10px)
}
.topbar > div:first-child{display:flex;align-items:center;gap:12px;min-width:0;flex-wrap:wrap}
.topbar #topbarSubtitle{flex-basis:100%}
.topbar h1{margin:0;font-size:20px;font-family:'Sora',sans-serif}
.guildbar-toggle{display:none;padding:8px 10px}
.dash-section-nav{
  display:none;
  align-items:center;
  justify-self:center;
  justify-content:center;
  gap:10px;
}
.dash-section-nav.is-visible{display:flex}
.dash-section-nav .button{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:9px 14px;
}
.dash-section-nav .button.active{
  background:linear-gradient(120deg,var(--accent),var(--accent-3));
  color:#241d00;
  border-color:transparent;
}
.user-menu{position:relative}
.user-btn{display:flex;align-items:center;gap:10px;background:var(--panel-2);border:1px solid rgba(255,255,255,.1);padding:8px 12px;border-radius:12px;cursor:pointer;max-width:100%}
.user-btn span{color:var(--text);max-width:220px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.user-btn i{color:var(--text)}
.user-btn img{width:28px;height:28px;border-radius:50%}
.user-dropdown{
  position:absolute;right:0;top:calc(100% + 10px);min-width:200px;background:var(--panel);
  border:1px solid rgba(255,255,255,.08);border-radius:14px;box-shadow:var(--shadow);
  padding:8px;display:none
}
.dash .user-dropdown{
  right:0;
  left:auto;
  min-width:min(240px,calc(100vw - 24px));
  max-width:min(320px,calc(100vw - 24px));
}
.topbar .user-menu{
  justify-self:end;
}
.user-dropdown a{display:flex;gap:8px;align-items:center;padding:10px 12px;border-radius:10px;color:var(--text)}
.user-dropdown a:hover{background:rgba(255,255,255,.06)}
.user-menu.open .user-dropdown{display:block}

.content{flex:1;overflow:auto;padding:24px 26px 40px}
.content::-webkit-scrollbar{width:10px}
.content::-webkit-scrollbar-track{background:rgba(255,255,255,.04);border-radius:999px}
.content::-webkit-scrollbar-thumb{background:linear-gradient(180deg,#f4c94a,#d7a92e);border-radius:999px}

.section-title{display:flex;align-items:center;gap:10px;margin:0 0 14px;font-size:18px;font-family:'Sora',sans-serif}
.panel{background:var(--panel);border-radius:var(--radius);border:1px solid rgba(255,255,255,.08);box-shadow:var(--shadow);padding:20px;margin-bottom:18px}
.panel .panel-head{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-bottom:16px}
.panel .panel-head > div{min-width:0}
.panel p{color:var(--muted);margin:4px 0 0}
.module-grid{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:18px;
}
.module-grid .panel{margin-bottom:0}
.module-head-actions{display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.module-head-actions [data-action="close-modal"]{display:none !important}
.config-detail-header{margin-bottom:18px}
.config-detail-toolbar{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:18px;
  flex-wrap:wrap;
}
.config-back-btn{
  display:inline-flex;
  align-items:center;
  gap:8px;
}
.module-lock-notice{
  display:none;
  align-items:center;
  gap:10px;
  margin:-2px 0 18px;
  padding:12px 14px;
  border-radius:14px;
  background:rgba(255,107,107,.08);
  border:1px solid rgba(255,107,107,.22);
  color:#ffd0d0;
  font-size:14px;
  font-weight:600;
}

.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:16px}
.form-row{display:flex;flex-direction:column;gap:8px}
label{font-weight:600}
input[type="text"],input[type="number"],select,textarea{
  background:var(--panel-2);border:1px solid rgba(255,255,255,.1);color:var(--text);
  padding:10px 12px;border-radius:12px;font-family:inherit;font-size:14px
}
textarea{min-height:120px;resize:vertical;line-height:1.4}
.help{color:var(--muted);font-size:12px}

.toggle{
  display:flex;align-items:center;gap:10px
}
.toggle input{display:none}
.toggle span{
  width:44px;height:24px;border-radius:999px;background:rgba(255,255,255,.12);position:relative;transition:.2s ease
}
.toggle span::after{
  content:'';position:absolute;width:18px;height:18px;border-radius:50%;background:#fff;left:3px;top:3px;transition:.2s ease
}
.toggle input:checked + span{background:linear-gradient(120deg,var(--accent),var(--accent-3))}
.toggle input:checked + span::after{left:23px;background:#241d00}

.tag-row{display:flex;gap:8px;flex-wrap:wrap}
.tag{padding:6px 10px;border-radius:999px;background:rgba(246,208,79,.12);border:1px solid rgba(246,208,79,.3);color:var(--accent)}
.tag-nav{cursor:pointer;font-family:inherit;font-weight:700}
.featured-tag{
  background:linear-gradient(120deg,rgba(246,208,79,.26),rgba(255,217,109,.16));
  border-color:rgba(246,208,79,.55);
  box-shadow:0 0 0 1px rgba(246,208,79,.22),0 8px 20px rgba(246,208,79,.14);
}

.panel-featured{
  background:linear-gradient(150deg,rgba(246,208,79,.16),rgba(23,27,36,.96) 32%,rgba(23,27,36,.98));
  border-color:rgba(246,208,79,.45);
  box-shadow:0 0 0 1px rgba(246,208,79,.24),0 14px 38px rgba(0,0,0,.35);
}

.module-status{
  display:inline-flex;
  align-items:center;
  gap:8px;
  margin-top:10px;
  padding:6px 10px;
  border-radius:999px;
  width:max-content;
  font-size:12px;
  font-weight:800;
  letter-spacing:.02em;
}
.module-status.is-enabled{
  color:#86efac;
  background:rgba(76,212,161,.12);
  border:1px solid rgba(76,212,161,.24);
}
.module-status.is-disabled{
  color:#fca5a5;
  background:rgba(255,107,107,.1);
  border:1px solid rgba(255,107,107,.2);
}

.role-list{display:grid;gap:8px;max-height:220px;overflow:auto;padding-right:6px}
.role-item{display:flex;align-items:center;gap:10px;background:var(--panel-2);padding:10px 12px;border-radius:14px;border:1px solid rgba(255,255,255,.08)}
.role-item input{transform:scale(1.1)}
.discord-role{
  --role-color:#99aab5;
  display:inline-flex;
  align-items:center;
  gap:8px;
  max-width:100%;
  min-height:28px;
  padding:4px 10px;
  border-radius:999px;
  color:var(--role-color);
  background:color-mix(in srgb, var(--role-color) 16%, rgba(255,255,255,.03));
  border:1px solid color-mix(in srgb, var(--role-color) 34%, rgba(255,255,255,.08));
  font-weight:700;
}
.discord-role.is-empty{
  color:var(--muted);
  background:rgba(255,255,255,.05);
  border-color:rgba(255,255,255,.08);
}
.discord-role-dot{
  width:10px;
  height:10px;
  border-radius:50%;
  background:currentColor;
  flex:0 0 auto;
}
.discord-role-text{
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.role-select-stack{
  display:grid;
  gap:8px;
}
.role-preview-slot{
  min-height:32px;
}

.level-rows{display:grid;gap:10px}
.level-row{display:grid;grid-template-columns:110px 1fr auto;gap:10px;align-items:center}
.level-row button{padding:8px 10px}

.preview{
  background:rgba(10,12,18,.6);border-radius:12px;border:1px solid rgba(255,255,255,.08);
  padding:12px;min-height:80px;color:var(--text)
}
.preview p{margin:0}

.action-row{display:flex;justify-content:flex-end;gap:10px;margin-top:12px;flex-wrap:wrap}
.action-row .button{min-width:140px}

.empty-state{display:grid;place-items:center;text-align:center;gap:16px;padding:60px 20px;color:var(--muted)}
.empty-state h2{margin:0;color:var(--text)}
.dashboard-access-note{
  margin-top:18px;
  padding:14px 16px;
  border-radius:16px;
  border:1px solid rgba(246,208,79,.18);
  background:rgba(246,208,79,.07);
  display:grid;
  gap:8px;
  text-align:left;
}
.dashboard-access-note strong{color:var(--text)}
.dashboard-access-note span{color:var(--muted);line-height:1.55}

.loader{
  position:fixed;inset:0;background:radial-gradient(800px 600px at 50% -10%,#242a3b 0%,#0b0d12 60%);
  display:flex;align-items:center;justify-content:center;flex-direction:column;gap:18px;z-index:100
}
.loader.hidden{display:none}
.loader .spinner{
  width:56px;height:56px;border-radius:50%;border:4px solid rgba(255,255,255,.12);
  border-top-color:var(--accent);animation:spin 1s linear infinite
}
@keyframes spin{to{transform:rotate(360deg)}}

.saving-overlay{
  position:fixed;
  inset:0;
  z-index:140;
  display:grid;
  place-items:center;
  background:rgba(7,9,14,.48);
  backdrop-filter:blur(8px);
}
.saving-overlay.hidden{
  display:none;
}
.saving-card{
  min-width:min(360px,calc(100vw - 32px));
  padding:24px 26px;
  border-radius:20px;
  border:1px solid rgba(255,255,255,.1);
  background:linear-gradient(180deg,var(--panel-2),var(--panel));
  box-shadow:0 24px 60px rgba(0,0,0,.38);
  display:grid;
  justify-items:center;
  gap:14px;
  text-align:center;
}
.saving-success-icon{
  display:none;
  width:60px;
  height:60px;
  border-radius:50%;
  place-items:center;
  background:rgba(76,212,161,.14);
  color:var(--success);
  font-size:34px;
}
.saving-spinner{
  width:52px;
  height:52px;
  border-radius:50%;
  border:4px solid rgba(255,255,255,.12);
  border-top-color:var(--accent);
  animation:spin 1s linear infinite;
}
.saving-overlay.is-success .saving-card{
  border-color:rgba(76,212,161,.32);
}
.saving-overlay.is-success .saving-message{
  color:var(--success);
}
.saving-message{
  font-size:18px;
  font-weight:800;
}

html.loading .app{opacity:0;pointer-events:none}

/* Invite */
.invite-card{max-width:560px;margin:60px auto;background:var(--panel);padding:28px;border-radius:var(--radius);border:1px solid rgba(255,255,255,.08);box-shadow:var(--shadow)}
.invite-card .guild-avatar{width:64px;height:64px;border-radius:16px;background:var(--panel-2);display:grid;place-items:center;margin-bottom:14px}
.invite-embed-card{max-width:660px;margin:0 auto}
.invite-actions{display:flex;gap:10px;flex-wrap:wrap;margin-top:16px}

.stats-kpi-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px}
.kpi-card{padding:16px;border-radius:14px;background:var(--panel-2);border:1px solid rgba(255,255,255,.08)}
.kpi-label{color:var(--muted);font-size:12px;margin-bottom:8px}
.kpi-value{font-size:26px;font-weight:700;line-height:1.1}
.stats-chart-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px}
.chart-card{
  background:var(--panel);border-radius:var(--radius);border:1px solid rgba(255,255,255,.08);
  box-shadow:var(--shadow);padding:16px
}
.chart-card canvas{width:100% !important;height:280px !important}

#toastWrap{
  position:fixed;right:20px;bottom:20px;display:grid;gap:10px;z-index:120
}
.toast{
  background:var(--panel);border:1px solid rgba(255,255,255,.08);padding:12px 14px;border-radius:12px;
  box-shadow:var(--shadow);font-weight:600
}
.toast.ok{color:var(--text)}
.toast.error{color:var(--danger)}

.module-grid.is-overview .panel{
  min-height:148px;
  display:flex;
  flex-direction:column;
  justify-content:space-between;
}
.module-grid.is-overview .panel.module-enabled{
  border-color:rgba(76,212,161,.22);
  box-shadow:0 16px 38px rgba(0,0,0,.3),0 0 0 1px rgba(76,212,161,.08);
}
.module-grid.is-overview .panel.module-disabled{
  border-color:rgba(255,255,255,.08);
  opacity:.9;
}
.module-grid.is-overview .panel .panel-head{
  margin-bottom:0;
  align-items:flex-start;
}
.module-grid.is-overview .panel .toggle,
.module-grid.is-overview .panel [data-action="close-modal"]{
  display:none !important;
}
.module-grid.is-overview .panel .module-head-actions{
  width:100%;
  margin-top:16px;
}
.module-grid.is-overview .panel .module-head-actions [data-action="open-modal"]{
  width:100%;
  justify-content:center;
}
.module-grid.is-overview .panel > :not(.panel-head){
  display:none;
}
.module-grid.is-detail{
  grid-template-columns:minmax(0,1fr);
}
.module-grid.is-detail .panel.is-hidden{
  display:none;
}
.module-grid.is-detail .panel.is-active-detail{
  margin-bottom:0;
}
.module-grid.is-detail .panel.is-active-detail .panel-head{
  margin-bottom:20px;
}
.module-grid.is-detail .panel.is-active-detail [data-action="open-modal"]{
  display:none;
}
.module-grid.is-detail .panel.is-active-detail.is-locked .module-lock-notice{
  display:flex;
}
.module-grid.is-detail .panel.is-active-detail.is-locked .form-grid,
.module-grid.is-detail .panel.is-active-detail.is-locked .action-row{
  opacity:.55;
}

@media (max-width: 1180px){
  .topbar{
    grid-template-columns:minmax(0,1fr) auto;
    align-items:start;
  }
  .dash-section-nav{
    grid-column:1 / -1;
    overflow:auto;
    padding-bottom:2px;
  }
  .dash-section-nav::-webkit-scrollbar{height:6px}
  .dash-section-nav::-webkit-scrollbar-thumb{
    background:rgba(255,255,255,.14);
    border-radius:999px;
  }
  .dash .user-menu{
    justify-self:end;
    max-width:100%;
  }
}

/* Responsive */
@media (max-width: 980px){
  body.dash{overflow:auto}
  .app{grid-template-columns:1fr;grid-template-rows:auto 1fr;height:auto;min-height:100vh}
  .guildbar-toggle{display:inline-flex;align-items:center;justify-content:center}
  .guildbar{
    position:fixed;
    left:0;
    top:0;
    width:86px;
    height:100vh;
    z-index:35;
    transform:translateX(-100%);
    transition:transform .2s ease;
    border-right:1px solid rgba(255,255,255,.08);
    border-bottom:none;
    padding:16px 10px;
    overflow-y:auto;
    overflow-x:hidden;
  }
  .guildbar::-webkit-scrollbar{width:8px}
  body.guildbar-open .guildbar{transform:translateX(0)}
  body.guildbar-open::before{
    content:"";
    position:fixed;
    inset:0;
    background:rgba(5,7,10,.45);
    z-index:22;
  }
  .guildbar-divider{
    width:100%;
    height:1px;
    margin:2px 0;
    flex:initial;
  }
  .guild-list{display:flex;flex-direction:column;gap:14px}
  .guild{
    width:58px;
    height:58px;
    border-radius:20px;
    flex:initial;
  }
  .guild::after{display:none}
  .main{height:auto;min-height:0}
  .topbar{
    position:sticky;
    top:0;
    z-index:26;
    padding:14px 16px;
  }
  .content{padding:18px 16px 28px}
  .panel .panel-head{align-items:flex-start}
  .hero-grid{grid-template-columns:1fr}
  .hero-full .hero-grid{
    grid-template-columns:1fr;
    gap:22px;
  }
  .hero-full{
    min-height:auto;
    padding:70px 0 120px;
  }
  .hero-full::after{height:94px}
  .hero-copy{padding-left:0}
  .hero-full h1{font-size:44px;max-width:none}
  .hero-subline{font-size:18px;max-width:none}
  .grid-3{grid-template-columns:1fr 1fr}
  .form-grid{grid-template-columns:1fr}
  .split-grid{grid-template-columns:1fr}
  .module-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .stats-kpi-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .stats-chart-grid{grid-template-columns:1fr}
  .twitch-showcase{grid-template-columns:1fr}
  .twitch-section .container{padding-top:26px}
  .twitch-copy{transform:none;padding:0}
  .twitch-preview-wrap{
    min-height:0;
    transform:none;
    padding-top:6px;
  }
  .twitch-preview-wrap::before{display:none}
  .twitch-preview-image{
    position:static;
    width:100%;
    max-width:560px;
    transform:none;
  }
  .floating-bot{position:static;margin:10px auto 0;transform:none}
  body.home .hero-grid > :first-child,
  body.home .hero-grid > :last-child,
  body.home .grid-3 .card:nth-child(odd),
  body.home .grid-3 .card:nth-child(even),
  body.home .feature-hero,
  body.home .feature-rail .card:first-child,
  body.home .feature-rail .card:last-child,
  body.home .steps .hero-card,
  body.home .steps .steps-card,
  .modules-chaos .chaos-1,
  .modules-chaos .chaos-2,
  .modules-chaos .chaos-3,
  .modules-chaos .chaos-4,
  .modules-chaos .chaos-5,
  .modules-chaos .chaos-6,
  .modules-chaos .chaos-7{transform:none}
  .modules-chaos .card{height:auto;min-height:120px}
  .feature-wall{grid-template-columns:repeat(2,minmax(0,1fr))}
  .feature-tile{grid-column:auto !important;transform:none !important}
  .module-chaos-wall{
    gap:18px;
    justify-content:center;
  }
  .module-sections{gap:26px}
  .module-section{
    grid-template-columns:1fr;
    transform:none !important;
    gap:14px;
    padding:0 0 20px;
  }
  .module-section.is-reverse .module-section-copy,
  .module-section.is-reverse .chaos-item{order:initial}
  .module-section-copy h3{font-size:24px}
  .module-mini-pills{margin-top:10px}
  .module-section-a .chaos-item,
  .module-section-b .chaos-item,
  .module-section-c .chaos-item,
  .module-section-d .chaos-item,
  .module-section-e .chaos-item{transform:none}
  .trust-marquee{margin-bottom:20px}
  .hero-trust-label{
    font-size:11px;
  }
  .trust-section{
    padding-top:16px !important;
    padding-bottom:22px !important;
  }
  .trust-header{margin-bottom:8px}
  .trust-marquee::before,
  .trust-marquee::after{width:42px}
  .trust-track{animation-duration:36s}
  .trust-name{font-size:13px}
  .chaos-suggest-stack{
    width:min(477px,96vw);
    min-height:330px;
  }
  .chaos-suggest-stack img:last-child{
    right:0;
    bottom:0;
  }
}
@media (max-width: 900px){
  .nav{position:static}
  .nav-inner{
    display:grid;
    grid-template-columns:minmax(0,1fr) auto;
    align-items:center;
    gap:10px 12px;
    padding:12px 0;
  }
  .brand{width:auto;min-width:0}
  .nav-toggle{display:inline-flex}
  .container{width:min(1200px,94vw)}
  .nav .nav-links{display:none;grid-template-columns:1fr;gap:8px;width:100%}
  .nav.nav-open .nav-links{display:grid}
  .nav .nav-links,.nav .nav-actions{
    grid-column:1 / -1;
    border-radius:14px;
    padding:8px;
    background:rgba(17,20,27,.85);
    border:1px solid rgba(255,255,255,.08);
  }
  .nav .nav-links a{text-align:center;padding:8px 6px;border-radius:10px;background:rgba(255,255,255,.04)}
  .nav .nav-actions{display:none;width:100%;grid-template-columns:1fr}
  .nav.nav-open .nav-actions{display:grid}
  .nav .nav-actions .button,.nav .nav-actions .user-menu{width:100%}
  .user-btn{width:100%;justify-content:space-between}
  .user-btn span{max-width:calc(100vw - 180px)}
  .nav .user-menu .user-dropdown{
    position:static;
    min-width:0;
    max-width:none;
    margin-top:8px;
  }
  .grid-3{grid-template-columns:1fr}
  .content{padding:16px 14px 24px}
  .module-grid{grid-template-columns:1fr}
  .dash-section-nav{width:100%;justify-content:flex-start;flex-wrap:wrap}
  .topbar{flex-direction:column;align-items:flex-start}
  .topbar > div:first-child{width:100%}
  .dash .user-menu{
    width:100%;
  }
  .dash .user-menu .user-dropdown{
    right:auto;
    left:0;
    width:100%;
    min-width:0;
    max-width:none;
  }
  .panel{padding:16px}
  .panel .panel-head{flex-direction:column}
  .module-head-actions{width:100%;justify-content:flex-start}
  .action-row{justify-content:stretch}
  .action-row .button{width:100%}
  .level-row{grid-template-columns:1fr}
  .stats-kpi-grid{grid-template-columns:1fr}
  .feature-wall{grid-template-columns:1fr}
  .module-sections{gap:18px}
  .module-section-copy h3{font-size:22px}
  .module-mini-pills span{font-size:11px}
  .twitch-section .container{padding-top:28px}
  .trust-track{
    gap:10px;
    padding:10px 12px;
    animation-duration:30s;
  }
  .trust-item{padding:8px 10px 8px 8px}
  .trust-icon{
    width:30px;
    height:30px;
    border-radius:9px;
  }
  .trust-name{font-size:12px}
  .chaos-item img{
    width:min(var(--w),96vw);
  }
  .chaos-item figcaption{
    max-width:min(var(--w),96vw);
  }
  .chaos-suggest-stack{
    width:min(477px,96vw);
    min-height:auto;
    display:grid;
    gap:12px;
  }
  .chaos-suggest-stack img{
    position:static;
    width:100% !important;
    transform:none !important;
  }
  .hero-full h1{font-size:36px}
  .hero-subline{font-size:16px}
  .hero h1{font-size:34px;line-height:1.1;overflow-wrap:normal;word-break:normal}
  .section h2{font-size:26px}
}
@media (max-width: 720px){
  .config-detail-toolbar{
    flex-direction:column;
    align-items:stretch;
  }
  .topbar{
    grid-template-columns:1fr;
  }
  .dash .user-menu{
    justify-self:stretch;
    width:100%;
  }
}
.guild-list{display:flex;flex-direction:column;gap:14px}

/* Status */
.status-shell{
  display:grid;
  gap:18px;
}
.status-head{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:16px;
}
.status-head h1{
  margin:0 0 8px;
  font-family:'Sora',sans-serif;
  font-size:36px;
}
.status-head p{
  margin:0;
  color:var(--muted);
}
.status-overall{
  padding:8px 12px;
  border-radius:999px;
  font-weight:800;
  font-size:13px;
  border:1px solid rgba(255,255,255,.16);
}
.status-kpis{
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:12px;
}
.status-kpi{
  background:var(--panel);
  border:1px solid rgba(255,255,255,.08);
  border-radius:14px;
  padding:14px;
}
.status-kpi .label{
  font-size:12px;
  color:var(--muted);
}
.status-kpi .value{
  margin-top:6px;
  font-size:24px;
  font-weight:800;
}
.status-grid{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:14px;
}
.status-card{
  background:var(--panel);
  border:1px solid rgba(255,255,255,.08);
  border-radius:16px;
  padding:16px;
}
.status-card-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
}
.status-card-head h3{
  margin:0;
  font-size:18px;
  font-family:'Sora',sans-serif;
}
.status-card p{
  margin:10px 0 12px;
  color:var(--muted);
}
.status-meta{
  color:#d7dbe7;
  font-size:13px;
}
.status-pill{
  padding:6px 10px;
  border-radius:999px;
  font-size:12px;
  font-weight:800;
  border:1px solid rgba(255,255,255,.14);
}
.status-ok{
  color:#0a2b12;
  background:linear-gradient(120deg,#57f287,#91f3b0);
}
.status-degraded{
  color:#3f2a00;
  background:linear-gradient(120deg,#ffd86d,#f4c94a);
}
.status-out{
  color:#3b0f11;
  background:linear-gradient(120deg,#ff9c9c,#ff6b6b);
}

@media (max-width: 980px){
  .status-kpis{grid-template-columns:repeat(2,minmax(0,1fr))}
  .status-grid{grid-template-columns:1fr}
}
@media (max-width: 720px){
  .status-head{flex-direction:column;align-items:flex-start}
  .status-head h1{font-size:30px}
  .status-kpis{grid-template-columns:1fr}
}
