/* Písma pribalené k webu (SIL OFL 1.1): Inter pre text, Barlow Semi Condensed pre nadpisy a čísla. Licencie: /assets/fonts/LICENSE-*.txt */
@font-face { font-family: "Barlow Semi Condensed"; font-style: normal; font-weight: 600; font-display: swap; src: url("/assets/fonts/barlow-semi-condensed-600-latin-ext.woff2") format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Barlow Semi Condensed"; font-style: normal; font-weight: 600; font-display: swap; src: url("/assets/fonts/barlow-semi-condensed-600-latin.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Barlow Semi Condensed"; font-style: normal; font-weight: 700; font-display: swap; src: url("/assets/fonts/barlow-semi-condensed-700-latin-ext.woff2") format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Barlow Semi Condensed"; font-style: normal; font-weight: 700; font-display: swap; src: url("/assets/fonts/barlow-semi-condensed-700-latin.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 400 800; font-display: swap; src: url("/assets/fonts/inter-variable-latin-ext.woff2") format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 400 800; font-display: swap; src: url("/assets/fonts/inter-variable-latin.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

:root {
  --ink: #171a2b;
  --muted: #5a6078;
  --paper: #f3f4f7;
  --panel: #ffffff;
  --line: #dcdfe8;
  --forest: #1d213b;
  --moss: #33384f;
  --lime: #c5e34f;
  /* Farby prostredia (vlastník 10. 11. 2026): pozadie menu a záhlavia --navy, popredie --lime. */
  --navy: #1d213b;
  /* Smer A (13. 11. 2026): lime je akcia a výber, povrchy sú neutrálne, náročnosť má vlastnú škálu, trasa je modrá. */
  --navy-2: #2a2f52;
  --accent-tint: #f6fbe3;
  --route: #3b5bdb;
  --lvl-paved: #7c8794;
  --lvl-light: #2f9e6b;
  --lvl-medium: #e0a019;
  --lvl-hard: #d4532b;
  --candidate: #e6a800;
  --unknown: #78837e;
  --forbidden: #d33f32;
  --confirmed: #27935a;
  --shadow: 0 16px 42px rgba(29, 33, 59, .16);
  --profile-height: 250px;
  --profile-collapsed-height: 52px;
  /* Povrchy, linky a stavové farby ako premenné – svetlý a tmavý vzhľad sa líšia iba ich hodnotami. */
  --surface: #ffffff;
  --surface-2: #eceef3;
  --surface-3: #f7f8fa;
  --surface-4: #e3e5ec;
  --line-2: #d5d8e2;
  --line-3: #c3c7d4;
  --line-4: #9aa0b8;
  --ink-2: #33384f;
  --strong: #1d213b;
  --strong-line: #1d213b;
  --warn-bg: #fff6e0;
  --warn-ink: #5c4200;
  --warn-line: #e6c35b;
  --danger-bg: #fbe9e2;
  --danger-ink: #8a2a14;
  --danger-line: #e6b3a1;
  --sev-danger: #b3261e;
  --sev-warning: #b06a00;
  --sev-ford: #1769c2;
  --sev-info: #46536b;
}

* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body { color: var(--ink); background: var(--paper); font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
button, input { font: inherit; }
a { color: inherit; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.skip-link { position: fixed; left: 1rem; top: -4rem; z-index: 2000; background: var(--surface); padding: .75rem 1rem; border-radius: .5rem; }
.skip-link:focus { top: 1rem; }

/* Široké ADV logo ostáva čitateľné v hlavičke; ikony menu majú samostatný 40 px stĺpec. */
.topbar { height: 56px; display: flex; align-items: center; gap: 1rem; padding: 0 1.1rem 0 13px; background: var(--navy); color: white; border-bottom: 1px solid rgba(255,255,255,.08); position: relative; z-index: 1001; }
.brand { display: inline-flex; align-items: center; gap: .65rem; text-decoration: none; min-width: 0; }
.brand-mark { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 12px; color: var(--navy); background: var(--lime); font-size: 1.75rem; line-height: 1; transform: rotate(-8deg); }
.brand-logo { display: block; width: 96px; height: 49px; flex-shrink: 0; }
.brand-logo img { display: block; width: 100%; height: 100%; object-fit: contain; }
.brand strong { display: block; font-size: 1.08rem; letter-spacing: .02em; }
.brand small { display: block; color: #b9bfd6; font-size: .68rem; margin-top: .1rem; letter-spacing: .025em; }
.topbar-actions { margin-left: auto; display: flex; align-items: center; gap: .55rem; }
.language-picker { display: inline-flex; align-items: center; gap: .38rem; color: #e7e9f3; font-size: .68rem; font-weight: 800; }
.language-picker select { min-width: 64px; padding: .48rem 1.7rem .48rem .58rem; border: 1px solid rgba(255,255,255,.24); border-radius: .55rem; color: white; background: #2a2f52; font: inherit; cursor: pointer; }
.language-picker select:focus-visible { outline: 3px solid rgba(197,227,79,.45); outline-offset: 2px; }
.primary-button, .ghost-button, .icon-button, .planner-button, .secondary-button, .osmand-button { border: 0; border-radius: .65rem; cursor: pointer; font-weight: 750; }
.primary-button { padding: .68rem .9rem; color: #1d213b; background: var(--lime); text-decoration: none; }
.primary-button.inline { display: inline-flex; }
.ghost-button { padding: .65rem .8rem; color: #e7e9f3; background: rgba(255,255,255,.07); }
.planner-button { padding: .65rem .8rem; color: #e7e9f3; background: rgba(197,227,79,.14); border: 1px solid rgba(197,227,79,.3); }
.planner-button.active { color: #1d213b; background: var(--lime); }
.poi-button[hidden] { display: none; }
.icon-button { width: 40px; height: 40px; color: white; background: rgba(255,255,255,.08); }
.mobile-only { display: none; }
.mobile-adventure-note { display: none; }

.tool-rail { position: fixed; top: 56px; bottom: 0; left: 0; z-index: 950; width: 72px; display: flex; flex-direction: column; align-items: stretch; padding: 9px 6px; color: white; background: var(--navy); border-right: 1px solid rgba(255,255,255,.08); box-shadow: 8px 0 24px rgba(17,20,38,.12); }
.tool-button { position: relative; width: 40px; min-height: 40px; display: grid; place-items: center; margin: 3px 0 3px 9px; padding: 0; border: 2px solid transparent; border-radius: 12px; color: var(--navy); background: #8da547; cursor: pointer; transition: opacity .15s ease, transform .15s ease, box-shadow .15s ease; }
.tool-button:hover, .tool-button:focus-visible { color: var(--navy); background: var(--lime); outline: none; opacity: 1; transform: translateY(-1px); box-shadow: 0 5px 14px rgba(0,0,0,.24); }
.tool-button.active { color: var(--navy); background: var(--lime); border-color: #f4ffd2; }
.tool-button svg { display: block; width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.tool-button::after { position: absolute; top: 50%; left: calc(100% + 10px); z-index: 1200; padding: .42rem .56rem; border-radius: .45rem; color: white; background: rgba(29,33,59,.96); box-shadow: 0 5px 16px rgba(0,0,0,.2); content: attr(data-label); font-size: .68rem; font-weight: 800; line-height: 1; pointer-events: none; transform: translate(4px,-50%); white-space: nowrap; opacity: 0; visibility: hidden; transition: opacity .14s ease, transform .14s ease; }
.tool-button:hover::after, .tool-button:focus-visible::after { transform: translate(0,-50%); opacity: 1; visibility: visible; }
.tool-button[hidden] { display: none; }
.tool-rail-divider { height: 1px; margin: 6px 4px; background: rgba(255,255,255,.12); }

.workspace { width: calc(100% - 72px); height: calc(100% - 56px); display: block; margin-left: 72px; overflow: hidden; }
body.profile-visible .workspace { height: calc(100% - 56px - var(--profile-height)); }
body.profile-visible.profile-collapsed .workspace { height: calc(100% - 56px - var(--profile-collapsed-height)); }
.sidebar { min-width: 0; height: 100%; display: flex; flex-direction: column; background: var(--panel); border-right: 1px solid var(--line); z-index: 800; }
.intro { padding: 1.3rem 1.3rem .9rem; }
.eyebrow { margin: 0 0 .45rem; color: var(--moss); font-size: .73rem; font-weight: 850; letter-spacing: .12em; text-transform: uppercase; }
.intro h1 { margin: 0; max-width: 330px; font-size: clamp(1.55rem, 2.1vw, 2.15rem); line-height: 1.04; letter-spacing: -.045em; }
.intro > p:last-child { margin: .7rem 0 0; color: var(--muted); font-size: .88rem; line-height: 1.5; }
.legal-warning { margin: 0 1.3rem .9rem; padding: .75rem .85rem; display: grid; gap: .2rem; border-left: 4px solid var(--candidate); background: var(--warn-bg); border-radius: 0 .55rem .55rem 0; font-size: .77rem; line-height: 1.4; }
.legal-warning span { color: var(--warn-ink); }
.planner-panel .legal-warning { margin: .75rem 0 0; padding: .65rem .72rem; font-size: .7rem; }
.filters { padding: 0 1.3rem .9rem; border-bottom: 1px solid var(--line); }
.search-wrap input { width: 100%; padding: .68rem .75rem; border: 1px solid var(--line); border-radius: .65rem; outline: none; background: var(--surface-3); }
.search-wrap input:focus { border-color: var(--strong-line); box-shadow: 0 0 0 3px rgba(29,33,59,.12); }
.filter-row { display: flex; flex-wrap: wrap; gap: .38rem; margin-top: .62rem; }
.filter-chip { padding: .38rem .55rem; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); color: var(--muted); font-size: .72rem; cursor: pointer; }
.filter-chip span { display: inline-grid; place-items: center; min-width: 1.1rem; height: 1.1rem; margin-left: .16rem; border-radius: 1rem; background: var(--surface-2); font-size: .65rem; }
.filter-chip.active { color: white; background: var(--forest); border-color: var(--strong-line); }
.filter-chip.candidate.active { background: var(--candidate); border-color: var(--candidate); color: #302500; }
.filter-chip.unknown.active { background: var(--unknown); border-color: var(--unknown); color: white; }
.filter-chip.forbidden.active { background: var(--forbidden); border-color: var(--forbidden); color: white; }

.list-section { min-height: 0; display: flex; flex: 1; flex-direction: column; }
.list-heading { display: flex; align-items: center; justify-content: space-between; padding: .8rem 1.3rem .5rem; }
.list-heading h2 { margin: 0; font-size: .82rem; text-transform: uppercase; letter-spacing: .09em; }
.text-button { padding: .25rem; border: 0; background: none; color: var(--moss); font-size: .72rem; font-weight: 800; cursor: pointer; }
.route-list { min-height: 0; overflow-y: auto; padding: 0 .75rem .8rem; }
.route-card { width: 100%; display: grid; grid-template-columns: 5px 1fr auto; gap: .7rem; padding: .76rem .62rem; border: 0; border-bottom: 1px solid var(--line); background: var(--surface); color: inherit; text-align: left; cursor: pointer; }
.route-card:hover, .route-card:focus-visible { background: var(--surface-3); outline: none; }
.route-card.active { background: var(--surface-2); border-radius: .55rem; }
.route-stripe { width: 5px; min-height: 46px; border-radius: 99px; background: var(--unknown); }
.route-stripe.kandidat { background: var(--candidate); }
.route-stripe.zakaz { background: var(--forbidden); }
.route-stripe.potvrdeny { background: var(--confirmed); }
.route-main strong { display: block; font-size: .83rem; line-height: 1.25; }
.route-main small { display: block; color: var(--muted); margin-top: .28rem; font-size: .7rem; }
.route-distance { color: var(--ink); font-size: .7rem; font-weight: 800; white-space: nowrap; }
.empty-state { padding: 1.3rem; color: var(--muted); font-size: .84rem; text-align: center; }
.sidebar-footer { padding: .65rem 1.3rem; display: flex; flex-wrap: wrap; justify-content: space-between; gap: .4rem; border-top: 1px solid var(--line); color: var(--muted); font-size: .67rem; }
.download-links { display: flex; gap: .65rem; }
.download-links a { color: var(--moss); font-weight: 800; }

.map-shell { position: relative; min-width: 0; height: 100%; background: var(--surface-4); }
#map { width: 100%; height: 100%; }
.map-legend { position: absolute; left: 14px; bottom: 22px; z-index: 500; display: flex; flex-wrap: wrap; gap: .55rem; padding: .55rem .7rem; border: 1px solid rgba(29,33,59,.1); border-radius: .65rem; background: rgba(255,255,255,.94); box-shadow: 0 8px 22px rgba(29,33,59,.12); font-size: .68rem; }
.map-legend[hidden] { display: none; }
.map-legend span { display: inline-flex; align-items: center; gap: .35rem; }
.legend-line { width: 20px; border-top: 4px solid; border-radius: 4px; }
.candidate { color: var(--candidate); }
.legend-line.candidate { border-color: var(--candidate); }
.legend-line.unknown { border-color: var(--unknown); border-top-style: dashed; }
.legend-line.forbidden { border-color: var(--forbidden); }
.legend-line.confirmed { border-color: var(--confirmed); }
.map-message { position: absolute; top: 12px; left: 50%; z-index: 600; transform: translateX(-50%); padding: .65rem .8rem; border-radius: .55rem; background: var(--surface); box-shadow: var(--shadow); font-size: .78rem; }
.map-zoom-debug { position: absolute; bottom: 28px; left: 12px; z-index: 650; min-width: 4.6rem; padding: .28rem .46rem; border: 1px solid rgba(29,33,59,.2); border-radius: .42rem; color: var(--ink); background: rgba(255,255,255,.9); box-shadow: 0 2px 8px rgba(29,33,59,.16); font: 750 .68rem/1.2 ui-monospace, SFMono-Regular, Consolas, monospace; text-align: center; pointer-events: none; backdrop-filter: blur(5px); }
.map-shell.planning #map { cursor: crosshair; }
.planner-panel { position: absolute; top: 14px; left: 14px; z-index: 700; width: min(390px, calc(100% - 28px)); max-height: calc(100% - 28px); overflow-y: auto; padding: 1rem; border: 1px solid rgba(29,33,59,.12); border-radius: .9rem; background: var(--surface); box-shadow: var(--shadow); }
.planner-panel[hidden] { display: none; }
.map-tool-panel { position: absolute; top: 14px; left: 14px; z-index: 700; width: min(390px, calc(100% - 28px)); max-height: calc(100% - 28px); overflow-y: auto; padding: 1rem; border: 1px solid rgba(29,33,59,.12); border-radius: .9rem; background: var(--surface); box-shadow: var(--shadow); }
.map-tool-panel[hidden] { display: none; }
.tool-panel-head { display: flex; align-items: flex-start; justify-content: space-between; gap: .8rem; margin-bottom: .85rem; }
.tool-panel-head h2 { margin: 0; font-size: 1.3rem; letter-spacing: -.025em; }
.tool-panel-head .eyebrow { margin-bottom: .18rem; }
.tool-panel-head .dialog-close { position: static; flex: 0 0 auto; }
.map-style-legend { display: grid; gap: .72rem; }
.map-style-legend span { display: flex; align-items: center; gap: .75rem; color: var(--ink-2); font-size: .78rem; font-weight: 750; }
.legend-section-title { margin: 0 0 .75rem; color: var(--ink); font-size: .8rem; }
.map-key { width: 38px; height: 10px; flex: 0 0 auto; display: block; border-radius: 4px; }
.map-key[class*="track-grade"] { height: 6px; border: 1px solid #6b5444; border-radius: 3px; }
.map-key.track-grade1 { background: #e3b04b; }
.map-key.track-grade2 { background: repeating-linear-gradient(90deg, #d08a2e 0 10px, #ecd0ab 10px 13px); }
.map-key.track-grade3 { background: repeating-linear-gradient(90deg, #b8612a 0 6px, #e3c0aa 6px 9px); }
.map-key.track-grade4 { background: repeating-linear-gradient(90deg, #8c3f22 0 3px, #d1b2a7 3px 6px); }
.map-key.track-grade5 { background: repeating-linear-gradient(90deg, #4a2618 0 1.5px, #b7a8a3 1.5px 4.5px); }
.map-key.track-ungraded { height: 0; border-top: 2px dashed #8a7a68; border-radius: 0; }
.map-key.route-line { height: 0; border-top: 5px solid var(--route); border-radius: 0; }
.map-key.water-line { height: 0; border-top: 3px solid #79b7e5; border-radius: 0; }
.map-key.forest-area { background: #cfe6bd; border: 1px solid #b5d39d; }
.map-key.protected-area { background: rgba(215,51,63,.16); border: 2px solid #bd1726; }
.legal-legend-note { padding: .65rem .7rem; border-left: 3px solid var(--candidate); border-radius: 0 .5rem .5rem 0; background: var(--warn-bg); }
.legal-legend-note strong { display: block; margin-bottom: .18rem; color: var(--warn-ink); }
.grade-note { border-left-color: #985f33; background: var(--warn-bg); }
.panel-note { margin: 1rem 0 0; padding: .7rem .75rem; border-radius: .55rem; color: var(--warn-ink); background: var(--warn-bg); font-size: .7rem; line-height: 1.45; }
.route-info-panel .route-result { margin: 0; padding: 0; border: 0; }
.poi-panel { position: absolute; top: 14px; left: 14px; z-index: 700; width: min(390px, calc(100% - 28px)); max-height: calc(100% - 28px); display: flex; flex-direction: column; overflow: hidden; border: 1px solid rgba(29,33,59,.12); border-radius: .9rem; background: var(--surface); box-shadow: var(--shadow); }
.poi-panel[hidden] { display: none; }
.poi-head { display: flex; align-items: flex-start; justify-content: space-between; gap: .8rem; padding: 1rem 1rem .35rem; }
.poi-head h2 { margin: 0; font-size: 1.3rem; letter-spacing: -.025em; }
.poi-head .eyebrow { margin-bottom: .18rem; }
.poi-close { position: static; flex: 0 0 auto; }
.poi-intro { margin: 0; padding: 0 1rem .65rem; color: var(--muted); font-size: .7rem; line-height: 1.42; }
.poi-filter { margin: 0 .75rem .5rem; border: 1px solid var(--line); border-radius: .6rem; background: var(--surface-3); }
.poi-filter summary { display: flex; align-items: center; justify-content: space-between; gap: .6rem; padding: .55rem .65rem; color: var(--strong); cursor: pointer; font-size: .7rem; font-weight: 850; list-style: none; }
.poi-filter summary::-webkit-details-marker { display: none; }
.poi-filter summary::before { content: "▸"; margin-right: .15rem; font-size: .72rem; transition: transform .15s ease; }
.poi-filter[open] summary::before { transform: rotate(90deg); }
.poi-filter summary span { margin-left: auto; color: var(--muted); font-size: .61rem; font-weight: 750; }
.poi-filter-options { display: grid; grid-template-columns: 1fr 1fr; gap: .2rem .35rem; padding: 0 .55rem .5rem; }
.poi-filter-option { min-width: 0; display: grid; grid-template-columns: auto 1.35rem minmax(0, 1fr) auto; align-items: center; gap: .3rem; padding: .3rem .28rem; border-radius: .42rem; color: var(--ink-2); cursor: pointer; font-size: .61rem; }
.poi-filter-option:hover { background: var(--surface-2); }
.poi-filter-option input { width: 14px; height: 14px; margin: 0; accent-color: var(--moss); }
.poi-filter-option i { width: 1.25rem; height: 1.25rem; display: grid; place-items: center; border-radius: 50%; color: white; background: var(--poi-color, var(--forest)); font-style: normal; font-size: .62rem; font-weight: 900; }
.poi-filter-option span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.poi-filter-option small { color: var(--muted); font-size: .56rem; }
.poi-filter-actions { display: flex; gap: .35rem; padding: .45rem .55rem .55rem; border-top: 1px solid var(--line); }
.poi-filter-actions button { flex: 1; padding: .4rem .35rem; border: 1px solid var(--line); border-radius: .42rem; color: var(--moss); background: var(--surface); cursor: pointer; font-size: .59rem; font-weight: 800; }
.poi-filter-actions button:hover { background: var(--surface-2); }
.poi-status { margin: 0 .75rem .45rem; padding: .52rem .62rem; border-radius: .55rem; color: var(--ink-2); background: var(--surface-2); font-size: .68rem; line-height: 1.35; }
.poi-list { min-height: 0; overflow-y: auto; padding: 0 .55rem .55rem; }
.poi-card { width: 100%; display: grid; grid-template-columns: 2.2rem minmax(0,1fr) auto; align-items: center; gap: .55rem; padding: .6rem .55rem; border: 0; border-bottom: 1px solid var(--line); border-radius: .55rem; color: inherit; background: transparent; text-align: left; cursor: pointer; }
.poi-card[hidden] { display: none; }
.poi-card:hover, .poi-card:focus-visible, .poi-card.active { outline: none; background: var(--surface-2); }
.poi-card.active { box-shadow: inset 3px 0 var(--strong-line); }
.poi-card-icon { width: 2rem; height: 2rem; display: grid; place-items: center; border-radius: 50%; color: white; background: var(--forest); font-size: .92rem; font-weight: 900; }
.poi-card-main { min-width: 0; }
.poi-card-main strong { display: block; overflow: hidden; font-size: .75rem; line-height: 1.25; text-overflow: ellipsis; white-space: nowrap; }
.poi-card-main small { display: block; margin-top: .16rem; overflow: hidden; color: var(--muted); font-size: .61rem; text-overflow: ellipsis; white-space: nowrap; }
.poi-card-distance { color: var(--moss); font-size: .62rem; font-weight: 850; white-space: nowrap; }
.poi-attribution { margin: 0; padding: .5rem .8rem .65rem; border-top: 1px solid var(--line); color: var(--muted); background: var(--surface-3); font-size: .55rem; line-height: 1.35; }
.poi-marker-wrap { background: none; border: 0; }
.poi-marker { width: 26px; height: 26px; display: grid; place-items: center; border: 2.5px solid var(--poi-color, var(--strong-line)); border-radius: 50%; color: var(--poi-color, var(--strong)); background: var(--surface); box-shadow: 0 2px 7px rgba(17,43,30,.3); font-size: .78rem; font-weight: 900; transition: transform .12s ease, box-shadow .12s ease; }
.poi-marker span { line-height: 1; }
.poi-marker.active { color: #fff; background: var(--poi-color, var(--forest)); border-color: #fff; box-shadow: 0 0 0 4px rgba(31,42,55,.28), 0 4px 12px rgba(17,43,30,.4); transform: scale(1.25); }
.poi-viewpoint { --poi-color: #c2500a; }
.poi-tower { --poi-color: #8b5e34; }
.poi-castle { --poi-color: #8a4f3d; }
.poi-historic { --poi-color: #a46b35; }
.poi-nature { --poi-color: #287d55; }
.poi-attraction { --poi-color: #b07a12; }
.poi-picnic { --poi-color: #4d7d3a; }
.poi-fuel { --poi-color: #365f8d; }
.poi-food { --poi-color: #a24f35; }
.poi-service { --poi-color: #3c7d86; }
.poi-card-icon[class*="poi-"] { background: var(--poi-color, var(--forest)); }
.poi-popup strong { display: block; margin-bottom: .15rem; }
.poi-popup small { color: var(--muted); }
.poi-popup a { display: inline-block; margin-top: .35rem; color: var(--moss); font-weight: 800; }
.planner-head { display: flex; align-items: flex-start; justify-content: space-between; gap: .8rem; }
.planner-head h2 { margin: 0; font-size: 1.3rem; letter-spacing: -.025em; }
.planner-head .eyebrow { margin-bottom: .18rem; }
.planner-close { position: static; flex: 0 0 auto; }
.planner-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: .35rem; margin: .9rem 0 .7rem; padding: .3rem; border-radius: .7rem; background: var(--surface-2); }
.planner-tab { padding: .58rem .45rem; border: 0; border-radius: .5rem; background: transparent; color: var(--muted); font-size: .78rem; font-weight: 800; cursor: pointer; }
.planner-tab.active { color: white; background: var(--forest); box-shadow: 0 4px 12px rgba(29,33,59,.18); }
.route-profile-field { display: grid; gap: .38rem; margin-bottom: .72rem; }
.route-profile-field > span { color: var(--muted); font-size: .68rem; font-weight: 850; }
.route-profile-switch { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .22rem; padding: .25rem; border-radius: .65rem; background: var(--surface-2); }
.route-profile-switch button { min-width: 0; padding: .48rem .18rem; overflow: hidden; border: 0; border-radius: .45rem; color: var(--muted); background: transparent; cursor: pointer; font-size: .64rem; font-weight: 850; text-overflow: ellipsis; white-space: nowrap; }
.route-profile-switch button.active { color: white; background: var(--navy); box-shadow: 0 3px 9px rgba(63,35,116,.2); }
.route-profile-switch button:disabled { cursor: wait; opacity: .55; }
.route-profile-field p { margin: 0; color: var(--muted); font-size: .64rem; line-height: 1.38; }
.planner-instructions { padding: .65rem .72rem; border-left: 3px solid var(--strong-line); border-radius: 0 .5rem .5rem 0; color: var(--ink-2); background: var(--surface); font-size: .78rem; line-height: 1.4; }
.waypoint-list { list-style: none; margin: .6rem 0 0; padding: 0; display: grid; gap: .3rem; }
.waypoint-list[hidden], .waypoint-tools[hidden], .loop-points-note[hidden] { display: none; }
.waypoint-item { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: .45rem; padding: .32rem .4rem; border: 1px solid var(--line); border-radius: .5rem; background: var(--surface); font-size: .72rem; }
.waypoint-badge { display: inline-grid; place-items: center; min-width: 1.45rem; height: 1.45rem; padding: 0 .3rem; border-radius: 999px; color: white; background: var(--navy); font-weight: 800; font-size: .68rem; }
.waypoint-text { min-width: 0; overflow: hidden; color: var(--ink); white-space: nowrap; text-overflow: ellipsis; }
.waypoint-actions { display: inline-flex; gap: .2rem; }
.waypoint-item.is-off-route { border-color: var(--warn-line); background: var(--warn-bg); }
.waypoint-gap { grid-column: 2 / 4; margin-top: -.15rem; color: var(--warn-ink); font-size: .66rem; line-height: 1.35; }
.result-gap-warning[hidden] { display: none; }
.waypoint-actions button { width: 1.6rem; height: 1.6rem; padding: 0; border: 1px solid var(--line); border-radius: .4rem; color: var(--ink); background: var(--surface-3); font: inherit; font-size: .78rem; line-height: 1; cursor: pointer; }
.waypoint-actions button:hover:not(:disabled) { border-color: var(--strong-line); color: var(--strong); }
.waypoint-actions button:disabled { opacity: .35; cursor: default; }
.waypoint-actions button:focus-visible, .text-button:focus-visible { outline: 2px solid var(--strong); outline-offset: 1px; }
.waypoint-tools { display: flex; justify-content: flex-end; margin-top: .3rem; }
.text-button { padding: .2rem .1rem; border: 0; color: var(--strong); background: none; font: inherit; font-size: .72rem; font-weight: 800; cursor: pointer; }
.loop-points-note { margin: .6rem 0 0; color: var(--muted); font-size: .72rem; }
.planner-field { display: grid; gap: .35rem; margin-top: .75rem; }
.planner-field[hidden] { display: none; }
.planner-field label { color: var(--muted); font-size: .7rem; font-weight: 800; }
.planner-field select { width: 100%; padding: .62rem .68rem; border: 1px solid var(--line); border-radius: .55rem; color: var(--ink); background: var(--surface); font: inherit; font-size: .82rem; }
.optional-forest-control { display: flex; align-items: flex-start; gap: .55rem; margin-top: .65rem; padding: .62rem .7rem; border: 1px solid var(--warn-line); border-radius: .6rem; background: var(--warn-bg); cursor: pointer; }
.optional-forest-control input { margin-top: .14rem; accent-color: var(--forest); }
.optional-forest-control span { display: grid; gap: .15rem; }
.optional-forest-control strong { color: var(--warn-ink); font-size: .73rem; }
.optional-forest-control.is-highlighted { border-color: var(--warn-line); box-shadow: 0 0 0 3px rgba(224, 165, 38, .45); }
.profile-suggestions { display: grid; gap: .4rem; margin-top: .5rem; font-size: .72rem; color: var(--ink); }
.profile-suggestions[hidden] { display: none; }
.profile-suggestions p { margin: 0; }
.profile-suggestion-buttons { display: flex; flex-wrap: wrap; gap: .4rem; }
.optional-forest-hint { display: grid; gap: .45rem; margin-top: .5rem; padding: .55rem .65rem; border: 1px solid var(--warn-line); border-radius: 8px; color: var(--warn-ink); background: var(--warn-bg); font-size: .72rem; line-height: 1.4; }
.optional-forest-hint[hidden] { display: none; }
.optional-forest-hint p { margin: 0; }
.optional-forest-hint button { justify-self: start; }
.optional-forest-control small { color: var(--warn-ink); font-size: .65rem; line-height: 1.4; }
.planner-actions { display: grid; grid-template-columns: 1fr auto; gap: .45rem; margin-top: .8rem; }
.planner-actions .primary-button { font-size: .78rem; }
.planner-actions .primary-button:disabled { cursor: not-allowed; opacity: .45; }
.secondary-button { padding: .65rem .75rem; color: var(--moss); background: var(--surface-2); font-size: .76rem; }
.planner-status { margin-top: .65rem; color: var(--muted); font-size: .72rem; line-height: 1.4; }
.planner-status.is-warning { color: var(--warn-ink); background: var(--warn-bg); border: 1px solid var(--warn-line); border-radius: 8px; padding: .5rem .6rem; font-size: .76rem; }
.planner-status.is-error { color: var(--danger-ink); background: var(--danger-bg); border: 1px solid var(--danger-line); border-radius: 8px; padding: .5rem .6rem; font-size: .76rem; }
.route-result { margin-top: .8rem; padding-top: .8rem; border-top: 1px solid var(--line); }
.variant-nav { display: grid; grid-template-columns: 2.6rem 1fr 2.6rem; align-items: center; gap: .55rem; margin-bottom: .65rem; text-align: center; }
.variant-nav[hidden] { display: none; }
.variant-cards { display: grid; gap: .35rem; margin-bottom: .7rem; }
.variant-cards[hidden] { display: none; }
.variant-card { display: grid; grid-template-columns: auto auto 1fr; align-items: center; gap: .5rem; width: 100%; padding: .45rem .55rem; border: 1px solid var(--line); border-radius: .55rem; color: var(--ink); background: var(--surface); font: inherit; font-size: .74rem; text-align: left; cursor: pointer; }
.variant-card:hover { border-color: var(--line-4); }
.variant-card[aria-pressed="true"] { border-color: var(--strong-line); box-shadow: inset 0 0 0 1px var(--strong-line); background: var(--accent-tint); }
.variant-card:focus-visible { outline: 2px solid var(--strong); outline-offset: 1px; }
.variant-swatch { width: 1.4rem; height: .38rem; border-radius: 999px; }
.variant-stats { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: .2rem .6rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.variant-stats small { font-size: .64rem; }
.variant-note { grid-column: 2 / -1; font-size: .75rem; font-weight: 650; line-height: 1.3; }
.variant-notes-status { margin: -.25rem 0 .7rem; color: var(--muted); font-size: .73rem; }
.variant-nav small { display: block; color: var(--muted); font-size: .62rem; }
.variant-nav strong { display: block; margin-top: .08rem; font-size: .88rem; }
.variant-arrow { width: 2.6rem; height: 2.6rem; border: 0; border-radius: 50%; color: white; background: var(--navy); cursor: pointer; font-size: 1.25rem; font-weight: 800; line-height: 1; box-shadow: 0 2px 8px rgba(29,33,59,.17); }
.variant-arrow:hover { background: #2a2f52; }
.variant-arrow:focus-visible { outline: 3px solid rgba(197,227,79,.6); outline-offset: 2px; }
.result-stats { display: grid; grid-template-columns: 1fr 1fr; gap: .4rem; }
.result-stats div { padding: .55rem .62rem; border-radius: .55rem; background: var(--surface-3); }
.result-stats small { display: block; color: var(--muted); font-size: .62rem; }
.result-stats strong { display: block; margin-top: .12rem; font-size: .82rem; }
.result-forest-note { margin: .45rem 0 0; color: var(--muted); font-size: .62rem; }
.result-forest-note strong { color: var(--ink); }
.result-road-types { margin-top: .55rem; padding: .58rem .62rem; border: 1px solid var(--line); border-radius: .55rem; background: var(--surface-3); }
.result-road-types > small { display: block; margin-bottom: .38rem; color: var(--muted); font-size: .62rem; font-weight: 800; }
#result-road-breakdown, #result-level-breakdown { display: flex; flex-wrap: wrap; gap: .28rem; }
.road-type-chip { display: inline-flex; align-items: center; gap: .28rem; padding: .25rem .36rem; border-radius: 999px; background: var(--surface-2); color: var(--ink); font-size: .59rem; font-weight: 750; }
.road-type-chip i { width: 7px; height: 7px; border-radius: 50%; }
.result-level-notice p { margin: 0; }
.result-level-notice p + p { margin-top: .3rem; }
.result-warning { margin-top: .6rem; padding: .6rem .7rem; border-left: 3px solid var(--candidate); border-radius: 0 .5rem .5rem 0; color: var(--warn-ink); background: var(--warn-bg); font-size: .68rem; line-height: 1.42; }
.result-actions { display: grid; grid-template-columns: 1fr 1fr; gap: .4rem; margin-top: .55rem; }
.result-actions .secondary-button { padding: .55rem .45rem; font-size: .68rem; }
.osmand-button { width: 100%; margin-top: .6rem; padding: .68rem .75rem; color: white; background: var(--navy); font-size: .78rem; }
.planner-sources { margin-top: .72rem; color: var(--muted); font-size: .67rem; line-height: 1.42; }
.planner-sources summary { color: var(--moss); font-weight: 800; cursor: pointer; }
.planner-sources p { margin: .35rem 0 0; }
.planner-marker-wrap { background: none; border: 0; }
.ford-marker-wrap { background: none; border: 0; }
.ford-marker { width: 28px; height: 28px; display: grid; place-items: center; border: 3px solid #ffffff; border-radius: 50%; color: #ffffff; background: var(--sev-ford); box-shadow: 0 3px 10px rgba(10,40,90,.45); }
.variant-badge.variant-badge-ford { color: #0f4c8f; background: #d9e9fb; }
.planner-marker { width: 34px; height: 34px; display: grid; place-items: center; border: 3px solid white; border-radius: 50% 50% 50% 5px; color: white; background: var(--navy); box-shadow: 0 5px 14px rgba(40,24,72,.38); font-size: .78rem; font-weight: 900; transform: rotate(-45deg); }
.planner-marker b { transform: rotate(45deg); }
.planner-marker { line-height: 1; }
.planner-marker { text-indent: 0; }
.legend-line.planned { border-color: var(--route); }
.profile-panel { position: fixed; left: 72px; right: 0; bottom: 0; z-index: 1000; height: var(--profile-height); display: grid; grid-template-columns: 148px minmax(0, 1fr); border-top: 1px solid var(--line-2); background: var(--surface); box-shadow: 0 -12px 35px rgba(29,33,59,.15); }
.profile-panel[hidden] { display: none; }
.profile-controls { min-width: 0; padding: .9rem 1rem; border-right: 1px solid var(--line); background: var(--surface-3); overflow-y: auto; }
.profile-controls .eyebrow { margin-bottom: .55rem; font-size: .66rem; letter-spacing: .08em; white-space: nowrap; }
.profile-panel-content { margin-top: .55rem; }
.profile-switch { display: grid; grid-template-columns: 1fr; gap: .3rem; padding: .25rem; border-radius: .65rem; background: var(--surface-4); }
.profile-mode { padding: .52rem .35rem; border: 0; border-radius: .48rem; color: var(--muted); background: transparent; font-size: .72rem; font-weight: 850; cursor: pointer; }
.profile-mode.active { color: white; background: var(--forest); box-shadow: 0 3px 10px rgba(29,33,59,.18); }
.profile-chart-wrap { position: relative; min-width: 0; padding: .75rem 1.2rem .55rem; overflow: hidden; }
.profile-chart-head { display: flex; align-items: flex-start; justify-content: space-between; min-height: 38px; }
.profile-chart-head h2 { margin: 0; font-size: .9rem; letter-spacing: -.015em; }
.profile-chart-head p { margin: .2rem 0 0; color: var(--muted); font-size: .62rem; }
.terrain-legend { display: flex; align-items: center; justify-content: flex-end; gap: .55rem; color: var(--muted); font-size: .6rem; white-space: nowrap; }
.terrain-legend strong { color: var(--ink); font-size: .62rem; }
.terrain-legend span { display: inline-flex; align-items: center; gap: .22rem; }
.terrain-legend i { width: 9px; height: 9px; border-radius: 2px; }
.terrain-legend .terrain-paved { background: #7c8794; }
.terrain-legend .terrain-light { background: #2f9e6b; }
.terrain-legend .terrain-medium { background: #e0a019; }
.terrain-legend .terrain-hard { background: #d4532b; }
.terrain-legend .terrain-blocked { background: #b3321f; }
#profile-chart { width: 100%; height: calc(100% - 38px); min-height: 150px; overflow: visible; }
#profile-chart text { fill: var(--muted); font: 11px Inter, ui-sans-serif, system-ui, sans-serif; }
#profile-chart .axis-line { stroke: var(--line); stroke-width: 1; }
#profile-chart .grid-line { stroke: var(--line); stroke-width: 1; stroke-dasharray: 4 5; }
#profile-chart .road-segment { stroke: rgba(255,255,255,.72); stroke-width: .6; }
#profile-chart .terrain-band-bg { fill: var(--surface-2); stroke: rgba(29,33,59,.12); stroke-width: 1; }
#profile-chart .terrain-segment { stroke: rgba(255,255,255,.65); stroke-width: .7; }
#profile-chart .terrain-grid-line { stroke: var(--line); stroke-width: 1; }
#profile-chart .terrain-difficulty-block { stroke: rgba(255,255,255,.8); stroke-width: 1; opacity: .92; }
#profile-chart .elevation-area { fill: rgba(59,91,219,.14); }
#profile-chart .elevation-line { fill: none; stroke: var(--route); stroke-width: 3; vector-effect: non-scaling-stroke; }
.profile-tooltip { position: absolute; z-index: 2; top: 58px; width: max-content; max-width: min(340px, calc(100% - 16px)); padding: .42rem .55rem; border: 1px solid var(--line); border-radius: .45rem; color: white; background: rgba(29,33,59,.94); box-shadow: 0 5px 14px rgba(29,33,59,.2); font-size: .64rem; line-height: 1.35; pointer-events: none; transform: translateX(-50%); white-space: normal; overflow-wrap: anywhere; }
.leaflet-control-attribution { font-size: 10px; }
.leaflet-interactive { transition: stroke-width .12s ease, opacity .12s ease; }
.profile-map-position { filter: drop-shadow(0 2px 5px rgba(35,20,65,.55)); }

dialog { color: var(--ink); border: 0; border-radius: 1rem; box-shadow: var(--shadow); }
dialog::backdrop { background: rgba(17,20,38,.58); backdrop-filter: blur(2px); }
.dialog-close { position: absolute; top: .75rem; right: .75rem; width: 34px; height: 34px; border: 0; display: grid; place-items: center; padding: 0 0 .12em; border-radius: 50%; background: var(--surface-2); color: var(--ink); font-size: 1.4rem; line-height: 1; cursor: pointer; }
.detail-dialog { width: min(570px, calc(100% - 2rem)); max-height: calc(100% - 2rem); padding: 1.35rem; }
.detail-dialog h2 { margin: .2rem 2.3rem .35rem 0; font-size: 1.45rem; line-height: 1.1; }
.low-terrain-dialog { width: min(460px, calc(100% - 2rem)); }
.low-terrain-dialog h2 { margin-right: 0; }
.low-terrain-dialog p { line-height: 1.5; }
.low-terrain-actions { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: .65rem; margin-top: 1rem; }
.status-pill { display: inline-flex; align-items: center; gap: .35rem; padding: .34rem .54rem; border-radius: 99px; font-size: .69rem; font-weight: 850; }
.status-pill.kandidat { color: #514000; background: #fff0ac; }
.status-pill.nezname { color: white; background: var(--unknown); }
.status-pill.zakaz { color: white; background: var(--forbidden); }
.status-pill.potvrdeny { color: white; background: var(--confirmed); }
.detail-meta { display: grid; grid-template-columns: repeat(3, 1fr); gap: .5rem; margin: 1rem 0; }
.detail-meta div { padding: .65rem; border: 1px solid var(--line); border-radius: .6rem; background: var(--surface-3); }
.detail-meta small { display: block; color: var(--muted); font-size: .65rem; }
.detail-meta strong { display: block; margin-top: .18rem; font-size: .82rem; }
.evidence-box { margin-top: .7rem; padding: .8rem; border-radius: .65rem; background: var(--surface-3); font-size: .8rem; line-height: 1.48; }
.evidence-box.warning { background: var(--warn-bg); }
.evidence-box h3 { margin: 0 0 .25rem; font-size: .72rem; text-transform: uppercase; letter-spacing: .07em; }
.detail-actions { display: flex; flex-wrap: wrap; gap: .55rem; margin-top: 1rem; }
.detail-actions a { padding: .58rem .7rem; border-radius: .55rem; color: var(--moss); background: var(--surface-2); font-size: .74rem; font-weight: 800; text-decoration: none; }
.about-dialog { width: min(760px, calc(100% - 2rem)); padding: 1.5rem; }
.about-dialog h2 { max-width: 620px; margin: .1rem 2rem 1.2rem 0; font-size: 1.6rem; }
.news-dialog { max-width: 520px; }
.news-release { padding-top: .85rem; border-top: 1px solid var(--line); }
.news-release + .news-release { margin-top: 1rem; }
.news-release h3 { margin: 0 0 .45rem; font-size: .85rem; color: var(--moss); }
.news-release ul { margin: 0; padding-inline-start: 1.2rem; line-height: 1.55; }
.news-release li + li { margin-top: .35rem; }
.method-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .7rem; }
.method-grid article { position: relative; padding: .85rem .9rem; border: 1px solid var(--line); border-radius: .7rem; }
.method-grid h3 { margin: 0 0 .25rem; font-size: .88rem; }
.method-grid p { margin: 0; color: var(--muted); font-size: .77rem; line-height: 1.45; }
.status-dot { position: absolute; top: .95rem; left: .85rem; width: 10px; height: 10px; border-radius: 50%; background: var(--unknown); }
.status-dot.candidate { background: var(--candidate); }
.status-dot.forbidden { background: var(--forbidden); }
.status-dot.confirmed { background: var(--confirmed); }
.about-note { margin: 1rem 0; color: var(--muted); font-size: .8rem; }
.about-links { display: flex; flex-wrap: wrap; gap: .55rem; }
.secondary-button.inline { display: inline-flex; align-items: center; padding: .68rem .9rem; border: 1px solid var(--line); color: var(--moss); background: var(--surface); text-decoration: none; }
.about-profiles { margin-top: 1.15rem; padding-top: 1rem; border-top: 1px solid var(--line); }
.about-section-head h3 { margin: .18rem 0 .35rem; font-size: 1.1rem; }
.about-section-head > p:last-child { margin: 0; color: var(--muted); font-size: .78rem; line-height: 1.55; }
.profile-explainer { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .65rem; margin-top: .8rem; }
.profile-explainer article { padding: .78rem; border: 1px solid var(--line); border-radius: .72rem; background: var(--surface-3); }
.profile-explainer strong { color: var(--strong); font-size: .8rem; }
.profile-explainer p { margin: .28rem 0 0; color: var(--muted); font-size: .72rem; line-height: 1.48; }
.level-explainer article[data-level] { border-left-width: 4px; }
.level-explainer article[data-level="paved"] { border-left-color: #7c8794; }
.level-explainer article[data-level="light"] { border-left-color: #2f9e6b; }
.level-explainer article[data-level="medium"] { border-left-color: #e0a019; }
.level-explainer article[data-level="hard"] { border-left-color: #d4532b; }
.level-explainer article[data-level="blocked"] { border-left-color: #b3321f; }

.legal-page { min-height: 100%; height: auto; padding: 2rem 1rem 4rem; background: var(--surface-2); }
.legal-page main { width: min(900px, 100%); margin: 0 auto; padding: clamp(1.2rem, 4vw, 2.4rem); border: 1px solid var(--line); border-radius: 1rem; background: var(--surface); box-shadow: var(--shadow); }
.legal-page h1 { margin: .2rem 0 .65rem; font-size: clamp(1.8rem, 5vw, 2.6rem); letter-spacing: -.04em; }
.legal-page h2 { margin: 1.7rem 0 .5rem; font-size: 1.15rem; }
.legal-page p, .legal-page li { color: var(--ink-2); line-height: 1.62; }
.legal-page .lead { margin-top: 0; color: var(--muted); }
.legal-page .legal-callout { padding: .85rem 1rem; border-left: 4px solid var(--candidate); border-radius: 0 .6rem .6rem 0; background: var(--warn-bg); }
.legal-page a { color: var(--moss); }
.legal-page .back-link { display: inline-flex; margin-bottom: .8rem; font-weight: 800; text-decoration: none; }

@media (max-width: 760px) {
  :root { --profile-height: 290px; }
  .topbar { height: 60px; gap: .4rem; padding: 0 .7rem; }
  .brand { gap: .45rem; }
  .brand-logo { width: 76px; height: 39px; }
  .brand small { display: none; }
  .topbar-actions { gap: .35rem; }
  .topbar-actions .ghost-button { min-height: 40px; padding: .35rem .5rem; font-size: .75rem; }
  .language-picker-label { display: none; }
  .language-picker select { min-width: 58px; padding: .42rem 1.45rem .42rem .5rem; }
  .tool-rail { display: none; }
  .primary-button { padding: .6rem .7rem; font-size: .75rem; }
  .workspace { width: 100%; height: calc(100% - 60px); display: block; margin-left: 0; }
  body.profile-visible .workspace, body.profile-visible.profile-collapsed .workspace { height: calc(100% - 60px); }
  .map-shell { height: 100%; }
  .planner-panel {
    top: auto;
    right: 8px;
    left: 8px;
    bottom: max(8px, env(safe-area-inset-bottom));
    width: calc(100% - 16px);
    max-height: 58%;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    border-radius: .9rem .9rem .7rem .7rem;
  }
  .planner-close { display: none; }
  .mobile-adventure-note { display: block; margin: 0 0 .75rem; padding: .65rem .72rem; border-left: 4px solid var(--lime); border-radius: 0 .55rem .55rem 0; color: var(--ink-2); background: #f1f7df; font-size: .68rem; line-height: 1.42; }
  .map-tool-panel, .poi-panel, .profile-panel { display: none !important; }
  .planner-head { position: sticky; top: -1rem; z-index: 2; margin: -1rem -1rem .8rem; padding: 1rem 1rem .55rem; background: rgba(255,255,255,.98); }
  .planner-head::before { content: ""; position: absolute; top: .36rem; left: 50%; width: 38px; height: 4px; border-radius: 99px; background: #c3c7d4; transform: translateX(-50%); }
  .poi-panel { top: 8px; left: 8px; width: calc(100% - 16px); max-height: calc(100% - 16px); }
  .profile-panel { grid-template-columns: 1fr; grid-template-rows: auto minmax(0, 1fr); }
  .profile-controls { padding: .55rem .7rem; border-right: 0; border-bottom: 1px solid var(--line); overflow: visible; }
  .profile-controls .eyebrow { display: none; }
  .profile-switch { width: auto; }
  .profile-chart-wrap { padding: .5rem .65rem .35rem; }
  .profile-chart-head { min-height: 34px; }
  .profile-chart-head p { display: none; }
  .terrain-legend strong { display: none; }
  .terrain-legend { gap: .35rem; font-size: .55rem; }
  #profile-chart { min-height: 145px; height: calc(100% - 32px); }
  .map-legend { left: 10px; right: 10px; bottom: 12px; justify-content: center; }
  .method-grid { grid-template-columns: 1fr; }
  .detail-meta { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 440px) {
  .brand strong { display: none; }
}

@media (max-width: 480px) {
  .profile-explainer { grid-template-columns: 1fr; }
  .profile-switch { width: auto; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}

/* ADV-P1-36: oznam o výpočte v strede mapy. */
.calc-overlay { position: absolute; top: 50%; left: 50%; z-index: 900; display: flex; align-items: center; gap: .8rem; max-width: min(420px, calc(100% - 2rem)); padding: .85rem 1.1rem; border-radius: .9rem; color: #fff; background: rgba(29,33,59,.94); box-shadow: 0 10px 30px rgba(0,0,0,.28); transform: translate(-50%,-50%); pointer-events: none; }
.calc-overlay[hidden] { display: none; }
.calc-overlay strong { display: block; color: var(--lime); font-size: .95rem; }
.calc-overlay span { display: block; margin-top: .15rem; font-size: .74rem; line-height: 1.35; color: #e6e9f5; }
.calc-spinner { flex: none; width: 26px; height: 26px; border: 3px solid rgba(197,227,79,.25); border-top-color: var(--lime); border-radius: 50%; animation: calc-spin .9s linear infinite; }
@keyframes calc-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .calc-spinner { animation-duration: 2.4s; } }
/* Zvolená úroveň navrchu informácií o trase. */
.result-profile { display: flex; align-items: baseline; flex-wrap: wrap; gap: .25rem .55rem; margin-bottom: .65rem; padding: .55rem .7rem; border-radius: .6rem; color: #fff; background: var(--navy); }
.result-profile small { color: #c9cde0; font-size: .64rem; text-transform: uppercase; letter-spacing: .05em; }
.result-profile strong { color: var(--lime); font-size: 1rem; }
.result-profile span { margin-left: auto; color: #e6e9f5; font-size: .7rem; }
/* Prvá návšteva: návod v troch krokoch, rada ku GPX, zrušenie výpočtu, skryté vývojárske prvky. */
.planner-steps { display: grid; gap: .3rem; margin: 0 0 .75rem; padding: .6rem .72rem .6rem 1.9rem; border-radius: .55rem; color: var(--ink); background: var(--surface-2); font-size: .76rem; font-weight: 650; line-height: 1.35; }
.planner-steps li::marker { color: var(--moss); font-weight: 850; }
.result-next-note { margin: .5rem 0 0; color: var(--muted); font-size: .66rem; line-height: 1.4; }
.calc-overlay small { display: block; margin-top: .2rem; font-size: .66rem; color: #b9bfd6; }
.calc-cancel { margin-left: .3rem; padding: .42rem .7rem; border: 1px solid rgba(255,255,255,.45); border-radius: .5rem; color: #fff; background: transparent; font: inherit; font-size: .74rem; font-weight: 800; cursor: pointer; pointer-events: auto; }
.calc-cancel:hover { background: rgba(255,255,255,.14); }
body:not(.dev-tools) .map-zoom-debug { display: none; }
.result-match-note { margin: .45rem 0 0; color: var(--muted); font-size: .64rem; line-height: 1.4; }
/* Orientácia pre nového návštevníka: popisy ikon, odporúčaný variant, rada na úpravu, legenda, mobil. */
.tool-button { margin-bottom: 19px; }
.tool-caption { position: absolute; top: calc(100% + 4px); left: 50%; width: 56px; color: #e7e9f3; font-size: .54rem; font-weight: 800; line-height: 1.1; text-align: center; transform: translateX(-50%); pointer-events: none; }
.tool-button::after { display: none; }
.planner-status:empty { display: none; }
.variant-badge { margin-left: .15rem; padding: .08rem .32rem; border-radius: 999px; color: #2f5f1c; background: #e4f3d2; font-size: .56rem; font-weight: 850; vertical-align: middle; white-space: nowrap; }
.result-edit-hint { margin: .45rem 0 .6rem; color: var(--muted); font-size: .64rem; line-height: 1.4; }
.map-key.variant-lines { height: 4px; border-radius: 0; background: linear-gradient(90deg, #0c8599 0 25%, #c2255c 25% 50%, #e8590c 50% 75%, #1f2a37 75%); }
.map-key.forest-route { height: 0; border-top: 4px dashed #ffb000; border-radius: 0; }
.map-key.planner-point { width: 14px; height: 14px; margin: 0 12px; border: 2px solid #fff; border-radius: 50% 50% 50% 3px; background: var(--navy); box-shadow: 0 1px 4px rgba(40,24,72,.4); transform: rotate(-45deg); }
.map-key.poi-point { width: 14px; height: 14px; margin: 0 12px; border: 2.5px solid #c2500a; border-radius: 50%; background: var(--surface); }
@media (max-width: 760px) {
  /* Na telefóne má byť pokyn a tlačidlo čo najvyššie: upozornenie ostáva jedným riadkom. */
  .legal-warning span { display: none; }
  .legal-warning { padding-top: .45rem; padding-bottom: .45rem; }
}
/* Vyhľadanie miesta a moja poloha. */
.place-search { display: flex; gap: .35rem; margin: 0 0 .5rem; }
.place-search input { flex: 1; min-width: 0; padding: .5rem .6rem; border: 1px solid var(--line); border-radius: .55rem; color: var(--ink); background: var(--surface); font: inherit; font-size: .78rem; }
.place-search input:focus-visible { outline: 2px solid var(--strong); outline-offset: 1px; }
.place-search button { flex: 0 0 auto; padding: .5rem .65rem; font-size: .72rem; }
.place-search .place-locate { display: grid; place-items: center; width: 2.3rem; padding: 0; }
.place-locate svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.place-results { display: grid; gap: .25rem; margin: 0 0 .75rem; }
.place-results[hidden] { display: none; }
.place-result { display: grid; gap: .08rem; width: 100%; padding: .42rem .55rem; border: 1px solid var(--line); border-radius: .5rem; color: var(--ink); background: var(--surface); font: inherit; text-align: left; cursor: pointer; }
.place-result:hover, .place-result:focus-visible { border-color: var(--strong-line); outline: none; }
.place-result strong { font-size: .76rem; }
.place-result small { color: var(--muted); font-size: .64rem; }
.place-message { margin: 0; color: var(--muted); font-size: .7rem; line-height: 1.4; }
/* Vymazanie bodov priamo z mapy (pod ovládaním priblíženia). */
.map-clear-button { position: absolute; top: 88px; right: 10px; z-index: 640; display: inline-flex; align-items: center; gap: .35rem; padding: .42rem .6rem; border: 2px solid rgba(0,0,0,.2); border-radius: .5rem; color: var(--danger-ink); background: var(--surface); background-clip: padding-box; font: inherit; font-size: .72rem; font-weight: 800; cursor: pointer; }
.map-clear-button[hidden] { display: none; }
.map-clear-button:hover, .map-clear-button:focus-visible { background: var(--danger-bg); outline: none; }
.map-clear-button svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
/* ===== Smer A – evolúcia navy + lime (13. 11. 2026): oddelené karty na neutrálnom podklade. ===== */
h2, .brand strong { letter-spacing: -.01em; }
.eyebrow { color: var(--muted); font-weight: 700; letter-spacing: .08em; }
.topbar { gap: 1rem; padding: 0 1rem 0 12px; border-bottom: 0; }
.brand-logo { width: 44px; height: 44px; }
@media (min-width: 761px) {
  /* Značka je vycentrovaná nad 72 px stĺpcom nástrojov; nápis začína na ľavej hrane obsahu panela (72 + 16 px). */
  .topbar { padding-left: 0; }
  .brand { gap: 16px; }
  .brand-logo { width: 72px; height: 56px; display: grid; place-items: center; }
  .brand-logo img { width: 48px; height: 48px; }
}
.brand strong { font-size: 1.3rem; font-weight: 800; }
.brand strong span { color: var(--lime); font-weight: 600; }
.ghost-button { min-height: 44px; padding: 0 .75rem; color: #e7e9f3; background: transparent; font-weight: 500; }
.ghost-button:hover, .ghost-button:focus-visible { background: var(--navy-2); outline: none; }
.language-picker select { min-height: 36px; border-color: #4a5080; background-color: var(--navy-2); font-weight: 600; }
.primary-button { color: var(--navy); background: var(--lime); }
.primary-button:hover:not(:disabled) { background: #d2ee6a; }
.secondary-button { color: var(--strong); background: var(--surface); border: 1px solid var(--line-3); }
.secondary-button:hover:not(:disabled) { background: var(--surface-2); }
.dialog-close { background: var(--surface); border: 1px solid var(--line); }
.dialog-close:hover { background: var(--surface-2); }

.tool-rail { align-items: center; gap: 6px; padding: 12px 6px; border-right: 0; box-shadow: none; }
.tool-button { width: 60px; min-height: 56px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; margin: 0; border: 0; border-radius: 12px; color: #aab0cc; background: transparent; }
.tool-button[hidden] { display: none; }
.tool-button svg { width: 22px; height: 22px; }
.tool-button:hover, .tool-button:focus-visible { color: #fff; background: var(--navy-2); transform: none; box-shadow: none; }
.tool-button:focus-visible { outline: 2px solid var(--lime); outline-offset: 1px; }
.tool-button.active, .tool-button.active:hover { color: var(--navy); background: var(--lime); }
.tool-caption { position: static; width: auto; max-width: 58px; overflow: hidden; color: inherit; font-size: .66rem; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; transform: none; }
.tool-button.active .tool-caption { font-weight: 700; }
.tool-rail-divider { width: 40px; margin: 4px 0; }

.planner-panel, .map-tool-panel, .poi-panel { border-color: var(--line-2); background: var(--paper); box-shadow: 0 10px 30px rgba(29,33,59,.16); }
.planner-head h2, .tool-panel-head h2, .poi-head h2 { font-size: 1.5rem; font-weight: 750; line-height: 1.1; }
@media (min-width: 761px) {
  /* Panel je ukotvený k ľavému okraju mapy na celú výšku, nie plávajúca karta. */
  .planner-panel, .map-tool-panel, .poi-panel { top: 0; left: 0; width: min(392px, 100%); height: 100%; max-height: 100%; border: 0; border-right: 1px solid var(--line-2); border-radius: 0; box-shadow: 4px 0 18px rgba(29,33,59,.08); }
  .calc-overlay, .map-message { left: calc(50% + 196px); }
}

.planner-steps { margin-bottom: .75rem; padding: .75rem .85rem .75rem 2.1rem; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); font-weight: 500; }
.planner-steps li::marker { color: var(--strong); font-weight: 800; }
.place-search input { min-height: 44px; border-radius: 10px; }
.place-search input:focus-visible, .place-result:focus-visible { outline: 2px solid var(--strong); outline-offset: 1px; }
.place-search button { min-height: 44px; border-radius: 10px; }
.place-search .place-locate { width: 44px; }
.legal-warning, .planner-panel .legal-warning { border: 1px solid var(--warn-line); border-radius: 12px; color: var(--warn-ink); background: var(--warn-bg); }
.legal-warning span { color: var(--warn-ink); }
.planner-tabs { gap: 4px; padding: 4px; border-radius: 12px; background: var(--surface-4); }
.planner-tab { min-height: 44px; border-radius: 9px; color: var(--ink-2); font-size: .85rem; font-weight: 500; }
.planner-tab.active { background: var(--navy); box-shadow: none; font-weight: 600; }
.route-profile-field, .planner-field { margin: .75rem 0 0; padding: .85rem; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); }
.route-profile-field > span, .planner-field label { color: var(--ink); font-size: .85rem; font-weight: 700; }
.route-profile-field p { color: var(--ink-2); font-size: .78rem; line-height: 1.45; }
.route-profile-switch { gap: 6px; padding: 0; background: none; }
.route-profile-switch button { min-height: 58px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 7px; padding: .4rem .15rem; border: 1px solid var(--line); border-radius: 10px; color: var(--ink-2); background: var(--surface); font-size: .74rem; font-weight: 500; }
.route-profile-switch button::before { content: ""; width: 24px; height: 5px; border-radius: 3px; background: var(--lvl, var(--lvl-paved)); }
.route-profile-switch button[data-route-profile="light"] { --lvl: var(--lvl-light); }
.route-profile-switch button[data-route-profile="medium"] { --lvl: var(--lvl-medium); }
.route-profile-switch button[data-route-profile="hard"] { --lvl: var(--lvl-hard); }
.route-profile-switch button:hover:not(:disabled) { border-color: var(--line-4); }
.route-profile-switch button.active { padding: calc(.4rem - 1px) .15rem; border: 2px solid var(--strong-line); color: var(--ink); background: var(--accent-tint); box-shadow: none; font-weight: 700; }
.planner-instructions { margin-top: .75rem; border: 1px solid var(--line); border-radius: 12px; color: var(--ink-2); background: var(--surface); }
.waypoint-item { padding: .4rem .5rem; border-radius: 10px; }
.waypoint-badge { color: var(--lime); background: var(--navy); }
.waypoint-actions button:hover:not(:disabled) { border-color: var(--strong-line); color: var(--strong); }
.text-button { color: var(--strong); text-decoration: underline; }
.planner-field select { min-height: 44px; border-radius: 10px; }
.optional-forest-control { margin-top: .75rem; padding: .85rem; border-radius: 14px; background: var(--warn-bg); }
.optional-forest-control input { accent-color: #8a6200; }
.optional-forest-control strong, .optional-forest-control small { color: var(--warn-ink); }
.optional-forest-control strong { font-size: .82rem; }
.optional-forest-control small { font-size: .72rem; }
.optional-forest-hint { border-radius: 12px; background: var(--warn-bg); }
.planner-actions .primary-button, .planner-actions .secondary-button { min-height: 48px; border-radius: 12px; font-size: .9rem; }
.planner-actions .primary-button { font-weight: 700; }

.result-profile { border-radius: 12px; }
.variant-arrow { border: 1px solid var(--line-3); border-radius: 12px; color: var(--strong); background: var(--surface); box-shadow: none; }
.variant-arrow:hover { background: var(--surface-2); }
.variant-arrow:focus-visible, .variant-card:focus-visible { outline: 2px solid var(--strong); outline-offset: 1px; }
.variant-card { padding: .6rem .7rem; border-radius: 12px; }
.variant-card:hover { border-color: var(--line-4); }
.variant-card[aria-pressed="true"] { border-color: var(--strong-line); box-shadow: inset 0 0 0 1px var(--strong-line); background: var(--accent-tint); }
.variant-swatch { width: .38rem; height: 1.9rem; }
.variant-card > strong { display: grid; justify-items: start; gap: .25rem; }
.variant-badge { margin-left: 0; padding: .12rem .45rem; color: var(--lime); background: var(--navy); font-size: .62rem; font-weight: 600; }
.variant-stats small { color: var(--ink-2); font-size: .7rem; }
.result-stats { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .8rem .6rem; padding: .85rem; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); }
.result-stats div { padding: 0; border-radius: 0; background: none; }
.result-stats small { font-size: .72rem; }
.result-stats strong { font-size: 1.05rem; font-weight: 750; }
.result-road-types { margin-top: .75rem; padding: .85rem; border-radius: 14px; background: var(--surface); }
.result-road-types > small { color: var(--ink); font-size: .82rem; font-weight: 700; }
.road-type-chip { padding: .28rem .5rem; font-size: .7rem; font-weight: 500; }
.road-type-chip i { width: 9px; height: 9px; border-radius: 3px; }
.result-warning, .panel-note.legal-legend-note, .planner-status.is-warning { border: 1px solid var(--warn-line); border-radius: 12px; color: var(--warn-ink); background: var(--warn-bg); }
.result-actions .secondary-button { min-height: 44px; border-radius: 10px; font-size: .78rem; }
.osmand-button { min-height: 48px; border-radius: 12px; color: var(--navy); background: var(--lime); font-size: .9rem; font-weight: 700; }
.osmand-button:hover { background: #d2ee6a; }
.map-style-legend { gap: .6rem; padding: .85rem; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); }
.map-style-legend span { font-size: .82rem; font-weight: 500; }
.legend-section-title { font-size: .85rem; }
.panel-note { border: 1px solid var(--line); border-radius: 12px; color: var(--ink-2); background: var(--surface); font-size: .74rem; }
.panel-note.grade-note { border-left-color: var(--line); background: var(--surface); }
.legal-legend-note strong { color: var(--warn-ink); }
.map-key.planner-point { background: var(--navy); }
.planner-marker { color: var(--lime); background: var(--navy); box-shadow: 0 5px 14px rgba(29,33,59,.38); }
.poi-filter, .poi-status { border-radius: 12px; }
.poi-filter { background: var(--surface); }
.poi-card.active { box-shadow: inset 3px 0 var(--strong-line); }
.poi-attribution { background: var(--paper); }
.profile-panel { border-top-color: var(--line-2); box-shadow: 0 -8px 24px rgba(29,33,59,.12); }
.profile-controls { background: var(--paper); }
.profile-switch { background: var(--surface-4); }
.profile-mode.active { background: var(--navy); box-shadow: none; }
.map-clear-button { border: 1px solid var(--line-2); border-radius: 10px; box-shadow: 0 4px 14px rgba(29,33,59,.12); }
.leaflet-bar { border: 1px solid var(--line-2) !important; border-radius: 12px !important; box-shadow: 0 4px 14px rgba(29,33,59,.12) !important; overflow: hidden; }
.leaflet-bar a { width: 40px !important; height: 40px !important; line-height: 40px !important; color: var(--strong) !important; }
@media (max-width: 760px) {
  .planner-head { background: var(--paper); }
  .mobile-adventure-note { border: 1px solid var(--line); border-radius: 12px; color: var(--ink-2); background: var(--surface); }
  .planner-panel { border-radius: 20px 20px .7rem .7rem; }
}
/* Upozornenia na naplánovanej trase: tlačidlo pod „Vymazať body“, zoznam a ikony na trase. */
.map-warnings-button { position: absolute; top: 130px; right: 10px; z-index: 640; display: inline-flex; align-items: center; gap: .35rem; padding: .42rem .6rem; border: 1px solid var(--line-2); border-radius: 10px; color: var(--ink); background: var(--surface); box-shadow: 0 4px 14px rgba(29,33,59,.12); font: inherit; font-size: .72rem; font-weight: 800; cursor: pointer; }
.map-warnings-button[hidden] { display: none; }
.map-warnings-button:disabled { color: #2f6b3a; cursor: default; opacity: 1; }
.map-warnings-button svg, .map-warning svg, .warning-marker svg { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.map-warnings-button[data-severity="danger"] svg { color: var(--sev-danger); }
.map-warnings-button[data-severity="warning"] svg { color: var(--sev-warning); }
.map-warnings-count { min-width: 1.25rem; padding: .05rem .38rem; border-radius: 999px; color: #fff; background: var(--sev-info); font-size: .68rem; text-align: center; }
.map-warnings-button[data-severity="danger"] .map-warnings-count { background: var(--sev-danger); }
.map-warnings-button[data-severity="warning"] .map-warnings-count { background: var(--sev-warning); }
.map-warnings-list { position: absolute; top: 172px; right: 10px; z-index: 640; display: grid; width: min(290px, calc(100% - 20px)); max-height: min(56vh, calc(100% - 190px)); overflow-y: auto; border: 1px solid var(--line-2); border-radius: 12px; background: var(--surface); box-shadow: 0 8px 24px rgba(29,33,59,.16); }
.map-warnings-list[hidden] { display: none; }
.map-warning { display: grid; grid-template-columns: auto 1fr; gap: .55rem; align-items: start; padding: .5rem .65rem; border: 0; border-bottom: 1px solid var(--line); color: var(--ink); background: none; font: inherit; text-align: left; cursor: pointer; }
.map-warning:last-child { border-bottom: 0; }
.map-warning:hover:not(:disabled), .map-warning:focus-visible, .map-warning.active { background: var(--surface-3); outline: none; }
.map-warning:disabled { cursor: default; }
.map-warning i { display: grid; place-items: center; margin-top: .05rem; color: var(--sev-info); }
.map-warning.severity-danger i { color: var(--sev-danger); }
.map-warning.severity-warning i { color: var(--sev-warning); }
.map-warning.type-ford i { color: var(--sev-ford); }
.map-warning strong { display: block; font-size: .74rem; }
.map-warning small { display: block; margin-top: .08rem; color: var(--muted); font-size: .66rem; line-height: 1.35; }
.warning-marker-wrap { background: none; border: 0; }
.warning-marker { width: 26px; height: 26px; display: grid; place-items: center; border: 2.5px solid var(--sev-info); border-radius: 50%; color: var(--sev-info); background: var(--surface); box-shadow: 0 2px 7px rgba(17,43,30,.3); transition: transform .12s ease; }
.warning-marker.severity-danger { border-color: var(--sev-danger); color: var(--sev-danger); }
.warning-marker.severity-warning { border-color: var(--sev-warning); color: var(--sev-warning); }
.warning-marker.type-ford { border-color: var(--sev-ford); color: var(--sev-ford); }
.warning-marker.active { color: #fff; background: currentColor; transform: scale(1.25); }
.warning-marker.active svg { color: #fff; }
@media (max-width: 760px) {
  /* Na telefóne sú tlačidlá mapy v hornom páse, ktorý priblíženie na trasu necháva voľný (inak by zakryli body). */
  .map-clear-button { top: 8px; right: auto; left: 10px; }
  .map-warnings-button { top: 8px; right: 62px; }
  .map-warnings-list { top: 50px; right: 10px; left: 10px; width: auto; max-height: 40vh; }
}
/* Tučnejšie X a šípky variantov: kreslené ikony (hrúbka 3) namiesto tenkých znakov písma. Text tlačidla ostáva pre čítačky v aria-label. */
.dialog-close, .dialog-close:hover, .variant-arrow, .variant-arrow:hover { font-size: 0; background-repeat: no-repeat; background-position: center; background-size: 18px 18px; }
.dialog-close, .dialog-close:hover { padding: 0; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231d213b' stroke-width='3' stroke-linecap='round'%3E%3Cpath d='M6 6l12 12M18 6L6 18'/%3E%3C/svg%3E"); }
#variant-prev, #variant-prev:hover { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231d213b' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 12H5M11 6l-6 6 6 6'/%3E%3C/svg%3E"); }
#variant-next, #variant-next:hover { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231d213b' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 12h15M13 6l6 6-6 6'/%3E%3C/svg%3E"); }
/* Tlačidlá na mape („Vymazať body“, „Upozornenia“): tmavé navy, aby nesplývali s mapou; zarovnané s ovládaním priblíženia. */
.map-clear-button, .map-warnings-button { min-height: 40px; gap: .45rem; padding: 0 .8rem; border: 0; border-radius: 12px; color: #fff; background: var(--navy); background-clip: border-box; box-shadow: 0 4px 14px rgba(29,33,59,.3); font-size: .8rem; font-weight: 700; }
.map-clear-button:hover, .map-clear-button:focus-visible, .map-warnings-button:hover:not(:disabled), .map-warnings-button:focus-visible { background: var(--navy-2); }
.map-clear-button:focus-visible, .map-warnings-button:focus-visible { outline: 3px solid var(--lime); outline-offset: 2px; }
.map-clear-button svg, .map-warnings-button svg { width: 18px; height: 18px; color: var(--lime); stroke-width: 2.4; }
.map-warnings-button:disabled { color: #c9f0d4; }
.map-warnings-button:disabled svg { color: #5fd39a; }
.map-warnings-button[data-severity="danger"] svg { color: #ff9a85; }
.map-warnings-button[data-severity="warning"] svg { color: #f6c453; }
.map-warnings-count { min-width: 1.4rem; padding: .1rem .4rem; color: var(--navy); background: var(--lime); font-size: .74rem; font-weight: 800; }
.map-warnings-button[data-severity="danger"] .map-warnings-count { color: var(--navy); background: #ff8a70; }
.map-warnings-button[data-severity="warning"] .map-warnings-count { color: var(--navy); background: #f6c453; }
@media (min-width: 761px) {
  /* Ovládanie priblíženia končí na 93 px; tlačidlá idú pod neho s 12 px medzerami. Bez „Vymazať body“ sa Upozornenia posunú vyššie. */
  .map-clear-button { top: 105px; }
  .map-warnings-button { top: 157px; }
  .map-warnings-list { top: 209px; max-height: min(56vh, calc(100% - 225px)); }
  .map-clear-button[hidden] + .map-warnings-button { top: 105px; }
  .map-clear-button[hidden] + .map-warnings-button + .map-warnings-list { top: 157px; }
}
/* Popisky lišty nástrojov podľa grafického návrhu: 11 px, bežná váha, aktívny tučný; krátky popis „Plán“. */
.tool-caption { max-width: 60px; font-size: .6875rem; font-weight: 500; line-height: 1.2; }
.tool-button.active .tool-caption { font-weight: 700; }
/* Písmo podľa grafického návrhu: nadpisy panelov, značka a hlavné čísla v Barlow Semi Condensed, ostatný text v Inter. */
:root { --font-display: "Barlow Semi Condensed", Inter, ui-sans-serif, system-ui, sans-serif; }
.brand strong, .planner-head h2, .tool-panel-head h2, .poi-head h2, .detail-dialog h2, .about-dialog h2, .legal-page h1, .variant-nav strong, .result-stats strong, .result-profile strong { font-family: var(--font-display); letter-spacing: 0; }
.brand strong { font-size: 1.5rem; font-weight: 700; line-height: 1; }
.brand strong span { font-weight: 600; }
.planner-head h2, .tool-panel-head h2, .poi-head h2 { font-size: 1.75rem; font-weight: 700; }
.variant-nav strong { font-size: 1.15rem; font-weight: 700; }
.result-stats strong { font-size: 1.3rem; font-weight: 700; }
.map-clear-button, .map-warnings-button { font-weight: 600; letter-spacing: .01em; }
/* POI ikony – variant 1 „farebné odznaky“: plný kruh vo farbe skupiny, biela ikona; vybraný bod má obrátené farby. */
.poi-viewpoint, .poi-tower, .poi-nature { --poi-color: #2f7d55; }
.poi-castle, .poi-historic, .poi-attraction { --poi-color: #a8532f; }
.poi-picnic, .poi-camp { --poi-color: #8a6a12; }
.poi-fuel, .poi-food, .poi-service { --poi-color: #2d5f9a; }
.poi-marker svg, .poi-card-icon svg, .poi-filter-option i svg { display: block; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.poi-marker { width: 34px; height: 34px; border: 2.5px solid #fff; color: #fff; background: var(--poi-color, var(--navy)); box-shadow: 0 2px 8px rgba(29,33,59,.35); }
.poi-marker span { display: grid; place-items: center; }
.poi-marker svg { width: 18px; height: 18px; }
.poi-marker.active { border: 3px solid var(--poi-color, var(--strong-line)); color: var(--poi-color, var(--strong)); background: var(--surface); box-shadow: 0 0 0 4px rgba(29,33,59,.25), 0 4px 12px rgba(29,33,59,.4); transform: scale(1.25); }
.poi-card-icon { width: 2.1rem; height: 2.1rem; }
.poi-card-icon svg { width: 18px; height: 18px; }
.poi-filter-option { grid-template-columns: auto 1.5rem minmax(0, 1fr) auto; font-size: .7rem; }
.poi-filter-option i { width: 1.5rem; height: 1.5rem; }
.poi-filter-option i svg { width: 14px; height: 14px; }
.map-key.poi-point { border: 2px solid #fff; background: #2f7d55; box-shadow: 0 1px 4px rgba(29,33,59,.4); }
/* ===== Tmavý vzhľad (13. 11. 2026): prepínač v hlavičke nastavuje data-theme na <html>; farby určujú premenné. ===== */
dialog { background: var(--surface); }
.theme-switch { display: inline-flex; gap: 2px; padding: 3px; border: 1px solid #4a5080; border-radius: 10px; background: var(--navy-2); }
.theme-switch button { min-width: 36px; height: 30px; display: grid; place-items: center; padding: 0 .5rem; border: 0; border-radius: 7px; color: #b9bfd6; background: transparent; font: inherit; font-size: .72rem; font-weight: 600; cursor: pointer; }
.theme-switch button:hover { color: #fff; }
.theme-switch button svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.theme-switch button[aria-pressed="true"], .theme-switch button[aria-pressed="true"]:hover { color: #1d213b; background: var(--lime); }
.theme-switch button:focus-visible { outline: 2px solid var(--lime); outline-offset: 1px; }
@media (max-width: 760px) {
  /* Na telefóne ostane jedno tlačidlo: ponúkne opačný vzhľad, než je zapnutý. */
  .theme-switch { padding: 2px; }
  .theme-switch button[data-theme-choice="auto"], .theme-switch button[aria-pressed="true"] { display: none; }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --ink: #eef0f8;
  --muted: #a9afc9;
  --paper: #1a1d33;
  --panel: #232744;
  --line: #343a5e;
  --forest: #12152a;
  --moss: #c3c8de;
  --navy: #12152a;
  --navy-2: #2a2f52;
  --accent-tint: #2c3340;
  --route: #7b96ff;
  --shadow: 0 16px 42px rgba(0, 0, 0, .45);
  --surface: #232744;
  --surface-2: #2c3152;
  --surface-3: #1f2340;
  --surface-4: #2b3050;
  --line-2: #2b3050;
  --line-3: #4a5080;
  --line-4: #6a7096;
  --ink-2: #c3c8de;
  --strong: #eef0f8;
  --strong-line: #c5e34f;
  --warn-bg: #2e2a1c;
  --warn-ink: #f6dc9a;
  --warn-line: #7a6220;
  --danger-bg: #3a2020;
  --danger-ink: #ffb4a3;
  --danger-line: #8a3a2c;
  --sev-danger: #ff8a70;
  --sev-warning: #f6c453;
  --sev-ford: #6fb1ff;
  --sev-info: #a9afc9;
}
:root[data-theme="dark"] .topbar { border-bottom: 1px solid var(--line-2); }
:root[data-theme="dark"] .tool-rail { border-right: 1px solid var(--line-2); }
:root[data-theme="dark"] .result-profile, :root[data-theme="dark"] .calc-overlay { border: 1px solid var(--line-2); }
:root[data-theme="dark"] .variant-badge { color: #12152a; background: var(--lime); }
:root[data-theme="dark"] .map-clear-button, :root[data-theme="dark"] .map-warnings-button { box-shadow: 0 0 0 1px var(--line-3), 0 4px 14px rgba(0, 0, 0, .45); }
:root[data-theme="dark"] .poi-marker.active { background: #fff; }
:root[data-theme="dark"] .leaflet-bar { border-color: var(--line-3) !important; }
:root[data-theme="dark"] .leaflet-bar a { border-bottom-color: var(--line-3) !important; background: var(--surface) !important; }
:root[data-theme="dark"] .leaflet-popup-content-wrapper, :root[data-theme="dark"] .leaflet-popup-tip, :root[data-theme="dark"] .leaflet-tooltip { color: var(--ink); background: var(--surface); }
:root[data-theme="dark"] .leaflet-tooltip { border-color: var(--line-3); }
:root[data-theme="dark"] .leaflet-control-attribution { color: #c3c8de; background: rgba(18, 21, 42, .82); }
:root[data-theme="dark"] .leaflet-control-attribution a { color: #9db4ff; }
:root[data-theme="dark"] .leaflet-control-scale-line { border-color: #c3c8de; color: #eef0f8; background: rgba(18, 21, 42, .7); text-shadow: none; }
:root[data-theme="dark"] .dialog-close, :root[data-theme="dark"] .dialog-close:hover { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23eef0f8' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 6l12 12M18 6L6 18'/%3E%3C/svg%3E"); }
:root[data-theme="dark"] #variant-prev, :root[data-theme="dark"] #variant-prev:hover { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23eef0f8' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 12H5M11 6l-6 6 6 6'/%3E%3C/svg%3E"); }
:root[data-theme="dark"] #variant-next, :root[data-theme="dark"] #variant-next:hover { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23eef0f8' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 12h15M13 6l6 6-6 6'/%3E%3C/svg%3E"); }
/* Legenda trackov v tmavom vzhľade zodpovedá tmavej palete na mape (app/theme.js). */
:root[data-theme="dark"] .map-key[class*="track-grade"] { border-color: #0d1018; }
:root[data-theme="dark"] .map-key.track-grade1 { background: #f5cc7a; }
:root[data-theme="dark"] .map-key.track-grade2 { background: repeating-linear-gradient(90deg, #f0a852 0 10px, #a8733a 10px 13px); }
:root[data-theme="dark"] .map-key.track-grade3 { background: repeating-linear-gradient(90deg, #e5814a 0 6px, #9c5a34 6px 9px); }
:root[data-theme="dark"] .map-key.track-grade4 { background: repeating-linear-gradient(90deg, #d4634a 0 3px, #8a4532 3px 6px); }
:root[data-theme="dark"] .map-key.track-grade5 { background: repeating-linear-gradient(90deg, #c05548 0 1.5px, #76382f 1.5px 4.5px); }

/* ADV-P1-51: legenda – ochranné pásmo pri hranici s Ukrajinou a oblasť mimo plánovania. */
.map-key.border-zone { background: rgba(215, 51, 63, .14); border: 1px dashed #bd1726; }
.map-key.outside-area { background: rgba(138, 144, 153, .6); border: 2px solid #1b2437; }

/* ADV-P0-26: štítky „Čo smie byť na trase“, oznam o zákonoch krajiny, kódex jazdca. */
.route-allow-field { display: grid; gap: .5rem; margin: .75rem 0 0; padding: .85rem; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); }
.route-allow-field > span { color: var(--ink); font-size: .85rem; font-weight: 700; }
.route-allow-field p { margin: 0; color: var(--ink-2); font-size: .78rem; line-height: 1.45; }
.route-allow-chips { display: flex; flex-wrap: wrap; gap: .35rem; }
.route-allow-chip { display: inline-flex; align-items: stretch; }
.route-allow-chip button { min-height: 40px; padding: 0 .8rem; border: 1px solid var(--line); border-radius: 999px; color: var(--ink-2); background: var(--surface-2); cursor: pointer; font-size: .78rem; font-weight: 700; }
.route-allow-chip button[aria-pressed="true"] { color: white; border-color: var(--navy); background: var(--navy); }
.route-allow-chip button[aria-pressed="false"] { text-decoration: line-through; }
.route-allow-chip button:disabled { cursor: wait; opacity: .55; }
.route-allow-chip button:focus-visible { outline: 2px solid var(--candidate); outline-offset: 2px; }
.route-allow-chip .route-allow-count { min-width: 30px; margin-left: -.55rem; padding: 0 .5rem; border-color: var(--warn-line); color: var(--warn-ink); background: var(--warn-bg); text-decoration: none; font-variant-numeric: tabular-nums; }
.result-law-notice { display: grid; gap: .2rem; margin: .5rem 0 .2rem; padding: .6rem .7rem; border: 1px solid var(--warn-line); border-radius: 12px; color: var(--warn-ink); background: var(--warn-bg); font-size: .7rem; line-height: 1.42; }
.result-law-notice strong { font-size: .74rem; }
.codex-lead { margin: .2rem 0 .9rem; color: var(--ink-2); font-size: .95rem; line-height: 1.5; }
.codex-list { margin: 0; padding-inline-start: 1.4rem; display: grid; gap: .6rem; line-height: 1.5; }
.codex-list li::marker { color: var(--moss); font-weight: 800; }
.codex-list strong { display: block; }
.codex-list span { color: var(--ink-2); font-size: .9rem; }
.codex-foot { margin: 1.1rem 0 0; padding-top: .85rem; border-top: 1px solid var(--line); line-height: 1.5; }

/* ===== Cloud (16. 11. 2026): modré tlačidlo „Cloud sync“ vedľa exportu GPX a dialóg „Moje trasy“. ===== */
.result-export-row { display: grid; grid-template-columns: 1fr 1fr; gap: .5rem; margin-top: .6rem; }
.result-export-row .osmand-button { margin-top: 0; }
.cloud-button { min-height: 48px; padding: .6rem .9rem; border: 0; border-radius: 12px; color: #fff; background: #3b5bdb; font: inherit; font-size: .9rem; font-weight: 700; cursor: pointer; }
.cloud-button:hover, .cloud-button:focus-visible { background: #2f4bc0; outline: none; }
.cloud-button:focus-visible { box-shadow: 0 0 0 3px rgba(59,91,219,.35); }
.cloud-button:disabled { opacity: .6; cursor: default; }
.my-routes-mobile { display: none; }
.cloud-dialog { width: min(560px, calc(100% - 2rem)); }
.cloud-dialog [hidden] { display: none; }
.cloud-dialog section > p { margin: 0 0 1rem; line-height: 1.5; }
.cloud-status { margin: 0 0 1rem; padding: .6rem .75rem; border: 1px solid var(--line); border-radius: 10px; background: var(--surface-2); line-height: 1.45; }
.cloud-status.is-error { color: var(--danger-ink); background: var(--danger-bg); border-color: var(--danger-line); }
.cloud-form { display: grid; gap: .5rem; }
.cloud-form label { font-size: .85rem; font-weight: 700; }
.cloud-form input:not([type="checkbox"]) { min-height: 46px; padding: .5rem .7rem; border: 1px solid var(--line); border-radius: 10px; color: var(--ink); background: var(--surface); font: inherit; font-size: 1rem; }
.cloud-form input:focus-visible { outline: 3px solid rgba(59,91,219,.35); outline-offset: 1px; }
.cloud-form .cloud-consent { display: flex; align-items: flex-start; gap: .55rem; font-weight: 500; line-height: 1.4; }
.cloud-consent input { width: 20px; height: 20px; flex: none; margin: .1rem 0 0; }
.cloud-account-line { display: flex; flex-wrap: wrap; align-items: baseline; gap: .3rem .6rem; }
.cloud-account-line strong { margin-right: auto; overflow-wrap: anywhere; }
.cloud-account-line span { color: var(--ink-2); font-size: .85rem; }
.cloud-routes { display: grid; gap: .5rem; margin: 0 0 1rem; padding: 0; list-style: none; }
.cloud-routes li { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: .5rem; padding: .6rem .7rem; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
.cloud-routes strong { display: block; overflow-wrap: anywhere; }
.cloud-routes small { display: flex; flex-wrap: wrap; gap: .1rem .6rem; color: var(--ink-2); font-size: .78rem; }
.cloud-routes .cloud-button, .cloud-routes .secondary-button { min-height: 40px; padding: .4rem .7rem; border-radius: 10px; font-size: .8rem; }
@media (max-width: 760px) {
  /* Do úzkej hlavičky sa ďalšie tlačidlo nezmestí (najmä v nemčine a španielčine): na mobile je
     „Moje trasy“ v paneli plánovača. */
  #my-routes-button { display: none; }
  .my-routes-mobile { display: block; width: 100%; min-height: 44px; margin: 0 0 .75rem; }
  .cloud-routes li { grid-template-columns: 1fr 1fr; }
  .cloud-routes li > div { grid-column: 1 / -1; }
}
/* Cloud – nastavenia účtu (zariadenia, zmena e-mailu, export, zrušenie). */
.cloud-settings { margin: 0 0 1rem; padding: .6rem .75rem; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
.cloud-settings > summary { cursor: pointer; font-weight: 700; min-height: 32px; display: flex; align-items: center; }
.cloud-settings h3 { margin: 1rem 0 .45rem; font-size: .95rem; }
.cloud-settings p { margin: 0 0 .5rem; color: var(--ink-2); font-size: .85rem; line-height: 1.45; }
.cloud-sessions { display: grid; gap: .4rem; margin: 0; padding: 0; list-style: none; }
.cloud-sessions li { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: .5rem; padding: .45rem .6rem; border: 1px solid var(--line); border-radius: 10px; }
.cloud-sessions strong { display: block; overflow-wrap: anywhere; font-size: .88rem; }
.cloud-sessions small { display: flex; flex-wrap: wrap; gap: .1rem .5rem; color: var(--ink-2); font-size: .76rem; }
.cloud-sessions .secondary-button { min-height: 36px; padding: .35rem .6rem; border-radius: 9px; font-size: .78rem; }
.cloud-current { color: var(--ink-2); font-size: .78rem; font-weight: 700; }
.cloud-danger-button { min-height: 44px; padding: .55rem .9rem; border: 1px solid var(--danger-line); border-radius: 10px; color: var(--danger-ink); background: var(--danger-bg); font: inherit; font-size: .85rem; font-weight: 700; cursor: pointer; }
.cloud-danger-button:hover, .cloud-danger-button:focus-visible { filter: brightness(.96); outline: none; }
.cloud-danger-button:disabled { opacity: .6; cursor: default; }
.cloud-reauth { margin: .6rem 0 .2rem; padding: .6rem; border: 1px solid var(--warn-line); border-radius: 10px; background: var(--warn-bg); }
