:root { color-scheme: dark; --ivory: #f1e6cf; --gold: #c9ac71; --green: #102c1c; }
html, body { background: #0c2418 url('theme-green.png') repeat; background-size: 650px; }
body { color: var(--ivory); font: 14px/1.5 system-ui, sans-serif; }
body::before, body::after { content: ''; position: fixed; z-index: 0; pointer-events: none; top: 12px; bottom: 12px; width: 22px; opacity: .18; background: url('theme-ornament.svg') center top / 22px 96px repeat-y; }
body::before { left: 8px; } body::after { right: 8px; }
header { position: relative; z-index: 3; width: min(540px, calc(100% - 24px)); align-self: center; min-height: 56px; margin: 8px 0 6px; padding: 5px 10px; gap: 6px; flex-wrap: nowrap; background: linear-gradient(110deg, #20251eea, #111a13ed); border: 1px solid #8d8873; box-shadow: inset 0 0 0 2px #151c15, inset 0 0 0 3px #4a4b3c, 0 3px 10px #0005; }
header::after { content: ''; flex: 0 1 72px; height: 18px; order: 1; opacity: .75; background: url('theme-knot.svg') center / contain no-repeat; pointer-events: none; }
#save-status { flex: 1 1 120px; max-width: none; display: flex; align-items: center; gap: 7px; font-size: 11px; line-height: 1.35; }
#save-status::before { content: ''; flex: 0 0 25px; height: 25px; background: url('theme-cloud.svg') center / contain no-repeat; }
button { border-radius: 3px; border: 1px solid #958e73; color: var(--ivory); background: linear-gradient(#29412a, #172b1c); box-shadow: inset 0 0 0 2px #101910, 0 2px 6px #0003; font: inherit; transition: filter .15s, border-color .15s; }
button:hover { filter: brightness(1.16); border-color: #d6be86; }
button:active { filter: brightness(.85); }
button:focus-visible { outline: 2px solid #e1c178; outline-offset: 3px; }
button:disabled { opacity: .5; }
#fullscreen-toggle, #sound-toggle, #account-toggle { order: 2; width: 44px; height: 44px; min-height: 44px; padding: 9px; border-radius: 50%; background: radial-gradient(circle at 35% 20%, #3c4035, #141c15 70%); box-shadow: inset 0 0 0 2px #111910, inset 0 0 0 3px #6d6d5b, 0 2px 5px #0006; font-size: 0; }
#fullscreen-toggle::before, #sound-toggle::before, #account-toggle::before { content: ''; display: block; width: 24px; height: 24px; background-position: center; background-size: contain; background-repeat: no-repeat; }
#fullscreen-toggle::before { background-image: url('theme-fullscreen.svg'); }
#sound-toggle::before { background-image: url('theme-sound.svg'); }
#sound-toggle[aria-pressed='true']::before { opacity: .45; }
#sound-toggle[aria-pressed='true'] { position: relative; }
#sound-toggle[aria-pressed='true']::after { content: ''; position: absolute; left: 9px; right: 9px; top: 21px; height: 2px; background: var(--gold); transform: rotate(-45deg); }
#account-toggle::before { background-image: url('theme-account.svg'); }
#retry { order: 2; padding: 6px 9px; font-size: 12px; min-height: 44px; }
#account-menu { position: absolute; top: calc(100% + 8px); right: 0; width: min(280px, 90vw); padding: 12px; background: #11291bf5; border: 1px solid #9b947c; box-shadow: 0 8px 24px #0008; }
#account-menu button { width: 100%; }
#account-note { margin: 0 0 10px; font-size: 13px; }
#game-viewport { z-index: 1; }
#unity-canvas { background: transparent; }
#account-gate { background: #0b2418ed; gap: 12px; padding: 20px; }
#account-gate h1 { padding: 0; line-height: 0; }
#account-gate h1 img { width: 180px; height: auto; max-height: 80px; object-fit: contain; }
#account-message { color: #ded8c6; font-size: 14px; line-height: 1.6; }
#account-gate > button, #conflict button { min-height: 48px; }
#continue-guest { background: #182c1d; border-color: #5f7058; }
#conflict { gap: 8px; }
#conflict button { flex: 1 1 100%; font-size: 13px; }
@media (max-width: 370px) { header { width: calc(100% - 16px); gap: 4px; padding: 5px 7px; } header::after { display: none; } #save-status { font-size: 10px; gap: 4px; } #save-status::before { flex-basis: 20px; height: 20px; } #fullscreen-toggle, #sound-toggle, #account-toggle { width: 44px; } #retry { padding: 4px; font-size: 10px; } }
@media (prefers-reduced-motion: reduce) { button { transition: none; } }
