/* ==========================================================
   Evergreen Echoes — evergreen.css
   A porch at night, a lantern, a knit blanket, a cat. Pine
   green, cranberry, cream and lantern gold. Bevels mandatory,
   mittens optional. Keep your porch light on.
   ========================================================== */

@font-face {
  font-family: 'EvergreenEchoes';
  src: url('../fonts/EvergreenEchoes.ttf') format('truetype');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #0a1510;
  --bg2: #10201a;
  --panel: #14241c;
  --panel-2: #1d3328;
  --pine: #1f5c3a;
  --pine-2: #2c7a4d;
  --wood: #5c3b22;
  --wood-2: #8a5a33;
  --ink: #f3e9d2;
  --ink-dim: #a9b5a0;
  --red: #d7383f;
  --red-deep: #8f1d26;
  --gold: #f3c64f;
  --amber: #ffa63d;
  --cream: #f5e9cf;
  --green: #3fae5c;
  --green-bright: #7ee081;
  --ice: #9ad7ff;
  --lcd: #1a0d04;
  --lcd-ink: #ffb347;
  --shadow: #000000;
  --px: 4px;
  --font-logo: 'EvergreenEchoes', 'Press Start 2P', monospace;
  --font-ui: 'Press Start 2P', 'VT323', monospace;
  --font-body: 'VT323', 'Courier New', monospace;
}

* { box-sizing: border-box; }
html { background: var(--bg); scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 20px;
  line-height: 1.25;
  background: var(--bg) url('../img/wall.png') repeat;
  image-rendering: pixelated;
  overflow-x: hidden;
  min-height: 100vh;
}
img, canvas { image-rendering: pixelated; image-rendering: crisp-edges; }
a { color: var(--gold); }
a:hover { color: var(--amber); }
b { color: var(--ink); }
kbd {
  font-family: var(--font-ui); font-size: 8px; padding: 2px 4px;
  background: var(--panel-2); border: 2px solid var(--ink-dim); color: var(--gold);
}
::selection { background: var(--red); color: #fff; }
.hidden { display: none !important; }
.small { font-size: 16px; color: var(--ink-dim); }
.mono { font-family: var(--font-body); letter-spacing: 0.5px; }
.center { text-align: center; }
.blink { animation: blink 1s steps(1) infinite; }
.pulse { animation: pulse 0.8s steps(2) infinite; }
@keyframes blink { 50% { opacity: 0; } }
@keyframes pulse { 50% { color: var(--gold); } }

/* ---------- WEATHER + CRT OVERLAYS ---------- */
.snow { position: fixed; inset: 0; z-index: 1; pointer-events: none; width: 100%; height: 100%; }
body.no-snow .snow { display: none; }
.scanlines {
  position: fixed; inset: 0; z-index: 50; pointer-events: none;
  background: repeating-linear-gradient(to bottom, rgba(0,0,0,0) 0px, rgba(0,0,0,0) 2px, rgba(0,0,0,0.18) 3px, rgba(0,0,0,0.18) 4px);
  mix-blend-mode: multiply;
}
body.no-scan .scanlines { display: none; }
.vignette {
  position: fixed; inset: 0; z-index: 49; pointer-events: none;
  background: radial-gradient(ellipse at center, rgba(0,0,0,0) 55%, rgba(0,0,0,0.55) 100%);
}

/* ---------- PAGE ---------- */
.page { max-width: 1140px; margin: 0 auto; padding: 16px; position: relative; z-index: 2; }

/* ---------- MASTHEAD: the porch ---------- */
.masthead {
  display: grid; grid-template-columns: 170px 1fr 170px; align-items: end; gap: 12px;
  padding: 14px 16px 0;
  background:
    radial-gradient(ellipse at 88% 22%, rgba(255,166,61,0.22) 0, rgba(255,166,61,0.08) 22%, rgba(0,0,0,0) 45%),
    linear-gradient(180deg, #0b1a2a 0, #10233a 40%, #0d1d14 70%, #0d1d14 100%);
  border: var(--px) solid var(--wood);
  box-shadow: 0 0 0 var(--px) var(--shadow), 0 0 0 calc(var(--px) * 2) var(--pine), 6px 6px 0 calc(var(--px) * 2) var(--shadow);
  position: relative;
  overflow: hidden;
}
.masthead::before {
  /* stars */
  content: ''; position: absolute; inset: 0; pointer-events: none; opacity: 0.8;
  background-image:
    radial-gradient(circle, #fff 1px, transparent 1.5px), radial-gradient(circle, #cfe8ff 1px, transparent 1.5px);
  background-size: 120px 70px, 90px 110px; background-position: 10px 8px, 50px 30px;
  mask-image: linear-gradient(180deg, #000 0, #000 45%, transparent 70%);
  -webkit-mask-image: linear-gradient(180deg, #000 0, #000 45%, transparent 70%);
}
.masthead::after {
  /* porch railing + deck boards */
  content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 14px;
  background:
    repeating-linear-gradient(90deg, var(--wood) 0 56px, var(--wood-2) 56px 58px, var(--wood) 58px 60px),
    var(--wood);
  border-top: 3px solid var(--wood-2);
  box-shadow: 0 -4px 0 rgba(255,255,255,0.08);
}
.mast-side { position: relative; z-index: 1; text-align: center; padding-bottom: 18px; }
.player-tag {
  display: inline-block; font-family: var(--font-ui); font-size: 8px; color: var(--ink);
  background: var(--shadow); border: 2px solid var(--ink-dim); padding: 4px 6px; margin-bottom: 4px;
}
.player-tag.host { border-color: var(--red); }
.player-tag.cat { border-color: var(--amber); }
.pnum { font-family: var(--font-ui); font-size: 8px; padding: 2px 4px; color: #fff; margin-right: 2px; }
.player-tag.host .pnum { background: var(--red); }
.player-tag.cat .pnum { background: var(--wood-2); }
.stage { position: relative; width: 128px; height: 128px; margin: 0 auto; }
.stage-shadow { position: absolute; left: 14px; bottom: 0; width: 100px; height: 10px; background: radial-gradient(ellipse, rgba(0,0,0,0.6), rgba(0,0,0,0) 70%); }
.sprite {
  position: absolute; left: 0; bottom: 4px; width: 64px; height: 64px;
  transform: scale(2); transform-origin: bottom left;
  background: no-repeat 0 0; image-rendering: pixelated;
}
/* Kris: 64px frames. idle 4f, sip 6f, dance 8f at 76px. */
.sprite.kris { background-image: url('../img/kris/south.png'); }
.sprite.kris.idle { background-image: url('../img/kris/idle.png'); animation: kris-idle 1.6s steps(4) infinite; }
.sprite.kris.sip { background-image: url('../img/kris/sip.png'); animation: kris-sip 1.5s steps(6) 1 forwards; }
.sprite.kris.dance { width: 76px; height: 76px; left: -6px; bottom: -4px; background-image: url('../img/kris/dance.png'); animation: kris-dance 1.1s steps(8) infinite; }
@keyframes kris-idle { to { background-position: -256px 0; } }
@keyframes kris-sip { to { background-position: -384px 0; } }
@keyframes kris-dance { to { background-position: -608px 0; } }
/* Cat: 56px frames, facing west so it looks at Kris. sleep 6f, sit 8f, dance 8f. */
.sprite.cat { width: 56px; height: 56px; left: 8px; background-image: url('../img/cat/west.png'); }
.sprite.cat.sleep { background-image: url('../img/cat/sleep.png'); animation: cat-sleep 2.4s steps(4) infinite; }
.sprite.cat.sit { background-image: url('../img/cat/sit.png'); animation: cat-sit 1.6s steps(8) infinite; }
.sprite.cat.dance { background-image: url('../img/cat/dance.png'); animation: cat-dance 0.9s steps(8) infinite; }
@keyframes cat-sleep { to { background-position: -224px 0; } }
@keyframes cat-sit { to { background-position: -448px 0; } }
@keyframes cat-dance { to { background-position: -448px 0; } }
.sprite.hyper { animation-duration: 0.4s !important; }

.lantern { position: absolute; top: 26px; left: -4px; z-index: 2; width: 48px; height: 64px; }
.lantern img { position: relative; z-index: 1; display: block; }
.lantern-glow {
  position: absolute; left: -36px; top: -8px; width: 120px; height: 120px; border-radius: 50%;
  background: radial-gradient(circle, rgba(255,200,90,0.45) 0, rgba(255,166,61,0.18) 35%, rgba(255,166,61,0) 70%);
  animation: lantern 2.2s steps(3) infinite; opacity: 0.55;
}
body.playing .lantern-glow { opacity: 1; }
@keyframes lantern { 50% { transform: scale(1.08); } }

.mast-title { text-align: center; min-width: 0; position: relative; z-index: 1; padding-bottom: 26px; }
.logo { margin: 0; font-family: var(--font-logo); font-weight: 700; line-height: 1; }
.logo-line { display: block; position: relative; letter-spacing: 2px; }
.logo-line.l1 {
  font-size: 58px; color: var(--green-bright);
  text-shadow: 3px 3px 0 var(--pine), 6px 6px 0 var(--shadow), 0 0 18px rgba(126,224,129,0.35);
}
.logo-line.l2 {
  font-size: 34px; margin-top: 10px; color: var(--red); letter-spacing: 10px; padding-left: 10px;
  text-shadow: 3px 3px 0 var(--red-deep), 5px 5px 0 var(--shadow), 0 0 14px rgba(215,56,63,0.4);
}
.tagline { font-family: var(--font-ui); font-size: 8px; color: var(--gold); margin-top: 14px; line-height: 2; }
.onair {
  display: inline-block; font-family: var(--font-ui); font-size: 8px; color: #fff;
  background: var(--red); padding: 4px 8px; border: 2px solid #fff; margin-right: 8px;
  box-shadow: 0 0 10px var(--red); vertical-align: middle;
}
.onair.off { background: #444; box-shadow: none; }
.onair .dot { display: inline-block; width: 8px; height: 8px; background: #fff; margin-right: 4px; animation: blink 1s steps(1) infinite; }

/* ---------- TICKER ---------- */
.ticker {
  overflow: hidden; white-space: nowrap; margin: 14px 0;
  background: var(--shadow); border: var(--px) solid var(--red-deep); color: var(--gold);
  font-family: var(--font-ui); font-size: 10px; line-height: 2.6;
  box-shadow: inset 0 0 12px rgba(243,198,79,0.2);
}
.ticker-track { display: inline-block; padding-left: 100%; animation: ticker 80s linear infinite; }
.ticker:hover .ticker-track { animation-play-state: paused; }
@keyframes ticker { to { transform: translateX(-100%); } }

/* ---------- COLUMNS ---------- */
.columns { display: grid; grid-template-columns: 236px 1fr 236px; gap: 14px; align-items: start; }
.sidebar { display: flex; flex-direction: column; gap: 14px; }
.main { display: flex; flex-direction: column; gap: 14px; min-width: 0; }

/* ---------- PANELS ---------- */
.panel {
  background: var(--panel); border: var(--px) solid var(--wood);
  box-shadow: 0 0 0 2px var(--shadow), 4px 4px 0 2px var(--shadow), inset 0 0 0 2px rgba(255,255,255,0.04);
  padding: 10px 12px 12px; position: relative;
}
.panel-title {
  font-family: var(--font-ui); font-size: 10px; color: var(--cream);
  background: linear-gradient(90deg, var(--pine), #163d28);
  margin: -10px -12px 10px; padding: 8px 10px; letter-spacing: 1px;
  border-bottom: 2px solid var(--red);
  text-shadow: 2px 2px 0 var(--shadow);
}
.panel-hint { float: right; color: var(--gold); font-size: 7px; font-weight: normal; line-height: 1.6; }
.panel p { margin: 6px 0; }
.panel-art { display: block; margin: 4px auto 6px; width: 48px; height: 48px; object-fit: contain; }
.navlist { list-style: none; margin: 0; padding: 0; }
.navlist li { margin: 0; }
.navlist a {
  display: flex; align-items: center; gap: 8px; text-decoration: none; padding: 5px 6px;
  color: var(--ink); border-bottom: 2px dotted rgba(169,181,160,0.25);
}
.navlist a:hover { background: var(--panel-2); color: var(--gold); }
.navlist img { flex: none; object-fit: contain; }
.stream-url { word-break: break-all; font-size: 15px; }

/* pixel buttons */
.pxbtn {
  display: inline-block; font-family: var(--font-ui); font-size: 9px; color: var(--ink); cursor: pointer;
  background: var(--panel-2); border: 0; padding: 9px 10px; text-decoration: none; line-height: 1.4;
  box-shadow: inset -3px -3px 0 var(--shadow), inset 3px 3px 0 rgba(255,255,255,0.22), 0 0 0 2px var(--shadow);
  text-transform: uppercase;
}
.pxbtn:hover { background: var(--red-deep); color: var(--gold); }
.pxbtn:active { box-shadow: inset 3px 3px 0 var(--shadow), inset -3px -3px 0 rgba(255,255,255,0.15), 0 0 0 2px var(--shadow); transform: translate(1px,1px); }
.pxbtn.small-btn { display: block; width: 100%; margin-top: 8px; text-align: center; }
.pxbtn.tiny { padding: 6px 7px; font-size: 8px; }
.pxbtn.on { background: var(--red-deep); color: #fff; }
.pxbtn.alt { background: var(--pine); }
.sleep-row { display: flex; gap: 4px; justify-content: center; flex-wrap: wrap; margin: 6px 0; }

.odometer {
  display: inline-block; font-family: var(--font-ui); font-size: 14px; letter-spacing: 3px;
  background: #000; color: var(--green-bright); border: 3px solid #555; padding: 6px 8px; margin: 4px 0;
  text-shadow: 0 0 6px var(--green-bright);
}
.odometer.gold { color: var(--gold); text-shadow: 0 0 6px var(--gold); font-size: 20px; letter-spacing: 6px; }
.mug-steam { display: block; margin: 4px auto 0; animation: steam 1.6s steps(2) infinite; }
@keyframes steam { 50% { transform: translateY(-2px); } }
.star-twinkle { display: block; margin: 4px auto 0; animation: twinkle 1.2s steps(2) infinite; }
@keyframes twinkle { 50% { transform: scale(0.85); filter: brightness(1.4); } }
.countdown .small { margin: 4px 0; }

/* ---------- CONSOLE (PLAYER) ---------- */
.console {
  background: linear-gradient(180deg, #3a2a1c, #1a120b);
  border: var(--px) solid var(--wood-2);
  box-shadow: 0 0 0 2px var(--shadow), 0 0 0 6px var(--pine), 6px 6px 0 6px var(--shadow), 0 0 30px rgba(255,166,61,0.18);
  padding: 0; overflow: hidden;
}
.console-top {
  display: flex; align-items: center; gap: 10px; padding: 8px 12px;
  background: linear-gradient(90deg, var(--red-deep), #5a1a20 60%, #3a2a1c);
  border-bottom: var(--px) solid var(--shadow);
  font-family: var(--font-ui); font-size: 10px; color: #fff; text-shadow: 2px 2px 0 var(--shadow);
}
.console-brand .ver { color: var(--gold); margin-left: 4px; font-size: 8px; }
.console-leds { display: flex; gap: 6px; margin-left: 4px; }
.led { width: 10px; height: 10px; border: 2px solid var(--shadow); background: #333; }
.led.pwr.on { background: var(--red); box-shadow: 0 0 8px var(--red); }
.led.sig.on { background: var(--green-bright); box-shadow: 0 0 8px var(--green-bright); animation: blink 0.6s steps(1) infinite; }
.led.live { background: var(--gold); box-shadow: 0 0 8px var(--gold); animation: blink 1s steps(1) infinite; }
.console-status { margin-left: auto; color: var(--gold); }
.console-body { padding: 12px; }

.crt {
  background: #0d0703; border: var(--px) solid #4a3a2a; padding: 6px;
  box-shadow: inset 0 0 0 2px #000, inset 0 0 30px rgba(255,166,61,0.1);
}
.crt-inner { background: var(--lcd); color: var(--lcd-ink); text-shadow: 0 0 6px rgba(255,179,71,0.6); padding: 6px; }
.crt-row { display: flex; align-items: center; gap: 10px; }
.lcd-time { font-family: var(--font-ui); font-size: 22px; min-width: 110px; }
.viz { flex: 1; height: 48px; background: #0a0502; border: 2px solid #3a2410; min-width: 0; }
.lcd-right { display: flex; flex-direction: column; gap: 4px; align-items: flex-end; }
.lcd-tag { font-family: var(--font-ui); font-size: 8px; border: 2px solid var(--lcd-ink); padding: 3px 5px; }
.lcd-ticker { overflow: hidden; white-space: nowrap; margin-top: 6px; border-top: 2px dashed rgba(255,179,71,0.3); padding-top: 4px; font-family: var(--font-ui); font-size: 10px; line-height: 1.8; }
.lcd-ticker-track { display: inline-block; padding-left: 100%; animation: ticker 24s linear infinite; }

.track-strip {
  display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin: 12px 0 8px;
  font-family: var(--font-ui);
}
.track-label { font-size: 9px; color: var(--ink-dim); }
.track-name { font-size: 16px; color: var(--gold); text-shadow: 0 0 10px var(--amber), 3px 3px 0 var(--shadow); word-break: break-word; }
.genre-tag { font-size: 8px; color: var(--shadow); background: var(--green-bright); padding: 3px 6px; border: 2px solid var(--pine-2); }
.genre-tag:empty { display: none; }

/* candy-cane progress bar with a mug on the end */
.hpbar { position: relative; display: flex; align-items: center; gap: 6px; }
.hp-cup { width: 24px; height: 24px; flex: none; }
.hpbar-track { position: relative; flex: 1; height: 22px; background: #0b0a07; border: 3px solid var(--ink); box-shadow: 0 0 0 2px var(--shadow); overflow: hidden; }
.hpbar-fill {
  height: 100%; width: 0; transition: width 1s linear;
  background: repeating-linear-gradient(135deg, #fff5e0 0 6px, var(--red) 6px 12px);
}
.hpbar.low .hpbar-fill { background: repeating-linear-gradient(135deg, var(--red) 0 6px, var(--red-deep) 6px 12px); animation: blink 1s steps(1) infinite; }
.hpbar-label { position: absolute; left: 36px; right: 6px; top: 0; bottom: 0; display: flex; justify-content: space-between; align-items: center; padding: 0 6px; font-size: 15px; color: #fff; text-shadow: 1px 1px 0 #000, -1px -1px 0 #000, 1px -1px 0 #000, -1px 1px 0 #000; pointer-events: none; }

.controls { display: flex; align-items: center; gap: 8px; margin-top: 12px; flex-wrap: wrap; }
.abtn {
  width: 48px; height: 44px; font-size: 18px; color: #fff; cursor: pointer; border: 0;
  background: #6a5a48; font-family: var(--font-body);
  box-shadow: inset -4px -4px 0 var(--shadow), inset 4px 4px 0 rgba(255,255,255,0.3), 0 0 0 2px var(--shadow);
}
.abtn.play { background: var(--red); }
.abtn.stop { background: #4a3a2c; }
.abtn.mute { background: var(--pine); }
.abtn:hover { filter: brightness(1.15); }
.abtn:active, .abtn.active { box-shadow: inset 4px 4px 0 var(--shadow), inset -4px -4px 0 rgba(255,255,255,0.15), 0 0 0 2px var(--shadow); transform: translate(1px,1px); }
.abtn.play.active { background: var(--green); color: #052; }
.vol { display: flex; align-items: center; gap: 6px; font-family: var(--font-ui); font-size: 9px; }
.vol input[type=range] { width: 120px; accent-color: var(--red); }
.vol-val { font-size: 16px; min-width: 2ch; color: var(--gold); }
.status-pill {
  margin-left: auto; font-family: var(--font-ui); font-size: 9px; padding: 6px 8px;
  background: var(--shadow); color: var(--ink-dim); border: 2px solid var(--ink-dim);
}
.status-pill.playing { color: var(--green-bright); border-color: var(--green-bright); box-shadow: 0 0 8px rgba(126,224,129,0.5); }
.status-pill.error { color: var(--red); border-color: var(--red); }

.np { display: flex; gap: 12px; align-items: center; padding: 12px; background: rgba(0,0,0,0.4); border-top: var(--px) solid var(--shadow); }
.np-art-wrap { position: relative; flex: none; }
.np-art { width: 96px; height: 96px; border: 3px solid var(--ink); box-shadow: 4px 4px 0 var(--shadow); background: #000; object-fit: cover; }
body.playing .np-art.vinyl { animation: spin 4s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.np-art-badge { position: absolute; right: -6px; bottom: -6px; font-family: var(--font-ui); font-size: 8px; background: var(--red); color: #fff; padding: 3px 5px; border: 2px solid #fff; }
.np-text { min-width: 0; }
.np-label { font-family: var(--font-ui); font-size: 9px; color: var(--red); margin-bottom: 6px; }
.np-title { font-size: 24px; color: var(--ink); line-height: 1.1; word-break: break-word; }
.np-artist { font-size: 18px; color: var(--gold); }
.np-sub { margin-top: 4px; }

/* ---------- FEATURED ---------- */
.featured { border-color: var(--red-deep); }
.feat { display: grid; grid-template-columns: 172px 1fr; gap: 16px; align-items: start; }
.feat-art-link { display: block; }
.feat-art { width: 172px; height: 256px; border: 3px solid var(--ink); box-shadow: 6px 6px 0 var(--shadow); display: block; }
.feat-art-link:hover .feat-art { border-color: var(--gold); }
.feat-text { min-width: 0; }
.feat-kicker { font-family: var(--font-ui); font-size: 8px; color: var(--green-bright); }
.feat-title { font-family: var(--font-logo); font-size: 40px; color: var(--gold); margin: 6px 0 2px; line-height: 1; text-shadow: 3px 3px 0 var(--wood-2), 5px 5px 0 var(--shadow); }
.feat-tag { font-family: var(--font-ui); font-size: 9px; color: var(--cream); margin: 4px 0 10px; line-height: 1.8; }
.beliefs { list-style: none; margin: 8px 0; padding: 0; font-size: 17px; color: var(--ink-dim); }
.beliefs li { display: flex; gap: 8px; align-items: flex-start; padding: 3px 0; border-bottom: 2px dotted rgba(169,181,160,0.2); }
.beliefs img { flex: none; margin-top: 1px; }
.beliefs b { margin-right: 4px; }
.feat-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }

/* ---------- UP NEXT / HISTORY ---------- */
.next { display: flex; gap: 12px; align-items: center; }
.next-art { width: 64px; height: 64px; border: 3px solid var(--ink-dim); flex: none; object-fit: cover; background: #000; }
.next-art.cassette { object-fit: contain; padding: 6px; }
.next-title { font-size: 22px; }
.next-when { color: var(--gold); }
.history-table { width: 100%; border-collapse: collapse; font-size: 18px; }
.history-table th { font-family: var(--font-ui); font-size: 8px; color: var(--gold); text-align: left; padding: 4px 6px; border-bottom: 2px solid var(--wood); }
.history-table td { padding: 4px 6px; border-bottom: 2px dotted rgba(169,181,160,0.2); vertical-align: top; }
.history-table td.rank { font-family: var(--font-ui); font-size: 9px; color: var(--gold); }
.history-table td.t { color: var(--ink-dim); white-space: nowrap; }
.history-table td.v { color: var(--ink-dim); white-space: nowrap; }
.stat-table { width: 100%; border-collapse: collapse; font-size: 18px; }
.stat-table td { padding: 3px 4px; border-bottom: 2px dotted rgba(169,181,160,0.2); }
.stat-table td:last-child { text-align: right; color: var(--gold); }

/* ---------- POSTS FROM THE PORCH ---------- */
.posts { list-style: none; margin: 0; padding: 0; }
.posts li { padding: 8px 0; border-bottom: 2px dotted rgba(169,181,160,0.25); }
.posts li:last-child { border-bottom: 0; }
.post-date { font-family: var(--font-ui); font-size: 7px; color: var(--green-bright); margin-bottom: 4px; }
.post-title { font-size: 22px; line-height: 1.1; }
.post-title a { color: var(--ink); text-decoration: none; border-bottom: 2px dotted var(--gold); }
.post-title a:hover { color: var(--gold); }
.post-excerpt { font-size: 17px; color: var(--ink-dim); margin-top: 3px; }

/* ---------- ORNAMENTS ---------- */
.orn-wrap { display: flex; gap: 14px; align-items: flex-start; }
.orn-tree { flex: none; width: 96px; height: 128px; }
.trophy-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; flex: 1; min-width: 0; }
.trophy {
  display: flex; gap: 8px; align-items: center; padding: 6px; background: var(--bg);
  border: 2px solid var(--wood); opacity: 0.45; filter: grayscale(1);
}
.trophy.unlocked { opacity: 1; filter: none; border-color: var(--gold); box-shadow: 0 0 10px rgba(243,198,79,0.35); }
.trophy img { width: 32px; height: 32px; flex: none; object-fit: contain; }
.trophy-name { font-family: var(--font-ui); font-size: 8px; color: var(--gold); line-height: 1.5; }
.trophy-desc { font-size: 14px; color: var(--ink-dim); line-height: 1.1; }

/* ---------- ABOUT ---------- */
.about-art { float: right; margin: 0 0 8px 12px; width: 128px; height: 96px; }
.about::after { content: ''; display: block; clear: both; }

/* ---------- PORCH STATUS ---------- */
.porch .stat-table td:last-child { color: var(--green-bright); }
.porch .stat-table td.off { color: var(--ink-dim); }

/* ---------- PORCH AD ---------- */
.porch-ad { text-align: center; border-color: var(--amber); background: #1d130a; }
.ad-label { font-family: var(--font-ui); font-size: 7px; color: var(--ink-dim); margin: -4px 0 6px; }
.ad-cups { display: flex; justify-content: center; gap: 8px; }
.ad-cups img { width: 32px; height: 32px; }
.ad-brand { font-family: var(--font-logo); font-size: 28px; color: var(--amber); text-shadow: 0 0 8px var(--amber), 3px 3px 0 var(--shadow); line-height: 1; margin: 6px 0; animation: neon 3s steps(1) infinite; }
.ad-brand small { font-size: 14px; color: var(--cream); letter-spacing: 6px; text-shadow: 2px 2px 0 var(--shadow); }
@keyframes neon { 0%, 93%, 96%, 100% { opacity: 1; } 94%, 97% { opacity: 0.45; } }
.ad-copy { font-size: 17px; color: var(--ink-dim); }
.ad-cta { display: block; font-family: var(--font-ui); font-size: 8px; color: var(--green-bright); margin: 8px 0 4px; text-decoration: none; }
.ad-fine { font-size: 13px; color: var(--ink-dim); opacity: 0.8; }

/* ---------- BADGES ---------- */
.badges { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; }
.badge {
  width: 88px; height: 31px; display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--font-ui); font-size: 6px; line-height: 1.4; text-align: center;
  border: 2px solid; color: #fff; text-shadow: 1px 1px 0 #000;
}
.b-holiday { background: var(--red-deep); border-color: var(--red); }
.b-mp3 { background: #0a3d62; border-color: var(--ice); }
.b-porch { background: #3a2a10; border-color: var(--gold); color: var(--gold); }
.b-cast { background: #1b5e20; border-color: var(--green-bright); }
.b-cf { background: #f38020; border-color: #ffd0a0; color: #000; text-shadow: none; }
.b-fire { background: #222; border-color: #999; }

/* ---------- THE YARD ---------- */
.yard {
  position: relative; height: 80px; margin: 16px 0 0; overflow: hidden;
  background:
    linear-gradient(180deg, transparent 0 30px, #f4f7ff 30px 34px, #dfe8f5 34px 40px, #c9d6ea 40px 44px, transparent 44px),
    linear-gradient(180deg, transparent 0 44px, #0e1a12 44px);
  border-top: 2px solid var(--wood-2);
}
.yard::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 36px;
  background: repeating-linear-gradient(90deg, transparent 0 22px, rgba(255,255,255,0.06) 22px 24px);
}
.yard-snowman { position: absolute; left: 4%; bottom: 6px; width: 32px; height: 48px; }
.yard-walker {
  position: absolute; bottom: 4px; left: -80px; width: 56px; height: 56px;
  background: url('../img/cat/walk.png') no-repeat 0 0; image-rendering: pixelated;
  animation: cat-walk 0.8s steps(8) infinite, stroll 34s linear infinite;
}
@keyframes cat-walk { to { background-position: -448px 0; } }
@keyframes stroll { 0% { left: -80px; } 100% { left: 110%; } }
.yard-sleigh { position: absolute; bottom: 12px; left: -80px; width: 64px; height: 40px; animation: glide 26s linear infinite 9s, bump 0.6s steps(2) infinite; }
@keyframes glide { 0% { left: -80px; } 100% { left: 110%; } }
@keyframes bump { 50% { transform: translateY(-2px); } }

/* ---------- FOOTER ---------- */
.footer { text-align: center; margin: 20px 0 10px; color: var(--ink-dim); font-size: 17px; }
.footer p { margin: 4px 0; }

/* ---------- ATTRACT SCREEN ---------- */
.attract {
  position: fixed; inset: 0; z-index: 100; display: flex; align-items: center; justify-content: center;
  background: rgba(4,8,6,0.92);
}
.attract.hidden { display: none; }
.attract-inner { text-align: center; padding: 24px 28px; border: var(--px) solid var(--green-bright); background: var(--bg2); box-shadow: 0 0 0 4px var(--shadow), 0 0 0 8px var(--wood), 0 0 40px rgba(126,224,129,0.35); max-width: 90vw; }
.attract-scene { position: relative; width: 320px; height: 224px; margin: 0 auto 6px; max-width: 100%; }
.attract-cabin { width: 320px; height: 224px; display: block; max-width: 100%; height: auto; }
.attract-lantern { position: absolute; right: 18px; top: 8px; width: 48px; height: 64px; animation: sway 2.6s steps(3) infinite; }
.attract-lantern.lit { filter: drop-shadow(0 0 12px rgba(255,200,90,0.9)); }
@keyframes sway { 50% { transform: rotate(4deg); } }
.attract-title { font-family: var(--font-logo); font-size: 44px; color: var(--green-bright); text-shadow: 3px 3px 0 var(--pine), 6px 6px 0 var(--shadow); line-height: 1; margin: 10px 0; }
.attract-title small { display: block; font-size: 24px; color: var(--red); letter-spacing: 10px; padding-left: 10px; margin-top: 8px; text-shadow: 2px 2px 0 var(--red-deep), 4px 4px 0 var(--shadow); }
.attract-copy { font-family: var(--font-ui); font-size: 9px; color: var(--gold); line-height: 2; margin: 10px 0; }
.attract-start { font-family: var(--font-ui); font-size: 12px; color: #fff; background: var(--red-deep); border: 0; padding: 14px 20px; cursor: pointer; box-shadow: inset -4px -4px 0 var(--shadow), inset 4px 4px 0 rgba(255,255,255,0.3), 0 0 0 3px var(--shadow); }
.attract-start:hover { background: var(--red); }
.attract-fine { font-family: var(--font-ui); font-size: 7px; color: var(--ink-dim); margin-top: 12px; }

/* ---------- TOASTS ---------- */
.toasts { position: fixed; left: 50%; bottom: 20px; transform: translateX(-50%); z-index: 90; display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; }
.toast {
  display: flex; align-items: center; gap: 10px; font-family: var(--font-ui); font-size: 9px; color: var(--gold);
  background: var(--bg2); border: 3px solid var(--gold); padding: 10px 14px; box-shadow: 4px 4px 0 var(--shadow);
  animation: toast-in 0.2s steps(3) both; max-width: 90vw;
}
.toast img { width: 32px; height: 32px; object-fit: contain; }
.toast small { display: block; color: var(--ink-dim); font-size: 7px; margin-top: 4px; }
@keyframes toast-in { from { transform: translateY(20px); opacity: 0; } }

/* ---------- SNOW DAY (Konami) ---------- */
.snowday { position: fixed; inset: 0; z-index: 95; pointer-events: none; display: none; align-items: center; justify-content: center; }
body.snow-day .snowday { display: flex; }
.snowday-text { font-family: var(--font-logo); font-size: 72px; color: #fff; text-shadow: 0 0 20px var(--ice), 6px 6px 0 var(--shadow); animation: snow-pop 0.5s steps(4) 6 both; opacity: 0; }
@keyframes snow-pop { 0% { transform: scale(0.5); opacity: 1; } 100% { transform: scale(1.4); opacity: 0; } }
body.snow-day .masthead { animation: twinkle-lights 0.4s steps(2) infinite; }
@keyframes twinkle-lights { 50% { box-shadow: 0 0 0 var(--px) var(--shadow), 0 0 0 calc(var(--px) * 2) var(--red), 6px 6px 0 calc(var(--px) * 2) var(--shadow), 0 0 30px var(--gold); } }
body.snow-day .sprite { animation-duration: 0.3s !important; }
body.snow-day .logo-line.l1 { color: var(--ice); }
.gift-drop { position: fixed; top: -80px; width: 32px; height: 32px; background: url('../img/gift.png') no-repeat 0 0; image-rendering: pixelated; animation: gift-fall 2.5s linear forwards, tumble 0.8s steps(4) infinite; z-index: 94; pointer-events: none; }
.gift-drop.alt { background-image: url('../img/ornament.png'); }
.gift-drop.alt2 { background-image: url('../img/candycane.png'); }
@keyframes gift-fall { to { top: 105vh; } }
@keyframes tumble { to { transform: rotate(360deg); } }

/* ---------- REDUCED MOTION ---------- */
@media (prefers-reduced-motion: reduce) {
  .ticker-track, .lcd-ticker-track, .yard-walker, .yard-sleigh, .mug-steam, .star-twinkle, .attract-lantern, .lantern-glow { animation: none !important; }
  .sprite { animation-duration: 2s !important; }
  .snow { display: none; }
}

/* ---------- RESPONSIVE ---------- */
@media (max-width: 1000px) {
  .columns { grid-template-columns: 1fr 1fr; }
  .main { grid-column: 1 / -1; order: -1; }
}
@media (max-width: 720px) {
  .feat { grid-template-columns: 1fr; }
  .feat-art { margin: 0 auto; }
  .orn-wrap { flex-direction: column; align-items: center; }
}
@media (max-width: 640px) {
  .page { padding: 10px; }
  .masthead { grid-template-columns: 1fr 1fr; padding: 10px 8px 0; }
  .mast-title { grid-column: 1 / -1; order: -1; padding-bottom: 10px; }
  .stage { width: 96px; height: 96px; }
  .sprite { transform: scale(1.5); }
  .lantern { top: 18px; left: -8px; transform: scale(0.75); transform-origin: top left; }
  .logo-line.l1 { font-size: 36px; }
  .logo-line.l2 { font-size: 22px; letter-spacing: 6px; padding-left: 6px; }
  .tagline { font-size: 7px; }
  .columns { grid-template-columns: 1fr; }
  .lcd-time { font-size: 16px; min-width: 80px; }
  .lcd-right { display: none; }
  .np { flex-direction: column; text-align: center; }
  .about-art { float: none; display: block; margin: 0 auto 8px; }
  .attract-title { font-size: 32px; }
  .attract-title small { font-size: 16px; letter-spacing: 6px; }
  .attract-scene { height: auto; }
  .attract-lantern { right: 6px; top: 0; }
  .snowday-text { font-size: 36px; }
  .status-pill { margin-left: 0; width: 100%; text-align: center; }
  .feat-title { font-size: 30px; }
}
