:root {
  color-scheme: dark;
  --bg: #090c11;
  --panel: #0e131a;
  --panel-2: #121923;
  --line: #222c39;
  --line-strong: #344154;
  --text: #f4f7fb;
  --muted: #9aa7b8;
  --accent: #8ca8ff;
  --accent-strong: #b9c8ff;
  --success: #72d6a1;
  --warning: #f2bd62;
  --danger: #f27878;
  --info: #8fb9ff;
  --radius: 10px;
  --content: 1180px;
  --gutter: clamp(20px, 4vw, 40px);
  --section-space: clamp(58px, 8vw, 92px);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { min-width: 320px; margin: 0; overflow-x: hidden; background: var(--bg); color: var(--text); line-height: 1.55; }
a { color: inherit; text-decoration: none; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, summary:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.skip-link { position: fixed; z-index: 1000; top: 12px; left: 12px; padding: 10px 14px; border-radius: 6px; transform: translateY(-160%); background: var(--text); color: var(--bg); font-weight: 750; }
.skip-link:focus { transform: translateY(0); }
.site-header nav a, .site-footer nav a { display: inline-flex; min-height: 44px; align-items: center; }
.site-header, .site-footer { width: min(calc(100% - (2 * var(--gutter))), var(--content)); margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.site-header { min-height: 76px; border-bottom: 1px solid var(--line); }
.site-header nav, .site-footer nav { display: flex; align-items: center; gap: 24px; color: var(--muted); font-size: .9rem; }
.site-header nav a:hover, .site-footer nav a:hover { color: var(--text); }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; letter-spacing: -.02em; }
.brand-logo { width: 32px; height: 32px; object-fit: contain; flex: 0 0 auto; }
.button { display: inline-flex; min-height: 46px; align-items: center; justify-content: center; padding: 0 20px; border: 1px solid var(--accent); border-radius: 8px; background: var(--accent); color: #0a1020; font-weight: 750; }
.button:hover { background: var(--accent-strong); }
.button-small { min-height: 38px; padding-inline: 15px; }
.hero { width: min(calc(100% - (2 * var(--gutter))), var(--content)); margin: 0 auto; padding: clamp(68px, 9vw, 108px) 0 clamp(64px, 8vw, 88px); }
.eyebrow, .kicker { color: var(--accent-strong); font-size: .76rem; font-weight: 750; letter-spacing: .11em; text-transform: uppercase; }
.eyebrow { display: flex; align-items: center; gap: 9px; }
h1, h2, h3, p { margin-top: 0; }
h1 { max-width: 840px; margin: 24px 0; font-size: clamp(3rem, 7.2vw, 6.7rem); line-height: .96; letter-spacing: -.06em; }
h1 span { color: var(--muted); }
[data-scramble] { display: inline-block; min-width: 15ch; font-family: ui-monospace, "SFMono-Regular", Consolas, monospace; font-variant-numeric: tabular-nums; letter-spacing: -.08em; }
.hero-copy { max-width: 650px; margin-bottom: 0; color: #bac4d1; font-size: clamp(1rem, 2vw, 1.22rem); }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 24px; margin-top: 32px; }
.text-link { color: var(--muted); font-weight: 650; }
.text-link:hover { color: var(--text); }
.flow-section, .control-section, .faq-section { width: min(calc(100% - (2 * var(--gutter))), var(--content)); margin: 0 auto; padding: var(--section-space) 0; border-top: 1px solid var(--line); }
.flow-section { display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); gap: clamp(44px, 7vw, 88px); }
.section-heading { position: sticky; top: 32px; align-self: start; }
h2 { max-width: 680px; font-size: clamp(2rem, 4vw, 3.4rem); line-height: 1.05; letter-spacing: -.045em; }
.section-heading h2, .control-section h2 { margin-bottom: 20px; }
.section-heading > p:last-child, .control-section > div:first-child p:last-child { max-width: 570px; color: var(--muted); }
.flow-list { margin: 0; padding: 0; list-style: none; }
.flow-list li { display: grid; grid-template-columns: 48px 1fr; gap: 20px; padding: 26px 0; border-top: 1px solid var(--line); }
.flow-list li > span { display: grid; place-items: center; width: 38px; height: 38px; border: 1px solid var(--line-strong); border-radius: 6px; color: var(--accent-strong); font: 700 .75rem/1 ui-monospace, monospace; }
.flow-list strong { display: block; margin-bottom: 6px; font-size: 1.1rem; }
.flow-list p { margin-bottom: 0; color: var(--muted); }
.control-section > div:first-child { max-width: 760px; }
.control-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 40px; }
.control-grid article { min-height: 190px; padding: 26px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); }
.control-grid article > span { color: var(--accent-strong); font-size: .78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; }
.control-grid h3 { margin: 32px 0 10px; font-size: 1.15rem; }
.control-grid p { margin-bottom: 0; color: var(--muted); }
.site-footer { min-height: 110px; padding-block: 22px; border-top: 1px solid var(--line); }
.faq-section { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(44px, 7vw, 88px); }
.faq-list { border-top: 1px solid var(--line); }
.faq-list details { border-bottom: 1px solid var(--line); }
.faq-list summary { min-height: 64px; padding: 20px 36px 20px 0; cursor: pointer; font-weight: 700; }
.faq-list p { max-width: 680px; padding: 0 36px 22px 0; color: var(--muted); }

@media (max-width: 760px) {
  .site-header nav > a:not(.button), .site-footer nav a:last-child { display: none; }
  .hero { padding-top: 68px; }
  .control-grid { grid-template-columns: 1fr; }
  .faq-section { grid-template-columns: 1fr; gap: 34px; }
  .flow-section { grid-template-columns: 1fr; gap: 34px; padding-block: 72px; }
  .section-heading { position: static; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

.legal-page { width: min(calc(100% - (2 * var(--gutter))), 760px); margin: 0 auto; padding: clamp(64px, 8vw, 92px) 0 clamp(88px, 10vw, 128px); }
.legal-page h1, .state-page h1, .verify-card h1, .server-list h1, .dash-content h1 { font-size: clamp(2.5rem, 7vw, 4.8rem); }
.legal-page h2 { margin: 48px 0 14px; font-size: 1.5rem; }
.legal-page p, .legal-page dd { color: var(--muted); }
.legal-page li { margin-bottom: 10px; color: var(--muted); }
.legal-page strong, .legal-page dt { color: var(--text); }
.legal-list { display: grid; grid-template-columns: minmax(180px, .8fr) minmax(0, 1.2fr); gap: 14px 28px; }
.legal-page code { padding: 2px 6px; border: 1px solid var(--line); border-radius: 4px; background: var(--panel); color: var(--accent-strong); }
.docs-steps { margin: 44px 0 56px; padding: 0; list-style: none; }
.docs-steps li { display: grid; grid-template-columns: 1fr 2fr; gap: 24px; padding: 20px 0; border-top: 1px solid var(--line); }
.docs-steps span, .docs-page dd { color: var(--muted); }
.docs-page dl { display: grid; grid-template-columns: 140px 1fr; gap: 14px 24px; }
.state-page, .verify-shell { min-height: 100svh; width: min(calc(100% - (2 * var(--gutter))), 900px); margin: 0 auto; padding: clamp(24px, 4vw, 40px) 0; }
.state-page { display: flex; flex-direction: column; justify-content: space-between; }
.state-page > div { max-width: 650px; padding: 100px 0; }
.state-code { color: var(--accent-strong); font: 700 .8rem/1 ui-monospace, monospace; text-transform: uppercase; letter-spacing: .1em; }
.state-page > div > p:not(.state-code), .verify-card > p:not(.kicker), .privacy-note { color: var(--muted); }
.steps { display: grid; grid-template-columns: repeat(4, 1fr); margin: clamp(48px, 8vw, 76px) 0; padding: 0; list-style: none; }
.steps li { position: relative; display: flex; flex-direction: column; gap: 9px; color: #627085; font-size: .78rem; text-align: center; }
.steps li::after { content: ""; position: absolute; z-index: -1; top: 16px; left: calc(50% + 20px); width: calc(100% - 40px); border-top: 1px solid var(--line); }
.steps li:last-child::after { display: none; }
.steps li span { display: grid; place-items: center; width: 34px; height: 34px; margin: 0 auto; border: 1px solid var(--line); border-radius: 6px; background: var(--bg); font: 700 .75rem/1 ui-monospace, monospace; }
.steps li.done, .steps li[aria-current="step"] { color: var(--text); }
.steps li.done span { border-color: #39654f; color: var(--success); }
.steps li[aria-current="step"] span { border-color: var(--accent); background: var(--accent); color: #08101f; }
.verify-card { padding: clamp(28px, 6vw, 58px); border: 1px solid var(--line); border-radius: 14px; background: var(--panel); }
.verify-card h1 { margin-top: 18px; }
.verify-card form { display: grid; gap: 24px; margin-top: 28px; }
.verify-card .button { width: fit-content; }
.assessment-scan { display: none; min-height: 470px; align-content: center; justify-items: center; text-align: center; }
.scan-enhanced .assessment-scan { display: grid; }
.scan-enhanced .assessment-results { display: none; }
.scan-enhanced.scan-complete .assessment-results { display: block; animation: assessment-enter .45s ease both; }
.scan-orbit { position: relative; display: grid; width: 148px; height: 148px; margin-bottom: 34px; place-items: center; border: 1px solid #26364b; border-radius: 50%; background: radial-gradient(circle, rgb(22 43 72 / 88%) 0 34%, rgb(10 14 20 / 0%) 35%); box-shadow: 0 0 70px rgb(31 127 255 / 14%); }
.scan-orbit::before { position: absolute; width: 112px; height: 112px; border: 1px solid rgb(70 150 255 / 30%); border-radius: 50%; content: ""; }
.scan-orbit::after { position: absolute; width: 100%; height: 2px; background: linear-gradient(90deg, transparent, #54d8ff, transparent); box-shadow: 0 0 18px #39a9ff; content: ""; animation: scan-sweep 1.45s ease-in-out infinite; }
.scan-orbit img { width: 50px; height: 50px; object-fit: contain; }
.scan-orbit span { position: absolute; width: 7px; height: 7px; border-radius: 50%; background: #65b3ff; box-shadow: 0 0 12px #65b3ff; animation: scan-pulse 1.6s ease-in-out infinite; }
.scan-orbit span:nth-child(1) { top: 9px; left: 69px; }
.scan-orbit span:nth-child(2) { right: 20px; bottom: 26px; animation-delay: .35s; }
.scan-orbit span:nth-child(3) { bottom: 31px; left: 16px; animation-delay: .7s; }
.assessment-scan h1 { margin: 14px 0 10px; }
.assessment-scan > p:not(.kicker, .scan-count) { min-height: 24px; color: var(--muted); }
.scan-progress { width: min(100%, 460px); height: 8px; margin-top: 28px; overflow: hidden; border: 1px solid #2a3c53; border-radius: 99px; background: #080c12; }
.scan-progress span { display: block; width: 8%; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #246eff, #2be0ed); box-shadow: 0 0 18px rgb(43 224 237 / 45%); transition: width .55s ease; }
.scan-count { margin-top: 10px; color: #8da3bd; font: 650 .76rem/1.2 ui-monospace, monospace; }
.assessment-header { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 28px; }
.assessment-header h1 { margin: 14px 0 10px; }
.assessment-header p:last-child { color: var(--muted); }
.risk-score { --risk-color: #56d69b; display: grid; width: 116px; height: 116px; place-content: center; border-radius: 50%; background: radial-gradient(circle at center, var(--panel) 0 59%, transparent 60%), conic-gradient(var(--risk-color) calc(var(--risk-score) * 1%), #202a37 0); text-align: center; box-shadow: inset 0 0 0 1px rgb(255 255 255 / 5%), 0 0 34px color-mix(in srgb, var(--risk-color) 15%, transparent); }
.risk-score[data-risk="elevated"] { --risk-color: #f0b84b; }
.risk-score[data-risk="high"] { --risk-color: #ff6678; }
.risk-score strong { font-size: 1.8rem; line-height: 1; }
.risk-score span { margin-top: 5px; color: var(--muted); font-size: .68rem; }
.risk-level-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: 30px; padding: 13px 0; border-block: 1px solid var(--line); color: var(--muted); font-size: .82rem; }
.risk-level { display: inline-flex; width: fit-content; align-items: center; gap: 7px; color: #61dba0; font-size: .78rem; font-weight: 750; text-transform: uppercase; letter-spacing: .08em; }
.risk-level::before { width: 8px; height: 8px; border-radius: 50%; background: currentColor; box-shadow: 0 0 10px currentColor; content: ""; }
.risk-level[data-risk="elevated"] { color: #f0b84b; }
.risk-level[data-risk="high"] { color: #ff7181; }
.assessment-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; margin: 24px 0 0; overflow: hidden; border: 1px solid var(--line); border-radius: 10px; background: var(--line); }
.assessment-grid div { min-width: 0; padding: 16px; background: #0b1017; }
.assessment-grid dt { color: #718096; font-size: .7rem; text-transform: uppercase; letter-spacing: .07em; }
.assessment-grid dd { margin: 7px 0 0; overflow: hidden; color: var(--text); font-size: .91rem; font-weight: 650; text-overflow: ellipsis; white-space: nowrap; }
.signal-panel { margin-top: 24px; padding: 18px; border: 1px solid var(--line); border-radius: 10px; background: #0b1017; }
.signal-panel h2 { font-size: .88rem; }
.signal-panel ul { display: grid; gap: 9px; margin: 14px 0 0; padding: 0; list-style: none; }
.signal-panel li { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: .84rem; }
.signal-panel li > span { width: 7px; height: 7px; flex: 0 0 auto; border-radius: 50%; background: #65b3ff; }
.signal-panel li[data-severity="warning"] > span { background: #f0b84b; }
.signal-panel li[data-severity="high"] > span { background: #ff7181; }
.signal-panel p { margin-top: 12px; color: var(--muted); font-size: .84rem; }
.assessment-results form { margin-top: 24px; }
.result-assessment { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; margin-top: 28px; padding-top: 20px; border-top: 1px solid var(--line); color: var(--muted); font-size: .82rem; }
.result-assessment strong { color: var(--text); }
@keyframes scan-sweep { 0%, 100% { transform: translateY(-48px); opacity: .35; } 50% { transform: translateY(48px); opacity: 1; } }
@keyframes scan-pulse { 0%, 100% { transform: scale(.7); opacity: .45; } 50% { transform: scale(1.2); opacity: 1; } }
@keyframes assessment-enter { from { transform: translateY(10px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
.privacy-note { max-width: 620px; margin: 20px auto 0; font-size: .82rem; text-align: center; }
.dashboard { min-height: 100vh; }
.dash-top { display: flex; min-height: 76px; align-items: center; justify-content: space-between; gap: 24px; padding: 0 var(--gutter); border-bottom: 1px solid var(--line); }
.dash-top > div, .dash-top form { display: flex; align-items: center; gap: 16px; }
.plain-button { padding: 0; border: 0; background: transparent; color: var(--muted); cursor: pointer; }
.server-list { width: min(calc(100% - (2 * var(--gutter))), 1060px); margin: 0 auto; padding: clamp(64px, 9vw, 96px) 0; }
.server-list > p { color: var(--muted); }
.server-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 16px; margin-top: 40px; }
.server-card { display: grid; min-height: 180px; align-content: end; padding: 22px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); }
.server-card:hover { border-color: var(--line-strong); background: var(--panel-2); }
.server-card small { color: var(--muted); }
.empty-state { padding: 32px; border: 1px dashed var(--line-strong); border-radius: var(--radius); color: var(--muted); }
.dashboard-layout { display: grid; grid-template-columns: 250px minmax(0, 1fr); min-height: 100vh; }
.dash-sidebar { display: flex; flex-direction: column; padding: 24px 18px; border-right: 1px solid var(--line); background: #0b0f15; }
.guild-title { display: grid; margin: 42px 8px 18px; }
.guild-title small { color: var(--muted); }
.guild-title strong { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dash-sidebar nav { display: grid; gap: 3px; }
.dash-sidebar nav a { padding: 9px 10px; border-radius: 6px; color: var(--muted); font-size: .9rem; }
.dash-sidebar nav a:hover, .dash-sidebar nav a[aria-current="page"] { background: var(--panel-2); color: var(--text); }
.back-link { margin-top: auto; padding: 10px; color: var(--muted); font-size: .85rem; }
.dash-content { width: min(100%, 1100px); padding: clamp(36px, 5vw, 56px) clamp(24px, 6vw, 72px) 72px; }
.dash-content > header { display: flex; align-items: start; justify-content: space-between; gap: 20px; }
.dash-content h1 { margin: 18px 0 40px; text-transform: capitalize; }
.status-text { color: var(--muted); font-size: .78rem; text-transform: capitalize; }
.metric-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.metric-row article, .panel { padding: clamp(20px, 3vw, 26px); border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); }
.metric-row article { display: grid; gap: 10px; }
.metric-row small { color: var(--muted); }
.metric-row strong { text-transform: capitalize; }
.panel { margin-top: 14px; overflow-x: auto; }
.panel h2 { font-size: 1.25rem; letter-spacing: -.02em; }
.panel p { color: var(--muted); }
.form-help { margin: 8px 0 0; font-size: .88rem; }
.notice { margin: 24px 0; padding: 14px 16px; border-left: 4px solid var(--info); background: var(--panel); }
.notice-success { border-left-color: var(--success); color: var(--success); }
.settings-form { display: grid; max-width: 680px; gap: 9px; }
.settings-form label { margin-top: 13px; font-size: .88rem; font-weight: 650; }
.settings-form input:not(.combobox-input), .settings-form select { width: 100%; min-height: 44px; padding: 0 12px; border: 1px solid var(--line-strong); border-radius: 7px; background: var(--bg); color: var(--text); }
.settings-form .button { width: fit-content; margin-top: 22px; }
table { width: 100%; min-width: 620px; border-collapse: collapse; font-size: .9rem; }
th, td { padding: 13px 10px; border-bottom: 1px solid var(--line); text-align: left; }
th { color: var(--muted); font-weight: 600; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.review-actions { display: flex; gap: 6px; }
.review-actions button { padding: 6px 9px; border: 1px solid var(--line-strong); border-radius: 5px; background: var(--panel-2); color: var(--text); cursor: pointer; }
.review-actions button:last-child { color: var(--danger); }
.semantic-value { color: var(--info); font-weight: 700; text-transform: capitalize; }
.semantic-value[data-state="normal"], .semantic-value[data-state="ready"], .semantic-value[data-state="approved"], .semantic-value[data-state="completed"], .semantic-value[data-state="verified"], .semantic-value[data-state="low"] { color: var(--success); }
.semantic-value[data-state="elevated"], .semantic-value[data-state="needed"], .semantic-value[data-state="pending"], .semantic-value[data-state="received"], .semantic-value[data-state="in_progress"] { color: var(--warning); }
.semantic-value[data-state="raid"], .semantic-value[data-state="denied"], .semantic-value[data-state="declined"], .semantic-value[data-state="high"] { color: var(--danger); }
.skeleton-screen { position: fixed; z-index: 900; inset: 0; overflow: hidden; padding: clamp(76px, 12vw, 140px) var(--gutter); background: var(--bg); }
.skeleton-shell { width: min(100%, 900px); margin: 0 auto; }
.skeleton-block { display: block; border-radius: 6px; background: linear-gradient(100deg, #111821 20%, #18212d 45%, #111821 70%); background-size: 220% 100%; animation: skeleton-shift 1.35s ease-in-out infinite; }
.skeleton-line { width: 100%; height: 18px; margin-bottom: 18px; }
.skeleton-line-short { width: 22%; height: 12px; }
.skeleton-line-title { width: min(76%, 620px); height: clamp(42px, 7vw, 72px); margin: 28px 0; }
.skeleton-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 42px; }
.skeleton-grid span { min-height: 180px; }
@keyframes skeleton-shift { from { background-position: 100% 0; } to { background-position: -100% 0; } }

@media (max-width: 760px) {
  .dashboard-layout { grid-template-columns: 1fr; }
  .dash-sidebar { border-right: 0; border-bottom: 1px solid var(--line); }
  .dash-sidebar nav { grid-template-columns: repeat(4, minmax(120px, 1fr)); overflow-x: auto; }
  .guild-title { margin-top: 30px; }
  .back-link { margin-top: 16px; }
  .metric-row { grid-template-columns: 1fr; }
  .steps { margin: 52px 0; }
  .steps li { font-size: .68rem; }
  .docs-steps li { grid-template-columns: 1fr; gap: 4px; }
  .assessment-header { grid-template-columns: 1fr; }
  .risk-score { width: 100px; height: 100px; }
  .assessment-grid { grid-template-columns: 1fr 1fr; }
  .legal-list { grid-template-columns: 1fr; gap: 4px; }
  .legal-list dd { margin: 0 0 18px; }
  .skeleton-grid { grid-template-columns: 1fr; }
  .skeleton-grid span:nth-child(n+2) { display: none; }
}

@media (forced-colors: active) {
  .button, .steps li[aria-current="step"] span { border: 2px solid ButtonText; }
  .semantic-value { color: CanvasText; text-decoration: underline; text-decoration-style: double; }
  .risk-level, .risk-score { color: CanvasText; forced-color-adjust: auto; }
}

@media (max-width: 520px) {
  .site-header { min-height: 68px; }
  .site-header nav { gap: 10px; }
  .site-header .button-small { min-height: 36px; padding-inline: 12px; }
  .site-footer { min-height: 132px; align-items: flex-start; flex-direction: column; justify-content: center; }
  .site-footer nav { width: 100%; justify-content: space-between; gap: 14px; }
  .hero-actions { align-items: stretch; flex-direction: column; }
  .hero-actions .button { width: 100%; }
  .hero-actions .text-link { padding: 8px 0; text-align: center; }
  .assessment-grid { grid-template-columns: 1fr; }
  .risk-level-row { align-items: flex-start; flex-direction: column; }
  .flow-list li { grid-template-columns: 40px 1fr; gap: 14px; }
  .dash-top { min-height: 88px; align-items: flex-start; flex-direction: column; justify-content: center; gap: 8px; }
  .dash-content > header { display: block; }
  .dash-content h1 { margin-bottom: 18px; }
  .status-text { display: block; margin-bottom: 28px; }
}

/* Dashboard */
.dashboard-home { background: radial-gradient(circle at 50% -20%, #17223a 0, var(--bg) 36rem); }
.dash-top { position: sticky; z-index: 20; top: 0; min-height: 72px; padding-inline: max(var(--gutter), calc((100vw - var(--content)) / 2)); background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(18px); }
.account-menu { color: var(--muted); font-size: .9rem; }
.plain-button { min-height: 44px; padding-inline: 4px; font: inherit; }
.plain-button:hover { color: var(--text); }
.button-secondary { border-color: var(--line-strong); background: var(--panel); color: var(--text); }
.button-secondary:hover { border-color: var(--accent); background: var(--panel-2); }
.button:disabled { cursor: not-allowed; border-color: var(--line); background: var(--panel-2); color: var(--muted); }
.server-list { width: min(calc(100% - (2 * var(--gutter))), var(--content)); padding: clamp(48px, 7vw, 84px) 0 100px; }
.dashboard-heading { display: flex; align-items: end; justify-content: space-between; gap: 32px; padding-bottom: clamp(38px, 5vw, 58px); border-bottom: 1px solid var(--line); }
.dashboard-heading h1 { margin: 14px 0 14px; font-size: clamp(2.6rem, 6vw, 5.2rem); }
.dashboard-heading p:last-child { max-width: 620px; margin: 0; color: var(--muted); }
.server-group { padding-top: clamp(44px, 6vw, 68px); }
.server-group + .server-group { margin-top: clamp(18px, 3vw, 34px); border-top: 1px solid var(--line); }
.server-group-heading { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: 22px; }
.server-group-heading h2 { margin: 8px 0 0; font-size: clamp(1.45rem, 3vw, 2.15rem); letter-spacing: -.035em; }
.server-group-heading > span { color: var(--muted); font-size: .82rem; }
.server-grid { grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); gap: 12px; margin-top: 0; }
.server-card { display: grid; grid-template-columns: 52px minmax(0, 1fr) 42px; min-width: 0; min-height: 92px; align-items: center; align-content: initial; gap: 15px; padding: 18px; overflow: hidden; }
.server-card-connected { border-color: #2d3e5b; background: linear-gradient(145deg, #111a28, var(--panel)); }
.server-icon, .server-icon-fallback { display: grid; width: 52px; height: 52px; place-items: center; margin: 0; border-radius: 14px; object-fit: cover; background: #1b2430; color: var(--accent-strong); font-size: 1.1rem; font-weight: 750; }
.server-card-copy { display: grid; width: auto; min-width: 0; height: auto; margin: 0; gap: 3px; border-radius: 0; background: transparent; }
.server-card-copy strong, .server-card-copy small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.server-card-copy small { color: var(--muted); }
.server-arrow { display: grid; width: 42px; height: 42px; place-items: center; margin: 0; border-radius: 10px; background: #192230; color: var(--accent-strong); font-size: 1.15rem; transition: transform .15s ease, background .15s ease; }
.server-card:hover .server-arrow { color: var(--accent-strong); transform: translateX(2px); }
.server-card:focus-visible { border-color: var(--accent); }
.empty-state h3 { margin-bottom: 6px; color: var(--text); }
.empty-state p { margin: 0; }
.breadcrumbs { margin-bottom: 26px; color: var(--muted); font-size: .8rem; }
.breadcrumbs ol { display: flex; min-width: 0; flex-wrap: nowrap; align-items: center; gap: 0; margin: 0; padding: 0; list-style: none; }
.breadcrumbs li { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.breadcrumbs li + li::before { content: "/"; padding-inline: 9px; color: #59677a; }
.breadcrumbs a:hover { color: var(--text); }
.breadcrumbs [aria-current="page"] { color: var(--accent-strong); }

.dashboard-layout { grid-template-columns: 272px minmax(0, 1fr); background: linear-gradient(115deg, #0b1018 0, var(--bg) 32%); }
.dash-sidebar { position: sticky; top: 0; height: 100vh; padding: 26px 20px 22px; background: #0b0f15; }
.guild-title { display: grid; grid-template-columns: 44px minmax(0, 1fr); align-items: center; gap: 12px; margin: 44px 4px 24px; }
.guild-title > div { display: grid; min-width: 0; }
.guild-icon { display: grid; width: 44px; height: 44px; place-items: center; border-radius: 12px; object-fit: cover; background: var(--panel-2); color: var(--accent-strong); font-weight: 750; }
.guild-title small { font-size: .72rem; }
.dash-sidebar nav { gap: 5px; }
.dash-sidebar nav a { min-height: 42px; padding: 10px 12px; border-radius: 8px; }
.dash-sidebar nav a[aria-current="page"] { box-shadow: inset 2px 0 var(--accent); background: #141c29; color: var(--text); }
.dash-content { width: min(100%, 1180px); padding: clamp(42px, 5vw, 64px) clamp(24px, 6vw, 78px) 96px; }
.content-heading { min-height: 126px; padding-bottom: 28px; border-bottom: 1px solid var(--line); }
.dash-content .content-heading h1 { margin: 12px 0 0; font-size: clamp(2.5rem, 5vw, 4.5rem); }
.raid-state { margin: 4px 0 0; color: var(--muted); font-size: .82rem; }
.section-intro { max-width: 680px; margin: 28px 0 8px; color: var(--muted); font-size: 1.04rem; }
.section-row { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin: 34px 0 18px; }
.section-row h2 { margin: 8px 0 0; font-size: clamp(1.7rem, 3vw, 2.4rem); }
.metric-row { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.metric-row article { min-height: 124px; align-content: space-between; }
.metric-row strong { font-size: clamp(1.7rem, 3vw, 2.3rem); }
.panel { margin-top: 24px; border-color: #263142; box-shadow: 0 20px 60px rgb(0 0 0 / 12%); }
.setup-panel { display: grid; grid-template-columns: minmax(210px, .8fr) minmax(300px, 1.2fr); align-items: start; gap: 30px 50px; margin-top: 28px; }
.setup-panel .button { grid-column: 1; width: fit-content; }
.setup-checklist { grid-column: 2; grid-row: 1 / span 2; margin: 0; padding: 0; list-style: none; }
.setup-checklist li { display: grid; grid-template-columns: 34px minmax(0, 1fr); gap: 12px; padding: 15px 0; border-top: 1px solid var(--line); }
.setup-checklist li > span { display: grid; width: 28px; height: 28px; place-items: center; border: 1px solid var(--line-strong); border-radius: 8px; color: var(--muted); font: 700 .75rem/1 ui-monospace, monospace; }
.setup-checklist li[data-complete="true"] > span { border-color: #39654f; color: var(--success); }
.setup-checklist li div { display: grid; gap: 2px; }
.setup-checklist small { color: var(--muted); }
.settings-form { max-width: 760px; gap: 0; padding: clamp(24px, 4vw, 36px); }
.field-group { display: grid; gap: 7px; padding: 2px 0 24px; }
.field-group + .field-group { padding-top: 24px; border-top: 1px solid var(--line); }
.field-group label { margin: 0; font-weight: 700; }
.field-group p, .field-group small { margin: 0; color: var(--muted); font-size: .86rem; }
.settings-form input:not(.combobox-input), .settings-form select { margin-top: 5px; min-height: 48px; background: #0a0e14; }
.settings-form select { cursor: pointer; }
.combobox { position: relative; width: 100%; margin-top: 5px; }
.combobox[data-open="true"] { z-index: 50; }
.combobox-control { display: flex; width: 100%; height: 48px; align-items: center; overflow: hidden; border: 1px solid var(--line-strong); border-radius: 7px; background: #0a0e14; }
.combobox:focus-within .combobox-control { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
.settings-form .combobox-input { flex: 1 1 auto; width: 100%; min-width: 0; height: 46px; min-height: 0; margin: 0; padding: 0 12px; border: 0; border-radius: 0; outline: 0; background: transparent; box-shadow: none; color: var(--text); font: inherit; }
.combobox-input::placeholder { color: #6f7c8e; }
.combobox-leading { display: grid; flex: 0 0 34px; height: 46px; place-items: center; color: var(--muted); font-weight: 760; }
.combobox-leading-role::before, .combobox-option-marker-role::before { width: 11px; height: 11px; border: 1px solid rgb(255 255 255 / 16%); border-radius: 50%; background: var(--option-color); content: ""; }
.combobox-leading-channel, .combobox-option-marker-channel { color: var(--muted); font-weight: 760; }
.combobox-toggle { display: grid; flex: 0 0 42px; align-self: stretch; place-items: center; border: 0; border-left: 1px solid var(--line); background: transparent; color: var(--muted); cursor: pointer; }
.combobox-toggle::before { content: "⌄"; transform: translateY(-2px); font-size: 1rem; }
.combobox-listbox { position: absolute; z-index: 40; top: calc(100% + 6px); left: 0; right: 0; max-height: min(260px, 42svh); margin: 0; padding: 5px; overflow-x: hidden; overflow-y: auto; border: 1px solid var(--line-strong); border-radius: 9px; background: #0d1219; box-shadow: 0 18px 50px rgb(0 0 0 / 45%); }
.combobox-listbox[hidden] { display: none; }
.combobox-option { display: flex; width: 100%; min-height: 48px; align-items: center; justify-content: flex-start; gap: 10px; padding: 7px 10px; border-radius: 6px; color: var(--muted); cursor: pointer; }
.combobox-option-marker { display: grid; flex: 0 0 24px; width: 24px; height: 24px; place-items: center; }
.combobox-option-copy { display: grid; flex: 1 1 auto; min-width: 0; gap: 2px; text-align: left; }
.combobox-option-copy strong, .combobox-option-copy small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.combobox-option-copy strong { color: inherit; font-size: .84rem; font-weight: 650; }
.combobox-option-copy small { color: #718096; font-size: .7rem; }
.combobox-option[data-active="true"] { background: var(--panel-2); color: var(--text); }
.combobox-option[aria-selected="true"] { color: var(--accent-strong); }
.combobox-check { display: grid; flex: 0 0 20px; width: 20px; margin-left: auto; place-items: center; visibility: hidden; color: var(--success); }
.combobox-option[aria-selected="true"] .combobox-check { visibility: visible; }
.combobox-empty { padding: 14px 10px; color: var(--muted); font-size: .86rem; }
.threshold-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-top: 6px; }
.threshold-grid .field-group { padding: 0; border: 0; }
.form-warning { margin: 0 0 4px; padding: 13px 14px; border-left: 3px solid var(--warning); background: #19160f; color: var(--warning); font-size: .88rem; }
.compact-empty { margin-top: 18px; padding: 24px; }

@media (max-width: 900px) {
  .dashboard-layout { grid-template-columns: 218px minmax(0, 1fr); }
  .metric-row { grid-template-columns: repeat(2, 1fr); }
  .setup-panel { grid-template-columns: 1fr; }
  .setup-panel .button, .setup-checklist { grid-column: 1; grid-row: auto; }
  .threshold-grid { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  .dashboard-heading { align-items: start; flex-direction: column; }
  .dashboard-layout { display: block; }
  .dash-sidebar { position: static; height: auto; padding: 20px; }
  .guild-title { margin: 28px 0 18px; }
  .dash-sidebar nav { display: flex; margin-inline: -20px; padding: 0 20px 4px; overflow-x: auto; }
  .dash-sidebar nav { scrollbar-width: none; }
  .dash-sidebar nav::-webkit-scrollbar { display: none; }
  .dash-sidebar nav a { flex: 0 0 auto; }
  .back-link { display: inline-block; margin-top: 14px; }
  .dash-content { padding-top: 34px; }
  .content-heading { min-height: 0; }
}

@media (max-width: 520px) {
  .dash-top { position: static; }
  .account-menu { width: 100%; justify-content: space-between; }
  .account-menu .text-link { display: none; }
  .server-grid { grid-template-columns: 1fr; }
  .server-group-heading { align-items: start; flex-direction: column; gap: 8px; }
  .server-card { grid-template-columns: 46px minmax(0, 1fr) auto; padding: 15px; }
  .server-icon, .server-icon-fallback { width: 46px; height: 46px; border-radius: 12px; }
  .metric-row { grid-template-columns: 1fr 1fr; }
  .metric-row article { min-height: 106px; }
  .section-row { align-items: start; flex-direction: column; }
}
