/* ==========================================================================
   IBRAHIM INTERNATIONAL - PREMIUM STATIC HTML WEBSITE
   FILE: css/responsive.css
   PURPOSE: Media Queries and Responsive Adjustments
   ========================================================================== */

/* --------------------------------------------------------------------------
   ULTRA WIDE MONITOR (2560px+)
   -------------------------------------------------------------------------- */
@media screen and (min-width: 2560px) {
    :root {
        --container-max-width: 1800px;
        --text-base: 1.125rem;
    }
    
    .hero {
        min-height: 800px;
    }
    
    .hero__title {
        font-size: 5rem;
    }
}

/* --------------------------------------------------------------------------
   LAPTOP LARGE (1600px)
   -------------------------------------------------------------------------- */
@media screen and (max-width: 1600px) {
    :root {
        --container-max-width: 1300px;
    }

    .hero__title {
        font-size: var(--text-5xl);
    }
}

/* --------------------------------------------------------------------------
   LAPTOP (1440px)
   -------------------------------------------------------------------------- */
@media screen and (max-width: 1440px) {
    :root {
        --space-9: 6rem;
        --space-10: 8rem;
    }

    .nav__list {
        gap: var(--space-4);
    }

    .hero {
        min-height: 600px;
    }
}

/* --------------------------------------------------------------------------
   LAPTOP SMALL (1366px)
   -------------------------------------------------------------------------- */
@media screen and (max-width: 1366px) {
    /* Category Section: 6 Columns -> 3 Columns */
    .category-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    /* Products: 4 Cards -> 3 Cards */
    .core-products-grid,
    .grid-4 {
        grid-template-columns: repeat(3, 1fr);
    }

    .footer__top {
        grid-template-columns: 2fr 1fr 1fr 1fr;
        gap: var(--space-4);
    }
}

/* --------------------------------------------------------------------------
   TABLET LANDSCAPE (1200px)
   -------------------------------------------------------------------------- */
@media screen and (max-width: 1200px) {
    :root {
        --text-5xl: 3rem;
        --text-4xl: 2.5rem;
        --space-9: 5rem;
    }

    .nav__link {
        font-size: 0.8rem;
    }

    .split-section {
        gap: var(--space-5);
    }

    .cert-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    /* Product Page Sidebar */
    .product-layout {
        grid-template-columns: 240px 1fr;
        gap: var(--space-4);
    }
}

/* --------------------------------------------------------------------------
   TABLET (1024px)
   -------------------------------------------------------------------------- */
@media screen and (max-width: 1024px) {
    :root {
        --header-height: 70px;
    }

    /* Header & Navigation -> Hamburger Menu */
    .nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 100%;
        max-width: 400px;
        height: 100vh;
        background-color: var(--color-bg-white);
        box-shadow: var(--shadow-lg);
        flex-direction: column;
        align-items: flex-start;
        padding: var(--space-8) var(--space-5) var(--space-5);
        transition: right var(--transition-normal);
        z-index: 999;
        overflow-y: auto;
    }

    .nav.is-active {
        right: 0;
    }

    .nav__list {
        flex-direction: column;
        align-items: flex-start;
        width: 100%;
        gap: 0;
    }

    .nav__item {
        width: 100%;
        height: auto;
        border-bottom: 1px solid var(--color-border);
    }

    .nav__link {
        width: 100%;
        padding: var(--space-4) 0;
        color: var(--color-secondary);
        font-size: var(--text-base);
    }

    .nav__dropdown,
    .mega-menu {
        position: static;
        box-shadow: none;
        opacity: 1;
        visibility: visible;
        transform: none;
        display: none; /* Handled by JS accordion on mobile */
        border-top: none;
        padding: 0 0 var(--space-3) var(--space-3);
    }

    .nav__item.is-open .nav__dropdown,
    .nav__item.is-open .mega-menu {
        display: block;
    }

    .mega-menu__container {
        grid-template-columns: 1fr;
        gap: var(--space-3);
        padding: 0;
    }

    /* Hamburger Button */
    .header__hamburger {
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        width: 30px;
        height: 20px;
        background: transparent;
        border: none;
        cursor: pointer;
        z-index: 1000;
    }

    .header__hamburger span {
        width: 100%;
        height: 2px;
        background-color: var(--color-text-light);
        transition: all var(--transition-fast);
    }

    .header--scrolled .header__hamburger span {
        background-color: var(--color-secondary);
    }

    .header__hamburger.is-active span:nth-child(1) {
        transform: translateY(9px) rotate(45deg);
        background-color: var(--color-secondary);
    }

    .header__hamburger.is-active span:nth-child(2) {
        opacity: 0;
    }

    .header__hamburger.is-active span:nth-child(3) {
        transform: translateY(-9px) rotate(-45deg);
        background-color: var(--color-secondary);
    }

    .header__logo img {
        height: 35px;
    }

    /* Category Section: 3 Columns -> 2 Columns */
    .category-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Products: 3 Cards -> 2 Cards */
    .core-products-grid,
    .grid-4,
    .grid-3 {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Jackets / Split Layout -> Single Column */
    .split-section {
        grid-template-columns: 1fr;
    }

    .split-section__image {
        order: -1; /* Image always first on mobile/tablet */
    }

    /* Manufacturing -> Stack Layout */
    .manufacturing-floating-card {
        position: static;
        transform: none;
        width: 100%;
        margin-top: calc(var(--space-5) * -1);
    }

    /* Footer: 4 Columns -> 2 Columns */
    .footer__top {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Product Page Sidebar */
    .product-layout {
        grid-template-columns: 1fr;
    }

    .sidebar {
        position: static;
        margin-bottom: var(--space-5);
    }
}

/* --------------------------------------------------------------------------
   SMALL TABLET / IPAD AIR (992px)
   -------------------------------------------------------------------------- */
@media screen and (max-width: 992px) {
    /* Statistics: 4 -> 2 Columns */
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Contact Page: 2 Columns -> 1 Column */
    .contact-layout {
        grid-template-columns: 1fr;
    }

    .map-container {
        height: 350px;
    }
}

/* --------------------------------------------------------------------------
   MOBILE LARGE (768px)
   -------------------------------------------------------------------------- */
@media screen and (max-width: 768px) {
    :root {
        --text-5xl: 2.5rem;
        --text-4xl: 2rem;
        --text-3xl: 1.75rem;
        --space-9: 4rem;
        /* Reduce animations for mobile performance */
        --transition-slow: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        --transition-normal: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    }

    /* Hero Section */
    .hero {
        min-height: 500px;
        height: 80vh;
    }

    .hero__title {
        font-size: var(--text-4xl);
    }

    .hero__subtitle {
        font-size: var(--text-md);
    }

    .hero__actions {
        display: flex;
        flex-direction: column;
        gap: var(--space-3);
    }

    .hero__actions .btn {
        width: 100%;
    }

    /* Equestrian -> Mobile Slider Ready */
    .equestrian-grid {
        display: flex;
        flex-wrap: nowrap;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        padding-bottom: var(--space-4);
        -webkit-overflow-scrolling: touch;
        gap: var(--space-4);
    }

    .equestrian-grid > * {
        flex: 0 0 85%;
        scroll-snap-align: start;
    }

    /* Hide scrollbar for a cleaner look but keep functionality */
    .equestrian-grid::-webkit-scrollbar {
        display: none;
    }
    .equestrian-grid {
        -ms-overflow-style: none;
        scrollbar-width: none;
    }

    /* Process Grid: 4 -> 2 Columns */
    .process-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Timeline Vertical Restructure */
    .timeline::before {
        left: 0;
    }

    .timeline__item {
        justify-content: flex-end;
        padding-right: 0;
        padding-left: var(--space-5);
    }

    .timeline__item:nth-child(even) {
        padding-left: var(--space-5);
    }

    .timeline__item:nth-child(odd) .timeline__content,
    .timeline__item:nth-child(even) .timeline__content {
        width: 100%;
        text-align: left;
        margin: 0;
    }

    .timeline__dot {
        left: 0;
    }

    /* Tables */
    .table-responsive {
        display: block;
        width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
}

/* --------------------------------------------------------------------------
   MOBILE (576px)
   -------------------------------------------------------------------------- */
@media screen and (max-width: 576px) {
    :root {
        --space-5: 1.5rem;
    }

    /* Category Section: 2 Columns -> 1 Column */
    .category-grid {
        grid-template-columns: 1fr;
    }

    /* Products: 2 Cards -> 1 Card */
    .core-products-grid,
    .grid-4,
    .grid-3,
    .grid-2 {
        grid-template-columns: 1fr;
    }

    /* Footer: 2 Columns -> 1 Column */
    .footer__top {
        grid-template-columns: 1fr;
    }

    /* Forms */
    .form-group {
        width: 100%;
    }

    .newsletter-form {
        flex-direction: column;
        gap: var(--space-2);
    }

    .newsletter-form__input,
    .newsletter-form__btn {
        width: 100%;
        border-radius: var(--radius-sm);
    }

    /* Process & Stats Grid: 2 -> 1 Column */
    .process-grid,
    .stats-grid {
        grid-template-columns: 1fr;
    }

    .contact-info-cards {
        grid-template-columns: 1fr;
    }

    /* Modals & Popups */
    .modal__dialog {
        height: 100vh;
        max-height: 100vh;
        border-radius: 0;
        overflow-y: auto;
    }
    
    .toolbar {
        flex-direction: column;
        align-items: flex-start;
        gap: var(--space-3);
    }
    
    .toolbar__sort {
        width: 100%;
    }
    
    .toolbar__select {
        width: 100%;
    }
}

/* --------------------------------------------------------------------------
   SMALL MOBILE (480px)
   -------------------------------------------------------------------------- */
@media screen and (max-width: 480px) {
    :root {
        --text-4xl: 1.75rem;
        --text-3xl: 1.5rem;
    }

    .hero__title {
        font-size: 2.25rem;
    }

    .hero__subtitle {
        font-size: var(--text-sm);
    }

    .section-title {
        font-size: var(--text-3xl);
    }

    .btn {
        padding: var(--space-3) var(--space-4);
        font-size: 0.75rem;
    }
    
    .page-banner {
        padding: 120px 0 60px;
    }
    
    .cert-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* --------------------------------------------------------------------------
   EXTRA SMALL MOBILE (360px)
   -------------------------------------------------------------------------- */
@media screen and (max-width: 360px) {
    :root {
        --text-base: 0.875rem;
    }

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

    .hero__title {
        font-size: 2rem;
    }
    
    .nav__link {
        font-size: var(--text-sm);
    }
    
    .header__logo img {
        height: 28px;
    }
}/* ==========================================================================
   IBRAHIM INTERNATIONAL - PREMIUM STATIC HTML WEBSITE
   FILE: css/responsive.css
   PURPOSE: Media Queries and Responsive Adjustments
   ========================================================================== */

/* --------------------------------------------------------------------------
   ULTRA WIDE MONITOR (2560px+)
   -------------------------------------------------------------------------- */
@media screen and (min-width: 2560px) {
    :root {
        --container-max-width: 1800px;
        --text-base: 1.125rem;
    }
    
    .hero {
        min-height: 800px;
    }
    
    .hero__title {
        font-size: 5rem;
    }
}

/* --------------------------------------------------------------------------
   LAPTOP LARGE (1600px)
   -------------------------------------------------------------------------- */
@media screen and (max-width: 1600px) {
    :root {
        --container-max-width: 1300px;
    }

    .hero__title {
        font-size: var(--text-5xl);
    }
}

/* --------------------------------------------------------------------------
   LAPTOP (1440px)
   -------------------------------------------------------------------------- */
@media screen and (max-width: 1440px) {
    :root {
        --space-9: 6rem;
        --space-10: 8rem;
    }

    .nav__list {
        gap: var(--space-4);
    }

    .hero {
        min-height: 600px;
    }
}

/* --------------------------------------------------------------------------
   LAPTOP SMALL (1366px)
   -------------------------------------------------------------------------- */
@media screen and (max-width: 1366px) {
    /* Category Section: 6 Columns -> 3 Columns */
    .category-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    /* Products: 4 Cards -> 3 Cards */
    .core-products-grid,
    .grid-4 {
        grid-template-columns: repeat(3, 1fr);
    }

    .footer__top {
        grid-template-columns: 2fr 1fr 1fr 1fr;
        gap: var(--space-4);
    }
}

/* --------------------------------------------------------------------------
   TABLET LANDSCAPE (1200px)
   -------------------------------------------------------------------------- */
@media screen and (max-width: 1200px) {
    :root {
        --text-5xl: 3rem;
        --text-4xl: 2.5rem;
        --space-9: 5rem;
    }

    .nav__link {
        font-size: 0.8rem;
    }

    .split-section {
        gap: var(--space-5);
    }

    .cert-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    /* Product Page Sidebar */
    .product-layout {
        grid-template-columns: 240px 1fr;
        gap: var(--space-4);
    }
}

/* --------------------------------------------------------------------------
   TABLET (1024px)
   -------------------------------------------------------------------------- */
@media screen and (max-width: 1024px) {
    :root {
        --header-height: 70px;
    }

    /* Header & Navigation -> Hamburger Menu */
    .nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 100%;
        max-width: 400px;
        height: 100vh;
        background-color: var(--color-bg-white);
        box-shadow: var(--shadow-lg);
        flex-direction: column;
        align-items: flex-start;
        padding: var(--space-8) var(--space-5) var(--space-5);
        transition: right var(--transition-normal);
        z-index: 999;
        overflow-y: auto;
    }

    .nav.is-active {
        right: 0;
    }

    .nav__list {
        flex-direction: column;
        align-items: flex-start;
        width: 100%;
        gap: 0;
    }

    .nav__item {
        width: 100%;
        height: auto;
        border-bottom: 1px solid var(--color-border);
    }

    .nav__link {
        width: 100%;
        padding: var(--space-4) 0;
        color: var(--color-secondary);
        font-size: var(--text-base);
    }

    .nav__dropdown,
    .mega-menu {
        position: static;
        box-shadow: none;
        opacity: 1;
        visibility: visible;
        transform: none;
        display: none; /* Handled by JS accordion on mobile */
        border-top: none;
        padding: 0 0 var(--space-3) var(--space-3);
    }

    .nav__item.is-open .nav__dropdown,
    .nav__item.is-open .mega-menu {
        display: block;
    }

    .mega-menu__container {
        grid-template-columns: 1fr;
        gap: var(--space-3);
        padding: 0;
    }

    /* Hamburger Button */
    .header__hamburger {
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        width: 30px;
        height: 20px;
        background: transparent;
        border: none;
        cursor: pointer;
        z-index: 1000;
    }

    .header__hamburger span {
        width: 100%;
        height: 2px;
        background-color: var(--color-text-light);
        transition: all var(--transition-fast);
    }

    .header--scrolled .header__hamburger span {
        background-color: var(--color-secondary);
    }

    .header__hamburger.is-active span:nth-child(1) {
        transform: translateY(9px) rotate(45deg);
        background-color: var(--color-secondary);
    }

    .header__hamburger.is-active span:nth-child(2) {
        opacity: 0;
    }

    .header__hamburger.is-active span:nth-child(3) {
        transform: translateY(-9px) rotate(-45deg);
        background-color: var(--color-secondary);
    }

    .header__logo img {
        height: 35px;
    }

    /* Category Section: 3 Columns -> 2 Columns */
    .category-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Products: 3 Cards -> 2 Cards */
    .core-products-grid,
    .grid-4,
    .grid-3 {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Jackets / Split Layout -> Single Column */
    .split-section {
        grid-template-columns: 1fr;
    }

    .split-section__image {
        order: -1; /* Image always first on mobile/tablet */
    }

    /* Manufacturing -> Stack Layout */
    .manufacturing-floating-card {
        position: static;
        transform: none;
        width: 100%;
        margin-top: calc(var(--space-5) * -1);
    }

    /* Footer: 4 Columns -> 2 Columns */
    .footer__top {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Product Page Sidebar */
    .product-layout {
        grid-template-columns: 1fr;
    }

    .sidebar {
        position: static;
        margin-bottom: var(--space-5);
    }
}

/* --------------------------------------------------------------------------
   SMALL TABLET / IPAD AIR (992px)
   -------------------------------------------------------------------------- */
@media screen and (max-width: 992px) {
    /* Statistics: 4 -> 2 Columns */
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Contact Page: 2 Columns -> 1 Column */
    .contact-layout {
        grid-template-columns: 1fr;
    }

    .map-container {
        height: 350px;
    }
}

/* --------------------------------------------------------------------------
   MOBILE LARGE (768px)
   -------------------------------------------------------------------------- */
@media screen and (max-width: 768px) {
    :root {
        --text-5xl: 2.5rem;
        --text-4xl: 2rem;
        --text-3xl: 1.75rem;
        --space-9: 4rem;
        /* Reduce animations for mobile performance */
        --transition-slow: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        --transition-normal: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    }

    /* Hero Section */
    .hero {
        min-height: 500px;
        height: 80vh;
    }

    .hero__title {
        font-size: var(--text-4xl);
    }

    .hero__subtitle {
        font-size: var(--text-md);
    }

    .hero__actions {
        display: flex;
        flex-direction: column;
        gap: var(--space-3);
    }

    .hero__actions .btn {
        width: 100%;
    }

    /* Equestrian -> Mobile Slider Ready */
    .equestrian-grid {
        display: flex;
        flex-wrap: nowrap;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        padding-bottom: var(--space-4);
        -webkit-overflow-scrolling: touch;
        gap: var(--space-4);
    }

    .equestrian-grid > * {
        flex: 0 0 85%;
        scroll-snap-align: start;
    }

    /* Hide scrollbar for a cleaner look but keep functionality */
    .equestrian-grid::-webkit-scrollbar {
        display: none;
    }
    .equestrian-grid {
        -ms-overflow-style: none;
        scrollbar-width: none;
    }

    /* Process Grid: 4 -> 2 Columns */
    .process-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Timeline Vertical Restructure */
    .timeline::before {
        left: 0;
    }

    .timeline__item {
        justify-content: flex-end;
        padding-right: 0;
        padding-left: var(--space-5);
    }

    .timeline__item:nth-child(even) {
        padding-left: var(--space-5);
    }

    .timeline__item:nth-child(odd) .timeline__content,
    .timeline__item:nth-child(even) .timeline__content {
        width: 100%;
        text-align: left;
        margin: 0;
    }

    .timeline__dot {
        left: 0;
    }

    /* Tables */
    .table-responsive {
        display: block;
        width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
}

/* --------------------------------------------------------------------------
   MOBILE (576px)
   -------------------------------------------------------------------------- */
@media screen and (max-width: 576px) {
    :root {
        --space-5: 1.5rem;
    }

    /* Category Section: 2 Columns -> 1 Column */
    .category-grid {
        grid-template-columns: 1fr;
    }

    /* Products: 2 Cards -> 1 Card */
    .core-products-grid,
    .grid-4,
    .grid-3,
    .grid-2 {
        grid-template-columns: 1fr;
    }

    /* Footer: 2 Columns -> 1 Column */
    .footer__top {
        grid-template-columns: 1fr;
    }

    /* Forms */
    .form-group {
        width: 100%;
    }

    .newsletter-form {
        flex-direction: column;
        gap: var(--space-2);
    }

    .newsletter-form__input,
    .newsletter-form__btn {
        width: 100%;
        border-radius: var(--radius-sm);
    }

    /* Process & Stats Grid: 2 -> 1 Column */
    .process-grid,
    .stats-grid {
        grid-template-columns: 1fr;
    }

    .contact-info-cards {
        grid-template-columns: 1fr;
    }

    /* Modals & Popups */
    .modal__dialog {
        height: 100vh;
        max-height: 100vh;
        border-radius: 0;
        overflow-y: auto;
    }
    
    .toolbar {
        flex-direction: column;
        align-items: flex-start;
        gap: var(--space-3);
    }
    
    .toolbar__sort {
        width: 100%;
    }
    
    .toolbar__select {
        width: 100%;
    }
}

/* --------------------------------------------------------------------------
   SMALL MOBILE (480px)
   -------------------------------------------------------------------------- */
@media screen and (max-width: 480px) {
    :root {
        --text-4xl: 1.75rem;
        --text-3xl: 1.5rem;
    }

    .hero__title {
        font-size: 2.25rem;
    }

    .hero__subtitle {
        font-size: var(--text-sm);
    }

    .section-title {
        font-size: var(--text-3xl);
    }

    .btn {
        padding: var(--space-3) var(--space-4);
        font-size: 0.75rem;
    }
    
    .page-banner {
        padding: 120px 0 60px;
    }
    
    .cert-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* --------------------------------------------------------------------------
   EXTRA SMALL MOBILE (360px)
   -------------------------------------------------------------------------- */
@media screen and (max-width: 360px) {
    :root {
        --text-base: 0.875rem;
    }

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

    .hero__title {
        font-size: 2rem;
    }
    
    .nav__link {
        font-size: var(--text-sm);
    }
    
    .header__logo img {
        height: 28px;
    }
}