@font-face { font-family: "WH Display"; src: url(fonts/fraunces-latin-800-normal.woff2) format("woff2"); font-weight: 800; font-display: swap; }
@font-face { font-family: "WH Display"; src: url(fonts/fraunces-latin-600-normal.woff2) format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "WH Text"; src: url(fonts/nunito-latin-400-normal.woff2) format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "WH Text"; src: url(fonts/nunito-latin-600-normal.woff2) format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "WH Text"; src: url(fonts/nunito-latin-800-normal.woff2) format("woff2"); font-weight: 800; font-display: swap; }

:root {
  --bg: #17110d; --bg2: #1d1510; --panel: #221912; --card: #2c2018; --card2: #33251b; --line: #4a3524; --line2: #5d432d;
  --honey: #d6a44c; --honey-hi: #f2c56b; --butter: #f6dc94; --cream: #eee7dc; --muted: #b3a491; --faint: #7d6d5c;
  --ok: #8fcf7a; --bad: #ec7a62; --sky: #7fb6d9; --berry: #c784c9; --syrup: #7a3f17; --ketchup: #c4432b;
  --r: 14px; --r-sm: 9px; --shadow: 0 10px 30px rgba(0,0,0,.35), 0 1px 0 rgba(255,220,150,.04) inset;
}
* { box-sizing: border-box; }
html { margin: 0; height: 100%; background: var(--bg); }
body { margin: 0; min-height: 100%; }
body { background: radial-gradient(1200px 600px at 80% -10%, #2a1d12 0%, transparent 60%), radial-gradient(900px 500px at -10% 110%, #24170e 0%, transparent 60%), var(--bg);
  color: var(--cream); font: 16px/1.5 "WH Text", "Segoe UI", system-ui, sans-serif; -webkit-font-smoothing: antialiased; }
a { color: var(--honey-hi); text-decoration: none; }
a:hover { color: var(--butter); }
h1, h2, h3 { font-family: "WH Display", Georgia, serif; font-weight: 800; letter-spacing: .005em; margin: 0; color: var(--butter); }
h1 { font-size: 34px; line-height: 1.15; }
h2 { font-size: 22px; }
h3 { font-size: 17px; font-weight: 600; }
p { margin: .4em 0; }
.muted { color: var(--muted); } .faint { color: var(--faint); } .ok { color: var(--ok); } .bad { color: var(--bad); }
.num { font-variant-numeric: tabular-nums; }

/* the top bar */
.top { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 22px; padding: 12px 28px;
  background: linear-gradient(180deg, rgba(23,17,13,.97), rgba(23,17,13,.88)); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 10px; color: var(--butter); font-family: "WH Display", Georgia, serif; font-weight: 800; font-size: 21px; }
.brand svg { width: 34px; height: 34px; }
.brand small { display: block; font: 600 11px/1 "WH Text", sans-serif; color: var(--honey); letter-spacing: .18em; text-transform: uppercase; margin-top: 2px; }
.nav { display: flex; gap: 4px; }
.nav a { color: var(--muted); padding: 7px 13px; border-radius: 999px; font-weight: 600; font-size: 15px; }
.nav a:hover { color: var(--cream); background: var(--card); }
.nav a.on { color: var(--bg); background: var(--honey); }
.top .spacer { flex: 1; }
.pillbtn { white-space: nowrap; display: inline-flex; align-items: center; gap: 8px; padding: 7px 14px; border-radius: 999px; background: var(--card); border: 1px solid var(--line); color: var(--cream); font-weight: 600; font-size: 14px; }

main { max-width: 1240px; margin: 0 auto; padding: 26px 28px 60px; }
.crumbs { color: var(--faint); font-size: 14px; margin-bottom: 6px; }
.crumbs a { color: var(--muted); }
.head { display: flex; align-items: flex-end; gap: 18px; flex-wrap: wrap; margin-bottom: 20px; }
.head .spacer { flex: 1; }

/* her tabs */
.tabs { display: flex; gap: 6px; flex-wrap: wrap; margin: 0 0 22px; padding: 5px; background: var(--panel); border: 1px solid var(--line); border-radius: 999px; width: fit-content; }
.tabs a { color: var(--muted); padding: 8px 16px; border-radius: 999px; font-weight: 600; font-size: 15px; display: inline-flex; gap: 8px; align-items: center; }
.tabs a:hover { color: var(--cream); }
.tabs a.on { background: var(--card2); color: var(--butter); box-shadow: 0 0 0 1px var(--line2) inset; }
.tabs svg { width: 16px; height: 16px; opacity: .85; }

/* cards */
.grid { display: grid; gap: 16px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } .g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.card { background: linear-gradient(180deg, var(--card), #281d15); border: 1px solid var(--line); border-radius: var(--r); padding: 18px 20px; box-shadow: var(--shadow); position: relative; }
.card.flat { box-shadow: none; }
.card h3 { margin-bottom: 8px; }
.card .k { color: var(--faint); font-size: 12.5px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.card .v { font-family: "WH Display", Georgia, serif; font-weight: 800; font-size: 30px; color: var(--butter); line-height: 1.1; margin-top: 4px; font-variant-numeric: tabular-nums; }
.card .v small { font: 600 14px "WH Text", sans-serif; color: var(--muted); margin-left: 4px; }
.card .sub { color: var(--muted); font-size: 14px; margin-top: 4px; }
.span2 { grid-column: span 2; } .span3 { grid-column: span 3; } .spanall { grid-column: 1 / -1; }

/* buttons and fields */
button, .btn { font: 800 15px "WH Text", sans-serif; border: 0; border-radius: 999px; padding: 10px 20px; cursor: pointer; color: #2a1a0c;
  background: linear-gradient(180deg, var(--honey-hi), var(--honey)); box-shadow: 0 2px 0 #8a5d22, 0 6px 16px rgba(214,164,76,.18); display: inline-flex; align-items: center; gap: 8px; }
button:hover, .btn:hover { filter: brightness(1.06); color: #2a1a0c; }
button:active { transform: translateY(1px); box-shadow: 0 1px 0 #8a5d22; }
button.ghost, .btn.ghost { background: transparent; color: var(--cream); box-shadow: 0 0 0 1px var(--line2) inset; }
button.ghost:hover { background: var(--card2); color: var(--cream); }
button.danger { background: transparent; color: var(--bad); box-shadow: 0 0 0 1px #6b3226 inset; }
button.small { padding: 6px 13px; font-size: 13.5px; }
button:disabled { opacity: .45; cursor: default; filter: none; }
input[type=text], input[type=search], select, textarea { font: 600 15px "WH Text", sans-serif; color: var(--cream); background: var(--bg2); border: 1px solid var(--line2);
  border-radius: var(--r-sm); padding: 10px 13px; outline: none; }
input:focus, select:focus, textarea:focus { border-color: var(--honey); box-shadow: 0 0 0 3px rgba(214,164,76,.18); }
.seg { display: inline-flex; background: var(--bg2); border: 1px solid var(--line2); border-radius: 999px; padding: 3px; gap: 2px; }
.seg button { background: transparent; box-shadow: none; color: var(--muted); padding: 7px 14px; font-size: 14px; }
.seg button.on { background: var(--card2); color: var(--butter); box-shadow: 0 0 0 1px var(--line2) inset; }
.switch { display: flex; align-items: center; gap: 14px; padding: 13px 0; border-bottom: 1px dashed var(--line); }
.switch:last-child { border-bottom: 0; }
.switch .t { flex: 1; } .switch .t b { display: block; font-weight: 800; color: var(--cream); } .switch .t span { color: var(--muted); font-size: 14px; }
.tog { width: 50px; height: 28px; border-radius: 999px; background: #3a2a1e; border: 1px solid var(--line2); position: relative; cursor: pointer; flex: none; transition: background .15s; }
.tog::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: var(--muted); transition: all .15s; }
.tog.on { background: var(--honey); border-color: var(--honey-hi); } .tog.on::after { left: 25px; background: #2a1a0c; }
.stepper { display: inline-flex; align-items: center; gap: 0; background: var(--bg2); border: 1px solid var(--line2); border-radius: 999px; }
.stepper button { background: transparent; box-shadow: none; color: var(--honey-hi); padding: 6px 13px; font-size: 18px; }
.stepper span { min-width: 74px; text-align: center; font-weight: 800; font-variant-numeric: tabular-nums; }

.badge { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 800; padding: 3px 10px; border-radius: 999px; background: var(--card2); color: var(--muted); border: 1px solid var(--line2); letter-spacing: .02em; }
.badge.honey { background: rgba(214,164,76,.15); color: var(--honey-hi); border-color: rgba(214,164,76,.45); }
.badge.ok { background: rgba(143,207,122,.12); color: var(--ok); border-color: rgba(143,207,122,.4); }
.badge.bad { background: rgba(236,122,98,.12); color: var(--bad); border-color: rgba(236,122,98,.4); }
.dot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; background: var(--faint); }
.dot.live { background: var(--ok); box-shadow: 0 0 0 4px rgba(143,207,122,.15); }
.dot.idle { background: var(--honey); }

/* characters */
.chars { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
.char { display: flex; gap: 16px; align-items: center; cursor: pointer; transition: transform .12s, border-color .12s; }
.char:hover { transform: translateY(-2px); border-color: var(--honey); }
.char .av { width: 72px; height: 84px; flex: none; border-radius: 12px; background: radial-gradient(circle at 50% 70%, #3b2a1c, #241a12); display: grid; place-items: center; border: 1px solid var(--line); }
.char .nm { font-family: "WH Display", Georgia, serif; font-weight: 800; font-size: 21px; color: var(--butter); }
.char .meta { color: var(--muted); font-size: 14px; }
.addchar { border-style: dashed; display: grid; place-items: center; min-height: 118px; color: var(--honey-hi); font-weight: 800; cursor: pointer; }

/* hero */
.hero { display: grid; grid-template-columns: 1.15fr 1fr; gap: 40px; align-items: center; padding: 40px 0 20px; }
.hero h1 { font-size: 50px; }
.hero h1 em { font-style: normal; color: var(--honey-hi); }
.hero p.lead { font-size: 19px; color: var(--muted); max-width: 34em; }
.hero .art { border-radius: 22px; overflow: hidden; border: 1px solid var(--line); box-shadow: var(--shadow); background: #1f1610; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 34px; }
.steps .n { font-family: "WH Display", Georgia, serif; font-size: 30px; color: var(--honey); font-weight: 800; }

/* pairing code */
.codebox { display: flex; gap: 10px; align-items: center; justify-content: center; margin: 22px 0; }
.codebox input { font: 800 34px "WH Display", Georgia, serif; letter-spacing: .22em; text-align: center; width: 330px; padding: 14px; text-transform: uppercase; color: var(--butter); }

/* the map */
.mapwrap { background: radial-gradient(ellipse at 50% 0%, #2b2116 0%, #18120d 70%); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; position: relative; }
.mapwrap svg { display: block; width: 100%; height: auto; max-height: 74vh; touch-action: none; user-select: none; }
.maptools { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-bottom: 12px; }
.legend { display: flex; gap: 16px; flex-wrap: wrap; font-size: 13.5px; color: var(--muted); margin-top: 10px; }
.legend i { display: inline-block; width: 16px; height: 4px; border-radius: 2px; vertical-align: middle; margin-right: 6px; }
.maplist { display: grid; gap: 8px; max-height: 640px; overflow: auto; padding-right: 4px; }
.maprow { display: grid; grid-template-columns: 1fr auto; gap: 4px 10px; padding: 11px 14px; border-radius: 11px; background: var(--card); border: 1px solid var(--line); cursor: pointer; }
.maprow:hover { border-color: var(--line2); background: var(--card2); }
.maprow.on { border-color: var(--honey); box-shadow: 0 0 0 1px var(--honey) inset; }
.maprow .nm { font-weight: 800; color: var(--cream); }
.maprow .st { color: var(--faint); font-size: 13px; }
.maprow .lv { font-weight: 800; color: var(--honey-hi); font-size: 14px; text-align: right; }
.mobs { display: flex; gap: 6px; flex-wrap: wrap; grid-column: 1 / -1; }
.mob { font-size: 12.5px; padding: 2px 8px; border-radius: 999px; background: #241a12; color: var(--muted); border: 1px solid var(--line); }
.mob b { color: var(--cream); font-weight: 800; }

/* the plan-ahead road */
.road { position: relative; padding-left: 26px; }
.road::before { content: ""; position: absolute; left: 8px; top: 8px; bottom: 8px; width: 3px; background: linear-gradient(var(--honey), var(--syrup)); border-radius: 2px; }
.stop { position: relative; margin-bottom: 14px; }
.stop::before { content: ""; position: absolute; left: -24px; top: 22px; width: 13px; height: 13px; border-radius: 50%; background: var(--bg); border: 3px solid var(--honey); }
.stop.now::before { background: var(--honey-hi); box-shadow: 0 0 0 5px rgba(242,197,107,.2); }
.stop .lvl { font-family: "WH Display", Georgia, serif; font-size: 15px; color: var(--honey); font-weight: 800; }

/* the day strip */
.strip { display: flex; height: 54px; border-radius: 12px; overflow: hidden; border: 1px solid var(--line2); position: relative; background: #1b140f; }
.strip .b { height: 100%; text-overflow: clip; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 13px; overflow: hidden; white-space: nowrap; border-right: 1px solid rgba(0,0,0,.35); }
.strip .b.play { background: linear-gradient(180deg, #e2b25c, #b9862f); color: #2a1a0c; }
.strip .b.rest { background: repeating-linear-gradient(135deg, #2d3a44, #2d3a44 8px, #283440 8px, #283440 16px); color: #bcd3e3; }
.strip .nowline { position: absolute; top: -6px; bottom: -6px; width: 3px; background: var(--cream); border-radius: 2px; box-shadow: 0 0 0 3px rgba(238,231,220,.18); }
.strip .handle { position: absolute; top: 6px; bottom: 6px; width: 12px; margin-left: -6px; border-radius: 6px; background: var(--butter); cursor: ew-resize; box-shadow: 0 0 0 3px rgba(0,0,0,.35); }
.hours { display: flex; justify-content: space-between; color: var(--faint); font-size: 12px; margin-top: 6px; font-variant-numeric: tabular-nums; }
.week { display: grid; grid-template-columns: 54px 1fr; gap: 8px 12px; align-items: center; }
.week .strip { height: 26px; border-radius: 8px; }

/* the Tabletop */
.tt { display: grid; grid-template-columns: 1fr 360px; gap: 18px; }
.palette { display: flex; gap: 8px; flex-wrap: wrap; }
.tok { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 10px 6px; border-radius: 12px; background: var(--card); border: 1px solid var(--line); cursor: pointer; font-size: 12.5px; font-weight: 800; color: var(--muted); min-width: 74px; }
.tok:hover { border-color: var(--line2); color: var(--cream); }
.tok.on { border-color: var(--honey); color: var(--butter); box-shadow: 0 0 0 1px var(--honey) inset; }
.tok svg { width: 38px; height: 46px; }
.said { background: #fffaf0; color: #2a1a0c; border-radius: 16px 16px 16px 4px; padding: 10px 14px; font-weight: 800; display: inline-block; margin: 6px 0; box-shadow: 0 4px 12px rgba(0,0,0,.3); }
.said.none { background: var(--card2); color: var(--muted); font-weight: 600; }
.why { color: var(--muted); font-size: 14px; }
.chatlog { display: grid; gap: 10px; max-height: 360px; overflow: auto; }
.line-in { display: flex; gap: 8px; }
.line-in input { flex: 1; }
.plate svg { width: 20px; height: 20px; flex: none; }
.plate { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-radius: 11px; background: rgba(127,182,217,.08); border: 1px solid rgba(127,182,217,.3); color: #bcd7ea; font-size: 14px; }

.empty { text-align: center; padding: 40px 20px; color: var(--muted); }
.empty svg { width: 120px; height: 120px; opacity: .9; }
.toast { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); background: var(--card2); color: var(--cream); border: 1px solid var(--honey); padding: 12px 20px; border-radius: 999px; font-weight: 800; box-shadow: var(--shadow); z-index: 50; }
.foot { color: var(--faint); font-size: 13px; text-align: center; padding: 30px 0 10px; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.between { justify-content: space-between; }
.mt { margin-top: 16px; } .mt2 { margin-top: 28px; } .mb { margin-bottom: 12px; }
.lookcode { font: 600 13px ui-monospace, Consolas, monospace; word-break: break-all; background: var(--bg2); border: 1px solid var(--line2); border-radius: 10px; padding: 12px; color: var(--butter); }
.expbar { height: 8px; border-radius: 4px; background: #3a2a1e; overflow: hidden; margin-top: 8px; }
.expbar i { display: block; height: 100%; background: linear-gradient(90deg, var(--honey), var(--honey-hi)); }

@media (max-width: 980px) {
  .hero, .tt, .g2, .g3, .g4 { grid-template-columns: 1fr; } .span2, .span3 { grid-column: auto; }
  .top { flex-wrap: wrap; padding: 10px 16px; } main { padding: 18px 16px 50px; }
}
