/* ======================================= */
/* ornekler.css - Katalog ve Pagination Stilleri */
/* ======================================= */

/* Başlık alanı */
.catalog-header {
    padding: 0 0 15px 0; 
    border-bottom: 3px solid #ff6b35; 
    margin-bottom: 25px;
}

.catalog-header p {
    font-size: 1.1rem;
    color: #444;
    margin-bottom: 5px;
}

/* Kartvizit Grid Düzeni */
.card-grid {
    display: grid;
    /* İstenen 2 sütunlu düzen */
    grid-template-columns: 1fr 1fr; 
    gap: 15px; 
    padding: 0; 
}

/* Tek Bir Kartvizit Öğesi Stili */
.card-item {
    background: white;
    border: 3px solid #b32d2e; 
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s;
    cursor: pointer;
}

.card-item:hover {
    transform: translateY(-2px); 
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* RESİM TEMEL STİLİ (Tüm resimler için) */
.card-item img {
    width: 100%;
    display: block;
    object-fit: cover;
    cursor: zoom-in; 
}

/* YATAY KARTVİZİT KURALI (varsayılan: 95x60mm) */
.card-item img {
    aspect-ratio: 9.5 / 6; 
}

/* DİKEY KARTVİZİT KURALI (60x95mm) */
.card-item.vertical img {
    aspect-ratio: 6 / 9.5; 
}


/* KOD ve WP Butonunun Bulunduğu Alt Alan */
.card-footer {
    display: flex;
    flex-direction: column;
    padding: 8px;
    gap: 8px;
    background: #f7f7f7;
}

.code-area {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 5px;
    border: 1px solid #b32d2e; 
    border-radius: 3px;
}

.product-code {
    font-size: 0.9rem;
    color: #333;
    font-weight: 700;
    padding-left: 5px;
}

.copy-btn {
    background-color: #ff6b35; 
    color: white;
    border: none;
    padding: 5px 8px;
    border-radius: 3px;
    font-size: 0.8rem;
    cursor: pointer;
}

/* WhatsApp Butonu */
.wp-btn {
    display: block;
    text-align: center;
    background: #25d366; 
    color: white;
    text-decoration: none;
    padding: 8px 0;
    border-radius: 3px;
    font-weight: 600;
    font-size: 1rem;
    transition: background 0.2s;
    border: 1px solid #25d366; 
}

.wp-btn:hover {
    background: #1eaf53;
}

/* ======================================= */
/* SAYFALANDIRMA (PAGINATION) Stilleri */
/* ======================================= */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 30px 0;
    padding: 10px;
    background: #f0f0f0;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.page-link {
    text-decoration: none;
    color: #1e3a5f;
    padding: 8px 15px;
    margin: 0 4px;
    border-radius: 5px;
    font-weight: 500;
    transition: background-color 0.3s, color 0.3s;
}

.page-link:hover:not(.active):not(.disabled) {
    background-color: #ddd;
}

.page-link.active {
    background-color: #ff6b35;
    color: white;
    font-weight: 700;
}

.page-link.disabled {
    color: #aaa;
    pointer-events: none; 
    cursor: default;
}

/* ======================================= */
/* MODAL (Lightbox) Stilleri ve Responsive Kurallar */
/* ======================================= */
.modal {
    display: none; 
    position: fixed; 
    z-index: 9999; 
    padding-top: 60px; 
    left: 0;
    top: 0;
    width: 100%; 
    height: 100%; 
    /* KAYDIRMAYI KALDIRDIK */
    overflow-y: hidden; 
    overflow-x: hidden; 
    background-color: rgba(0,0,0,0.9); 
}

.close {
    position: absolute;
    top: 15px;
    right: 35px;
    color: #f1f1f1;
    font-size: 40px;
    font-weight: bold;
    transition: 0.3s;
    cursor: pointer;
}

/* Modal İçerik Kapsayıcısı (Boyutlandırma ve Taşıma Engeli Burada) */
.modal-content-wrapper {
    position: relative;
    margin: auto;
    
    /* GENİŞLİK KONTROLÜ */
    width: auto;      
    max-width: 900px;
    padding: 10px;    
    
    /* YÜKSEKLİK KONTROLÜ (Taşmayı Engeller) */
    max-height: 85vh; 
    /* İÇERİKTEKİ KAYDIRMAYI KALDIRDIK */
    overflow-y: hidden;  
}

/* Modal içeriği (img etiketi) */
.modal-content {
    margin: auto;
    display: block;
    width: 100%;       /* Kapsayıcısının tamamını kaplasın */
    height: auto;      /* Yüksekliğini otomatik ayarlasın */
    max-width: 100%;   /* Kapsayıcısından taşmasın */
    animation-name: zoom;
    animation-duration: 0.6s;
}

/* YENİ: MODAL FİLİGRAN STİLİ */
#watermark {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-30deg); /* Ortala ve çapraz çevir */
    
    color: transparent; /* Metin içi şeffaf olsun */
    font-size: 2.0vw; 
    font-weight: 900;
    
    /* Kontur etkisi için text-shadow kullanıyoruz (silik ve konturlu) */
    text-shadow: 
        1px 1px 0 rgba(255, 255, 255, 0.1),  /* Hafif beyaz kontur */
        -1px -1px 0 rgba(255, 255, 255, 0.1),
        1px -1px 0 rgba(255, 255, 255, 0.1),
        -1px 1px 0 rgba(255, 255, 255, 0.1);
        
    pointer-events: none; 
    z-index: 99999; 
    white-space: nowrap; 
    display: none; 
}

/* Modal 'active' olduğunda filigranı göster */
.modal.active #watermark {
    display: block;
}

/* RESPONSIVE KURALLAR */
@media (max-width: 650px) {
    .card-grid {
        grid-template-columns: 1fr; 
    }
    .modal-content-wrapper {
        width: 90%; 
        max-width: none; 
        max-height: 90vh; 
    }
}