/* ═══════════════════════════════════════════════════════════════
   LOCALITY ANALYSIS — Štýly pre sekciu Lokalita analýza
   ═══════════════════════════════════════════════════════════════ */

/* ─── Grid kariet (klon analysis-grid) ─── */
.locality-prop-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 8px;
}

.locality-prop-card {
    background: #fff;
    border: 1px solid #eef1f5;
    border-radius: 14px;
    overflow: hidden;
    transition: box-shadow 0.2s, transform 0.2s;
    cursor: pointer;
    display: flex;
    flex-direction: column;
}

.locality-prop-card:hover {
    box-shadow: 0 8px 32px rgba(0,0,0,0.10);
    transform: translateY(-2px);
}

.locality-prop-card-img {
    width: 100%;
    height: 130px;
    object-fit: cover;
    background: #f0f3f7;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 36px;
    flex-shrink: 0;
}

.locality-prop-card-img img {
    width: 100%;
    height: 130px;
    object-fit: cover;
}

.locality-prop-card-body {
    padding: 14px 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
}

.locality-prop-card-title {
    font-size: 0.88rem;
    font-weight: 700;
    color: #111;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.3;
}

.locality-prop-card-title a {
    color: inherit;
    text-decoration: none;
}

.locality-prop-card-address {
    font-size: 0.75rem;
    color: #888;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.locality-prop-card-stats {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 2px;
}

.locality-prop-card-stats span {
    background: #f4f6fa;
    color: #555;
    border-radius: 5px;
    padding: 3px 8px;
    font-size: 0.72rem;
    font-weight: 600;
    white-space: nowrap;
}

.locality-prop-card-btn {
    margin-top: auto;
    padding-top: 12px;
}

.locality-btn-view {
    width: 100%;
    padding: 9px 0;
    background: #111;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    transition: background 0.18s, transform 0.15s;
    font-family: inherit;
}

.locality-btn-view:hover {
    background: #222;
    transform: translateY(-1px);
}

/* ─── Detail View ─── */
#localityDetailView {
    animation: localityFadeIn 0.35s ease-out;
}

@keyframes localityFadeIn {
    from { opacity: 0; transform: translateY(14px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ─── Súhrn nehnuteľnosti ─── */
.locality-summary-card {
    background: linear-gradient(135deg, #0a0a0a 0%, #1c1c1c 100%);
    border-radius: 16px;
    padding: 28px 32px;
    color: #fff;
    margin-bottom: 24px;
    position: relative;
    overflow: hidden;
}

.locality-summary-card::before {
    content: '';
    position: absolute;
    top: -60px; right: -60px;
    width: 200px; height: 200px;
    background: radial-gradient(circle, rgba(255,255,255,0.08) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.locality-summary-card::after {
    content: '';
    position: absolute;
    bottom: -40px; left: -40px;
    width: 150px; height: 150px;
    background: radial-gradient(circle, rgba(16,185,129,0.12) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.locality-summary-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.locality-summary-title-block {
    flex: 1;
    min-width: 0;
}

.locality-summary-prop-name {
    font-size: 1.05rem;
    font-weight: 800;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 4px;
    line-height: 1.3;
}

.locality-summary-prop-name a {
    color: inherit;
    text-decoration: none;
    opacity: 0.9;
    transition: opacity 0.2s;
}

.locality-summary-prop-name a:hover { opacity: 1; }

.locality-summary-prop-address {
    font-size: 0.8rem;
    color: rgba(255,255,255,0.55);
    display: flex;
    align-items: center;
    gap: 5px;
}

.locality-summary-score-badge {
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.18);
    border-radius: 12px;
    padding: 10px 16px;
    text-align: center;
    flex-shrink: 0;
    backdrop-filter: blur(4px);
}

.locality-summary-score-badge .score-val {
    font-size: 1.6rem;
    font-weight: 900;
    color: #fff;
    line-height: 1;
}

.locality-summary-score-badge .score-lbl {
    font-size: 0.62rem;
    font-weight: 700;
    color: rgba(255,255,255,0.5);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 3px;
}

.locality-summary-metrics {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
    gap: 12px;
    position: relative;
    z-index: 1;
}

.locality-metric-card {
    background: rgba(255,255,255,0.07);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 10px;
    padding: 12px 14px;
    transition: background 0.2s;
}

.locality-metric-card:hover {
    background: rgba(255,255,255,0.11);
}

.locality-metric-card .lbl {
    font-size: 0.63rem;
    font-weight: 700;
    color: rgba(255,255,255,0.45);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 5px;
}

.locality-metric-card .val {
    font-size: 1.15rem;
    font-weight: 800;
    color: #fff;
    line-height: 1.1;
}

.locality-metric-card .val.positive { color: #4ade80; }
.locality-metric-card .val.negative { color: #f87171; }

/* ─── Address Step ─── */
.locality-address-panel {
    background: #fff;
    border: 1px solid #eef1f5;
    border-radius: 14px;
    padding: clamp(16px, 3vw, 32px);
    margin-bottom: clamp(14px, 2.5vw, 24px);
}

.locality-address-panel .step-label {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.7rem;
    font-weight: 800;
    color: #111;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 8px;
}

.locality-address-panel h3 {
    font-size: clamp(0.97rem, 2.5vw, 1.15rem);
    font-weight: 800;
    color: #111;
    margin: 0 0 6px 0;
}

.locality-address-panel p {
    font-size: 0.87rem;
    color: #777;
    margin: 0 0 20px 0;
    line-height: 1.5;
}

.locality-address-input-wrap {
    position: relative;
    margin-bottom: 14px;
}

.locality-address-input {
    width: 100%;
    box-sizing: border-box;
    padding: 14px 16px 14px 44px;
    border: 1.5px solid #e2e8f0;
    border-radius: 10px;
    font-size: 0.97rem;
    font-family: inherit;
    font-weight: 500;
    color: #111;
    background: #fafbfc;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.locality-address-input:focus {
    border-color: #111;
    box-shadow: 0 0 0 3px rgba(17,17,17,0.1);
    background: #fff;
}

.locality-address-input-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #aaa;
    pointer-events: none;
}

.locality-address-dropdown {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    width: 100%;
    box-sizing: border-box;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.10);
    z-index: 1000;
    max-height: 240px;
    overflow-y: auto;
    display: none;
}

.locality-address-dropdown-item {
    padding: 10px 16px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
    color: #111;
    border-bottom: 1px solid #f0f0f0;
    transition: background 0.15s;
    display: flex;
    align-items: flex-start;
    gap: 8px;
}

.locality-address-dropdown-item:last-child { border-bottom: none; }
.locality-address-dropdown-item:hover { background: #f8f9fc; }

/* Nový layout: text + badge vedľa seba */
.locality-address-dropdown-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
    flex: 1;
}

.locality-address-dropdown-main {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: nowrap;
    min-width: 0;
}

.locality-address-dropdown-main > span:first-child {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 0;
    flex: 1;
}

.locality-address-dropdown-type {
    font-size: 0.60rem;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 4px;
    background: #f0f1f3;
    color: #777;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    white-space: nowrap;
    flex-shrink: 0;
}

.locality-address-dropdown-secondary {
    font-size: 0.72rem;
    color: #b0b0b8;
    font-weight: 400;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Starý item-text/item-sub — zachované pre spätnú kompatibilitu */
.locality-address-dropdown-item .item-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.locality-address-dropdown-item .item-sub {
    font-size: 0.75rem;
    color: #999;
    font-weight: 400;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.locality-btn-analyze {
    width: 100%;
    padding: 15px 24px;
    min-height: 52px;
    background: #111;
    color: #fff;
    border: none;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: background 0.2s ease, transform 0.18s cubic-bezier(.34,1.56,.64,1), box-shadow 0.2s ease, opacity 0.2s ease;
    font-family: inherit;
    box-shadow: 0 4px 18px rgba(0,0,0,0.18);
    letter-spacing: 0.01em;
    position: relative;
    overflow: hidden;
}

.locality-btn-analyze:hover:not(:disabled):not(.loc-btn-loading) {
    background: #1a1a1a;
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(0,0,0,0.22);
}

.locality-btn-analyze:active:not(:disabled):not(.loc-btn-loading) {
    transform: scale(0.97);
    box-shadow: 0 2px 8px rgba(0,0,0,0.14);
    transition: transform 0.07s ease, box-shadow 0.07s ease;
}

.locality-btn-analyze:disabled {
    opacity: 0.42;
    cursor: not-allowed;
    transform: none !important;
    box-shadow: none;
}

.locality-btn-analyze.loc-btn-loading {
    background: #333;
    cursor: not-allowed;
    pointer-events: none;
    box-shadow: 0 2px 8px rgba(0,0,0,0.10);
}

.loc-btn-spinner {
    width: 17px;
    height: 17px;
    border: 2px solid rgba(255,255,255,0.28);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
    flex-shrink: 0;
    display: inline-block;
}

/* ─── Loading skeleton ─── */
.locality-skeleton {
    background: linear-gradient(90deg, #f0f3f7 25%, #e8ecf2 50%, #f0f3f7 75%);
    background-size: 200% 100%;
    animation: localitySkeleton 1.4s ease-in-out infinite;
    border-radius: 8px;
}

@keyframes localitySkeleton {
    0%   { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* ─── PANEL TRANSITIONS ─── */
#localityResultsPanel {
    transition: opacity 0.3s ease;
}
#localityResultsPanel.loc-stale {
    opacity: 0.4;
    pointer-events: none;
}

/* ─── NEW DASHBOARD RESULTS ─── */
.loc-dashboard-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) clamp(300px, 35%, 420px);
    gap: clamp(12px, 2vw, 24px);
    align-items: start;
}

/* ─── LEFT COLUMN (CHARTS) ─── */
.loc-charts-col {
    display: flex;
    flex-direction: column;
    gap: clamp(12px, 2vw, 20px);
    min-width: 0;
}

.loc-chart-card {
    background: #fff;
    border: 1px solid #eef1f5;
    padding: clamp(14px, 2.5vw, 24px);
    display: flex;
    flex-direction: column;
}

.loc-chart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
}

.loc-chart-title {
    font-size: clamp(0.82rem, 1.8vw, 0.95rem);
    font-weight: 700;
    color: #111;
}

.loc-chart-btn {
    border: 1px solid #111;
    background: transparent;
    color: #111;
    font-size: 0.7rem;
    font-weight: 700;
    padding: 6px 12px;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    transition: all 0.2s;
}

.loc-chart-btn:hover {
    background: #111;
    color: #fff;
}

.loc-chart-canvas-wrap {
    position: relative;
    width: 100%;
    min-height: clamp(150px, 25vw, 240px);
}

/* ─── TABLE STYLES (Pohyb obyvatelstva) ─── */
.loc-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.8rem;
    text-align: left;
}

.loc-table th {
    font-weight: 700;
    color: #888;
    padding-bottom: 12px;
    border-bottom: 1px solid #eef1f5;
    text-transform: uppercase;
    font-size: 0.65rem;
    letter-spacing: 0.05em;
}

.loc-table td {
    padding: 12px 0;
    border-bottom: 1px solid #f8f9fb;
    color: #333;
    font-weight: 500;
}

.loc-table tr:last-child td {
    border-bottom: none;
    padding-bottom: 0;
}

.loc-table td.pos {
    font-weight: 700;
    color: #111;
}

/* ─── AGE STRUCTURE ─── */
.loc-age-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-bottom: 16px;
}

.loc-age-box {
    border: 1px solid #eef1f5;
    padding: 16px;
    text-align: left;
}

.loc-age-lbl {
    font-size: 0.65rem;
    font-weight: 800;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 6px;
}

.loc-age-val {
    font-size: 1.3rem;
    font-weight: 800;
    color: #111;
}

.loc-age-index {
    background: #f4f6fa;
    border: 1px solid #eef1f5;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* ─── INVESTMENT SUMMARY ─── */
.loc-inv-card {
    border-top: 3px solid #111;
    border-radius: 10px;
}

.loc-inv-rating {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 24px;
}

.loc-inv-rating .stars {
    font-size: 1.2rem;
    color: #111;
    letter-spacing: 2px;
}

.loc-inv-rating .rating-text {
    font-size: 0.75rem;
    font-weight: 700;
    color: #555;
}

.loc-inv-strategy .strategy-lbl {
    font-size: 0.65rem;
    font-weight: 800;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 8px;
}

.loc-inv-strategy p {
    font-size: 0.85rem;
    line-height: 1.6;
    color: #333;
    margin: 0;
}

/* ─── RIGHT COLUMN (MAP & LIST) ─── */
.loc-side-col {
    display: flex;
    flex-direction: column;
}

.loc-map-container {
    width: 100%;
    height: clamp(220px, 30vw, 460px);
    border: 1px solid #eef1f5;
    background: #f8f9fb;
    border-bottom: none;
    z-index: 1; /* for leaflet */
    transition: height 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}
.loc-map-container.loc-map-expanded {
    height: clamp(380px, 55vw, 600px);
}

.loc-amenities-panel {
    background: #fafbfc;
    border: 1px solid #eef1f5;
    padding: 24px;
}

.loc-amenities-title {
    font-size: 0.8rem;
    font-weight: 700;
    color: #555;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 16px;
    border-bottom: 1px solid #eef1f5;
    padding-bottom: 8px;
}

.loc-amenity-list {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.loc-amenity-item {
    display: flex;
    align-items: center;
    padding: 16px 0;
    border-bottom: 1px solid #eef1f5;
}

.loc-amenity-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.loc-amenity-icon {
    width: 32px;
    height: 32px;
    border: 1px solid #eef1f5;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 16px;
    flex-shrink: 0;
}

.loc-amenity-info {
    flex: 1;
    min-width: 0;
}

.loc-amenity-name {
    font-size: 0.85rem;
    font-weight: 600;
    color: #111;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.loc-amenity-cat {
    font-size: 0.65rem;
    font-weight: 700;
    color: #888;
    text-transform: uppercase;
    margin-top: 2px;
}

.loc-amenity-dist {
    text-align: right;
    flex-shrink: 0;
    margin-left: 12px;
}

.loc-amenity-meters {
    font-size: 0.85rem;
    font-weight: 600;
    color: #111;
}

.loc-amenity-time {
    font-size: 0.65rem;
    font-weight: 600;
    color: #888;
    margin-top: 2px;
}

/* ─── Leaflet custom markers ─── */
.custom-map-marker {
    background: none;
    border: none;
}
.marker-pin-main {
    width: 16px;
    height: 16px;
    background: #111;
    border: 2px solid #fff;
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0,0,0,0.3);
}
.marker-pin-poi {
    width: 12px;
    height: 12px;
    background: #666;
    border: 2px solid #fff;
    border-radius: 50%;
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

/* ─── Error a empty state ─── */
.locality-error {
    background: #fff5f5;
    border: 1px solid #fecaca;
    padding: 16px 20px;
    color: #dc2626;
    font-size: 0.88rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* ═══════════════════════════════════════════════════════════════
   RESPONZÍVNOSŤ — 4-tierový breakpoint systém
   XS < 480px | SM < 900px | MD < 1024px | LG ≥ 1024px | XL ≥ 1400px
   ═══════════════════════════════════════════════════════════════ */

/* ─── MD (tablet 900–1023px): 2 stĺpce, užší sidebar ─── */
@media (max-width: 1023px) {
    .loc-dashboard-grid {
        grid-template-columns: minmax(0, 1fr) 300px;
        gap: 16px;
    }
}

/* ─── SM (≤899px): jeden stĺpec, mapa hore ─── */
@media (max-width: 899px) {
    /* Layout: single column, mapa hore */
    .loc-dashboard-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }
    .loc-side-col {
        order: -1; /* mapa ide nad grafy */
    }

    /* Mapa */
    .loc-map-container {
        height: 260px;
        border-radius: 12px;
        border: 1px solid #eef1f5;
    }
    .loc-map-container.loc-map-expanded {
        height: 420px;
    }

    /* POI taby — horizontálny scroll */
    .loc-poi-tabs {
        overflow-x: auto;
        flex-wrap: nowrap;
        scroll-snap-type: x mandatory;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        -ms-overflow-style: none;
        padding-bottom: 2px;
        gap: 6px;
    }
    .loc-poi-tabs::-webkit-scrollbar { display: none; }
    .loc-poi-tab {
        flex: 0 0 auto;
        scroll-snap-align: start;
        min-width: 72px;
        min-height: 52px;
    }
    .loc-poi-tab-label { font-size: 0.63rem; }
    .loc-poi-tab-icon { width: 28px; height: 28px; }
    .loc-poi-tab-icon svg { width: 17px; height: 17px; }

    /* Adresný panel */
    .locality-address-panel {
        border-radius: 10px;
        padding: 16px;
    }
    .locality-address-input { font-size: 0.93rem; padding: 13px 14px 13px 42px; }
    .locality-address-dropdown-item { padding: 13px 14px; min-height: 48px; }

    /* Chart karty */
    .loc-chart-card { border-radius: 8px; }
    .loc-chart-header { margin-bottom: 16px; }

    /* Tax card */
    .loc-tax-card { padding: 16px; }
    .loc-tax-item { padding: 10px 12px; }

    /* Score card */
    .loc-score-card { padding: 14px 16px; }

    /* POI list */
    .loc-poi-list-wrap { max-height: 280px; }

    /* POI interpretation */
    .loc-poi-interpretation { font-size: 0.79rem; }

    /* Age grid — zachovaj 3 stĺpce na SM */
    .loc-age-grid { gap: 10px; }
    .loc-age-box { padding: 12px; }
    .loc-age-val { font-size: 1.1rem; }

    /* History chips */
    .loc-history-chips { gap: 6px; }
    .loc-history-chip { padding: 6px 12px; font-size: 0.78rem; min-height: 36px; }

    /* Stale overlay */
    .loc-stale-overlay { position: relative; border-radius: 8px; margin-bottom: 10px; }
}

/* ─── XS (malý mobil ≤479px) ─── */
@media (max-width: 479px) {
    /* Age grid — 1 stĺpec */
    .loc-age-grid { grid-template-columns: 1fr; gap: 8px; }

    /* Mapa ešte trochu nižšia */
    .loc-map-container { height: 230px; }

    /* Adresný panel */
    .locality-address-panel { padding: 14px; border-radius: 10px; }
    .locality-address-panel h3 { font-size: 0.95rem; }
    .locality-address-panel p { font-size: 0.82rem; }

    /* Skóre riadok — kompaktnejšie */
    .loc-lscore-row {
        grid-template-columns: 78px 1fr 30px 42px;
        font-size: 0.71rem;
        gap: 5px;
    }

    /* Tax items */
    .loc-tax-item { flex-direction: column; gap: 6px; }
    .loc-tax-item-icon { font-size: 1.2rem; }

    /* Export button */
    .loc-export-btn { font-size: 0.78rem; padding: 11px 16px; }
}

/* ─── XL (veľký monitor ≥1400px) ─── */
@media (min-width: 1400px) {
    .loc-dashboard-grid {
        grid-template-columns: minmax(0, 1fr) 460px;
        gap: 32px;
    }
    .loc-map-container { height: 500px; }
    .loc-poi-list-wrap { max-height: 420px; }
    .loc-chart-canvas-wrap { min-height: 260px; }
}

/* ─── POI Taby (školy / doprava / obchody) ─── */
.loc-poi-tabs {
    display: flex;
    gap: 8px;
    margin-top: 14px;
}

.loc-poi-tab {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    padding: 12px 8px 10px;
    background: #fff;
    border: 1.5px solid #eaeaea;
    border-radius: 10px;
    cursor: pointer;
    transition: border-color 0.15s, background 0.15s, color 0.15s;
    color: #111;
    font-family: inherit;
    position: relative;
}

.loc-poi-tab:hover {
    border-color: #bbb;
    background: #fafafa;
}

.loc-poi-tab.active {
    border-color: #111;
    background: #f9f9f9;
    color: #111;
}

.loc-poi-tab-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
}

.loc-poi-tab-label {
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.loc-poi-tab-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    background: #111;
    color: #fff;
    font-size: 0.65rem;
    font-weight: 700;
    line-height: 1;
    padding: 2px 5px;
    border-radius: 20px;
    min-width: 18px;
    text-align: center;
}

.loc-poi-tab.active .loc-poi-tab-badge {
    background: #111;
}

/* ─── POI Zoznam ─── */
.loc-poi-list-wrap {
    margin-top: 8px;
    border: 1px solid #eaeaea;
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
    max-height: 320px;
    overflow-y: auto;
}

.loc-poi-list-wrap::-webkit-scrollbar { width: 4px; }
.loc-poi-list-wrap::-webkit-scrollbar-track { background: transparent; }
.loc-poi-list-wrap::-webkit-scrollbar-thumb { background: #ddd; border-radius: 4px; }

.loc-poi-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 14px;
    border-bottom: 1px solid #f2f2f2;
    transition: background 0.1s;
}

.loc-poi-item:last-child {
    border-bottom: none;
}

.loc-poi-item:hover {
    background: #fafafa;
}

.loc-poi-item-info {
    flex: 1;
    min-width: 0;
}

.loc-poi-item-name {
    font-size: 0.83rem;
    font-weight: 500;
    color: #222;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.loc-poi-item-addr {
    font-size: 0.72rem;
    color: #999;
    margin-top: 1px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.loc-poi-item-dist {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    flex-shrink: 0;
    gap: 1px;
}

.loc-poi-item-meters {
    font-size: 0.8rem;
    font-weight: 700;
    color: #111;
}

.loc-poi-item-walk {
    font-size: 0.7rem;
    color: #999;
}

.loc-poi-empty {
    padding: 24px 16px;
    text-align: center;
    color: #aaa;
    font-size: 0.82rem;
}

/* ─── PDF EXPORT BUTTON ─── */
.loc-export-btn {
    display: flex;
    align-items: center;
    gap: 7px;
    margin: 20px 0 4px;
    padding: 10px 18px;
    background: #111;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 0.82rem;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: background 0.15s;
    width: 100%;
    justify-content: center;
}

.loc-export-btn:hover { background: #333; }
.loc-export-btn:disabled { opacity: 0.6; cursor: default; }

/* ── LOADING ANIMATION ──────────────────────────────────────────────────────── */

@keyframes spin {
    to { transform: rotate(360deg); }
}

@keyframes locStepIn {
    from { opacity: 0; transform: translateY(5px); }
    to   { opacity: 1; transform: translateY(0); }
}

.loc-loading-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 52px 24px 40px;
    text-align: center;
}

.loc-loading-spinner {
    width: 52px;
    height: 52px;
    border: 3px solid #eee;
    border-top-color: #111;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin-bottom: 22px;
    flex-shrink: 0;
}

.loc-loading-title {
    font-size: 14px;
    color: #333;
    margin-bottom: 24px;
}

.loc-loading-steps {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 22px;
    min-width: 220px;
    text-align: left;
}

.loc-loading-step {
    font-size: 12px;
    color: #aaa;
    padding-left: 22px;
    position: relative;
    opacity: 0;
    line-height: 1.4;
}

.loc-loading-step::before {
    content: '○';
    position: absolute;
    left: 0;
    color: #ddd;
}

.loc-step-done {
    opacity: 1;
    color: #444;
    animation: none;
}
.loc-step-done::before {
    content: '✓';
    color: #111;
    font-weight: 700;
}

.loc-step-1 { animation: locStepIn 0.4s ease 1.8s forwards; }
.loc-step-2 { animation: locStepIn 0.4s ease 5.5s forwards; }
.loc-step-3 { animation: locStepIn 0.4s ease 10s  forwards; }

.loc-loading-note {
    font-size: 11px;
    color: #bbb;
    opacity: 0;
    animation: locStepIn 0.4s ease 1s forwards;
}

/* ─── Stale overlay ─── */
.loc-stale-overlay {
    position: sticky;
    top: 0;
    z-index: 10;
    background: #fffbe6;
    border: 1px solid #f0d060;
    border-radius: 6px;
    padding: 8px 14px;
    font-size: 12px;
    color: #7a6000;
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

/* ─── History chips ─── */
.loc-history-wrap {
    margin-bottom: 12px;
}

.loc-history-label {
    font-size: 0.65rem;
    font-weight: 800;
    color: #999;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 8px;
}

.loc-history-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.loc-history-chip {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 5px 10px;
    background: #f4f6fa;
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    font-size: 0.78rem;
    font-weight: 600;
    color: #333;
    cursor: pointer;
    font-family: inherit;
    transition: background 0.15s, border-color 0.15s;
}

.loc-history-chip:hover {
    background: #eef1f7;
    border-color: #c5cdd9;
}

.loc-history-stars {
    font-size: 0.7rem;
    color: #888;
    letter-spacing: 1px;
}

/* ─── Interpretation callouts ─── */
.loc-chart-interpretation {
    font-size: 0.82rem;
    line-height: 1.55;
    color: #4a5568;
    margin-top: 14px;
    padding: 12px 16px;
    background: #f8fafc;
    border-left: 3px solid #111;
    border-radius: 0 6px 6px 0;
}
.loc-market-explanation {
    font-size: 0.85rem;
    line-height: 1.6;
    color: #333;
}

.loc-chart-source {
    margin-top: 10px;
    font-size: 0.67rem;
    color: #bbb;
    text-align: right;
    letter-spacing: 0.01em;
}
.loc-poi-interpretation {
    margin-top: 14px;
    padding: 14px;
    background: #fafbfc;
    border: 1px solid #eef1f5;
    border-radius: 10px;
    font-size: 0.82rem;
    line-height: 1.5;
    color: #555;
}

.loc-address-note {
    display: flex;
    align-items: center;
    gap: 7px;
    margin-top: 10px;
    padding: 10px 14px;
    background: #f0f4ff;
    border: 1px solid #d6e0ff;
    border-radius: 8px;
    font-size: 0.78rem;
    font-weight: 600;
    color: #3451b2;
}
.loc-address-note svg { flex-shrink: 0; }

/* ─── Address Confirmation Modal ────────────────────────────────────────────── */

@keyframes locConfirmIn {
    from { opacity: 0; transform: scale(0.95) translateY(6px); }
    to   { opacity: 1; transform: scale(1)    translateY(0); }
}

.loc-confirm-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.45);
    z-index: 9900;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: locConfirmFadeIn 0.18s ease;
}

@keyframes locConfirmFadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

.loc-confirm-modal {
    background: #fff;
    border-radius: 12px;
    padding: 26px 28px 24px;
    max-width: 380px;
    width: 90%;
    box-shadow: 0 16px 48px rgba(0,0,0,.18);
    animation: locConfirmIn 0.22s cubic-bezier(.34,1.56,.64,1) both;
}

.loc-confirm-eyebrow {
    font-size: .68rem;
    text-transform: uppercase;
    letter-spacing: .12em;
    font-weight: 800;
    color: #999;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.loc-confirm-name {
    font-size: 1.08rem;
    font-weight: 800;
    color: #111;
    margin-bottom: 4px;
}

.loc-confirm-original {
    font-size: .78rem;
    color: #bbb;
    margin-bottom: 20px;
}

.loc-confirm-alts {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 20px;
}

.loc-confirm-alt-btn {
    background: #fff;
    border: 1.5px solid #e5e7eb;
    border-radius: 8px;
    padding: 10px 14px;
    font-size: .88rem;
    font-weight: 700;
    color: #111;
    cursor: pointer;
    text-align: left;
    transition: all .15s;
    font-family: inherit;
    display: flex;
    align-items: center;
    gap: 8px;
}

.loc-confirm-alt-btn:hover {
    border-color: #111;
    background: #fafafa;
}

.loc-confirm-actions {
    display: flex;
    gap: 10px;
}

.loc-confirm-proceed {
    flex: 1;
    background: #111;
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 11px;
    font-size: .88rem;
    font-weight: 700;
    cursor: pointer;
    font-family: inherit;
    transition: opacity .2s;
}

.loc-confirm-proceed:hover { opacity: .8; }

.loc-confirm-cancel {
    background: none;
    border: 1.5px solid #e5e7eb;
    border-radius: 8px;
    padding: 11px 16px;
    font-size: .88rem;
    font-weight: 700;
    color: #666;
    cursor: pointer;
    font-family: inherit;
    transition: all .15s;
}

.loc-confirm-cancel:hover { border-color: #999; color: #111; }

/* ─── Tax Benefits Card ───────────────────────────────────────────────────── */
.loc-tax-card {
    background: #fff;
    border: 1px solid #eef1f5;
    border-radius: 12px;
    padding: 24px;
    animation: localityFadeIn 0.35s ease 0.1s both;
}

.loc-tax-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 18px;
}

.loc-tax-icon {
    width: 38px;
    height: 38px;
    background: #f0f4ff;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #1a56db;
}

.loc-tax-title {
    font-size: 0.95rem;
    font-weight: 800;
    color: #111;
    line-height: 1.2;
}

.loc-tax-subtitle {
    font-size: 0.72rem;
    color: #999;
    font-weight: 600;
    margin-top: 2px;
}

.loc-tax-items {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.loc-tax-item {
    display: flex;
    gap: 12px;
    padding: 13px 14px;
    background: #fafbfc;
    border-radius: 8px;
    border: 1px solid #f0f0f2;
    transition: background 0.15s;
}

.loc-tax-item:hover {
    background: #f4f6fa;
}

.loc-tax-item-icon {
    font-size: 1.2rem;
    flex-shrink: 0;
    line-height: 1.5;
}

.loc-tax-item-body {
    flex: 1;
    min-width: 0;
}

.loc-tax-item-title {
    font-size: 0.82rem;
    font-weight: 700;
    color: #111;
    margin-bottom: 3px;
}

.loc-tax-item-text {
    font-size: 0.78rem;
    line-height: 1.55;
    color: #555;
}

.loc-tax-item-text strong {
    color: #111;
    font-weight: 700;
}

/* ─── Score card ─── */
.loc-score-card {
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    padding: 16px 18px;
    margin-bottom: 14px;
}

.loc-score-header {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.loc-score-stars {
    font-size: 1.35rem;
    letter-spacing: 2px;
    line-height: 1;
    color: #111;
}

.loc-score-verdict {
    font-size: 0.88rem;
    font-weight: 700;
    color: #111;
}

.loc-score-details {
    margin-top: 10px;
    border-top: 1px solid #e5e7eb;
    padding-top: 10px;
}

.loc-score-summary {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.78rem;
    font-weight: 700;
    color: #555;
    cursor: pointer;
    list-style: none;
    user-select: none;
}

.loc-score-summary::-webkit-details-marker { display: none; }

.loc-score-chevron {
    transition: transform 0.2s ease;
    flex-shrink: 0;
}

details.loc-score-details[open] .loc-score-chevron {
    transform: rotate(180deg);
}

.loc-score-factors {
    margin-top: 10px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.loc-score-factor {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.loc-score-factor-icon {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 800;
    flex-shrink: 0;
    margin-top: 1px;
}

.loc-score-factor-icon.ok {
    background: #ecfdf5;
    color: #059669;
}

.loc-score-factor-icon.bad {
    background: #fef2f2;
    color: #dc2626;
}

.loc-score-factor-icon.info {
    background: #eff6ff;
    color: #2563eb;
    font-size: 0.65rem;
}

.loc-score-factor-body {
    flex: 1;
    min-width: 0;
}

.loc-score-factor-label {
    font-size: 0.78rem;
    font-weight: 600;
    color: #111;
    margin-bottom: 1px;
}

.loc-score-factor-value {
    font-size: 0.73rem;
    color: #777;
}

/* ═══════════════════════════════════════════════════════════════
   ENHANCED LOCALITY — Farebná mapa, score panel, show-more, popup
   ═══════════════════════════════════════════════════════════════ */

/* ─── Fullscreen button (Leaflet control) ─── */
.loc-fullscreen-btn {
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    cursor: pointer;
    border: none;
    color: #444;
    border-radius: 4px;
    transition: color 0.15s, background 0.15s;
    box-shadow: 0 1px 5px rgba(0,0,0,0.2);
}
.loc-fullscreen-btn:hover {
    color: #111;
    background: #f4f4f4;
}

/* ─── POI Markers — override size ─── */
.marker-pin-poi {
    width: 14px !important;
    height: 14px !important;
    border: 2px solid rgba(255,255,255,0.92) !important;
    border-radius: 50% !important;
    box-shadow: 0 1px 5px rgba(0,0,0,0.28) !important;
}

/* ─── Leaflet Popup — custom styles ─── */
.loc-popup {
    font-family: inherit;
    min-width: 160px;
    max-width: 220px;
}
.loc-popup-name {
    font-size: 0.85rem;
    font-weight: 700;
    color: #111;
    margin-bottom: 5px;
    line-height: 1.3;
}
.loc-popup-meta {
    display: flex;
    flex-direction: column;
    gap: 2px;
    margin-bottom: 7px;
}
.loc-popup-type {
    font-size: 0.68rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}
.loc-popup-addr {
    font-size: 0.72rem;
    color: #888;
    line-height: 1.35;
}
.loc-popup-dist {
    font-size: 0.75rem;
    font-weight: 700;
    color: #555;
    border-top: 1px solid #f0f0f0;
    padding-top: 5px;
    margin-top: 2px;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* ─── Location Score Panel ─── */
.loc-location-scores {
    background: #fff;
    border: 1px solid #eef1f5;
    border-top: none;
    padding: 14px 16px 12px;
    animation: localityFadeIn 0.35s ease both;
}

.loc-lscore-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 13px;
}

.loc-lscore-title {
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: #888;
}

.loc-lscore-overall {
    display: flex;
    align-items: baseline;
    gap: 1px;
    font-weight: 800;
}

.loc-lscore-overall-num {
    font-size: 1.45rem;
    line-height: 1;
}

.loc-lscore-overall-denom {
    font-size: 0.7rem;
    color: #bbb;
    font-weight: 600;
}

.loc-lscore-rows {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.loc-lscore-row {
    display: grid;
    grid-template-columns: 108px 1fr 36px 58px;
    align-items: center;
    gap: 8px;
}

.loc-lscore-label {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 0.74rem;
    font-weight: 600;
    color: #444;
    white-space: nowrap;
}

.loc-lscore-bar-wrap {
    height: 6px;
    background: #f0f0f2;
    border-radius: 3px;
    overflow: hidden;
}

.loc-lscore-bar {
    height: 100%;
    border-radius: 3px;
    transition: width 0.7s cubic-bezier(0.4, 0, 0.2, 1);
    width: 0;
}

.loc-lscore-value {
    font-size: 0.74rem;
    font-weight: 800;
    text-align: right;
    white-space: nowrap;
}

.loc-lscore-status {
    font-size: 0.66rem;
    font-weight: 700;
    color: #bbb;
    text-align: right;
    white-space: nowrap;
}

.loc-lscore-note {
    margin-top: 10px;
    font-size: 0.67rem;
    color: #ccc;
    font-style: italic;
    line-height: 1.4;
}

/* ─── Show More Button ─── */
.loc-show-more-btn {
    display: block;
    width: 100%;
    padding: 10px 16px;
    background: #f8f9fb;
    border: none;
    border-top: 1px solid #eaeaea;
    font-size: 0.78rem;
    font-weight: 700;
    color: #555;
    cursor: pointer;
    text-align: center;
    transition: background 0.15s, color 0.15s;
    font-family: inherit;
    letter-spacing: 0.01em;
}
.loc-show-more-btn:hover {
    background: #eef0f4;
    color: #111;
}

/* ─── Fullscreen map overlay ─── */
.loc-map-container:-webkit-full-screen {
    height: 100vh !important;
}
.loc-map-container:-moz-full-screen {
    height: 100vh !important;
}
.loc-map-container:fullscreen {
    height: 100vh !important;
}


/* ═══════════════════════════════════════════════════════════════
   FULLSCREEN PANEL — overlay vo vnútri Leaflet mapy
   ═══════════════════════════════════════════════════════════════ */

.loc-fs-panel {
    position: absolute;
    top: 0;
    right: 0;
    width: 280px;
    height: 100%;
    z-index: 1000;
    display: flex;
    flex-direction: row;
    transform: translateX(0);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    pointer-events: none;
}
.loc-fs-panel > * { pointer-events: all; }
.loc-fs-panel[hidden] { display: none; }
.loc-fs-panel.loc-fs-collapsed { transform: translateX(calc(100% - 36px)); }

/* Toggle tlačidlo — vždy viditeľné na ľavom okraji panela */
.loc-fs-toggle {
    width: 36px;
    align-self: center;
    height: 56px;
    background: rgba(255,255,255,0.96);
    border: 1.5px solid rgba(0,0,0,0.08);
    border-right: none;
    border-radius: 10px 0 0 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    flex-shrink: 0;
    box-shadow: -2px 0 10px rgba(0,0,0,0.1);
    color: #555;
    transition: color 0.15s, background 0.15s;
}
.loc-fs-toggle:hover { background: #fff; color: #111; }
.loc-fs-toggle svg { transition: transform 0.3s ease; }
.loc-fs-panel.loc-fs-collapsed .loc-fs-toggle svg { transform: rotate(180deg); }

/* Vnútorný obsah panela */
.loc-fs-inner {
    flex: 1;
    background: rgba(255,255,255,0.97);
    backdrop-filter: blur(8px);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: -4px 0 24px rgba(0,0,0,0.13);
}

/* Hlavička */
.loc-fs-header {
    padding: 14px 14px 10px;
    border-bottom: 1px solid #eef1f5;
    font-size: 0.78rem;
    font-weight: 800;
    color: #111;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    flex-shrink: 0;
}

/* Tab bar — ikonky kategórií */
.loc-fs-tab-bar {
    display: flex;
    gap: 4px;
    padding: 10px 10px 6px;
    flex-wrap: wrap;
    flex-shrink: 0;
    border-bottom: 1px solid #f0f0f0;
}
.loc-fs-tab {
    flex: 1 1 auto;
    min-width: 32px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1.5px solid #eaeaea;
    border-radius: 8px;
    background: #fff;
    cursor: pointer;
    position: relative;
    transition: border-color 0.15s, background 0.15s;
    padding: 0;
    color: #111;
}
.loc-fs-tab:hover { border-color: #bbb; background: #fafafa; }
.loc-fs-tab.active { border-color: #111; background: #f9f9f9; color: #111; }
.loc-fs-tab-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #111;
    color: #fff;
    font-size: 0.58rem;
    font-weight: 800;
    padding: 1px 4px;
    border-radius: 10px;
    line-height: 1.4;
    min-width: 14px;
    text-align: center;
}
.loc-fs-tab.active .loc-fs-tab-badge { background: #333; }

/* Scrollovateľný obsah */
.loc-fs-content {
    flex: 1;
    overflow-y: auto;
    padding: 8px 10px 12px;
    -webkit-overflow-scrolling: touch;
}
.loc-fs-content::-webkit-scrollbar { width: 3px; }
.loc-fs-content::-webkit-scrollbar-thumb { background: #ddd; border-radius: 3px; }

/* POI zoznam v paneli — kompaktnejší */
.loc-fs-content .loc-poi-item { padding: 8px 10px; }
.loc-fs-content .loc-poi-item-name { font-size: 0.78rem; }
.loc-fs-content .loc-poi-item-addr { font-size: 0.68rem; }

/* Prázdny stav v paneli */
.loc-fs-empty {
    padding: 20px 8px;
    text-align: center;
    color: #bbb;
    font-size: 0.78rem;
    line-height: 1.5;
}

/* ═══════════════════════════════════════════════════════════════
   TOUCH TARGETS — všetky interaktívne prvky min 44px
   ═══════════════════════════════════════════════════════════════ */
.loc-poi-tab,
.loc-confirm-proceed,
.loc-confirm-cancel,
.loc-confirm-alt-btn,
.loc-export-btn,
.loc-history-chip,
.loc-show-more-btn {
    min-height: 44px;
}

/* ═══════════════════════════════════════════════════════════════
   FLOATING MAP EXPAND BUTTON — zobrazí sa len na mobile
   ═══════════════════════════════════════════════════════════════ */
.loc-map-expand-btn {
    display: none;
    width: 100%;
    background: #f8f9fb;
    border: 1px solid #eef1f5;
    border-top: none;
    border-radius: 0 0 12px 12px;
    padding: 9px 16px;
    font-size: 0.78rem;
    font-weight: 700;
    color: #555;
    cursor: pointer;
    font-family: inherit;
    white-space: nowrap;
    transition: background 0.15s, color 0.15s;
    min-height: 40px;
    justify-content: center;
    align-items: center;
    gap: 6px;
}
.loc-map-expand-btn:hover { background: #eef0f4; color: #111; }
@media (max-width: 767px) {
    .loc-map-expand-btn { display: flex; }
}

/* ═══════════════════════════════════════════════════════════════
   BOTTOM-SHEET CONFIRM MODAL — na mobile slide up zo spodku
   ═══════════════════════════════════════════════════════════════ */
@media (max-width: 767px) {
    .loc-confirm-overlay {
        align-items: flex-end;
        padding: 0;
    }
    .loc-confirm-modal {
        max-width: 100%;
        width: 100%;
        border-radius: 20px 20px 0 0;
        padding: 20px 20px max(24px, env(safe-area-inset-bottom));
        animation: locBottomSheetIn 0.28s cubic-bezier(0.32, 0.72, 0, 1) both;
    }
    .loc-confirm-modal::before {
        content: '';
        display: block;
        width: 40px;
        height: 4px;
        background: #ddd;
        border-radius: 2px;
        margin: 0 auto 18px;
    }
}
@keyframes locBottomSheetIn {
    from { transform: translateY(100%); opacity: 0.6; }
    to   { transform: translateY(0);    opacity: 1;   }
}

/* ═══════════════════════════════════════════════════════════════
   BOTTOM DRAWER — fullscreen POI panel na mobile
   ═══════════════════════════════════════════════════════════════ */
@media (max-width: 767px) {
    .loc-fs-panel {
        top: auto;
        right: 0;
        bottom: 0;
        left: 0;
        width: 100%;
        height: auto;
        max-height: 60vh;
        flex-direction: column;
        transform: translateY(calc(100% - 44px));
        border-radius: 16px 16px 0 0;
        overflow: hidden;
    }
    .loc-fs-panel.loc-fs-expanded { transform: translateY(0); }
    .loc-fs-panel.loc-fs-collapsed { transform: translateY(calc(100% - 44px)); }

    /* Handle bar namiesto bočného toggle tlačidla */
    .loc-fs-toggle {
        width: 100%;
        height: 44px;
        border-radius: 0;
        border: none;
        border-bottom: 1px solid #eef1f5;
        justify-content: center;
        box-shadow: none;
        order: -1;
    }
    .loc-fs-toggle::before {
        content: '';
        display: block;
        width: 36px;
        height: 4px;
        background: #ddd;
        border-radius: 2px;
        position: absolute;
        top: 8px;
        left: 50%;
        transform: translateX(-50%);
    }
    .loc-fs-inner {
        flex: 1;
        max-height: calc(60vh - 44px);
        box-shadow: none;
    }
}

/* ═══════════════════════════════════════════════════════════════
   SAFE AREA — iPhone notch / Dynamic Island
   ═══════════════════════════════════════════════════════════════ */
.locality-address-panel {
    padding-bottom: max(clamp(16px, 3vw, 32px), env(safe-area-inset-bottom, 0px));
}

/* ═══════════════════════════════════════════════════════════════
   REDUCED MOTION — slabé zariadenia / accessibility
   ═══════════════════════════════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
    .loc-map-container,
    .loc-fs-panel,
    .loc-confirm-modal,
    .loc-lscore-bar,
    .loc-chart-card,
    .loc-fs-toggle svg {
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
    }
    .loc-loading-spinner {
        animation: none !important;
        opacity: 1 !important;
    }
    [class*="locStep"],
    .loc-loading-step {
        animation: none !important;
        opacity: 1 !important;
    }
}
