@import url('https://fonts.googleapis.com/css2?family=DM+Mono:wght@400;500&family=DM+Sans:wght@400;500;600;700&family=Manrope:wght@400;500;600;700;800&display=swap');

:root {
  color-scheme: dark;
  --ink: #eef9fa;
  --muted: #91a9ad;
  --faint: #536b70;
  --sea: #020506;
  --panel: #090f12;
  --panel-light: #10191d;
  --line: #1d353b;
  --cyan: #36bfd0;
  --lime: #c4edf0;
  --amber: #82c5cd;
  --red: #ff8175;
  font-family: 'DM Sans', sans-serif;
}

* { box-sizing: border-box; }
body {
  min-width: 320px;
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(ellipse at 82% 10%, rgba(15, 83, 94, .12), transparent 38rem),
    radial-gradient(ellipse at 10% 85%, rgba(7, 42, 48, .16), transparent 34rem),
    var(--sea);
}
.ambient-bubbles { z-index: 0; position: fixed; inset: 0; overflow: hidden; pointer-events: none; }
.ambient-bubbles i { position: absolute; bottom: -24px; left: var(--bubble-x); width: var(--bubble-size); height: var(--bubble-size); border: 1px solid rgba(115, 214, 223, .42); border-radius: 50%; background: rgba(96, 188, 198, .08); box-shadow: 0 0 8px rgba(67, 170, 182, .14); animation: bubble-rise var(--bubble-duration) linear var(--bubble-delay) infinite; }
@keyframes bubble-rise { to { transform: translateY(-115vh) translateX(18px); opacity: 0; } }
button, input { font: inherit; }
button { color: inherit; }
button { border-radius: 7px; }
button:focus-visible, input:focus-visible { outline: 2px solid var(--cyan); outline-offset: 3px; }
.hidden { display: none !important; }
.shell { position: relative; z-index: 1; max-width: 1320px; padding: 0 32px; margin: auto; }
.topbar { height: 68px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid rgba(147, 189, 195, .13); }
.shell.in-game .topbar { display: none; }
.top-status, .crew-note { display: flex; align-items: center; gap: 9px; color: var(--muted); font-size: 12px; }
.top-status { margin-left: auto; }
.status-dot, .crew-dot { width: 7px; height: 7px; display: inline-block; border-radius: 50%; background: #617881; }
.status-dot.online, .crew-dot { background: var(--cyan); box-shadow: 0 0 10px rgba(54, 191, 208, .55); }

.lobby { position: relative; isolation: isolate; min-height: calc(100vh - 69px); display: grid; grid-template-columns: 152px minmax(0, 1fr) minmax(220px, .7fr); grid-template-rows: 1fr; align-items: center; column-gap: clamp(22px, 4vw, 52px); padding: 26px 0 18px; }
.lobby::before { z-index: -1; position: absolute; inset: 4% -5% 10%; background: radial-gradient(ellipse at 76% 45%, rgba(12, 93, 105, .13), transparent 36%), radial-gradient(ellipse at 24% 85%, rgba(10, 48, 54, .12), transparent 42%); content: ''; pointer-events: none; }
.eyebrow, .field-label, .panel-index, .stat > span, .checkpoint-stat span, .system-label span, .station-owner, .game-footer, .divider, .room-code { font-family: 'DM Mono', monospace; letter-spacing: .1em; }
.eyebrow { margin: 0 0 12px; color: var(--cyan); font-size: 10px; }
.menu-nav { display: flex; flex-direction: column; align-items: stretch; gap: 8px; padding: 22px 18px 22px 0; border-right: 1px solid rgba(81, 132, 140, .22); }
.menu-tab { display: grid; grid-template-columns: 20px 1fr; align-items: center; gap: 12px; width: 100%; padding: 12px 10px; color: var(--muted); border: 1px solid transparent; border-radius: 7px; background: transparent; cursor: pointer; text-align: left; transition: color .18s, background .18s, border-color .18s; }
.menu-tab svg { width: 18px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.menu-tab span { font-size: 12px; font-weight: 600; }
.menu-tab:hover, .menu-tab.active { color: var(--ink); border-color: #1d4048; background: rgba(9, 28, 32, .82); }
.menu-tab.active { box-shadow: inset 2px 0 var(--cyan); }
.menu-tab.active svg { color: var(--cyan); }
.lobby-main { min-width: 0; display: grid; grid-template-columns: minmax(0, 1fr); grid-template-rows: auto auto; align-content: center; gap: clamp(14px, 2.4vh, 22px); }
.lobby-panel { position: relative; min-width: 0; overflow: hidden; padding: 22px; border: 1px solid #1d3940; border-radius: 10px; background: linear-gradient(145deg, rgba(10, 20, 23, .98), rgba(4, 9, 11, .99)); box-shadow: 0 25px 70px rgba(0, 0, 0, .44), inset 0 1px rgba(255,255,255,.025); }
.lobby-panel::before { position: absolute; top: 0; right: 9%; left: 9%; height: 1px; background: linear-gradient(90deg, transparent, var(--cyan), transparent); content: ''; opacity: .65; }
.panel-heading { display: flex; justify-content: space-between; gap: 12px; margin-bottom: 19px; }
.panel-heading .eyebrow { margin: 0; }
.panel-index { color: var(--faint); font-size: 9px; white-space: nowrap; }
.menu-page { min-height: 410px; }
.menu-prompt { margin: 0 0 14px; color: var(--ink); font: 700 14px Manrope, sans-serif; }
.play-mode { padding: 13px; border: 1px solid #1b353b; border-radius: 7px; background: rgba(6, 14, 17, .9); }
.mode-heading { display: flex; align-items: center; gap: 11px; margin-bottom: 13px; }
.mode-heading svg { width: 21px; height: 21px; fill: none; stroke: var(--cyan); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.mode-heading b, .mode-heading small { display: block; }
.mode-heading b { margin-bottom: 3px; font-size: 12px; }
.mode-heading small { color: var(--muted); font-size: 10px; }
.primary-button, .secondary-button, .action-button, .shop-button { display: flex; align-items: center; justify-content: space-between; gap: 12px; border: 0; cursor: pointer; transition: background .18s, transform .18s; }
.primary-button { width: 100%; padding: 12px 13px; color: #031114; border-radius: 5px; background: linear-gradient(135deg, #69d6df, #30b2c4); box-shadow: 0 4px 14px rgba(31, 173, 190, .12); font-size: 12px; font-weight: 800; }
.primary-button:hover, .shop-button:hover { background: #87e4ea; transform: translateY(-1px); }
.primary-button:disabled, .secondary-button:disabled { opacity: .55; cursor: wait; transform: none; }
.room-display { padding: 13px 0 0; }
.field-label { display: block; margin-bottom: 8px; color: var(--muted); font-size: 9px; }
.room-code-row { display: flex; align-items: center; justify-content: space-between; padding: 10px 12px; border: 1px dashed #34616a; background: rgba(5, 16, 19, .8); }
.room-code { color: var(--lime); font-size: 19px; letter-spacing: .18em; }
.copy-button, .quiet-button, .icon-button { padding: 7px; border: 0; color: var(--muted); background: transparent; cursor: pointer; font: 500 9px 'DM Mono', monospace; letter-spacing: .08em; }
.copy-button:hover, .quiet-button:hover, .icon-button:hover { color: var(--cyan); }
.field-hint, .connection-message { color: var(--muted); font-size: 10px; line-height: 1.5; }
.field-hint { margin: 8px 0 0; }
.divider { display: flex; align-items: center; gap: 10px; margin: 13px 0; color: var(--faint); font-size: 8px; white-space: nowrap; }
.divider::before, .divider::after { height: 1px; flex: 1; background: var(--line); content: ''; }
.join-row { display: flex; gap: 8px; }
.join-row input { min-width: 0; flex: 1; padding: 10px; border: 1px solid var(--line); border-radius: 5px; color: var(--ink); background: #050b0d; font: 500 13px 'DM Mono', monospace; letter-spacing: .14em; }
.join-row input::placeholder { color: #4a646a; }
.secondary-button { padding: 10px 13px; color: var(--ink); border: 1px solid #31545b; border-radius: 5px; background: #0d2025; font-size: 11px; font-weight: 600; cursor: pointer; }
.secondary-button:hover { border-color: var(--cyan); background: #102e35; }
.local-mode-options { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 10px; }
.mode-card { min-width: 0; display: grid; grid-template-columns: 25px 1fr 12px; align-items: center; gap: 8px; padding: 11px 9px; color: var(--muted); border: 1px solid #1b353b; border-radius: 6px; background: #080e10; cursor: pointer; text-align: left; transition: border-color .18s, background .18s, color .18s; }
.mode-card:hover { color: var(--ink); border-color: #31727b; background: #0a171a; }
.mode-card > svg { width: 20px; fill: none; stroke: var(--cyan); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.mode-card b, .mode-card small { display: block; }
.mode-card b { color: var(--ink); font-size: 10px; }
.mode-card small { margin-top: 4px; font-size: 9px; line-height: 1.3; }
.mode-arrow { color: var(--cyan); font-size: 13px; }
.info-page h2 { margin: 0 0 14px; color: var(--ink); font: 700 clamp(27px, 3vw, 38px)/1.08 Manrope, sans-serif; letter-spacing: -.045em; }
.info-page h2 span { color: var(--cyan); }
.info-page > p { color: var(--muted); font-size: 11px; line-height: 1.7; }
.info-roles { display: grid; gap: 8px; margin: 20px 0; }
.info-roles > div { display: flex; align-items: center; gap: 11px; padding: 10px; border: 1px solid #1b353b; border-radius: 6px; background: #070e10; }
.info-icon { width: 32px; height: 32px; display: grid; place-items: center; color: var(--cyan); border: 1px solid #24515a; border-radius: 50%; background: #0a1a1e; }
.info-icon svg { width: 18px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.info-roles b, .info-roles small { display: block; }
.info-roles b { margin-bottom: 4px; font-size: 11px; }
.info-roles small { color: var(--muted); font-size: 10px; }
.info-page .info-footnote { padding-top: 10px; border-top: 1px solid var(--line); }
.controls-page { display: grid; align-content: start; gap: 12px; }
.control-card { display: flex; align-items: center; gap: 12px; padding: 13px; border: 1px solid #1d3b42; border-radius: 6px; background: rgba(7, 17, 20, .92); }
.control-icon { width: 36px; height: 36px; flex: 0 0 36px; display: grid; place-items: center; color: var(--cyan); border: 1px solid #25505a; border-radius: 5px; font: 700 9px 'DM Mono', monospace; }
.control-icon svg { width: 21px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; }
.control-card b { color: var(--cyan); font: 700 10px 'DM Mono', monospace; letter-spacing: .1em; }
.control-card p { margin: 6px 0 0; color: #b2c8c8; font-size: 10px; line-height: 1.7; }
.control-card kbd { display: inline-block; margin: 0 2px; padding: 2px 4px; color: var(--ink); border: 1px solid #35535a; border-radius: 3px; background: #0e1a1d; font: 700 9px 'DM Mono', monospace; }
.controls-note { margin: 2px 2px 0; color: var(--muted); font-size: 10px; line-height: 1.6; }
.credits-page h2 { margin: 0 0 13px; font: 700 20px Manrope, sans-serif; }
.credits-page h3, .credits-panel h3 { margin: 15px 0 8px; color: var(--cyan); font: 700 10px 'DM Mono', monospace; letter-spacing: .1em; text-transform: uppercase; }
.credits-developers { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.credit-card { display: grid; gap: 5px; padding: 11px; border: 1px solid #1d3b42; border-radius: 6px; background: #071114; }
.credit-card b { font-size: 12px; }
.credit-card span { color: var(--cyan); font: 8px 'DM Mono', monospace; text-transform: uppercase; }
.credit-card small { color: var(--muted); font-size: 9px; }
.credit-portfolio { width: fit-content; color: var(--cyan); font-size: 10px; text-decoration-color: rgba(54, 191, 208, .5); text-underline-offset: 3px; }
.credit-portfolio:hover { color: var(--ink); }
.credits-tools { display: grid; gap: 5px; margin: 0; padding: 0; list-style: none; }
.credits-tools li { display: flex; justify-content: space-between; gap: 10px; padding: 7px 9px; border: 1px solid rgba(29, 53, 59, .8); background: rgba(5, 12, 14, .7); font-size: 9px; }
.credits-tools li b { color: var(--ink); }
.credits-tools li span { color: var(--muted); text-align: right; }
.connection-message { min-height: 30px; margin: 10px 0 0; color: var(--amber); }
.menu-hero { min-width: 0; display: grid; place-items: center; }
.menu-logo-title { width: min(100%, 380px); margin: 0; line-height: 0; }
.menu-logo-title img { width: 100%; height: auto; display: block; object-fit: contain; filter: drop-shadow(0 8px 26px rgba(34, 178, 193, .12)); animation: menu-logo-float 6s ease-in-out infinite; }
@keyframes menu-logo-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
.menu-scene { position: relative; height: clamp(130px, 18vh, 180px); overflow: hidden; border: 1px solid rgba(48, 114, 123, .38); border-radius: 7px; background: linear-gradient(180deg, #071619, #03090b 82%); box-shadow: inset 0 0 30px rgba(28, 147, 158, .07); }
.menu-scene::before { position: absolute; inset: 0; background: repeating-linear-gradient(0deg, transparent 0 24px, rgba(130, 194, 198, .045) 25px), repeating-linear-gradient(90deg, transparent 0 24px, rgba(130, 194, 198, .045) 25px); content: ''; }
.menu-scene::after { position: absolute; inset: -50%; background: conic-gradient(from 260deg at 63% 50%, transparent 0 30%, rgba(54, 191, 208, .09) 34%, transparent 38% 100%); animation: sonar-sweep 9s linear infinite; content: ''; }
@keyframes sonar-sweep { to { transform: rotate(360deg); } }
.sonar-ring { z-index: 1; position: absolute; top: 50%; left: 63%; aspect-ratio: 1; border: 1px solid rgba(54, 191, 208, .3); border-radius: 50%; transform: translate(-50%, -50%); }
.sonar-ring-one { width: 118px; }
.sonar-ring-two { width: 72px; }
.menu-submarine { z-index: 2; position: absolute; top: calc(50% - 24px); left: 26%; width: 88px; fill: #b5dfe2; stroke: #b5dfe2; stroke-width: 1.2; filter: drop-shadow(0 0 8px rgba(54, 191, 208, .4)); animation: sub-drift 4s ease-in-out infinite; }
.menu-fish { z-index: 2; position: absolute; top: calc(50% - 13px); left: 75%; width: 34px; fill: #72cbd5; stroke: #72cbd5; stroke-width: 1.2; transform: rotate(180deg); animation: fish-drift 3s ease-in-out infinite alternate; }
@keyframes sub-drift { 50% { transform: translate(7px, -4px); } }
@keyframes fish-drift { to { transform: translate(-15px, -5px) rotate(180deg); } }

.game { padding: 14px 0 12px; }
.game-heading { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.game-heading .eyebrow { margin-bottom: 5px; }
.game-heading h2 { margin: 0; font: 700 21px Manrope, sans-serif; letter-spacing: -.03em; }
.game-heading-right { display: flex; align-items: center; gap: 17px; }
.role-badge, .station-owner { padding: 7px 9px; color: var(--cyan); border: 1px solid #28525a; background: #0a1c20; font-size: 9px; }
.quiet-button { font-family: 'DM Sans', sans-serif; font-size: 11px; letter-spacing: 0; }
.voyage-strip { display: grid; grid-template-columns: .8fr .9fr .9fr 2.2fr; align-items: center; gap: 16px; padding: 11px 15px; border: 1px solid var(--line); border-radius: 8px 8px 0 0; background: rgba(6, 14, 16, .94); }
.stat > span, .checkpoint-stat span { display: block; margin-bottom: 7px; color: var(--muted); font-size: 9px; }
.checkpoint-stat .checkpoint-fish-progress { display: inline; margin: 0; color: var(--cyan); font-size: 8px; font-style: normal; letter-spacing: .04em; }
.stat b, .checkpoint-stat b { color: var(--ink); font: 600 19px Manrope, sans-serif; }
.stat b small { color: var(--muted); font: 11px 'DM Mono', monospace; }
.stat b .coin-mark { width: 15px; height: 15px; display: inline-grid; place-items: center; margin-left: 4px; color: var(--cyan); border: 1px solid currentColor; border-radius: 50%; font: 700 8px 'DM Mono', monospace; vertical-align: 2px; }
.checkpoint-stat { display: flex; align-items: center; gap: 18px; }
.checkpoint-stat > div:first-child { min-width: max-content; }
.meter { height: 5px; overflow: hidden; background: #132d32; }
.meter i { width: 100%; height: 100%; display: block; background: var(--cyan); transition: width .3s ease; }
.checkpoint-stat .meter { flex: 1; }
.checkpoint-stat .meter i { background: var(--lime); }
.sub-status { display: grid; grid-template-columns: 58px repeat(3, minmax(90px, 1fr)) minmax(125px, 1.5fr); align-items: center; gap: 18px; padding: 10px 15px; border: solid var(--line); border-width: 0 1px 1px; border-radius: 0 0 8px 8px; background: rgba(5, 12, 14, .94); }
.sub-art { position: relative; width: 48px; height: 35px; display: grid; place-items: center; }
.sub-art img { max-width: 100%; max-height: 100%; object-fit: contain; }
.sub-fallback { display: grid; width: 48px; place-items: center; }
.sub-fallback svg { width: 48px; fill: none; stroke: #75c4cc; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.system-label { display: flex; justify-content: space-between; margin-bottom: 6px; }
.system-label span { color: var(--muted); font-size: 8px; }
.system-label b { font: 500 10px 'DM Mono', monospace; }
.system-meter .meter i { background: var(--lime); }
.system-meter.danger .meter i { background: var(--red); }
.water-meter i { background: #4aaec0 !important; }
.status-note { color: var(--muted); text-align: right; font-size: 10px; }
.stations { display: grid; grid-template-columns: 1fr 1fr; gap: 11px; margin-top: 11px; }
.game.online-fisher .stations, .game.online-engineer .stations { grid-template-columns: minmax(0, 1fr); }
.game.online-fisher .engineer-station, .game.online-engineer .fisher-station { display: none; }
.station { min-width: 0; padding: 13px; border: 1px solid var(--line); border-radius: 8px; background: linear-gradient(155deg, rgba(11, 23, 26, .98), rgba(5, 11, 13, .99)); box-shadow: 0 12px 34px rgba(0, 0, 0, .26); }
.fisher-station { position: relative; }
.station-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.station-title { display: flex; align-items: center; gap: 10px; }
.station-icon { width: 34px; height: 34px; display: grid; place-items: center; color: var(--cyan); border: 1px solid #204b52; border-radius: 50%; background: #081719; }
.station-icon svg { width: 19px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.engineer-station .station-icon { color: #a6d9df; }
.station-title .eyebrow { margin: 0 0 3px; font-size: 8px; }
.station-title h3 { margin: 0; font: 700 15px Manrope, sans-serif; }
.station-owner { color: var(--muted); border-color: #203b41; background: #081316; }
.ocean-scene { position: relative; min-height: 171px; display: flex; align-items: flex-end; overflow: hidden; padding: 16px; border: 1px solid #20434a; border-radius: 6px; background: linear-gradient(180deg, #0b2327 0%, #08181c 48%, #050e11 100%); }
.ocean-scene::before, .ocean-scene::after { position: absolute; inset: 0; pointer-events: none; content: ''; }
.ocean-scene::before { opacity: .42; background: repeating-linear-gradient(175deg, transparent 0 35px, rgba(127, 218, 223, .09) 36px 37px, transparent 38px 66px); animation: current 12s linear infinite; }
.ocean-scene::after { background: linear-gradient(90deg, rgba(2, 8, 10, .28), transparent 72%); }
@keyframes current { to { background-position: 0 100px; } }
.ocean-scene img { position: absolute; z-index: 1; top: 20px; right: 12%; width: min(45%, 185px); height: 105px; object-fit: contain; }
.ocean-silhouette { position: absolute; top: 19px; right: 19%; width: 62px; height: 30px; display: grid; place-items: center; color: #88ccca; opacity: .22; font-size: 56px; transform: rotate(-15deg); }
.ocean-copy { z-index: 2; position: relative; max-width: 85%; }
.ocean-copy .eyebrow { margin-bottom: 6px; color: var(--lime); font-size: 8px; }
.ocean-copy h4 { margin: 0 0 4px; font: 600 17px Manrope, sans-serif; }
.ocean-copy p { margin: 0; color: #b0c5c6; font-size: 11px; }
.fishing-controls { min-height: 76px; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.fisher-activity { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 7px 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.activity-meter > div:first-child { display: flex; justify-content: space-between; margin-bottom: 6px; color: var(--muted); font: 8px 'DM Mono', monospace; letter-spacing: .08em; }
.activity-meter b { color: #a4c9cc; font-weight: 500; }
.activity-meter .meter { height: 6px; border: 1px solid #28515a; background: #091518; }
.activity-meter .meter i { width: 0; background: var(--lime); transition: width .3s ease, background .3s ease; }
.activity-meter .meter i.danger-fill { background: var(--red); }
.activity-status { grid-column: 1; color: var(--muted); font-size: 9px; }
.fisher-activity-button { grid-column: 2; grid-row: 1 / span 2; min-width: 138px; }
.fisher-activity-button:disabled { color: #8ba3a6; background: #203d4a; cursor: not-allowed; }
.challenge-copy b, .challenge-copy span { display: block; }
.challenge-copy b { margin-bottom: 4px; font-size: 11px; }
.challenge-copy span { max-width: 235px; color: var(--muted); font-size: 10px; line-height: 1.4; }
.challenge-actions { display: flex; align-items: center; gap: 5px; }
.challenge-actions .progress-track { min-width: 90px; }
.action-button { min-width: 120px; justify-content: center; padding: 10px 12px; color: #031114; background: var(--cyan); font-size: 10px; font-weight: 700; }
.action-button:disabled { color: #8ba3a6; background: #203d4a; cursor: not-allowed; }
.action-button:hover:not(:disabled) { background: #a4f6e5; }
.rhythm-keys { display: flex; gap: 4px; }
.rhythm-key { width: 31px; height: 35px; display: grid; place-items: center; color: #d3e6e5; border: 1px solid #35555c; border-radius: 4px; background: linear-gradient(145deg, #10282d, #0a171a); cursor: pointer; font-size: 17px; font-weight: 800; box-shadow: 0 2px 6px #020708; }
.rhythm-key.hit { color: #13332f; border-color: var(--lime); background: var(--lime); }
.rhythm-key.next { color: #072a30; border-color: var(--cyan); background: var(--cyan); animation: rhythm-pulse .7s ease-in-out infinite alternate; }
@keyframes rhythm-pulse { to { box-shadow: 0 0 13px rgba(108, 225, 212, .75); transform: translateY(-2px); } }
.aim-target, .aim-dot { z-index: 4; position: absolute; pointer-events: none; transform: translate(-50%, -50%); }
.aim-target { width: 64px; height: 64px; border: 2px solid var(--lime); border-radius: 50%; box-shadow: 0 0 14px rgba(196, 237, 240, .35), inset 0 0 10px rgba(196, 237, 240, .16); transition: left .85s ease-in-out, top .85s ease-in-out; }
.aim-target::before, .aim-target::after { position: absolute; background: var(--lime); content: ''; }
.aim-target::before { top: 50%; left: -7px; width: 74px; height: 1px; }
.aim-target::after { top: -7px; left: 50%; width: 1px; height: 74px; }
.aim-dot { width: 11px; height: 11px; border: 2px solid #fff; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 12px var(--cyan); transition: left .08s ease-out, top .08s ease-out; }
.smoke-active .ocean-scene::after { background: linear-gradient(90deg, rgba(18, 30, 34, .6), rgba(96, 95, 78, .23)); }
.station-inactive { border-color: rgba(36, 68, 84, .75); }
.upgrade-summary { display: flex; justify-content: space-between; gap: 8px; padding-top: 12px; color: var(--ink); font-size: 10px; }
.upgrade-summary span { color: var(--muted); font-size: 9px; text-align: right; }
.engineer-board { display: grid; grid-template-columns: minmax(0, .95fr) minmax(0, 1.05fr); align-items: start; gap: 9px; }
.mission-list { min-height: 186px; border: 1px solid #1b353b; border-radius: 6px; background: rgba(4, 10, 12, .72); }
.mission-list-heading { padding: 8px 10px; color: var(--cyan); border-bottom: 1px solid rgba(43, 76, 91, .7); font: 500 9px 'DM Mono', monospace; letter-spacing: .1em; }
.mission-empty { display: grid; min-height: 185px; place-content: center; gap: 6px; padding: 15px; color: var(--muted); text-align: center; font-size: 11px; }
.mission-empty b { color: var(--lime); font-size: 12px; }
.mission-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 10px; border-bottom: 1px solid rgba(43, 76, 91, .7); }
.mission-row.selected { background: rgba(83, 163, 159, .12); }
.mission-row:last-child { border-bottom: 0; }
.mission-details { min-width: 0; flex: 1; }
.mission-details b, .mission-details span { display: block; }
.mission-details b { font-size: 10px; }
.mission-details span { margin-top: 4px; color: var(--muted); font-size: 9px; }
.mission-details .mission-room { margin: 0 0 4px; color: var(--amber); font: 8px 'DM Mono', monospace; text-transform: uppercase; }
.mission-row .action-button { min-width: 60px; padding: 8px; font-size: 9px; }
.mission-row .action-button:disabled { display: none; }
.mission-row .danger-label { color: var(--red); font: 8px 'DM Mono', monospace; }
.mission-timer { display: flex; align-items: center; justify-content: center; flex: 0 0 auto; color: var(--cyan); font: 700 16px/1 'DM Mono', monospace; font-variant-numeric: tabular-nums; white-space: nowrap; }
.mission-timer.urgent { color: var(--red); text-shadow: 0 0 10px rgba(255, 129, 117, .42); }
.repair-timer { min-width: 54px; min-height: 36px; padding: 4px 7px; border: 1px solid rgba(54, 191, 208, .4); border-radius: 5px; background: rgba(7, 26, 30, .8); font-size: 22px; }
.repair-timer.urgent { border-color: rgba(255, 129, 117, .55); }
.repair-panel { min-height: 186px; padding: 10px; border: 1px solid #28515a; border-radius: 6px; background: linear-gradient(145deg, #0b1c20, #071114); }
.repair-heading { display: flex; align-items: center; justify-content: space-between; }
.repair-heading .eyebrow { margin: 0 0 3px; font-size: 8px; }
.repair-heading h4 { margin: 0; font: 600 13px Manrope, sans-serif; }
.icon-button { font-size: 19px; line-height: 1; }
.repair-instructions { margin: 8px 0; color: #9eb4b9; font-size: 10px; line-height: 1.45; }
.repair-challenge { min-height: 105px; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 7px; }
.repair-standby { min-height: 92px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; color: var(--muted); text-align: center; font-size: 10px; }
.repair-standby b { color: var(--ink); font-size: 11px; }
.repair-standby-icon { width: 27px; height: 27px; display: grid; place-items: center; color: var(--lime); border: 1px solid #47777b; border-radius: 50%; background: #153b43; font-size: 14px; }
.mini-button { min-width: 34px; min-height: 33px; padding: 7px; color: var(--ink); border: 1px solid #2a4b51; background: #0d2024; cursor: pointer; font-size: 11px; }
.mini-button:hover { border-color: var(--cyan); }
.mini-button.done { color: #102b30; border-color: var(--lime); background: var(--lime); }
.mini-button.target { color: #102b30; border-color: var(--amber); background: var(--amber); }
.progress-track { width: 100%; height: 7px; margin-top: 4px; overflow: hidden; background: #1b3d4d; }
.progress-track i { height: 100%; display: block; background: var(--lime); transition: width .15s; }
.alignment-console { display: flex; align-items: center; justify-content: center; gap: 18px; width: 100%; }
.alignment-button { width: 46px; height: 44px; display: grid; place-items: center; color: var(--ink); border: 1px solid #37656d; background: linear-gradient(145deg, #113139, #0a1d21); cursor: pointer; font-size: 26px; font-weight: 700; box-shadow: inset 0 1px rgba(255,255,255,.07), 0 4px 12px #020708; }
.alignment-button:hover { border-color: var(--lime); color: var(--lime); }
.alignment-dial { position: relative; width: 164px; height: 92px; display: grid; place-items: center; overflow: hidden; border: 1px solid #527583; border-radius: 100px 100px 14px 14px; background: repeating-conic-gradient(from 270deg at 50% 100%, #41616a 0 1deg, transparent 1deg 15deg), radial-gradient(ellipse at 50% 100%, #214353 0 54%, #0b2535 56%); }
.alignment-dial::after { position: absolute; top: 12px; left: calc(50% - 1px); width: 2px; height: 15px; background: var(--lime); box-shadow: 0 0 8px var(--lime); content: ''; }
.alignment-sub { z-index: 1; width: 92px; height: 40px; margin-top: 17px; transition: transform .24s cubic-bezier(.2,.8,.2,1); }
.alignment-sub svg { width: 100%; height: 100%; overflow: visible; fill: #b7dad5; stroke: #b7dad5; stroke-width: 1.5; filter: drop-shadow(0 3px 4px #04131b); }
.alignment-sub svg circle { fill: #183c48; stroke: #a7d8d1; }
.alignment-level { position: absolute; bottom: 5px; color: var(--lime); font: 8px 'DM Mono', monospace; letter-spacing: .12em; }
.alignment-reading { position: absolute; top: 8px; right: 12px; color: var(--amber); font: 9px 'DM Mono', monospace; }
.weld-track { position: relative; width: 100%; height: 115px; overflow: hidden; touch-action: none; border: 1px solid #28515a; border-radius: 6px; background: radial-gradient(ellipse at center, #10272b, #071316); cursor: crosshair; }
.weld-track svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.weld-track polyline { fill: none; stroke: #71d5df; stroke-width: 8; stroke-linecap: round; stroke-linejoin: round; opacity: .8; filter: drop-shadow(0 0 5px #2c9eac); }
.weld-track::after { position: absolute; right: 0; bottom: 0; left: 0; height: 24px; background: linear-gradient(transparent, rgba(3, 17, 26, .8)); content: ''; pointer-events: none; }
.weld-label { z-index: 1; position: absolute; bottom: 5px; color: var(--lime); font: 8px 'DM Mono', monospace; pointer-events: none; }
.weld-start { left: 7px; }
.weld-finish { right: 7px; }
.weld-dot { z-index: 2; position: absolute; top: 50%; left: 0; width: 17px; height: 17px; border: 2px solid #e8fffb; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 14px 4px rgba(54, 191, 208, .45); pointer-events: none; transform: translate(-50%, -50%); }
.bolt-field { position: relative; width: 100%; height: 145px; overflow: hidden; border: 1px solid #28515a; border-radius: 6px; background: repeating-linear-gradient(0deg, transparent 0 27px, rgba(104, 175, 181, .07) 28px 29px), repeating-linear-gradient(90deg, transparent 0 27px, rgba(104, 175, 181, .07) 28px 29px), linear-gradient(145deg, #0b1c20, #050d0f); }
.bolt-button { position: absolute; min-width: 37px; min-height: 37px; padding: 4px; color: #a4dce1; border: 1px solid #4d8991; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #40545a, #15282c 70%); box-shadow: 0 3px 8px #020708; font-size: 22px; transform: translate(-50%, -50%); }
.bolt-screw { display: block; line-height: 18px; transition: transform .18s ease-out; }
.bolt-turn-count { position: absolute; right: -5px; bottom: -5px; min-width: 18px; padding: 2px; color: var(--ink); border: 1px solid #406970; border-radius: 8px; background: #071417; font: 7px 'DM Mono', monospace; }
.bolt-button:hover:not(:disabled) { border-color: var(--lime); color: var(--lime); transform: translate(-50%, -50%) scale(1.12); }
.bolt-button.done { color: #d3f8fa; border-color: #53b3bd; background: #12363b; box-shadow: inset 0 0 8px #091a1d; }
.pump-rig { width: min(100%, 290px); display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 10px 12px; padding: 14px; border: 1px solid #28515a; border-radius: 6px; background: linear-gradient(145deg, #0c1e22, #061114); }
.pump-gauge { position: relative; height: 20px; overflow: hidden; border: 1px solid #526b73; border-radius: 10px; background: linear-gradient(90deg, #a9524b 0 55%, #c39b54 55% 78%, #79b983 78%); }
.pump-gauge::after { position: absolute; inset: 0; background: repeating-linear-gradient(90deg, transparent 0 9%, rgba(3, 17, 26, .7) 9.5% 10%); content: ''; }
.pump-gauge i { position: absolute; inset: 0 auto 0 0; width: 0; background: rgba(54, 191, 208, .5); transition: width .2s; }
.pump-reading { color: var(--muted); font: 9px 'DM Mono', monospace; }
.pump-button { min-width: 122px; min-height: 43px; grid-row: span 2; color: #031114; border: 1px solid #7ad8df; background: linear-gradient(145deg, #72dce3, #34aebe); font-weight: 800; box-shadow: 0 4px 0 #1b6570; }
.pump-button:active { transform: translateY(3px); box-shadow: 0 1px 0 #1b6570; }
.bottom-bar { min-height: 45px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.crew-note { font-size: 10px; }
.network-note { color: var(--faint); font: 9px 'DM Mono', monospace; }
.shop-button { padding: 11px 14px; color: #07262b; background: var(--lime); font-size: 10px; font-weight: 700; }
.shop-panel { padding: 17px; border: 1px solid #28515a; background: linear-gradient(135deg, #0c1b1f, #060e10); }
.fish-log-panel { margin-top: 8px; padding: 17px; border: 1px solid #28515a; background: linear-gradient(135deg, #0c1b1f, #060e10); }
.fish-log-panel > p { color: var(--muted); font-size: 10px; }
.collection-button { padding: 9px 11px; color: #b9dfe1; border: 1px solid #31545b; background: #0a1a1e; cursor: pointer; font-size: 9px; }
.collection-button:hover { border-color: var(--cyan); color: var(--cyan); }
.fish-collection { max-height: 280px; display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 6px; overflow-y: auto; }
.collection-entry { min-width: 0; display: flex; align-items: center; gap: 9px; padding: 6px; border: 1px solid #1b353b; background: #071114; opacity: .62; }
.collection-entry.discovered { border-color: #2b5961; opacity: 1; }
.collection-art { width: 43px; height: 30px; flex: 0 0 43px; }
.collection-art svg { width: 100%; height: 100%; }
.collection-details { min-width: 0; }
.collection-details b, .collection-details small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.collection-details b { font-size: 9px; }
.collection-details small { margin-top: 3px; color: var(--muted); font-size: 8px; }
.shop-heading { display: flex; justify-content: space-between; align-items: center; }
.shop-heading .eyebrow { margin-bottom: 4px; }
.shop-heading h3 { margin: 0; font: 600 19px Manrope, sans-serif; }
.shop-panel > p { color: var(--muted); font-size: 11px; }
.shop-actions { display: flex; align-items: flex-start; gap: 14px; }
.upgrade-list { display: flex; flex-wrap: wrap; gap: 7px; }
.upgrade-card { min-width: 145px; padding: 9px; border: 1px solid var(--line); background: #081316; }
.upgrade-card b, .upgrade-card small { display: block; }
.upgrade-card b { margin-bottom: 4px; font-size: 10px; }
.upgrade-card small { margin-bottom: 7px; color: var(--muted); font-size: 9px; }
.upgrade-card button { width: 100%; padding: 6px; color: #0a282d; border: 0; background: var(--cyan); cursor: pointer; font-size: 9px; font-weight: 700; }
.upgrade-card button:disabled { color: #91a6aa; background: #24414c; cursor: not-allowed; }
.game-over { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin: 8px 0; padding: 15px 18px; border: 1px solid #86564f; background: linear-gradient(110deg, #231719, #101719); }
.game-over .eyebrow { margin-bottom: 5px; color: var(--red); }
.game-over b, .game-over span { display: block; }
.game-over b { font: 600 14px Manrope, sans-serif; }
.game-over span { margin-top: 4px; color: #b7c5c6; font-size: 10px; }
.sequence-preview { width: 100%; display: flex; align-items: center; justify-content: center; gap: 6px; color: var(--amber); text-align: center; font: 500 12px 'DM Mono', monospace; letter-spacing: .14em; }
.sequence-preview span { min-width: 24px; padding: 3px 5px; border: 1px solid #415d67; border-radius: 5px; background: #102d3c; animation: sequence-light .42s ease-in-out both; }
@keyframes sequence-light { 0%, 100% { color: var(--muted); border-color: #415d67; background: #102d3c; box-shadow: none; } 45% { color: #092d32; border-color: var(--lime); background: var(--lime); box-shadow: 0 0 14px rgba(211, 239, 155, .8); } }
.sequence-preview.concealed { color: var(--faint); filter: blur(5px); }
.sequence-grid { display: grid; grid-template-columns: repeat(3, 32px); gap: 4px; }
.arrow-grid { grid-template-columns: repeat(4, 48px); gap: 7px; }
.arrow-grid .mini-button { min-height: 48px; color: #e5f7f5; border-color: #5b8594; border-radius: 8px; background: linear-gradient(145deg, #20546a, #12384d); font-size: 22px; font-weight: 800; box-shadow: 0 3px 8px #04151c; }
.arrow-grid .mini-button:hover { color: var(--lime); border-color: var(--lime); }
.direction-arrow { width: 24px; height: 24px; display: block; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.rhythm-key .direction-arrow, .arrow-grid .direction-arrow { width: 21px; height: 21px; }
.sequence-preview .direction-arrow { width: 18px; height: 18px; stroke-width: 2; }
.mini-button.active { color: #092d32; border-color: var(--lime); background: var(--lime); box-shadow: 0 0 14px rgba(211, 239, 155, .35); }
.compass-mark { min-width: 28px; color: var(--amber); text-align: center; font-size: 18px; }
.valve-button, .pump-button { min-width: 120px; }
.valve-button { width: 130px; min-height: 70px; display: grid; grid-template-columns: 1fr; justify-items: center; gap: 4px; padding: 6px; color: var(--ink); border-color: #376a72; border-radius: 6px; background: linear-gradient(145deg, #17363b, #0c2024); font-size: 10px; font-weight: 700; }
.valve-wheel { width: 40px; height: 40px; display: grid; place-items: center; color: #a8e7eb; border: 2px solid #55959d; border-radius: 50%; background: radial-gradient(circle, #1a3b40 38%, #315c62 41% 47%, #122a2e 50%); transform-origin: center; transition: transform .18s ease-out; }
.valve-wheel svg { width: 30px; height: 30px; display: block; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; }
.valve-button:hover { border-color: var(--amber); }
.repair-progress { width: 100%; }
.repair-progress i { background: var(--amber); }
.weld-track { cursor: crosshair; }
.game-footer { display: none; }
.toast { z-index: 10; position: fixed; right: 20px; bottom: 20px; max-width: 360px; padding: 12px 16px; color: var(--ink); border: 1px solid #47737c; background: #113342; box-shadow: 0 12px 35px #06131c99; font-size: 12px; opacity: 0; pointer-events: none; transform: translateY(8px); transition: .2s ease; }
.toast.visible { opacity: 1; transform: translateY(0); }
.toast.warning { border-color: #95635a; }
.keyboard-hint { color: var(--faint); font: 9px 'DM Mono', monospace; }
.fishing-meta { min-height: 27px; display: flex; align-items: center; justify-content: space-between; gap: 8px; padding-top: 6px; }
.fish-timer { z-index: 2; position: absolute; top: 10px; left: 12px; width: 54px; height: 58px; flex-direction: column; gap: 1px; border: 1px solid rgba(54, 191, 208, .62); border-radius: 7px; background: rgba(3, 17, 21, .86); box-shadow: 0 0 14px rgba(21, 131, 146, .2); }
.fish-timer span { font-size: 26px; }
.fish-timer small { color: var(--muted); font: 7px 'DM Mono', monospace; letter-spacing: .12em; }
.fish-timer.urgent { color: var(--red); border-color: rgba(255, 129, 117, .7); animation: timer-pulse .65s ease-in-out infinite alternate; }
@keyframes timer-pulse { to { box-shadow: 0 0 15px rgba(255, 129, 117, .45); } }
.bait-count { min-height: 25px; display: inline-flex; align-items: center; padding: 0 9px; color: #b9f4f4; border: 1px solid #28616a; border-radius: 4px; background: #0b252a; font: 700 9px 'DM Mono', monospace; letter-spacing: .06em; white-space: nowrap; }
.bait-count.low { color: var(--amber); border-color: #765d35; background: #2a2114; }
.bait-count.empty { color: #ff9789; border-color: #75463f; background: #291816; }
.harpoon-warning { color: #ff8b7b; font: 700 8px 'DM Mono', monospace; letter-spacing: .06em; }
.swimming-fish { z-index: 3; position: absolute; inset: 0; pointer-events: none; }
.fish-swimmer { position: absolute; width: 58px; height: 38px; display: grid; place-items: center; padding: 3px; border: 0; background: transparent; cursor: pointer; pointer-events: auto; transform: translate(-50%, -50%); animation: swim-bob 1.8s ease-in-out infinite alternate; transition: left .9s linear, top .9s ease; }
.fish-swimmer:disabled { opacity: 1; cursor: default; }
.fish-swimmer svg { width: 100%; height: 100%; overflow: visible; filter: drop-shadow(0 2px 6px #051013); transition: transform .18s ease; }
.fish-swimmer:hover svg { transform: scale(1.25); }
.fish-swimmer.swimming-left svg { transform: scaleX(-1); }
.fish-swimmer.swimming-left:hover svg { transform: scaleX(-1) scale(1.25); }
@keyframes swim-bob { to { margin-top: -6px; } }
.shoal-cursor { z-index: 4; position: absolute; width: 23px; height: 23px; border: 2px solid #fff; border-radius: 50%; background: rgba(57, 214, 224, .28); box-shadow: 0 0 13px #51e4e9; pointer-events: none; transform: translate(-50%, -50%); transition: left .1s ease-out, top .1s ease-out; }
.shoal-cursor span { position: absolute; inset: 5px; border-radius: 50%; background: #e6ffff; }
.mission-row.critical { border-left: 2px solid var(--red); background: rgba(153, 55, 49, .15); }
.mission-row.critical .danger-label { white-space: nowrap; }
.barnacle-field { position: relative; width: 100%; height: 155px; overflow: hidden; border: 1px solid #28515a; border-radius: 6px; background: radial-gradient(ellipse at 48% 45%, #10333a, #071316 74%); }
.barnacle-cleanup-overlay { z-index: 8; position: absolute; inset: 56px 8px 8px; display: flex; flex-direction: column; gap: 8px; padding: 14px; border: 1px solid #4d8991; border-radius: 7px; background: rgba(3, 12, 15, .97); box-shadow: 0 12px 34px #000b; }
.barnacle-cleanup-overlay > header { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.barnacle-cleanup-overlay .eyebrow { margin: 0 0 4px; color: var(--cyan); font-size: 8px; }
.barnacle-cleanup-overlay h4 { margin: 0; font: 700 16px Manrope, sans-serif; }
.barnacle-cleanup-progress { color: var(--amber); font: 500 9px 'DM Mono', monospace; text-align: right; }
.barnacle-cleanup-overlay > p { margin: 0; color: var(--muted); font-size: 10px; }
.cleanup-field { min-height: 170px; height: clamp(170px, 30vh, 235px); flex: 1 1 auto; }
.barnacle-hull { position: absolute; inset: 13% 8%; border: 2px solid #527780; border-radius: 47% 47% 38% 38%; background: repeating-linear-gradient(165deg, transparent 0 17px, rgba(142, 194, 193, .1) 18px 19px, transparent 20px 31px), linear-gradient(160deg, #274b50, #10282e 60%, #08171a); box-shadow: inset 0 0 25px #061216, 0 5px 15px #020708; transform: perspective(180px) rotateX(7deg); }
.scraper-arm { z-index: 2; position: absolute; top: 84%; left: 10%; width: 65%; height: 6px; border: 1px solid #b0e6e5; border-radius: 6px; background: linear-gradient(#acd9d7, #477e83); box-shadow: 0 0 8px #2b919c; transform-origin: left center; transition: transform .3s ease; }
.arm-claw { position: absolute; top: -5px; right: -9px; width: 13px; height: 13px; border: 2px solid #b8ece9; border-radius: 3px 3px 8px 8px; background: #28555a; }
.scraper-label { z-index: 1; position: absolute; bottom: 4px; left: 8px; color: #80b4bb; font: 7px 'DM Mono', monospace; letter-spacing: .12em; }
.barnacle-target { z-index: 3; position: absolute; width: 29px; height: 29px; min-width: 0; min-height: 0; display: grid; place-items: center; padding: 4px; border-color: #927d54; border-radius: 50%; background: radial-gradient(circle, #6d624a, #302f2a); box-shadow: 0 2px 6px #020708; transform: translate(-50%, -50%); }
.barnacle-target svg { width: 100%; height: 100%; fill: #b6a477; stroke: #594f3b; stroke-width: 2; }
.barnacle-target:hover:not(:disabled) { border-color: var(--lime); transform: translate(-50%, -50%) scale(1.18); }
.barnacle-target.scraped { opacity: .14; filter: grayscale(1); }
.bait-restock { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 12px 0; padding: 10px; border: 1px solid #23454d; background: #081619; }
.bait-restock b, .bait-restock small { display: block; }
.bait-restock b { font-size: 10px; }
.bait-restock small { margin-top: 4px; color: var(--muted); font-size: 9px; }
.bait-restock .secondary-button { min-width: 160px; padding: 9px 11px; color: #09262b; background: var(--cyan); font-size: 9px; font-weight: 700; }
.bait-restock .secondary-button:disabled { color: #91a6aa; background: #24414c; cursor: not-allowed; }
.crew-comms { margin-top: 8px; padding: 8px 10px; border: 1px solid rgba(29, 53, 59, .75); border-radius: 6px; background: rgba(5, 12, 14, .76); }
.chat-feed { min-height: 19px; max-height: 74px; display: flex; flex-direction: column; gap: 3px; overflow: auto; }
.chat-message { margin: 0; color: #b6dadd; font-size: 9px; line-height: 1.3; }
.chat-message:last-child { color: var(--cyan); }
.quick-chat { display: flex; align-items: center; justify-content: flex-start; flex-wrap: wrap; gap: 5px; min-height: 35px; }
.quick-chat > span { margin-right: 3px; color: var(--faint); font: 8px 'DM Mono', monospace; }
.quick-chat button { padding: 6px 8px; color: #bdd9d9; border: 1px solid #25434a; border-radius: 3px; background: #091619; cursor: pointer; font-size: 8px; }
.quick-chat button:hover { color: var(--cyan); border-color: var(--cyan); }
.sequence-preview { user-select: none; }
.sequence-preview.concealed { color: var(--faint); filter: none; opacity: .48; }
.role-overlay { z-index: 21; position: fixed; inset: 0; display: grid; place-items: center; padding: 22px; background: rgba(1, 7, 9, .9); backdrop-filter: blur(7px); }
.role-panel { width: min(590px, 100%); padding: clamp(22px, 5vw, 36px); border: 1px solid #28515a; background: linear-gradient(145deg, #0c2025, #050c0f); box-shadow: 0 28px 90px #000b; }
.role-panel h2 { margin: 0 0 9px; font: 600 clamp(22px, 4vw, 30px) Manrope, sans-serif; }
.role-panel > p:not(.eyebrow) { margin: 0 0 23px; color: #b2c7ca; font-size: 12px; line-height: 1.6; }
.role-options { display: grid; gap: 10px; }
.role-card { width: 100%; display: grid; grid-template-columns: 35px minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 14px; color: var(--ink); border: 1px solid #25454c; border-radius: 5px; background: #081316; cursor: pointer; text-align: left; transition: background .18s, border-color .18s, opacity .18s; }
.role-card:hover:not(:disabled), .role-card.selected { border-color: var(--cyan); background: #0c252b; }
.role-card:disabled { opacity: .45; cursor: not-allowed; }
.role-card-icon { width: 34px; height: 34px; display: grid; place-items: center; color: var(--cyan); border: 1px solid #28515a; border-radius: 50%; }
.role-card-icon svg { width: 20px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.role-card b, .role-card small { display: block; }
.role-card b { font: 700 11px 'DM Mono', monospace; letter-spacing: .1em; }
.role-card small { margin-top: 5px; color: var(--muted); font-size: 10px; }
.role-card-key { color: #71939a; font: 8px 'DM Mono', monospace; letter-spacing: .06em; white-space: nowrap; }
.role-footer { min-height: 33px; display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 17px; }
.role-footer > span { color: var(--cyan); font-size: 10px; line-height: 1.5; }
.story-overlay { z-index: 20; position: fixed; inset: 0; display: grid; place-items: center; padding: 24px; background: rgba(1, 7, 9, .88); backdrop-filter: blur(7px); }
.story-panel { width: min(760px, 100%); display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); overflow: hidden; border: 1px solid #28515a; background: linear-gradient(145deg, #0c2025, #050c0f); box-shadow: 0 28px 90px #000b; }
.story-art { position: relative; min-height: 300px; display: grid; place-items: center; overflow: hidden; background: radial-gradient(ellipse at 50% 55%, #114451, #07171d 58%, #03090b); }
.story-art::before { position: absolute; inset: 0; background: linear-gradient(180deg, transparent 55%, rgba(3, 10, 13, .8)); content: ''; }
.story-art svg { z-index: 1; width: 75%; fill: #a7d8d6; stroke: #a7d8d6; stroke-width: 2; filter: drop-shadow(0 8px 12px #020708); animation: story-drift 4s ease-in-out infinite alternate; }
.story-sonar { position: absolute; width: 210px; height: 210px; border: 1px solid rgba(89, 205, 215, .35); border-radius: 50%; box-shadow: 0 0 0 24px rgba(89, 205, 215, .06), 0 0 0 50px rgba(89, 205, 215, .04); }
.sonar-two { width: 120px; height: 120px; }
.story-depth { z-index: 1; position: absolute; bottom: 18px; color: #7aa4ac; font: 8px 'DM Mono', monospace; letter-spacing: .15em; }
.story-art[data-stage="descent"] { background: radial-gradient(ellipse at 50% 70%, #163b53, #091522 58%, #03090b); }
.story-art[data-stage="descent"] svg { transform: translateY(28px) scale(.8); }
.story-art[data-stage="legacy"] { background: radial-gradient(ellipse at 50% 55%, #14515a, #07171d 58%, #03090b); }
.story-art[data-stage="legacy"] .sonar-one { animation: sonar-pulse 2.8s ease-out infinite; }
.story-copy { padding: 34px; align-self: center; }
.story-copy .eyebrow { color: var(--cyan); font: 9px 'DM Mono', monospace; letter-spacing: .1em; }
.story-copy h2 { margin: 16px 0 10px; font: 600 clamp(22px, 3vw, 30px) Manrope, sans-serif; }
.story-copy p { margin: 0 0 24px; color: #b2c7ca; font-size: 12px; line-height: 1.8; }
.story-copy .primary-button { width: 100%; padding: 13px 15px; color: #06272b; background: var(--cyan); font-size: 11px; font-weight: 800; }
@keyframes story-drift { to { transform: translateY(-8px); } }
@keyframes sonar-pulse { 50% { transform: scale(1.2); opacity: .45; } }

@media (max-width: 850px) {
  .shell { padding: 0 22px; }
  .lobby { grid-template-columns: 124px minmax(0, 1fr) minmax(150px, .55fr); column-gap: 18px; }
  .menu-nav { padding-right: 12px; }
  .lobby-main { gap: 14px; }
  .lobby-panel { padding: 16px; }
  .menu-logo-title { width: min(100%, 250px); }
  .menu-tab { gap: 8px; padding: 10px 7px; }
  .sub-status { grid-template-columns: 48px repeat(3, 1fr); }
  .status-note { grid-column: 2 / -1; text-align: left; }
  .stations { gap: 10px; }
  .station { padding: 11px; }
  .engineer-board { grid-template-columns: 1fr; }
}
@media (max-width: 1100px) {
  .engineer-board { grid-template-columns: 1fr; }
}
@media (max-width: 650px) {
  .shell { padding: 0 15px; }
  .topbar { height: 60px; }
  .top-status { font-size: 10px; }
  .lobby { min-height: auto; grid-template-columns: 1fr; grid-template-rows: auto auto auto; gap: 15px; padding: 18px 0 16px; }
  .menu-nav { grid-column: 1; grid-row: 1; flex-direction: row; align-items: center; gap: 5px; padding: 0 0 10px; border-right: 0; border-bottom: 1px solid rgba(81, 132, 140, .22); }
  .menu-tab { grid-template-columns: 17px 1fr; gap: 6px; justify-content: center; padding: 9px 5px; }
  .menu-tab svg { width: 16px; }
  .menu-tab span { font-size: 10px; }
  .lobby-main { grid-column: 1; grid-row: 2; grid-template-columns: 1fr; gap: 14px; }
  .menu-hero { grid-column: 1; grid-row: 3; justify-items: end; min-height: 76px; }
  .menu-logo-title { width: min(100%, 160px); }
  .menu-scene { height: 112px; }
  .lobby-panel { padding: 17px; }
  .menu-page { min-height: 0; }
  .game { padding-top: 10px; }
  .game-heading h2 { font-size: 22px; }
  .game-heading-right { gap: 7px; }
  .game-heading-right .quiet-button { font-size: 10px; }
  .voyage-strip { grid-template-columns: repeat(3, 1fr); gap: 12px; padding: 12px; }
  .checkpoint-stat { grid-column: 1 / -1; }
  .sub-status { grid-template-columns: repeat(3, 1fr); gap: 12px; padding: 12px; }
  .sub-art { display: none; }
  .status-note { grid-column: 1 / -1; }
  .stations { grid-template-columns: 1fr; }
  .engineer-board { grid-template-columns: minmax(0, 1fr); }
  .ocean-scene { min-height: 150px; }
  .mission-list { min-height: 130px; }
  .mission-empty { min-height: 148px; }
  .repair-panel { min-height: 150px; }
  .bottom-bar { min-height: 50px; flex-wrap: wrap; }
  .shop-actions { flex-direction: column; }
  .fisher-activity { grid-template-columns: minmax(0, 1fr); }
  .fisher-activity-button { grid-column: 1; grid-row: auto; width: 100%; }
  .credits-developers { grid-template-columns: 1fr; }
  .credits-tools li { align-items: flex-start; flex-direction: column; gap: 3px; }
  .credits-tools li span { text-align: left; }
  .fish-collection { grid-template-columns: 1fr; }
  .quick-chat { justify-content: flex-start; flex-wrap: wrap; padding: 6px 0; }
  .quick-chat > span { flex-basis: 100%; }
  .role-overlay { padding: 14px; }
  .role-card { grid-template-columns: 32px minmax(0, 1fr); gap: 9px; padding: 12px; }
  .role-card-key { grid-column: 2; }
  .role-footer { align-items: flex-start; }
  .story-overlay { padding: 14px; }
  .story-panel { grid-template-columns: 1fr; }
  .story-art { min-height: 150px; }
  .story-art svg { width: 43%; }
  .story-copy { padding: 22px; }
  .story-copy h2 { margin-top: 10px; }
  .story-copy p { margin-bottom: 16px; }
  .bait-restock { align-items: flex-start; flex-direction: column; }
  .bait-restock .secondary-button { width: 100%; }
  .game-over { align-items: flex-start; flex-direction: column; gap: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
