
:root{
  --bg:#0d0d0d;
  --fg:#f5f3ed;
  --muted:rgba(245,243,237,.58);
  --line:rgba(245,243,237,.20);
  --card:clamp(180px,19vw,300px);
  --ease:cubic-bezier(.16,1,.3,1);
}
html[data-theme="light"]{
  --bg:#f4f1eb;
  --fg:#0d0d0d;
  --muted:rgba(13,13,13,.55);
  --line:rgba(13,13,13,.18);
}
*{box-sizing:border-box}
html,body{margin:0;width:100%;height:100%;overflow:hidden;background:var(--bg);color:var(--fg)}
body{
  font-family:Arial,Helvetica,sans-serif;
  transition:background .5s var(--ease),color .5s var(--ease);
  user-select:none;overscroll-behavior:none;
}
button,a{font:inherit}
button{color:inherit}
.viewport{
  position:fixed;inset:0;overflow:hidden;perspective:1250px;
  background:
    radial-gradient(circle at 50% 47%,color-mix(in srgb,var(--fg) 4%,transparent),transparent 56%),
    var(--bg);
  transition:background .5s var(--ease);
}
.world{
  position:absolute;left:50%;top:50%;width:1px;height:1px;
  transform-style:preserve-3d;will-change:transform;
}
.tile{
  position:absolute;width:var(--card);aspect-ratio:4/5;overflow:hidden;
  background:color-mix(in srgb,var(--fg) 8%,var(--bg));
  transform-style:preserve-3d;will-change:transform;
  cursor:pointer;box-shadow:none;
  backface-visibility:hidden;
}
.tile.landscape{aspect-ratio:5/4}
.tile.square{aspect-ratio:1}
.tile img{
  position:absolute;inset:-5%;width:110%;height:110%;object-fit:cover;
  pointer-events:none;will-change:transform,filter;
  transform-origin:50% 50%;
}
.tile::after{
  content:"";position:absolute;inset:0;pointer-events:none;
  background:linear-gradient(180deg,transparent 55%,rgba(0,0,0,.42));
  opacity:0;transition:opacity .45s var(--ease);
}
.tile:hover::after{opacity:1}
.tile-meta{
  position:absolute;z-index:2;left:16px;right:16px;bottom:14px;
  display:flex;justify-content:space-between;align-items:end;gap:14px;
  color:white;text-shadow:0 2px 14px rgba(0,0,0,.35);
  opacity:0;transform:translateY(12px);
  transition:.42s var(--ease);pointer-events:none;
}
.tile:hover .tile-meta{opacity:1;transform:none}
.tile-meta strong{display:block;font-size:16px;letter-spacing:-.02em}
.tile-meta span{font-size:10px;text-transform:uppercase;letter-spacing:.13em}

.chrome{
  position:fixed;inset:0;z-index:20;pointer-events:none;
  text-transform:uppercase;letter-spacing:.12em;font-size:10px;
}
.logo{
  position:absolute;left:28px;top:24px;pointer-events:auto;
  display:flex;align-items:center;text-decoration:none;
}
.logo img{
  display:block;
  width:auto;
  height:200px;
  max-width:320px;
  object-fit:contain;
}
.theme-toggle{
  position:absolute;right:28px;top:24px;pointer-events:auto;
  border:1px solid var(--line);background:color-mix(in srgb,var(--bg) 84%,transparent);
  backdrop-filter:blur(12px);border-radius:999px;padding:7px;
  display:flex;align-items:center;gap:4px;cursor:pointer;
}
.theme-toggle span{
  width:29px;height:29px;display:grid;place-items:center;border-radius:50%;
  transition:.3s var(--ease);font-size:11px;
}
.theme-toggle .active{background:var(--fg);color:var(--bg)}
.help{position:absolute;right:28px;bottom:26px;text-align:right;color:var(--muted);line-height:1.75}
.zoom-ui{color:var(--muted)}
.zoom-ui b{color:var(--fg);font-weight:600}
.panel-backdrop{
  position:fixed;inset:0;z-index:39;background:rgba(0,0,0,.22);
  backdrop-filter:blur(7px);opacity:0;pointer-events:none;
  transition:.45s var(--ease);
}
.panel-backdrop.open{opacity:1;pointer-events:auto}
.panel{
  position:fixed;z-index:40;top:0;right:0;height:100%;width:min(550px,92vw);
  padding:28px;background:var(--fg);color:var(--bg);
  transform:translateX(102%);transition:transform .65s var(--ease);
  display:flex;flex-direction:column;box-shadow:-40px 0 90px rgba(0,0,0,.17)
}
.panel.open{transform:none}
.panel-close{
  margin-left:auto;border:0;background:none;color:inherit;font-size:31px;
  cursor:pointer;line-height:1;padding:0 0 28px
}
.panel-kicker{font-size:10px;text-transform:uppercase;letter-spacing:.16em;opacity:.58;margin-bottom:15px}
.panel-title{font-size:clamp(38px,6vw,58px);line-height:.95;letter-spacing:-.05em;margin:0 0 25px}
.panel-desc{
  font-size:15px;
  line-height:1.65;
  opacity:.74;
  margin:0 0 27px;
  max-width:35em;
  white-space:pre-line;
}
.panel-link{
  color:inherit;text-decoration:none;text-transform:uppercase;letter-spacing:.1em;
  font-size:11px;width:max-content;border-bottom:1px solid currentColor;padding-bottom:6px
}
.panel-image{width:100%;aspect-ratio:3/3;object-fit:cover;margin-top:10px}
.dragging{cursor:grabbing!important}
.dragging .tile{cursor:grabbing}

@media(max-width:700px){
  .logo{left:18px;top:18px}
  .logo img{
    height:140px;
    max-width:260px;
  }
  .theme-toggle{right:18px;top:17px}
  .help{display:none}
  .zoom-ui{left:18px;bottom:18px}
  .panel{padding:22px}
}

/* Privacy / Cookie */
.privacy-pop{
  position:fixed;left:24px;bottom:24px;z-index:70;width:min(390px,calc(100vw - 36px));
  padding:22px;background:var(--fg);color:var(--bg);border:1px solid color-mix(in srgb,var(--bg) 16%,transparent);
  opacity:0;transform:translateY(24px);pointer-events:none;
  transition:opacity .4s var(--ease),transform .5s var(--ease);
}
.privacy-pop.show{opacity:1;transform:none;pointer-events:auto}
.privacy-close{position:absolute;top:13px;right:15px;border:0;background:none;color:inherit;font-size:24px;cursor:pointer}
.privacy-eyebrow{font-size:9px;text-transform:uppercase;letter-spacing:.17em;opacity:.55;margin-bottom:10px}
.privacy-pop h2{margin:0 34px 10px 0;font-size:22px;letter-spacing:-.03em}
.privacy-pop p{margin:0 0 14px;font-size:13px;line-height:1.55;opacity:.74}
.privacy-links{display:flex;gap:14px;flex-wrap:wrap;margin-bottom:18px}
.privacy-links a{color:inherit;font-size:10px;text-transform:uppercase;letter-spacing:.12em;text-decoration:none;border-bottom:1px solid currentColor;padding-bottom:3px}
.privacy-actions{display:flex;gap:8px;flex-wrap:wrap}
.privacy-btn{border:1px solid currentColor;padding:10px 14px;cursor:pointer;text-transform:uppercase;letter-spacing:.1em;font-size:10px}
.privacy-btn.primary{background:var(--bg);color:var(--fg)}
.privacy-btn.secondary{background:transparent;color:inherit}
@media(max-width:700px){.privacy-pop{left:18px;bottom:18px;width:calc(100vw - 36px)}}


/* =========================================================
   CIRIX ACCESS - ACCESSIBILITY TOOLBAR
   ========================================================= */
.a11y-trigger{
  position:fixed;
  right:24px;
  bottom:86px;
  z-index:78;
  width:52px;
  height:52px;
  border-radius:50%;
  border:1px solid var(--line);
  background:var(--fg);
  color:var(--bg);
  display:grid;
  place-items:center;
  cursor:pointer;
  box-shadow:none;
  font-size:24px;
  transition:transform .25s var(--ease),background .35s var(--ease),color .35s var(--ease);
}
.a11y-trigger:hover{transform:scale(1.06)}
.a11y-trigger:focus-visible,
.a11y-panel button:focus-visible,
.a11y-panel a:focus-visible{
  outline:3px solid #ffcc00;
  outline-offset:3px;
}

.a11y-panel{
  position:fixed;
  left:24px;
  bottom:24px;
  z-index:79;
  width:min(430px,calc(100vw - 36px));
  max-height:min(760px,calc(100vh - 48px));
  overflow:auto;
  background:#fff;
  color:#111;
  border:1px solid rgba(0,0,0,.12);
  border-radius:18px;
  padding:20px;
  opacity:0;
  transform:translateY(18px) scale(.98);
  pointer-events:none;
  transition:opacity .3s var(--ease),transform .35s var(--ease);
  box-shadow:0 20px 65px rgba(0,0,0,.18);
  text-transform:none;
  letter-spacing:normal;
}
.a11y-panel.open{
  opacity:1;
  transform:none;
  pointer-events:auto;
}
.a11y-header{
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap:18px;
  padding-bottom:16px;
  border-bottom:1px solid #e8e8e8;
}
.a11y-header h2{
  margin:3px 0 0;
  font-size:22px;
  line-height:1.08;
  letter-spacing:-.03em;
}
.a11y-eyebrow{
  text-transform:uppercase;
  letter-spacing:.14em;
  font-size:9px;
  opacity:.55;
}
.a11y-close{
  border:0;
  background:transparent;
  color:#111;
  font-size:28px;
  cursor:pointer;
  line-height:1;
  padding:0;
}
.a11y-section{
  padding:17px 0 2px;
}
.a11y-section h3{
  margin:0 0 10px;
  font-size:11px;
  text-transform:uppercase;
  letter-spacing:.12em;
  color:#666;
}
.a11y-grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:8px;
}
.a11y-grid.profiles{
  grid-template-columns:1fr;
}
.a11y-card,.a11y-tool{
  border:1px solid #e5e5e5;
  background:#fafafa;
  color:#111;
  border-radius:11px;
  cursor:pointer;
  text-align:left;
  min-height:64px;
  transition:border-color .2s ease,background .2s ease,transform .2s ease;
}
.a11y-card{
  padding:12px 13px;
  display:flex;
  flex-direction:column;
  gap:4px;
}
.a11y-card strong{font-size:13px}
.a11y-card span{font-size:11px;color:#666;line-height:1.35}
.a11y-tool{
  padding:11px;
  display:grid;
  grid-template-columns:32px 1fr auto;
  align-items:center;
  gap:8px;
  font-size:11px;
  line-height:1.25;
}
.a11y-icon{
  width:30px;
  height:30px;
  border-radius:8px;
  background:#efefef;
  display:grid;
  place-items:center;
  font-weight:700;
}
.a11y-tool b{
  font-size:9px;
  font-weight:600;
  color:#777;
}
.a11y-card:hover,.a11y-tool:hover{transform:translateY(-1px);border-color:#bdbdbd}
.a11y-card.active,.a11y-tool.active{
  background:#111;
  color:#fff;
  border-color:#111;
}
.a11y-card.active span,.a11y-tool.active b{color:#d6d6d6}
.a11y-card.active .a11y-icon,.a11y-tool.active .a11y-icon{background:#333}
.a11y-footer{
  display:flex;
  gap:8px;
  padding-top:18px;
  margin-top:14px;
  border-top:1px solid #e8e8e8;
}
.a11y-footer button{
  flex:1;
  border-radius:10px;
  padding:11px 10px;
  cursor:pointer;
  font-size:10px;
  text-transform:uppercase;
  letter-spacing:.08em;
}
.a11y-secondary{
  border:1px solid #d7d7d7;
  background:#fff;
  color:#111;
}
.a11y-reset{
  border:1px solid #111;
  background:#111;
  color:#fff;
}
.a11y-shortcut{
  text-align:center;
  color:#777;
  font-size:10px;
  margin:11px 0 0;
}
.a11y-shortcut kbd{
  border:1px solid #ddd;
  border-bottom-width:2px;
  border-radius:4px;
  padding:1px 4px;
  background:#f7f7f7;
  color:#333;
}

/* Accessibility effects */
html.a11y-readable-font body,
html.a11y-readable-font button,
html.a11y-readable-font input,
html.a11y-readable-font textarea,
html.a11y-readable-font select{
  font-family:Arial,Helvetica,sans-serif !important;
}
html.a11y-big-cursor,
html.a11y-big-cursor *{
  cursor:crosshair !important;
}
html.a11y-monochrome{
  filter:grayscale(1);
}
html.a11y-hide-images img{
  visibility:hidden !important;
}
html.a11y-highlight-titles h1,
html.a11y-highlight-titles h2,
html.a11y-highlight-titles h3,
html.a11y-highlight-titles h4,
html.a11y-highlight-titles h5,
html.a11y-highlight-titles h6{
  outline:3px solid #ffcc00 !important;
  outline-offset:4px !important;
}
html.a11y-highlight-links a{
  outline:3px solid #ffcc00 !important;
  outline-offset:3px !important;
  text-decoration:underline !important;
  text-decoration-thickness:2px !important;
}
html.a11y-stop-animations *,
html.a11y-seizure-safe *,
html.a11y-epilepsy-safe *{
  animation-play-state:paused !important;
  animation-duration:0s !important;
  transition-duration:0s !important;
  scroll-behavior:auto !important;
}
html.a11y-low-vision{
  filter:contrast(1.25) saturate(1.12);
}
html.a11y-seizure-safe{
  filter:saturate(.45) contrast(.95);
}
html.a11y-epilepsy-safe{
  filter:saturate(.3) brightness(.86);
}
html.a11y-adhd .tile:not(:hover){
  opacity:.42;
  filter:saturate(.65);
}
html.a11y-blind-mode :focus-visible{
  outline:4px solid #ffcc00 !important;
  outline-offset:4px !important;
}
html.a11y-contrast-high{
  filter:contrast(1.55);
}
html.a11y-contrast-invert{
  filter:invert(1) hue-rotate(180deg);
}
html.a11y-text-left body *:not(.tile):not(.world){
  text-align:left !important;
}
html.a11y-text-center body *:not(.tile):not(.world){
  text-align:center !important;
}

.a11y-reading-line{
  position:fixed;
  left:0;
  right:0;
  height:3px;
  background:#ffcc00;
  z-index:9998;
  pointer-events:none;
  display:none;
  box-shadow:0 0 0 1px rgba(0,0,0,.35);
}
.a11y-reading-line.active{display:block}
.a11y-mask{
  position:fixed;
  left:0;
  right:0;
  background:rgba(0,0,0,.62);
  z-index:9997;
  pointer-events:none;
  display:none;
}
.a11y-mask.active{display:block}
.a11y-mask.top{top:0}
.a11y-mask.bottom{bottom:0}

.a11y-statement{
  max-width:620px;
  width:calc(100vw - 36px);
  border:0;
  border-radius:18px;
  padding:28px;
  background:#fff;
  color:#111;
  box-shadow:0 25px 80px rgba(0,0,0,.28);
}
.a11y-statement::backdrop{background:rgba(0,0,0,.5);backdrop-filter:blur(4px)}
.a11y-statement h2{margin:0 34px 16px 0;font-size:28px;letter-spacing:-.04em}
.a11y-statement p{font-size:14px;line-height:1.65;color:#555}
.a11y-statement-close{
  position:absolute;
  top:16px;
  right:18px;
  border:0;
  background:none;
  color:#111;
  font-size:28px;
  cursor:pointer;
}

@media(max-width:700px){
  .a11y-trigger:not(.a11y-trigger-inline){right:18px;bottom:78px}
  .a11y-panel{
    left:18px;
    bottom:18px;
    width:calc(100vw - 36px);
    max-height:calc(100vh - 36px);
  }
  .a11y-grid{grid-template-columns:1fr}
}


/* =========================================================
   V9 LAYOUT CORRECTIONS
   ========================================================= */

.bottom-left-tools{
  position:absolute;
  left:28px;
  bottom:24px;
  display:flex;
  align-items:center;
  gap:12px;
  pointer-events:auto;
}

.bottom-left-tools .zoom-ui{
  position:static;
  left:auto;
  bottom:auto;
}

.a11y-trigger.a11y-trigger-inline{
  position:static;
  right:auto;
  bottom:auto;
  width:34px;
  height:34px;
  font-size:16px;
  flex:0 0 34px;
}

.bottom-right-logo{
  position:absolute;
  right:28px;
  bottom:24px;
  pointer-events:auto;
  display:flex;
  align-items:center;
  justify-content:flex-end;
  text-decoration:none;
}

.bottom-right-logo img{
  display:block;
  width:auto;
  height:48px;
  max-width:180px;
  object-fit:contain;
}

.footer-center{
  position:absolute;
  left:50%;
  bottom:27px;
  transform:translateX(-50%);
  pointer-events:auto;
  color:var(--muted);
  font-size:10px;
  text-transform:uppercase;
  letter-spacing:.12em;
  white-space:nowrap;
}

.footer-center a{
  color:var(--fg);
  text-decoration:none;
  border-bottom:1px solid var(--line);
  padding-bottom:2px;
}

.footer-center a:hover{
  border-bottom-color:var(--fg);
}

@media(max-width:700px){
  .bottom-left-tools{
    left:18px;
    bottom:18px;
    gap:9px;
  }

  .footer-center{
    bottom:68px;
    font-size:9px;
  }

  .bottom-right-logo{
    right:18px;
    bottom:18px;
  }

  .bottom-right-logo img{
    height:38px;
    max-width:130px;
  }
}


/* =========================================================
   V10 - ACCESSIBILITY PANEL LEFT + V8 HELP TEXT RESTORED
   ========================================================= */

/* Accessibility popup opens on the left */
.a11y-panel{
  left:24px !important;
  right:auto !important;
}

.bottom-right-area{
  position:absolute;
  right:28px;
  bottom:24px;
  display:flex;
  align-items: flex-end;
  gap:18px;
  pointer-events:auto;
}

.bottom-right-area .help{
  position:static;
  right:auto;
  bottom:auto;
  text-align:right;
  color:var(--muted);
  line-height:1.75;
  pointer-events:none;
  white-space:nowrap;
}

.bottom-right-area .bottom-right-logo{
  position:static;
  right:auto;
  bottom:auto;
  display:flex;
  align-items:center;
  justify-content:flex-end;
}

@media(max-width:700px){
  .a11y-panel{
    left:18px !important;
    right:auto !important;
  }

  .bottom-right-area{
    right:18px;
    bottom:18px;
  }

  .bottom-right-area .help{
    display:none;
  }
}


/* =========================================================
   V11 - FOOTER FINAL LAYOUT
   ========================================================= */

/* Center: restore the original navigation instructions */
.footer-center.footer-help{
  position:absolute;
  left:50%;
  bottom:22px;
  transform:translateX(-50%);
  color:var(--muted);
  font-size:10px;
  line-height:1.75;
  text-align:center;
  text-transform:uppercase;
  letter-spacing:.12em;
  white-space:nowrap;
  pointer-events:none;
}

/* Right: logo above Privacy / Cookie links */
.bottom-right-area{
  position:absolute;
  right:28px;
  bottom:24px;
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:9px;
  pointer-events:auto;
}

.bottom-right-area .bottom-right-logo{
  position:static;
  display:flex;
  align-items:center;
  justify-content:flex-end;
  text-decoration:none;
}

.bottom-right-area .bottom-right-logo img{
  display:block;
  width:auto;
  height:48px;
  max-width:180px;
  object-fit:contain;
}

.bottom-right-links{
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap:4px;
  color:var(--muted);
  font-size:10px;
  text-transform:none;
  letter-spacing:.12em;
  white-space:nowrap;
}

.bottom-right-links a{
  color:var(--fg);
  text-decoration:none;
  border-bottom:1px solid var(--line);
  padding-bottom:2px;
}

.bottom-right-links a:hover{
  border-bottom-color:var(--fg);
}

.bottom-right-links span{
  color:var(--muted);
}

/* old help block is no longer used */
.bottom-right-area .help{
  display:none !important;
}

@media(max-width:700px){
  .footer-center.footer-help{
    bottom:72px;
    font-size:9px;
    line-height:1.6;
  }

  .bottom-right-area{
    right:18px;
    bottom:18px;
    gap:7px;
  }

  .bottom-right-area .bottom-right-logo img{
    height:38px;
    max-width:130px;
  }

  .bottom-right-links{
    font-size:9px;
  }
}


.panel-desc strong{
  font-weight:700;
  opacity:1;
  color:inherit;
}


/* =========================================================
   V15 - PRIVACY POPUP
   ========================================================= */

.bottom-right-links .cookie-label{
  color:var(--fg);
  padding-bottom:2px;
  cursor:default;
}

.privacy-links .cookie-label{
  color:inherit;
  opacity:.7;
}

.privacy-modal-overlay{
  position:fixed;
  inset:0;
  z-index:120;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:24px;
  background:rgba(0,0,0,.58);
  backdrop-filter:blur(5px);
  -webkit-backdrop-filter:blur(5px);
  opacity:0;
  visibility:hidden;
  pointer-events:none;
  transition:opacity .35s ease, visibility .35s ease;
}

.privacy-modal-overlay.open{
  opacity:1;
  visibility:visible;
  pointer-events:auto;
}

.privacy-modal-box{
  width:min(550px,92vw);
  height:min(550px,86vh);
  background:#fff;
  color:#111;
  border-radius:18px;
  overflow:hidden;
  box-shadow:0 24px 80px rgba(0,0,0,.28);
  transform:translateY(18px) scale(.985);
  opacity:0;
  transition:transform .38s cubic-bezier(.22,.61,.36,1), opacity .32s ease;
}

.privacy-modal-overlay.open .privacy-modal-box{
  transform:translateY(0) scale(1);
  opacity:1;
}

.privacy-modal-head{
  height:40px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding:0 20px 0 24px;
  border-bottom:1px solid rgba(0,0,0,.1);
  background:#fff;
}

.privacy-modal-head h2{
  margin:0;
  font-size:16px;
  font-weight:600;
  letter-spacing:.02em;
}

.privacy-modal-close{
  border:0;
  background:transparent;
  color:#111;
  font-size:30px;
  line-height:1;
  cursor:pointer;
  padding:4px 6px;
}

.privacy-modal-box iframe{
  display:block;
  width:100%;
  height:calc(100% - 60px);
  border:0;
  background:#fff;
}

html.privacy-modal-open,
html.privacy-modal-open body{
  overflow:hidden !important;
}

@media(max-width:700px){
  .privacy-modal-overlay{
    padding:14px;
  }

  .privacy-modal-box{
    width:100%;
    height:88vh;
    border-radius:14px;
  }
}


/* =========================================================
   V16 - PANNELLO DETTAGLIO SCROLLABILE
   ========================================================= */
.panel{
  overflow-y:auto;
  overflow-x:hidden;
  overscroll-behavior:contain;
  -webkit-overflow-scrolling:touch;
  scrollbar-gutter:stable;
}


/* =========================================================
   V17 - MOBILE + PAGINAZIONE
   ========================================================= */

/* Paginazione centrale */
.portfolio-pagination{
  position:absolute;
  left:50%;
  bottom:86px;
  transform:translateX(-50%);
  display:flex;
  align-items:center;
  justify-content:center;
  gap:10px;
  pointer-events:auto;
  z-index:4;
}

.portfolio-pagination a{
  min-width:26px;
  height:26px;
  padding:0 7px;
  display:grid;
  place-items:center;
  border:1px solid var(--line);
  border-radius:999px;
  color:var(--muted);
  text-decoration:none;
  font-size:9px;
  letter-spacing:.08em;
  background:color-mix(in srgb,var(--bg) 86%,transparent);
  backdrop-filter:blur(8px);
  -webkit-backdrop-filter:blur(8px);
  transition:background .25s var(--ease),color .25s var(--ease),border-color .25s var(--ease);
}

.portfolio-pagination a:hover,
.portfolio-pagination a.active{
  background:var(--fg);
  color:var(--bg);
  border-color:var(--fg);
}

/* SOLO MOBILE */
@media(max-width:700px){

  /* Il browser non intercetta più swipe/drag sulla griglia */
  .viewport,
  .world,
  .tile{
    touch-action:none !important;
    -ms-touch-action:none !important;
  }

  .tile img{
    -webkit-user-drag:none;
  }

  /* Pannelli e popup restano normalmente scrollabili col dito */
  .panel,
  .a11y-panel,
  .privacy-modal-box,
  .privacy-pop{
    touch-action:pan-y !important;
  }

  /* Logo fisso/sticky in alto a sinistra */
  .logo{
    position:fixed !important;
    left:14px !important;
    top:14px !important;
  }

  /* Popup accessibilità più compatto su smartphone */
  .a11y-panel{
    left:12px !important;
    right:auto !important;
    bottom:62px !important;
    width:min(318px,calc(100vw - 24px)) !important;
    max-height:62vh !important;
    max-height:62dvh !important;
    padding:12px !important;
    border-radius:14px !important;
  }

  .a11y-header{
    gap:10px !important;
    padding-bottom:10px !important;
  }

  .a11y-header h2{
    font-size:16px !important;
    line-height:1.05 !important;
  }

  .a11y-eyebrow{
    font-size:8px !important;
  }

  .a11y-close{
    font-size:24px !important;
  }

  .a11y-section{
    padding:10px 0 0 !important;
  }

  .a11y-section h3{
    margin-bottom:7px !important;
    font-size:9px !important;
  }

  .a11y-grid{
    grid-template-columns:1fr 1fr !important;
    gap:6px !important;
  }

  .a11y-grid.profiles{
    grid-template-columns:1fr !important;
  }

  .a11y-card,
  .a11y-tool{
    min-height:48px !important;
    border-radius:9px !important;
  }

  .a11y-card{
    padding:8px 9px !important;
  }

  .a11y-card strong{
    font-size:11px !important;
  }

  .a11y-card span{
    font-size:9px !important;
  }

  .a11y-tool{
    padding:7px !important;
    grid-template-columns:25px 1fr auto !important;
    gap:6px !important;
    font-size:9px !important;
  }

  .a11y-icon{
    width:24px !important;
    height:24px !important;
    border-radius:6px !important;
    font-size:9px !important;
  }

  .a11y-footer{
    gap:6px !important;
    padding-top:10px !important;
    margin-top:8px !important;
  }

  .a11y-footer button{
    padding:8px 6px !important;
    font-size:8px !important;
  }

  .a11y-shortcut{
    display:none !important;
  }

  /* Paginazione sopra le scritte centrali */
  .portfolio-pagination{
    bottom:122px;
    gap:8px;
  }

  .portfolio-pagination a{
    min-width:24px;
    height:24px;
    font-size:8px;
  }
}


/* =========================================================
   V18 - PRIVACY POPUP MOBILE PIÙ COMPATTO
   ========================================================= */
@media(max-width:700px){

  .privacy-modal-overlay{
    padding:18px !important;
    align-items:center !important;
    justify-content:center !important;
  }

  .privacy-modal-box{
    width:min(330px,calc(100vw - 36px)) !important;
    height:min(520px,64vh) !important;
    max-height:64vh !important;
    max-height:64dvh !important;
    border-radius:14px !important;
  }

  .privacy-modal-head{
    height:48px !important;
    padding:0 14px 0 16px !important;
  }

  .privacy-modal-head h2{
    font-size:14px !important;
  }

  .privacy-modal-close{
    font-size:24px !important;
    padding:2px 4px !important;
  }

  .privacy-modal-box iframe{
    height:calc(100% - 48px) !important;
  }
}
