
    * { box-sizing: border-box; margin: 0; padding: 0; -webkit-tap-highlight-color: transparent; }
    html { touch-action: pan-x pan-y; -ms-touch-action: pan-x pan-y; overscroll-behavior: none; }
    body { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; background-color: #010409; color: #e2e8f0; display: flex; flex-direction: column; height: 100vh; height: 100dvh; overflow: hidden; touch-action: pan-x pan-y; overscroll-behavior: none; }
    /* 지구본/상세지도 뷰포트 자체는 핀치줌을 완전히 막고 앱이 직접 제스처를 처리 */
    #viewport-container { touch-action: none; }

    header { display: none; } /* [CHANGE] 웹에서도 항상 숨김 */
    .badge-count { font-size: 11px; background: #0369a1; color: #f0f9ff; padding: 2px 7px; border-radius: 10px; }

    main { flex: 1; min-height: 0; display: flex; flex-direction: column; position: relative; overflow: hidden; }
    #viewport-container { flex: 6; min-height: 0; position: relative; background: url('bg/SuhwanMilkyway.jpg') center/cover; overflow: hidden; }

    /* [CHANGE] "로딩 중에도 분할모드 유지, BIOS 텍스트는 그래프 영역 안에"
       요청 반영 - 더 이상 로딩 중 차트 패널을 숨기지 않습니다. 대신 그
       영역 안에 터미널 오버레이를 덮어서 보여줍니다. */

    /* [ADD] BIOS 부팅 화면 - 허큘레스 그래픽 카드 스타일(호박색 모노크롬 CRT).
       진행바는 지구본 위에, 터미널 텍스트는 그래프 패널 안에 각각 뜹니다. */
    #boot-screen {
      position: absolute; inset: 0; z-index: 300;
      pointer-events: none;
      font-family: 'Courier New', Courier, monospace;
    }
    #boot-screen::before {
      content: ''; position: absolute; inset: 0; pointer-events: none;
      background: repeating-linear-gradient(to bottom, rgba(0,0,0,0) 0px, rgba(0,0,0,0) 2px, rgba(0,0,0,0.18) 3px);
      mix-blend-mode: multiply;
    }
    #boot-progress-wrap {
      position: absolute; top: 50%; left: 50%; transform: translate(-50%, 46px);
      width: min(78%, 360px); text-align: center;
    }
    #boot-progress-bar {
      width: 100%; height: 10px; border: 1.5px solid #ffb000; border-radius: 2px;
      background: rgba(255,176,0,0.08); overflow: hidden;
      box-shadow: 0 0 8px rgba(255,176,0,0.5);
    }
    #boot-progress-fill {
      height: 100%; width: 2%; background: #ffb000;
      box-shadow: 0 0 10px #ffb000, 0 0 4px #fff5da inset;
      transition: width 0.25s ease;
    }
    #boot-progress-label {
      margin-top: 6px; font-size: 10.5px; letter-spacing: 0.06em; color: #ffb000;
      text-shadow: 0 0 6px rgba(255,176,0,0.8);
    }
    #boot-screen.boot-done { opacity: 0; transition: opacity 0.7s ease; }

    /* [CHANGE] 터미널은 #boot-screen이 아니라 #bottom-sheet 안에서 그래프
       영역을 대신 채우는 오버레이로 표시합니다. */
    #boot-terminal { display: none; }
    body.booting #boot-terminal {
      display: block; position: absolute; inset: 0; z-index: 70;
      margin: 0; padding: 14px 16px; overflow: hidden;
      background: #050400; font-size: 11px; line-height: 1.65;
      font-family: 'Courier New', Courier, monospace;
    }
    .boot-line {
      color: #ffb000; text-shadow: 0 0 5px rgba(255,176,0,0.85);
      white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
      animation: boot-line-in 0.18s ease-out;
    }
    @keyframes boot-line-in { from { opacity: 0; transform: translateY(3px); } to { opacity: 1; transform: translateY(0); } }

    /* 레이어 1: 3D 위성 지구공 */
    #globe-canvas-container { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 10; cursor: grab; transition: opacity 0.3s ease; }
    #globe-canvas-container:active { cursor: grabbing; }

    /* 레이어 2: 평면 고해상도 위성 지도 */
    #leafletMap { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 5; opacity: 0; pointer-events: none; transition: opacity 0.3s ease; }
    #leafletMap.active { opacity: 1; pointer-events: auto; z-index: 15; }

    /* HUD */
    .hud-overlay {
      position: absolute; top: 12px; right: 12px;
      background: rgba(11, 19, 41, 0.4); border: 1px solid rgba(51,65,85,.5);
      border-radius: 8px; padding: 8px 12px; font-size: 10.5px;
      pointer-events: none; backdrop-filter: blur(4px); z-index: 50;
      box-shadow: 0 4px 15px rgba(0,0,0,0.4);
    }
    .color-legend { display: flex; align-items: center; gap: 5px; }
    .legend-bar { width: 120px; height: 7px; border-radius: 3px; background: linear-gradient(to right, #f1f5f9, #bfdbfe, #60a5fa, #2563eb, #1d4ed8, #1e40af, #0e7490, #0d9488, #10b981, #84cc16, #facc15, #f59e0b, #f97316, #dc2626, #991b1b); }
    .legend-item { display: flex; align-items: center; gap: 5px; margin-top: 4px; }
    .dot-beach { width: 8px; height: 8px; border-radius: 50%; background: #38bdf8; border: 1.5px solid #fff; }

    /* [ADD] 모바일에서는 지구본:그래프 비율을 60:40으로 (헤더는 위에서 이미 항상 숨김) */
    /* [CHANGE] 기본 비율(60:40)로 이미 통일해서 모바일 전용 오버라이드는 불필요 */

    /* 컨트롤 - HUD가 같은 오른쪽으로 옮겨져서 그 아래로 내렸습니다 */
    .map-controls {
      position: absolute; top: 92px; right: 12px;
      display: flex; flex-direction: column; align-items: center; gap: 6px; z-index: 50;
    }
    .ctrl-btn {
      width: 34px; height: 34px; background: #111d3d; border: 1px solid #334155;
      color: #f8fafc; border-radius: 6px; font-size: 15px; font-weight: bold;
      cursor: pointer; display: flex; align-items: center; justify-content: center;
      box-shadow: 0 2px 8px rgba(0,0,0,0.5);
    }

    /* [ADD] "정점이 많아졌으니 검색으로 바로 찾기" 요청 반영 - HUD 검색 패널.
       부팅 중엔 아래 부팅 위젯 쪽 검색을 쓰므로 돋보기 버튼은 숨겨둡니다. */
    /* [FIX] "로딩화면에 돋보기가 없다가 끝나면 생김" - 부팅 중 숨기던 규칙을
       없애서 처음부터 계속 떠 있게 했습니다. */
    .search-panel {
      display: none;
      position: absolute; top: 92px; right: 56px; z-index: 55;
      width: 240px; max-width: 58vw;
    }
    .search-panel.open { display: block; }
    .search-input {
      width: 100%; box-sizing: border-box;
      padding: 8px 10px; border-radius: 8px;
      border: 1px solid #334155; background: #0b1329; color: #e2e8f0; font-size: 13px;
    }
    .search-input:focus { outline: none; border-color: #38bdf8; }
    .search-results {
      display: none; margin-top: 4px;
      background: #0b1329; border: 1px solid #334155; border-radius: 8px;
      max-height: 260px; overflow-y: auto; box-shadow: 0 4px 16px rgba(0,0,0,0.6);
    }
    .search-result-item {
      padding: 8px 10px; cursor: pointer;
      display: flex; flex-direction: column; gap: 1px;
      border-bottom: 1px solid #1e293b;
    }
    .search-result-item:last-child { border-bottom: none; }
    .search-result-item:hover { background: #172033; }
    .sr-name { color: #e2e8f0; font-size: 13px; font-weight: 600; }
    .sr-sub { color: #64748b; font-size: 10.5px; }

    /* [ADD] "로딩 중 위치 공유 안 한 사용자에게 내 위치/검색/대륙 선택" 요청
       반영 - 부팅 화면 위에 뜨는 위치 선택 위젯. 뭔가 선택되면(또는 자동
       위치 감지가 성공하면) 페이드아웃됩니다. */
    #boot-location-widget {
      position: absolute; left: 50%; bottom: 12%; transform: translateX(-50%);
      width: min(86%, 320px); z-index: 250;
      display: flex; flex-direction: column; gap: 8px;
      opacity: 1; transition: opacity 0.5s ease;
      font-family: 'Courier New', Courier, monospace;
    }
    #boot-location-widget.hide { opacity: 0; pointer-events: none; }
    .boot-widget-btn {
      padding: 10px 14px; border-radius: 10px; border: 1px solid #334155;
      background: rgba(11,19,41,0.85); color: #e2e8f0; font-size: 13px; font-weight: 600;
      cursor: pointer; font-family: inherit;
      display: flex; align-items: center; justify-content: center; gap: 8px;
    }
    .boot-search-wrap .search-input {
      background: rgba(5,4,0,0.6); border: 1px solid rgba(255,176,0,0.5);
      color: #ffb000; font-family: inherit;
    }
    .boot-search-wrap .search-results {
      background: rgba(5,4,0,0.9); border: 1px solid rgba(255,176,0,0.4);
    }
    .boot-search-wrap .sr-name { color: #ffd88a; }
    .boot-search-wrap .sr-sub { color: rgba(255,176,0,0.5); }
    .boot-search-wrap.applied { display: none; }
    .continent-chips { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; }
    .chip-btn {
      padding: 6px 10px; border-radius: 999px; border: 1px solid rgba(255,176,0,0.5);
      background: rgba(5,4,0,0.5); color: #ffb000; font-size: 11.5px; cursor: pointer;
      font-family: inherit;
    }
    .chip-btn.active {
      background: #ffb000; color: #050400; font-weight: 700;
      box-shadow: 0 0 10px rgba(255,176,0,0.7);
    }
    .ctrl-btn:active { background: #38bdf8; color: #000; }

    .zoom-slider-wrap {
      width: 22px; height: 90px;
      background: rgba(17, 29, 61, 0.85); border: 1px solid #334155;
      border-radius: 12px; position: relative; display: flex;
      flex-direction: column; align-items: center; padding: 6px 0;
      backdrop-filter: blur(4px);
    }
    .zoom-track { width: 4px; height: 100%; background: #1e293b; border-radius: 2px; position: relative; }
    .zoom-fill { position: absolute; bottom: 0; left: 0; width: 100%; background: #38bdf8; border-radius: 2px; }
    .zoom-handle { position: absolute; left: 50%; width: 13px; height: 13px; background: #fff; border: 2px solid #0284c7; border-radius: 50%; transform: translate(-50%, 50%); }

    /* [FIX] "모바일 세로모드에서 °C/°F 버튼이 안 보임" - 원인을 찾았어요.
       버튼 6개 전부 쌓으면 top:92px에서 시작해 약 382px까지 내려가는데,
       짧은 화면(iPhone SE급 등)에서는 지구본 영역(#viewport-container) 자체
       높이가 그보다 작아서 맨 아래(°C 버튼)가 overflow:hidden에 잘렸던
       거예요. 짧은/좁은 화면에서는 버튼을 더 작고 촘촘하게 배치합니다. */
    @media (max-width: 400px), (max-height: 700px) {
      .map-controls { gap: 3px; top: 74px; }
      .ctrl-btn { width: 27px; height: 27px; font-size: 12px; }
      .zoom-slider-wrap { height: 52px; }
      .search-panel { top: 74px; right: 50px; }
    }

    .disclaimer-bar {
      position: absolute; bottom: 4px; left: 10px; right: 10px;
      font-size: 8.5px; color: #cbd5e1; pointer-events: none; z-index: 50;
      text-align: left; line-height: 1.2; text-shadow: 0 1px 3px rgba(0,0,0,0.9);
    }

    /* 하단 패널 */
    /* [CHANGE] 패널은 내용 높이만큼만(고정) - 숨은 세로 스크롤 없이, 남는 높이는 지구본이 씁니다 */
    #bottom-sheet { flex: 0 0 auto; min-height: 0; overflow: hidden; position: relative; background: #0b1329; border-top: 1px solid #1e293b; border-radius: 14px 14px 0 0; padding: 10px 14px; display: flex; flex-direction: column; z-index: 60; box-shadow: 0 -4px 20px rgba(0,0,0,0.7); }
    .meta-row { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 2px; }
    .station-name { font-size: 19px; font-weight: 800; color: #f8fafc; max-width: 65%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; letter-spacing: -0.01em; }
    .temp-val { font-size: 16px; font-weight: 800; color: #38bdf8; text-align: right; }
    .station-sub { font-size: 10.5px; color: #94a3b8; margin-bottom: 5px; }
    .tab-bar { display: flex; gap: 6px; margin-bottom: 6px; }
    .tab-btn { flex: 1; padding: 4px; font-size: 10px; background: #111d3d; border: 1px solid #334155; color: #cbd5e1; border-radius: 5px; cursor: pointer; }
    .tab-btn.active { background: #0284c7; color: #fff; border-color: #38bdf8; }
    .chart-box { flex: 0 0 auto; height: 262px; position: relative; } /* [CHANGE] 실시간 현황 표 높이에 맞춘 고정 높이 - 세 버튼이 이 자리를 같이 씀 */
    .chart-legend-overlay {
      position: absolute; top: 2px; right: 2px; z-index: 5;
      display: flex; flex-direction: column; gap: 2px;
      background: rgba(11,19,41,0.6); border-radius: 5px; padding: 4px 7px;
      font-size: 8.5px; color: #cbd5e1; pointer-events: none;
    }
    .chart-legend-overlay .item { display: flex; align-items: center; gap: 4px; white-space: nowrap; }
    /* [ADD] 실시간 현황 표 (Windy 스타일, 3시간 간격) */
    .now-table { position: absolute; inset: 0; display: flex; flex-direction: column; font-size: 10px; }
    .nt-top { display: flex; align-items: center; gap: 6px; padding: 2px 0 4px; }
    .nt-status { flex: 1; min-width: 0; font-size: 10px; text-align: right; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
    .nt-nav { flex: 0 0 auto; background: #111d3d; border: 1px solid #334155; color: #cbd5e1; border-radius: 5px; font-size: 10px; padding: 2px 7px; cursor: pointer; }
    .nt-scroll { flex: 1; overflow-x: auto; overflow-y: hidden; -webkit-overflow-scrolling: touch; }
    .nt-inner { display: flex; min-width: max-content; }
    .nt-labels { position: sticky; left: 0; z-index: 3; background: #0f172a; flex: 0 0 58px; border-right: 1px solid #1e293b; }
    .nt-labels div { display: flex; align-items: center; color: #94a3b8; font-size: 9px; padding-left: 4px; }
    .nt-grid { position: relative; }
    .nt-row { display: flex; align-items: center; }
    .nt-cell { flex: 0 0 34px; width: 34px; height: 100%; display: flex; align-items: center; justify-content: center; }
    /* [CHANGE] "지금" 표시: 해당 3시간 칸 전체를 테두리로 강조 (가는 세로선은 뺐어요) */
    .nt-band { position: absolute; top: 30px; bottom: 0; background: rgba(125,211,252,0.22); z-index: 1; pointer-events: none; }
    .nt-live { color: #4ade80; } .nt-est { color: #facc15; }
    .nt-note { font-size: 8.5px; color: #64748b; padding-top: 1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
    .station-foot { margin: 4px 0 0; font-size: 10px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
    .chart-legend-overlay .swatch { width: 9px; height: 2px; border-radius: 1px; flex-shrink: 0; }
    .chart-legend-overlay .swatch.dashed { background-image: linear-gradient(to right, currentColor 50%, transparent 50%); background-size: 4px 2px; background-color: transparent !important; }

    /* Leaflet 마커 라벨 */
    .lf-marker-wrap { display: flex; align-items: center; white-space: nowrap; cursor: pointer; }
    .lf-dot { width: 11px; height: 11px; border-radius: 50%; border: 1.5px solid rgba(255,255,255,.85); flex-shrink: 0; box-shadow: 0 0 4px rgba(0,0,0,0.6); transition: transform .15s ease; }
    .lf-dot.selected { transform: scale(1.6); border: 2.5px solid #f97316; box-shadow: 0 0 10px rgba(249,115,22,0.9); }
    .lf-dot.beach { width: 14px; height: 14px; border-width: 2px; }
    .lf-label {
      margin-left: 6px; padding: 2px 6px; font-size: 10.5px; font-weight: 600; color: #f8fafc;
      background: rgba(15, 23, 42, 0.72); border: 0.8px solid rgba(255, 255, 255, 0.4);
      border-radius: 4px; backdrop-filter: blur(3px); pointer-events: none;
      text-shadow: 0 1px 2px rgba(0,0,0,0.8);
    }
  
    /* [CHANGE] "가로모드도 지원하자" 요청 반영 - 예전엔 가로모드(세로 폭이
       좁은 모바일 화면)를 아예 막고 세로로 돌려달라고만 안내했는데, 이제는
       지구본을 전체화면으로 보여주고 그래프 패널을 우측 하단에 화면의
       40%×40% 크기 플로팅 창으로 띄웁니다. 세로 비율이 긴 화면(일반적인
       세로 모드, 그리고 창이 충분히 큰 데스크톱)은 지금처럼 위/아래로
       쌓인 레이아웃을 그대로 씁니다.
       max-height 기준은 일반 폰/작은 태블릿 가로모드를 겨냥한 것으로,
       데스크톱 창처럼 충분히 큰 화면에는 적용되지 않습니다. */
    .rotate-overlay { display: none !important; }
    /* [CHANGE] "세로형으로만 고정 제공" 요청 반영 - 예전의 "가로 화면이면
       지구본 60% + 패널 40% 좌우 배치"를 없애고, 어떤 화면이든 지구본 위 /
       패널 아래(세로형)로 통일했습니다. 휴대폰을 가로로 눕히면(높이 500px
       이하) 지구본이 거의 안 보이므로 "세로로 돌려주세요" 안내를 띄웁니다. */
    .rotate-overlay {
      position: fixed; inset: 0; z-index: 9999; background: #010409;
      flex-direction: column; align-items: center; justify-content: center; gap: 10px;
      padding: 24px; text-align: center; color: #e2e8f0;
    }
    .rotate-overlay .icon { font-size: 34px; }
    .rotate-overlay .msg { font-size: 13px; max-width: 420px; line-height: 1.5; }
    /* [CHANGE] "가로로 돌려도 세로 화면 그대로" - 안내 문구 대신 페이지를 돌려서
       세로 화면을 유지합니다(main.js applyForcedPortrait가 클래스를 붙임). */
    body.force-portrait-90, body.force-portrait-270 { position: fixed; top: 0; left: 0; transform-origin: top left; }
    body.force-portrait-90 { transform: rotate(-90deg) translateX(-100%); }
    body.force-portrait-270 { transform: rotate(90deg) translateY(-100%); }

    /* =====================================================================
       [CHANGE] "사이트 색을 단순하고 멋있게 - 포인트 색은 호박색(허큘레스
       모니터 / 부팅 터미널과 같은 #FFB000)" 요청 반영. 지구본 수온 색은
       그대로 두고, UI는 거의 흑백 다크 톤 + 포인트 색 하나로 정리했습니다.
       호박색 = 강조(선택·지금·실시간), 빨강 = 주의(강풍·높은 파도),
       파랑 = 물(조석).
       ===================================================================== */
    :root {
      --ui-bg: #070B14; --ui-bg-top: #0B1120;
      --ui-line: rgba(255,255,255,0.08); --ui-surface: rgba(255,255,255,0.04);
      --ui-text: rgba(255,255,255,0.9); /* [CHANGE] "흰색이 너무 강해 - 10% 투명하게" */ --ui-muted: #8A94A6; --ui-dim: #5B6474;
      --accent: #FFB000; --accent-rgb: 255,176,0;
    }
    #bottom-sheet { background: linear-gradient(180deg, var(--ui-bg-top) 0%, var(--ui-bg) 100%); border-top: 1px solid var(--ui-line); box-shadow: 0 -12px 40px rgba(0,0,0,0.6); }
    .tab-bar { background: var(--ui-surface); border: 1px solid var(--ui-line); border-radius: 10px; padding: 3px; gap: 2px; }
    .tab-btn { background: transparent; border: none; color: var(--ui-muted); font-weight: 600; border-radius: 7px; padding: 6px 4px; }
    .tab-btn.active { background: rgba(255,255,255,0.08); color: var(--ui-text); border-color: transparent; box-shadow: inset 0 -2px 0 var(--accent); }
    .ctrl-btn { background: rgba(7,11,20,0.55); border: 1px solid var(--ui-line); color: var(--ui-text); border-radius: 10px; backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); box-shadow: 0 4px 14px rgba(0,0,0,0.35); }
    .ctrl-btn:active { background: rgba(var(--accent-rgb),0.25); color: var(--ui-text); }
    .zoom-track { background: rgba(255,255,255,0.08); }
    .zoom-fill { background: var(--accent); }
    .zoom-handle { background: #fff; border-color: var(--accent); }
    .chart-legend-overlay { background: rgba(7,11,20,0.7); border: 1px solid var(--ui-line); color: #CBD5E1; }
    .nt-nav { background: transparent; border: 1px solid var(--ui-line); color: var(--ui-muted); border-radius: 999px; padding: 3px 10px; }
    .nt-nav:hover { color: var(--ui-text); }
    .nt-labels { background: var(--ui-bg); border-right: 1px solid var(--ui-line); }
    .nt-labels div { color: var(--ui-muted); }
    .nt-row { border-bottom: 1px solid rgba(255,255,255,0.04); }
    .nt-cell { font-variant-numeric: tabular-nums; }
    .nt-band { top: 18px; background: rgba(var(--accent-rgb),0.06); box-shadow: inset 1px 0 0 rgba(var(--accent-rgb),0.65), inset -1px 0 0 rgba(var(--accent-rgb),0.65); }
    .nt-live { color: var(--accent); }
    .nt-est { color: var(--ui-muted); font-style: italic; }
    .nt-status { color: var(--ui-muted); flex: 0 0 auto; }
    /* [CHANGE] "정점명 앞 이모티콘 빼고, 박스 없이 그냥 텍스트로 가운데" -
       표 맨 위에 평범한 제목 텍스트로 가운데 정렬합니다. */
    .nt-title { text-align: center; font-size: 15px; font-weight: 700; color: var(--ui-text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; letter-spacing: 0.01em; padding: 0 0 2px; }
    .nt-spacer { flex: 1; }
    .nt-note { color: #4B5565; }
    .station-foot { color: var(--ui-muted); }

    /* =====================================================================
       [CHANGE] 첨부 디자인 반영 (실시간 현황 표 v2)
       - 탭: 폴더 탭 모양(선택된 탭만 호박색 윤곽, 나머지는 글자 + 구분선)
       - 정점명 가운데 + 옆에 Live, 전날/다음날은 표 양옆 화살표
       - "지금" 칸은 좌우로 넘겨도 가장자리에 붙어 있음(sticky)
       - 높이 축소, 경고 문구 톤 다운
       ===================================================================== */
    .chart-box { height: 232px; }
    .tab-bar { background: transparent; border: none; border-bottom: 1px solid var(--accent); border-radius: 0; padding: 0; gap: 0; margin-bottom: 6px; }
    .tab-btn { position: relative; border: 1px solid transparent; border-bottom: none; border-radius: 10px 10px 0 0; padding: 7px 4px; margin-bottom: -1px; box-shadow: none; }
    .tab-btn + .tab-btn::before { content: ''; position: absolute; left: 0; top: 25%; bottom: 25%; width: 1px; background: var(--ui-line); }
    .tab-btn.active { background: var(--ui-bg-top); color: var(--ui-text); border-color: var(--accent); box-shadow: none; }
    .tab-btn.active::before, .tab-btn.active + .tab-btn::before { display: none; }

    .nt-head { display: flex; justify-content: center; align-items: baseline; gap: 10px; padding: 0 0 5px; min-width: 0; }
    .nt-head .nt-title { display: inline; font-size: 16px; padding: 0; min-width: 0; }
    .nt-head .nt-status { flex: 0 0 auto; font-size: 12px; text-align: left; overflow: visible; }
    .nt-retry { color: var(--accent); margin-left: 4px; }
    .nt-frame { flex: 1; min-height: 0; display: flex; border: 1px solid var(--ui-line); border-radius: 10px; overflow: hidden; }
    .nt-arrow { flex: 0 0 20px; background: transparent; border: none; color: var(--ui-muted); font-size: 9px; cursor: pointer; padding: 0; }
    .nt-arrow:hover { color: var(--ui-text); background: rgba(255,255,255,0.03); }
    .nt-arrow[data-dir="-1"] { border-right: 1px solid var(--ui-line); }
    .nt-arrow[data-dir="1"] { border-left: 1px solid var(--ui-line); }
    .nt-scroll { scrollbar-width: none; }
    .nt-scroll::-webkit-scrollbar { display: none; }
    .nt-nowcell { position: sticky; left: 58px; right: 0; z-index: 2; background: #0E1524; box-shadow: inset 1px 0 0 rgba(var(--accent-rgb),0.6), inset -1px 0 0 rgba(var(--accent-rgb),0.6); }
    .nt-tiderow { position: relative; align-items: stretch; }
    .nt-tidesvg { position: absolute; left: 0; top: 0; }
    .nt-tidenow { font-size: 9px; line-height: 1.25; color: #BAE6FD; text-align: center; background: #0E1524; }
    .nt-note { font-size: 8px; color: #3F4756; padding-top: 3px; }
    .station-foot { margin-top: 2px; font-size: 9.5px; }
    .disclaimer-bar { font-size: 7.5px; color: rgba(148,163,184,0.55); text-shadow: none; }
    .disclaimer-bar b { font-weight: 500; }

    /* [CHANGE] "버튼 위 빈 공간 빼서 지구본 공간 넓히기" - 패널 위쪽 여백과
       둥근 윗부분을 없애고, 탭이 패널 맨 위에 붙게 했어요. 탭 줄 뒤는 투명이라
       지구본 영역과 자연스럽게 이어집니다. */
    #bottom-sheet {
      padding-top: 0; border-radius: 0; border-top: none; box-shadow: none;
      background: linear-gradient(180deg, transparent 0, transparent 29px, var(--ui-bg-top) 29px, var(--ui-bg) 100%);
    }
    .tab-btn { background: var(--ui-bg-top); }
    /* [CHANGE] "선택된 탭 호박색 테두리는 중요한 값이 아니니 톤 다운" */
    .tab-bar { border-bottom-color: rgba(var(--accent-rgb),0.35); }
    .tab-btn.active { border-color: rgba(var(--accent-rgb),0.35); }
    /* [ADD] "지금" = 누르면 현재 시각으로 돌아가는 버튼 */
    .nt-nowbtn { background: none; border: none; padding: 0; color: var(--accent); font: inherit; font-weight: 700; cursor: pointer; text-decoration: underline dotted rgba(var(--accent-rgb),0.5); text-underline-offset: 2px; }
    .nt-nowbtn:hover { text-decoration-style: solid; }
    /* [FIX] "가로 라인이 빠졌어" - 탭 배경을 칠하면서 모든 탭이 아래 가로선을
       1px 덮고 있었어요. 선택된 탭만 가로선을 덮게(= 열린 폴더 모양) 고쳤습니다. */
    .tab-btn { margin-bottom: 0; }
    .tab-btn.active { margin-bottom: -1px; }

    /* [FIX] "검은 지구본 영역과 데이터 영역 사이 양쪽 끝에 선이 빠졌어" - 탭 아래
       가로선을 패널 좌우 여백까지 끝에서 끝으로 늘렸어요. */
    .tab-bar { margin-left: -14px; margin-right: -14px; padding: 0 14px; }
    /* [FIX] 모바일에서 ◀▶⬆ 글자가 이모지로 바뀌어 웹과 모양이 달랐어요 → SVG 아이콘으로 통일 */
    .nt-arrow svg, .nt-dir svg { display: block; margin: 0 auto; }

    /* ───────── [ADD] 시야(물 투명도) ───────── */
    /* 정점명 옆 게이지: 숫자 + 1~30m 로그 막대(옅은 띠 = 90일 통상 범위, 흰 눈금 = 오늘 추정) */
    .nt-head .nt-status { display: inline-flex; align-items: center; gap: 10px; }
    .nt-vis { display: inline-flex; align-items: center; gap: 5px; color: var(--ui-muted); white-space: nowrap; cursor: help; }
    .nt-vis svg { flex: 0 0 auto; }
    .nt-vis b { color: var(--ui-text); font-weight: 600; }
    .nt-vis-wait { opacity: 0.6; }
    .nt-vis-track { position: relative; display: inline-block; width: 46px; height: 4px; border-radius: 2px;
      background: linear-gradient(90deg, #6B7F5E 0%, #3E8E9E 40%, #38BDF8 100%); opacity: 0.55; }
    .nt-vis-band { position: absolute; top: -1px; bottom: -1px; border-radius: 3px; background: rgba(255,255,255,0.55); }
    .nt-vis-mark { position: absolute; top: -3px; width: 2px; height: 10px; margin-left: -1px; background: #fff; border-radius: 1px; box-shadow: 0 0 0 1.5px var(--ui-bg); }

    /* 90일 추이 위쪽: 수온·시야 / 시야 원인 전환 칩 + 계산식 요약 */
    .fc-top { position: absolute; left: 6px; top: 3px; right: 6px; z-index: 6; pointer-events: none; font-size: 10.5px; line-height: 1.35; color: var(--ui-muted); }
    .fc-row { display: flex; align-items: center; gap: 8px; min-width: 0; }
    .fc-chips { display: inline-flex; border: 1px solid rgba(255,255,255,0.12); border-radius: 10px; overflow: hidden; pointer-events: auto; flex: 0 0 auto; }
    .fc-chip { background: transparent; border: none; color: var(--ui-muted); font: inherit; font-size: 10px; padding: 2px 9px; cursor: pointer; }
    .fc-chip.on { background: rgba(56,189,248,0.18); color: #fff; }
    .fc-line { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
    .fc-line b { color: var(--ui-text); }
    .fc-line .vis-num { color: #38BDF8; }
    .fc-sub { padding: 2px 0 0 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

    /* 범례: 왼쪽은 어둡게, 오른쪽 끝으로 갈수록 완전히 투명 - 뒤의 오른쪽 축(시야 m)이 보이게 */
    .chart-legend-overlay { background: linear-gradient(90deg, rgba(7,11,20,0.78) 0%, rgba(7,11,20,0.78) 50%, rgba(7,11,20,0) 100%); border: none; padding-right: 26px; }
    .chart-legend-overlay .swatch.sq { width: 8px; height: 8px; border-radius: 1px; }
    .chart-legend-overlay .swatch.band { height: 6px; background: rgba(56,189,248,0.25); border-top: 1.5px dashed rgba(56,189,248,0.9); border-radius: 0; box-sizing: border-box; }

    /* [FIX] "버튼 옆 검은 여백은 투명하게" - 탭 줄 뒤(패널 위 29px)가 투명이어도 그 뒤에
       지구본이 없어서 검게 보였어요. 패널을 29px 위로 겹쳐 올려 그 자리에 지구본이
       보이게 하고, 빈 부분은 지구본 드래그가 되도록 클릭을 통과시킵니다. */
    /* [FIX] "버튼 아래 투명한 빈 공간 / 호박색 테두리가 안 보여" - 탭 줄 높이가 기기(글꼴)마다
       1~2px씩 달라서, 29px로 고정한 투명 구간과 어긋나 틈이 생겼어요. 탭 줄 높이를 29px로
       고정해 딱 맞추고, 지도/지구본 위에서도 보이도록 탭 테두리·가로선을 조금 진하게 했어요. */
    /* [FIX] "버튼들이 날아다녀 / 활성 테두리는 불투명하게, 채색은 낮춰서 뒤에 안 비치게" -
       반투명 호박색 대신 어두운 배경과 미리 섞은 '불투명한 낮은 채도 호박색'을 씁니다. */
    :root { --tab-line: #7A5A16; }
    .tab-bar { height: 29px; box-sizing: border-box; align-items: stretch; border-bottom: 1px solid var(--tab-line); }
    .tab-btn { height: 28px; box-sizing: border-box; padding-top: 0; padding-bottom: 0; display: flex; align-items: center; justify-content: center; }
    .tab-btn.active { height: 29px; border-color: var(--tab-line); background: var(--ui-bg-top); }
    #bottom-sheet { margin-top: -29px; pointer-events: none; }
    #bottom-sheet > * { pointer-events: auto; }
    #bottom-sheet > .tab-bar { pointer-events: none; }
    #bottom-sheet > .tab-bar .tab-btn { pointer-events: auto; }
    .disclaimer-bar { bottom: 33px; }

    /* [ADD] 국립해양조사원 실측 칸 표시: 숫자 아래 작은 하늘색 점 */
    .nt-obs { position: relative; }
    .nt-obs::after { content: ''; position: absolute; left: 50%; bottom: -4px; width: 3px; height: 3px; margin-left: -1.5px; border-radius: 50%; background: #38BDF8; }
    .nt-obsdot { display: inline-block; width: 4px; height: 4px; border-radius: 50%; background: #38BDF8; vertical-align: middle; margin-right: 2px; }

    /* [ADD] 상태 옆 데이터 출처(작게) */
    .nt-src { margin-left: 5px; font-size: 10px; color: var(--ui-muted); white-space: nowrap; }
    /* [ADD] 90일·수심 탭 머리줄(정점명) - 그래프 위에 겹쳐 두고 그래프·칩·범례를 그만큼 아래로 */
    .mode-head { position: absolute; left: 0; right: 0; top: 0; z-index: 7; background: transparent; }
    .chart-box.with-head .fc-top { top: 27px; }
    .chart-box.with-head .chart-legend-overlay { top: 26px; }
    /* [FIX] "정점명을 눌러도 선택" - 확대 지도의 이름표가 클릭을 통과시키고 있었어요 */
    .lf-label { pointer-events: auto; cursor: pointer; }

    /* [ADD] 후원 버튼: 다른 버튼과 같은 모양, 컵 아이콘만 호박색 */
    .ctrl-btn.donate-btn { display: flex; align-items: center; justify-content: center; color: var(--accent); text-decoration: none; }

    /* [ADD] 시야는 하늘색으로 통일: 게이지 숫자 + 출처 표기 */
    .nt-vis b { color: #7DD3FC; }
    .nt-src-vis { color: #7DD3FC; }
