/* Tavitalia REV21 — 03-10-2026
   Correzione mirata notebook: card/scena si RIDIMENSIONANO, niente scroll interno.
   Attiva solo su desktop >=1024px con viewport bassa <=900px.
   Mobile e desktop/monitor con altezza >900px restano invariati. */
:root{--tvh:100svh}
@supports(height:100dvh){:root{--tvh:100dvh}}

/* Mantiene la sincronizzazione scroll-to-view della REV20 */
@media (min-width:761px){
  .company-page .hs-story{height:var(--hs-scene-height,calc(var(--hs-count)*52vh + 100vh))!important;min-height:0!important}
  .company-page .hs-sticky{top:var(--hs-sticky-top,64px)!important;height:calc(var(--tvh) - var(--hs-sticky-top,64px))!important;min-height:0!important}
  .finitura-page .finitura-systems-scroll{height:calc(var(--tvh) * 4)!important;min-height:2400px}
  .finitura-page .finitura-life-scroll{height:calc(var(--tvh) * 5)!important;min-height:3000px}
  .meccanica-page .meccanica-flow-scroll{height:calc(var(--tvh) * 5)!important;min-height:3000px}
  .finitura-page .finitura-systems-sticky,
  .finitura-page .finitura-life-sticky,
  .meccanica-page .meccanica-flow-sticky{height:var(--tvh)!important;min-height:0!important;top:0!important}
}

/* SOLO notebook / desktop con schermo basso */
@media (min-width:1024px) and (max-height:900px){
  /* ===== STORIA ===== */
  .company-page .hs-head{padding:clamp(8px,1.5vh,14px) clamp(18px,3vw,42px) 0!important;flex:0 0 auto}
  .company-page .hs-kicker{margin-bottom:clamp(4px,1vh,8px)!important;font-size:clamp(10px,1.25vh,12px)!important}
  .company-page .hs-current-year{font-size:clamp(38px,7vh,62px)!important;line-height:.88!important}
  .company-page .hs-current-title{font-size:clamp(12px,1.8vh,15px)!important}
  .company-page .hs-track{gap:clamp(14px,2vw,26px)!important;padding:clamp(12px,2.2vh,20px) 0 clamp(18px,3vh,28px)!important}
  .company-page .hs-slide{
    flex-basis:clamp(390px,46vw,650px)!important;
    height:clamp(390px,calc(var(--tvh) - 205px),560px)!important;
    min-height:0!important;
    max-height:none!important;
    padding:clamp(20px,3vh,28px) clamp(24px,2.5vw,32px)!important;
    overflow:hidden!important;
  }
  .company-page .hs-slide-top{margin-bottom:clamp(10px,1.8vh,16px)!important}
  .company-page .hs-pill{padding:6px 10px!important;font-size:10px!important}
  .company-page .hs-slide h3{margin-bottom:clamp(8px,1.5vh,12px)!important;font-size:clamp(27px,4.8vh,40px)!important;line-height:.98!important}
  .company-page .hs-slide p{font-size:clamp(12px,1.85vh,14px)!important;line-height:1.55!important}
  .company-page .hs-points{gap:clamp(5px,1vh,8px)!important;margin-top:clamp(12px,2vh,18px)!important}
  .company-page .hs-points li{font-size:clamp(10px,1.55vh,12px)!important;line-height:1.45!important}
  .company-page .hs-slide-ghost{font-size:clamp(74px,14vh,125px)!important}
  .company-page .hs-story-sketch{transform:scale(.82)!important;transform-origin:right bottom!important}

  /* ===== FINITURA — PARCO MACCHINARI ===== */
  .finitura-page .finitura-systems__title{
    top:clamp(24px,4vh,42px)!important;
    left:max(34px,calc((100% - 1380px)/2))!important;
    width:min(500px,calc(100% - 68px))!important;
  }
  .finitura-page .finitura-systems__title h2{font-size:clamp(34px,6.2vh,54px)!important;line-height:.9!important}
  .finitura-page .finitura-systems__content{
    top:auto!important;
    bottom:clamp(22px,4vh,40px)!important;
    left:max(34px,calc((100% - 1380px)/2))!important;
    width:min(570px,48vw)!important;
    min-height:0!important;
    max-height:calc(var(--tvh) - 245px)!important;
    padding:clamp(18px,2.8vh,28px) clamp(28px,3vw,44px)!important;
    overflow:hidden!important;
  }
  .finitura-page .finitura-system-slide{max-height:none!important;overflow:visible!important}
  .finitura-page .finitura-system-slide>small{margin-bottom:clamp(7px,1.2vh,11px)!important;font-size:10px!important}
  .finitura-page .finitura-system-slide h3{margin-bottom:clamp(10px,1.8vh,15px)!important;font-size:clamp(34px,6.5vh,54px)!important;line-height:.88!important}
  .finitura-page .finitura-system-slide p{font-size:clamp(12px,1.9vh,15px)!important;line-height:1.5!important}
  .finitura-page .finitura-system-slide>strong{margin-top:clamp(10px,1.8vh,18px)!important;padding-top:8px!important;font-size:clamp(9px,1.35vh,11px)!important;line-height:1.45!important}
  .finitura-page .finitura-system-visual figcaption{right:24px!important;bottom:18px!important;font-size:11px!important}

  /* ===== ALTRE SCENE SCROLL-TO-VIEW ===== */
  .finitura-page .finitura-shell,.meccanica-page .meccanica-shell{width:min(1180px,calc(100% - 56px))!important}
  .finitura-page .finitura-life__head,.meccanica-page .meccanica-flow__head{padding-top:clamp(42px,6vh,68px)!important}
  .finitura-page .finitura-life__head h2,.meccanica-page .meccanica-flow h2{font-size:clamp(32px,6vh,52px)!important;line-height:.92!important}
  .finitura-page .finitura-life__stage,.meccanica-page .meccanica-flow__stage{min-height:0!important}
  .finitura-page .finitura-life-slide,.meccanica-page .meccanica-flow-slide{overflow:hidden!important}
  .finitura-page .finitura-life-slide p,.meccanica-page .meccanica-flow-slide p{font-size:clamp(12px,1.9vh,15px)!important;line-height:1.5!important}
}

/* Notebook molto bassi (es. 1366x768 / viewport browser ~650-720px) */
@media (min-width:1024px) and (max-height:760px){
  .company-page .hs-slide{height:clamp(350px,calc(var(--tvh) - 175px),500px)!important;padding:18px 24px!important}
  .company-page .hs-slide h3{font-size:clamp(24px,4.6vh,34px)!important}
  .company-page .hs-slide p{font-size:12px!important;line-height:1.42!important}
  .company-page .hs-points{margin-top:10px!important;gap:4px!important}
  .company-page .hs-points li{font-size:10px!important;line-height:1.35!important}
  .finitura-page .finitura-systems__title{top:20px!important}
  .finitura-page .finitura-systems__title h2{font-size:clamp(30px,5.7vh,44px)!important}
  .finitura-page .finitura-systems__content{bottom:18px!important;max-height:calc(var(--tvh) - 205px)!important;padding:16px 30px!important}
  .finitura-page .finitura-system-slide h3{font-size:clamp(30px,6vh,44px)!important;margin-bottom:9px!important}
  .finitura-page .finitura-system-slide p{font-size:12px!important;line-height:1.42!important}
  .finitura-page .finitura-system-slide>strong{margin-top:9px!important;font-size:9px!important}
}
