/* ════════════════════════════════════════════════════
   Studio Legale D'Angelo — main.css
   Stili condivisi tra tutte le pagine del sito
   ════════════════════════════════════════════════════ */

/* ─── VARIABILI ─── */
:root {
  --black:       #0D0D0D;
  --gold:        #B8942A;
  --gold-hover:  #CBA93E;
  --white:       #FAFAFA;
  --paper:       #F3F1EC;
  --gray:        #666666;
  --gray-lt:     #999999;
  --border-gold: rgba(184,148,42,.22);

  --ff-display:  'Cormorant Garamond', Georgia, serif;
  --ff-body:     'DM Sans', system-ui, sans-serif;

  --max-w:  1200px;
  --nav-h:  70px;
  --ease:   cubic-bezier(.16,1,.3,1);
}

/* ─── RESET ─── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  background: var(--white);
  color: var(--black);
  font-family: var(--ff-body);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, svg { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
address { font-style: normal; }

/* ─── LAYOUT ─── */
.container {
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
}
@media (min-width: 768px)  { .container { padding: 0 40px; } }
@media (min-width: 1200px) { .container { padding: 0 64px; } }

/* ─── TYPOGRAPHY HELPERS ─── */
.eyebrow {
  display: block;
  font-family: var(--ff-body);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--gold);
}

/* ─── BUTTONS ─── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--ff-body);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .14em;
  text-transform: uppercase;
  padding: 14px 30px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background .25s var(--ease), border-color .25s var(--ease), color .25s var(--ease);
  white-space: nowrap;
}
.btn-gold {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--black);
}
.btn-gold:hover { background: var(--gold-hover); border-color: var(--gold-hover); }

.btn-outline-white {
  background: transparent;
  border-color: rgba(250,250,250,.28);
  color: var(--white);
}
.btn-outline-white:hover { border-color: var(--white); }

.btn-outline-dark {
  background: transparent;
  border-color: rgba(13,13,13,.28);
  color: var(--black);
}
.btn-outline-dark:hover { border-color: var(--black); }

.btn-dark {
  background: var(--black);
  border-color: var(--black);
  color: var(--white);
}
.btn-dark:hover { background: #1c1c1c; }

/* ─── NAVBAR ─── */
.navbar {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 200;
  height: var(--nav-h);
  background: rgba(13,13,13,.97);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-gold);
  transition: border-color .3s;
}
.navbar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}
/* Logo desktop (orizzontale) — nascosto su mobile */
.navbar__logo-desktop { display: none; height: 38px; width: auto; }
/* Logo mobile (solo mark/monogramma) — visibile su mobile */
.navbar__logo-mobile  { display: block; height: 44px; width: auto; }
@media (min-width: 768px) {
  .navbar__logo-desktop { display: block; }
  .navbar__logo-mobile  { display: none; }
}

.navbar__links {
  display: none;
  align-items: center;
  gap: 34px;
}
@media (min-width: 1024px) { .navbar__links { display: flex; } }

.navbar__links a {
  font-size: 11px;
  font-weight: 400;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: rgba(250,250,250,.62);
  position: relative;
  transition: color .2s;
}
.navbar__links a::after {
  content: '';
  position: absolute;
  bottom: -3px; left: 0; right: 0;
  height: 1px;
  background: var(--gold);
  transform: scaleX(0);
  transition: transform .3s var(--ease);
}
.navbar__links a:hover { color: var(--white); }
.navbar__links a:hover::after { transform: scaleX(1); }

/* Active page link */
.navbar__links a.is-active {
  color: var(--white);
}
.navbar__links a.is-active::after { transform: scaleX(1); }

.navbar__cta { display: none; }
@media (min-width: 1024px) { .navbar__cta { display: inline-flex; } }

/* Hamburger */
.burger {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  width: 40px;
  height: 40px;
  padding: 6px;
  background: none;
  border: none;
  cursor: pointer;
}
@media (min-width: 1024px) { .burger { display: none; } }

.burger__line {
  display: block;
  height: 1px;
  background: var(--white);
  transition: transform .35s var(--ease), opacity .25s;
  transform-origin: center;
}
.burger.is-open .burger__line:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger.is-open .burger__line:nth-child(2) { opacity: 0; transform: scaleX(0); }
.burger.is-open .burger__line:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile drawer */
.mobile-menu {
  position: fixed;
  top: var(--nav-h);
  left: 0; right: 0;
  z-index: 199;
  background: var(--black);
  border-bottom: 1px solid var(--border-gold);
  padding: 36px 24px 44px;
  transform: translateY(-8px);
  opacity: 0;
  visibility: hidden;
  transition: transform .38s var(--ease), opacity .3s, visibility 0s .38s;
}
.mobile-menu.is-open {
  transform: translateY(0);
  opacity: 1;
  visibility: visible;
  transition: transform .38s var(--ease), opacity .3s, visibility 0s;
}
.mobile-menu__nav { margin-bottom: 32px; }
.mobile-menu__nav a {
  display: block;
  font-family: var(--ff-display);
  font-size: 30px;
  font-weight: 300;
  color: var(--white);
  padding: 13px 0;
  border-bottom: 1px solid rgba(255,255,255,.07);
  transition: color .2s;
}
.mobile-menu__nav a:last-child { border-bottom: none; }
.mobile-menu__nav a:hover { color: var(--gold); }
.mobile-menu .btn { width: 100%; justify-content: center; }

/* ─── PAGE HERO (pagine interne) ─── */
.page-hero {
  background: var(--black);
  padding: calc(var(--nav-h) + 72px) 0 80px;
  position: relative;
  overflow: hidden;
}
.page-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(184,148,42,.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(184,148,42,.03) 1px, transparent 1px);
  background-size: 72px 72px;
  pointer-events: none;
}
.page-hero::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 1px;
  background: var(--border-gold);
}
.page-hero__inner { position: relative; z-index: 1; }
.page-hero__eyebrow { margin-bottom: 20px; }
.page-hero__title {
  font-family: var(--ff-display);
  font-weight: 300;
  font-size: clamp(40px, 7vw, 80px);
  color: var(--white);
  line-height: 1.06;
  max-width: 18ch;
}
.page-hero__title em { font-style: italic; color: var(--gold); }
.page-hero__sub {
  margin-top: 20px;
  font-size: 16px;
  font-weight: 300;
  color: rgba(250,250,250,.48);
  max-width: 52ch;
  line-height: 1.75;
}
.page-hero__mark {
  position: absolute;
  top: 50%;
  right: 0;
  transform: translateY(-50%);
  width: 200px;
  opacity: .05;
  pointer-events: none;
}
@media (min-width: 768px) { .page-hero__mark { width: 280px; } }

/* ─── VIDEO HERO ─── */
.page-hero--video { background: var(--black); }
.page-hero__video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  z-index: 0;
}
.page-hero__video--desktop { display: none; }
@media (min-width: 768px) {
  .page-hero__video--mobile { display: none; }
  .page-hero__video--desktop { display: block; }
}
.page-hero__video-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
}
.page-hero--video .page-hero__mark,
.page-hero--video .container { position: relative; z-index: 2; }

/* ─── CTA SECTION (condivisa) ─── */
.s-cta {
  background: var(--white);
  border-top: 1px solid rgba(184,148,42,.15);
  padding: 100px 0;
  text-align: center;
}
.s-cta .eyebrow { color: var(--gold); margin-bottom: 18px; }
.s-cta__title {
  font-family: var(--ff-display);
  font-weight: 300;
  font-size: clamp(38px, 7vw, 86px);
  color: var(--black);
  line-height: 1.04;
  margin-bottom: 14px;
}
.s-cta__sub {
  font-size: 15px;
  font-weight: 300;
  color: rgba(13,13,13,.55);
  max-width: 44ch;
  margin: 0 auto 40px;
  line-height: 1.7;
}

/* ─── FOOTER ─── */
.footer {
  background: #060606;
  border-top: 1px solid rgba(184,148,42,.13);
  padding: 72px 0 32px;
}
.footer__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 48px;
  margin-bottom: 60px;
}
@media (min-width: 768px) {
  .footer__grid { grid-template-columns: 2fr 1fr 1fr; gap: 64px; }
}
.footer__logo { height: 36px; width: auto; opacity: .72; margin-bottom: 18px; }
.footer__tagline {
  font-size: 13px;
  font-weight: 300;
  color: rgba(250,250,250,.3);
  line-height: 1.75;
}
.footer__col-title {
  font-size: 9px;
  font-weight: 500;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 18px;
}
.footer__links { display: flex; flex-direction: column; gap: 10px; }
.footer__links a {
  font-size: 13px;
  font-weight: 300;
  color: rgba(250,250,250,.38);
  transition: color .2s;
}
.footer__links a:hover { color: var(--white); }
.footer__address {
  font-size: 13px;
  font-weight: 300;
  color: rgba(250,250,250,.38);
  line-height: 1.8;
}
.footer__bottom {
  padding-top: 28px;
  border-top: 1px solid rgba(255,255,255,.05);
  display: flex;
  flex-direction: column;
  gap: 12px;
}
@media (min-width: 768px) {
  .footer__bottom { flex-direction: row; align-items: center; justify-content: space-between; }
}
.footer__copy { font-size: 12px; font-weight: 300; color: rgba(250,250,250,.2); }
.footer__legal { display: flex; gap: 24px; }
.footer__legal a {
  font-size: 12px;
  font-weight: 300;
  color: rgba(250,250,250,.22);
  transition: color .2s;
}
.footer__legal a:hover { color: rgba(250,250,250,.55); }

/* ─── TESTO GIUSTIFICATO ─── */
/* Regola globale: tutto il corpo pagina giustificato */
p, li { text-align: justify; }

/* Eccezioni centrate: sezioni CTA e intro prenota */
.s-cta p,
.s-cta li,
.prenota-intro p,
.prenota-intro li,
.prenota-riservatezza p,
.team-card p { text-align: center; }

/* Eccezioni sinistra: UI, footer, indirizzi */
.footer p,
.footer li,
.footer__tagline,
.footer__copy,
.navbar p,
.mobile-menu p,
address,
address p { text-align: left; }

/* ─── SCROLL REVEAL ─── */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .72s var(--ease), transform .72s var(--ease);
}
.reveal.d1 { transition-delay: .1s; }
.reveal.d2 { transition-delay: .2s; }
.reveal.d3 { transition-delay: .3s; }
.reveal.is-visible { opacity: 1; transform: none; }

/* ─── ACCESSIBILITY ─── */
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }
