/* Antehouse — a house show in fine line-art on a fired-clay ground: cream ink, one teal glow. The CA hangs as a vertical
   stub on the left edge at every width; the page is the bill (headline), the live line, then the house itself. */
:root {
  --clay: #774539;          /* ground, luminance ~0.32 */
  --clay-deep: #5F3328;     /* panels */
  --cream: #F4EAD5;         /* ink + line-art */
  --cream-2: rgba(244, 234, 213, .72);
  --cream-3: rgba(244, 234, 213, .42);
  --rule: rgba(244, 234, 213, .26);
  --glow: #4DF0CF;          /* the one accent */
  --glow-ink: #10302A;
  --disp: 'Limelight', 'Figtree', serif;
  --txt: 'Figtree', system-ui, sans-serif;
  --mono: 'IBM Plex Mono', ui-monospace, monospace;
  --stub: 42px;
}
* { box-sizing: border-box; }
html { background: var(--clay); }
body { margin: 0; background: var(--clay); color: var(--cream); font: 400 15px/1.5 var(--txt); padding: 0 14px 40px calc(var(--stub) + 12px);
  -webkit-font-smoothing: antialiased; overflow-x: hidden; }
a { color: var(--cream); }
code { font-family: var(--mono); }
img { display: block; }

/* ---------- the CA stub: a vertical ticket stub pinned to the left edge ---------- */
.cue-rail { position: fixed; z-index: 40; left: 0; top: 50%; transform: translateY(-50%); width: var(--stub);
  display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 12px 0;
  background: var(--clay-deep); border: 1.5px solid var(--cream); border-left: 0; border-radius: 0 14px 14px 0; }
.cue-k, .cue-addr, .cue-copy, .cue-gm { writing-mode: vertical-lr; transform: rotate(180deg); }
.cue-k { font: 400 13px/1 var(--disp); color: var(--glow); letter-spacing: .08em; }
.cue-addr { font: 500 10px/1 var(--mono); color: var(--cream); letter-spacing: 0; user-select: all; -webkit-user-select: all; }
.cue-addr.is-wait { font: 500 11px/1 var(--txt); color: var(--cream-2); user-select: none; -webkit-user-select: none; }
.cue-copy { border: 1.5px solid var(--glow); background: var(--glow); color: var(--glow-ink); font: 700 12px/1 var(--txt);
  padding: 9px 5px; border-radius: 999px; cursor: pointer; }
.cue-copy:disabled { background: transparent; border-color: var(--cream-3); color: var(--cream-3); cursor: default; }
.cue-copy.is-done { background: var(--cream); border-color: var(--cream); }
.cue-gm { font: 500 10px/1 var(--txt); color: var(--cream-2); text-decoration: none; }

/* ---------- door line: the name and the connect button, no bar ---------- */
.doorline { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 0 2px; max-height: 50px; }
.doorline-mark { display: flex; align-items: center; gap: 8px; text-decoration: none; font: 400 17px/1 var(--disp); }
.doorline-mark img { border-radius: 8px; border: 1px solid var(--rule); }
.doorbtn { background: transparent; color: var(--cream); border: 1.5px solid var(--cream); border-radius: 999px; font: 600 13px/1 var(--txt);
  padding: 8px 14px; cursor: pointer; }
.doorbtn[data-on="1"] { border-color: var(--glow); color: var(--glow); font-family: var(--mono); font-size: 12px; }

/* ---------- the bill ---------- */
.billtop { font: 400 clamp(34px, 9.6vw, 76px)/1.02 var(--disp); margin: 14px 0 10px; letter-spacing: -.005em; max-width: 15ch; }
.nowline { font-size: 16px; line-height: 1.45; margin: 0 0 14px; max-width: 46ch; color: var(--cream); min-height: 4.4em; }
.nowline b { color: var(--glow); font-weight: 700; }
.nowline em { font-style: normal; font-family: var(--mono); font-size: .92em; border-bottom: 1px dashed var(--cream-3); }
.nowline[data-tone="cut"]::before { content: "OUT"; font: 700 11px/1 var(--txt); letter-spacing: .1em; color: var(--glow-ink); background: var(--glow);
  padding: 3px 6px 2px; border-radius: 4px; margin-right: 8px; vertical-align: 2px; }

/* ---------- the house ---------- */
.hall { border: 1.5px solid var(--cream); border-radius: 18px; padding: 12px 12px 14px; background: var(--clay-deep); }
.setlist { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(6, 1fr); gap: 4px; }
.cut { border: 1px solid var(--rule); border-radius: 8px; padding: 5px 2px 4px; text-align: center; line-height: 1.1; min-width: 0; }
.cut i { display: block; font: 400 14px/1.1 var(--disp); font-style: normal; color: var(--cream-2); }
.cut b { display: block; font: 500 10px/1.3 var(--mono); color: var(--cream-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cut.is-past b { color: var(--cream-2); }
.cut.is-past b s { color: var(--glow); text-decoration: none; }
.cut.is-now { border-color: var(--glow); box-shadow: 0 0 0 1px var(--glow) inset; }
.cut.is-now i, .cut.is-now b { color: var(--glow); }
.hall-clock { display: flex; justify-content: space-between; align-items: baseline; margin: 8px 2px 0; font-size: 13px; color: var(--cream-2); }
.hall-clock b { font: 500 18px/1 var(--mono); color: var(--cream); }
.hall-clock b[data-hot="1"] { color: var(--glow); }
.housewrap { margin: 4px auto 0; max-width: 560px; }
.houseart { width: 100%; height: auto; display: block; overflow: visible; }
.houseart .ln { fill: none; stroke: var(--cream); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.houseart .ln-thin { fill: none; stroke: var(--cream-3); stroke-width: 1; stroke-dasharray: 3 4; }
.houseart .seat { fill: none; stroke: var(--cream); stroke-width: 1.6; }
.houseart .seat-n { font: 500 10px var(--mono); fill: var(--cream-2); text-anchor: middle; dominant-baseline: central; }
.houseart g.is-in .seat { fill: var(--glow); stroke: var(--glow); filter: drop-shadow(0 0 4px rgba(77, 240, 207, .65)); }
.houseart g.is-in .seat-n { fill: var(--glow-ink); font-weight: 700; }
.houseart g.is-due .seat { stroke-dasharray: 2 2.4; animation: owe 1.6s ease-in-out infinite; }
.houseart g.is-out .seat { stroke: var(--cream-3); stroke-dasharray: 1.5 3; }
.houseart g.is-out .seat-n { fill: var(--cream-3); }
.houseart g.is-out .strike { stroke: var(--cream); stroke-width: 1.6; stroke-linecap: round; }
.houseart g.is-full .seat { fill: var(--glow); stroke: var(--glow); }
.houseart g.is-full .seat-n { fill: var(--glow-ink); }
.houseart g.is-mine .seat { stroke-width: 3; }
.houseart g.is-first .seat { stroke: var(--glow); stroke-width: 2.2; animation: owe 1.3s ease-in-out infinite; }
.houseart g.is-first .seat-n { fill: var(--glow); font-weight: 700; }
.houseart g.is-ghost .seat { stroke: var(--cream-3); stroke-dasharray: 2 3; }
.houseart .flow { fill: none; stroke: var(--cream-3); stroke-width: 1; stroke-dasharray: 2 4; animation: drift 2.2s linear infinite; }
.houseart .coin { fill: var(--clay-deep); stroke: var(--glow); stroke-width: 1.6; }
.houseart .potlbl { font: 400 15px var(--disp); fill: var(--cream); text-anchor: middle; }
.houseart .potsub { font: 500 9.5px var(--mono); fill: var(--cream-2); text-anchor: middle; }
.houseart .stagelbl { font: 500 9px var(--txt); letter-spacing: .22em; fill: var(--cream-3); text-anchor: middle; }
.houseart .hint { font: 600 10px var(--txt); fill: var(--glow); }
.houseart .more { font: 500 10px var(--mono); fill: var(--cream-2); }
@keyframes owe { 0%, 100% { opacity: 1; } 50% { opacity: .45; } }
@keyframes drift { to { stroke-dashoffset: -12; } }

.key { list-style: none; margin: 4px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 12px; color: var(--cream-2); }
.key li { display: flex; align-items: center; gap: 6px; }
.key-dot { width: 11px; height: 11px; border-radius: 50%; border: 1.5px solid var(--cream); display: inline-block; }
.key-dot--in { background: var(--glow); border-color: var(--glow); }
.key-dot--due { border-style: dashed; }
.key-dot--out { border-color: var(--cream-3); border-style: dotted; position: relative; }
.key-dot--out::after { content: ""; position: absolute; left: -2px; right: -2px; top: 4px; height: 1.5px; background: var(--cream); transform: rotate(-45deg); }

.anterow { margin-top: 12px; display: grid; gap: 8px; }
.antebtn { width: 100%; min-height: 54px; border: 0; border-radius: 14px; background: var(--glow); color: var(--glow-ink); font: 400 21px/1 var(--disp);
  cursor: pointer; letter-spacing: .01em; }
.antebtn:disabled { background: transparent; color: var(--cream-2); box-shadow: inset 0 0 0 1.5px var(--cream-3); cursor: default; font: 600 15px/1.2 var(--txt); }
.antebtn[data-urgent="1"] { animation: owe 1.4s ease-in-out infinite; }
.anterow-me { margin: 0; font-size: 13px; color: var(--cream-2); }
.anterow-me b { color: var(--cream); }
.takebtn { justify-self: start; background: transparent; color: var(--glow); border: 1.5px solid var(--glow); border-radius: 999px; padding: 9px 16px;
  font: 700 14px/1 var(--txt); cursor: pointer; }

/* ---------- the tape ---------- */
.feed { margin-top: 22px; }
.feed-h, .houserules-h { font: 400 24px/1.1 var(--disp); margin: 0 0 8px; }
.feed-h span { font: 500 12px/1 var(--mono); color: var(--cream-3); }
.feed-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--rule); max-height: 460px; overflow: auto; }
.feed-row { display: grid; grid-template-columns: 44px 1fr; gap: 8px; padding: 8px 0; border-bottom: 1px solid var(--rule); font-size: 13.5px; }
.feed-row.is-new { animation: printin .6s ease-out; }
.feed-t { font: 500 11px/1.6 var(--mono); color: var(--cream-3); }
.feed-x b { color: var(--glow); font-weight: 700; }
.feed-x small { display: block; font: 400 10.5px/1.4 var(--mono); color: var(--cream-3); word-break: break-all; }
.feed-row--cut .feed-x { color: var(--cream); }
.feed-row--cut .feed-x::before { content: "✕ "; color: var(--glow); }
.feed-row--quiet .feed-x { color: var(--cream-2); }
@keyframes printin { from { opacity: 0; transform: translateY(-6px); background: rgba(77, 240, 207, .14); } to { opacity: 1; transform: none; background: transparent; } }

/* ---------- house rules ---------- */
.houserules { margin-top: 26px; }
.rulecard { margin: 0; display: grid; grid-template-columns: 1fr; gap: 2px 14px; }
.rulecard dt { font: 400 16px/1.2 var(--disp); color: var(--glow); margin-top: 10px; }
.rulecard dd { margin: 2px 0 0; color: var(--cream); }
.worked { margin-top: 16px; border: 1.5px dashed var(--cream-3); border-radius: 14px; padding: 12px 14px; }
.worked h3 { font: 400 18px/1 var(--disp); margin: 0 0 6px; }
.worked p { margin: 6px 0; color: var(--cream-2); }
.worked-t { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.worked-t td { padding: 5px 0; border-bottom: 1px solid var(--rule); }
.worked-t td:last-child { text-align: right; font-family: var(--mono); white-space: nowrap; padding-left: 10px; }
.worked-t em { font-style: normal; color: var(--glow); font-size: 12px; }
.worked-sum td { font-weight: 700; color: var(--cream); }

/* ---------- credits ---------- */
.credits { margin-top: 30px; padding-top: 14px; border-top: 1.5px solid var(--cream); font-size: 12.5px; color: var(--cream-2); }
.credits p { margin: 6px 0; }
.credits-name { display: flex; align-items: center; gap: 8px; font: 400 15px/1 var(--disp); color: var(--cream); }
.credits-ref code { word-break: break-all; color: var(--cream); font-size: 11.5px; }
.credits-links a { margin-right: 12px; }

.pings { position: fixed; z-index: 60; left: 50%; bottom: 16px; transform: translateX(-50%); display: grid; gap: 6px; width: min(92vw, 380px); pointer-events: none; }
.ping { background: var(--cream); color: var(--clay-deep); border-radius: 12px; padding: 10px 14px; font-size: 13.5px; font-weight: 600; box-shadow: 0 6px 22px rgba(0, 0, 0, .25); }

/* ---------- tablet: wider measure, bigger house ---------- */
@media (min-width: 720px) {
  :root { --stub: 50px; }
  body { padding: 0 28px 48px calc(var(--stub) + 28px); font-size: 16px; }
  .cue-addr { font-size: 12px; }
  .cue-k { font-size: 15px; }
  .nowline { font-size: 18px; max-width: 54ch; }
  .hall { padding: 18px 20px 20px; }
  .cut i { font-size: 17px; }
  .cut b { font-size: 11.5px; }
  .housewrap { max-width: 640px; }
  .rulecard { grid-template-columns: 150px 1fr; }
  .rulecard dt { margin-top: 12px; }
  .rulecard dd { margin-top: 12px; }
}

/* ---------- desktop: the bill and the house on the left, the tape and the rules in a second column ---------- */
@media (min-width: 1000px) {
  :root { --stub: 58px; }
  body { display: grid; grid-template-columns: minmax(0, 1fr) 360px; column-gap: 44px; align-content: start;
    grid-template-areas: "door door" "bill side" "now side" "hall side" "foot foot"; grid-template-rows: auto auto auto 1fr auto;
    max-width: calc(1200px + var(--stub)); margin: 0 auto; padding: 0 32px 56px calc(var(--stub) + 40px); }
  .doorline { grid-area: door; padding-top: 18px; }
  .billtop { grid-area: bill; font-size: 62px; max-width: 14ch; margin-top: 18px; }
  .nowline { grid-area: now; font-size: 19px; min-height: 0; }
  .hall { grid-area: hall; align-self: start; padding: 20px 26px 22px; }
  .housewrap { max-width: 500px; }
  .sidecol { grid-area: side; align-self: start; }
  .feed { margin-top: 26px; }
  .feed-list { max-height: 440px; }
  .houserules { margin-top: 22px; }
  .rulecard { grid-template-columns: 1fr; }
  .rulecard dt { margin-top: 10px; } .rulecard dd { margin-top: 2px; }
  .credits { grid-area: foot; }
  .cue-addr { font-size: 13px; }
  .cue-copy { font-size: 13px; padding: 11px 6px; }
}
