/* Marcello Salvia — pagine servizio. CSS condiviso, nessun asset esterno. */

:root {
  --bg: #0b0c0e;
  --surface: #121417;
  --surface-2: #181b1f;
  --line: #2a2e34;
  --line-soft: #20242a;
  --text: #f4f1ea;
  --text-soft: #ded7ca;
  --muted: #b3aca0;
  --accent: #e0a04a;
  --accent-dark: #b97a28;
  --ink: #151006;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Times New Roman", serif;
  --sans: "Segoe UI", system-ui, -apple-system, Roboto, Helvetica, Arial, sans-serif;
  --radius: 2px;
  --max: 1120px;
}

*,
*::before,
*::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 500;
  letter-spacing: -0.015em;
  text-wrap: balance;
}

h1 {
  font-size: clamp(2.5rem, 6vw, 4.35rem);
  line-height: 1.02;
  margin: 0.18em 0 0.32em;
}

h2 {
  font-size: clamp(1.75rem, 3.6vw, 2.7rem);
  line-height: 1.1;
  margin: 0 0 0.5em;
}

h3 {
  font-size: 1.15rem;
  line-height: 1.3;
  margin: 0 0 0.35em;
}

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

ul, ol { margin: 0 0 1em; padding-left: 1.15em; }
li { margin-bottom: 0.35em; }

.container {
  width: min(var(--max), calc(100% - 40px));
  margin-inline: auto;
}

.skip-link {
  position: absolute;
  left: 12px;
  top: -80px;
  z-index: 200;
  padding: 12px 16px;
  background: var(--accent);
  color: var(--ink);
  font-weight: 700;
}
.skip-link:focus { top: 12px; }

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  background: rgba(11, 12, 14, 0.9);
  border-bottom: 1px solid var(--line-soft);
  backdrop-filter: blur(14px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 68px;
  padding: 10px 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--text);
  text-decoration: none;
  flex: 0 0 auto;
}
.brand:hover { text-decoration: none; }

.brand-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid var(--accent);
  color: var(--accent);
  font-family: var(--serif);
  font-size: 17px;
  letter-spacing: 0.02em;
}

.brand-text { display: grid; line-height: 1.15; }
.brand-name { font-family: var(--serif); font-size: 1.12rem; letter-spacing: 0.01em; }
.brand-role { color: var(--muted); font-size: 0.72rem; letter-spacing: 0.1em; text-transform: uppercase; }

.nav {
  display: flex;
  align-items: center;
  gap: 22px;
  margin-left: auto;
}
.nav a {
  color: var(--muted);
  font-size: 0.93rem;
  padding: 8px 0;
}
.nav a:hover { color: var(--text); text-decoration: none; }

.nav-drop { position: relative; display: flex; align-items: center; }
.nav-drop::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  height: 14px;
}
.nav-drop-panel {
  position: absolute;
  top: calc(100% + 12px);
  left: -14px;
  z-index: 90;
  display: none;
  min-width: 270px;
  padding: 10px;
  background: var(--surface-2);
  border: 1px solid var(--line);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
}
.nav-drop:hover .nav-drop-panel,
.nav-drop:focus-within .nav-drop-panel { display: block; }
.nav-drop-panel a {
  display: block;
  padding: 9px 12px;
  color: var(--text-soft);
  font-size: 0.9rem;
}
.nav-drop-panel a:hover { background: var(--surface); color: var(--text); text-decoration: none; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 12px 22px;
  border: 1px solid var(--accent);
  border-radius: var(--radius);
  background: var(--accent);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease;
}
.btn:hover { background: #eeb266; border-color: #eeb266; text-decoration: none; }

.btn-ghost {
  background: transparent;
  border-color: var(--line);
  color: var(--text);
}
.btn-ghost:hover { background: var(--surface-2); border-color: var(--muted); }

.btn-sm { min-height: 42px; padding: 10px 16px; font-size: 0.88rem; }

/* Menu mobile senza JavaScript */
.menu { display: none; position: relative; }
.menu summary {
  list-style: none;
  cursor: pointer;
  padding: 11px 14px;
  border: 1px solid var(--line);
  color: var(--text);
  font-size: 0.9rem;
  user-select: none;
}
.menu summary::-webkit-details-marker { display: none; }
.menu summary:hover { border-color: var(--muted); }
.menu-panel {
  position: absolute;
  right: 0;
  top: calc(100% + 10px);
  min-width: 230px;
  max-height: calc(100vh - 96px);
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 10px;
  background: var(--surface-2);
  border: 1px solid var(--line);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
}
.menu-panel a {
  display: block;
  padding: 10px 12px;
  color: var(--text-soft);
  font-size: 0.95rem;
}
.menu-panel a:hover { background: var(--surface); color: var(--text); text-decoration: none; }

/* ---------- Breadcrumb ---------- */

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 22px;
  color: var(--muted);
  font-size: 0.8rem;
}
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--text); }
.breadcrumb span[aria-current="page"] { color: var(--text-soft); }

/* ---------- Hero ---------- */

.hero {
  position: relative;
  overflow: hidden;
  padding: clamp(54px, 8vw, 92px) 0 clamp(46px, 7vw, 76px);
  border-bottom: 1px solid var(--line-soft);
  background:
    radial-gradient(900px 520px at 82% -10%, rgba(224, 160, 74, 0.16), transparent 62%),
    radial-gradient(620px 420px at 8% 110%, rgba(224, 160, 74, 0.06), transparent 70%);
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.55), transparent 78%);
}

.hero .container { position: relative; z-index: 1; }

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
  gap: clamp(32px, 5vw, 64px);
  align-items: end;
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 8px;
  color: var(--accent);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.eyebrow::before {
  content: "";
  width: 26px;
  height: 1px;
  background: currentColor;
  flex: 0 0 auto;
}

.lead {
  max-width: 36em;
  color: var(--text-soft);
  font-size: clamp(1.08rem, 1.8vw, 1.32rem);
  line-height: 1.55;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 26px;
}

.trust {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin: 26px 0 0;
  color: var(--muted);
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.trust span { display: inline-flex; align-items: center; gap: 8px; }
.trust span::before {
  content: "";
  width: 5px;
  height: 5px;
  background: var(--accent);
  border-radius: 50%;
}

/* Scheda servizio */
.sheet {
  padding: 24px;
  background: linear-gradient(180deg, var(--surface-2), var(--surface));
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.sheet-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}
.sheet-label {
  margin: 0;
  color: var(--muted);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.sheet-num {
  font-family: var(--serif);
  font-size: 1.6rem;
  color: var(--accent);
  line-height: 1;
}
.sheet dl { margin: 0; padding-top: 8px; }
.sheet-row {
  display: grid;
  grid-template-columns: 92px 1fr;
  gap: 12px;
  padding: 11px 0;
  border-bottom: 1px solid var(--line-soft);
}
.sheet-row:last-child { border-bottom: 0; }
.sheet dt {
  color: var(--muted);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding-top: 3px;
}
.sheet dd { margin: 0; font-size: 0.94rem; color: var(--text-soft); }

/* ---------- Sections ---------- */

.section {
  padding: clamp(48px, 7vw, 80px) 0;
  border-bottom: 1px solid var(--line-soft);
}

section[id] { scroll-margin-top: 86px; }
.section-alt { background: var(--surface); }

.section-head { max-width: 760px; margin-bottom: clamp(26px, 4vw, 40px); }
.section-head p { color: var(--muted); max-width: 62ch; }

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.card {
  padding: 24px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: transform 160ms ease, border-color 160ms ease;
}
.card:hover { transform: translateY(-2px); border-color: #3a4048; }
.card p { color: var(--muted); font-size: 0.95rem; }
.card-link { display: block; color: inherit; }
.card-link:hover { text-decoration: none; }
.card-link h3 a { color: var(--text); }
.card-link h3 a:hover { color: var(--accent); text-decoration: none; }
.card .card-kicker {
  display: block;
  margin-bottom: 10px;
  color: var(--accent);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

/* Processo */
.steps { counter-reset: step; border-top: 1px solid var(--line); }
.step {
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr);
  gap: 22px;
  padding: 24px 0;
  border-bottom: 1px solid var(--line);
}
.step::before {
  counter-increment: step;
  content: "0" counter(step);
  font-family: var(--serif);
  font-size: 2rem;
  line-height: 1;
  color: var(--accent);
}
.step h3 { margin-bottom: 0.3em; }
.step p { color: var(--muted); max-width: 68ch; }

/* Pubblico */
.tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.tag {
  padding: 7px 12px;
  border: 1px solid var(--line);
  color: var(--text-soft);
  font-size: 0.84rem;
  border-radius: 999px;
}

/* Prova / portfolio */
.proof {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
  gap: clamp(28px, 4vw, 48px);
  align-items: start;
}
.proof-card {
  padding: 24px;
  border: 1px solid var(--line);
  background: var(--surface-2);
}
.proof-card .eyebrow { margin-bottom: 14px; }

.author {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 24px 0;
}
.author img {
  width: 64px;
  height: 96px;
  object-fit: cover;
  border: 1px solid var(--line);
  flex: 0 0 auto;
}
.author p { margin: 0; }
.author-name { color: var(--text); font-weight: 600; font-size: 0.95rem; }
.author-role { color: var(--muted); font-size: 0.82rem; }
.proof-card ul { margin: 0; padding-left: 1.05em; }
.proof-card li { color: var(--text-soft); font-size: 0.94rem; }
.proof-card li::marker { color: var(--accent); }

.note {
  padding: 18px 20px;
  border-left: 3px solid var(--accent);
  background: rgba(224, 160, 74, 0.07);
  color: var(--text-soft);
  font-size: 0.95rem;
}
.note strong { color: var(--text); }

/* Elenco specifiche */
.spec-list {
  columns: 2;
  column-gap: 34px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.spec-list li {
  position: relative;
  break-inside: avoid;
  padding: 12px 0 12px 20px;
  border-bottom: 1px solid var(--line);
  color: var(--text-soft);
  font-size: 0.95rem;
}
.spec-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 22px;
  width: 8px;
  height: 1px;
  background: var(--accent);
}

/* FAQ */
.faq { border-top: 1px solid var(--line); }
.faq-item { padding: 22px 0; border-bottom: 1px solid var(--line); }
.faq-item h3 { margin-bottom: 0.35em; }
.faq-item p { color: var(--muted); max-width: 74ch; }

/* CTA */
.cta-band {
  background: var(--accent);
  color: var(--ink);
  padding: clamp(44px, 6vw, 68px) 0;
}
.cta-band .eyebrow { color: #4a3210; }
.cta-band .eyebrow::before { background: #4a3210; }
.cta-band h2 { color: var(--ink); }
.cta-band p { color: #3b2a10; max-width: 58ch; }
.cta-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  flex-wrap: wrap;
}
.cta-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.btn-dark {
  background: var(--ink);
  border-color: var(--ink);
  color: #fff8ec;
}
.btn-dark:hover { background: #2b2112; border-color: #2b2112; }
.btn-outline-dark {
  background: transparent;
  border-color: rgba(21, 16, 6, 0.45);
  color: var(--ink);
}
.btn-outline-dark:hover { background: rgba(21, 16, 6, 0.08); border-color: var(--ink); }

/* Correlati */
.related { background: var(--surface); }
.related .card { background: var(--bg); }
.related .card h3 a { color: var(--text); }
.related .card h3 a:hover { color: var(--accent); text-decoration: none; }

/* ---------- Footer ---------- */

.site-footer {
  padding: 48px 0 26px;
  background: #08090a;
  color: var(--muted);
  font-size: 0.9rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr;
  gap: 32px;
}
.footer-brand .brand { margin-bottom: 14px; }
.footer-brand p { max-width: 36ch; }
.footer-title {
  margin: 0 0 12px;
  color: var(--text);
  font-size: 0.76rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.footer-sub {
  margin: 18px 0 8px;
  color: var(--muted);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.footer-title + .footer-sub { margin-top: 0; }
.footer-list { list-style: none; margin: 0; padding: 0; }
.footer-list li { margin-bottom: 8px; }
.footer-list a { color: var(--muted); }
.footer-list a:hover { color: var(--text); }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 36px;
  padding-top: 18px;
  border-top: 1px solid #1c1f23;
  font-size: 0.8rem;
}
.footer-bottom p { margin: 0; }

/* ---------- Responsive ---------- */

@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr; align-items: start; }
  .sheet { max-width: 520px; }
  .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .proof { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  .nav { display: none; }
  .menu { display: block; }
  .header-inner { gap: 12px; }
  .brand-role { display: none; }
  .header-cta { display: none; }
  .footer-grid { grid-template-columns: 1fr; gap: 26px; }
}

@media (max-width: 600px) {
  body { font-size: 16px; }
  .container { width: calc(100% - 28px); }
  .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .step { grid-template-columns: 48px minmax(0, 1fr); gap: 14px; }
  .step::before { font-size: 1.5rem; }
  .sheet { padding: 18px; }
  .spec-list { columns: 1; }
  .cta-actions { width: 100%; }
  .cta-actions .btn { flex: 1 1 auto; }
  .faq-item { padding: 18px 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}

/* ---------- Case study ---------- */

.work-figure { margin: 0; }

.work-frame {
  display: block;
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #000;
}
.work-frame img { display: block; width: 100%; height: auto; }
.work-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(11, 12, 14, 0.72), rgba(11, 12, 14, 0) 42%);
  pointer-events: none;
}
.work-play {
  position: absolute;
  left: 18px;
  bottom: 18px;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 999px;
  background: rgba(11, 12, 14, 0.62);
  color: #fff;
  font-size: 0.88rem;
  font-weight: 600;
}
.work-frame:hover .work-play,
.work-frame:focus-visible .work-play {
  background: var(--accent);
  border-color: var(--accent);
  color: #141414;
}
.work-figure figcaption {
  margin-top: 12px;
  color: var(--muted);
  font-size: 0.84rem;
}

.work-card {
  padding: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.work-card-media { display: block; border-bottom: 1px solid var(--line); }
.work-card-media img { display: block; width: 100%; height: auto; }
.work-card-body { display: block; padding: 20px 22px 24px; }
.work-card-title {
  display: block;
  margin-bottom: 8px;
  font-family: var(--serif);
  font-size: 1.24rem;
  color: var(--text);
}
.work-card-text { display: block; color: var(--muted); font-size: 0.94rem; }
.work-card .card-kicker { margin-bottom: 8px; }

@media print {
  .site-header, .cta-band, .related, .site-footer, .hero-actions, .work-play { display: none; }
  body { background: #fff; color: #111; }
  .section { border-color: #ddd; }
}
