/* OGM Web CBS Platform - Main Styles */

/* ============================= */
/* Base Styles & Reset           */
/* ============================= */
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    overflow: hidden;
    margin: 0;
    padding: 0;
}

* {
    box-sizing: border-box;
}

/* ============================= */
/* Map Container - MapLibre GL JS */
/* ============================= */
#map {
    height: 100vh;
    width: 100%;
    cursor: crosshair;
}

.maplibregl-map {
    height: 100vh;
    width: 100%;
}

.logo{
    height: 70px;
}

/* MapLibre GL JS Popup Styles */
.maplibregl-popup-content {
    padding: 12px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    z-index: 1001 !important; /* Popup'lar her zaman en üstte */
}

/* Pin marker popup'ları için ekstra z-index */
.maplibregl-popup {
    z-index: 2000 !important; /* Marker'ların üstünde görünsün */
}

/* Compact style for measurement popups */
.maplibregl-popup.meas-popup .maplibregl-popup-content {
    padding: 6px 32px 6px 10px; /* sağdaki kapatma alanı için daha geniş boşluk */
    border-radius: 8px;
    font-weight: 700;
    font-size: 13px;
    white-space: nowrap; /* tek satır görünüm */
}

.maplibregl-popup.meas-popup .maplibregl-popup-close-button {
    font-size: 14px;
    line-height: 1;
    padding: 0;
    right: 0; /* kapsayıcının sağına yapıştır */
    top: 0;  /* kapsayıcının üstüne yapıştır */
    width: 28px; /* sağdaki koyu şerit genişliği */
    height: 100%; /* popup yüksekliğini kapla */
    display: flex;
    align-items: center;
    justify-content: center;
    background: #111827; /* koyu arka plan */
    color: #ffffff; /* X beyaz */
    border-radius: 0 8px 8px 0; /* sağ kenar oval */
    opacity: 1;
    border: 0;
    box-sizing: border-box;
}

.maplibregl-popup.meas-popup .maplibregl-popup-close-button:hover {
    background: #1f2937;
}

/* Ölçüm popup metin rengi (sonuç ve geçici için aynı) */
.maplibregl-popup.meas-popup .maplibregl-popup-content strong {
    color: #1f2937;
    font-weight: 700;
}

/* Mesafe ölçüm marker'ları için özel z-index */
.maplibregl-marker {
    z-index: 1000 !important; /* Marker'lar her zaman üstte */
}

/* Minimal Distance Measurement Popup */
#distance-result-popup,
#area-result-popup {
    padding: 0;
    margin: 0;
    background: transparent;
    border: none;
    box-shadow: none;
    font-size: 12px;
    line-height: 1.2;
}

#distance-result-popup p,
#area-result-popup p {
    margin: 0;
    padding: 0;
}

#distance-result-popup strong,
#area-result-popup strong {
    color: #1f2937;
    font-weight: 700;
}

.maplibregl-popup-close-button {
    font-size: 18px;
    padding: 0 8px;
}

.maplibregl-popup-anchor-top .maplibregl-popup-tip,
.maplibregl-popup-anchor-bottom .maplibregl-popup-tip,
.maplibregl-popup-anchor-left .maplibregl-popup-tip,
.maplibregl-popup-anchor-right .maplibregl-popup-tip {
    border-width: 8px;
}

/* ============================= */
/* Custom Scrollbar              */
/* ============================= */
.sidebar-content::-webkit-scrollbar {
    width: 8px;
}

.sidebar-content::-webkit-scrollbar-track {
    background: #f8fafc;
    border-radius: 10px;
}

.sidebar-content::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #cbd5e1, #94a3b8);
    border-radius: 10px;
    border: 2px solid #f8fafc;
}

.sidebar-content::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #94a3b8, #64748b);
}

/* ============================= */
/* Sidebar Styles                */
/* ============================= */
.sidebar-content {
    padding: 0;
}

#sidebar.tips-hidden .edu-hint {
    display: none;
}

.sidebar-footer {
    flex-shrink: 0;
    flex-grow: 0;
}

/* ============================= */
/* Gradient Effects              */
/* ============================= */
.gradient-hover {
    transition: all 0.2s ease;
}

.gradient-hover:hover {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(147, 197, 253, 0.1));
    transform: translateY(-1px);
}

/* ============================= */
/* CBS Tool Buttons              */
/* ============================= */
.cbs-tool-button {
    display: none !important;
}

.cbs-tool-button.active {
    display: flex !important;
}

/* ============================= */
/* Map Measurement Markers       */
/* ============================= */
.measure-marker {
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.distance-label,
.area-label,
.buffer-label {
    white-space: nowrap;
    font-weight: bold;
}

/* ============================= */
/* Custom Map Markers - MapLibre */
/* ============================= */
.custom-marker {
    cursor: pointer;
    width: 20px;
    height: 20px;
    border-radius: 3px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 9px;
    border: 1px solid white;
    box-shadow: 0 2px 4px rgba(0,0,0,0.15);
    transition: transform 0.2s ease;
}

.custom-marker:hover {
    transform: scale(1.1);
}

/* MapLibre Marker specific */
.maplibregl-marker {
    cursor: pointer;
}

/* ============================= */
/* Analysis Layers               */
/* ============================= */
.analysis-layer {
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.analysis-layer:hover {
    opacity: 1;
}

/* ============================= */
/* Educational Feedback Toast    */
/* ============================= */
.educational-feedback {
    position: fixed;
    top: 1rem;
    left: 50%;
    transform: translateX(-50%);
    background: #10b981;
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 0.5rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    z-index: 3000;
    pointer-events: none;
    transition: all 0.3s ease;
    animation: slideInDown 0.3s ease;
}

@keyframes slideInDown {
    from {
        transform: translateX(-50%) translateY(-100%);
        opacity: 0;
    }
    to {
        transform: translateX(-50%) translateY(0);
        opacity: 1;
    }
}

/* ============================= */
/* Panel Cards                   */
/* ============================= */
.panel-card {
    background: white;
    border-radius: 0.75rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    transition: all 0.2s ease;
}

.panel-card:hover {
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.panel-card-header {
    padding: 0.75rem 1rem;
    font-weight: bold;
    color: white;
}

/* ============================= */
/* Form Controls                 */
/* ============================= */
.form-input,
.form-select {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    transition: all 0.2s ease;
}

.form-input:focus,
.form-select:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

/* ============================= */
/* Buttons                       */
/* ============================= */
.btn {
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    font-weight: 600;
    transition: all 0.2s ease;
    cursor: pointer;
    border: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn:hover {
    transform: scale(1.05);
}

.btn-primary {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: white;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
}

.btn-success {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
}

.btn-danger {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
}

/* ============================= */
/* Tool Panel States             */
/* ============================= */
.tool-selected {
    background-color: rgba(59, 130, 246, 0.1);
    border-left: 4px solid #3b82f6;
}

/* ============================= */
/* Mobile Responsive             */
/* ============================= */
@media (max-width: 768px) {
    #sidebar {
        width: 100%;
        max-width: 100%;
    }

    .sidebar-content {
        /* Mobilde footer için alan bırak */
        max-height: calc(100vh - 140px);
        padding-bottom: 0.5rem;
    }

    .sidebar-footer {
        /* Mobilde footer her zaman görünsün */
        position: sticky;
        bottom: 0;
        z-index: 10;
        background: white;
        border-top: 1px solid #e4e4e7;
    }

    .cbs-tool-button {
        font-size: 0.75rem;
    }

    #tools-panel {
        width: calc(100% - 2rem);
        right: 1rem;
    }

    /* Geocoder mobil düzenlemeleri */
    #search-container {
        /* JavaScript positionControls() tarafından ayarlanacak */
        width: auto !important;
    }

    #geocoder-toggle-btn {
        /* Sol üstte hamburger menünün yanında */
    }

    #geocoder-input-container {
        width: calc(100vw - 80px) !important;
        max-width: 345px !important;
        left: 0 !important;
        transform: none !important;
    }

    @keyframes expandFromLeft {
        from {
            opacity: 0;
            transform: translateY(-10px) scale(0.95);
        }
        to {
            opacity: 1;
            transform: translateY(0) scale(1);
        }
    }

    @keyframes collapseToLeft {
        from {
            opacity: 1;
            transform: translateY(0) scale(1);
        }
        to {
            opacity: 0;
            transform: translateY(-10px) scale(0.95);
        }
    }

    #geocoder-results-dropdown {
        max-height: 300px;
    }

    .geocoder-result-item {
        padding: 10px 12px;
    }

    .geocoder-result-name {
        font-size: 13px;
    }

    .geocoder-result-address {
        font-size: 12px;
    }
}

/* ============================= */
/* Loading Indicator             */
/* ============================= */
.loading-spinner {
    border: 3px solid #f3f3f3;
    border-top: 3px solid #3b82f6;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ============================= */
/* Z-Index Management            */
/* ============================= */
.z-map { z-index: 1; }
.z-controls { z-index: 1000; }
.z-panels { z-index: 1300; }
.z-mobile-buttons { z-index: 1400; }
.z-modal { z-index: 2000; }
.z-toast { z-index: 3000; }

/* ============================= */
/* Geocoder Search Marker        */
/* ============================= */
.search-marker {
    cursor: pointer;
    transition: transform 0.2s ease;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

.search-marker:hover {
    transform: scale(1.1);
}

/* Geocoder Marker Popup - Minimal stil */
.geocoder-marker-popup .maplibregl-popup-content {
    background: transparent !important;
    box-shadow: none !important;
    padding: 0 !important;
    border: none !important;
    border-radius: 0 !important;
}

.geocoder-marker-popup .maplibregl-popup-tip {
    display: none !important;
}

/* ============================= */
/* Geocoder Toggle Animation     */
/* ============================= */
#geocoder-input-container {
    animation: expandFromLeft 0.25s ease-out;
    transform-origin: left top;
}

@keyframes expandFromLeft {
    from {
        opacity: 0;
        transform: translateY(-10px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

#geocoder-input-container.closing {
    animation: collapseToLeft 0.2s ease-in;
}

@keyframes collapseToLeft {
    from {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
    to {
        opacity: 0;
        transform: translateY(-10px) scale(0.95);
    }
}

/* ============================= */
/* Geocoder Results Dropdown     */
/* ============================= */
#geocoder-results-dropdown {
    max-height: 400px;
    overflow-y: auto;
}

#geocoder-results-dropdown::-webkit-scrollbar {
    width: 8px;
}

#geocoder-results-dropdown::-webkit-scrollbar-track {
    background: #f9fafb;
    border-radius: 4px;
}

#geocoder-results-dropdown::-webkit-scrollbar-thumb {
    background: #d1d5db;
    border-radius: 4px;
}

#geocoder-results-dropdown::-webkit-scrollbar-thumb:hover {
    background: #9ca3af;
}

/* Geocoder Result Item */
.geocoder-result-item {
    display: flex;
    align-items: flex-start;
    padding: 12px 16px;
    cursor: pointer;
    transition: background-color 0.15s ease;
    border-bottom: 1px solid #f3f4f6;
}

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

.geocoder-result-item:hover {
    background-color: #f9fafb;
}

.geocoder-result-item:active {
    background-color: #f3f4f6;
}

.geocoder-result-icon {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 12px;
    font-size: 16px;
}

.geocoder-result-content {
    flex: 1;
    min-width: 0;
}

.geocoder-result-name {
    font-size: 14px;
    font-weight: 600;
    color: #111827;
    margin-bottom: 2px;
    line-height: 1.4;
}

.geocoder-result-address {
    font-size: 13px;
    color: #6b7280;
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.geocoder-no-results {
    padding: 16px;
    text-align: center;
    color: #6b7280;
    font-size: 14px;
}

/* Geocoder Loading State */
#geocoder-loading {
    animation: fadeIn 0.2s ease;
}

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

/* Premium Fonts Import */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

/* ============================= */
/* Layers Panel - Minimal Design */
/* ============================= */
.layers-panel {
    position: fixed;
    top: 52px; /* Butonların hemen altında */
    left: 57.6px; /* Arama ve katman butonu ile aynı hizada */
    width: 280px; /* 320px -> 280px (küçültüldü) */
    max-width: 20rem; /* max-w-xs */
    max-height: calc(100vh - 70px);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: #f3f4f6; /* bg-gray-100 */
    border-radius: 0.625rem; /* rounded-lg - küçültüldü */
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06); /* shadow-md - küçültüldü */
    z-index: 9998;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* Sidebar açıkken panel sağa kayar */
.layers-panel.sidebar-open {
    left: 352px; /* Katman butonu ile aynı hizada */
}

/* Mobilde sidebar tam ekran, panel gizlenir */
@media (max-width: 768px) {
    .layers-panel.sidebar-open {
        opacity: 0;
        pointer-events: none;
    }
}

/* Color Picker Input - Minimal görünüm */
.color-picker-input {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    width: 0.875rem; /* 14px - küçültüldü */
    height: 0.875rem; /* 14px - küçültüldü */
    background-color: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
}

/* Webkit tabanlı tarayıcılar için (Chrome, Safari) */
.color-picker-input::-webkit-color-swatch-wrapper {
    padding: 0;
}

.color-picker-input::-webkit-color-swatch {
    border: none;
    border-radius: 0.25rem; /* rounded - küçültüldü */
}

/* Firefox için */
.color-picker-input::-moz-color-swatch {
    border: none;
    border-radius: 0.25rem; /* rounded - küçültüldü */
}

/* Toggle Switch - Minimal Design */
.toggle-label {
    position: relative;
}

.toggle-checkbox {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-bg {
    position: relative;
    display: inline-block;
    width: 2rem; /* w-8 = 32px - küçültüldü */
    height: 1.125rem; /* h-4.5 = 18px - küçültüldü */
    background-color: #e5e7eb; /* gray-200 */
    border-radius: 9999px;
    transition: background-color 0.15s ease;
    will-change: background-color;
}

.toggle-bg::before {
    content: '';
    position: absolute;
    left: 0.125rem; /* left-0.5 = 2px */
    top: 0.125rem; /* top-0.5 = 2px */
    width: 0.875rem; /* 14px - küçültüldü */
    height: 0.875rem; /* 14px - küçültüldü */
    background-color: white;
    border-radius: 50%;
    transition: transform 0.15s ease;
    will-change: transform;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.toggle-checkbox:checked + .toggle-bg {
    background-color: #1f2937; /* gray-800 */
}

.toggle-checkbox:checked + .toggle-bg::before {
    transform: translate3d(0.875rem, 0, 0); /* GPU-accelerated */
}

.toggle-checkbox:focus + .toggle-bg {
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.3); /* blue-300 with opacity */
}

/* Opacity Slider */
.opacity-slider {
    -webkit-appearance: none;
    appearance: none;
    height: 0.375rem; /* h-1.5 - küçültüldü */
    background: #e5e7eb; /* gray-200 */
    border-radius: 0.375rem; /* rounded-md */
    outline: none;
    cursor: pointer;
}

.opacity-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 0.875rem; /* 14px - küçültüldü */
    height: 0.875rem; /* 14px - küçültüldü */
    background: #1f2937; /* gray-800 - siyah */
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
    border: none;
}

.opacity-slider::-webkit-slider-thumb:hover {
    background: #111827; /* gray-900 - daha koyu */
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.opacity-slider::-moz-range-thumb {
    width: 0.875rem; /* 14px - küçültüldü */
    height: 0.875rem; /* 14px - küçültüldü */
    background: #1f2937; /* gray-800 - siyah */
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
    border: none;
}

.opacity-slider::-moz-range-thumb:hover {
    background: #111827; /* gray-900 - daha koyu */
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

/* Opacity Slider Container - Animasyon optimizasyonu */
.opacity-slider-container {
    will-change: max-height, opacity;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}

/* Layers Panel Content Scrollbar */
#layers-panel-content {
    overflow-y: auto;
    overflow-x: hidden;
    flex: 1;
    -webkit-overflow-scrolling: touch; /* Smooth scrolling on iOS */
    contain: layout style paint; /* CSS containment for performance */
}

#layers-panel-content::-webkit-scrollbar {
    width: 6px;
}

#layers-panel-content::-webkit-scrollbar-track {
    background: transparent;
}

#layers-panel-content::-webkit-scrollbar-thumb {
    background: #d1d5db; /* gray-300 */
    border-radius: 3px;
}

#layers-panel-content::-webkit-scrollbar-thumb:hover {
    background: #9ca3af; /* gray-400 */
}

/* Search Toggle Button */
.search-toggle-btn {
    width: 36px;
    height: 36px;
    background-color: #1c1c1e;
    border: none;
    border-radius: 50%;
    box-shadow: rgba(34, 34, 34, 0.35) 0px 2px 8px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    color: #fff;
    padding: 0;
}

.search-toggle-btn:hover {
    background-color: rgba(0, 0, 0, 0.9);
}

/* Geocoder Container - Koyu tema */
.geocoder-container {
    background-color: #1c1c1e;
    border: none;
    border-radius: 18px;
    box-shadow: rgba(34, 34, 34, 0.35) 0px 2px 8px;
    overflow: hidden;
}

.geocoder-input {
    width: 100%;
    padding: 10px 16px;
    font-size: 14px;
    background-color: transparent;
    border: none;
    color: #fff;
    outline: none;
}

.geocoder-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.geocoder-search-btn {
    padding: 10px 14px;
    background-color: transparent;
    border: none;
    color: #fff;
    cursor: pointer;
}

.geocoder-search-btn:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.geocoder-close-btn {
    padding: 10px 12px;
    background-color: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
}

.geocoder-close-btn:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.geocoder-dropdown {
    background-color: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    overflow-y: auto;
}

.geocoder-results-list {
    padding: 8px 0;
}

.geocoder-result-item {
    display: flex;
    align-items: center;
    padding: 10px 14px;
    cursor: pointer;
    gap: 12px;
}

.geocoder-result-item:hover {
    background-color: #f3f4f6;
}

.geocoder-result-icon {
    flex-shrink: 0;
}

.geocoder-result-icon i {
    color: #3b82f6 !important;
}

.geocoder-result-content {
    flex: 1;
    min-width: 0;
}

.geocoder-result-name {
    font-size: 14px;
    font-weight: 500;
    color: #1f2937;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.geocoder-result-address {
    font-size: 12px;
    color: #6b7280;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.geocoder-no-results {
    padding: 16px;
    text-align: center;
    color: #6b7280;
    font-size: 14px;
}

/* Dark Round Button - Ortak stil */
.dark-round-btn {
    width: 36px;
    height: 36px;
    background-color: #1c1c1e;
    border: none;
    border-radius: 50%;
    box-shadow: rgba(34, 34, 34, 0.35) 0px 2px 8px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    color: #fff;
    padding: 0;
}

.dark-round-btn:hover {
    background-color: rgba(0, 0, 0, 0.9);
}

.dark-round-btn.active {
    background-color: #1c1c1e;
    color: #fff;
}

.dark-round-btn.active:hover {
    background-color: rgba(0, 0, 0, 0.9);
}

/* Layers Button - Arama butonunun sağında (inline) */
.layers-button-inline {
    position: absolute;
    top: 0;
    left: 46px; /* Arama butonu (36px) + gap (10px) */
    width: 36px;
    height: 36px;
    background-color: #1c1c1e;
    border: none;
    border-radius: 50%;
    box-shadow: rgba(34, 34, 34, 0.35) 0px 2px 8px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    color: #fff;
    padding: 0;
}

.layers-button-inline:hover {
    background-color: rgba(0, 0, 0, 0.9);
}

.layers-button-inline.active {
    background-color: #1c1c1e;
    color: #fff;
}

.layers-button-inline.active:hover {
    background-color: rgba(0, 0, 0, 0.9);
}

/* Arama kutusu açıkken layers butonu sağa kayar */
.layers-button-inline.search-open {
    left: 355px; /* Arama kutusu genişliği (345px) + gap (10px) */
}

/* Globe Button - Layers butonunun sağında (inline) */
.globe-button-inline {
    position: absolute;
    top: 0;
    left: 92px; /* Arama (36px) + gap (10px) + Layers (36px) + gap (10px) */
    width: 36px;
    height: 36px;
    background-color: #1c1c1e;
    border: none;
    border-radius: 50%;
    box-shadow: rgba(34, 34, 34, 0.35) 0px 2px 8px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 500;
    color: #fff;
    padding: 0;
}

.globe-button-inline .globe-btn-text {
    font-family: system-ui, -apple-system, sans-serif;
    letter-spacing: -0.5px;
}

.globe-button-inline:hover {
    background-color: rgba(0, 0, 0, 0.9);
}

.globe-button-inline.active {
    background-color: #1c1c1e;
    color: #fff;
}

.globe-button-inline.active:hover {
    background-color: rgba(0, 0, 0, 0.9);
}

/* Arama kutusu açıkken globe butonu sağa kayar */
.globe-button-inline.search-open {
    left: 401px; /* Arama kutusu (345px) + gap (10px) + Layers (36px) + gap (10px) */
}

/* Hikâye Haritası Button - Globe butonunun sağında (inline) */
.storymap-button-inline {
    position: absolute;
    top: 0;
    left: 138px; /* Arama (36px) + gap (10px) + Layers (36px) + gap (10px) + Globe (36px) + gap (10px) */
    height: 36px;
    background-color: #1c1c1e;
    border: none;
    border-radius: 18px;
    box-shadow: rgba(34, 34, 34, 0.35) 0px 2px 8px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 500;
    color: #fff;
    padding: 0 14px;
    white-space: nowrap;
}

.storymap-button-inline .storymap-btn-text {
    font-family: system-ui, -apple-system, sans-serif;
    letter-spacing: -0.3px;
}

.storymap-button-inline:hover {
    background-color: rgba(0, 0, 0, 0.9);
}

.storymap-button-inline.active {
    background-color: #1c1c1e;
    color: #fff;
}

.storymap-button-inline.active:hover {
    background-color: rgba(0, 0, 0, 0.9);
}

/* Arama kutusu açıkken storymap butonu sağa kayar */
.storymap-button-inline.search-open {
    left: 447px; /* Arama kutusu (345px) + gap (10px) + Layers (36px) + gap (10px) + Globe (36px) + gap (10px) */
}


/* ============================= */
/* Screenshot Selection Tool     */
/* ============================= */
.screenshot-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1000;
}

.screenshot-selection-box {
    position: absolute;
    border: 2px dashed #3b82f6;
    background: rgba(59, 130, 246, 0.1);
    pointer-events: none;
    box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.3);
}

.screenshot-dimensions {
    position: absolute;
    bottom: -24px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.75);
    color: white;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
    white-space: nowrap;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* Screenshot button active state */
#screenshot-selection.tool-active {
    background-color: rgba(6, 182, 212, 0.15);
    border-left: 3px solid #06b6d4;
}
