/*
 * AtlasStore.Outlet - Public Coverage Page Styles
 * "Our Outlets" customer-facing page with interactive map and outlet cards.
 * Designed to match the Tasty Treat brand: warm reds, clean whites, rounded cards.
 */

/* ============================================================
   Hero Section
   ============================================================ */
.otl-pub-hero {
    position: relative;
    overflow: hidden;
    border-radius: 1.25rem;
    margin-bottom: 2.5rem;
    padding: 3rem 2rem;
    background: linear-gradient(135deg, #e53935 0%, #b71c1c 50%, #880e4f 100%);
    color: #fff;
    text-align: center;
}

.otl-pub-hero__bg {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 20% 80%, rgba(255, 255, 255, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(255, 255, 255, 0.06) 0%, transparent 50%);
    pointer-events: none;
}

.otl-pub-hero__content {
    position: relative;
    z-index: 1;
    max-width: 700px;
    margin: 0 auto;
}

.otl-pub-hero__badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.35rem 1rem;
    border-radius: 2rem;
    background: rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(6px);
    font-size: 0.82rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    margin-bottom: 1rem;
}

.otl-pub-hero__badge-icon {
    font-size: 1rem;
}

.otl-pub-hero__title {
    font-size: clamp(1.6rem, 4vw, 2.5rem);
    font-weight: 800;
    line-height: 1.2;
    margin: 0 0 0.75rem;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.15);
}

.otl-pub-hero__subtitle {
    font-size: 1.05rem;
    opacity: 0.92;
    margin: 0 0 1.75rem;
    line-height: 1.5;
}

.otl-pub-hero__stats {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.otl-pub-stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 80px;
}

.otl-pub-stat__number {
    font-size: 1.75rem;
    font-weight: 800;
    line-height: 1.1;
}

.otl-pub-stat__label {
    font-size: 0.78rem;
    opacity: 0.85;
    margin-top: 0.2rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

/* ============================================================
   Map Section
   ============================================================ */
.otl-pub-map-section {
    margin-bottom: 2.5rem;
}

.otl-pub-map-header {
    text-align: center;
    margin-bottom: 1.25rem;
}

.otl-pub-map-header__title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1a1a2e;
    margin: 0 0 0.3rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.otl-pub-map-header__icon {
    font-size: 1.3rem;
}

.otl-pub-map-header__desc {
    font-size: 0.92rem;
    color: #666;
    margin: 0;
}

.otl-pub-map-container {
    border-radius: 1rem;
    overflow: hidden;
    box-shadow:
        0 4px 24px -6px rgba(0, 0, 0, 0.12),
        0 0 0 1px rgba(0, 0, 0, 0.04);
    background: #f0f0f0;
}

.otl-pub-map-canvas {
    width: 100%;
    height: 480px;
}

.otl-pub-map-legend {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-top: 0.85rem;
    font-size: 0.85rem;
    color: #555;
}

.otl-pub-legend-item {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.otl-pub-legend-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.otl-pub-legend-dot--delivery {
    background: #e53935;
    box-shadow: 0 0 0 3px rgba(229, 57, 53, 0.2);
}

.otl-pub-legend-dot--pickup {
    background: #8d9ba9;
    box-shadow: 0 0 0 3px rgba(141, 155, 169, 0.2);
}

/* ============================================================
   Search Section
   ============================================================ */
.otl-pub-search-section {
    margin-bottom: 2rem;
    display: flex;
    justify-content: center;
}

.otl-pub-search {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    width: 100%;
    max-width: 480px;
    padding: 0.75rem 1.25rem;
    border-radius: 3rem;
    background: #fff;
    border: 2px solid #eee;
    box-shadow: 0 2px 12px -4px rgba(0, 0, 0, 0.06);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.otl-pub-search:focus-within {
    border-color: #e53935;
    box-shadow: 0 4px 18px -4px rgba(229, 57, 53, 0.15);
}

.otl-pub-search__icon {
    font-size: 1.1rem;
    flex-shrink: 0;
}

.otl-pub-search__input {
    border: none;
    outline: none;
    background: transparent;
    font-size: 0.95rem;
    width: 100%;
    color: #333;
}

.otl-pub-search__input::placeholder {
    color: #aaa;
}

/* ============================================================
   Cards Grid
   ============================================================ */
.otl-pub-cards-section {
    margin-bottom: 3rem;
}

.otl-pub-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.5rem;
}

/* ============================================================
   City Group Headers
   ============================================================ */
.otl-pub-city-group {
    margin-bottom: 2.5rem;
}

.otl-pub-city-header {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.6rem 1rem;
    margin-bottom: 1.25rem;
    background: linear-gradient(90deg, #fff5f5 0%, #ffffff 100%);
    border-left: 4px solid #e53935;
    border-radius: 0 0.5rem 0.5rem 0;
    box-shadow: 0 1px 6px -2px rgba(0, 0, 0, 0.06);
}

.otl-pub-city-header__icon {
    font-size: 1.2rem;
}

.otl-pub-city-header__name {
    font-size: 1.15rem;
    font-weight: 700;
    color: #1a1a2e;
    margin: 0;
    flex: 1;
}

.otl-pub-city-header__count {
    font-size: 0.8rem;
    color: #888;
    background: #f0f0f0;
    padding: 0.2rem 0.6rem;
    border-radius: 1rem;
    font-weight: 500;
}

/* ============================================================
   Individual Card
   ============================================================ */
.otl-pub-card {
    background: #fff;
    border-radius: 1rem;
    border: 1px solid #f0f0f0;
    box-shadow: 0 2px 16px -4px rgba(0, 0, 0, 0.07);
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    display: flex;
    flex-direction: column;
}

.otl-pub-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 32px -8px rgba(229, 57, 53, 0.15);
}

.otl-pub-card__header {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1.25rem 1.25rem 0.75rem;
    flex-wrap: wrap;
}

.otl-pub-card__icon-wrap {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: linear-gradient(135deg, #ffebee 0%, #fce4ec 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    flex-shrink: 0;
}

.otl-pub-card__title-area {
    flex: 1;
    min-width: 0;
}

.otl-pub-card__name {
    font-size: 1.05rem;
    font-weight: 700;
    color: #1a1a2e;
    margin: 0;
    line-height: 1.3;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.otl-pub-card__code {
    font-size: 0.75rem;
    color: #999;
    font-weight: 500;
    letter-spacing: 0.02em;
}

.otl-pub-card__badge {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.25rem 0.7rem;
    border-radius: 2rem;
    font-size: 0.72rem;
    font-weight: 600;
    white-space: nowrap;
}

.otl-pub-card__badge--delivery {
    background: #e8f5e9;
    color: #2e7d32;
}

.otl-pub-card__badge--pickup {
    background: #f3e5f5;
    color: #6a1b9a;
}

.otl-pub-card__body {
    padding: 0 1.25rem;
    flex: 1;
}

.otl-pub-card__row {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    font-size: 0.88rem;
    color: #555;
    margin-bottom: 0.5rem;
    line-height: 1.4;
}

.otl-pub-card__row-icon {
    flex-shrink: 0;
    font-size: 0.9rem;
    margin-top: 0.1rem;
}

.otl-pub-card__row a {
    color: #e53935;
    text-decoration: none;
}

.otl-pub-card__row a:hover {
    text-decoration: underline;
}

.otl-pub-card__footer {
    padding: 0.75rem 1.25rem;
    margin-top: 0.5rem;
    background: #fafafa;
    border-top: 1px solid #f5f5f5;
}

.otl-pub-card__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.otl-pub-card__meta-item {
    font-size: 0.8rem;
    color: #666;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.otl-pub-card__min-order {
    font-size: 0.78rem;
    color: #888;
    margin-top: 0.4rem;
    font-style: italic;
}

.otl-pub-card__locate-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    width: 100%;
    padding: 0.75rem;
    border: none;
    border-top: 1px solid #f0f0f0;
    background: #fff;
    color: #e53935;
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease;
}

.otl-pub-card__locate-btn:hover {
    background: #e53935;
    color: #fff;
}

/* ============================================================
   Empty State
   ============================================================ */
.otl-pub-empty {
    text-align: center;
    padding: 3rem 1rem;
    color: #888;
}

.otl-pub-empty__icon {
    font-size: 3rem;
    display: block;
    margin-bottom: 1rem;
    opacity: 0.5;
}

/* ============================================================
   Marker Cluster (brand color) - Glossy sexy style
   ============================================================ */
.otl-pub-cluster {
    display: flex;
    align-items: center;
    justify-content: center;
    animation: otl-cluster-pop 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    transition: transform 0.2s ease;
}

@keyframes otl-cluster-pop {
    0% { transform: scale(0); opacity: 0; }
    60% { transform: scale(1.1); }
    100% { transform: scale(1); opacity: 1; }
}

.otl-pub-cluster:hover {
    transform: scale(1.15);
    filter: brightness(1.1);
}

.otl-pub-cluster:active {
    transform: scale(0.95);
}

/* ============================================================
   Default Pin (fallback) - uses brand color
   ============================================================ */
.otl-pub-pin {
    width: 36px;
    height: 36px;
    border-radius: 50% 50% 50% 0;
    background: #8d9ba9;
    display: flex;
    align-items: center;
    justify-content: center;
    transform: rotate(-45deg);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
    cursor: pointer;
    transition: transform 0.2s ease;
}

.otl-pub-pin--delivery {
    background: #e53935;
}

.otl-pub-pin:hover {
    transform: rotate(-45deg) scale(1.15);
}

.otl-pub-pin__body {
    transform: rotate(45deg);
    font-size: 1rem;
}

/* ============================================================
   Custom Branded Pin (Marker.png in teardrop) - brand color
   ============================================================ */
.otl-pub-pin-custom {
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
    transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
    filter: drop-shadow(0 4px 8px rgba(229, 57, 53, 0.4));
}

.otl-pub-pin-custom:hover {
    transform: scale(1.2) translateY(-4px);
    filter: drop-shadow(0 6px 12px rgba(229, 57, 53, 0.5));
}

.otl-pub-pin-custom__body {
    width: 25px;
    height: 25px;
    border-radius: 50%;
    background: linear-gradient(145deg, #e53935 0%, #b71c1c 100%);
    border: 3px solid #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow:
        inset 0 2px 6px rgba(0, 0, 0, 0.3),
        0 2px 12px rgba(229, 57, 53, 0.4);
    position: relative;
    z-index: 1;
}

.otl-pub-pin-custom--pickup .otl-pub-pin-custom__body {
    background: linear-gradient(145deg, #3d3d3d 0%, #555555 100%);
    border-color: rgba(255, 255, 255, 0.8);
    box-shadow:
        inset 0 2px 6px rgba(0, 0, 0, 0.3),
        0 2px 12px rgba(0, 0, 0, 0.2);
}

.otl-pub-pin-custom__img {
    width: 28px;
    height: 28px;
    object-fit: contain;
}

.otl-pub-pin-custom--pickup .otl-pub-pin-custom__img {
    filter: grayscale(0.4) opacity(0.7);
}

.otl-pub-pin-custom__tail {
    width: 0;
    height: 0;
    border-left: 9px solid transparent;
    border-right: 9px solid transparent;
    border-top: 14px solid #b71c1c;
    margin-top: -3px;
    position: relative;
    z-index: 0;
}

.otl-pub-pin-custom--pickup .otl-pub-pin-custom__tail {
    border-top-color: #3d3d3d;
}

/* ============================================================
   Info Window
   ============================================================ */
.otl-pub-iw {
    padding: 0.75rem;
    max-width: 260px;
    font-family: inherit;
}

.otl-pub-iw__name {
    font-size: 1rem;
    font-weight: 700;
    color: #1a1a2e;
    margin-bottom: 0.4rem;
}

.otl-pub-iw__addr,
.otl-pub-iw__phone {
    font-size: 0.85rem;
    color: #555;
    margin-bottom: 0.25rem;
}

.otl-pub-iw__status {
    margin-top: 0.5rem;
    font-size: 0.82rem;
    font-weight: 600;
    color: #2e7d32;
}

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 768px) {
    .otl-pub-hero {
        padding: 2rem 1.25rem;
        border-radius: 0.75rem;
    }

    .otl-pub-hero__stats {
        gap: 1.25rem;
    }

    .otl-pub-stat__number {
        font-size: 1.4rem;
    }

    .otl-pub-map-canvas {
        height: 350px;
    }

    .otl-pub-cards-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .otl-pub-map-legend {
        flex-direction: column;
        align-items: center;
        gap: 0.5rem;
    }
}

@media (max-width: 480px) {
    .otl-pub-hero {
        padding: 1.5rem 1rem;
    }

    .otl-pub-hero__title {
        font-size: 1.4rem;
    }

    .otl-pub-map-canvas {
        height: 280px;
    }

    .otl-pub-search {
        padding: 0.6rem 1rem;
    }
}
