:root {
    --bg-color: #f8f9fa;
    --card-bg: #ffffff;
    --text-primary: #333333;
    --text-secondary: #666666;
    --primary-color: #146678;
    --primary-hover: #277b8c;
    --border-color: #e0e0e0;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Typography */
h1, h2, h3 {
    font-weight: 500;
    letter-spacing: -0.5px;
}

/* Header */
.main-header {
    padding: 15px 0;
    background-color: #fff;
    border-bottom: 1px solid var(--border-color);
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

.header-content {
    display: grid;
    grid-template-columns: 250px 1fr 250px; /* Logo - Arama - İkonlar */
    align-items: center;
    gap: 20px;
}

.logo-img {
    max-width: 150px; /* Masaüstü için daha da küçülttüm */
    height: auto;
    display: block;
    object-fit: contain; /* Görüntü bozulmasını engeller */
}

/* Search Bar */
.search-container {
    display: flex;
    gap: 10px;
    width: 100%;
    max-width: 500px;
    justify-self: center;
}

/* Contact Icons */
.contact-icons {
    display: flex;
    gap: 15px;
    justify-self: end; /* Sağa yaslar */
}

.contact-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    color: #fff;
    font-size: 18px;
    text-decoration: none;
    transition: transform 0.3s, opacity 0.3s;
}

.contact-btn:hover {
    transform: translateY(-3px);
    opacity: 0.9;
}

.contact-btn.whatsapp { background-color: #25D366; }
.contact-btn.phone { background-color: #007bff; }
.contact-btn.mail { background-color: #ea4335; }

@media (max-width: 900px) {
    .header-content {
        grid-template-columns: 1fr;
        justify-items: center;
        gap: 15px;
    }
    
    .contact-icons {
        justify-self: center;
    }

    .logo-img {
        max-width: 150px; /* Mobilde logo boyutunu koru */
    }
}

#search-input {
    flex-grow: 1;
    padding: 12px 20px;
    border: 2px solid #eee;
    border-right: none;
    border-radius: 50px 0 0 50px; /* Sol taraf yuvarlak */
    font-family: 'Inter', sans-serif;
    font-size: 15px;
    outline: none;
    transition: all 0.3s;
    background-color: #f8f9fa;
}

#search-input:focus {
    border-color: var(--primary-color);
    background-color: #fff;
    box-shadow: 0 0 0 4px rgba(20, 102, 120, 0.1);
}

#search-btn {
    padding: 10px 25px;
    background-color: var(--primary-color);
    color: #fff;
    border: none;
    border-radius: 0 50px 50px 0; /* Sağ taraf yuvarlak */
    cursor: pointer;
    transition: all 0.3s;
    font-size: 16px;
}

#search-btn:hover {
    background-color: var(--primary-hover);
    padding-right: 30px; /* Hover'da hafif uzama efekti */
}

/* Main Layout */
.main-layout {
    display: grid;
    grid-template-columns: 250px 1fr;
    gap: 40px;
    margin-top: 40px;
    margin-bottom: 40px;
    flex-grow: 1;
    align-items: start; /* Tüm layout için yukarı hizalama */
}

/* Sidebar Filter */
.sidebar {
    position: fixed; /* Sticky yerine Fixed: Ekrana çiviler */
    top: 150px; /* Header'ın altından başlar */
    width: 250px; /* Genişliği sabitlemek zorundayız çünkü fixed akıştan çıkar */
    height: calc(100vh - 150px); /* Ekranın geri kalanını kaplasın */
    overflow-y: auto; /* İçerik çoksa kendi içinde scroll olsun */
    z-index: 100;
}

/* Sağ içerik (Ürünler ve InfoBox) */
.right-content {
    grid-column: 2; /* 2. sütuna yerleşir */
    /* Sidebar fixed olduğu için grid boşluğunu manuel korumamız gerekebilir ama grid yapısı bunu zaten ayırıyor */
}

.filter-box h3 {
    margin-bottom: 20px;
    font-size: 18px;
    color: var(--primary-color);
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 10px;
    display: inline-block;
}

.filter-buttons.vertical {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.filter-btn {
    padding: 12px 20px;
    border: 1px solid var(--border-color);
    background-color: #fff;
    color: var(--text-secondary);
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    font-size: 15px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: left;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.filter-btn:after {
    content: '\f054'; /* FontAwesome Chevron Right */
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    font-size: 12px;
    opacity: 0;
    transform: translateX(-5px);
    transition: all 0.3s;
}

.filter-btn:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    padding-left: 25px;
}

.filter-btn.active {
    background-color: var(--primary-color);
    color: #fff;
    border-color: var(--primary-color);
}

.filter-btn.active:after {
    opacity: 1;
    transform: translateX(0);
}

/* Mobile Filter Button */
.mobile-filter-toggle {
    display: none; /* Masaüstünde gizli */
    width: 100%; /* Tam genişlik */
    background-color: #fff;
    border: 1px solid var(--primary-color);
    color: var(--primary-color);
    padding: 12px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    align-items: center;
    justify-content: center; /* Ortala */
    gap: 8px;
    margin-bottom: 20px; /* Info box ile mesafe */
    transition: all 0.3s;
}

.mobile-filter-toggle:hover {
    background-color: var(--primary-color);
    color: #fff;
}

/* Sidebar Close Button */
.close-sidebar {
    display: none;
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    font-size: 24px;
    color: #333;
    cursor: pointer;
}

/* Sidebar Overlay */
.sidebar-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 900;
    opacity: 0;
    transition: opacity 0.3s;
}

.sidebar-overlay.active {
    opacity: 1;
}

/* Info Box */
.info-box {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 30px;
}

@media (max-width: 900px) {
    .header-content {
        display: grid;
        grid-template-columns: 1fr auto;
        grid-template-rows: auto auto;
        gap: 15px;
        padding: 15px 0;
        justify-items: stretch;
        align-items: center;
        /* Container padding'i zaten var ama garanti olsun diye: */
        padding-left: 0; 
        padding-right: 0;
    }

    /* Container mobilde zaten padding'e sahip ama header özelinde hizayı eşitleyelim */
    .container {
        padding: 0 20px; /* Filtre butonu ile aynı hizada olması için */
    }

    .logo-container {
        grid-column: 1 / 2;
        grid-row: 1;
        justify-self: start; /* Sola yasla */
    }

    .contact-icons {
        grid-column: 2 / 3;
        grid-row: 1;
        justify-self: end; /* Sağa yasla */
        gap: 10px; /* İkon aralığını biraz daralt */
    }

    .search-container {
        grid-column: 1 / -1; /* Tam genişlik */
        grid-row: 2;
        max-width: 100%;
    }

    .logo-img {
        max-width: 130px; /* Mobilde daha kompakt */
    }

    .contact-btn {
        width: 36px; /* Mobilde butonlar bir tık küçülebilir */
        height: 36px;
        font-size: 16px;
    }

    .mobile-filter-toggle {
        display: flex; /* Mobilde görünür yap */
    }

    /* Sidebar Mobile Slide-in (Modal Effect) */
    .sidebar {
        position: fixed;
        top: 0;
        left: -100%; /* Tamamen ekran dışına al */
        width: 80%; /* Ekranın %80'ini kaplasın (Modal havası) */
        max-width: 300px;
        height: 100vh;
        background: #fff;
        padding: 60px 20px 20px;
        z-index: 1000;
        box-shadow: 5px 0 15px rgba(0,0,0,0.2); /* Daha belirgin gölge */
        transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1); /* Yumuşak geçiş */
        overflow-y: auto;
        visibility: hidden; /* Kapalıyken görünmez */
    }

    .sidebar.active {
        left: 0;
        visibility: visible;
    }

    .sidebar-overlay.active {
        display: block;
    }

    .close-sidebar {
        display: block;
    }

    /* Info Box Mobile 2 Columns */
    .info-box {
        grid-template-columns: repeat(2, 1fr); 
        gap: 10px;
    }

    /* Product Grid Mobile 2 Columns */
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    
    .product-header h2 {
        font-size: 14px; /* Başlıkları küçült */
    }

    .product-desc {
        display: none; /* Mobilde açıklamayı gizle, yer kazandır */
    }
}

@media (max-width: 480px) {
    /* Extra small adjustments if needed */
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr); /* Telefondada 2'li kalsın */
    }
}

.info-item {
    background-color: #fff;
    border: 1px solid rgba(20, 102, 120, 0.2);
    border-radius: 12px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 10px;
    font-size: 13px;
    color: var(--text-secondary);
    box-shadow: 0 2px 10px rgba(0,0,0,0.03);
    transition: transform 0.3s;
}

.info-item:hover {
    transform: translateY(-3px);
    border-color: var(--primary-color);
}

.info-item i {
    color: var(--primary-color);
    font-size: 24px;
    margin-bottom: 5px;
}

.info-item span {
    font-weight: 500;
    color: var(--text-primary);
}

/* No Results Message */
.no-results {
    display: none; /* Hidden by default */
    background-color: #fff5f5;
    border: 1px solid #feb2b2;
    color: #c53030;
    padding: 30px;
    border-radius: 12px;
    text-align: center;
    font-weight: 500;
    margin-top: 20px;
}

.no-results i {
    font-size: 30px;
    margin-bottom: 10px;
    display: block;
}

.no-results.visible {
    display: block;
    animation: fadeIn 0.4s ease-in-out;
}

/* Gallery Grid */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

/* Product Item */
.product-item {
    background-color: var(--card-bg);
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    transition: transform 0.3s, box-shadow 0.3s;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.product-item.hidden {
    display: none;
}

.product-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
}

/* Visual Side */
.product-visual {
    width: 100%;
    aspect-ratio: 4/3; /* Forces horizontal aspect ratio */
    background-color: #eee;
    position: relative;
    overflow: hidden;
}

/* Slider Integration */
.product-slider {
    width: 100%;
    height: 100%;
}

.slider-image {
    display: none;
    width: 100%;
    height: 100%;
    object-fit: cover; /* Ensures image fills the area without distortion */
    animation: fadeIn 0.4s ease-in-out;
}

.slider-image.active {
    display: block;
}

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

.slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.9);
    color: var(--primary-color);
    border: none;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
    z-index: 10;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    opacity: 0;
}

.product-visual:hover .slider-btn {
    opacity: 1;
}

.slider-btn:hover {
    background: var(--primary-color);
    color: #fff;
}

.slider-btn.prev { left: 10px; }
.slider-btn.next { right: 10px; }

/* Slider Dots */
.slider-dots {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 6px;
    z-index: 10;
}

.slider-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.5); /* Yarı saydam beyaz */
    cursor: pointer;
    transition: all 0.3s;
    border: 1px solid rgba(0, 0, 0, 0.1);
}

.slider-dot.active {
    background-color: #fff; /* Aktifken tam beyaz */
    transform: scale(1.2);
    box-shadow: 0 0 4px rgba(0,0,0,0.2);
}

/* Details Side */
.product-details {
    padding: 25px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.product-header {
    margin-bottom: 15px;
}

.product-header h2 {
    font-size: 20px;
    margin-bottom: 8px;
    color: var(--text-primary);
    line-height: 1.4;
}

.product-tag {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 3px 10px;
    background-color: rgba(20, 102, 120, 0.08);
    color: var(--primary-color);
    border-radius: 4px;
    font-weight: 600;
}

.product-desc {
    margin-bottom: 20px;
    color: var(--text-secondary);
    font-size: 14px;
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-specs {
    margin-bottom: 20px;
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
    padding: 15px;
    background-color: #f8f9fa;
    border-radius: 8px;
}

.spec-item {
    font-size: 13px;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 8px;
}

.spec-item i {
    color: var(--primary-color);
    width: 16px;
    text-align: center;
}

.product-price {
    font-size: 18px; /* 24px'ten 18px'e düşürdüm */
    font-weight: 600;
    color: var(--primary-color);
    margin-top: auto;
}

/* Price List for Multiple Options */
.price-list {
    margin-top: auto;
    border-top: 1px solid #eee;
    padding-top: 15px;
}

.price-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 5px 0;
    font-size: 14px;
}

.price-row.highlight {
    color: var(--primary-color);
    font-weight: 600;
    font-size: 16px;
    margin-top: 5px;
}

/* Footer */
.main-footer {
    text-align: center;
    padding: 30px 20px;
    margin-top: auto;
    background-color: #fff;
    border-top: 1px solid var(--border-color);
    color: var(--text-secondary);
    font-size: 13px;
}

/* Responsive */
@media (max-width: 1200px) {
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 900px) {
    .main-layout {
        display: block; /* Grid veya Flex yerine blok yapıp akışı serbest bıraktık */
    }

    /* Sidebar Mobile Slide-in (Modal Effect) */
    .sidebar {
        position: fixed; /* Akıştan tamamen çıkar */
        top: 0;
        left: -100%; 
        width: 80%; 
        max-width: 300px;
        height: 100vh;
        background: #fff;
        padding: 60px 20px 20px;
        z-index: 1000;
        box-shadow: 5px 0 15px rgba(0,0,0,0.2); 
        transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1); 
        overflow-y: auto;
        visibility: hidden; 
        margin: 0; /* Margin sıfırla */
    }
    
    .right-content {
        width: 100%;
    }

    .gallery-grid {
        grid-template-columns: repeat(2, 1fr); /* Keep 2 columns on tablet/large mobile if possible, or switch to 1 */
    }
    
    .header-content {
        flex-direction: column;
        gap: 15px;
    }

    .search-container {
        width: 100%;
        max-width: none;
    }
}

@media (max-width: 600px) {
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    
    .product-desc {
        display: -webkit-box; /* Tekrar görünür yap */
        -webkit-line-clamp: 2; /* 2 satırla sınırla */
        -webkit-box-orient: vertical;
        overflow: hidden;
        font-size: 11px; /* Daha küçük font */
        margin-bottom: 5px;
        line-height: 1.3;
        color: var(--text-secondary);
    }

    .product-details {
        padding: 10px; /* Daha kompakt padding */
        gap: 5px; /* Elemanlar arası boşluğu azalt */
    }

    .product-header {
        margin-bottom: 5px; /* Başlık altı boşluğu azalt */
    }

    .product-header h2 {
        font-size: 13px; /* Başlık boyutu ideal */
        line-height: 1.3;
        height: 34px; /* 2 satıra sabitle */
        overflow: hidden;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        margin-bottom: 5px;
    }

    .product-tag {
        font-size: 9px;
        padding: 2px 6px;
    }

    /* Teknik özellikleri göster */
    .product-specs {
        display: grid; /* Tekrar görünür yap */
        padding: 5px;
        gap: 3px;
        margin-bottom: 5px;
        background-color: #f8f9fa;
        border-radius: 4px;
    }

    .spec-item {
        font-size: 10px;
        gap: 4px;
    }

    .spec-item i {
        font-size: 10px;
        width: 12px;
    }

    .price-list {
        padding-top: 8px;
        margin-top: 5px;
    }

    .price-row {
        font-size: 11px;
        padding: 2px 0;
    }

    .price-row strong {
        font-size: 12px;
    }

    .price-row.highlight {
        font-size: 12px;
        margin-top: 2px;
    }
    
    .product-price {
        font-size: 14px; /* Mobilde ana fiyat boyutu */
        font-weight: 600;
        margin-top: auto;
    }
}
