/* =========================================================
   APHAREL — HOME
   Estilos exclusivos de la página de inicio
========================================================= */


/* =========================================================
   1. HERO
========================================================= */

.apharel-hero {
    position: relative;
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    min-height: 720px;
    padding: 80px 8%;
    overflow: hidden;
    background: #f7f7f5;
}

/* Fondo fotográfico */

.apharel-hero::before {
    content: "";
    position: absolute;
    inset: -25px;
    z-index: 0;

    background:
        linear-gradient(
            90deg,
            rgba(247,247,245,.96) 0%,
            rgba(247,247,245,.78) 42%,
            rgba(247,247,245,.20) 100%
        ),
            url("../../images/home/hero-secondary.png");

    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;

    animation: apharelHeroImage 14s ease-in-out infinite alternate;

    pointer-events: none;
}

@keyframes apharelHeroImage {

    0% {
        transform: scale(1.03) translateX(0);
    }

    100% {
        transform: scale(1.07) translateX(-10px);
    }
}


/* Contenido encima del fondo */

.apharel-hero-content,
.apharel-hero-visual {
    position: relative;
    z-index: 2;
}

.apharel-hero-content {
    max-width: 620px;
}


/* =========================================================
   2. TEXTOS DEL HERO
========================================================= */

.apharel-hero-eyebrow,
.apharel-section-eyebrow {
    margin: 0 0 22px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: .28em;
    color: #777;
}

.apharel-hero-title {
    margin: 0;
    font-size: clamp(58px, 7vw, 105px);
    line-height: .92;
    font-weight: 400;
    letter-spacing: -.06em;
    color: #111;
}

.apharel-hero-title span {
    display: block;
    font-style: italic;
}

.apharel-hero-text {
    max-width: 430px;
    margin: 34px 0;
    font-size: 16px;
    line-height: 1.7;
    color: #555;
}


/* =========================================================
   3. BOTONES
========================================================= */

.apharel-hero-buttons {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.apharel-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 0 28px;

    text-decoration: none;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .16em;

    transition: .3s ease;
}

.apharel-btn-primary {
    background: #111;
    color: #fff;
}

.apharel-btn-primary:hover {
    background: #333;
    color: #fff;
}

.apharel-btn-secondary {
    border: 1px solid #111;
    color: #111;
}

.apharel-btn-secondary:hover {
    background: #111;
    color: #fff;
}

.apharel-btn-light {
    border: 1px solid #fff;
    color: #fff;
}

.apharel-btn-light:hover {
    background: #fff;
    color: #111;
}


/* =========================================================
   4. VISUAL DEL HERO
========================================================= */

.apharel-hero-visual {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 520px;

    transition: transform .4s ease;
}

.apharel-hero-circle {
    position: absolute;
    width: 420px;
    height: 420px;

    border-radius: 50%;
    background: #e6e6e1;
}

.apharel-hero-placeholder {
    position: relative;
    z-index: 2;

    display: flex;
    align-items: flex-end;
    justify-content: center;

    width: 285px;
    height: 455px;
    padding-bottom: 55px;

    background: #111;
    color: #fff;

    box-shadow: 0 30px 60px rgba(0,0,0,.12);
}

.apharel-hero-placeholder span {
    font-size: 12px;
    letter-spacing: .35em;
}


/* =========================================================
   5. ANIMACIÓN DE ENTRADA DE TEXTOS
========================================================= */

@keyframes apharelTextReveal {

    0% {
        opacity: 0;
        transform: translateY(45px);
        filter: blur(10px);
    }

    60% {
        opacity: .8;
        filter: blur(3px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
        filter: blur(0);
    }
}


/* Hero */

.apharel-hero-eyebrow {
    animation:
        apharelTextReveal .9s cubic-bezier(.16,1,.3,1)
        both;
    animation-delay: .1s;
}

.apharel-hero-title {
    animation:
        apharelTextReveal 1.1s cubic-bezier(.16,1,.3,1)
        both;
    animation-delay: .25s;
}

.apharel-hero-text {
    animation:
        apharelTextReveal .9s cubic-bezier(.16,1,.3,1)
        both;
    animation-delay: .5s;
}

.apharel-hero-buttons {
    animation:
        apharelTextReveal .9s cubic-bezier(.16,1,.3,1)
        both;
    animation-delay: .7s;
}


/* =========================================================
   6. MOVIMIENTO DE LAS LETRAS
========================================================= */

.apharel-word {
    display: inline-block;
    will-change: transform;

    animation:
        apharelWordMove 4s ease-in-out infinite;
}

@keyframes apharelWordMove {

    0%,
    100% {
        transform: translateX(0);
    }

    25% {
        transform: translateX(4px);
    }

    50% {
        transform: translateX(-4px);
    }

    75% {
        transform: translateX(2px);
    }
}

.apharel-word:nth-child(1) {
    animation-delay: 0s;
}

.apharel-word:nth-child(2) {
    animation-delay: .25s;
}

.apharel-word:nth-child(3) {
    animation-delay: .5s;
}

.apharel-word:nth-child(4) {
    animation-delay: .75s;
}


/* =========================================================
   7. ANIMACIÓN GENERAL AL HACER SCROLL
========================================================= */

.apharel-reveal {
    opacity: 0;
    transform: translateY(35px);

    transition:
        opacity .8s ease,
        transform .8s cubic-bezier(.22,1,.36,1);
}

.apharel-visible {
    opacity: 1;
    transform: translateY(0);
}


/* =========================================================
   8. TÍTULOS DE SECCIONES
========================================================= */

.apharel-section-heading {
    max-width: 700px;
    margin: 0 auto 55px;
    text-align: center;
}

.apharel-section-heading h2 {
    margin: 0;

    font-size: clamp(36px,4vw,58px);
    line-height: 1;
    font-weight: 400;
    letter-spacing: -.04em;

    color: #111;

    animation:
        apharelTextReveal 1s cubic-bezier(.16,1,.3,1)
        both;

    animation-delay: .15s;
}

.apharel-section-heading p:last-child {
    margin: 20px 0 0;

    font-size: 16px;
    line-height: 1.6;

    color: #666;

    animation:
        apharelTextReveal .9s cubic-bezier(.16,1,.3,1)
        both;

    animation-delay: .35s;
}


/* =========================================================
   9. CATEGORÍAS
========================================================= */

.apharel-categories {
    padding: 110px 6%;
    background: #fff;
}

.apharel-categories-grid {
    display: grid;
    grid-template-columns: repeat(4,1fr);
    gap: 16px;

    max-width: 1400px;
    margin: auto;
}

.apharel-category-card {
    position: relative;

    display: flex;
    align-items: flex-end;

    min-height: 500px;
    padding: 30px;

    overflow: hidden;

    background-color: #171717;
    background-position: center;
    background-size: cover;

    text-decoration: none;

    transition: transform .45s ease;
}

.apharel-category-card::after {
    content: "";

    position: absolute;
    inset: 0;

    background:
        linear-gradient(
            to top,
            rgba(0,0,0,.65),
            rgba(0,0,0,.05) 60%
        );
}

.apharel-category-card:hover {
    transform: translateY(-8px);
}

.apharel-category-overlay {
    position: absolute;
    inset: 0;

    background: rgba(0,0,0,.05);

    transition: .4s ease;
}

.apharel-category-card:hover
.apharel-category-overlay {
    background: rgba(0,0,0,.18);
}

.apharel-category-content {
    position: relative;
    z-index: 2;

    color: #fff;
}

.apharel-category-content span {
    display: block;
    margin-bottom: 10px;

    font-size: 26px;
}

.apharel-category-content small {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: .16em;
}


/* =========================================================
   10. PRODUCTOS
========================================================= */

.apharel-products {
    padding: 120px 6%;
    background: #f7f7f5;
}

.apharel-products-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 24px;

    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
}


/* TARJETA DEL PRODUCTO */

.apharel-product-card {
    display: block;

    color: #111;
    text-decoration: none;

    transition:
        transform .4s ease,
        opacity .3s ease;
}

.apharel-product-card:hover {
    transform: translateY(-6px);
}


/* IMAGEN */

.apharel-product-image {
    position: relative;

    width: 100%;
    aspect-ratio: 4 / 5;

    overflow: hidden;

    background: #e9e9e7;
}

.apharel-product-image img {
    display: block;

    width: 100%;
    height: 100%;

    object-fit: cover;

    transition: transform .6s cubic-bezier(.16,1,.3,1);
}

.apharel-product-card:hover
.apharel-product-image img {
    transform: scale(1.045);
}


/* PRODUCTO SIN IMAGEN */

.apharel-product-no-image {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 100%;
    height: 100%;

    background: #111;

    color: #fff;

    font-size: 11px;
    font-weight: 500;
    letter-spacing: .3em;
}


/* INFORMACIÓN */

.apharel-product-info {
    padding-top: 18px;
}

.apharel-product-info h3 {
    margin: 0 0 7px;

    color: #111;

    font-size: 14px;
    font-weight: 500;
    line-height: 1.4;
}

.apharel-product-price {
    color: #666;

    font-size: 14px;
    line-height: 1.4;
}


/* BOTÓN */

.apharel-products-button {
    margin-top: 60px;

    text-align: center;
}


/* SIN PRODUCTOS */

.apharel-products-empty {
    grid-column: 1 / -1;

    padding: 70px 20px;

    text-align: center;

    color: #777;
}

/* =========================================================
   11. BANNER EDITORIAL
========================================================= */

.apharel-editorial {
    position: relative;

    display: flex;
    align-items: center;

    min-height: 650px;
    padding: 100px 8%;

    overflow: hidden;

    background:
        linear-gradient(
            90deg,
            rgba(0,0,0,.82),
            rgba(0,0,0,.25)
        ),
        #171717;
}

.apharel-editorial::after {
    content: "APHAREL";

    position: absolute;
    right: -30px;
    bottom: -45px;

    font-size: clamp(120px,18vw,280px);
    font-weight: 700;

    color: rgba(255,255,255,.04);
}

.apharel-editorial-content {
    position: relative;
    z-index: 2;

    max-width: 650px;

    color: #fff;
}

.apharel-editorial .apharel-section-eyebrow {
    color: #aaa;
}

.apharel-editorial h2 {
    margin: 0;

    font-size: clamp(55px,7vw,100px);
    line-height: .92;
    font-weight: 400;
    letter-spacing: -.05em;

    animation:
        apharelTextReveal 1s cubic-bezier(.16,1,.3,1)
        both;
}

.apharel-editorial p:not(.apharel-section-eyebrow) {
    max-width: 500px;

    margin: 30px 0;

    font-size: 17px;
    line-height: 1.7;

    color: #ddd;

    animation:
        apharelTextReveal .9s cubic-bezier(.16,1,.3,1)
        both;

    animation-delay: .35s;
}

.apharel-editorial .apharel-btn {
    animation:
        apharelTextReveal .9s cubic-bezier(.16,1,.3,1)
        both;

    animation-delay: .55s;
}


/* =========================================================
   12. COLECCIONES
========================================================= */

.apharel-collections {
    padding: 110px 6%;
    background: #fff;
}

.apharel-collections-grid {
    display: grid;
    grid-template-columns: repeat(2,1fr);
    gap: 18px;

    max-width: 1400px;
    margin: auto;
}

.apharel-collection-card {
    position: relative;

    display: flex;
    align-items: flex-end;

    min-height: 500px;
    padding: 45px;

    overflow: hidden;

    background:
        linear-gradient(
            to top,
            rgba(0,0,0,.7),
            rgba(0,0,0,.05)
        ),
        #202020;

    color: #fff;
    text-decoration: none;

    transition: transform .45s ease;
}

.apharel-collection-card:hover {
    transform: translateY(-8px);
}

.apharel-collection-content {
    position: relative;
    z-index: 2;
}

.apharel-collection-content span {
    display: block;

    margin-bottom: 12px;

    font-size: 11px;
    letter-spacing: .22em;

    animation:
        apharelTextReveal .8s ease both;
}

.apharel-collection-content h3 {
    margin: 0 0 18px;

    font-size: clamp(38px,5vw,70px);
    font-weight: 400;

    animation:
        apharelTextReveal 1s cubic-bezier(.16,1,.3,1)
        both;

    animation-delay: .25s;
}

.apharel-collection-content small {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: .18em;

    animation:
        apharelTextReveal .8s ease both;

    animation-delay: .45s;
}


/* =========================================================
   13. CARRUSELES
========================================================= */

[data-apharel-carousel] {
    position: relative;
}

.apharel-carousel-track {
    display: flex;
    gap: 24px;

    overflow-x: auto;

    scroll-behavior: smooth;

    scrollbar-width: none;

    cursor: grab;
}

.apharel-carousel-track::-webkit-scrollbar {
    display: none;
}

.apharel-carousel-track.is-dragging {
    cursor: grabbing;
    scroll-behavior: auto;
}

.apharel-carousel-track > * {
    flex: 0 0 calc(25% - 18px);
}

.apharel-carousel-prev,
.apharel-carousel-next {
    position: absolute;
    top: 50%;
    z-index: 5;

    width: 46px;
    height: 46px;

    border: 1px solid #111;

    background: #fff;
    color: #111;

    cursor: pointer;

    transform: translateY(-50%);

    transition: .3s ease;
}

.apharel-carousel-prev {
    left: -20px;
}

.apharel-carousel-next {
    right: -20px;
}

.apharel-carousel-prev:hover,
.apharel-carousel-next:hover {
    background: #111;
    color: #fff;
}


/* =========================================================
   14. BANNER PRINCIPAL
========================================================= */

.apharel-main-banner {
    width: 100%;
    overflow: hidden;
    background: #111;
}

.apharel-main-banner img {
    display: block;

    width: 100%;
    height: auto;

    max-width: none;

    object-fit: cover;
}


/* =========================================================
   15. TABLET
========================================================= */

@media (max-width: 1000px) {

    .apharel-hero {
        grid-template-columns: 1fr;
        gap: 50px;
        padding: 70px 6%;
    }

    .apharel-categories-grid,
    .apharel-products-grid {
        grid-template-columns: repeat(2,1fr);
    }

    .apharel-carousel-track > * {
        flex: 0 0 calc(33.333% - 16px);
    }
}


/* =========================================================
   16. MÓVIL
========================================================= */

@media (max-width: 600px) {

    .apharel-hero {
        min-height: auto;
        padding: 60px 22px;
    }

    .apharel-hero-title {
        font-size: clamp(52px,15vw,75px);
    }

    .apharel-hero-visual {
        min-height: 380px;
    }

    .apharel-hero-circle {
        width: 290px;
        height: 290px;
    }

    .apharel-hero-placeholder {
        width: 210px;
        height: 340px;
    }

    .apharel-categories,
    .apharel-products,
    .apharel-collections {
        padding: 75px 18px;
    }

    .apharel-categories-grid,
    .apharel-collections-grid {
        grid-template-columns: 1fr;
    }

    .apharel-category-card {
        min-height: 360px;
    }

    .apharel-products-grid {
        grid-template-columns: 1fr 1fr;
        gap: 12px;
    }

    .apharel-editorial {
        min-height: 550px;
        padding: 70px 22px;
    }

    .apharel-editorial h2 {
        font-size: 55px;
    }

    .apharel-collection-card {
        min-height: 380px;
        padding: 30px;
    }

    .apharel-carousel-track {
        gap: 15px;
    }

    .apharel-carousel-track > * {
        flex: 0 0 78%;
    }

    .apharel-carousel-prev,
    .apharel-carousel-next {
        width: 40px;
        height: 40px;
    }

    .apharel-carousel-prev {
        left: 8px;
    }

    .apharel-carousel-next {
        right: 8px;
    }
}


/* =========================================================
   17. ACCESIBILIDAD
========================================================= */

@media (prefers-reduced-motion: reduce) {

    .apharel-hero::before,
    .apharel-hero-eyebrow,
    .apharel-hero-title,
    .apharel-hero-text,
    .apharel-hero-buttons,
    .apharel-section-heading h2,
    .apharel-section-heading p,
    .apharel-editorial h2,
    .apharel-editorial p,
    .apharel-editorial .apharel-btn,
    .apharel-collection-content span,
    .apharel-collection-content h3,
    .apharel-collection-content small,
    .apharel-word {
        animation: none;
    }

    .apharel-reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
}