/* ===== CRITICAL CSS FOR IMMEDIATE LOADING ===== */
/* Bu CSS kuralları sayfa yüklenir yüklenmez çalışır */

body { 
    opacity: 1 !important; 
    visibility: visible !important; 
    background: #ffffff !important;
    overflow-x: hidden !important; /* Prevent horizontal scroll */
    width: 100% !important; /* Ensure body doesn't exceed viewport */
    max-width: 100vw !important; /* Use viewport width */
    box-sizing: border-box !important; /* Include padding in width calculation */
}

.page-header { 
    opacity: 1 !important; 
    visibility: visible !important; 
    background: rgba(250, 243, 224, 0.95) !important; /* Krem Beyaz */
    height: 97.5px !important;
    max-height: 97.5px !important;
    min-height: 97.5px !important;
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important; /* Ensure full width */
    max-width: 100vw !important; /* Use viewport width */
    z-index: 1000 !important;
    border-bottom: 1px solid rgba(244, 197, 66, 0.3) !important; /* Altın Işık */
    backdrop-filter: blur(20px) !important; /* Arka plan bulanıklığı */
    -webkit-backdrop-filter: blur(20px) !important; /* Safari desteği */
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1), 
                opacity 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                background-color 0.3s ease !important;
    box-sizing: border-box !important; /* Include padding in width calculation */
}

.header { 
    height: 97.5px !important; 
    background: transparent !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    padding: 0 1rem !important; /* Reduced from 1.5rem */
    max-width: 1280px !important;
    margin: 0 auto !important;
    width: 100% !important; /* Ensure full width */
    box-sizing: border-box !important; /* Include padding in width calculation */
}

/* ===== CSS RESET & BASE STYLES ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box; /* Ensure all elements use border-box */
}

html {
    /* scroll-behavior: smooth; - kaldırıldı */
    width: 100%; /* Ensure html doesn't exceed viewport */
    max-width: 100vw; /* Use viewport width */
    overflow-x: hidden; /* Prevent horizontal scroll */
}

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: #2C1B18; /* Koyu Kahve */
    background-color: #FAF3E0; /* Krem Beyaz */
    overflow-x: hidden;
    opacity: 1 !important; /* Force visibility */
    visibility: visible !important; /* Force visibility */
    width: 100%; /* Ensure body doesn't exceed viewport */
    max-width: 100vw; /* Use viewport width */
    box-sizing: border-box; /* Include padding in width calculation */
}

/* Critical CSS for immediate visibility */
.header {
    opacity: 1 !important;
    visibility: visible !important;
    width: 100%; /* Ensure full width */
    max-width: 100%; /* Don't exceed viewport */
    box-sizing: border-box; /* Include padding in width calculation */
}

.logo-img {
    opacity: 1 !important;
    visibility: visible !important;
    height: 60px !important;
    width: auto !important;
    object-fit: contain !important;
}

/* ===== HEADER SCROLL BEHAVIOR ===== */
/* Header scroll davranışları kaldırıldı - sadece temel header işlevleri kaldı */

/* ===== CSS VARIABLES ===== */
:root {
    /* 🎭 Tiyatro Temalı Renk Paleti */
    --bordo-perde: #7A1E2C;      /* Ana tiyatro perdesi rengi */
    --altin-isik: #F4C542;       /* Sahne ışığı, CTA butonları */
    --kizil-sahne: #D94141;      /* Oyunculuk, tutku ve heyecan */
    --amber-turuncu: #E67E22;    /* Sıcaklık, gençlere hitap */
    --krem-beyaz: #FAF3E0;       /* Kontrast için, yazılar ve arka plan */
    --koyu-kahve: #2C1B18;       /* Derinlik ve denge */
    
    /* Eski renkler için alias'lar (geriye uyumluluk) */
    --primary-900: var(--bordo-perde);
    --primary-800: #5a1621;
    --primary-700: var(--bordo-perde);
    --primary-600: #d94141;
    --primary-500: var(--altin-isik);
    --primary-400: #f8d85c;
    --primary-300: #fbe89a;
    --primary-200: #fdf2c3;
    --primary-100: #fef9e8;
    
    /* Accent Colors - Tiyatro temasına uygun */
    --accent-red: var(--kizil-sahne);
    --accent-orange: var(--amber-turuncu);
    --accent-yellow: var(--altin-isik);
    --accent-green: #16a34a;
    --accent-blue: #2563eb;
    --accent-purple: #7c3aed;
    
    /* Neutral Colors - Tiyatro temasına uygun */
    --white: var(--krem-beyaz);
    --gray-50: #fefdfb;
    --gray-100: #fdfaf5;
    --gray-200: #fbf5eb;
    --gray-300: #f8ede0;
    --gray-400: #f5e6c3;
    --gray-500: #eed4a0;
    --gray-600: #e4c17a;
    --gray-700: #d8a94f;
    --gray-800: var(--koyu-kahve);
    --gray-900: var(--koyu-kahve);
    --black: var(--koyu-kahve);
    
    /* Text Colors - Tiyatro temasına uygun */
    --text-primary: var(--koyu-kahve);
    --text-secondary: #8a7c71;
    --text-muted: #6b5d52;
    --text-inverse: var(--krem-beyaz);
    
    /* Background Colors - Tiyatro temasına uygun */
    --bg-primary: var(--krem-beyaz);
    --bg-secondary: #f5e6c3;
    --bg-dark: var(--bordo-perde);
    --bg-gradient: linear-gradient(135deg, var(--bordo-perde) 0%, var(--kizil-sahne) 100%);
    
    /* Border Colors - Tiyatro temasına uygun */
    --border-light: #f5e6c3;
    --border-medium: #eed4a0;
    --border-dark: #d8a94f;
    
    /* Shadow Colors - Tiyatro temasına uygun */
    --shadow-sm: 0 1px 2px 0 rgba(122, 30, 44, 0.1);
    --shadow-md: 0 4px 6px -1px rgba(122, 30, 44, 0.15), 0 2px 4px -1px rgba(122, 30, 44, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(122, 30, 44, 0.2), 0 4px 6px -2px rgba(122, 30, 44, 0.15);
    --shadow-xl: 0 20px 25px -5px rgba(122, 30, 44, 0.25), 0 10px 10px -5px rgba(122, 30, 44, 0.2);
    
    /* Typography */
    --font-heading: 'Playfair Display', serif;
    --font-body: 'Inter', sans-serif;
    
    /* Spacing */
    --spacing-xs: 0.25rem;
    --spacing-sm: 0.5rem;
    --spacing-md: 1rem;
    --spacing-lg: 1.5rem;
    --spacing-xl: 2rem;
    --spacing-2xl: 3rem;
    --spacing-3xl: 4rem;
    
    /* Border Radius */
    --radius-sm: 0.25rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    --radius-2xl: 1.5rem;
    
    /* Transitions */
    --transition-fast: 0.15s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.5s ease;
    
    /* Z-Index */
    --z-dropdown: 1000;
    --z-sticky: 1020;
    --z-fixed: 1030;
    --z-modal-backdrop: 1040;
    --z-modal: 1050;
    --z-popover: 1060;
    --z-tooltip: 1070;
    
    /* Border Radius */
    --border-radius-sm: 0.25rem;
    --border-radius-md: 0.5rem;
    --border-radius-lg: 0.75rem;
    --border-radius-xl: 1rem;
    
    /* Background Colors */
    --bg-light: var(--gray-50);
    --bg-medium: var(--gray-100);
    --bg-dark: var(--bordo-perde);
    
    /* Primary Colors for compatibility */
    --primary-50: #fef2f2;
    --primary-100: #fee2e2;
    --primary-200: #fecaca;
    --primary-300: #fca5a5;
    --primary-400: #f87171;
    --primary-500: #ef4444;
    --primary-600: #dc2626;
    --primary-700: #b91c1c;
    --primary-800: #991b1b;
    --primary-900: #7f1d1d;
    
    /* Text Colors */
    --text-primary: var(--koyu-kahve);
    --text-secondary: #6b7280;
    --text-muted: #9ca3af;
    
    /* Gray Colors for compatibility */
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-400: #9ca3af;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-800: #1f2937;
    --gray-900: #111827;
    
    /* White */
    --white: #ffffff;
}

/* ===== TYPOGRAPHY ===== */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: var(--spacing-md);
    color: var(--bordo-perde); /* Bordo Perde */
}

h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 700;
}

h2 {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 600;
}

h3 {
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 600;
}

h4 {
    font-size: clamp(1.25rem, 2.5vw, 1.5rem);
    font-weight: 500;
}

p {
    margin-bottom: var(--spacing-md);
    color: var(--koyu-kahve); /* Koyu Kahve */
    font-size: 1rem;
    line-height: 1.7;
}

a {
    color: var(--bordo-perde); /* Bordo Perde */
    text-decoration: none;
    transition: color var(--transition-fast);
}

a:hover {
    color: var(--kizil-sahne); /* Kızıl Sahne */
}

/* ===== LAYOUT & CONTAINERS ===== */
.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 var(--spacing-lg);
    width: 100%; /* Ensure full width */
    box-sizing: border-box; /* Include padding in width calculation */
}

.section-header {
    text-align: center;
    margin-bottom: var(--spacing-3xl);
}

.section-title {
    color: var(--bordo-perde); /* Bordo Perde */
    margin-bottom: var(--spacing-sm);
}

.section-subtitle {
    color: var(--koyu-kahve); /* Koyu Kahve */
    font-size: 1.125rem;
    max-width: 600px;
    margin: 0 auto;
}

/* ===== LOGO STYLES ===== */
.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    transition: transform 0.3s ease;
}

.logo:hover {
    transform: scale(1.05);
}

.logo-img {
    height: 60px;
    width: auto;
    object-fit: contain;
}

/* ===== NAVIGATION STYLES ===== */
.nav-menu {
    display: flex;
    align-items: center;
    gap: var(--spacing-md); /* Reduced from var(--spacing-lg) */
}

.nav-link {
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.8rem; /* Reduced from 0.9rem */
    padding: 0.4rem 0.6rem; /* Reduced from 0.5rem 0.75rem */
    border-radius: 0.4rem; /* Reduced from 0.5rem */
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    white-space: nowrap; /* Prevent text wrapping */
    min-width: fit-content; /* Ensure buttons fit content */
}

.nav-link:hover,
.nav-link.active {
    color: var(--bordo-perde);
    background: rgba(244, 197, 66, 0.05);
    transform: translateY(-1px);
}

.nav-link.active {
    background: rgba(244, 197, 66, 0.1);
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(244, 197, 66, 0.15);
}

/* Hover efekti - alt çizgi animasyonu */
.nav-link::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--bordo-perde), var(--kizil-sahne));
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-link:hover::before,
.nav-link.active::before {
    width: 100%;
}

/* ===== HEADER RIGHT SECTION ===== */
.header-right {
    display: flex;
    align-items: center;
    gap: var(--spacing-md); /* Reduced from var(--spacing-lg) */
}

/* Language Selector */
.lang-selector {
    position: relative;
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    padding: 0.5rem 1rem;
    background: rgba(244, 197, 66, 0.1);
    border: 1px solid rgba(244, 197, 66, 0.3);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all 0.3s ease;
}

.lang-selector:hover {
    background: rgba(244, 197, 66, 0.2);
    border-color: rgba(244, 197, 66, 0.5);
}

.lang-selector.active {
    background: rgba(244, 197, 66, 0.25);
    border-color: rgba(244, 197, 66, 0.6);
}

.lang-current {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.875rem;
}

.lang-arrow {
    color: var(--text-secondary);
    font-size: 0.75rem;
    transition: transform 0.3s ease;
}

.lang-selector.active .lang-arrow {
    transform: rotate(180deg);
}

.lang-options {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--white);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1001;
    margin-top: 0.5rem;
}

.lang-selector.active .lang-options {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.lang-option {
    padding: 0.75rem 1rem;
    cursor: pointer;
    transition: background-color 0.2s ease;
    font-size: 0.875rem;
    color: var(--text-primary);
}

.lang-option:hover {
    background: var(--bg-light);
}

.lang-option.active {
    background: var(--primary-50);
    color: var(--primary-600);
    font-weight: 600;
}

/* CTA Button */
.btn-cta {
    background: linear-gradient(135deg, var(--bordo-perde) 0%, var(--kizil-sahne) 100%);
    color: var(--krem-beyaz);
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-md);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.875rem;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(122, 30, 44, 0.3);
}

.btn-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(122, 30, 44, 0.4);
    background: linear-gradient(135deg, var(--kizil-sahne) 0%, #5a1621 100%);
}

/* ===== MOBILE MENU BUTTON ===== */
.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 4px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: var(--radius-sm);
    transition: background-color 0.3s ease;
}

.mobile-menu-btn:hover {
    background: rgba(244, 197, 66, 0.1);
}

.mobile-menu-btn span {
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    transition: all 0.3s ease;
    border-radius: 1px;
}

.mobile-menu-btn.active span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.mobile-menu-btn.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-btn.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

/* ===== MOBILE MENU ===== */
.mobile-menu {
    display: none;
    position: fixed;
    top: 97.5px;
    left: 0;
    right: 0;
    background: rgba(250, 243, 224, 0.98);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(244, 197, 66, 0.3);
    padding: 1rem 0;
    transform: translateY(-100%);
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 999;
    width: 100%; /* Ensure full width */
    max-width: 100vw; /* Use viewport width */
    box-sizing: border-box; /* Include padding in width calculation */
}

.mobile-menu.active {
    transform: translateY(0);
    opacity: 1;
}

.mobile-menu-content {
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    width: 100%; /* Ensure full width */
    max-width: 100%; /* Don't exceed viewport */
    box-sizing: border-box;
}

.mobile-nav-link {
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 500;
    font-size: 1.125rem;
    padding: 1rem;
    border-radius: var(--radius-md);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.mobile-nav-link:hover,
.mobile-nav-link.active {
    color: var(--bordo-perde);
    background: rgba(244, 197, 66, 0.1);
}

.mobile-nav-link i {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.mobile-language-section {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(244, 197, 66, 0.2);
}

.mobile-language-section h3 {
    font-size: 0.9rem;
    margin-bottom: 0.75rem;
    color: var(--text-secondary);
}

.mobile-languages {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
}

.mobile-lang-btn {
    width: 100%;
    background: rgba(244, 197, 66, 0.1);
    border: 1px solid rgba(244, 197, 66, 0.3);
    color: var(--text-primary);
    padding: 0.75rem;
    border-radius: var(--radius-md);
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: block;
    text-align: center;
}

.mobile-lang-btn:hover,
.mobile-lang-btn.active {
    background: rgba(244, 197, 66, 0.2);
    border-color: rgba(244, 197, 66, 0.5);
}

/* Responsive Design */
@media (max-width: 1200px) {
    .nav-menu {
        gap: var(--spacing-sm); /* Even smaller gap on medium screens */
    }
    
    .nav-link {
        font-size: 0.75rem; /* Smaller font on medium screens */
        padding: 0.3rem 0.5rem; /* Smaller padding on medium screens */
    }
}

@media (max-width: 992px) {
    .nav-menu {
        display: none;
    }
    
    .mobile-menu-btn {
        display: flex;
    }
    
    .mobile-menu {
        display: block;
    }
}

@media (max-width: 768px) {
    .header {
        padding: 1rem var(--spacing-md);
        height: 80px;
        max-width: 100%; /* Ensure header doesn't exceed viewport */
        width: 100%; /* Full width on mobile */
        box-sizing: border-box; /* Include padding in width calculation */
    }
    
    .page-header {
        border-bottom: 1px solid rgba(244, 197, 66, 0.2) !important;
        width: 100% !important; /* Ensure full width */
        max-width: 100vw !important; /* Use viewport width */
        box-sizing: border-box !important; /* Include padding in width calculation */
    }
    
    .mobile-menu {
        top: 80px;
        width: 100%; /* Ensure mobile menu doesn't exceed viewport */
        left: 0;
        right: 0;
        box-sizing: border-box;
    }
    
    .logo-main {
        font-size: 1.125rem;
    }
    
    .logo-sub {
        font-size: 0.7rem;
    }
    
    .btn-cta {
        padding: 0.625rem 1.25rem;
        font-size: 0.8rem;
    }
}

@media (max-width: 576px) {
    .header {
        padding: 1rem var(--spacing-sm);
        height: 70px;
        max-width: 100%; /* Ensure header doesn't exceed viewport */
        width: 100%; /* Full width on mobile */
        box-sizing: border-box; /* Include padding in width calculation */
    }
    
    .page-header {
        width: 100% !important; /* Ensure full width */
        max-width: 100vw !important; /* Use viewport width */
        box-sizing: border-box !important; /* Include padding in width calculation */
    }
    
    .mobile-menu {
        top: 70px;
        width: 100%; /* Ensure mobile menu doesn't exceed viewport */
        left: 0;
        right: 0;
        box-sizing: border-box;
    }
    
    .logo-icon {
        width: 32px;
        height: 32px;
        font-size: 1rem;
    }
    
    .logo-main {
        font-size: 1rem;
    }
    
    .logo-sub {
        font-size: 0.65rem;
    }
    
    .btn-cta {
        padding: 0.5rem 1rem;
        font-size: 0.75rem;
    }
}
