* { box-sizing: border-box; }
:root { color-scheme: light; --ink: #113e3e; --paper: #faf7ed; --gold: #ffdd68; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 1rem/1.5 'DM Sans', 'Segoe UI', sans-serif; }
a { color: inherit; }
button, a { touch-action: manipulation; }
button { font: inherit; cursor: pointer; }
:focus-visible { outline: 3px solid #c44913; outline-offset: 4px; }
.bar, .section, footer { width: min(1240px, 90%); margin-inline: auto; }
.bar, nav, .brand, footer, .gallery-heading, .scoreboard, .hero-links, .viewer-top, .viewer-bottom { display: flex; align-items: center; }
.bar, footer, .gallery-heading, .scoreboard, .viewer-top, .viewer-bottom { justify-content: space-between; }
.bar { min-height: 76px; gap: 12px; }
.brand { gap: 12px; font: bold 1.25rem Georgia, serif; text-decoration: none; }
nav { gap: clamp(14px, 3vw, 40px); font-size: .92rem; font-weight: 650; }
nav a { text-decoration: none; } nav a:hover, .brand:hover { text-decoration: underline; }
.hero { position: relative; display: grid; align-items: end; isolation: isolate; min-height: clamp(390px, 39vw, 580px); background: #154b50; color: #fffaf0; }
.hero-photo, .hero::after { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero-photo { object-fit: cover; object-position: 52% 43%; z-index: -2; }
.hero::after { content: ''; z-index: -1; background: linear-gradient(90deg, #092f38b8, #072d3830 75%), linear-gradient(0deg, #082d377d, transparent 75%); }
.hero-copy { display: grid; grid-template-columns: minmax(0,1.55fr) minmax(0,1fr); align-items: center; gap: 24px; width: min(1240px, 90%); margin: 0 auto; padding: clamp(32px, 4vw, 68px) 0; }
.hero-portrait { display: block; width: min(100%, 290px); height: auto; justify-self: center; border: 7px solid #fffaf0; transform: rotate(2deg); box-shadow: 0 8px 26px #06293066; }
h1, h2 { margin: 0; font-family: Georgia, serif; letter-spacing: -.066em; font-weight: 500; line-height: .98; }
h1 { font-size: clamp(4rem, 9.4vw, 9.6rem); }
h1 span { display: block; font-size: .54em; font-style: italic; margin-bottom: .13em; }
.hero-links { margin-top: 30px; flex-wrap: wrap; gap: 20px; font-size: .93rem; font-weight: 700; }
.button, #start { display: inline-flex; gap: 14px; align-items: center; border: 0; border-radius: 99px; background: var(--gold); padding: 12px 20px; text-decoration: none; color: #183635; font-weight: 750; }
.button:hover, #start:hover { background: #ffea9c; }
.light-link { text-underline-offset: 4px; }
.section { padding-block: clamp(42px, 6vw, 88px); }
.arcade { display: grid; grid-template-columns: minmax(0, .7fr) minmax(0, 1.3fr); align-items: center; gap: clamp(26px, 6vw, 90px); }
h2 { font-size: clamp(3.2rem, 6.5vw, 6.5rem); }
h2 i { color: #15726d; font-weight: 400; }
.arcade-copy p { max-width: 33ch; }
.controls { font-size: .88rem; }
kbd { border: 1px solid #97a9a0; border-bottom-width: 2px; padding: 1px 5px; border-radius: 4px; }
.console { background: #12534f; color: #fff9da; border: 4px solid #123e3d; padding: 0 9px 9px; border-radius: 18px; box-shadow: 0 5px 0 #092e2e; }
.scoreboard { padding: 7px 6px; font: .8rem/1.5 'Courier New', monospace; text-transform: uppercase; }
.scoreboard strong { color: var(--gold); font-size: 1rem; }
.screen { position: relative; background: #a7e2df; border-radius: 8px; }
canvas { display: block; width: 100%; height: auto; image-rendering: pixelated; border-radius: inherit; touch-action: manipulation; }
.overlay { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; border-radius: inherit; background: #073c4030; }
.overlay[hidden] { display: none; }
.overlay > div { background: #fff8dd; color: var(--ink); padding: clamp(10px, 2vw, 24px); border: 2px solid #164d49; border-radius: 12px; box-shadow: 0 4px 0 #164d49; }
#state { font: bold clamp(1.1rem,2.5vw,1.8rem)/1.1 Georgia, serif; margin: 0 0 10px; }
#start { padding: 9px 18px; }
.gallery { border-top: 1px solid #a9b5a9; }
.gallery-heading { align-items: end; margin-bottom: 30px; gap: 12px; }
.gallery-heading span { font-size: .85rem; }
.photos { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: clamp(14px,2vw,32px); }
.photo { display: block; text-decoration: none; }
.photo img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; display: block; border-radius: 3px; }
.photo span { display: block; margin: 6px 0 12px; font: italic 1.16rem Georgia, serif; }
.photo:hover span { text-decoration: underline; }
footer { padding: 22px 0 30px; border-top: 1px solid #a9b5a9; font-size: .85rem; }
dialog { width: fit-content; max-width: 94vw; max-height: 94svh; padding: 12px; border: 0; border-radius: 10px; background: var(--paper); color: var(--ink); }
dialog::backdrop { background: #042628e8; }
#enlarged { display: block; max-width: 100%; max-height: 67svh; width: auto; margin: auto; }
.viewer-top, .viewer-bottom { gap: 16px; }
.viewer-top { margin-bottom: 8px; } .viewer-bottom { margin-top: 8px; }
dialog button { min-width: 44px; min-height: 40px; border-radius: 8px; border: 1px solid #adbbb2; background: transparent; color: var(--ink); }
@media (max-width: 700px) {
  .hero-copy { grid-template-columns: 1fr; justify-items: center; text-align: center; }
  .hero-portrait { grid-row: 1; width: clamp(145px, 42vw, 230px); }
  .hero-links { justify-content: center; }
  .bar { min-height: 62px; }
  .brand { font-size: 1rem; gap: 7px; }
  nav { font-size: .83rem; }
  .arcade { grid-template-columns: 1fr; gap: 16px; }
  .arcade-copy br { display: none; } .arcade-copy i::before { content: ' '; }
  .arcade-copy p { max-width: none; margin: 12px 0; }
  .photos { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .gallery-heading { align-items: start; flex-direction: column; }
}
