:root { color-scheme: dark; font-family: system-ui, sans-serif; color: #fff7e9; background: #13283d; }
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0;
  min-height: 100vh;
  background: url("snowflakes.svg") repeat center top / 340px 290px,
    radial-gradient(ellipse at top, #2c4a63, #142a40 32rem, #101e30);
}
main { width: min(100%, 690px); padding: 20px 16px 36px; margin-inline: auto; }
header {
  text-align: center;
  padding: 16px 12px clamp(64px, 13vw, 102px);
  margin-bottom: 12px;
  border: 1px solid #a98e64;
  border-radius: 19px;
  background:
    radial-gradient(ellipse at 50% 22%, #071422e8 0%, #071422a3 33%, #0714221c 68%),
    url("victorian-street.webp") center 58% / cover no-repeat #13283d;
  text-shadow: 0 2px 4px #071422, 0 0 10px #071422;
}
@media (max-width: 440px) {
  header {
    background-position: center, 65% center;
  }
}
a { color: #ffe19b; }
.brand { text-decoration: none; font-weight: 750; letter-spacing: .06em; }
.eyebrow { color: #ffe19b; font-size: .76rem; font-weight: 750; letter-spacing: .13em; text-transform: uppercase; margin: 22px 0 4px; }
h1, h2 { font-family: Georgia, serif; font-weight: 500; margin: 5px 0 8px; }
h1 { font-size: clamp(2.65rem, 10vw, 4.2rem); line-height: .99; }
header > p:not(.eyebrow) { margin: 12px auto 0; max-width: 32ch; line-height: 1.45; }
.progress { color: #ffe19b; font-weight: 700; }
.calendar, .play { border: 1px solid #728a9e; border-radius: 19px; padding: 16px; }
.calendar { border-color: #a98e64; background: url("snowflakes.svg") repeat left top / 300px auto, #192c3e; }
.calendar > p { margin: 0 0 15px; color: #dbe8ef; }
.street { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 12px 8px; }
.house { --wall: #673b42; --roof: #e7edf3; position: relative; display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 5px; padding: 8px 5px; margin-top: 17px; border-radius: 4px 4px 6px 6px; background:
    repeating-linear-gradient(0deg, #18121b38 0 1px, transparent 1px 9px),
    repeating-linear-gradient(90deg, #18121b28 0 1px, transparent 1px 17px),
    var(--wall); }
.house:nth-child(3n+2) { --wall: #7a4f46; }
.house:nth-child(3n) { --wall: #624147; }
.house::before { content: ''; position: absolute; left: 0; right: 0; top: -16px; height: 21px; background: var(--roof); clip-path: polygon(50% 0, 100% 85%, 100% 100%, 0 100%, 0 85%); }
.window { position: relative; display: grid; place-items: center; min-height: 44px; border: 1px solid #9bafbf; border-radius: 12px 12px 4px 4px; font: 700 .92rem system-ui; background: linear-gradient(90deg, transparent 48%, #b3c7d51a 48% 52%, transparent 52%), #253a4f; color: #cbd9e5; }
button.window { cursor: pointer; background: linear-gradient(135deg, #fff1cb, #f3bb67); color: #402715; border-color: #ffedc8; }
button.window[aria-expanded="true"] { outline: 2px solid white; outline-offset: 1px; }
button.window.lit { background: #ffc65d; box-shadow: 0 0 15px #ffc65d88; }
button.window.lit::after { content: '✦'; position: absolute; right: 3px; top: 1px; font-size: .62rem; }
.play { margin-top: 14px; background: #213c4f; }
.play .eyebrow { margin-top: 0; }
.play p { line-height: 1.5; }
details, .rules { margin: 12px 0; padding: 11px 13px; border-radius: 10px; background: #152d42; }
summary { cursor: pointer; font-weight: 750; }
details p { margin-bottom: 0; }
.choices { display: grid; gap: 7px; }
.choice, .primary { min-height: 46px; padding: 9px 12px; border: 1px solid #92a9b9; border-radius: 10px; font: 750 1rem system-ui; cursor: pointer; }
.choice { text-align: left; background: #294b60; color: #fff7e9; }
.choice span { display: block; font-size: .75rem; color: #dce7f1; }
.choice[aria-pressed="true"], .primary { background: #ffe19b; color: #332318; }
.choice[aria-pressed="true"] span { color: #543918; }
.rules h3 { margin-top: 0; }
#lit-message { color: #ffe19b; margin-bottom: 0; }
footer { text-align: center; color: #dbe8ef; font-size: .88rem; margin-top: 17px; }
:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
.window[data-frame] { border: 2px solid var(--frame); box-shadow: inset 0 0 0 1px #101e30; }
.window[data-frame="cranberry"] { --frame: #db7782; }
.window[data-frame="gold"] { --frame: #e5bf6e; }
.window[data-frame="pine"] { --frame: #78c09d; }
.window[data-frame="frost"] { --frame: #8cc8e7; }
.window[data-frame="plum"] { --frame: #bc9cdb; }
.window[data-frame="copper"] { --frame: #e3a17b; }
.window[data-frame="rose"] { --frame: #e5a9c2; }
