/* TEMEL AYARLAR */
body {
    margin: 0;
    padding: 0;
    font-family: 'Lora', serif;
    background: #f7eed8 url('cini-desen.png') repeat fixed;
    color: #2c2c2c;
}

header {
    background: #800000 url('cini-desen.png') repeat;
    background-blend-mode: overlay;
    color: #d4af37;
    text-align: center;
    padding: 2.5rem 0;
    border-bottom: 5px solid #d4af37;
    font-family: 'Cinzel', serif;
}

/* --- KONTROL PANELİ VE YAN YANA HİZALAMA --- */
.kontrol-paneli {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    max-width: 800px;
    margin: 20px auto 0 auto;
    width: 90%;
}

.arama-alani {
    position: relative;
    flex: 2; /* Arama çubuğu biraz daha geniş dursun */
}

.filtre-alani {
    flex: 1; /* Filtre kutusu daha kibar dursun */
}

#arama-girdisi, #donem-filtresi {
    width: 100%;
    padding: 12px 20px 12px 45px;
    font-family: 'Lora', serif;
    font-size: 1.05rem;
    border: 2px solid #d4af37;
    border-radius: 30px;
    background-color: rgba(255, 250, 240, 0.85);
    color: #2c2c2c;
    outline: none;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
    box-sizing: border-box;
}

#donem-filtresi {
    padding: 12px 20px; /* Seçim kutusunda büyüteç olmadığı için sol boşluğu normalleştirdik */
    cursor: pointer;
    appearance: none; /* Standart ok işaretini kaldırıp daha temiz gösterir */
    background-image: url("data:image/svg+xml;utf8,<svg fill='%23800000' height='24' viewBox='0 0 24 24' width='24' xmlns='http://www.w3.org/2000/svg'><path d='M7 10l5 5 5-5z'/><path d='M0 0h24v24H0z' fill='none'/></svg>");
    background-repeat: no-repeat;
    background-position: right 15px center;
}

#arama-girdisi:focus, #donem-filtresi:focus {
    background-color: #ffffff;
    box-shadow: 0 4px 25px rgba(214, 175, 55, 0.5);
    transform: translateY(-2px);
}

.arama-büyüteç {
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.1rem;
    color: #800000;
    pointer-events: none;
    z-index: 10;
}

/* ANA SAYFA KARTLARI */
.grid-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    padding: 50px;
    max-width: 1300px;
    margin: auto;
}

.kart {
    background: #fff;
    border: 3px solid #d4af37;
    border-radius: 10px;
    padding: 15px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
    opacity: 0;
    animation: yukariSüzül 0.6s ease-out forwards;
}

@keyframes yukariSüzül {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

.kart:hover {
    box-shadow: 0 15px 35px rgba(128, 0, 0, 0.25);
}

.kart-gorseli {
    width: 100%;
    height: 350px;
    object-fit: contain;
    background-color: #fbfbfb;
    border-radius: 5px;
    border: 2px solid #d4af37;
}

/* TAM SAYFA MODAL */
.modal-tam-sayfa {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: #fffaf0;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
}

.gizli { display: none !important; }

.geri-don-btn {
    position: absolute;
    top: 20px; left: 30px;
    background: #800000;
    color: #d4af37;
    padding: 10px 25px;
    border-radius: 30px;
    cursor: pointer;
    font-family: 'Cinzel', serif;
    font-weight: bold;
    z-index: 2100;
    transition: 0.3s;
}

.geri-don-btn:hover { background: #d4af37; color: #800000; }

.tam-sayfa-icerik { display: flex; min-height: 100vh; }

.sol-bolum {
    flex: 1;
    background: #1a1a1a;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px;
    border-right: 5px solid #d4af37;
}

.ana-resim-cerceve {
    width: 100%;
    text-align: center;
}

.ana-resim-cerceve img {
    max-width: 100%;
    max-height: 70vh;
    height: auto;
    object-fit: contain;
    border: 5px solid #d4af37;
    box-shadow: 0 0 50px rgba(0,0,0,0.8);
}

.sag-bolum {
    flex: 1.2;
    padding: 60px;
    background-image: linear-gradient(rgba(255,250,240,0.9), rgba(255,250,240,0.9)), url('cini-desen.png');
}

.sag-bolum h2 { font-family: 'Cinzel', serif; font-size: 3rem; color: #800000; margin-bottom: 0; }
.sag-bolum h4 { font-size: 1.5rem; color: #d4af37; margin-top: 10px; border-bottom: 2px solid #d4af37; padding-bottom: 15px; }

.scroll-alanı h3 {
    font-family: 'Cinzel', serif;
    color: #800000;
    background: rgba(128, 0, 0, 0.05);
    padding: 10px;
    border-left: 5px solid #800000;
    margin-top: 40px;
}

.scroll-alanı p {
    font-size: 1.2rem;
    line-height: 2;
    text-align: justify;
}

/* =======================================================
   MOBİL UYUMLULUK: ANA SAYFA VE DETAY MODALI DÜZENLEMESİ
   ======================================================= */
@media (max-width: 768px) {
    
    /* 1. ANA SAYFA: ARAMA VE KATEGORİ ALANINI ALT ALTA YAPAR */
    .kontrol-paneli {
        display: flex !important;
        flex-direction: column !important; /* Elemanları alt alta dizer */
        gap: 15px !important; /* Aralarına temiz bir boşluk bırakır */
        width: 90% !important;
        margin: 20px auto !important;
    }
    
    .arama-alani, .filtre-alani {
        width: 100% !important; /* İki kutu da ekranı tam kaplar */
        flex: none !important;
    }

    #arama-girdisi, #donem-filtresi {
        font-size: 1rem !important;
        padding: 14px 20px !important; /* Parmakla rahat basılması için kutuları genişletir */
        box-sizing: border-box !important;
    }

    #arama-girdisi {
        padding-left: 45px !important; /* Büyüteç ikonu için sol boşluk */
    }

    /* 2. DETAY MODALI: FOTOĞRAF ÜSTTE - YAZILAR ALTTA */
    .tam-sayfa-icerik {
        display: flex !important;
        flex-direction: column !important;
        min-height: auto !important;
    }

    .sol-bolum {
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        justify-content: center !important;
        width: 100% !important;
        flex: none !important;
        padding: 80px 20px 30px 20px !important;
        border-right: none !important;
        border-bottom: 5px solid #d4af37 !important;
        box-sizing: border-box !important;
    }

    .ana-resim-cerceve {
        width: 100% !important;
        max-width: 300px !important;
        text-align: center !important;
    }

    .ana-resim-cerceve img {
        width: 100% !important;
        max-height: 45vh !important;
        height: auto !important;
        object-fit: contain !important;
        display: block !important;
        margin: 0 auto !important;
    }

    .sag-bolum {
        width: 100% !important;
        flex: none !important;
        padding: 30px 20px !important;
        box-sizing: border-box !important;
    }

    .sag-bolum h2, .sag-bolum h4 {
        text-align: center !important;
    }
    
    .sag-bolum h2 {
        font-size: 2.2rem !important;
    }
}