/* ============================================
   e-ŞEHIR SUNUM2 - RESPONSIVE STYLES
   Mobile First Responsive Design
   ============================================ */

/* ============================================
   TABLET (768px - 1024px)
   ============================================ */
@media (max-width: 1024px) {
    .container {
        padding: 0 var(--spacing-md);
    }
    
    .nav-wrapper {
        padding: var(--spacing-sm) var(--spacing-md);
    }
    
    .nav-links {
        gap: var(--spacing-xs);
    }
    
    .nav-link {
        padding: 8px 15px;
        font-size: 0.9rem;
    }
    
    .section-title {
        font-size: 2.5rem;
    }
    
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ============================================
   MOBILE (max 768px)
   ============================================ */
@media (max-width: 768px) {
    /* Typography */
    h1 { font-size: 2.5rem; }
    h2 { font-size: 2rem; }
    h3 { font-size: 1.5rem; }
    
    .section-title {
        font-size: 2rem;
    }
    
    .section-subtitle {
        font-size: 1rem;
    }
    
    /* Navigation */
    .main-nav {
        margin: var(--spacing-xs);
        border-radius: 15px;
    }
    
    .nav-wrapper {
        flex-wrap: wrap;
    }
    
    .nav-toggle {
        display: flex;
        order: 3;
    }
    
    .nav-toggle.active span:nth-child(1) {
        transform: rotate(45deg) translate(8px, 8px);
    }
    
    .nav-toggle.active span:nth-child(2) {
        opacity: 0;
    }
    
    .nav-toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -7px);
    }
    
    .nav-links {
        order: 4;
        flex-basis: 100%;
        flex-direction: column;
        max-height: 0;
        overflow: hidden;
        transition: max-height var(--transition-normal);
        gap: 0;
    }
    
    .nav-links.active {
        max-height: 500px;
        padding-top: var(--spacing-md);
    }
    
    .nav-link {
        width: 100%;
        justify-content: flex-start;
        padding: var(--spacing-sm);
        border-radius: 8px;
    }
    
    .nav-search-btn {
        order: 2;
    }
    
    /* Content */
    .app-content {
        padding-top: 100px;
    }
    
    .section {
        padding: var(--spacing-lg) 0;
    }
    
    /* Cards */
    .glass-card {
        padding: var(--spacing-md);
        border-radius: 15px;
    }
    
    .module-card {
        margin-bottom: var(--spacing-md);
    }
    
    /* Stats */
    .stat-icon {
        font-size: 2rem;
    }
    
    .stat-value {
        font-size: 2rem;
    }
    
    /* Search */
    .search-overlay-content {
        margin: 5% auto;
        padding: var(--spacing-md);
    }
    
    .search-bar {
        font-size: 14px;
        padding: 14px 20px;
        padding-left: 48px;
    }
    
    /* Footer */
    .footer-content {
        grid-template-columns: 1fr;
        gap: var(--spacing-lg);
    }
    
    .footer-section {
        padding: var(--spacing-sm);
        text-align: center;
    }
    
    .footer-social {
        justify-content: center;
    }
    
    /* Theme Switcher */
    .theme-switcher {
        top: auto;
        bottom: 20px;
        right: 50%;
        transform: translateX(50%);
        padding: 8px;
        gap: 6px;
    }
    
    .theme-btn {
        width: 35px;
        height: 35px;
    }
    
    /* Scroll to Top */
    .scroll-to-top {
        bottom: 90px;
        right: 20px;
        width: 45px;
        height: 45px;
    }
    
    /* Buttons */
    .btn {
        padding: 10px 24px;
        font-size: 14px;
    }
    
    .btn-lg {
        padding: 14px 30px;
        font-size: 16px;
    }
    
    /* Grid Layouts */
    .grid-2 {
        grid-template-columns: 1fr !important;
    }
    
    .grid-3 {
        grid-template-columns: 1fr !important;
    }
    
    .grid-4 {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

/* ============================================
   SMALL MOBILE (max 480px)
   ============================================ */
@media (max-width: 480px) {
    /* Container */
    .container {
        padding: 0 var(--spacing-sm);
    }
    
    /* Typography */
    h1 { font-size: 2rem; }
    h2 { font-size: 1.75rem; }
    h3 { font-size: 1.4rem; }
    
    .section-title {
        font-size: 1.75rem;
    }
    
    /* Navigation */
    .logo-img {
        height: 32px;
    }
    
    .logo-text {
        font-size: 1.2rem;
    }
    
    .nav-link {
        font-size: 0.9rem;
    }
    
    /* Cards */
    .glass-card {
        padding: var(--spacing-sm);
        border-radius: 12px;
    }
    
    .module-card-header {
        padding: var(--spacing-md);
    }
    
    .module-card-body {
        padding: var(--spacing-md);
    }
    
    .module-card-icon {
        font-size: 2.5rem;
    }
    
    .module-card-title {
        font-size: 1.2rem;
    }
    
    /* Stats */
    .stat-card {
        padding: var(--spacing-md);
    }
    
    .stat-icon {
        font-size: 1.75rem;
    }
    
    .stat-value {
        font-size: 1.75rem;
    }
    
    .stat-label {
        font-size: 0.85rem;
    }
    
    /* Footer */
    .footer-title {
        font-size: 1.25rem;
    }
    
    .footer-subtitle {
        font-size: 1rem;
    }
    
    .footer-text {
        font-size: 0.9rem;
    }
    
    /* Error Page */
    .error-title {
        font-size: 4rem;
    }
    
    .error-message {
        font-size: 1.2rem;
    }
    
    /* Grid */
    .grid-4 {
        grid-template-columns: 1fr !important;
    }
}

/* ============================================
   LANDSCAPE PHONES
   ============================================ */
@media (max-height: 500px) and (orientation: landscape) {
    .app-content {
        padding-top: 80px;
    }
    
    .section {
        padding: var(--spacing-md) 0;
    }
    
    .theme-switcher {
        top: 10px;
        bottom: auto;
        right: 10px;
        transform: none;
    }
}

/* ============================================
   PRINT STYLES
   ============================================ */
@media print {
    .main-nav,
    .theme-switcher,
    .scroll-to-top,
    .nav-search-btn,
    .search-overlay,
    .page-loader {
        display: none !important;
    }
    
    .app-content {
        padding-top: 0;
    }
    
    .glass-card {
        border: 1px solid #ddd;
        box-shadow: none;
        backdrop-filter: none;
        background: #fff;
    }
    
    * {
        background: #fff !important;
        color: #000 !important;
    }
}

/* ============================================
   HIGH CONTRAST MODE
   ============================================ */
@media (prefers-contrast: high) {
    .glass-card {
        border-width: 2px;
    }
    
    .btn {
        border: 2px solid currentColor;
    }
    
    .nav-link:focus,
    .btn:focus {
        outline: 3px solid var(--primary-color);
        outline-offset: 2px;
    }
}

/* ============================================
   REDUCED MOTION
   ============================================ */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .hover-float:hover,
    .hover-scale:hover,
    .hover-rotate:hover {
        transform: none;
    }
}

/* ============================================
   DARK MODE PREFERENCE
   ============================================ */
@media (prefers-color-scheme: dark) {
    /* Otomatik tema değişimi için theme-manager.js kullanılacak */
}

/* ============================================
   GRID UTILITIES
   ============================================ */
.grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-lg);
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--spacing-lg);
}

.grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--spacing-lg);
}

@media (max-width: 1200px) {
    .grid-4 {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 900px) {
    .grid-3,
    .grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .grid-2,
    .grid-3,
    .grid-4 {
        grid-template-columns: 1fr;
    }
}
