:root {
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  color: #f8f8f8;
  background: #040607;
  --teal: #388092;
  --teal-dark: #2b616e;
  --silver: #b5b9ba;
  --silver-light: #e4e5e5;
  --gold: #d4aa47;
  --panel: #101518;
  --line: #1d343b;
  --green: #38a875;
  --bad: #e07b7b;
}
* { box-sizing: border-box; }
body { margin: 0; background: #040607; }
button, input, select { font: inherit; }
button { cursor: pointer; }
button:disabled { opacity: 0.6; cursor: wait; }
.app {
  width: min(100%, 430px);
  min-height: 100vh;
  margin: 0 auto;
  padding: 28px 22px 96px;
  background: radial-gradient(circle at 50% -10%, #10242a 0, #040607 42%);
}
.eyebrow {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--teal);
}
h1 {
  font-size: 42px;
  line-height: 0.98;
  margin: 14px 0 10px;
  letter-spacing: -0.04em;
}
.login-title { font-size: clamp(20px, 9.3vw, 42px); white-space: nowrap; }
h2 { font-size: 28px; line-height: 1.05; margin: 12px 0; letter-spacing: -0.03em; }
p { color: var(--silver); line-height: 1.45; }
.muted { color: var(--silver); }
.card, .puzzle, .roster button, .mission-card, .record, .option {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 16px;
}
.card, .puzzle { padding: 16px; margin-top: 16px; }
.stat-row, .topline, .row, .key-strip, .action-row {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: center;
}
.standing {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  column-gap: 12px;
  align-items: center;
  padding: 12px 0;
  border-top: 1px solid #172226;
}
.standing:first-child { border-top: 0; padding-top: 2px; }
.standing:last-child { padding-bottom: 2px; }
.standing .rank { color: var(--teal); font-size: 16px; }
.standing .who { line-height: 1.2; }
.standing .who small {
  display: block;
  margin-top: 4px;
  color: var(--silver);
  font-size: 11px;
  letter-spacing: 0.04em;
}
.standing .pts { font-size: 18px; font-variant-numeric: tabular-nums; }
.stat-row { margin: 8px 0 16px; color: #8bc0cc; font-size: 13px; font-weight: 800; }
.primary, .secondary, .ghost {
  width: 100%;
  min-height: 52px;
  border-radius: 14px;
  font-weight: 900;
  margin-top: 12px;
}
.primary { background: var(--teal); color: #041014; border: 0; }
.secondary, .ghost { background: #142d34; color: white; border: 1px solid #234a55; }
.ghost { background: transparent; color: var(--silver); }
input {
  width: 100%;
  height: 52px;
  margin-top: 12px;
  border-radius: 12px;
  border: 1px solid #2e3038;
  background: #0b0d0f;
  color: white;
  padding: 0 14px;
  outline: none;
}
input:focus, .option.selected { border-color: var(--teal); }
select {
  display: block;
  width: 100%;
  min-height: 48px;
  margin-top: 8px;
  padding: 0 12px;
  border: 1px solid #2e3038;
  border-radius: 12px;
  color: white;
  background: #0b0d0f;
}
select:focus { border-color: var(--teal); }
.coin-token { border-color: var(--gold); }
.coin-token h2 { color: var(--gold); overflow-wrap: anywhere; }
.coin-sharing-prompt { margin-top: 14px; padding-top: 12px; border-top: 1px solid #3b3830; }
.post-claim-notice { border-color: var(--gold); }
.post-claim-notice .coin-sharing-prompt { margin-top: 0; padding-top: 0; border-top: 0; }
.post-claim-notice [data-action="dismiss-claim-instructions"]:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
}
.coin-sharing-prompt h3 { margin: 0 0 8px; color: var(--gold); font-size: 17px; }
.coin-sharing-prompt p { margin: 8px 0; }
.coin-sharing-prompt blockquote {
  margin: 0 0 8px;
  padding: 9px 12px;
  border-left: 3px solid var(--teal);
  border-radius: 0 8px 8px 0;
  background: #0b0d0f;
  color: white;
  font-weight: 700;
}
.coin-sharing-prompt p:last-child { color: var(--teal); font-weight: 800; }
.coin-status { margin-bottom: 16px; }
.coin-status p { margin-bottom: 0; }
.coin-admin-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(160px, 48%);
  align-items: start;
  gap: 12px;
}
.coin-admin-identity { min-width: 0; }
.coin-admin-identity b { font-size: clamp(15px, 4vw, 20px); }
.coin-admin-identity .note { margin: 12px 0 0; overflow-wrap: anywhere; }
.coin-config-controls {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 40px;
  align-items: end;
  gap: 6px;
  min-width: 0;
}
.coin-type-control { margin: 0; font-size: 11px; }
.coin-type-control select {
  min-height: 42px;
  margin-top: 6px;
  padding: 0 4px;
  font-size: 11px;
  font-weight: 700;
}
.coin-save {
  display: grid;
  place-items: center;
  width: 40px;
  height: 42px;
  padding: 0;
  border: 1px solid #234a55;
  border-radius: 12px;
  background: #142d34;
  color: white;
}
.coin-save:focus-visible { outline: 2px solid var(--teal); outline-offset: 2px; }
.coin-points-control { margin-top: 12px; }
.coin-points-control input { width: 130px; height: 42px; margin-top: 6px; }
.coin-points-note { margin: 6px 0 0; }
@media (max-width: 360px) {
  .coin-admin-head { grid-template-columns: 1fr; }
  .coin-config-controls { width: min(100%, 200px); }
}
.coin-admin-row .coin-history-trigger { margin-top: 16px; }
.coin-history { border-top: 1px solid var(--line); margin-top: 14px; padding-top: 14px; font-size: 13px; }
.coin-holder-list { margin: 12px 0 0; padding-left: 22px; }
.coin-holder-list li { padding: 8px 0; border-top: 1px solid var(--line); color: var(--silver); }
.coin-holder-list li b { color: var(--silver-light); }
.coin-holder-list li span { display: block; margin-top: 3px; font-size: 12px; }
input[aria-invalid="true"] { border-color: var(--bad); }
label { display: block; margin-top: 18px; color: var(--silver-light); font-size: 13px; font-weight: 700; }
.name-hint { margin: 12px 0 0; font-size: 12px; }
.field-error:not(:empty) { display: block; margin-top: 6px; color: var(--bad); font-size: 12px; }
.invite-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; border-top: 1px solid var(--line); padding: 14px 0; font-size: 13px; }
.invite-row:first-of-type { margin-top: 12px; }
.invite-row small { display: block; margin-top: 4px; color: var(--silver); }
.invite-row .link { flex: none; font-size: 11px; color: #8bc0cc; }
.roster-pager { margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); color: var(--silver); font-size: 12px; }
.roster-pager .link { color: #8bc0cc; font-size: 11px; }
.issued { border-color: var(--gold); }
.issued-code { overflow-wrap: anywhere; color: var(--gold); font-weight: 900; letter-spacing: .05em; font-size: 17px; }
.option {
  padding: 14px;
  margin-top: 10px;
  text-align: left;
  color: white;
  width: 100%;
}
.option.selected { background: #10242a; }
.archive { max-height: 240px; overflow: auto; margin-top: 14px; }
.archive div, .record {
  display: grid;
  grid-template-columns: 42px 1fr auto;
  gap: 8px;
  padding: 8px 4px;
  border-bottom: 1px solid #111b1f;
  font-size: 13px;
}
.archive b, .year { color: var(--teal); }
.record { grid-template-columns: 72px 1fr; padding: 12px; margin-top: 10px; }
.year { font-size: 24px; font-weight: 900; }
.mission-list { display: grid; gap: 10px; }
.mission-card {
  display: grid;
  grid-template-columns: 42px 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 14px;
  color: white;
  text-align: left;
  width: 100%;
}
.mission-card small { color: var(--silver); letter-spacing: 0.06em; }
.mission-card.locked { opacity: 0.45; }
.mission-card.complete b { color: var(--green); }
.mission-card.active b, .key-strip span { color: var(--teal); }
.key-strip {
  margin: 16px 0;
  font-weight: 900;
  letter-spacing: 0.04em;
}
.action-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.action-row button { margin-top: 0; }
.roster { display: grid; gap: 8px; margin-top: 8px; }
.roster button { width: 100%; padding: 12px 14px; color: white; text-align: left; }
.roster small, .note { color: var(--silver); font-size: 12px; }
.fusion { font-size: 22px; font-weight: 900; letter-spacing: -0.03em; }
.bonus-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.bonus-grid button { margin-top: 0; min-height: 84px; }
.msg { min-height: 1.2em; font-size: 13px; font-weight: 700; }
.msg.ok { color: var(--green); }
.msg.bad { color: var(--bad); }
.hint {
  margin-top: 12px;
  padding: 10px 12px;
  border-left: 3px solid var(--teal);
  color: #c5d4d8;
  font-size: 13px;
}
.key {
  font-size: 56px;
  font-weight: 900;
  color: var(--teal);
  letter-spacing: 0.06em;
  margin: 8px 0;
}
.toast {
  position: fixed;
  left: 50%;
  top: 16px;
  transform: translateX(-50%);
  background: #17343d;
  border: 1px solid var(--teal);
  color: white;
  padding: 10px 14px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  z-index: 5;
  max-width: 90vw;
}
.count {
  font-size: 120px;
  font-weight: 900;
  text-align: center;
  color: var(--teal);
  line-height: 0.9;
  margin: 24px 0;
}
.credential {
  background: linear-gradient(145deg, #070707, #151515 55%, #050505);
  border: 1px solid #373737;
  border-radius: 20px;
  min-height: 190px;
  padding: 20px;
  margin-top: 16px;
}
.credential .name { font-size: 26px; font-weight: 900; margin-top: 28px; }
.credential .meta { display: flex; gap: 16px; margin-top: 24px; color: var(--silver); font-size: 12px; }
.ledger { font-size: 12px; color: var(--silver); }
.ledger div { display: flex; justify-content: space-between; padding: 6px 0; border-bottom: 1px solid #172226; }
.link {
  background: none;
  border: 0;
  color: var(--silver-light);
  padding: 0;
  min-height: 0;
  width: auto;
  margin: 0;
  font-weight: 800;
}
.badge { font-size: 11px; font-weight: 800; letter-spacing: 0.06em; color: var(--gold); }
.activity-title { margin-top: 28px; }
.activity-filters { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin: 20px 0; }
.activity-filters button {
  min-height: 48px; padding: 8px 5px; border: 1px solid #234a55; border-radius: 11px;
  color: var(--silver-light); background: #101b1e; font-size: 10px; font-weight: 800;
}
.activity-filters button[aria-pressed="true"] { background: var(--teal); border-color: var(--teal); color: #041014; }
.activity-filters button:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.activity-overview { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.activity-metric {
  display: flex; flex-direction: column; min-height: 124px; padding: 15px;
  background: var(--panel); border: 1px solid var(--line); border-radius: 16px;
}
.activity-metric span { color: #8bc0cc; font-size: 10px; font-weight: 800; letter-spacing: .07em; }
.activity-metric strong { margin: 6px 0 2px; font-size: 32px; font-variant-numeric: tabular-nums; line-height: 1; }
.activity-metric small { margin-top: auto; color: var(--silver); font-size: 11px; }
.activity-card h2 { font-size: 23px; margin: 8px 0 14px; }
.activity-card .note { margin: -6px 0 10px; }
.activity-row { padding: 9px 0; border-top: 1px solid var(--line); font-size: 14px; }
.activity-row span { color: var(--silver-light); }
.activity-row b { font-variant-numeric: tabular-nums; }
.activity-coverage { margin: 20px 0; line-height: 1.55; }
