/* Verdex — Prima schermata compatta su smartphone (larghezza inferiore a 768 px)
 * All'apertura sul telefono, con la barra «Verdex / IT / Aa / Account / PRO» interamente visibile in alto, la
 * schermata iniziale arriva fino al pulsante «Verifica ora» e alla riga «Tester · Controlli illimitati · Esempi gratis»
 * sul fondo dello schermo, mentre «Prova subito con un esempio» resta appena sotto la piega.
 * Si stringono solo spazi interni e margini tra i blocchi: barra superiore, invito iniziale, «Allerte attive», griglia
 * delle categorie, «Confronta Originale vs Sospetto» e riquadro «Controlla un Messaggio, SMS o Email». Caratteri,
 * icone e aree di tocco restano le stesse (pulsanti di almeno 40 px). L'area di testo parte intorno ai 74 px e si
 * allunga mentre si scrive; shield-reach.js ne rifinisce l'altezza sullo schermo reale.
 * Da 768 px in su (computer, laptop e tablet larghi) nessuna regola di questo foglio si applica.
 */
@media (max-width: 767.98px) {

  /* ---------- 1) Barra superiore: stesso contenuto e stessi pulsanti, meno margine sopra e sotto ---------- */
  html:not(.ph-off) body #app-header .hdr.hdr-one { min-height: 3.35rem; padding-top: .2rem; padding-bottom: .2rem; }

  /* ---------- 2) Spazi tra i blocchi superiori ---------- */
  html:not(.ph-off) body > main { padding-top: .3rem !important; }
  html:not(.ph-off) body > main > #sg-alerts:not(.hidden) { margin-top: .3rem !important; }
  html:not(.ph-off) body > main > #tools-nav { margin-top: .35rem !important; }
  html:not(.ph-off) body > main > #work-area { margin-top: .4rem !important; }

  /* Invito «Scegli cosa vuoi controllare qui sotto…» */
  html:not(.ph-off) body > main > #quick-guide { padding-top: .2rem !important; padding-bottom: .2rem !important; }
  html:not(.ph-off) body > main > #quick-guide #hero-instruction { line-height: 1.24; }

  /* «Allerte attive» */
  html:not(.ph-off) body > main > #sg-alerts { padding-top: .22rem !important; padding-bottom: .26rem !important; }
  html:not(.ph-off) body > main > #sg-alerts .sg-alerts-head { padding-bottom: .08rem; }
  html:not(.ph-off) body > main > #sg-alerts .sg-alerts-row { padding-top: .05rem; padding-bottom: .1rem; }
  html:not(.ph-off) body > main > #sg-alerts .sg-alert { min-height: 2.75rem; padding-top: .22rem !important; padding-bottom: .22rem !important; }
  html:not(.ph-off) body > main > #sg-alerts .sg-alert-txt { gap: .05rem; }
  html:not(.ph-off) body > main > #sg-alerts .sg-alert-txt > * { line-height: 1.14; }

  /* Griglia delle categorie e «Confronta Originale vs Sospetto» */
  html:not(.ph-off) body > main > #tools-nav { gap: .35rem !important; }
  html:not(.ph-off) body > main > #tools-nav .tool-primary { min-height: 3.75rem; padding-top: .25rem; padding-bottom: .25rem; }
  html:not(.ph-off) body > main > #tools-nav .tool-primary .tab-icon { width: 2.2rem; height: 2.2rem; }
  html:not(.ph-off) body > main > #tools-nav .tool-primary .tab-hint { line-height: 1.12; }
  html:not(.ph-off) body > main > #tools-nav .tool-compact { min-height: 4.05rem; padding-top: .22rem; padding-bottom: .22rem; gap: .15rem; }
  html:not(.ph-off) body > main > #tools-nav .tool-compact .tab-icon { width: 1.95rem; height: 1.95rem; }
  html:not(.ph-off) body > main > #tools-nav .tool-compact .tab-label { line-height: 1.15; }
  html:not(.ph-off) body > main > #tools-nav .tool-compact .tab-hint { line-height: 1.12; }
  html:not(.ph-off) body > main > #tools-nav .tool-compare { min-height: 3.3rem; padding-top: .25rem; padding-bottom: .25rem; }
  html:not(.ph-off) body > main > #tools-nav .tool-compare .tab-label { line-height: 1.14; }

  /* ---------- 3) «Controlla un Messaggio, SMS o Email» ---------- */
  html:not(.ph-off) body > main > #work-area { padding-top: .6rem; padding-bottom: .55rem; gap: .45rem; }
  html:not(.ph-off) body > main > #work-area > #panel-text { gap: .45rem; }
  html:not(.ph-off) body > main > #work-area #title-text { line-height: 1.16; }
  html:not(.ph-off) body > main > #work-area #btn-paste.text-head-paste { min-height: 2.5rem; }
  /* Area di testo: circa 78 px all'apertura (3 righe), si allunga da sola mentre si scrive. */
  html:not(.ph-off) body > main > #work-area #panel-text > #input-text {
    height: var(--phone-ta-h, calc(2.6 * 1.4em + 1rem + 4px));
    min-height: calc(2 * 1.4em + 1rem + 4px);
    padding-top: .5rem; padding-bottom: .5rem;
  }
  /* Selettore «Standard / Anti-truffa / Forense», «Verifica ora» e riga delle prove */
  html:not(.ph-off) body > main > #work-area .vp-quick { gap: .12rem; }
  html:not(.ph-off) body > main > #work-area .vp-seg { padding: .12rem; }
  html:not(.ph-off) body > main > #work-area #btn-verify.verify-cta { min-height: 2.9rem; padding-top: .55rem; padding-bottom: .55rem; }
  html:not(.ph-off) body > main > #work-area > .trial-block { margin-top: 0 !important; }
}
