:root {
            --yesilay-yesili: #00913f;
            --acik-gri: #f4f4f4;
            --koyu-gri: #333;
        }

        body {
            font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
            line-height: 1.6;
            margin: 0;
            color: var(--koyu-gri);
            background-color: #fff;
        }

        /* Navigasyon */
        nav {
            background: #fff;
            padding: 1rem 5%;
            display: flex;
            justify-content: space-between;
            align-items: center;
            box-shadow: 0 2px 10px rgba(0,0,0,0.1);
            position: sticky;
            top: 0;
            z-index: 1000;
        }

        .logo {
            font-weight: bold;
            font-size: 1.5rem;
            color: var(--yesilay-yesili);
        }

        .nav-links {
            list-style: none;
            display: flex;
        }

        .nav-links li {
            margin-left: 20px;
        }

        .nav-links a {
            text-decoration: none;
            color: var(--koyu-gri);
            font-weight: 500;
            transition: color 0.3s;
        }

        .nav-links a:hover {
            color: var(--yesilay-yesili);
        }

        /* Hero (Giriş) Kısmı */
        .hero {
            background: linear-gradient(rgba(0,145,63,0.8), rgba(0,145,63,0.8)), url('/images/header.jpeg') ;
            background-size: cover;
            background-position: center;
            color: white;
            padding: 100px 5%;
            text-align: center;
        }

        .hero h1 {
            font-size: 3rem;
            margin-bottom: 10px;
        }

        /* Bölümler */
        section {
            padding: 60px 5%;
        }

        .section-title {
            text-align: center;
            color: var(--yesilay-yesili);
            margin-bottom: 40px;
            font-size: 2rem;
        }

        /* Tarihçe Kartı */
        .history-card {
            background: var(--acik-gri);
            padding: 30px;
            border-radius: 15px;
            border-left: 10px solid var(--yesilay-yesili);
        }

        /* Etkinlikler ve Posterler (Grid) */
        .grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
            gap: 20px;
        }

        .card {
            border: 1px solid #ddd;
            border-radius: 10px;
            overflow:hidden;
            transition: transform 0.3s;
        }

        .card:hover {
            transform: translateY(-5px);
        }

        /* Bu kısmı kopyalayıp eskisinin üzerine yapıştır */
        .card img {
            width: 100%;            /* Kartın genişliğini tamamen kaplasın */
            height: auto;           /* Yüksekliği orantılı olarak ayarlasın */
            object-fit: contain;    /* Resmin tüm içeriğini ezmeden gösterir */
            max-height: 550px;      /* Çok uzun olmamaları için bir sınır */
            background: #fff;       /* Resim dikey formatta olduğu için yanlarda boşluk kalırsa beyaz görünsün */
        }

        .card-content {
            padding: 20px;
            text-align: center;
        }
        .grid2 {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
            gap: 20px;
        }

        .card2 {
            border: 1px solid #ddd;
            border-radius: 10px;
            overflow:hidden;
            transition: transform 0.3s;
        }

        .card2:hover {
            transform: translateY(-5px);
        }

        .card2 img {
            width: 100%;            /* Kartın genişliğini tamamen kaplasın */
            height: 500px;           /* Yüksekliği orantılı olarak ayarlasın */
            object-fit: fill;    /* Resmin tüm içeriğini ezmeden gösterir */
            max-height: 550px;      /* Çok uzun olmamaları için bir sınır */
            background: #fff;       /* Resim dikey formatta olduğu için yanlarda boşluk kalırsa beyaz görünsün */
        }

        .card2-content {
            padding: 20px;
            text-align: center;
        }


        /* Linkler Bölümü */
        .links-container {
            display: flex;
            flex-wrap: wrap;
            gap: 15px;
            justify-content: center;
        }

        .btn {
            padding: 12px 25px;
            border-radius: 25px;
            text-decoration: none;
            font-weight: bold;
            transition: opacity 0.3s;
        }

        .btn-yesilay { background-color: var(--yesilay-yesili); color: white; }
        .btn-meb { background-color: #0056b3; color: white; }

        footer {
            background: var(--koyu-gri);
            color: white;
            text-align: center;
            padding: 20px;
            margin-top: 40px;
        }
        .view-all-container {
            text-align: center;
            margin-top: 30px;
        }

        .btn-outline {
            display: inline-block;
            padding: 10px 25px;
            border: 2px solid var(--yesilay-yesili);
            color: var(--yesilay-yesili);
            text-decoration: none;
            border-radius: 25px;
            font-weight: bold;
            transition: all 0.3s ease;
        }

        .btn-outline:hover {
            background-color: var(--yesilay-yesili);
            color: white;
        }
        /* Modal Arka Planı */
        .modal-overlay {
            display: none; /* İlk başta gizli */
            position: fixed;
            z-index: 9999; /* Her şeyin üstünde görünsün */
            left: 0;
            top: 0;
            width: 100%;
            height: 100%;
            background-color: rgba(0, 0, 0, 0.9); /* Arkayı karart */
            justify-content: center;
            align-items: center;
        }

        /* Modal İçerik Kutusu */
        .modal-content {
            position: relative;
            max-width: 80%;
            max-height: 90%;
        }

        /* Büyük Fotoğraf */
        .modal-img {
            width: auto;           /* Genişliği otomatiğe al */
            max-width: 100%;       /* Ekrandan taşmasın */
            height: auto;          /* Orantıyı bozma */
            max-height: 80vh;      /* Ekran yüksekliğinin %80'ini geçmesin */
            display: block;
            margin: 0 auto;
            border-radius: 10px;
        }

        /* Kapatma Butonu (X) */
        .close-btn {
            position: absolute;
            top: -40px;
            right: -30px;
            color: #fff;
            font-size: 40px;
            font-weight: bold;
            cursor: pointer;
            transition: 0.3s;
        }

        .close-btn:hover {
            color: var(--yesilay-yesili);
        }
        /* --- Mobil Uyumluluk (Responsive) Ayarları --- */

/* Tablet ve Telefonlar için (1024px ve altı) */
@media (max-width: 1024px) {
    .hero h1 {
        font-size: 2.5rem; /* Başlığı biraz küçültüyoruz */
    }
    
    .grid, .grid2 {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
        gap: 15px;
    }
}

/* Sadece Telefonlar için (768px ve altı) */
@media (max-width: 768px) {
    nav {
        flex-direction: column; /* Logo ve Menüyü alt alta getir */
        padding: 1rem;
        gap: 10px;
        flex-wrap: wrap; /* Linkler sığmazsa aşağı kayar, ekranı itmez */
        justify-content: center; /* Mobilde her şeyi ortalar */
    }

    .nav-links {
        padding: 0;
        margin: 10px 0 0 0;
        width: 100%;
        justify-content: center;
        flex-wrap: wrap; /* Menü sığmazsa aşağı kayar */
        flex-wrap: wrap; 
        justify-content: center;
        padding: 0;
    }

    .nav-links li {
        margin: 5px 10px;
        margin: 5px 10px;
    }

    .hero {
        padding: 80px 5%; /* Yanlardaki %5 boşluk yazının ekrana yapışmasını önler */
        overflow: hidden;
    }

    .hero h1 {
        /* clamp(minimum, ideal, maksimum) yazı boyutu */
        font-size: clamp(1.5rem, 8vw, 3rem); 
        line-height: 1.2;
        margin-bottom: 15px;
        word-wrap: break-word; /* Çok uzun kelime olursa alt satıra kır */
    }

    .hero p {
        font-size: clamp(0.9rem, 4vw, 1.2rem);
        max-width: 90%; /* Yazının ekrana tam yapışmaması için */
        margin: 0 auto; /* Ortala */
    }

    .section-title {
        font-size: 1.5rem;
        margin-bottom: 25px;
    }

    .modal-content {
        max-width: 95%; /* Modal mobilde ekranı daha çok kaplasın */
    }

    .close-btn {
        top: -45px;
        right: 0px;
        font-size: 35px;
    }

    /* Kart yüksekliklerini mobilde otomatik yapalım ki içerik taşmasın */
    .card2 img {
        height: 350px; 
    }
}

/* Çok Küçük Ekranlar için (480px ve altı) */
@media (max-width: 480px) {
    .nav-links {
        font-size: 0.9rem;
    }

    .btn {
        width: 100%; /* Link butonlarını mobilde tam genişlik yap */
        text-align: center;
        box-sizing: border-box;
    }

    .links-container {
        flex-direction: column;
    }
}