/* ===========================
   La Foa — Design System
   Light Theme, Premium Feel
   =========================== */

/* --- CSS Variables --- */
:root {
    --color-bg: #FAF8F5;
    --color-surface: #FFFFFF;
    --color-surface-glass: rgba(255, 255, 255, 0.85);
    --color-text: #2C1810;
    --color-text-secondary: #6B5C4E;
    --color-text-muted: #776B5F;
    --color-accent: #8B4513;
    --color-accent-light: #D4A574;
    --color-accent-hover: #A0522D;
    --color-border: #E8DDD0;
    --color-border-light: #F0E8DD;
    --color-shadow: rgba(44, 24, 16, 0.08);
    --color-shadow-strong: rgba(44, 24, 16, 0.15);
    --color-kale: #C0392B;
    --color-kilise: #8E44AD;
    --color-diger: #2980B9;
    --color-marker-glow: rgba(192, 57, 43, 0.3);
    --detail-panel-width: 300px;
    --footer-height: 44px;

    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-serif: 'Noto Serif', Georgia, serif;

    --radius-sm: 6px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;

    --shadow-sm: 0 1px 3px var(--color-shadow);
    --shadow-md: 0 4px 12px var(--color-shadow);
    --shadow-lg: 0 8px 30px var(--color-shadow-strong);
    --shadow-xl: 0 20px 60px var(--color-shadow-strong);

    --transition-fast: 0.15s ease;
    --transition-base: 0.25s ease;
    --transition-slow: 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

/* --- Reset --- */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-sans);
    background: var(--color-bg);
    color: var(--color-text);
    min-height: 100vh;
    overflow: hidden;
    position: relative;
}

/* --- Header --- */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    background: linear-gradient(135deg, rgba(31, 74, 94, 0.94) 0%, rgba(139, 69, 19, 0.94) 100%);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 4px 32px rgba(0, 0, 0, 0.25);
}

.header-content {
    display: grid;
    grid-template-columns: minmax(170px, 1fr) auto minmax(0, 1fr);
    align-items: center;
    padding: 0 24px;
    height: 80px;
    max-width: 100%;
}

.logo-area {
    grid-column: 1;
    display: flex;
    align-items: center;
    position: relative;
    margin-left: 4px;
    padding-left: 110px;
    min-width: 0;
    height: 80px;
    text-decoration: none;
}

.logo-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 120px;
    height: 120px;
    border-radius: var(--radius-md);
    overflow: hidden;
    position: absolute;
    left: 0;
    top: -20px;
    z-index: 101;
}

.logo-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: brightness(1.2) sepia(0.3) saturate(1.5);
}

.logo-text {
    min-width: 0;
    overflow: hidden;
}

.logo-text h1 {
    font-family: var(--font-serif);
    font-size: 0.8rem;
    font-weight: 700;
    color: #E8D8BE;
    line-height: 1;
    letter-spacing: -0.005em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* --- Nav Links --- */
.nav-links {
    grid-column: 2;
    display: flex;
    align-items: center;
    gap: 12px;
    list-style: none;
    justify-self: center;
}

.nav-links a {
    text-decoration: none;
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.95rem;
    font-weight: 500;
    padding: 8px 15px;
    border-radius: 8px;
    transition: var(--transition-fast);
    white-space: nowrap;
    -webkit-tap-highlight-color: transparent;
}

.nav-links a:hover,
.nav-links a:active {
    background: rgba(255, 255, 255, 0.15);
    color: #FFF;
}

.nav-hamburger {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 6px;
    color: #E8D8BE;
    -webkit-tap-highlight-color: transparent;
}

.header-nav {
    grid-column: 3;
    display: flex;
    align-items: center;
    gap: 20px;
    justify-self: end;
    min-width: 0;
    max-width: 100%;
}

.settlement-count {
    font-size: 0.8rem;
    font-weight: 600;
    color: #E8D8BE;
    background: rgba(255, 255, 255, 0.12);
    padding: 6px 14px;
    border-radius: 100px;
    white-space: nowrap;
    flex-shrink: 0;
}

.search-box {
    position: relative;
    display: flex;
    align-items: center;
    flex: 1;
    min-width: 0;
}

.search-icon {
    position: absolute;
    left: 12px;
    color: rgba(255, 255, 255, 0.6);
    pointer-events: none;
}

#searchInput {
    font-family: var(--font-sans);
    font-size: 0.85rem;
    padding: 8px 14px 8px 36px;
    border: 1.5px solid rgba(255, 255, 255, 0.25);
    border-radius: 100px;
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    width: 240px;
    min-width: 90px;
    outline: none;
    transition: border-color var(--transition-fast), box-shadow var(--transition-fast), width var(--transition-base);
}

#searchInput:focus {
    border-color: var(--color-accent-light);
    box-shadow: 0 0 0 3px rgba(212, 165, 116, 0.2);
    width: 300px;
    background: rgba(255, 255, 255, 0.18);
}

#searchInput::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

/* --- Search Results --- */
.search-results {
    position: fixed;
    top: 80px;
    right: 24px;
    width: 320px;
    max-height: 400px;
    overflow-y: auto;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    z-index: 200;
    display: none;
}

.search-results.active {
    display: block;
}

.search-result-item {
    padding: 12px 16px;
    cursor: pointer;
    border-bottom: 1px solid var(--color-border-light);
    transition: background var(--transition-fast);
    display: flex;
    align-items: center;
    gap: 10px;
}

.search-result-item:last-child {
    border-bottom: none;
}

.search-result-item:hover {
    background: #FDF8F3;
}

.search-result-item .result-id {
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--color-accent);
    background: #FDF0E6;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.search-result-item .result-name {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--color-text);
}

/* --- Footer --- */
.site-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: var(--footer-height);
    z-index: 100;
    background: linear-gradient(135deg, rgba(31, 74, 94, 0.94) 0%, rgba(139, 69, 19, 0.94) 100%);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid rgba(255, 255, 255, 0.15);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    gap: 16px;
}

.footer-text {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.75);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.footer-text-right {
    flex-shrink: 0;
    font-weight: 600;
}

@media (max-width: 768px) {
    .footer-text:not(.footer-text-right) {
        display: none;
    }

    .site-footer {
        padding: 0 12px;
        justify-content: center;
    }
}

/* --- Main Content --- */
.main-content {
    position: fixed;
    top: 80px;
    left: 0;
    right: 0;
    bottom: var(--footer-height);
    display: flex;
}

/* --- Map --- */
.map-wrapper {
    flex: 1;
    min-width: 0;
    height: 100%;
    overflow: hidden;
    position: relative;
    cursor: default;
    background: #E8DDD0;
}

/* Blurred backdrop fills the letterbox gaps left when the map (fit via
   Math.min, see fitMapToView) doesn't match the wrapper's aspect ratio */
.map-wrapper::before {
    content: '';
    position: absolute;
    inset: -40px;
    background-image: url('assets/map-low.webp');
    background-size: cover;
    background-position: center;
    filter: blur(35px) brightness(0.88) saturate(1.05);
    z-index: 0;
    pointer-events: none;
}

/* --- Detail Panel (proje hakkında) --- */
.detail-panel {
    width: var(--detail-panel-width);
    flex-shrink: 0;
    height: 100%;
    background: var(--color-surface);
    border-left: 1px solid var(--color-border);
    box-shadow: -2px 0 16px rgba(44, 24, 16, 0.05);
    overflow: hidden;
    display: flex;
}

/* Masaüstünde panel zaten sabit duruyor: aç/kapat kontrolleri yalnızca
   dar ekranlarda (bkz. max-width:1024px bloğu) görünür hale gelir. */
.detail-panel-close,
.lafoa-info-btn {
    display: none;
}

.detail-panel-inner {
    padding: 36px 30px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    overflow-y: auto;
    max-height: 100%;
}

.detail-panel-label {
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--color-accent);
    margin-bottom: 10px;
}

.detail-panel-title {
    flex-shrink: 0;
    font-family: var(--font-serif);
    font-size: 1.08rem;
    font-weight: 700;
    color: var(--color-text);
    line-height: 1.3;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 2px solid var(--color-border);
}

#lafoaNedirText {
    flex-shrink: 0;
}

.detail-panel-text {
    font-family: var(--font-serif);
    font-size: 0.81rem;
    line-height: 1.57;
    color: var(--color-text-secondary);
    margin-bottom: 12px;
}

.detail-panel-text:last-child {
    margin-bottom: 0;
}

.map-container {
    position: absolute;
    z-index: 1;
    transform-origin: 0 0;
    will-change: transform;
    transition: none;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    /* Force GPU compositing layer */
    transform: translate3d(0, 0, 0);
    /* Rendering isolation — browser only repaints this layer */
    contain: strict;
}

.map-image {
    display: block;
    width: 100%;
    height: 100%;
    user-select: none;
    -webkit-user-drag: none;
    /* Smooth WebP scaling during zoom */
    image-rendering: auto;
    -ms-interpolation-mode: bicubic;
}

.markers-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

/* --- Markers --- */
.marker {
    position: absolute;
    pointer-events: all;
    cursor: pointer;
    z-index: 10;
    transform: translate(-50%, -50%);
    /* No transitions on markers — they cause jank during pan/zoom */
    contain: layout style;
}

.marker-dot {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 2.5px solid var(--color-surface);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
    transition: transform var(--transition-fast), box-shadow var(--transition-fast);
    position: relative;
}

.marker-dot::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: transparent;
}

.marker.type-kale .marker-dot {
    background: var(--color-kale);
}

.marker.type-kilise .marker-dot {
    background: var(--color-kilise);
}

.marker.type-diger .marker-dot {
    background: var(--color-diger);
}

.marker:hover .marker-dot {
    transform: scale(1.25);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.marker:hover {
    z-index: 50;
}

.marker.active {
    z-index: 60;
}

.marker.active .marker-dot {
    transform: scale(1.35);
    box-shadow: 0 0 0 4px rgba(139, 69, 19, 0.25), 0 2px 8px rgba(0, 0, 0, 0.3);
}

/* Marker Label (on hover) */
.marker-label {
    position: absolute;
    bottom: calc(100% + 6px);
    left: 50%;
    transform: translateX(-50%) translateY(4px);
    white-space: nowrap;
    background: var(--color-text);
    color: var(--color-surface);
    font-size: 0.7rem;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: var(--radius-sm);
    pointer-events: none;
    opacity: 0;
    transition: opacity var(--transition-fast), transform var(--transition-fast);
    letter-spacing: 0.01em;
}

.marker-label::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: var(--color-text);
}

.marker:hover .marker-label {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* Pulse animation for markers */
@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 var(--color-marker-glow);
    }

    70% {
        box-shadow: 0 0 0 10px rgba(192, 57, 43, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(192, 57, 43, 0);
    }
}

.marker.active .marker-dot::before {
    content: '';
    position: absolute;
    top: -2.5px;
    left: -2.5px;
    right: -2.5px;
    bottom: -2.5px;
    border-radius: 50%;
    animation: pulse 2s infinite;
}

/* --- Map Controls --- */
.map-controls {
    position: absolute;
    bottom: 24px;
    right: 24px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    z-index: 50;
}

.control-btn {
    width: 40px;
    height: 40px;
    border: none;
    background: var(--color-surface);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--color-text-secondary);
    box-shadow: var(--shadow-md);
    transition: background var(--transition-fast), color var(--transition-fast), transform var(--transition-fast);
}

.control-btn:hover {
    background: var(--color-accent);
    color: white;
    transform: scale(1.05);
}

.control-btn:active {
    transform: scale(0.95);
}

/* --- Info Card --- */
.info-card {
    position: fixed;
    bottom: -300px;
    left: calc((100vw - var(--detail-panel-width)) / 2);
    transform: translateX(-50%);
    width: 330px;
    max-width: calc(100vw - var(--detail-panel-width) - 40px);
    background: var(--color-surface);
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    box-shadow: var(--shadow-xl);
    z-index: 150;
    transition: bottom var(--transition-slow);
    overflow: hidden;
}

.info-card.active {
    bottom: var(--footer-height);
}

.info-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--color-accent), var(--color-accent-light));
}

.card-close {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 32px;
    height: 32px;
    border: none;
    background: var(--color-border-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--color-text-secondary);
    transition: background var(--transition-fast), color var(--transition-fast);
    z-index: 5;
}

.card-close:hover {
    background: var(--color-kale);
    color: white;
}

.card-header {
    padding: 20px 20px 10px;
}

.card-id {
    display: inline-block;
    font-size: 0.65rem;
    font-weight: 700;
    color: var(--color-accent);
    background: #FDF0E6;
    padding: 3px 10px;
    border-radius: 100px;
    margin-bottom: 8px;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.card-title {
    font-family: var(--font-serif);
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--color-text);
    line-height: 1.3;
    padding-right: 32px;
}

.card-body {
    padding: 0 20px 20px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.card-action-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}

.card-qr-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 6px;
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    flex-shrink: 0;
    transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.card-qr-box:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-sm);
}

.card-qr-box img {
    width: 62px;
    height: 62px;
    display: block;
    mix-blend-mode: multiply;
}

.card-qr-box .qr-label {
    font-size: 0.55rem;
    font-weight: 700;
    color: var(--color-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.card-coords {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.78rem;
    color: var(--color-text-muted);
}

.card-detail-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: var(--font-sans);
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--color-surface);
    background: linear-gradient(135deg, var(--color-accent), var(--color-accent-hover));
    padding: 10px 18px;
    border-radius: 100px;
    text-decoration: none;
    transition: transform var(--transition-fast), box-shadow var(--transition-fast), opacity var(--transition-fast);
    box-shadow: 0 2px 8px rgba(139, 69, 19, 0.3);
}

.card-detail-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(139, 69, 19, 0.4);
}

.card-detail-btn:active {
    transform: translateY(0);
}

/* --- Legend --- */
.map-legend {
    position: fixed;
    bottom: calc(var(--footer-height) + 24px);
    left: 24px;
    background: var(--color-surface-glass);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--color-border-light);
    border-radius: var(--radius-md);
    padding: 12px 16px;
    display: flex;
    gap: 16px;
    z-index: 50;
    box-shadow: var(--shadow-md);
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--color-text-secondary);
}

.legend-marker {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    border: 2px solid var(--color-surface);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.15);
}

.legend-kale {
    background: var(--color-kale);
}

.legend-kilise {
    background: var(--color-kilise);
}

.legend-diger {
    background: var(--color-diger);
}

/* --- Responsive --- */
@media (max-width: 900px) {
    .nav-links {
        display: none;
    }

    .nav-links.open {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        position: absolute;
        top: 100%;
        right: 24px;
        left: auto;
        width: max-content;
        min-width: 180px;
        max-width: calc(100vw - 48px);
        background: linear-gradient(135deg, rgba(31, 74, 94, 0.98) 0%, rgba(139, 69, 19, 0.98) 100%);
        backdrop-filter: blur(20px);
        padding: 8px;
        gap: 4px;
        margin-top: 8px;
        border: 1px solid rgba(255, 255, 255, 0.15);
        border-radius: var(--radius-md);
        box-shadow: var(--shadow-lg);
    }

    .nav-links.open a {
        padding: 12px 15px;
    }

    .nav-links.open a:hover,
    .nav-links.open a:active {
        background-clip: content-box;
    }

    .nav-hamburger {
        display: flex;
    }
}

@media (max-width: 1024px) {
    :root {
        --detail-panel-width: 0px;
    }

    /* Panel artık yan sütun değil, aşağıdan açılan bir bilgi katmanı.
       Kapalıyken ekran dışında beklediği için harita görünümü değişmez. */
    .detail-panel {
        display: flex;
        position: fixed;
        left: 0;
        right: 0;
        bottom: 0;
        width: auto;
        height: auto;
        max-height: 70vh;
        border-left: none;
        border-top: 1px solid var(--color-border);
        border-radius: var(--radius-lg) var(--radius-lg) 0 0;
        box-shadow: var(--shadow-xl);
        transform: translateY(101%);
        transition: transform var(--transition-slow);
        z-index: 160;
    }

    .detail-panel.open {
        transform: translateY(0);
    }

    .detail-panel-inner {
        position: relative;
        padding: 26px 20px calc(20px + var(--footer-height));
        justify-content: flex-start;
        max-height: 70vh;
    }

    .detail-panel-close {
        display: flex;
        align-items: center;
        justify-content: center;
        position: absolute;
        top: 14px;
        right: 14px;
        width: 34px;
        height: 34px;
        border: none;
        border-radius: 50%;
        background: var(--color-border-light);
        color: var(--color-text-secondary);
        cursor: pointer;
        -webkit-tap-highlight-color: transparent;
    }

    /* Lejant ile zoom kontrollerinin arasında, harita çerçevesini kapatmayacak
       şekilde ortalanır; ikisiyle de arasında boşluk kalır. */
    /* Lejant ile zoom/sıfırla kontrollerinin arasında, aynı hizada durur. */
    .lafoa-info-btn {
        display: flex;
        align-items: center;
        gap: 7px;
        position: fixed;
        bottom: calc(var(--footer-height) + 16px);
        right: calc(16px + 44px + 24px);
        padding: 9px 15px;
        border: 1px solid var(--color-border);
        border-radius: 100px;
        background: var(--color-surface-glass);
        backdrop-filter: blur(16px);
        -webkit-backdrop-filter: blur(16px);
        color: var(--color-accent);
        font-family: var(--font-sans);
        font-size: 0.76rem;
        font-weight: 600;
        letter-spacing: 0.01em;
        white-space: nowrap;
        box-shadow: var(--shadow-md);
        cursor: pointer;
        z-index: 55;
        -webkit-tap-highlight-color: transparent;
        transition: background var(--transition-fast), transform var(--transition-fast);
    }

    .lafoa-info-btn:active {
        transform: scale(0.96);
        background: #FDF0E6;
    }

    .lafoa-info-btn svg {
        flex-shrink: 0;
        opacity: 0.95;
    }

    /* Harita zoom kontrolleriyle ve açılan kartlarla çakışmasın */
    .map-controls {
        bottom: calc(var(--footer-height) + 64px);
    }

    body:has(.info-card.active) .lafoa-info-btn,
    body:has(.detail-panel.open) .lafoa-info-btn {
        display: none;
    }

    body:has(.detail-panel.open) .map-legend,
    body:has(.detail-panel.open) .map-controls {
        display: none;
    }
}

@media (max-width: 768px) {
    .header-content {
        padding: 0 16px;
        height: 70px;
    }

    .nav-links.open {
        right: 16px;
    }

    .logo-text h1 {
        font-size: 0.75rem;
        max-width: 180px;
    }

    .settlement-count {
        display: none;
    }

    #searchInput {
        width: 160px;
    }

    #searchInput:focus {
        width: 200px;
    }

    .main-content {
        top: 70px;
    }

    .map-legend {
        bottom: calc(var(--footer-height) + 16px);
        left: 16px;
        gap: 12px;
        padding: 8px 12px;
    }

    body:has(.info-card.active) .map-legend {
        display: none;
    }

    .legend-item {
        font-size: 0.7rem;
    }

    .map-controls {
        bottom: 16px;
        right: 16px;
    }

    .search-results {
        left: 16px;
        right: 16px;
        width: auto;
    }
}

@media (max-width: 480px) {
    .logo-icon {
        display: none;
    }

    .logo-area {
        padding-left: 0;
    }

    #searchInput {
        width: 130px;
    }

    .map-legend {
        flex-direction: column;
        gap: 6px;
    }
}

/* Çok dar ekranlarda lejanta değmemesi için buton yalnızca ikona iner */
@media (max-width: 374px) {
    .lafoa-info-btn span {
        display: none;
    }

    .lafoa-info-btn {
        gap: 0;
        padding: 10px;
    }
}

/* --- Scrollbar --- */
.search-results::-webkit-scrollbar {
    width: 6px;
}

.search-results::-webkit-scrollbar-track {
    background: transparent;
}

.search-results::-webkit-scrollbar-thumb {
    background: var(--color-border);
    border-radius: 3px;
}

/* --- Loading animation (removed staggered delays — they cause jank) --- */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.5);
    }

    to {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
}

.marker {
    animation: fadeInUp 0.3s ease both;
}

