/* vetrina.css - la struttura come un profilo Instagram (vetrina.php, vetrina.js).
   Misure prese da MenuAlaCarte/ig (14px, grigio #737373 per le seconde righe); i colori sono
   quelli della struttura (--brand dal tema), non il blu di Instagram: e' il suo booking.
   Alzare ?v= in vetrina.php a ogni modifica. Prefisso vt-. */

:root { --vt-bg: #fff; --vt-fg: #1b1a21; --vt-fg2: #6b6678; --vt-linea: #e3e1ea; --vt-tasto: #efeef3; --vt-tasto-h: #e2e0ea;
        --vt-anello: linear-gradient(45deg, var(--brand-soft, #efecf8), var(--brand, #3f347f) 45%, var(--brand-dark, #2f296f)); }

* { box-sizing: border-box; }
[hidden] { display: none !important; }
body.vt { margin: 0; background: var(--vt-bg); color: var(--vt-fg); font-family: var(--font, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif);
          font-size: 14px; line-height: 18px; -webkit-text-size-adjust: 100%; -webkit-tap-highlight-color: transparent; }
/* :where() = specificita' zero: l'azzeramento non deve battere le classi dei componenti (.vt-ring, .vt-av...). */
:where(.vt) a { color: inherit; text-decoration: none; }
:where(.vt) button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
.vt :focus-visible { outline: 3px solid var(--brand, #3f347f); outline-offset: 2px; border-radius: 4px; }

.vt-main { max-width: 935px; margin: 0 auto; outline: none; }

/* ── testata: avatar, numeri, bio, pulsanti ── */
.vt-profilo { display: grid; grid-template-columns: auto 1fr; column-gap: 28px; align-items: center;
              grid-template-areas: "av dx" "bio bio" "az az"; padding-top: 16px; }
.vt-av { grid-area: av; margin-left: 16px; margin-bottom: 12px; width: 86px; height: 86px; border-radius: 50%; padding: 3px; display: grid; place-items: center; }
.vt-av:disabled { cursor: default; }
.vt-ring { background: var(--vt-anello); }
.vt-avatar { width: 100%; height: 100%; border-radius: 50%; display: block; object-fit: contain; background: #fff; border: 3px solid var(--vt-bg); padding: 6px; }
.vt-av:not(.vt-ring) .vt-avatar { border-color: var(--vt-linea); border-width: 1px; }
.vt-sigla { display: grid; place-items: center; font-size: 34px; font-weight: 700; color: var(--brand-dark, #2f296f); }
.vt-dx { grid-area: dx; min-width: 0; margin-bottom: 12px; padding-right: 16px; }
.vt-nome { margin: 0 0 10px; font-size: 17px; line-height: 22px; font-weight: 700; }
.vt-stats { display: flex; gap: 28px; margin: 0; padding: 0; list-style: none; }
.vt-stats li { display: flex; flex-direction: column; font-size: 14px; }
.vt-stats b { font-size: 16px; font-weight: 700; }

.vt-bio { grid-area: bio; padding: 0 16px 14px; }
.vt-bio-testo { margin: 0; overflow-wrap: anywhere; }
.vt-bio-testo.is-corta { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.vt-bio-altro { color: var(--vt-fg2); }
.vt-bio-riga { display: flex; align-items: center; gap: 7px; margin-top: 2px; min-height: 26px; }   /* 24px minimi: WCAG 2.5.8 */
.vt-bio-riga .fa { width: 14px; text-align: center; margin-top: 2px; color: var(--vt-fg2); }
.vt-bio-link { color: var(--brand-dark, #2f296f); font-weight: 700; }
.vt-lingue { display: flex; gap: 6px; margin-top: 6px; font-size: 12px; font-weight: 700; }
.vt-lingue a { color: var(--vt-fg2); display: inline-flex; align-items: center; justify-content: center; min-width: 28px; min-height: 26px; }
.vt-lingue a[aria-current] { color: var(--vt-fg); text-decoration: underline; text-underline-offset: 3px; }

.vt-azioni { grid-area: az; display: flex; gap: 6px; padding: 0 16px 16px; }
.vt-btn { flex: 1; display: flex; align-items: center; justify-content: center; min-height: 34px; padding: 0 12px; border-radius: 8px; background: var(--vt-tasto);
          font-weight: 700; font-size: 14px; white-space: nowrap; }
.vt-btn:hover { background: var(--vt-tasto-h); }
.vt-btn-brand { background: var(--brand, #3f347f); color: var(--brand-ink, #fff) !important; }
.vt-btn-brand:hover { background: var(--brand-dark, #2f296f); }

/* ── in evidenza ── */
.vt-hl { display: flex; gap: 15px; padding: 2px 16px 16px; scroll-padding: 0 16px; overflow-x: auto; scrollbar-width: none; overscroll-behavior-x: contain; scroll-snap-type: x proximity; }
.vt-hl::-webkit-scrollbar { display: none; }
.vt-hl-el { flex: 0 0 auto; width: 70px; display: flex; flex-direction: column; align-items: center; gap: 6px; scroll-snap-align: start; }
.vt-hl-cerchio { width: 70px; height: 70px; border-radius: 50%; padding: 3px; background: var(--vt-anello); }
.vt-hl-cerchio img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; display: block; background: var(--vt-tasto); border: 2px solid var(--vt-bg); }
.vt-hl-nome { width: 100%; font-size: 12px; line-height: 16px; text-align: center; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ── schede e griglia ── */
.vt-tabs { display: flex; justify-content: center; border-top: 1px solid var(--vt-linea); }
.vt-tab { flex: 1; max-width: 220px; display: flex; align-items: center; justify-content: center; gap: 7px; padding: 12px 0; color: var(--vt-fg2); font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
.vt-tab .fa { font-size: 16px; }
.vt-tab.is-on { color: var(--vt-fg); box-shadow: inset 0 -2px 0 var(--vt-fg); }
.vt-griglia { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2px; }
.vt-griglia-el { position: relative; display: block; aspect-ratio: 4 / 5; overflow: hidden; background: var(--vt-tasto); }
.vt-griglia-el img { width: 100%; height: 100%; object-fit: cover; display: block; }
.vt-griglia-el:hover img { opacity: .88; }
.vt-multi { position: absolute; top: 8px; right: 8px; color: #fff; font-size: 16px; text-shadow: 0 1px 3px rgba(0,0,0,.5); }
.vt-griglia-testo { position: absolute; left: 0; right: 0; bottom: 0; padding: 26px 8px 8px; color: #fff; text-align: left;
                    background: linear-gradient(to top, rgba(0,0,0,.72), transparent); }
.vt-griglia-testo b { display: block; font-size: 13px; line-height: 16px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vt-griglia-testo small { display: block; font-size: 11.5px; opacity: .95; }
.vt-vuoto { text-align: center; color: var(--vt-fg2); padding: 60px 16px; }
.vt-diretta { text-align: center; color: var(--vt-fg2); font-size: 13px; margin: 26px 16px; }
.vt-diretta .fa { color: var(--brand-dark, #2f296f); }
.vt-footer { width: min(935px, calc(100% - 32px)); margin: 0 auto; padding: 24px 0 calc(24px + env(safe-area-inset-bottom)); display: flex; justify-content: space-between; gap: 18px;
             color: #45414f; font-size: 13px; line-height: 1.6; border-top: 1px solid var(--vt-linea); }
.vt-footer strong { display: block; color: #1e2430; font-size: 14px; margin-bottom: 4px; }
.vt-footer a { color: var(--brand-dark, #2f296f); }
.vt-footer img { height: auto; }
.vt-footer .wr-foot-info { display: flex; flex-wrap: wrap; gap: 4px 10px; }

@media (min-width: 736px) {
  .vt-main { padding: 30px 20px 0; }
  .vt-profilo { grid-template-columns: 290px 1fr; column-gap: 0; align-items: start; grid-template-areas: "av dx" "av bio" "av az"; padding: 0 0 40px; }
  .vt-av { width: 160px; height: 160px; margin: 0 auto; justify-self: center; }
  .vt-avatar { padding: 14px; }
  .vt-dx { margin: 0; padding: 0; }
  .vt-nome { font-size: 22px; line-height: 28px; margin: 4px 0 18px; }
  .vt-stats { gap: 40px; margin-bottom: 16px; }
  .vt-stats li { flex-direction: row; gap: 5px; font-size: 16px; }
  .vt-bio { padding: 0 0 18px; }
  .vt-azioni { padding: 0; max-width: 460px; }
  .vt-hl { gap: 44px; padding: 0 0 40px 40px; }
  .vt-hl-el { width: 88px; }
  .vt-hl-cerchio { width: 88px; height: 88px; }
  .vt-hl-nome { font-weight: 600; }
  .vt-tab.is-on { box-shadow: inset 0 2px 0 var(--vt-fg); }
  .vt-griglia { gap: 4px; }
}
@media (max-width: 640px) { .vt-footer { flex-direction: column; } .vt-tab span { display: none; } .vt-tab .fa { font-size: 20px; } }

/* ══ visori: post e storie ══════════════════════════════════════════════ */
body.vt-aperto { overflow: hidden; }

.vt-feed { position: fixed; inset: 0; z-index: 50; background: var(--vt-bg); overflow-y: auto; overscroll-behavior: contain; }
.vt-feed-top { position: sticky; top: 0; z-index: 2; display: flex; align-items: center; gap: 12px; height: 48px; padding: 0 12px; padding-top: env(safe-area-inset-top);
               background: var(--vt-bg); border-bottom: 1px solid var(--vt-linea); }
.vt-feed-top button { display: grid; place-items: center; width: 40px; height: 40px; font-size: 20px; }
.vt-feed-top b { flex: 1; text-align: center; font-size: 16px; margin-right: 40px; }
.vt-feed-lista { max-width: 470px; margin: 0 auto; padding-bottom: env(safe-area-inset-bottom); }

.vt-post { border-bottom: 1px solid var(--vt-linea); padding-bottom: 14px; scroll-margin-top: 48px; }
.vt-post-head { display: flex; align-items: center; gap: 10px; padding: 8px 12px; }
.vt-post-av { width: 32px; height: 32px; border-radius: 50%; padding: 2px; background: var(--vt-anello); flex: 0 0 auto; }
.vt-post-av img, .vt-post-av span { width: 100%; height: 100%; border-radius: 50%; border: 2px solid var(--vt-bg); object-fit: contain; background: #fff; display: grid; place-items: center; font-size: 12px; font-weight: 700; }
.vt-post-chi { min-width: 0; line-height: 16px; }
.vt-post-chi b { display: block; font-weight: 700; }
.vt-post-chi span { display: block; font-size: 12px; color: var(--vt-fg2); }
.vt-car { position: relative; }
.vt-car-track { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
.vt-car-track::-webkit-scrollbar { display: none; }
.vt-car-track img { flex: 0 0 100%; width: 100%; aspect-ratio: 4 / 5; object-fit: cover; background: var(--vt-tasto); scroll-snap-align: center; display: block; }
.vt-car-btn { position: absolute; top: 50%; transform: translateY(-50%); width: 32px; height: 32px; border-radius: 50%; background: rgba(255,255,255,.92) !important; color: #1b1a21;
              display: grid; place-items: center; box-shadow: 0 1px 4px rgba(0,0,0,.25); }
.vt-car-btn.vt-sx { left: 8px; } .vt-car-btn.vt-dx { right: 8px; }
.vt-car-punti { display: flex; justify-content: center; gap: 4px; padding-top: 8px; }
.vt-car-punti i { width: 6px; height: 6px; border-radius: 50%; background: var(--vt-linea); }
.vt-car-punti i.is-on { background: var(--brand, #3f347f); }
.vt-post-az { display: flex; gap: 14px; padding: 8px 12px 4px; }
.vt-post-az button { font-size: 22px; width: 32px; height: 32px; display: grid; place-items: center; }
.vt-post-cap { padding: 4px 12px 0; overflow-wrap: anywhere; white-space: pre-line; }
.vt-post-cap b { font-weight: 700; margin-right: 4px; }
.vt-post-cta { display: inline-flex; margin: 10px 12px 0; padding: 8px 14px; border-radius: 8px; background: var(--brand, #3f347f); color: var(--brand-ink, #fff) !important; font-weight: 700; }
.vt-post-cta:hover { background: var(--brand-dark, #2f296f); }

.vt-storia { position: fixed; inset: 0; z-index: 60; background: #1a1a1a; display: grid; place-items: center; touch-action: none; user-select: none; -webkit-user-select: none; }
.vt-storia-box { position: relative; width: 100%; height: 100%; overflow: hidden; background: #000; color: #fff; }
@media (min-width: 736px) { .vt-storia-box { width: auto; height: 92vh; aspect-ratio: 9 / 16; border-radius: 10px; } }
.vt-storia-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.vt-storia-barre { position: absolute; top: calc(8px + env(safe-area-inset-top)); left: 8px; right: 8px; z-index: 3; display: flex; gap: 3px; }
.vt-storia-barre i { flex: 1; height: 2px; border-radius: 2px; background: rgba(255,255,255,.35); overflow: hidden; }
.vt-storia-barre i b { display: block; height: 100%; width: 0; background: #fff; }
.vt-storia-head { position: absolute; top: calc(18px + env(safe-area-inset-top)); left: 12px; right: 6px; z-index: 4; display: flex; align-items: center; gap: 8px; text-shadow: 0 1px 2px rgba(0,0,0,.4); }
.vt-storia-head img, .vt-storia-head .vt-sigla { width: 32px; height: 32px; border-radius: 50%; object-fit: contain; background: #fff; flex: 0 0 auto; font-size: 15px; }
.vt-storia-head b { flex: 1; min-width: 0; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vt-storia-head button { width: 40px; height: 40px; display: grid; place-items: center; color: #fff; font-size: 20px; }
.vt-storia-ombra { position: absolute; inset: 0; z-index: 1; pointer-events: none; background: linear-gradient(to bottom, rgba(0,0,0,.45), transparent 18%, transparent 50%, rgba(0,0,0,.8)); }
.vt-storia-testo { position: absolute; left: 18px; right: 18px; bottom: calc(24px + env(safe-area-inset-bottom)); z-index: 4; }
.vt-storia-desc { margin: 0 0 8px; font-size: 14px; line-height: 19px; opacity: .95; display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.vt-storia-riga { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.vt-storia-nome { margin: 0; font-size: 22px; line-height: 26px; font-weight: 700; }
.vt-storia-prezzo { flex: 0 0 auto; font-weight: 700; font-size: 14px; padding: 5px 11px; border-radius: 999px; background: rgba(255,255,255,.94); color: #000; }
.vt-storia-cta { display: flex; align-items: center; justify-content: center; margin-top: 14px; min-height: 44px; border-radius: 10px; background: var(--brand, #3f347f); color: var(--brand-ink, #fff) !important; font-weight: 700; font-size: 15px; }
.vt-storia-tap { position: absolute; top: 70px; bottom: 150px; z-index: 2; width: 34%; }
.vt-storia-tap.vt-sx { left: 0; } .vt-storia-tap.vt-dx { right: 0; width: 66%; }

@media (prefers-reduced-motion: reduce) { .vt-car-track { scroll-behavior: auto; } }
