/* Pagine legali CR8 Booking — standalone */

:root {
  --bg: #09090b;
  --text: #eef2f6;
  --muted: #8b9cb0;
  --accent: #e8941e;
  --accent-glow: rgba(232, 148, 30, 0.35);
  --border: rgba(255, 255, 255, 0.1);
  --surface: rgba(17, 17, 24, 0.92);
  --surface-hi: rgba(24, 24, 31, 0.96);
  --ok: #4ade80;
  --font: 'Plus Jakarta Sans', system-ui, sans-serif;
  --font-display: 'Outfit', 'Plus Jakarta Sans', system-ui, sans-serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --cr8-ease: cubic-bezier(0.22, 1, 0.36, 1);
  --r: 14px;
  --r-lg: 20px;
  --wave-h: clamp(80px, 14vw, 140px);
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-right: env(safe-area-inset-right, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --safe-left: env(safe-area-inset-left, 0px);
  --header-pad-y: 0.75rem;
  --header-pad-y-desktop: 0.85rem;
  --logo-h: 3.25rem;
  --logo-h-desktop: 3.5rem;
}

html[data-theme='light'] {
  --bg: #f4f6fa;
  --text: #0c1220;
  --muted: #5a6b7d;
  --accent: #cf7718;
  --accent-glow: rgba(232, 148, 30, 0.2);
  --border: rgba(0, 0, 0, 0.08);
  --surface: rgba(255, 255, 255, 0.92);
  --surface-hi: #ffffff;
}

*, *::before, *::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  overflow-x: hidden;
}

body.legal-page {
  margin: 0;
  min-height: 100dvh;
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.5;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

.legal-page {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  overflow-x: clip;
  max-width: 100%;
  position: relative;
}

.legal-page__bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 70% 50% at 50% -10%, rgba(232, 148, 30, 0.12), transparent 60%),
    radial-gradient(ellipse 50% 40% at 100% 50%, rgba(232, 148, 30, 0.06), transparent 55%),
    radial-gradient(ellipse 40% 35% at 0% 80%, rgba(232, 148, 30, 0.05), transparent 50%);
}

.wrap {
  width: min(1140px, calc(100% - 32px));
  margin-inline: auto;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text);
  font: 600 14px/1 var(--font);
  text-decoration: none;
  cursor: pointer;
  transition:
    color 0.2s var(--ease),
    background 0.2s var(--ease),
    border-color 0.2s var(--ease);
}

.btn--ghost:hover {
  color: var(--text);
  background: color-mix(in srgb, var(--accent) 10%, var(--surface));
  border-color: color-mix(in srgb, var(--accent) 25%, var(--border));
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: var(--accent);
  color: #09090b;
  font: 700 14px/1 var(--font);
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 0 24px var(--accent-glow);
  transition:
    background 0.2s var(--cr8-ease),
    border-color 0.2s var(--cr8-ease),
    transform 0.15s var(--cr8-ease);
}

.btn-primary:hover {
  background: #cf7718;
  border-color: rgba(255, 255, 255, 0.3);
}

.mobile-menu__cta .btn-primary,
.mobile-menu__cta .btn--ghost {
  width: 100%;
  padding-top: 1rem;
  padding-bottom: 1rem;
  font-size: 1rem;
  justify-content: center;
}

.btn--sm {
  padding: 9px 14px;
  font-size: 13px;
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  padding: 0;
  border: none;
  background: transparent;
  cursor: pointer;
}

.theme-toggle__track {
  position: relative;
  display: block;
  width: 52px;
  height: 28px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--border);
  transition: background 0.25s var(--ease);
}

.theme-toggle__thumb {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 2px 8px var(--accent-glow);
  transition: transform 0.28s var(--ease);
  display: grid;
  place-items: center;
}

html[data-theme='light'] .theme-toggle__thumb {
  transform: translateX(24px);
}

.theme-toggle__icon {
  position: absolute;
  width: 12px;
  height: 12px;
  color: #041018;
}

.theme-toggle__icon--sun {
  opacity: 0;
}

.theme-toggle__icon--moon {
  opacity: 1;
}

html[data-theme='light'] .theme-toggle__icon--sun {
  opacity: 1;
}

html[data-theme='light'] .theme-toggle__icon--moon {
  opacity: 0;
}

.site-footer {
  position: relative;
  z-index: 1;
  padding: 48px 0 24px;
}

.site-footer__grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, minmax(0, 1fr));
  gap: 28px 32px;
}

.site-footer__brand p {
  margin: 12px 0 0;
  font-size: 13px;
  color: var(--muted);
  line-height: 1.55;
}

.site-footer__grid h4 {
  margin: 0 0 12px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.site-footer__grid a {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: color 0.2s var(--ease);
}

.site-footer__grid a:hover {
  color: var(--accent);
}

.site-footer__bottom {
  margin-top: 28px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  text-align: center;
}

.site-footer__bottom p {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
}

.site-footer__bottom a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
}

.site-footer__bottom a:hover {
  text-decoration: underline;
}

@media (max-width: 900px) {
  .site-footer__grid {
    grid-template-columns: 1fr 1fr;
  }

  .site-footer__brand {
    grid-column: 1 / -1;
  }
}

@media (max-width: 560px) {
  .site-footer__grid {
    grid-template-columns: 1fr;
  }
}

.theme-toggle--menu {
  align-self: center;
  margin-top: 0.25rem;
}

/* ─── Header (identico landing) ─── */
.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  padding-top: var(--safe-top);
  overflow: visible;
  transition:
    background 0.3s var(--cr8-ease),
    border-color 0.3s var(--cr8-ease),
    box-shadow 0.3s var(--cr8-ease);
}

.site-header.is-scrolled {
  border-bottom: 1px solid var(--border);
  background: color-mix(in srgb, var(--bg) 90%, transparent);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

.site-header.is-menu-open {
  pointer-events: none;
}

.site-header.is-menu-open .site-header__logo-link,
.site-header.is-menu-open .site-header__toggle-wrap {
  pointer-events: auto;
}

.site-header__bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.75rem 1rem;
  padding-block: var(--header-pad-y);
}

.site-header__logo-link {
  display: block;
  width: fit-content;
  max-width: min(88vw, 24rem);
  line-height: 0;
  flex-shrink: 0;
  overflow: visible;
  transform: translateY(0.6rem);
  transition: opacity 0.18s ease;
  text-decoration: none;
}

.site-header__logo-link:hover {
  opacity: 0.88;
}

.booking-logo {
  display: block;
  height: var(--logo-h);
  width: auto;
  max-width: 100%;
  object-fit: contain;
  filter: drop-shadow(0 0 24px rgba(99, 68, 212, 0.45));
}

.legal-footer__logo {
  filter: drop-shadow(0 0 20px rgba(99, 68, 212, 0.4));
}

.site-header__nav {
  display: none;
  align-items: center;
  justify-self: center;
}

.site-header__actions {
  display: none;
  align-items: center;
  gap: 0.625rem;
  justify-self: end;
}

.site-header__nav-link {
  white-space: nowrap;
  padding: 0.5rem 0.85rem;
  border-radius: 999px;
  font: 500 0.8125rem/1 var(--font);
  color: var(--muted);
  text-decoration: none;
  transition: color 0.2s var(--cr8-ease);
}

.site-header__nav-link:hover {
  color: var(--accent);
}

.site-header__nav-link.is-active {
  color: var(--accent);
}

.site-header__toggle-wrap {
  justify-self: end;
}

.menu-toggle {
  position: relative;
  z-index: 110;
  display: flex;
  height: 3rem;
  width: 3rem;
  flex-shrink: 0;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
  transition:
    border-color 0.25s var(--cr8-ease),
    background 0.25s var(--cr8-ease),
    box-shadow 0.25s var(--cr8-ease);
}

.menu-toggle:hover {
  border-color: rgba(99, 68, 212, 0.35);
  background: rgba(99, 68, 212, 0.08);
}

.menu-toggle.is-open {
  border-color: rgba(99, 68, 212, 0.45);
  background: rgba(99, 68, 212, 0.12);
  box-shadow: 0 0 24px rgba(99, 68, 212, 0.2);
}

.menu-toggle__lines {
  position: relative;
  display: block;
  height: 14px;
  width: 20px;
}

.menu-toggle__line {
  position: absolute;
  left: 0;
  display: block;
  height: 2px;
  width: 100%;
  border-radius: 9999px;
  background: rgb(255 255 255);
  transform-origin: center;
  transition:
    transform 0.38s var(--cr8-ease),
    opacity 0.28s var(--cr8-ease),
    top 0.38s var(--cr8-ease),
    width 0.38s var(--cr8-ease);
}

.menu-toggle__line:nth-child(1) {
  top: 0;
}

.menu-toggle__line:nth-child(2) {
  top: 6px;
}

.menu-toggle__line:nth-child(3) {
  top: 12px;
  width: 70%;
}

.menu-toggle.is-open .menu-toggle__line:nth-child(1) {
  top: 6px;
  transform: rotate(45deg);
}

.menu-toggle.is-open .menu-toggle__line:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.menu-toggle.is-open .menu-toggle__line:nth-child(3) {
  top: 6px;
  width: 100%;
  transform: rotate(-45deg);
}

.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: #050508;
  clip-path: circle(0% at calc(100% - 2.25rem - var(--safe-right)) calc(1rem + var(--safe-top) + 1.5rem));
  visibility: hidden;
  pointer-events: none;
  will-change: clip-path;
  transition:
    clip-path 0.72s var(--cr8-ease),
    visibility 0s linear 0.72s;
}

.mobile-menu[hidden] {
  display: none !important;
}

.mobile-menu.is-open {
  clip-path: circle(160% at calc(100% - 2.25rem - var(--safe-right)) calc(1rem + var(--safe-top) + 1.5rem));
  visibility: visible;
  pointer-events: auto;
  transition:
    clip-path 0.72s var(--cr8-ease),
    visibility 0s;
}

.mobile-menu.is-closing {
  clip-path: circle(0% at calc(100% - 2.25rem - var(--safe-right)) calc(1rem + var(--safe-top) + 1.5rem));
  visibility: visible;
  pointer-events: none;
  transition:
    clip-path 0.5s var(--cr8-ease),
    visibility 0s linear 0.5s;
}

.mobile-menu__backdrop {
  pointer-events: none;
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 50% at 50% -10%, rgba(99, 68, 212, 0.22), transparent 55%),
    radial-gradient(ellipse 60% 40% at 100% 100%, rgba(99, 68, 212, 0.12), transparent 50%),
    linear-gradient(180deg, #0a0e16 0%, #050508 45%, #050508 100%);
}

.mobile-menu__grid {
  pointer-events: none;
  position: absolute;
  inset: 0;
  opacity: 0.35;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(180deg, black 0%, transparent 85%);
}

.mobile-menu__inner {
  position: relative;
  z-index: 1;
  display: flex;
  min-height: 100%;
  flex-direction: column;
  padding:
    calc(1rem + var(--safe-top))
    calc(1.25rem + var(--safe-right))
    calc(1.5rem + var(--safe-bottom))
    calc(1.25rem + var(--safe-left));
}

.mobile-menu__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 2.5rem;
  opacity: 0;
  transform: translateY(-12px);
}

.mobile-menu.is-open .mobile-menu__top {
  animation: legal-menu-top-in 0.45s var(--cr8-ease) 0.08s forwards;
}

.mobile-menu.is-closing .mobile-menu__top {
  animation: legal-menu-top-out 0.2s var(--cr8-ease) forwards;
}

.mobile-menu__logo-link {
  display: block;
  line-height: 0;
  text-decoration: none;
}

.mobile-menu__logo.booking-logo {
  height: 3.25rem;
  width: auto;
  max-width: min(88vw, 22rem);
}

.mobile-menu__nav {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.35rem;
}

.mobile-menu__item {
  opacity: 0;
  transform: translateX(32px);
  filter: blur(6px);
}

.mobile-menu.is-open .mobile-menu__item {
  animation: legal-menu-link-in 0.5s var(--cr8-ease) forwards;
}

.mobile-menu.is-open .mobile-menu__item:nth-child(1) { animation-delay: 0.12s; }
.mobile-menu.is-open .mobile-menu__item:nth-child(2) { animation-delay: 0.19s; }
.mobile-menu.is-open .mobile-menu__item:nth-child(3) { animation-delay: 0.26s; }
.mobile-menu.is-open .mobile-menu__item:nth-child(4) { animation-delay: 0.33s; }
.mobile-menu.is-open .mobile-menu__item:nth-child(5) { animation-delay: 0.4s; }

.mobile-menu.is-closing .mobile-menu__item {
  animation: legal-menu-link-out 0.2s var(--cr8-ease) forwards;
}

.mobile-menu__link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  font-size: clamp(1.65rem, 7vw, 2.25rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
  color: rgba(255, 255, 255, 0.92);
  text-decoration: none;
  transition: color 0.2s var(--cr8-ease);
}

.mobile-menu__link:active,
.mobile-menu__link.is-active {
  color: rgb(58 190 249);
}

.mobile-menu__link-arrow {
  flex-shrink: 0;
  font-size: 1.25rem;
  font-weight: 400;
  color: rgb(58 190 249);
  opacity: 0.7;
  transition:
    transform 0.25s var(--cr8-ease),
    opacity 0.25s var(--cr8-ease);
}

.mobile-menu__link:hover .mobile-menu__link-arrow {
  opacity: 1;
  transform: translateX(4px);
}

.mobile-menu__cta {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 2rem;
  opacity: 0;
  transform: translateY(24px);
}

.mobile-menu.is-open .mobile-menu__cta {
  animation: legal-menu-cta-in 0.5s var(--cr8-ease) 0.45s forwards;
}

.mobile-menu.is-closing .mobile-menu__cta {
  animation: legal-menu-cta-out 0.2s var(--cr8-ease) forwards;
}

.mobile-menu:not(.is-open):not(.is-closing) .mobile-menu__top,
.mobile-menu:not(.is-open):not(.is-closing) .mobile-menu__item,
.mobile-menu:not(.is-open):not(.is-closing) .mobile-menu__cta {
  opacity: 0;
  animation: none;
}

.mobile-menu:not(.is-open):not(.is-closing) .mobile-menu__item {
  transform: translateX(32px);
  filter: blur(6px);
}

.mobile-menu:not(.is-open):not(.is-closing) .mobile-menu__top {
  transform: translateY(-12px);
}

.mobile-menu:not(.is-open):not(.is-closing) .mobile-menu__cta {
  transform: translateY(24px);
}

@keyframes legal-menu-top-in {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes legal-menu-top-out {
  to {
    opacity: 0;
    transform: translateY(-8px);
  }
}

@keyframes legal-menu-link-in {
  to {
    opacity: 1;
    transform: translateX(0);
    filter: blur(0);
  }
}

@keyframes legal-menu-link-out {
  to {
    opacity: 0;
    transform: translateX(16px);
    filter: blur(4px);
  }
}

@keyframes legal-menu-cta-in {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes legal-menu-cta-out {
  to {
    opacity: 0;
    transform: translateY(12px);
  }
}

.mobile-menu__tagline {
  margin: 0.5rem 0 0;
  text-align: center;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgb(122 138 168 / 0.75);
}

@media (min-width: 1280px) {
  .site-header__bar {
    grid-template-columns: minmax(0, max-content) minmax(0, 1fr) auto;
    gap: 1rem 2.5rem;
    padding-block: var(--header-pad-y-desktop);
  }

  .site-header__nav,
  .site-header__actions {
    display: flex;
  }

  .site-header__toggle-wrap,
  .menu-toggle,
  .legal-mobile-menu {
    display: none !important;
  }

  .booking-logo,
  .site-header__logo.booking-logo {
    height: var(--logo-h-desktop);
  }

  .site-header__nav-link {
    padding-inline: 1rem;
    font-size: 0.875rem;
  }
}

html[data-theme='light'] .site-header.is-scrolled {
  background: rgba(255, 255, 255, 0.92);
}

html[data-theme='light'] .booking-logo__cr {
  fill: #0c1220;
}

html[data-theme='light'] .booking-logo__booking {
  fill: #64748b;
}

html[data-theme='light'] .menu-toggle__line {
  background: #0c1220;
}

html[data-theme='light'] .menu-toggle {
  border-color: rgba(0, 0, 0, 0.1);
  background: rgba(0, 0, 0, 0.03);
}

@media (prefers-reduced-motion: reduce) {
  .mobile-menu,
  .mobile-menu.is-open,
  .mobile-menu.is-closing {
    transition: none;
    clip-path: none;
  }

  .mobile-menu__top,
  .mobile-menu__item,
  .mobile-menu__cta {
    opacity: 1;
    transform: none;
    filter: none;
    animation: none !important;
  }

  .menu-toggle__line {
    transition: none;
  }
}

@media (max-width: 1279px) {
  html,
  body.legal-page {
    overflow-x: hidden;
    max-width: 100%;
    overscroll-behavior-x: none;
    touch-action: pan-y;
  }

  .legal-page,
  .legal-main,
  .legal-main__inner,
  .legal-doc,
  .legal-doc-card,
  .wrap,
  .site-header__bar {
    max-width: 100%;
    overflow-x: clip;
  }

  .legal-table-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    max-width: 100%;
  }
}

html.legal-scroll-lock,
html.legal-scroll-lock body.legal-page {
  overflow: hidden;
  overscroll-behavior: none;
}

/* ─── Main content ─── */
.legal-main {
  position: relative;
  z-index: 1;
  flex: 1;
  padding: calc(5.5rem + var(--safe-top)) 0 64px;
  min-width: 0;
  max-width: 100%;
}

.legal-main__inner {
  display: grid;
  gap: 24px;
  min-width: 0;
  justify-items: center;
}

.legal-doc-card {
  width: 100%;
  max-width: 780px;
  margin: 0 auto;
  min-width: 0;
  overflow-x: clip;
  padding: clamp(28px, 5vw, 40px) clamp(24px, 4vw, 36px);
  border-radius: var(--r-lg);
  border: 1px solid var(--border);
  background: linear-gradient(
    165deg,
    color-mix(in srgb, var(--surface-hi) 90%, transparent) 0%,
    color-mix(in srgb, var(--surface) 70%, transparent) 100%
  );
  box-shadow:
    0 24px 64px rgba(0, 0, 0, 0.22),
    0 0 0 1px color-mix(in srgb, var(--accent) 6%, transparent) inset;
}

.legal-doc__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 12px;
  padding: 6px 12px;
  border-radius: 999px;
  font: 700 11px/1 var(--font);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  background: color-mix(in srgb, var(--accent) 12%, transparent);
  border: 1px solid color-mix(in srgb, var(--accent) 25%, transparent);
}

.legal-doc__title {
  margin: 0 0 10px;
  font-size: clamp(1.75rem, 4.5vw, 2.35rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.legal-doc__updated {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 28px;
  padding: 8px 12px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
  background: var(--surface);
  border: 1px solid var(--border);
}

.legal-doc__updated::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--ok);
  box-shadow: 0 0 8px color-mix(in srgb, var(--ok) 60%, transparent);
}

.legal-lead {
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--muted);
  margin: 0 0 28px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border);
}

.legal-doc h2 {
  margin: 36px 0 14px;
  padding-top: 8px;
  font-size: 1.125rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
  scroll-margin-top: 88px;
}

.legal-doc h2:first-of-type {
  margin-top: 0;
}

.legal-doc p {
  margin: 0 0 14px;
  line-height: 1.7;
  color: color-mix(in srgb, var(--text) 92%, var(--muted));
  overflow-wrap: anywhere;
  word-break: break-word;
}

.legal-doc li {
  margin-bottom: 8px;
  line-height: 1.65;
  color: color-mix(in srgb, var(--text) 92%, var(--muted));
  overflow-wrap: anywhere;
  word-break: break-word;
}

.legal-doc ul,
.legal-doc ol {
  padding-left: 1.35rem;
  margin: 0 0 18px;
}

.legal-doc strong {
  color: var(--text);
  font-weight: 700;
}

.legal-doc a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
  transition: opacity 0.15s;
}

.legal-doc a:hover {
  text-decoration: underline;
  opacity: 0.9;
}

.legal-doc code {
  font-size: 0.88em;
  padding: 3px 8px;
  border-radius: 8px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text);
  overflow-wrap: anywhere;
  word-break: break-word;
}

.legal-note {
  font-size: 14px;
  line-height: 1.6;
  color: var(--muted);
  border-left: 3px solid var(--accent);
  padding: 12px 16px;
  margin: 20px 0;
  border-radius: 0 12px 12px 0;
  background: color-mix(in srgb, var(--accent) 8%, var(--surface));
}

.legal-table-wrap {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 16px 0 24px;
  border-radius: 12px;
  border: 1px solid var(--border);
  scrollbar-width: thin;
}

.legal-table-wrap .legal-table {
  margin: 0;
  border: none;
  border-radius: 0;
  min-width: 520px;
}

.legal-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 13px;
  margin: 16px 0 24px;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border);
}

.legal-table th,
.legal-table td {
  border-bottom: 1px solid var(--border);
  padding: 12px 14px;
  text-align: left;
  vertical-align: top;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.legal-table tr:last-child th,
.legal-table tr:last-child td {
  border-bottom: none;
}

.legal-table th {
  background: color-mix(in srgb, var(--accent) 10%, var(--surface));
  font-weight: 700;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
}

.legal-table td {
  background: var(--surface);
}

.legal-table tbody tr:hover td {
  background: color-mix(in srgb, var(--accent) 5%, var(--surface));
}

/* ─── Footer legale ─── */
.legal-footer {
  margin-top: auto;
  border-top: 1px solid var(--border);
  max-width: 100%;
  overflow-x: clip;
}

.legal-footer .wrap {
  width: min(1140px, calc(100% - 32px));
  margin-inline: auto;
}

.legal-footer .site-footer__brand img {
  width: min(200px, 100%);
  height: auto;
}

.site-footer__legal {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  justify-content: center;
  margin-top: 8px;
  font-size: 12px;
}

.site-footer__legal a {
  display: inline;
  color: var(--muted);
  text-decoration: none;
}

.site-footer__legal a:hover {
  color: var(--accent);
}

@media (max-width: 640px) {
  .wrap,
  .legal-footer .wrap {
    width: min(1140px, calc(100% - 24px));
  }

  .site-header__bar.wrap {
    width: min(1140px, calc(100% - 24px));
  }

  .legal-doc-card {
    padding: 22px 16px;
    border-radius: var(--r);
  }

  .legal-doc__title {
    font-size: clamp(1.5rem, 7vw, 1.85rem);
  }
}

/* ─── Wave layout (stile Studios) ─── */
.wave-section {
  overflow: hidden;
  position: relative;
}

.section-dark {
  background: var(--bg);
  color: var(--text);
}

.section-on-accent {
  background: var(--accent);
  color: #09090b;
}

.wave-wrap {
  z-index: 3;
  flex-shrink: 0;
  width: 100%;
  margin-bottom: -2px;
  line-height: 0;
  display: block;
  position: relative;
  overflow: hidden;
}

.wave-wrap--flip {
  transform: scaleY(-1);
  margin-bottom: 0;
  margin-top: -2px;
}

.wave-layer {
  width: 120%;
  max-width: none;
  height: var(--wave-h);
  margin-left: -10%;
  display: block;
}

.wave-animate .wave-layer-front {
  will-change: transform;
  animation: 10s ease-in-out infinite legal-wave-drift;
}

@keyframes legal-wave-drift {
  0%, 100% { transform: translateX(0); }
  50% { transform: translateX(-2%); }
}

@media (prefers-reduced-motion: reduce) {
  .wave-animate .wave-layer-front {
    animation: none !important;
  }
}

/* Hero legale */
.legal-hero {
  padding: calc(5.5rem + var(--safe-top)) 0 0;
  position: relative;
}

.legal-hero__inner {
  position: relative;
  z-index: 1;
  padding: 2.5rem 0 1.5rem;
  max-width: 48rem;
}

.legal-hero__blob {
  pointer-events: none;
  position: absolute;
  border-radius: 9999px;
  filter: blur(48px);
  background: rgba(232, 148, 30, 0.12);
}

.legal-hero__blob--a {
  right: -4rem;
  top: 5rem;
  width: 16rem;
  height: 16rem;
}

.legal-hero__blob--b {
  left: -3rem;
  bottom: 2rem;
  width: 12rem;
  height: 12rem;
  background: rgba(232, 148, 30, 0.08);
}

.legal-hero__eyebrow {
  margin: 0;
  font: 700 0.6875rem/1 var(--font);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
}

.legal-hero__title {
  margin: 0.75rem 0 0;
  font-family: var(--font-display);
  font-size: clamp(2rem, 6vw, 3rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.1;
}

.legal-hero__updated {
  margin: 0.85rem 0 0;
  font-size: 0.875rem;
  color: var(--muted);
}

/* Body + pills */
.legal-body-section {
  position: relative;
  padding: 2.5rem 0 0;
}

.legal-body-section__inner {
  position: relative;
  z-index: 1;
  max-width: 48rem;
  padding-bottom: 2rem;
}

.legal-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.75rem;
}

.legal-pill {
  display: inline-flex;
  align-items: center;
  padding: 0.45rem 0.9rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.03);
  color: var(--muted);
  font-size: 0.8125rem;
  font-weight: 600;
  text-decoration: none;
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}

.legal-pill:hover {
  border-color: rgba(232, 148, 30, 0.35);
  color: var(--text);
}

.legal-pill.is-active {
  border-color: rgba(232, 148, 30, 0.45);
  background: rgba(232, 148, 30, 0.14);
  color: var(--accent);
}

.legal-doc-panel {
  width: 100%;
  padding: clamp(1.5rem, 4vw, 2.25rem);
  border-radius: 1.25rem;
  border: 1px solid var(--border);
  background: #111118;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.28);
}

.legal-doc-panel .legal-lead {
  margin-top: 0;
}

.legal-doc-panel h2 {
  font-family: var(--font-display);
  margin: 2rem 0 0.75rem;
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.legal-doc-panel h2:first-of-type {
  margin-top: 0.5rem;
}

/* Footer accent zone */
.legal-footer-zone {
  position: relative;
  z-index: 1;
  margin-top: -2px;
  padding: 2.5rem 0 calc(2rem + var(--safe-bottom));
}

.legal-footer-zone__inner {
  max-width: 72rem;
}

.legal-footer-zone__brand {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2rem;
}

.legal-footer-zone__name {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.legal-footer-zone__meta {
  margin: 0.15rem 0 0;
  font-size: 0.8125rem;
  opacity: 0.85;
}

.legal-footer-zone__cols {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-bottom: 2rem;
}

.legal-footer-zone__cols h4 {
  margin: 0 0 0.65rem;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  opacity: 0.75;
}

.legal-footer-zone__cols a {
  display: block;
  padding: 0.3rem 0;
  color: inherit;
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  opacity: 0.92;
}

.legal-footer-zone__cols a:hover {
  opacity: 1;
  text-decoration: underline;
}

.legal-footer-zone__copy {
  margin: 0;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(0, 0, 0, 0.18);
  font-size: 0.75rem;
  opacity: 0.85;
}

.legal-footer-zone__copy a {
  color: inherit;
  font-weight: 600;
}

@media (max-width: 720px) {
  .legal-footer-zone__cols {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }

  .legal-hero__inner {
    padding: 2rem 0 1rem;
  }
}

html[data-theme='light'] .legal-doc-panel {
  background: #fff;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.08);
}

html[data-theme='light'] .legal-pill {
  background: rgba(0, 0, 0, 0.03);
}

html[data-theme='light'] .legal-pill.is-active {
  background: rgba(232, 148, 30, 0.12);
}
