/* Modern CSS - Çıkma Enjektör */

:root {
    /* Yeni Renk Paleti: Koyu Gri, Parlak Turuncu ve Güven Veren Orta Mavi */
    --primary: #FF8800; /* Canlı Turuncu (Vurgu, Butonlar, Etkileşim) */
    --primary-dark: #CC6600; /* Koyu Turuncu (Hover Durumu) */
    --secondary: #0077B6; /* Güven veren Orta Mavi (Fiyatlar, Önemli Bilgiler) */
    --danger: #ef4444;
    --warning: #f59e0b;
    --dark: #1C1C1C; /* Koyu Siyah (Metin, Footer) */
    --light: #F8F8F8; /* Çok Açık Gri (Arkaplan) */
    --white: #ffffff;
    --shadow: 0 4px 10px rgba(0, 0, 0, 0.08); /* Daha Yumuşak Gölgeler */
    --shadow-lg: 0 15px 30px rgba(0, 0, 0, 0.1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    line-height: 1.6;
    color: var(--dark);
    background: var(--light);
}

.container {
    max-width: 1000px; /* Maksimum genişlik sabit kaldı */
    margin: 0 auto;    /* Sayfayı yatayda ortalar */
    padding: 20px 20px;   /* Sol ve sağ kenarlardan 20px boşluk bırakır */
}

/* Header Görsel İyileştirme: Mekanik ve Güçlü Tema */
header {
    background: #2D3748; /* Koyu, Güven Veren Gri-Mavi Tonu */
    color: var(--white);
    padding: 4rem 0; /* Daha yüksek padding */
    text-align: center;
    position: relative;
    overflow: hidden;
}

/* Header Arkaplan Efekti (Hafif Dokulu Görünüm) */
header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    /* Hafif metalik, çapraz çizgili desen */
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 0 10 L 10 0" stroke="rgba(255,255,255,0.05)" stroke-width="1"/></pattern></defs><rect width="100%" height="100%" fill="url(%23grid)"/></svg>');
    opacity: 1; 
}

header h1 {
    font-size: 3.5rem; /* Daha büyük başlık */
    margin-bottom: 0.75rem;
    position: relative;
    z-index: 1;
    font-weight: 900; /* Ekstra Kalın */
    text-shadow: 0 4px 6px rgba(0,0,0,0.4); 
}

header p {
    font-size: 1.3rem;
    position: relative;
    z-index: 1;
    opacity: 0.95;
    font-weight: 500;
}

/* Navigation Modern */
nav {
    background: var(--white);
    padding: 0;
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 100;
}

nav .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

nav a {
    color: var(--dark);
    text-decoration: none;
    padding: 1rem 1.5rem;
    display: inline-block;
    transition: all 0.3s;
    font-weight: 500;
    position: relative;
}

nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 3px;
    background: var(--primary); /* Turuncu çizgi */
    transition: width 0.3s;
}

nav a:hover::after {
    width: 100%;
}

nav a:hover {
    color: var(--primary);
}

/* Search Box Modern */
.search-box {
    background: var(--white);
    padding: 2rem;
    margin: 2rem 0;
    border-radius: 15px;
    box-shadow: var(--shadow-lg);
}

.search-box form {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.search-box input,
.search-box select {
    flex: 1;
    min-width: 200px;
    padding: 14px 18px;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    font-size: 16px;
    transition: all 0.3s;
}

.search-box input:focus,
.search-box select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(255, 136, 0, 0.15); /* Turuncu odak gölgesi */
}

.search-box button {
    padding: 14px 32px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    transition: all 0.3s;
}

.search-box button:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/* Stats Bar */
.stats-bar {
    background: var(--white);
    padding: 1.5rem;
    margin: 2rem 0;
    border-radius: 10px;
    box-shadow: var(--shadow);
    display: flex;
    justify-content: space-around;
    flex-wrap: wrap;
    gap: 1rem;
}

.stat-item {
    text-align: center;
}

.stat-item .number {
    font-size: 2rem;
    font-weight: bold;
    color: var(--primary); /* Turuncu istatistikler */
}

.stat-item .label {
    color: #6b7280;
    font-size: 0.9rem;
}

/* İlanlar Grid Modern */
.ilanlar-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2rem;
    margin: 2rem 0;
}

.ilan-card {
    background: var(--white);
    border-radius: 15px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: all 0.3s;
    position: relative;
}

.ilan-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.ilan-card .image-container {
    position: relative;
    height: 240px;
    overflow: hidden;
}

.ilan-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.ilan-card:hover img {
    transform: scale(1.1);
}

.ilan-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: var(--primary); /* Turuncu rozet */
    color: white;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

.views-badge {
    position: absolute;
    bottom: 10px;
    left: 10px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    display: flex;
    align-items: center;
    gap: 5px;
}

.no-image {
    width: 100%;
    height: 240px;
    background: linear-gradient(135deg, #e5e7eb 0%, #d1d5db 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #9ca3af;
    font-size: 14px;
}

.ilan-content {
    padding: 1.5rem;
}

.ilan-content h3 {
    color: var(--dark);
    margin-bottom: 0.5rem;
    font-size: 1.25rem;
    font-weight: 700;
}

.kategori {
    color: var(--white); /* Yazı rengi beyaz */
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    display: inline-block;
    background: var(--primary); /* Arkaplan Turuncu */
    padding: 4px 10px;
    border-radius: 5px;
}

.aciklama {
    color: #6b7280;
    font-size: 0.9rem;
    margin-bottom: 1rem;
    line-height: 1.5;
}

.ilan-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1rem;
    border-top: 1px solid #e5e7eb;
}

.fiyat {
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--secondary); /* Yeni Mavi Renk */
}

.btn {
    display: inline-block;
    padding: 10px 24px;
    background: var(--primary); /* Turuncu */
    color: white;
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.3s;
    border: none;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.95rem;
}

.btn:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.btn-success {
    background: var(--secondary); /* Başarı rengi de Mavi olabilir */
}

.btn-success:hover {
    background: #006AA1;
}

.btn-danger {
    background: var(--danger);
}

.btn-danger:hover {
    background: #dc2626;
}

.btn-warning {
    background: var(--warning);
}

.btn-warning:hover {
    background: #d97706;
}

.btn-secondary {
    background: #6b7280;
}

.btn-secondary:hover {
    background: #4b5563;
}

/* İlan Detay Modern */
.ilan-detay {
    background: var(--white);
    padding: 0;
    margin: 2rem 0;
    border-radius: 15px;
    box-shadow: var(--shadow-lg);
    overflow: hidden;
}

.detay-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
}

.detay-sol {
    position: relative;
}

/* Image Slider */
.image-slider {
    position: relative;
    height: 500px;
    overflow: hidden;
}

.slider-container {
    display: flex;
    transition: transform 0.5s ease;
    height: 100%;
}

.slide {
    min-width: 100%;
    height: 100%;
}

.slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.slider-nav {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 10;
}

.slider-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s;
}

.slider-dot.active {
    background: white;
    width: 30px;
    border-radius: 6px;
}

.slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 20px;
    transition: all 0.3s;
    z-index: 10;
}

.slider-btn:hover {
    background: rgba(0, 0, 0, 0.8);
}

.slider-btn.prev {
    left: 20px;
}

.slider-btn.next {
    right: 20px;
}

.detay-sag {
    padding: 2.5rem;
}

.detay-sag h2 {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: var(--dark);
}

.fiyat-buyuk {
    font-size: 3rem; /* Daha büyük */
    font-weight: 800;
    color: var(--secondary); /* Mavi */
    margin: 1.5rem 0;
}

.action-buttons {
    display: flex;
    gap: 1rem;
    margin: 2rem 0;
    flex-wrap: wrap;
}

.btn-call,
.btn-whatsapp {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 24px;
    text-decoration: none;
    border-radius: 10px;
    font-weight: 600;
    transition: all 0.3s;
}

.btn-call {
    background: var(--primary); /* Turuncu */
    color: white;
}

.btn-call:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
}

.btn-whatsapp {
    background: #25d366;
    color: white;
}

.btn-whatsapp:hover {
    background: #20ba5a;
    transform: translateY(-2px);
}

.ozellikler,
.aciklama-detay {
    margin: 2rem 0;
}

.ozellikler h3,
.aciklama-detay h3 {
    margin-bottom: 1rem;
    color: var(--primary); /* Turuncu başlıklar */
    font-size: 1.3rem;
}

.ozellikler ul {
    list-style: none;
}

.ozellikler li {
    padding: 12px 0;
    border-bottom: 1px solid #e5e7eb;
    display: flex;
    justify-content: space-between;
}

.ozellikler li strong {
    color: var(--dark);
}

.sosyal-paylasim {
    margin: 2rem 0;
    padding: 1.5rem;
    background: #f9fafb;
    border-radius: 10px;
}

.sosyal-paylasim h3 {
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.paylasim-butonlari {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.paylasim-btn {
    padding: 10px 20px;
    border-radius: 8px;
    text-decoration: none;
    color: white;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.3s;
}

.paylasim-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.btn-facebook {
    background: #1877f2;
}

.btn-twitter {
    background: #1da1f2;
}

.btn-linkedin {
    background: #0077b5;
}

.view-count {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 1rem;
    background: #f3f4f6;
    border-radius: 8px;
    margin: 1rem 0;
}

.view-count-number {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--primary);
}

/* Admin Styles */
.admin-header {
    background: var(--dark);
    color: white;
    padding: 1rem 0;
    box-shadow: var(--shadow);
}

.admin-nav {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.admin-nav a {
    color: white;
    padding: 0.75rem 1.25rem;
    border-radius: 8px;
    transition: all 0.3s;
}

.admin-nav a:hover,
.admin-nav a.active {
    background: rgba(255, 255, 255, 0.1);
}

.admin-table {
    width: 100%;
    background: var(--white);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: var(--shadow);
}

.admin-table th,
.admin-table td {
    padding: 1rem;
    text-align: left;
}

.admin-table thead {
    background: var(--primary);
    color: white;
}

.admin-table tbody tr {
    border-bottom: 1px solid #e5e7eb;
}

.admin-table tbody tr:hover {
    background: #f9fafb;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin: 2rem 0;
}

.stat-box {
    background: var(--white);
    padding: 2rem;
    border-radius: 15px;
    box-shadow: var(--shadow);
    text-align: center;
    transition: all 0.3s;
}

.stat-box:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.stat-box h3 {
    font-size: 3rem;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

/* Footer */
footer {
    background: var(--dark);
    color: white;
    text-align: center;
    padding: 2rem 0;
    margin-top: 4rem;
}

/* Responsive */
@media (max-width: 768px) {
    header h1 {
        font-size: 2.5rem; /* Küçültülmüş başlık */
    }
    
    .ilanlar-grid {
        grid-template-columns: 1fr;
    }
    
    .detay-grid {
        grid-template-columns: 1fr;
    }
    
    .image-slider {
        height: 300px;
    }
    
    nav .container {
        flex-direction: column;
    }
    
    .action-buttons {
        flex-direction: column;
    }
    
    .btn-call,
    .btn-whatsapp {
        width: 100%;
    }
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.ilan-card {
    animation: fadeIn 0.5s ease-out;
}

/* Loading Spinner */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}