/* ============================================================
   PORTA NOVA — Luxury Door Company
   Theme: Olympus & Zeus · Black Marble & Reflective Gold
   ============================================================ */

/* ── RESET & ROOT ─────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  /* Palette Tempesta Divina (Marmo e Ossidiana) */
  --black:     #050505; /* Ossidiana pura */
  --deep:      #0f0f12; /* Marmo nero profondo */
  --surface:   #1a1a1d; /* Lastra di pietra scura */
  --surface2:  #26262b; /* Grigio scuro opaco */
  --border:    #333333; /* Venatura grigia */
  --border-lg: #4d4d4d; /* Venatura chiara */
  
  /* Marmo e Oro Riflettente */
  --text:      #e8ecef; /* Bianco marmo */
  --text-dim:  #8c9196; /* Cenere */
  --gold:      #d4af37; /* Oro classico puro */
  --gold-lt:   #fff5b8; /* Riflesso oro bianco/elettrico */
  --gold-dk:   #8a6e1c; /* Ombra dell'oro */
  --gold-glow: rgba(212, 175, 55, 0.6);
  --white:     #ffffff;
  --lightning: rgba(255, 245, 184, 0.9); /* Luce del fulmine dorato */

  --ff-display: 'Cormorant Garamond', Georgia, serif;
  --ff-body:    'Raleway', 'Helvetica Neue', sans-serif;

  --ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);
  --ease-expo:   cubic-bezier(0.16, 1, 0.3, 1);
  --ease-back:   cubic-bezier(0.34, 1.56, 0.64, 1);
}

html { scroll-behavior: smooth; font-size: 16px; }

body {
  background: var(--black);
  color: var(--text);
  font-family: var(--ff-body);
  font-weight: 300;
  line-height: 1.65;
  overflow-x: hidden;
  cursor: none;
  position: relative;
}

/* ── EFFETTO FULMINI SULLO SFONDO ─────────────────────────── */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  background: var(--lightning);
  opacity: 0;
  pointer-events: none;
  z-index: 99999;
  mix-blend-mode: overlay;
  animation: zeusWrath 14s infinite;
}

/* ── SCROLLBAR ────────────────────────────────────────────── */
::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: var(--black); }
::-webkit-scrollbar-thumb { background: linear-gradient(to bottom, var(--gold-lt), var(--gold), var(--gold-dk)); border-radius: 2px; }

/* ── TYPOGRAPHY BASE ──────────────────────────────────────── */
h1, h2, h3, h4 { font-family: var(--ff-display); font-weight: 300; line-height: 1.1; text-transform: uppercase; letter-spacing: 0.05em; }
em { font-style: italic; color: var(--gold); text-transform: none; }
a { color: inherit; text-decoration: none; }

.section-label {
  font-family: var(--ff-body);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--gold-lt);
  margin-bottom: 1.4rem;
  display: block;
  text-shadow: 0 0 8px var(--gold-glow);
}
.section-label.centered { text-align: center; }

/* ── ANIMATIONS ───────────────────────────────────────────── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(32px); }
  to   { opacity: 1; transform: translateY(0); }
}
/* ============================================================
   MARQUEE — PATCH FINALE (sostituisce TUTTE le sezioni
   .marquee-* presenti in style.css con questo blocco unico)
   ============================================================ */

/* ── Striscia contenitore ── */
.marquee-strip {
    background: var(--surface);
    border-top:    1px solid var(--border);
    border-bottom: 1px solid var(--border);
    overflow: hidden;          /* ← SOLO QUI l'overflow:hidden */
    width: 100vw;
    position: relative;
    box-shadow: 0 5px 30px rgba(0,0,0,0.8) inset;

    /* Fade laterale luxury */
    -webkit-mask-image: linear-gradient(to right, transparent 0%, black 5%, black 95%, transparent 100%);
    mask-image:         linear-gradient(to right, transparent 0%, black 5%, black 95%, transparent 100%);
}

/* ── Track: è l'elemento #dynamicMarquee creato dal JS ──
   L'animazione VA QUI, su translateX(-50%), perché il track
   contiene DUE blocchi .marquee-content identici:
   spostandosi del 50% torna esattamente all'inizio → loop seamless ── */
#dynamicMarquee {
    display: flex;
    align-items: center;
    width: max-content;        /* si allarga quanto serve */
    height: 64px;              /* altezza barra */
    will-change: transform;
    animation: marqueeScroll 32s linear infinite;
}

/* Pausa al hover */
.marquee-strip:hover #dynamicMarquee {
    animation-play-state: paused;
}

/* Pausa se scheda in background (impostata via JS, ma anche qui per sicurezza) */
#dynamicMarquee[style*="paused"] {
    animation-play-state: paused;
}

/* ── I due blocchi clonati dal JS ── */
.marquee-content {
    display: inline-flex;
    align-items: center;
    flex-shrink: 0;
    /* NESSUNA animation qui — l'animazione è solo sul track */
}

/* ── IMMAGINI ── */
.marquee-img {
    display:        inline-block;
    height:         44px;      /* altezza fissa — modifica questo se vuoi più/meno grande */
    width:          auto;      /* larghezza proporzionale automatica */
    min-width:      55px;
    max-width:      110px;
    object-fit:     cover;
    object-position: center;
    border-radius:  2px;
    flex-shrink:    0;
    vertical-align: middle;
    opacity:        0.85;
    outline:        1px solid rgba(212,175,55,0.3);
    transition:     opacity 0.3s ease, transform 0.3s ease;
}

.marquee-img:hover {
    opacity:       1;
    transform:     scale(1.06);
    outline-color: var(--gold-lt);
}

/* ── Testi ── */
.marquee-content span {
    display:        inline-flex;
    align-items:    center;
    padding:        0 22px;
    font-family:    var(--ff-body);
    font-size:      0.75rem;
    font-weight:    600;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color:          var(--text);
    white-space:    nowrap;
    flex-shrink:    0;
}

/* ── Separatori ── */
.marquee-content .sep {
    padding:    0 10px;
    color:      var(--gold-lt);
    letter-spacing: 0;
    text-shadow: 0 0 15px var(--white);
    flex-shrink: 0;
}

/* ── Keyframe (translateX -50% = si sposta di 1 blocco su 2 → loop) ── */
@keyframes marqueeScroll {
    0%   { transform: translate3d(0, 0, 0); }
    100% { transform: translate3d(-50%, 0, 0); }
}

/* ── Responsive ── */
@media (max-width: 768px) {
    #dynamicMarquee { height: 52px; animation-duration: 22s; }
    .marquee-img    { height: 34px; }
}
@media (max-width: 480px) {
    #dynamicMarquee { height: 44px; animation-duration: 18s; }
    .marquee-img    { height: 28px; }
}

/* ── Accessibilità ── */
@media (prefers-reduced-motion: reduce) {
    #dynamicMarquee { animation: none; }
}

@keyframes doorOpen {
  0%   { transform: perspective(1000px) rotateY(0deg); box-shadow: 0 0 0 transparent; }
  100% { transform: perspective(1000px) rotateY(-85deg); box-shadow: -20px 0 50px var(--gold-glow); }
}
@keyframes lightPulse {
  0%, 100% { opacity: 0.5; transform: scale(0.95); }
  50%       { opacity: 1; transform: scale(1.05); }
}
@keyframes rotateGeo {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}
@keyframes scrollLine {
  0%   { transform: scaleY(0); transform-origin: top; }
  50%  { transform: scaleY(1); transform-origin: top; box-shadow: 0 0 15px var(--gold-lt); }
  51%  { transform: scaleY(1); transform-origin: bottom; }
  100% { transform: scaleY(0); transform-origin: bottom; }
}
@keyframes zeusWrath {
  0%, 91%, 93%, 95%, 97%, 100% { opacity: 0; }
  92% { opacity: 0.8; }
  94% { opacity: 0.2; }
  96% { opacity: 1; }
}

.reveal-up {
  opacity: 0;
  animation: fadeUp 1s var(--ease-expo) forwards;
}
.reveal-up:nth-child(1) { animation-delay: 0.3s; }
.reveal-up:nth-child(2) { animation-delay: 0.55s; }
.reveal-up:nth-child(3) { animation-delay: 0.75s; }
.reveal-up:nth-child(4) { animation-delay: 0.95s; }

/* ── NAV ──────────────────────────────────────────────────── */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.6rem 3rem;
  z-index: 900;
  transition: background 0.5s, padding 0.4s, backdrop-filter 0.5s, border-bottom 0.5s;
}
.nav.scrolled {
  background: rgba(5, 5, 5, 0.9);
  backdrop-filter: blur(20px);
  padding: 1rem 3rem;
  border-bottom: 1px solid var(--border);
  box-shadow: 0 10px 30px rgba(0,0,0,0.8);
}
.nav__logo {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  font-family: var(--ff-body);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--white);
  text-shadow: 0 0 10px rgba(255,255,255,0.2);
}
.nav__logo-symbol { color: var(--gold); font-size: 1.2rem; text-shadow: 0 0 20px var(--gold-lt); }

.nav__links {
  display: flex;
  gap: 2.4rem;
  list-style: none;
}
.nav__link {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-dim);
  position: relative;
  transition: color 0.3s, text-shadow 0.3s;
}
.nav__link::after {
  content: '';
  position: absolute;
  bottom: -6px; left: 0;
  width: 0; height: 2px;
  background: linear-gradient(90deg, transparent, var(--gold-lt), transparent);
  box-shadow: 0 0 8px var(--gold);
  transition: width 0.35s var(--ease-smooth);
}
.nav__link:hover { color: var(--white); text-shadow: 0 0 8px var(--gold-lt); }
.nav__link:hover::after { width: 100%; }

.nav__menu-btn {
  display: none;
  flex-direction: column;
  gap: 6px;
  background: none;
  border: none;
  cursor: none;
  padding: 4px;
}
.nav__menu-btn span {
  display: block;
  width: 26px; height: 2px;
  background: var(--gold);
  box-shadow: 0 0 5px var(--gold);
  transition: transform 0.3s, opacity 0.3s;
}

/* ── MOBILE MENU ──────────────────────────────────────────── */
.mobile-menu {
  position: fixed;
  inset: 0;
  background: var(--deep);
  z-index: 850;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s;
}
.mobile-menu.open {
  opacity: 1;
  pointer-events: all;
  background: radial-gradient(circle at center, var(--surface), var(--black));
}
.mobile-menu ul {
  list-style: none;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 2.4rem;
}
.mobile-link {
  font-family: var(--ff-display);
  font-size: clamp(2rem, 8vw, 3.5rem);
  color: var(--text-dim);
  text-transform: uppercase;
  transition: color 0.3s, text-shadow 0.3s;
}
.mobile-link:hover { color: var(--white); text-shadow: 0 0 20px var(--gold-glow); }

/* ── HERO (GATES OF OLYMPUS) ──────────────────────────────── */
.hero {
  position: relative;
  height: 100vh;
  min-height: 700px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: var(--black);
}

.hero__corridor {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  perspective: 1000px;
}
.corridor__layer {
  position: absolute;
  border: 2px solid rgba(212, 175, 55, 0.3);
  transform-style: preserve-3d;
  box-shadow: inset 0 0 60px rgba(0, 0, 0, 0.9);
}
.corridor__layer--1 { width: 92%; height: 88%; opacity: 1.00; }
.corridor__layer--2 { width: 78%; height: 72%; opacity: 0.85; border-color: rgba(212, 175, 55, 0.25); }
.corridor__layer--3 { width: 62%; height: 56%; opacity: 0.70; border-color: rgba(212, 175, 55, 0.20); }
.corridor__layer--4 { width: 46%; height: 42%; opacity: 0.55; border-color: rgba(212, 175, 55, 0.15); }
.corridor__layer--5 { width: 30%; height: 28%; opacity: 0.40; border-color: rgba(212, 175, 55, 0.10); }
.corridor__layer--6 { width: 16%; height: 14%; opacity: 0.25; border-color: rgba(212, 175, 55, 0.05); }

.corridor__layer--1::before,
.corridor__layer--1::after {
  content: '';
  position: absolute;
  width: 40px; height: 40px;
  border-color: var(--gold-lt);
  border-style: solid;
  box-shadow: 0 0 20px var(--gold-glow);
}
.corridor__layer--1::before { top: -2px; left: -2px; border-width: 3px 0 0 3px; }
.corridor__layer--1::after { bottom: -2px; right: -2px; border-width: 0 3px 3px 0; }

/* =========================================
   PORTE GIGANTI E SBLOCCATE PER IL JS
========================================= */
.corridor__door {
  position: absolute;
  /* Dimensioni monumentali */
  width: 45vw; 
  max-width: 500px;
  min-width: 300px;
  height: 65vh;
  max-height: 850px;
  min-height: 450px;
  perspective: 1200px; /* Aumentato per non distorcere le ante giganti */
  cursor: grab; /* Cambia il cursore per far capire che si può toccare */
  z-index: 50;
}

.corridor__door:active {
  cursor: grabbing;
}

.door__frame { 
  width: 100%; height: 100%; 
  border: 4px solid var(--gold-lt); 
  position: relative; 
  transform-style: preserve-3d; 
  box-shadow: 0 0 50px var(--gold-glow); 
  transition: box-shadow 0.3s ease;
}

.corridor__door:hover .door__frame {
  box-shadow: 0 0 80px var(--gold-lt); /* Si illumina quando ci passi sopra */
}

/* =========================================
   PORTE INTERATTIVE (Proporzioni Reali Corrette)
========================================= */
.corridor__door {
  position: absolute;
  /* Larghezza ridotta per non accavallarsi ai testi */
  width: 28vw; 
  min-width: 260px;
  max-width: 350px; /* Blocco la larghezza massima */
  
  /* Altezza slanciata */
  height: 65vh;
  min-height: 450px;
  max-height: 750px;
  
  perspective: 1500px; /* Aumentato per una prospettiva 3D più realistica */
  cursor: grab; 
  z-index: 50; /* Lo mantiene cliccabile */
}

.corridor__door:active {
  cursor: grabbing;
}

.door__frame { 
  width: 100%; height: 100%; 
  border: 4px solid var(--gold-lt); 
  position: relative; 
  transform-style: preserve-3d; 
  box-shadow: 0 0 50px var(--gold-glow); 
  transition: box-shadow 0.3s ease;
}

.corridor__door:hover .door__frame {
  box-shadow: 0 0 80px var(--gold-lt); 
}

/* =========================================
   PANNELLI DELLE ANTE (Texture Fotografiche)
========================================= */
.door__panel { 
  position: absolute; 
  top: 0; 
  width: 50%; 
  height: 100%; 
  border: 1px solid var(--gold-dk); 
  
  /* background-size: cover riempie l'anta senza distorcere/schiacciare la foto */
  background-size: cover; 
  background-position: center;
  background-repeat: no-repeat;
  
  animation: none !important; 
}

/* Texture Anta Sinistra */
.door__panel--left { 
  left: 0; 
  transform-origin: left; 
  transform: perspective(1200px) rotateY(0deg); 
  background-image: url('ante/as.jpg'); 
}

/* Texture Anta Destra */
.door__panel--right { 
  right: 0; 
  transform-origin: right; 
  transform: perspective(1200px) rotateY(0deg); 
  background-image: url('ante/ad.jpg'); 
}

.door__light { 
  position: absolute; inset: 0; 
  background: radial-gradient(ellipse at center, rgba(255, 245, 184, 0.8) 0%, transparent 80%); 
  animation: lightPulse 4s ease-in-out infinite; 
  mix-blend-mode: screen; 
  pointer-events: none; 
}

.door__light { 
  position: absolute; inset: 0; 
  background: radial-gradient(ellipse at center, rgba(255, 245, 184, 0.8) 0%, transparent 80%); 
  animation: lightPulse 4s ease-in-out infinite; 
  mix-blend-mode: screen; 
  pointer-events: none; /* Impedisce che la luce blocchi il click sulle ante */
}




.hero::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse 80% 80% at 50% 50%, transparent 20%, rgba(5,5,5,0.8) 60%, var(--black) 100%); z-index: 1;
}

.hero__grain {
  position: absolute; inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23n)' opacity='0.08'/%3E%3C/svg%3E");
  opacity: 0.6; z-index: 2; pointer-events: none; mix-blend-mode: overlay;
}

.hero__content { position: relative; z-index: 10; text-align: center; padding: 2rem; text-shadow: 0 5px 30px rgba(0,0,0,0.9); }
.hero__eyebrow { 
  font-size: 0.55rem; 
  font-weight: 600; 
  letter-spacing: 0.2em; 
  line-height: 2; 
  text-transform: uppercase; 
  color: var(--white); 
  margin-top: 30px;
  margin-bottom: 2rem; 
  text-shadow: 0 0 15px var(--gold-lt);
  max-width: 650px; 
  margin-inline: auto; 
}
.hero__title { font-family: var(--ff-display); font-size: clamp(4rem, 10vw, 8.5rem); font-weight: 300; line-height: 0.95; color: var(--white); margin-bottom: 1.6rem; text-transform: uppercase; }
.hero__title span, .hero__title em { display: block; }
.hero__title em { 
  background: linear-gradient(to bottom, var(--gold-lt) 20%, var(--gold) 50%, var(--gold-dk) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  font-style: normal; 
  text-shadow: 0 0 40px rgba(212, 175, 55, 0.4); 
}
.hero__subtitle { font-size: clamp(1rem, 1.8vw, 1.2rem); font-weight: 400; color: var(--text); line-height: 1.8; margin-bottom: 3rem; letter-spacing: 0.05em; max-width: 600px; margin-inline: auto; }
.hero__cta { display: inline-flex; align-items: center; gap: 1rem; padding: 1rem 2.5rem; border: 1px solid var(--gold); font-size: 0.8rem; font-weight: 600; letter-spacing: 0.25em; text-transform: uppercase; color: var(--white); background: rgba(5, 5, 5, 0.6); backdrop-filter: blur(5px); transition: all 0.4s var(--ease-smooth); position: relative; overflow: hidden; box-shadow: 0 0 20px rgba(0,0,0,0.8); }
.hero__cta::before { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, var(--gold-dk), var(--gold-lt), var(--gold-dk)); transform: scaleX(0); transform-origin: left; transition: transform 0.5s var(--ease-expo); z-index: 0; }
.hero__cta:hover::before { transform: scaleX(1); }
.hero__cta:hover { color: var(--black); box-shadow: 0 0 40px var(--gold-glow); border-color: var(--white); }
.hero__cta svg { width: 18px; height: 18px; position: relative; z-index: 1; transition: transform 0.3s; }
.hero__cta:hover svg { transform: translateX(5px); color: var(--black); }
.hero__cta span { position: relative; z-index: 1; text-shadow: 0 0 5px rgba(255,255,255,0.3); }

.hero__scroll-hint { position: absolute; bottom: 2.4rem; left: 50%; transform: translateX(-50%); z-index: 10; display: flex; flex-direction: column; align-items: center; gap: 0.8rem; }
.hero__scroll-hint span { font-size: 0.65rem; font-weight: 600; letter-spacing: 0.35em; text-transform: uppercase; color: var(--gold-lt); text-shadow: 0 0 10px var(--gold-glow); }
.scroll-line { width: 2px; height: 60px; background: linear-gradient(to bottom, var(--gold-lt), transparent); transform-origin: top; animation: scrollLine 2s ease-in-out infinite; }

/* ── ABOUT (TEMPLE FOUNDATIONS) ───────────────────────────── */
.about { padding: 10rem 6vw; background: radial-gradient(circle at top right, var(--surface2), var(--deep) 70%); }
.about__grid { max-width: 1200px; margin: 0 auto; display: grid; grid-template-columns: 1fr 1fr; gap: 8rem; align-items: center; }
.about__visual { position: relative; }
.about__frame { aspect-ratio: 1; border: 2px solid var(--border-lg); position: relative; max-width: 450px; margin-bottom: 2rem; overflow: hidden; background: var(--black); box-shadow: 0 20px 60px rgba(0,0,0,0.9); }
.about__inner-frame { position: absolute; inset: 20px; border: 1px solid var(--gold-dk); display: flex; align-items: center; justify-content: center; overflow: hidden; background: linear-gradient(135deg, var(--surface) 0%, var(--black) 100%); }
.about__geometry { position: absolute; inset: 0; }
.geo { position: absolute; }
.geo--rect { inset: 15%; border: 1px solid rgba(255, 255, 255, 0.15); animation: rotateGeo 40s linear infinite; box-shadow: 0 0 30px inset rgba(212,175,55,0.08); }
.geo--diagonal { width: 200%; height: 2px; background: linear-gradient(90deg, transparent, var(--gold-lt), transparent); top: 50%; left: -50%; transform: rotate(-30deg); box-shadow: 0 0 20px var(--gold); }
.geo--circle { width: 65%; height: 65%; border-radius: 50%; border: 2px solid rgba(212, 175, 55, 0.25); top: 17.5%; left: 17.5%; }
.about__number { font-family: var(--ff-display); font-size: 10rem; font-weight: 300; color: rgba(255, 255, 255, 0.05); line-height: 1; position: relative; z-index: 1; user-select: none; text-shadow: 0 0 40px rgba(212,175,55,0.15); }
.about__stat-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 1.5rem; }
.stat-card { padding: 1.5rem; border: 1px solid var(--border); background: rgba(26, 26, 29, 0.6); backdrop-filter: blur(10px); transition: all 0.4s var(--ease-smooth); box-shadow: 0 10px 30px rgba(0,0,0,0.6); }
.stat-card:hover { border-color: var(--gold-lt); box-shadow: 0 15px 40px rgba(0,0,0,0.8), 0 0 25px var(--gold-glow) inset; transform: translateY(-5px); background: rgba(38, 38, 43, 0.8); }
.stat-card__num { font-family: var(--ff-display); font-size: 2.5rem; font-weight: 300; color: var(--white); line-height: 1; margin-bottom: 0.5rem; text-shadow: 0 0 20px var(--gold-glow); }
.stat-card__label { font-size: 0.7rem; font-weight: 600; letter-spacing: 0.15em; text-transform: uppercase; color: var(--gold-lt); }

.about__title { font-size: clamp(2.5rem, 4.5vw, 4rem); margin-bottom: 2rem; color: var(--white); text-shadow: 0 5px 20px rgba(0,0,0,0.8); }
.about__body { font-size: 1rem; color: var(--text); line-height: 1.9; margin-bottom: 2rem; font-weight: 400; }
.text-link { display: inline-flex; align-items: center; gap: 0.8rem; font-size: 0.75rem; font-weight: 600; letter-spacing: 0.25em; text-transform: uppercase; color: var(--gold-lt); position: relative; margin-top: 1rem; text-shadow: 0 0 10px rgba(255, 245, 184, 0.4); }
.text-link__line { display: block; width: 40px; height: 2px; background: var(--white); transition: width 0.4s var(--ease-expo); box-shadow: 0 0 10px var(--gold); }
.text-link:hover .text-link__line { width: 70px; background: var(--gold-lt); }

/* ── COLLECTIONS (DIVINE ARTIFACTS) ───────────────────────── */
.collections {
  position: relative;
  min-height: 80vh;
  padding: 120px 0;
  background-image: url('sfondo2.png'); 
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-attachment: fixed; 
  overflow: hidden;
}

.collections::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0, 0, 0, 0.75); /* Più scuro per risaltare l'oro */
  z-index: 1;
}

.collections__header, 
.collections__grid, 
#grid-container {
  position: relative;
  z-index: 2; 
}

.collections__title {
  color: #ffffff !important;
  text-shadow: 0 5px 20px rgba(0,0,0,0.8);
}

.section-label {
    color: var(--gold-lt); 
}

.collections__header { max-width: 1200px; margin: 0 auto 5rem; text-align: center; }
.collections__title { font-size: clamp(2.8rem, 5.5vw, 4.5rem); color: var(--white); text-shadow: 0 0 25px rgba(255,255,255,0.2); }

.collections__grid { 
  max-width: 1400px; 
  margin: 0 auto; 
  display: grid; 
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); 
  gap: 2.5rem; 
}
.collection-card { 
  position: relative; 
  min-height: 450px; 
  overflow: hidden; 
  cursor: none; 
  background: var(--surface); 
  border: 1px solid var(--border); 
  transition: all 0.5s var(--ease-smooth); 
  box-shadow: 0 15px 40px rgba(0,0,0,0.8);
}
.collection-card:hover { 
  border-color: var(--white); 
  box-shadow: 0 20px 60px rgba(0,0,0,0.9), 0 0 40px rgba(212, 175, 55, 0.3) inset; 
  transform: translateY(-10px);
}
.collection-card__bg { 
  position: absolute; 
  inset: 0; 
  padding: 1.5rem; 
  overflow: hidden; 
}
/* Effetto ORO puro a riposo */
.collection-card__img {
  width: 100%;
  height: 100%;
  object-fit: contain; 
  object-position: center;
  display: block;
  transform: scale(0.95);
  
  /* Sostituisci il vecchio grayscale con questo mix dorato */
  filter: sepia(1) saturate(250%) hue-rotate(5deg) brightness(0.9) contrast(1.2);
  
  transition: transform 0.8s var(--ease-expo), filter 0.8s var(--ease-expo);
}

/* Quando l'utente passa il mouse, l'oro si accende e "brilla" */
.collection-card:hover .collection-card__img {
  transform: scale(1.08);
  filter: sepia(1) saturate(400%) hue-rotate(10deg) brightness(1.1) contrast(1.3) drop-shadow(0 0 20px var(--gold-glow));
}

/* =========================================
   OVERLAY MODIFICATO PER MAGGIORE CONTRASTO
========================================= */
.collection-card__content {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 1.5rem;
  z-index: 10;
}
.collection-card__overlay { 
  position: absolute; 
  inset: 0; 
  background: linear-gradient(to top, rgba(5,5,5,0.95) 0%, rgba(5,5,5,0.6) 35%, transparent 60%); 
  z-index: 1; 
  transition: background 0.5s var(--ease-smooth);
}

.collection-card:hover .collection-card__overlay {
  background: linear-gradient(to top, rgba(5,5,5,1) 0%, rgba(5,5,5,0.75) 45%, transparent 70%);
}

/* =========================================
   TESTO CON OMBRA MARCATA
========================================= */
@keyframes whiteGoldGrey {
  0%   { color: #ffffff; text-shadow: 0 0 20px rgba(255,255,255,0.8); }
  40%  { color: var(--gold-lt); text-shadow: 0 0 20px var(--gold-glow); }
  100% { color: #888888; text-shadow: 0 0 10px rgba(136,136,136,0.3); }
}

.collection-card__name { 
  font-family: var(--ff-display); 
  font-size: clamp(1.4rem, 2.5vw, 2rem); 
  font-weight: 300; 
  margin-bottom: 0.8rem; 
  transform: scale(1);
  animation: whiteGoldGrey 3s var(--ease-smooth) infinite alternate;
  transition: transform 0.4s var(--ease-smooth); /* solo transform, non color/text-shadow */
}

.collection-card:hover .collection-card__name {
  color: var(--gold-lt);
  text-shadow: 0 0 20px var(--gold-glow), 0 4px 10px rgba(0,0,0,0.9);
  transform: scale(1.05);
  animation-play-state: paused; /* ferma l'animazione sull'hover */
}

.card-cta { 
  font-size: 0.7rem; 
  font-weight: 600;
  letter-spacing: 0.25em; 
  text-transform: uppercase; 
  color: var(--white); 
  opacity: 0; 
  transform: translateY(15px); 
  transition: opacity 0.4s var(--ease-expo), transform 0.4s var(--ease-expo); 
  display: inline-block; 
  border-bottom: 1px solid var(--gold-lt);
  padding-bottom: 4px;
  /* Aggiunta ombra di leggibilità anche per la Call To Action */
  text-shadow: 0 2px 5px rgba(0,0,0,1);
}

.collection-card:hover .card-cta { 
  opacity: 1; 
  transform: translateY(0); 
  transition-delay: 0.1s; 
}


/* ── CRAFT (FORGING THE GATES) ────────────────────────────── */
.craft { position: relative; padding: 10rem 6vw; background: linear-gradient(to bottom, var(--surface2), var(--deep)); overflow: hidden; }
.craft__bg { position: absolute; inset: 0; opacity: 0.4; pointer-events: none; background: radial-gradient(circle at center, rgba(255, 255, 255, 0.05), transparent 70%); }
.craft__perspective-grid { position: absolute; inset: 0; background-image: linear-gradient(var(--border) 1px, transparent 1px), linear-gradient(90deg, var(--border) 1px, transparent 1px); background-size: 80px 80px; transform: perspective(800px) rotateX(50deg) translateY(-10%); transform-origin: bottom center; opacity: 0.3; }
.craft__content { position: relative; z-index: 2; max-width: 1300px; margin: 0 auto; display: grid; grid-template-columns: 1fr 1.5fr; gap: 8rem; align-items: start; }
.craft__title { font-size: clamp(2.5rem, 4.5vw, 4rem); color: var(--white); margin-bottom: 1.8rem; text-shadow: 0 5px 20px rgba(0,0,0,0.8); }
.craft__body { font-size: 1rem; color: var(--text); line-height: 1.9; font-weight: 400; }

.craft-step { display: flex; gap: 2rem; align-items: flex-start; margin-bottom: 2rem; }
.craft-step__connector { width: 2px; height: 3.5rem; background: linear-gradient(to bottom, var(--gold-lt), transparent); margin: 0.5rem 0 0.5rem 1.8rem; box-shadow: 0 0 15px rgba(212,175,55,0.4); }
.craft-step__num { width: 3.8rem; height: 3.8rem; flex-shrink: 0; border: 2px solid var(--gold); background: rgba(5, 5, 5, 0.8); display: flex; align-items: center; justify-content: center; font-family: var(--ff-display); font-size: 1.4rem; color: var(--white); box-shadow: 0 0 20px var(--gold-glow) inset, 0 5px 20px rgba(0,0,0,0.8); }
.craft-step__info h4 { font-family: var(--ff-display); font-size: 1.4rem; font-weight: 400; color: var(--gold-lt); margin-bottom: 0.5rem; letter-spacing: 0.1em; }
.craft-step__info p { font-size: 0.9rem; color: var(--text-dim); line-height: 1.8; }

/* ── QUOTE INTERLUDE (VOICE OF GODS) ──────────────────────── */
.quote-interlude { position: relative; padding: 9rem 6vw; background: var(--black); display: flex; align-items: center; justify-content: center; text-align: center; overflow: hidden; box-shadow: 0 0 80px rgba(0,0,0,0.9) inset; }
.quote-interlude__lines { position: absolute; inset: 0; opacity: 0.3; }
.qi-line { position: absolute; background: var(--border-lg); box-shadow: 0 0 15px var(--white); }
.qi-line--h { width: 100%; height: 1px; top: 50%; }
.qi-line--v { width: 1px; height: 100%; left: 50%; }
blockquote { position: relative; z-index: 2; max-width: 800px; background: rgba(10, 10, 12, 0.8); padding: 4rem; backdrop-filter: blur(10px); border: 1px solid var(--border); box-shadow: 0 30px 60px rgba(0,0,0,0.9); }
.quote-mark { font-family: var(--ff-display); font-size: 8rem; line-height: 0.5; color: var(--white); opacity: 0.2; display: block; margin-bottom: 1.5rem; text-shadow: 0 0 30px var(--gold-lt); }
blockquote p { font-family: var(--ff-display); font-size: clamp(1.6rem, 3vw, 2.4rem); font-weight: 300; font-style: normal; color: var(--gold-lt); line-height: 1.4; margin-bottom: 2rem; text-transform: uppercase; letter-spacing: 0.05em; text-shadow: 0 0 15px rgba(212,175,55,0.3); }
blockquote cite { font-size: 0.8rem; font-weight: 600; letter-spacing: 0.3em; text-transform: uppercase; color: var(--white); font-style: normal; }

/* ── CONTACT (THE ALTAR) ──────────────────────────────────── */
.contact { 
  position: relative; 
  padding: 10rem 6vw; 
  background: linear-gradient(rgba(5, 5, 5, 0.7), rgba(5, 5, 5, 0.7)), url('sfondo3.png'); 
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-attachment: fixed; 
  overflow: hidden; 
}

.contact__bg { 
  position: absolute; 
  inset: 0; 
  pointer-events: none; 
  background: radial-gradient(circle at center, rgba(38, 38, 43, 0.3), var(--black) 90%); 
  z-index: 1;
}

.contact__mirror-frame { 
  position: absolute; 
  top: 50%; left: 50%; 
  width: 75%; height: 80%; 
  transform: translate(-50%, -50%); 
  border: 2px solid var(--border-lg); 
  box-shadow: 0 0 60px rgba(0,0,0,0.8) inset, 0 0 20px rgba(212,175,55,0.2); 
  pointer-events: none;
  z-index: 2;
}

.contact__mirror-frame::before { 
  content: ''; 
  position: absolute; 
  inset: 24px; 
  border: 1px solid var(--gold); 
  opacity: 0.3; 
}

.contact__inner { 
  position: relative; 
  z-index: 10; 
  max-width: 800px; 
  margin: 0 auto; 
  text-align: center; 
  background: rgba(15, 15, 18, 0.9); 
  padding: 4rem; 
  backdrop-filter: blur(15px); 
  border: 1px solid var(--border-lg); 
  box-shadow: 0 30px 60px rgba(0,0,0,0.9); 
}

.contact__title { 
  font-size: clamp(2.8rem, 5.5vw, 4.5rem); 
  color: var(--white); 
  margin-bottom: 1.5rem; 
  text-shadow: 0 0 25px rgba(255,255,255,0.3); 
}

.contact__sub { 
  font-size: 1rem; 
  color: var(--text); 
  margin-bottom: 4rem; 
  font-weight: 400; 
}

.contact__form { text-align: left; }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; }

.form-field { position: relative; margin-bottom: 2.5rem; }

.form-field input, 
.form-field textarea { 
  width: 100%; 
  background: transparent; 
  border: none; 
  border-bottom: 2px solid var(--border); 
  padding: 1rem 0 0.5rem; 
  font-family: var(--ff-body); 
  font-size: 1rem; 
  font-weight: 400; 
  color: var(--white); 
  outline: none; 
  resize: none; 
  transition: border-color 0.3s, box-shadow 0.3s; 
}

.form-field label { 
  position: absolute; 
  top: 1rem; left: 0; 
  font-size: 0.8rem; 
  font-weight: 600; 
  letter-spacing: 0.15em; 
  color: var(--text-dim); 
  text-transform: uppercase; 
  pointer-events: none; 
  transition: transform 0.3s, font-size 0.3s, color 0.3s; 
  transform-origin: left; 
}

.form-field input:focus ~ label, 
.form-field input:not(:placeholder-shown) ~ label, 
.form-field textarea:focus ~ label, 
.form-field textarea:not(:placeholder-shown) ~ label { 
  transform: translateY(-1.5rem); 
  font-size: 0.65rem; 
  color: var(--gold-lt); 
  letter-spacing: 0.25em; 
  text-shadow: 0 0 10px var(--gold-glow); 
}

.field-line { 
  position: absolute; 
  bottom: 0; left: 0; 
  width: 0; height: 2px; 
  background: linear-gradient(90deg, var(--gold-lt), var(--gold), var(--gold-dk)); 
  transition: width 0.5s var(--ease-expo); 
  box-shadow: 0 0 15px var(--gold); 
}

.form-field:focus-within .field-line { width: 100%; }

.form-submit { 
  display: flex; 
  align-items: center; 
  justify-content: center; 
  gap: 1.2rem; 
  width: 100%; 
  padding: 1.4rem 2.5rem; 
  background: var(--surface); 
  border: 2px solid var(--gold); 
  font-family: var(--ff-body); 
  font-size: 0.85rem; 
  font-weight: 600; 
  letter-spacing: 0.3em; 
  text-transform: uppercase; 
  color: var(--white); 
  cursor: none; 
  position: relative; 
  overflow: hidden; 
  transition: color 0.4s, box-shadow 0.4s; 
  margin-top: 2rem; 
  box-shadow: 0 15px 30px rgba(0,0,0,0.6); 
}

.form-submit::before { 
  content: ''; 
  position: absolute; 
  inset: 0; 
  background: linear-gradient(90deg, var(--gold-dk), var(--gold-lt), var(--gold-dk)); 
  transform: translateY(100%); 
  transition: transform 0.5s var(--ease-expo); 
}

.form-submit:hover::before { transform: translateY(0); }

.form-submit:hover { 
  color: var(--black); 
  box-shadow: 0 20px 40px var(--gold-glow); 
  border-color: var(--white); 
}

.form-submit__text, 
.form-submit__icon { position: relative; z-index: 1; }

.form-success { 
  display: none; 
  flex-direction: column; 
  align-items: center; 
  gap: 1rem; 
  padding: 2.5rem; 
  margin-top: 2rem; 
  border: 2px solid var(--gold-lt); 
  background: rgba(212, 175, 55, 0.08); 
  color: var(--gold-lt); 
  text-align: center; 
  animation: fadeUp 0.6s var(--ease-expo) forwards; 
  box-shadow: 0 0 40px var(--gold-glow) inset; 
}

.form-success.visible { display: flex; }

.form-success__icon { font-size: 2rem; text-shadow: 0 0 20px var(--gold-lt); }

.form-success p { 
  font-size: 0.9rem; 
  font-weight: 600; 
  letter-spacing: 0.15em; 
  color: var(--white); 
  text-transform: uppercase; 
}

/* ── FOOTER ───────────────────────────────────────────────── */
.footer { 
  background: var(--black); 
  border-top: 2px solid var(--border); 
  box-shadow: 0 -15px 40px rgba(0,0,0,0.8); 
}

.footer__top { 
  display: grid; 
  grid-template-columns: 2fr 1fr 1fr 1fr; 
  gap: 4rem; 
  padding: 5rem 6vw; 
  max-width: 1400px; 
  margin: 0 auto; 
}

.footer__brand .footer__logo-symbol { 
  font-size: 1.8rem; 
  color: var(--gold); 
  text-shadow: 0 0 25px var(--gold-glow); 
}

.footer__brand .footer__logo-text { 
  display: block; 
  font-size: 0.85rem; 
  font-weight: 600; 
  letter-spacing: 0.35em; 
  text-transform: uppercase; 
  color: var(--white); 
  margin: 0.8rem 0; 
}

.footer__brand p { 
  font-size: 0.85rem; 
  color: var(--text-dim); 
  line-height: 1.8; 
}

.footer__links { display: flex; flex-direction: column; gap: 1rem; }

.footer__links h5 { 
  font-family: var(--ff-body); 
  font-size: 0.75rem; 
  font-weight: 600; 
  letter-spacing: 0.25em; 
  text-transform: uppercase; 
  color: var(--white); 
  margin-bottom: 0.5rem; 
  text-shadow: 0 0 8px rgba(255,255,255,0.4); 
}

.footer__links a, 
.footer__links span { 
  font-size: 0.85rem; 
  font-weight: 400; 
  color: var(--text); 
  transition: color 0.3s, text-shadow 0.3s; 
}

.footer__links a:hover { 
  color: var(--gold-lt); 
  text-shadow: 0 0 15px var(--gold-glow); 
}

.footer__bottom { 
  border-top: 1px solid var(--border); 
  padding: 2rem 6vw; 
  display: flex; 
  justify-content: space-between; 
  align-items: center; 
  font-size: 0.75rem; 
  font-weight: 500; 
  color: var(--text-dim); 
  letter-spacing: 0.1em; 
  max-width: 100%; 
  text-transform: uppercase; 
}

/* ── SCROLL REVEAL ────────────────────────────────────────── */
.js-reveal { opacity: 0; transform: translateY(40px); transition: opacity 1s var(--ease-expo), transform 1s var(--ease-expo); }
.js-reveal.visible { opacity: 1; transform: translateY(0); }

/* =========================================
   LIGHTBOX / MODALE (ESTERNO)
========================================= */
.lightbox {
    position: fixed;
    top: 0; left: 0; width: 100vw; height: 100vh;
    z-index: 9999;
    display: none; 
    align-items: center; justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
}
.lightbox.active { display: flex; opacity: 1; }

.lightbox__overlay {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background-color: rgba(5, 5, 5, 0.95);
    backdrop-filter: blur(12px);
    z-index: 1;
}

.lightbox__close {
    position: absolute; top: 30px; right: 30px;
    background: transparent; color: var(--gold-lt); border: none; font-size: 2rem;
    cursor: pointer; z-index: 10; transition: transform 0.2s ease, text-shadow 0.2s;
}
.lightbox__close:hover { transform: scale(1.1); text-shadow: 0 0 20px var(--gold-glow); }

/* =========================================
   LAYOUT LIGHTBOX 2 COLONNE (INTERNO)
========================================= */
.lightbox__layout {
    position: relative; z-index: 2; width: 90vw; height: 85vh;
    display: flex; flex-direction: row; gap: 2rem; align-items: stretch;
}

.lightbox__col { display: flex; flex-direction: column; justify-content: center; }

.lightbox__col--img { flex: 2; align-items: center; height: 100%; }
.lightbox__col--img .lightbox__img { max-width: 100%; max-height: calc(85vh - 80px); object-fit: contain; filter: drop-shadow(0 0 20px rgba(255,255,255,0.1)); }

.lightbox__col--img .lightbox__nav { display: flex; align-items: center; gap: 1rem; margin-top: 1.5rem; color: #fff; }

.lightbox__btn {
    background: transparent; border: 1px solid var(--gold); color: var(--gold-lt);
    padding: 0.5rem 1rem; cursor: pointer; transition: all 0.3s ease;
}
.lightbox__btn:hover { background: var(--white); color: var(--black); box-shadow: 0 0 15px var(--white); border-color: var(--white); }

/* =========================================
   ISPETTORE 3D (COLONNA DESTRA)
========================================= */
.lightbox__col--3d {
    flex: 1;
    background: var(--surface2);
    border: 1px solid var(--border-lg);
    padding: 3rem 2rem; align-items: center;
    box-shadow: 0 20px 60px rgba(0,0,0,0.9) inset;
    border-radius: 4px; max-width: 450px;
}

.lightbox__3d-title {
    color: var(--white); font-family: var(--ff-display); font-size: 1.4rem;
    margin-bottom: 3rem; text-transform: uppercase; letter-spacing: 0.15em; text-shadow: 0 0 15px rgba(255,255,255,0.3);
}

.door-3d-scene { width: 100%; max-width: 200px; aspect-ratio: 1 / 2.1; perspective: 1500px; margin-bottom: 3rem; }
.door-3d-hinge { width: 100%; height: 100%; transform-origin: left center; transform-style: preserve-3d; filter: drop-shadow(20px 20px 30px rgba(0,0,0,0.9)); }
.door-3d-mesh { width: 100%; height: 100%; position: relative; transform-style: preserve-3d; }
.door-3d-face { position: absolute; backface-visibility: hidden; }

.door-3d-front {
    inset: 0; background-size: cover; background-position: center; background-repeat: no-repeat;
    border: 2px solid var(--gold); transform: translateZ(8px); overflow: hidden;
    box-shadow: inset 0 0 30px rgba(0,0,0,0.5);
}

.door-3d-back {
    inset: 0; background: linear-gradient(135deg, #1f1f24, #050505);
    border: 2px solid var(--gold-dk); transform: rotateY(180deg) translateZ(8px);
}

.door-3d-edge {
    top: 0; right: 0; width: 16px; height: 100%;
    background: linear-gradient(to bottom, var(--gold-dk), var(--gold), var(--gold-dk));
    transform-origin: right center; transform: rotateY(90deg);
}

.lightbox__3d-controls { width: 100%; text-align: center; display: flex; flex-direction: column; gap: 0.8rem; }
.door-slider { width: 100%; accent-color: var(--gold-lt); cursor: ew-resize; }
.lightbox__3d-controls label { font-size: 0.75rem; font-weight: 600; color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.2em; }

/* ── RESPONSIVE ───────────────────────────────────────────── */
@media (max-width: 1024px) {
  .about__grid { grid-template-columns: 1fr; gap: 4rem; }
  .about__visual { max-width: 550px; margin: 0 auto; }
  .craft__content { grid-template-columns: 1fr; gap: 4rem; }
  .footer__top { grid-template-columns: 1fr 1fr; gap: 3rem; }
}
@media (max-width: 768px) {
  .nav__links { display: none; }
  .nav__menu-btn { display: flex; }
  .nav { padding: 1.5rem 5vw; }
  .nav.scrolled { padding: 1.2rem 5vw; }
  .collections__grid { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
  .collection-card { min-height: 400px; }
  .form-row { grid-template-columns: 1fr; }
  .footer__top { grid-template-columns: 1fr; gap: 3rem; text-align: center; }
  .footer__bottom { flex-direction: column; gap: 1rem; text-align: center; }
  .about, .collections, .craft, .contact { padding: 6rem 5vw; }
  #cursorDot, #cursorRing { display: none; pointer-events: none; z-index: 9999; }
  body { cursor: auto; }
}
@media (max-width: 480px) {
  .hero__title { font-size: clamp(3rem, 15vw, 4.5rem); }
  .about__stat-grid { grid-template-columns: 1fr; }
  .lightbox__img { max-height: 70vh; }
}

.slide-img {
  position: absolute; top: 1rem; left: 1rem; width: calc(100% - 2rem); height: calc(100% - 2rem);
  object-fit: contain; object-position: center; display: block; opacity: 0; transform: scale(0.95);
  transition: opacity 1.2s ease-in-out, transform 0.8s var(--ease-expo);
}
.slide-img.active { opacity: 1; z-index: 2; }
.collection-card:hover .slide-img.active { transform: scale(1.08); }

/* ── I NOSTRI LAVORI (TEMPLE ARCHIVES) ────────────────────── */
.our-works {
  padding: 10rem 6vw; position: relative;
  background-image: url('sfondo.png'); 
  background-size: cover; background-position: center; background-repeat: no-repeat; background-attachment: fixed;
  padding: 100px 0; border-bottom: 2px solid var(--border); box-shadow: 0 10px 50px rgba(0,0,0,0.8) inset;
}

.our-works::before { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%; background-color: rgba(5, 5, 5, 0.6); z-index: 1; }
.our-works__header, #works-container { position: relative; z-index: 2; }
.our-works__header { max-width: 1200px; margin: 0 auto 5rem; text-align: center; }
.our-works__title { font-size: clamp(2.8rem, 5.5vw, 4.5rem); color: var(--white); text-shadow: 0 0 30px rgba(255,255,255,0.2); }

.our-works__gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(350px, 1fr)); gap: 2.5rem; max-width: 1500px; margin: 0 auto; }

.work-item {
  position: relative; overflow: hidden; aspect-ratio: 4 / 5; cursor: none;
  border: 2px solid var(--border); transition: all 0.5s var(--ease-smooth); box-shadow: 0 15px 35px rgba(0,0,0,0.7);
}
.work-item:hover {
  border-color: var(--gold-lt); box-shadow: 0 20px 50px rgba(0,0,0,0.9), 0 0 30px rgba(212,175,55,0.3) inset; transform: translateY(-8px);
}
.work-item img {
  width: 100%; height: 100%; object-fit: cover; transition: transform 1s var(--ease-smooth), filter 0.6s;
  filter: brightness(0.7) contrast(1.3) grayscale(0.4);
}
.work-item:hover img { transform: scale(1.1); filter: brightness(1.1) contrast(1.2) grayscale(0) drop-shadow(0 0 10px rgba(212,175,55,0.3)); }

.work-item__overlay {
  position: absolute; inset: 0; background: linear-gradient(0deg, rgba(5,5,5,0.95) 0%, transparent 50%);
  opacity: 0; transition: opacity 0.5s ease; display: flex; align-items: flex-end; justify-content: center; padding: 2.5rem;
}
.work-item:hover .work-item__overlay { opacity: 1; }

.work-cta {
  font-size: 0.8rem; font-weight: 600; letter-spacing: 0.25em; text-transform: uppercase;
  color: var(--white); transform: translateY(20px); transition: transform 0.5s var(--ease-expo); text-shadow: 0 0 15px var(--gold-lt);
}
.work-item:hover .work-cta { transform: translateY(0); }

/* =========================================
   SOTTOCARTELLE LIGHTBOX
========================================= */
.lightbox__subgrid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 1.5rem; width: 100%;
    max-height: calc(85vh - 40px); overflow-y: auto; padding: 1rem; scrollbar-width: thin; scrollbar-color: var(--gold) transparent;
}
.lightbox__subgrid::-webkit-scrollbar { width: 6px; }
.lightbox__subgrid::-webkit-scrollbar-thumb { background: linear-gradient(to bottom, var(--gold-lt), var(--gold)); border-radius: 4px; }

.lightbox__subcard {
    position: relative; height: 280px; border: 1px solid var(--border-lg); border-radius: 2px; overflow: hidden;
    cursor: pointer; transition: all 0.4s var(--ease-smooth); background: var(--surface);
}
.lightbox__subcard:hover { border-color: var(--white); transform: translateY(-5px); box-shadow: 0 15px 40px rgba(0,0,0,0.9), 0 0 20px rgba(212, 175, 55, 0.3) inset; }

.subcard-bg { position: absolute; inset: 0; background-size: cover; background-position: center; transition: transform 0.6s var(--ease-expo); filter: grayscale(0.3); }
.lightbox__subcard:hover .subcard-bg { transform: scale(1.08); filter: grayscale(0); }

.subcard-overlay { position: absolute; inset: 0; background: linear-gradient(180deg, transparent 30%, rgba(5, 5, 5, 0.95) 100%); opacity: 0.9; transition: opacity 0.3s; }
.lightbox__subcard:hover .subcard-overlay { opacity: 1; }

.subcard-title {
    position: absolute; bottom: 0; left: 0; width: 100%; padding: 1.5rem 1rem; text-align: center;
    color: var(--white); font-family: var(--ff-display); font-size: 1.3rem; z-index: 2; text-shadow: 0 0 15px rgba(0,0,0,0.9); transition: color 0.3s, text-shadow 0.3s;
}
.lightbox__subcard:hover .subcard-title { color: var(--gold-lt); text-shadow: 0 0 20px var(--gold-glow); }

/* =========================================
   UI DINAMICA LIGHTBOX: SIDEBAR & BACK BTN
========================================= */
.lightbox__back-btn {
    position: absolute; top: 30px; left: 30px; background: transparent; border: 1px solid var(--gold);
    color: var(--white); padding: 0.6rem 1.2rem; font-family: var(--ff-body); font-size: 0.8rem; font-weight: 600;
    text-transform: uppercase; letter-spacing: 0.15em; cursor: pointer; z-index: 10; transition: all 0.3s var(--ease-expo); box-shadow: 0 0 15px rgba(0,0,0,0.8);
}
.lightbox__back-btn:hover { background: var(--white); color: var(--black); box-shadow: 0 0 25px var(--white); border-color: var(--white); }

.lightbox__col--sidebar {
    flex: 0 0 240px; background: var(--surface2); border: 1px solid var(--border-lg); padding: 1.5rem 1rem;
    box-shadow: 0 20px 60px rgba(0,0,0,0.9) inset; border-radius: 4px; display: flex; flex-direction: column;
    overflow-y: auto; max-height: calc(85vh - 40px); scrollbar-width: thin; scrollbar-color: var(--gold) transparent;
}
.lightbox__col--sidebar::-webkit-scrollbar { width: 4px; }
.lightbox__col--sidebar::-webkit-scrollbar-thumb { background: var(--gold); border-radius: 2px; }

.lightbox__sidebar-title {
    color: var(--white); font-family: var(--ff-display); font-size: 1.1rem; margin-bottom: 1.5rem;
    text-transform: uppercase; letter-spacing: 0.1em; text-align: center; flex-shrink: 0;
    text-shadow: 0 0 15px rgba(255,255,255,0.3); border-bottom: 1px solid var(--border-lg); padding-bottom: 1rem;
}

.lightbox__sidebar-grid { display: flex; flex-direction: column; gap: 1rem; }

.sidebar-card {
    position: relative; height: 140px; border: 1px solid var(--border-lg); border-radius: 2px; overflow: hidden;
    cursor: pointer; transition: all 0.4s var(--ease-smooth); background: var(--surface); flex-shrink: 0;
}
.sidebar-card:hover { border-color: var(--gold-lt); transform: translateY(-3px) scale(1.02); box-shadow: 0 15px 30px rgba(0,0,0,0.9), 0 0 20px rgba(212, 175, 55, 0.3) inset; }

.sidebar-card__bg { position: absolute; inset: 0; background-size: cover; background-position: center; transition: transform 0.6s var(--ease-expo); filter: grayscale(0.4); }
.sidebar-card:hover .sidebar-card__bg { transform: scale(1.1); filter: grayscale(0); }

.sidebar-card__overlay { position: absolute; inset: 0; background: linear-gradient(180deg, transparent 20%, rgba(5, 5, 5, 0.95) 100%); opacity: 0.9; transition: opacity 0.3s; }
.sidebar-card:hover .sidebar-card__overlay { opacity: 1; }

.sidebar-card__title {
    position: absolute; bottom: 0; left: 0; width: 100%; padding: 1rem 0.5rem; text-align: center;
    color: var(--text-dim); font-family: var(--ff-body); font-size: 0.8rem; font-weight: 600; letter-spacing: 0.05em;
    z-index: 2; text-shadow: 0 0 15px rgba(0,0,0,0.9); transition: color 0.3s, text-shadow 0.3s;
}
.sidebar-card:hover .sidebar-card__title { color: var(--gold-lt); text-shadow: 0 0 20px var(--gold-glow); }

/* Gestione Mobile */
@media (max-width: 900px) {
    .lightbox__layout { flex-direction: column; }
    .lightbox__col--sidebar { flex: none; height: auto; max-height: 250px; }
    .lightbox__sidebar-grid { flex-direction: row; overflow-x: auto; padding-bottom: 10px; }
    .sidebar-card { width: 160px; }
}

/* =========================================
   SISTEMA DI LAYER PBR FAKE (CSS)
========================================= */
.pbr-layer { position: absolute; inset: 0; width: 100%; height: 100%; background-size: cover; background-position: center; pointer-events: none; }
.pbr-ao { mix-blend-mode: multiply; opacity: 0.8; }
.pbr-roughness { mix-blend-mode: screen; opacity: 0.3; filter: contrast(1.5) brightness(0.9); }
.pbr-normal { mix-blend-mode: overlay; opacity: 0.5; filter: grayscale(100%) contrast(2.5); }

.door-3d-front::after {
    content: ''; position: absolute; inset: 0;
    background: linear-gradient(105deg, 
        transparent 20%, 
        rgba(255, 245, 184, 0.25) 45%, /* Riflesso dorato */
        rgba(255, 255, 255, 0.6) 50%, /* Piccolo hot-spot bianco puro */
        rgba(255, 245, 184, 0.25) 55%, 
        transparent 80%);
    background-size: 200% 100%; opacity: 0.7; mix-blend-mode: overlay; pointer-events: none;
}
/* Necessario per posizionare il sottomenu rispetto al link padre */
.nav__item--has-dropdown {
    position: relative;
}

.nav__dropdown {
    position: absolute;
    top: 100%; /* Si posiziona sotto la nav */
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    background: rgba(15, 15, 15, 0.98); /* Sfondo scuro lusso */
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    list-style: none;
    padding: 10px 0;
    margin: 0;
    min-width: 200px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
    box-shadow: 0 15px 35px rgba(0,0,0,0.5);
}

/* Mostra il menu al passaggio del mouse */
.nav__item--has-dropdown:hover .nav__dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.nav__dropdown-link {
    display: block;
    padding: 12px 20px;
    color: #fff;
    text-decoration: none;
    font-family: 'Raleway', sans-serif;
    font-size: 13px;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    text-align: center;
    transition: 0.3s;
}

.nav__dropdown-link:hover {
    background: rgba(255, 255, 255, 0.05);
    color: #d4af37; /* Colore oro */
}

/* Container del Dropdown per Catalogo */
.nav__item--has-dropdown {
    position: relative;
}

/* =========================================
   MEGA MENU SETUP (DEFINITIVO)
========================================= */
.nav__item--has-dropdown {
    position: relative;
}

.nav__dropdown--mega {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    width: 750px; 
    max-width: 95vw; 
    max-height: 80vh; 
    overflow-y: auto; 
    background: #fff;
    border: 1px solid #e0e0e0;
    
    display: flex; 
    flex-direction: row;
    flex-wrap: nowrap;
    
    /* Manteniamo stretch sul padre così il box bianco si allunga sempre fino in fondo */
    align-items: stretch; 
    
    opacity: 0;
    visibility: hidden;
    pointer-events: none; 
    transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease;
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
    z-index: 1000;
    padding: 20px;
}

.nav__item--has-dropdown:hover .nav__dropdown--mega {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateX(-50%) translateY(0);
}

/* Parte Sinistra: Categorie */
.mega-col-left {
    flex: 1 1 auto;
    min-width: 0; 
    padding-right: 20px;
    border-right: 1px solid #eee;
    
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); 
    gap: 10px;
    
    /* LA MAGIA È QUI: Allinea i bottoni in alto e impedisce loro di stirarsi verticalmente */
    align-content: start;
    grid-auto-rows: min-content;
}

/* Pulsanti Categorie */
.nav__dropdown-btn {
    width: 100%;
    background: #f9f9f9;
    border: 1px solid #ddd;
    padding: 10px 15px;
    text-align: left;
    font-family: 'Raleway', sans-serif;
    font-size: 0.75rem;
    letter-spacing: 1px;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.3s ease, color 0.3s ease, border-color 0.3s ease;
    color: #333;
    
    word-wrap: break-word; 
    overflow-wrap: break-word;
    white-space: normal; 
    line-height: 1.4;
}

.nav__dropdown-btn:hover {
    background: #000;
    color: #fff;
    border-color: #000;
}

/* Parte Destra: Gestione Pulsanti Speciali */
.mega-col-right {
    flex: 0 0 220px; 
    min-width: 0;
    padding-left: 20px;
    
    display: flex;
    flex-direction: column;
    justify-content: flex-start; /* Allinea anche questi bottoni in alto */
    gap: 12px;
}

.special-btn {
    width: 100%;
    padding: 12px 15px;
    text-align: center;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 1.5px;
    font-size: 0.75rem;
    text-decoration: none;
    transition: transform 0.3s ease, box-shadow 0.3s, background 0.3s, color 0.3s, border-color 0.3s;
    display: block;
    word-wrap: break-word; 
    white-space: normal;
    line-height: 1.4;
}

.special-btn--dark {
    background: #1a1a1a;
    color: white;
    border: 1px solid #1a1a1a;
}

.special-btn--outline {
    border: 1px solid #1a1a1a;
    color: #1a1a1a;
    background: transparent;
}

.special-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    background: #c5a059;
    color: white;
    border-color: #c5a059;
}

/* ── ADATTAMENTO RESPONSIVE ── */
@media (max-width: 768px) {
    .nav__dropdown--mega {
        flex-direction: column; 
        width: 100%;
        padding: 15px;
    }

    .mega-col-left {
        padding-right: 0;
        border-right: none;
        border-bottom: 1px solid #eee;
        padding-bottom: 15px;
        margin-bottom: 15px;
        grid-template-columns: 1fr; 
    }

    .mega-col-right {
        padding-left: 0;
        flex: 1 1 auto;
        width: 100%;
    }
}

.special-btn {
    width: 100%;
    padding: 12px 15px;
    text-align: center;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 1.5px;
    font-size: 0.75rem;
    text-decoration: none;
    
    /* Transizioni specifiche senza usare "all" */
    transition: transform 0.3s cubic-bezier(0.23, 1, 0.32, 1), box-shadow 0.3s, background 0.3s, color 0.3s, border-color 0.3s;
    display: block;
    
    word-wrap: break-word; 
    white-space: normal;
    line-height: 1.4;
}

.special-btn--dark {
    background: #1a1a1a;
    color: white;
    border: 1px solid #1a1a1a;
}

.special-btn--outline {
    border: 1px solid #1a1a1a;
    color: #1a1a1a;
    background: transparent;
}

.special-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    background: #c5a059;
    color: white;
    border-color: #c5a059;
}

/* ── ADATTAMENTO RESPONSIVE PER IL MEGA MENU ── */
/* Allineato al breakpoint della navbar originale (768px) per evitare conflitti */
@media (max-width: 768px) {
    .nav__dropdown--mega {
        flex-direction: column; 
        width: 100%;
        padding: 15px;
    }

    .mega-col-left {
        padding-right: 0;
        border-right: none;
        border-bottom: 1px solid #eee;
        padding-bottom: 15px;
        margin-bottom: 15px;
        grid-template-columns: 1fr; 
    }

    .mega-col-right {
        padding-left: 0;
        flex: 1 1 auto;
        width: 100%;
    }
}

.special-btn {
    width: 100%;
    padding: 12px 15px;
    text-align: center;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 1.5px;
    font-size: 0.75rem;
    text-decoration: none;
    transition: transform 0.3s cubic-bezier(0.23, 1, 0.32, 1), box-shadow 0.3s, background 0.3s, color 0.3s, border-color 0.3s;
    display: block;
    word-wrap: break-word; 
    white-space: normal;
    line-height: 1.4;
}

.special-btn--dark {
    background: #1a1a1a;
    color: white;
    border: 1px solid #1a1a1a;
}

.special-btn--outline {
    border: 1px solid #1a1a1a;
    color: #1a1a1a;
    background: transparent;
}

.special-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    background: #c5a059;
    color: white;
    border-color: #c5a059;
}

/* ── ADATTAMENTO RESPONSIVE ── */
@media (max-width: 768px) {
    .nav__dropdown--mega {
        flex-direction: column; 
        width: 100%;
        padding: 15px;
    }

    .mega-col-left {
        padding-right: 0;
        border-right: none;
        border-bottom: 1px solid #eee;
        padding-bottom: 15px;
        margin-bottom: 15px;
        grid-template-columns: 1fr; 
    }

    .mega-col-right {
        padding-left: 0;
        flex: 1 1 auto;
        width: 100%;
    }
}

.special-btn {
    width: 100%;
    padding: 12px 15px;
    text-align: center;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 1.5px;
    font-size: 0.75rem;
    text-decoration: none;
    
    /* Transizioni specifiche senza usare "all" */
    transition: transform 0.3s cubic-bezier(0.23, 1, 0.32, 1), box-shadow 0.3s, background 0.3s, color 0.3s, border-color 0.3s;
    display: block;
    
    word-wrap: break-word; 
    white-space: normal;
    line-height: 1.4;
}

.special-btn--dark {
    background: #1a1a1a;
    color: white;
    border: 1px solid #1a1a1a;
}

.special-btn--outline {
    border: 1px solid #1a1a1a;
    color: #1a1a1a;
    background: transparent;
}

.special-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    background: #c5a059;
    color: white;
    border-color: #c5a059;
}

/* ── ADATTAMENTO RESPONSIVE PER IL MEGA MENU ── */
/* Allineato al breakpoint della navbar originale (768px) per evitare conflitti */
@media (max-width: 768px) {
    .nav__dropdown--mega {
        flex-direction: column; 
        width: 100%;
        padding: 15px;
    }

    .mega-col-left {
        padding-right: 0;
        border-right: none;
        border-bottom: 1px solid #eee;
        padding-bottom: 15px;
        margin-bottom: 15px;
        grid-template-columns: 1fr; 
    }

    .mega-col-right {
        padding-left: 0;
        flex: 1 1 auto;
        width: 100%;
    }
}

.special-btn {
    width: 100%;
    padding: 12px 15px;
    text-align: center;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 1.5px;
    font-size: 0.75rem;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.23, 1, 0.32, 1);
    display: block;
    
    /* FIX TESTI LUNGHI */
    word-wrap: break-word; 
    white-space: normal;
    line-height: 1.4;
}

.special-btn--dark {
    background: #1a1a1a;
    color: white;
    border: 1px solid #1a1a1a;
}

.special-btn--outline {
    border: 1px solid #1a1a1a;
    color: #1a1a1a;
    background: transparent;
}

.special-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    background: #c5a059;
    color: white;
    border-color: #c5a059;
}

/* ── ADATTAMENTO RESPONSIVE PER IL MEGA MENU ── */
@media (max-width: 900px) {
    .nav__dropdown--mega {
        flex-direction: column; /* Impila verticalmente la parte sinistra e destra */
        width: 90vw;
        padding: 15px;
    }

    .mega-col-left {
        padding-right: 0;
        border-right: none;
        border-bottom: 1px solid #eee;
        padding-bottom: 15px;
        margin-bottom: 15px;
        grid-template-columns: 1fr; /* Singola colonna su mobile e tablet */
    }

    .mega-col-right {
        padding-left: 0;
        flex: 1 1 auto;
        width: 100%;
    }
}

.special-btn {
    width: 100%;
    padding: 12px 15px;
    text-align: center;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 1.5px;
    font-size: 0.75rem;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.23, 1, 0.32, 1);
    display: block;
    /* Gestione testi lunghi */
    word-wrap: break-word; 
    white-space: normal;
    line-height: 1.4;
}

.special-btn--dark {
    background: #1a1a1a;
    color: white;
    border: 1px solid #1a1a1a;
}

.special-btn--outline {
    border: 1px solid #1a1a1a;
    color: #1a1a1a;
    background: transparent;
}

.special-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    background: #c5a059;
    color: white;
    border-color: #c5a059;
}

/* ── ADATTAMENTO RESPONSIVE PER IL MEGA MENU ── */
@media (max-width: 900px) {
    .nav__dropdown--mega {
        flex-direction: column; /* Impila verticalmente la parte sinistra e destra */
        width: 90vw;
        padding: 15px;
    }

    .mega-col-left {
        padding-right: 0;
        border-right: none;
        border-bottom: 1px solid #eee;
        padding-bottom: 15px;
        margin-bottom: 15px;
        grid-template-columns: 1fr; /* Passa a una singola colonna per i bottoni interni */
    }

    .mega-col-right {
        padding-left: 0;
        flex-direction: column;
        width: 100%;
    }
}

.special-btn {
    width: 100%;
    padding: 12px 15px; /* Padding leggermente ridotto */
    text-align: center;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 1.5px;
    font-size: 0.75rem;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.23, 1, 0.32, 1);
    display: block;
}

.special-btn--dark {
    background: #1a1a1a;
    color: white;
    border: 1px solid #1a1a1a;
}

.special-btn--outline {
    border: 1px solid #1a1a1a;
    color: #1a1a1a;
    background: transparent;
}

.special-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    background: #c5a059; /* Colore oro/luxury al passaggio */
    color: white;
    border-color: #c5a059;
}

/* Catalog Modal Styles */
.catalog-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2000;
    display: none; /* Nascosto di default */
    align-items: center;
    justify-content: center;
}

.catalog-modal.active {
    display: flex;
}

.catalog-modal__overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(10px);
}

.catalog-modal__content {
    position: relative;
    width: 95%;
    height: 90%;
    background: #000;
    border: 1px solid #c5a059; /* Bordo oro Luxury */
    z-index: 2;
    overflow: hidden;
}

.catalog-modal__close {
    position: absolute;
    top: -40px;
    right: 0;
    background: transparent;
    border: none;
    color: #fff;
    font-family: 'Raleway', sans-serif;
    font-size: 1rem;
    cursor: pointer;
    letter-spacing: 2px;
    text-transform: uppercase;
}

#catalogIframe {
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease;
}

#catalogIframe.loaded {
    opacity: 1;
}

/* Loader */
.catalog-modal__loader {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: #c5a059;
}

.loader-spinner {
    width: 40px;
    height: 40px;
    border: 2px solid #333;
    border-top: 2px solid #c5a059;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 10px;
}

@keyframes spin { 100% { transform: rotate(360deg); } }

/* ── DAY THEME: APPOLO'S LIGHT ────────────────────────────── */
body.day-theme {
  --black:      #ffffff; /* Bianco puro */
  --deep:       #f2f2f7; /* Marmo bianco venato */
  --surface:    #ffffff;
  --surface2:   #e5e5ea; /* Grigio chiarissimo */
  --border:     #d1d1d6; /* Venatura grigio chiaro */
  --border-lg:  #c7c7cc;
  
  --text:       #1a1a1d; /* Testo scuro per leggibilità */
  --text-dim:   #636366; /* Grigio medio */
  
  /* L'oro diventa più vibrante e caldo */
  --gold:       #b8860b; 
  --gold-lt:    #ffd700; 
  --gold-dk:    #8b7500;
  --gold-glow:  rgba(184, 134, 11, 0.3);
  
  --lightning:  rgba(212, 175, 55, 0.4); /* Fulmini dorati su sfondo chiaro */
}

/* Correzioni specifiche per il tema giorno */
body.day-theme .nav.scrolled {
  background: rgba(255, 255, 255, 0.9);
  border-bottom: 1px solid var(--gold);
}

body.day-theme .hero__cta {
  background: white;
  color: var(--gold-dk);
  border-color: var(--gold);
}

body.day-theme .hero__cta:hover {
  color: white;
}

body.day-theme .hero__title em {
  text-shadow: 0 0 20px rgba(184, 134, 11, 0.2);
}

/* Invertiamo il cursore per visibilità */
body.day-theme #cursorDot {
  background: var(--gold);
}

/* Assicuriamoci che la colonna immagine sia il riferimento per il posizionamento */
.lightbox__col--img {
    position: relative; 
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

/* ============================================================
   DIVINE LOADER SYSTEM — Luxury Doors Engine
   ============================================================ */

/* 1. Base Comune per tutti i Loader */
.divine-loader {
    display: none; /* Attivato via JS (flex) */
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    pointer-events: none;
    text-align: center;
    transition: opacity 0.5s ease;
}

/* 2. Caso A: Loader nel Lightbox (Assoluto sopra l'immagine) */
.lightbox__col--img .divine-loader {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 150;
}

/* 3. Caso B: Loader nelle Sezioni (Relativo sotto i titoli) */
.section-loader {
    position: relative;
    margin: 60px auto;
    min-height: 250px; /* Evita il salto di layout quando scompare */
}

/* 4. L'Icona del Fulmine (SVG) */
.divine-loader__icon svg {
    width: 100px;
    height: 100px;
    /* Applichiamo l'animazione a colore, riempimento e contorno */
    filter: drop-shadow(0 0 15px var(--gold-glow));
    animation: divineCycle 3s infinite ease-in-out, lightningPulse 1.2s infinite alternate;
}

/* 5. Il Testo "Caricamento" */
.divine-loader__text {
    margin-top: 25px;
    font-family: var(--ff-display);
    font-size: 1.1rem;
    letter-spacing: 0.5rem;
    text-transform: uppercase;
    font-weight: 300;
    animation: divineCycle 3s infinite ease-in-out;
}

/* 6. Animazione Cromatica Divina: Oro -> Grigio -> Nero -> Bianco */
@keyframes divineCycle {
    0%, 100% { 
        color: #D4AF37;   /* Oro */
        fill: #D4AF37; 
        stroke: #D4AF37; 
        opacity: 1; 
    }
    25% { 
        color: #808080;   /* Grigio Pietra */
        fill: #808080; 
        stroke: #808080; 
    }
    50% { 
        color: #050505;   /* Nero Ossidiana */
        fill: #050505; 
        stroke: #050505; 
    }
    75% { 
        color: #FFFFFF;   /* Bianco Marmo */
        fill: #FFFFFF; 
        stroke: #FFFFFF; 
    }
}

/* 7. Pulsazione del Fulmine */
@keyframes lightningPulse {
    from { 
        transform: scale(0.85) rotate(-5deg); 
        filter: brightness(1) drop-shadow(0 0 10px var(--gold-glow)); 
    }
    to { 
        transform: scale(1.1) rotate(5deg); 
        filter: brightness(1.8) drop-shadow(0 0 30px var(--gold-lt)); 
    }
}

/* 8. Container delle Gallerie (Stato iniziale invisibile) */
#works-container, #grid-container {
    opacity: 0;
    transition: opacity 1s var(--ease-smooth);
}


/* Loader specifico per le singole Card */
.collection-card .divine-loader {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex; /* Visibile di default all'inserimento nel DOM */
    z-index: 5;
    background: var(--black); /* Copre il fondo nero finché non c'è l'immagine */
    width: 100%;
    height: 100%;
}

/* Riduciamo il fulmine per le card */
.collection-card .divine-loader__icon svg {
    width: 50px;
    height: 50px;
}

.collection-card .divine-loader__text {
    font-size: 0.7rem; /* Testo più discreto */
    letter-spacing: 0.2rem;
}

/* Assicuriamoci che le immagini della card siano invisibili finché caricate */
.collection-card .slide-img {
    opacity: 0;
    transition: opacity 0.8s ease;
}

.collection-card .slide-img.loaded {
    opacity: 1;
}

/* =========================================
   PULSANTI ORO ANIMATI - SEZIONE CATALOGHI
   ========================================= */
.collections__header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    flex-wrap: wrap;
    gap: 2rem;
    margin-bottom: 3rem; /* Spazio prima della griglia */
}

.collections__super-actions {
    display: flex;
    gap: 1.5rem;
}

/* Stile Base Bottone Oro */
.gold-btn {
    position: relative;
    padding: 14px 32px;
    background: transparent;
    border: 1px solid #d4af37; /* Bordo oro scuro */
    color: #d4af37; /* Testo oro */
    font-family: 'Raleway', sans-serif;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    cursor: pointer;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    outline: none;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Isoliamo i click interni per far scattare sempre il bottone padre nel JS */
.gold-btn__text {
    position: relative;
    z-index: 2;
    pointer-events: none; 
}

/* Effetto di riempimento Hover (Sfumatura Oro) */
.gold-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #d4af37, #aa771c, #f3e5ab, #d4af37);
    background-size: 300% 300%;
    z-index: 1;
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.5s cubic-bezier(0.86, 0, 0.07, 1);
}

.gold-btn:hover::before {
    transform: scaleX(1);
    transform-origin: left;
    animation: goldShimmer 3s ease infinite;
}

.gold-btn:hover {
    color: #111; /* Il testo diventa scuro per contrastare l'oro */
    border-color: transparent;
    box-shadow: 0 10px 25px rgba(212, 175, 55, 0.25);
    transform: translateY(-2px);
}

/* Riflesso di luce in movimento continuo */
.gold-btn__shine {
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.4) 50%, rgba(255,255,255,0) 100%);
    transform: skewX(-25deg);
    z-index: 3;
    animation: shineLight 5s infinite;
    pointer-events: none;
}

/* Keyframes Animazioni */
@keyframes goldShimmer {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes shineLight {
    0% { left: -100%; }
    20% { left: 200%; }
    100% { left: 200%; }
}

/* Adattamento Mobile */
@media (max-width: 768px) {
    .collections__header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1.5rem;
    }
    .collections__super-actions {
        flex-direction: column;
        width: 100%;
    }
    .gold-btn {
        width: 100%;
    }
}
/* =========================================
   TESTO DIVINO AEGIS (Al posto delle immagini)
========================================= */
.god-text-container {
  position: relative;
  max-width: 900px;
  margin: 0 auto;
  text-align: center;
  padding: 2rem;
  z-index: 2;
  /* Sfondo trasparente per far vedere la porta dietro */
  background: transparent;
  border: none;
  box-shadow: none;
}

.god-text {
  font-family: var(--ff-display);
  font-size: clamp(1.4rem, 2.5vw, 2.2rem);
  font-weight: 300;
  line-height: 1.6;
  text-transform: none; /* Disattiva il tutto maiuscolo */
  
  /* Gradiente animato: Oro scuro -> Bianco puro -> Oro scuro */
  background: linear-gradient(90deg, var(--gold-dk) 0%, var(--white) 50%, var(--gold-dk) 100%);
  background-size: 200% auto;
  color: transparent;
  -webkit-background-clip: text;
  background-clip: text;
  animation: divineTextShimmer 5s linear infinite;
  
  /* Luce divina sullo sfondo (funziona anche con il background-clip attivo) */
  filter: drop-shadow(0 0 15px rgba(255, 245, 184, 0.4)) drop-shadow(0 0 40px rgba(212, 175, 55, 0.6));
}

.god-cite {
  display: block;
  margin-top: 3rem;
  font-family: var(--ff-body);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--gold-lt);
  text-shadow: 0 0 15px var(--gold-glow);
  font-style: normal;
}

@keyframes divineTextShimmer {
  to {
    background-position: 200% center;
  }
}

/* ================================================
   WHATSAPP FLOATING WIDGET — Luxury Doors Theme
   Appendi questo blocco in fondo a style.css
   ================================================ */

/* ── FAB ── */
#wa-fab {
  position: fixed;
  bottom: 32px;
  right: 32px;
  z-index: 900;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 20px 0 14px;
  height: 52px;
  background: var(--color-dark, #0d0d0d);
  border: 1px solid var(--color-gold, #c9a84c);
  border-radius: 0;                     /* segue il design sharp del sito */
  color: var(--color-gold, #c9a84c);
  font-family: 'Raleway', sans-serif;
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  cursor: pointer;
  overflow: hidden;
  transition: background 0.3s ease, color 0.3s ease, box-shadow 0.3s ease;
  /* variabile interna usata dall'SVG per il fill del logo WA */
  --wa-bg: #0d0d0d;
}

#wa-fab::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--color-gold, #c9a84c);
  transform: translateX(-101%);
  transition: transform 0.35s cubic-bezier(0.76, 0, 0.24, 1);
  z-index: 0;
}
#wa-fab:hover::before { transform: translateX(0); }
#wa-fab:hover { color: #0d0d0d; --wa-bg: #0d0d0d; }
#wa-fab:hover svg path:first-child { fill: #0d0d0d; }

#wa-fab svg,
#wa-fab .wa-fab__label { position: relative; z-index: 1; }

/* pulse dorato (attivo solo quando il modale è chiuso) */
#wa-fab.pulse {
  animation: wa-gold-pulse 3s ease-in-out infinite;
}
@keyframes wa-gold-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(201,168,76,0); }
  50%       { box-shadow: 0 0 0 8px rgba(201,168,76,0.18); }
}

/* ── OVERLAY ── */
#wa-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(5, 4, 3, 0.72);
  backdrop-filter: blur(3px);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
#wa-overlay.open {
  opacity: 1;
  pointer-events: all;
}

/* ── MODALE ── */
#wa-modal {
  background: var(--color-dark, #0d0d0d);
  border: 1px solid var(--color-gold, #c9a84c);
  border-bottom: none;
  width: 100%;
  max-width: 520px;
  transform: translateY(32px);
  transition: transform 0.4s cubic-bezier(0.34, 1.2, 0.64, 1);
  position: relative;
  overflow: hidden;
}
/* cornice interna dorata sottilissima */
#wa-modal::before {
  content: '';
  position: absolute;
  inset: 8px;
  border: 1px solid rgba(201,168,76,0.15);
  pointer-events: none;
  z-index: 0;
}
#wa-overlay.open #wa-modal { transform: translateY(0); }

/* Header */
.wa-modal__header {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 22px 24px 18px;
  border-bottom: 1px solid rgba(201,168,76,0.2);
  position: relative;
  z-index: 1;
}
.wa-modal__header-deco {
  font-size: 22px;
  color: var(--color-gold, #c9a84c);
  line-height: 1;
  flex-shrink: 0;
}
.wa-modal__header-text h3 {
  margin: 0 0 3px;
  font-family: 'Cormorant Garamond', serif;
  font-size: 20px;
  font-weight: 400;
  font-style: italic;
  color: var(--color-gold, #c9a84c);
  letter-spacing: 0.04em;
}
.wa-modal__header-text p {
  margin: 0;
  font-family: 'Raleway', sans-serif;
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(201,168,76,0.5);
}
.wa-modal__close {
  margin-left: auto;
  background: none;
  border: none;
  color: rgba(201,168,76,0.5);
  font-size: 14px;
  cursor: pointer;
  padding: 4px 8px;
  font-family: 'Raleway', sans-serif;
  letter-spacing: 0.1em;
  transition: color 0.2s;
  flex-shrink: 0;
}
.wa-modal__close:hover { color: var(--color-gold, #c9a84c); }

/* Body */
.wa-modal__body {
  padding: 24px 24px 16px;
  position: relative;
  z-index: 1;
}
.wa-modal__intro {
  font-family: 'Cormorant Garamond', serif;
  font-size: 15px;
  font-weight: 300;
  color: rgba(201,168,76,0.65);
  margin: 0 0 22px;
  line-height: 1.6;
}

/* Campi form — stile identico al contactForm del sito */
#wa-form { display: flex; flex-direction: column; gap: 16px; }

.wa-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.wa-field {
  position: relative;
}
.wa-field input,
.wa-field textarea {
  width: 100%;
  box-sizing: border-box;
  background: transparent;
  border: none;
  border-bottom: 1px solid rgba(201,168,76,0.25);
  padding: 14px 0 8px;
  font-family: 'Raleway', sans-serif;
  font-size: 13px;
  font-weight: 300;
  letter-spacing: 0.08em;
  color: #e8dcc8;
  outline: none;
  resize: none;
  transition: border-color 0.3s;
}
.wa-field input:focus,
.wa-field textarea:focus { border-bottom-color: var(--color-gold, #c9a84c); }

.wa-field label {
  position: absolute;
  top: 14px;
  left: 0;
  font-family: 'Raleway', sans-serif;
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(201,168,76,0.4);
  pointer-events: none;
  transition: transform 0.25s ease, font-size 0.25s ease, color 0.25s ease;
}
.wa-field input:focus ~ label,
.wa-field input:not(:placeholder-shown) ~ label,
.wa-field textarea:focus ~ label,
.wa-field textarea:not(:placeholder-shown) ~ label {
  transform: translateY(-18px);
  font-size: 10px;
  color: var(--color-gold, #c9a84c);
}

.wa-field__line {
  position: absolute;
  bottom: 0; left: 0;
  height: 1px;
  width: 0;
  background: var(--color-gold, #c9a84c);
  transition: width 0.35s ease;
}
.wa-field input:focus ~ .wa-field__line,
.wa-field textarea:focus ~ .wa-field__line { width: 100%; }

/* Status */
#wa-status {
  font-family: 'Raleway', sans-serif;
  font-size: 12px;
  letter-spacing: 0.1em;
  min-height: 16px;
  padding: 0 2px;
}
.wa-status--success { color: var(--color-gold, #c9a84c); }
.wa-status--error   { color: #c0614a; }

/* Submit — clone del .form-submit del sito */
#wa-submit {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 16px 20px;
  background: transparent;
  border: 1px solid var(--color-gold, #c9a84c);
  color: var(--color-gold, #c9a84c);
  font-family: 'Raleway', sans-serif;
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: color 0.35s;
  margin-top: 4px;
}
#wa-submit::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--color-gold, #c9a84c);
  transform: translateX(-101%);
  transition: transform 0.4s cubic-bezier(0.76, 0, 0.24, 1);
}
#wa-submit:hover::before  { transform: translateX(0); }
#wa-submit:hover          { color: #0d0d0d; }
#wa-submit:disabled       { opacity: 0.5; cursor: not-allowed; }
#wa-submit:disabled::before { transform: translateX(-101%); }

#wa-submit-text,
.wa-submit__icon { position: relative; z-index: 1; }

/* Footer modale */
.wa-modal__footer {
  padding: 10px 24px 18px;
  text-align: center;
  font-family: 'Raleway', sans-serif;
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(201,168,76,0.2);
  position: relative;
  z-index: 1;
}

/* ── RESPONSIVE ── */
@media (min-width: 540px) {
  #wa-modal { border-bottom: 1px solid var(--color-gold, #c9a84c); margin-bottom: 32px; }
  #wa-overlay { align-items: center; }
}
@media (max-width: 480px) {
  .wa-form-row { grid-template-columns: 1fr; }
  #wa-fab .wa-fab__label { display: none; }
  #wa-fab { padding: 0; width: 52px; justify-content: center; border-radius: 50%; }
}

/* ── LIGHT MODE (se il sito supporta tema chiaro) ── */
[data-theme="light"] #wa-fab,
body.light #wa-fab {
  background: #faf7f0;
  --wa-bg: #faf7f0;
}
[data-theme="light"] #wa-modal,
body.light #wa-modal {
  background: #faf7f0;
  color: #1a1207;
}
[data-theme="light"] .wa-field input,
[data-theme="light"] .wa-field textarea,
body.light .wa-field input,
body.light .wa-field textarea {
  color: #1a1207;
}

/* ============================================================
   MENU A CASCATA (Cascading Dropdown) - OLYMPUS THEME
   ============================================================ */

/* Livello 1: Il menu a discesa principale sotto "Catalogo" */
.nav__dropdown--cascading {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(10px); /* Allineato all'animazione del tuo tema */
    background: rgba(15, 15, 15, 0.98); /* Stesso sfondo lusso del tuo menu I Lavori */
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    min-width: 260px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.5);
    display: none;
    flex-direction: column;
    padding: 10px 0;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

/* Attivazione Livello 1 */
.nav__item--has-dropdown:hover > .nav__dropdown--cascading {
    display: flex;
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

/* Livelli 2+: I sottomenu che escono lateralmente */
.nav__dropdown--cascading .dropdown-menu {
    position: absolute;
    top: -10px;
    left: 100%;
    background: rgba(20, 20, 22, 0.98); /* Leggermente diverso per dare profondità 3D */
    border: 1px solid var(--border);
    min-width: 250px;
    box-shadow: 0 15px 40px rgba(0,0,0,0.8);
    display: none;
    flex-direction: column;
    padding: 10px 0;
    backdrop-filter: blur(10px);
}

.dropdown-item {
    position: relative;
    list-style: none;
}

/* Voci del menu */
.dropdown-link {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 20px;
    color: var(--white);
    text-decoration: none;
    font-family: var(--ff-body);
    font-size: 13px;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    transition: 0.3s ease;
}

/* Effetto Hover (Usa il tuo Oro) */
.dropdown-link:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--gold);
}

/* Attivazione Sottomenu Laterali */
.dropdown-item.has-submenu:hover > .dropdown-menu {
    display: flex;
}

/* Freccia indicatrice per i sottomenu */
.submenu-indicator {
    font-size: 1.2rem;
    color: var(--gold-dk);
    line-height: 1;
}

/* Separatore prima dei PDF */
.dropdown-separator {
    border: none;
    border-top: 1px solid var(--border);
    margin: 10px 0;
}

/* Bottoni PDF Statici */
.static-pdf-item .dropdown-link {
    color: var(--gold-lt);
    font-weight: 600;
}

.static-pdf-item .dropdown-link:hover {
    color: var(--black);
    background: var(--gold);
}


/* ── CURSOR (SCINTILLA DIVINA V3 - ZERO LAG) ─────────────────────────── */
* { cursor: none !important; }

#custom-cursor {
    position: fixed;
    top: 0;
    left: 0;
    pointer-events: none;
    z-index: 999999;
    will-change: transform;   /* GPU compositing, nessun layout */
    /* NESSUNA transition qui: il movimento è 1:1 con il mouse */
}

.cursor-wrapper {
    position: relative;
    transition: transform 0.18s cubic-bezier(0.25, 1, 0.5, 1);
}

.cursor-icon {
    position: absolute;
    transition: opacity 0.22s ease, transform 0.22s cubic-bezier(0.25, 1, 0.5, 1);
}

/* ── STATO DEFAULT: + dorato ── */
.icon-plus {
    filter: drop-shadow(0 0 10px var(--gold-glow));
    transform: translate(-50%, -50%) scale(1) rotate(0deg);
    opacity: 1;
}

/* ── STATO DEFAULT: mano nascosta ── */
.icon-hand {
    /* offset: punta del dito (7*1.58≈11px, 2*1.58≈3px) allineata al cursore */
    transform: translate(-11px, -3px) scale(0.25) translateY(20px);
    opacity: 0;
}

/* ── HOVER: mano visibile ── */
#custom-cursor.is-hovering .icon-plus {
    transform: translate(-50%, -50%) scale(0) rotate(180deg);
    opacity: 0;
}
#custom-cursor.is-hovering .icon-hand {
    transform: translate(-11px, -3px) scale(1) translateY(0);
    opacity: 1;
    animation: cursorLightning 2.2s infinite alternate;
}

/* ── CLICK ── */
#custom-cursor.is-clicking .cursor-wrapper {
    transform: scale(0.72);
}

/* ── ENTRATA/USCITA FINESTRA ── */
#custom-cursor { transition: opacity 0.15s ease; }

/* ── FULMINI ── */
@keyframes cursorLightning {
    0%,35%  { filter: drop-shadow(0 0 5px var(--gold-glow)); }
    40%     { filter: drop-shadow(0 0 18px var(--lightning)) drop-shadow(0 0 28px var(--gold-lt)); }
    45%     { filter: drop-shadow(0 0 5px var(--gold-glow)); }
    52%     { filter: drop-shadow(0 0 24px var(--lightning)) drop-shadow(0 0 38px var(--gold-lt)); }
    57%     { filter: drop-shadow(0 0 5px var(--gold-glow)); }
    100%    { filter: drop-shadow(0 0 5px var(--gold-glow)); }
}

@media (max-width: 768px) {
    /* Su mobile non serve nascondere il cursore di sistema (non esiste) */
    * { cursor: auto !important; }
    /* Nascosto di default: appare solo al tocco via JS */
    #custom-cursor { opacity: 0; }
}
