/* =========================================================
   KEY! | RESPONSIVE.CSS
   Adaptación para laptop, tablet y celular
========================================================= */


/* =========================================================
   1. PANTALLAS GRANDES Y LAPTOPS
   1440px o menos
========================================================= */

@media (max-width: 1440px) {
    :root {
        --container-width: 1160px;
    }

    .hero__title {
        font-size: clamp(3.6rem, 7vw, 6.6rem);
    }

    .hero__character {
        min-height: 570px;
    }

    .hero__character-image {
        max-height: 76vh;
    }

    .expedition-progress {
        right: 0.7rem;
    }

    .expedition-progress__label {
        display: none;
    }

    .mission-panel__scene {
        min-height: 500px;
    }
}


/* =========================================================
   2. LAPTOPS MEDIANAS
   1240px o menos
========================================================= */

@media (max-width: 1240px) {
    :root {
        --header-height: 76px;
    }

    .container {
        width: min(calc(100% - 3rem), 1080px);
    }

    .site-header__container {
        width: calc(100% - 2rem);
    }

    .main-navigation__list {
        gap: 0.85rem;
    }

    .main-navigation__link {
        font-size: 0.9rem;
    }

    .sound-toggle__text {
        display: none;
    }

    .hero__container {
        grid-template-columns: 1fr 0.85fr;
    }

    .hero__character {
        min-height: 530px;
    }

    .hero-equipment--shirt {
        left: 0;
    }

    .hero-equipment--cup {
        right: 0;
    }

    .mission-panel {
        gap: 1.4rem;
    }

    .services-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .service-card,
    .service-card--featured {
        grid-column: auto;
    }

    .customizer-app {
        grid-template-columns: 340px 1fr;
    }

    .process-step {
        padding: 1.15rem;
    }

    .projects-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .project-card,
    .project-card--large,
    .project-card--wide {
        grid-column: auto;
        grid-row: auto;
    }

    .project-card--large .project-card__button {
        min-height: 500px;
    }

    .project-card__button {
        min-height: 360px;
    }

    .testimonial-slider__track {
        grid-template-columns: repeat(3, minmax(280px, 1fr));
    }
}


/* =========================================================
   3. TABLETS HORIZONTALES / LAPTOP PEQUEÑA
   1080px o menos
========================================================= */

@media (max-width: 1080px) {
    .section {
        padding: 5.2rem 0;
    }

    .main-navigation {
        display: none;
    }

    .menu-toggle {
        display: inline-flex;
    }

    .site-header__actions > .button {
        display: inline-flex;
    }

    .expedition-progress {
        display: none;
    }

    .hero {
        min-height: auto;
        padding-top: 3rem;
        padding-bottom: 6rem;
    }

    .hero__container {
        grid-template-columns: 1fr 0.8fr;
        gap: 1.5rem;
    }

    .hero-interface {
        left: 2rem;
    }

    .hero__title {
        font-size: clamp(3.5rem, 7vw, 5.8rem);
    }

    .hero__character {
        min-height: 500px;
    }

    .hero__character-card {
        left: -1rem;
        bottom: 12%;
    }

    .hero-equipment {
        font-size: 0.84rem;
    }

    .section-heading__split {
        grid-template-columns: 1fr;
        align-items: start;
    }

    .section-heading__description {
        max-width: 620px;
    }

    .section-heading:not(.section-heading--center)
    .section-heading__description {
        margin-inline: 0;
    }

    .mission-panel {
        grid-template-columns: 1fr 0.85fr;
    }

    .mission-panel__scene {
        min-height: 470px;
    }

    .benefits__container {
        gap: 1.5rem;
    }

    .benefits__image {
        min-height: 560px;
    }

    .customizer-app {
        grid-template-columns: 1fr;
    }

    .customizer-controls {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 1.25rem;
    }

    .customizer-controls__header {
        grid-column: 1 / -1;
    }

    .customizer-step + .customizer-step {
        margin-top: 0;
        padding-top: 0;
        border-top: 0;
    }

    .customizer-step {
        padding: 1.1rem;
        border-radius: var(--radius-lg);
        background: rgba(255, 255, 255, 0.025);
        border: 1px solid var(--color-border);
    }

    .process-timeline {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 1.5rem;
    }

    .process-timeline__path {
        display: none;
    }

    .comparison__container {
        grid-template-columns: 0.8fr 1.2fr;
    }

    .quote__container {
        grid-template-columns: 0.75fr 1.25fr;
    }

    .quote__character img {
        max-width: 290px;
    }

    .contact__container {
        grid-template-columns: 0.9fr 1.1fr;
    }

    .site-footer__top {
        grid-template-columns: 0.8fr 1.2fr;
    }
}


/* =========================================================
   4. TABLETS VERTICALES
   920px o menos
========================================================= */

@media (max-width: 920px) {
    .container {
        width: min(calc(100% - 2.4rem), 780px);
    }

    .site-header {
        padding: 0.7rem 0;
    }

    .site-header__container {
        min-height: 68px;
    }

    .hero {
        padding-top: 2rem;
    }

    .hero__container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero__content {
        max-width: 720px;
        margin-inline: auto;
        position: relative;
        z-index: 5;
    }

    .hero__description {
        margin-inline: auto;
    }

    .hero__actions {
        justify-content: center;
    }

    .hero__trust {
        margin-inline: auto;
    }

    .hero__character {
        min-height: 540px;
        width: min(100%, 650px);
        margin-inline: auto;
    }

    .hero__character-image {
        max-height: 580px;
    }

    .hero__character-card {
        left: 4%;
        bottom: 12%;
        text-align: left;
    }

    .hero-equipment--shirt {
        top: 17%;
        left: 4%;
    }

    .hero-equipment--cup {
        top: 24%;
        right: 3%;
    }

    .hero-equipment--badge {
        right: 6%;
        bottom: 13%;
    }

    .hero-interface {
        display: none;
    }

    .scroll-indicator {
        bottom: 1rem;
    }

    .mission-selector__tabs {
        justify-content: flex-start;
        flex-wrap: nowrap;
        overflow-x: auto;
        padding: 0 0 0.8rem;
        scroll-snap-type: x mandatory;
        scrollbar-width: thin;
    }

    .mission-tab {
        flex: 0 0 auto;
        scroll-snap-align: start;
    }

    .mission-panel {
        grid-template-columns: 1fr;
    }

    .mission-panel__visual {
        order: 1;
    }

    .mission-panel__information {
        order: 2;
        padding: 1rem 0.5rem 0.5rem;
    }

    .mission-panel__scene {
        min-height: 560px;
    }

    .services-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .benefits__container,
    .comparison__container,
    .faq__container,
    .quote__container,
    .contact__container {
        grid-template-columns: 1fr;
    }

    .benefits__visual {
        order: 2;
    }

    .benefits__content {
        order: 1;
    }

    .benefits__image {
        min-height: 520px;
    }

    .comparison__content {
        max-width: 650px;
    }

    .comparison-slider {
        min-height: 520px;
    }

    .quote__introduction {
        display: grid;
        grid-template-columns: 1fr auto;
        column-gap: 1.5rem;
        align-items: end;
    }

    .quote__introduction .eyebrow,
    .quote__title,
    .quote__description {
        grid-column: 1;
    }

    .quote__character {
        grid-column: 2;
        grid-row: 1 / span 3;
        align-self: end;
        margin-top: 0;
    }

    .quote__character img {
        max-width: 250px;
    }

    .contact__content {
        max-width: 680px;
    }

    .site-footer__top {
        grid-template-columns: 1fr;
    }

    .site-footer__brand {
        max-width: 580px;
    }
}


/* =========================================================
   5. CELULARES GRANDES Y TABLETS PEQUEÑAS
   740px o menos
========================================================= */

@media (max-width: 740px) {
    :root {
        --radius-xl: 26px;
        --radius-lg: 20px;
        --radius-md: 15px;
    }

    .section {
        padding: 4.3rem 0;
    }

    .container {
        width: min(calc(100% - 2rem), 640px);
    }

    .site-header__container {
        width: calc(100% - 1.2rem);
        padding: 0 0.8rem;
    }

    .site-header__logo-image {
        width: 82px;
    }

    .sound-toggle {
        display: none;
    }

    .site-header__actions > .button {
        min-height: 42px;
        padding: 0.75rem 1rem;
        font-size: 0.88rem;
    }

    .hero {
        padding-top: 1.7rem;
        padding-bottom: 5rem;
    }

    .hero__title {
        font-size: clamp(3.5rem, 15vw, 5.5rem);
        line-height: 0.86;
    }

    .hero__description {
        font-size: 1rem;
    }

    .hero__actions {
        width: 100%;
    }

    .hero__actions .button {
        flex: 1 1 240px;
    }

    .hero__trust {
        width: min(100%, 500px);
        justify-content: center;
        border-radius: var(--radius-lg);
    }

    .hero__character {
        min-height: 480px;
    }

    .hero__character-image {
        max-height: 500px;
    }

    .hero__character-ring {
        width: min(82%, 450px);
    }

    .hero__character-card {
        width: 200px;
        left: 0;
        bottom: 9%;
    }

    .hero-equipment {
        padding: 0.65rem 0.8rem;
    }

    .hero-equipment--cup {
        right: 0;
    }

    .scroll-indicator__text {
        display: none;
    }

    .mission-ticker__group {
        font-size: 0.88rem;
    }

    .section-heading {
        margin-bottom: 2.2rem;
    }

    .section-heading__title {
        font-size: clamp(2.4rem, 10vw, 4rem);
    }

    .eyebrow__line {
        width: 36px;
    }

    .mission-tab {
        padding: 0.75rem 0.9rem;
    }

    .mission-tab__icon {
        width: 34px;
        height: 34px;
    }

    .mission-panel {
        padding: 1rem;
    }

    .mission-panel__scene {
        min-height: 500px;
    }

    .mission-panel__visual-label {
        align-items: flex-start;
        flex-direction: column;
        gap: 0.3rem;
    }

    .services-grid {
        grid-template-columns: 1fr;
    }

    .service-card,
    .service-card--featured {
        min-height: 410px;
    }

    .benefits__image {
        min-height: 480px;
    }

    .customizer-controls {
        grid-template-columns: 1fr;
    }

    .customizer-controls__header {
        grid-column: auto;
    }

    .customizer-canvas {
        min-height: 520px;
    }

    .product-mockup {
        width: min(100%, 430px);
    }

    .process-timeline {
        grid-template-columns: 1fr;
    }

    .process-step {
        padding: 1.25rem;
    }

    .comparison-slider {
        min-height: 460px;
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }

    .project-card__button,
    .project-card--large .project-card__button {
        min-height: 420px;
    }

    .testimonial-slider__viewport {
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        scrollbar-width: thin;
    }

    .testimonial-slider__track {
        display: flex;
        width: max-content;
    }

    .testimonial-card {
        width: min(82vw, 360px);
        flex: 0 0 auto;
        scroll-snap-align: center;
    }

    .quote__introduction {
        display: block;
    }

    .quote__character {
        margin: 1.3rem auto 0;
    }

    .quote__character img {
        max-width: 260px;
        margin-inline: auto;
    }

    .form-choice-grid,
    .form-grid {
        grid-template-columns: 1fr;
    }

    .form-field--full {
        grid-column: auto;
    }

    .contact__map {
        min-height: 340px;
    }

    .site-footer__navigation {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .site-footer__column:last-child {
        grid-column: 1 / -1;
    }

    .modal {
        padding: 1rem 0.7rem;
        align-items: start;
    }

    .modal__dialog,
    .modal__dialog--large {
        grid-template-columns: 1fr;
        width: 100%;
        margin-block: 1rem;
    }

    .modal__media {
        min-height: 360px;
    }

    .modal__content,
    .project-modal__content {
        padding: 1.4rem;
    }

    .project-modal__gallery {
        padding: 0.8rem;
    }

    .project-modal__main-image img {
        height: 380px;
    }

    .floating-whatsapp {
        width: 58px;
        height: 58px;
        padding: 0;
        justify-content: center;
        border-radius: 50%;
    }

    .floating-whatsapp__label {
        display: none;
    }
}


/* =========================================================
   6. CELULARES MEDIANOS
   560px o menos
========================================================= */

@media (max-width: 560px) {
    .container {
        width: min(calc(100% - 1.4rem), 520px);
    }

    .site-header__actions > .button {
        display: none;
    }

    .site-header__container {
        min-height: 62px;
    }

    .hero__title {
        font-size: clamp(3.1rem, 13vw, 4.5rem);
    }

    .hero__description {
        line-height: 1.65;
    }

    .hero__actions {
        display: grid;
        grid-template-columns: 1fr;
    }

    .hero__actions .button {
        width: 100%;
    }

    .hero__trust {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 0.55rem;
        padding: 0.85rem;
    }

    .hero__trust-divider {
        display: none;
    }

    .hero__trust-item strong {
        font-size: 1.15rem;
    }

    .hero__trust-item span {
        font-size: 0.68rem;
    }

    .hero__character {
        min-height: 420px;
    }

    .hero__character-image {
        max-height: 440px;
    }

    .hero-equipment {
        font-size: 0;
        width: 44px;
        height: 44px;
        padding: 0;
        justify-content: center;
        border-radius: 50%;
    }

    .hero-equipment i {
        font-size: 1rem;
    }

    .hero__character-card {
        width: 175px;
        padding: 0.8rem;
    }

    .hero__character-card strong {
        font-size: 1.2rem;
    }

    .mission-panel__scene {
        min-height: 430px;
    }

    .mission-panel__information h3 {
        font-size: 2.3rem;
    }

    .mission-panel__equipment li {
        padding: 0.8rem;
    }

    .service-card {
        min-height: 380px;
    }

    .benefits__image {
        min-height: 420px;
    }

    .benefit-item {
        grid-template-columns: 1fr;
    }

    .customizer-controls,
    .customizer-preview {
        padding: 1rem;
    }

    .product-options {
        grid-template-columns: repeat(2, 1fr);
    }

    .customizer-preview__header {
        align-items: flex-start;
        flex-direction: column;
    }

    .view-selector {
        width: 100%;
    }

    .view-selector__button {
        flex: 1;
    }

    .customizer-canvas {
        min-height: 440px;
    }

    .product-mockup {
        width: 100%;
    }

    .product-mockup__print-area {
        width: 36%;
    }

    .customizer-position-actions {
        grid-template-columns: repeat(5, 1fr);
    }

    .customizer-position-actions .icon-button {
        width: 100%;
        max-width: none;
    }

    .customizer-preview__footer {
        display: grid;
        grid-template-columns: 1fr;
    }

    .customizer-preview__footer .button {
        width: 100%;
    }

    .comparison-slider {
        min-height: 400px;
    }

    .project-card__button,
    .project-card--large .project-card__button {
        min-height: 360px;
    }

    .project-card__information {
        align-items: flex-start;
        flex-direction: column;
    }

    .project-card__information h3 {
        font-size: 1.55rem;
    }

    .faq-item__question {
        padding: 1rem;
    }

    .quote-form-wrapper {
        padding: 1rem;
    }

    .quote-form__progress {
        gap: 0.35rem;
    }

    .quote-form__progress-step {
        font-size: 0.72rem;
    }

    .quote-form__progress-step span {
        width: 32px;
        height: 32px;
    }

    .quote-form__step-heading h3 {
        font-size: 1.7rem;
    }

    .quote-form__actions {
        display: grid;
        grid-template-columns: 1fr;
    }

    .quote-form__actions .button {
        width: 100%;
    }

    .quote-form__actions .button--ghost {
        order: 2;
    }

    .quote-form__actions .button--primary {
        order: 1;
    }

    .contact-method {
        align-items: flex-start;
    }

    .contact-method__arrow {
        display: none;
    }

    .contact__map-header,
    .contact__map-footer {
        flex-direction: column;
    }

    .site-footer__navigation {
        grid-template-columns: 1fr;
    }

    .site-footer__column:last-child {
        grid-column: auto;
    }

    .site-footer__bottom {
        flex-direction: column;
        align-items: flex-start;
    }

    .project-modal__main-image img {
        height: 300px;
    }

    .project-modal__data div {
        align-items: flex-start;
        flex-direction: column;
        gap: 0.2rem;
    }
}


/* =========================================================
   7. CELULARES PEQUEÑOS
   400px o menos
========================================================= */

@media (max-width: 400px) {
    .section {
        padding: 3.7rem 0;
    }

    .site-header__logo-image {
        width: 74px;
    }

    .menu-toggle {
        min-width: 40px;
        min-height: 40px;
    }

    .mobile-menu {
        width: 94vw;
    }

    .hero__title {
        font-size: clamp(2.4rem, 13vw, 3.1rem);
    }

    .hero__character {
        min-height: 370px;
    }

    .hero__character-image {
        max-height: 390px;
    }

    .hero__character-card {
        bottom: 4%;
        left: 0;
    }

    .hero-equipment--shirt {
        left: 0;
    }

    .hero-equipment--cup {
        right: 0;
    }

    .hero-equipment--badge {
        bottom: 10%;
        right: 0;
    }

    .eyebrow {
        gap: 0.5rem;
    }

    .eyebrow__line {
        width: 24px;
    }

    .eyebrow__text {
        font-size: 0.78rem;
    }

    .mission-panel__scene {
        min-height: 370px;
    }

    .product-options {
        grid-template-columns: 1fr;
    }

    .customizer-canvas {
        min-height: 370px;
    }

    .comparison-slider {
        min-height: 350px;
    }

    .project-card__button,
    .project-card--large .project-card__button {
        min-height: 320px;
    }

    .testimonial-card {
        width: 86vw;
    }

    .preloader__content {
        padding: 1.3rem 1rem;
    }

    .preloader__message {
        font-size: 0.78rem;
    }

    .toast-container {
        left: 0.7rem;
        right: 0.7rem;
        top: 0.7rem;
    }

    .toast {
        width: 100%;
    }
}


/* =========================================================
   8. PANTALLAS BAJAS EN MODO HORIZONTAL
========================================================= */

@media (max-height: 700px) and (orientation: landscape) {
    .hero {
        min-height: 720px;
    }

    .hero__character {
        min-height: 470px;
    }

    .hero__character-image {
        max-height: 500px;
    }

    .scroll-indicator {
        display: none;
    }

    .modal {
        place-items: start center;
    }
}


/* =========================================================
   9. DISPOSITIVOS TÁCTILES
========================================================= */

@media (hover: none), (pointer: coarse) {
    .custom-cursor {
        display: none !important;
    }

    .global-effects__cursor-glow {
        display: none;
    }

    .button:hover,
    .service-card:hover,
    .project-card__button:hover,
    .contact-method:hover,
    .mission-tab:hover,
    .icon-button:hover,
    .slider-button:hover {
        transform: none;
    }

    .mission-tab,
    .button,
    .project-filter,
    .view-selector__button {
        -webkit-tap-highlight-color: transparent;
    }
}


/* =========================================================
   10. ACCESIBILIDAD: MENOS MOVIMIENTO
========================================================= */

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
    }

    .mission-ticker__track {
        animation: none;
    }

    .global-effects__cursor-glow,
    .custom-cursor {
        display: none;
    }
}


/* =========================================================
   11. ÁREAS SEGURAS EN CELULARES
========================================================= */

@supports (padding: max(0px)) {
    .site-header {
        padding-top:
            max(
                0.7rem,
                env(safe-area-inset-top)
            );
    }

    .floating-whatsapp {
        right:
            max(
                1rem,
                env(safe-area-inset-right)
            );

        bottom:
            max(
                1rem,
                env(safe-area-inset-bottom)
            );
    }

    .mobile-menu__content {
        padding-top:
            max(
                1.35rem,
                env(safe-area-inset-top)
            );

        padding-bottom:
            max(
                1.5rem,
                env(safe-area-inset-bottom)
            );
    }
}