/* alongtrackgames.com. The page is the game's diorama, top to bottom: sky, a live beach, the cut face of the sand holding the
   content, and the chart table the slab stands on. Colours are the logo's; the faces are the logo's Fraunces and the game's
   own reading face, Atkinson Hyperlegible. */
:root{
  --paper:#FBF6EA;--table:#F4EFE2;--ink:#14293A;--sub:#3E5466;--sea:#29669B;--tint:#A6CAE0;--mark:#A11C74;
  --sand:#DDBE7E;--sand-skin:#F2D9A0;--sand-line:#C6A462;--sand-foot:#C9A765;--buoy:#F2B21B;
  --display:'Fraunces',Georgia,'Times New Roman',serif;--text:'Atkinson Hyperlegible',Verdana,system-ui,sans-serif;
  --gutter:clamp(20px,5vw,72px);--radius:12px;
  --edge:max(var(--gutter),calc((100vw - 1320px)/2 + var(--gutter)));--panel-w:min(430px,36vw);--panel-right:calc(var(--edge) + clamp(0px,4vw,90px));
}
*,*::before,*::after{box-sizing:border-box}
[hidden]{display:none!important}
html{scroll-behavior:smooth;-webkit-text-size-adjust:100%}
body{margin:0;background:var(--paper);color:var(--ink);font:400 1.125rem/1.6 var(--text)}
img,video,svg{display:block;max-width:100%}
img,video{height:auto}
a{color:inherit;text-underline-offset:.18em;text-decoration-thickness:.08em}
p{margin:0 0 1em;max-width:62ch}
h1,h2,h3{margin:0;font-family:var(--display);font-weight:600;line-height:1.08;letter-spacing:-.012em}
h2{font-size:clamp(2rem,4.4vw,3.4rem);margin-bottom:.6em}
h3{font-size:1.5rem;margin:.9em 0 .35em}
:focus-visible{outline:3px solid var(--mark);outline-offset:3px;border-radius:4px}
.wrap{width:100%;max-width:1320px;margin-inline:auto;padding-inline:var(--gutter)}
.hidden{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
.small{font-size:.95rem;color:var(--sub)}
.skip{position:absolute;left:-999px;top:8px;z-index:10;background:var(--ink);color:var(--paper);padding:.5em .9em;border-radius:var(--radius)}
.skip:focus{left:8px}

.button{display:inline-block;font:700 1rem/1.2 var(--text);color:var(--ink);background:transparent;border:1.5px solid var(--ink);border-radius:var(--radius);padding:.62em 1em;text-decoration:none;cursor:pointer}
.button:hover{background:rgba(20,41,58,.08)}
.button:disabled{opacity:.45;cursor:default}
.button-steam{background:var(--buoy);color:#14293A;border-color:#14293A;font-size:1.1rem;padding:.75em 1.25em}
.button-steam:hover{background:#FFC43A}
.button-steam[aria-disabled=true]{cursor:default}
.button-watch{display:inline-flex;align-items:center;gap:.5em;font-size:1.1rem;padding:.75em 1.15em}
.button-watch svg{width:.8em;height:.8em;fill:currentColor}
.button-steam[aria-disabled=true]:hover{background:var(--buoy)}

/* The sky and the beach. The canvas fills the header; the sky's text sits over its empty air, and the band at the foot is
   kept clear for the sand and the sea. */
.hero{position:relative}
.hero-stage{position:relative;display:flex;flex-direction:column;min-height:100svh;overflow:hidden;background:linear-gradient(#FBF6EA 55%,#F1F3EA)}
.hero-canvas{position:absolute;inset:0;width:100%;height:100%}
/* Under a finger the beach lets a swipe scroll the page until it has been tapped into play. */
.hero-zone{position:absolute;left:0;right:0;bottom:0;height:40%;touch-action:pan-y;cursor:grab}
.hero-zone.playing{touch-action:none}
.play{position:absolute;left:var(--edge);bottom:14px;z-index:2;font:700 .95rem/1.2 var(--text);color:#14293A;background:rgba(251,246,234,.96);border:1.5px solid #14293A;border-radius:999px;padding:.6em 1.1em;box-shadow:0 3px 0 rgba(20,41,58,.22);cursor:pointer}
.hero-zone:active{cursor:grabbing}
.hero-sky{position:relative;display:grid;grid-template-columns:minmax(0,1fr);gap:clamp(20px,3vw,48px);padding-top:22px;pointer-events:none}
.hero-title{max-width:min(600px,calc(100vw - var(--panel-w) - var(--panel-right) - var(--edge) - 44px))}
.hero-sky a,.tide-panel button,.tide-panel input{pointer-events:auto}
.tide-panel .button:hover{background:rgba(127,140,150,.22)}
/* After dark the sky is navy and the words over it turn pale; the logo's lettering and curve follow. */
.hero{--halo-a:0;--halo:rgb(251 246 234 / var(--halo-a))}
.hero[data-sky=night]{--halo:rgb(14 34 49 / var(--halo-a))}
.hero-stage,.tide-panel{--sub:color-mix(in srgb,var(--ink) calc(var(--dusk,0)*100%),#3E5466);color:var(--ink);transition:color .5s;text-shadow:0 0 .18em var(--halo),0 0 .45em var(--halo),0 0 .9em var(--halo)}
.hero .button,.dock{text-shadow:none}
.curve text{paint-order:stroke;stroke:var(--halo);stroke-width:3px;stroke-linejoin:round}
.hero[data-sky=night] .hero-stage{--ink:#F4EFE2;--sub:color-mix(in srgb,#F4EFE2 calc(var(--dusk,0)*100%),#BFD3DD);--sea:#7DB6E0;--tint:#29669B;--mark:#F06CC0}
.hero[data-sky=night] .nav img{filter:invert(.92)}
@media (min-width:901px){.hero[data-sky=night] .tide-panel{--ink:#F4EFE2;--sub:color-mix(in srgb,#F4EFE2 calc(var(--dusk,0)*100%),#BFD3DD);--sea:#7DB6E0;--tint:#29669B;--mark:#F06CC0;--under:#12283A}}
.logo .l-tint{fill:var(--tint)}.logo .l-mean{stroke:var(--sub)}.logo .l-curve{stroke:var(--sea)}.logo .l-mark{fill:var(--mark)}
.hero-beach{flex:1 0 var(--beach-band,31vw)}

.nav{grid-column:1/-1;display:flex;flex-wrap:wrap;align-items:center;gap:.4em 1.6em;font-size:1rem}
.nav a{text-decoration:none;padding:.3em 0}
.nav a:hover{text-decoration:underline}
.nav .studio{display:flex;align-items:center;gap:.55em;margin-right:auto;font:600 1.15rem var(--display)}
.logo{width:min(100%,600px);height:auto;overflow:visible}
.logo-name{font:700 142px var(--display);letter-spacing:-1px;font-variant-ligatures:none;fill:var(--ink)}
.logo-sub{font:italic 500 35px var(--display);letter-spacing:1.5px;fill:var(--sub)}
.lede{font-size:clamp(1.15rem,1.6vw,1.4rem);line-height:1.45;max-width:34ch;margin:.5em 0 1.1em}
.cta-row{display:flex;flex-wrap:wrap;align-items:center;gap:.6em 1.2em;margin:0}
.platform{color:var(--sub)}

.tide-panel{--under:var(--paper);position:absolute;top:84px;right:var(--panel-right);width:var(--panel-w);pointer-events:none}
.tide-panel h2{font-size:1.7rem;margin-bottom:.25em}
.tide-panel p{margin-bottom:.6em;font-size:1rem;line-height:1.45}
.curve{position:relative;height:96px;margin:.2em 0 .5em;border-radius:6px}
.curve svg{width:100%;height:100%;overflow:visible}
.curve .night{fill:var(--ink);opacity:.11}
.curve .fill{fill:var(--tint);opacity:.5}
.curve .mean{stroke:var(--sub);stroke-width:1.2;stroke-dasharray:2 6;vector-effect:non-scaling-stroke}
.curve .line{fill:none;stroke:var(--sea);stroke-width:3;stroke-linecap:round;vector-effect:non-scaling-stroke}
.curve text{font:italic 500 11px var(--display);fill:var(--sub)}
.curve-dot{position:absolute;width:22px;height:22px;margin:-11px 0 0 -11px;border-radius:50%;background:var(--mark);box-shadow:0 0 0 3px var(--under),0 0 0 4.5px var(--mark);pointer-events:none}
.curve input{position:absolute;inset:0;width:100%;height:100%;margin:0;opacity:0;cursor:grab}
.curve input:active{cursor:grabbing}
.curve:focus-within{outline:3px solid var(--mark);outline-offset:4px}
.tide-status{font-weight:700;font-variant-numeric:tabular-nums;font-size:clamp(.9rem,1.25vw,1rem)}
.tide-status span{display:block;white-space:nowrap}
.tide-run{display:flex;flex-wrap:wrap;align-items:center;gap:.5em 1em}
.button-small{font-size:.9rem;padding:.4em .8em}
.link{font:inherit;font-weight:400;color:inherit;background:none;border:0;padding:0;text-decoration:underline;text-underline-offset:.18em;cursor:pointer}

/* The dock: picture roundels on a slip of chart paper, lying on the sand at the header's foot. */
.dock{position:absolute;right:var(--edge);bottom:18px;max-width:calc(100vw - 2*var(--edge));background:rgba(251,246,234,.96);border:1.5px solid #14293A;border-radius:14px;padding:8px 12px 7px;box-shadow:0 3px 0 rgba(20,41,58,.22);color:#14293A}
.dock-hint{margin:0 0 6px;max-width:none;font-size:.9rem;line-height:1.3}
.dock-row{display:flex;flex-wrap:wrap;gap:6px 0}
.dock-group{display:flex;gap:4px;padding:0 9px;border-left:1.5px solid rgba(20,41,58,.22)}
.dock-group:first-child{padding-left:0;border-left:0}
.dock-group:last-child{padding-right:0}
.roundel{display:flex;flex-direction:column;align-items:center;gap:3px;width:52px;padding:0;background:none;border:0;color:#14293A;font:400 .7rem/1.1 var(--text);cursor:pointer}
.roundel .disc{display:grid;place-items:center;width:42px;height:42px;border:1.5px solid #14293A;border-radius:50%;background:#FBF6EA}
.roundel svg{width:24px;height:24px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.roundel:hover .disc{background:#EFE9D8}
.roundel[aria-pressed=true] .disc{background:var(--tint)}
.roundel[aria-pressed=true] .cap{font-weight:700}
.roundel:disabled{opacity:.45;cursor:default}
.roundel:focus-visible{outline:none}
.roundel:focus-visible .disc{outline:3px solid var(--mark);outline-offset:2px}

/* The cut face of the slab: sand, with bedding lines between the sections. */
.slab{background:var(--sand);padding-bottom:clamp(12px,2vw,28px)}
.band{padding-block:clamp(40px,6vw,84px)}
.stratum{width:100%;height:24px}
.stratum path{fill:none;stroke:var(--sand-line);stroke-width:3;vector-effect:non-scaling-stroke}
.film,.clip,.stills img{border-radius:var(--radius);background:#0E2A3B;box-shadow:0 2px 0 var(--sand-line)}
.film{width:100%}
.trio{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:clamp(20px,3vw,44px)}
.trio p{max-width:36ch}
.clip{width:100%;aspect-ratio:1170/658;object-fit:cover}
.stills{list-style:none;margin:0;padding:0;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:clamp(10px,1.4vw,20px)}
.stills a{display:block;border-radius:var(--radius)}
.stills img{width:100%}
.game{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(0,.8fr);gap:clamp(28px,5vw,80px);align-items:start}
.features{margin:0;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:1.3em clamp(20px,3vw,44px)}
.features dt{font:600 1.3rem/1.2 var(--display);margin-bottom:.25em}
.features dd{margin:0}
.needs h3{margin-top:0}
.spec{border-collapse:collapse;width:100%;margin:.6em 0 1em;font-size:.98rem}
.spec th,.spec td{text-align:left;vertical-align:top;padding:.45em .8em .45em 0;border-bottom:1.5px solid var(--sand-line)}
.spec thead th{border-bottom-color:var(--ink)}
.spec tbody th{font-weight:700;white-space:nowrap}
.maker{display:grid;grid-template-columns:minmax(0,1fr) minmax(180px,300px);gap:clamp(24px,6vw,96px);align-items:center}
.roundel{width:100%;justify-self:end}
.press{display:grid;grid-template-columns:minmax(0,1.1fr) minmax(0,.9fr);gap:clamp(24px,5vw,80px);align-items:start}
.facts{margin:0}
.facts div{display:grid;grid-template-columns:8.5em 1fr;gap:1em;padding:.5em 0;border-bottom:1.5px solid var(--sand-line)}
.facts dt{font-weight:700}
.facts dd{margin:0}
.slab .small{color:#3A3420}

/* The slab's foot and the chart table it stands on. */
.slab-foot{height:54px;background:linear-gradient(var(--sand-foot) 0 16px,rgba(20,41,58,.2) 16px,rgba(20,41,58,0) 54px) var(--table)}
.table{position:relative;overflow:hidden;background:var(--table);padding-block:clamp(28px,4vw,56px) 170px}
.contours{position:absolute;left:0;right:0;bottom:0;width:100%;height:150px;pointer-events:none}
.contours path{fill:none;stroke:var(--sea);stroke-width:1.5;opacity:.3;vector-effect:non-scaling-stroke}
.contours .track{stroke:var(--mark);stroke-dasharray:6 5;opacity:.45}
.table-grid{position:relative;display:grid;grid-template-columns:minmax(0,1.1fr) minmax(0,.9fr);gap:clamp(28px,6vw,96px)}
.table h2{font-size:clamp(1.6rem,2.6vw,2.2rem)}
.tides{border-collapse:collapse;width:100%;max-width:520px;margin-bottom:1em}
.tides th{text-align:left;font-weight:700;border-bottom:1.5px solid var(--ink);padding:.3em .8em .3em 0}
.tides td{border-bottom:1px solid #C9C0A8;padding:.36em .8em .36em 0}
.tides .fig{font:italic 500 1.15rem var(--display);font-variant-numeric:tabular-nums}
.imprint{margin-top:2em}

@media (max-width:900px){
  .hero-title{max-width:600px}
  .tide-panel{--under:var(--sand);position:static;width:auto;background:var(--sand);padding:10px var(--gutter) 4px}
  .dock{position:static;max-width:none;margin:0;border:0;border-radius:0;box-shadow:none;background:var(--sand);padding:6px var(--gutter) 10px}
  .dock-hint{font-size:1rem}
  .tide-panel{text-shadow:none}
  .tide-panel .curve text{stroke:none}
  .game{grid-template-columns:minmax(0,1fr)}
  .dock-row{gap:10px 20px}
  .dock-group{padding:0;border-left:0}
  .tide-panel .curve,.tide-panel p{max-width:520px}
  .trio{grid-template-columns:minmax(0,1fr)}
  .trio p{max-width:62ch}
  .stills{grid-template-columns:repeat(2,minmax(0,1fr))}
  .maker,.press,.table-grid{grid-template-columns:minmax(0,1fr)}
  .roundel{max-width:200px;justify-self:start}
}
@media (max-width:1180px) and (min-width:901px){
  .roundel{width:44px}
  .roundel .disc{width:38px;height:38px}
  .roundel .cap{font-size:.62rem}
}
@media (max-width:520px){
  .features{grid-template-columns:minmax(0,1fr)}
  body{font-size:1.0625rem}
  .nav{gap:.2em 1.1em}
  .nav .studio{flex-basis:100%}
  .facts div{grid-template-columns:6.5em 1fr}
}
@media (prefers-reduced-motion:reduce){html{scroll-behavior:auto}}

/* The page a wrong address lands on. */
.lost main{min-height:100svh;padding-block:22px 80px}
.lost h1{font-size:clamp(2.2rem,6vw,4rem);margin:18vh 0 .4em;max-width:16ch}
.studio-home{display:inline-flex;align-items:center;gap:.55em;font:600 1.15rem var(--display);text-decoration:none}
