/* ── Category Showcase Carousel ──────────────────────────────────────────── */

.cc-cat-showcase {
    position: relative;
    padding: 0 3rem;
}

/* Track wrapper: scroll-snap horizontal */
.cc-cat-showcase__wrap {
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    scrollbar-width: none;
    -ms-overflow-style: none;
    cursor: grab;
}
.cc-cat-showcase__wrap::-webkit-scrollbar { display: none; }
.cc-cat-showcase__wrap.is-dragging { cursor: grabbing; scroll-behavior: auto; }

.cc-cat-showcase__track {
    display: flex;
    gap: 1.25rem;
    padding: 0.5rem 0.25rem 1rem;
}

/* ── Tarjeta de categoría ───────────────────────────────────────────────── */
.cc-cat-card {
    flex: 0 0 clamp(200px, 22vw, 280px);
    scroll-snap-align: start;
    position: relative;
    border-radius: 14px;
    overflow: hidden;
    aspect-ratio: 1 / 1;
    box-shadow: 0 4px 20px rgba(0,0,0,0.18);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.cc-cat-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 32px rgba(0,0,0,0.28);
}

/* Fondo con imágenes que ciclan */
.cc-cat-card__bg {
    position: absolute;
    inset: 0;
    background: #1c1c1c;
}
.cc-cat-card__slide {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 1s ease;
    will-change: opacity;
}
.cc-cat-card__slide.is-active { opacity: 1; }

/* Placeholder cuando no hay imágenes */
.cc-cat-card__placeholder {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, #2a2a2a 0%, #1c1c1c 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255,255,255,0.15);
    font-size: 4rem;
}

/* Gradiente overlay */
.cc-cat-card__overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to top,
        rgba(0,0,0,0.88) 0%,
        rgba(0,0,0,0.38) 45%,
        rgba(0,0,0,0.06) 100%
    );
    pointer-events: none;
}

/* Contenido (link transparente sobre toda la tarjeta) */
.cc-cat-card__body {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 1.4rem 1.25rem;
    text-decoration: none;
    color: #fff;
}

.cc-cat-card__name {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: clamp(1.1rem, 1.6vw, 1.45rem);
    font-weight: 700;
    color: #fff;
    margin: 0 0 0.2rem;
    line-height: 1.2;
    text-shadow: 0 1px 4px rgba(0,0,0,0.5);
}
.cc-cat-card__count {
    font-size: 0.78rem;
    color: rgba(255,255,255,0.65);
    display: block;
    margin-bottom: 0.85rem;
    letter-spacing: 0.02em;
}
.cc-cat-card__cta {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.8rem;
    font-weight: 700;
    color: #E8A84A;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    transition: gap 0.25s ease;
}
.cc-cat-card:hover .cc-cat-card__cta { gap: 0.65rem; }
.cc-cat-card__cta svg { flex-shrink: 0; }

/* Indicadores de imagen (puntos debajo de cada tarjeta) */
.cc-cat-card__dots {
    position: absolute;
    bottom: 0.55rem;
    right: 0.75rem;
    display: flex;
    gap: 4px;
    pointer-events: none;
}
.cc-cat-card__dot {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: rgba(255,255,255,0.35);
    transition: background 0.3s, transform 0.3s;
}
.cc-cat-card__dot.is-active {
    background: #E8A84A;
    transform: scale(1.4);
}

/* ── Flechas de navegación ──────────────────────────────────────────────── */
.cc-cat-showcase__arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    background: rgba(255,255,255,0.96);
    border: none;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 2px 14px rgba(0,0,0,0.2);
    transition: background 0.2s, color 0.2s, transform 0.2s;
    color: #1C1C1C;
    padding: 0;
}
.cc-cat-showcase__arrow:hover {
    background: #C27B2E;
    color: #fff;
    transform: translateY(-50%) scale(1.08);
}
.cc-cat-showcase__arrow:disabled {
    opacity: 0.3;
    pointer-events: none;
}
.cc-cat-showcase__arrow--prev { left: 0; }
.cc-cat-showcase__arrow--next { right: 0; }

/* ── Responsive ─────────────────────────────────────────────────────────── */
@media (max-width: 900px) {
    .cc-cat-showcase {
        padding: 0 2.75rem;
    }
    .cc-cat-card {
        flex: 0 0 clamp(180px, 58vw, 260px);
    }
}
@media (max-width: 600px) {
    .cc-cat-showcase {
        padding: 0 2.25rem;
    }
    .cc-cat-card {
        flex: 0 0 75vw;
        max-width: 280px;
    }
    .cc-cat-showcase__arrow {
        width: 38px;
        height: 38px;
    }
}

/* Con pocas categorías (entran todas) quedan centradas; con muchas, siguen deslizándose. */
.cc-cat-showcase__track { width: max-content; min-width: 100%; box-sizing: border-box; }
.cc-cat-showcase__track > .cc-cat-card:first-child { margin-left: auto; }
.cc-cat-showcase__track > .cc-cat-card:last-child { margin-right: auto; }
