/* ============================================
   OFIMÁTICA DEL SEGURA — RESPONSIVE STYLES
   Mobile-first: 480 → 768 → 1024 → 1200
   ============================================ */

/* ----------------------------------------
   MOBILE BASE (default, all sizes)
   ---------------------------------------- */

/* Copiadoras: featured first on mobile */
.copiadoras__card--featured {
    order: -1;
}

/* Top bar: single line on small screens */
.top-bar__right {
    display: none;
}

.top-bar__left {
    justify-content: center;
    width: 100%;
    gap: 16px;
    font-size: 12px;
}

/* Hero mobile: centred layout */
.hero {
    padding: 90px 0 80px;
}

.hero__left {
    text-align: center;
    align-items: center;
}

.hero__title {
    font-size: clamp(2rem, 7vw, 3rem);
}

.hero__stats {
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
}

.hero__actions {
    flex-direction: column;
    align-items: center;
}

.hero__cta-primary,
.hero__cta-secondary {
    width: 100%;
    justify-content: center;
}

/* ----------------------------------------
   SMALL PHONES (480px+)
   ---------------------------------------- */
@media (min-width: 480px) {
    .container {
        padding: 0 24px;
    }

    .hero__title {
        font-size: clamp(2.2rem, 6vw, 3.2rem);
    }

    .hero__actions {
        flex-direction: row;
        align-items: center;
        justify-content: center;
    }

    .hero__cta-primary,
    .hero__cta-secondary {
        width: auto;
    }

    .contact-form {
        padding: 36px;
    }
}

/* ----------------------------------------
   TABLETS (768px+)
   ---------------------------------------- */
@media (min-width: 768px) {
    .container {
        padding: 0 32px;
    }

    /* Top Bar */
    .top-bar__left {
        justify-content: flex-start;
        width: auto;
        gap: 24px;
        font-size: 13px;
    }

    .top-bar__right {
        display: flex;
    }

    /* Hero */
    .hero__stats {
        flex-wrap: nowrap;
    }

    .hero__title {
        font-size: clamp(2.6rem, 5vw, 3.6rem);
    }

    /* Services grid */
    .services__grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 28px;
    }

    /* Why Us */
    .why-us__inner {
        grid-template-columns: 1fr 1fr;
        gap: 60px;
    }

    .why-us__visual {
        display: block;
    }

    /* Stats */
    .stats__inner {
        grid-template-columns: repeat(2, 1fr);
        gap: 40px;
    }

    /* Clients */
    .clients__grid {
        grid-template-columns: 1fr 1fr;
        gap: 24px;
    }

    /* Copiadoras */
    .copiadoras__grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 24px;
    }

    .copiadoras__card--featured {
        order: 0;
    }

    /* Process */
    .process__timeline {
        grid-template-columns: repeat(2, 1fr);
        gap: 40px;
        max-width: 100%;
    }

    /* FAQ */
    .faq__inner {
        grid-template-columns: 3fr 2fr;
        gap: 60px;
    }

    .faq__visual {
        display: block;
    }

    /* Contact */
    .contact__inner {
        grid-template-columns: 1fr 1fr;
        gap: 60px;
    }

    /* Footer */
    .footer__inner {
        grid-template-columns: repeat(2, 1fr);
        gap: 40px;
    }

    .footer__bottom-inner {
        flex-direction: row;
        justify-content: space-between;
        text-align: left;
    }

    /* Cookie consent banner */
    .cc-banner__inner {
        flex-direction: row;
        text-align: left;
    }

    .cc-banner__text {
        flex: 1;
    }

    .cc-banner__buttons {
        flex-shrink: 0;
    }
}

/* ----------------------------------------
   DESKTOP (1024px+)
   ---------------------------------------- */
@media (min-width: 1024px) {
    .container {
        padding: 0 40px;
    }

    /* Navbar: show links, hide hamburger */
    .navbar__nav {
        display: flex;
    }

    .navbar__cta {
        display: inline-flex !important;
    }

    .navbar__tools-btn {
        display: inline-flex !important;
    }

    .navbar__hamburger {
        display: none;
    }

    /* Hero: wider, bigger title */
    .hero {
        padding: 120px 0 80px;
    }

    .hero__title {
        font-size: clamp(3rem, 4.5vw, 4.2rem);
    }

    .hero__left {
        max-width: 900px;
    }

    /* Services grid */
    .services__grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 28px;
    }

    /* Stats horizontal row */
    .stats__inner {
        grid-template-columns: repeat(7, auto);
        justify-content: center;
        gap: 0;
        align-items: center;
    }

    .stats__item {
        padding: 0 40px;
    }

    .stats__separator {
        display: block;
        width: 1px;
        height: 60px;
        background: rgba(255, 255, 255, 0.2);
    }

    /* Comparison: 3 columns only on desktop (titles fit comfortably at ~296px/column) */
    .comparison__grid {
        grid-template-columns: 1fr 1fr 1fr;
        gap: 28px;
    }

    /* Copiadoras: 3 cols with featured scale */
    .copiadoras__grid {
        gap: 32px;
        padding: 0 16px;
    }

    .copiadoras__card--featured {
        transform: scale(1.03);
        z-index: 1;
    }

    @media (hover: hover) {
        .copiadoras__card--featured:hover {
            transform: scale(1.03) translateY(-6px);
        }
    }

    /* Clients 4 columns */
    .clients__grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 24px;
    }

    /* Process horizontal */
    .process__timeline {
        grid-template-columns: repeat(4, 1fr);
        gap: 0;
    }

    .process__connector {
        display: block;
        position: absolute;
        top: 32px;
        left: calc(50% + 38px);
        width: calc(100% - 76px);
        height: 2px;
        background: linear-gradient(90deg, #C8102E 0%, rgba(200,16,46,0.15) 100%);
    }

    .process__step:last-child .process__connector {
        display: none;
    }

    /* Footer 4 columns */
    .footer__inner {
        grid-template-columns: 1.5fr 1fr 1fr 1.2fr;
        gap: 40px;
    }
}

/* ----------------------------------------
   LARGE DESKTOP (1200px+)
   ---------------------------------------- */
@media (min-width: 1200px) {
    .container {
        padding: 0 20px;
    }

    /* Services 5 columns */
    .services__grid {
        grid-template-columns: repeat(5, 1fr);
    }

    /* Brands */
    .brands__grid {
        gap: 30px 60px;
    }

    /* Stats */
    .stats__item {
        padding: 0 50px;
    }

    /* Why Us */
    .why-us__inner {
        gap: 80px;
    }

    /* Contact */
    .contact__inner {
        gap: 80px;
    }
}

/* ----------------------------------------
   HOVER MEDIA QUERY
   ---------------------------------------- */
@media (hover: hover) {
    .service-card:hover {
        border-top-color: #C8102E;
        transform: translateY(-6px);
    }

    .client-card:hover {
        transform: translateY(-3px);
        border-left-color: #C8102E;
    }

    .process__step:hover .process__number {
        transform: scale(1.08);
    }
}

@media (pointer: coarse) {
    .custom-cursor {
        display: none !important;
    }
}

@media (max-width: 768px) {
    .preloader__track {
        width: 160px;
    }
}

/* ----------------------------------------
   REDUCED MOTION
   ---------------------------------------- */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }

    .btn--pulse,
    .hero__scroll-line {
        animation: none;
    }

    .custom-cursor {
        display: none !important;
    }
}
