/* ════════════════════════════════════════════════════════
   COSA TRASPORTI STRIP
   fascia orizzontale scorrevole – homepage + pagine prodotto
   ════════════════════════════════════════════════════════ */

/* ── Sezione ── */
.ct-strip {
    background: var(--color-secondary);
    padding: clamp(48px, 7vw, 96px) 0;
    overflow: hidden;
    position: relative;
    z-index: 45;
}


/* grain texture overlay */
.ct-strip::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.04'/%3E%3C/svg%3E");
    pointer-events: none;
    z-index: 0;
}

.ct-strip-inner {
    position: relative;
    z-index: 1;
}

/* ── Variante chiara (pagine prodotto su sfondo crema) ── */
.ct-strip--light {
    background: var(--color-cream);
}

.ct-strip--light::before {
    display: none;
}

/* ── Header ── */
.ct-strip-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    padding: 0 var(--layout-margin);
    margin-bottom: clamp(32px, 5vw, 56px);
    gap: 24px;
}

@media (min-width: 992px) {
    .ct-strip-header {
        padding: 0 calc(var(--layout-margin) * 2);
    }
}

.ct-strip-label {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--color-primary);
    margin-bottom: 12px;
}

.ct-strip-label::before {
    content: '';
    display: block;
    width: 28px;
    height: 2px;
    background: var(--color-primary);
    flex-shrink: 0;
}

/* H2: eredita tutti gli stili dal design system del sito */
.ct-strip-title {
    color: #fff;
    margin: 0;
}

.ct-strip--light .ct-strip-title {
    color: var(--color-secondary);
}

.ct-strip-title em {
    font-style: normal;
}

/* ── Nav buttons ── */
.ct-strip-nav {
    display: flex;
    gap: 10px;
    flex-shrink: 0;
}

.ct-nav-btn {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 1.5px solid rgba(255, 255, 255, 0.2);
    background: transparent;
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background var(--transition-base), border-color var(--transition-base), transform var(--transition-base);
    flex-shrink: 0;
}

.ct-nav-btn:hover {
    background: var(--color-primary);
    border-color: var(--color-primary);
    transform: scale(1.05);
}

.ct-nav-btn:focus-visible {
    outline: 2px solid var(--color-primary);
    outline-offset: 3px;
}

.ct-nav-btn svg {
    width: 18px;
    height: 18px;
}

.ct-strip--light .ct-nav-btn {
    border-color: rgba(38, 38, 38, 0.2);
    color: var(--color-secondary);
}

.ct-strip--light .ct-nav-btn:hover {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: #fff;
}

/* ── Track wrapper con fade laterale ── */
.ct-track-wrapper {
    position: relative;
}

.ct-track-wrapper::before,
.ct-track-wrapper::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    width: clamp(20px, 4vw, 80px);
    z-index: 2;
    pointer-events: none;
}

.ct-track-wrapper::before {
    left: 0;
    background: linear-gradient(to right, var(--color-secondary), transparent);
}

.ct-track-wrapper::after {
    right: 0;
    background: linear-gradient(to left, var(--color-secondary), transparent);
}

.ct-strip--light .ct-track-wrapper::before {
    background: linear-gradient(to right, var(--color-cream), transparent);
}

.ct-strip--light .ct-track-wrapper::after {
    background: linear-gradient(to left, var(--color-cream), transparent);
}

/* ── Track scrollabile ── */
.ct-track {
    display: flex;
    gap: 16px;
    /* mobile: padding uniforme */
    padding: 20px var(--layout-margin) 28px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    cursor: grab;
    -webkit-overflow-scrolling: touch;
    user-select: none;
    -webkit-user-select: none;
}

/* desktop: padding allineato all'header */
@media (min-width: 992px) {
    .ct-track {
        padding: 20px calc(var(--layout-margin) * 2) 68px;
    }
}

.ct-track::-webkit-scrollbar {
    display: none;
}

.ct-track.is-dragging {
    cursor: grabbing;
    scroll-snap-type: none;
}

/* mobile: scroll fluido senza snap */
@media (max-width: 768px) {
    .ct-track {
        scroll-snap-type: none;
        -webkit-overflow-scrolling: touch;
        scroll-behavior: smooth;
    }
}

/* ── Card ── */
.ct-card {
    flex: 0 0 clamp(240px, 26vw, 340px);
    scroll-snap-align: start;
    border-radius: 20px;
    overflow: visible; /* visible per far uscire l'ombra */
    position: relative;
    aspect-ratio: 3 / 4;
    display: block;
    text-decoration: none;
    transition: transform 500ms cubic-bezier(0.4, 0, 0.2, 1),
                box-shadow 500ms cubic-bezier(0.4, 0, 0.2, 1);
    will-change: transform;
    box-shadow:
        0 4px 12px rgba(0, 0, 0, 0.5),
        0 16px 40px rgba(0, 0, 0, 0.45),
        0 32px 64px rgba(0, 0, 0, 0.3);
}

/* wrapper interno: clippa immagine e overlay dentro il border-radius */
.ct-card-inner {
    position: absolute;
    inset: 0;
    border-radius: 20px;
    overflow: hidden;
    background: #1a1a1a;
}

.ct-card:hover {
    transform: translateY(-8px) scale(1.015);
    box-shadow:
        0 8px 20px rgba(0, 0, 0, 0.6),
        0 24px 56px rgba(0, 0, 0, 0.5),
        0 48px 80px rgba(0, 0, 0, 0.35);
}

.ct-card:focus-visible {
    outline: 2px solid var(--color-primary);
    outline-offset: 4px;
}

/* immagine */
.ct-card-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 500ms cubic-bezier(0.4, 0, 0.2, 1);
    display: block;
}

.ct-card:hover .ct-card-image {
    transform: scale(1.06);
}

/* overlay gradiente */
.ct-card-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0) 30%,
        rgba(15, 5, 5, 0.5) 60%,
        rgba(15, 5, 5, 0.92) 100%
    );
    transition: opacity var(--transition-base);
}

/* numero (top-right) */
.ct-card-number {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 2;
    font-size: 11px;
    font-weight: 800;
    color: rgba(255, 255, 255, 0.3);
    letter-spacing: 1px;
    font-variant-numeric: tabular-nums;
    line-height: 1;
}

/* info in basso */
.ct-card-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 2;
    padding: 18px 18px 22px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.ct-card-title {
    font-size: clamp(0.875rem, 1.3vw, 1.05rem);
    font-weight: 800;
    text-transform: uppercase;
    color: #fff;
    line-height: 1.2;
    letter-spacing: -0.01em;
    margin: 0;
}

.ct-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

/* tag prodotto */
.ct-card-product {
    display: inline-block;
    background: var(--color-primary);
    color: #fff;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    padding: 5px 10px;
    border-radius: var(--radius-sm, 4px);
    line-height: 1;
    transition: background var(--transition-base);
    flex-shrink: 0;
    max-width: 68%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.ct-card:hover .ct-card-product {
    background: var(--color-primary-dark);
}

/* freccia */
.ct-card-arrow {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    border: 1.5px solid rgba(255, 255, 255, 0.28);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: rgba(255, 255, 255, 0.55);
    transition: border-color var(--transition-base), color var(--transition-base),
                transform var(--transition-base), background var(--transition-base);
}

.ct-card:hover .ct-card-arrow {
    border-color: #fff;
    color: #fff;
    transform: rotate(45deg);
    background: rgba(255, 255, 255, 0.08);
}

.ct-card-arrow svg {
    width: 13px;
    height: 13px;
}

/* ── Progress bar ── */
.ct-progress {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 24px var(--layout-margin) 0;
}

@media (min-width: 992px) {
    .ct-progress {
        padding: 24px calc(var(--layout-margin) * 2) 0;
    }
}

.ct-progress-bar {
    width: 180px;
    height: 2px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    overflow: hidden;
    flex-shrink: 0;
}

.ct-strip--light .ct-progress-bar {
    background: rgba(38, 38, 38, 0.1);
}

.ct-progress-fill {
    height: 100%;
    background: var(--color-primary);
    border-radius: 2px;
    transition: width 400ms cubic-bezier(0.4, 0, 0.2, 1);
    width: 0%;
}

.ct-progress-count {
    font-size: 12px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.32);
    letter-spacing: 1px;
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

.ct-strip--light .ct-progress-count {
    color: rgba(38, 38, 38, 0.38);
}

/* ── Sottotitolo ── */
.ct-strip-subtitle {
    margin-top: 12px;
    color: rgba(255, 255, 255, 0.55);
    max-width: 560px;
    line-height: 1.6;
}

.ct-strip--light .ct-strip-subtitle {
    color: rgba(38, 38, 38, 0.6);
}

/* ── CTA ── */
.ct-strip-cta {
    margin-top: 36px;
    padding: 0 var(--layout-margin);
}

@media (min-width: 992px) {
    .ct-strip-cta {
        padding: 0 calc(var(--layout-margin) * 2);
    }
}

/* ── Responsive ── */
@media (max-width: 768px) {
    .ct-strip-nav {
        display: none;
    }

    .ct-strip-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .ct-card {
        flex: 0 0 72vw;
    }
}

@media (max-width: 480px) {
    .ct-card {
        flex: 0 0 82vw;
    }
}