/* ===== GLOBAL MOBILE FIXES ===== */
/* Bu dosyayı tüm sayfalara import edin */

/* Reset & Base */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
}

body {
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
}

img {
    max-width: 100%;
    height: auto;
}

/* Touch-friendly buttons */
button, a, .btn, [role="button"] {
    min-height: 44px;
    min-width: 44px;
}

/* ===== Navbar Mobile ===== */
@media (max-width: 768px) {
    .navbar, .nav {
        padding: 0.75rem 1rem !important;
    }
    
    .navbar-logo span, .nav-logo-text {
        font-size: 1rem !important;
    }
    
    .nav-links, .nav-menu {
        display: none !important;
    }
    
    .back-btn {
        font-size: 0.8rem !important;
        padding: 0.5rem 0.75rem !important;
    }
    
    .theme-toggle {
        width: 40px !important;
        height: 40px !important;
    }
}

/* ===== Hero Mobile ===== */
@media (max-width: 768px) {
    .hero {
        min-height: auto !important;
        padding: 100px 1rem 3rem !important;
    }
    
    .hero-content {
        padding: 1rem !important;
    }
    
    .hero h1 {
        font-size: 2rem !important;
        line-height: 1.2 !important;
    }
    
    .hero-title {
        font-size: 2rem !important;
    }
    
    .hero-subtitle, .hero p {
        font-size: 1rem !important;
    }
    
    .hero-badge {
        font-size: 0.7rem !important;
        padding: 0.5rem 1rem !important;
    }
    
    .hero-stats {
        flex-direction: column !important;
        gap: 1rem !important;
    }
    
    .hero-stat {
        padding: 1rem !important;
    }
    
    .hero-stat-number, .hero-stat-value {
        font-size: 1.75rem !important;
    }
    
    .hero-actions {
        flex-direction: column !important;
        gap: 0.75rem !important;
    }
    
    .hero-btn, .btn {
        width: 100% !important;
        justify-content: center !important;
    }
    
    .hero-grid {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }
    
    .hero-image {
        order: -1 !important;
    }
    
    .hero-cards {
        display: none !important;
    }
    
    .simulation-btn {
        font-size: 0.9rem !important;
        padding: 1rem 1.5rem !important;
    }
}

/* ===== Section Headers Mobile ===== */
@media (max-width: 768px) {
    section {
        padding: 3rem 1rem !important;
    }
    
    .section-header {
        margin-bottom: 2rem !important;
    }
    
    .section-title {
        font-size: 1.5rem !important;
    }
    
    .section-subtitle, .section-desc {
        font-size: 0.9rem !important;
    }
    
    .section-badge {
        font-size: 0.65rem !important;
        padding: 0.4rem 1rem !important;
    }
}

/* ===== Grid Layouts Mobile ===== */
@media (max-width: 768px) {
    .page-grid, .page-cards {
        grid-template-columns: 1fr !important;
        gap: 1.5rem !important;
    }
    
    .features-grid {
        grid-template-columns: 1fr !important;
        gap: 1rem !important;
    }
    
    .bio-grid {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }
    
    .nature-grid, .thermal-cards, .gastro-grid, .culture-grid, .tips-grid {
        grid-template-columns: 1fr !important;
        gap: 1rem !important;
    }
    
    .thermal-grid {
        grid-template-columns: 1fr !important;
    }
    
    .gastro-featured, .nature-featured {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }
}

/* ===== Cards Mobile ===== */
@media (max-width: 768px) {
    .page-card, .feature-card, .ozan-card {
        border-radius: 1rem !important;
    }
    
    .page-card-content, .feature-card {
        padding: 1.25rem !important;
    }
    
    .page-card-title, .feature-title {
        font-size: 1.1rem !important;
    }
    
    .page-card-desc, .feature-desc {
        font-size: 0.85rem !important;
    }
    
    .page-card-image {
        height: 180px !important;
    }
    
    .ozan-image {
        height: 220px !important;
    }
}

/* ===== Timeline Mobile ===== */
@media (max-width: 768px) {
    .timeline::before {
        left: 20px !important;
    }
    
    .timeline-item,
    .timeline-item:nth-child(even) {
        flex-direction: row !important;
        padding-left: 50px !important;
    }
    
    .timeline-dot {
        left: 20px !important;
        width: 16px !important;
        height: 16px !important;
    }
    
    .timeline-content {
        width: 100% !important;
        padding: 0 !important;
    }
}

/* ===== Principles Grid Mobile ===== */
@media (max-width: 768px) {
    .principles-grid {
        grid-template-columns: 1fr !important;
        gap: 1rem !important;
    }
    
    .hierarchy-pyramid {
        transform: scale(0.8) !important;
    }
    
    .rules-grid {
        grid-template-columns: 1fr !important;
    }
    
    .legacy-grid {
        grid-template-columns: 1fr !important;
    }
}

/* ===== Turizm Page Mobile ===== */
@media (max-width: 768px) {
    .nature-featured-image {
        height: 300px !important;
    }
    
    .nature-stats {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 0.75rem !important;
    }
    
    .thermal-image img {
        height: 300px !important;
    }
    
    .thermal-benefits {
        grid-template-columns: 1fr !important;
    }
    
    .gastro-image img {
        height: 280px !important;
    }
    
    .culture-card {
        height: 280px !important;
    }
}

/* ===== Cacabey Page Mobile ===== */
@media (max-width: 768px) {
    .observatory-features {
        grid-template-columns: 1fr !important;
    }
    
    .planet-columns {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 0.75rem !important;
    }
    
    .sciences-grid {
        grid-template-columns: 1fr !important;
    }
    
    .features-grid-arch {
        grid-template-columns: 1fr !important;
    }
}

/* ===== Footer Mobile ===== */
@media (max-width: 768px) {
    .footer, footer {
        padding: 3rem 1rem 2rem !important;
    }
    
    .footer-grid {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
        text-align: center !important;
    }
    
    .footer-brand p {
        max-width: 100% !important;
        margin: 1rem auto !important;
    }
    
    .footer-social {
        justify-content: center !important;
    }
    
    .footer-bottom {
        flex-direction: column !important;
        gap: 0.5rem !important;
        text-align: center !important;
    }
}

/* ===== CTA Section Mobile ===== */
@media (max-width: 768px) {
    .cta {
        padding: 4rem 1.5rem !important;
    }
    
    .cta-title {
        font-size: 1.5rem !important;
    }
    
    .cta-desc {
        font-size: 0.95rem !important;
    }
}

/* ===== Video Container Mobile ===== */
@media (max-width: 768px) {
    .video-container {
        border-radius: 1rem !important;
    }
    
    .video-container iframe {
        height: 220px !important;
    }
}

/* ===== Modal/Popup Mobile ===== */
@media (max-width: 768px) {
    .modal-content, .youtube-modal-content {
        width: 95% !important;
        padding: 1rem !important;
    }
}

/* ===== Map Mobile ===== */
@media (max-width: 768px) {
    .map-container iframe {
        height: 300px !important;
    }
}

/* ===== Touch Improvements ===== */
@media (hover: none) and (pointer: coarse) {
    /* Remove hover effects on touch devices */
    .page-card:hover,
    .feature-card:hover,
    .ozan-card:hover {
        transform: none !important;
    }
    
    /* Make tap targets larger */
    a, button {
        padding: 0.5rem !important;
    }
}

/* ===== Safe Areas (iPhone X+) ===== */
@supports (padding: max(0px)) {
    body {
        padding-left: max(0px, env(safe-area-inset-left));
        padding-right: max(0px, env(safe-area-inset-right));
    }
    
    .navbar, .nav, footer, .footer {
        padding-left: max(1rem, env(safe-area-inset-left));
        padding-right: max(1rem, env(safe-area-inset-right));
    }
}

/* ===== Font Size Accessibility ===== */
@media (max-width: 360px) {
    html {
        font-size: 14px !important;
    }
    
    .hero h1, .hero-title {
        font-size: 1.75rem !important;
    }
}

/* ===== Landscape Phone ===== */
@media (max-height: 500px) and (orientation: landscape) {
    .hero {
        min-height: auto !important;
        padding: 80px 2rem 2rem !important;
    }
    
    .hero-stats {
        flex-direction: row !important;
    }
}
