/* ==========================================================================
   CSS DEĞİŞKENLERİ (Sistemi Tek Yerden Yönetmek İçin)
   ========================================================================== */
:root {
    --primary-color: #e67e22; /* Turuncu vurgu */
    --secondary-color: #2c3e50; /* Koyu lacivert */
    --success-color: #27ae60; /* Yeşil butonlar */
    --bg-color: #f4f7f6;
    --text-dark: #333333;
    --text-light: #7f8c8d;
    --white: #ffffff;
    --border-radius-md: 12px;
    --border-radius-lg: 20px;
    --transition-fast: 0.3s ease;
}

/* ==========================================================================
   GENEL AYARLAR & RESET
   ========================================================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box; /* Padding ve border hesaplamasını güvenli hale getirir */
}

body {
    background-color: var(--bg-color);
    color: var(--text-dark);
    font-family: 'Montserrat', sans-serif;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased; /* Yazıların daha keskin görünmesini sağlar */
}

/* Yardımcı (Utility) Sınıflar */
.text-center { text-align: center; }
.w-100 { width: 100%; }

/* ==========================================================================
   ÜST NAVİGASYON (TOP NAV)
   ========================================================================== */
.top-nav {
    position: absolute;
    top: 20px;
    left: 30px;
    z-index: 100;
}

.auth-links {
    display: flex;
    align-items: center;
    gap: 15px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px); /* Safari desteği */
    padding: 10px 20px;
    border-radius: 50px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.nav-link {
    color: var(--white);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 600;
    transition: var(--transition-fast);
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-link:hover {
    color: var(--primary-color);
}

.nav-divider {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.8rem;
}

/* ==========================================================================
   HERO / SLIDER ALANI
   ========================================================================== */
.hero-container {
    /* Görselin üzerine okunaklılık için koyu gradient bindirmesi */
    background: linear-gradient(rgba(44, 62, 80, 0.85), rgba(44, 62, 80, 0.85)), 
                url('https://images.unsplash.com/photo-1541339907198-e08756ebafe3?q=80&w=2070&auto=format&fit=crop') center/cover no-repeat;
    min-height: 85vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--white);
    padding: 80px 20px 40px; 
}

.hero-content {
    max-width: 1000px;
    width: 100%;
}

.badge-news {
    background: var(--primary-color);
    padding: 8px 20px;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 600;
    display: inline-block;
    margin-bottom: 25px;
    box-shadow: 0 4px 15px rgba(230, 126, 34, 0.4);
}

.main-title {
    /* clamp() fonksiyonu ekran küçüldükçe fontu dinamik olarak ufaltır */
    font-size: clamp(2rem, 5vw, 3.5rem); 
    font-weight: 700;
    margin-bottom: 15px;
    line-height: 1.2;
}

.subtitle {
    font-size: clamp(1rem, 2vw, 1.2rem);
    color: rgba(255,255,255,0.9);
    margin-bottom: 40px;
}

/* ==========================================================================
   HIZLI ERİŞİM BUTONLARI (FLEXBOX)
   ========================================================================== */
.quick-access {
    display: flex;
    flex-wrap: wrap; /* Sığmazsa alta inmesini sağlar */
    justify-content: center;
    align-items: stretch;
    gap: 15px;
    width: 100%;
    margin: 0 auto;
}

.btn-card {
    flex: 1 1 160px; /* Büyüme:1, Küçülme:1, Minimum Genişlik:160px */
    max-width: 200px;
    height: 110px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--border-radius-md);
    color: var(--white);
    text-decoration: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    transition: var(--transition-fast);
    padding: 10px;
}

.btn-card:hover {
    background: var(--white);
    color: var(--secondary-color);
    transform: translateY(-5px); /* Yukarı kalkma efekti */
    box-shadow: 0 10px 20px rgba(0,0,0,0.2);
}

.btn-card i {
    font-size: 1.8rem;
    margin-bottom: 10px;
}

.btn-card span {
    font-size: 0.9rem;
    font-weight: 600;
    line-height: 1.2;
}

/* ==========================================================================
   AKADEMİK BÖLÜMLER (CSS GRID)
   ========================================================================== */
.academic-sections {
    padding: 80px 20px;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
}

.section-header {
    text-align: center;
    margin-bottom: 50px;
}

.section-title {
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    color: var(--secondary-color);
    margin-bottom: 10px;
}

.section-subtitle {
    color: var(--text-light);
    font-size: 1.1rem;
}

.dept-grid {
    display: grid;
    /* Grid yapısı: Sığdığı kadar kolon oluşturur, en az 320px genişlikte olur */
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
}

.dept-card {
    background: var(--white);
    border-radius: var(--border-radius-md);
    padding: 35px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.04);
    transition: var(--transition-fast);
    display: flex;
    flex-direction: column;
}

.dept-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.08);
}

.dept-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
    color: var(--success-color);
}

.dept-header i { 
    font-size: 2.2rem; 
}

.dept-header h3 {
    color: var(--secondary-color);
    font-size: 1.3rem;
}

.dept-body p {
    color: var(--text-light);
    margin-bottom: 20px;
}

.dept-links {
    list-style: none;
    margin-bottom: 25px;
    flex-grow: 1; /* Alt kısmın daima butona yaslanmasını sağlar */
}

.dept-links li { margin-bottom: 12px; }

.dept-links a {
    text-decoration: none;
    color: #555;
    font-size: 0.95rem;
    transition: var(--transition-fast);
    display: flex;
    align-items: center;
    gap: 8px;
}

.dept-links a:hover {
    color: var(--primary-color);
    padding-left: 5px; /* Hover'da hafif sağa kayma efekti */
}

.btn-details {
    display: block;
    text-align: center;
    background: var(--success-color);
    color: var(--white);
    padding: 14px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition-fast);
}

.btn-details:hover {
    background: #219653;
}

/* ==========================================================================
   MODAL SİSTEMİ (PURE CSS TARGET MİMARİSİ)
   JS kullanmadan a etiketinin href'i id ile eşleştiğinde modalı açar.
   ========================================================================== */
.modal-css {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0,0,0,0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease-in-out;
}

/* Animasyonlu Görünürlük */
.modal-css:target {
    opacity: 1;
    visibility: visible;
}

.modal-content-css {
    background: var(--white);
    padding: 40px;
    border-radius: var(--border-radius-lg);
    width: 90%;
    max-width: 500px;
    position: relative;
    color: var(--text-dark);
    transform: scale(0.8);
    transition: all 0.3s ease-in-out;
    max-height: 90vh;
    overflow-y: auto; /* İçerik taşarsa scroll çıkarır */
}

.modal-css:target .modal-content-css {
    transform: scale(1);
}

.close-btn-css {
    position: absolute;
    top: 15px; 
    right: 25px;
    font-size: 2.5rem;
    text-decoration: none;
    color: #bdc3c7;
    line-height: 1;
    transition: var(--transition-fast);
}

.close-btn-css:hover {
    color: #e74c3c;
}

.modal-header {
    text-align: center;
    margin-bottom: 25px;
    border-bottom: 1px solid #eee;
    padding-bottom: 15px;
}

.modal-header i {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 10px;
}

/* Modal İçerik Özelleştirmeleri */
.food-item, .contact-info-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px dashed #eee;
}

.contact-info-item { justify-content: flex-start; gap: 15px; }
.contact-info-item i { color: var(--secondary-color); font-size: 1.2rem; }

.food-cal {
    background: #f1f2f6;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 600;
}

.food-footer { margin-top: 20px; text-align: right; font-size: 1.1rem; }

/* ==========================================================================
   FORM ELEMANLARI (GİRİŞ / KAYIT)
   ========================================================================== */
.auth-form {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.input-group {
    position: relative;
    display: flex;
    align-items: center;
}

.input-group i {
    position: absolute;
    left: 15px;
    color: var(--text-light);
    font-size: 1.1rem;
}

.input-group input {
    width: 100%;
    padding: 14px 14px 14px 45px;
    border: 2px solid #ecf0f1;
    border-radius: 8px;
    font-family: inherit;
    font-size: 0.95rem;
    transition: var(--transition-fast);
    background: #fafafa;
}

.input-group input:focus {
    border-color: var(--primary-color);
    background: var(--white);
    outline: none;
    box-shadow: 0 0 0 4px rgba(230, 126, 34, 0.1);
}

.btn-auth {
    background: var(--secondary-color);
    color: var(--white);
    padding: 14px;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition-fast);
    display: inline-block;
    text-decoration: none;
    text-align: center;
}

.btn-auth:hover {
    background: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(230, 126, 34, 0.3);
}

/* ==========================================================================
   MOBİL UYUMLULUK (MEDIA QUERIES)
   Mobile-First felsefesinde tasarladığımız blokları ufak ekranlarda eziyoruz.
   ========================================================================== */
@media (max-width: 768px) {
    .top-nav {
        left: 50%;
        transform: translateX(-50%); /* Ortalamak için */
        top: 15px;
        width: 90%;
        max-width: 350px;
    }
    
    .auth-links {
        justify-content: center;
    }

    .hero-container {
        padding-top: 100px; /* Mobilde menü butonlarla çakışmasın diye */
    }

    .btn-card {
        flex: 1 1 45%; /* Tablette/Mobilde 2'li yan yana sığması için */
    }

    .modal-content-css {
        padding: 30px 20px;
    }
}

@media (max-width: 480px) {
    .btn-card {
        flex: 1 1 100%; /* Ekran çok küçülünce butonlar alt alta listelensin */
    }
    
    .main-title {
        font-size: 1.8rem;
    }
}
