/* ============================================================
   PROGETTO SERRAMENTI — pages.css
   New work (v4.12+): loaded AFTER main.css so it can refine it
   without touching the battle-tested base. Contains:
     1. Global typography increase (readability)
     2. "Prodotti" mega-menu (nav)
     3. Chi Siamo page
     4. Guide e Consigli (blog: archive, card, single)
   ============================================================ */

/* ---------------------------------------------------------------
   1. TYPOGRAPHY — moderate global increase for readability
   (overrides main.css; loaded later)
   --------------------------------------------------------------- */
body            { font-size: 17px; line-height: 1.65; }
.lead           { font-size: clamp(18px, 1.5vw, 22px); line-height: 1.7; }
.body           { font-size: 16.5px; line-height: 1.75; }
.eyebrow        { font-size: 12px; }
/* L'oro del brand (#c9a96e) su fondo chiaro dà 2.08:1 — sotto la soglia AA e
   duro da leggere per il nostro pubblico (proprietari di casa 45+). Su chiaro
   passa a un oro più profondo (4.51:1); sui fondi scuri resta l'oro originale,
   che lì è già a 8.85:1. */
:root { --gold-ink: #8a6d36; }
.eyebrow { color: var(--gold-ink); }
.is-dark .eyebrow, .is-deep .eyebrow, .hero .eyebrow { color: var(--gold); }
.small          { font-size: 13.5px; }
/* keep headings tight & balanced */
.display-xl, .display-lg, .display-md, .display-sm { text-wrap: balance; }
.lead, .body, p { text-wrap: pretty; }

/* ---------------------------------------------------------------
   2. NAV — "Prodotti" mega-menu
   Uses a fresh .nav-mega class (NOT .nav-dropdown) so the legacy
   "hide dropdown on mobile" rule never hides the product links.
   On mobile the panel collapses into an indented sub-list.
   --------------------------------------------------------------- */
.nav-has-mega { position: relative; display: inline-block; }
.nav-caret {
  font-size: 0.68em; color: var(--gold); margin-left: 5px;
  display: inline-block; transition: transform 0.28s var(--ease);
}
.nav-has-mega:hover .nav-caret { transform: rotate(180deg); }

.nav-mega {
  position: absolute; top: 100%; left: 0;
  width: min(640px, 92vw);
  background: var(--bg-paper);
  border: 1px solid var(--line-light);
  border-radius: 8px;
  box-shadow: 0 28px 64px -16px rgba(20,16,8,.30), 0 6px 14px rgba(20,16,8,.08);
  padding: 18px;
  opacity: 0; visibility: hidden; pointer-events: none;
  transform: translateY(12px);
  transition: opacity 0.26s var(--ease-out), transform 0.26s var(--ease-out);
  z-index: 60;
}
.nav-mega::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
  border-radius: 8px 8px 0 0;
}
@media (min-width: 901px) {
  .nav-has-mega:hover .nav-mega,
  .nav-has-mega:focus-within .nav-mega {
    opacity: 1; visibility: visible; pointer-events: auto; transform: translateY(0);
  }
}
.nav-mega-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; }
.nav-main .nav-mega-item {
  display: block; padding: 12px 14px; border-radius: 5px;
  transition: background 0.2s var(--ease), transform 0.2s var(--ease);
}
.nm-label {
  display: block; font-family: var(--font-display);
  font-size: 19px; font-weight: 400; line-height: 1.1; color: var(--fg-on-light);
  text-transform: none; letter-spacing: 0;
}
.nm-desc {
  display: block; font-family: var(--font-body); font-size: 12px;
  letter-spacing: 0.01em; color: var(--fg-on-light-3); margin-top: 3px;
  text-transform: none;
}
@media (hover: hover) {
  .nav-main .nav-mega-item:hover { background: var(--bg-cream); transform: translateX(4px); }
  .nav-main .nav-mega-item:hover .nm-label { color: var(--gold-deep); }
}
.nav-mega-sub {
  display: flex; align-items: center; flex-wrap: wrap; gap: 10px;
  margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line-light);
}
.nav-mega-sub-head {
  font-size: 10px; letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--fg-on-light-3);
}
.nav-main .nav-mega-sub a {
  font-size: 13px; padding: 6px 14px; border: 1px solid var(--line-light);
  border-radius: 999px; transition: border-color 0.2s var(--ease), color 0.2s var(--ease);
}
.nav-main .nav-mega-sub a:hover { border-color: var(--gold); color: var(--gold-deep); }

/* Mobile (v4.14.0): NO "Prodotti" parent and NO accordion. The product pages
   (Porte, Infissi, Persiane, Zanzariere, Blindate, Residenziali) are listed
   DIRECTLY as flat top-level rows — pure CSS, zero JS dependency, so it can
   never "fail to open". Desktop (>=901px) keeps the hover mega-menu untouched. */
@media (max-width: 900px) {
  /* Every top-level row spans the full width, centered (uniform list). */
  .nav-main > a { display: block; width: 100%; text-align: center; }

  /* Drop the "Prodotti" trigger + caret entirely on phone. */
  .nav-has-mega .nav-mega-trigger,
  .nav-caret { display: none !important; }

  /* The wrapper just contributes its children to the flat list. */
  .nav-has-mega { display: block; width: 100%; }

  /* Panel is always open and inline — no animation, no toggle needed. */
  .nav-mega {
    position: static; width: auto; padding: 0; margin: 0;
    background: transparent; border: none; border-radius: 0; box-shadow: none;
    opacity: 1; visibility: visible; pointer-events: auto; transform: none;
    max-height: none; overflow: visible;
  }
  .nav-mega::before { display: none; }
  .nav-mega-grid { display: block; }

  /* Each product becomes a normal full-width nav row, matching the others. */
  .nav-main .nav-mega-item {
    padding: 14px var(--sp-6); text-align: center;
    border-bottom: 1px solid var(--line-dark); border-radius: 0;
    background: transparent;
  }
  .nav-main .nav-mega-item:last-child { border-bottom: none; }
  .nav-mega-item .nm-label {
    font-size: 15px; letter-spacing: 0.06em; color: var(--fg-on-dark);
  }
  .nav-mega-item .nm-desc { display: none; }
}

/* ---------------------------------------------------------------
   3. CHI SIAMO
   --------------------------------------------------------------- */
.cs-hero { min-height: 78vh; }
.cs-hero .hero-content { padding-bottom: var(--sp-9); }

/* Story lead paragraph reused via .feature-row + .feature-img */
.cs-story-portrait { aspect-ratio: 3/4; }

/* Values grid — no numbered markers, just a hairline + serif title */
.cs-values { display: grid; grid-template-columns: repeat(3, 1fr); gap: 44px 56px; }
.cs-value { padding-top: 22px; border-top: 1px solid var(--line-light); }
.cs-value h3 {
  font-family: var(--font-display); font-weight: 400; font-size: 25px;
  line-height: 1.15; margin-bottom: 10px;
}
.cs-value h3 em { font-style: italic; color: var(--gold-deep); }
@media (max-width: 900px) { .cs-values { grid-template-columns: 1fr 1fr; gap: 32px 40px; } }
@media (max-width: 600px) { .cs-values { grid-template-columns: 1fr; gap: 28px; } }

/* Video block — portrait phone clip in an elegant frame */
.cs-video-row { display: grid; grid-template-columns: 1fr 1fr; gap: var(--sp-9); align-items: center; }
.cs-video-frame {
  position: relative; border-radius: 10px; overflow: hidden; background: #000;
  box-shadow: 0 36px 70px -34px rgba(0,0,0,.65); max-width: 440px;
}
.cs-video-frame video { display: block; width: 100%; height: auto; }
@media (max-width: 900px) {
  .cs-video-row { grid-template-columns: 1fr; gap: var(--sp-6); }
  .cs-video-frame { margin: 0 auto; }
}

/* Realizzazioni — due bande, un solo formato per banda.
   Il masonry a colonne lasciava a ogni foto la sua altezza nativa: la griglia
   sembrava disordinata. Ora ogni riquadro ha un aspect-ratio fisso (9:16 le
   verticali, 16:9 le orizzontali) e l'immagine riempie con object-fit, quindi
   dentro la banda tutte le foto hanno esattamente la stessa dimensione. */
.lav-band { display: grid; gap: 14px; }
.lav-band--v { grid-template-columns: repeat(auto-fill, minmax(232px, 1fr)); }
.lav-band--o { grid-template-columns: repeat(auto-fill, minmax(430px, 1fr)); margin-top: 14px; }

.lav-tile {
  display: block; position: relative; overflow: hidden;
  background: #2a2622; border-radius: var(--r-sm);
}
.lav-tile[hidden] { display: none; }
.lav-band--v .lav-tile { aspect-ratio: 9 / 16; }
.lav-band--o .lav-tile { aspect-ratio: 16 / 9; }
.lav-tile img {
  width: 100%; height: 100%; display: block; object-fit: cover;
  transition: transform var(--dur-reveal) var(--ease);
}
.lav-tile::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, transparent 55%, rgba(10,10,10,.45));
  opacity: 0; transition: opacity var(--dur-ui) var(--ease);
}
@media (hover: hover) {
  .lav-tile:hover img { transform: scale(1.05); }
  .lav-tile:hover::after { opacity: 1; }
}

/* "Mostra tutti" — regola sottile, non un bottone pieno: la galleria resta
   il soggetto della sezione. */
.lav-more {
  display: block; margin: var(--sp-7) auto 0; padding: 13px 30px;
  background: transparent; color: var(--fg-on-dark);
  border: 1px solid var(--line-dark); border-radius: var(--r-sm);
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.18em;
  text-transform: uppercase; cursor: pointer;
  transition: border-color var(--dur-ui) var(--ease), color var(--dur-ui) var(--ease);
}
.lav-more:hover { border-color: var(--gold); color: var(--gold); }

@media (max-width: 560px) {
  .lav-band--v { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
  .lav-band--o { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  .lav-tile img { transition: none; }
  .lav-tile:hover img { transform: none; }
}

/* ---------------------------------------------------------------
   3b. SOCIAL — reel dai cantieri
   Sta su carta, non su fondo scuro: spezza la sequenza di bande nere
   (Realizzazioni -> testimonial) e i riquadri 9:16 neri dei video
   diventano l'elemento più forte della sezione.
   --------------------------------------------------------------- */
.social-head { margin-bottom: var(--sp-7); }
.social-intro { max-width: 46ch; }
.social-intro .lead { margin-top: 18px; }
.social-cta { margin-top: var(--sp-6); }



/* Il rail scorre dentro il container: niente calcoli su 100vw, così la pagina
   non può ereditare overflow orizzontale. */
.reel-rail {
  display: flex; overflow-x: auto; overflow-y: hidden;
  scroll-snap-type: x proximity; -webkit-overflow-scrolling: touch;
  padding-bottom: 6px; margin: 0 calc(var(--sp-4) * -1); padding-inline: var(--sp-4);
  scrollbar-width: thin;
}
.reel-track { list-style: none; margin: 0; padding: 0; display: flex; gap: 14px; }
.reel { flex: 0 0 auto; width: clamp(186px, 44vw, 244px); scroll-snap-align: start; }

.reel-frame {
  position: relative; aspect-ratio: 9 / 16; overflow: hidden;
  background: var(--bg-deep); border-radius: var(--r-sm); box-shadow: var(--shadow-2);
}
.reel-video { width: 100%; height: 100%; display: block; object-fit: cover; }

/* Toggle audio — l'unico comando sul riquadro. Spento è discreto, acceso è oro:
   lo stato si legge a colpo d'occhio anche senza sentire nulla. */
.reel-audio {
  position: absolute; top: 10px; right: 10px; z-index: 2;
  display: inline-flex; align-items: center; gap: 6px; padding: 6px 9px;
  font-family: var(--mono); font-size: 10px; letter-spacing: 0.12em;
  text-transform: uppercase; cursor: pointer; border-radius: var(--r-sm);
  background: rgba(10,10,10,.55); color: var(--fg-on-dark);
  border: 1px solid rgba(245,239,230,.3);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  transition: background var(--dur-ui) var(--ease), color var(--dur-ui) var(--ease),
              border-color var(--dur-ui) var(--ease);
}
.reel-audio:not(.is-muted) {
  background: var(--gold); color: #171310; border-color: var(--gold);
}
.reel-audio:hover { border-color: var(--gold); }

/* Filo d'avanzamento: unico accento oro in movimento della sezione. */
.reel-bar {
  position: absolute; left: 0; bottom: 0; height: 2px; width: 0; z-index: 2;
  background: var(--gold); pointer-events: none;
}

.reel-cap {
  margin: 12px 0 0; font-size: 13px; line-height: 1.45;
  color: var(--fg-on-light-2);
}


@media (prefers-reduced-motion: reduce) {
  .reel-audio { transition: none; }
}

/* ---------------------------------------------------------------
   4. GUIDE E CONSIGLI (blog)
   --------------------------------------------------------------- */
/* Category filter — reuses .door-tabs JS; allow horizontal scroll on mobile */
.guide-filter { display: flex; flex-wrap: wrap; gap: 14px 24px; margin-top: 4px; }
@media (max-width: 600px) {
  .guide-filter { flex-wrap: nowrap; overflow-x: auto; -webkit-overflow-scrolling: touch; padding-bottom: 6px; }
  .guide-filter .door-tab { white-space: nowrap; }
}

/* Featured (latest) article */
.guide-featured {
  display: grid; grid-template-columns: 1.15fr 1fr; gap: var(--sp-8);
  align-items: center; margin-bottom: var(--sp-9);
}
.guide-featured .gf-img {
  display: block; aspect-ratio: 16/10; border-radius: 10px; overflow: hidden;
  background: #2a2622 center/cover no-repeat; position: relative;
}
.guide-featured .gf-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.9s var(--ease); }
.guide-featured:hover .gf-img img { transform: scale(1.04); }
.guide-featured h2 { font-family: var(--font-display); font-weight: 400; font-size: clamp(30px, 3.4vw, 48px); line-height: 1.08; margin: 12px 0 14px; }
.guide-featured h2 a:hover { color: var(--gold-deep); }
@media (max-width: 860px) {
  .guide-featured { grid-template-columns: 1fr; gap: var(--sp-5); }
}

/* Card grid */
.guide-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: var(--sp-7) var(--sp-5); }
.blog-card { display: flex; flex-direction: column; }
.blog-card .bc-img {
  display: block; aspect-ratio: 3/2; border-radius: 8px; overflow: hidden;
  background: #2a2622 center/cover no-repeat; position: relative;
}
.blog-card .bc-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.8s var(--ease); }
@media (hover: hover) { .blog-card:hover .bc-img img { transform: scale(1.05); } }
.blog-card .bc-cat {
  font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--gold-deep); font-weight: 600; margin: 18px 0 8px;
}
.blog-card h3 { font-family: var(--font-display); font-weight: 400; font-size: clamp(22px, 2vw, 27px); line-height: 1.18; margin-bottom: 10px; }
.blog-card h3 a:hover { color: var(--gold-deep); }
.blog-card .bc-excerpt { font-size: 15.5px; line-height: 1.6; color: var(--fg-on-light-2); margin-bottom: 16px; }
.blog-card .bc-meta { margin-top: auto; display: flex; gap: 16px; font-size: 12.5px; letter-spacing: 0.03em; color: var(--fg-on-light-3); }

/* Hide cards filtered out (door-tabs JS sets display:none directly; this is a safety) */
.blog-card[hidden] { display: none; }

/* Single article */
.article-hero { padding: var(--sp-10) 0 var(--sp-8); background: var(--bg-deep); color: var(--fg-on-dark); border-bottom: 1px solid var(--line-dark); }
.article-hero .article-cat { color: var(--gold); }
.article-hero h1 { max-width: 22ch; margin: 18px 0 0; }
.article-meta { display: flex; flex-wrap: wrap; gap: 18px; font-size: 13px; letter-spacing: 0.05em; color: var(--fg-on-dark-2); margin-top: 22px; }
.article-figure { margin: 0; }
.article-figure img { width: 100%; height: auto; display: block; }
.article-figure figcaption { font-size: 12.5px; color: var(--fg-on-light-3); margin-top: 10px; text-align: center; }

.article-body { max-width: 70ch; margin: 0 auto; font-size: 18px; line-height: 1.8; color: var(--fg-on-light); }
.article-body > * + * { margin-top: 1.05em; }
.article-body h2 { font-family: var(--font-display); font-weight: 400; font-size: clamp(28px, 3vw, 40px); line-height: 1.1; margin-top: 1.5em; }
.article-body h3 { font-family: var(--font-display); font-weight: 400; font-size: clamp(22px, 2.4vw, 30px); line-height: 1.15; margin-top: 1.3em; }
.article-body h2 em, .article-body h3 em { font-style: italic; color: var(--gold-deep); }
.article-body ul, .article-body ol { padding-left: 1.3em; display: flex; flex-direction: column; gap: 0.5em; }
.article-body li { line-height: 1.7; }
.article-body a { color: var(--gold-deep); text-decoration: underline; text-underline-offset: 3px; }
.article-body a:hover { color: var(--gold); }
.article-body blockquote {
  font-family: var(--font-display); font-style: italic; font-weight: 300;
  font-size: clamp(23px, 2.6vw, 32px); line-height: 1.4; color: var(--fg-on-light);
  margin: 1.6em 0; padding-left: 1.4em; text-indent: -0.7em; position: relative;
}
.article-body blockquote::before {
  content: "\201C"; color: var(--gold); font-size: 1.5em; line-height: 0;
  font-style: italic; padding-right: 0.06em; vertical-align: -0.35em;
}
.article-body img { border-radius: 8px; }
@media (max-width: 600px) { .article-body { font-size: 17px; } }

/* ============================================================
   v4.12.1 — feedback fixes (perf + header + nav)
   ============================================================ */

/* (a) Scroll reveals are now defined once in main.css (blur removed there). */

/* (b) Header: CONSTANT height (no grow/shrink on scroll) so it never "breaks"
   for a moment when scrolling back up. Only the subtle shadow still reacts. */
.site-header .header-inner,
.site-header.is-scrolled .header-inner { transition: box-shadow var(--t-med) var(--ease); }
@media (min-width: 901px) {
  .site-header .header-inner,
  .site-header.is-scrolled .header-inner { height: 96px; }
}
@media (max-width: 900px) {
  .site-header .header-inner,
  .site-header.is-scrolled .header-inner { height: 72px; }
  .nav-main { top: 72px; }
}

/* (c) Bigger, bolder, vertically aligned primary nav — desktop only (≥901px),
   so it never fights the full-width mobile drawer layout. Every top-level item
   shares identical metrics so none (e.g. Home) sits lower than the others. */
@media (min-width: 901px) {
  .nav-main { align-items: center; }
  .nav-main a { font-weight: 600; }
  .nav-main > a,
  .nav-has-mega,
  .nav-main .nav-mega-trigger { display: inline-flex; align-items: center; line-height: 1; white-space: nowrap; }
}
@media (min-width: 1281px) { .nav-main { font-size: 18px; gap: 30px; } }
@media (min-width: 1061px) and (max-width: 1280px) { .nav-main { font-size: 16px; gap: 24px; } }
@media (min-width: 901px) and (max-width: 1060px) { .nav-main { font-size: 15px; gap: 18px; } }
@media (max-width: 900px) { .nav-main a { font-size: 18px; font-weight: 600; } }

/* ============================================================
   v4.12.2 — product pages (uniform porte image + zanzariere consistency)
   ============================================================ */

/* Porte single: render the main door photo at a UNIFORM, larger size on
   desktop, so every product page shows the door at the same scale (before:
   small and inconsistent, driven by per-door pixel sizes from the import). */
@media (min-width: 1101px) {
  .tp-row.tp-hero .tp-col:last-child img.tp-img,
  .tp-row.tp-hero .tp-col:last-child .lightbox-link img.tp-img {
    height: 600px !important;
    width: auto !important;
    max-width: 100% !important;
    max-height: none !important;
    object-fit: contain;
  }
}
@media (min-width: 901px) and (max-width: 1100px) {
  .tp-row.tp-hero .tp-col:last-child img.tp-img,
  .tp-row.tp-hero .tp-col:last-child .lightbox-link img.tp-img {
    height: 520px !important;
    width: auto !important;
    max-width: 100% !important;
    max-height: none !important;
    object-fit: contain;
  }
}
@media (min-width: 901px) {
  .tp-row.tp-hero .tp-col:last-child .lightbox-link {
    display: inline-flex; justify-content: center; width: 100%;
  }
}

/* ============================================================
   v4.12.4 — founder photo / autoplay video / zanzariere on Home / perf
   ============================================================ */

/* Chi Siamo: 3 stats now (garanzia removed) → 3 columns */
.stats.cs-stats { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 680px) { .stats.cs-stats { grid-template-columns: 1fr; } }

/* Autoplay video frame + unmute toggle */
.cs-video-frame { position: relative; }
.cs-unmute {
  position: absolute; right: 12px; bottom: 12px; z-index: 2;
  width: 44px; height: 44px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  background: rgba(10, 10, 10, 0.55); color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.28);
  -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
  cursor: pointer; transition: background 0.2s var(--ease), color 0.2s var(--ease);
}
.cs-unmute:hover { background: var(--gold); color: #0a0a0a; border-color: var(--gold); }
.cs-unmute svg { width: 20px; height: 20px; display: block; }
.cs-unmute .ic-on { display: none; }
.cs-unmute:not(.is-muted) .ic-muted { display: none; }
.cs-unmute:not(.is-muted) .ic-on { display: block; }

/* Home product grid: 4-up cards so Zanzariere fits the second row cleanly */
.product-card.quarter { grid-column: span 3; aspect-ratio: 3/4; }
@media (max-width: 900px) { .product-card.quarter { grid-column: span 6; aspect-ratio: 4/5; } }
@media (max-width: 600px) { .product-card.quarter { grid-column: span 12; aspect-ratio: 4/3; } }

/* Perf: lighter door-intro leaves (drop the heavy repeating wood texture +
   shrink the inset shadow) so the 3D open animation is smooth, no jank. */
.intro-leaf {
  background:
    linear-gradient(180deg, rgba(255,236,200,0.10) 0%, rgba(0,0,0,0) 30%, rgba(0,0,0,0.34) 100%),
    linear-gradient(100deg, #3f2a18 0%, #2a1810 56%, #1b0f07 100%);
  box-shadow: inset 0 0 70px rgba(0,0,0,0.38);
}

/* ============================================================
   v4.12.5 — scroll perf + zanzariere matte card
   ============================================================ */

/* Sticky header: drop the backdrop blur. blur() on a fixed/sticky bar is
   repainted on EVERY scroll frame → the main cause of "the whole site lags a
   bit". Opaque background = buttery scrolling, same look. */
.site-header {
  -webkit-backdrop-filter: none !important;
  backdrop-filter: none !important;
  background: var(--bg-paper);
}
.site-header.on-dark { background: var(--bg-deep); }

/* Lighter intro panels (cheaper paint while the 3D doors rotate open). */
.intro-panel {
  box-shadow:
    inset 3px 3px 8px rgba(0,0,0,0.55),
    0 0 0 1px rgba(0,0,0,0.40),
    0 0 0 2px rgba(214,170,110,0.08);
}

/* Home "Zanzariere" = matte product render on cream, fully visible (not a
   cover-cropped photo like the others — it's a product, shown whole). */
.product-card.is-zanzariere img {
  object-fit: contain;
  background: var(--bg-cream);
  padding: 9%;
  filter: none;
}
.product-card.is-zanzariere:hover img { filter: none; transform: none; }
.product-card.is-zanzariere .product-card-overlay {
  background: linear-gradient(180deg, transparent 52%, rgba(10,10,10,0.72));
}

/* ============================================================
   v4.12.7 — door intro: REAL 3D (Three.js / WebGL canvas)
   ============================================================ */
.intro-3d { position: absolute; inset: 0; width: 100%; height: 100%; display: block; z-index: 1; }
/* logo sits ABOVE the door handles (upper third), readable over the wood */
.door-logo { justify-content: flex-start; padding-top: 14vh; z-index: 4; }
.door-logo-name { text-shadow: 0 2px 26px rgba(0,0,0,0.7); }
.door-logo-eyebrow, .door-logo-tagline { text-shadow: 0 1px 14px rgba(0,0,0,0.7); }
@media (max-width: 600px) { .door-logo { padding-top: 12vh; } }

/* ============================================================
   v4.12.9 — bolder motion (GPU-only): hero Ken Burns, clip reveals, depth parallax
   ============================================================ */

/* Hero: slow cinematic zoom on load (transform-only). On scroll the JS parallax
   takes over (translate + the same scale), so it stays seamless. */
@keyframes ps-kenburns { from { transform: scale(1); } to { transform: scale(1.06); } }
@media (prefers-reduced-motion: no-preference) {
  .hero .hero-bg { animation: ps-kenburns 8s var(--ease-out) both; }
}

/* Image wipe-reveal + depth parallax REMOVED — could leave images hidden.
   Images now render statically and are always visible. */

/* ---------------------------------------------------------------
   5. LANDSCAPE PHONES / TOUCH TABLETS (v4.14.0)
   A phone turned sideways can be 915–1024px wide and would otherwise
   fall back to the cramped desktop nav bar. We detect TOUCH devices
   (pointer: coarse, no hover) in that range and force the SAME mobile
   menu: burger + full-width dropdown with products listed directly.
   Real laptops/desktops (pointer: fine, hover) are excluded, so their
   layout is never affected. Self-contained block, loads last.
   --------------------------------------------------------------- */
@media (min-width: 901px) and (max-width: 1024px) and (pointer: coarse) and (hover: none) {
  .nav-toggle { display: flex !important; }
  .nav-main {
    position: absolute !important;
    top: 80px; left: 0; right: 0;
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 0 !important;
    background: var(--bg-deep);
    padding: 8px 0 16px;
    border-bottom: 1px solid var(--line-dark);
    box-shadow: 0 8px 32px rgba(0,0,0,0.18);
    display: none;
    z-index: 100;
  }
  .nav-main.is-open { display: flex !important; }
  .nav-main > a {
    display: block; width: 100%; text-align: center;
    padding: 14px var(--sp-6); font-size: 15px; letter-spacing: 0.06em;
    border-bottom: 1px solid var(--line-dark); color: var(--fg-on-dark);
  }
  /* Hide "Prodotti" + caret; show product pages directly (same as phone). */
  .nav-has-mega .nav-mega-trigger,
  .nav-caret { display: none !important; }
  .nav-has-mega { display: block; width: 100%; }
  .nav-mega {
    position: static !important; width: auto; padding: 0; margin: 0;
    background: transparent; border: none; box-shadow: none;
    opacity: 1 !important; visibility: visible !important; pointer-events: auto !important;
    transform: none !important; max-height: none !important; overflow: visible !important;
  }
  .nav-mega::before { display: none; }
  .nav-mega-grid { display: block; }
  .nav-main .nav-mega-item {
    padding: 14px var(--sp-6); text-align: center;
    border-bottom: 1px solid var(--line-dark); border-radius: 0; background: transparent;
  }
  .nav-main .nav-mega-item:last-child { border-bottom: none; }
  .nav-mega-item .nm-label { font-size: 15px; letter-spacing: 0.06em; color: var(--fg-on-dark); }
  .nav-mega-item .nm-desc { display: none; }
}

/* ============================================================
   PAS 3 — Responsive hardening (mobile-first safety net)
   Loads last, non-destructive. Obiectiv: zero overflow orizontal,
   media care nu forțează lățimea, hit-area touch >=44px, ritm curat.
   ============================================================ */

/* 1. Niciun element media nu poate lărgi pagina */
img, svg, video, iframe, canvas { max-width: 100%; }
video, iframe { height: auto; }
.cr-swatch-cell img { max-width: 100%; }

/* 2. Tabele din conținut (blog): scroll în propria cutie, nu pe pagină */
.article-body table {
  display: block;
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border-collapse: collapse;
}

/* 3. Container: respiră mai bine pe telefoane (32px era prea mult la 320px) */
@media (max-width: 480px) {
  .container, .container-wide { padding-left: 20px; padding-right: 20px; }
}
@media (max-width: 360px) {
  .container, .container-wide { padding-left: 16px; padding-right: 16px; }
}

/* 4. Footer bottom: se așază pe rânduri în loc să se înghesuie / iasă din ecran */
.footer-bottom { flex-wrap: wrap; gap: 8px 16px; }
.footer-legal { display: inline-flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; }
@media (max-width: 600px) {
  .footer-bottom { flex-direction: column; align-items: flex-start; gap: 10px; }
}

/* 5. Touch targets >=44px (zona de atingere), fără a schimba desktop-ul */
.nav-toggle { width: 44px; height: 44px; padding: 10px; }
@media (max-width: 900px) {
  .door-tab { min-height: 44px; display: inline-flex; align-items: center; padding: 10px 18px; }
  .res-style-tab { min-height: 44px; }
  .g-rev-arrow { width: 44px; height: 44px; flex-basis: 44px; }
}
@media (max-width: 600px) {
  .phone-link { width: 44px; height: 44px; }
}
