/* Zone Control's web page (polish #14, 2026-11-10). The game fills the window; the loading screen sits on top of it
   until the game is ready, then fades away. */
@font-face { font-family: "Lilita One"; src: url("LilitaOne-Regular.ttf") format("truetype"); font-display: swap; }

html, body { margin: 0; padding: 0; width: 100%; height: 100%; overflow: hidden; background: #10141c; }
#unity-canvas { position: fixed; inset: 0; width: 100%; height: 100%; display: block; background: #10141c; outline: none; }

#zc-loading { position: fixed; inset: 0; overflow: hidden; z-index: 10; transition: opacity 0.8s ease; font-family: "Lilita One", "Trebuchet MS", sans-serif; color: #f5eee1; }
#zc-loading.gone { opacity: 0; pointer-events: none; }

/* the world: crisp pixels, slowly drifting (a little bigger than the window, so the drift never shows an edge) */
#zc-world { position: absolute; inset: -6%; background: #2a3a24 center / cover no-repeat; image-rendering: pixelated; image-rendering: crisp-edges;
            animation: zc-drift 38s ease-in-out infinite alternate; opacity: 0; transition: opacity 0.6s ease; }
#zc-world.shown { opacity: 1; }
@keyframes zc-drift { from { transform: translate(-2%, -1%) scale(1.02); } to { transform: translate(2%, 1%) scale(1.06); } }
#zc-motes { position: absolute; inset: 0; width: 100%; height: 100%; }
#zc-shade { position: absolute; inset: 0; background: radial-gradient(ellipse at 50% 45%, rgba(8, 10, 16, 0) 35%, rgba(8, 10, 16, 0.55) 100%); }

#zc-title { position: absolute; left: 0; right: 0; top: 18%; text-align: center; font-size: clamp(40px, 9vmin, 110px); color: #ffd35a;
            text-shadow: 0 4px 0 #7a4a10, 0 8px 22px rgba(0, 0, 0, 0.6); letter-spacing: 0.02em; animation: zc-bob 3.2s ease-in-out infinite; }
@keyframes zc-bob { 50% { transform: translateY(-6px); } }

#zc-panel { box-sizing: border-box; position: absolute; left: 50%; bottom: 9%; width: min(560px, 84vw); transform: translateX(-50%); padding: 16px 22px 14px;
            background: rgba(22, 28, 40, 0.82); border: 2px solid rgba(160, 180, 210, 0.55); border-radius: 18px;
            box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45); text-align: center; }
#zc-status { font-size: clamp(16px, 2.4vmin, 22px); margin-bottom: 10px; }
#zc-bar { height: 18px; border-radius: 9px; background: rgba(255, 255, 255, 0.12); overflow: hidden; border: 1px solid rgba(255, 255, 255, 0.18); }
#zc-fill { height: 100%; width: 0%; border-radius: 9px; background: linear-gradient(180deg, #ffe08a, #f0a92b); box-shadow: 0 0 12px rgba(255, 200, 80, 0.8);
           transition: width 0.25s ease; }
#zc-tip { margin-top: 12px; min-height: 1.3em; font-family: "Trebuchet MS", "Segoe UI", sans-serif; font-size: clamp(13px, 2vmin, 16px); color: #cfd6e2;
          transition: opacity 0.4s ease; }
#zc-tip.fading { opacity: 0; }
#zc-loading.starting #zc-fill { animation: zc-pulse 1.1s ease-in-out infinite; }
@keyframes zc-pulse { 50% { filter: brightness(1.35); } }
#zc-loading.failed #zc-fill { background: #d9584a; box-shadow: none; }
#zc-loading.failed #zc-status { color: #ffb0a6; }

#zc-fullscreen { position: fixed; right: 10px; bottom: 10px; z-index: 5; width: 34px; height: 34px; border-radius: 9px; border: 1px solid rgba(255, 255, 255, 0.35);
                 background: rgba(22, 28, 40, 0.7); color: #f5eee1; font-size: 18px; cursor: pointer; opacity: 0.55; }
#zc-fullscreen:hover { opacity: 1; }
#zc-fullscreen[hidden] { display: none; }

/* Touch Controls (2026-11-16): an upright phone is asked to turn sideways (the game's layout is wide). Only on touch
   screens that are narrow when upright, so tablets held upright still play. */
#zc-rotate { display: none; position: fixed; inset: 0; z-index: 20; background: #10141c; color: #f5eee1; font-family: "Lilita One", "Trebuchet MS", sans-serif;
             align-items: center; justify-content: center; flex-direction: column; gap: 18px; text-align: center; padding: 24px; box-sizing: border-box; }
#zc-rotate .phone { width: 54px; height: 92px; border: 4px solid #ffd35a; border-radius: 12px; animation: zc-turn 2.4s ease-in-out infinite; }
#zc-rotate .words { font-size: 26px; line-height: 1.25; }
#zc-rotate .words b { color: #ffd35a; font-weight: normal; }
@keyframes zc-turn { 0%, 30% { transform: rotate(0deg); } 60%, 100% { transform: rotate(-90deg); } }
@media (orientation: portrait) and (pointer: coarse) and (max-width: 600px) { #zc-rotate { display: flex; } }
/* the full-screen button is a finger's size on touch screens */
@media (pointer: coarse) { #zc-fullscreen { width: 46px; height: 46px; font-size: 24px; opacity: 0.8; } }
