:root {
  --lcd: #c4c8a6;
  --seg: #1d2216;
  --case: #eee3c3;
  --red: #a93129;
  --ink: #302b22;
  --paper: #fbf6e8;
}
* { box-sizing: border-box; }
html { min-width: 280px; background: #244b3c; }
body {
  margin: 0;
  min-height: 100vh;
  padding: 32px 28px 100px;
  font-family: "PT Sans", system-ui, sans-serif;
  color: var(--ink);
  background:
    radial-gradient(ellipse at 50% 10%, #ffffff36, transparent 60%),
    linear-gradient(180deg, #e7e5d9 0, #dfddcf 330px, #97a28d 330px, #97a28d 334px, #345b47 334px, #244b3c 100%);
}
button, input, select, textarea { font: inherit; }
button { -webkit-tap-highlight-color: transparent; }
button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 3px solid #986023;
  outline-offset: 5px;
}
button:disabled { cursor: not-allowed; }
[hidden] { display: none !important; }
.wrap { max-width: 1000px; margin: 0 auto; }
.page-header { display: flex; align-items: center; justify-content: space-between; gap: 20px; max-width: 760px; margin: 0 auto 22px; padding: 0 8px; }
.graffiti { font-family: Neucha, cursive; color: #52617c; font-size: 25px; transform: rotate(-3deg); }
.graffiti b { color: var(--red); font-weight: 400; }
.edition { margin: 0; text-align: right; font-size: 14px; font-weight: 700; }
.edition span { display: block; font-size: 11px; font-weight: 400; letter-spacing: .12em; text-transform: uppercase; margin-top: 3px; }

/* A physical CSS 3D shell: rear casing, seam, face and raised controls. */
.game-section { padding-bottom: 40px; }
.console-stage { perspective: 1400px; max-width: 760px; margin: 0 auto; padding: 12px 0 28px; }
.console {
  --tilt-x: 7deg;
  --tilt-y: -5deg;
  position: relative;
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr) 74px;
  column-gap: 22px;
  padding: 25px 30px 20px;
  border: 1px solid #fff3d8;
  border-radius: 31px;
  background: linear-gradient(125deg, #f6edce 0%, #e9ddba 46%, #d5c49b 100%);
  box-shadow: inset 0 3px 2px #fff9e7, inset 3px 0 3px #ffffff70, inset -3px -3px 5px #ab956c;
  transform-style: preserve-3d;
  transform: rotateX(var(--tilt-x)) rotateY(var(--tilt-y));
  transition: transform .35s ease-out;
}
.console::before {
  content: "";
  position: absolute;
  inset: 1px;
  border: 1px solid #fff6dc90;
  border-radius: 30px;
  background: repeating-linear-gradient(90deg, #ffffff08 0 1px, transparent 1px 3px);
  pointer-events: none;
  transform: translateZ(1px);
}
.case-back, .case-edge { position: absolute; inset: 0; border-radius: 31px; pointer-events: none; }
.case-back {
  background: #ac9872;
  transform: translateZ(-22px);
  box-shadow: 0 1px 0 #786746, 0 2px 0 #99835c, 0 3px 0 #8d7852, 0 4px 0 #786746, 8px 23px 20px #12271c55, 15px 45px 48px #10261d55;
}
.case-edge {
  background: #d0bd94;
  transform: translateZ(-10px);
  box-shadow: 0 1px 0 1px #e4d4af, 0 3px 0 1px #c7b58e, 0 5px 0 1px #b3a07a, 0 7px 0 1px #7f6b49, 0 9px 0 #bba67e, 0 11px 0 #b09a72;
}
.screw { position: absolute; width: 9px; height: 9px; border-radius: 50%; background: linear-gradient(135deg, #b6ab8e, #e7dcc0 48%, #9a8e71); box-shadow: inset 0 0 2px #665b43, 0 1px 0 #fff9; transform: translateZ(2px); }
.screw::after { content: ""; position: absolute; left: 2px; right: 2px; top: 4px; height: 1px; background: #80745c; transform: rotate(-30deg); }
.screw-tl { top: 13px; left: 15px; }.screw-tr { top: 13px; right: 15px; }.screw-bl { bottom: 14px; left: 15px; }.screw-br { bottom: 14px; right: 15px; }
.brand { grid-column: 1 / -1; display: flex; justify-content: space-between; align-items: center; gap: 12px; margin: 0 5px 12px; font: 13px "Russo One", sans-serif; color: var(--red); letter-spacing: .17em; text-shadow: 0 1px #fff9; transform: translateZ(2px); }
.brand small { color: #73674d; letter-spacing: .08em; font: 700 11px "PT Sans", sans-serif; }
.title { grid-column: 1 / -1; margin: 0 0 20px; color: var(--red); font: 30px/1.1 "Russo One", sans-serif; text-align: center; letter-spacing: .015em; text-shadow: 0 1px 0 #fff6, 0 -1px 0 #752c23; transform: translateZ(2px); }
.bezel { grid-column: 2; grid-row: 3; padding: 12px; border: 1px solid #5e5849; border-radius: 15px; background: linear-gradient(145deg, #33332c, #555344); box-shadow: 0 2px 0 #fff4, 0 -2px 2px #a28f6b, inset 0 3px 5px #1119, inset 0 -2px 1px #78715b; transform: translateZ(3px); }
.screen { position: relative; overflow: hidden; border-radius: 5px; background: radial-gradient(ellipse at 30% 10%, #d4d8bb, var(--lcd) 58%, #aeb48f); box-shadow: inset 3px 5px 9px #3b422b70, inset -1px -1px 3px #fff5; touch-action: manipulation; cursor: pointer; }
.screen svg { display: block; width: 100%; height: auto; }
.screen::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(125deg, #fff3, #fff0 36%, #fff0 65%, #fff1), repeating-linear-gradient(0deg, #0000 0 2px, #00000005 2px 3px); box-shadow: inset 2px 4px 8px #31382250; }
.seg { fill: var(--seg); opacity: .07; transition: opacity .04s; }.seg.on { opacity: 1; }
.lim { fill: none; stroke: var(--seg); stroke-width: 6; stroke-linecap: round; }
.net { fill: none; stroke: var(--seg); stroke-width: 2; stroke-linejoin: round; }
.dig { font-family: "Share Tech Mono", monospace; font-size: 30px; fill: var(--seg); }.dig.gh { opacity: .08; }
.lcdt { font-family: "Russo One", sans-serif; font-size: 12px; fill: var(--seg); }
.blink { animation: bl 1s steps(2) infinite; }@keyframes bl { 50% { opacity: 0; } }
.controls { display: contents; }
.side { grid-row: 3; display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 42px; transform-style: preserve-3d; }
.side:first-child { grid-column: 1; }.side:last-child { grid-column: 3; }
.big { width: 62px; height: 62px; padding: 0; border: 1px solid #9a2b22; border-radius: 50%; background: radial-gradient(circle at 35% 22%, #e3634e, #bd3f31 45%, #98291f 85%); color: #fff0cf; font: 28px/1 "PT Sans", sans-serif; cursor: pointer; touch-action: manipulation; box-shadow: inset 0 2px 2px #ffbd9570, inset 0 -3px 4px #76201980, 0 5px 0 #7c2b20, 0 7px 3px #4b331e80, 0 1px 0 7px #d4c5a1, 0 1px 0 9px #aa9871, 0 3px 0 10px #f1e2bb; transform: translateZ(10px); transition: transform .08s, box-shadow .08s; }
.big:active, .big.pr { transform: translate3d(0, 4px, 6px); box-shadow: inset 0 2px 4px #76201940, 0 1px 0 #7c2b20, 0 2px 3px #4b331e80, 0 -3px 0 7px #d4c5a1, 0 -3px 0 9px #aa9871, 0 -1px 0 10px #f1e2bb; }
.mid { grid-row: 4; grid-column: 2; display: flex; justify-content: center; gap: 14px; margin-top: 20px; transform-style: preserve-3d; }
.sm { min-height: 44px; flex: 1; max-width: 104px; padding: 0 10px; border: 1px solid #3f3b32; border-radius: 8px 8px 12px 12px; background: linear-gradient(#5c584a, #413e34); color: #f9edce; font: 11px "Russo One", sans-serif; letter-spacing: .05em; cursor: pointer; touch-action: manipulation; box-shadow: inset 0 1px 0 #ffffff35, 0 4px 0 #28271f, 0 5px 4px #483b2880, 0 0 0 3px #c8b88f; transform: translateZ(6px); transition: transform .08s, box-shadow .08s; }
.sm:active, .sm.pr { transform: translate3d(0, 3px, 3px); box-shadow: inset 0 1px 0 #ffffff20, 0 1px 0 #28271f, 0 2px 3px #483b2850, 0 -2px 0 3px #c8b88f; }
.ticker { grid-row: 5; grid-column: 1 / -1; display: flex; align-items: center; justify-content: center; text-align: center; min-height: 58px; margin: 21px 0 0; padding: 10px 16px; border: 1px solid #b3a27e; border-radius: 6px; background: #d7c9a5; box-shadow: inset 0 1px 3px #8f7d5840, 0 1px 0 #fff6; color: #514830; font: 14px/1.35 "Share Tech Mono", "PT Sans", monospace; transform: translateZ(2px); }
.hardware-footer { grid-column: 1 / -1; display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 16px 2px 0; color: #827354; font: 9px "PT Sans", sans-serif; letter-spacing: .12em; text-shadow: 0 1px #fff6; }
.speaker { width: 64px; height: 17px; background: repeating-linear-gradient(90deg, #827355 0 2px, #f3e5c0 2px 3px, transparent 3px 7px); border-radius: 9px; opacity: .75; }
.hint { text-align: center; font-size: 14px; line-height: 1.55; color: #f1edda; margin: 19px 0 0; }.hint span { color: #c0cebd; font-size: 12px; }
.shake { animation: sh .25s; }@keyframes sh { 25% { transform: translateX(-4px); } 75% { transform: translateX(4px); } }

/* Birthday card on the entrance noticeboard. */
.invitation { max-width: 620px; margin: 12px auto 0; }
.card { position: relative; border: 1px solid #e0d6be; border-radius: 3px; box-shadow: 2px 4px 0 #10291f18, 0 15px 30px #10291f40; }
.card { background: var(--paper); padding: 34px 32px 26px; transform: rotate(-1deg); }
.card::before { content: ""; position: absolute; top: -12px; left: 50%; width: 94px; height: 26px; margin-left: -47px; background: #e9ddaaa6; border-left: 1px dashed #fff5; border-right: 1px dashed #fff5; transform: rotate(4deg); box-shadow: 0 1px 1px #796a3612; }
.card .eyebrow { margin: 0 0 14px; color: #887b62; font: 11px "Share Tech Mono", "PT Sans", monospace; letter-spacing: .09em; text-transform: uppercase; }
.card h1 { font: 26px/1.22 "Russo One", sans-serif; color: var(--red); margin: 0 0 20px; overflow-wrap: anywhere; text-wrap: balance; }
.card p { font-size: 17px; line-height: 1.6; margin: 0 0 14px; }
.liver { color: var(--red); font-weight: 700; text-decoration: underline; text-decoration-color: #ba493c66; text-decoration-thickness: 2px; text-underline-offset: 4px; }
.facts { list-style: none; padding: 0; margin: 24px 0 0; font-size: 15px; }
.facts li { display: grid; grid-template-columns: 100px minmax(0, 1fr); gap: 10px; padding: 11px 0; border-top: 1px dashed #c7b997; line-height: 1.4; overflow-wrap: anywhere; }
.facts b { color: #74654d; font-weight: 400; }
.sign { font-family: Neucha, cursive; font-size: 25px; text-align: right; color: #4b5d83; margin-top: 22px; }
.mapbtn { margin-top: 12px; min-height: 44px; padding: 0 16px; border: 1px solid #8b7d62; background: transparent; border-radius: 5px; font-weight: 700; cursor: pointer; }
.music { position: fixed; right: max(20px, env(safe-area-inset-right)); bottom: max(18px, env(safe-area-inset-bottom)); z-index: 20; min-height: 44px; padding: 0 17px; border: 1px solid #ffffff26; border-radius: 24px; background: #20382c; color: #f2e9c9; font: 13px "PT Sans", sans-serif; font-weight: 700; box-shadow: 0 4px 15px #13271e40; cursor: pointer; }
.music.on { background: #f4ecd6; color: #344333; border-color: #fff8; }
.foot { color: #c0cebd; text-align: center; font-size: 12px; letter-spacing: .02em; margin: 38px 0 0; }
@media (hover: hover) { .music:hover { filter: brightness(1.08); }.mapbtn:hover { background: #e9dfc6; } }
@media (max-width: 760px) {
  body { padding: 24px 22px 90px; }
  .console { column-gap: 15px; padding: 24px 22px 18px; grid-template-columns: 60px minmax(0, 1fr) 60px; }
  .big { width: 50px; height: 50px; font-size: 25px; }
  .title { font-size: 27px; }
  .invitation { max-width: 520px; }
  .card { padding: 30px 24px 24px; }
  .card h1 { font-size: 23px; }
  .facts li { grid-template-columns: 1fr; gap: 3px; }
}
@media (max-width: 600px) {
  body { padding: 20px 18px 90px; background: linear-gradient(180deg, #e7e5d9 0, #dfddcf 250px, #97a28d 250px, #97a28d 254px, #345b47 254px, #244b3c 100%); }
  .wrap { max-width: 440px; }
  .page-header { margin-bottom: 12px; gap: 12px; padding: 0 4px; }
  .graffiti { font-size: 22px; }.edition { font-size: 12px; }.edition span { font-size: 9px; letter-spacing: .08em; }
  .game-section { padding-bottom: 28px; }
  .console-stage { padding: 10px 0 20px; perspective: 1100px; }
  .console { --tilt-x: 4deg; --tilt-y: -3deg; display: block; padding: 23px 16px 16px; border-radius: 26px; }
  .console::before, .case-back, .case-edge { border-radius: 26px; }
  .brand { margin: 0 2px 14px; font-size: 12px; letter-spacing: .13em; }.brand small { font-size: 10px; }
  .title { font-size: clamp(19px, 5.6vw, 26px); margin-bottom: 16px; }
  .bezel { padding: 10px; border-radius: 12px; }
  .controls { display: grid; grid-template-columns: 1fr 1.2fr 1fr; gap: 15px; align-items: center; margin-top: 20px; transform-style: preserve-3d; }
  .side, .side:first-child, .side:last-child { grid-column: auto; grid-row: auto; gap: 27px; }
  .big { width: 54px; height: 54px; }
  .mid { grid-column: auto; grid-row: auto; flex-direction: column; gap: 12px; margin: 0; }
  .sm { width: 100%; max-width: none; flex: auto; min-height: 44px; font-size: 10px; padding: 0 6px; }
  .ticker { min-height: 70px; padding: 9px 10px; font-size: 12px; margin-top: 12px; }
  .hardware-footer { padding-top: 18px; font-size: 7px; letter-spacing: .08em; gap: 9px; }.speaker { width: 45px; height: 13px; }
  .hint { margin-top: 16px; font-size: 12px; }.hint span { font-size: 11px; }
  .invitation { margin: 8px 3px 0; }
  .card { padding: 30px 24px 24px; }.card h1 { font-size: 25px; }.card p { font-size: 16px; }
  .facts li { grid-template-columns: 95px minmax(0, 1fr); gap: 10px; }
  .music { right: 14px; min-height: 44px; font-size: 12px; padding: 0 14px; }
}
@media (max-width: 360px) {
  body { padding-left: 13px; padding-right: 13px; }
  .graffiti { font-size: 19px; }.edition { font-size: 11px; }
  .console { padding-left: 13px; padding-right: 13px; }
  .brand { font-size: 11px; }.brand small { font-size: 9px; }
  .big { width: 46px; height: 46px; font-size: 23px; }.side { gap: 29px; }
  .hardware-footer { letter-spacing: 0; }.speaker { width: 32px; }
  .card { padding-left: 20px; padding-right: 20px; }.card h1 { font-size: 23px; }
  .facts li { grid-template-columns: 1fr; gap: 3px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
  .blink, .shake { animation: none; }
  .card, .graffiti { transform: none; }
}
