:root {
  color-scheme: dark;
  --bg: #070b12;
  --bg-raised: #0c121d;
  --surface: #101824;
  --surface-strong: #151f2e;
  --surface-soft: #0b111b;
  --line: rgba(174, 197, 225, 0.14);
  --line-strong: rgba(174, 197, 225, 0.24);
  --text: #f3f7fb;
  --muted: #91a0b5;
  --faint: #657287;
  --accent: #32df9d;
  --accent-strong: #14c783;
  --accent-soft: rgba(50, 223, 157, 0.12);
  --cyan: #61c9ff;
  --yellow: #ffcf5c;
  --danger: #ff6d7e;
  --danger-soft: rgba(255, 109, 126, 0.12);
  --radius-sm: 8px;
  --radius: 13px;
  --radius-lg: 20px;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.28);
  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 { min-height: 100%; scroll-behavior: smooth; }
body { min-height: 100vh; margin: 0; background: var(--bg); color: var(--text); }
button, input, select, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; }
button { color: inherit; }
::selection { background: rgba(50, 223, 157, 0.28); }

.sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

.skip-link {
  position: fixed;
  z-index: 1000;
  top: 10px;
  left: 10px;
  transform: translateY(-160%);
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  background: var(--accent);
  color: #04120d;
  font-weight: 800;
}
.skip-link:focus { transform: translateY(0); }

.eyebrow {
  margin: 0 0 9px;
  color: var(--accent);
  font-size: 11px;
  font-weight: 850;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: var(--text);
  text-decoration: none;
}
.brand > span:last-child { display: grid; line-height: 1; }
.brand strong { font-size: 18px; letter-spacing: -.02em; }
.brand small { margin-top: 5px; color: var(--muted); font-size: 9px; font-weight: 800; letter-spacing: .22em; text-transform: uppercase; }
.brand-mark {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 1px solid rgba(50, 223, 157, .5);
  border-radius: 11px;
  background: linear-gradient(145deg, rgba(50, 223, 157, .22), rgba(50, 223, 157, .03));
  color: var(--accent);
  font-size: 17px;
  font-weight: 950;
  box-shadow: inset 0 0 20px rgba(50, 223, 157, .08);
}
.brand-large .brand-mark { width: 44px; height: 44px; font-size: 21px; }
.brand-large strong { font-size: 22px; }

.status-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--accent);
  box-shadow: 0 0 0 5px rgba(50, 223, 157, .09), 0 0 18px rgba(50, 223, 157, .65);
}

/* Login */
.login-page {
  overflow-x: hidden;
  background:
    radial-gradient(circle at 16% 18%, rgba(50, 223, 157, .10), transparent 27%),
    radial-gradient(circle at 83% 82%, rgba(97, 201, 255, .07), transparent 30%),
    var(--bg);
}
.login-layout { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(430px, .85fr); min-height: 100vh; }
.login-story {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 100vh;
  padding: clamp(34px, 5vw, 76px);
  border-right: 1px solid var(--line);
  overflow: hidden;
}
.login-story::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: .35;
  pointer-events: none;
  background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 62px 62px;
  mask-image: linear-gradient(135deg, black, transparent 68%);
}
.login-story > * { position: relative; z-index: 1; }
.story-copy { max-width: 770px; margin: clamp(70px, 12vh, 160px) 0 55px; }
.story-copy h1 { max-width: 750px; margin: 0; font-size: clamp(44px, 5.3vw, 82px); line-height: .98; letter-spacing: -.055em; }
.story-lead { max-width: 590px; margin: 30px 0 0; color: var(--muted); font-size: clamp(17px, 1.4vw, 21px); line-height: 1.55; }
.trust-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.trust-grid article { display: flex; gap: 14px; align-items: center; padding: 22px 20px 22px 0; }
.trust-grid article + article { padding-left: 20px; border-left: 1px solid var(--line); }
.trust-grid strong, .trust-grid small { display: block; }
.trust-grid strong { margin-bottom: 5px; font-size: 13px; }
.trust-grid small { color: var(--muted); font-size: 11px; }
.trust-number { color: var(--accent); font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 12px; }
.login-legal { margin: 25px 0 0; color: var(--faint); font-size: 11px; }
.login-access { display: grid; place-items: center; min-height: 100vh; padding: clamp(24px, 5vw, 70px); background: rgba(5, 8, 13, .5); }
.login-card { display: grid; gap: 23px; width: min(440px, 100%); }
.login-card-heading { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 12px; font-weight: 750; }
.login-card h2 { margin: 0; font-size: clamp(31px, 4vw, 46px); letter-spacing: -.045em; }
.login-card > div > p:last-child { margin: 12px 0 0; color: var(--muted); line-height: 1.55; }
.login-links { display: flex; justify-content: space-between; gap: 18px; padding-top: 18px; border-top: 1px solid var(--line); }
.login-links a { color: var(--muted); font-size: 12px; text-decoration: none; }
.login-links a:hover { color: var(--accent); }

/* Controls */
.field { display: grid; gap: 8px; }
.field > span:first-child { color: #b7c3d3; font-size: 11px; font-weight: 780; letter-spacing: .055em; text-transform: uppercase; }
input, select, textarea {
  width: 100%;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  outline: none;
  background: rgba(5, 9, 15, .82);
  color: var(--text);
  transition: border-color .16s ease, box-shadow .16s ease, background .16s ease;
}
input, select { min-height: 44px; padding: 0 12px; }
textarea { min-height: 94px; padding: 12px; resize: vertical; line-height: 1.5; }
input:focus, select:focus, textarea:focus { border-color: rgba(50, 223, 157, .65); background: #080e17; box-shadow: 0 0 0 3px rgba(50, 223, 157, .10); }
.input-action-wrap { position: relative; display: block; }
.input-action-wrap input { padding-right: 76px; }
.text-button { position: absolute; top: 50%; right: 12px; transform: translateY(-50%); border: 0; background: none; color: var(--accent); cursor: pointer; font-size: 11px; font-weight: 800; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 40px;
  padding: 0 15px;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: 12px;
  font-weight: 820;
  text-decoration: none;
  transition: transform .16s ease, filter .16s ease, border-color .16s ease, background .16s ease;
}
.button:hover { filter: brightness(1.08); transform: translateY(-1px); }
.button:active { transform: translateY(0); }
.button:disabled { cursor: not-allowed; filter: grayscale(.5); opacity: .55; transform: none; }
.button-primary { background: var(--accent); color: #04130d; box-shadow: 0 12px 28px rgba(20, 199, 131, .17); }
.button-secondary { border-color: var(--line-strong); background: rgba(255, 255, 255, .045); color: var(--text); }
.button-ghost { border-color: var(--line); background: transparent; color: var(--muted); }
.button-danger { background: var(--danger); color: #1a0609; }
.button-wide { width: 100%; justify-content: space-between; }
.login-card .button-wide { min-height: 50px; padding: 0 18px; }
.form-status { min-height: 18px; color: var(--muted); font-size: 12px; }
.form-status[data-tone="error"] { color: var(--danger); }
.form-status[data-tone="success"] { color: var(--accent); }
.field-hint, .panel-copy { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.5; }

/* App shell */
.app-shell { display: grid; grid-template-columns: 244px minmax(0, 1fr); min-height: 100vh; }
.sidebar {
  position: sticky;
  top: 0;
  display: flex;
  flex-direction: column;
  height: 100vh;
  padding: 25px 18px 18px;
  border-right: 1px solid var(--line);
  background: #080d15;
}
.sidebar .brand { padding: 0 8px 26px; }
.side-nav { display: grid; gap: 5px; margin-top: 15px; }
.nav-item {
  display: flex;
  align-items: center;
  gap: 13px;
  width: 100%;
  min-height: 45px;
  padding: 0 12px;
  border: 1px solid transparent;
  border-radius: 9px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  text-align: left;
  font-size: 12px;
  font-weight: 760;
}
.nav-item span { color: var(--faint); font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 9px; }
.nav-item:hover { background: rgba(255, 255, 255, .035); color: var(--text); }
.nav-item.is-active { border-color: rgba(50, 223, 157, .18); background: var(--accent-soft); color: var(--text); }
.nav-item.is-active span { color: var(--accent); }
.sidebar-footer { display: grid; gap: 14px; margin-top: auto; }
.api-live { display: flex; align-items: center; gap: 13px; padding: 15px 12px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.api-live strong, .api-live small { display: block; }
.api-live strong { font-size: 11px; }
.api-live small { margin-top: 4px; color: var(--faint); font-size: 10px; }
.app-main { min-width: 0; }
.topbar {
  position: sticky;
  z-index: 20;
  top: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 88px;
  padding: 17px clamp(20px, 3vw, 42px);
  border-bottom: 1px solid var(--line);
  background: rgba(7, 11, 18, .88);
  backdrop-filter: blur(18px);
}
.topbar h1 { margin: 0; font-size: 24px; letter-spacing: -.035em; }
.topbar .eyebrow { margin-bottom: 5px; }
.topbar-actions { display: flex; align-items: center; gap: 13px; }
.account-chip { display: flex; align-items: center; gap: 10px; min-width: 180px; padding-left: 13px; border-left: 1px solid var(--line); }
.account-chip > span, .account-avatar { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 10px; background: var(--accent-soft); color: var(--accent); font-weight: 900; }
.account-chip strong, .account-chip small { display: block; max-width: 155px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.account-chip strong { font-size: 11px; }
.account-chip small { margin-top: 4px; color: var(--faint); font-size: 10px; }
.content { width: min(1580px, 100%); margin: 0 auto; padding: 32px clamp(18px, 3vw, 42px) 70px; }
.view { display: none; animation: view-in .2s ease both; }
.view.is-active { display: block; }
@keyframes view-in { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: none; } }
.welcome-row, .section-intro { display: flex; align-items: end; justify-content: space-between; gap: 26px; margin-bottom: 24px; }
.welcome-row h2, .section-intro h2 { margin: 0; font-size: clamp(27px, 3vw, 40px); letter-spacing: -.045em; }
.welcome-row p:last-child, .section-intro p:last-child { max-width: 720px; margin: 10px 0 0; color: var(--muted); line-height: 1.55; }

/* Panels and metrics */
.metric-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.metric-card, .panel, .credential-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(160deg, rgba(18, 27, 41, .95), rgba(10, 16, 26, .95));
  box-shadow: inset 0 1px rgba(255, 255, 255, .025);
}
.metric-card { position: relative; min-height: 145px; padding: 19px; overflow: hidden; }
.metric-card::after { content: ""; position: absolute; right: -25px; bottom: -48px; width: 100px; height: 100px; border: 1px solid var(--line); border-radius: 50%; }
.metric-card span, .metric-card small { display: block; }
.metric-card > span { color: var(--muted); font-size: 11px; font-weight: 760; letter-spacing: .055em; text-transform: uppercase; }
.metric-card strong { display: block; margin-top: 24px; font-size: clamp(29px, 3vw, 39px); line-height: 1; letter-spacing: -.045em; }
.metric-card small { margin-top: 12px; color: var(--faint); font-size: 11px; }
.metric-accent { border-color: rgba(50, 223, 157, .28); background: linear-gradient(150deg, rgba(28, 57, 52, .9), rgba(10, 20, 24, .96)); }
.metric-accent strong { color: var(--accent); }
.dashboard-grid { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(350px, .92fr); gap: 14px; margin-top: 14px; }
.panel { margin-top: 14px; padding: 20px; }
.dashboard-grid .panel, .integration-grid .panel, .account-grid .panel { margin-top: 0; }
.panel-heading { display: flex; align-items: start; justify-content: space-between; gap: 16px; margin-bottom: 19px; }
.panel-heading h3 { margin: 0; font-size: 17px; letter-spacing: -.025em; }
.panel-heading .eyebrow { margin-bottom: 7px; }
.badge { display: inline-flex; align-items: center; min-height: 27px; padding: 0 9px; border: 1px solid var(--line-strong); border-radius: 999px; color: var(--muted); font-size: 9px; font-weight: 850; letter-spacing: .08em; text-transform: uppercase; }
.badge-live { border-color: rgba(50, 223, 157, .28); background: var(--accent-soft); color: var(--accent); }
.link-button, .copy-button, .filter-button, .icon-button { border: 0; background: none; color: var(--muted); cursor: pointer; }
.link-button, .copy-button { padding: 5px; color: var(--accent); font-size: 11px; font-weight: 800; }
.wallet-figure { display: flex; align-items: center; justify-content: space-between; gap: 25px; padding: 5px 0 20px; }
.wallet-figure span, .wallet-figure small { display: block; }
.wallet-figure span { color: var(--muted); font-size: 11px; }
.wallet-figure strong { display: block; margin: 7px 0; font-size: 39px; letter-spacing: -.04em; }
.wallet-figure small { color: var(--faint); font-size: 11px; }
.donut { --percent: 0; display: grid; place-items: center; width: 105px; height: 105px; flex: 0 0 105px; border-radius: 50%; background: conic-gradient(var(--accent) calc(var(--percent) * 1%), rgba(255,255,255,.07) 0); position: relative; }
.donut::after { content: ""; position: absolute; inset: 10px; border-radius: 50%; background: var(--surface); }
.donut span { position: relative; z-index: 1; color: var(--text); font-size: 18px; font-weight: 900; }
.progress { height: 5px; border-radius: 999px; overflow: hidden; background: rgba(255,255,255,.07); }
.progress span { display: block; height: 100%; width: 0; border-radius: inherit; background: linear-gradient(90deg, var(--accent), var(--cyan)); transition: width .35s ease; }
.wallet-legend { display: flex; justify-content: space-between; gap: 12px; margin-top: 14px; }
.wallet-legend span { display: flex; align-items: center; gap: 7px; color: var(--muted); font-size: 11px; }
.wallet-legend strong { margin-left: 4px; color: var(--text); }
.legend-dot { width: 7px; height: 7px; border-radius: 50%; }
.legend-dot.available { background: var(--accent); }
.legend-dot.locked { background: var(--yellow); }
.purchase-callout { display: flex; align-items: center; justify-content: space-between; gap: 15px; margin-top: 20px; padding: 15px; border: 1px solid var(--line); border-radius: 10px; background: rgba(255,255,255,.025); }
.purchase-callout strong, .purchase-callout small { display: block; }
.purchase-callout strong { font-size: 12px; }
.purchase-callout small { max-width: 460px; margin-top: 5px; color: var(--muted); font-size: 10px; line-height: 1.45; }
.timeline { display: grid; gap: 2px; }
.timeline-item { position: relative; display: grid; grid-template-columns: 9px minmax(0, 1fr) auto; gap: 12px; align-items: start; padding: 10px 0; }
.timeline-item + .timeline-item { border-top: 1px solid var(--line); }
.timeline-marker { width: 7px; height: 7px; margin-top: 5px; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 12px rgba(97, 201, 255, .4); }
.timeline-item strong, .timeline-item small { display: block; }
.timeline-item strong { font-size: 11px; }
.timeline-item small { margin-top: 5px; color: var(--faint); font-size: 10px; }
.timeline-item time { color: var(--faint); font-size: 9px; white-space: nowrap; }

/* Tables */
.table-panel { padding: 0; overflow: hidden; }
.table-wrap { width: 100%; overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 11px; }
th { padding: 12px 14px; border-bottom: 1px solid var(--line); color: var(--faint); background: rgba(255,255,255,.02); font-size: 9px; letter-spacing: .1em; text-align: left; text-transform: uppercase; white-space: nowrap; }
td { padding: 13px 14px; border-bottom: 1px solid rgba(174,197,225,.08); color: #c8d2df; white-space: nowrap; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover td { background: rgba(255,255,255,.018); }
td strong { color: var(--text); }
.mono { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; }
.table-empty { padding: 34px !important; color: var(--muted); text-align: center; }
.status-pill { display: inline-flex; align-items: center; min-height: 23px; padding: 0 8px; border-radius: 999px; background: rgba(145,160,181,.12); color: var(--muted); font-size: 9px; font-weight: 850; text-transform: uppercase; }
.status-pill.active { background: var(--accent-soft); color: var(--accent); }
.status-pill.expired { background: rgba(255,207,92,.11); color: var(--yellow); }
.table-action { min-height: 29px; padding: 0 9px; border: 1px solid var(--line); border-radius: 6px; background: rgba(255,255,255,.03); color: var(--muted); cursor: pointer; font-size: 9px; font-weight: 800; }
.positive { color: var(--accent); font-weight: 800; }
.negative { color: var(--danger); font-weight: 800; }

/* Integration */
.doc-actions, .form-actions, .filter-group { display: flex; flex-wrap: wrap; gap: 8px; }
.credential-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.credential-card { position: relative; min-width: 0; padding: 17px; }
.credential-card > span { display: block; margin-bottom: 15px; color: var(--faint); font-size: 9px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.credential-card code { display: block; padding-right: 45px; overflow: hidden; color: var(--text); font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.credential-card .copy-button { position: absolute; right: 12px; bottom: 12px; }
.credential-secret { border-color: rgba(255, 207, 92, .22); }
.credential-secret code { color: var(--yellow); }
.security-note { margin: 12px 0 0; padding: 12px 14px; border-left: 2px solid var(--yellow); background: rgba(255,207,92,.055); color: var(--muted); font-size: 11px; line-height: 1.5; }
.security-note strong { color: var(--yellow); }
.integration-grid { display: grid; grid-template-columns: minmax(0, 1.12fr) minmax(340px, .88fr); gap: 14px; margin-top: 14px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 13px; }
.field-span-2 { grid-column: 1 / -1; }
.form-actions { margin: 16px 0; }
.code-panel pre { max-width: 100%; margin: 0; padding: 16px; overflow: auto; border: 1px solid var(--line); border-radius: 9px; background: #060a10; color: var(--yellow); font-size: 10px; line-height: 1.65; }
.endpoint-list { display: grid; gap: 0; margin: 15px 0; border-top: 1px solid var(--line); }
.endpoint-list > div { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.endpoint-list code { color: var(--cyan); font-size: 10px; }
.endpoint-list span { color: var(--muted); font-size: 10px; text-align: right; }

/* Catalog */
.search-field { width: min(330px, 100%); }
.catalog-summary { display: flex; justify-content: space-between; gap: 15px; margin-bottom: 13px; color: var(--muted); font-size: 11px; }
.games-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.game-card { min-width: 0; padding: 15px; border: 1px solid var(--line); border-radius: 11px; background: linear-gradient(150deg, rgba(17,26,39,.92), rgba(10,15,24,.92)); }
.game-number { color: var(--accent); font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 9px; }
.game-card h3 { margin: 17px 0 7px; overflow: hidden; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.game-card code { display: block; overflow: hidden; color: var(--faint); font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.game-card footer { display: flex; justify-content: space-between; gap: 10px; margin-top: 17px; padding-top: 11px; border-top: 1px solid var(--line); color: var(--muted); font-size: 9px; text-transform: uppercase; }
.empty-state { margin: 0; padding: 24px; color: var(--muted); text-align: center; }
.filter-button { min-height: 34px; padding: 0 12px; border: 1px solid var(--line); border-radius: 999px; font-size: 10px; font-weight: 760; }
.filter-button.is-active { border-color: rgba(50,223,157,.3); background: var(--accent-soft); color: var(--accent); }

/* Account */
.account-grid { display: grid; grid-template-columns: minmax(280px, .78fr) minmax(330px, 1.1fr) minmax(330px, 1.1fr); gap: 14px; align-items: start; }
.definition-list { display: grid; margin: 0; }
.definition-list div { display: flex; justify-content: space-between; gap: 15px; padding: 13px 0; border-bottom: 1px solid var(--line); }
.definition-list div:last-child { border-bottom: 0; }
.definition-list dt { color: var(--muted); font-size: 10px; }
.definition-list dd { max-width: 65%; margin: 0; overflow-wrap: anywhere; font-size: 10px; font-weight: 750; text-align: right; }
.account-grid form { display: grid; gap: 14px; }

/* Dialog and feedback */
.dialog { width: min(480px, calc(100vw - 30px)); padding: 0; border: 1px solid var(--line-strong); border-radius: var(--radius-lg); background: #0d1420; color: var(--text); box-shadow: var(--shadow); }
.dialog::backdrop { background: rgba(2,5,9,.76); backdrop-filter: blur(5px); }
.dialog form { display: grid; gap: 18px; padding: 24px; }
.dialog-heading { display: flex; justify-content: space-between; gap: 20px; }
.dialog h2 { margin: 0; font-size: 24px; }
.dialog p:not(.eyebrow) { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.6; }
.icon-button { min-width: 36px; min-height: 36px; border: 1px solid var(--line); border-radius: 8px; }
.toast-region { position: fixed; z-index: 200; right: 20px; bottom: 20px; display: grid; gap: 8px; width: min(380px, calc(100vw - 40px)); }
.toast { padding: 13px 15px; border: 1px solid var(--line-strong); border-left: 3px solid var(--accent); border-radius: 9px; background: #121b28; box-shadow: var(--shadow); color: var(--text); font-size: 11px; animation: toast-in .2s ease both; }
.toast.error { border-left-color: var(--danger); }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } }
.mobile-only { display: none; }

@media (max-width: 1240px) {
  .metric-grid, .credential-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .games-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .account-grid { grid-template-columns: 1fr 1fr; }
  .account-summary-card { grid-column: 1 / -1; }
}

@media (max-width: 980px) {
  .login-layout { grid-template-columns: 1fr; }
  .login-story { min-height: auto; padding-bottom: 38px; border-right: 0; border-bottom: 1px solid var(--line); }
  .story-copy { margin: 80px 0 45px; }
  .login-access { min-height: auto; padding-top: 55px; padding-bottom: 70px; }
  .app-shell { grid-template-columns: 1fr; }
  .sidebar { position: fixed; z-index: 50; width: 250px; transform: translateX(-105%); transition: transform .22s ease; box-shadow: 30px 0 70px rgba(0,0,0,.4); }
  .app-shell.menu-open .sidebar { transform: translateX(0); }
  .mobile-only { display: inline-flex; }
  .topbar { min-height: 78px; }
  .dashboard-grid, .integration-grid { grid-template-columns: 1fr; }
  .games-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 680px) {
  .login-story { padding: 28px 22px; }
  .story-copy { margin: 66px 0 40px; }
  .story-copy h1 { font-size: 42px; }
  .trust-grid { grid-template-columns: 1fr; }
  .trust-grid article + article { padding-left: 0; border-top: 1px solid var(--line); border-left: 0; }
  .login-access { padding: 45px 22px 60px; }
  .topbar { align-items: center; padding: 14px 15px; }
  .topbar > div:nth-child(2) { display: none; }
  .topbar-actions { margin-left: auto; }
  .topbar-actions > .button { display: none; }
  .account-chip { min-width: 0; border-left: 0; padding-left: 0; }
  .account-chip div { display: none; }
  .content { padding: 24px 14px 55px; }
  .welcome-row, .section-intro { align-items: stretch; flex-direction: column; }
  .metric-grid, .credential-grid, .games-grid, .account-grid, .form-grid { grid-template-columns: 1fr; }
  .field-span-2, .account-summary-card { grid-column: auto; }
  .metric-card { min-height: 125px; }
  .metric-card strong { margin-top: 19px; }
  .wallet-figure { align-items: flex-start; }
  .donut { width: 88px; height: 88px; flex-basis: 88px; }
  .wallet-legend, .purchase-callout { align-items: stretch; flex-direction: column; }
  .doc-actions .button { flex: 1; }
  .catalog-summary { flex-direction: column; }
}

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