/* Approved Orbital Hangar foundation. Legacy panels and gameplay remain separately scoped. */
:root {
  --sd-bg: #080d18; --sd-surface: #111c2c; --sd-border: #263348;
  --sd-text: #edf4fb; --sd-muted: #a6b6ca; --sd-cyan: #7de5d3;
  --sd-pink: #f295bd; --sd-violet: #b7a4f5;
  --sd-font: 'Segoe UI', Arial, sans-serif;
}
#sdApp:not(.sd-enabled), #sdApp:not(.sd-enabled) > #sdLegacy { display: contents; }
.sd-shell-header[hidden], .sd-stage-note[hidden], .sd-shell-back[hidden], .sd-shell-settings[hidden] { display: none !important; }
.sd-shell-header, .sd-stage-note, .sd-shell-status { font-family: var(--sd-font); }
.sd-shell-header svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.sd-shell-header button { font: 14px/1.3 var(--sd-font); color: var(--sd-muted); border: 1px solid var(--sd-border); background: var(--sd-surface); border-radius: 10px; min-height: 44px; cursor: pointer; }
.sd-shell-header button:hover { border-color: #56756f; color: var(--sd-text); }
.sd-shell-header button:active { background: #20373e; }
.sd-shell-header button:focus-visible { outline: 3px solid var(--sd-cyan); outline-offset: 3px; }
.sd-shell-header button:disabled { opacity: .55; cursor: wait; }
.sd-shell-header { width: min(1184px, 100%); margin-inline: auto; display: flex; align-items: center; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--sd-border); color: var(--sd-text); }
.sd-shell-back { display: flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 14px; }
.sd-shell-brand { display: flex; align-items: center; gap: 12px; min-width: 0; }
.sd-shell-mark { display: flex; align-items: center; gap: 3px; width: 26px; height: 28px; transform: rotate(-25deg); }
.sd-shell-mark i { display: block; width: 5px; background: var(--sd-cyan); }
.sd-shell-mark i:nth-child(1) { height: 12px; }.sd-shell-mark i:nth-child(2) { height: 26px; }.sd-shell-mark i:nth-child(3) { height: 18px; }
.sd-shell-wordmark { font: 10px/1.6 'Press Start 2P', monospace; color: var(--sd-text); white-space: nowrap; }
.sd-shell-wordmark span { color: var(--sd-cyan); }
.sd-shell-location { margin-left: auto; color: var(--sd-muted); font: 14px/1.4 var(--sd-font); }
.sd-shell-settings { width: 44px; flex: 0 0 44px; display: grid; place-items: center; padding: 8px; }
.sd-stage-note { color: var(--sd-muted); font-size: 12px; line-height: 1.5; text-align: center; padding: 10px 4px; }
.sd-shell-status { position: fixed; z-index: 100; bottom: max(20px, var(--tg-safe-bottom)); left: 50%; transform: translateX(-50%); width: min(440px, calc(100% - 32px)); color: var(--sd-text); font-size: 14px; padding: 14px 18px; border: 1px solid var(--sd-border); border-radius: 10px; background: var(--sd-surface); }
.sd-shell-status:empty { display: none; }
body.sd-shell-active.sd-shell-menu { display: block; background: var(--sd-bg); }
.sd-shell-menu #sdApp { width: 100%; height: 100%; display: grid; grid-template-rows: auto minmax(0, 1fr) auto; padding-inline: clamp(16px, 3vw, 40px); }
.sd-shell-menu #sdLegacy { display: flex; align-items: center; justify-content: center; min-height: 0; overflow: auto; width: 100%; }
.sd-shell-menu #wrap { height: 100%; width: min(100%, 680px); padding: 20px 8px; }
.sd-shell-menu #wrap.adminMenuActive { width: min(100%, 780px); }
.sd-shell-menu #hud, .sd-shell-menu #gameControls, .sd-shell-menu #pvpBattleHud { display: none !important; }
.sd-shell-menu #screen { width: 100%; height: 100%; min-height: 0; flex: 1 1 auto; aspect-ratio: auto; }
/* No combat overrides: the unchanged Canvas, input rectangle and HUD use style.css. */
body.sd-shell-active:not(.sd-shell-menu) #sdApp,
body.sd-shell-active:not(.sd-shell-menu) #sdLegacy { display: contents; }
@media (max-width: 700px) {
  .sd-shell-header { padding-block: 10px; gap: 10px; flex-wrap: wrap; }
  .sd-shell-brand { gap: 8px; }.sd-shell-wordmark { font-size: 8px; }
  .sd-shell-back { padding: 9px; }.sd-shell-back span { display: none; }.sd-shell-back { width: 44px; flex: 0 0 44px; }
  .sd-shell-location { font-size: 12px; }.sd-shell-menu #wrap { padding: 12px 4px; }
  .sd-stage-note { font-size: 11px; padding-block: 6px; }
}
@media (max-width: 359px) { .sd-shell-location { flex-basis: 100%; order: 4; margin-left: 0; }.sd-shell-settings { margin-left: auto; } }
@media (prefers-reduced-motion: reduce) { .sd-shell-header * { transition: none !important; } }

/* Stage 3: the approved Home and Select Mode live outside the legacy playfield. */
#sdFront[hidden] { display: none !important; }
body.oh-front-active { display: block; background: radial-gradient(ellipse at 73% 28%, #13313a55, transparent 43%), radial-gradient(ellipse at 16% 80%, #21233a44, transparent 50%), var(--sd-bg); }
body.oh-front-active #sdApp { width: 100%; height: 100%; display: flex; flex-direction: column; min-height: 0; padding: 0; }
body.oh-front-active #sdLegacy, body.oh-front-active #sdStageNote { display: none !important; }
body.oh-front-active .sd-shell-header { flex: 0 0 auto; min-height: 104px; padding: 16px 40px; }
body.oh-front-active #sdNavBack, body.oh-front-active .sd-shell-location { display: none !important; }
body.oh-home-active #sdNavSettings { display: none !important; }
.oh-home-settings { display: none !important; }
body.oh-home-active .oh-home-settings { display: grid !important; margin-left: auto; }
body.oh-front-active #sdNavSettings { margin-left: auto; }
.oh-front { width: min(1184px, 100%); margin-inline: auto; padding: 0 40px; overflow: hidden; min-height: 0; flex: 1 1 auto; display: flex; flex-direction: column; font: 16px/1.5 var(--sd-font); color: var(--sd-text); touch-action: pan-y; }
.oh-view { flex: 1 1 0; min-height: 0; overflow-y: auto; overscroll-behavior-y: contain; scrollbar-color: #395366 transparent; scrollbar-width: thin; }
.oh-front button { font-family: var(--sd-font); cursor: pointer; color: inherit; transition: border-color .15s, background .15s; }
.oh-front button:focus-visible { outline: 3px solid #b2f5ed; outline-offset: 4px; }
.oh-front button:active { filter: brightness(.94); }.oh-front button:disabled { cursor: wait; opacity: .65; }
.oh-front svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.oh-front canvas { background: transparent; cursor: inherit; image-rendering: pixelated; }
.oh-front ::selection { background: #7de5d340; color: var(--sd-text); }
.oh-home-hero { display: grid; grid-template-columns: 1fr 1.1fr; align-items: center; gap: 14px; padding: 32px 0 8px; }
.oh-eyebrow { margin: 0 0 28px; color: var(--sd-muted); letter-spacing: 2px; font-size: 11px; font-weight: 600; display: flex; align-items: center; gap: 9px; }
.oh-status-dot { width: 5px; height: 5px; background: var(--sd-cyan); }
.oh-wordmark { margin: 0; font: clamp(28px, 3.8vw, 46px)/1.5 'Press Start 2P', monospace; letter-spacing: -1.5px; text-shadow: none; }
.oh-wordmark > span { display: block; }.oh-wordmark > span:last-child { color: var(--sd-cyan); }
.oh-logo-pixel { color: #f68c9d; font-size: 20px; margin-left: 6px; vertical-align: top; }
.oh-hero-tagline { font-size: 25px; font-weight: 500; line-height: 1.35; margin: 22px 0 14px; letter-spacing: -.5px; }.oh-hero-tagline br { display: none; }
.oh-hero-description { max-width: 350px; font-size: 15px; line-height: 1.65; color: var(--sd-muted); margin: 0 0 28px; }
.oh-play { display: flex; align-items: center; justify-content: space-between; width: min(350px, 100%); height: 62px; padding: 0 22px; border: 0; border-radius: 10px; background: var(--sd-cyan); color: #0b2728 !important; font-size: 16px; font-weight: 750; letter-spacing: 1.4px; box-shadow: 0 4px 0 #214d49; }
.oh-play > span { display: flex; align-items: center; gap: 12px; }.oh-play:hover { background: #a2f4e4; }
.oh-hero-art { position: relative; min-width: 0; height: 450px; display: grid; place-items: center; overflow: hidden; pointer-events: none; background: radial-gradient(ellipse at 50% 45%, #28565b44, transparent 60%); }
.oh-hero-art canvas { position: relative; width: 100%; height: 100%; object-fit: contain; z-index: 1; }
.oh-orbit { position: absolute; inset: 13% 10% 17%; border: 1px solid #57788125; border-radius: 50%; transform: rotate(-24deg); }.oh-orbit-two { inset: 25% -2% 27%; transform: rotate(20deg); border-color: #57788122; }
.oh-orbit-cross { position: absolute; width: 11px; height: 11px; }.oh-orbit-cross:before, .oh-orbit-cross:after { content: ''; position: absolute; background: #6ba0a25c; }.oh-orbit-cross:before { width: 11px; height: 1px; top: 5px; }.oh-orbit-cross:after { width: 1px; height: 11px; left: 5px; }.oh-cross-a { left: 15%; top: 23%; }.oh-cross-b { right: 8%; bottom: 35%; }
.oh-art-label { position: absolute; top: 8%; right: 8%; color: var(--sd-muted); font-size: 10px; letter-spacing: 1.8px; }
.oh-ship-caption { position: absolute; bottom: 5%; left: 10%; right: 10%; display: flex; align-items: center; gap: 12px; color: var(--sd-muted); font-size: 11px; letter-spacing: 1px; }.oh-caption-line { width: 22px; height: 1px; background: #637d8a; }.oh-ship-caption b { display: block; color: var(--sd-text); font-size: 13px; font-weight: 500; letter-spacing: 0; margin-top: 3px; }.oh-ready-badge { margin-left: auto; color: var(--sd-cyan); border: 1px solid #31564f; padding: 4px 7px; font-size: 10px; letter-spacing: 1.3px; }
.oh-home-nav { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-top: 12px; }
.oh-home-nav button { display: flex; align-items: center; gap: 13px; min-width: 0; min-height: 90px; padding: 20px 16px; border: 1px solid #253347; border-radius: 12px; background: #111d2b; text-align: left; }.oh-home-nav button:hover { border-color: #5f8e91; background: #152535; }.oh-home-nav svg { width: 22px; color: var(--sd-cyan); }.oh-home-nav button > span:not(.oh-nav-arrow) { font-size: 15px; font-weight: 600; min-width: 0; }.oh-home-nav small { display: block; margin-top: 4px; color: var(--sd-muted); font-size: 11px; font-weight: 400; white-space: nowrap; }.oh-nav-arrow { margin-left: auto; color: #8699af; }
.oh-home-nav .oh-nav-arrow { width: 17px; color: #8699af; }
.oh-home-footer { display: flex; align-items: center; justify-content: center; gap: 14px; padding: 30px 0 22px; color: var(--sd-muted); font-size: 10px; letter-spacing: 1.6px; }.oh-home-footer span { width: 32px; height: 1px; background: #354357; }
.oh-admin-link { display: block; min-height: 44px; padding: 10px 14px; margin: 0 auto 12px; border: 1px solid var(--sd-border); border-radius: 8px; background: none; font-size: 13px; }
.oh-sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.oh-modes { padding-top: 12px; }.oh-mode-heading { text-align: center; position: relative; padding: 8px 0 22px; }.oh-mode-heading .oh-eyebrow { justify-content: center; color: var(--sd-cyan); font-size: 11px; margin: 0 0 8px; }.oh-mode-heading h1 { font-size: 36px; font-weight: 550; line-height: 1.25; letter-spacing: -1px; margin: 0; }.oh-page-description { color: var(--sd-muted); font-size: 15px; margin: 12px 0 0; }
.oh-back { position: absolute; top: 8px; left: 0; display: flex; align-items: center; gap: 9px; min-height: 44px; padding: 10px 8px 10px 0; background: none; border: 0; color: var(--sd-muted); font-size: 14px; }.oh-back svg { width: 20px; }
.oh-mode-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; padding: 6px 0 10px; }
.oh-mode-card { --oh-accent: var(--sd-cyan); --oh-tint: #1a4b48; display: flex; flex-direction: column; min-width: 0; padding: 0; border: 1px solid #2a3b4c; border-radius: 16px; overflow: hidden; background: linear-gradient(160deg, #142a3155, transparent 50%), #101a29; text-align: left; }
.oh-mode-card.oh-pvp { --oh-accent: var(--sd-pink); --oh-tint: #59324e; background: linear-gradient(160deg, #49293744, transparent 50%), #121a29; }.oh-mode-card.oh-operation { --oh-accent: var(--sd-violet); --oh-tint: #3c315c; background: linear-gradient(160deg, #352a5144, transparent 50%), #121a29; }.oh-mode-card:hover { border-color: var(--oh-accent); }
.oh-card-topline { display: flex; align-items: center; justify-content: space-between; gap: 6px; padding: 20px 20px 0; color: var(--sd-muted); font-size: 10px; letter-spacing: 1px; }.oh-type-badge { color: var(--oh-accent); font-size: 10px; letter-spacing: .4px; border: 1px solid color-mix(in srgb, var(--oh-accent) 30%, transparent); background: #090e1980; border-radius: 4px; padding: 4px 6px; white-space: nowrap; }
.oh-mode-visual { display: block; height: 155px; background: radial-gradient(ellipse at center, var(--oh-tint), transparent 72%); }.oh-mode-visual canvas { width: 100%; height: 100%; object-fit: contain; }
.oh-mode-copy { padding: 0 20px 16px; display: flex; flex-direction: column; flex: 1; min-width: 0; }.oh-mode-kicker { display: block; color: var(--oh-accent); font-size: 10px; letter-spacing: 1.5px; font-weight: 600; margin-bottom: 12px; }.oh-mode-title { font: 18px/1.5 'Press Start 2P', monospace; letter-spacing: -.6px; color: var(--sd-text); }.oh-mode-title > span { color: var(--oh-accent); }
.oh-mode-description { display: block; color: #b8c6d8; font-size: 15px; line-height: 1.6; min-height: 72px; margin: 12px 0 14px; }.oh-mode-facts { display: flex; flex-direction: column; gap: 6px; color: var(--sd-muted); font-size: 12px; margin-bottom: 18px; overflow-wrap: anywhere; }.oh-mode-facts > span:before { content: '+'; color: var(--oh-accent); margin-right: 9px; }
.oh-mode-metrics { display: block; color: var(--sd-muted); font-size: 12px; line-height: 1.6; margin-bottom: 14px; font-variant-numeric: tabular-nums; }.oh-mode-metrics b { color: var(--sd-text); font-weight: 600; }
.oh-card-bottom { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding-top: 12px; border-top: 1px solid #a5b4cc1a; margin-top: auto; color: var(--oh-accent); font-size: 11px; letter-spacing: 1px; font-weight: 600; }.oh-arrow-box { background: color-mix(in srgb, var(--oh-accent) 12%, transparent); border-radius: 7px; width: 38px; height: 36px; display: grid; place-items: center; }.oh-arrow-box svg { width: 20px; }
.oh-mode-bottom-note { margin: 22px 0 30px; color: var(--sd-muted); text-align: center; font-size: 12px; }
.oh-legacy-settings { position: static; width: 44px; margin: 0 auto 16px !important; }
@media (min-width: 600px) and (max-width: 950px) {
  body.oh-front-active .sd-shell-header, .oh-front { padding-inline: 28px; }.oh-wordmark { font-size: 30px; }.oh-hero-tagline { font-size: 22px; }.oh-hero-art { height: 450px; }.oh-home-nav { grid-template-columns: repeat(2, minmax(0, 1fr)); }.oh-home-nav button { min-height: 82px; }
  .oh-mode-cards { grid-template-columns: 1fr; }.oh-mode-card { display: grid; grid-template-columns: 34% 1fr; }.oh-card-topline { grid-column: 1 / -1; padding-top: 15px; }.oh-mode-visual { grid-column: 1; grid-row: 2; height: 210px; }.oh-mode-copy { grid-column: 2; grid-row: 2; padding: 6px 24px 18px; }.oh-mode-description { min-height: 0; margin: 8px 0 12px; }.oh-mode-description br { display: none; }.oh-mode-facts { margin-bottom: 12px; }.oh-mode-kicker { margin-bottom: 6px; }.oh-mode-heading { padding-top: 45px; }
}
@media (max-width: 599px) {
  body.oh-front-active .sd-shell-header { min-height: 78px; padding: 10px 22px; gap: 10px; }.oh-front { padding-inline: 22px; }
  .oh-home-hero { display: flex; flex-direction: column; padding: 24px 0 0; gap: 0; }.oh-hero-copy { display: contents; }.oh-eyebrow { order: 0; justify-content: center; font-size: 10px; letter-spacing: 1.4px; margin: 0 0 14px; }.oh-wordmark { order: 1; text-align: center; font-size: 29px; line-height: 1.45; letter-spacing: -1px; }.oh-logo-pixel { display: none; }.oh-hero-tagline { order: 2; font-size: 16px; letter-spacing: 0; margin: 12px 0 0; color: #b8c8d8; }.oh-hero-description { display: none; }.oh-hero-art { order: 3; height: 245px; width: 100%; max-width: 390px; margin: -6px 0 10px; }.oh-orbit-one { inset: 11% 12% 14%; }.oh-orbit-two { inset: 30% 0 27%; }.oh-art-label { top: 12%; font-size: 10px; }.oh-ship-caption { bottom: 1%; left: 5%; right: 5%; font-size: 10px; }.oh-ship-caption b { font-size: 12px; }.oh-play { order: 4; width: 100%; height: 58px; }.oh-play-hint { order: 5; }
  .oh-home-nav { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: 24px; }.oh-home-nav button { min-height: 70px; padding: 13px 12px; gap: 10px; border-radius: 10px; }.oh-home-nav button > span:not(.oh-nav-arrow) { font-size: 13px; }.oh-home-nav small, .oh-nav-arrow { display: none; }.oh-home-nav svg { width: 20px; }.oh-home-footer { font-size: 8px; letter-spacing: 1.1px; gap: 8px; padding: 24px 0 10px; }.oh-home-footer span { width: 13px; }
  .oh-modes { padding: 0; }.oh-mode-heading { padding: 68px 0 24px; text-align: left; }.oh-mode-heading .oh-eyebrow { justify-content: flex-start; font-size: 10px; margin-bottom: 10px; }.oh-mode-heading h1 { font-size: 30px; letter-spacing: -.6px; }.oh-page-description { font-size: 14px; max-width: 290px; margin-top: 8px; }.oh-back { top: 10px; }.oh-mode-cards { grid-template-columns: 1fr; gap: 16px; padding: 0; }.oh-card-topline { padding: 16px 18px 0; }.oh-mode-visual { height: 150px; }.oh-mode-copy { padding: 0 20px 18px; }.oh-mode-title { font-size: 20px; }.oh-mode-kicker { margin-bottom: 9px; }.oh-mode-description { min-height: 0; margin: 12px 0 14px; }.oh-mode-description br { display: none; }.oh-mode-facts { gap: 5px; margin-bottom: 18px; }.oh-card-bottom { padding-top: 13px; }.oh-mode-bottom-note { text-align: left; line-height: 1.6; }
}
@media (max-width: 359px) { body.oh-front-active .sd-shell-header, .oh-front { padding-inline: 16px; }.oh-wordmark { font-size: 25px; }.oh-hero-art { height: 205px; }.oh-hero-tagline { font-size: 14px; }.oh-home-nav button { padding: 12px 10px; gap: 8px; }.oh-home-nav button > span:not(.oh-nav-arrow) { font-size: 12px; }.oh-home-footer { letter-spacing: .5px; }.oh-mode-title { font-size: 18px; } }
@media (max-height: 740px) and (max-width: 599px) { body.oh-front-active .sd-shell-header { min-height: 66px; }.oh-home-hero { padding-top: 18px; }.oh-wordmark { font-size: 25px; }.oh-hero-art { height: 190px; margin-bottom: 6px; }.oh-home-nav { margin-top: 20px; }.oh-home-nav button { min-height: 62px; }.oh-home-footer { padding-top: 18px; } }
@media (orientation: landscape) and (max-height: 600px) and (min-width: 600px) { body.oh-front-active .sd-shell-header { min-height: 70px; }.oh-home-hero { padding-block: 20px; }.oh-hero-art { height: 280px; }.oh-home-nav { grid-template-columns: repeat(4, minmax(0, 1fr)); }.oh-home-nav button { min-height: 65px; padding: 12px; gap: 8px; }.oh-home-nav small, .oh-nav-arrow { display: none; }.oh-mode-heading { padding: 20px 0 24px; }.oh-back { position: static; margin-bottom: 8px; }.oh-mode-cards { grid-template-columns: 1fr; }.oh-mode-visual { height: 185px; } }
@media (prefers-reduced-motion: reduce) { .oh-front * { transition: none !important; scroll-behavior: auto !important; } }


/* Stage 4: approved Settings, scoped to its independent full-size panel. */
.oh-settings{scroll-behavior:smooth}.oh-settings .ohs-app-shell{padding-top:env(safe-area-inset-top);padding-bottom:env(safe-area-inset-bottom)}.ohs-settings-header-label{font-size:10px;letter-spacing:1.8px;color:var(--sd-muted)}.ohs-settings-heading{padding:26px 0 30px}.ohs-settings-back{display:flex;align-items:center;gap:10px;width:fit-content;min-height:44px;color:var(--sd-muted);text-decoration:none;font-size:14px;margin-bottom:24px}.ohs-settings-back:hover{color:var(--sd-text)}.ohs-settings-back svg{width:20px}.ohs-settings-eyebrow{font-size:10px;font-weight:600;letter-spacing:2px;color:var(--sd-cyan);margin:0 0 12px}.ohs-settings-heading h1{font-size:38px;font-weight:550;letter-spacing:-1px;line-height:1.2;margin:0 0 12px}.ohs-settings-heading>p:last-child{margin:0;color:var(--sd-muted);font-size:16px}.ohs-settings-layout{display:grid;grid-template-columns:210px minmax(0,1fr);gap:36px;align-items:start}.ohs-settings-aside{position:sticky;top:24px}.ohs-settings-nav{display:grid;gap:8px}.ohs-settings-nav a{min-height:54px;border:1px solid transparent;border-radius:10px;padding:12px 14px;color:var(--sd-muted);display:flex;align-items:center;gap:12px;text-decoration:none;font-size:15px}.ohs-settings-nav a svg{width:20px;height:20px}.ohs-settings-nav a:hover{background:#172638}.ohs-settings-nav a[aria-current]{background:#152e33;border-color:#375952;color:var(--sd-cyan)}.ohs-nav-index{font-size:11px;letter-spacing:1px;color:var(--sd-muted);margin-left:auto}.ohs-aside-message{padding:32px 14px 20px;border-top:1px solid var(--sd-border);margin-top:32px}.ohs-mini-orbit{width:56px;height:56px;border:1px solid #43656177;border-radius:50%;display:grid;place-items:center;color:var(--sd-cyan);margin-bottom:20px}.ohs-aside-message strong{display:block;font-size:15px;font-weight:500}.ohs-aside-message p{font-size:13px;line-height:1.6;color:var(--sd-muted);margin:8px 0 0}.ohs-settings-sections{min-width:0;display:flex;flex-direction:column;gap:24px}.ohs-settings-panel{background:linear-gradient(145deg,#14233166,transparent 40%),#101a29;border:1px solid var(--sd-border);border-radius:16px;padding:26px;min-width:0;scroll-margin-top:24px}.ohs-section-heading{display:flex;align-items:center;gap:14px;margin-bottom:24px}.ohs-section-icon{display:grid;place-items:center;width:44px;height:44px;background:#1c363a;border-radius:12px;flex-shrink:0;color:var(--sd-cyan)}.ohs-section-icon svg{width:22px;height:22px}.ohs-section-heading h2{margin:0;font-size:22px;line-height:1.3;font-weight:550;letter-spacing:-.3px}.ohs-section-heading p{color:var(--sd-muted);font-size:14px;margin:5px 0 0;line-height:1.6}.ohs-toggle-row{display:flex;position:relative;align-items:center;gap:24px;justify-content:space-between;min-height:80px;padding:18px 0;cursor:pointer;border-top:1px solid var(--sd-border)}.ohs-toggle-row strong{display:block;font-size:15px;line-height:1.4;font-weight:550}.ohs-toggle-row small{display:block;font-size:13px;color:var(--sd-muted);line-height:1.6;margin-top:5px}.ohs-toggle-row>input{position:absolute;right:0;width:52px;height:44px;opacity:0;cursor:pointer;z-index:1;margin:0}.ohs-switch{width:48px;height:28px;border-radius:20px;background:#38485f;border:1px solid #5c6c82;flex-shrink:0;position:relative;transition:background .15s}.ohs-switch:after{content:'';position:absolute;left:3px;top:3px;width:20px;height:20px;border-radius:50%;background:#c5d1df;transition:transform .15s}.ohs-toggle-row input:checked+.ohs-switch{background:var(--sd-cyan);border-color:var(--sd-cyan)}.ohs-toggle-row input:checked+.ohs-switch:after{background:#0f3433;transform:translateX(20px)}.ohs-toggle-row input:focus-visible+.ohs-switch{outline:3px solid #c3fff3;outline-offset:5px}.ohs-mute-row{padding:0 0 20px;border-top:0;border-bottom:1px solid var(--sd-border);min-height:66px;margin-bottom:24px}.ohs-volume-grid{display:grid;grid-template-columns:1fr 1fr;gap:32px;min-width:0}.ohs-volume-control{min-width:0}.ohs-field-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:8px}.ohs-field-heading label{font-size:15px;font-weight:550}.ohs-field-heading output{color:var(--sd-cyan);font-size:17px;font-variant-numeric:tabular-nums;font-weight:600}.oh-settings input[type=range]{appearance:none;-webkit-appearance:none;background:transparent;cursor:pointer;width:100%;height:44px;margin:0;--progress:75%}.oh-settings input[type=range]::-webkit-slider-runnable-track{height:5px;border-radius:5px;background:linear-gradient(to right,var(--sd-cyan) var(--progress),#38465b var(--progress))}.oh-settings input[type=range]::-webkit-slider-thumb{appearance:none;-webkit-appearance:none;margin-top:-7.5px;width:20px;height:20px;border-radius:50%;background:#dbfff7;border:4px solid var(--sd-cyan);box-shadow:0 0 0 5px #152533}.oh-settings input[type=range]::-moz-range-track{height:5px;border-radius:5px;background:#38465b}.oh-settings input[type=range]::-moz-range-progress{height:5px;background:var(--sd-cyan)}.oh-settings input[type=range]::-moz-range-thumb{width:16px;height:16px;border:3px solid var(--sd-cyan);background:#dbfff7;border-radius:50%}.oh-settings input[type=range]:focus-visible{outline:2px solid var(--sd-cyan);outline-offset:4px;border-radius:4px}.ohs-range-ends{display:flex;justify-content:space-between;color:var(--sd-muted);font-size:12px;margin-top:-3px}.ohs-field-note{color:var(--sd-muted);font-size:13px;line-height:1.6;margin:12px 0 0}.ohs-panel-footer{display:flex;align-items:center;justify-content:space-between;gap:16px;border-top:1px solid var(--sd-border);margin-top:24px;padding-top:18px}.ohs-panel-footer p{font-size:12px;color:var(--sd-muted);margin:0}.ohs-quiet-button{display:flex;align-items:center;justify-content:center;gap:9px;min-height:44px;font-size:13px;border:1px solid #405169;border-radius:8px;background:#19283a;padding:8px 12px;flex-shrink:0}.ohs-quiet-button svg{width:18px;height:18px;color:var(--sd-cyan)}.ohs-quiet-button:hover{background:#22394b}.ohs-quiet-button:disabled{opacity:.55;cursor:default}.ohs-sound-muted .ohs-volume-control{opacity:.55}.ohs-sound-muted input[type=range]{cursor:not-allowed}.ohs-sound-muted .ohs-field-heading output{color:var(--sd-muted)}.oh-settings fieldset{padding:0;margin:0;border:0;min-width:0}.ohs-sr-only{position:absolute;left:-10000px;width:1px;height:1px;overflow:hidden}.ohs-control-options{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin-bottom:20px}.ohs-control-option{position:relative;display:flex;flex-direction:column;border:1px solid #3a495e;padding:16px 14px;border-radius:12px;background:#111c2d;min-width:0;cursor:pointer}.ohs-control-option:has(input:checked){border-color:var(--sd-cyan);background:#142f32}.ohs-control-option>input,.ohs-segmented-options input{position:absolute;opacity:0;width:100%;height:100%;inset:0;margin:0;cursor:pointer}.ohs-option-head{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:16px}.ohs-control-symbol{font-size:25px;line-height:1;color:var(--sd-muted)}.ohs-radio-mark{width:16px;height:16px;border:1px solid #708199;border-radius:50%;display:block}.ohs-control-option:has(input:checked) .ohs-radio-mark{border:4px solid var(--sd-cyan)}.ohs-control-option:has(input:checked) .ohs-control-symbol{color:var(--sd-cyan)}.ohs-control-option strong{font-size:14px;line-height:1.5;font-weight:600;overflow-wrap:anywhere}.ohs-control-option small{font-size:13px;line-height:1.5;color:var(--sd-muted);display:block;margin-top:7px;margin-bottom:16px}.ohs-option-caption{font-size:10px;letter-spacing:1.5px;color:var(--sd-muted);margin-top:auto}.ohs-control-option:has(input:focus-visible){outline:3px solid #b2f5ed;outline-offset:4px}.ohs-control-demo{padding:16px 18px;background:#0a1220;border:1px solid #304352;border-radius:12px;overflow:hidden}.ohs-demo-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;color:var(--sd-muted);font-size:10px;letter-spacing:1.5px}.ohs-demo-badge{padding:3px 6px;color:var(--sd-cyan);border:1px solid #3e5d59;border-radius:4px;letter-spacing:1px;font-size:10px}#ohs-control-canvas{display:block;touch-action:none;width:100%;height:160px;object-fit:contain;cursor:ew-resize}.ohs-demo-instructions{display:flex;align-items:flex-start;justify-content:center;gap:8px;color:#bfd5dd;font-size:13px}.ohs-demo-instructions p{margin:0;text-align:center}.ohs-demo-instructions svg{width:16px;height:16px;margin-top:2px;color:var(--sd-cyan)}.ohs-demo-range-note{text-align:center;color:var(--sd-muted);font-size:12px;margin:0}.ohs-info-note{display:flex;gap:10px;color:var(--sd-muted);font-size:13px;line-height:1.7;margin:18px 0 0}.ohs-info-note svg{width:17px;height:17px;color:var(--sd-muted);margin-top:2px}.ohs-choice-field{margin:24px 0}.ohs-choice-field legend{font-size:15px;font-weight:550;margin-bottom:12px}.ohs-segmented-options{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px;border:1px solid var(--sd-border);padding:5px;border-radius:11px;background:#0a1220}.ohs-segmented-options label{display:block;position:relative;cursor:pointer;min-width:0}.ohs-segmented-options span{display:flex;align-items:center;justify-content:center;min-height:44px;padding:8px 10px;border-radius:7px;color:var(--sd-muted);font-size:14px;font-weight:500;border:1px solid transparent;text-align:center}.ohs-segmented-options input:checked+span{color:var(--sd-cyan);background:#1b383d;border-color:#46675f}.ohs-segmented-options input:focus-visible+span{outline:3px solid #c3fff3;outline-offset:2px}.ohs-safety-note{padding:14px 16px;background:#152a2d;border-radius:9px;border-left:2px solid #6bc7b7}.ohs-safety-note svg{color:var(--sd-cyan)}.ohs-haptics-note{max-width:620px}.ohs-settings-end{display:flex;align-items:center;justify-content:space-between;gap:20px;padding:2px 0}.ohs-save-state{display:flex;align-items:center;gap:8px;font-size:13px;color:var(--sd-muted)}.ohs-save-state svg{color:var(--sd-cyan);width:18px;height:18px}.ohs-reset-button{display:flex;gap:8px;align-items:center;justify-content:center;min-height:44px;padding:10px 14px;background:transparent;border:1px solid #405169;border-radius:8px;color:var(--sd-muted);font-size:13px;cursor:pointer}.ohs-reset-button svg{width:17px;height:17px}.ohs-reset-button:hover{color:var(--sd-text);background:#19283a}.ohs-settings-demo-note{font-size:12px;color:var(--sd-muted);margin:0 0 30px;max-width:600px}.oh-settings .ohs-prototype-note{padding-top:20px;padding-bottom:24px;font-size:10px}.ohs-reset-dialog{background:#142132;color:var(--sd-text);border:1px solid #4d617b;border-radius:18px;width:min(440px,calc(100% - 32px));padding:28px;box-shadow:0 30px 120px #0008}.ohs-reset-dialog::backdrop{background:#030814ce}.ohs-reset-dialog h2{font-size:26px;line-height:1.3;font-weight:550;margin:12px 0 16px}.ohs-reset-dialog p{font-size:15px;color:var(--sd-muted);line-height:1.7;margin:0}.ohs-dialog-eyebrow{color:var(--sd-cyan);font-size:10px;letter-spacing:1.4px}.ohs-dialog-footnote{font-size:13px;margin-top:12px}.ohs-reset-dialog-actions{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-top:24px}.ohs-reset-dialog-actions button{min-height:48px;border:1px solid #4e617a;border-radius:9px;background:#1a2c40;font-size:14px}.ohs-reset-dialog-actions #ohs-confirm-reset{color:#0d2b29;background:var(--sd-cyan);border-color:var(--sd-cyan);font-weight:600}
@media(max-width:1050px) and (min-width:701px){.ohs-settings-layout{grid-template-columns:170px minmax(0,1fr);gap:24px}.ohs-settings-panel{padding:22px}.ohs-settings-nav a{padding:11px;gap:10px;font-size:14px}.ohs-nav-index{display:none}.ohs-volume-grid{grid-template-columns:1fr;gap:24px}.ohs-control-options{grid-template-columns:1fr}.ohs-control-option{display:grid;grid-template-columns:32px 1fr;gap:3px 12px;padding:14px}.ohs-option-head{grid-column:1;grid-row:1/3;margin:0;justify-content:center}.ohs-option-head .ohs-radio-mark{display:none}.ohs-control-option strong{grid-column:2;grid-row:1;font-size:15px;overflow-wrap:normal}.ohs-control-option small{grid-column:2;grid-row:2;margin:0}.ohs-control-option .ohs-option-caption{display:none}.ohs-control-option:has(input:checked) .ohs-option-head:after{content:'✓';font-size:18px;color:var(--sd-cyan)}.ohs-control-option:has(input:checked) .ohs-control-symbol{display:none}}
@media(max-width:700px){.oh-settings .ohs-app-shell{padding-left:20px;padding-right:20px}.ohs-settings-heading{padding:12px 0 22px}.ohs-settings-back{margin-bottom:18px}.ohs-settings-eyebrow{font-size:9px;letter-spacing:1.5px}.ohs-settings-heading h1{font-size:32px}.ohs-settings-heading>p:last-child{font-size:14px;max-width:290px;line-height:1.6}.ohs-settings-header-label{font-size:9px;letter-spacing:.8px}.ohs-settings-layout{display:flex;flex-direction:column;gap:20px}.ohs-settings-aside{position:sticky;top:0;z-index:4;background:#080d18f5;width:calc(100% + 40px);margin:0 -20px;padding:8px 20px;border-bottom:1px solid #304052;backdrop-filter:blur(8px)}.ohs-settings-nav{grid-template-columns:repeat(4,minmax(0,1fr));gap:4px}.ohs-settings-nav a{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;padding:8px 2px;min-height:64px;font-size:11px;border-radius:9px}.ohs-settings-nav a svg{width:19px;height:19px}.ohs-nav-index{display:none}.ohs-aside-message{display:none}.ohs-settings-sections{gap:18px;width:100%}.ohs-settings-panel{padding:20px 16px;border-radius:13px;scroll-margin-top:96px}.ohs-section-heading{gap:12px;margin-bottom:22px;align-items:flex-start}.ohs-section-icon{width:38px;height:38px;border-radius:10px}.ohs-section-heading h2{font-size:20px}.ohs-section-heading p{font-size:13px;line-height:1.6;margin-top:5px}.ohs-volume-grid{grid-template-columns:1fr;gap:24px}.ohs-mute-row{margin-bottom:22px;padding-bottom:18px}.ohs-toggle-row{gap:18px;min-height:84px}.ohs-toggle-row strong{font-size:15px}.ohs-toggle-row small{font-size:13px;max-width:230px}.ohs-field-heading label{font-size:15px}.ohs-field-note{font-size:13px}.ohs-panel-footer{align-items:flex-start;flex-direction:column;gap:12px;padding-top:16px;margin-top:20px}.ohs-quiet-button{width:100%;min-height:46px}.ohs-control-options{grid-template-columns:1fr;gap:10px}.ohs-control-option{display:grid;grid-template-columns:minmax(0,1fr) 18px;gap:3px 12px;padding:15px 14px}.ohs-option-head{display:contents}.ohs-control-symbol,.ohs-option-caption{display:none}.ohs-radio-mark{grid-column:2;grid-row:1/3;align-self:center}.ohs-control-option strong{grid-column:1;grid-row:1;font-size:15px;overflow-wrap:normal}.ohs-control-option small{grid-column:1;grid-row:2;margin:3px 0 0;font-size:13px}.ohs-control-demo{padding:14px 12px}#ohs-control-canvas{height:135px}.ohs-demo-heading{font-size:9px}.ohs-demo-range-note{font-size:11px}.ohs-info-note{font-size:13px;gap:8px}.ohs-segmented-options{gap:3px;padding:4px}.ohs-segmented-options span{font-size:13px;padding:9px 3px;min-height:46px}.ohs-choice-field legend{font-size:15px}.ohs-safety-note{padding:12px}.ohs-settings-end{flex-direction:column;align-items:stretch;gap:16px;padding-top:8px}.ohs-save-state{justify-content:center;min-height:24px}.ohs-reset-button{min-height:48px;font-size:14px}.ohs-settings-demo-note{font-size:12px;line-height:1.6;text-align:center;margin-bottom:20px}.oh-settings .ohs-prototype-note{font-size:9px;text-align:center}}
@media(max-width:359px){.oh-settings .ohs-app-shell{padding-left:16px;padding-right:16px}.ohs-settings-aside{width:calc(100% + 32px);margin-inline:-16px;padding-inline:16px}.ohs-settings-header-label{display:none}.ohs-settings-panel{padding:18px 14px}.ohs-settings-nav a{font-size:10px}.ohs-settings-nav a svg{width:18px}.ohs-section-heading h2{font-size:19px}.ohs-settings-heading h1{font-size:30px}.ohs-toggle-row small{max-width:180px}.ohs-segmented-options span{font-size:12px}.ohs-field-heading{gap:8px}.ohs-field-heading label{font-size:14px}.ohs-settings-back{font-size:14px}}
@media(prefers-reduced-motion:reduce){.oh-settings{scroll-behavior:auto}.ohs-switch,.ohs-switch:after{transition:none}}
@media(max-width:700px){.ohs-settings-nav a{font-size:12px}}
@media(max-width:359px){.ohs-settings-nav a{font-size:11px}}



body.oh-settings-active #sdNavBack, body.oh-settings-active #sdLocation { display: none !important; }
.oh-settings .panelBack { position: static; inset: auto; border: 0; background: none; padding: 0; }
.oh-settings { padding-bottom: 28px; scroll-padding-top: 100px; }
.oh-settings button, .oh-settings input { font: inherit; color: inherit; }
.oh-settings svg { fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.ohs-icon-defs { position: absolute; width: 0; height: 0; overflow: hidden; }
.oh-settings .ohs-settings-heading h1 { font-family: var(--sd-font); color: var(--sd-text); text-shadow: none; text-align: left; }
.oh-settings .ohs-section-heading h2 { font-family: var(--sd-font); color: var(--sd-text); text-shadow: none; text-align: left; }
.ohs-settings-sections { touch-action: pan-y; }
.ohs-settings-back svg { height: 20px; }
.ohs-settings-panel button:focus-visible, .ohs-settings-nav a:focus-visible,
.ohs-reset-button:focus-visible, .ohs-settings-back:focus-visible, .ohs-reset-dialog button:focus-visible { outline: 3px solid #b2f5ed; outline-offset: 3px; }
.ohs-settings-panel :disabled { opacity: .55; cursor: not-allowed; }
.ohs-reset-dialog { position: fixed; inset: 0; margin: auto; max-height: calc(100dvh - 32px); overflow-y: auto; font: 16px/1.5 var(--sd-font); }
.ohs-reset-dialog h2 { color: var(--sd-text); text-shadow: none; font-family: var(--sd-font); text-align: left; }
.ohs-reset-dialog button { cursor: pointer; color: var(--sd-text); }
.ohs-save-state[data-error="true"] { color: #f5b8ad; }
.ohs-settings-panel :focus-visible { scroll-margin-block: 110px 20px; }
#ohs-test-haptics { margin-top: 18px; }
.ohs-control-symbol { width: 24px; height: 24px; }
@media (max-width: 700px) { .oh-settings { padding-top: 0; }.ohs-settings-back { margin-top: 8px; } }
@media (max-width: 700px) { .ohs-settings-aside { width: 100%; margin: 0; padding: 8px 0; }.ohs-settings-nav a { font-size: 12px; } }
@media (max-width: 359px) { .ohs-settings-nav a { font-size: 11px; } }

/* Pilot Experience — scoped extension of Orbital Hangar. */
body.oh-front-active.oh-lobby-active #sdNavBack:not([hidden]) { display:flex!important; }
body.oh-lobby-active .sd-shell-brand { margin-right:auto; }
.oh-lobby { --ohl-accent:#f295bd; --ohl-border:#3a3d54; padding:25px 3px 36px; display:grid; align-content:start; gap:18px; scroll-padding-block:12px; }
.oh-lobby[hidden],.oh-lobby [hidden] { display:none!important; }
.ohl-heading,.ohl-line { display:flex; justify-content:space-between; align-items:center; flex-wrap:wrap; gap:10px; }
.ohl-heading { padding:4px 0 8px; }
.ohl-heading h1 { font:clamp(24px,4vw,37px)/1.45 'Press Start 2P',monospace; color:var(--sd-text); }
.ohl-kicker { color:var(--ohl-accent); letter-spacing:1.5px; font-size:12px; margin-bottom:8px; }
.ohl-heading div > p:last-child,.ohl-small { color:var(--sd-muted); }
.ohl-heading div > p:last-child { margin-top:8px; }
.ohl-small,.ohl-options small,.ohl-state small { font-size:13px; line-height:1.5; color:var(--sd-muted); }
.ohl-layout { display:grid; grid-template-columns:minmax(0,2.5fr) minmax(250px,1fr); gap:16px; align-items:start; }
.ohl-column { display:grid; align-content:start; gap:16px; min-width:0; }
.ohl-deck-tools { display:flex; flex-wrap:wrap; align-items:center; gap:8px; }
.oh-lobby #ohl-help { padding-inline:10px; font-size:13px; background:#152033; color:var(--sd-muted); }
.ohl-sidebar { display:grid; gap:14px; min-width:0; }
.ohl-card { background:#101a29; border:1px solid var(--sd-border); border-radius:15px; padding:clamp(13px,2vw,22px); min-width:0; display:grid; gap:13px; }
.ohl-card h2,.ohl-dialog h2 { color:var(--sd-text); font:650 20px/1.3 var(--sd-font); text-align:left; text-shadow:none; }
.ohl-deck { border-color:var(--ohl-border); background:linear-gradient(145deg,#201d31,#101a29 60%); }
.ohl-badge { font-size:12px; color:#f8c9dd; border:1px solid #775269; background:#332235; padding:3px 8px; border-radius:5px; }
.ohl-scene { position:relative; min-width:0; display:grid; grid-template-columns:minmax(0,1fr) auto minmax(0,1fr); align-items:center; gap:9px; padding:12px; border-radius:11px; border:1px solid #394358; background:radial-gradient(ellipse at 25% 50%,#19454b,transparent 63%),radial-gradient(ellipse at 82% 50%,#482d47,transparent 57%),#0b1422; }
.ohl-scene figure { display:grid; gap:6px; text-align:center; justify-items:center; color:var(--sd-muted); min-width:0; overflow-wrap:anywhere; }
.ohl-scene canvas,.ohl-unknown { width:min(100%,195px); aspect-ratio:3/2; height:auto; }
.ohl-scene .ohl-ship-art { width:min(100%,195px); aspect-ratio:3/2; min-width:0; }
.ohl-scene .ohl-ship-art > canvas:not(.sd-classic-webgl) { display:block; width:100%; height:100%; }
.ohl-unknown { display:grid; place-items:center; color:#f4b5d2; font:clamp(24px,5vw,50px) 'Press Start 2P',monospace; background:radial-gradient(ellipse,#3d2845 20%,transparent 65%); }
.ohl-versus { color:#edc3dc; font:clamp(12px,2vw,21px) 'Press Start 2P',monospace; }
.oh-lobby button { min-height:44px; min-width:0; padding:8px 12px; border:1px solid #45566f; border-radius:8px; color:var(--sd-text); background:#172638; font:600 14px/1.4 var(--sd-font); }
.oh-lobby button:hover:not(:disabled),.oh-lobby button[aria-pressed="true"] { border-color:var(--ohl-accent); background:#31263d; }
.oh-lobby :is(button,input):focus-visible { outline:2px solid var(--ohl-accent); outline-offset:2px; }
.oh-lobby button:disabled { opacity:.55; cursor:default; }
.oh-lobby .ohl-primary { background:#f295bd; color:#281525; border-color:transparent; }
.oh-lobby .ohl-primary:hover:not(:disabled) { color:#281525; background:#ffc0d9; }
.ohl-primary span { float:right; }
.ohl-options,.ohl-stats { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; }
.ohl-options button { text-align:left; }
.ohl-options small { display:block; margin-top:4px; font-weight:400; }
.ohl-stats > div { color:var(--sd-muted); padding:8px 0; border-top:1px solid var(--sd-border); font-size:13px; }
.ohl-stats strong { display:block; color:var(--sd-text); font-size:17px; }
.ohl-rating { color:var(--ohl-accent); font:700 40px/1.15 var(--sd-font); }
.ohl-state { display:grid; grid-template-columns:auto minmax(0,1fr) auto; align-items:center; gap:10px; border:1px solid #805978; background:#292038; border-radius:10px; padding:8px 12px; min-height:54px; }
.ohl-state[data-kind="error"],.ohl-state[data-kind="join-error"] { border-color:#8e5968; }
.ohl-state > div:nth-child(2) { grid-column:2; }
.ohl-state:has(.ohl-clock[hidden]) > div:nth-child(2) { grid-column:1/3; }
.ohl-clock { color:#ffc0da; font:700 clamp(22px,4vw,32px)/1 var(--sd-font); min-width:2ch; text-align:center; font-variant-numeric:tabular-nums; }
.oh-lobby #pvpCancel.ohl-danger { border-color:#b26a82; background:#492637; color:#ffe5f0; margin:0; width:auto; box-shadow:none; }
.ohl-private :is(#ohl-host,#pvpInviteBox,form) { display:grid; gap:8px; justify-items:start; }
.ohl-private #pvpInviteBox { width:100%; border-top:1px solid var(--sd-border); padding-top:10px; }
.ohl-tabs,.ohl-field { display:flex; flex-wrap:wrap; align-items:center; gap:8px; }
.ohl-field { width:100%; }
.ohl-field input { flex:1 1 130px; min-width:0; max-width:100%; min-height:44px; border:1px solid #465871; border-radius:8px; padding:9px 10px; background:#0c1728; color:var(--sd-text); font:16px var(--sd-font); }
.ohl-code { color:var(--ohl-accent); letter-spacing:2px; font-size:24px; }
.ohl-rows { display:grid; gap:8px; }
.ohl-row { display:grid; grid-template-columns:auto minmax(0,1fr) auto; align-items:center; gap:6px 10px; padding:8px; border:1px solid var(--sd-border); border-radius:8px; overflow-wrap:anywhere; }
.ohl-row small { grid-column:2/-1; }
.ohl-win { color:var(--sd-cyan); }
.ohl-dialog { position:fixed; inset:0; margin:auto; width:min(460px,calc(100% - 32px)); max-height:calc(100dvh - 32px); overflow:auto; border:1px solid #5b4b66; border-radius:15px; padding:20px; background:#172236; color:var(--sd-text); }
.ohl-dialog[open] { display:grid; gap:14px; }
.ohl-dialog::backdrop { background:#030814cc; }
.ohl-dialog ol { padding-left:20px; }
@media(max-width:740px){.ohl-layout{grid-template-columns:minmax(0,1fr)}.oh-lobby{padding-top:18px}}
@media(max-width:440px){.ohl-options{grid-template-columns:minmax(0,1fr)}.ohl-state{grid-template-columns:auto minmax(0,1fr)}.oh-lobby #pvpCancel{grid-column:1/-1}.ohl-row{grid-template-columns:auto minmax(0,1fr)}.ohl-row small{grid-column:1/-1}}
body.oh-front-active.oh-pilot-active #sdNavBack:not([hidden]) { display:flex!important; }
body.oh-pilot-active .sd-shell-brand { margin-right:auto; }
.oh-pilot { padding: 26px 3px 38px; scroll-padding: 12px; }
.ohp-heading { margin: 4px 0 26px; }
.ohp-heading h1 { font: 550 clamp(28px,4vw,40px)/1.18 var(--sd-font); letter-spacing: -.025em; }
.ohp-heading p { margin-top: 8px; }
.ohp-body { display:grid; gap:18px; min-width:0; }
.adminPhotoPreview { display:block; width:100%; max-height:260px; object-fit:contain; border-radius:8px; background:#080e19; }
.adminPhotoPreview[hidden],#adminBroadcastPhotoRemove[hidden] { display:none; }
#adminBroadcastPhoto { max-width:100%; min-height:44px; }
.adminPhotoHint { font-size:13px; line-height:1.5; color:var(--sd-muted); margin:4px 0; }
#adminBroadcastPhotoRemove { min-height:44px; }
.ohp-body h2,.ohp-dialog h2 { font: 650 22px/1.25 var(--sd-font); text-align:left; text-shadow:none; color:var(--sd-text); }
.ohp-body h3 { font: 650 17px/1.35 var(--sd-font); }
.ohp-muted { color:var(--sd-muted); font-size:14px; line-height:1.55; }
.ohp-card { display:grid; align-content:start; gap:14px; min-width:0; background:#101a29; border:1px solid var(--sd-border); border-radius:16px; padding:clamp(14px,2.4vw,26px); }
.ohp-card.violet { background:#171a30; border-color:#3c355b; }
.ohp-card.gold { background:#201e27; border-color:#554639; }
.ohp-split { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:18px; }
.ohp-profile-hero { grid-template-columns:repeat(2,minmax(0,1fr)); align-items:center; background:linear-gradient(125deg,#152638,#101a29 65%); }
.ohp-identity,.ohp-ship-stage { display:grid; gap:12px; min-width:0; }
.ohp-ranking-ship { border-top:1px solid var(--sd-border); padding-top:14px; }
.ohp-ranking-ship .ohp-art-large { min-height:170px; }
.ohp-ranking-ship .ohp-art > .ohp-muted { padding:16px; text-align:center; }
.ohp-pilot-heading { display:grid; gap:5px; min-width:0; }
.ohp-pilot-heading .ohp-pilot-name { min-width:0; margin:0; }
.ohp-ship-heading { display:flex; flex-wrap:wrap; align-items:baseline; justify-content:space-between; gap:4px 12px; overflow-wrap:anywhere; }
.ohp-ship-heading p { margin:0; }
.ohp-monogram.ohp-pilot-sign { border:0; background:#192738; color:var(--sd-text); }
.ohp-title-art,.ohp-art .ohp-title-art { display:block; width:168px; max-width:100%; height:auto; aspect-ratio:6; object-fit:fill; image-rendering:pixelated; }
.ohp-item .ohp-title-art { width:132px; }
.ohp-identity h2.ohp-pilot-name { font-size:clamp(24px,4vw,38px); overflow-wrap:anywhere; }
.ohp-record { color:var(--sd-cyan); font-size:clamp(28px,5vw,52px); line-height:1.1; overflow-wrap:anywhere; }
.ohp-badge { display:inline-block; width:fit-content; padding:4px 9px; border:1px solid #506076; border-radius:6px; font-size:12px; color:var(--sd-text); }
.ohp-badge.cyan { border-color:#417c75; color:var(--sd-cyan); background:#153432; }
.ohp-stats { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; }
.ohp-stat { display:grid; gap:5px; min-width:0; overflow-wrap:anywhere; }
.ohp-stat strong { font-size:18px; font-variant-numeric:tabular-nums; }
.ohp-highlights { grid-template-columns:repeat(4,minmax(0,1fr)); }
.ohp-highlights > div { padding:clamp(12px,2vw,20px); background:var(--sd-surface); border:1px solid var(--sd-border); border-radius:12px; }
.ohp-highlights strong { font-size:clamp(17px,2.3vw,26px); }
.ohp-art { display:grid; place-items:center; background:radial-gradient(ellipse,#20394d,#0a1322 74%); border-radius:10px; overflow:hidden; min-width:0; }
.ohp-art canvas { width:100%; max-width:108px; aspect-ratio:3/2; height:auto; object-fit:contain; }
.ohp-art-large { min-height:220px; }
.ohp-art-large canvas { max-width:360px; }
.ohp-selected-ship-art { position:relative; }
.ohp-ship-badge { position:absolute; inset-block-start:8px; inset-inline-end:8px; }
.ohp-tools,.ohp-inline { display:flex; flex-wrap:wrap; align-items:center; gap:8px; min-width:0; }
.ohp-button { min-height:44px; padding:8px 12px; border:1px solid #40536a; border-radius:8px; color:var(--sd-text); background:#152336; font:600 14px/1.4 var(--sd-font); cursor:pointer; }
.ohp-button:hover,.ohp-button[aria-pressed="true"] { border-color:var(--sd-cyan); background:#1a373c; color:var(--sd-cyan); }
.ohp-button:focus-visible,.oh-pilot :is(input,select,summary):focus-visible,.ohp-dialog button:focus-visible { outline:2px solid var(--sd-cyan); outline-offset:3px; }
.ohp-button.primary { background:var(--sd-cyan); color:#102b29; border-color:transparent; }
.ohp-button:disabled { opacity:.62; cursor:default; }
.ohp-row-button { text-align:left; }
.ohp-progress { width:100%; height:8px; accent-color:var(--sd-cyan); }
.ohp-card > div > .ohp-tools,.ohp-card > div > .ohp-stats { margin-bottom:12px; }
.ohp-mission { border-top:1px solid var(--sd-border); padding:8px 0; }
.ohp-mission summary { min-height:44px; cursor:pointer; display:flex; gap:10px 18px; flex-wrap:wrap; align-items:center; }
.ohp-mission summary::before { content:'+'; color:var(--sd-cyan); }
.ohp-mission[open] summary::before { content:'−'; }
.ohp-mission .ohp-stats { margin:12px 0; }
.ohp-loss,.ohp-kit { display:grid; gap:6px; }
.ohp-kit { grid-template-columns:64px minmax(0,1fr); align-items:center; }
.ohp-kit .ohp-stat:first-child { grid-column:1/-1; }
.ohp-dialog { position:fixed; inset:0; margin:auto; width:min(490px,calc(100% - 32px)); max-height:calc(100dvh - 32px); overflow:auto; border:1px solid #4d617b; border-radius:16px; padding:clamp(16px,4vw,28px); background:#142132; color:var(--sd-text); font:15px/1.55 var(--sd-font); }
.ohp-dialog[open] { display:grid; gap:14px; }
.ohp-dialog::backdrop { background:#030814ce; }
.ohp-empty { min-height:110px; justify-items:start; }
.ohp-icon { width:22px; height:22px; fill:none; stroke:currentColor; stroke-width:1.7; }
#overlayBoard.oh-pilot { background:transparent; }
.ohp-button.ohp-row-button { display:grid; grid-template-columns:auto minmax(0,1fr); align-items:center; gap:3px 10px; }
.ohp-row-button .ohp-icon { color:#e6cd9c; grid-row:span 2; }
.ohp-row-button p { grid-column:2; }
.ohp-progress { appearance:none; border:0; border-radius:6px; overflow:hidden; background:#354457; }
.ohp-progress::-webkit-progress-bar { background:#354457; }
.ohp-progress::-webkit-progress-value { background:var(--sd-cyan); border-radius:6px; }
.ohp-progress::-moz-progress-bar { background:var(--sd-cyan); }
.ohp-card.gold .ohp-progress::-webkit-progress-value { background:#e6cd9c; }
.ohp-card.gold .ohp-progress::-moz-progress-bar { background:#e6cd9c; }
.ohp-collection { display:grid; grid-template-columns:minmax(0,1.13fr) minmax(0,1fr); gap:22px; align-items:start; }
.ohp-collection-count { width:min(240px,100%); display:grid; gap:6px; }
.ohp-category-tabs { padding-bottom:14px; border-bottom:1px solid var(--sd-border); }
.ohp-select { display:none; }
.ohp-search,.ohp-select { min-height:44px; min-width:0; width:100%; padding:9px 12px; font:15px var(--sd-font); border:1px solid #40536a; border-radius:8px; background:#111f30; color:var(--sd-text); }
.ohp-collection-tools { display:grid; gap:10px; }
.ohp-items { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; }
.ohp-button.ohp-item { display:grid; gap:6px; align-content:start; text-align:left; overflow-wrap:anywhere; }
.ohp-item small { color:var(--sd-muted); font-size:13px; }
.ohp-item .ohp-art { min-height:84px; }
.ohp-inspector .ohp-art-large { min-height:clamp(170px,27vw,330px); position:relative; }
.ohp-art > .ohp-preview-ship { position:absolute; bottom:8%; left:35%; width:30%; background:transparent; aspect-ratio:3/2; }
.ohp-preview-ship > canvas { max-width:none; }
.ohp-preview-ship > .sd-classic-poster { transform:scale(1.4); }
[data-preview-kind="trail"] > .ohp-preview-ship { top:17%; bottom:auto; }
.ohp-preview-profile { align-content:center; padding:16px; }
.ohp-preview-dossier { display:grid; justify-items:center; text-align:center; gap:8px; overflow-wrap:anywhere; }
.ohp-acquisition { display:grid; gap:8px; padding:14px; border:1px solid var(--sd-border); border-radius:10px; background:#0d1726; }
.ohp-loadout { display:grid; grid-template-columns:repeat(auto-fit,minmax(min(100%,128px),1fr)); gap:8px; }
.ohp-loadout button { text-align:left; overflow-wrap:anywhere; }
.ohp-preview-play > canvas { animation:ohp-show-sample .48s ease-out; }
@keyframes ohp-show-sample { from { transform:translateY(8px); opacity:.55 } to { transform:none; opacity:1 } }
@media(prefers-reduced-motion:reduce){.ohp-preview-play > canvas{animation:none}}
@media(min-width:761px) and (min-height:850px){.ohp-inspector{position:sticky;top:12px}}
@media(max-width:760px){.ohp-collection{grid-template-columns:minmax(0,1fr)}.ohp-category-tabs{display:none}.ohp-select{display:block}.ohp-collection-count{margin-inline-start:0}}
.ohp-board-top { display:flex; justify-content:space-between; flex-wrap:wrap; align-items:center; gap:10px; padding-bottom:14px; border-bottom:1px solid var(--sd-border); }
.ohp-podium-region { display:grid; gap:10px; }
.ohp-podium-heading { display:grid; grid-template-columns:minmax(0,1fr) minmax(0,1fr); grid-template-areas:"title period"; align-items:baseline; gap:18px; }
.ohp-podium-heading h2 { grid-area:title; margin:0; }
.ohp-podium-heading .ohp-muted { grid-area:period; margin:0; text-align:right; overflow-wrap:anywhere; }
.ohp-podium {
  --ohp-podium-rise:36px;
  display:grid; grid-template-columns:minmax(0,1fr) minmax(0,1.2fr) minmax(0,1fr);
  grid-template-rows:var(--ohp-podium-rise) auto; column-gap:12px;
  width:100%; max-width:820px; justify-self:center;
}
.ohp-button.ohp-leader {
  grid-row:2; position:relative; min-width:0; min-height:156px;
  display:grid; grid-template-columns:minmax(0,1fr); justify-items:center; align-content:center;
  gap:6px; padding:12px; text-align:center; border-radius:12px; overflow-wrap:anywhere;
  border-color:color-mix(in srgb,var(--ohp-metal) 45%,var(--sd-border));
  background:linear-gradient(0deg,color-mix(in srgb,var(--ohp-metal) 35%,var(--sd-surface)) 4px,transparent 4px),
    linear-gradient(160deg,color-mix(in srgb,var(--ohp-metal) var(--ohp-metal-tint,10%),var(--sd-surface)),var(--sd-surface) 74%);
}
.ohp-leader[data-podium-slot="left"] { grid-column:1; }
.ohp-leader[data-podium-slot="right"] { grid-column:3; }
.ohp-button.ohp-leader[data-podium-slot="center"] { grid-column:2; grid-row:1 / 3; min-height:192px; --ohp-metal-tint:16%; }
.ohp-button.ohp-leader:hover { color:var(--sd-text); border-color:var(--ohp-metal); }
.ohp-rank-pilot { display:grid; gap:4px; min-width:0; }
.ohp-leader-name {
  display:-webkit-box; -webkit-box-orient:vertical; -webkit-line-clamp:2; overflow:hidden;
  max-width:100%; min-height:2.44em; font-size:16px; line-height:1.22;
}
.ohp-leader-score { max-width:100%; font-size:24px; line-height:1.15; font-variant-numeric:tabular-nums; color:var(--ohp-metal); }
.ohp-leader[data-podium-slot="center"] .ohp-leader-score { font-size:32px; }
.ohp-leader[data-podium-slot="center"] .ohp-rank-emblem { width:60px; height:60px; }
.ohp-leader .ohp-badge { position:absolute; inset:7px 7px auto auto; padding:2px 4px; font-size:11px; }
.ohp-rank-mark,.ohp-leader { --ohp-metal:var(--sd-muted); }
:is(.ohp-rank-mark,.ohp-leader)[data-rank="1"] { --ohp-metal:#f6dba4; }
:is(.ohp-rank-mark,.ohp-leader)[data-rank="2"] { --ohp-metal:#c8ddf1; }
:is(.ohp-rank-mark,.ohp-leader)[data-rank="3"] { --ohp-metal:#e4aa87; }
.ohp-rank-mark { display:inline-flex; align-items:center; justify-content:center; gap:4px; color:var(--ohp-metal); font-variant-numeric:tabular-nums; }
.ohp-leader .ohp-rank-mark { display:grid; justify-items:center; align-content:center; }
.ohp-rank-emblem { width:44px; height:44px; flex:none; fill:color-mix(in srgb,currentColor 12%,transparent); stroke:currentColor; stroke-width:1.4; stroke-linecap:square; stroke-linejoin:bevel; }
.ohp-rank-row .ohp-rank-emblem { width:26px; height:26px; }
.ohp-monogram { width:42px; height:42px; display:inline-grid; place-items:center; border-radius:9px; border:1px solid #50716f; color:var(--sd-cyan); background:#1b383e; font-weight:650; flex:none; }
.ohp-score-list { --ohp-rank-col:70px; margin-top:8px; }
.ohp-board-search { display:flex; flex-wrap:wrap; gap:8px; }
.ohp-board-search input { flex:1 1 200px; }
.ohp-rank-rows { display:grid; gap:6px; list-style:none; margin:0; padding:0; }
.ohp-rank-header,.ohp-button.ohp-rank-row { display:grid; grid-template-columns:var(--ohp-rank-col) minmax(0,1fr) auto; align-items:center; gap:10px; text-align:left; padding:8px 10px; }
.ohp-rank-header { color:var(--sd-muted); font-size:13px; border-bottom:1px solid var(--sd-border); }
.ohp-rank-header > :first-child { text-align:center; }
.ohp-button.ohp-rank-row { width:100%; border-color:#2d4053; overflow-wrap:anywhere; }
.ohp-rank-call { display:flex; align-items:center; gap:6px; flex-wrap:wrap; min-width:0; }
.ohp-rank-call > strong { min-width:0; }
.ohp-board-message:empty,.ohp-rank-rows:empty { display:none; }
.ohp-board-message:not(:empty) { display:grid; justify-items:start; gap:8px; }
.ohp-rank-row.me { border-color:#649a8e; background:#19323a; }
.ohp-rank-row > b { font-variant-numeric:tabular-nums; text-align:end; }
.ohs-settings-heading h1 { margin-bottom:0; }
body.oh-front-active :is(#sdNavRefresh,#sdNavAwardsInfo) { margin-inline-start:auto; }
.sd-shell-header #sdNavAwardsInfo { border-radius:50%; }
#sdNavRefresh[aria-busy="true"] { color:var(--sd-cyan); cursor:progress; }
@media (prefers-reduced-motion:no-preference) {
  #sdNavRefresh[aria-busy="true"] svg { animation:oh-board-refresh .9s linear infinite; }
}
@keyframes oh-board-refresh { to { transform:rotate(1turn); } }
.ohp-select {
  appearance:none;
  padding-inline-end:38px;
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23a6b6ca' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat:no-repeat;
  background-position:right 14px center;
  background-size:18px;
}
.ohp-badge.ohp-price,.ohp-item small.ohp-price,.ohp-button.ohp-buy-price {
  color:#e6cd9c;
  background:#28241f;
  border:1px solid #8e7045;
}
.ohp-item small.ohp-price { width:fit-content; max-width:100%; padding:3px 7px; border-radius:6px; }
.ohp-button.ohp-buy-price:hover { background:#352c22; border-color:#e6cd9c; }

/* Prefer the Telegram BackButton on mobile only when the shell has bound it. */
@media (max-width:599px), (max-width:767px) and (max-height:600px) and (pointer:coarse) {
  .oh-home .oh-hero-tagline { display:none; }
  .ohp-awards-layout { grid-template-columns:minmax(0,1fr); }
  .ohp-award-nav { display:none; }
  body.oh-native-back #sdShellHeader:is([data-view="profile"],[data-view="board"],[data-view="hangar"],[data-view="achievements"]) #sdNavBack:not([hidden]),
  body.oh-native-back .oh-settings .ohs-settings-back,
  body.oh-native-back .oh-modes .oh-back { display:none !important; }
  body.oh-native-back .oh-modes .oh-mode-heading { padding-top:20px; }
  .oh-modes {
    --oh-modes-inset: max(24px, calc(16px + max(var(--tg-safe-bottom,0px),env(safe-area-inset-bottom,0px))));
    padding-block-end:var(--oh-modes-inset);
    scroll-padding-block-end:var(--oh-modes-inset);
  }
}
@media (min-width:600px) and (max-width:767px) and (max-height:600px) and (pointer:coarse) {
  .oh-home .oh-home-hero { padding-block:12px; }
  .oh-home .oh-hero-art { height:250px; }
}
.ohp-awards-hero { grid-template-columns:repeat(2,minmax(0,1fr)); }
.ohp-awards-hero h2 { grid-column:1/-1; }
.ohp-awards-summary { display:grid; gap:9px; align-content:center; }
.ohp-awards-summary .ohp-record { color:#f0d6a6; }
.oh-pilot .ohp-medal { width:54px; height:54px; stroke:#edce91; fill:#43392c; stroke-width:1.5; }
.ohp-awards-layout { display:grid; grid-template-columns:minmax(185px,1fr) minmax(0,4fr); gap:16px; align-items:start; }
.ohp-award-nav h2 { font-size:18px; overflow-wrap:anywhere; }
.ohp-award-nav .ohp-tools { grid-template-columns:minmax(0,1fr); }
.ohp-award-tabs .ohp-tools { display:grid; }
.ohp-award-tabs button { text-align:left; }
.ohp-button.ohp-award { display:grid; align-content:start; gap:9px; min-width:0; text-align:left; padding:14px; background:#141f2f; overflow-wrap:anywhere; }
.ohp-award.earned { border-color:#6c5a42; }
.ohp-award > strong { font-size:17px; }
.ohp-award .ohp-icon,.ohp-award-reward { color:#e2ca9b; }
.ohp-award-reward { border-top:1px solid var(--sd-border); padding-top:8px; font-size:13px; }
.sd-dialog-heading { display:grid; grid-template-columns:minmax(0,1fr) auto; align-items:start; gap:12px; }
.sd-dialog-heading > h2 { align-self:center; min-width:0; overflow-wrap:anywhere; }
button.sd-close-circle {
  display:grid; place-items:center; flex:none; width:44px; height:44px; padding:0;
  border:1px solid #40536a; border-radius:50%; background:var(--sd-surface); color:var(--sd-text); cursor:pointer;
}
button.sd-close-circle svg { display:block; width:20px; height:20px; fill:none; stroke:currentColor; stroke-width:1.7; stroke-linecap:round; }
button.sd-close-circle:hover { color:var(--sd-cyan); border-color:var(--sd-cyan); }
button.sd-close-circle:focus-visible { outline:2px solid var(--sd-cyan); outline-offset:2px; }
.bundleModalCard:has(.sd-close-circle) :is(.bundleEyebrow,h3) { padding-right:44px; }
.ohp-meter { display:grid; gap:5px; }
@media(max-width:760px) {
  .ohp-awards-layout,.ohp-awards-hero { grid-template-columns:minmax(0,1fr); }
  .ohp-award-tabs .ohp-tools { display:flex; }
  .ohp-awards-layout .ohp-items { grid-template-columns:minmax(0,1fr); }
}
@media(max-width:780px){
  .ohp-podium-heading { grid-template-columns:minmax(0,1fr); grid-template-areas:"period" "title"; }
  .ohp-podium-heading h2 { text-align:center; }
  .ohp-podium-heading .ohp-muted { text-align:left; }
  .ohp-podium { --ohp-podium-rise:28px; column-gap:6px; }
  .ohp-button.ohp-leader { min-height:124px; gap:5px; padding:8px 5px; }
  .ohp-button.ohp-leader[data-podium-slot="center"] { min-height:152px; }
  .ohp-leader .ohp-rank-emblem { width:30px; height:30px; }
  .ohp-leader[data-podium-slot="center"] .ohp-rank-emblem { width:42px; height:42px; }
  .ohp-leader-name { font-size:clamp(12px,3.5vw,16px); }
  .ohp-leader-score { font-size:clamp(14px,4.2vw,23px); }
  .ohp-leader[data-podium-slot="center"] .ohp-leader-score { font-size:clamp(17px,4.9vw,28px); }
  .ohp-leader .ohp-badge { inset:4px 4px auto auto; font-size:10px; }
  .ohp-score-list { --ohp-rank-col:51px; }
  .ohp-board-search input { flex-basis:138px; }
  .ohp-button.ohp-rank-row,.ohp-rank-header { gap:6px; padding-inline:6px; }
}
@media(max-width:700px) {
  .oh-pilot { padding-top:18px; }
  #overlayProfile.oh-pilot { scroll-padding-top:112px; }
  .ohp-profile-hero,.ohp-split { grid-template-columns:minmax(0,1fr); }
  .ohp-highlights { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .ohp-art-large { min-height:160px; }
}

/* HUD layers do not participate in sizing the legacy playfield. */
.ohh-primary,.ohh-mode-tag,.ohh-rail,.ohh-fleet,.ohh-signal,.ohh-result-title,.ohh-result-detail,.ohh-retry { display:none; }
body.ohh-active { --ohh-accent:var(--sd-cyan); --ohh-number:#ffd83d; background:radial-gradient(ellipse at 50% 28%,#152d3c,#080d18 70%); }
body.ohh-active[data-hud-mode="operation"] { --ohh-accent:var(--sd-violet); }
body.ohh-active[data-hud-mode="pvp"] { --ohh-accent:var(--sd-pink); }
.ohh-active #wrap,.ohh-active #hud { position:relative; }
.ohh-active #hud > .hudItem { visibility:hidden; }
.ohh-active .ohh-mode-tag { position:absolute; inset:auto 0 calc(100% + 9px); display:block; text-align:center; color:var(--ohh-accent); font:700 13px/1.1 var(--sd-font); text-shadow:none; }
.ohh-active #hud .ohh-primary { position:absolute; inset:-3px 0 0; display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); align-items:center; gap:6px; color:var(--sd-text); text-shadow:none; letter-spacing:normal; }
.ohh-primary .ohh-stat { text-align:center; line-height:1.15; }
.ohh-stat { display:grid; gap:3px; font-family:var(--sd-font); min-width:0; overflow-wrap:anywhere; }
.ohh-stat > span { color:var(--sd-muted); font-size:12px; }
.ohh-primary .ohh-stat > span { font-size:10px; }
.ohh-stat > strong { color:var(--ohh-accent,var(--sd-cyan)); font-size:17px; font-variant-numeric:tabular-nums; }
.ohh-primary .ohh-stat > strong { font-size:15px; color:var(--ohh-number); }
.ohh-active #screen { border-color:#2e4456; box-shadow:0 8px 28px #04091499; }
.ohh-active[data-hud-state="gameover"] :is(#hud,#gameControls,.ohh-rail) { visibility:hidden; }
.ohh-active:not([data-hud-state="gameover"]) #gameControls { min-width:174px; }
.ohh-active:not([data-hud-state="gameover"]) #gameControls .roundControl { min-width:44px; min-height:44px; }
.ohh-active .arcadeBtn:focus-visible,.ohh-retry:focus-visible,.ohh-confirm button:focus-visible { outline:2px solid var(--ohh-accent,var(--sd-cyan)); outline-offset:2px; }
.ohh-active #gameControls :is(.ohh-fleet,.ohh-signal) { position:absolute; display:block; top:50%; transform:translateY(-50%); width:max(0px,calc((100% - 156px)/2)); color:var(--sd-muted); text-align:center; pointer-events:none; font:600 11px/1.25 var(--sd-font); overflow-wrap:anywhere; }
.ohh-fleet { left:50px; }
.ohh-active #gameControls .ohh-fleet { width:1px; height:1px; margin:-1px; padding:0; overflow:hidden; clip-path:inset(50%); white-space:nowrap; }
.ohh-signal { right:50px; }
.ohh-active #pvpBattleHud { background:#211b2e; border-color:#69455f; color:#f5c3d8; text-shadow:none; }
.ohh-active :is(#overlayPause,#overlayOver) { justify-content:safe center; align-content:safe center; overflow-y:auto; padding:16px; color:var(--sd-text); font:15px/1.45 var(--sd-font); background:#0b1523; }
.ohh-active :is(#pauseTitle,.ohh-result-title) { font:700 clamp(21px,5vw,32px)/1.2 var(--sd-font); color:var(--sd-text); text-shadow:none; margin:0; }
.ohh-active #pauseSummary,.ohh-active #pauseSaveStatus { font:14px/1.45 var(--sd-font); color:var(--sd-muted); letter-spacing:normal; }
.ohh-active #pauseSummary,.ohh-active #pauseSaveStatus { font-size:14px!important; line-height:1.45!important; color:var(--sd-muted)!important; }
.ohh-active #pauseSaveStatus.error { color:#ffd0cd; }
.ohh-active .arcadeBtn,.ohh-active .ohh-retry,.ohh-confirm button { min-height:44px; padding:8px 10px; border-radius:8px; border:1px solid #41536b; color:var(--sd-text); background:#17283b; box-shadow:none; text-shadow:none; font:600 14px/1.35 var(--sd-font); cursor:pointer; }
.ohh-active .arcadeBtn.primary { background:var(--ohh-accent); color:#101825; border-color:transparent; }
.ohh-active .arcadeBtn:disabled { opacity:.6; }
.ohh-active #overlayOver > :is(#gameOverTitle,#finalScore,#runStats,#saveStatus,#newRecord) { display:none!important; }
.ohh-active :is(.ohh-result-title,.ohh-result-detail,.ohh-retry:not([hidden])) { display:block; }
.ohh-result-detail { width:100%; max-width:450px; }
.ohh-result-fleet { display:flex; align-items:center; justify-content:center; gap:10px; margin:4px 0 8px; font:600 14px/1.4 var(--sd-font); }
.ohh-result-ship { position:relative; width:88px; height:60px; flex:none; overflow:hidden; }
.ohh-result-ship > canvas { display:block; width:100%; height:100%; }
.ohh-result-status,.ohh-note { color:var(--sd-muted); font:14px/1.45 var(--sd-font); }
.ohh-active #overlayOver :is(.ohh-result-status,.ohh-note,.ohh-rewards) { font:13px/1.4 var(--sd-font); }
.ohh-result-status.saved { color:var(--sd-cyan); }
.ohh-result-status.failed,.ohh-result-status.rejected { color:#ffd0cd; }
.ohh-final { display:block; color:var(--ohh-accent); font:700 clamp(25px,7vw,45px)/1.35 var(--sd-font); }
.ohh-stats { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; margin:8px 0; }
.ohh-stats .ohh-stat { border:1px solid #314258; border-radius:8px; padding:7px; background:#111e2e; }
.ohh-rewards { color:var(--sd-cyan); }
.ohh-confirm { position:fixed; inset:0; margin:auto; width:min(420px,calc(100% - 32px)); max-height:calc(100dvh - 32px); overflow:auto; border:1px solid #4e6179; border-radius:14px; padding:18px; background:#132033; color:var(--sd-text); font:15px/1.5 var(--sd-font); }
.ohh-confirm[open] { display:grid; gap:12px; }
.ohh-confirm h2 { color:var(--sd-text); font:700 22px/1.3 var(--sd-font); text-shadow:none; }
.ohh-confirm::backdrop { background:#030814c9; }
.ohh-confirm-actions { display:flex; flex-wrap:wrap; gap:8px; }
.ohh-confirm.ohh-confirm-duel { text-align:center; }
.ohh-confirm-duel :is(h2,p) { text-align:center; overflow-wrap:anywhere; }
.ohh-confirm-duel .ohh-confirm-actions { justify-content:center; }
.ohh-confirm-duel .ohh-confirm-actions button { max-width:100%; overflow-wrap:anywhere; }
body[data-hud-mode="operation"] .ohh-confirm-actions { justify-content:center; }

/* Desktop settings: heading and section links on the left, controls begin at the same top edge. */
@media (min-width:701px) {
  #overlaySettings:not([hidden]) {
    display:grid;
    grid-template-columns: minmax(170px,210px) minmax(0,1fr);
    grid-template-rows:auto 1fr;
    align-items:start;
    column-gap:clamp(24px,3vw,36px);
    padding-block-start:26px;
  }
  #overlaySettings .ohs-settings-layout { display:contents; }
  #overlaySettings .ohs-settings-heading { grid-area:1 / 1; padding:0 0 24px; }
  #overlaySettings .ohs-settings-aside { grid-area:2 / 1; }
  #overlaySettings .ohs-settings-sections { grid-area:1 / 2 / 3 / 3; }
  #overlaySettings .ohs-settings-heading h1 { font-size:clamp(28px,3.2vw,36px); }
}

/* Existing admin controls in the standard shell; IDs, visibility and handlers stay intact. */
body.sd-shell-menu:has(#overlayAdmin:not([hidden])) #sdStageNote { display:none !important; }
body.sd-shell-menu #wrap.adminMenuActive { width:min(100%,1184px); padding:0; }
body.sd-shell-menu #wrap.adminMenuActive #screen { border:0; box-shadow:none; }
body.sd-shell-menu #wrap.adminMenuActive :is(#game,.crt) { visibility:hidden; }
body.sd-shell-menu #overlayAdmin:not([hidden]) {
  display:block;
  overflow:auto;
  overscroll-behavior:contain;
  scrollbar-color:#395366 transparent;
  padding:clamp(16px,2vw,24px) clamp(4px,3vw,40px) max(28px,var(--tg-safe-bottom,0px));
  text-align:left;
  background:var(--sd-bg);
  color:var(--sd-text);
  font:14px/1.55 var(--sd-font);
}
body.sd-shell-menu #overlayAdmin > .panelBack { display:none; }
.sd-shell-header[data-view="admin"] .sd-shell-location { flex-basis:auto; margin-inline-start:auto; }
body.sd-shell-menu #overlayAdmin > .sd-admin-intro {
  font:14px/1.5 var(--sd-font); color:var(--sd-muted); margin:0 0 16px; text-align:left;
}
body.sd-shell-menu #overlayAdmin .adminContent { overflow:visible; padding:0; gap:16px; }
body.sd-shell-menu #overlayAdmin .adminTabs { flex-wrap:wrap; overflow:visible; gap:8px; padding:0 0 12px; border-bottom:1px solid var(--sd-border); }
body.sd-shell-menu #overlayAdmin :is(.adminTabs button,.adminAction,.arcadeBtn) {
  width:auto; min-height:44px; padding:8px 14px; border:1px solid #40536a; border-radius:8px;
  background:#152336; color:var(--sd-text); text-shadow:none; box-shadow:none; font:600 14px/1.35 var(--sd-font);
}
body.sd-shell-menu #overlayAdmin #adminRefresh { align-self:start; }
body.sd-shell-menu #overlayAdmin :is(.adminTabs button.active,.adminTabs button:hover,.adminAction:hover,.arcadeBtn:hover) {
  border-color:var(--sd-cyan); color:var(--sd-cyan); background:#1a373c;
}
body.sd-shell-menu #overlayAdmin :is(.adminAction,.arcadeBtn).danger { border-color:#ad647c; color:#ffd7df; background:#46273a; }
body.sd-shell-menu #overlayAdmin :is(button,input,textarea,select):focus-visible { outline:2px solid var(--sd-cyan); outline-offset:2px; }
body.sd-shell-menu #overlayAdmin :is(.adminPanel,.adminList,.adminSummary,.adminPayments) { gap:12px; min-width:0; }
body.sd-shell-menu #overlayAdmin .adminSummary { grid-template-columns:repeat(3,minmax(0,1fr)); }
body.sd-shell-menu #overlayAdmin :is(.statCard,.adminListItem,.adminPlayerDetail,.adminGrantForm,.adminPayment,.adminPlayerLoadout) {
  border:1px solid var(--sd-border); border-radius:12px; background:var(--sd-surface);
  padding:14px; color:var(--sd-muted); font:14px/1.5 var(--sd-font); overflow-wrap:anywhere;
}
body.sd-shell-menu #overlayAdmin .adminListItem.ok { border-color:#417c75; }
body.sd-shell-menu #overlayAdmin :is(.adminListItem.warn,.adminPayment.attention) { border-color:#ad647c; }
body.sd-shell-menu #overlayAdmin :is(.statCard,.adminListItem,.adminPlayerDetail,.adminPayment) strong {
  color:var(--sd-text); font:650 16px/1.4 var(--sd-font);
}
body.sd-shell-menu #overlayAdmin .statCard strong { font-size:22px; }
body.sd-shell-menu #overlayAdmin :is(.statCard span,.adminPayment span,.adminGrantForm label,.adminHint,.adminGrantResult) {
  color:var(--sd-muted); font:14px/1.5 var(--sd-font);
}
body.sd-shell-menu #overlayAdmin :is(.adminSectionTitle,.adminGrantForm h3) { color:var(--sd-text); font:650 17px/1.35 var(--sd-font); }
body.sd-shell-menu #overlayAdmin :is(input,select,textarea) {
  min-width:0; min-height:44px; border:1px solid #40536a; border-radius:8px;
  background:#111f30; color:var(--sd-text); font:15px/1.5 var(--sd-font);
}
@media (max-width:599px) {
  body.sd-shell-menu #overlayAdmin .adminSummary { grid-template-columns:repeat(2,minmax(0,1fr)); }
  body.sd-shell-menu #overlayAdmin .adminActions { grid-template-columns:minmax(0,1fr); }
}

/* Only the secondary Home links: preserve their grid, gutters and icon alignment. */
.oh-home-nav button { min-height:82px; padding-block:16px; }
@media (max-width:950px) { .oh-home-nav button { min-height:74px; } }
@media (max-width:599px) { .oh-home-nav button { min-height:58px; padding-block:10px; } }
@media (max-width:599px) and (max-height:740px) { .oh-home-nav button { min-height:54px; } }
@media (min-width:600px) and (max-height:600px) and (orientation:landscape) {
  .oh-home-nav button { min-height:55px; padding-block:10px; }
}
.ohh-confirm .ohh-danger { color:#ffd7df; border-color:#ad647c; background:#46273a; }
@media (min-width:1040px) {
  .ohh-active .ohh-rail { position:absolute; top:62px; display:grid; gap:8px; width:min(220px,calc((100vw - var(--playfield-width) - 90px)/2)); padding:14px; border:1px solid #314258; border-radius:12px; color:var(--sd-text); background:#111e2e; font:14px/1.45 var(--sd-font); overflow-wrap:anywhere; }
  .ohh-active #gameControls .ohh-fleet { display:none; }
  .ohh-left { right:100%; margin-right:8px; }.ohh-right { left:100%; margin-left:8px; }
  .ohh-eyebrow { color:var(--ohh-accent); font-size:11px; }.ohh-rail-copy { color:var(--sd-muted); }
}
@media (max-height:510px) {
  .ohh-active .ohh-mode-tag { display:none; }
  .ohh-active :is(#overlayPause,#overlayOver) { justify-content:safe start; padding:10px; gap:8px; }
  .ohh-active :is(.pauseActions,.gameOverActions) { display:flex; flex-wrap:wrap; }
}
