:root {
  --bg: #12161c;
  --bg-2: #181d25;
  --panel: rgba(32, 38, 48, 0.86);
  --panel-edge: rgba(170, 182, 200, 0.18);
  --line: rgba(170, 182, 200, 0.18);
  --line-strong: rgba(170, 182, 200, 0.32);
  --inset: rgba(16, 20, 27, 0.7);
  --text: #eef2f7;
  --text-dim: #a8b4c6;
  --text-faint: #7e8b9c;
  --muted: #a8b4c6;
  --accent: #d6dce6;
  --accent-dim: rgba(214, 220, 228, 0.14);
  --cream: #d6dce6;
  --bone: #d6dce6;
  --good: #4de1c1;
  --mark: #4de1c1;
  --buy: #4de1c1;
  --buy-dim: rgba(77, 225, 193, 0.12);
  --sell: #ffb545;
  --sell-dim: rgba(255, 181, 69, 0.12);
  --discord: #5865f2;
  --discord-bg: #313338;
  --discord-chat: #2b2d31;
  --font: "Segoe UI Variable Text", "Segoe UI", Inter, system-ui, sans-serif;
  --radius: 14px;
  --radius-sm: 9px;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --rail: 220px;
}

* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  height: 100%;
  margin: 0;
  overflow: hidden;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
p {
  margin: 0;
}

h1,
h2,
h3 {
  font-weight: 600;
}

h2 {
  font-size: 28px;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

h3 {
  font-size: 16px;
}

button,
input,
select {
  font: inherit;
  color: inherit;
}

.starfield {
  position: fixed;
  inset: 0;
  overflow: hidden;
  z-index: 0;
  pointer-events: none;
}

.starfield span {
  position: absolute;
  border-radius: 50%;
  opacity: 0.5;
}

.starfield span:nth-child(1) {
  width: 46vw;
  height: 46vw;
  left: -8vw;
  top: -12vw;
  background: radial-gradient(circle, rgba(77, 225, 193, 0.1), transparent 68%);
}

.starfield span:nth-child(2) {
  width: 38vw;
  height: 38vw;
  right: -6vw;
  top: 24vh;
  background: radial-gradient(circle, rgba(170, 182, 200, 0.08), transparent 68%);
}

.starfield span:nth-child(3) {
  width: 34vw;
  height: 34vw;
  left: 32vw;
  bottom: -14vw;
  background: radial-gradient(circle, rgba(170, 182, 200, 0.06), transparent 70%);
}

.shell {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: var(--rail) minmax(0, 1fr);
  height: 100%;
  max-height: 100%;
  overflow: hidden;
}

.rail {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 16px 12px;
  border-right: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(24, 29, 38, 0.94), rgba(16, 20, 27, 0.84));
  backdrop-filter: blur(14px);
  min-height: 0;
  overflow: auto;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 8px 18px;
  color: var(--text);
  text-decoration: none;
}

.brand-mark {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  object-fit: cover;
  background: #000;
  flex: none;
}

.brand-text {
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: 12px;
  line-height: 1.25;
  max-width: 11.5em;
}

.rail-links {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.rail-group {
  display: grid;
  gap: 3px;
}

.rail-kicker {
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-faint);
  padding: 2px 11px 4px;
}

.rail-foot {
  margin-top: auto;
  padding: 16px 0 6px;
  display: grid;
  gap: 5px;
}

.rail-contact {
  text-decoration: none;
  color: var(--text);
}

.rail-contact .ico svg {
  fill: currentColor;
  stroke: none;
}

.sync-stamp {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  color: var(--text-dim);
}

.sync-stamp time {
  text-align: right;
  line-height: 1.3;
}

.sync-stamp span {
  color: var(--text-faint);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.rail-link {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 9px 11px;
  border-radius: var(--radius-sm);
  background: transparent;
  border: 1px solid transparent;
  cursor: pointer;
  color: var(--text-dim);
  text-align: left;
  width: 100%;
  transition: background 0.18s var(--ease), color 0.18s var(--ease);
}

.rail-link:hover {
  background: rgba(126, 152, 190, 0.1);
  color: var(--text);
}

.rail-link.on {
  background: linear-gradient(90deg, rgba(214, 220, 228, 0.14), rgba(214, 220, 228, 0.02));
  border-color: rgba(214, 220, 228, 0.32);
  color: var(--text);
}

.rail-label {
  font-size: 13px;
}

.ico {
  width: 18px;
  height: 18px;
  display: inline-grid;
  place-items: center;
  flex: none;
  color: currentColor;
}

.ico svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.main {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  height: 100%;
  overflow: hidden;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 20px;
  border-bottom: 1px solid var(--line);
  min-height: 58px;
}

.crumbs-text {
  min-width: 0;
}

.crumbs h2 {
  font-size: 18px;
  line-height: 1.25;
}

.crumbs p {
  color: var(--text-faint);
  font-size: 12.5px;
  margin-top: 2px;
}

.topbar-right,
#session-slot {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
}

.page-scroll {
  flex: 1 1 auto;
  min-width: 0;
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
  padding: 18px 20px 48px;
}

.page-scroll::-webkit-scrollbar {
  width: 10px;
}

.page-scroll::-webkit-scrollbar-track {
  background: rgba(126, 152, 190, 0.06);
}

.page-scroll::-webkit-scrollbar-thumb {
  background: var(--line-strong);
  border-radius: 10px;
}

#session-slot .err-code {
  margin: 0;
}

.session-actions {
  flex-wrap: wrap;
  justify-content: flex-end;
}

.kicker {
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 10px;
}

#session-slot .err-code {
  margin: 0;
}

.session {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 4px 10px 4px 4px;
  border: 1px solid var(--line);
  background: var(--panel);
  border-radius: 20px;
}

.session-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 2px;
  min-width: 0;
  line-height: 1.15;
}

.session strong {
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
}

.session-out {
  appearance: none;
  border: 0;
  background: none;
  padding: 0;
  color: var(--muted);
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.1;
  text-decoration: none;
}

.session-out:hover {
  color: var(--cream);
}

.session-avatar {
  width: 36px;
  height: 36px;
  object-fit: cover;
  border-radius: 50%;
  flex: 0 0 auto;
}

.linkish,
a.linkish:visited {
  appearance: none;
  border: 0;
  background: none;
  color: var(--muted);
  cursor: pointer;
  padding: 0;
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.15s var(--ease);
}

.linkish:hover {
  color: var(--text);
}

.view {
  display: block;
}

.view.view-in {
  animation: view-in 0.38s var(--ease);
}

.hero {
  max-width: 40rem;
  margin-bottom: 22px;
}

.hero h2 {
  font-size: 28px;
  letter-spacing: -0.02em;
  line-height: 1.2;
  color: var(--text);
}

.hero p,
.intro p,
.lead {
  margin-top: 12px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.6;
}

.intro {
  max-width: 34rem;
  margin-bottom: 28px;
}

.outline {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 22px;
}

.outline-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 18px;
  backdrop-filter: blur(12px);
}

.outline-card:nth-child(2) {
  animation-delay: 0.06s;
}

.outline-card:nth-child(3) {
  animation-delay: 0.12s;
}

.outline-card h3 {
  margin: 10px 0 8px;
}

.outline-card p {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
}

.outline-mark {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: 999px;
}

.buy-mark {
  color: var(--buy);
  background: var(--buy-dim);
}

.sell-mark {
  color: var(--sell);
  background: var(--sell-dim);
}

.accent-mark {
  color: var(--accent);
  background: var(--accent-dim);
}

.steps {
  list-style: none;
  margin: 0 0 28px;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  counter-reset: step;
}

.steps li {
  position: relative;
  padding: 4px 4px 4px 42px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
}

.steps li strong {
  display: block;
  color: var(--text);
  margin-bottom: 4px;
}

.steps li::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  left: 0;
  top: 2px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(214, 220, 228, 0.16);
  color: var(--text);
  box-shadow: 0 0 0 1px rgba(214, 220, 228, 0.32);
  font-size: 13px;
  font-weight: 800;
  display: grid;
  place-items: center;
}

.rates-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.rates-head .lead {
  margin-top: 6px;
  font-size: 14px;
}

.trade-card {
  max-width: 520px;
}

.view.is-hidden,
.is-hidden {
  display: none !important;
}

.window,
.card,
.outline-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 18px;
  backdrop-filter: blur(12px);
}

.rates-card {
  animation-delay: 0.08s;
}

.titlebar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 16px;
  border-bottom: 1px solid var(--panel-edge);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--accent);
  position: relative;
  overflow: hidden;
}

.titlebar::after {
  content: "";
  position: absolute;
  inset: 0 auto 0 -30%;
  width: 30%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.06), transparent);
  animation: sweep 5s var(--ease) infinite;
}

.titlebar > * {
  position: relative;
  z-index: 1;
}

.titlebar-meta,
.hint,
.quote {
  color: var(--muted);
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0;
}

.quote {
  margin: 12px 0 0;
}

.quote.is-fresh {
  animation: quote-flash 0.5s var(--ease);
}

.window-body {
  padding: 16px 16px 18px;
}

.gate {
  display: grid;
  gap: 12px;
  max-width: 36rem;
}

.gate-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.gate h3 {
  color: var(--accent);
  font-size: 14px;
  font-weight: 600;
}

.gate p {
  color: var(--muted);
}

.setup {
  margin: 0;
  padding-left: 1.15rem;
  color: var(--muted);
  display: grid;
  gap: 6px;
}

.setup a,
.setup code {
  color: var(--text);
}

.setup code {
  font-size: 12px;
}

.err-code,
.err-hero {
  margin: 0;
  color: var(--sell);
  font-weight: 600;
  letter-spacing: 0.04em;
  font-variant-numeric: tabular-nums;
}

.err-code {
  font-size: 14px;
}

.err-hero {
  font-size: 72px;
  line-height: 1;
  letter-spacing: -0.04em;
}

.auth-error {
  color: var(--sell);
}

.sides,
.admin-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3px;
  margin-bottom: 18px;
  padding: 3px;
  border-radius: 11px;
  border: 1px solid var(--line-strong);
  background: var(--panel);
}

.admin-tabs {
  grid-template-columns: 1fr 1fr 1fr;
  max-width: 420px;
}

.side {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--text-dim);
  padding: 8px 10px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  border-radius: 8px;
  transition: color 0.16s var(--ease), background 0.16s var(--ease);
}

.side:hover {
  color: var(--text);
  background: rgba(126, 152, 190, 0.1);
}

.side.is-on {
  color: var(--text);
  background: rgba(214, 220, 228, 0.16);
  box-shadow: 0 0 0 1px rgba(214, 220, 228, 0.32);
}

.form {
  display: grid;
  gap: 0;
}

.eve-row {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.eve-row span {
  font-size: 13px;
  color: var(--muted);
}

.eve-row input,
.eve-row select {
  width: 100%;
  background: var(--inset);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text);
  padding: 8px 10px;
  outline: none;
  border-radius: var(--radius-sm);
  transition: border-color 0.18s var(--ease), box-shadow 0.18s var(--ease);
}

.eve-row input:focus,
.eve-row select:focus {
  border-color: rgba(94, 180, 232, 0.55);
  box-shadow: 0 0 0 3px rgba(94, 180, 232, 0.16);
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 18px;
}

.btn {
  appearance: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 10px;
  cursor: pointer;
  border: 1px solid var(--line-strong);
  background: var(--panel);
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.14s var(--ease), border-color 0.14s var(--ease);
}

.btn:hover {
  background: rgba(126, 152, 190, 0.12);
}

.btn-primary {
  background: rgba(77, 225, 193, 0.1);
  border-color: rgba(77, 225, 193, 0.42);
  color: var(--text);
}

.btn-primary:hover {
  background: rgba(77, 225, 193, 0.18);
}

.foot {
  margin-top: 48px;
  padding-top: 18px;
  border-top: 1px solid var(--panel-edge);
  color: var(--muted);
  font-size: 12px;
}

.btn-discord {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  padding: 8px 14px;
  border: 1px solid rgba(88, 101, 242, 0.45);
  border-radius: 10px;
  background: rgba(88, 101, 242, 0.16);
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
}

.btn-discord svg {
  width: 18px;
  height: 18px;
}

.btn-discord:hover {
  background: rgba(88, 101, 242, 0.24);
}

.success {
  display: grid;
  gap: 10px;
  animation: rise 0.35s var(--ease);
}

.success h3 {
  color: var(--accent);
  font-size: 14px;
}

.success p {
  color: var(--muted);
}

.empty-history {
  color: var(--muted);
  font-size: 13px;
}

.journal-page {
  display: grid;
  gap: 16px;
}

#view-history .intro {
  margin-bottom: 18px;
}

#view-history .card {
  padding: 18px 18px 16px;
}

.journal-wrap h3,
.split h3 {
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 10px;
}

.journal-scroll {
  overflow-x: auto;
  border: 1px solid var(--panel-edge);
  border-radius: var(--radius);
  background: var(--inset);
}

.journal {
  width: 100%;
  border-collapse: collapse;
  min-width: 820px;
}

.journal th,
.journal td {
  text-align: left;
  padding: 10px 12px;
  font-size: 12px;
  white-space: nowrap;
}

.journal th {
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 600;
  font-size: 11px;
  background: rgba(255, 255, 255, 0.03);
  border-bottom: 1px solid var(--panel-edge);
}

.journal td {
  color: var(--text);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.journal tbody tr:last-child td {
  border-bottom: 0;
}

.journal tbody tr {
  transition: background 0.22s var(--ease), box-shadow 0.22s var(--ease);
}

.journal tbody tr:nth-child(even) {
  background: rgba(255, 255, 255, 0.02);
}

.journal tbody tr:hover {
  background: rgba(143, 184, 204, 0.09);
  box-shadow: inset 3px 0 0 var(--accent);
}

.status-pill {
  display: inline-block;
  padding: 2px 7px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.02em;
  background: var(--accent-dim);
  color: var(--accent);
}

.status-pill.status-complete,
.status-pill.status-completed {
  background: var(--buy-dim);
  color: var(--buy);
}

.status-pill.status-new,
.status-pill.status-open,
.status-pill.status-pending {
  background: var(--accent-dim);
  color: var(--accent);
}

.status-pill.status-declined {
  background: rgba(139, 147, 154, 0.16);
  color: var(--muted);
}

.side-buy {
  color: var(--buy);
}

.side-sell {
  color: var(--sell);
}

.catalog {
  width: 100%;
  border-collapse: collapse;
}

.catalog th,
.catalog td {
  text-align: left;
  padding: 7px 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  font-size: 13px;
}

.catalog th {
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.catalog th:nth-child(2) {
  color: var(--buy);
}

.catalog th:nth-child(3) {
  color: var(--sell);
}

.catalog tbody tr {
  cursor: pointer;
  transition: background 0.22s var(--ease), box-shadow 0.22s var(--ease);
}

.catalog tbody tr:hover {
  background: rgba(94, 180, 232, 0.1);
  box-shadow: inset 3px 0 0 var(--accent);
}

.col-buy {
  color: var(--buy);
  font-weight: 600;
}

.col-sell {
  color: var(--sell);
  font-weight: 600;
}

.catalog td:nth-child(2),
.catalog td:nth-child(3),
.journal td:nth-child(3),
.journal td:nth-child(4),
.journal td:nth-child(5) {
  font-variant-numeric: tabular-nums;
}

.admin-tabs {
  margin-bottom: 16px;
}

.pending-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 10px;
}

.pending-toolbar .admin-tabs {
  margin-bottom: 0;
}

.side-filter {
  max-width: none;
  grid-template-columns: repeat(auto-fit, minmax(72px, 1fr));
}

.pending-count {
  margin: 0 0 14px;
  color: var(--muted);
}

.pending-wrap {
  margin-bottom: 18px;
}

.order-list {
  display: grid;
  gap: 10px;
}

.order-card {
  background: var(--inset);
  border: 1px solid var(--panel-edge);
  border-radius: var(--radius-sm);
  padding: 12px 14px 10px;
}

.order-card-top,
.order-card-grid {
  display: grid;
  gap: 8px;
}

.order-card-top {
  grid-template-columns: 88px minmax(0, 1fr) 120px auto;
  align-items: center;
  margin-bottom: 10px;
}

.order-card-grid {
  grid-template-columns: 1fr 1fr;
}

.order-card-grid label {
  display: grid;
  gap: 4px;
  font-size: 11px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}

.order-card-grid strong,
.order-type {
  color: var(--text);
  font-size: 14px;
  font-weight: 600;
  text-transform: none;
  letter-spacing: 0;
}

.order-card .order-side {
  font-size: 14px;
}

.order-card select {
  width: 100%;
  background: rgba(8, 11, 14, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text);
  padding: 7px 8px;
  border-radius: 8px;
}

.order-card .order-side.side-buy {
  color: var(--buy);
}

.order-card .order-side.side-sell {
  color: var(--sell);
}

.order-card select.order-status.status-pending {
  color: var(--accent);
}

.order-card select.order-status.status-complete {
  color: var(--buy);
}

.order-card select.order-status.status-declined {
  color: var(--muted);
}

.order-card-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 8px;
  color: var(--muted);
  font-size: 12px;
}

.btn-contact {
  padding: 7px 12px;
  font-size: 12px;
  white-space: nowrap;
}

.btn:disabled,
.btn-contact:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

@media (max-width: 800px) {
  .order-card-top,
  .order-card-grid {
    grid-template-columns: 1fr 1fr;
  }

  .order-card-top {
    grid-template-columns: 1fr 1fr;
  }
}

.admin-table tbody tr,
.admin-table tbody tr:hover {
  cursor: default;
  background: transparent;
  box-shadow: none;
}

.admin-table input {
  width: 100%;
  background: var(--inset);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text);
  padding: 6px 8px;
  border-radius: 6px;
}

.inventory-stats {
  margin-bottom: 16px;
}

.inventory-stats .stat:nth-child(3) {
  border-color: rgba(138, 164, 181, 0.22);
}

.inv-chart {
  margin-bottom: 18px;
}

.inv-chart .chart-card,
.inv-chart .chart-card:first-child,
.inv-chart .chart-card:last-child {
  border-color: rgba(138, 164, 181, 0.2);
}

.inventory-table th:nth-child(2),
.inventory-table th:nth-child(3),
.inventory-table th:nth-child(4) {
  color: var(--muted);
}

.inventory-table td:nth-child(2),
.inventory-table td:nth-child(3),
.inventory-table td:nth-child(4) {
  font-variant-numeric: tabular-nums;
}

.stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.stat {
  background: var(--inset);
  border: 1px solid var(--panel-edge);
  border-radius: var(--radius);
  padding: 12px;
  transition: transform 0.22s var(--ease), border-color 0.22s var(--ease);
}

.stat:hover {
  transform: translateY(-2px);
}

.stat:nth-child(1) {
  border-color: rgba(143, 188, 138, 0.22);
}

.stat:nth-child(2) {
  border-color: rgba(212, 162, 122, 0.22);
}

.stat span {
  display: block;
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.stat strong {
  display: block;
  font-size: 20px;
}

.stat em {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-style: normal;
  font-size: 12px;
}

.dash-charts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.chart-card {
  background: var(--inset);
  border: 1px solid var(--panel-edge);
  border-radius: var(--radius);
  padding: 14px 16px 16px;
  transition: transform 0.22s var(--ease), border-color 0.22s var(--ease);
}

.chart-card:hover {
  transform: translateY(-2px);
}

.chart-card:first-child {
  border-color: rgba(143, 188, 138, 0.2);
}

.chart-card:last-child {
  border-color: rgba(212, 162, 122, 0.2);
}

.chart-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.chart-head h3 {
  margin: 0;
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.chart-head strong {
  font-size: 15px;
}

.chart-body {
  display: grid;
  grid-template-columns: 168px minmax(0, 1fr);
  gap: 16px;
  align-items: center;
}

.donut-wrap {
  width: 168px;
  height: 168px;
}

.donut {
  width: 168px;
  height: 168px;
  transform-origin: 50% 50%;
  animation: donut-pop 0.55s var(--ease) both;
}

.donut-track {
  stroke: rgba(255, 255, 255, 0.08);
}

.chart-legend {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}

.chart-legend li {
  display: grid;
  grid-template-columns: 8px minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  font-size: 13px;
}

.chart-legend-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.chart-legend em {
  font-style: normal;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  font-size: 12px;
}

.swatch {
  width: 8px;
  height: 8px;
  border-radius: 2px;
}

.split-empty {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

@media (max-width: 900px) {
  .outline,
  .steps,
  .dash-charts,
  .stats,
  .rates-head {
    grid-template-columns: 1fr;
  }

  .rates-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .chart-body {
    grid-template-columns: 1fr;
    justify-items: center;
  }
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes view-in {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes donut-pop {
  from {
    opacity: 0;
    transform: scale(0.82) rotate(-14deg);
  }
  to {
    opacity: 1;
    transform: scale(1) rotate(0deg);
  }
}

@keyframes quote-flash {
  from {
    color: var(--accent);
  }
  to {
    color: var(--muted);
  }
}

@keyframes sweep {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(420%);
  }
}

@media (max-width: 640px) {
  .top {
    flex-wrap: wrap;
    align-items: flex-start;
  }

  .top-nav,
  #session-slot,
  .session,
  .session-actions {
    margin-left: 0;
  }

  #session-slot {
    width: auto;
    margin-left: auto;
  }

  .session-actions {
    justify-content: flex-start;
  }

  .eve-row {
    grid-template-columns: 1fr;
    gap: 4px;
  }
}

@media (max-width: 800px) {
  :root {
    --rail: 72px;
  }

  .brand-text,
  .rail-kicker,
  .rail-label {
    display: none;
  }

  .rail-foot {
    padding: 12px 0 4px;
  }

  .rail-contact {
    justify-content: center;
    padding: 10px 8px;
  }

  .brand {
    justify-content: center;
    padding: 6px 0 12px;
  }

  .rail-link {
    justify-content: center;
    padding: 10px 8px;
  }

  .page-scroll {
    padding: 14px 12px 36px;
  }

  .topbar {
    padding: 10px 12px;
  }

  .hero h2 {
    font-size: 22px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}
