/* an element with the hidden attribute stays hidden whatever display a rule below gives it (#game covered the start page) */
[hidden] { display: none !important; }
html, body { margin: 0; min-height: 100%; background: #0d0605; color: #e6dcd0; font: 15px/1.45 system-ui, sans-serif; }

/* ---- the start page: the game's poster on the left (the Mac startup window's art), the choices on the right */
#start { position: relative; display: grid; grid-template-columns: minmax(16em, 30vw) minmax(0, 1fr); min-height: 100vh;
         background: radial-gradient(90em 50em at 85% -10%, #6a1c0c55, transparent 60%),
                     radial-gradient(60em 40em at 100% 100%, #f5a51814, transparent 60%), #0d0605; }
/* rain over the whole page: thin slanted streaks drifting down */
#start::before { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .22;
                 background: repeating-linear-gradient(104deg, transparent 0 13px, #ffb36b33 13px 14px, transparent 14px 37px);
                 background-size: 220px 220px; animation: rain .7s linear infinite; }
@keyframes rain { to { background-position: -55px 220px; } }
@media (prefers-reduced-motion: reduce) { #start::before { animation: none; } }
.poster { position: sticky; top: 0; height: 100vh; overflow: hidden; border-right: 1px solid #3a1a10;
          box-shadow: 0 0 60px #000 inset, 30px 0 60px -30px #000; }
/* the art is 400x1200; its lower strip names the desktop game's renderers, so the picture is shown down to just above it */
.poster img { display: block; width: 100%; height: 121%; object-fit: cover; object-position: top center; }
.panel { position: relative; max-width: 62em; padding: 3.2em clamp(1.2em, 4vw, 4em) 2em; }
.hero h1 { margin: 0; font: 900 clamp(2.6em, 6.2vw, 5.4em)/.92 Impact, Haettenschweiler, "Arial Narrow Bold", "Arial Black", sans-serif;
           text-transform: uppercase; letter-spacing: .02em; user-select: none; cursor: default;
           background: linear-gradient(#fff3c4 0 18%, #ffd257 38%, #f59a18 52%, #ffe08a 54%, #f5c518 78%, #b8600c);
           -webkit-background-clip: text; background-clip: text; color: transparent;
           filter: drop-shadow(0 3px 0 #2a0d05) drop-shadow(0 0 22px #f5781840); }
.sub { margin: .9em 0 0; color: #d8c4ae; font-size: 1.15em; max-width: 34em; }
.chips { list-style: none; display: flex; flex-wrap: wrap; gap: .5em; margin: 1.2em 0 0; padding: 0; }
.chips li { padding: .25em .8em; border: 1px solid #6b3a1c; border-radius: 99px; background: #2a110a99; color: #f5c98a; font-size: .85em; }
.cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1em; margin-top: 2.2em; }
@media (max-width: 1100px) { .cards { grid-template-columns: 1fr; } }
.card { padding: 1em 1.2em 1.1em; background: #1a0c08cc; border: 1px solid #3a1e12; border-radius: 10px;
        box-shadow: 0 10px 30px #0008; backdrop-filter: blur(3px); }
h2 { display: flex; align-items: center; gap: .6em; font-size: .95em; margin: 0 0 .8em; color: #f5c518; text-transform: uppercase; letter-spacing: .1em; }
h2 span { display: inline-grid; place-items: center; width: 1.7em; height: 1.7em; border-radius: 50%; background: #f5c518; color: #1a0c08; font-weight: 800; letter-spacing: 0; }
.card p { margin: .4em 0; }
.drop { border: 2px dashed #6b3a1c; border-radius: 8px; padding: .8em 1em; }
.drop.over { border-color: #f5c518; background: #2a1a08; }
.hint { color: #9a8878; font-size: .88em; }
.rows label { display: flex; justify-content: space-between; align-items: center; gap: 1em; margin: .55em 0; }
select, input[type=text] { width: 16em; max-width: 68%; box-sizing: border-box; padding: .4em .5em; background: #0d0605; color: #f0e6da; border: 1px solid #4a2a1a; border-radius: 6px; font: inherit; }
select:focus, input[type=text]:focus { outline: 2px solid #f5c518; outline-offset: 1px; }
input[type=checkbox] { accent-color: #f5c518; width: 1.15em; height: 1.15em; }
.button { display: inline-block; padding: .7em 3.2em; border: 0; border-radius: 8px; cursor: pointer; font: 900 1.5em/1 Impact, "Arial Black", sans-serif;
          letter-spacing: .08em; text-transform: uppercase; color: #1a0c08; background: linear-gradient(#ffe08a, #f5c518 45%, #f59a18);
          box-shadow: 0 4px 0 #8a4a0a, 0 10px 30px #f5781855; transition: transform .08s, box-shadow .08s, filter .15s; }
.button:hover:not(:disabled) { filter: brightness(1.08); transform: translateY(-1px); }
.button:active:not(:disabled) { transform: translateY(3px); box-shadow: 0 1px 0 #8a4a0a, 0 4px 14px #f5781855; }
.button:disabled { background: #3a2a22; color: #7a6a5e; box-shadow: none; cursor: default; }
.button.small { font: 700 1em/1 system-ui, sans-serif; letter-spacing: 0; text-transform: none; padding: .6em 1.2em; margin-top: .4em; }
.button input[type=file] { display: none; }
.launch { display: flex; flex-wrap: wrap; align-items: center; gap: 1em 1.6em; margin-top: 1.8em; }
.launch .hint { flex: 1 1 16em; margin: 0; }
#config-section .link { margin-right: 1.2em; }
.link { background: none; border: 0; color: #f5c98a; cursor: pointer; padding: 0; text-decoration: underline; font: inherit; }
#error { color: #ff8a7a; min-height: 1.2em; }
footer { margin-top: 2.5em; padding-top: 1em; border-top: 1px solid #2a150d; color: #6f6056; font-size: .8em; max-width: 50em; }
@media (max-width: 760px) {
  #start { grid-template-columns: 1fr; }
  .poster { position: relative; height: 34vh; border-right: 0; border-bottom: 1px solid #3a1a10; }
  .poster img { height: auto; }
  .hero h1 { display: none; }   /* the poster above already carries the title */
}
/* the developer console stays out of sight until the title is clicked seven times (dev.js) */
body:not(.dev-on) #dev-start, body:not(.dev-on) #dev-open { display: none !important; }
#game { position: fixed; inset: 0; display: flex; align-items: center; justify-content: center; background: #000; }
/* the picture as large as the window or the screen allows, in its own proportions (--aspect is set by main.js) */
#game canvas { width: min(100vw, calc(100vh * var(--aspect, 1.7778))) !important; height: auto !important;
               aspect-ratio: var(--aspect, 1.7778); image-rendering: pixelated; outline: none; }
.corner { position: absolute; right: 1em; top: .7em; padding: .3em .8em; background: #222c; color: #ccc; border: 1px solid #555;
          border-radius: 4px; cursor: pointer; font-size: .85em; }
#game:fullscreen .corner { display: none; }
#game-status { position: absolute; left: 1em; bottom: .5em; margin: 0; color: #888; font-size: .85em; }
/* the developer panel (dev.js): over the game's left side, also in full screen */
.corner.second { right: 8.5em; }
#game:fullscreen .corner.second { display: block; opacity: .35; }
#dev { position: absolute; left: 0; top: 0; bottom: 0; width: min(46em, 96vw); box-sizing: border-box; padding: .6em .8em; display: flex;
       flex-direction: column; gap: .4em; background: #101014e6; border-right: 1px solid #444; font-size: 13px; overflow: hidden; }
#dev header { display: flex; gap: .6em; align-items: baseline; }
#dev header span { flex: 1; color: #8c8; font-size: .85em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#dev h3 { margin: .3em 0; font-size: 1em; color: #f5c518; }
#dev button { background: #2a2a30; color: #ccc; border: 1px solid #555; border-radius: 3px; cursor: pointer; font-size: .85em; }
#dev section { overflow-y: auto; flex: 0 1 auto; min-height: 4em; }
#dev .fx { display: grid; grid-template-columns: 1fr 1fr; gap: .1em .8em; }
#dev .fx label { cursor: pointer; line-height: 1.25; padding: .1em 0; }
#dev-log { flex: 1 1 6em; min-height: 5em; margin: 0; overflow: auto; background: #000a; color: #9a9; font: 11px/1.3 ui-monospace, monospace; white-space: pre-wrap; }
#dev-command { background: #000; color: #eee; border: 1px solid #555; padding: .3em; font: 12px ui-monospace, monospace; }
/* the same switches on the start page */
#dev-start { margin: 1.4em 0 0; box-sizing: border-box; background: #120806; border: 1px solid #444; border-radius: 4px; padding: .4em .7em; }
#dev-start summary { cursor: pointer; color: #f5c518; }
#dev-start h3 { margin: .7em 0 .3em; font-size: .95em; color: #aaa; }
#dev-start .fx { display: grid; grid-template-columns: 1fr 1fr; gap: .3em 1.4em; font-size: .9em; }
#dev-start .fx label { display: block; margin: 0; cursor: pointer; line-height: 1.25; }
#dev-start button { background: #2a2a30; color: #ccc; border: 1px solid #555; border-radius: 3px; cursor: pointer; font-size: .85em; }

/* links inside hints (the shareware link): the text's own colour, not the browser's blue on the dark page */
.hint a { color: inherit; text-decoration: underline; }
/* the short description under the cards (for players and for search engines) */
.about { margin-top: 2.2em; max-width: 50em; color: #b8a898; font-size: .92em; }
.about h2 { margin-bottom: .5em; }
.about p { margin: .5em 0; }
footer a { color: #9a8878; }
