@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=Outfit:wght@500;600;700;800;900&display=swap');
:root{font-family:'DM Sans',sans-serif;color:#fff9df;background:#062e42;font-synthesis:none}*{box-sizing:border-box}body{margin:0;overflow:hidden}button,a{-webkit-tap-highlight-color:transparent}button{font:700 15px 'DM Sans',sans-serif;cursor:pointer;border:1px solid #ffffff35;border-radius:14px;background:#073d50d9;color:#fff9df;padding:12px 20px;touch-action:none}button:hover{background:#116077}button:focus-visible,a:focus-visible{outline:3px solid #ffda7b;outline-offset:4px}[hidden]{display:none!important}#game{height:100dvh;min-height:420px;position:relative;overflow:hidden}canvas{width:100%;height:100%;display:block}header{position:absolute;top:28px;left:38px;right:38px;display:flex;justify-content:space-between;align-items:center;z-index:4}.brand{color:#fff9df;text-decoration:none;letter-spacing:2px;font:800 16px Outfit,sans-serif}.brand:first-letter{color:#ffce6b}.top-actions{display:flex;gap:8px}.top-actions button{font-size:12px;padding:9px 14px;border-radius:30px}.panel{position:absolute;inset:0;display:flex;flex-direction:column;justify-content:center;align-items:flex-start;padding:85px 9%;pointer-events:none}.panel>*{pointer-events:auto}.eyebrow{font-size:12px;font-weight:700;letter-spacing:3px;color:#9ce4d6;margin:0 0 20px}.panel h1{font:900 clamp(64px,9vw,132px)/.85 Outfit,sans-serif;letter-spacing:-5px;margin:0 0 25px;text-shadow:0 5px 0 #084457}.panel h1 em{color:#ffdb87;font-style:normal}.panel h2{font:800 clamp(36px,5vw,64px)/1 Outfit,sans-serif;margin:0 0 20px;letter-spacing:-2px}.panel p{font-size:16px;line-height:1.7;max-width:380px;color:#d3ece7;margin:0 0 24px}.buttons{display:flex;gap:10px;flex-wrap:wrap}.primary{background:#ffda7b;color:#173f4b;border:0;box-shadow:0 4px 0 #c79542;padding:16px 30px}.primary:hover{background:#ffe6a5}.secondary{background:#09475bd9}.trip{display:flex;gap:20px;margin-top:40px;font-size:12px;color:#abd9d9}.trip b{display:block;color:#fff9df;font:600 19px Outfit;margin-bottom:5px}.panel.center{align-items:center;text-align:center;background:#052e47b8;backdrop-filter:blur(5px)}.panel.center p{max-width:480px}.records{display:flex;gap:14px;margin-bottom:28px}.record{background:#0b5062;padding:24px;border-radius:20px;min-width:140px}.record strong{display:block;font:700 32px Outfit;color:#ffdb87}.record span{font-size:12px}footer{position:absolute;bottom:25px;left:9%;font-size:10px;letter-spacing:3px;color:#b0d9d5}#hud{position:absolute;left:38px;right:38px;top:90px;display:flex;align-items:flex-start;justify-content:space-between;pointer-events:none}.vitals{width:190px}.vitals>span{font:600 16px Outfit}.health{height:10px;background:#052f43;border-radius:10px;margin:10px 0;overflow:hidden}.health i{display:block;height:100%;background:#8ce3bb;transition:width .15s}.vitals small,.wallet small{display:block;color:#bce7e3;font-size:12px}.depth{text-align:center;position:absolute;left:50%;transform:translateX(-50%)}.depth strong{font:800 44px/.95 Outfit;display:block}.depth span{font-size:10px;letter-spacing:2px}.depth small{display:block;margin-top:7px;font-size:11px;color:#a9ddd4}.wallet{text-align:right}.wallet b{font:700 28px Outfit}.wallet>span{color:#ffdb87}#toast{position:absolute;top:180px;width:100%;text-align:center;color:#ffe29c;font-weight:700;pointer-events:none}#bossHud{position:absolute;bottom:165px;left:30%;width:40%;text-align:center;font:600 16px Outfit}#bossHealth{background:#faaf8c}#controls{position:absolute;bottom:30px;left:38px;right:38px;display:flex;justify-content:space-between;align-items:center;pointer-events:none}#controls button{pointer-events:auto;user-select:none}#attack{border-radius:50%;width:94px;height:94px;background:#ffda7b;color:#153d4b;font-size:30px;box-shadow:0 5px 0 #b88942}#attack span{display:block;font-size:10px;letter-spacing:1px}#shop{position:absolute;bottom:35px;left:50%;transform:translateX(-50%);background:#ffdb87;color:#173e4b} @media(max-width:650px){header{top:18px;left:20px;right:20px}.brand{font-size:12px}.panel{padding:80px 7%}.panel h1{font-size:76px}.panel p{max-width:270px;font-size:14px}.trip{gap:16px;margin-top:28px}.trip b{font-size:15px}#hud{left:20px;right:20px;top:78px}.vitals{width:120px}.vitals>span{font-size:13px}#controls{left:18px;right:18px;bottom:22px}.records{gap:6px}.record{min-width:0;padding:15px 12px}.record strong{font-size:27px}#toast{top:160px;font-size:12px}#shop{bottom:145px;font-size:12px}#bossHud{bottom:195px;left:20%;width:60%}footer{font-size:8px}.panel.center{padding-top:100px}}

/* Sunlit reef: the interface sits lightly over the dimensional artwork. */
header{top:22px;left:30px;right:30px}.brand{text-shadow:0 2px 8px #07384899}.top-actions button{background:#123e5280;backdrop-filter:blur(14px);box-shadow:inset 0 1px 0 #ffffff30}.panel h1{text-shadow:0 4px 0 #07384944,0 12px 35px #07384944}.panel p{text-shadow:0 2px 12px #07384988}.eyebrow{text-shadow:0 2px 10px #07384988;color:#ccf7e8}.panel.center{background:linear-gradient(135deg,#062c4699,#123c4c66);backdrop-filter:blur(12px)}.panel.center h2{text-shadow:0 3px 20px #072f4c66}.primary{background:linear-gradient(#ffe9a4,#ffce6d);border:1px solid #fff3c9;box-shadow:0 4px 0 #bd904a,0 8px 25px #102c4050}.secondary{backdrop-filter:blur(12px);background:#0b3e5277}.trip{color:#d4e9de;text-shadow:0 2px 10px #08344d}.trip b{color:#fff8dd}#hud{top:83px;left:30px;right:30px}.vitals,.wallet,.depth{padding:14px 17px;border-radius:20px;background:linear-gradient(140deg,#124153aa,#0b354377);border:1px solid #ffffff30;backdrop-filter:blur(16px);box-shadow:0 8px 26px #062b4218,inset 0 1px 0 #ffffff12}.depth{padding:12px 26px}.depth strong{font-size:39px;text-shadow:0 3px 0 #0e344777}.depth small{color:#d2ede3}.vitals{width:200px}.health{height:9px;background:#052f4377;box-shadow:inset 0 1px 3px #001b3350}.health i{background:linear-gradient(#c3f6b9,#70d4b1);border-radius:10px}.wallet{min-width:100px}.wallet span{color:#ffdf8b}#toast{top:195px;text-shadow:0 2px 8px #062b45,0 0 20px #062b45}#attack{background:linear-gradient(145deg,#fff0b7,#ffcf70);border:2px solid #fff0bd;box-shadow:0 5px 0 #bd9146,0 10px 30px #062f4350}#bossHud{background:#082c4599;border:1px solid #ffffff33;padding:14px 20px 7px;border-radius:20px;backdrop-filter:blur(12px)}footer{color:#e2f0de;text-shadow:0 2px 12px #062d47}#loading{position:absolute;inset:0;z-index:100;background:radial-gradient(ellipse at 35% 20%,#229daf,#073851);display:flex;flex-direction:column;align-items:center;justify-content:center;gap:15px;color:#fff2c9}.loading-pearl{font-size:55px;animation:pearl 1.8s ease-in-out infinite}#loading p{font-size:14px;letter-spacing:1px}@keyframes pearl{50%{transform:translateY(-8px);opacity:.5}}@media(max-width:650px){header{left:18px;right:18px;top:18px}#hud{left:16px;right:16px;top:77px}.vitals{width:130px;padding:11px}.wallet{min-width:75px;padding:10px}.wallet b{font-size:23px}.depth{padding:10px 15px}.depth strong{font-size:34px}.depth small{font-size:9px}.vitals small{font-size:10px}.panel h1{font-size:76px}.panel:not(.center){background:linear-gradient(90deg,#052e4844,transparent)}#toast{top:184px;font-size:11px}.trip{margin-top:26px}#bossHud{padding:10px 15px 5px}}@media(max-width:390px){.vitals{width:110px}.depth{padding:9px 12px}.wallet{min-width:65px}.panel h1{font-size:65px}.trip{gap:12px}.top-actions button{padding:8px 10px}.brand{font-size:10px}}@media(prefers-reduced-motion:reduce){.loading-pearl{animation:none}}

.shelf-link{font:700 12px 'DM Sans',sans-serif;color:#fff9df;background:#123e5280;border:1px solid #ffffff35;border-radius:30px;padding:9px 14px;backdrop-filter:blur(14px);text-decoration:none;white-space:nowrap}.shelf-link:hover{background:#1a637b}.shelf-link:focus-visible{outline:3px solid #ffda7b;outline-offset:3px}@media(max-width:650px){header{flex-wrap:wrap;row-gap:8px}.top-actions{gap:5px}.shelf-link{font-size:10px;padding:8px 9px}.top-actions button{font-size:10px;padding:8px 9px}.brand{font-size:10px;letter-spacing:1px}}@media(max-width:390px){header{left:12px;right:12px}.brand{font-size:9px;letter-spacing:.5px}.shelf-link{font-size:9px;padding:7px}.top-actions button{font-size:9px;padding:7px}.top-actions{gap:4px}}

/* Discoveries and the second tool stay within thumb reach. */
.action-buttons{display:flex;gap:12px;align-items:flex-end;pointer-events:none}#bubble{border-radius:50%;width:86px;height:86px;background:linear-gradient(145deg,#d7ffff,#69d6e9);border:2px solid #e7ffff;color:#123f53;box-shadow:0 5px 0 #37859e;font-size:32px;padding:8px}#bubble span{display:block;font-size:9px;letter-spacing:.4px}#bubble:disabled{opacity:.55;cursor:default;background:#16465a;color:#e0f6f7;box-shadow:none;border-color:#9cc5cc66}#discoveries{margin-top:7px;font-size:10px;line-height:1.5;color:#ffdfa0}.dive-tips{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;max-width:490px;margin:0 0 24px;text-align:left}.dive-tips span{padding:12px;border:1px solid #bce9e333;border-radius:12px;background:#07354b99;font-size:12px;line-height:1.5;color:#d6eeea}.dive-tips b{display:block;color:#ffe19d;font-size:13px;margin-bottom:3px}.panel.center{overflow-y:auto}.panel .dive-results{font-size:13px;color:#ffe19d}#hud .vitals{width:225px}@media(max-width:650px){#hud .vitals{width:128px}#discoveries{font-size:8px}.action-buttons{gap:8px}#bubble{width:68px;height:68px;font-size:25px}#bubble span{font-size:7px}#attack{width:76px;height:76px}.dive-tips{gap:7px;margin-bottom:16px}.dive-tips span{padding:9px;font-size:11px}.panel.center p{font-size:13px;margin-bottom:16px}.panel.center h2{font-size:36px;margin-bottom:14px}}@media(max-height:740px){.panel.center{justify-content:flex-start;padding-top:165px;padding-bottom:150px}.panel.center .eyebrow{margin-bottom:12px}}

/* The characters themselves are the start controls. */
.panel.title-panel{padding:85px 7% 65px;overflow-y:auto;pointer-events:auto}
.title-layout{width:100%;max-width:1200px;margin:auto;display:grid;grid-template-columns:1fr 1.1fr;gap:18px 40px;align-items:center}
.title-copy .eyebrow{font-size:11px;letter-spacing:2px}.title-copy h1{font-size:clamp(70px,9vw,124px)}
.title-actions button{font-size:12px;padding:10px 15px}.title-copy .trip{margin-top:28px}
.diver-picker{border:0;min-width:0;padding:0;margin:0;text-align:center}
.diver-picker legend{float:left;width:100%;font:700 24px Outfit,sans-serif;color:#fff1c6;letter-spacing:-.5px;padding:0}
.panel .choose-hint{clear:both;max-width:none;font-size:13px;margin:8px 0 16px}
.diver-choices{display:grid;gap:12px}.diver-choice{display:block;width:100%;padding:0 12px 10px;background:radial-gradient(ellipse,#b2f5e822,transparent 70%);border:1px solid transparent;border-radius:32px;transition:background .2s,border-color .2s,transform .2s;touch-action:manipulation}
.diver-choice canvas{display:block;width:100%;height:auto;aspect-ratio:600/270;pointer-events:none}
.diver-choice span{display:block;font-size:12px;font-weight:700;color:#fff0be;letter-spacing:1px}
.diver-choice:hover,.diver-choice:focus-visible{background:radial-gradient(ellipse,#9ee9df44,#06394d55 75%);border-color:#e4ffef88;transform:translateY(-3px)}
.panel .title-controls{grid-column:1/-1;max-width:none;text-align:center;font-size:11px;line-height:1.8;color:#d6efea;margin:5px 0 0}
@media(max-width:700px){.panel.title-panel{padding:90px 6% 35px;justify-content:flex-start}.title-layout{grid-template-columns:1fr;gap:22px;margin:0 auto}.title-copy{text-align:center}.title-copy h1{font-size:68px;letter-spacing:-3px;margin-bottom:16px}.title-copy .eyebrow{font-size:9px;letter-spacing:1.5px;margin-bottom:14px}.title-copy p{max-width:none;font-size:13px;margin-bottom:16px}.title-actions{justify-content:center}.title-copy .trip{display:none}.diver-picker legend{font-size:22px}.diver-choices{grid-template-columns:1fr 1fr;gap:8px}.diver-choice{padding:8px 0 12px;border-color:#d5ffef33;background:#06394d55;border-radius:20px}.diver-choice span{font-size:10px}.panel .choose-hint{font-size:12px;margin-bottom:10px}.panel .title-controls{font-size:10px;margin:0}.title-panel~footer{display:none}}
@media(max-height:650px) and (min-width:701px){.panel.title-panel{justify-content:flex-start;padding-top:85px;padding-bottom:25px}.title-layout{gap:8px 30px}.title-copy h1{font-size:72px}.title-copy .trip{display:none}.diver-choices{grid-template-columns:1fr 1fr}.diver-picker legend{font-size:20px}.title-panel~footer{display:none}}
@media(prefers-reduced-motion:reduce){.diver-choice{transition:none}}

/* Analog thumb control: one captured finger can steer while another attacks. */
.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap;border:0}
#controls{align-items:flex-end;left:calc(24px + env(safe-area-inset-left,0px));right:calc(24px + env(safe-area-inset-right,0px));bottom:calc(24px + env(safe-area-inset-bottom,0px));user-select:none;-webkit-user-select:none;touch-action:none}
#joystick{position:relative;flex:0 0 auto;width:140px;height:140px;border-radius:50%;pointer-events:auto;touch-action:none;cursor:grab;background:radial-gradient(circle,#83d8dc22 0 35%,#0a3b5277 36% 68%,#d1ffff22 69%);border:2px solid #d6ffff66;box-shadow:inset 0 2px 15px #d0ffff22,0 6px 25px #062b4344;backdrop-filter:blur(7px)}
#joystick[data-active="true"]{cursor:grabbing;border-color:#d4ffffbb;background:radial-gradient(circle,#a6f2ef33 0 35%,#0a3b5288 36% 68%,#d1ffff44 69%)}
.joystick-axis{position:absolute;inset:16px;border:1px dashed #c9ffff33;border-radius:50%;pointer-events:none}
#joystickStick{position:absolute;width:58px;height:58px;left:calc(50% - 29px);top:calc(50% - 29px);display:grid;place-items:center;border:2px solid #e3ffffaa;border-radius:50%;background:linear-gradient(145deg,#c5f4ecdd,#609facdd);box-shadow:0 4px 10px #042e4d66,inset 0 2px 4px #ffffff66;color:#155069;font-size:28px;pointer-events:none;transition:transform .14s ease-out}
#joystick[data-active="true"] #joystickStick{transition:none;background:linear-gradient(145deg,#e4fff4,#87c9cc)}
.joystick-label{position:absolute;bottom:10px;left:0;right:0;text-align:center;font-size:8px;font-weight:700;letter-spacing:2px;color:#e1f6f1;pointer-events:none}
.action-buttons button[data-held="true"]{filter:brightness(1.15);transform:translateY(2px)}
@media(max-width:650px){#controls{left:calc(16px + env(safe-area-inset-left,0px));right:calc(16px + env(safe-area-inset-right,0px));bottom:calc(20px + env(safe-area-inset-bottom,0px))}#joystick{width:120px;height:120px}#joystickStick{width:52px;height:52px;left:calc(50% - 26px);top:calc(50% - 26px);font-size:25px}.joystick-label{bottom:7px;font-size:7px}}
@media(max-height:500px) and (orientation:landscape){#game{min-height:0}#controls{bottom:calc(12px + env(safe-area-inset-bottom,0px))}#joystick{width:108px;height:108px}#joystickStick{width:48px;height:48px;left:calc(50% - 24px);top:calc(50% - 24px)}#attack{width:76px;height:76px}#bubble{width:68px;height:68px}#hud{top:62px}.vitals,.wallet,.depth{padding:8px 12px}.depth strong{font-size:28px}#toast{top:165px;font-size:11px}}
@media(prefers-reduced-motion:reduce){#joystickStick{transition:none}}

@media(max-width:650px) and (orientation:portrait){.vitals>span{font-size:11px}#toast{top:230px;padding:0 16px;line-height:1.5}}

/* Every world is available before choosing a diver. */
.level-picker{border:0;padding:0;margin:0 0 18px;min-width:0}.level-picker legend{font-size:11px;letter-spacing:1px;font-weight:700;color:#d5f7e9;padding:0;margin-bottom:10px}.level-choices{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}.level-choice{position:relative;overflow:hidden;padding:0;border:2px solid #ffffff44;border-radius:12px;background:#07394e;min-height:88px;touch-action:manipulation}.level-choice img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;opacity:.65}.level-choice span{position:relative;display:flex;min-height:88px;align-items:flex-end;padding:12px 8px 9px;font-size:11px;line-height:1.3;text-align:left;color:#fff8dd;background:linear-gradient(transparent,#052c49ee)}.level-choice[aria-pressed="true"]{border-color:#ffe29a;box-shadow:0 0 0 2px #ffdc6b33}.level-choice[aria-pressed="true"] span{color:#ffe29a}.level-choice:hover img{opacity:1}.title-copy h1{font-size:clamp(64px,8vw,108px)}.title-copy .trip{margin-top:20px}.panel .next-countdown{font-size:18px;color:#ffe29a}
@media(max-width:700px){.panel.title-panel{padding-top:78px;padding-bottom:24px}.title-layout{gap:14px}.title-copy .eyebrow{margin-bottom:10px}.title-copy h1{font-size:52px;margin-bottom:10px}.title-copy p{margin-bottom:12px}.level-picker{margin-bottom:12px}.level-picker legend{width:100%;margin-bottom:7px}.level-choice,.level-choice span{min-height:64px}.level-choice span{font-size:10px;padding:8px 6px}.title-actions button{padding:8px 12px;font-size:11px}.diver-picker legend{font-size:20px}.panel .choose-hint{font-size:11px;margin:5px 0 8px}.panel .title-controls{font-size:9px}}

/* Keep both diver choices comfortably sized, including narrow Safari grids. */
.title-layout{grid-template-columns:minmax(0,1fr) minmax(0,1.1fr)}
.title-copy,.diver-picker,.diver-choice{min-width:0}
.diver-choices{justify-items:center}
.diver-choice{max-width:360px;padding:0 10px 10px}
.diver-choice canvas{max-width:100%}
.panel.title-panel{padding-left:max(6%,env(safe-area-inset-left));padding-right:max(6%,env(safe-area-inset-right));padding-bottom:max(32px,env(safe-area-inset-bottom))}
@media(max-width:700px){.title-layout{grid-template-columns:minmax(0,1fr)}.diver-choices{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.diver-choice{max-width:190px;padding:6px 4px 10px}.panel.title-panel{padding-top:72px}.title-copy h1{font-size:48px}.title-layout{gap:12px}}
@media(max-width:700px) and (max-height:620px){.title-copy .eyebrow{display:none}.title-copy h1{font-size:42px}.panel.title-panel{padding-top:66px;padding-bottom:16px}.title-layout{gap:10px}.level-choice,.level-choice span{min-height:56px}.diver-picker legend{font-size:18px}.panel .title-controls{font-size:8px}}
@media(orientation:landscape) and (max-height:500px){.panel.title-panel{padding:70px max(4%,env(safe-area-inset-right)) 18px max(4%,env(safe-area-inset-left))}.title-layout{grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:10px 22px;align-items:center}.title-copy .eyebrow,.title-copy .trip,.panel .title-controls{display:none}.title-copy h1{font-size:40px;letter-spacing:-2px;margin-bottom:8px}.title-copy h1 br{display:none}.title-copy p{font-size:11px;margin-bottom:8px}.level-picker{margin-bottom:8px}.level-picker legend{font-size:9px;margin-bottom:6px}.level-choice,.level-choice span{min-height:58px}.level-choice span{font-size:9px;padding:7px 5px}.title-actions{gap:6px}.title-actions button{font-size:10px;padding:7px 10px}.diver-picker legend{font-size:18px}.panel .choose-hint{font-size:10px;margin:5px 0 7px}.diver-choices{grid-template-columns:repeat(2,minmax(0,1fr));gap:7px}.diver-choice{padding:6px 2px 9px;border:1px solid #d5ffef33;border-radius:16px;background:#06394d55}.diver-choice span{font-size:9px}.title-panel~footer{display:none}}
