/* Catalog and category landing pages (kettad/…).
   Dark top (hero, filters, "Lennukaart" flight map) continues the homepage's
   night fairway; the card list below sits on the light surface.
   Colour rule (owner): never light text on a light background. On dark only
   --on-dark / --on-dark-muted / --sky / --left; on light only --text /
   --text-muted / --blue-strong. */

.cx [hidden] { display: none !important; }

/* ---------- hero ---------- */
.cx-hero {
  color: var(--on-dark);
  background:
    radial-gradient(ellipse 60% 40% at 50% 0%, rgba(92, 196, 247, 0.14), transparent 70%),
    linear-gradient(180deg, var(--ink) 0%, var(--night) 55%, var(--night-2) 100%);
  padding: 18px 0 44px;
}
.cx .crumbs ol { list-style: none; margin: 0 0 18px; padding: 0; display: flex; flex-wrap: wrap; gap: 4px; font-size: 13.5px; }
.cx .crumbs li { color: var(--on-dark); font-weight: 650; }
.cx .crumbs li + li::before { content: "›"; margin-right: 6px; color: var(--on-dark-muted); }
.cx .crumbs a { color: var(--on-dark-muted); text-decoration: none; font-weight: 500; }
.cx .crumbs a:hover { color: var(--on-dark); text-decoration: underline; }
.cx-h1 { margin: 6px 0 10px; font-size: clamp(32px, 4.6vw, 56px); line-height: 1.05; font-style: italic; font-weight: 850; letter-spacing: -0.02em; }
.cx-intro { margin: 0; max-width: 760px; font-size: 17.5px; color: var(--on-dark-muted); }
.cx-count { margin: 12px 0 0; font-size: 14px; color: var(--on-dark-muted); }
.cx-count strong { color: var(--on-dark); font-size: 16px; }
.cx-rhbh { margin: 12px 0 0; max-width: 760px; padding-left: 12px; border-left: 3px solid var(--sky); font-size: 14px; color: var(--on-dark-muted); }
.cx-rhbh strong { color: var(--on-dark); }
.cx-mirror { margin: 14px 0 0; max-width: 760px; padding: 10px 14px; border-radius: 12px; background: rgba(255, 181, 71, 0.12); border: 1px solid rgba(255, 181, 71, 0.55); color: var(--on-dark); font-size: 14.5px; }
.cx-mirror strong { color: var(--left); }

.cx-cats ul { list-style: none; margin: 20px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.cx-cats a { display: inline-block; padding: 7px 14px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, 0.2); color: var(--on-dark); text-decoration: none; font-size: 14px; font-weight: 650; }
.cx-cats a:hover { border-color: var(--sky); background: rgba(255, 255, 255, 0.06); }
.cx-cats a[aria-current="page"] { background: var(--sky); border-color: var(--sky); color: #031520; }

/* ---------- filters ---------- */
.cx-tools { margin-top: 22px; padding: 14px 16px; display: grid; gap: 12px; border-radius: 16px; background: rgba(12, 22, 36, 0.78); border: 1px solid rgba(92, 196, 247, 0.22); }
.cx-fbody { display: grid; gap: 12px; }
.cx-ftoggle { display: none; }
.cx-fgroup { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; }
.cx-flabel { min-width: 64px; font-size: 11.5px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--on-dark-muted); }
.cx-fgroup-sel .cx-flabel { min-width: 0; margin-left: 6px; }
.cx-fgroup-sel .cx-flabel:first-child { min-width: 64px; margin-left: 0; }
.cx-chip { border: 1px solid rgba(255, 255, 255, 0.2); background: rgba(255, 255, 255, 0.05); color: var(--on-dark); border-radius: 999px; padding: 6px 13px; font-size: 13.5px; font-weight: 650; cursor: pointer; }
.cx-chip:hover { border-color: var(--sky); }
.cx-chip[aria-pressed="true"] { background: var(--sky); border-color: var(--sky); color: #031520; }
.cx-chip[data-v="vasakule"][aria-pressed="true"] { background: var(--left); border-color: var(--left); color: #1d1300; }
.cx-chip[data-v="otse"][aria-pressed="true"] { background: #fff; border-color: #fff; color: var(--text); }
.cx-arrow { font-style: normal; font-weight: 800; }
.cx-select {
  appearance: none; -webkit-appearance: none; font: inherit; font-size: 13.5px; font-weight: 650;
  color: var(--on-dark); background-color: #0b1420; border: 1px solid rgba(255, 255, 255, 0.22); border-radius: 999px;
  padding: 6px 32px 6px 13px; cursor: pointer; max-width: 100%;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%235cc4f7' stroke-width='1.8'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center; background-size: 11px 8px;
}
.cx-select:hover { border-color: var(--sky); }
.cx-select option { color: var(--text); background: #fff; }
.cx-check { display: inline-flex; align-items: center; gap: 8px; margin-left: 8px; font-size: 14px; font-weight: 650; color: var(--on-dark); cursor: pointer; }
.cx-check input { width: 18px; height: 18px; accent-color: var(--sky); margin: 0; }
.cx-check small { color: var(--on-dark-muted); font-weight: 500; }
.cx-tools-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; padding-top: 10px; border-top: 1px solid rgba(255, 255, 255, 0.08); }
.cx-active { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 13px; color: var(--on-dark-muted); min-height: 30px; }
.cx-pill { display: inline-flex; align-items: center; gap: 6px; padding: 4px 6px 4px 11px; border-radius: 999px; background: rgba(255, 255, 255, 0.1); color: var(--on-dark); font-weight: 650; font-size: 13px; }
.cx-pill button, .cx-pill a { display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, 0.14); color: var(--on-dark); cursor: pointer; text-decoration: none; font-size: 14px; line-height: 1; padding: 0; }
.cx-pill button:hover, .cx-pill a:hover { background: var(--sky); color: #031520; }
.cx-clearall { border: 0; background: none; color: var(--sky); font-weight: 700; font-size: 13px; text-decoration: underline; cursor: pointer; padding: 4px; }
.cx-view { display: inline-flex; padding: 3px; border-radius: 999px; background: rgba(255, 255, 255, 0.08); }
.cx-view button { border: 0; background: none; color: var(--on-dark); font-weight: 750; font-size: 13.5px; padding: 6px 16px; border-radius: 999px; cursor: pointer; }
.cx-view button[aria-pressed="true"] { background: #fff; color: var(--text); }

/* ---------- map ---------- */
.cx-mapsec { margin-top: 26px; }
.cx-maphead { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 12px 24px; }
.cx-maptitle { margin: 0; font-size: clamp(24px, 3vw, 32px); font-style: italic; font-weight: 850; letter-spacing: -0.01em; }
.cx-mapsub { margin: 4px 0 0; max-width: 700px; font-size: 14.5px; color: var(--on-dark-muted); }
.cx-mapsub strong { color: var(--on-dark); }
.cx-me { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; font-size: 14px; color: var(--on-dark-muted); }
.cx-me strong { color: var(--on-dark); }
.cx-me .btn { padding: 8px 16px; }
.cx-me-link { border: 1px solid rgba(92, 196, 247, .5); background: none; color: var(--on-dark); border-radius: 999px; padding: 6px 14px; font-weight: 700; font-size: 13.5px; cursor: pointer; }
.cx-me-link:hover { border-color: var(--sky); background: rgba(255, 255, 255, .06); }

.cx-map {
  --dot: 32px;
  position: relative; margin-top: 14px; height: clamp(560px, 76vh, 800px); border-radius: 20px; overflow: hidden;
  background: linear-gradient(180deg, #000 0%, #050c16 40%, #0b1a2b 100%);
  border: 1px solid rgba(92, 196, 247, 0.18);
  box-shadow: inset 0 0 80px rgba(0, 0, 0, .6);
  -webkit-user-select: none; user-select: none;
}
.cx-field, .cx-curve { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.cx-curve { z-index: 4; }
.cx-dots { position: absolute; inset: 0; z-index: 3; }
.cx-dot {
  position: absolute; left: 0; top: 0; width: var(--dot); height: var(--dot); border-radius: 50%;
  background: #fff; display: block; overflow: hidden;
  box-shadow: 0 0 0 2px var(--ring, rgba(255, 255, 255, .85)), 0 3px 10px rgba(0, 0, 0, .55);
  opacity: 1; scale: 1; outline: none;
}
.cx-dot img { width: 100%; height: 100%; object-fit: cover; clip-path: circle(47%); pointer-events: none; }
.cx-dot[data-vdir="left"] { --ring: var(--left); }
.cx-dot[data-vdir="right"] { --ring: var(--sky); }
.cx-dot.is-fit { box-shadow: 0 0 0 2px var(--ring, #fff), 0 0 14px 2px rgba(92, 196, 247, .75); }
.cx-dot.is-dim { opacity: .26; filter: grayscale(1); }
.cx-dot.is-out { opacity: 0; scale: .3; pointer-events: none; }
.cx-dot:hover, .cx-dot.is-hot { scale: 1.75; z-index: 10; opacity: 1; filter: none; box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--ring, #fff), 0 8px 22px rgba(0, 0, 0, .6); }
.cx-map.is-ready .cx-dot { transition: translate .55s cubic-bezier(.3, .7, .25, 1), opacity .3s, scale .2s, filter .3s; }

.cx-edge { position: absolute; bottom: 18px; z-index: 4; font-size: 13px; font-weight: 850; letter-spacing: .06em; text-transform: uppercase; pointer-events: none; text-shadow: 0 1px 6px #000; }
.cx-edge-l { left: 14px; color: var(--left); }
.cx-edge-r { right: 14px; color: var(--sky); }
.cx-bandlabel { position: absolute; right: 12px; z-index: 5; translate: 0 -50%; padding: 3px 11px; border-radius: 999px; background: var(--sky); color: #031520; font-size: 12px; font-weight: 850; white-space: nowrap; pointer-events: none; box-shadow: 0 0 16px rgba(92, 196, 247, .7); }
.cx-empty-map { position: absolute; left: 50%; top: 42%; translate: -50% 0; margin: 0; z-index: 5; padding: 12px 18px; border-radius: 12px; background: rgba(12, 22, 36, .92); color: var(--on-dark); font-weight: 650; text-align: center; max-width: calc(100% - 32px); }

.cx-curve path { fill: none; stroke-width: 2.6; stroke-linecap: round; stroke-dasharray: 1; stroke-dashoffset: 0; filter: drop-shadow(0 0 6px rgba(92, 196, 247, .6)); opacity: .9; }
@media (prefers-reduced-motion: no-preference) {
  .cx-curve path { animation: cx-draw .6s cubic-bezier(.3, .7, .3, 1) both; }
}
@keyframes cx-draw { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }

.cx-tip {
  position: absolute; left: 0; top: 0; z-index: 20; width: 270px; padding: 12px; border-radius: 14px; pointer-events: none;
  background: #0b1420; color: var(--on-dark); border: 1px solid rgba(92, 196, 247, .4); box-shadow: 0 18px 44px rgba(0, 0, 0, .55);
  display: grid; grid-template-columns: 64px 1fr; gap: 4px 12px; align-items: start;
}
.cx-tip .plate { width: 64px; height: 64px; grid-row: span 3; }
.cx-tip-brand { margin: 0; font-size: 11.5px; color: var(--on-dark-muted); text-transform: uppercase; letter-spacing: .05em; font-weight: 700; }
.cx-tip-name { margin: 0; font-size: 15px; font-weight: 800; line-height: 1.2; }
.cx-tip-price { margin: 0; font-size: 16px; font-weight: 850; }
.cx-tip-price small { font-size: 12px; font-weight: 600; color: var(--on-dark-muted); }
.cx-tip-price s { font-size: 12.5px; color: var(--on-dark-muted); font-weight: 600; margin-left: 4px; }
.cx-tip-fn { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; margin-top: 6px; }
.cx-tip-fn span { background: rgba(255, 255, 255, .08); border-radius: 8px; text-align: center; padding: 3px 0 2px; font-weight: 850; font-size: 14px; line-height: 1.1; }
.cx-tip-fn small { display: block; font-size: 9.5px; font-weight: 600; color: var(--on-dark-muted); }
.cx-tip-meta { grid-column: 1 / -1; margin: 4px 0 0; font-size: 12.5px; color: var(--on-dark-muted); }
.cx-tip-meta strong { color: var(--on-dark); }
.cx-tip-verdict { grid-column: 1 / -1; justify-self: start; margin: 4px 0 0; font-size: 12px; font-weight: 800; border-radius: 999px; padding: 3px 10px; background: rgba(255, 255, 255, .1); color: var(--on-dark); }
.cx-tip-verdict.is-ok { background: var(--sky); color: #031520; }
.cx-tip-verdict.is-no { background: rgba(255, 107, 107, .2); color: #ffd2d2; }

/* ---------- list ---------- */
.cx-listsec { padding: 40px 0 56px; }
.cx-listhead { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 12px 20px; margin-bottom: 20px; }
.cx-listhead h2 { margin: 0; font-size: clamp(24px, 3vw, 34px); line-height: 1.15; font-style: italic; font-weight: 850; letter-spacing: -0.02em; color: var(--text); }
.cx-listcount { font-size: 15px; font-style: normal; font-weight: 700; color: var(--text-muted); letter-spacing: 0; margin-left: 6px; white-space: nowrap; }
.cx-sort { display: flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 700; color: var(--text-muted); }
.cx-select-light { color: var(--text); background-color: #fff; border-color: var(--line); }
.cx-select-light:hover { border-color: var(--blue-strong); }
.cx-select-light { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%230a679c' stroke-width='1.8'/%3E%3C/svg%3E"); }

.cx-grid { list-style: none; margin: 0; padding: 0; display: grid; gap: 18px; grid-template-columns: repeat(auto-fill, minmax(224px, 1fr)); }
.cx-grid > li { display: flex; min-width: 0; }
.cx-card { width: 100%; }
.cx-card .card-name { font-size: 16px; }
.cx-dir { margin: 0; display: flex; align-items: center; gap: 7px; font-size: 13px; font-weight: 650; color: var(--text); }
.cx-dir-dot { flex: none; width: 11px; height: 11px; border-radius: 50%; background: #fff; border: 2px solid var(--text-muted); }
.cx-dir-dot[data-dir="left"] { background: var(--left); border-color: #9a5b00; }
.cx-dir-dot[data-dir="right"] { background: var(--sky); border-color: var(--blue-strong); }
.cx-verdict { margin: 0; align-self: flex-start; font-size: 12px; font-weight: 800; border-radius: 999px; padding: 2px 10px; }
.cx-verdict.is-ok { background: #e2f4ea; color: #0d5530; }
.cx-verdict.is-no { background: #fdecea; color: #8a1c1c; }
.cx-card .price small { font-size: 12px; font-weight: 650; color: var(--text-muted); }
.cx-more { font-size: 13px; font-weight: 750; color: var(--blue-strong); white-space: nowrap; }
.cx-card:hover .cx-more { text-decoration: underline; }
.cx-empty { padding: 40px 20px; text-align: center; background: var(--card); border: 1px dashed var(--line); border-radius: var(--radius); color: var(--text); }
.cx-empty p { margin: 0 0 14px; font-weight: 650; }

.cx-howto { background: var(--card); border-top: 1px solid var(--line); padding: 40px 0 48px; color: var(--text); }
.cx-howto h2 { margin: 0 0 12px; font-size: 22px; font-style: italic; font-weight: 850; }
.cx-howto p { margin: 0 0 12px; max-width: 820px; color: var(--text); }

/* ---------- small screens: list first, map on demand ---------- */
@media (max-width: 759px) {
  .cx-hero { padding: 14px 0 32px; }
  .cx-intro { font-size: 16px; }
  .cx-cats ul { gap: 6px; }
  .cx-cats a { padding: 6px 11px; font-size: 13px; }
  .cx-tools { padding: 12px; gap: 10px; }
  .cx-ftoggle { display: inline-flex; align-items: center; justify-content: space-between; gap: 8px; width: 100%; border: 1px solid rgba(255, 255, 255, .22); background: rgba(255, 255, 255, .05); color: var(--on-dark); border-radius: 12px; padding: 10px 14px; font-weight: 750; font-size: 15px; cursor: pointer; }
  .cx-ftoggle::after { content: "▾"; color: var(--sky); }
  .cx-ftoggle[aria-expanded="true"]::after { content: "▴"; }
  .cx-tools:not(.is-open) .cx-fbody { display: none; }
  .cx-tools-foot { border-top: 0; padding-top: 0; }
  .cx-flabel, .cx-fgroup-sel .cx-flabel:first-child { min-width: 0; width: 100%; }
  .cx-fgroup-sel .cx-flabel { margin-left: 0; }
  .cx-chip { padding: 6px 11px; font-size: 13px; }
  .cx-check { margin: 4px 0 0; width: 100%; }
  .cx-map { --dot: 24px; height: 640px; border-radius: 16px; }
  .cx-edge { font-size: 11.5px; bottom: 12px; }
  .cx-tip { width: 230px; }
  /* Phone list: one disc per row, photo left, details right. */
  .cx-grid { gap: 10px; grid-template-columns: minmax(0, 1fr); }
  .cx-card { flex-direction: row; }
  .cx-card .card-media { flex: none; width: 118px; padding: 8px; align-self: flex-start; }
  .cx-card .card-flight { width: 22px; height: 42px; right: 4px; top: 4px; border-radius: 7px; padding: 2px; }
  .cx-card .badge-sale { left: 4px; top: 4px; font-size: 10.5px; padding: 2px 7px; }
  .cx-card .card-body { min-width: 0; border-top: 0; border-left: 1px solid var(--line); padding: 10px 12px 12px; gap: 5px; }
  .cx-card .card-name { font-size: 15px; min-height: 0; }
  .cx-card .fn span { font-size: 13.5px; min-width: 0; }
  .cx-card .fn small { font-size: 9px; overflow: hidden; text-overflow: ellipsis; }
  .cx-card .card-arm { font-size: 12.5px; }
  .cx-card .price { font-size: 18px; }
  .cx-more { display: none; }
  .cx-listsec { padding: 28px 0 40px; }
}

@media (prefers-reduced-motion: reduce) {
  .cx-map.is-ready .cx-dot { transition: none; }
  .cx-curve path { animation: none; }
}

/* flight-term glossary under every catalog page */
.cx-gloss { background: #fff; padding: 48px 0 56px; border-top: 1px solid var(--line); }
.cx-gloss h2 { margin: 0 0 6px; font-size: clamp(22px, 2.6vw, 30px); font-style: italic; font-weight: 850; }
.cx-gloss-sub { margin: 0 0 18px; color: var(--text-muted); }
.cx-gloss-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 28px; margin: 0; }
.cx-gloss-list div { padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); }
.cx-gloss-list dt { font-weight: 800; color: var(--text); }
.cx-gloss-list dd { margin: 4px 0 0; color: var(--text-muted); font-size: 14.5px; line-height: 1.5; }
@media (max-width: 720px) { .cx-gloss-list { grid-template-columns: 1fr; } }

/* True landing spot when the plate had to be moved aside (dense map). */
.cx-curve .cx-leader { stroke-width: 1.6; stroke-dasharray: 2 5; stroke-linecap: round; opacity: .85; }
.cx-curve .cx-land { fill: rgba(6, 11, 19, .65); stroke-width: 2.4; }
