@media (max-width: 1200px) {
    .about-grid, .why-grid, .sustainability-grid {
        gap: 50px;
    }
    
    .product-row {
        gap: 40px;
    }
}

@media (max-width: 991px) {
    .hero {
        padding-top: 140px;
        padding-bottom: 80px;
    }

    .hero-grid {
        grid-template-columns: 1fr;
        gap: 50px;
    }

    .hero h1 {
        font-size: clamp(48px, 8vw, 68px);
    }

    .hero-image {
        order: -1;
    }

    .hero-buttons {
        flex-wrap: wrap;
    }

    .scroll-indicator {
        display: none;
    }

    /* Disable hover zoom/animations on mobile */
    .about-image img,
    .why-image img,
    .product-image-col img,
    .sustainability-image img,
    .solution-card img,
    .project-featured-card img,
    .project-side-card img {
        transition: none !important;
        transform: none !important;
    }
    
    /* About */
    .about-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .about-image {
        order: -1;
        height: 400px;
    }
    
    /* About Page New Sections */
    .story-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .values-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 30px;
    }
    
    .exports-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .exports-image {
        order: -1;
        height: 350px;
    }
    
    .about-hero {
        padding-top: 140px;
        min-height: auto;
    }

    .about-hero-image {
        height: auto;
        aspect-ratio: 16 / 9;
    }
    
    /* Solutions Page New Layouts */
    .solution-row, .solution-row:nth-child(even) {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .solution-row:nth-child(even) .solution-image-col,
    .solution-row .solution-image-col {
        order: -1;
    }
    
    .solution-image-col {
        height: 400px;
    }
    
    /* Products Page Layouts */
    .product-detail-grid, .product-detail-grid.reverse {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .product-detail-grid.reverse .product-detail-content,
    .product-detail-grid .product-detail-content {
        order: -1;
    }
    
    .product-gallery.layout-a, .product-gallery.layout-b {
        grid-template-columns: 1fr;
    }
    
    .gallery-item {
        height: 350px;
    }
    
    /* Projects Page Layouts */
    .portfolio-grid {
        grid-template-columns: 1fr;
    }
    
    .portfolio-card.featured {
        grid-column: 1;
        height: 500px;
    }
    
    .portfolio-card {
        height: 450px;
    }
    
    /* Contact Page Layouts */
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 50px;
    }
    
    /* Timeline Mobile (Vertical) */
    .timeline-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .timeline-grid::before {
        top: 0;
        left: 24px;
        width: 2px;
        height: 100%;
    }
    
    .timeline-item {
        padding-top: 0;
        padding-left: 60px;
    }
    
    .timeline-dot {
        top: 0;
        left: 15px;
    }
    
    /* Capabilities */
    .capabilities-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 30px;
    }
    
    .capability-item:nth-child(2)::after {
        display: none;
    }
    
    /* Solutions */
    .solutions-grid {
        grid-template-columns: 1fr;
        gap: 25px;
    }
    
    .solution-card {
        height: 400px;
        padding: 40px;
    }

    .solution-card::after {
        background: linear-gradient(180deg, rgba(23, 55, 47, 0.2) 0%, rgba(23, 55, 47, 0.9) 100%) !important;
        transition: none !important;
    }
    
    .solution-card p {
        opacity: 1 !important;
        transform: translateY(0) !important;
        height: auto !important;
        margin-top: 10px !important;
        transition: none !important;
    }
    
    /* Products */
    .product-row, .product-row:nth-child(even) {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .product-row:nth-child(even) .product-image-col {
        order: 0;
    }
    
    .product-row:nth-child(even) .product-content-col {
        order: 0;
    }
    
    .product-image-col {
        height: 380px;
    }
    
    /* Why Kiwari */
    .why-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .why-image {
        height: 350px;
        order: -1;
    }
    
    /* Projects */
    .projects-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .project-featured-card {
        height: 450px;
        padding: 40px;
    }
    
    .project-featured-card h3 {
        font-size: 32px;
    }
    
    /* Process */
    .process-timeline {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .process-timeline::before {
        display: none;
    }

    .process-step:hover .process-num {
        transform: none !important;
        background-color: var(--bg-color) !important;
        color: var(--primary-color) !important;
        border-color: var(--border-color) !important;
    }
    
    /* Sustainability */
    .sustainability-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .sustainability-image {
        height: 350px;
    }
    
    /* Footer */
    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 40px;
    }
}

@media (max-width: 768px) {
    .header {
        height: 80px;
    }
    
    .header .container {
        height: 80px;
        display: flex;
        justify-content: space-between;
        align-items: center;
    }
    
    /* Toggle Button (Hamburger) */
    .menu-toggle {
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        width: 26px;
        height: 18px;
        background: transparent;
        border: none;
        cursor: pointer;
        padding: 0;
        z-index: 1001;
        position: relative;
    }
    
    .menu-toggle span {
        width: 100%;
        height: 2px;
        background-color: var(--primary-color);
        transition: all 0.3s cubic-bezier(0.645, 0.045, 0.355, 1);
        transform-origin: left center;
    }
    
    /* Hamburger to X Animation */
    .menu-toggle.active span:nth-child(1) {
        transform: rotate(45deg) translate(-2px, -3px);
    }
    
    .menu-toggle.active span:nth-child(2) {
        opacity: 0;
        transform: scale(0);
    }
    
    .menu-toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translate(-2px, 3px);
    }
    
    /* Mobile Fullscreen Navigation Overlay */
    .nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 100%;
        height: 100vh;
        background-color: var(--bg-color);
        display: flex;
        align-items: center;
        justify-content: center;
        transition: right 0.4s cubic-bezier(0.77, 0.2, 0.05, 1);
        z-index: 1000;
        padding: 40px;
    }
    
    .nav.active {
        right: 0;
    }
    
    .nav ul {
        flex-direction: column;
        gap: 30px;
        text-align: center;
        width: 100%;
    }
    
    .nav a {
        font-family: var(--font-serif);
        font-size: 28px;
        font-weight: 500;
        color: var(--primary-color);
        display: inline-block;
        transition: color 0.3s ease;
    }
    
    .nav a:hover {
        color: var(--accent-color);
    }

    body.menu-open {
        overflow: hidden;
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .section-padding {
        padding-block: 60px;
    }
    
    .header .container {
        display: flex;
        justify-content: space-between;
        align-items: center;
        height: 70px;
        padding-block: 0;
    }
    
    .header {
        position: fixed;
        width: 100%;
        top: 0;
        z-index: 999;
        height: 70px;
        background: var(--bg-color) !important;
        border-bottom: 1px solid var(--border-color) !important;
    }
    
    .hero {
        padding-top: 100px;
    }
    
    .page-hero {
        padding-top: 130px;
    }
    
    .about-hero {
        padding-top: 130px;
    }

    
    .values-grid {
        grid-template-columns: 1fr;
    }
    
    .solution-features {
        grid-template-columns: 1fr;
    }
    
    .solution-image-col {
        height: 300px;
    }
    
    .page-hero h1 {
        font-size: 40px;
    }
    
    .product-tech-specs {
        grid-template-columns: 1fr;
    }
    
    .spec-item:nth-child(even) {
        border-right: 1px solid var(--border-color);
    }
    
    .spec-item {
        border-right: none !important;
        border-bottom: 1px solid var(--border-color) !important;
    }
    
    .spec-item:last-child {
        border-bottom: none !important;
    }
    
    /* Projects Mobile */
    .portfolio-card.featured {
        height: 400px;
    }
    
    .portfolio-card {
        height: 350px;
    }
    
    .portfolio-card.featured .portfolio-info h3 {
        font-size: 32px;
    }
    
    .portfolio-info h3 {
        font-size: 28px;
    }
    
    .about-hero h1 {
        font-size: 42px;
    }
    
    /* Contact Mobile */
    .contact-hero h1 {
        font-size: 42px;
    }
    
    .contact-form {
        padding: 30px 20px;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .capabilities-grid {
        grid-template-columns: 1fr;
    }
    
    .capability-item::after {
        display: none;
    }
    
    .solution-card {
        padding: 30px 20px;
        height: 350px;
    }
    
    .solution-card h3 {
        font-size: 26px;
    }
    
    .product-image-col {
        height: 280px;
    }
    
    .product-content-col h3 {
        font-size: 30px;
    }
    
    .product-specs {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .project-featured-card {
        padding: 30px 20px;
        height: 350px;
    }
    
    .project-featured-card h3 {
        font-size: 26px;
    }
    
    .project-side-card {
        padding: 20px;
        height: 240px;
    }
    
    .project-side-card h3 {
        font-size: 20px;
    }
}

/* Base structural fix for horizontal scroll */
* {
    max-width: 100%;
}

html, body {
    position: relative;
    overflow-x: hidden !important;
}

/* Contact page mobile grid override */
@media (max-width: 768px) {
    .contact-section .container > div[style*="grid-template-columns"] {
        grid-template-columns: 1fr !important;
        gap: 20px !important;
    }
    
    .solution-image-col {
        aspect-ratio: 4 / 5 !important;
        width: 100% !important;
        height: auto !important;
    }

    .gallery-item {
        aspect-ratio: 16 / 10 !important;
        width: 100% !important;
        height: auto !important;
    }
    
    .product-gallery {
        grid-template-columns: 1fr !important;
    }
}
