/* Top Service – sito pubblico. Font in locale, nessuna risorsa esterna. */
@font-face {
  font-family: "Raleway";
  src: url("../fonts/raleway-latin-wght-normal.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Open Sans";
  src: url("../fonts/open-sans-latin-wght-normal.woff2") format("woff2");
  font-weight: 300 800;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #0d0d0f;
  --bg-2: #141417;
  --bg-3: #1b1b20;
  --line: #2a2a31;
  --text: #ececef;
  --muted: #a6a6b0;
  --brand: #f2f23a;
  --brand-ink: #111111;
  --brand-soft: rgba(242, 242, 58, .12);
  --radius: 14px;
  --wrap: 1180px;
  --head-font: "Raleway", system-ui, sans-serif;
  --body-font: "Open Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --header-h: 76px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 12px); -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { animation: none !important; transition: none !important; } }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 1rem/1.65 var(--body-font);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--brand); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: #fff; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 3px; border-radius: 4px; }
h1, h2, h3 { font-family: var(--head-font); line-height: 1.15; margin: 0 0 .6em; letter-spacing: -.01em; }
p { margin: 0 0 1em; }
ul { margin: 0; padding: 0; list-style: none; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }
.wrap.narrow { max-width: 780px; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 200; background: var(--brand); color: var(--brand-ink); padding: 10px 16px; border-radius: 8px; font-weight: 700; }
.skip-link:focus { top: 12px; }
.icon { width: 1.15em; height: 1.15em; flex: none; }

/* Pulsanti */
.btn { display: inline-flex; align-items: center; gap: .6em; padding: .95em 1.6em; border-radius: 999px; font: 700 .95rem/1 var(--head-font); letter-spacing: .04em; text-transform: uppercase; text-decoration: none; transition: transform .2s, background .2s, color .2s; }
.btn-primary { background: var(--brand); color: var(--brand-ink); }
.btn-primary:hover { background: #fff; color: var(--brand-ink); transform: translateY(-2px); }

/* Barra superiore */
.topbar { background: #000; border-bottom: 1px solid var(--line); font-size: .82rem; }
.topbar-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 38px; }
.topbar-contacts { display: flex; flex-wrap: wrap; gap: 4px 22px; }
.topbar a { color: var(--muted); text-decoration: none; display: inline-flex; align-items: center; gap: 8px; }
.topbar a:hover { color: var(--brand); }
.topbar .icon { width: 15px; height: 15px; }
.social { display: flex; gap: 6px; }
.social a { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; color: var(--muted); }
.social a:hover { color: var(--brand-ink); background: var(--brand); }
.social .icon { width: 18px; height: 18px; }

/* Testata */
.site-header { position: sticky; top: 0; z-index: 100; background: rgba(13, 13, 15, .86); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid transparent; transition: border-color .3s, background .3s; }
.site-header.is-scrolled { border-bottom-color: var(--line); background: rgba(13, 13, 15, .96); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; min-height: var(--header-h); }
.brand { display: block; flex: none; }
.brand img { height: 52px; width: auto; border-radius: 4px; }
.brand span { font: 800 1.3rem var(--head-font); color: var(--text); }
.site-nav ul { display: flex; gap: 4px; }
.site-nav a { display: block; padding: 10px 14px; color: var(--text); text-decoration: none; font: 700 .8rem/1 var(--head-font); letter-spacing: .12em; text-transform: uppercase; border-radius: 999px; transition: color .2s, background .2s; }
.site-nav a:hover, .site-nav a.is-current { color: var(--brand-ink); background: var(--brand); }
.nav-toggle { display: none; background: none; border: 1px solid var(--line); color: var(--text); width: 46px; height: 46px; border-radius: 12px; cursor: pointer; place-items: center; }
.nav-toggle .icon { width: 24px; height: 24px; }
.nav-toggle .icon-close { display: none; }
.nav-toggle[aria-expanded="true"] .icon-open { display: none; }
.nav-toggle[aria-expanded="true"] .icon-close { display: block; }

@media (max-width: 900px) {
  :root { --header-h: 68px; }
  .brand img { height: 44px; }
  .js .nav-toggle { display: grid; }
  .js .site-nav { position: absolute; left: 0; right: 0; top: 100%; background: var(--bg-2); border-bottom: 1px solid var(--line); padding: 10px 20px 22px; display: none; }
  .js .site-nav.is-open { display: block; }
  .site-nav ul { flex-direction: column; }
  .js .site-nav a { padding: 15px 12px; font-size: .9rem; border-radius: 10px; }
  html:not(.js) .header-inner { flex-wrap: wrap; padding: 10px 20px; }
  html:not(.js) .site-nav ul { flex-direction: row; flex-wrap: wrap; }
}
@media (max-width: 560px) {
  .topbar-social { display: none; }
  .topbar-contacts a:first-child span { display: none; }
}

/* Copertina */
.hero { position: relative; min-height: calc(100svh - var(--header-h) - 38px); min-height: max(520px, calc(100svh - var(--header-h) - 38px)); display: flex; align-items: center; overflow: hidden; isolation: isolate; }
.hero-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; transform: scale(1.04); animation: hero-zoom 18s ease-out forwards; }
@keyframes hero-zoom { to { transform: scale(1); } }
.hero-shade { position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(0,0,0,.82) 0%, rgba(0,0,0,.55) 45%, rgba(0,0,0,.15) 100%), linear-gradient(0deg, var(--bg) 0%, transparent 30%); }
.hero-content { padding-top: 60px; padding-bottom: 90px; }
.hero-title { font-size: clamp(2.4rem, 6.4vw, 5rem); font-weight: 800; text-transform: uppercase; max-width: 13ch; letter-spacing: -.02em; margin-bottom: .35em; }
.hero-lead { font-size: clamp(1.05rem, 1.8vw, 1.35rem); color: #d8d8de; max-width: 38ch; margin-bottom: 2em; }
.hero-scroll { position: absolute; left: 50%; bottom: 22px; transform: translateX(-50%); width: 30px; height: 50px; border: 2px solid rgba(255,255,255,.5); border-radius: 20px; }
.hero-scroll-line { position: absolute; left: 50%; top: 9px; width: 4px; height: 9px; margin-left: -2px; border-radius: 2px; background: var(--brand); animation: scroll-dot 1.8s infinite; }
@keyframes scroll-dot { 0% { opacity: 0; transform: translateY(0); } 30% { opacity: 1; } 100% { opacity: 0; transform: translateY(16px); } }

/* Sezioni */
.section { padding: clamp(64px, 9vw, 110px) 0; }
.section:nth-of-type(even) { background: var(--bg-2); }
.section-head { max-width: 720px; margin-bottom: 44px; }
.section-title { font-size: clamp(1.9rem, 4vw, 2.9rem); font-weight: 800; text-transform: uppercase; }
.section-title::after { content: ""; display: block; width: 56px; height: 4px; margin-top: 18px; border-radius: 2px; background: var(--brand); }
.section-sub { color: var(--muted); font-size: 1.08rem; margin: 0; }
.prose { color: #d5d5dc; font-size: 1.05rem; }
.prose h2 { font-size: 1.5rem; margin-top: 1.6em; color: #fff; }
.prose h3 { font-size: 1.2rem; margin-top: 1.4em; }
.prose strong { color: #fff; }
.prose ul, .prose ol { margin: 0 0 1em; padding-left: 1.3em; }
.prose ul { list-style: disc; }
.prose ol { list-style: decimal; }
.prose li { margin-bottom: .35em; }
.prose blockquote { margin: 0 0 1.5em; padding: 14px 18px; border-left: 4px solid var(--brand); background: var(--brand-soft); border-radius: 0 10px 10px 0; }
.prose blockquote p { margin: 0; }
.prose code { background: var(--bg-3); padding: 2px 6px; border-radius: 5px; font-size: .9em; }

/* Contatti */
.section-contacts { background: linear-gradient(180deg, var(--bg) 0%, var(--bg-2) 100%); }
.section-contacts .wrap { display: grid; grid-template-columns: 1fr 1.25fr; gap: 48px; align-items: center; }
.contacts-intro .prose { font-size: 1.15rem; }
.contact-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
.contact-card { height: 100%; display: flex; flex-direction: column; gap: 4px; padding: 22px; background: var(--bg-3); border: 1px solid var(--line); border-radius: var(--radius); color: var(--text); text-decoration: none; transition: border-color .2s, transform .2s; }
a.contact-card:hover { border-color: var(--brand); transform: translateY(-3px); color: var(--text); }
.contact-icon { width: 28px; height: 28px; color: var(--brand); margin-bottom: 8px; }
.contact-label { color: var(--muted); font-size: .8rem; text-transform: uppercase; letter-spacing: .1em; }
.contact-value { font: 700 1.15rem/1.35 var(--head-font); overflow-wrap: anywhere; }
@media (max-width: 860px) { .section-contacts .wrap { grid-template-columns: 1fr; gap: 28px; } }
@media (max-width: 480px) { .contact-grid { grid-template-columns: 1fr; } }

/* Schede */
.card-grid { display: grid; gap: 20px; }
.card { background: var(--bg-3); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.card h3 { font-size: 1.25rem; font-weight: 800; }
.card p { color: var(--muted); margin: 0; }
.services-grid { grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }
.service-card { padding: 30px 26px; transition: border-color .25s, transform .25s; }
.service-card:hover { border-color: rgba(242, 242, 58, .5); transform: translateY(-4px); }
.service-icon { display: grid; place-items: center; width: 60px; height: 60px; margin-bottom: 22px; border-radius: 16px; background: var(--brand-soft); color: var(--brand); }
.service-icon .icon { width: 30px; height: 30px; }
.service-img { width: calc(100% + 52px); max-width: none; margin: -30px -26px 22px; aspect-ratio: 16/10; object-fit: cover; }

.equipment-grid { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.equipment-card { display: flex; flex-direction: column; }
.equipment-media { aspect-ratio: 5/4; overflow: hidden; background: #000; }
.equipment-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.equipment-card:hover .equipment-media img { transform: scale(1.05); }
.equipment-body { padding: 24px 24px 26px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.chips li { padding: 5px 12px; border: 1px solid var(--line); border-radius: 999px; font-size: .8rem; color: var(--text); background: var(--bg-2); }

.team-grid { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.team-card { padding: 0 0 24px; text-align: center; }
.team-photo { width: 100%; aspect-ratio: 1; object-fit: cover; margin-bottom: 18px; }
.team-card h3, .team-card p { padding: 0 18px; }
.team-role { color: var(--brand) !important; font-size: .85rem; text-transform: uppercase; letter-spacing: .1em; margin-bottom: 10px !important; }

/* Portfolio e gallerie */
.filters { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 28px; }
.filter { font: 700 .8rem/1 var(--head-font); letter-spacing: .1em; text-transform: uppercase; padding: 12px 20px; border-radius: 999px; border: 1px solid var(--line); background: transparent; color: var(--text); cursor: pointer; }
.filter:hover { border-color: var(--brand); }
.filter.is-active { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px; }
.photo-grid li[hidden] { display: none; }
.photo-grid a { display: block; aspect-ratio: 4/3; overflow: hidden; border-radius: 10px; background: #000; position: relative; }
.photo-grid img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s, opacity .3s; }
.photo-grid a:hover img { transform: scale(1.06); opacity: .85; }
.gallery-title { font-size: 1.4rem; font-weight: 800; text-transform: uppercase; margin: 56px 0 22px; }

/* Partner */
.partner-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 14px; }
.partner-grid a, .partner-grid div { display: block; border-radius: 12px; overflow: hidden; border: 1px solid var(--line); background: #fff; transition: transform .25s, border-color .25s; }
.partner-grid a:hover { transform: translateY(-4px); border-color: var(--brand); }
.partner-grid img { width: 100%; aspect-ratio: 32/44; object-fit: cover; }

/* Storie */
.stories-grid { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.story-card a { display: flex; flex-direction: column; height: 100%; color: var(--text); text-decoration: none; }
.story-media { position: relative; aspect-ratio: 16/9; overflow: hidden; background: #000; }
.story-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.story-card a:hover .story-media img { transform: scale(1.05); }
.story-badge { position: absolute; left: 14px; bottom: 14px; display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px 6px 8px; border-radius: 999px; background: rgba(0,0,0,.75); font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; }
.story-badge .icon { color: var(--brand); width: 16px; height: 16px; }
.story-body { padding: 24px; display: flex; flex-direction: column; flex: 1; }
.story-body time, .story-head time { color: var(--brand); font-size: .8rem; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; margin-bottom: 8px; display: block; }
.story-body p { margin-bottom: 18px; }
.link-more { margin-top: auto; display: inline-flex; align-items: center; gap: 8px; color: var(--brand); font: 700 .85rem var(--head-font); text-transform: uppercase; letter-spacing: .08em; }
.story-card a:hover .link-more .icon { transform: translateX(4px); }
.link-more .icon { transition: transform .2s; }

/* Pagine interne */
.page-sub .section:first-of-type { padding-top: 48px; }
.page-title { font-size: clamp(2rem, 5vw, 3.2rem); font-weight: 800; }
.page-meta { color: var(--muted); }
.back-link { display: inline-flex; align-items: center; gap: 8px; margin-bottom: 30px; color: var(--muted); text-decoration: none; font-size: .9rem; }
.back-link:hover { color: var(--brand); }
.story-head { margin-bottom: 28px; }
.other-stories { display: grid; gap: 10px; }
.other-stories a { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 18px; padding: 18px 22px; border-radius: 12px; background: var(--bg-3); border: 1px solid var(--line); color: var(--text); text-decoration: none; }
.other-stories a:hover { border-color: var(--brand); }
.other-stories time { color: var(--brand); font-size: .8rem; font-weight: 700; text-transform: uppercase; }
.other-stories span { font-weight: 600; }
@media (max-width: 560px) { .other-stories a { grid-template-columns: 1fr auto; } .other-stories time { grid-column: 1 / -1; } }

/* Video a richiesta */
.video { margin: 0 0 36px; }
.video-facade, .video iframe { display: block; position: relative; width: 100%; aspect-ratio: 16/9; border: 0; border-radius: var(--radius); overflow: hidden; background: #000; }
.video-facade img { width: 100%; height: 100%; object-fit: cover; opacity: .85; transition: opacity .3s; }
.video-facade:hover img { opacity: 1; }
.video-play { position: absolute; left: 50%; top: 50%; width: 84px; height: 84px; margin: -42px 0 0 -42px; border-radius: 50%; display: grid; place-items: center; background: var(--brand); color: var(--brand-ink); box-shadow: 0 10px 40px rgba(0,0,0,.5); transition: transform .2s; }
.video-play .icon { width: 36px; height: 36px; margin-left: 4px; }
.video-facade:hover .video-play { transform: scale(1.08); }
.video figcaption { margin-top: 10px; font-size: .82rem; color: var(--muted); }

/* Lightbox */
.lightbox { position: fixed; inset: 0; z-index: 300; background: rgba(0,0,0,.94); display: flex; align-items: center; justify-content: center; padding: 60px 70px; }
.lightbox[hidden] { display: none; }
.lightbox-figure { margin: 0; max-width: 100%; max-height: 100%; display: flex; flex-direction: column; align-items: center; }
.lightbox img { max-width: 100%; max-height: calc(100vh - 140px); width: auto; height: auto; border-radius: 8px; }
.lightbox-caption { margin-top: 12px; color: var(--muted); font-size: .9rem; text-align: center; }
.lightbox button { position: absolute; display: grid; place-items: center; width: 50px; height: 50px; border-radius: 50%; border: 0; background: rgba(255,255,255,.1); color: #fff; cursor: pointer; }
.lightbox button:hover { background: var(--brand); color: var(--brand-ink); }
.lightbox .icon { width: 26px; height: 26px; }
.lb-close { top: 16px; right: 16px; }
.lb-prev { left: 12px; top: 50%; margin-top: -25px; }
.lb-next { right: 12px; top: 50%; margin-top: -25px; }
@media (max-width: 640px) { .lightbox { padding: 60px 8px; } .lb-prev, .lb-next { top: auto; bottom: 14px; margin: 0; } .lb-prev { left: calc(50% - 60px); } .lb-next { right: calc(50% - 60px); } }

/* Piè di pagina */
.site-footer { background: #000; border-top: 1px solid var(--line); padding: 64px 0 0; font-size: .92rem; color: var(--muted); }
.footer-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 40px; }
.footer-name, .footer-title { font: 800 1rem var(--head-font); color: var(--text); text-transform: uppercase; letter-spacing: .1em; margin-bottom: 14px; }
.footer-legal li, .footer-list li { margin-bottom: 6px; }
.footer-list a, .footer-privacy a { color: var(--muted); }
.footer-list a:hover, .footer-privacy a:hover { color: var(--brand); }
.footer-social { margin: -6px 0 16px -8px; }
.footer-note { font-size: .82rem; }
.footer-bottom { border-top: 1px solid var(--line); margin-top: 48px; padding-top: 20px; padding-bottom: 24px; font-size: .82rem; }
.footer-bottom p { margin: 0; }
@media (max-width: 800px) { .footer-grid { grid-template-columns: 1fr; gap: 28px; } }

.page-404 { min-height: 50vh; }

/* Comparsa morbida delle sezioni */
.js .reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; }
.js .reveal.is-visible { opacity: 1; transform: none; }
