/*
 * De ce exista:
 * Acest fisier stilizeaza ecranul dedicat pentru harta ofertelor clientului.
 *
 * Responsabilitate:
 * Defineste compozitia pentru panoul de harta, markerele si bottom sheet-ul
 * fara sa atinga alte ecrane client sau worker.
 *
 * Ce NU face:
 * Nu stilizeaza detaliile ofertei sau create flow-ul client.
 *
 * Depinde de:
 * tpl-screen-client-map-offers, Leaflet si stilurile shared app-v2.
 */

.v2-screen--map {
    display: grid;
    gap: 14px;
    padding-bottom: 6px;
}

.v2-map-hero {
    display: grid;
    gap: 12px;
    padding: 18px 18px 0;
    margin-bottom: -2px;
}

.v2-map-hero-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.v2-map-hero-copy {
    display: grid;
    gap: 6px;
}

.v2-map-hero .v2-title {
    letter-spacing: -0.04em;
}

.v2-map-trust-note {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
    width: fit-content;
    max-width: min(100%, 420px);
}

.v2-map-trust-note .v2-copy {
    margin: 0;
}

.v2-map-trust-icon {
    display: inline-grid;
    place-items: center;
    width: 26px;
    height: 26px;
    border-radius: 999px;
    background: rgba(22, 163, 74, 0.12);
    color: #16a34a;
    font-size: 0.9rem;
    font-weight: 700;
}

.v2-map-filter-card {
    display: grid;
    gap: 12px;
    padding: 14px;
    border-radius: 24px;
    background:
        radial-gradient(circle at top left, rgba(220, 252, 231, 0.72), transparent 28%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(249, 250, 251, 0.98));
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.08);
}

.v2-map-filter-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.v2-map-filter-summary .v2-filter-item {
    min-height: 74px;
    padding: 14px 16px;
    border-radius: 20px;
    border: 1px solid rgba(209, 213, 219, 0.9);
    background: #ffffff;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
}

.v2-map-filter-summary .v2-filter-item strong {
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #111827;
}

.v2-map-filter-summary .v2-filter-value {
    font-size: 1.02rem;
    font-weight: 600;
    color: #111827;
}

.v2-map-filter-card .v2-filter-actions {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
}

.v2-map-filter-card .v2-filter-actions .v2-button,
.v2-map-filter-card .v2-filter-actions .v2-button-secondary {
    min-height: 48px;
    border-radius: 18px;
}

.v2-map-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

.v2-map-meta .v2-chip {
    background: rgba(255, 255, 255, 0.98);
    border: 1px solid rgba(209, 213, 219, 0.88);
}

.v2-map-meta .v2-copy {
    margin: 0;
    flex-basis: 100%;
}

.v2-map-panel,
.v2-map-sheet-card-shell,
.v2-map-status-card {
    border-radius: 28px;
    border: 1px solid rgba(229, 231, 235, 0.92);
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 22px 44px rgba(15, 23, 42, 0.1);
}

.v2-map-panel {
    position: relative;
    overflow: hidden;
    min-height: 432px;
    background:
        linear-gradient(180deg, rgba(248, 250, 252, 0.86), rgba(255, 255, 255, 0.94));
}

.v2-map-stage-meta {
    position: absolute;
    inset: 14px 14px auto;
    display: grid;
    gap: 10px;
    z-index: 500;
    pointer-events: none;
}

.v2-map-stage-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.v2-map-stage-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 32px;
    padding: 0 12px;
    border-radius: 999px;
    border: 1px solid rgba(209, 213, 219, 0.86);
    background: rgba(255, 255, 255, 0.94);
    color: #111827;
    font-size: 0.84rem;
    font-weight: 700;
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
}

.v2-map-stage-pill.is-accent {
    background: rgba(22, 163, 74, 0.12);
    border-color: rgba(22, 163, 74, 0.2);
    color: #15803d;
}

.v2-map-stage-note {
    display: inline-flex;
    width: fit-content;
    max-width: min(100%, 280px);
    padding: 8px 12px;
    border-radius: 14px;
    background: rgba(17, 24, 39, 0.82);
    color: #f9fafb;
    font-size: 0.82rem;
    font-weight: 600;
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.18);
}

.v2-map-canvas {
    min-height: 432px;
}

.v2-map-sheet-card-shell {
    position: relative;
    z-index: 2;
    display: grid;
    gap: 14px;
    padding: 14px 14px 16px;
    margin: -94px 10px 0;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(16px);
}

.v2-map-sheet-handle {
    justify-self: center;
    width: 56px;
    height: 6px;
    border-radius: 999px;
    background: rgba(156, 163, 175, 0.55);
}

.v2-map-sheet-head {
    margin-bottom: 0;
    gap: 6px;
}

.v2-map-sheet-head .v2-copy {
    margin: 0;
}

.v2-map-sheet-list {
    display: grid;
    gap: 12px;
}

.v2-map-sheet-card {
    display: grid;
    gap: 12px;
    padding: 16px;
    border-radius: 22px;
    border: 1px solid rgba(229, 231, 235, 0.96);
    background:
        radial-gradient(circle at top right, rgba(220, 252, 231, 0.42), transparent 34%),
        rgba(255, 255, 255, 0.98);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

.v2-map-sheet-copy {
    display: grid;
    gap: 4px;
}

.v2-map-sheet-copy strong {
    font-size: 1.04rem;
}

.v2-map-sheet-copy span,
.v2-map-sheet-empty p,
.v2-map-sheet-hint {
    color: #6b7280;
}

.v2-map-sheet-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.v2-map-sheet-empty {
    display: grid;
    gap: 6px;
    padding: 10px 2px 4px;
}

.v2-map-sheet-card .v2-button-row .v2-button {
    width: 100%;
    min-height: 48px;
    border-radius: 18px;
}

.v2-map-marker {
    min-width: 68px;
    min-height: 44px;
    padding: 0 14px;
    border: 1px solid rgba(22, 163, 74, 0.18);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.98);
    color: #16a34a;
    font-size: 0.92rem;
    font-weight: 800;
    box-shadow: 0 16px 30px rgba(15, 23, 42, 0.12);
}

.v2-map-marker span {
    white-space: nowrap;
}

.v2-map-marker.is-cluster {
    min-width: 56px;
    min-height: 56px;
    padding: 0 18px;
    border-color: rgba(17, 24, 39, 0.16);
    background: #111827;
    color: #ffffff;
    box-shadow: 0 18px 34px rgba(17, 24, 39, 0.24);
}

.v2-map-marker.is-selected {
    outline: 4px solid rgba(245, 158, 11, 0.28);
}

.leaflet-container {
    font: inherit;
    background: #eef2f7;
}

.leaflet-control-zoom {
    overflow: hidden;
    border: 0;
    border-radius: 18px;
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.14);
}

.leaflet-touch .leaflet-bar a,
.leaflet-touch .leaflet-bar a:first-child,
.leaflet-touch .leaflet-bar a:last-child {
    width: 40px;
    height: 40px;
    line-height: 40px;
    border: 0;
}

.leaflet-control-attribution {
    border-radius: 12px 0 0 0;
    background: rgba(255, 255, 255, 0.82);
}

@media (max-width: 430px) {
    .v2-map-hero {
        padding-inline: 12px;
    }

    .v2-map-filter-card .v2-filter-actions {
        grid-template-columns: 1fr 1fr;
    }

    .v2-map-filter-card .v2-filter-actions .v2-button:last-child {
        grid-column: 1 / -1;
    }

    .v2-map-sheet-card-shell {
        margin-inline: 6px;
    }
}

@media (max-width: 389px) {
    .v2-map-filter-summary,
    .v2-map-filter-card .v2-filter-actions {
        grid-template-columns: 1fr;
    }

    .v2-map-filter-card .v2-filter-actions .v2-button:last-child {
        grid-column: auto;
    }

    .v2-map-sheet-card-shell {
        margin-top: -74px;
    }
}
