/* ================================================
   LABORATORIO ORAFO OLIVETTI PAOLO — Styles
   ================================================ */

/* Google Fonts caricati via <link> in ogni HTML  */

:root {
  --gold:        #C9A84C;
  --gold-dark:   #A07A28;
  --gold-light:  #E8D5A0;
  --dark:        #1C1610;
  --dark-2:      #2C2416;
  --medium:      #4A3B28;
  --light-bg:    #FAF7F2;
  --cream:       #F0E6D0;
  --text:        #2C2416;
  --text-light:  #7A6545;
  --white:       #FFFFFF;
  --nav-h:       80px;
  --max-w:       1200px;
  --radius:      4px;
  --shadow:      0 4px 20px rgba(28,22,16,.12);
  --shadow-lg:   0 8px 40px rgba(28,22,16,.18);
  --tr:          .3s ease;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Lato', sans-serif;
  font-size: 16px;
  line-height: 1.75;
  color: var(--text);
  background: var(--light-bg);
}
img { max-width: 100%; height: auto; display: block; }
ul  { list-style: none; }
a   { color: var(--gold); text-decoration: none; transition: color var(--tr); }
a:hover { color: var(--gold-dark); }

/* ---- TYPOGRAPHY ---- */
h1, h2, h3, h4, h5 {
  font-family: 'Cormorant Garant', serif;
  line-height: 1.2;
  color: var(--dark);
  font-weight: 600;
}
h1 { font-size: clamp(2.2rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.8rem, 3.5vw, 2.8rem); }
h3 { font-size: clamp(1.25rem, 2.5vw, 1.8rem); }
h4 { font-size: 1.15rem; }
p  { margin-bottom: 1rem; }
p:last-child { margin-bottom: 0; }

/* ---- LAYOUT ---- */
.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 1.5rem;
}
.section        { padding: 5rem 0; }
.section-dark   { background: var(--dark); color: var(--white); }
.section-cream  { background: var(--cream); }
.section-dark h2,
.section-dark h3,
.section-dark h4 { color: var(--gold-light); }

.section-header   { text-align: center; margin-bottom: 3.5rem; }
.section-header h2 { margin-bottom: .75rem; }
.section-header p  { font-size: 1.05rem; color: var(--text-light); max-width: 600px; margin: 0 auto; }
.section-dark .section-header p { color: rgba(255,255,255,.7); }

.section-label {
  display: inline-block;
  font-family: 'Lato', sans-serif;
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: .75rem;
}

.gold-divider        { width: 50px; height: 2px; background: var(--gold); margin: .75rem auto 1.5rem; }
.gold-divider.left   { margin-left: 0; }

/* ---- BUTTONS ---- */
.btn {
  display: inline-block;
  padding: .85rem 2rem;
  font-family: 'Lato', sans-serif;
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  border-radius: var(--radius);
  transition: all var(--tr);
  cursor: pointer;
  border: none;
  text-align: center;
}
.btn-gold { background: var(--gold); color: var(--dark); }
.btn-gold:hover {
  background: var(--gold-dark); color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(201,168,76,.35);
}
.btn-outline { background: transparent; border: 2px solid var(--gold); color: var(--gold); }
.btn-outline:hover { background: var(--gold); color: var(--dark); transform: translateY(-2px); }
.btn-outline-dark { background: transparent; border: 2px solid var(--dark); color: var(--dark); }
.btn-outline-dark:hover { background: var(--dark); color: var(--white); }
.btn-outline-white { background: transparent; border: 2px solid var(--white); color: var(--white); }
.btn-outline-white:hover { background: var(--white); color: var(--dark); }

/* ---- NAVBAR ---- */
.navbar {
  position: fixed; top: 0; left: 0; width: 100%;
  z-index: 1000;
  background: transparent;
  transition: background var(--tr), box-shadow var(--tr);
}
.navbar.scrolled {
  background: var(--dark);
  box-shadow: 0 2px 20px rgba(0,0,0,.35);
}
.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--nav-h);
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 1.5rem;
}
.nav-logo {
  display: flex; flex-direction: column;
  line-height: 1.1;
  text-decoration: none;
  color: var(--white);
}
.nav-logo .logo-main {
  font-family: 'Cormorant Garant', serif;
  font-size: 1.2rem; font-weight: 700;
  letter-spacing: .05em; color: var(--gold);
}
.nav-logo .logo-sub {
  font-family: 'Lato', sans-serif;
  font-size: .62rem; letter-spacing: .28em;
  text-transform: uppercase; color: rgba(255,255,255,.8);
}
.nav-menu {
  display: flex; gap: 2rem; align-items: center;
}
.nav-menu a {
  font-family: 'Lato', sans-serif;
  font-size: .78rem; font-weight: 700;
  letter-spacing: .12em; text-transform: uppercase;
  color: rgba(255,255,255,.88);
  position: relative; padding-bottom: 4px;
  transition: color var(--tr);
}
.nav-menu a::after {
  content: '';
  position: absolute; bottom: 0; left: 0;
  width: 0; height: 1px;
  background: var(--gold);
  transition: width var(--tr);
}
.nav-menu a:hover,
.nav-menu a.active { color: var(--gold); }
.nav-menu a:hover::after,
.nav-menu a.active::after { width: 100%; }

/* hamburger */
.hamburger {
  display: none; flex-direction: column; gap: 5px;
  cursor: pointer; background: none; border: none;
  padding: 4px; z-index: 1002;
}
.hamburger span {
  display: block; width: 24px; height: 2px;
  background: var(--white);
  transition: all var(--tr);
  transform-origin: center;
}
.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.nav-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.55);
  z-index: 999;
  opacity: 0; pointer-events: none;
  transition: opacity var(--tr);
}
.nav-overlay.open { opacity: 1; pointer-events: all; }

/* ---- HERO ---- */
.hero {
  position: relative; min-height: 100vh;
  display: flex; align-items: center; overflow: hidden;
}
.hero-bg { position: absolute; inset: 0; z-index: 0; }
.hero-bg img { width: 100%; height: 100%; object-fit: cover; object-position: center; }
.hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(135deg,rgba(28,22,16,.88) 0%,rgba(28,22,16,.62) 55%,rgba(28,22,16,.38) 100%);
}
.hero-inner {
  position: relative; z-index: 1;
  width: 100%; max-width: var(--max-w);
  margin: 0 auto; padding: 0 1.5rem;
}
.hero-content { max-width: 680px; padding: 2rem 0; }
.hero-label {
  display: inline-block;
  font-family: 'Lato', sans-serif;
  font-size: .7rem; font-weight: 700;
  letter-spacing: .3em; text-transform: uppercase;
  color: var(--gold);
  border-bottom: 1px solid var(--gold);
  padding-bottom: .45rem; margin-bottom: 1.5rem;
}
.hero h1 { color: var(--white); margin-bottom: 1.25rem; }
.hero h1 em { font-style: normal; color: var(--gold); }
.hero p {
  font-size: 1.12rem; color: rgba(255,255,255,.85);
  max-width: 520px; margin-bottom: 2.5rem; line-height: 1.8;
}
.hero-btns { display: flex; gap: 1rem; flex-wrap: wrap; }

/* ---- PAGE HERO (pagine interne) ---- */
.page-hero {
  padding: 10rem 0 4.5rem;
  background: var(--dark);
  position: relative; overflow: hidden;
}
.page-hero::before {
  content: '';
  position: absolute; inset: 0;
  background: url('https://images.unsplash.com/photo-1611591437281-460bfbe1220a?w=1600&q=55') center/cover no-repeat;
  opacity: .1;
}
.page-hero .container { position: relative; z-index: 1; }
.page-hero h1 { color: var(--white); margin-bottom: .5rem; }
.page-hero .breadcrumb {
  font-size: .8rem; color: rgba(255,255,255,.5);
  letter-spacing: .08em;
}
.page-hero .breadcrumb a { color: var(--gold); }

/* ---- INTRO GRID ---- */
.intro-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem; align-items: center;
}
.intro-grid.reverse { direction: rtl; }
.intro-grid.reverse > * { direction: ltr; }

.intro-img {
  position: relative; border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow-lg);
}
.intro-img img {
  width: 100%; height: 480px;
  object-fit: cover;
  transition: transform .6s ease;
}
.intro-img:hover img { transform: scale(1.04); }
.intro-img::after {
  content: '';
  position: absolute; bottom: -1rem; right: -1rem;
  width: 55%; height: 55%;
  border: 2px solid var(--gold); border-radius: var(--radius);
  z-index: -1; opacity: .45;
}
.intro-text .section-label { margin-bottom: .4rem; }
.intro-text h2 { margin-bottom: .85rem; }
.intro-text p { color: var(--text-light); margin-bottom: 1.1rem; }
.intro-text .btn { margin-top: .75rem; }

/* ---- FEATURE CARDS ---- */
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}
.feature-card {
  text-align: center; padding: 2.5rem 2rem;
  background: var(--white); border-radius: var(--radius);
  box-shadow: var(--shadow);
  transition: transform var(--tr), box-shadow var(--tr);
}
.feature-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.feature-icon { width: 56px; height: 56px; margin: 0 auto 1.5rem; color: var(--gold); }
.feature-card h3 { font-size: 1.25rem; margin-bottom: .6rem; }
.feature-card p  { font-size: .93rem; color: var(--text-light); margin: 0; }

/* ---- SERVICE CARDS ---- */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
}
.service-card {
  padding: 2.5rem 2rem;
  border: 1px solid rgba(201,168,76,.2);
  border-radius: var(--radius);
  background: var(--white);
  position: relative; overflow: hidden;
  transition: transform var(--tr), box-shadow var(--tr), border-color var(--tr);
}
.service-card::before {
  content: '';
  position: absolute; top: 0; left: 0;
  width: 3px; height: 0;
  background: var(--gold);
  transition: height .4s ease;
}
.service-card:hover::before { height: 100%; }
.service-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-color: rgba(201,168,76,.4);
}
.service-icon { width: 46px; height: 46px; color: var(--gold); margin-bottom: 1.25rem; }
.service-card h3 { font-size: 1.3rem; margin-bottom: .65rem; }
.service-card p  { font-size: .92rem; color: var(--text-light); line-height: 1.65; margin: 0; }

/* ---- GALLERY ---- */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}
.gallery-item {
  position: relative; overflow: hidden;
  border-radius: var(--radius); cursor: pointer;
}
.gallery-item.tall { grid-row: span 2; }
.gallery-item img {
  width: 100%; height: 280px; object-fit: cover;
  transition: transform .55s ease;
}
.gallery-item.tall img { height: 100%; min-height: 570px; }
.gallery-item:hover img { transform: scale(1.07); }
.gallery-overlay {
  position: absolute; inset: 0;
  background: rgba(28,22,16,0);
  display: flex; align-items: center; justify-content: center;
  transition: background var(--tr);
}
.gallery-item:hover .gallery-overlay { background: rgba(28,22,16,.42); }
.gallery-zoom {
  color: var(--white); opacity: 0;
  transition: opacity var(--tr);
  width: 48px; height: 48px;
}
.gallery-item:hover .gallery-zoom { opacity: 1; }

/* ---- STATS ---- */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem; text-align: center;
}
.stat-num {
  font-family: 'Cormorant Garant', serif;
  font-size: 3rem; font-weight: 700;
  color: var(--gold); display: block;
  line-height: 1; margin-bottom: .5rem;
}
.stat-label {
  font-size: .78rem; font-weight: 700;
  letter-spacing: .12em; text-transform: uppercase;
  color: rgba(255,255,255,.6);
}

/* ---- CONTACT ---- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: 4rem; align-items: start;
}
.contact-info h3 { margin-bottom: 2rem; }
.info-block {
  display: flex; gap: 1rem;
  margin-bottom: 1.75rem; align-items: flex-start;
}
.info-icon {
  width: 44px; height: 44px; min-width: 44px;
  background: rgba(201,168,76,.12);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--gold);
}
.info-icon svg { width: 20px; height: 20px; }
.info-block strong {
  display: block; font-size: .8rem; font-weight: 700;
  letter-spacing: .06em; text-transform: uppercase;
  margin-bottom: .25rem; color: var(--dark);
}
.info-block p,
.info-block a { font-size: .95rem; color: var(--text-light); margin: 0; line-height: 1.6; }
.info-block a:hover { color: var(--gold); }

.hours-table { font-size: .9rem; color: var(--text-light); border-collapse: collapse; }
.hours-table td:first-child { font-weight: 700; color: var(--dark); padding-right: 1.25rem; padding-bottom: .3rem; }

.map-wrapper { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); margin-top: 2rem; }
.map-wrapper iframe { display: block; border: 0; width: 100%; height: 280px; }

/* FORM */
.contact-form label {
  display: block;
  font-size: .78rem; font-weight: 700;
  letter-spacing: .08em; text-transform: uppercase;
  color: var(--dark);
  margin-bottom: .45rem; margin-top: 1.25rem;
}
.contact-form label:first-child { margin-top: 0; }
.contact-form input,
.contact-form select,
.contact-form textarea {
  width: 100%; padding: .85rem 1rem;
  font-family: 'Lato', sans-serif;
  font-size: .95rem; color: var(--text);
  background: var(--white);
  border: 1px solid rgba(44,36,22,.2);
  border-radius: var(--radius);
  transition: border-color var(--tr), box-shadow var(--tr);
  outline: none; -webkit-appearance: none; appearance: none;
}
.contact-form select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%237A6545' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  padding-right: 2.5rem;
}
.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(201,168,76,.15);
}
.contact-form textarea { resize: vertical; min-height: 140px; }
.contact-form .btn { margin-top: 1.5rem; width: 100%; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }

/* ---- CTA STRIP ---- */
.cta-strip { padding: 5rem 0; background: var(--dark); text-align: center; }
.cta-strip h2 { color: var(--white); margin-bottom: .85rem; }
.cta-strip p  { color: rgba(255,255,255,.72); font-size: 1.1rem; max-width: 480px; margin: 0 auto 2rem; }

/* ---- FOOTER ---- */
.footer { background: var(--dark-2); color: rgba(255,255,255,.68); padding: 4rem 0 2rem; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 3rem; margin-bottom: 3rem;
}
.footer-brand .logo-main {
  font-family: 'Cormorant Garant', serif;
  font-size: 1.3rem; font-weight: 700;
  color: var(--gold); display: block; margin-bottom: .2rem;
}
.footer-brand .logo-sub {
  font-family: 'Lato', sans-serif;
  font-size: .62rem; letter-spacing: .28em;
  text-transform: uppercase;
  color: rgba(255,255,255,.45); display: block; margin-bottom: 1.25rem;
}
.footer-brand p { font-size: .9rem; line-height: 1.7; margin-bottom: 1.5rem; }
.footer-social a {
  display: inline-flex; align-items: center; gap: .5rem;
  color: rgba(255,255,255,.52); font-size: .85rem;
  transition: color var(--tr);
}
.footer-social a:hover { color: var(--gold); }
.footer-social svg { width: 18px; height: 18px; }
.footer h4 {
  font-family: 'Lato', sans-serif;
  font-size: .72rem; font-weight: 700;
  letter-spacing: .22em; text-transform: uppercase;
  color: var(--gold-light); margin-bottom: 1.25rem;
}
.footer ul li { margin-bottom: .5rem; }
.footer ul li a { color: rgba(255,255,255,.58); font-size: .9rem; transition: color var(--tr); }
.footer ul li a:hover { color: var(--gold); }
.footer-contact p { font-size: .9rem; margin-bottom: .5rem; }
.footer-contact a { color: rgba(255,255,255,.58); transition: color var(--tr); }
.footer-contact a:hover { color: var(--gold); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.1);
  padding-top: 1.5rem;
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: .5rem;
  font-size: .8rem; color: rgba(255,255,255,.38);
}

/* ---- WHATSAPP BUTTON ---- */
.whatsapp-btn {
  position: fixed; bottom: 2rem; right: 2rem;
  width: 58px; height: 58px;
  background: #25D366; color: var(--white);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 20px rgba(37,211,102,.4);
  z-index: 998;
  transition: transform var(--tr), box-shadow var(--tr);
}
.whatsapp-btn:hover {
  color: var(--white);
  transform: scale(1.1) translateY(-2px);
  box-shadow: 0 8px 30px rgba(37,211,102,.5);
}
.whatsapp-btn svg { width: 30px; height: 30px; }

/* ---- SCROLL REVEAL ---- */
.reveal {
  opacity: 0; transform: translateY(30px);
  transition: opacity .65s ease, transform .65s ease;
}
.reveal.revealed { opacity: 1; transform: translateY(0); }
.reveal-d1 { transition-delay: .1s; }
.reveal-d2 { transition-delay: .2s; }
.reveal-d3 { transition-delay: .3s; }
.reveal-d4 { transition-delay: .4s; }
.reveal-d5 { transition-delay: .5s; }

/* ---- 404 ---- */
.page-404 {
  min-height: 100vh;
  display: flex; align-items: center; justify-content: center;
  text-align: center; background: var(--dark); padding: 2rem;
}
.page-404-inner { max-width: 500px; }
.num-404 {
  font-family: 'Cormorant Garant', serif;
  font-size: clamp(6rem, 18vw, 11rem); font-weight: 700;
  color: var(--gold); opacity: .22; line-height: 1;
  display: block; margin-bottom: -1rem;
}
.page-404-inner h2 { color: var(--white); margin-bottom: .85rem; }
.page-404-inner p  { color: rgba(255,255,255,.62); margin-bottom: 2rem; }

/* ---- VALORI (chi siamo) ---- */
.valori-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}
.valore-card {
  padding: 2.25rem 2rem; text-align: center;
  background: var(--white); border-radius: var(--radius);
  box-shadow: var(--shadow); border-top: 3px solid var(--gold);
  transition: transform var(--tr);
}
.valore-card:hover { transform: translateY(-5px); }
.valore-num {
  font-family: 'Cormorant Garant', serif;
  font-size: 2.5rem; font-weight: 700;
  color: var(--gold); display: block; margin-bottom: .25rem;
}
.valore-card h3 { font-size: 1.2rem; margin-bottom: .65rem; }
.valore-card p  { font-size: .92rem; color: var(--text-light); margin: 0; }

/* ---- RESPONSIVE ---- */
@media (max-width: 1024px) {
  .intro-grid    { gap: 3rem; }
  .features-grid { grid-template-columns: repeat(2,1fr); }
  .stats-grid    { grid-template-columns: repeat(2,1fr); }
  .footer-grid   { grid-template-columns: 1fr 1fr; }
  .footer-grid > :first-child { grid-column: 1 / -1; }
}

@media (max-width: 768px) {
  :root { --nav-h: 70px; }
  .section { padding: 3.5rem 0; }

  .hamburger { display: flex; }
  .nav-menu {
    position: fixed; top: 0; right: -100%;
    width: 75%; max-width: 300px; height: 100vh;
    background: var(--dark);
    flex-direction: column; justify-content: center;
    align-items: center; gap: 2.25rem;
    transition: right var(--tr);
    box-shadow: -4px 0 30px rgba(0,0,0,.3);
    z-index: 1001;
  }
  .nav-menu.open { right: 0; }
  .nav-menu a { font-size: 1rem; }

  .intro-grid,
  .intro-grid.reverse { grid-template-columns: 1fr; direction: ltr; gap: 2.5rem; }
  .intro-img img { height: 300px; }
  .intro-img::after { display: none; }

  .features-grid  { grid-template-columns: 1fr; }
  .services-grid  { grid-template-columns: 1fr; }
  .valori-grid    { grid-template-columns: 1fr; }
  .gallery-grid   { grid-template-columns: repeat(2,1fr); }
  .gallery-item.tall { grid-row: auto; }
  .gallery-item.tall img { min-height: auto; }
  .contact-grid   { grid-template-columns: 1fr; gap: 3rem; }
  .stats-grid     { grid-template-columns: repeat(2,1fr); }
  .footer-grid    { grid-template-columns: 1fr; gap: 2rem; }
  .footer-grid > :first-child { grid-column: auto; }
  .footer-bottom  { flex-direction: column; text-align: center; }
  .form-row       { grid-template-columns: 1fr; }
  .page-hero      { padding: 8rem 0 3.5rem; }

  .whatsapp-btn { bottom: 1.5rem; right: 1.5rem; width: 52px; height: 52px; }
  .whatsapp-btn svg { width: 26px; height: 26px; }
}

@media (max-width: 480px) {
  .gallery-grid { grid-template-columns: 1fr; }
  .hero-btns    { flex-direction: column; }
  .hero-btns .btn { text-align: center; }
  .stats-grid   { grid-template-columns: repeat(2,1fr); }
}
