/* Mobile First Responsive Design */

/* Small devices (landscape phones, 576px and up) */
@media (max-width: 575.98px) {
    :root {
        --font-size-5xl: 2.5rem;
        --font-size-4xl: 2rem;
        --font-size-3xl: 1.5rem;
        --font-size-2xl: 1.25rem;
        --spacing-20: 3rem;
        --spacing-16: 2.5rem;
        --spacing-12: 2rem;
    }

    .container {
        padding: 0 var(--spacing-3);
    }

    /* Header */
    .header-container {
        flex-direction: column;
        gap: var(--spacing-4);
        padding: var(--spacing-4);
    }

    .logo-section {
        flex-direction: column;
        text-align: center;
        gap: var(--spacing-3);
    }

    .header-logo {
        width: 60px;
        height: 60px;
    }

    .header-text h1 {
        font-size: var(--font-size-2xl);
    }

    .tagline {
        font-size: var(--font-size-xs);
    }

    .social-nav {
        justify-content: center;
    }

    .social-icon {
        width: 35px;
        height: 35px;
    }

    /* Hero Section */
    .hero-section {
        padding: var(--spacing-12) 0;
    }

    .hero-title {
        font-size: var(--font-size-3xl);
        margin-bottom: var(--spacing-4);
    }

    .hero-subtitle {
        font-size: var(--font-size-base);
        margin-bottom: var(--spacing-6);
    }

    .cta-button {
        padding: var(--spacing-3) var(--spacing-6);
        font-size: var(--font-size-base);
    }

    /* Section Titles */
    .section-title {
        font-size: var(--font-size-3xl);
        margin-bottom: var(--spacing-8);
    }

    /* Gallery */
    .gallery-slider {
        margin: 0 var(--spacing-2);
    }

    .slider-container {
        height: 300px;
    }

    .slider-btn {
        width: 40px;
        height: 40px;
    }

    .slider-btn svg {
        width: 20px;
        height: 20px;
    }

    .prev-btn {
        left: var(--spacing-2);
    }

    .next-btn {
        right: var(--spacing-2);
    }

    /* Services */
    .services-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-6);
    }

    .service-card {
        padding: var(--spacing-6);
    }

    .service-icon {
        width: 50px;
        height: 50px;
    }

    .service-icon svg {
        width: 25px;
        height: 25px;
    }

    .contact-title {
        font-size: var(--font-size-lg);
    }

    .services-intro p {
        font-size: var(--font-size-base);
    }

    /* About */
    .about-content {
        grid-template-columns: 1fr;
        gap: var(--spacing-8);
    }

    .about-features {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
    }

    .feature-item {
        flex: 1;
        min-width: 120px;
        padding: var(--spacing-4);
    }

    .feature-number {
        font-size: var(--font-size-2xl);
    }

    .feature-text {
        font-size: var(--font-size-xs);
    }

    /* Contact */
    .contact-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-8);
    }

    .contact-info-card,
    .contact-form-card {
        padding: var(--spacing-6);
    }

    .contact-item {
        flex-direction: column;
        text-align: center;
        gap: var(--spacing-2);
    }

    /* Footer */
    .footer-content {
        grid-template-columns: 1fr;
        gap: var(--spacing-6);
        text-align: center;
    }

    .footer-social {
        justify-content: center;
    }
}

/* Medium devices (tablets, 768px and up) */
@media (min-width: 576px) and (max-width: 767.98px) {
    .header-container {
        flex-direction: column;
        gap: var(--spacing-4);
    }

    .logo-section {
        justify-content: center;
    }

    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .about-content {
        grid-template-columns: 1fr;
        gap: var(--spacing-10);
    }

    .about-features {
        flex-direction: row;
        justify-content: space-around;
    }

    .contact-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-10);
    }

    .footer-content {
        grid-template-columns: 1fr 1fr;
        gap: var(--spacing-8);
    }
}

/* Large devices (desktops, 992px and up) */
@media (min-width: 768px) and (max-width: 991.98px) {
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-content {
        grid-template-columns: 2fr 1fr 1fr;
    }
}

/* Extra large devices (large desktops, 1200px and up) */
@media (min-width: 1200px) {
    .container {
        max-width: 1400px;
    }

    .hero-title {
        font-size: 4rem;
    }

    .section-title {
        font-size: 3.5rem;
    }

    .slider-container {
        height: 600px;
    }
}

/* Landscape orientation adjustments */
@media (orientation: landscape) and (max-height: 500px) {
    .hero-section {
        padding: var(--spacing-8) 0;
    }

    .hero-title {
        font-size: var(--font-size-3xl);
        margin-bottom: var(--spacing-3);
    }

    .hero-subtitle {
        font-size: var(--font-size-base);
        margin-bottom: var(--spacing-4);
    }
}

/* High DPI displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .header-logo {
        image-rendering: -webkit-optimize-contrast;
        image-rendering: crisp-edges;
    }
}

/* Reduced motion preferences */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .hero-title,
    .hero-subtitle,
    .cta-button {
        animation: none;
    }

    .slider-container {
        transition: none;
    }
}


/* Print styles */
@media print {
    .header,
    .footer,
    .cta-button,
    .slider-btn,
    .social-nav,
    .contact-form-card {
        display: none !important;
    }

    body {
        background: white !important;
        color: black !important;
    }

    .section-title {
        color: black !important;
    }

    .service-card {
        break-inside: avoid;
        box-shadow: none !important;
        border: 1px solid #ccc;
    }

    .map-container iframe {
        display: none;
    }

    .map-container::after {
        content: "Harita: Bamby Su Arıtma Sistemleri - Mersin, Türkiye";
        display: block;
        padding: 2rem;
        text-align: center;
        border: 1px solid #ccc;
        background: #f5f5f5;
    }
}