/* koordinat.online - combined CSS (landing + tool) */
    :root {
      --bg: #f2f5f9;
      --surface: #ffffff;
      --surface-2: #f8fafc;
      --line: #e2e8f0;
      --text: #0f1f35;
      --muted: #5a6f85;
      --brand: #1d5fa8;
      --brand-light: #e8f0fb;
      --brand-mid: #3a7dd4;
      --accent: #0fb87a;
      --accent-light: #e6faf3;
      --warn: #c47f1a;
      --danger: #d04f4f;
      --shadow: 0 2px 8px rgba(15,31,53,0.07), 0 12px 32px rgba(15,31,53,0.06);
      --shadow-sm: 0 1px 4px rgba(15,31,53,0.06), 0 4px 12px rgba(15,31,53,0.05);
      --r: 16px;
      --r-lg: 24px;
      --max: 1280px;
    }
    [data-theme="dark"] {
      --bg: #080f1a;
      --surface: #0e1929;
      --surface-2: #0a1420;
      --line: rgba(255,255,255,0.08);
      --text: #e2eaf4;
      --muted: #6b88a8;
      --brand: #4a90d9;
      --brand-light: rgba(74,144,217,0.12);
      --brand-mid: #5fa3e8;
      --accent: #18d48e;
      --accent-light: rgba(24,212,142,0.1);
      --shadow: 0 2px 8px rgba(0,0,0,0.3), 0 12px 32px rgba(0,0,0,0.2);
      --shadow-sm: 0 1px 4px rgba(0,0,0,0.2), 0 4px 12px rgba(0,0,0,0.15);
    }

    *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
    html { scroll-behavior: smooth; }

    body {
      font-family: 'DM Sans', sans-serif;
      font-size: 15px;
      color: var(--text);
      background: var(--bg);
      line-height: 1.6;
      transition: background .25s, color .2s;
    }

    a { color: inherit; text-decoration: none; }
    .container { width: min(var(--max), calc(100% - 40px)); margin: 0 auto; }

    /* ── HEADER ── */
    .site-header {
      position: sticky; top: 0; z-index: 200;
      background: rgba(242,245,249,0.9);
      backdrop-filter: blur(16px);
      border-bottom: 1px solid var(--line);
      transition: background .25s;
    }
    [data-theme="dark"] .site-header { background: rgba(8,15,26,0.92); }
    .header-inner {
      display: flex; align-items: center; justify-content: space-between;
      gap: 16px; height: 64px;
    }
    .brand { display: flex; align-items: center; gap: 12px; }
    .brand-mark {
      width: 36px; height: 36px; border-radius: 10px; flex-shrink: 0;
      background: var(--brand);
      display: grid; place-items: center;
      color: white; font-weight: 900; font-size: 1rem;
      letter-spacing: -0.02em;
    }
    .brand-name { font-weight: 700; font-size: 1rem; letter-spacing: -0.02em; }
    .brand-name em { font-style: normal; color: var(--brand); }
    .header-right { display: flex; align-items: center; gap: 8px; }

    /* ── COUNTRY PICKER ── */
    .country-picker { position: relative; }
    .country-btn {
      display: flex; align-items: center; gap: 7px;
      background: var(--surface); border: 1px solid var(--line);
      border-radius: 999px; padding: 5px 12px 5px 10px;
      cursor: pointer; font: 700 0.82rem 'DM Sans', sans-serif;
      color: var(--text); transition: .15s;
    }
    .country-btn:hover { border-color: var(--brand); color: var(--brand); }
    .country-btn .flag { font-size: 1.15em; line-height: 1; }
    .country-btn svg { width: 12px; height: 12px; color: var(--muted); flex-shrink: 0; transition: transform .2s; }
    .country-picker.open .country-btn svg { transform: rotate(180deg); }

    .country-menu {
      position: absolute; top: calc(100% + 8px); right: 0;
      background: var(--surface); border: 1px solid var(--line);
      border-radius: 16px; box-shadow: var(--shadow);
      padding: 8px; min-width: 220px;
      opacity: 0; pointer-events: none; transform: translateY(-6px);
      transition: opacity .18s, transform .18s;
      z-index: 500;
    }
    .country-picker.open .country-menu { opacity: 1; pointer-events: all; transform: translateY(0); }

    .country-group-label {
      font-size: 0.72rem; font-weight: 700; letter-spacing: 0.08em;
      text-transform: uppercase; color: var(--muted);
      padding: 6px 10px 4px;
    }
    .country-menu hr { border: none; border-top: 1px solid var(--line); margin: 6px 0; }
    .country-item {
      display: flex; align-items: center; gap: 10px;
      padding: 8px 10px; border-radius: 10px;
      font-size: 0.88rem; font-weight: 500; color: var(--text);
      cursor: pointer; transition: background .12s;
      text-decoration: none;
    }
    .country-item:hover:not(.disabled) { background: var(--brand-light); color: var(--brand); }
    .country-item.active { background: var(--brand-light); color: var(--brand); }
    .country-item.disabled { color: var(--muted); cursor: default; }
    .country-item .ci-flag { font-size: 1.25em; line-height: 1; }
    .country-item .ci-name { flex: 1; }
    .ci-badge {
      font-size: 0.72rem; font-weight: 700; padding: 2px 8px;
      border-radius: 999px; white-space: nowrap;
    }
    .ci-badge.live { background: var(--accent-light); color: var(--accent); }
    .ci-badge.soon { background: var(--brand-light); color: var(--brand); }
    .ci-badge.later { background: var(--surface-2); color: var(--muted); border: 1px solid var(--line); }

    .theme-btn {
      width: 36px; height: 36px; border-radius: 999px;
      background: var(--surface); border: 1px solid var(--line);
      cursor: pointer; font-size: 16px;
      display: grid; place-items: center; color: var(--muted);
      transition: .15s; flex-shrink: 0;
    }
    .theme-btn:hover { color: var(--text); }

    .btn {
      display: inline-flex; align-items: center; gap: 7px;
      padding: 0 20px; height: 40px; border-radius: 999px;
      background: var(--brand); color: white;
      font: 700 0.9rem 'DM Sans', sans-serif;
      border: 0; cursor: pointer; white-space: nowrap;
      transition: .15s; letter-spacing: -0.01em;
    }
    .btn:hover { background: var(--brand-mid); transform: translateY(-1px); }
    .btn:disabled { opacity: .4; cursor: not-allowed; transform: none; }
    .btn-outline {
      display: inline-flex; align-items: center; gap: 7px;
      padding: 0 20px; height: 40px; border-radius: 999px;
      background: transparent; color: var(--brand);
      font: 700 0.9rem 'DM Sans', sans-serif;
      border: 1.5px solid var(--brand); cursor: pointer;
      transition: .15s; letter-spacing: -0.01em; white-space: nowrap;
    }
    .btn-outline:hover { background: var(--brand-light); }
    .btn-ghost {
      display: inline-flex; align-items: center; gap: 6px;
      padding: 0 14px; height: 38px; border-radius: 999px;
      background: transparent; color: var(--muted);
      font: 600 0.88rem 'DM Sans', sans-serif;
      border: 0; cursor: pointer; transition: .15s;
    }
    .btn-ghost:hover { color: var(--text); background: var(--surface); }

    /* ── HERO ── */
    .hero { padding: 64px 0 48px; }
    .hero-inner {
      display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center;
    }
    .hero-eyebrow {
      display: inline-flex; align-items: center; gap: 8px;
      font-size: 0.78rem; font-weight: 700; letter-spacing: 0.1em;
      text-transform: uppercase; color: var(--brand); margin-bottom: 20px;
    }
    .hero-eyebrow span { width: 6px; height: 6px; border-radius: 50%; background: var(--brand); display: block; }
    .hero h1 {
      font-size: clamp(2.4rem, 4vw, 3.6rem);
      font-weight: 900; letter-spacing: -0.05em;
      line-height: 1.0; margin-bottom: 20px;
    }
    .hero h1 .accent { color: var(--brand); }
    .hero-lead { font-size: 1.05rem; color: var(--muted); line-height: 1.75; margin-bottom: 28px; max-width: 480px; }
    .hero-actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
    .hero-meta {
      margin-top: 16px; font-size: 0.82rem; color: var(--muted);
      display: flex; align-items: center; gap: 6px;
    }
    .hero-meta::before { content: ''; display: block; width: 5px; height: 5px; border-radius: 50%; background: var(--accent); }

    /* ── HERO VISUAL v2 ── */
    .hero-visual { display: flex; flex-direction: column; gap: 0; }

    .steps-map-row {
      display: flex; gap: 20px; align-items: flex-start;
    }
    .steps-col {
      display: flex; flex-direction: column; gap: 10px; flex: 1;
    }

    .step-v2 {
      background: var(--surface); border: 1px solid var(--line);
      border-radius: 16px; padding: 16px 20px;
      display: flex; align-items: flex-start; gap: 14px;
      cursor: pointer; transition: all .2s;
    }
    .step-v2.active, .step-v2:hover {
      box-shadow: var(--shadow-sm); transform: translateX(3px);
    }
    .step-v2.s1.active, .step-v2.s1:hover { border-color: #d04f4f; }
    .step-v2.s2.active, .step-v2.s2:hover { border-color: #1d5fa8; }
    .step-v2.s3.active, .step-v2.s3:hover { border-color: #0fb87a; }

    .step-v2-num {
      width: 36px; height: 36px; border-radius: 50%;
      flex-shrink: 0; position: relative;
      display: flex; align-items: center; justify-content: center;
    }
    .step-v2-num::before {
      content: ''; position: absolute; inset: 0;
      border-radius: 50%; opacity: 0.22;
    }
    .step-v2-num::after {
      content: ''; position: absolute;
      inset: 6px; border-radius: 50%;
    }
    .step-v2-num-label {
      position: relative; z-index: 1;
      font-weight: 900; font-size: 0.88rem; font-family: 'DM Mono', monospace;
      line-height: 1; color: #fff;
    }
    .step-v2-num.n1::before { background: #d04f4f; }
    .step-v2-num.n1::after  { background: #d04f4f; }
    .step-v2-num.n2::before { background: #1d5fa8; }
    .step-v2-num.n2::after  { background: #1d5fa8; }
    .step-v2-num.n3::before { background: #0fb87a; }
    .step-v2-num.n3::after  { background: #0fb87a; }

    .step-connector { width: 1px; height: 10px; background: var(--line); margin-left: 18px; }
    .step-v2-body { flex: 1; min-width: 0; }
    .step-v2-body strong {
      display: block; font-weight: 700; font-size: 0.95rem;
      letter-spacing: -0.02em; margin-bottom: 4px;
    }
    .step-v2-body span { font-size: 0.86rem; color: var(--muted); line-height: 1.55; }

    /* ── Map thumbnail ── */
    .map-thumb {
      margin-top: 16px; width: 100%; height: 240px;
      border-radius: 16px; overflow: hidden;
      box-shadow: 0 4px 16px rgba(15,31,53,0.13), 0 1px 4px rgba(15,31,53,0.08);
      cursor: pointer; position: relative;
      transition: transform .2s, box-shadow .2s;
      background: #e8edf2;
    }
    .map-thumb:hover { transform: scale(1.01); box-shadow: 0 8px 28px rgba(15,31,53,0.18); }
    #mini-map { position: absolute; inset: 0; z-index: 1; }
    .map-thumb-overlay {
      position: absolute; inset: 0; z-index: 5;
      background: linear-gradient(135deg, rgba(29,95,168,0.18) 0%, rgba(15,184,122,0.10) 100%);
      display: flex; flex-direction: column;
      align-items: center; justify-content: center; gap: 8px;
      transition: background .25s, opacity .2s;
    }
    .map-thumb:hover .map-thumb-overlay {
      background: linear-gradient(135deg, rgba(29,95,168,0.32) 0%, rgba(15,184,122,0.20) 100%);
    }
    .hero-visual:has(.step-v2.active) .map-thumb-overlay {
      opacity: 0; pointer-events: none;
    }
    .map-thumb-label {
      color: white; font-weight: 700; font-size: 0.9rem;
      text-shadow: 0 1px 4px rgba(0,0,0,0.3);
      display: flex; align-items: center; gap: 7px;
    }
    .map-thumb-label .play-icon {
      width: 26px; height: 26px; border-radius: 50%;
      background: rgba(255,255,255,0.25); border: 1.5px solid rgba(255,255,255,0.6);
      display: grid; place-items: center; font-size: 0.75rem; flex-shrink: 0;
    }
    .map-thumb-sub { color: rgba(255,255,255,0.8); font-size: 0.76rem; font-weight: 500; }

    /* ── Animated dots ── */
    @keyframes dot-pop {
      0%   { transform: scale(0) translate(-50%,-50%); opacity: 0; }
      65%  { transform: scale(1.35) translate(-37%,-37%); opacity: 1; }
      100% { transform: scale(1) translate(-50%,-50%); opacity: 1; }
    }
    @keyframes dot-ring {
      0%   { box-shadow: 0 0 0 0 rgba(208,79,79,.55); }
      70%  { box-shadow: 0 0 0 7px rgba(208,79,79,0); }
      100% { box-shadow: 0 0 0 0 rgba(208,79,79,0); }
    }
    .survey-dot {
      width: 10px; height: 10px; background: #d04f4f;
      border: 2px solid #fff; border-radius: 50%;
      position: absolute; top: 0; left: 0; transform: translate(-50%,-50%);
      animation: dot-pop .4s cubic-bezier(.34,1.56,.64,1) both,
                 dot-ring 1.4s ease-out .4s infinite;
    }
    .dot-cluster { width: 32px; height: 32px; border-radius: 50%;
      background: rgba(208,79,79,.25); display: flex; align-items: center;
      justify-content: center; position: absolute; top: 0; left: 0;
      transform: translate(-50%,-50%);
      animation: dot-pop .35s cubic-bezier(.34,1.56,.64,1) both; }
    .dot-cluster-inner { width: 22px; height: 22px; border-radius: 50%;
      background: #d04f4f; color: #fff; font-family: 'DM Mono', monospace;
      font-size: 12px; font-weight: 700; display: flex; align-items: center;
      justify-content: center; box-shadow: 0 1px 5px rgba(208,79,79,.5); }

    @keyframes toast-up {
      from { opacity: 0; transform: translateX(-50%) translateY(6px); }
      to   { opacity: 1; transform: translateX(-50%) translateY(0); }
    }
    @keyframes corner-in {
      from { opacity: 0; transform: scale(.7); }
      to   { opacity: 1; transform: scale(1); }
    }
    .mini-toast {
      position: absolute; bottom: 12px; left: 50%; transform: translateX(-50%);
      z-index: 100; pointer-events: none; background: #fff;
      border-radius: 10px; padding: 6px 12px;
      font-family: 'DM Sans', sans-serif; font-size: 12px; font-weight: 700; color: #1a2a3a;
      box-shadow: 0 3px 12px rgba(0,0,0,.22); white-space: nowrap;
      border: 1.5px solid rgba(0,0,0,.07);
      animation: toast-up .35s cubic-bezier(.34,1.56,.64,1) both;
    }
    .mini-toast.import { color: var(--brand); }
    .mini-toast.ok     { color: #0a7a50; }
    .mini-toast.export { color: #d04f4f; }

    /* ── OTP / Signup reusable classes ────────────────────────────── */
    .otp-input {
      font-family: 'DM Mono', monospace;
      font-size: 1.5rem;
      text-align: center;
      letter-spacing: 8px;
    }
    .code-step-icon {
      font-size: 2rem;
      margin-bottom: 16px;
    }
    .otp-step-label {
      color: var(--muted);
      margin-bottom: 8px;
    }
    .otp-step-title {
      font-weight: 700;
      margin-bottom: 24px;
    }
    .link-btn {
      background: none;
      border: none;
      color: var(--brand);
      cursor: pointer;
      font-size: 0.88rem;
      font-family: inherit;
    }
    .link-btn:hover { text-decoration: underline; }
    .dashboard-spacing { margin: 16px 0; }
    .mini-csv-corner {
      position: absolute; top: 8px; right: 8px; z-index: 100; pointer-events: none;
      background: #d04f4f; color: #fff; font-family: 'DM Mono', monospace;
      font-size: 10px; font-weight: 700; letter-spacing: .06em;
      padding: 3px 8px; border-radius: 5px;
      box-shadow: 0 2px 6px rgba(208,79,79,.5);
      animation: corner-in .35s cubic-bezier(.34,1.56,.64,1) both;
    }
    [data-theme="dark"] .leaflet-tile { filter: brightness(.8) saturate(.65); }

    /* ── DIVIDER ── */
    .divider { height: 1px; background: var(--line); margin: 0; }

    /* ── SECTION LABEL (shared) ── */
    .section-label {
      font-size: 0.78rem; font-weight: 700; letter-spacing: 0.1em;
      text-transform: uppercase; color: var(--brand); margin-bottom: 14px;
    }

    /* ── TRUST SECTION ── */
    .trust-section { padding: 56px 0; text-align: center; }
    .trust-section h2 {
      font-size: clamp(1.8rem, 3vw, 2.6rem); font-weight: 900;
      letter-spacing: -0.04em; line-height: 1.15; margin-bottom: 16px;
    }
    .trust-section p { color: var(--muted); font-size: 1.05rem; max-width: 580px; margin: 0 auto; line-height: 1.8; }

    /* ── WHY BUILT SECTION ── */
    .why-built-section { padding: 56px 0; background: var(--surface); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
    .why-built-inner { display: grid; grid-template-columns: 1fr 2fr; gap: 48px; align-items: start; }
    .why-built-copy h2 { font-size: clamp(1.3rem, 2vw, 1.7rem); font-weight: 900; letter-spacing: -0.03em; line-height: 1.2; margin-bottom: 16px; }
    .why-built-copy p { color: var(--muted); font-size: 0.98rem; line-height: 1.8; margin-bottom: 12px; }
    .why-built-copy p:last-child { margin-bottom: 0; }

    /* ── FREE VALUE SECTION ── */
    .free-value-section { padding: 56px 0; }
    .free-value-card {
      background: var(--surface); border: 1px solid var(--line);
      border-radius: var(--r-lg); padding: 48px; box-shadow: var(--shadow);
      display: grid; grid-template-columns: 1fr auto; gap: 40px; align-items: center;
      position: relative; overflow: hidden;
    }
    .free-value-card::before {
      content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
      background: linear-gradient(90deg, var(--accent), var(--brand));
    }
    .free-value-card h2 { font-size: clamp(1.4rem, 2vw, 1.8rem); font-weight: 900; letter-spacing: -0.03em; margin-bottom: 20px; }
    .free-list { list-style: none; display: flex; flex-direction: column; gap: 10px; margin-bottom: 16px; }
    .free-list li { display: flex; align-items: center; gap: 10px; font-size: 0.95rem; }
    .free-list li::before { content: '✓'; color: var(--accent); font-weight: 700; font-size: 1rem; flex-shrink: 0; }
    .free-limit { font-size: 0.88rem; color: var(--muted); }
    .free-cta { display: flex; flex-direction: column; align-items: center; gap: 10px; flex-shrink: 0; }
    .free-cta .btn { height: 52px; padding: 0 32px; font-size: 1rem; white-space: nowrap; }
    .free-cta span { font-size: 0.8rem; color: var(--muted); }

    /* ── WHY SECTION ── */
    .why-section { padding: 56px 0; }
    .why-inner { display: grid; grid-template-columns: 1fr 2fr; gap: 48px; align-items: start; }
    .why-label { font-size: 0.78rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--brand); margin-bottom: 14px; }
    .why-copy h2 { font-size: clamp(1.5rem, 2.5vw, 2rem); font-weight: 900; letter-spacing: -0.04em; line-height: 1.1; margin-bottom: 16px; }
    .why-copy p { color: var(--muted); line-height: 1.8; font-size: 0.98rem; }
    .error-list { display: grid; gap: 10px; }
    .error-item {
      display: grid; grid-template-columns: 44px 1fr; gap: 14px;
      align-items: start; padding: 16px;
      background: var(--surface); border: 1px solid var(--line);
      border-radius: var(--r); box-shadow: var(--shadow-sm);
    }
    .error-num {
      width: 40px; height: 40px; border-radius: 50%; flex-shrink: 0;
      display: grid; place-items: center; position: relative;
    }
    .error-num::before {
      content: ''; position: absolute; inset: 0;
      border-radius: 50%; background: var(--brand); opacity: .18;
    }
    .error-num::after {
      content: ''; position: absolute; inset: 6px;
      border-radius: 50%; background: var(--brand);
    }
    .error-num span {
      position: relative; z-index: 1;
      font-weight: 900; font-size: 0.82rem; font-family: 'DM Mono', monospace;
      color: #fff; line-height: 1;
    }
    .error-item strong { display: block; font-size: 0.95rem; font-weight: 700; margin-bottom: 4px; letter-spacing: -0.02em; }
    .error-item p { color: var(--muted); font-size: 0.88rem; line-height: 1.65; }

    /* ── LIGHT INTRO SECTION ── */
    .light-intro-section { padding: 56px 0; }
    .light-intro-card {
      background: var(--surface); border: 1px solid var(--line);
      border-radius: var(--r-lg); padding: 48px; box-shadow: var(--shadow);
      display: grid; grid-template-columns: 1fr auto; gap: 40px; align-items: center;
    }
    .light-intro-card h2 { font-size: clamp(1.4rem, 2.5vw, 2rem); font-weight: 900; letter-spacing: -0.04em; margin-bottom: 12px; }
    .light-intro-card > div > p { color: var(--muted); font-size: 0.98rem; line-height: 1.75; }
    .light-list { list-style: none; display: flex; flex-direction: column; gap: 8px; margin: 20px 0 28px; }
    .light-list li { display: flex; align-items: center; gap: 10px; font-size: 0.92rem; }
    .light-list li::before { content: '→'; color: var(--brand); font-weight: 700; flex-shrink: 0; }
    .light-cta { display: flex; flex-direction: column; align-items: flex-end; gap: 10px; flex-shrink: 0; }
    .light-cta .btn { height: 48px; padding: 0 28px; font-size: 0.95rem; }
    .light-cta span { font-size: 0.8rem; color: var(--muted); white-space: nowrap; }

    /* ── COMPARISON SECTION ── */
    .compare-section { padding: 56px 0; }
    .compare-header { text-align: center; margin-bottom: 40px; }
    .compare-header h2 { font-size: clamp(1.5rem, 2.5vw, 2rem); font-weight: 900; letter-spacing: -0.04em; margin-bottom: 10px; }
    .compare-header p { color: var(--muted); font-size: 0.98rem; }
    .compare-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; align-items: start; }
    .compare-box {
      background: var(--surface); border: 1px solid var(--line);
      border-radius: var(--r-lg); padding: 28px 24px; box-shadow: var(--shadow-sm);
      display: flex; flex-direction: column; position: relative; overflow: hidden;
    }
    .compare-box.featured {
      border-color: var(--brand);
      box-shadow: 0 0 0 1px var(--brand), var(--shadow);
    }
    .compare-box.featured::before {
      content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
      background: linear-gradient(90deg, var(--brand), var(--accent));
    }
    .compare-tier { font-size: 0.72rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--brand); margin-bottom: 6px; }
    .compare-name { font-size: 1.5rem; font-weight: 900; letter-spacing: -0.04em; margin-bottom: 4px; }
    .compare-price { font-size: 0.88rem; color: var(--muted); font-weight: 600; margin-bottom: 20px; padding-bottom: 16px; border-bottom: 1px solid var(--line); }
    .compare-list { list-style: none; display: flex; flex-direction: column; gap: 7px; flex: 1; margin-bottom: 20px; }
    .compare-list li { display: flex; align-items: flex-start; gap: 8px; font-size: 0.88rem; line-height: 1.4; }
    .compare-list li::before { content: '·'; color: var(--brand); font-weight: 900; font-size: 1.1rem; flex-shrink: 0; margin-top: -1px; }
    .compare-badge {
      margin-top: auto; padding: 10px 0 0;
      font-size: 0.8rem; font-weight: 700; color: var(--muted);
      border-top: 1px solid var(--line); text-align: center;
    }
    .compare-box.featured .compare-badge { color: var(--brand); }

    /* ── TOOL SECTION ── */
    .tool-section { display: none; }

    /* ── TOOL SHELL ── */
    .tool-shell {
      background: var(--surface); border: 1px solid var(--line);
      border-radius: var(--r-lg); box-shadow: var(--shadow);
      overflow: hidden; min-height: 680px;
      display: flex; flex-direction: column;
    }
    .tool-topbar {
      display: flex; align-items: center; justify-content: space-between;
      gap: 14px; padding: 12px 18px;
      background: var(--surface-2); border-bottom: 1px solid var(--line);
    }
    .tool-brand { display: flex; align-items: center; gap: 9px; font-weight: 700; font-size: 0.92rem; letter-spacing: -0.02em; }
    .tool-brand .brand-mark { width: 28px; height: 28px; border-radius: 8px; font-size: 0.82rem; }
    .tool-brand em { font-style: normal; color: var(--brand); }
    .tool-coord {
      font-family: 'DM Mono', monospace; font-size: 0.8rem;
      color: var(--muted); background: var(--bg); border: 1px solid var(--line);
      border-radius: 999px; padding: 3px 10px; display: none;
    }
    .tool-status-pill {
      padding: 5px 12px; border-radius: 999px;
      background: var(--accent-light); border: 1px solid rgba(15,184,122,0.25);
      color: var(--accent); font-size: 0.8rem; font-weight: 700; white-space: nowrap;
    }
    [data-theme="dark"] .tool-status-pill { border-color: rgba(24,212,142,0.2); }

    .steps-bar {
      display: flex; align-items: stretch; justify-content: space-between; gap: 0;
      background: var(--surface-2); border-bottom: 1px solid var(--line); padding: 0;
    }
    .steps-tabs { display: flex; align-items: stretch; }
    .step-tab {
      display: flex; align-items: center; gap: 9px;
      padding: 13px 28px; cursor: default;
      font-size: 0.88rem; font-weight: 700; color: var(--muted);
      border-right: 1px solid var(--line); transition: .15s;
    }
    .step-tab:first-child { border-left: 1px solid var(--line); }
    .step-tab .num {
      width: 26px; height: 26px; border-radius: 8px;
      display: grid; place-items: center;
      background: var(--bg); color: var(--muted);
      font-size: 0.8rem; font-weight: 900;
      font-family: 'DM Mono', monospace;
      border: 1px solid var(--line); transition: .2s;
    }
    .step-tab.active { color: var(--brand); background: var(--brand-light); }
    .step-tab.active .num { background: var(--brand); color: white; border-color: var(--brand); }
    .step-tab.done { color: var(--accent); }
    .step-tab.done .num { background: var(--accent-light); color: var(--accent); border-color: rgba(15,184,122,0.3); }

    .bar-tools { display: flex; align-items: center; gap: 0; border-left: 1px solid var(--line); }
    .bar-tool-btn {
      display: flex; align-items: center; gap: 7px;
      padding: 0 16px; height: 100%; cursor: pointer;
      font-size: 0.82rem; font-weight: 700; color: var(--muted);
      border: none; background: none; border-right: 1px solid var(--line);
      transition: background .15s, color .15s; white-space: nowrap; position: relative;
    }
    .bar-tool-btn:last-child { border-right: 0; }
    .bar-tool-btn:hover { background: var(--brand-light); color: var(--brand); }
    .bar-tool-btn .bar-icon { font-size: 1rem; line-height: 1; }
    .bar-tool-btn .pro-tag {
      font-size: 8px; font-weight: 900; letter-spacing: .04em;
      background: var(--brand); color: #fff; border-radius: 4px;
      padding: 1px 3px; margin-left: 2px; vertical-align: super;
    }
    .bar-tool-btn.pro-btn { opacity: .65; }
    .bar-tool-btn.pro-btn:hover { opacity: 1; }

    .bar-tool-btn .light-tag {
      font-size: 8px; font-weight: 900; letter-spacing: .04em;
      background: var(--brand); color: #fff; border-radius: 4px;
      padding: 1px 3px; margin-left: 2px; vertical-align: super;
    }
    .bar-tool-btn.light-btn { opacity: .65; }
    .bar-tool-btn.light-btn:hover { opacity: 1; }

    .bar-tool-btn.active-bar { background: var(--brand-light); color: var(--brand); border-bottom: 2px solid var(--brand); }

    .draw-snap-btn { display:flex; align-items:center; gap:6px; margin-top:8px; padding:5px 12px; border-radius:6px; border:1.5px solid var(--line); background:var(--bg); cursor:pointer; font-size:.78rem; font-weight:700; color:var(--muted); transition:all .15s; width:100%; }
    .draw-snap-btn:hover { border-color:var(--brand); color:var(--brand); background:var(--brand-light); }
    .draw-snap-btn.snap-on { background:var(--brand); color:#fff; border-color:var(--brand); }

    #select-panel { position:absolute; top:56px; right:12px; width:260px; background:var(--surface); border-radius:10px; box-shadow:0 4px 24px rgba(0,0,0,.22); z-index:800; display:none; }
    #select-panel.open { display:block; }
    .sp-head { display:flex; align-items:center; justify-content:space-between; padding:12px 14px 10px; border-bottom:1px solid var(--line); font-size:.8rem; font-weight:700; letter-spacing:.08em; text-transform:uppercase; color:var(--muted); }
    .sp-close { background:none; border:none; font-size:1.1rem; cursor:pointer; color:var(--muted); padding:0 2px; }
    .sp-section { padding:12px 14px; border-bottom:1px solid var(--line); }
    .sp-label { font-size:.72rem; font-weight:700; letter-spacing:.08em; text-transform:uppercase; color:var(--muted); display:block; margin-bottom:8px; }
    .sel-tools { display:flex; gap:8px; }
    .sel-tool-btn { flex:1; display:flex; flex-direction:column; align-items:center; gap:4px; padding:8px 4px; border:1.5px solid var(--line); border-radius:7px; background:var(--bg); cursor:pointer; font-size:.75rem; font-weight:700; color:var(--muted); transition:all .15s; }
    .sel-tool-btn .di { font-size:1.1rem; }
    .sel-tool-btn:hover { border-color:var(--brand); color:var(--brand); background:var(--brand-light); }
    .sel-tool-btn.active { background:var(--brand); color:#fff; border-color:var(--brand); }
    .sp-counter { font-size:.82rem; color:var(--muted); padding:10px 14px; display:flex; align-items:center; justify-content:space-between; }
    .sp-counter strong { color:var(--text); font-size:1rem; }
    .sp-counter.over { color:#d32f2f; }
    .sp-counter.over strong { color:#d32f2f; }
    .sp-actions { padding:10px 14px; display:flex; gap:8px; }
    .sp-btn { flex:1; padding:7px 0; border-radius:6px; border:1.5px solid var(--line); background:var(--bg); cursor:pointer; font-size:.8rem; font-weight:700; color:var(--muted); transition:all .15s; }
    .sp-btn:hover { background:var(--brand-light); color:var(--brand); border-color:var(--brand); }
    .sp-btn.primary { background:var(--brand); color:#fff; border-color:var(--brand); }
    .sp-btn.primary:hover { opacity:.85; }

    .tool-body {
      display: grid; grid-template-columns: 360px 1fr;
      flex: 1; min-height: 0; overflow: hidden;
    }
    .tool-sidebar {
      padding: 16px; border-right: 1px solid var(--line);
      overflow-y: auto; display: flex; flex-direction: column; gap: 12px;
      background: var(--surface-2);
    }
    .sb-label {
      font-size: 0.75rem; font-weight: 700; letter-spacing: 0.08em;
      text-transform: uppercase; color: var(--muted);
      display: flex; align-items: center; justify-content: space-between;
    }
    .sb-badge {
      font-size: 0.75rem; font-weight: 700; padding: 3px 8px;
      background: var(--bg); border: 1px solid var(--line);
      border-radius: 999px; color: var(--muted); font-family: 'DM Mono', monospace;
    }
    .sb-block {
      background: var(--surface); border: 1px solid var(--line);
      border-radius: var(--r); padding: 12px;
    }
    .textarea {
      width: 100%; min-height: 148px; resize: vertical;
      border: 1px solid var(--line); border-radius: 10px; padding: 12px;
      font: 0.88rem/1.7 'DM Mono', monospace; color: var(--text);
      background: var(--bg); outline: none; transition: border-color .15s;
    }
    .textarea:focus { border-color: var(--brand); }
    .textarea::placeholder { color: var(--muted); font-family: 'DM Sans', sans-serif; font-size: 0.85rem; }

    .adv-toggle {
      display: inline-flex; align-items: center; gap: 5px;
      margin-top: 8px; font-size: 0.84rem; font-weight: 600;
      color: var(--brand); cursor: pointer; transition: opacity .15s;
    }
    .adv-toggle:hover { opacity: .75; }

    .upload-zone {
      border: 1.5px dashed var(--line); background: var(--bg);
      border-radius: var(--r); padding: 20px 14px; text-align: center;
      position: relative; cursor: pointer; transition: .15s;
    }
    .upload-zone:hover { border-color: var(--brand); background: var(--brand-light); }
    .upload-zone input { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; height: 100%; }
    .upload-icon {
      width: 44px; height: 44px; margin: 0 auto 10px;
      border-radius: 12px; display: grid; place-items: center;
      background: var(--brand-light); color: var(--brand); font-size: 1.2rem;
      pointer-events: none;
    }
    .upload-zone strong { display: block; margin-bottom: 5px; font-size: 0.92rem; pointer-events: none; }
    .upload-zone p { margin: 0; color: var(--muted); font-size: 0.84rem; pointer-events: none; }
    .upload-fname { font-size: 0.8rem; color: var(--brand); font-weight: 600; margin-top: 6px; }

    .guess-grid { display: grid; gap: 8px; }
    .guess-item {
      padding: 10px 12px; border-radius: 10px;
      background: var(--bg); border: 1px solid var(--line);
    }
    .guess-item .lbl { display: block; color: var(--muted); font-size: 0.74rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.07em; margin-bottom: 4px; }
    .guess-item strong { font-size: 0.92rem; letter-spacing: -0.02em; }
    .guess-item p { margin: 4px 0 0; color: var(--muted); font-size: 0.84rem; }
    .confidence-pill {
      display: inline-flex; align-items: center; gap: 5px; margin-top: 6px;
      padding: 4px 9px; border-radius: 999px;
      background: #fff7e6; color: var(--warn); border: 1px solid rgba(196,127,26,0.25);
      font-size: 0.76rem; font-weight: 700;
    }
    [data-theme="dark"] .confidence-pill { background: rgba(196,127,26,0.12); border-color: rgba(196,127,26,0.2); }

    .adv-row { display: none; }
    .adv-row.open { display: block; }
    .sel {
      width: 100%; height: 42px; border-radius: 10px;
      border: 1px solid var(--line); padding: 0 12px;
      background: var(--surface); font: 0.9rem 'DM Sans', sans-serif;
      color: var(--text); cursor: pointer; outline: none; margin-top: 6px;
    }
    .sel:focus { border-color: var(--brand); }

    .tip-card {
      padding: 12px; background: var(--brand-light); border-radius: 10px;
      border: 1px solid rgba(29,95,168,0.12);
    }
    .tip-card p { margin: 0; color: var(--brand); font-size: 0.85rem; line-height: 1.65; font-weight: 500; }

    .status-line { padding: 8px 12px; border-radius: 8px; font-size: 0.84rem; font-weight: 600; display: none; }
    .status-line.on { display: block; }
    .status-line.info { background: var(--brand-light); color: var(--brand); }
    .status-line.ok { background: var(--accent-light); color: var(--accent); }
    .status-line.err { background: #fdf0f0; color: var(--danger); }
    [data-theme="dark"] .status-line.err { background: rgba(208,79,79,0.1); }
    .limit-note { font-size: 0.8rem; color: var(--warn); font-weight: 600; display: none; }
    .limit-note.on { display: block; }
    .pt-count { font-size: 0.8rem; color: var(--muted); text-align: right; font-family: 'DM Mono', monospace; }

    .sidebar-actions { margin-top: auto; display: grid; gap: 8px; }
    .sidebar-actions .btn, .sidebar-actions .btn-outline { width: 100%; height: 44px; border-radius: 10px; justify-content: center; font-size: 0.9rem; }
    .sidebar-note { margin: 0; color: var(--muted); font-size: 0.79rem; line-height: 1.6; text-align: center; }

    .tool-map { position: relative; overflow: hidden; min-height: 620px; }
    #map { width: 100%; height: 100%; min-height: 620px; }
    .map-chip {
      position: absolute; top: 12px; right: 12px; z-index: 400;
      padding: 7px 12px; border-radius: 999px;
      background: rgba(255,255,255,0.95); border: 1px solid var(--line);
      box-shadow: var(--shadow-sm); color: var(--muted);
      font-weight: 700; font-size: 0.84rem; display: none;
    }
    [data-theme="dark"] .map-chip { background: rgba(14,25,41,0.95); }
    .map-warning {
      position: absolute; top: 12px; left: 12px; z-index: 400; max-width: 320px;
      padding: 10px 14px; border-radius: 12px;
      background: rgba(255,255,255,0.96); border: 1px solid rgba(196,127,26,0.3);
      box-shadow: var(--shadow-sm); color: var(--warn);
      font-size: 0.87rem; line-height: 1.6; display: none;
    }
    [data-theme="dark"] .map-warning { background: rgba(14,25,41,0.95); }

    .legend-box {
      position: absolute; left: 12px; bottom: 12px; z-index: 400;
      width: min(360px, calc(100% - 24px));
      background: rgba(255,255,255,0.97); border: 1px solid var(--line);
      border-radius: var(--r); box-shadow: var(--shadow); padding: 14px; display: none;
    }
    [data-theme="dark"] .legend-box { background: rgba(14,25,41,0.97); }
    .legend-box.on { display: block; }
    .legend-hd { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
    .legend-hd h4 { margin: 0; font-size: 0.92rem; letter-spacing: -0.02em; }
    .legend-close { background: none; border: none; cursor: pointer; color: var(--muted); font-size: 16px; line-height: 1; }
    .rtable { width: 100%; border-collapse: collapse; font-size: 0.8rem; }
    .rtable th { padding: 4px 6px; text-align: left; font-size: 0.7rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); border-bottom: 1px solid var(--line); }
    .rtable td { padding: 5px 6px; border-bottom: 1px solid rgba(0,0,0,0.04); font-family: 'DM Mono', monospace; font-size: 0.79rem; }
    [data-theme="dark"] .rtable td { border-bottom-color: rgba(255,255,255,0.04); }
    .rtable td.lbl { font-family: 'DM Sans', sans-serif; color: var(--muted); font-size: 0.8rem; }
    .rtable tr:last-child td { border-bottom: 0; }
    .legend-export { margin-top: 10px; width: 100%; display: none; }

    [data-theme="dark"] .leaflet-tile { filter: brightness(.8) saturate(.65); }

    .dot-cluster {
      width: 32px; height: 32px; border-radius: 50%;
      background: rgba(208,79,79,.25); border: none;
      display: flex; align-items: center; justify-content: center;
      position: absolute; top: 0; left: 0; transform: translate(-50%, -50%);
    }
    .dot-cluster-inner {
      width: 22px; height: 22px; border-radius: 50%;
      background: #d04f4f; color: #fff;
      font-family: 'DM Sans', sans-serif; font-size: 12px; font-weight: 700;
      display: flex; align-items: center; justify-content: center;
      box-shadow: 0 1px 5px rgba(208,79,79,.5);
    }
    [data-theme="dark"] .leaflet-popup-content-wrapper { background: var(--surface); color: var(--text); }
    [data-theme="dark"] .leaflet-popup-tip { background: var(--surface); }

    /* ── DRAW PANEL ── */
    #draw-panel {
      position: absolute; top: 10px; left: 10px; z-index: 500;
      background: rgba(255,255,255,0.97); border: 1px solid var(--line);
      border-radius: var(--r); box-shadow: var(--shadow);
      width: 210px; display: none;
    }
    [data-theme="dark"] #draw-panel { background: rgba(14,25,41,0.97); }
    #draw-panel.open { display: block; }
    .dp-head {
      padding: 10px 12px 8px; font-size: .72rem; font-weight: 700;
      text-transform: uppercase; letter-spacing: .08em; color: var(--muted);
      border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between;
    }
    .dp-close { background: none; border: none; cursor: pointer; color: var(--muted); font-size: 16px; line-height: 1; padding: 0; }
    .dp-close:hover { color: var(--text); }
    .dp-section { padding: 10px 12px; border-bottom: 1px solid var(--line); }
    .dp-section:last-child { border-bottom: 0; }
    .dp-label { font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); margin-bottom: 7px; display: block; }
    .draw-tools { display: flex; gap: 6px; }
    .draw-tool-btn {
      flex: 1; height: 36px; border-radius: 8px;
      border: 1.5px solid var(--line); background: var(--bg);
      color: var(--text); font-size: .78rem; font-weight: 700; cursor: pointer;
      display: flex; flex-direction: column; align-items: center; justify-content: center;
      gap: 1px; transition: .15s; line-height: 1;
    }
    .draw-tool-btn .di { font-size: 1rem; }
    .draw-tool-btn:hover { border-color: var(--brand); background: var(--brand-light); color: var(--brand); }
    .draw-tool-btn.active { border-color: var(--brand); background: var(--brand); color: #fff; }
    .draw-tool-btn.active:hover { background: var(--brand-mid); }
    .dp-layer-row {
      display: flex; align-items: center; justify-content: space-between; gap: 6px; padding: 4px 0;
    }
    .dp-layer-name { font-size: .8rem; font-weight: 600; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .dp-layer-swatch { width: 20px; height: 20px; border-radius: 5px; border: 2px solid rgba(255,255,255,.7); cursor: pointer; flex-shrink: 0; box-shadow: 0 0 0 1px rgba(0,0,0,.15); transition: transform .1s; }
    .dp-layer-swatch:hover { transform: scale(1.15); }
    .dp-layer-name-input {
      flex: 1; font-size: .8rem; font-weight: 600; border: none; background: transparent;
      color: var(--text); outline: none; min-width: 0; padding: 2px 4px; border-radius: 5px;
    }
    .dp-layer-name-input:focus { background: var(--brand-light); color: var(--brand); }
    .dp-layer-del { background: none; border: none; cursor: pointer; color: var(--muted); font-size: 14px; padding: 2px 4px; line-height: 1; }
    .dp-layer-del:hover { color: var(--danger); }
    .dp-add-layer { width: 100%; height: 32px; border-radius: 8px; border: 1.5px dashed var(--line); background: none; color: var(--muted); font-size: .8rem; font-weight: 600; cursor: pointer; margin-top: 6px; transition: .15s; }
    .dp-add-layer:hover { border-color: var(--brand); color: var(--brand); background: var(--brand-light); }
    .dp-active-layer { display: flex; align-items: center; gap: 6px; margin-bottom: 7px; }
    .dp-active-layer select { flex: 1; height: 32px; border-radius: 8px; border: 1px solid var(--line); background: var(--bg); color: var(--text); font-size: .82rem; padding: 0 8px; outline: none; }
    .dp-active-layer select:focus { border-color: var(--brand); }

    #color-picker-popup {
      position: fixed; z-index: 9999; background: var(--surface);
      border: 1px solid var(--line); border-radius: 12px;
      box-shadow: var(--shadow); padding: 10px; display: none;
      flex-direction: column; gap: 6px; width: 168px;
    }
    #color-picker-popup.open { display: flex; }
    .cp-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 5px; }
    .cp-swatch {
      width: 20px; height: 20px; border-radius: 5px; cursor: pointer;
      border: 2px solid transparent; transition: transform .1s, border-color .1s;
      box-shadow: 0 0 0 1px rgba(0,0,0,.12);
    }
    .cp-swatch:hover { transform: scale(1.2); }
    .cp-swatch.selected { border-color: #fff; box-shadow: 0 0 0 2px #333; }
    .cp-custom-row { display: flex; align-items: center; gap: 6px; padding-top: 4px; border-top: 1px solid var(--line); }
    .cp-custom-row label { font-size: .7rem; color: var(--muted); white-space: nowrap; }
    .cp-custom-input { width: 32px; height: 24px; border-radius: 5px; border: 1px solid var(--line); cursor: pointer; padding: 0; }
    .cp-hex-input {
      flex: 1; height: 26px; border-radius: 6px; border: 1px solid var(--line);
      background: var(--bg); color: var(--text); font: .78rem 'DM Mono', monospace;
      padding: 0 6px; outline: none;
    }
    .cp-hex-input:focus { border-color: var(--brand); }
    .dp-hint { font-size: .72rem; color: var(--muted); line-height: 1.5; padding: 2px 0; }
    .dp-undo-row { display: flex; gap: 6px; }
    .dp-undo-btn { flex: 1; height: 30px; border-radius: 7px; border: 1px solid var(--line); background: var(--bg); color: var(--muted); font-size: .78rem; font-weight: 600; cursor: pointer; transition: .15s; }
    .dp-undo-btn:hover:not(:disabled) { border-color: var(--brand); color: var(--brand); }
    .dp-undo-btn:disabled { opacity: .35; cursor: default; }

    #info-panel {
      position: absolute; bottom: 38px; left: 10px; z-index: 500;
      background: rgba(255,255,255,0.97); border: 1px solid var(--line);
      border-radius: var(--r); box-shadow: var(--shadow);
      width: 240px; display: none; padding: 12px 14px;
    }
    [data-theme="dark"] #info-panel { background: rgba(14,25,41,0.97); }
    #info-panel.open { display: block; }
    .ip-head { font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin-bottom: 8px; display: flex; justify-content: space-between; align-items: center; }
    .ip-close { background: none; border: none; cursor: pointer; color: var(--muted); font-size: 15px; padding: 0; }
    .ip-row { display: flex; justify-content: space-between; padding: 4px 0; border-bottom: 1px solid var(--line); font-size: .82rem; }
    .ip-row:last-child { border-bottom: 0; }
    .ip-key { color: var(--muted); }
    .ip-val { font-family: 'DM Mono', monospace; font-size: .78rem; }
    .ip-hint { font-size: .72rem; color: var(--muted); padding: 4px 0 0; line-height: 1.5; }

    .tool-map.draw-active { cursor: crosshair; }
    .tool-map.info-active { cursor: help; }

    /* ── PDF MODAL ── */
    #pdf-modal {
      position: fixed; inset: 0; z-index: 1200;
      background: rgba(8,15,26,0.75); backdrop-filter: blur(4px);
      display: flex; align-items: center; justify-content: center;
      opacity: 0; pointer-events: none; transition: opacity .2s;
    }
    #pdf-modal.open { opacity: 1; pointer-events: auto; }
    .pdf-card {
      background: var(--surface); border: 1px solid var(--line);
      border-radius: var(--r-lg); padding: 32px 36px;
      box-shadow: var(--shadow); width: min(520px, calc(100vw - 40px));
      position: relative; transform: translateY(12px); transition: transform .2s;
    }
    #pdf-modal.open .pdf-card { transform: translateY(0); }
    .pdf-card::before {
      content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
      background: linear-gradient(90deg, var(--brand), var(--accent));
      border-radius: var(--r-lg) var(--r-lg) 0 0;
    }
    .pdf-close {
      position: absolute; top: 14px; right: 14px;
      width: 32px; height: 32px; border-radius: 999px;
      background: var(--bg); border: 1px solid var(--line);
      color: var(--muted); font-size: 16px; cursor: pointer;
      display: grid; place-items: center;
    }
    .pdf-close:hover { color: var(--text); }
    .pdf-card h3 { font-size: 1.1rem; font-weight: 900; letter-spacing: -0.03em; margin-bottom: 20px; }
    .pdf-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 16px; }
    .pdf-field label {
      display: block; font-size: 0.72rem; font-weight: 700; letter-spacing: .08em;
      text-transform: uppercase; color: var(--muted); margin-bottom: 6px;
    }
    .pdf-field select, .pdf-field input[type=text] {
      width: 100%; height: 40px; border-radius: 10px;
      border: 1px solid var(--line); padding: 0 12px;
      background: var(--bg); font: 0.9rem 'DM Sans', sans-serif;
      color: var(--text); outline: none;
    }
    .pdf-field select:focus, .pdf-field input:focus { border-color: var(--brand); }
    .pdf-field-full { grid-column: 1 / -1; }
    .pdf-preview {
      border: 1px solid var(--line); border-radius: 10px;
      background: var(--bg); margin-bottom: 16px; overflow: hidden;
      display: flex; align-items: center; justify-content: center;
      position: relative; height: 140px;
    }
    .pdf-preview-inner {
      background: #fff; border: 1px solid #ccc;
      box-shadow: 0 2px 8px rgba(0,0,0,.1); position: relative;
      display: flex; align-items: stretch; justify-content: stretch; transition: all .2s;
    }
    .pdf-preview-map { background: #e8eef5; flex: 1; display: flex; align-items: center; justify-content: center; color: #7090b0; font-size: 0.75rem; font-weight: 600; }
    .pdf-preview-north { position: absolute; top: 6px; right: 6px; width: 18px; height: 18px; background: #fff; border-radius: 50%; border: 1.5px solid #666; display: flex; align-items: center; justify-content: center; font-size: 9px; font-weight: 900; color: #333; }
    .pdf-preview-scale { position: absolute; bottom: 4px; left: 6px; font-size: 8px; color: #444; font-weight: 700; }
    .pdf-preview-remark { position: absolute; bottom: 4px; right: 6px; font-size: 7px; color: #666; max-width: 60px; text-align: right; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
    .pdf-panel-strip { position: absolute; right: 0; top: 0; bottom: 0; width: 32px; background: #f0f0f0; border-left: 1px solid #ccc; display: flex; flex-direction: column; align-items: center; justify-content: flex-start; padding-top: 4px; gap: 2px; font-size: 7px; color: #888; }
    .pdf-actions { display: flex; gap: 10px; }
    .pdf-actions .btn { flex: 1; height: 44px; justify-content: center; }
    .pdf-actions .btn-outline { flex: 0 0 auto; height: 44px; padding: 0 20px; justify-content: center; }

    /* ── PRO MODAL ── */
    #pro-modal {
      position: fixed; inset: 0; z-index: 1100;
      background: rgba(8,15,26,0.75); backdrop-filter: blur(4px);
      display: flex; align-items: center; justify-content: center;
      opacity: 0; pointer-events: none; transition: opacity .2s;
    }
    #pro-modal.open { opacity: 1; pointer-events: auto; }
    .pro-card {
      background: var(--surface); border: 1px solid var(--line);
      border-radius: var(--r-lg); padding: 36px 40px;
      box-shadow: var(--shadow); width: min(460px, calc(100vw - 40px));
      position: relative; transform: translateY(12px); transition: transform .2s;
    }
    #pro-modal.open .pro-card { transform: translateY(0); }
    .pro-card::before {
      content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
      background: linear-gradient(90deg, var(--brand), var(--accent));
      border-radius: var(--r-lg) var(--r-lg) 0 0;
    }
    .pro-close {
      position: absolute; top: 14px; right: 14px;
      width: 32px; height: 32px; border-radius: 999px;
      background: var(--bg); border: 1px solid var(--line);
      color: var(--muted); font-size: 16px; cursor: pointer;
      display: grid; place-items: center;
    }
    .pro-close:hover { color: var(--text); }
    .pro-card h3 { font-size: 1.25rem; font-weight: 900; letter-spacing: -0.03em; margin-bottom: 6px; }
    .pro-card .pro-sub { color: var(--muted); font-size: 0.9rem; margin-bottom: 20px; }
    .pro-list { list-style: none; display: flex; flex-direction: column; gap: 8px; margin-bottom: 24px; }
    .pro-list li { display: flex; align-items: center; gap: 10px; font-size: 0.92rem; }
    .pro-list li::before { content: '✓'; color: var(--accent); font-weight: 700; font-size: 1rem; }
    .pro-price { font-size: 1.5rem; font-weight: 900; letter-spacing: -0.04em; margin-bottom: 18px; }
    .pro-price span { font-size: 0.9rem; font-weight: 500; color: var(--muted); }
    .pro-actions { display: flex; gap: 10px; }
    .pro-actions .btn { flex: 1; height: 46px; justify-content: center; font-size: 0.95rem; }
    .pro-actions .btn-outline { flex: 1; height: 46px; justify-content: center; font-size: 0.92rem; }

    /* ── LIGHT MODAL ── */
    #light-modal {
      position: fixed; inset: 0; z-index: 1100;
      background: rgba(8,15,26,0.75); backdrop-filter: blur(4px);
      display: flex; align-items: center; justify-content: center;
      opacity: 0; pointer-events: none; transition: opacity .2s;
    }
    #light-modal.open { opacity: 1; pointer-events: auto; }
    #light-modal .pro-card { transform: translateY(12px); transition: transform .2s; }
    #light-modal.open .pro-card { transform: translateY(0); }

    /* ── TOOL MODAL ── */
    #tool-modal {
      position: fixed; inset: 0; z-index: 999;
      background: rgba(8,15,26,0.97);
      display: flex; flex-direction: column;
      opacity: 0; pointer-events: none;
      transition: opacity .25s;
    }
    #tool-modal.open { opacity: 1; pointer-events: auto; }
    .modal-inner {
      display: flex; flex-direction: column;
      width: 100%; height: 100%;
      transform: scale(0.97); transition: transform .25s;
    }
    #tool-modal.open .modal-inner { transform: scale(1); }
    .modal-topbar {
      display: flex; align-items: center; justify-content: space-between;
      padding: 10px 18px; flex-shrink: 0;
      border-bottom: 1px solid rgba(255,255,255,0.08);
    }
    .modal-title {
      color: rgba(255,255,255,0.9); font-weight: 700; font-size: 0.95rem;
      letter-spacing: -0.02em; display: flex; align-items: center; gap: 10px;
    }
    .modal-title .brand-mark { width: 28px; height: 28px; border-radius: 8px; font-size: 0.78rem; }
    .modal-close {
      width: 38px; height: 38px; border-radius: 999px;
      background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.12);
      color: rgba(255,255,255,0.7); font-size: 18px; line-height: 1;
      cursor: pointer; display: grid; place-items: center;
      transition: background .15s, color .15s;
    }
    .modal-close:hover { background: rgba(255,255,255,0.16); color: white; }
    .modal-body { flex: 1; min-height: 0; display: flex; flex-direction: column; padding: 16px; }
    .modal-body .tool-shell { flex: 1; min-height: 0; border-radius: var(--r-lg); }
    .modal-body .tool-map, .modal-body #map { min-height: 0; }

    /* ── CORE CTA ── */
    .core-section { padding: 0 0 72px; }
    .core-card {
      background: var(--surface); border: 1px solid var(--line);
      border-radius: var(--r-lg); padding: 48px; box-shadow: var(--shadow);
      display: grid; grid-template-columns: 1fr auto; gap: 32px; align-items: center;
      position: relative; overflow: hidden;
    }
    .core-card::before {
      content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
      background: linear-gradient(90deg, var(--brand), var(--accent));
    }
    .core-card h2 { font-size: clamp(1.6rem, 2.5vw, 2.2rem); font-weight: 900; letter-spacing: -0.04em; margin-bottom: 12px; }
    .core-card p { color: var(--muted); line-height: 1.75; font-size: 0.98rem; max-width: 600px; }
    .core-features { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 16px; }
    .core-tag {
      padding: 5px 12px; border-radius: 999px;
      background: var(--bg); border: 1px solid var(--line);
      font-size: 0.8rem; font-weight: 600; color: var(--muted);
    }
    .core-cta { display: flex; flex-direction: column; align-items: flex-end; gap: 10px; flex-shrink: 0; }
    .core-cta .btn { height: 48px; padding: 0 28px; font-size: 0.95rem; }
    .core-cta span { font-size: 0.8rem; color: var(--muted); white-space: nowrap; }

    /* ── MODULES SECTION ── */
    .modules-section { padding: 56px 0; background: var(--surface); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
    .modules-inner { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
    .modules-copy h2 { font-size: clamp(1.3rem, 2vw, 1.7rem); font-weight: 900; letter-spacing: -0.03em; margin-bottom: 16px; }
    .modules-copy p { color: var(--muted); font-size: 0.93rem; line-height: 1.8; margin-bottom: 12px; }
    .module-list { list-style: none; display: flex; flex-direction: column; gap: 8px; margin: 16px 0; }
    .module-list li { display: flex; align-items: center; gap: 10px; font-size: 0.9rem; }
    .module-list li::before { content: '▸'; color: var(--accent); font-weight: 700; }
    .modules-note {
      padding: 20px; background: var(--brand-light); border-radius: var(--r);
      border: 1px solid rgba(29,95,168,.12);
    }
    .modules-note p { color: var(--brand); font-size: 0.9rem; line-height: 1.75; font-weight: 500; margin: 0; }

    /* ── EPSG ── */
    .epsg-section { padding: 56px 0; }
    .epsg-intro { color: var(--muted); font-size: 1rem; line-height: 1.75; max-width: 600px; margin-bottom: 28px; }
    .epsg-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(256px, 1fr)); gap: 12px; margin-bottom: 32px; }
    .epsg-card { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 20px 22px; display: block; color: inherit; text-decoration: none; transition: border-color .15s, box-shadow .15s; }
    a.epsg-card:hover { border-color: var(--brand); box-shadow: var(--shadow-sm); }
    .epsg-code { display: inline-flex; align-items: center; font: 700 0.8rem/1 'DM Mono', monospace; color: var(--brand); background: var(--brand-light); padding: 4px 10px; border-radius: 999px; margin-bottom: 10px; letter-spacing: 0.02em; }
    .epsg-name { font-weight: 700; font-size: 0.95rem; margin-bottom: 6px; letter-spacing: -0.02em; }
    .epsg-desc { color: var(--muted); font-size: 0.84rem; line-height: 1.65; }
    .epsg-related { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 32px; padding-top: 24px; border-top: 1px solid var(--line); }
    .epsg-related a { font-size: 0.84rem; font-weight: 600; color: var(--brand); padding: 6px 14px; border: 1px solid var(--brand-light); border-radius: 999px; background: var(--brand-light); transition: .15s; }
    .epsg-related a:hover { background: var(--brand); color: white; }

    /* ── FAQ ── */
    .faq-section { padding: 56px 0 80px; }
    .faq-header { margin-bottom: 28px; }
    .faq-header h2 { font-size: clamp(1.5rem, 2.5vw, 2rem); font-weight: 900; letter-spacing: -0.04em; }
    .faq-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
    .faq-item {
      background: var(--surface); border: 1px solid var(--line);
      border-radius: var(--r); padding: 20px 22px; box-shadow: var(--shadow-sm);
    }
    .faq-item h4 { font-size: 0.95rem; font-weight: 700; letter-spacing: -0.02em; margin-bottom: 8px; }
    .faq-item p { color: var(--muted); font-size: 0.88rem; line-height: 1.75; }

    /* ── SEO SUBPAGES (shared by csv/shape/dwg/koordinat-transformation/hoejdesystem) ── */
    .page-hero { padding: 64px 0 48px; }
    .page-eyebrow { display: inline-flex; align-items: center; gap: 8px; font-size: .78rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--brand); margin-bottom: 16px; }
    .page-eyebrow span { width: 6px; height: 6px; border-radius: 50%; background: var(--brand); display: block; }
    .page-hero h1 { font-size: clamp(2rem, 3.5vw, 3rem); font-weight: 900; letter-spacing: -.05em; line-height: 1.05; margin-bottom: 16px; }
    .page-hero h1 .accent { color: var(--brand); }
    .page-lead { font-size: 1.05rem; color: var(--muted); line-height: 1.75; max-width: 580px; margin-bottom: 28px; }

    .content-section { padding: 48px 0; }
    .content-section + .content-section { border-top: 1px solid var(--line); }
    .content-section h2 { font-size: clamp(1.4rem, 2.2vw, 1.9rem); font-weight: 900; letter-spacing: -.04em; margin-bottom: 12px; }
    .content-section p { color: var(--muted); font-size: .95rem; line-height: 1.8; max-width: 660px; margin-bottom: 16px; }
    .content-section h3 { font-size: 1.1rem; font-weight: 700; margin: 24px 0 10px; letter-spacing: -.02em; }
    .content-section code { font-family: 'DM Mono', monospace; font-size: .85em; background: var(--surface-2); border: 1px solid var(--line); padding: 1px 6px; border-radius: 5px; color: var(--text); }

    .feature-list { list-style: none; display: flex; flex-direction: column; gap: 10px; margin: 20px 0 28px; }
    .feature-list li { display: flex; align-items: flex-start; gap: 12px; font-size: .95rem; }
    .feature-list li::before { content: '✓'; font-weight: 900; color: var(--accent); flex-shrink: 0; margin-top: 1px; }

    .warn-box { background: var(--warn-light); border: 1px solid var(--warn); border-radius: 16px; padding: 18px 22px; margin: 20px 0 28px; display: flex; gap: 14px; align-items: flex-start; }
    .warn-box p { color: var(--text); font-size: .9rem; line-height: 1.7; margin: 0; max-width: none; }

    .compare-table { width: 100%; border-collapse: collapse; margin: 20px 0 28px; font-size: .88rem; }
    .compare-table th { background: var(--surface); border: 1px solid var(--line); padding: 10px 14px; text-align: left; font-weight: 700; font-size: .8rem; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }
    .compare-table td { border: 1px solid var(--line); padding: 10px 14px; color: var(--muted); vertical-align: top; }
    .compare-table td:first-child { font-weight: 700; color: var(--text); font-family: 'DM Mono', monospace; font-size: .83rem; white-space: nowrap; }
    .compare-table tr:nth-child(even) td { background: var(--surface-2); }

    .code-block { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 14px 18px; margin: 14px 0 22px; font-family: 'DM Mono', monospace; font-size: .82rem; line-height: 1.7; color: var(--text); white-space: pre; overflow-x: auto; }
    .code-block .c-muted { color: var(--muted); }
    .code-block .c-brand { color: var(--brand); font-weight: 700; }

    .related-section { padding: 40px 0; border-top: 1px solid var(--line); }
    .related-section h3 { font-size: 1rem; font-weight: 700; margin-bottom: 16px; letter-spacing: -.02em; }
    .related-links { display: flex; gap: 10px; flex-wrap: wrap; }
    .related-links a { font-size: .84rem; font-weight: 600; color: var(--brand); padding: 8px 16px; border: 1px solid var(--brand-light); border-radius: 999px; background: var(--brand-light); transition: .15s; }
    .related-links a:hover { background: var(--brand); color: white; }

    @media (max-width: 768px) {
      .header-inner { height: 56px; }
      .page-hero { padding: 40px 0 32px; }
      .epsg-grid { grid-template-columns: 1fr; }
    }

    /* ── FOOTER ── */
    .site-footer { padding: 20px 0 48px; }
    .footer-inner {
      display: flex; align-items: center; justify-content: space-between; gap: 16px;
      padding-top: 20px; border-top: 1px solid var(--line);
      flex-wrap: wrap; color: var(--muted); font-size: 0.86rem;
    }
    .footer-inner a { color: var(--muted); }
    .footer-inner a:hover { color: var(--brand); }
    .footer-lang { display: flex; gap: 16px; }
    .footer-legal { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; }
    .footer-legal a { color: var(--muted); text-decoration: none; }
    .footer-legal a:hover { color: var(--brand); }
    .footer-cookie-settings {
      background: none; border: none; padding: 0; margin: 0; cursor: pointer;
      color: var(--muted); font: inherit; font-size: 0.86rem;
    }
    .footer-cookie-settings:hover { color: var(--brand); }

    /* ── DISCLAIMER BLOCK (rapport-sider) ── */
    .disclaimer-block {
      margin: 24px 0 0;
      padding: 14px 18px;
      background: var(--surface);
      border: 1px solid var(--line);
      border-left: 3px solid var(--warn, #c47f1a);
      border-radius: 0 8px 8px 0;
      font-size: 0.85rem;
      line-height: 1.6;
      color: var(--muted);
    }
    .disclaimer-block a { color: var(--brand); text-decoration: underline; }

    /* ── TOPIC NAV ── */
    .topic-nav{position:sticky;top:64px;z-index:190;background:rgba(242,245,249,.85);backdrop-filter:blur(14px);border-bottom:1px solid var(--line);transition:background .25s;}
    [data-theme="dark"] .topic-nav{background:rgba(8,15,26,.88);}
    .topic-nav-inner{display:flex;gap:6px;overflow-x:auto;scrollbar-width:none;padding:10px 0;align-items:center;flex-wrap:nowrap;}
    .topic-nav-inner::-webkit-scrollbar{display:none;}
    .topic-nav-label{font-size:.72rem;font-weight:700;letter-spacing:.08em;text-transform:uppercase;color:var(--muted);white-space:nowrap;padding-right:10px;flex-shrink:0;}
    .topic-tab{display:inline-flex;align-items:center;gap:6px;padding:6px 14px;border-radius:999px;background:var(--surface);border:1px solid var(--line);font:600 .82rem 'DM Sans',sans-serif;color:var(--text);white-space:nowrap;transition:all .15s;flex-shrink:0;text-decoration:none;}
    .topic-tab:hover{border-color:var(--brand);color:var(--brand);background:var(--brand-light);}
    .topic-tab.active{background:var(--brand);border-color:var(--brand);color:#fff;}
    .topic-tab.active:hover{background:var(--brand-mid);}
    .topic-tab .ti{font-size:.88em;opacity:.75;}
    .topic-tab svg.ti{width:14px;height:14px;opacity:.85;flex-shrink:0;}
    .topic-tab.active svg.ti{opacity:1;}
    .t-ref{display:inline-flex;align-items:center;gap:5px;color:var(--brand);font-weight:600;text-decoration:none;border-bottom:1px solid transparent;transition:border-color .15s;}
    .t-ref:hover{border-bottom-color:var(--brand);}
    .t-ref svg{width:13px;height:13px;flex-shrink:0;vertical-align:-2px;}
    @media(max-width:768px){
      .topic-nav-label{display:none;}
      .topic-nav-inner{padding:8px 0;}
      .topic-tab{padding:5px 12px;font-size:.76rem;}
    }

    /* ── RESPONSIVE ── */
    @media (max-width: 1024px) {
      .hero-inner { grid-template-columns: 1fr; gap: 32px; }
      .tool-body { grid-template-columns: 1fr; }
      .tool-sidebar { border-right: 0; border-bottom: 1px solid var(--line); }
      .tool-map, #map { min-height: 440px; }
      .why-inner { grid-template-columns: 1fr; gap: 28px; }
      .why-built-inner { grid-template-columns: 1fr; gap: 28px; }
      .core-card { grid-template-columns: 1fr; }
      .core-cta { align-items: flex-start; }
      .steps-map-row { flex-direction: column; }
      .free-value-card { grid-template-columns: 1fr; }
      .free-cta { align-items: flex-start; }
      .light-intro-card { grid-template-columns: 1fr; }
      .light-cta { align-items: flex-start; }
      .compare-grid { grid-template-columns: 1fr; max-width: 480px; margin: 0 auto; }
      .modules-inner { grid-template-columns: 1fr; gap: 28px; }
    }
    @media (max-width: 700px) {
      .faq-grid { grid-template-columns: 1fr; }
      .core-card { padding: 28px; }
      .free-value-card { padding: 28px; }
      .light-intro-card { padding: 28px; }
      .hero { padding: 40px 0 32px; }
      .steps-bar { flex-wrap: wrap; }
      .step-tab { flex: 1; justify-content: center; }
      .compare-grid { max-width: 100%; }
    }
