/* =========================================
   1. GENEL KAPLAYICI (WRAPPER)
   ========================================= */
.acf-extended-filter-wrapper {
    background-color: #ffffff;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    padding: 30px;
    margin-bottom: 40px;
    border: 1px solid #f0f0f0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

/* =========================================
   2. ÜST BAR (ARAMA VE SIRALAMA)
   ========================================= */
.acf-extended-top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

/* Arama Kutusu */
.acf-extended-search-box {
    position: relative;
    flex: 2; /* Arama kutusu daha geniş olsun */
}

.acf-extended-main-search {
    width: 100%;
    padding: 14px 45px 14px 20px;
    border: 1px solid #e1e1e1;
    border-radius: 50px; /* Yuvarlak hatlar */
    background-color: #f9f9f9;
    font-size: 15px;
    transition: all 0.3s ease;
    outline: none;
}

.acf-extended-main-search:focus {
    background-color: #fff;
    border-color: #6c5ce7;
    box-shadow: 0 0 0 4px rgba(108, 92, 231, 0.1);
}

.search-icon {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 18px;
    color: #aaa;
    pointer-events: none;
}

/* Sıralama Kutusu */
.acf-extended-sort-box {
    flex: 1;
    min-width: 200px;
}

.acf-extended-sort-select {
    width: 100%;
    padding: 14px 20px;
    border: 1px solid #e1e1e1;
    border-radius: 8px;
    background-color: #fff;
    cursor: pointer;
    font-size: 14px;
    color: #444;
    appearance: none; /* Varsayılan oku gizle */
    background-image: url("data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%23333%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E");
    background-repeat: no-repeat;
    background-position: right 15px top 50%;
    background-size: 12px auto;
}

/* =========================================
   3. FİLTRE FORMU GRID YAPISI
   ========================================= */
.form-fields-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 30px;
}

.acf-extended-field-group {
    display: flex;
    flex-direction: column;
}

/* Etiketler */
.group-label {
    font-size: 14px;
    font-weight: 600;
    color: #2d3436;
    margin-bottom: 12px;
    display: block;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Select ve Text Inputlar */
.acf-extended-select,
.acf-extended-text {
    width: 100%;
    height: 48px;
    padding: 0 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    background-color: #fff;
    color: #444;
    transition: border-color 0.3s;
}

.acf-extended-select:focus,
.acf-extended-text:focus {
    border-color: #6c5ce7;
    outline: none;
}

/* =========================================
   4. CHECKBOX GRUBU
   ========================================= */
.acf-extended-checkbox-group {
    max-height: 200px;
    overflow-y: auto;
    padding-right: 5px;
}

/* Scrollbar özelleştirme */
.acf-extended-checkbox-group::-webkit-scrollbar {
    width: 6px;
}
.acf-extended-checkbox-group::-webkit-scrollbar-thumb {
    background-color: #ccc;
    border-radius: 3px;
}

.acf-extended-checkbox-label {
    display: flex;
    align-items: center;
    margin-bottom: 8px;
    cursor: pointer;
    font-size: 14px;
    color: #555;
    transition: color 0.2s;
}

.acf-extended-checkbox-label:hover {
    color: #6c5ce7;
}

.acf-extended-checkbox-label input {
    margin-right: 10px;
    width: 18px;
    height: 18px;
    accent-color: #6c5ce7; /* Modern tarayıcılar için renk */
    cursor: pointer;
}

/* =========================================
   5. RANGE SLIDER (noUiSlider Özelleştirme)
   ========================================= */
.acf-slider-container {
    padding: 10px 5px 0 5px;
}

/* Slider Çubuğu */
.acf-range-slider {
    height: 6px;
    border: none;
    background: #e0e0e0;
    box-shadow: none;
    margin-bottom: 20px;
}

/* Dolu Kısım Rengi */
.noUi-connect {
    background: #6c5ce7;
}

/* Tutamaklar (Handles) */
.noUi-horizontal .noUi-handle {
    width: 20px;
    height: 20px;
    right: -10px;
    top: -8px;
    border: 2px solid #fff;
    border-radius: 50%;
    background: #6c5ce7;
    box-shadow: 0 2px 6px rgba(0,0,0,0.3);
    cursor: pointer;
}

/* Tutamak çizgilerini gizle */
.noUi-handle:before, 
.noUi-handle:after {
    display: none;
}

/* Tooltip (Sayı baloncuğu) */
.noUi-tooltip {
    font-size: 11px;
    padding: 3px 6px;
    background: #333;
    color: #fff;
    border: none;
    border-radius: 4px;
}

/* Slider Inputları (Alt kısımdaki manuel giriş) */
.acf-slider-inputs {
    display: flex;
    align-items: center;
    gap: 10px;
}

.slider-input-min,
.slider-input-max {
    width: 100%;
    padding: 8px;
    font-size: 13px;
    border: 1px solid #ddd;
    border-radius: 6px;
    text-align: center;
    color: #666;
}

.separator {
    color: #999;
    font-weight: bold;
}

/* =========================================
   6. BUTONLAR
   ========================================= */
.acf-extended-submit-container {
    margin-top: 35px;
    padding-top: 20px;
    border-top: 1px solid #f0f0f0;
    display: flex;
    justify-content: flex-end;
    gap: 15px;
}

.acf-extended-submit-btn,
.acf-extended-reset-btn {
    padding: 12px 35px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
}

/* Filtrele Butonu */
.acf-extended-submit-btn {
    background: #6c5ce7;
    color: #ffffff;
    box-shadow: 0 4px 15px rgba(108, 92, 231, 0.3);
}

.acf-extended-submit-btn:hover {
    background: #5b4bc4;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(108, 92, 231, 0.4);
}

/* Temizle Butonu */
.acf-extended-reset-btn {
    background: #f1f2f6;
    color: #636e72;
}

.acf-extended-reset-btn:hover {
    background: #dfe6e9;
    color: #2d3436;
}

/* =========================================
   7. SONUÇ KARTLARI (GRID)
   ========================================= */
.acf-extended-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 30px;
}

.acf-extended-card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid #eaeaea;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.acf-extended-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
}

/* Thumbnail */
.acf-extended-thumbnail {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.acf-extended-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.acf-extended-card:hover .acf-extended-thumbnail img {
    transform: scale(1.05);
}

/* Fiyat Badge */
.acf-extended-price {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(33, 37, 41, 0.9);
    color: #fff;
    padding: 8px 15px;
    border-radius: 30px;
    font-size: 14px;
    font-weight: 700;
    backdrop-filter: blur(5px);
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

/* Kart İçeriği */
.acf-extended-card-content {
    padding: 25px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.acf-extended-title {
    margin: 0 0 15px 0;
    font-size: 18px;
    line-height: 1.4;
    font-weight: 700;
}

.acf-extended-title a {
    color: #2d3436;
    text-decoration: none;
    transition: color 0.2s;
}

.acf-extended-title a:hover {
    color: #6c5ce7;
}

.acf-extended-excerpt {
    font-size: 14px;
    color: #636e72;
    line-height: 1.6;
    margin-bottom: 20px;
    flex-grow: 1; /* Butonu alta itmek için */
}

/* İncele Butonu */
.acf-extended-read-more {
    display: inline-block;
    color: #6c5ce7;
    font-weight: 600;
    text-decoration: none;
    font-size: 14px;
    position: relative;
    padding-left: 20px;
    transition: all 0.3s;
}

.acf-extended-read-more:before {
    content: '→';
    position: absolute;
    left: 0;
    transition: left 0.3s;
    opacity: 0;
}

.acf-extended-read-more:hover {
    padding-left: 25px;
    color: #5b4bc4;
}

.acf-extended-read-more:hover:before {
    left: 5px;
    opacity: 1;
}

/* =========================================
   8. SAYFALAMA (PAGINATION)
   ========================================= */
.acf-extended-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 50px;
    gap: 8px;
}

.acf-extended-pagination-button {
    min-width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #e1e1e1;
    background: #fff;
    color: #444;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.2s;
}

.acf-extended-pagination-button:hover {
    border-color: #6c5ce7;
    color: #6c5ce7;
}

.acf-extended-pagination-button.active {
    background: #6c5ce7;
    color: #fff;
    border-color: #6c5ce7;
}

.acf-extended-pagination-dots {
    color: #999;
}

/* Daha Fazla Göster Butonu */
.acf-extended-load-more-container {
    text-align: center;
    margin-top: 40px;
}

.acf-extended-load-more {
    background: #2d3436;
    color: #fff;
    border: none;
    padding: 15px 40px;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s;
}

.acf-extended-load-more:hover {
    transform: scale(1.05);
}

/* =========================================
   9. DİĞER DURUMLAR (Loading, No Results)
   ========================================= */
   
/* Yükleniyor Opaklığı */
.loading {
    opacity: 0.6;
    pointer-events: none;
    transition: opacity 0.3s;
}

.acf-extended-no-results {
    grid-column: 1 / -1; /* Tüm satırı kapla */
    text-align: center;
    padding: 60px 20px;
    background: #f9f9f9;
    border-radius: 12px;
    border: 1px dashed #ccc;
}

.acf-extended-no-results-icon {
    font-size: 48px;
    margin-bottom: 20px;
    display: block;
}

.acf-extended-loading-initial {
    text-align: center;
    padding: 40px;
    font-size: 16px;
    color: #666;
}

/* =========================================
   10. RESPONSIVE (MOBİL UYUMLULUK)
   ========================================= */

/* Tablet ve Altı */
@media (max-width: 992px) {
    .acf-extended-top-bar {
        flex-direction: column;
        align-items: stretch;
    }
    
    .acf-extended-search-box, 
    .acf-extended-sort-box {
        width: 100%;
        flex: auto;
    }
    
    .acf-extended-sort-select {
        width: 100%;
    }
}

/* Mobil */
@media (max-width: 600px) {
    .acf-extended-filter-wrapper {
        padding: 20px;
    }

    .form-fields-container {
        grid-template-columns: 1fr; /* Mobilde tek sütun */
    }

    .acf-extended-submit-container {
        flex-direction: column;
    }

    .acf-extended-submit-btn,
    .acf-extended-reset-btn {
        width: 100%;
    }
}

/* DİKEY LAYOUT (Sidebar Kullanımı İçin) */
.acf-layout-vertical .acf-extended-filter-wrapper {
    padding: 20px;
}

.acf-layout-vertical .acf-extended-top-bar {
    flex-direction: column;
}

.acf-layout-vertical .form-fields-container {
    grid-template-columns: 1fr; /* Her zaman tek sütun */
}

.acf-layout-vertical .acf-extended-submit-container {
    flex-direction: column;
}