/* BabaMaker — foglio di stile */

@font-face { font-family: "Cormorant"; src: url("../fonts/cormorant-garamond-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: "Cormorant"; src: url("../fonts/cormorant-garamond-latin-500-italic.woff2") format("woff2"); font-weight: 500; font-style: italic; font-display: swap; }
@font-face { font-family: "Cormorant"; src: url("../fonts/cormorant-garamond-latin-600-normal.woff2") format("woff2"); font-weight: 600; font-style: normal; font-display: swap; }
@font-face { font-family: "Work Sans"; src: url("../fonts/work-sans-latin-300-normal.woff2") format("woff2"); font-weight: 300; font-display: swap; }
@font-face { font-family: "Work Sans"; src: url("../fonts/work-sans-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Work Sans"; src: url("../fonts/work-sans-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-display: swap; }

:root {
  --paper: #f5f0e6;
  --paper-2: #ebe3d3;
  --paper-3: #e2d7c2;
  --ink: #2a2723;
  --ink-soft: #5f584e;
  --slate: #3e5755;
  --olive: #7b7c33;
  --brick: #9b2418;
  --brick-dark: #7d1c12;
  --line: #d6cab4;
  --serif: "Cormorant", "Cormorant Garamond", Garamond, "Times New Roman", serif;
  --sans: "Work Sans", "Helvetica Neue", Arial, sans-serif;
  --wrap: 1240px;
  --gutter: clamp(16px, 4vw, 48px);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-weight: 300;
  font-size: 17px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration-color: var(--line); text-underline-offset: 3px; }
a:hover { text-decoration-color: currentColor; }
::selection { background: var(--paper-3); }

h1, h2, h3 { font-family: var(--serif); font-weight: 500; line-height: 1.08; letter-spacing: -0.01em; margin: 0 0 .5em; }
h1 { font-size: clamp(44px, 6.4vw, 88px); }
h2 { font-size: clamp(34px, 4.4vw, 58px); }
h3 { font-size: clamp(24px, 2.4vw, 32px); }
h1 em, h2 em, h3 em { font-style: italic; color: var(--slate); }
p { margin: 0 0 1.1em; }
strong { font-weight: 500; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.narrow { max-width: 720px; }
.eyebrow {
  font-family: var(--sans); font-size: 12px; font-weight: 500; letter-spacing: .22em; text-transform: uppercase;
  color: var(--olive); margin: 0 0 1.4em; display: flex; align-items: center; gap: 14px;
}
.eyebrow::before { content: ""; width: 32px; height: 1px; background: currentColor; }
.lead { font-family: var(--serif); font-size: clamp(22px, 2.3vw, 29px); line-height: 1.45; font-weight: 500; color: var(--ink); }
.muted { color: var(--ink-soft); }
.small { font-size: 14px; }

/* --- Header --- */
.site-header { position: sticky; top: 0; z-index: 20; background: rgba(245, 240, 230, .94); backdrop-filter: blur(8px); border-bottom: 1px solid transparent; transition: border-color .3s; }
.site-header.scrolled { border-bottom-color: var(--line); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 84px; }
.brand img { width: 150px; }
.nav { display: flex; gap: clamp(18px, 2.6vw, 38px); align-items: center; }
.nav a { text-decoration: none; font-size: 14px; font-weight: 400; letter-spacing: .06em; padding: 6px 0; border-bottom: 1px solid transparent; }
.nav a:hover, .nav a[aria-current="page"] { border-bottom-color: var(--ink); }
.nav .nav-cta { border: 1px solid var(--ink); padding: 9px 18px; }
.nav .nav-cta:hover { background: var(--ink); color: var(--paper); }
.nav-toggle { display: none; background: none; border: 0; padding: 10px; margin-right: -10px; cursor: pointer; color: var(--ink); }
.nav-toggle span { display: block; width: 24px; height: 1.5px; background: currentColor; margin: 6px 0; transition: transform .3s, opacity .3s; }

@media (max-width: 860px) {
  .site-header { backdrop-filter: none; background: var(--paper); }
  .site-header .wrap { height: 68px; }
  .brand img { width: 122px; }
  .nav-toggle { display: block; }
  .nav { position: fixed; inset: 68px 0 0 0; background: var(--paper); flex-direction: column; align-items: flex-start; gap: 0; padding: 24px var(--gutter); transform: translateY(-8px); opacity: 0; visibility: hidden; transition: opacity .25s, transform .25s, visibility .25s; }
  .nav a { font-family: var(--serif); font-size: 34px; letter-spacing: 0; padding: 10px 0; width: 100%; border-bottom: 1px solid var(--line); }
  .nav .nav-cta { border: 0; border-bottom: 1px solid var(--line); padding: 10px 0; color: var(--brick); }
  .nav-open .nav { opacity: 1; visibility: visible; transform: none; }
  .nav-open .nav-toggle span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
  .nav-open .nav-toggle span:nth-child(2) { opacity: 0; }
  .nav-open .nav-toggle span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }
  .nav-open { overflow: hidden; }
}

/* --- Bottoni --- */
.btn {
  display: inline-flex; align-items: center; gap: 12px; text-decoration: none; font-size: 14px; font-weight: 500;
  letter-spacing: .08em; text-transform: uppercase; padding: 16px 28px; border: 1px solid var(--ink); color: var(--ink);
  background: transparent; cursor: pointer; transition: background .2s, color .2s, border-color .2s; font-family: var(--sans);
}
.btn:hover { background: var(--ink); color: var(--paper); }
.btn-etsy { background: var(--brick); border-color: var(--brick); color: #fff; }
.btn-etsy:hover { background: var(--brick-dark); border-color: var(--brick-dark); color: #fff; }
.btn .arrow { transition: transform .2s; }
.btn:hover .arrow { transform: translateX(4px); }
.link-arrow { text-decoration: none; font-size: 14px; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; border-bottom: 1px solid var(--ink); padding-bottom: 4px; }
.btn-row { display: flex; flex-wrap: wrap; gap: 14px 22px; align-items: center; margin-top: 2em; }

/* --- Sezioni --- */
.section { padding: clamp(72px, 10vw, 140px) 0; }
.section-tight { padding: clamp(48px, 6vw, 80px) 0; }
.bg-2 { background: var(--paper-2); }
.bg-dark { background: #26302f; color: #eae3d4; }
.bg-dark h2 em { color: #c9c78a; }
.bg-dark .eyebrow { color: #c9c78a; }
.rule { border: 0; border-top: 1px solid var(--line); margin: 0; }

/* --- Hero --- */
.hero { position: relative; display: grid; grid-template-columns: 5fr 7fr; min-height: calc(100vh - 84px); max-height: 900px; }
.hero-text { display: flex; flex-direction: column; justify-content: center; padding: 64px var(--gutter) 64px max(var(--gutter), calc((100vw - var(--wrap)) / 2 + var(--gutter))); }
.hero-text h1 { margin-bottom: .35em; }
.hero-text p { max-width: 30em; }
.hero-media { position: relative; overflow: hidden; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; }
.hero-caption { position: absolute; left: 24px; bottom: 20px; color: #fff; font-family: var(--serif); font-style: italic; font-size: 18px; text-shadow: 0 1px 10px rgba(0,0,0,.4); }
@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; min-height: 0; max-height: none; }
  .hero-media { order: -1; aspect-ratio: 4 / 3; }
  .hero-text { padding: 44px var(--gutter) 56px; }
}

.page-head { padding: clamp(64px, 9vw, 120px) 0 clamp(40px, 5vw, 64px); }
.page-head h1 { max-width: 14em; }
.page-head .lead { max-width: 34em; color: var(--ink-soft); }

/* --- Griglie --- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 96px); align-items: center; }
.split.wide-left { grid-template-columns: 7fr 5fr; }
.split.wide-right { grid-template-columns: 5fr 7fr; }
.split .media img { width: 100%; }
@media (max-width: 860px) { .split, .split.wide-left, .split.wide-right { grid-template-columns: 1fr; } .split .media { order: -1; } .split.keep-order .media { order: 0; } }

.cols-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(24px, 3vw, 48px); }
.cols-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(20px, 2.4vw, 36px); }
@media (max-width: 980px) { .cols-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 760px) { .cols-3 { grid-template-columns: 1fr; } }
@media (max-width: 520px) { .cols-4 { grid-template-columns: 1fr; } }

.step-num { font-family: var(--serif); font-style: italic; font-size: 44px; color: var(--olive); line-height: 1; display: block; margin-bottom: 12px; }

/* --- Card collezioni --- */
.coll { text-decoration: none; display: block; }
.coll .img { overflow: hidden; background: #fff; aspect-ratio: 4 / 3; }
.coll .img img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s cubic-bezier(.2,.7,.2,1); }
.coll:hover .img img { transform: scale(1.04); }
.coll h3 { margin: 18px 0 4px; }
.coll .meta { font-size: 14px; color: var(--ink-soft); }
.coll .price { font-family: var(--serif); font-size: 21px; color: var(--ink); }
.coll .img { position: relative; }

/* --- Realizzazioni --- */
.works { display: grid; grid-template-columns: repeat(12, 1fr); gap: clamp(28px, 3.4vw, 52px) clamp(20px, 2.6vw, 40px); }
.work { grid-column: span 4; text-decoration: none; display: block; }
.work.big { grid-column: span 6; }
.work .img { overflow: hidden; aspect-ratio: 4 / 5; background: var(--paper-3); }
.work.big .img { aspect-ratio: 5 / 4; }
.work img { width: 100%; height: 100%; object-fit: cover; transition: transform .9s cubic-bezier(.2,.7,.2,1), filter .5s; filter: saturate(.92); }
.work:hover img { transform: scale(1.035); filter: saturate(1); }
.work h3 { margin: 16px 0 2px; font-size: 27px; }
.work p { margin: 0; font-size: 14px; color: var(--ink-soft); }
@media (max-width: 900px) { .work, .work.big { grid-column: span 6; } .work.big .img { aspect-ratio: 4 / 5; } }
@media (max-width: 560px) { .work, .work.big { grid-column: span 12; } }

/* --- Galleria dettaglio --- */
.gallery { display: grid; grid-template-columns: repeat(6, 1fr); gap: clamp(10px, 1.4vw, 18px); }
.gallery > * { grid-column: span 2; display: block; overflow: hidden; background: var(--paper-3); aspect-ratio: 1; }
.gallery a { cursor: zoom-in; }
.gallery > .lg { grid-column: span 4; grid-row: span 2; aspect-ratio: auto; }
.gallery > .md { grid-column: span 3; aspect-ratio: 4 / 3; }
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s cubic-bezier(.2,.7,.2,1); }
.gallery a:hover img { transform: scale(1.03); }
@media (max-width: 700px) { .gallery { grid-template-columns: repeat(2, 1fr); } .gallery > *, .gallery > .md { grid-column: span 1; aspect-ratio: 1; } .gallery > .lg { grid-column: span 2; grid-row: auto; aspect-ratio: 4 / 5; } }

.work-detail { display: grid; grid-template-columns: 4fr 8fr; gap: clamp(32px, 5vw, 80px); align-items: start; }
.work-detail aside { position: sticky; top: 120px; }
.facts { list-style: none; padding: 0; margin: 28px 0 0; border-top: 1px solid var(--line); font-size: 14px; }
.facts li { display: flex; justify-content: space-between; gap: 20px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.facts li span:first-child { color: var(--ink-soft); }
.facts li span:last-child { text-align: right; }
@media (max-width: 900px) { .work-detail { grid-template-columns: 1fr; } .work-detail aside { position: static; } }

.video { position: relative; aspect-ratio: 16 / 9; background: #1f2524; color: #d8d2c3; display: grid; place-items: center; text-align: center; overflow: hidden; }
.video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video .ph { padding: 24px; }
.video .ph .play { width: 72px; height: 72px; border: 1px solid currentColor; border-radius: 50%; display: grid; place-items: center; margin: 0 auto 16px; }
.video .ph p { font-family: var(--serif); font-style: italic; font-size: 22px; margin: 0; }
.video-poster { position: absolute; inset: 0; background-size: cover; background-position: center; opacity: .35; }

.pager { display: flex; justify-content: space-between; gap: 24px; padding: 40px 0; border-top: 1px solid var(--line); margin-top: clamp(56px, 7vw, 96px); }
.pager a { text-decoration: none; max-width: 45%; }
.pager small { display: block; font-size: 12px; letter-spacing: .2em; text-transform: uppercase; color: var(--ink-soft); }
.pager span { font-family: var(--serif); font-size: 26px; }
.pager .next { text-align: right; margin-left: auto; }

/* --- Citazione --- */

/* --- Strip immagini --- */
.strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; }
.strip img { aspect-ratio: 1; object-fit: cover; width: 100%; }
@media (max-width: 700px) { .strip { grid-template-columns: repeat(2, 1fr); } }

/* --- FAQ --- */
.faq details { border-bottom: 1px solid var(--line); }
.faq details:first-child { border-top: 1px solid var(--line); }
.faq summary { list-style: none; cursor: pointer; padding: 22px 40px 22px 0; font-family: var(--serif); font-size: 24px; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 4px; top: 18px; font-family: var(--sans); font-weight: 300; font-size: 26px; transition: transform .25s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding-right: 40px; color: var(--ink-soft); }

/* --- Persone --- */
.person h3 { margin-bottom: .1em; }
.person .role { font-size: 13px; letter-spacing: .18em; text-transform: uppercase; color: var(--olive); margin-bottom: 1.4em; }
.monogram { width: 92px; height: 92px; border-radius: 50%; border: 1px solid var(--line); display: grid; place-items: center; font-family: var(--serif); font-style: italic; font-size: 40px; color: var(--slate); margin-bottom: 26px; }

/* --- Form --- */
.form { display: grid; gap: 22px; }
.form label { display: block; font-size: 13px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-soft); margin-bottom: 8px; }
.form input[type=text], .form input[type=email], .form textarea {
  width: 100%; font: inherit; font-weight: 400; color: var(--ink); background: transparent; border: 0; border-bottom: 1px solid var(--ink-soft);
  padding: 10px 0; border-radius: 0; outline: none; transition: border-color .2s;
}
.form textarea { min-height: 150px; resize: vertical; border: 1px solid var(--ink-soft); padding: 12px; }
.form input:focus, .form textarea:focus { border-color: var(--brick); }
.form .check { display: flex; gap: 12px; align-items: flex-start; font-size: 14px; text-transform: none; letter-spacing: 0; color: var(--ink); margin: 0; }
.form .check input { margin-top: 5px; accent-color: var(--brick); }
.form .hp { position: absolute; left: -9999px; }
.notice { padding: 18px 22px; border-left: 3px solid var(--olive); background: var(--paper-2); margin-bottom: 28px; }
.notice.err { border-left-color: var(--brick); }
.contact-list { list-style: none; padding: 0; margin: 0; }
.contact-list li { padding: 18px 0; border-bottom: 1px solid var(--line); }
.contact-list small { display: block; font-size: 12px; letter-spacing: .2em; text-transform: uppercase; color: var(--ink-soft); }
.contact-list a { font-family: var(--serif); font-size: 26px; text-decoration: none; }

/* --- Footer --- */
.site-footer { background: #26302f; color: #cfc8b8; padding: 72px 0 36px; font-size: 14px; }
.site-footer a { color: #eae3d4; text-decoration-color: rgba(234,227,212,.3); }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 40px; }
.footer-grid h4 { font-family: var(--sans); font-weight: 500; font-size: 12px; letter-spacing: .2em; text-transform: uppercase; color: #c9c78a; margin: 0 0 16px; }
.footer-grid ul { list-style: none; padding: 0; margin: 0; }
.footer-grid li { margin-bottom: 8px; }
.footer-claim { font-family: var(--serif); font-style: italic; font-size: 28px; line-height: 1.25; color: #eae3d4; max-width: 12em; margin: 0 0 18px; }
.footer-bottom { margin-top: 56px; padding-top: 22px; border-top: 1px solid rgba(234,227,212,.15); display: flex; flex-wrap: wrap; gap: 10px 28px; justify-content: space-between; color: #9f998b; font-size: 13px; }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-grid > :first-child { grid-column: 1 / -1; } }

/* --- Lightbox --- */
.lb { position: fixed; inset: 0; z-index: 50; background: rgba(24, 22, 19, .96); display: none; align-items: center; justify-content: center; }
.lb.open { display: flex; }
.lb img { max-width: 92vw; max-height: 86vh; width: auto; height: auto; box-shadow: 0 20px 60px rgba(0,0,0,.4); }
.lb button { position: absolute; background: none; border: 0; color: #eae3d4; font-size: 34px; font-family: var(--sans); font-weight: 300; cursor: pointer; padding: 14px 20px; }
.lb .lb-close { top: 10px; right: 10px; }
.lb .lb-prev { left: 6px; top: 50%; transform: translateY(-50%); }
.lb .lb-next { right: 6px; top: 50%; transform: translateY(-50%); }
.lb .lb-count { position: absolute; bottom: 18px; left: 0; right: 0; text-align: center; color: #9f998b; font-size: 13px; letter-spacing: .2em; }

/* --- Comparsa allo scroll --- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .9s ease, transform .9s cubic-bezier(.2,.7,.2,1); }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } html { scroll-behavior: auto; } }

.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; z-index: 100; background: var(--ink); color: var(--paper); padding: 10px 16px; }
:focus-visible { outline: 2px solid var(--brick); outline-offset: 3px; }

.cookie-bar { position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 60; max-width: 560px; margin-inline: auto; padding: 18px 20px; background: var(--paper); border: 1px solid var(--ink); display: flex; flex-wrap: wrap; gap: 12px 20px; align-items: center; justify-content: space-between; font-size: 14px; }
.cookie-bar[hidden] { display: none; }
.cookie-bar p { margin: 0; flex: 1 1 260px; }
.cookie-actions { display: flex; gap: 10px; }
.cookie-actions .btn { padding: 10px 18px; }
.link-cookie { background: none; border: 0; padding: 0; font: inherit; color: inherit; text-decoration: underline; cursor: pointer; }
