/* ===================================================================
   REMEA MILANO - Design System condiviso
   Aggiornamento 6.2 - premium, naturale, caldo, osteopatia integrata
   =================================================================== */

/* -------------------------------------------------------------------
   1. TOKEN - palette, tipografia, spazi, raggi, ombre
   Palette intensificata e coerente col brand REMEA.
   I testi usano charcoal-green per leggibilita calda (non nero freddo).
------------------------------------------------------------------- */
:root {
  /* Verdi - accento principale del brand */
  --sage-deep:    #4F5F50;  /* verde salvia profondo - bottoni, accenti forti */
  --sage:         #7A8B72;  /* salvia medio */
  --sage-soft:    #A8B5A3;  /* salvia chiaro */
  --sage-mist:    #DCE3D7;  /* salvia nebbia - sfondi tenui */

  /* Neutri caldi */
  --ivory:        #F7F3EC;  /* fondo principale */
  --ivory-warm:   #F1EBE0;  /* fondo alternato */
  --warm-beige:   #E7DDD0;  /* card secondarie */
  --taupe:        #B8AA9B;  /* dettagli neutri */
  --taupe-soft:   #D6CBBE;  /* bordi morbidi */

  /* Marrone / scuri */
  --warm-brown:   #8B7355;  /* dettagli caldi */
  --charcoal:     #26352D;  /* charcoal green - testi principali */
  --charcoal-soft:#3D4A40;  /* testi secondari */
  --ink-muted:    #6B7468;  /* testo tenue, didascalie */

  /* Funzionali */
  --white:        #FFFFFF;
  --red:          #B5524A;
  --line:         rgba(38,53,45,0.10);   /* linee sottili */
  --line-soft:    rgba(38,53,45,0.06);

  /* Tipografia */
  --font-title: 'Cormorant Garamond', Georgia, 'Times New Roman', serif;
  --font-body:  'Inter', 'Manrope', -apple-system, BlinkMacSystemFont, sans-serif;

  /* Raggi - bordi arrotondati eleganti */
  --r-sm: 10px;
  --r-md: 16px;
  --r-lg: 24px;
  --r-xl: 32px;
  --r-pill: 999px;

  /* Ombre - morbide, naturali */
  --shadow-sm: 0 2px 12px rgba(38,53,45,0.05);
  --shadow-md: 0 8px 30px rgba(38,53,45,0.08);
  --shadow-lg: 0 20px 60px rgba(38,53,45,0.10);

  /* Layout */
  --container: 1200px;
  --container-narrow: 920px;
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
}

/* -------------------------------------------------------------------
   2. RESET & BASE
------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
  color: var(--charcoal-soft);
  background: var(--ivory);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }

a { color: inherit; text-decoration: none; transition: color 0.2s var(--ease); }

::selection { background: var(--sage-soft); color: var(--charcoal); }

/* -------------------------------------------------------------------
   3. TIPOGRAFIA
------------------------------------------------------------------- */
h1, h2, h3, h4, h5 { font-family: var(--font-title); font-weight: 400; color: var(--charcoal); line-height: 1.15; }

.display {
  font-size: clamp(2.6rem, 6vw, 4.6rem);
  font-weight: 300;
  letter-spacing: -0.01em;
  line-height: 1.05;
}
h1, .h1 { font-size: clamp(2.2rem, 4.5vw, 3.4rem); }
h2, .h2 { font-size: clamp(1.8rem, 3.5vw, 2.6rem); }
h3, .h3 { font-size: clamp(1.3rem, 2.2vw, 1.6rem); }

.eyebrow {
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--sage-deep);
}

.lead {
  font-size: clamp(1.05rem, 1.6vw, 1.22rem);
  line-height: 1.75;
  color: var(--charcoal-soft);
}

p { margin-bottom: 1rem; }
p:last-child { margin-bottom: 0; }

.text-muted { color: var(--ink-muted); }
.text-center { text-align: center; }
.serif { font-family: var(--font-title); }

/* -------------------------------------------------------------------
   4. LAYOUT - container, sezioni, griglie
------------------------------------------------------------------- */
.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 1.5rem; }
.container-narrow { max-width: var(--container-narrow); }

.section { padding: clamp(3.5rem, 8vw, 7rem) 0; }
.section-sm { padding: clamp(2.5rem, 5vw, 4rem) 0; }

/* Sfondi alternati per dare ritmo */
.bg-ivory { background: var(--ivory); }
.bg-warm { background: var(--ivory-warm); }
.bg-beige { background: var(--warm-beige); }
.bg-sage-mist { background: var(--sage-mist); }
.bg-deep { background: var(--charcoal); color: var(--ivory); }
.bg-deep h1, .bg-deep h2, .bg-deep h3 { color: var(--ivory); }

/* Gradiente morbido beige -> salvia */
.bg-gradient {
  background: linear-gradient(160deg, var(--ivory) 0%, var(--ivory-warm) 40%, var(--sage-mist) 100%);
}
.bg-gradient-deep {
  background: linear-gradient(155deg, #2E3D32 0%, #26352D 55%, #1F2B24 100%);
  color: var(--ivory);
}

.grid { display: grid; gap: 1.5rem; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 900px) {
  .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
}

/* Section header centrato riutilizzabile */
.section-head { text-align: center; max-width: 680px; margin: 0 auto clamp(2.5rem, 5vw, 3.5rem); }
.section-head .eyebrow { display: block; margin-bottom: 1rem; }
.section-head h2 { margin-bottom: 1rem; }
.section-head p { color: var(--ink-muted); }

/* -------------------------------------------------------------------
   5. BOTTONI - arrotondati, hover morbido
------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--font-body);
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.95rem 2rem;
  border: none;
  border-radius: var(--r-pill);
  cursor: pointer;
  transition: all 0.25s var(--ease);
  white-space: nowrap;
}

.btn-primary {
  background: var(--sage-deep);
  color: var(--ivory);
  box-shadow: 0 4px 16px rgba(79,95,80,0.25);
}
.btn-primary:hover {
  background: var(--charcoal);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(79,95,80,0.3);
  color: var(--ivory);
}

.btn-outline {
  background: transparent;
  color: var(--charcoal);
  box-shadow: inset 0 0 0 1.5px var(--taupe);
}
.btn-outline:hover {
  box-shadow: inset 0 0 0 1.5px var(--sage-deep);
  color: var(--sage-deep);
  transform: translateY(-2px);
}

.btn-light {
  background: var(--ivory);
  color: var(--charcoal);
}
.btn-light:hover { background: var(--white); transform: translateY(-2px); color: var(--charcoal); }

.btn-lg { padding: 1.15rem 2.6rem; font-size: 0.86rem; }
.btn-block { display: flex; width: 100%; }

/* -------------------------------------------------------------------
   6. CARD - bordi ampi, morbide, premium
------------------------------------------------------------------- */
.card {
  background: var(--white);
  border-radius: var(--r-lg);
  padding: 2rem;
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease);
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }

.card-soft { background: var(--ivory-warm); box-shadow: none; border: 1px solid var(--line-soft); }
.card-beige { background: var(--warm-beige); box-shadow: none; }
.card-deep { background: var(--charcoal); color: var(--ivory); box-shadow: var(--shadow-md); }
.card-deep h3 { color: var(--ivory); }

.card-ico {
  width: 56px; height: 56px;
  display: flex; align-items: center; justify-content: center;
  background: var(--sage-mist);
  border-radius: var(--r-md);
  margin-bottom: 1.2rem;
}
.card-ico svg { width: 26px; height: 26px; color: var(--sage-deep); stroke-width: 1.4; }
.card-deep .card-ico { background: rgba(168,181,163,0.18); }
.card-deep .card-ico svg { color: var(--sage-soft); }

.card h3 { margin-bottom: 0.6rem; }
.card p { font-size: 0.92rem; color: var(--ink-muted); line-height: 1.65; }

/* Immagini con angoli arrotondati */
.rounded   { border-radius: var(--r-md); }
.rounded-lg { border-radius: var(--r-lg); }
.rounded-xl { border-radius: var(--r-xl); }
.img-cover { width: 100%; height: 100%; object-fit: cover; }

/* -------------------------------------------------------------------
   7. CHIP / TAG / BADGE
------------------------------------------------------------------- */
.chip {
  display: inline-flex; align-items: center;
  font-size: 0.72rem; font-weight: 500; letter-spacing: 0.04em;
  padding: 0.35rem 0.85rem;
  background: var(--sage-mist);
  color: var(--sage-deep);
  border-radius: var(--r-pill);
}
.chip-outline { background: transparent; box-shadow: inset 0 0 0 1px var(--taupe-soft); color: var(--charcoal-soft); }

/* -------------------------------------------------------------------
   8. HEADER / NAVBAR
------------------------------------------------------------------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(247,243,236,0.85);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line-soft);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 76px; }

.logo { display: flex; align-items: center; gap: 0.7rem; }
.logo-icon { width: 40px; height: 40px; object-fit: contain; }
.logo-text { display: flex; flex-direction: column; line-height: 1.1; }
.logo-name { font-family: var(--font-title); font-size: 1.35rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--charcoal); }
.logo-sub { font-size: 0.54rem; letter-spacing: 0.22em; text-transform: uppercase; color: var(--ink-muted); margin-top: 2px; }

.main-nav { display: flex; align-items: center; gap: 1.7rem; }
.main-nav > a { font-size: 0.82rem; letter-spacing: 0.04em; color: var(--charcoal-soft); font-weight: 400; }
.main-nav > a:hover { color: var(--sage-deep); }

.nav-dropdown { position: relative; }
.nav-dropdown > a { display: inline-flex; align-items: center; gap: 0.3rem; font-size: 0.82rem; color: var(--charcoal-soft); cursor: pointer; }
.nav-dropdown > a:hover { color: var(--sage-deep); }
.chevron { width: 10px; height: 10px; transition: transform 0.2s; }
.nav-dropdown:hover .chevron { transform: rotate(180deg); }
.nav-dropdown-menu {
  position: absolute; top: 100%; left: 50%; transform: translateX(-50%) translateY(10px);
  background: var(--white); border-radius: var(--r-md); box-shadow: var(--shadow-md);
  padding: 0.6rem; min-width: 190px; opacity: 0; visibility: hidden;
  transition: all 0.22s var(--ease); display: flex; flex-direction: column;
}
.nav-dropdown:hover .nav-dropdown-menu { opacity: 1; visibility: visible; transform: translateX(-50%) translateY(8px); }
.nav-dropdown-menu a { padding: 0.6rem 0.9rem; font-size: 0.82rem; border-radius: var(--r-sm); color: var(--charcoal-soft); }
.nav-dropdown-menu a:hover { background: var(--sage-mist); color: var(--sage-deep); }

.nav-link-subtle { font-size: 0.78rem !important; color: var(--ink-muted) !important; }
.nav-cta {
  background: var(--sage-deep); color: var(--ivory) !important;
  padding: 0.65rem 1.5rem; border-radius: var(--r-pill); font-size: 0.78rem;
  font-weight: 500; letter-spacing: 0.06em; transition: all 0.25s var(--ease);
}
.nav-cta:hover { background: var(--charcoal); transform: translateY(-1px); }

.hamburger { display: none; flex-direction: column; gap: 5px; background: none; border: none; cursor: pointer; padding: 8px; }
.hamburger span { width: 24px; height: 2px; background: var(--charcoal); border-radius: 2px; transition: all 0.3s; }

/* Mobile nav */
.mobile-nav {
  position: fixed; top: 0; right: 0; bottom: 0; width: min(86vw, 360px);
  background: var(--ivory); z-index: 200; padding: 5rem 2rem 2rem;
  display: flex; flex-direction: column; gap: 0.4rem;
  transform: translateX(100%); transition: transform 0.35s var(--ease);
  overflow-y: auto; box-shadow: var(--shadow-lg);
}
.mobile-nav.is-open { transform: translateX(0); }
.mobile-nav > a, .mobile-nav-parent {
  font-size: 1rem; padding: 0.7rem 0; color: var(--charcoal); font-family: var(--font-body);
  background: none; border: none; text-align: left; width: 100%; cursor: pointer;
  display: flex; align-items: center; justify-content: space-between;
}
.mobile-nav-close { position: absolute; top: 1.5rem; right: 1.5rem; background: none; border: none; font-size: 2rem; color: var(--charcoal); cursor: pointer; line-height: 1; }
.mobile-nav-group { display: flex; flex-direction: column; }
.mobile-nav-sub { display: none; flex-direction: column; padding-left: 1rem; }
.mobile-nav-group.is-open .mobile-nav-sub { display: flex; }
.mobile-nav-sub a { font-size: 0.9rem; padding: 0.5rem 0; color: var(--ink-muted); }
.mob-chevron { width: 12px; height: 12px; transition: transform 0.2s; }
.mobile-nav-group.is-open .mob-chevron { transform: rotate(180deg); }

@media (max-width: 920px) {
  .main-nav { display: none; }
  .hamburger { display: flex; }
}

/* -------------------------------------------------------------------
   9. FOOTER
------------------------------------------------------------------- */
.site-footer { background: var(--charcoal); color: rgba(247,243,236,0.7); padding: clamp(3rem, 6vw, 5rem) 0 2rem; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.2fr; gap: 2.5rem; padding-bottom: 3rem; border-bottom: 1px solid rgba(247,243,236,0.12); }
.footer-brand .logo-name { color: var(--ivory); }
.footer-brand .logo-sub { color: var(--sage-soft); }
.footer-payoff { font-family: var(--font-title); font-size: 1.05rem; color: var(--sage-soft); margin: 1rem 0; font-style: italic; }
.footer-brand p { font-size: 0.86rem; line-height: 1.7; color: rgba(247,243,236,0.6); }
.footer-founder { margin-top: 1rem; font-size: 0.8rem !important; color: rgba(247,243,236,0.5) !important; }
.footer-col h4 { color: var(--ivory); font-family: var(--font-body); font-size: 0.74rem; letter-spacing: 0.16em; text-transform: uppercase; margin-bottom: 1.1rem; font-weight: 600; }
.footer-col a { display: block; font-size: 0.86rem; color: rgba(247,243,236,0.65); padding: 0.32rem 0; }
.footer-col a:hover { color: var(--sage-soft); }
.footer-disclaimer { font-size: 0.74rem; color: rgba(247,243,236,0.4); line-height: 1.6; padding: 1.8rem 0; }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; font-size: 0.78rem; color: rgba(247,243,236,0.5); flex-wrap: wrap; gap: 0.5rem; }
.footer-bottom a:hover { color: var(--sage-soft); }

@media (max-width: 820px) { .footer-grid { grid-template-columns: 1fr 1fr; gap: 2rem; } }
@media (max-width: 500px) { .footer-grid { grid-template-columns: 1fr; } }

/* -------------------------------------------------------------------
   10. HERO generico
------------------------------------------------------------------- */
.hero { position: relative; padding: clamp(4rem, 9vw, 8rem) 0; overflow: hidden; }
.hero-content { max-width: 720px; position: relative; z-index: 2; }
.hero .eyebrow { margin-bottom: 1.4rem; display: inline-block; }
.hero h1 { margin-bottom: 1.5rem; }
.hero .lead { margin-bottom: 2.2rem; max-width: 560px; }
.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; }

/* decorazione organica leggera di sfondo */
.hero-orb {
  position: absolute; border-radius: 50%; filter: blur(60px); opacity: 0.5; z-index: 0;
  background: radial-gradient(circle, var(--sage-soft), transparent 70%);
}

/* -------------------------------------------------------------------
   11. UTILITY
------------------------------------------------------------------- */
.mt-0{margin-top:0}.mt-1{margin-top:.5rem}.mt-2{margin-top:1rem}.mt-3{margin-top:1.5rem}.mt-4{margin-top:2rem}
.mb-0{margin-bottom:0}.mb-2{margin-bottom:1rem}.mb-3{margin-bottom:1.5rem}.mb-4{margin-bottom:2rem}
.flex{display:flex}.items-center{align-items:center}.justify-center{justify-content:center}.justify-between{justify-content:space-between}
.gap-1{gap:.5rem}.gap-2{gap:1rem}.gap-3{gap:1.5rem}
.wrap{flex-wrap:wrap}
.relative{position:relative}

/* Reveal on scroll (attivato via JS opzionale, fallback visibile) */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.7s var(--ease), transform 0.7s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } }
