@import url('https://fonts.googleapis.com/css2?family=Syne:wght@400..800&display=swap');

/* Cambia questi due valori per aggiornare i colori del sito. */
:root {
  --color-yellow: #f2c94c;
  --color-blue: #4da3d9;
  --bg: #1a1d20;
  --bg-alt: #24282c;
  --surface: #2d3237;
  --text: #f3f2ed;
  --muted: #b2b5b7;
  --border: rgba(255, 255, 255, 0.13);
  --radius: 16px;
  --font: "syne", Arial, Helvetica, sans-serif;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 15px; scroll-behavior: smooth; scroll-padding-top: 86px; }
body {
  overflow-x: hidden;
  color: var(--text);
  background: var(--bg);
  font: 1rem/1.65 var(--font);
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; }

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: minmax(130px, 1fr) auto minmax(130px, 1fr);
  align-items: center;
  gap: 18px;
  min-height: 76px;
  padding: 10px 5vw;
  border-bottom: 1px solid var(--border);
  background: rgba(26, 29, 32, .97);
}
.topbar > .brand,
.topbar > .menu,
.topbar > .topbar-actions { align-self: center; }
.event-link {
  padding: 7px 15px;
  border: 1px solid var(--color-yellow);
  border-radius: 8px;
  color: var(--color-yellow);
  font-size: .9rem;
  font-weight: 700;
}
.event-link:hover { color: var(--bg); background: var(--color-yellow); }
.topbar-actions { grid-column: 3; grid-row: 1; display: flex; align-items: center; justify-self: end; gap: 10px; }
.ideas-top-link { display: inline-flex; align-items: center; justify-content: center; padding: 7px 15px; border: 1px solid var(--color-blue); border-radius: 8px; color: var(--color-blue); background: transparent; font-size: .9rem; font-weight: 700; transition: color .2s, background .2s; }
.ideas-top-link:hover { color: var(--bg); background: var(--color-blue); }
.ideas-top-link:focus-visible { outline: 3px solid var(--color-blue); outline-offset: 3px; }
.ideas-top-link svg { display: none; }
.brand { grid-column: 1; grid-row: 1; display: flex; align-items: center; justify-self: start; }
.brand-logo { width: auto; height: 42px; }
.menu { grid-column: 2; grid-row: 1; display: flex; flex-wrap: nowrap; align-items: center; justify-content: center; gap: clamp(7px, 1vw, 14px); align-self: center; }
.menu a { color: var(--muted); font-size: .85rem; white-space: nowrap; transition: color .2s; }
.menu a:hover, .menu a[aria-current="page"] { color: var(--color-yellow); }
.menu .home-nav-link { color: var(--muted); }
@media (min-width: 1101px) {
  .topbar { grid-template-columns: minmax(212px, 1fr) minmax(0, auto) minmax(212px, 1fr); gap: 12px; padding-right: 4vw; padding-left: 4vw; }
  .menu { gap: clamp(5px, .6vw, 10px); }
  .menu a { font-size: clamp(.78rem, .85vw, .85rem); }
}
.nav-toggle, .burger { display: none; }

.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  min-height: calc(100svh - 76px);
  display: grid;
  place-items: center;
  padding: 100px 6vw 60px;
  text-align: center;
  background: #181a1c;
}
.hero::before {
  position: absolute;
  z-index: 0;
  inset: -10% 0;
  content: "";
  background:
    linear-gradient(120deg, rgba(10, 10, 10, .72), rgba(10, 10, 10, .42)),
    url("../../images/mercato.webp") center / cover no-repeat;
  transform: translate3d(0, var(--parallax-offset, 0), 0) scale(1.08);
}
.hero-content { position: relative; z-index: 1; display: flex; width: min(1120px, 100%); flex-direction: column; justify-content: space-between; align-self: stretch; }
.hero-top, .hero-bottom { width: 100%; }
.hero-top { margin-bottom: 0; }
.hero-brand { margin-bottom: 8px; color: var(--text); font-size: .9rem; font-weight: 700; letter-spacing: .12em; }
.hero-top .eyebrow { margin-bottom: 18px; }
.hero-bottom { max-width: 720px; margin: 0 auto; }
.eyebrow {
  margin-bottom: 16px;
  color: var(--color-yellow);
  font-size: .82rem;
  font-weight: 700;
  letter-spacing: .15em;
  text-transform: uppercase;
}
.hero h1 {
  font-size: clamp(2.4rem, 6vw, 4.4rem);
  line-height: 1.05;
  letter-spacing: -.04em;
}
.hero-bottom p { max-width: 620px; margin: 0 auto; color: rgba(255,255,255,.88); font-size: 1.12rem; }
.hero-button { margin-top: 22px; }
.hero-tools-link { display: block; width: fit-content; margin: 10px auto 0; color: rgba(255,255,255,.82); font-size: .82rem; text-decoration: underline; text-underline-offset: 4px; }
.hero-tools-link:hover { color: var(--color-yellow); }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 10px 20px;
  border: 1px solid transparent;
  border-radius: 8px;
  font-weight: 700;
  transition: transform .2s, background .2s, color .2s;
}
.btn:hover { transform: translateY(-2px); }
.btn-yellow { color: #141414; background: var(--color-yellow); }
.btn-yellow:hover { background: #ffdc72; }
.btn-blue { color: #101518; background: var(--color-blue); }
.btn-blue:hover { background: #75c4f1; }
.btn-outline { border-color: var(--border); border-radius: 8px; color: var(--text); }
.btn-outline:hover { border-color: var(--color-blue); color: var(--color-blue); }
.btn[href^="mailto:"], .btn[href*="instagram.com"] { border-radius: 999px; }
.text-link { border: 0; border-radius: 0; color: var(--color-blue); font-weight: 700; text-decoration: underline; text-underline-offset: 4px; cursor: pointer; }
.text-link:hover { color: var(--color-yellow); }

.section { padding: 82px 5vw; }
.section-alt { background: var(--bg-alt); }
.container { width: min(1120px, 100%); margin: 0 auto; }
.narrow { max-width: 760px; }
.center { text-align: center; }
.section h2, .page-heading h1 {
  margin-bottom: 18px;
  font-size: clamp(1.9rem, 4vw, 3rem);
  line-height: 1.15;
  letter-spacing: -.025em;
}
.section h2::after, .page-heading h1::after {
  content: "";
  display: block;
  width: 48px;
  height: 4px;
  margin-top: 14px;
  border-radius: 4px;
  background: var(--color-yellow);
}
.center h2::after, .page-heading.center h1::after { margin-right: auto; margin-left: auto; }
.muted { color: var(--muted); }
.section-intro { max-width: 700px; color: var(--muted); }

.service-grid, .what-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 32px;
}
.service-card, .what-card {
  padding: 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
.service-grid { grid-template-columns: 1fr; gap: 0; border-top: 1px solid var(--border); }
.service-card { padding: 28px 4px; border: 0; border-bottom: 1px solid var(--border); border-radius: 0; background: transparent; }
.service-grid .service-card:last-child { border-bottom: 0; }
.service-card h3, .what-card h3 { margin-bottom: 8px; font-size: 1.15rem; }
.service-card h2 { margin-bottom: 8px; font-size: clamp(1.5rem, 2.8vw, 1.85rem); }
.service-card h2::after { display: none; }
.service-card-3d h2 { color: var(--color-blue); }
.service-card-laser h2 { color: var(--color-yellow); }
.service-card p, .what-card p { color: var(--muted); }
.service-card .photos,
.album-photos { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 190px), 1fr)); grid-auto-rows: 1px; grid-auto-flow: row dense; align-items: start; gap: 8px; margin-top: 16px; }
.service-card .photos { background: var(--bg); }
.album-photos { background: var(--bg-alt); }
.service-card .photos img,
.album-photos img { grid-column-end: span 1; grid-row-end: span 1; width: 100%; height: 100%; margin: 0; object-fit: cover; cursor: zoom-in; }
.service-card .photos img[hidden],
.album-photos img[hidden] { display: none; }
.album-photos img { transition: filter .2s ease; }
.album-photos img:hover { filter: brightness(1.08); }
.album-section { background: var(--bg-alt); }
.gallery-expand { margin-top: 14px; }
.gallery-expand summary { display: inline-flex; cursor: pointer; list-style: none; }
.gallery-expand summary::-webkit-details-marker { display: none; }
.gallery-expand summary::after { content: "+"; margin-left: 8px; }
.gallery-expand[open] summary::after { content: "−"; }
.gallery-expand .photos { margin-top: 0; }
.album-expand:not([open]) .album-photos { display: none; }
.gallery-expand .album-photos { margin-top: 16px; }
.album-expand .album-open-button { display: inline-flex; width: fit-content; min-height: 46px; align-items: center; justify-content: center; gap: 10px; margin: 22px auto 0; padding: 10px 18px; border: 1px solid transparent; border-radius: 8px; color: #101518; background: var(--color-blue); font-size: .9rem; font-weight: 700; list-style: none; cursor: pointer; transition: transform .2s, background .2s; }
.album-expand .album-open-button:hover { background: #75c4f1; }
.album-expand .album-open-button:focus-visible { outline: 3px solid var(--color-yellow); outline-offset: 3px; }
.album-expand .album-open-button::after { content: "↓"; margin-left: 2px; color: #101518; font-size: 1rem; }
.album-expand[open] .album-open-button::after { content: "↑"; }
.album-expand .album-load-more { justify-self: center; min-height: 46px; margin: 20px auto 0; padding: 10px 20px; border: 1px solid var(--color-blue); border-radius: 999px; color: var(--text); background: var(--surface); font: inherit; font-weight: 700; cursor: pointer; }
.album-expand .album-load-more:hover { color: #fff; background: #1d668b; }
.album-expand .album-load-more:focus-visible { outline: 3px solid var(--color-yellow); outline-offset: 3px; }
.album-expand .album-load-more[hidden] { display: none; }
.model-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 190px), 1fr)); align-items: start; gap: 0; margin: 28px 0; }
.model-gallery figure { min-width: 0; aspect-ratio: 4 / 3; }
.model-gallery img { width: 100%; height: 100%; aspect-ratio: 4 / 3; object-fit: cover; cursor: zoom-in; }
.model-gallery figcaption { display: none; }
.what-card { border-radius: 0; background: transparent; }
.what-grid { gap: 0 32px; border-top: 1px solid var(--border); }
.what-card { padding: 22px 4px; border: 0; border-bottom: 1px solid var(--border); }
.what-page .page-heading { padding-top: 88px; padding-bottom: 56px; background: radial-gradient(ellipse at 50% 0, rgba(77,163,217,.12), transparent 68%); }
.what-page .page-heading > p { max-width: 660px; font-size: 1.08rem; line-height: 1.7; }
.what-page .what-grid { gap: 18px; margin-top: 8px; border: 0; }
.what-page .what-card { padding: 26px; border: 1px solid var(--border); border-top: 3px solid var(--color-yellow); border-radius: var(--radius); background: linear-gradient(145deg, var(--surface), rgba(36,40,44,.68)); transition: transform .2s, border-color .2s; }
.what-page .what-card:nth-child(even) { border-top-color: var(--color-blue); }
.what-page .what-card:hover { transform: translateY(-4px); border-right-color: rgba(255,255,255,.28); border-bottom-color: rgba(255,255,255,.28); border-left-color: rgba(255,255,255,.28); }
.what-page .what-card-icon { display: grid; width: 48px; height: 48px; place-items: center; margin-bottom: 18px; border: 1px solid rgba(241,193,78,.28); border-radius: 14px; color: var(--color-yellow); background: rgba(241,193,78,.08); }
.what-page .what-card-icon svg { width: 25px; height: 25px; fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.6; }
.what-page .what-card:nth-child(even) .what-card-icon { border-color: rgba(77,163,217,.3); color: var(--color-blue); background: rgba(77,163,217,.08); }
.what-page .what-card-number { display: block; margin-bottom: 12px; color: var(--color-yellow); font-size: .75rem; font-weight: 700; letter-spacing: .12em; }
.what-page .what-card:nth-child(even) .what-card-number { color: var(--color-blue); }
.what-page .what-card h3 { margin-bottom: 10px; font-size: clamp(1.3rem, 2vw, 1.45rem); }
.what-page .what-card p { line-height: 1.65; }
.what-page .page-prose { margin-top: 58px; padding-top: 34px; border-top: 1px solid var(--border); }
.what-page .page-prose h2 { margin-bottom: 14px; }
.what-page .page-prose p { line-height: 1.75; }
.what-page .page-prose .inline-actions { margin-top: 22px; }
.what-page .what-feature { display: grid; grid-template-columns: minmax(0, 1fr) minmax(240px, .75fr); gap: 30px; align-items: center; width: min(940px, 100%); margin: 28px auto 0; text-align: left; }
.what-page .what-feature img { width: 100%; max-height: 250px; border-radius: var(--radius); object-fit: cover; }
.what-page .what-feature figcaption { color: var(--muted); font-size: .85rem; }
.what-page .what-feature p { margin-bottom: 8px; font-size: 1.1rem; line-height: 1.65; }
.combined-placeholders { display: grid !important; grid-template-columns: repeat(2, minmax(0, 1fr)) !important; gap: 10px !important; margin-top: 16px !important; background: transparent !important; }
.project-placeholder { display: grid; min-height: 130px; aspect-ratio: 4 / 3; place-items: center; padding: 18px; border: 1px dashed rgba(255,255,255,.28); border-radius: 12px; color: var(--muted); background: linear-gradient(145deg, #30363b, #202529); text-align: center; font-size: .88rem; }
.service-machine-section { margin: 58px 0 0; padding: 34px 0; border-top: 1px solid var(--border); }
.service-machine-section > h2 { margin-bottom: 8px; font-size: clamp(1.6rem, 3vw, 2.1rem); }
.service-machine-section > p { max-width: 760px; color: var(--muted); }
.service-machine-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; margin-top: 24px; }
.service-machine-card { padding: 24px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); }
.service-machine-card h3 { margin-bottom: 8px; font-size: 1.35rem; }
.service-machine-card p, .service-machine-card li { color: var(--muted); }
.service-machine-card ul { margin: 12px 0 0; padding-left: 20px; }
.service-machine-card li + li { margin-top: 5px; }
.service-machine-card a { display: inline-flex; margin-top: 16px; color: var(--color-blue); font-weight: 700; }
.service-machine-card a:hover { color: var(--color-yellow); }
.technical-note { margin-top: 14px; color: var(--muted); font-size: .85rem; }
.technical-note a { color: var(--color-blue); text-decoration: underline; text-underline-offset: 3px; }
.material-section { margin-top: 42px; }
.material-section h2 { margin-bottom: 8px; }
.material-section > p { max-width: 780px; color: var(--muted); }
.material-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; margin-top: 20px; }
.material-item { min-width: 0; overflow: hidden; border: 1px solid var(--border); border-radius: 12px; background: #1d2226; }
.material-item summary { display: flex; min-height: 82px; align-items: center; gap: 16px; padding: 14px 18px; cursor: pointer; list-style: none; }
.material-item summary::-webkit-details-marker { display: none; }
.material-item summary::after { content: "+"; margin-left: auto; color: var(--color-yellow); font-size: 1.35rem; }
.material-item[open] summary::after { content: "−"; }
.material-item summary:focus-visible { outline: 2px solid var(--color-yellow); outline-offset: -3px; }
.material-item:nth-child(1) summary { background: linear-gradient(105deg, rgba(125,82,46,.42), rgba(70,53,39,.2) 42%, rgba(29,34,38,.96) 88%); }
.material-item:nth-child(2) summary { background: linear-gradient(105deg, rgba(72,113,126,.38), rgba(48,67,73,.2) 42%, rgba(29,34,38,.96) 88%); }
.material-item:nth-child(3) summary { background: linear-gradient(105deg, rgba(145,153,158,.32), rgba(74,82,87,.2) 42%, rgba(29,34,38,.96) 88%); }
.material-item:nth-child(4) summary { background: linear-gradient(105deg, rgba(137,103,63,.38), rgba(75,61,44,.2) 42%, rgba(29,34,38,.96) 88%); }
.material-item:nth-child(5) summary { background: linear-gradient(105deg, rgba(71,119,128,.34), rgba(48,72,76,.18) 42%, rgba(29,34,38,.96) 88%); }
.material-item:nth-child(6) summary { background: linear-gradient(105deg, rgba(119,119,115,.36), rgba(67,69,67,.2) 42%, rgba(29,34,38,.96) 88%); }
.material-item:nth-child(7) summary { background: linear-gradient(105deg, rgba(116,121,125,.3), rgba(65,69,72,.18) 42%, rgba(29,34,38,.96) 88%); }
.material-swatch { display: block; flex: 0 0 48px; width: 48px; height: 48px; border: 1px solid rgba(255,255,255,.2); border-radius: 12px; box-shadow: inset 0 1px 5px rgba(0,0,0,.25); filter: brightness(.78) saturate(.8); }
.material-swatch-wood { background: repeating-linear-gradient(8deg, #aa7544 0 4px, #c99a62 5px 9px, #895c36 10px 12px); }
.material-swatch-acrylic { background: linear-gradient(135deg, #f3f5f4 0%, #a9d8db 48%, #789eb3 49%, #d7eff0 100%); }
.material-swatch-metal { background: linear-gradient(135deg, #747b7f, #e1e4e3 38%, #8d969b 68%, #cbd0d1); }
.material-swatch-card { background: repeating-linear-gradient(135deg, #b88855 0 5px, #e0c49a 6px 11px); }
.material-swatch-glass { background: linear-gradient(135deg, rgba(132,193,201,.32), rgba(235,247,247,.82), rgba(90,145,155,.44)); }
.material-swatch-stone { background: radial-gradient(circle at 30% 25%, #c3c0b9, #777a7b 58%, #494d4e); }
.material-swatch-metallic { background: linear-gradient(135deg, #52575b, #b8bdc0 34%, #666c70 65%, #e1e3e3); }
.material-item-title { display: grid; gap: 2px; }
.material-item-title strong { font-size: clamp(1.25rem, 2.5vw, 1.6rem); letter-spacing: -.02em; }
.material-item-title small { color: var(--muted); font-size: .78rem; }
.material-detail { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; padding: 16px; border-top: 1px solid var(--border); }
.material-detail p { color: var(--muted); font-size: .9rem; line-height: 1.5; }
.material-detail dl { display: grid; gap: 5px; margin-top: 9px; font-size: .82rem; }
.material-detail dl div { display: grid; grid-template-columns: 90px 1fr; gap: 8px; }
.material-detail dt { color: var(--text); font-weight: 700; }
.material-detail dd { margin: 0; color: var(--muted); }
.ideas-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.idea-categories { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin: 0 0 54px; }
.idea-categories a { padding: 8px 14px; border: 1px solid var(--border); border-radius: 999px; color: var(--text); background: var(--surface); font-size: .9rem; transition: border-color .2s, color .2s, background .2s; }
.idea-categories a:hover, .idea-categories a:focus-visible { border-color: var(--color-blue); color: var(--color-blue); background: rgba(77,163,217,.08); }
.idea-categories a:focus-visible { outline: 2px solid var(--color-blue); outline-offset: 3px; }
.idea-category { margin-top: 52px; scroll-margin-top: 96px; }
.idea-category > h2 { margin-bottom: 20px; font-size: clamp(1.5rem, 3vw, 2rem); text-align: center; }
.idea-category > h2::after { margin-right: auto; margin-left: auto; }
.idea-category .ideas-grid { grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 440px)); justify-content: center; }
.idea-card { display: flex; min-width: 0; flex-direction: column; overflow: hidden; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); transition: transform .2s, border-color .2s; }
.idea-card:hover { transform: translateY(-4px); border-color: var(--color-blue); }
.idea-card img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.idea-card-copy { display: flex; flex: 1; flex-direction: column; align-items: flex-start; padding: 20px; }
.idea-card-copy h2, .idea-card-copy h3 { margin-bottom: 8px; font-size: 1.25rem; }
.idea-card-copy p { margin-bottom: 16px; color: var(--muted); }
.idea-card-copy a { margin-top: auto; color: var(--color-yellow); font-weight: 700; }
.idea-card-text { min-height: 260px; background: radial-gradient(ellipse at 85% 15%, rgba(77,163,217,.16), transparent 55%), var(--surface); }
.ideas-note { margin-top: 42px; padding: 24px; border-left: 3px solid var(--color-blue); background: var(--surface); }
.ideas-note p { color: var(--muted); }
#novita .container, #album .container { text-align: center; }
#novita h2::after, #album h2::after { margin-right: auto; margin-left: auto; }
#novita .news-item { width: min(760px, 100%); margin: 28px auto 0; text-align: center; }
#novita .news-item .inline-actions { justify-content: center; }
#album .section-intro { margin-right: auto; margin-left: auto; }
#album .album-expand { display: grid; justify-items: center; }

.machines { padding: 0; }
.machine-panel {
  position: relative;
  min-height: 100svh;
  display: grid;
  place-items: center;
  overflow: hidden;
  isolation: isolate;
  text-align: center;
}
.machine-image {
  position: absolute;
  z-index: 0;
  top: -10%;
  left: 0;
  width: 100%;
  height: 120%;
  object-fit: cover;
  pointer-events: none;
  transform: translate3d(0, var(--parallax-offset, 0), 0) scale(1.08);
}
.machine-panel::after { position: absolute; z-index: 1; inset: 0; content: ""; background: linear-gradient(120deg, rgba(8,10,12,.76), rgba(8,10,12,.32)); }
.machine-copy { position: relative; z-index: 2; max-width: 720px; padding: 50px 24px; }
.machine-copy h2 { margin-bottom: 14px; font-size: clamp(2.8rem, 8vw, 6rem); line-height: 1; }
.machine-copy p { margin: 0 auto 24px; color: rgba(255,255,255,.86); font-size: 1.1rem; }
.machine-panel .eyebrow { color: var(--color-blue); }
.machine-panel:first-child .machine-copy h2 { color: var(--color-yellow); }
.machine-panel:nth-child(2) .machine-copy h2 { color: var(--color-blue); }

.events-section {
  color: #151718;
  background: linear-gradient(130deg, var(--color-yellow), var(--color-blue));
}
.events-section .eyebrow { color: #17191b; }
.events-section h2::after { background: #17191b; }
.events-section .section-intro { color: rgba(20,22,23,.78); }
.event-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 56px; margin-top: 36px; }
.event-card { padding: 12px 30px; }
.event-card + .event-card { border-left: 1px solid rgba(0,0,0,.42); }
.event-date { color: #18212a; font-size: .88rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.event-card h3 { margin-top: 6px; font-size: 1.45rem; }
.news-item { max-width: 760px; padding: 18px 0 0; border-top: 1px solid var(--border); }
.news-item h3 { margin-bottom: 6px; color: var(--color-blue); font-size: 1.15rem; }
.news-item p { color: var(--muted); }

.place-contact { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0; text-align: center; }
.place-contact > div { padding: 0 36px; }
.place-contact > div + div { border-left: 1px solid var(--border); }
.place-contact h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); }
.place-contact h2::after { margin-right: auto; margin-left: auto; }
.contact-list { display: grid; gap: 10px; margin-top: 18px; list-style: none; }
a[href^="mailto:"]:not(.btn),
a[href*="instagram.com"]:not(.btn),
.location-link { color: inherit; text-decoration: underline; text-underline-offset: 4px; }
.contact-list a:hover { text-decoration-thickness: 2px; }
.inline-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 20px; }

.site-footer { padding: 42px 5vw 24px; border-top: 1px solid var(--border); background: #0c0e0f; }
.site-footer-inner { display: grid; grid-template-columns: 1fr 2fr; gap: 28px 48px; width: min(1120px, 100%); margin: 0 auto; }
.site-footer-brand p { max-width: 420px; margin: 8px 0; color: var(--muted); font-size: .9rem; }
.site-footer-brand > a:first-child { font-size: 1.15rem; font-weight: 700; }
.site-footer-logo { display: inline-flex; flex: 0 0 38px; width: 38px; height: 38px; margin-left: auto; }
.site-footer-logo img { width: 100%; height: 100%; object-fit: contain; }
.site-footer-links { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-content: start; gap: 10px 20px; }
.site-footer-links a { color: var(--muted); font-size: .92rem; }
.site-footer-links a:hover { color: var(--color-yellow); }
.site-footer-links a[href="../impressum/"] { grid-column: 1 / -1; padding-top: 12px; border-top: 1px solid var(--border); }
.site-footer-copy { display: flex; grid-column: 1 / -1; align-items: center; padding-top: 16px; border-top: 1px solid var(--border); color: var(--muted); font-size: .82rem; }

.page-main { min-height: 60vh; }
.page-heading { padding: 74px 5vw 30px; text-align: center; }
.page-heading h1 { margin-bottom: 12px; }
.page-heading h1::after { margin-right: auto; margin-left: auto; }
.page-heading > p { max-width: 720px; margin: 0 auto; color: var(--muted); }
.page-content { padding: 24px 5vw 80px; }
.machine-details { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; align-items: start; }
.machine-photo-placeholder, .product-photo-placeholder {
  display: grid;
  min-height: 300px;
  place-items: center;
  padding: 20px;
  border: 1px dashed rgba(255,255,255,.3);
  border-radius: var(--radius);
  color: var(--muted);
  background: linear-gradient(135deg, #292e32, #1d2226);
  text-align: center;
}
.machine-details { gap: 0; align-items: stretch; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.machine-details > .machine-photo { width: 100%; height: 100%; max-height: none; min-height: 380px; border-radius: 0; object-fit: cover; }
.machine-facts { padding: 28px clamp(20px, 4vw, 48px); border: 0; border-left: 1px solid var(--border); border-radius: 0; background: transparent; }
.machine-facts h2, .machine-facts h3 { margin-bottom: 12px; }
.machine-facts ul { padding-left: 20px; color: var(--muted); }
.machine-facts li + li { margin-top: 7px; }
.machine-page-3d .page-heading h1::after { background: var(--color-blue); }
.machine-page-3d .machine-facts h2,
.machine-page-3d .machine-facts h3,
.machine-page-3d .machine-model-section h2 { color: var(--color-blue); }
.machine-page-laser .page-heading h1::after { background: var(--color-yellow); }
.machine-page-laser .machine-facts h2,
.machine-page-laser .machine-facts h3 { color: var(--color-yellow); }
.machine-model-section { margin-top: 30px; padding: 28px 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.machine-model-section > p { max-width: 760px; color: var(--muted); }
.machine-model-gallery { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: 1px; margin-top: 18px; }
.machine-model-gallery img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; cursor: zoom-in; }
.role-3d { color: var(--color-blue); font-weight: 700; }
.role-laser { color: var(--color-yellow); font-weight: 700; }
.page-cta { margin-top: 30px; }
.product-filters { position: relative; display: flex; justify-content: center; margin: 12px auto 30px; }
.filter-menu { position: relative; }
.filter-menu summary { display: flex; align-items: center; gap: 9px; padding: 9px 16px; border: 1px solid var(--border); border-radius: 8px; color: var(--text); background: var(--surface); cursor: pointer; list-style: none; }
.filter-menu summary::-webkit-details-marker { display: none; }
.filter-menu summary svg { width: 18px; height: 18px; }
.filter-menu[open] summary, .filter-menu summary:hover { border-color: var(--color-yellow); color: var(--color-yellow); }
.filter-options { position: absolute; z-index: 5; top: calc(100% + 8px); left: 50%; display: grid; min-width: 190px; padding: 7px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); box-shadow: 0 12px 30px rgba(0,0,0,.35); transform: translateX(-50%); }
.filter-button { padding: 8px 15px; border: 1px solid var(--border); border-radius: 7px; color: var(--text); background: var(--surface); cursor: pointer; }
.filter-options .filter-button { border: 0; border-radius: 7px; text-align: left; }
.filter-options .filter-button:hover { color: var(--color-yellow); background: rgba(255,255,255,.06); }
.filter-button[aria-pressed="true"], .filter-button:hover { border-color: var(--color-yellow); color: #171717; background: var(--color-yellow); }
.filter-menu[data-active-filter="incisione"] summary,
.filter-menu[data-active-filter="taglio-laser"] summary,
.filter-menu[data-active-filter="macchina-laser"] summary,
.filter-menu[data-active-filter="incisione"] .filter-button[aria-pressed="true"],
.filter-menu[data-active-filter="taglio-laser"] .filter-button[aria-pressed="true"],
.filter-menu[data-active-filter="macchina-laser"] .filter-button[aria-pressed="true"] {
  border-color: var(--color-yellow);
  color: #171717;
  background: var(--color-yellow);
}
.filter-menu[data-active-filter="stampa3d"] summary,
.filter-menu[data-active-filter="modellizzazione"] summary,
.filter-menu[data-active-filter="stampa3d"] .filter-button[aria-pressed="true"],
.filter-menu[data-active-filter="modellizzazione"] .filter-button[aria-pressed="true"] {
  border-color: var(--color-blue);
  color: #171717;
  background: var(--color-blue);
}
.product-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 440px), 1fr)); column-gap: 32px; }
.empty-products { padding: 28px 0; color: var(--muted); text-align: center; }
.empty-products a { color: var(--color-blue); text-decoration: underline; text-underline-offset: 3px; }
.product-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  grid-template-rows: minmax(0, 1fr);
  gap: 0;
  align-items: stretch;
  min-width: 0;
  height: clamp(190px, 22vw, 250px);
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}
.product-card > * { min-height: 0; }
.product-card[hidden] { display: none; }
.product-card-image-link { display: flex; height: 100%; min-width: 0; align-items: center; justify-content: center; overflow: hidden; padding: 8px 12px; }
.product-card .product-image { width: auto; height: auto; max-width: 100%; max-height: 100%; border-radius: var(--radius); object-fit: contain; }
.product-card-copy { display: flex; min-width: 0; flex-direction: column; justify-content: center; align-self: stretch; padding: 8px 12px; }
.product-card-image-link:focus-visible, .product-card-copy:focus-visible { outline: 2px solid var(--color-yellow); outline-offset: 4px; }
.product-card-copy:hover h2 { color: var(--color-blue); }
.product-card-copy p { color: var(--muted); font-size: clamp(.82rem, 1.1vw, .95rem); line-height: 1.4; }
.product-card-copy h2 { margin: 4px 0; font-size: clamp(.9rem, 1.25vw, 1.08rem); line-height: 1.25; }
.product-card-copy .product-summary { display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.product-price { margin-top: 10px; color: var(--color-yellow); font-weight: 700; }
.product-card-copy .product-price { color: var(--color-yellow); }
.product-card-copy .product-short-price { margin-top: 5px; font-size: .92rem; font-weight: 700; }
.product-detail { display: grid; grid-template-columns: minmax(240px, .9fr) 1.1fr; gap: 32px; align-items: start; }
.product-detail-gallery { grid-column: 1; grid-row: 1; }
.product-detail-copy { grid-column: 2; grid-row: 1; }
.product-detail-copy h1 { margin: 8px 0; font-size: clamp(2rem, 5vw, 3.2rem); line-height: 1.12; }
.product-detail-copy > p { color: var(--muted); }
.product-specs { margin: 22px 0; border-top: 1px solid var(--border); }
.product-spec { display: grid; grid-template-columns: minmax(110px, .7fr) 1.3fr; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--border); }
.product-spec dt { color: var(--muted); }
.product-spec dd { margin: 0; }
.product-detail-copy .product-price { margin-bottom: 20px; font-size: 1.1rem; }
.product-variants-title { margin: 20px 0 10px; font-size: 1rem; }
.product-variants { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; max-width: 420px; }
.product-variant[hidden] { display: none; }
.product-variant { display: grid; min-width: 0; gap: 7px; padding: 8px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); color: var(--text); font: inherit; text-align: center; cursor: pointer; }
.product-variant img { width: 100%; aspect-ratio: 1; border-radius: calc(var(--radius) / 2); object-fit: cover; }
.product-variant span { font-size: .82rem; line-height: 1.25; }
.product-variant .product-variant-price { color: var(--color-yellow); font-weight: 700; }
.product-variant[aria-pressed="true"] { border-color: var(--color-yellow); box-shadow: 0 0 0 1px var(--color-yellow); }
.product-variant:focus-visible { outline: 2px solid var(--color-yellow); outline-offset: 3px; }
.product-variant-selection { margin-top: 18px; }
.product-variant-pagination { display: flex; max-width: 420px; align-items: center; justify-content: space-between; gap: 12px; margin-top: 12px; padding: 8px 10px; border: 1px solid var(--border); border-radius: 12px; background: var(--bg-alt); }
.product-variant-page-button { display: grid; width: 38px; height: 38px; place-items: center; border: 1px solid var(--border); border-radius: 10px; color: var(--color-blue); background: var(--surface); font-size: 1.2rem; cursor: pointer; }
.product-variant-page-button:hover:not(:disabled) { border-color: var(--color-blue); background: rgba(77,163,217,.12); }
.product-variant-page-button:disabled { opacity: .4; cursor: not-allowed; }
.product-variant-page-button:focus-visible { outline: 2px solid var(--color-blue); outline-offset: 2px; }
.product-variant-page-status { color: var(--muted); font-size: .85rem; }
.product-detail-gallery { min-width: 0; }
.product-gallery-stage { display: grid; width: 100%; height: clamp(280px, 42vw, 560px); place-items: center; }
.product-detail-image-frame { display: grid; width: 100%; max-width: 100%; height: auto; max-height: 100%; aspect-ratio: 4 / 3; place-items: center; overflow: hidden; border-radius: var(--radius); background: var(--surface); }
.product-detail-image-frame.is-landscape { width: 100%; height: auto; aspect-ratio: 4 / 3; }
.product-detail-image-frame.is-portrait { width: auto; height: 100%; aspect-ratio: 3 / 4; }
.product-detail-image-frame.is-square { width: min(100%, 560px); height: auto; aspect-ratio: 1 / 1; }
.product-detail-image { width: 100%; height: 100%; border-radius: var(--radius); object-fit: contain; }
.product-gallery-controls { display: grid; grid-template-columns: 42px minmax(0, 1fr) 42px; align-items: center; gap: 10px; margin-top: 10px; }
.product-gallery-button { display: grid; width: 38px; height: 38px; place-items: center; border: 1px solid var(--border); border-radius: 50%; color: var(--text); background: var(--surface); font-size: 1.7rem; line-height: 1; cursor: pointer; }
.product-gallery-button:hover:not(:disabled) { border-color: var(--color-yellow); color: var(--color-yellow); }
.product-gallery-button:disabled { opacity: .4; cursor: not-allowed; }
.product-gallery-button:focus-visible { outline: 2px solid var(--color-yellow); outline-offset: 2px; }
.product-gallery-thumbnails { display: flex; min-width: 0; gap: 8px; overflow-x: auto; scrollbar-color: var(--border) transparent; }
.product-gallery-thumbnail { display: grid; flex: 0 0 58px; width: 58px; height: 58px; padding: 3px; place-items: center; overflow: hidden; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); cursor: pointer; }
.product-gallery-thumbnail[aria-current="true"] { border-color: var(--color-yellow); box-shadow: 0 0 0 1px var(--color-yellow); }
.product-gallery-thumbnail:focus-visible { outline: 2px solid var(--color-yellow); outline-offset: 2px; }
.product-gallery-thumbnail img { width: 100%; height: 100%; border-radius: 6px; object-fit: contain; }
.product-gallery-counter { display: block; min-height: 1.5em; margin: 4px 0 0; overflow: hidden; color: var(--muted); font-size: .82rem; text-overflow: ellipsis; white-space: nowrap; }
.product-contact { display: flex; flex-wrap: wrap; gap: 12px; margin: 20px 0; }
.not-found { padding: 80px 20px; text-align: center; }

@media (max-width: 1100px) {
  .topbar { grid-template-columns: 1fr auto 1fr; padding: 10px 4vw; }
  .brand { grid-column: 2; grid-row: 1; justify-self: center; }
  .menu { grid-column: 1 / -1; }
  .topbar-actions { grid-column: 3; grid-row: 1; justify-self: end; gap: 6px; }
  .event-link { position: static; top: auto; left: auto; padding: 6px 12px; font-size: .82rem; transform: none; }
  .ideas-top-link { padding: 6px 12px; font-size: .82rem; }
  .burger { display: flex; grid-column: 1; grid-row: 1; justify-self: start; flex-direction: column; gap: 5px; padding: 10px; cursor: pointer; }
  .burger span { width: 23px; height: 2px; border-radius: 2px; background: var(--text); }
  .menu { position: absolute; top: 100%; right: 0; left: 0; display: none; flex-direction: column; flex-wrap: nowrap; gap: 0; border-bottom: 1px solid var(--border); background: rgba(26, 29, 32, .97); }
  .menu a { display: flex; width: 100%; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 6vw; border-top: 1px solid var(--border); }
  .menu a::after { content: "›"; flex: 0 0 auto; color: var(--color-blue); font-size: 1.4rem; line-height: 1; }
  .menu a:hover::after, .menu a[aria-current="page"]::after { color: var(--color-yellow); }
  .nav-toggle:checked ~ .menu { display: flex; }
  .nav-toggle:focus-visible + .burger { outline: 2px solid var(--color-yellow); }
  .service-grid, .what-grid { grid-template-columns: 1fr; }
  .machine-details, .product-detail { grid-template-columns: 1fr; }
  .product-detail-gallery { grid-column: 1; grid-row: 1; }
  .product-detail-copy { grid-column: 1; grid-row: 2; }
  .what-page .what-feature { grid-template-columns: 1fr; max-width: 680px; }
  .what-page .what-feature img { max-height: 300px; }
  .ideas-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .machine-details > .machine-photo { min-height: 0; height: auto; aspect-ratio: 4 / 3; }
  .machine-facts { padding: 24px 4px; border-top: 1px solid var(--border); border-left: 0; }
}
@media (max-width: 600px) {
  .section { padding: 64px 6vw; }
  .hero { min-height: calc(100svh - 76px); padding: 48px 6vw 34px; }
  .event-cards, .place-contact { grid-template-columns: 1fr; gap: 0; }
  .event-cards { gap: 24px; }
  .topbar-actions { gap: 5px; }
  .event-link { padding: 6px 8px; font-size: .76rem; }
  .ideas-top-link { padding: 6px 8px; font-size: .76rem; }
  .event-card { padding: 20px 4px; }
  .event-card + .event-card { border-top: 1px solid rgba(0,0,0,.42); border-left: 0; }
  .place-contact > div { padding: 0 0 28px; }
  .place-contact > div + div { padding: 28px 0 0; border-top: 1px solid var(--border); border-left: 0; }
  .site-footer-inner { grid-template-columns: 1fr; gap: 24px; }
  .site-footer-links { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .site-footer-copy { grid-column: auto; }
  .product-grid { grid-template-columns: 1fr; }
  .service-machine-grid, .material-grid, .ideas-grid { grid-template-columns: 1fr; }
  .combined-placeholders { grid-template-columns: 1fr !important; }
  .service-machine-card { padding: 20px; }
  .material-detail { grid-template-columns: 1fr; }
  .what-page .what-feature { gap: 12px; }
  .product-card-copy { padding-right: 8px; padding-left: 10px; }
  .product-card-image-link { padding-right: 10px; padding-left: 8px; }
  .machine-panel { min-height: 100svh; }
  .service-card .photos,
  .album-photos,
  .model-gallery { grid-template-columns: repeat(auto-fill, minmax(min(100%, 140px), 1fr)); }
}

.photo-viewer {
  position: fixed;
  inset: 0;
  margin: auto;
  display: none;
  width: min(94vw, 1100px);
  max-width: none;
  max-height: 92vh;
  padding: 48px 18px 18px;
  border: 1px solid var(--border);
  border-radius: 14px;
  color: var(--text);
  background: var(--bg);
}
.photo-viewer[open] { display: grid; place-items: center; }
.photo-viewer figure { width: 100%; }
.photo-viewer::backdrop { background: rgba(0, 0, 0, .86); }
.photo-viewer img { max-width: 100%; max-height: calc(92vh - 100px); width: auto; height: auto; margin: 0 auto; object-fit: contain; }
.photo-viewer figcaption { margin-top: 10px; color: var(--muted); text-align: center; }
.photo-viewer-close {
  position: absolute;
  top: 8px;
  right: 10px;
  width: 38px;
  height: 38px;
  border: 1px solid var(--border);
  border-radius: 50%;
  color: var(--text);
  background: var(--surface);
  font-size: 1.4rem;
  cursor: pointer;
}
.photo-viewer-trigger { cursor: zoom-in; }
.photo-viewer-trigger:focus-visible { outline: 3px solid var(--color-yellow); outline-offset: 3px; }
