/* ============================================================
   TOKENS & RESET
   ============================================================ */
:root {
  --bg:       #FDFAF5;
  --surface:  #F4EFE6;
  --text:     #0F0E0C;
  --text-2:   #625D56;
  --accent:   #2d4a68;
  --gold:     #B8934A;
  --line:     #E4DDD0;
  --nav-bg:   rgba(253,250,245,0.92);
  --nav-blur: rgba(253,250,245,0.82);
  --hero-bg:  #0F0E0C;
  --hero-txt: #FDFAF5;
  --shadow:   0 2px 8px rgba(15,14,12,.06), 0 8px 32px rgba(15,14,12,.04);
  --radius:   14px;
  --max-w:    1140px;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
/* Offset anchor scroll to clear the fixed header (72px) + breathing room */
[id] { scroll-margin-top: 96px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  font-weight: 400;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  transition: background .3s ease, color .3s ease;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }
p, h1, h2, h3, h4, h5 { margin: 0; }
ul { list-style: none; margin: 0; padding: 0; }
.container { width: 100%; max-width: var(--max-w); margin: 0 auto; padding: 0 40px; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* ============================================================
   SCROLL PROGRESS
   ============================================================ */
#progress {
  position: fixed; top: 0; left: 0;
  height: 2px; width: 0%;
  background: var(--accent); z-index: 200;
  transition: width .1s linear;
}

/* ============================================================
   CUSTOM CURSOR
   ============================================================ */
.c-dot, .c-ring { display: none; }

/* ============================================================
   BACK TO TOP
   ============================================================ */
#btt {
  position: fixed; bottom: 28px; right: 28px;
  width: 48px; height: 48px; border-radius: 50%;
  background: var(--accent); color: #fff; font-size: 18px;
  display: flex; align-items: center; justify-content: center;
  z-index: 60; opacity: 0; transform: translateY(12px);
  transition: opacity .3s ease, transform .3s ease, box-shadow .2s ease;
  pointer-events: none;
}
#btt.show { opacity: 1; transform: translateY(0); pointer-events: all; }
#btt:hover { box-shadow: 0 6px 20px rgba(26,43,74,.35); }

/* ============================================================
   PAGE TRANSITION
   ============================================================ */
.page-fade { animation: pageIn .35s ease forwards; }
@keyframes pageIn { from { opacity: 0; } to { opacity: 1; } }
.page-fade > main { animation: pageSlide .35s ease forwards; }
@keyframes pageSlide { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }

/* ============================================================
   HEADER
   ============================================================ */
/* hero state — semi-trasparente, filo oro, logo intatto */
.has-hero .site-header {
  background: rgba(253, 250, 245, 0.76);
  border-bottom-color: rgba(184, 147, 74, 0.30);
  box-shadow: 0 1px 0 rgba(184, 147, 74, 0.10), 0 6px 32px rgba(15, 14, 12, 0.06);
}
.has-hero .site-header.scrolled {
  background: var(--nav-bg);
  border-bottom-color: var(--line);
  box-shadow: var(--shadow);
}
/* fully transparent at top of home page */
.has-hero .site-header.at-top {
  background: rgba(253, 250, 245, 0.72);
  border-bottom-color: rgba(184, 147, 74, 0.20);
  box-shadow: 0 1px 0 rgba(184, 147, 74, 0.10);
}
.has-hero .site-header.at-top .hdr-nav a {
  color: var(--text);
}
.has-hero .site-header.at-top .hdr-nav a:hover,
.has-hero .site-header.at-top .hdr-nav a[aria-current="page"] {
  background: none;
  color: var(--accent);
}
.has-hero .site-header.at-top .hdr-cta {
  border-color: var(--accent);
  color: var(--accent);
}

.site-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  background: var(--nav-bg);
  border-bottom: 1px solid transparent;
  transition: background .45s ease, box-shadow .45s ease, border-color .45s ease;
}
.site-header.scrolled { border-bottom-color: var(--line); box-shadow: var(--shadow); }
.hdr-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 72px; gap: 20px;
}
.brand { display: flex; align-items: center; flex-shrink: 0; }
.brand-logo { height: 52px; width: auto; display: block; }
.hdr-nav { display: flex; align-items: center; gap: 4px; }
.hdr-right { display: flex; align-items: center; gap: 4px; }
.hdr-nav a {
  padding: 8px 13px; font-size: 13px; color: var(--text-2);
  border-radius: 8px; transition: color .2s ease;
  min-height: 44px; display: inline-flex; align-items: center;
  position: relative;
}
.hdr-nav a::after {
  content: '';
  position: absolute; bottom: 5px; left: 13px; right: 13px;
  height: 1.5px; background: var(--accent); border-radius: 2px;
  transform: scaleX(0); transform-origin: left;
  transition: transform .25s ease;
}
.hdr-nav a:hover { color: var(--accent); }
.hdr-nav a[aria-current="page"] { color: var(--accent); }
.hdr-nav a[aria-current="page"]::after {
  animation: navLineIn .45s cubic-bezier(.22,1,.36,1) forwards;
}
@keyframes navLineIn {
  from { transform: scaleX(0); }
  to   { transform: scaleX(1); }
}
.hdr-actions { display: flex; align-items: center; gap: 8px; }
.theme-btn {
  width: 40px; height: 40px; border-radius: 50%;
  border: 1px solid var(--line); color: var(--text-2); font-size: 14px;
  display: flex; align-items: center; justify-content: center;
  transition: background .15s, color .15s;
}
.theme-btn:hover { background: var(--surface); color: var(--text); }
.hdr-cta {
  display: inline-flex; align-items: center;
  padding: 9px 20px; border: 1.5px solid var(--accent);
  color: var(--accent); border-radius: 999px; font-size: 13px;
  font-weight: 500; letter-spacing: .03em;
  transition: background .22s ease, color .22s ease, border-color .22s ease, transform .2s ease, box-shadow .22s ease;
  min-height: 44px; white-space: nowrap;
}
.hdr-cta:hover { background: var(--accent); border-color: var(--accent); color: #fff !important; transform: translateY(-1px); box-shadow: 0 4px 16px rgba(30,54,85,.20); }
.hdr-cta[aria-current="page"] { display: none; }
.menu-toggle {
  display: none;
  width: 44px; height: 44px;
  flex-direction: column;
  align-items: center; justify-content: center;
  border: none; background: none; padding: 4px;
}
.menu-toggle .bar {
  display: block;
  width: 26px; height: 2px;
  background-color: var(--text);
  border-radius: 40px;
  margin: 3px 0;
  transition: transform .4s cubic-bezier(0.23, 1, 0.32, 1),
              opacity .3s ease,
              background-color .3s ease;
}
.menu-toggle[aria-expanded="true"] .bar { background-color: var(--text); }
.menu-toggle[aria-expanded="true"] .bar:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] .bar:nth-child(2) { opacity: 0; transform: scaleX(0); }
.menu-toggle[aria-expanded="true"] .bar:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

/* ============================================================
   MOBILE NAV DRAWER
   ============================================================ */
.mob-nav {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 49; background: var(--bg);
  display: flex; flex-direction: column;
  padding: 86px 0 20px;
  transform: translateY(-100%);
  transition: transform .52s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 16px 48px rgba(15,14,12,.18);
  border-bottom: 1px solid var(--line);
  pointer-events: none;
}
.mob-nav.open { transform: translateY(0); pointer-events: all; }
.mob-nav a {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 24px; font-weight: 300;
  color: var(--text); padding: 16px 28px;
  border-bottom: 1px solid var(--line);
  letter-spacing: .03em;
  transition: color .15s, padding-left .2s ease;
}
.mob-nav a:last-child { border-bottom: none; }
.mob-nav a:hover, .mob-nav a[aria-current="page"] { color: var(--accent); padding-left: 40px; }
.mob-close { display: none; }
.mob-backdrop {
  position: fixed; inset: 0; z-index: 48;
  background: rgba(15,14,12,.45);
  opacity: 0; pointer-events: none;
  transition: opacity .38s ease;
}
.mob-backdrop.show { opacity: 1; pointer-events: all; }

/* ============================================================
   HERO — HOMEPAGE (full viewport)
   ============================================================ */
.hero {
  position: relative; min-height: 100svh;
  background-color: var(--hero-bg);
  background-image: url('../img/linegold.png');
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  display: flex; flex-direction: column; justify-content: center;
  overflow: hidden; padding-top: 72px;
}
.hero::after {
  content: '';
  position: absolute; inset: -40px;
  background:
    linear-gradient(180deg, rgba(15,14,12,.45) 0%, rgba(15,14,12,.60) 55%, rgba(15,14,12,.78) 100%),
    radial-gradient(ellipse at 65% 40%, rgba(26,43,74,.10) 0%, transparent 65%),
    radial-gradient(ellipse at 20% 70%, rgba(184,147,74,.06) 0%, transparent 55%);
  z-index: 0; pointer-events: none;
}
.hero::before {
  content: '';
  position: absolute; inset: 0; pointer-events: none;
  opacity: .10; mix-blend-mode: screen;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.82' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='200' height='200' filter='url(%23n)' opacity='.4'/%3E%3C/svg%3E");
  background-size: 200px 200px; z-index: 3;
}
.hero-ring {
  position: absolute; top: 14%; right: 6%;
  width: min(380px, 38vw); height: min(380px, 38vw);
  border-radius: 50%; border: 1px solid rgba(184,147,74,.15);
  pointer-events: none; z-index: 1;
  display: flex; align-items: center; justify-content: center;
}
.hero-ring::after {
  content: ''; position: absolute; inset: 36px;
  border-radius: 50%; border: 1px solid rgba(184,147,74,.06);
}
.hero-year { position: relative; z-index: 1; text-align: center; }
.hero-year-num {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(44px, 5vw, 72px); font-weight: 300;
  color: rgba(184,147,74,.25); line-height: 1; letter-spacing: -.02em;
}
.hero-year-lbl { font-size: 9px; letter-spacing: .24em; text-transform: uppercase; color: rgba(184,147,74,.25); }
.hero-inner { position: relative; z-index: 2; padding: 0 0 15px; text-align: left; margin-top: 12vh; }
.hero-pre {
  display: flex; align-items: center; gap: 14px;
  font-size: 11px; letter-spacing: .22em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 22px;
  opacity: 0; animation: fadein .7s ease .25s forwards;
}
.hero-pre::before { content: ''; display: block; width: 30px; height: 1px; background: var(--gold); opacity: .6; }
.hero-h1 {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(28px, 4.4vw, 56px); line-height: .92;
  font-weight: 300; color: var(--hero-txt); letter-spacing: -.025em; margin-bottom: 0;
}
.hero-h1 .line { display: block; overflow: hidden; }
.hero-h1 .line span { display: block; transform: translateY(105%); animation: slideup .85s cubic-bezier(.22,1,.36,1) forwards; }
.hero-h1 .line:nth-child(1) span { animation-delay: .4s; }
.hero-h1 .line:nth-child(2) span { animation-delay: .58s; }
.hero-h1 .line:nth-child(3) span { animation-delay: .76s; }
.hero-h1 em { font-style: italic; color: rgba(253,250,245,.4); }
.hero-meta {
  display: flex; align-items: flex-end; justify-content: space-between;
  padding-top: 28px; border-top: 1px solid rgba(253,250,245,.09);
  gap: 28px; flex-wrap: wrap;
  opacity: 0; animation: fadein .7s ease 1.1s forwards;
}
.hero-desc { font-size: 15px; line-height: 1.8; color: rgba(253,250,245,.5); max-width: 44ch; }
.hero-btns { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }

/* ============================================================
   INNER PAGE HERO
   ============================================================ */
.page-hero {
  position: relative; min-height: 42vh; max-height: 480px;
  background-color: var(--hero-bg);
  background-image: url('../img/footer.png');
  background-size: cover; background-position: center;
  display: flex; align-items: flex-end; overflow: hidden;
  padding-top: 72px;
}
.page-hero::after {
  content: ''; position: absolute; inset: 0;
  backdrop-filter: blur(5px); -webkit-backdrop-filter: blur(5px);
  background:
    linear-gradient(180deg, rgba(15,14,12,.55) 0%, rgba(15,14,12,.90) 100%),
    radial-gradient(ellipse at 70% 30%, rgba(26,43,74,.10) 0%, transparent 60%);
  z-index: 0;
}
.page-hero::before {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  opacity: .08; mix-blend-mode: screen;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.82' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='200' height='200' filter='url(%23n)' opacity='.4'/%3E%3C/svg%3E");
  background-size: 200px 200px; z-index: 3;
}
.page-hero-inner { position: relative; z-index: 2; padding: 52px 0 52px; }
.page-hero-kicker {
  font-size: 10px; letter-spacing: .24em; text-transform: uppercase;
  color: var(--gold); display: flex; align-items: center; gap: 12px; margin-bottom: 14px;
  opacity: 0; animation: fadein .6s ease .2s forwards;
}
.page-hero-kicker::before { content: ''; display: block; width: 24px; height: 1px; background: var(--gold); opacity: .6; }
.page-hero-title {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(38px, 5.5vw, 72px); font-weight: 300;
  color: var(--hero-txt); line-height: 1; letter-spacing: -.02em;
  opacity: 0; animation: fadein .7s ease .35s forwards;
}
.page-hero-sub {
  font-size: 15px; line-height: 1.7; color: rgba(253,250,245,.45);
  max-width: 52ch; margin-top: 14px;
  opacity: 0; animation: fadein .7s ease .5s forwards;
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn-primary {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 15px 34px; background: var(--accent); color: #fff;
  border-radius: 999px; font-size: 14px; font-weight: 500; letter-spacing: .04em;
  transition: opacity .15s, transform .15s, box-shadow .15s; min-height: 52px;
}
.btn-primary:hover { opacity: .9; transform: translateY(-2px); box-shadow: 0 8px 24px rgba(26,43,74,.32); }
.btn-ghost {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 15px 28px; border: 1px solid rgba(253,250,245,.18);
  color: rgba(253,250,245,.65); border-radius: 999px; font-size: 14px;
  transition: border-color .15s, color .15s, transform .15s; min-height: 52px;
}
.btn-ghost:hover { border-color: rgba(253,250,245,.5); color: var(--hero-txt); transform: translateY(-1px); }
.btn-outline {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 26px; border: 1.5px solid var(--accent);
  color: var(--accent); border-radius: 999px; font-size: 13.5px; font-weight: 500;
  transition: background .15s, color .15s, transform .15s; min-height: 46px;
}
.btn-outline:hover { background: var(--accent); color: #fff; transform: translateY(-1px); }

/* ============================================================
   TICKER / MARQUEE
   ============================================================ */
.ticker { background: var(--accent); overflow: hidden; padding: 12px 0; user-select: none; }
.ticker-track { display: flex; width: max-content; animation: ticker 36s linear infinite; }
.ticker:hover .ticker-track { animation-play-state: paused; }
.ticker-item {
  display: flex; align-items: center; gap: 16px; padding: 0 24px;
  font-size: 10.5px; letter-spacing: .2em; text-transform: uppercase;
  color: rgba(255,255,255,.82); white-space: nowrap;
}
.ticker-dot { width: 3px; height: 3px; border-radius: 50%; background: rgba(255,255,255,.4); flex-shrink: 0; }

/* ============================================================
   STATS
   ============================================================ */
.stats-sec { padding: 80px 0; background: var(--surface); border-bottom: 1px solid var(--line); }
.stats-grid {
  display: grid; grid-template-columns: repeat(4,1fr);
  gap: 1px; background: var(--line); border: 1px solid var(--line);
  border-radius: var(--radius); overflow: hidden;
}
.stat { background: var(--surface); padding: 34px 24px; text-align: center; transition: background .2s; }
.stat:hover { background: var(--bg); }
.stat-num {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(38px, 5vw, 62px); font-weight: 300; line-height: 1;
  letter-spacing: -.02em; color: var(--accent); margin-bottom: 8px;
}
.stat-lbl { font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--text-2); }
/* ============================================================
   PULL QUOTE
   ============================================================ */
.pull-quote-sec {
  background: var(--hero-bg); padding: 120px 0 80px;
  border-top: 1px solid rgba(253,250,245,.05);
}
.pull-quote-sec .container {
  padding-left: 20px;
}
.pull-quote {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(16px, 2.2vw, 26px); font-style: italic; font-weight: 400;
  line-height: 1.45; color: #ffffff !important;
  max-width: 60ch; position: relative; padding-left: 32px; margin-left: 0; margin-right: auto;
}
.pull-quote::before {
  content: ''; position: absolute; left: 0; top: 8px;
  width: 3px; height: calc(100% - 16px); background: var(--gold); opacity: .5;
}
.pull-quote-attr { font-size: 11px; letter-spacing: .18em; text-transform: uppercase; color: rgba(255, 255, 255, 0.28); margin-top: 18px; }
.pull-quote--prominent { color: rgba(255,255,255,0.78) !important; font-size: clamp(15px, 1.9vw, 23px); font-weight: 400; max-width: 62ch; }

/* ============================================================
   HOME CARDS — DNA LAYOUT
   ============================================================ */
.home-cards-sec {
  background: var(--bg);
  padding: 80px 0 112px;
}
.home-cards-grid {
  display: flex;
  flex-direction: column;
  gap: 60px;
  position: relative;
  padding: 12px 0;
}
/* Backbone verticale */
.home-cards-grid::before {
  content: '';
  position: absolute;
  left: 50%; top: 0; bottom: 0;
  width: 1px;
  background: linear-gradient(to bottom,
    transparent 0%, var(--line) 4%,
    var(--line) 96%, transparent 100%);
  transform: translateX(-50%);
  pointer-events: none;
}
.home-card {
  width: calc(50% - 36px);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 36px 32px 32px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  position: relative;
  transition: border-color .25s ease, box-shadow .25s ease;
}
.home-card:hover {
  border-color: var(--gold);
  box-shadow: 0 8px 32px rgba(184,147,74,.12);
}
/* Connettore orizzontale verso il backbone */
.home-card::after {
  content: '';
  position: absolute;
  top: 50%; width: 36px; height: 1px;
  background: var(--line);
  transform: translateY(-50%);
}
/* Nodo dorato sul backbone */
.home-card::before {
  content: '';
  position: absolute;
  top: 50%;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--bg);
  border: 1.5px solid var(--gold);
  opacity: .7;
  transform: translateY(-50%);
  z-index: 1;
}
/* Carte sinistra (dispari) */
.home-card:nth-child(odd)  { align-self: flex-start; }
.home-card:nth-child(odd)::after  { left: 100%; }
.home-card:nth-child(odd)::before { left: calc(100% + 32px); }
/* Carte destra (pari) */
.home-card:nth-child(even) { align-self: flex-end; }
.home-card:nth-child(even)::after  { right: 100%; }
.home-card:nth-child(even)::before { right: calc(100% + 32px); }

.home-card-title {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(20px, 2vw, 26px);
  font-weight: 300;
  line-height: 1.2;
  color: var(--text);
  margin: 0;
}
.home-card-desc {
  font-size: 14px;
  color: var(--text-2);
  line-height: 1.65;
  flex: 1;
  margin: 4px 0 8px;
}
.home-card .btn-outline,
.home-card .btn-primary {
  align-self: flex-start;
  margin-top: auto;
}
/* Mobile: colonna singola, niente DNA */
@media (max-width: 768px) {
  .home-cards-grid::before { display: none; }
  .home-card,
  .home-card:nth-child(odd),
  .home-card:nth-child(even) { width: 100%; align-self: stretch; }
  .home-card::after,
  .home-card::before { display: none; }
}

/* ============================================================
   SECTIONS — SHARED
   ============================================================ */
.section { padding: 104px 0; }
.sec-hdr { margin-bottom: 56px; }
.kicker {
  display: flex; align-items: center; gap: 12px;
  font-size: 11px; letter-spacing: .22em; text-transform: uppercase;
  color: var(--accent); margin-bottom: 14px;
}
.kicker::before { content: ''; display: block; width: 24px; height: 1px; background: var(--accent); }
.sec-title {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(30px, 4.5vw, 56px); font-weight: 300;
  line-height: 1.04; letter-spacing: -.01em;
}
.sec-title em { font-style: italic; color: var(--text-2); }
.sec-lead { font-size: 16px; line-height: 1.8; color: var(--text-2); max-width: 60ch; margin-top: 16px; }

/* ============================================================
   ABOUT / STUDIO
   ============================================================ */
.about-grid { display: grid; grid-template-columns: 5fr 6fr; gap: 80px; align-items: center; }
.about-visual {
  position: relative; aspect-ratio: 4/5; background: var(--surface);
  border-radius: 4px; overflow: hidden; border: 1px solid var(--line);
  display: flex; align-items: center; justify-content: center;
}
.about-visual::before {
  content: ''; position: absolute; bottom: 0; left: 0;
  width: 64px; height: 64px;
  border-bottom: 3px solid var(--accent); border-left: 3px solid var(--accent);
}
.about-visual::after {
  content: ''; position: absolute; top: 0; right: 0;
  width: 64px; height: 64px;
  border-top: 1px solid var(--gold); border-right: 1px solid var(--gold); opacity: .5;
}
.about-monogram {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(80px, 12vw, 160px); font-weight: 300;
  color: var(--accent); opacity: .12; user-select: none; line-height: 1;
  letter-spacing: -.04em;
}
.about-year-badge {
  position: absolute; bottom: 24px; right: 24px;
  background: var(--bg); border: 1px solid var(--line);
  border-radius: 10px; padding: 12px 18px; text-align: center;
}
.about-year-n { font-family: 'Cormorant Garamond', Georgia, serif; font-size: 28px; font-weight: 300; color: var(--accent); line-height: 1; }
.about-year-l { font-size: 9px; letter-spacing: .16em; text-transform: uppercase; color: var(--text-2); margin-top: 2px; }
.about-text { font-size: 16px; line-height: 1.85; color: var(--text-2); margin-bottom: 22px; }
.about-text strong { color: var(--text); font-weight: 500; }
.about-list { display: flex; flex-direction: column; gap: 9px; margin-bottom: 30px; }
.about-list li { display: flex; align-items: center; gap: 12px; font-size: 14px; color: var(--text-2); }
.about-list li::before { content: ''; width: 16px; height: 1px; background: var(--accent); flex-shrink: 0; }
.badges { display: flex; gap: 8px; flex-wrap: wrap; }
.badge {
  padding: 6px 14px; border: 1px solid var(--line); border-radius: 999px;
  font-size: 12px; color: var(--text-2); letter-spacing: .04em;
}

/* ============================================================
   COMPETENZE / SERVICE CARDS
   ============================================================ */
.svcs-sec { background: var(--surface); }
.svcs-grid {
  display: grid; grid-template-columns: repeat(3,1fr);
  gap: 1px; background: var(--line); border: 1px solid var(--line);
  border-radius: var(--radius); overflow: hidden;
}
.svc {
  background: var(--surface); padding: 34px 26px;
  position: relative; overflow: hidden; transition: background .2s;
}
.svc::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: var(--accent); transform: scaleX(0); transform-origin: left;
  transition: transform .3s ease;
}
.svc:hover { background: var(--bg); }
.svc:hover::before { transform: scaleX(1); }
.svc-icon {
  width: 42px; height: 42px; border-radius: 10px;
  background: rgba(26,43,74,.08); color: var(--accent);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 18px; box-shadow: 0 0 0 1px rgba(26,43,74,.08) inset;
}
.svc-icon svg { width: 22px; height: 22px; stroke: currentColor; stroke-width: 1.8; fill: none; stroke-linecap: round; stroke-linejoin: round; }
[data-theme="dark"] .svc-icon { background: rgba(26,43,74,.14); }
.svc-title { font-family: 'Cormorant Garamond', Georgia, serif; font-size: 22px; font-weight: 600; line-height: 1.15; margin-bottom: 10px; }
.svc-desc { font-size: 14px; line-height: 1.72; color: var(--text-2); }
.svc-link { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--accent); margin-top: 14px; font-weight: 500; letter-spacing: .03em; transition: gap .2s; }
.svc:hover .svc-link { gap: 10px; }

/* ============================================================
   METODO / PROCESS STEPS
   ============================================================ */
.process-grid {
  display: grid; grid-template-columns: repeat(4,1fr); gap: 36px; position: relative;
}
.process-grid::before {
  content: ''; position: absolute; top: 21px; left: 21px; right: 21px;
  height: 1px; background: var(--line);
}
.step { position: relative; }
.step-num {
  width: 42px; height: 42px; border-radius: 50%;
  border: 1px solid var(--line); background: var(--bg);
  display: flex; align-items: center; justify-content: center;
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 17px; font-weight: 600; color: var(--accent);
  margin-bottom: 18px; position: relative; z-index: 1;
}
.step-title { font-size: 15px; font-weight: 600; margin-bottom: 8px; letter-spacing: .01em; }
.step-desc { font-size: 13.5px; line-height: 1.65; color: var(--text-2); }

/* ============================================================
   METODO — DETAILED (full page)
   ============================================================ */
.metodo-list { display: flex; flex-direction: column; gap: 2px; }
.metodo-item {
  border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; transition: background .2s;
}
.metodo-item:hover { background: var(--surface); }
.metodo-hdr {
  display: flex; align-items: flex-start; gap: 24px; padding: 28px 30px;
}
.metodo-n {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 38px; font-weight: 300; color: var(--accent); opacity: .35;
  line-height: 1; flex-shrink: 0; letter-spacing: -.02em; min-width: 40px;
}
.metodo-body h3 { font-size: 18px; font-weight: 600; margin-bottom: 8px; }
.metodo-body p { font-size: 14.5px; line-height: 1.78; color: var(--text-2); }

/* ============================================================
   DARK SECTION (Assistenza Continuativa teaser / full page)
   ============================================================ */
.dark-sec {
  background: var(--hero-bg); padding: 104px 0;
  border-top: 1px solid rgba(253,250,245,.05);
  border-bottom: 1px solid rgba(253,250,245,.05);
}
.dark-sec .kicker { color: var(--gold); }
.dark-sec .kicker::before { background: var(--gold); }
.dark-sec .sec-title { color: var(--hero-txt); }
.dark-sec .sec-lead { color: rgba(253,250,245,.5); }
.features-grid {
  display: grid; grid-template-columns: repeat(3,1fr); gap: 24px; margin-top: 52px;
}
.feature {
  background: rgba(253,250,245,.04); border: 1px solid rgba(253,250,245,.07);
  border-radius: var(--radius); padding: 28px 24px;
  transition: background .25s, border-color .25s, transform .25s;
}
.feature:hover { background: rgba(253,250,245,.07); border-color: rgba(184,147,74,.25); transform: translateY(-4px); }
.feature-icon {
  width: 40px; height: 40px; border-radius: 8px;
  background: rgba(184,147,74,.1); color: var(--gold);
  display: flex; align-items: center; justify-content: center; margin-bottom: 14px;
}
.feature-icon svg { width: 20px; height: 20px; stroke: currentColor; stroke-width: 1.8; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.feature-title { font-size: 15px; font-weight: 600; color: rgba(253,250,245,.85); margin-bottom: 8px; }
.feature-desc { font-size: 13.5px; line-height: 1.68; color: rgba(253,250,245,.45); }

/* ============================================================
   ASSISTENZA CONTINUATIVA — full page sections
   ============================================================ */
.ac-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: start; }
.ac-item { padding: 28px 0; border-bottom: 1px solid var(--line); }
.ac-item:first-child { border-top: 1px solid var(--line); }
.ac-item h3 { font-family: 'Cormorant Garamond', Georgia, serif; font-size: 22px; font-weight: 600; margin-bottom: 10px; }
.ac-item p { font-size: 14.5px; line-height: 1.78; color: var(--text-2); }
.ac-box {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 32px; position: sticky; top: 96px;
}
/* Colonna destra ac-grid: sticky come unità — entrambi i box si muovono insieme */
.ac-sticky-col {
  position: sticky;
  top: 96px;
  align-self: start;
}
.ac-sticky-col .ac-box {
  position: static;
}
.ac-box-title { font-family: 'Cormorant Garamond', Georgia, serif; font-size: 24px; font-weight: 300; margin-bottom: 20px; }
.ac-list { display: flex; flex-direction: column; gap: 12px; margin-bottom: 24px; }
.ac-list li { display: flex; align-items: baseline; gap: 10px; font-size: 14px; color: var(--text-2); }
.ac-list li::before { content: '—'; color: var(--accent); font-size: 12px; flex-shrink: 0; }
.ac-note {
  padding: 16px 18px; background: var(--bg); border-left: 3px solid var(--accent);
  border-radius: 0 8px 8px 0; font-size: 13.5px; line-height: 1.7; color: var(--text-2);
  font-style: italic; margin-top: 20px;
}

/* ============================================================
   COMPETENZE — full page
   ============================================================ */
.comp-area { padding: 40px 0; border-bottom: 1px solid var(--line); }
.comp-area:last-child { border-bottom: none; }
.comp-area-hdr { display: flex; align-items: flex-start; gap: 22px; margin-bottom: 18px; }
.comp-area-icon {
  width: 46px; height: 46px; border-radius: 10px; flex-shrink: 0;
  background: rgba(26,43,74,.08); color: var(--accent);
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 0 0 1px rgba(26,43,74,.08) inset;
}
.comp-area-icon svg { width: 24px; height: 24px; stroke: currentColor; stroke-width: 1.7; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.comp-area-name { font-family: 'Cormorant Garamond', Georgia, serif; font-size: 26px; font-weight: 600; line-height: 1.1; margin-bottom: 4px; }
.comp-area-tag { font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--accent); }
.comp-area-body { font-size: 15px; line-height: 1.82; color: var(--text-2); padding-left: 68px; }
.comp-area-body p { margin-bottom: 14px; }
.comp-area-body p:last-child { margin-bottom: 0; }
.comp-area-body strong { color: var(--text); font-weight: 500; }
.comp-note {
  margin-top: 16px; padding: 16px 18px; background: var(--surface);
  border-left: 3px solid var(--line); border-radius: 0 8px 8px 0;
  font-size: 13.5px; line-height: 1.7; color: var(--text-2); font-style: italic;
}

/* ============================================================
   COMPETENZE GRID — CHESSBOARD
   ============================================================ */
.comp-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

/* Default: tutte le tile chiare */
.comp-tile { background: var(--bg); transition: background .2s; }
.comp-tile:has(.comp-tile-hdr:hover) { background: var(--surface); }

/* Aperta: tile resta chiara */
.comp-tile.open { background: var(--bg); }

.comp-tile-hdr {
  display: flex; align-items: flex-start; gap: 14px;
  padding: 28px 26px; cursor: pointer;
  min-height: 116px;
  transition: background .18s;
}
.comp-tile-hdr:focus-visible {
  outline: 2px solid var(--accent); outline-offset: -3px;
}
.comp-tile.open .comp-tile-hdr:focus-visible { outline-color: var(--gold); }

.comp-tile-icon {
  width: 44px; height: 44px; border-radius: 10px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
}
.comp-tile         .comp-tile-icon { background: rgba(26,43,74,.08); color: var(--accent); }
.comp-tile.open    .comp-tile-icon { background: rgba(26,43,74,.08); color: var(--accent); }
.comp-tile-icon svg {
  width: 22px; height: 22px; stroke: currentColor; stroke-width: 1.7;
  fill: none; stroke-linecap: round; stroke-linejoin: round;
}

.comp-tile-info { flex: 1; min-width: 0; }

.comp-tile-area-lbl {
  font-size: 9.5px; letter-spacing: .2em; text-transform: uppercase; margin-bottom: 6px;
}
.comp-tile         .comp-tile-area-lbl { color: var(--accent); }
.comp-tile.open    .comp-tile-area-lbl { color: var(--accent); }

.comp-tile-title {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 20px; font-weight: 600; line-height: 1.15;
  letter-spacing: -.01em; margin-bottom: 5px;
}
.comp-tile         .comp-tile-title { color: var(--text); }
.comp-tile.open    .comp-tile-title { color: var(--text); }

.comp-tile-tagline { font-size: 11.5px; line-height: 1.45; }
.comp-tile         .comp-tile-tagline { color: var(--text-2); }
.comp-tile.open    .comp-tile-tagline { color: var(--text-2); }

.comp-tile-chevron {
  width: 22px; height: 22px; flex-shrink: 0; margin-top: 2px;
  display: flex; align-items: center; justify-content: center;
}
.comp-tile-chevron svg {
  width: 18px; height: 18px; stroke: currentColor; stroke-width: 2;
  fill: none; stroke-linecap: round; stroke-linejoin: round;
  transition: transform 260ms ease;
}
.comp-tile         .comp-tile-chevron { color: var(--text-2); }
.comp-tile.open    .comp-tile-chevron { color: var(--text-2); }
.comp-tile.open .comp-tile-chevron svg { transform: rotate(180deg); }

/* Accordion body */
.comp-tile-body {
  max-height: 0; overflow: hidden;
  transition: max-height 280ms ease;
}
.comp-tile-body-inner {
  padding: 0 26px 26px; padding-top: 18px;
  border-top: 1px solid;
  font-size: 14.5px; line-height: 1.78;
}
.comp-tile         .comp-tile-body-inner { border-top-color: var(--line); color: var(--text-2); }
.comp-tile.open    .comp-tile-body-inner { border-top-color: var(--line); color: var(--text-2); }
.comp-tile-body-inner p { margin-bottom: 12px; }
.comp-tile-body-inner p:last-child { margin-bottom: 0; }
.comp-tile         .comp-tile-body-inner strong { color: var(--text); font-weight: 500; }
.comp-tile.open    .comp-tile-body-inner strong { color: var(--text); font-weight: 500; }

.comp-tile-note {
  margin-top: 14px; padding: 12px 16px;
  border-left: 3px solid; border-radius: 0 6px 6px 0;
  font-size: 13px; line-height: 1.65; font-style: italic;
}
.comp-tile         .comp-tile-note { background: var(--surface); border-left-color: var(--line); color: var(--text-2); }
.comp-tile.open    .comp-tile-note { background: var(--surface); border-left-color: var(--line); color: var(--text-2); }

/* ============================================================
   CURRICULUM — TIMELINE
   ============================================================ */
.cv-section { padding: 56px 0; border-bottom: 1px solid var(--line); }
.cv-section:last-of-type { border-bottom: none; }
.cv-section-title {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 28px; font-weight: 300; margin-bottom: 32px;
  display: flex; align-items: center; gap: 16px;
}
.cv-section-title::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.timeline { position: relative; padding-left: 32px; }
.timeline::before {
  content: ''; position: absolute; left: 7px; top: 8px; bottom: 8px;
  width: 1px; background: var(--line);
}
.tl-item { position: relative; padding-bottom: 36px; }
.tl-item:last-child { padding-bottom: 0; }
.tl-dot {
  position: absolute; left: -32px; top: 5px;
  width: 14px; height: 14px; border-radius: 50%;
  border: 2px solid var(--line); background: var(--bg); z-index: 1;
  transition: border-color .2s, background .2s;
}
.tl-item:hover .tl-dot { border-color: var(--accent); background: var(--accent); }
.tl-date { font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--text-2); margin-bottom: 4px; }
.tl-org { font-size: 17px; font-weight: 600; margin-bottom: 2px; }
.tl-role { font-family: 'Cormorant Garamond', Georgia, serif; font-size: 16px; font-style: italic; color: var(--accent); margin-bottom: 8px; }
.tl-desc { font-size: 14px; line-height: 1.72; color: var(--text-2); }
.tl-area-tag {
  display: inline-flex; margin-top: 8px; padding: 3px 10px;
  background: rgba(26,43,74,.08); border-radius: 999px;
  font-size: 10.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--accent);
}

/* ============================================================
   PUBLICATIONS
   ============================================================ */
.pub-groups { display: flex; flex-direction: column; gap: 8px; }
.pub-group { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.pub-group-hdr {
  width: 100%; display: flex; align-items: center; gap: 14px;
  padding: 18px 22px; background: var(--surface); font-family: inherit;
  cursor: pointer; text-align: left; transition: background .15s;
}
.pub-group-hdr:hover { background: var(--bg); }
.pub-group-hdr:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; border-radius: var(--radius); }
.pub-group-dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
.pub-group-dot--da { background: var(--accent); }
.pub-group-dot--gc { background: var(--gold); }
.pub-group-dot--sj { background: #2d7a5a; }
.pub-group-name { font-size: 14px; font-weight: 600; color: var(--text); flex: 1; letter-spacing: .01em; }
.pub-group-count {
  font-size: 11px; letter-spacing: .07em; padding: 3px 11px;
  border-radius: 999px; background: rgba(26,43,74,.07); color: var(--text-2); flex-shrink: 0;
}
.pub-group-chevron {
  width: 16px; height: 16px; flex-shrink: 0; color: var(--text-2);
  transition: transform 320ms cubic-bezier(.22,1,.36,1);
}
.pub-group-hdr[aria-expanded="true"] .pub-group-chevron { transform: rotate(180deg); }
.pub-group-body {
  max-height: 0; overflow: hidden;
  transition: max-height 440ms cubic-bezier(.22,1,.36,1);
}
.pub-group-list {
  display: flex; flex-direction: column; gap: 1px;
  background: var(--line); border-top: 1px solid var(--line);
}
.pub-item {
  background: var(--surface); padding: 14px 22px;
  display: flex; align-items: baseline; gap: 20px; transition: background .15s;
}
.pub-item:hover { background: var(--bg); }
.pub-date { font-size: 11px; color: var(--text-2); letter-spacing: .06em; white-space: nowrap; flex-shrink: 0; min-width: 90px; }
.pub-title { font-size: 14px; line-height: 1.5; flex: 1; }
.skills-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 16px; margin-top: 24px; }
.skill-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 22px; }
.skill-card h4 { font-size: 13px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--text-2); margin-bottom: 8px; }
.skill-card p { font-size: 14px; line-height: 1.6; color: var(--text); }

/* ============================================================
   CONTACTS
   ============================================================ */
.contact-single { max-width: 600px; }
.ci { display: flex; flex-direction: column; gap: 3px; padding: 18px 0; border-bottom: 1px solid var(--line); }
.ci:first-of-type { border-top: 1px solid var(--line); }
.ci-lbl { font-size: 10.5px; letter-spacing: .18em; text-transform: uppercase; color: var(--text-2); }
.ci-val { font-family: 'Cormorant Garamond', Georgia, serif; font-size: 20px; font-weight: 400; }
.ci-val a { transition: color .15s; }
.ci-val a:hover { color: var(--accent); }
.contact-note {
  margin-top: 24px; padding: 16px 20px;
  background: var(--surface); border-left: 3px solid var(--accent);
  border-radius: 0 8px 8px 0; font-size: 14px; line-height: 1.7;
  color: var(--text-2); font-style: italic;
}

/* ============================================================
   CONTACT FORM
   ============================================================ */
.form-group { margin-bottom: 20px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-group label { display: block; font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--text-2); margin-bottom: 8px; }
.form-group input,
.form-group select,
.form-group textarea {
  width: 100%; padding: 13px 16px; background: var(--surface);
  border: 1px solid var(--line); border-radius: 10px;
  font-size: 14.5px; color: var(--text); font-family: inherit;
  transition: border-color .15s, box-shadow .15s;
  appearance: none;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none; border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(26,43,74,.08);
}
.form-group textarea { resize: vertical; min-height: 120px; }
.form-check { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 24px; }
.form-check input[type="checkbox"] { width: 18px; height: 18px; flex-shrink: 0; accent-color: var(--accent); margin-top: 2px; }
.form-check label { font-size: 13px; line-height: 1.5; color: var(--text-2); }
.form-success {
  display: none; padding: 20px 24px;
  background: var(--surface); border: 1px solid var(--line);
  border-left: 3px solid var(--accent); border-radius: 0 10px 10px 0;
  font-size: 15px; color: var(--text); line-height: 1.6;
}

/* ============================================================
   FAQ ACCORDION
   ============================================================ */
.faq-sec { background: var(--surface); }
.faq-list { display: flex; flex-direction: column; gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.faq-item { background: var(--surface); transition: background .2s; }
.faq-item.open { background: var(--bg); }
.faq-q {
  width: 100%; display: flex; align-items: center; justify-content: space-between;
  gap: 16px; padding: 22px 26px; font-size: 15px; font-weight: 500;
  color: var(--text); text-align: left; transition: color .15s; min-height: 44px;
}
.faq-q:hover { color: var(--accent); }
.faq-ico {
  width: 28px; height: 28px; border-radius: 50%; border: 1px solid var(--line);
  display: flex; align-items: center; justify-content: center;
  font-size: 17px; color: var(--text-2); flex-shrink: 0;
  transition: transform .3s, background .2s, border-color .2s, color .2s;
}
.faq-item.open .faq-ico { transform: rotate(45deg); background: var(--accent); border-color: var(--accent); color: #fff; }
.faq-body { max-height: 0; overflow: hidden; transition: max-height .4s ease; }
.faq-body-inner { padding: 0 26px 22px; font-size: 14.5px; line-height: 1.78; color: var(--text-2); }

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer {
  position: relative;
  overflow: hidden;
  border-top: none;
  margin-top: 120px;
  --text:   #F0EBE1;
  --text-2: rgba(240, 235, 225, 0.58);
  --line:   rgba(200, 164, 107, 0.14);
}

/* Layer 1 — immagine di sfondo */
.site-footer::before {
  content: '';
  position: absolute;
  inset: -20px;
  background-image: url('../img/footer.png');
  background-size: cover;
  background-position: center center;
  filter: blur(2px) brightness(0.70) saturate(0.88);
  z-index: 0;
}
@media (max-width: 768px) {
  .site-footer::before { background-size: 180%; background-position: center 78%; }
}

/* Layer 2 — blur su tutto il footer */
.site-footer::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(8,7,5,.22) 0%, rgba(8,7,5,.48) 100%);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  z-index: 1;
}

/* Contenuto sopra i due layer */
.site-footer > * {
  position: relative;
  z-index: 2;
}

/* CTA band */
.foot-cta-band {
  display: flex; align-items: center; justify-content: space-between;
  gap: 32px; padding: 64px 0 60px;
  border-bottom: 1px solid var(--line);
  flex-wrap: wrap;
}
.foot-cta-kicker {
  font-size: 10px; letter-spacing: .24em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 14px; display: block;
}
.foot-cta-heading {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(30px, 4vw, 52px); font-weight: 300; line-height: 1.1;
  color: var(--text); letter-spacing: -.01em; margin: 0;
}
.foot-cta-heading em { color: var(--gold); font-style: italic; }
.foot-cta-btn {
  flex-shrink: 0;
  display: inline-flex; align-items: center; gap: 12px;
  padding: 16px 34px; background: var(--accent); color: #fff;
  font-size: 12px; letter-spacing: .14em; text-transform: uppercase;
  border-radius: 999px; white-space: nowrap; border: none;
  transition: background .22s ease, transform .22s ease;
}
.foot-cta-btn:hover { background: var(--gold); transform: translateX(6px); }

/* Main grid */
.foot-main {
  display: flex; flex-direction: row-reverse; align-items: center; justify-content: space-between; gap: 56px;
  padding: 32px 0 24px;
  border-bottom: 1px solid var(--line);
}
.foot-brand {
  position: relative;
  isolation: isolate;
  margin-top: 16px;
  display: inline-block;
}

/* Finestra nitida — stessa immagine senza blur, copre solo il logo */
.foot-brand::before {
  content: '';
  position: absolute;
  inset: -8px;
  border-radius: 18px;
  background-image: url('../img/footer.png');
  background-size: 280%;
  background-position: 80% 70%;
  filter: brightness(1.8) saturate(0.90) blur(9px);
  -webkit-mask-image:
    linear-gradient(to bottom, transparent 0%, rgba(45,74,104,1) 28%, rgba(45,74,104,1) 72%, transparent 100%),
    linear-gradient(to right,  transparent 0%, rgba(45,74,104,1) 13%, rgba(45,74,104,1) 91%, transparent 100%);
  mask-image:
    linear-gradient(to bottom, transparent 0%, rgba(45,74,104,1) 28%, rgba(45,74,104,1) 72%, transparent 100%),
    linear-gradient(to right,  transparent 0%, rgba(45,74,104,1) 13%, rgba(45,74,104,1) 91%, transparent 100%);
  -webkit-mask-composite: source-in;
  mask-composite: intersect;
  z-index: -1;
}
.foot-brand-logo {
  height: 110px; width: auto; display: block;
  border-radius: 18px;
  /* Maschera verticale × maschera orizzontale = sfumatura su tutti e 4 i lati */
  -webkit-mask-image:
    linear-gradient(to bottom, transparent 0%, black 18%, black 82%, transparent 100%),
    linear-gradient(to right,  transparent 0%, black 18%, black 82%, transparent 100%);
  mask-image:
    linear-gradient(to bottom, transparent 0%, black 18%, black 82%, transparent 100%),
    linear-gradient(to right,  transparent 0%, black 18%, black 82%, transparent 100%);
  -webkit-mask-composite: source-in; /* Safari */
  mask-composite: intersect;
}
.foot-claim { max-width: 460px; }
.foot-claim-heading {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(24px, 2.4vw, 32px); font-weight: 500; font-style: italic;
  color: var(--text); line-height: 1.3; margin-bottom: 14px;
}
.foot-claim-heading em { color: var(--gold); font-style: italic; }
.foot-claim-sub {
  font-size: 13.5px; color: var(--text-2); line-height: 1.78;
  margin-bottom: 28px;
}
.foot-claim-btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 13px 30px; background: var(--accent); color: #fff;
  font-size: 10.5px; letter-spacing: .2em; text-transform: uppercase;
  border-radius: 100px; border: none;
  transition: background .2s, transform .22s;
}
.foot-claim-btn:hover { background: var(--gold); transform: translateX(5px); }

/* Footer contact form */
.foot-form-wrapper { display: flex; flex-direction: column; align-items: center; max-width: 360px; width: 100%; flex-shrink: 0; }
.foot-flip-inner { width: 100%; display: flex; flex-direction: column; align-items: center; }
.foot-flip-back { display: none; width: 100%; }
.foot-form-trigger { transition: opacity .25s, transform .25s; }
.foot-form-trigger.is-hidden { opacity: 0; transform: translateY(-6px); pointer-events: none; position: absolute; }
.foot-form { display: flex; flex-direction: column; gap: 10px; width: 100%; max-width: 360px; flex-shrink: 0; }
.foot-form--hidden { opacity: 0; transform: translateY(10px); pointer-events: none; max-height: 0; overflow: hidden; transition: opacity .35s ease, transform .35s ease, max-height .4s ease; }
.foot-form--visible { opacity: 1; transform: translateY(0); pointer-events: auto; max-height: 400px; }
.foot-form-row { display: flex; gap: 10px; }
.foot-form-input {
  width: 100%; background: rgba(255,255,255,.06);
  border: 1px solid rgba(200,164,107,.18); border-radius: 8px;
  padding: 11px 14px; font-size: 13px; color: var(--text);
  font-family: inherit; transition: border-color .2s;
}
.foot-form-input::placeholder { color: rgba(240,235,225,.28); }
.foot-form-input:focus { outline: none; border-color: rgba(200,164,107,.55); }
.foot-form-textarea { resize: none; height: 82px; }
.foot-form-submit {
  align-self: flex-start; cursor: pointer;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 13px 30px; background: var(--accent); color: #fff;
  font-size: 10.5px; letter-spacing: .2em; text-transform: uppercase;
  border-radius: 100px; border: none; font-family: inherit;
  transition: background .2s, transform .22s;
}
.foot-form-submit:hover { background: var(--gold); transform: translateX(5px); }
.foot-col-label {
  display: block; font-size: 9px; letter-spacing: .26em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 22px;
}
.foot-nav { display: flex; flex-direction: column; gap: 0; }
.foot-nav a {
  font-size: 13.5px; color: var(--text-2);
  padding: 9px 0; display: block;
  border-bottom: 1px solid var(--line);
  transition: color .18s ease, padding-left .22s ease;
}
.foot-nav a:first-child { border-top: 1px solid rgba(200,164,107,.12); }
.foot-nav a:hover { color: #C8A46B; padding-left: 10px; }
.foot-contacts { display: flex; flex-direction: column; gap: 20px; }
.foot-ci { display: flex; flex-direction: column; gap: 4px; }
.foot-ci-lbl {
  font-size: 9px; letter-spacing: .2em; text-transform: uppercase;
  color: rgba(200,164,107,.55);
}
.foot-ci-val { font-size: 13px; color: rgba(255,255,255,.48); line-height: 1.5; }
.foot-ci-val a { color: inherit; transition: color .15s; }
.foot-ci-val a:hover { color: #C8A46B; }

/* Bottom bar */
.foot-bottom {
  display: flex; justify-content: space-between; align-items: center;
  padding: 14px 0; gap: 14px; flex-wrap: wrap;
  user-select: none;
}
.foot-copy { font-size: 11px; color: rgba(255,255,255,.22); letter-spacing: .04em; }
.foot-location { font-size: 10px; color: rgba(200,164,107,.35); letter-spacing: .12em; text-transform: uppercase; }
.foot-legal { font-size: 11px; color: rgba(255,255,255,.22); }
.foot-privacy { font-size: 11px; color: rgba(255,255,255,.22); text-decoration: none; transition: text-decoration .15s; }
.foot-privacy:hover { text-decoration: underline; }

/* ============================================================
   SCROLL REVEAL
   ============================================================ */
.reveal { opacity: 0; transform: translateY(20px); transition: opacity .7s ease, transform .7s ease; will-change: opacity, transform; }
.reveal.vis { opacity: 1; transform: translateY(0); }

/* Horizontal reveal — timeline items slide in from right */
.reveal-x { opacity: 0; transform: translateX(20px); transition: opacity .5s cubic-bezier(.22,1,.36,1), transform .5s cubic-bezier(.22,1,.36,1); will-change: opacity, transform; }
.reveal-x.vis { opacity: 1; transform: translateX(0); }
@media (max-width: 768px) {
  .reveal-x { transform: translateY(8px); }
  .reveal-x.vis { transform: translateY(0); }
}

/* DNA card directional reveals */
.reveal-left  { opacity: 0; transform: translateX(-44px); transition: opacity .65s ease, transform .75s cubic-bezier(0.16, 1, 0.3, 1); will-change: opacity, transform; }
.reveal-right { opacity: 0; transform: translateX( 44px); transition: opacity .65s ease, transform .75s cubic-bezier(0.16, 1, 0.3, 1); will-change: opacity, transform; }
.reveal-left.vis, .reveal-right.vis { opacity: 1; transform: translateX(0); }
@media (max-width: 768px) {
  .reveal-left, .reveal-right { transform: translateY(12px); }
  .reveal-left.vis, .reveal-right.vis { transform: translateY(0); }
}

/* ============================================================
   CURRICULUM — TIMELINE ENHANCEMENTS
   ============================================================ */
.tl-item--current .tl-dot { border-color: var(--accent); background: var(--accent); }

/* Timeline accordion */
.tl-hdr {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 16px; cursor: pointer; user-select: none;
  border-radius: 8px; transition: background .18s;
  margin: -6px -8px; padding: 6px 8px;
}
.tl-hdr:hover { background: rgba(26,43,74,.05); }
.tl-hdr:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 8px; }
.tl-hdr-text { flex: 1; min-width: 0; }
.tl-chevron {
  width: 18px; height: 18px; flex-shrink: 0; margin-top: 20px;
  color: var(--text-2);
  transition: transform 340ms cubic-bezier(.22,1,.36,1), color .2s;
}
.tl-item.open .tl-chevron { transform: rotate(180deg); color: var(--accent); }
.tl-hdr:hover .tl-chevron { color: var(--accent); }
.tl-body {
  max-height: 0; overflow: hidden;
  transition: max-height 460ms cubic-bezier(.22,1,.36,1);
}
.tl-body-inner { padding-top: 10px; }

/* dark-mode tint for pub-group-count */
[data-theme="dark"] .pub-group-count { background: rgba(240,235,225,.08); }

/* ============================================================
   KEYFRAMES
   ============================================================ */
@keyframes slideup { to { transform: translateY(0); } }
@keyframes fadein  { to { opacity: 1; } }
@keyframes ticker  { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
  .container { padding: 0 28px; }
  .about-grid { gap: 48px; }
  .svcs-grid { grid-template-columns: repeat(2,1fr); }
  .process-grid { grid-template-columns: repeat(2,1fr); }
  .process-grid::before { display: none; }
  .features-grid { grid-template-columns: repeat(2,1fr); }
  .ac-grid { grid-template-columns: 1fr; }
  .ac-box { position: static; }
  .ac-sticky-col { position: static; }
  .skills-grid { grid-template-columns: repeat(2,1fr); }
  .comp-grid { grid-template-columns: repeat(2, 1fr); }
  /* 2-col: stessa logica — chiaro di default, blu quando .open (nessun nth-child necessario) */
}
/* tablet only: last tile solo nella riga — centrato senza artefatti ai lati */
@media (min-width: 769px) and (max-width: 1024px) {
  .comp-tile:last-child:nth-child(odd) { grid-column: 1 / -1; }
  .comp-tile:last-child:nth-child(odd) .comp-tile-hdr { max-width: 50%; margin: 0 auto; }
}
@media (max-width: 768px) {
  .container { padding: 0 20px; }
  .section { padding: 72px 0; }
  .dark-sec { padding: 72px 0; }
  .hdr-nav, .hdr-cta { display: none; }
  .menu-toggle { display: flex; }
  .hdr-inner { display: flex; justify-content: space-between; }
  .brand { padding: 0; }
  .brand-logo { height: 42px; }
  .hdr-inner { height: auto; min-height: 72px; padding: 8px 0; }
  .about-grid { grid-template-columns: 1fr; gap: 32px; }
  .about-visual { aspect-ratio: 16/9; }
  .svcs-grid { grid-template-columns: 1fr; }
  .process-grid { grid-template-columns: 1fr; gap: 28px; }
  .features-grid { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: repeat(2,1fr); }
  .hero-ring { width: 160px; height: 160px; }
  .form-row { grid-template-columns: 1fr; }
  .pub-item { flex-direction: column; gap: 4px; }
  .pub-date { min-width: auto; }
  .skills-grid { grid-template-columns: 1fr; }
  .comp-area-body { padding-left: 0; }
  .comp-grid { grid-template-columns: 1fr; }

  /* Reset chessboard — colonna singola, tutte le tile uguali */
  .comp-tile:nth-child(n) { background: var(--bg); }
  .comp-tile:nth-child(n):has(.comp-tile-hdr:hover) { background: var(--surface); }
  .comp-tile:nth-child(n) .comp-tile-icon { background: rgba(26,43,74,.08); color: var(--accent); }
  .comp-tile:nth-child(n) .comp-tile-area-lbl { color: var(--accent); }
  .comp-tile:nth-child(n) .comp-tile-title { color: var(--text); }
  .comp-tile:nth-child(n) .comp-tile-tagline { color: var(--text-2); }
  .comp-tile:nth-child(n) .comp-tile-chevron { color: var(--text-2); }
  .comp-tile:nth-child(n) .comp-tile-body-inner { border-top-color: var(--line); color: var(--text-2); }
  .comp-tile:nth-child(n) .comp-tile-body-inner strong { color: var(--text); }
  .comp-tile:nth-child(n) .comp-tile-note { background: var(--surface); border-left-color: var(--line); color: var(--text-2); }
  .comp-tile-hdr { min-height: auto; padding: 20px 18px; gap: 12px; }

  .cv-section { padding: 40px 0; }
  .foot-cta-band { flex-direction: column; align-items: center; padding: 32px 0; text-align: center; }
  .foot-main { flex-direction: column; align-items: center; gap: 24px; padding: 28px 0; text-align: center; }
  .foot-brand { display: none; }
  .foot-claim { max-width: 100%; text-align: center; order: 1; }
  .foot-claim-btn { align-self: center; margin: 0 auto; display: inline-flex; order: 2; }
  .foot-form { order: 2; max-width: 100%; }
  .foot-form-submit { align-self: center; }
  .foot-form-input::placeholder { text-align: left; }

  /* Flip card mobile */
  .foot-form-wrapper { width: 100%; order: 2; perspective: 900px; }
  .foot-flip-inner {
    width: 100%;
    transition: transform .28s ease, opacity .28s ease;
    transform-origin: center center;
  }
  .foot-flip-inner.flip-out {
    transform: rotateY(90deg);
    opacity: 0;
  }
  .foot-flip-front { display: flex; justify-content: center; }
}
@media (max-width: 480px) {
  .container { padding: 0 16px; }
  .section { padding: 56px 0; }
  .hero-meta { flex-direction: column; align-items: flex-start; }
  .hero-btns { width: 100%; }
  .stats-grid { grid-template-columns: repeat(2,1fr); }
  .page-hero { min-height: 38vh; }
}

/* ============================================================
   MOBILE LAYOUT FIXES — P1-P6
   Target: 375 px (iPhone SE) · 390 px (iPhone 14)
   ============================================================ */
@media (max-width: 768px) {

  /* P1 — Logo navbar: grande e visibile su mobile */
  .brand-logo {
    height: 64px;
    width: auto;
  }

  /* P2 + P3 — Titolo hero: impatto visivo su mobile
     clamp: min 44.8 px · a 375 px → 37.5 px → usa min · a 768 px → 76.8 px → usa max 80 px */
  .hero-h1 {
    font-size: clamp(2.8rem, 10vw, 5rem);
    letter-spacing: -0.02em;
  }
  .hero-h1 .line {
    word-break: break-word;
  }

  /* P4 — Spaziatura sezioni: da 72 px a 4 rem (64 px) */
  .section        { padding: 4rem 0; }
  .dark-sec       { padding: 4rem 0; }
  .home-cards-sec { padding: 3rem 0 4rem; }
  .pull-quote-sec { padding: 4rem 0; }

  /* P5 — Kicker / etichette: non scende sotto 11 px (0.7 rem × 16 px = 11.2 px) */
  .kicker {
    font-size: 0.7rem;
    letter-spacing: 0.12em;
  }

  /* P6 — Testo body: leggibilità minima su mobile */
  .sec-lead,
  .home-card-desc,
  .about-text,
  .svc-desc,
  .step-desc,
  .feature-desc,
  .faq-body-inner,
  .metodo-body p {
    font-size: 1rem;
    line-height: 1.7;
    max-width: 100%;
  }
}

/* Ripristina padding ridotto per schermi ≤ 480 px (override del blocco precedente) */
@media (max-width: 480px) {
  .section  { padding: 3.5rem 0; }
  .dark-sec { padding: 3.5rem 0; }
}

/* ============================================================
   HOME — LINK DI NAVIGAZIONE MINIMALI
   ============================================================ */
.home-nav-link {
  padding-right: 20px !important;
  transition: background .18s ease, padding-left .18s ease;
  border-radius: 4px;
}
.home-nav-link:hover {
  background: var(--surface);
  padding-left: 12px !important;
  padding-right: 20px !important;
}
.home-nav-link:hover span {
  opacity: 1 !important;
  transform: translateX(4px);
  display: inline-block;
  transition: transform .18s ease, opacity .18s ease;
}
