/* ==========================================================================
   LODO SPORT — homepage
   hero · nuova collezione · marche · discipline · valori · manifesto · dove siamo
   ========================================================================== */

/* ---------- HERO ---------- */
.hero {
  position: relative; isolation: isolate; overflow: hidden;
  min-height: clamp(660px, calc(100vh - var(--bar-h) - 56px), 900px);
  background: linear-gradient(160deg, var(--c-hero-a), var(--c-hero-b));
}
.hero__media { position: absolute; inset: 0; z-index: -3; }
.hero__slide { position: absolute; inset: 0; opacity: 0; transition: opacity 1.4s var(--ease); }
.hero__slide.is-active { opacity: 1; }
.hero__slide > img { transform: scale(1.08); transition: transform 9s linear, filter .8s; }
.hero__slide.is-active > img { transform: scale(1); }
.hero__media::after {
  content: ""; position: absolute; inset: 0; z-index: 2; pointer-events: none;
  background:
    linear-gradient(90deg, color-mix(in srgb, var(--c-hero-b) 90%, transparent) 0%, color-mix(in srgb, var(--c-hero-b) 58%, transparent) 30%, transparent 60%),
    linear-gradient(0deg, color-mix(in srgb, var(--c-hero-b) 62%, transparent) 0%, transparent 38%),
    linear-gradient(180deg, color-mix(in srgb, var(--c-hero-b) 55%, transparent) 0%, transparent 22%);
}
.hero__tag {
  position: absolute; z-index: -2; left: 24%; top: 4%; width: 64%;
  color: #fff; opacity: .34; mix-blend-mode: screen; filter: blur(2.5px);
  pointer-events: none;
}
.hero__tag .graffiti { position: relative; width: 100%; height: auto; }

.hero__inner {
  position: relative; min-height: inherit;
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(280px, .58fr); gap: 32px;
  padding: calc(var(--header-h) + clamp(34px, 6vh, 80px)) var(--gutter) clamp(28px, 4.5vh, 48px);
}
.hero__copy { align-self: center; max-width: 600px; }
.hero__kicker { display: flex; flex-wrap: wrap; gap: 12px; color: var(--c-muted); margin-bottom: 22px; }
.hero__title { display: grid; text-shadow: 0 2px 30px rgb(0 0 0 / .12); }
.hero__product { margin-top: 18px; color: var(--c-muted); }
.hero__product a { color: var(--c-text); border-bottom: 1px solid var(--c-line); transition: border-color .3s; }
.hero__product a:hover { border-color: var(--c-text); }
.hero__opts { margin-top: 34px; display: grid; gap: 14px; }
.opt { display: grid; grid-template-columns: 108px 1fr; align-items: baseline; }
.opt dt { color: var(--c-muted); }
.opt dd { display: flex; flex-wrap: wrap; gap: 6px 28px; }
.opt__btn {
  padding: 3px 0; color: var(--c-muted);
  font: 400 11px/1.4 var(--f-mono); letter-spacing: .06em; text-transform: uppercase;
  border-bottom: 1px solid transparent; transition: color .25s, border-color .25s;
}
.opt__btn:hover { color: var(--c-text); }
.opt__btn[aria-pressed="true"] { color: var(--c-text); border-bottom-color: currentColor; }
.hero__buy { margin-top: 40px; }

.hero__anim > * { animation: rise .9s var(--ease) both; }
.hero__anim > *:nth-child(2) { animation-delay: .06s; }
.hero__anim > *:nth-child(3) { animation-delay: .12s; }
.hero__anim > *:nth-child(4) { animation-delay: .18s; }
.hero__anim > *:nth-child(5) { animation-delay: .24s; }
@keyframes rise { from { opacity: 0; transform: translateY(22px); } }

.hero__side { display: grid; grid-template-rows: 1fr auto 1fr; justify-items: end; align-items: center; gap: 22px; }
.hero__thumbs { grid-row: 2; display: flex; gap: 14px; margin-right: calc(var(--gutter) * -1 - 70px); }
.hthumb {
  position: relative; --cut: 14px; flex: none;
  width: clamp(130px, 11.5vw, 178px); aspect-ratio: 3 / 4;
  opacity: .9; transition: transform .6s var(--ease), opacity .4s;
}
.hthumb > img { position: absolute; inset: 0; }
.hthumb:hover, .hthumb:focus-visible { transform: translateY(-6px); opacity: 1; }
.hthumb__num { position: absolute; z-index: 2; left: 12px; bottom: 10px; color: #fff; }
.hero__counter { grid-row: 3; align-self: start; display: flex; align-items: center; gap: 14px; color: var(--c-muted); }
.hero__counter button { width: 26px; height: 26px; display: grid; place-items: center; color: var(--c-muted); transition: color .25s; }
.hero__counter button:hover { color: var(--c-text); }
.hero__counter button svg { width: 14px; height: 14px; }
.hero__counter [data-step="-1"] svg { transform: rotate(180deg); }
.hero__bar { position: relative; flex: 0 1 120px; width: 120px; min-width: 32px; height: 1px; background: var(--c-line); overflow: hidden; }
.hero__bar i { position: absolute; inset: 0; background: var(--c-text); transform-origin: left; transform: scaleX(0); }
.hero__bar i.is-run { animation: progress var(--dur, 7s) linear forwards; }
.hero.is-paused .hero__bar i { animation-play-state: paused; }
@keyframes progress { to { transform: scaleX(1); } }
.hero__social { grid-row: 3; align-self: end; display: flex; gap: 8px; }
.hero__social .icon-btn { width: 26px; height: 26px; border-radius: 5px; }
.hero__social .icon-btn svg { width: 14px; height: 14px; }

/* spazio per l'avviso anteprima fisso in basso a destra */
html.has-preview .hero__social { margin-bottom: 64px; }

/* tablet orizzontale / iPad Pro verticale: colonna laterale stretta, contatore e contatti non si sovrappongono */
@media (min-width: 861px) and (max-width: 1100px) {
  .hero__side { grid-template-columns: minmax(0, 1fr) auto; column-gap: 18px; }
  .hero__counter { min-width: 0; gap: 10px; }
}

@media (max-width: 860px) {
  html.has-preview .hero__inner { padding-bottom: 76px; }
  html.has-preview .hero__social { margin-bottom: 0; }
  .hero { min-height: calc(100svh - var(--bar-h)); }
  .hero__media::after {
    background:
      linear-gradient(0deg, var(--c-hero-b) 0%, color-mix(in srgb, var(--c-hero-b) 70%, transparent) 42%, transparent 72%),
      linear-gradient(180deg, color-mix(in srgb, var(--c-hero-b) 60%, transparent) 0%, transparent 25%);
  }
  .hero__tag { left: -6%; width: 112%; top: 14%; }
  .hero__inner { grid-template-columns: minmax(0, 1fr); grid-template-rows: 1fr auto; gap: 26px; padding-top: calc(var(--header-h) + 24px); }
  .hero__copy { align-self: end; }
  .hero__opts { margin-top: 24px; }
  .hero__buy { margin-top: 28px; --buy-size: 74px; }
  .hero__side { grid-template-rows: auto; grid-template-columns: minmax(0, 1fr) auto; justify-items: start; gap: 16px; }
  .hero__thumbs { display: none; }
  .hero__counter, .hero__social { grid-row: 1; align-self: center; }
  .hero__counter { min-width: 0; max-width: 100%; gap: 8px; }
  .hero__social { justify-self: end; }
  /* aree di tocco più ampie su touch */
  .hero__counter button { width: 36px; height: 36px; }
  .hero__social .icon-btn { width: 36px; height: 36px; border-radius: var(--radius); }
  .hero__social .icon-btn svg { width: 16px; height: 16px; }
  .opt dd { gap: 4px 22px; }
  .opt__btn { padding: 8px 0 5px; }
}
@media (max-width: 400px) {
  .opt { grid-template-columns: 84px 1fr; }
  .opt dd { gap: 4px 18px; }
}
/* telefono in orizzontale: hero compatta, il titolo resta nel primo schermo */
@media (max-height: 520px) and (orientation: landscape) and (max-width: 1100px) {
  .hero { min-height: 0; }
  .hero__inner { padding-top: calc(var(--header-h) + 18px); gap: 18px; }
  .hero__kicker { margin-bottom: 14px; }
  .hero__title { font-size: clamp(38px, 5.4vw, 56px); }
  .hero__opts { margin-top: 18px; gap: 8px; }
  .hero__buy { margin-top: 20px; --buy-size: 64px; }
}

/* ---------- NUOVA COLLEZIONE ---------- */
.collection { padding: clamp(48px, 6vw, 84px) var(--gutter) clamp(56px, 7vw, 100px); background: var(--c-panel); transition: background-color .8s var(--ease); }
.cgrid {
  --cols: 5; --gap-x: clamp(12px, 1.4vw, 20px);
  container-type: inline-size;
  display: grid; grid-template-columns: repeat(var(--cols), minmax(0, 1fr));
  gap: clamp(30px, 3.2vw, 46px) var(--gap-x);
}
.feature {
  --cut: 18px;
  grid-column: span 2; position: relative; overflow: hidden; isolation: isolate;
  height: calc((100cqw - (var(--cols) - 1) * var(--gap-x)) / var(--cols) * 1.25);
  background: var(--c-hero-b); color: var(--c-text);
}
.feature__media { position: absolute; inset: 0; z-index: -2; }
.feature__media > img { transition: transform 1.2s var(--ease); }
.feature:hover .feature__media > img { transform: scale(1.04); }
.feature__media::before {
  content: ""; position: absolute; inset: 0; z-index: 2;
  background: linear-gradient(270deg, color-mix(in srgb, var(--c-hero-b) 94%, transparent) 0%, color-mix(in srgb, var(--c-hero-b) 72%, transparent) 38%, transparent 78%);
}
.feature__tag { position: absolute; z-index: -1; right: -4%; bottom: -17%; width: 56%; color: #fff; transform: rotate(-3deg); }
.feature__tag .graffiti { position: relative; width: 100%; height: auto; }
.feature__body { position: absolute; right: 7%; top: 16%; display: grid; gap: 10px; justify-items: start; max-width: 46%; }
.feature__kicker, .feature__name { color: var(--c-muted); }
.feature__title a:hover { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 4px; }
.feature .buy { margin-top: 10px; }

.cgrid__more {
  --cut: 18px;
  grid-column: span var(--span, 1);
  display: flex; flex-direction: column; justify-content: space-between; gap: 20px;
  padding: 22px; align-self: start;
  aspect-ratio: auto; height: calc((100cqw - (var(--cols) - 1) * var(--gap-x)) / var(--cols) * 1.25);
  background: transparent; box-shadow: inset 0 0 0 1px var(--c-line);
  transition: background-color .4s;
}
.cgrid__more:hover { background: rgb(255 255 255 / .06); }
.cgrid__more .display-s { max-width: 12ch; }
.cgrid__more .mono:last-child { display: flex; align-items: center; gap: 8px; color: var(--c-muted); }
.cgrid__more svg { width: 16px; height: 16px; }

/* la card "vedi tutto" chiude l'ultima riga a ogni numero di colonne:
   js/home.js imposta --span4/3/2 e, se occupa tutta la riga, --h4/3/2: auto (fascia bassa) */
.cgrid__more.is-off5 { display: none; }
@media (max-width: 1100px) {
  .cgrid { --cols: 4; }
  .cgrid__more { grid-column: span var(--span4, 1); min-height: 150px; height: var(--h4, calc((100cqw - (var(--cols) - 1) * var(--gap-x)) / var(--cols) * 1.25)); }
  .cgrid__more.is-off5 { display: flex; }
}
@media (max-width: 860px) {
  .cgrid { --cols: 3; }
  .feature { grid-column: 1 / -1; }
  .feature__body { max-width: 40%; }
  .cgrid__more { grid-column: span var(--span3, 1); height: var(--h3, calc((100cqw - (var(--cols) - 1) * var(--gap-x)) / var(--cols) * 1.25)); }
}
@media (max-width: 640px) {
  .cgrid { --cols: 2; }
  .cgrid__more { grid-column: span var(--span2, 1); height: var(--h2, calc((100cqw - (var(--cols) - 1) * var(--gap-x)) / var(--cols) * 1.25)); }
  .feature { height: auto; aspect-ratio: 4 / 5; }
  .feature__media::before { background: linear-gradient(0deg, color-mix(in srgb, var(--c-hero-b) 88%, transparent) 10%, transparent 70%); }
  .feature__body { left: 22px; right: 22px; top: auto; bottom: 24px; max-width: none; }
  .feature__tag { width: 78%; right: -8%; bottom: auto; top: 6%; }
}

/* ---------- MARCHE (scorrimento) ---------- */
.marquee { overflow: hidden; padding: 22px 0; background: var(--c-panel); border-top: 1px solid var(--c-line); border-bottom: 1px solid var(--c-line); transition: background-color .8s var(--ease); }
.marquee__track { display: flex; width: max-content; animation: marquee 42s linear infinite; }
.marquee:hover .marquee__track { animation-play-state: paused; }
.marquee__list { display: flex; flex: none; }
.marquee__item {
  display: flex; align-items: center; gap: .45em; padding-right: .45em;
  font: 700 clamp(38px, 5.6vw, 84px)/1 var(--f-display); font-stretch: 82%; text-transform: uppercase; white-space: nowrap;
  color: transparent; -webkit-text-stroke: 1px var(--c-muted);
}
.marquee__item::after { content: ""; width: .32em; height: .32em; background: var(--c-muted); clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%); }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- DISCIPLINE ---------- */
.sports { padding: clamp(56px, 7vw, 100px) var(--gutter); background: color-mix(in srgb, var(--c-panel) 72%, var(--c-panel-2)); transition: background-color .8s var(--ease); }
.shead--2 { grid-template-columns: minmax(0, 1.5fr) minmax(0, 1.2fr) auto; }
.shead__lead { max-width: 52ch; padding-top: 6px; }
.sgrid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(12px, 1.4vw, 20px); }
.stile {
  --cut: 22px;
  position: relative; aspect-ratio: 3 / 4.1;
  display: flex; flex-direction: column; justify-content: space-between;
  padding: 18px; color: #fff;
}
.stile > img { position: absolute; inset: 0; z-index: 0; transition: transform 1.2s var(--ease); }
.stile:hover > img { transform: scale(1.06); }
.stile__shade { position: absolute; inset: 0; z-index: 1; background: linear-gradient(0deg, rgb(0 0 0 / .55), transparent 55%), linear-gradient(180deg, rgb(0 0 0 / .25), transparent 30%); }
.stile__top, .stile__bottom, .stile__arrow { position: relative; z-index: 2; }
.stile__top { display: flex; justify-content: space-between; color: rgb(255 255 255 / .85); }
.stile__bottom { display: grid; gap: 8px; }
/* le parole lunghe (--len = lettere della parola più lunga, da js/home.js) si rimpiccioliscono
   per stare nella card senza finire sotto la freccia */
.stile { container-type: inline-size; }
.stile__name { font-size: min(clamp(28px, 3.2vw, 46px), calc((100cqw - 42px) / (var(--len, 8) * .57))); }
.stile__sub { color: rgb(255 255 255 / .8); }
.stile__arrow {
  position: absolute; right: 16px; bottom: 18px;
  width: 36px; height: 36px; display: grid; place-items: center;
  border-radius: 50%; box-shadow: inset 0 0 0 1px rgb(255 255 255 / .6);
  transition: background-color .35s, color .35s, transform .5s var(--ease);
}
.stile__arrow svg { width: 15px; height: 15px; }
.stile:hover .stile__arrow { background: #fff; color: #111; transform: rotate(45deg); }
@media (max-width: 1100px) {
  .sgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .shead--2 { grid-template-columns: 1fr; }
  .shead--2 > .pill { justify-self: start; }
  /* 2×2 orizzontali sui tablet: niente riquadri giganti */
  .stile { aspect-ratio: 4 / 3; }
}
@media (max-width: 520px) {
  .stile { aspect-ratio: 3 / 3.6; padding: 14px 12px; --cut: 16px; }
  /* card strette: la freccia sale in alto al posto dell'etichetta stagione */
  .stile__top > span:last-child { display: none; }
  .stile__arrow { top: 10px; right: 10px; bottom: auto; width: 32px; height: 32px; }
  .stile__name { font-size: min(28px, calc(100cqw / (var(--len, 8) * .57))); }
}

/* ---------- VALORI ---------- */
.values { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); background: var(--c-panel); border-top: 1px solid var(--c-line); transition: background-color .8s var(--ease); }
.value { display: grid; align-content: start; gap: 14px; padding: clamp(28px, 3.4vw, 44px) var(--gutter); border-right: 1px solid var(--c-line); }
.value:last-child { border-right: 0; }
.value__head { display: flex; justify-content: space-between; align-items: center; color: var(--c-faint); }
.value__head svg { width: 22px; height: 22px; color: var(--c-text); }
.value h3 { font-size: clamp(24px, 2.3vw, 32px); }
.value p { color: var(--c-muted); font-size: 11px; }
@media (max-width: 1100px) { .values { grid-template-columns: 1fr 1fr; } .value:nth-child(2) { border-right: 0; } .value:nth-child(-n+2) { border-bottom: 1px solid var(--c-line); } }
@media (max-width: 560px) { .values { grid-template-columns: 1fr; } .value { border-right: 0; border-bottom: 1px solid var(--c-line); } }

/* ---------- MANIFESTO (sezione montagna del template) ---------- */
.manifesto {
  position: relative; overflow: hidden; isolation: isolate;
  min-height: clamp(600px, 66vw, 860px);
  padding: clamp(40px, 6vw, 80px) var(--gutter);
  display: grid; align-content: end;
  background: var(--c-panel-2); transition: background-color .8s var(--ease);
}
.manifesto__media {
  position: absolute; left: 0; right: 0; bottom: 0; height: 80%; z-index: -3;
  -webkit-mask-image: linear-gradient(180deg, transparent 0%, #000 34%);
  mask-image: linear-gradient(180deg, transparent 0%, #000 34%);
  background: transparent;
}
.manifesto__media > img { object-position: 50% 30%; }
.manifesto__tag {
  position: absolute; z-index: -2; left: 6%; right: 6%; top: 0;
  color: var(--c-hi); opacity: .78; mix-blend-mode: screen;
  -webkit-mask-image: linear-gradient(180deg, #000 40%, transparent 92%);
  mask-image: linear-gradient(180deg, #000 40%, transparent 92%);
}
.manifesto__tag .graffiti { position: relative; width: 100%; height: auto; }
.manifesto__left { position: absolute; left: var(--gutter); top: 40%; max-width: 250px; display: grid; gap: 14px; }
.manifesto__right { position: absolute; right: var(--gutter); top: 52%; max-width: 200px; text-align: right; }
.manifesto__lines { display: grid; font-size: clamp(40px, 5.6vw, 84px); line-height: .92; text-shadow: 0 2px 40px rgb(0 0 0 / .25); }
.manifesto .barcode { position: absolute; right: var(--gutter); bottom: clamp(40px, 6vw, 80px); color: var(--c-text); }
@media (max-width: 760px) {
  .manifesto { min-height: 0; padding-top: 34vw; gap: 26px; }
  .manifesto__media { height: 72%; }
  .manifesto__left, .manifesto__right { position: static; text-align: left; max-width: 34ch; }
  .manifesto__right { order: 2; }
  /* ogni riga del titolo resta su una riga sola */
  .manifesto__lines { order: 3; margin-top: 30vw; font-size: min(40px, 8.2vw); }
  .manifesto .barcode { position: static; order: 4; justify-self: start; }
}

/* ---------- DOVE SIAMO ---------- */
.visit {
  display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); gap: clamp(28px, 5vw, 88px); align-items: center;
  padding: clamp(56px, 7vw, 104px) var(--gutter);
  background: var(--c-panel); transition: background-color .8s var(--ease);
}
.visit__media { --cut: 26px; aspect-ratio: 4 / 5; }
.visit__media > img { object-position: 50% 30%; }
.visit__label { color: var(--c-muted); margin-bottom: 20px; }
.visit .lead { margin-top: 22px; }
.visit__list { display: grid; grid-template-columns: 120px 1fr; gap: 12px 22px; margin-top: 32px; padding-top: 26px; border-top: 1px solid var(--c-line); }
.visit__list dt { color: var(--c-faint); }
.visit__list a { border-bottom: 1px solid var(--c-line); }
.visit__list a:hover { border-color: var(--c-text); }
.visit__cta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 34px; }
@media (max-width: 860px) {
  .visit { align-items: start; }
  .visit__list { grid-template-columns: 1fr; gap: 2px; }
  .visit__list dd { margin-bottom: 12px; }
}
/* telefono: foto sopra il testo, inquadrata in alto per non tagliare il viso */
@media (max-width: 640px) {
  .visit { grid-template-columns: 1fr; }
  .visit__media { aspect-ratio: 4 / 3; }
  .visit__media > img { object-position: 50% 10%; }
}
