/* =========================================================
   TITOFLIX - RESPONSIVE GLOBAL
   ========================================================= */

html,
body {
    max-width: 100%;
    overflow-x: hidden;
}

* {
    box-sizing: border-box;
}

img,
svg,
video {
    max-width: 100%;
}

input,
select,
textarea,
button {
    font: inherit;
}


/* =========================================================
   TABLET / NOTEBOOK PEQUEÑO
   ========================================================= */

@media (max-width: 1100px) {

    .header-main {
        gap: 16px;
        padding-left: 18px;
        padding-right: 18px;
    }

    .brand-word {
        font-size: 23px;
    }

    .header-search {
        flex: 1;
        min-width: 200px;
    }

    .category-nav {
        justify-content: flex-start;

        overflow-x: auto;
        overflow-y: hidden;

        white-space: nowrap;

        scrollbar-width: none;
    }

    .category-nav::-webkit-scrollbar {
        display: none;
    }

    .category-nav a {
        flex: 0 0 auto;
    }

    .home-hero {
        padding-left: 30px;
        padding-right: 30px;
    }

    .section-container,
    .section {
        width: calc(100% - 40px);
        max-width: 100%;

        margin-left: auto;
        margin-right: auto;
    }

}


/* =========================================================
   TABLET
   ========================================================= */

@media (max-width: 900px) {

    body {
        padding-bottom: 95px;
    }


    /* HEADER */

    .header-main {
        min-height: auto;

        display: grid;

        grid-template-columns:
            auto 1fr auto;

        align-items: center;

        gap: 12px;

        padding-top: 10px;
        padding-bottom: 10px;
    }

    .brand {
        min-width: 0;
    }

    .brand-word {
        display: none;
    }

    .brand-mark-box {
        width: 54px;
        height: 54px;
    }

    .header-search {
        width: 100%;
        min-width: 0;
    }

    .header-search input {
        min-width: 0;
    }

    .login-link {
        display: none;
    }

    .cart-label {
        display: none;
    }

    .cart-button {
        min-width: 54px;

        justify-content: center;

        padding-left: 12px;
        padding-right: 12px;
    }


    /* MENU SUPERIOR */

    .category-nav {
        justify-content: flex-start;

        overflow-x: auto;

        padding-left: 15px;
        padding-right: 15px;

        border-top:
            1px solid var(--border);

        scrollbar-width: none;
    }

    .category-nav::-webkit-scrollbar {
        display: none;
    }


    /* HOME */

    .home-hero {
        grid-template-columns: 1fr;

        gap: 25px;

        padding-top: 45px;
        padding-bottom: 45px;

        text-align: center;
    }

    .hero-copy {
        max-width: 760px;

        margin-left: auto;
        margin-right: auto;
    }

    .hero-copy p {
        margin-left: auto;
        margin-right: auto;
    }

    .hero-actions,
    .hero-points {
        justify-content: center;
    }

    .hero-brand {
        max-width: 600px;

        margin: 0 auto;
    }

    .hero-full-logo {
        max-height: 360px;

        object-fit: contain;
    }


    /* CATEGORIAS HOME */

    .home-categories {
        grid-template-columns:
            repeat(
                2,
                minmax(0, 1fr)
            );
    }


    /* PRODUCTO */

    .product-page {
        grid-template-columns: 1fr;

        gap: 28px;
    }

    .product-giftcard {
        width: 100%;
        max-width: 600px;

        margin-left: auto;
        margin-right: auto;
    }


    /* CARRITO */

    .cart-layout {
        grid-template-columns: 1fr;
    }

    .order-summary {
        position: static;

        width: 100%;
    }


    /* CHECKOUT */

    .checkout-layout {
        grid-template-columns: 1fr;
    }


    /* FOOTER */

    .footer-grid {
        grid-template-columns:
            repeat(
                2,
                minmax(0, 1fr)
            );

        gap: 30px;
    }


    .mobile-nav {
        display: grid;
    }

}


/* =========================================================
   TELEFONOS
   ========================================================= */

@media (max-width: 680px) {

    body {
        padding-bottom: 100px;
    }


    /* CONTENEDORES */

    .section-container,
    .section {
        width: calc(100% - 28px);

        margin-left: auto;
        margin-right: auto;
    }


    /* HEADER */

    .header-main {
        grid-template-columns:
            auto auto;

        grid-template-areas:
            "brand actions"
            "search search";

        gap: 10px;

        padding:
            10px 16px 12px;
    }

    .brand {
        grid-area: brand;
    }

    .header-actions {
        grid-area: actions;

        justify-self: end;
    }

    .header-search {
        grid-area: search;

        width: 100%;
        height: 48px;

        margin: 0;
    }

    .brand-mark-box {
        width: 56px;
        height: 56px;
    }

    .header-search svg {
        width: 20px;
        height: 20px;
    }

    .header-search input {
        min-width: 0;

        font-size: 14px;
    }

    .header-search input::placeholder {
        font-size: 14px;
    }

    .theme-toggle {
        display: none;
    }

    .cart-button {
        min-width: 98px;
        min-height: 56px;

        padding:
            0 14px;

        gap: 8px;

        border-radius: 12px;
    }

    .cart-button svg {
        width: 23px;
    }

    .cart-button b {
        min-width: 25px;
        height: 25px;

        font-size: 12px;
    }


    /* MENU SUPERIOR */

    .category-nav {
        display: none;
    }


    /* HOME HERO */

    .home-hero {
        padding:
            35px 16px;

        gap: 20px;
    }

    .hero-label {
        font-size: 11px;
    }

    .hero-copy h1 {
        font-size:
            clamp(
                37px,
                12vw,
                55px
            );

        line-height: .98;
    }

    .hero-copy p {
        font-size: 15px;

        line-height: 1.6;
    }

    .hero-actions {
        display: grid;

        grid-template-columns: 1fr;

        gap: 9px;
    }

    .hero-actions .button {
        width: 100%;
    }

    .hero-points {
        display: flex;

        flex-wrap: wrap;

        gap:
            8px 14px;

        font-size: 11px;
    }

    .hero-brand {
        width: 100%;
    }

    .hero-full-logo {
        width: 100%;
        max-height: 280px;

        object-fit: contain;
    }


    /* HOME CATEGORIAS */

    .home-categories {
        grid-template-columns: 1fr;

        gap: 8px;
    }

    .home-categories > a {
        min-height: 72px;
    }


    /* TITULOS */

    .section-heading-clean,
    .section-heading {
        align-items: flex-start;

        flex-direction: column;

        gap: 10px;
    }


    /* TARJETAS */

    .simple-product-grid {
        grid-template-columns:
            repeat(
                2,
                minmax(0, 1fr)
            );

        gap: 10px;
    }

    .simple-product-card {
        min-width: 0;
    }

    .simple-product-image {
        height: auto !important;

        aspect-ratio: .76;
    }

    .simple-product-info {
        padding: 11px;
    }

    .simple-product-info h3 {
        margin:
            5px 0;

        font-size: 13px;

        line-height: 1.25;
    }

    .product-category {
        font-size: 8px;
    }

    .catalog-card-description {
        display: none;
    }

    .catalog-price small {
        font-size: 9px;
    }

    .catalog-price strong {
        font-size: 11px;
    }


    /* TIENDA */

    .shop-hero {
        padding-top: 48px !important;
        padding-bottom: 28px !important;
    }

    .shop-hero h1 {
        font-size:
            clamp(
                42px,
                13vw,
                58px
            ) !important;

        line-height: 1.04;
    }

    .shop-hero > p {
        margin:
            16px auto 25px !important;

        font-size: 14px !important;
    }

    .catalog-search {
        min-height: 58px;

        margin-bottom: 20px;

        border-radius: 13px;
    }

    .catalog-search input {
        height: 56px;

        padding-left: 17px;

        font-size: 14px;
    }

    .catalog-search-submit {
        min-width: 105px;

        padding:
            0 18px;

        font-size: 13px;
    }

    .catalog-filters {
        justify-content: flex-start;

        flex-wrap: nowrap;

        overflow-x: auto;

        margin-left: -14px;
        margin-right: -14px;

        padding-left: 14px;
        padding-right: 14px;
        padding-bottom: 6px;

        scroll-padding-left: 14px;

        scrollbar-width: none;
    }

    .catalog-filters::-webkit-scrollbar {
        display: none;
    }

    .catalog-filters a {
        flex: 0 0 auto;

        min-height: 44px;

        padding:
            0 16px;

        font-size: 12px;
    }

    .catalog-category {
        margin-bottom: 38px;
    }

    .catalog-category-heading h2 {
        font-size: 22px;
    }


    /* PRODUCTO */

    .product-page {
        padding-top: 25px;

        grid-template-columns: 1fr;

        gap: 22px;
    }

    .product-giftcard {
        min-height: 0 !important;

        aspect-ratio: .78;

        padding: 10px !important;
    }

    .product-giftcard img {
        width: 100%;
        height: 100%;

        max-height: none !important;

        object-fit: contain;
    }

    .product-purchase h1 {
        font-size:
            clamp(
                34px,
                10vw,
                48px
            );

        line-height: 1;
    }

    .product-description {
        font-size: 14px;
    }

    .plan-options {
        display: grid;

        grid-template-columns: 1fr;
    }

    .plan-card {
        width: 100%;
    }

    .quantity-box {
        align-items: center;

        justify-content:
            space-between;
    }

    .purchase-button {
        width: 100%;
    }

    .purchase-benefits {
        grid-template-columns: 1fr;

        gap: 8px;
    }


    /* CARRITO */

    .cart-page {
        padding-top: 30px;
    }

    .cart-item {
        grid-template-columns:
            68px 1fr !important;

        gap: 12px;

        padding:
            14px 0;
    }

    .cart-image {
        width: 68px !important;
        height: 88px !important;
    }

    .cart-info h3 {
        margin:
            3px 0;

        font-size: 15px;
    }

    .cart-info p {
        font-size: 12px;
    }

    .cart-price {
        grid-column:
            2 !important;

        width: 100%;

        display: flex;

        align-items: center;

        justify-content:
            space-between;

        gap: 12px;

        text-align: left !important;
    }

    .order-summary {
        padding: 18px;
    }


    /* CHECKOUT */

    .checkout-page {
        padding-top: 30px;
    }

    .checkout-form-card {
        padding: 18px;
    }

    .checkout-form-card h2 {
        font-size: 20px;
    }

    .form-grid {
        grid-template-columns: 1fr;
    }

    .form-grid .wide {
        grid-column: auto;
    }

    .form-grid input {
        width: 100%;
    }

    .payment-option {
        align-items: flex-start;
    }

    .payment-option span {
        align-items: flex-start !important;

        flex-direction: column;

        gap: 3px !important;
    }

    .checkout-product {
        grid-template-columns:
            42px 1fr !important;
    }

    .checkout-product > strong {
        grid-column: 2;

        text-align: left;
    }


    /* PAGINAS INFORMATIVAS */

    .info-hero h1 {
        font-size:
            clamp(
                36px,
                11vw,
                50px
            );
    }

    .info-grid {
        grid-template-columns:
            1fr !important;
    }

    .info-card {
        padding: 19px;
    }

    .info-cta {
        display: block !important;
    }

    .info-cta .button {
        width: 100%;

        margin-top: 18px;
    }


    /* HOME BLOQUES */

    .why-cards {
        grid-template-columns: 1fr;
    }

    .help-banner {
        align-items: flex-start;

        flex-direction: column;

        gap: 20px;
    }

    .help-banner .button {
        width: 100%;
    }


    /* FOOTER */

    .site-footer {
        padding-bottom: 25px;
    }

    .footer-grid {
        grid-template-columns:
            1fr !important;

        gap: 27px;
    }

    .footer-bottom {
        align-items: flex-start;

        flex-direction: column;

        gap: 8px;
    }


    /* =====================================================
       BARRA INFERIOR
       ===================================================== */

    .mobile-nav {
        position: fixed;

        z-index: 9999;

        left: 10px;
        right: 10px;
        bottom: 10px;

        width: auto;

        min-height: 64px;

        display: grid;

        grid-template-columns:
            repeat(
                4,
                minmax(0, 1fr)
            );

        gap: 4px;

        padding: 5px;

        border:
            1px solid var(--border);

        border-radius: 18px;

        background:
            rgba(17, 17, 17, .96);

        box-shadow:
            0 10px 35px
            rgba(0, 0, 0, .35);

        backdrop-filter:
            blur(18px);

        overflow: hidden;
    }

    [data-theme="light"]
    .mobile-nav {
        background:
            rgba(245, 245, 245, .96);
    }

    .mobile-nav a,
    .mobile-nav button {
        min-width: 0;
        min-height: 54px;

        display: flex;

        align-items: center;

        justify-content: center;

        flex-direction: column;

        gap: 2px;

        padding:
            6px 3px;

        border: 0;
        border-radius: 13px;

        background:
            transparent;

        color:
            var(--muted);

        font-size: 10px;
        font-weight: 700;

        cursor: pointer;
    }

    .mobile-nav a.active {
        background:
            var(--red) !important;

        color:
            #ffffff !important;
    }

    .mobile-nav a.active
    .mobile-symbol {
        color:
            #ffffff !important;
    }

    .mobile-nav button {
        color:
            var(--muted);
    }

    .mobile-nav a:not(.active):hover,
    .mobile-nav button:hover {
        background:
            var(--surface-2);
    }

    .mobile-symbol {
        display: block;

        color: inherit;

        font-size: 11px;
        font-weight: 900;

        line-height: 1;
    }

    .theme-circle {
        width: 15px;
        height: 15px;

        border:
            2px solid currentColor;

        border-radius: 50%;
    }

}


/* =========================================================
   TELEFONOS MUY PEQUEÑOS
   ========================================================= */

@media (max-width: 400px) {

    .header-main {
        padding-left: 10px;
        padding-right: 10px;
    }

    .brand-mark-box {
        width: 52px;
        height: 52px;
    }

    .cart-button {
        min-width: 88px;
        min-height: 52px;
    }

    .simple-product-grid {
        gap: 7px;
    }

    .simple-product-info {
        padding: 9px;
    }

    .catalog-search-submit {
        min-width: 92px;

        padding:
            0 11px;
    }

    .mobile-nav {
        left: 7px;
        right: 7px;
        bottom: 7px;
    }

}


/* =========================================================
   ESCRITORIO
   ========================================================= */

@media (min-width: 901px) {

    .mobile-nav {
        display: none;
    }

}