:root {
  color-scheme: light;
  font-family: Verdana, Arial, sans-serif;
  font-size: 14px;
  color: #4c3457;
  background: #ffef9f;
  --ink: #4c3457;
  --purple: #79429a;
  --pink: #e84b92;
  --teal: #087b7a;
  --cream: #fffdf1;
  --display: "Arial Rounded MT Bold", "Trebuchet MS", Arial, sans-serif;
  --hand: "Chalkboard SE", "Comic Sans MS", "Trebuchet MS", sans-serif;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; min-height: 100vh; background: radial-gradient(ellipse at 15% 0, #fffbdc, transparent 60%), radial-gradient(#f7cf6c 1.4px, transparent 1.4px), #ffef9f; background-size: auto, 22px 22px, auto; }
.site-shell { max-width: 1060px; margin: 0 auto; padding: 28px 28px 24px; }
.masthead { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding-bottom: 18px; }
.site-identity { display: flex; align-items: center; gap: 13px; min-width: 0; }
.paw-mark { display: grid; place-items: center; flex: 0 0 55px; width: 55px; height: 55px; color: var(--purple); background: #ffd966; border: 3px solid #cf8339; border-radius: 48% 45% 43% 50%; box-shadow: inset 2px 3px #fff4b4, 2px 3px 0 #e7b45b; transform: rotate(-10deg); }
.paw-mark svg { width: 37px; height: 37px; }
.eyebrow { margin: 0 0 5px; color: #6a4b75; font-size: 10px; font-weight: bold; letter-spacing: .3px; }
h1 { margin: 0; color: var(--teal); font: 900 34px/1.1 var(--display); letter-spacing: -1.7px; }
.title-lead { display: block; margin-bottom: 3px; color: var(--purple); font-size: .48em; line-height: 1.2; letter-spacing: .3px; }
.title-name { color: var(--teal); }
a { color: #076c72; text-underline-offset: 3px; }
a:hover { color: #a42d73; }
:focus-visible { outline: 3px solid #7241a0; outline-offset: 4px; }
.header-actions, #account { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 10px; font-size: 12px; }
button, .nav-link { font: bold 12px Verdana, Arial, sans-serif; color: #5f327b; background: linear-gradient(#fffafc, #f9dcec); border: 2px solid #97527e; border-radius: 14px; padding: 10px 16px; box-shadow: inset 0 2px #fff, 0 3px 0 #c1809c; cursor: pointer; }
button:hover, .nav-link:hover { color: #5f327b; background: #ffe7f3; }
button:active, .nav-link:active { box-shadow: inset 0 2px 3px #b5779c; }
button:disabled { opacity: .55; cursor: default; }
.nav-link { display: inline-block; min-width: 62px; text-align: center; text-decoration: none; }
.nav-link:first-child { background: linear-gradient(#fffbdc, #ffe072); border-color: #be8739; box-shadow: inset 0 2px #fff, 0 3px 0 #dba74f; color: #765021; }
p { line-height: 1.65; margin: 0 0 12px; }
h2 { margin: 0 0 17px; font: 900 38px/1.1 var(--display); letter-spacing: -1.3px; }
h3 { font-size: 15px; margin: 0 0 10px; }
.project-note { text-align: center; color: #70516b; font-size: 12px; margin: 7px 0 21px; }
.welcome-panel, .game-panel, .card { background: var(--cream); border: 3px solid #9153a7; border-radius: 30px 22px 28px 20px; box-shadow: 0 0 0 5px #e4b6e8, 6px 9px 0 4px #dfa24c55; }
.welcome-panel { overflow: hidden; }
.welcome-content { display: grid; grid-template-columns: 1fr 1.15fr; align-items: center; gap: 26px; padding: 38px 34px 34px; background: radial-gradient(ellipse at 95% 5%, #fff0bd, transparent 55%), #fffdf1; }
.welcome-start { padding-left: 5px; }
.welcome-tag { display: inline-block; margin-bottom: 18px; padding: 4px 12px 5px; font: bold 14px var(--hand); color: #a22d68; background: #ffe0eb; border: 1px solid #efb0c8; border-radius: 45% 12px 40% 10px; transform: rotate(-4deg); }
.welcome-start h2 { color: var(--purple); font-size: clamp(40px, 4.7vw, 53px); letter-spacing: -1.8px; line-height: 1.05; text-shadow: 1px 2px #ead5f0; }
.welcome-start > p:not(.welcome-tag):not(.small-note) { max-width: 310px; font-size: 14px; color: #725475; }
.primary-button { display: inline-flex; align-items: center; justify-content: space-between; gap: 33px; margin: 10px 0 0; padding: 15px 23px; color: #164c54; background: linear-gradient(#e6fff1, #a6f5d5 45%, #63dcbb 46%, #8fedcb); border: 3px solid #408b82; border-radius: 24px 20px 25px 17px; font: 900 20px var(--display); box-shadow: inset 0 2px #fff, inset 0 -3px #48bda3, 2px 5px 0 #276c71; text-shadow: 0 1px #d8fff1; }
.primary-button:hover { color: #164c54; background: linear-gradient(#f0fff4, #b2ffe1 45%, #7be6c8 46%, #a6f8dd); }
.primary-button:active { box-shadow: inset 0 2px 3px #4dab9c, 0 2px 0 #276c71; }
.primary-button span { width: 0; height: 0; border-top: 7px solid transparent; border-bottom: 7px solid transparent; border-left: 11px solid currentColor; }
.welcome-start .small-note { color: #7d637d; font-size: 10px; margin: 18px 0 0; }
.pet-room { position: relative; min-width: 0; height: 370px; isolation: isolate; }
.pet-room::before { content: ""; position: absolute; z-index: -2; inset: 16px 0 9px 12px; background: #75e3de; border: 3px solid #44a5ac; border-radius: 45% 36% 40% 38%; transform: rotate(-7deg); box-shadow: inset 0 0 0 6px #c6f8ed; }
.pet-room::after { content: ""; position: absolute; z-index: -1; left: 24px; right: -3px; bottom: 8px; height: 79px; background: #ffba55; border: 2px solid #e99a4c; border-radius: 45% 44% 40% 48%; transform: rotate(5deg); }
.pet-card { position: absolute; background: #fff; border: 3px solid #9b5caf; border-radius: 20px; box-shadow: 4px 5px 0 #47355d30, inset 0 0 0 3px #ead3f4; padding: 6px 7px 8px; }
.pet-picture { position: relative; overflow: hidden; aspect-ratio: 1.9; background: #fff; border-radius: 12px 12px 3px 3px; }
.pet-picture img { display: block; position: absolute; width: 106%; height: auto; top: -2%; left: -3%; }
.cat-card { z-index: 2; width: 57%; right: 7px; top: 0; transform: rotate(7deg); border-color: #df68a0; }
.dog-card { z-index: 1; width: 76%; left: 0; top: 143px; transform: rotate(-5deg); }
.pet-name { display: block; text-align: center; color: #71418c; padding-top: 5px; font: bold 16px var(--hand); }
.pet-name > span { color: #886c83; font: 10px Verdana, Arial, sans-serif; margin-left: 3px; }
.room-spark { position: absolute; color: #cf732a; font-size: 39px; line-height: 1; text-shadow: 2px 1px #ffefa8; }
.spark-one { top: 17px; left: 38px; transform: rotate(-15deg); }
.spark-two { bottom: 81px; right: 0; font-size: 33px; color: #b254aa; }
.toy-ball { position: absolute; right: 14px; bottom: 1px; width: 62px; height: 62px; filter: drop-shadow(2px 3px 0 #d99b4b); }
.save-note { display: flex; align-items: flex-start; gap: 13px; padding: 16px 24px; background: #fff4cf; border-top: 2px dashed #e5bd7b; color: #7b5c59; font-size: 11px; }
.save-note strong { color: #644658; font-weight: bold; }
.save-note p { margin: 0; }
.save-icon { position: relative; display: block; flex: 0 0 24px; width: 24px; height: 26px; background: #bb91d2; border: 2px solid #805096; border-radius: 3px; box-shadow: inset 1px 1px #e9c7f2; margin-top: 2px; }
.save-icon::before { content: ""; position: absolute; left: 4px; right: 4px; top: -2px; height: 9px; background: #fff9df; border: 2px solid #805096; border-radius: 0 0 2px 2px; }
.save-icon::after { content: ""; position: absolute; left: 3px; right: 3px; bottom: 0; height: 9px; background: #f8ebfc; border: 1px solid #805096; }
.save-note details { margin-top: 4px; max-width: 760px; }
summary { color: #076c72; cursor: pointer; line-height: 1.6; }
summary:hover { color: #a42d73; }
details p { margin: 12px 0 0; }
.site-shell:has(#game:not([hidden])) #about { display: none; }
.site-shell:has(#game:not([hidden])) main { padding-top: 10px; }
.game-panel { padding: 0 23px 16px; }
.toolbar { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px; max-width: 650px; min-height: 52px; margin: 0 auto; padding: 8px 0; font-size: 12px; color: #496d6b; }
.play-label { color: #874d9e; font: bold 16px var(--hand); }
.stage { overflow: hidden; background: #000; max-width: 650px; border: 5px solid #57b9b2; border-radius: 0; margin: 0 auto; box-shadow: 2px 3px 0 #cae6d1; }
canvas { display: block; width: 100%; height: auto; aspect-ratio: 4 / 3; touch-action: none; }
.director-frame { display: block; }
.game-notes { max-width: 650px; margin: 13px auto 0; text-align: center; font-size: 11px; color: #75647b; }
.game-notes p { margin-bottom: 4px; }
.game-notes details p { text-align: left; }
#message { margin: 18px 0; padding: 10px 14px; color: #8e3554; border: 1px solid #d789a2; border-radius: 9px; background: #fff3e1; font-size: 13px; line-height: 1.6; }
#message:empty { display: none; }
.site-footer { margin-top: 28px; padding: 18px 7px 0; border-top: 2px dotted #d7ac67; font-size: 11px; color: #71586c; }
.footer-heading { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin-bottom: 11px; }
.fan-stamp { display: inline-block; padding: 4px 8px; color: #775285; background: #fbe3ef; border: 1px solid #bd84a8; border-radius: 7px 4px 8px 5px; font-size: 9px; font-weight: bold; letter-spacing: .5px; }
.disclaimer { margin: 0; }
.legal-details { max-width: 850px; }
.legal-details summary { display: list-item; width: fit-content; }
.legal-copy { text-align: left; padding: 4px 14px 16px; margin: 12px 0; background: #fff9e4; border: 1px solid #ddb981; border-radius: 10px; }
.footer-links { display: flex; gap: 12px 25px; flex-wrap: wrap; margin-top: 12px; font-size: 11px; }
.footer-links span { color: #7d6681; font-size: 10px; }
/* The private edition keeps its existing controller and account fields. */
.card { max-width: 450px; margin: 0 auto; padding: 26px; }
.card .welcome-tag { font-size: 12px; }
.card h2 { color: #79429a; font-size: 34px; }
.card > p:not(.welcome-tag) { font-size: 13px; }
label { display: block; margin: 18px 0 12px; font-size: 12px; font-weight: bold; color: #6f457a; }
input { display: block; margin-top: 7px; width: 100%; padding: 10px; font: inherit; font-size: 16px; color: #4c3457; background: #fff; border: 2px solid #be9bc7; border-radius: 8px; box-shadow: inset 1px 2px #ece1f0; }
.card button { width: 100%; margin: 10px 0 16px; }
.quiet { color: #79657c; font-size: 12px; line-height: 1.6; }
nav#game-controls { display: flex; justify-content: center; gap: 9px; flex-wrap: wrap; margin-top: 22px; }
#instructions, .build-note { max-width: 650px; margin: 16px auto 0; font-size: 12px; line-height: 1.6; }
.locked canvas { pointer-events: none; opacity: .6; }
@media (max-width: 760px) {
  .site-shell { padding: 22px 20px; }
  h1 { font-size: 29px; letter-spacing: -1.5px; }
  .paw-mark { width: 44px; height: 44px; flex-basis: 44px; }
  .paw-mark svg { width: 30px; height: 30px; }
  .site-identity { gap: 10px; }
  .eyebrow { font-size: 9px; }
  .welcome-content { gap: 18px; padding: 30px 24px; }
  .welcome-start h2 { font-size: 37px; }
  .welcome-start > p:not(.welcome-tag):not(.small-note) { font-size: 12px; }
  .primary-button { font-size: 17px; padding: 13px 16px; gap: 23px; }
  .pet-room { height: 300px; }
  .dog-card { top: 125px; }
  .pet-name { font-size: 14px; }
  .pet-name > span { display: none; }
}
@media (max-width: 600px) {
  .site-shell { padding: 20px 17px 22px; }
  .masthead { flex-wrap: wrap; gap: 17px; padding-bottom: 14px; }
  h1 { font-size: clamp(23px, 6.7vw, 31px); }
  .header-actions { width: 100%; justify-content: flex-start; }
  .header-actions .nav-link { font-size: 11px; padding: 7px 13px; }
  .project-note { font-size: 11px; margin: 4px 5px 20px; }
  .welcome-panel, .game-panel, .card { border-radius: 23px 17px 25px 18px; box-shadow: 0 0 0 4px #e4b6e8, 3px 6px 0 3px #dfa24c55; }
  .welcome-content { grid-template-columns: 1fr; gap: 24px; padding: 25px 21px 19px; }
  .welcome-start { text-align: center; padding: 0; }
  .welcome-tag { font-size: 13px; margin-bottom: 16px; }
  .welcome-start h2 { font-size: clamp(34px, 10.3vw, 44px); letter-spacing: -1.3px; }
  .welcome-start > p:not(.welcome-tag):not(.small-note) { font-size: 12px; max-width: 250px; margin: 0 auto 12px; }
  .primary-button { font-size: 19px; padding: 14px 21px; gap: 30px; }
  .welcome-start .small-note { font-size: 10px; }
  .pet-room { height: 285px; width: 100%; max-width: 350px; margin: 0 auto; }
  .cat-card { width: 57%; top: 0; }
  .dog-card { width: 83%; top: 119px; }
  .pet-name { font-size: 14px; }
  .spark-one { left: 21px; font-size: 31px; }
  .toy-ball { width: 51px; height: 51px; bottom: 13px; right: 6px; }
  .save-note { padding: 16px 14px; gap: 11px; font-size: 10px; }
  .game-panel { padding: 0 7px 13px; }
  .toolbar { font-size: 10px; gap: 7px; min-height: 42px; }
  .play-label { font-size: 13px; }
  .game-notes { font-size: 10px; }
  .site-footer { font-size: 10px; margin-top: 25px; padding-left: 1px; padding-right: 1px; }
  .footer-links { font-size: 10px; gap: 10px 16px; line-height: 1.5; }
  .card { padding: 22px 18px; }
  .site-shell:has(#game:not([hidden])) { padding: 12px 10px 18px; }
  .site-shell:has(#game:not([hidden])) main { padding-top: 5px; }
  .site-shell:has(#game:not([hidden])) .masthead { gap: 10px; padding-bottom: 11px; }
  .site-shell:has(#game:not([hidden])) .paw-mark { display: none; }
  .site-shell:has(#game:not([hidden])) h1 { font-size: clamp(20px, 5.8vw, 28px); letter-spacing: -1px; }
  .site-shell:has(#game:not([hidden])) .eyebrow { font-size: 8px; }
  .site-shell:has(#game:not([hidden])) .header-actions { width: auto; margin-left: auto; }
  .site-shell:has(#game:not([hidden])) .header-actions > a:not(.catalog-link) { display: none; }
  .site-shell:has(#game:not([hidden])) .header-actions .catalog-link { font-size: 10px; padding: 8px 10px; }
  .site-shell:has(#game:not([hidden])) .header-actions button { font-size: 10px; padding: 8px 10px; }
}
@media (forced-colors: active) {
  button, .nav-link, .stage, .welcome-panel, .game-panel, .card { border-color: ButtonText; }
  .primary-button span { border-left-color: ButtonText; }
}
