:root {
  --ink: #21100b;
  --ink-soft: #4b3329;
  --espresso: #170805;
  --espresso-2: #24110c;
  --paper: #f4ead9;
  --paper-2: #fff6e6;
  --paper-3: #ead9bf;
  --gold: #d2944f;
  --gold-2: #f2c57a;
  --white: #fff8ee;
  --line: rgba(33,16,11,.14);
  --line-light: rgba(255,248,238,.16);
  --shadow: 0 24px 70px rgba(50, 26, 16, .20);
  --shadow-dark: 0 28px 80px rgba(0,0,0,.35);
  --max: 1180px;
  --serif: Georgia, "Times New Roman", Times, serif;
  --sans: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: var(--sans);
  line-height: 1.65;
  text-rendering: optimizeLegibility;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
.container { width: min(var(--max), calc(100% - 48px)); margin: 0 auto; }
section { scroll-margin-top: 92px; }
.skip-link { position: absolute; left: -9999px; top: 8px; background: var(--gold); color: var(--ink); padding: 10px 14px; z-index: 999; }
.skip-link:focus { left: 8px; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(27, 10, 6, .88);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.nav {
  min-height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.brand { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; color: var(--white); font-weight: 900; }
.brand-mark { width: 36px; height: 36px; display: grid; place-items: center; border-radius: 50%; background: linear-gradient(135deg, var(--gold-2), var(--gold)); color: var(--ink); font-family: var(--serif); font-weight: 900; box-shadow: 0 10px 30px rgba(0,0,0,.30); }
.brand-name { letter-spacing: .01em; }
.nav-links { display: flex; align-items: center; gap: 26px; color: rgba(255,248,238,.88); font-weight: 800; font-size: .93rem; }
.nav-links a { text-decoration: none; }
.nav-links a:hover { color: var(--gold-2); }
.nav-button { padding: 10px 18px; border: 1px solid rgba(242,197,122,.55); border-radius: 999px; background: rgba(242,197,122,.14); color: var(--white); }

h1, h2, h3, p { margin: 0; }
h1, h2, h3 { font-family: var(--serif); letter-spacing: -.045em; line-height: .96; }
h1 { font-size: clamp(4rem, 8.4vw, 7.25rem); max-width: 720px; }
h2 { font-size: clamp(2.45rem, 5vw, 4.75rem); max-width: 760px; }
h3 { font-size: 1.55rem; }
.kicker, .section-label { text-transform: uppercase; letter-spacing: .23em; font-size: .75rem; font-weight: 900; color: #a95d1f; }
.section-label.light, .kicker { color: var(--gold-2); }
.lead { font-size: clamp(1.08rem, 1.35vw, 1.25rem); color: var(--ink-soft); max-width: 630px; }

.hero {
  position: relative;
  overflow: hidden;
  min-height: calc(100svh - 74px);
  padding: clamp(62px, 7vw, 96px) 0 clamp(68px, 8vw, 108px);
  background:
    linear-gradient(90deg, rgba(244,234,217,.98) 0%, rgba(244,234,217,.90) 51%, rgba(33,16,11,.12) 100%),
    url('assets/texture-foto-sfondo.jpg') center/cover no-repeat;
}
.hero::after { content: ""; position: absolute; inset: auto -8% -22% 36%; height: 48%; background: radial-gradient(circle, rgba(210,148,79,.23), transparent 62%); pointer-events: none; }
.hero-texture { position: absolute; inset: 0; background-image: linear-gradient(rgba(33,16,11,.04) 1px, transparent 1px), linear-gradient(90deg, rgba(33,16,11,.03) 1px, transparent 1px); background-size: 42px 42px; opacity: .38; }
.hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, .92fr) minmax(440px, 1.05fr);
  gap: clamp(44px, 6vw, 88px);
  align-items: center;
}
.hero-copy { padding: 8px 0; }
.claim { margin: 18px 0 18px; font-family: var(--serif); font-size: clamp(1.8rem, 3vw, 2.7rem); font-weight: 900; letter-spacing: -.03em; color: #8c4b1d; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; margin: 30px 0 30px; }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 13px 20px; border-radius: 999px; text-decoration: none; font-weight: 900; line-height: 1; transition: transform .2s ease, box-shadow .2s ease, background .2s ease; }
.btn:hover { transform: translateY(-2px); }
.btn-primary { color: var(--espresso); background: linear-gradient(135deg, #fff0cf, var(--gold-2)); box-shadow: 0 16px 34px rgba(114,64,28,.18); }
.btn-secondary { color: var(--ink); border: 1px solid rgba(33,16,11,.25); background: rgba(255,255,255,.28); }
.section-dark .btn-secondary { color: var(--white); border-color: rgba(255,248,238,.28); background: rgba(255,255,255,.05); }
.hero-facts { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 12px; max-width: 610px; margin: 0; }
.hero-facts div { padding: 14px 16px; border: 1px solid var(--line); border-radius: 16px; background: rgba(255,255,255,.38); }
.hero-facts dt { font-size: .72rem; text-transform: uppercase; letter-spacing: .16em; font-weight: 900; color: #8c4b1d; }
.hero-facts dd { margin: 4px 0 0; font-family: var(--serif); font-weight: 900; font-size: 1.2rem; }
.hero-photo { margin: 0; position: relative; border-radius: 34px; padding: 12px; background: rgba(255,248,238,.55); border: 1px solid rgba(33,16,11,.13); box-shadow: var(--shadow); }
.hero-photo img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; object-position: center; border-radius: 24px; filter: contrast(1.04); }
.hero-photo figcaption { position: absolute; left: 34px; right: 34px; bottom: 28px; padding: 13px 16px; border-radius: 14px; color: var(--white); background: rgba(23,8,5,.86); font-size: .9rem; font-weight: 800; line-height: 1.45; }

.summary { padding: 34px 0; background: var(--espresso); color: var(--white); }
.summary-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.summary article { padding: 24px; border: 1px solid var(--line-light); border-radius: 20px; background: linear-gradient(135deg, rgba(255,255,255,.075), rgba(255,255,255,.025)); }
.summary span, .works-grid span, .timeline span, .next-card span { width: 34px; height: 34px; display: inline-grid; place-items: center; border-radius: 50%; background: var(--gold); color: var(--espresso); font-weight: 900; margin-bottom: 16px; }
.summary h2 { font-family: var(--sans); font-size: 1rem; line-height: 1.2; letter-spacing: 0; margin-bottom: 8px; }
.summary p { color: rgba(255,248,238,.78); }

.section { padding: clamp(84px, 8vw, 128px) 0; }
.section-paper { background: var(--paper); }
.section-dark { background: radial-gradient(circle at top right, rgba(115,59,23,.35), transparent 32%), var(--espresso); color: var(--white); }
.story-grid, .project-grid, .next-grid, .contact-card { display: grid; gap: clamp(42px, 6vw, 82px); align-items: center; }
.story-grid { grid-template-columns: minmax(0, .95fr) minmax(430px, 1fr); }
.story-copy p:not(.section-label), .project-copy p, .next-grid p, .contact-card p { margin-top: 18px; color: var(--ink-soft); font-size: 1.04rem; max-width: 670px; }
.section-dark p { color: rgba(255,248,238,.83); }
blockquote { margin: 30px 0 0; padding: 24px 28px; border-left: 5px solid var(--gold); border-radius: 0 20px 20px 0; background: #ead4b6; font-family: var(--serif); font-size: clamp(1.28rem, 2vw, 1.7rem); font-weight: 700; line-height: 1.38; color: var(--ink); }
.image-card { margin: 0; border-radius: 28px; padding: 10px; border: 1px solid rgba(33,16,11,.14); background: rgba(255,248,238,.54); box-shadow: var(--shadow); }
.image-card img { width: 100%; border-radius: 20px; object-fit: cover; }
.image-card-large img { aspect-ratio: 4 / 3; }
.image-card figcaption { padding: 12px 10px 2px; color: var(--ink-soft); font-size: .9rem; font-weight: 800; }

.split { display: grid; grid-template-columns: minmax(0,1fr) minmax(300px,.52fr); gap: 56px; align-items: end; margin-bottom: 36px; }
.split > p { font-size: 1.06rem; }
.works-banner { margin: 0 0 22px; overflow: hidden; border-radius: 28px; border: 1px solid rgba(255,255,255,.13); box-shadow: var(--shadow-dark); }
.works-banner img { width: 100%; aspect-ratio: 21/7.5; object-fit: cover; object-position: center; opacity: .9; }
.works-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 18px; }
.works-grid article { min-height: 220px; padding: 26px; border-radius: 24px; border: 1px solid var(--line-light); background: linear-gradient(145deg, rgba(255,255,255,.08), rgba(255,255,255,.03)); }
.works-grid h3 { margin-bottom: 12px; }
.works-grid p { color: rgba(255,248,238,.80); }

.project-grid { grid-template-columns: minmax(420px,.9fr) minmax(0,1fr); }
.detail-photo img { aspect-ratio: 16 / 10; object-position: center; }
.timeline { display: grid; gap: 14px; margin-top: 28px; }
.timeline article { display: grid; grid-template-columns: 38px 1fr; gap: 16px; align-items: start; padding: 18px; border: 1px solid var(--line); border-radius: 18px; background: rgba(255,255,255,.38); }
.timeline span { background: var(--espresso); color: var(--white); margin: 0; }
.timeline h3 { font-family: var(--sans); font-size: 1rem; letter-spacing: 0; line-height: 1.3; margin-bottom: 4px; }
.timeline p { margin: 0; font-size: .98rem; }

.next-step { position: relative; background: linear-gradient(90deg, rgba(23,8,5,.94), rgba(42,19,11,.88)), url('assets/texture-foto-sfondo.jpg') center/cover no-repeat; color: var(--white); overflow: hidden; }
.next-grid { grid-template-columns: minmax(0,1fr) minmax(360px,.62fr); }
.next-grid h2 { color: var(--paper-2); }
.next-grid p { color: rgba(255,248,238,.82); }
.next-card { padding: 32px; border-radius: 26px; background: var(--paper-2); color: var(--ink); box-shadow: var(--shadow-dark); }
.next-card h3 { margin-bottom: 20px; }
.next-card ol { margin: 0; padding: 0; list-style: none; display: grid; gap: 14px; }
.next-card li { display: grid; grid-template-columns: 36px 1fr; gap: 14px; align-items: start; }
.next-card span { margin: 0; }
.next-card p { margin: 2px 0 0; color: var(--ink-soft); }

.contact-card { grid-template-columns: minmax(0,1fr) minmax(330px,.48fr); padding: clamp(34px, 5vw, 58px); border: 1px solid var(--line-light); border-radius: 30px; background: linear-gradient(135deg, rgba(255,255,255,.085), rgba(255,255,255,.025)); }
.contact-card h2 { color: var(--paper-2); }
.contact-box { padding: 30px; border-radius: 24px; background: linear-gradient(135deg, #fff0cf, #f0bd72); color: var(--ink); box-shadow: 0 22px 54px rgba(0,0,0,.28); }
.contact-box span { display: block; font-size: .82rem; text-transform: uppercase; letter-spacing: .12em; font-weight: 900; color: #80501f; margin-bottom: 10px; }
.contact-box > a:not(.btn) { display: block; margin-bottom: 22px; font-size: 1.05rem; font-weight: 900; }
.site-footer { padding: 28px 20px; text-align: center; background: #080302; color: rgba(255,248,238,.78); font-size: .88rem; }
.site-footer a { color: var(--gold-2); font-weight: 800; }

@media (max-width: 1040px) {
  .container { width: min(760px, calc(100% - 32px)); }
  .nav { flex-wrap: wrap; justify-content: center; padding: 12px 0; }
  .nav-links { width: 100%; justify-content: center; gap: 12px; flex-wrap: wrap; }
  .hero { min-height: auto; }
  .hero-grid, .story-grid, .split, .project-grid, .next-grid, .contact-card { grid-template-columns: 1fr; }
  .hero-photo { order: -1; }
  .hero-facts, .summary-grid, .works-grid { grid-template-columns: 1fr; }
  .works-banner img { aspect-ratio: 16/8; }
}

@media (max-width: 620px) {
  .container { width: min(100% - 24px, 520px); }
  .nav { min-height: auto; }
  .brand { width: 100%; justify-content: center; }
  .nav-links { font-size: .83rem; gap: 6px; }
  .nav-links a { padding: 7px 8px; }
  h1 { font-size: clamp(3.15rem, 16vw, 4.4rem); }
  h2 { font-size: clamp(2.3rem, 12vw, 3.4rem); }
  .hero { padding: 34px 0 58px; }
  .hero-copy { text-align: left; }
  .hero-actions { display: grid; }
  .btn { width: 100%; }
  .hero-facts { gap: 8px; }
  .hero-photo { border-radius: 22px; padding: 8px; }
  .hero-photo img, .image-card-large img { aspect-ratio: 4/5; object-position: center; }
  .hero-photo figcaption { position: static; margin-top: 10px; border-radius: 14px; }
  .section { padding: 64px 0; }
  .summary { padding: 24px 0; }
  .works-banner img { aspect-ratio: 4/3; }
  .timeline article, .next-card li { grid-template-columns: 32px 1fr; }
  .contact-card { padding: 24px; }
}
