/* Ink It ZM: public pages (home, booking, asking, aftercare, 404).
   One loud thing per page: on the home page it is the transfer sheet, where the logo is traced in
   stencil and then inked. Everything around it stays quiet. */

/* ---------- Header ---------- */
.top { display: flex; align-items: center; gap: 14px; padding: 14px 0; }
.brand { font-family: var(--font-mark); font-size: 1.75rem; line-height: 1; text-decoration: none; color: var(--bone); padding: 8px 0; }
.top-nav { display: none; gap: 4px; margin-left: auto; }
.top-nav a {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 12px;
  color: var(--ash); text-decoration: none; font-weight: 560; font-stretch: 92%; font-size: var(--t-s);
}
.top-nav a:hover { color: var(--bone); }
.top .open-status { margin-left: auto; }
.top > a.btn:last-child:not(.top-book) { margin-left: auto; }
.top-book { display: none; }

/* Sections share one rhythm; each section sets only what differs. */
main > section { padding-block: 56px; }
.display + p { margin-top: 16px; }

/* ---------- Hero: the transfer sheet ---------- */
.hero { display: grid; gap: 22px; padding-top: 4px; padding-bottom: 44px; }
.sheet {
  position: relative;
  background: var(--bone); color: var(--ink);
  border-radius: 3px;
  padding: clamp(18px, 5.5vw, 44px) clamp(16px, 5vw, 44px);
}
.wordmark { margin: 0; }
.wm { width: 100%; height: auto; overflow: visible; }
.wm-1 { display: none; }
.wm-stencil { transform: translate(26px, 22px); }
.wm-stencil path { fill: none; stroke: var(--transfer); stroke-width: 9; stroke-linejoin: round; }
.wm-ink path { fill: var(--ink); }
/* Written in the empty corner beside "ZM", the way an artist notes things on a stencil sheet. */
.sheet-note {
  position: absolute; left: clamp(16px, 5vw, 44px); bottom: clamp(18px, 5.5vw, 44px);
  max-width: 34%; margin: 0;
  font-size: var(--t-xs); font-stretch: var(--w-note); font-weight: 620; line-height: 1.35; color: #3b362f;
}
/* The one orchestrated moment: the needle traces the stencil, then the ink goes in, line by line. */
@media (prefers-reduced-motion: no-preference) {
  .wm-stencil path { stroke-dasharray: 1; stroke-dashoffset: 1; animation: trace 1.1s cubic-bezier(0.55, 0, 0.3, 1) forwards; }
  .wm-stencil path.l1 { animation-delay: 0.12s; }
  .wm-stencil path.l2 { animation-delay: 0.42s; }
  .wm-ink .ink-line { clip-path: inset(-5% 100% -5% 0); animation: ink-in 0.6s cubic-bezier(0.6, 0, 0.2, 1) forwards; }
  .wm-ink .l1 { animation-delay: 1.02s; }
  .wm-ink .l2 { animation-delay: 1.4s; animation-duration: 0.45s; }
  .sheet-note { opacity: 0; animation: fade-in-up 0.5s ease 1.75s forwards; }
}
@keyframes trace { to { stroke-dashoffset: 0; } }
@keyframes ink-in { to { clip-path: inset(-5% 0 -5% 0); } }
@keyframes fade-in-up { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

.hero-side { display: grid; gap: 16px; align-content: start; }
.hero-line { margin: 0; font-size: var(--t-l); line-height: 1.35; font-weight: 500; max-width: 30ch; }
.hero-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.hero-actions .btn { padding: 0 12px; }
.hero-wa { margin: 0; color: var(--ash); font-size: var(--t-s); }

/* ---------- A returning customer's conversations (live) ---------- */
.threads { margin-top: 6px; }
.thread-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.thread-card {
  display: grid; grid-template-columns: 1fr auto; gap: 2px 14px; align-items: center;
  padding: 14px 16px; min-height: 64px;
  border: 1.5px solid var(--line); border-radius: var(--r-m);
  color: var(--bone); text-decoration: none; background: var(--wet);
  transition: transform 0.15s var(--spring), border-color 0.15s ease;
}
.thread-card:hover { border-color: var(--edge); }
.thread-card:active { transform: scale(0.98); }
/* Waiting for the customer (a price to accept): drawn as a stencil. Booked: inked. */
.thread-card.is-pending { border-style: dashed; border-color: var(--stencil); }
.thread-card.is-booked { border-color: var(--bone); }
.thread-head { display: flex; align-items: center; gap: 9px; font-weight: 640; font-stretch: 92%; line-height: 1.25; }
.thread-meta { grid-column: 1; margin: 0; color: var(--ash); font-size: var(--t-xs); font-stretch: var(--w-note); font-weight: 520; }
.thread-side { grid-column: 2; grid-row: 1 / span 2; text-align: right; font-weight: 640; font-variant-numeric: tabular-nums; }
.thread-side svg { width: 20px; height: 20px; margin-left: auto; color: var(--ash); }

/* ---------- Section heads and links ---------- */
.section-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 16px; margin-bottom: 22px; }
.link-out { display: inline-flex; align-items: center; min-height: 44px; color: var(--ash); font-size: var(--t-s); font-weight: 560; }
.link-out:hover { color: var(--bone); }

/* ---------- Work ---------- */
.work { padding-top: 24px; }
.work-grid { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px 10px; margin-top: 0; margin-bottom: 0; }
.work-grid li { position: relative; min-width: 0; }
.work-item {
  position: relative; display: block; width: 100%; padding: 0;
  border: 0; border-radius: 4px; overflow: hidden; background: var(--wet);
  aspect-ratio: 388 / 444;
  transition: transform 0.15s var(--spring);
  -webkit-tap-highlight-color: transparent;
}
.work-item img { width: 100%; height: 100%; object-fit: cover; }
.work-item:active { transform: scale(0.98); }
.work-item:focus-visible { outline-offset: 3px; }
.work-cap { margin: 9px 0 0; font-size: var(--t-s); font-weight: 600; font-stretch: 94%; line-height: 1.3; }
.work-cap span { display: block; margin-top: 2px; color: var(--ash); font-weight: 480; font-stretch: var(--w-note); font-size: var(--t-xs); }
/* Added from the dashboard in the last two weeks. */
.work-new {
  position: absolute; top: 8px; left: 8px; z-index: 1;
  padding: 3px 8px; border-radius: 3px;
  background: var(--bone); color: var(--ink);
  font-size: 0.75rem; font-weight: 720; font-stretch: 100%; line-height: 1.3;
  pointer-events: none;
}

/* ---------- Prices: the flash sheet ---------- */
.prices { display: grid; gap: 22px; }
.prices-text p { color: var(--ash); max-width: 46ch; }
.flash { border: 1.5px solid var(--bone); border-radius: 4px; padding: 10px 20px; }
.price-list { margin: 0; }
.price-row {
  display: flex; align-items: baseline; gap: 10px;
  padding: 14px 0; border-bottom: 1px solid var(--line);
}
.price-row:last-child { border-bottom: 0; }
.price-row dt { font-size: 1.9rem; line-height: 1; flex: none; }
.price-row::after { content: ""; flex: 1 1 auto; order: 1; border-bottom: 1.5px dotted var(--edge); transform: translateY(-5px); min-width: 16px; }
.price-row dd { order: 2; margin: 0; font-weight: 640; font-stretch: 94%; text-align: right; }

/* ---------- How to book: a real sequence, so it is numbered ---------- */
.steps { list-style: none; margin: 28px 0 0; padding: 0; counter-reset: step; display: grid; gap: 0; }
.steps li { position: relative; counter-increment: step; padding: 0 0 28px 58px; min-width: 0; }
.steps li::before {
  content: counter(step);
  position: absolute; left: 0; top: -4px;
  width: 40px; height: 40px; display: grid; place-items: center;
  border: 1.5px dashed var(--stencil); border-radius: 50%;
  font-weight: 640; font-stretch: 80%; font-size: 1.125rem; color: var(--bone);
}
.steps li::after { content: ""; position: absolute; left: 20px; top: 42px; bottom: 4px; border-left: 1.5px dashed var(--line); }
.steps li:last-child::after { display: none; }
.steps h3 { font-size: var(--t-l); font-stretch: 86%; margin: 0 0 6px; }
.steps p { margin: 0; color: var(--ash); }
.how-actions { display: grid; gap: 12px; margin-top: 8px; }
.how-actions p { margin: 0; }

/* ---------- Find the studio ---------- */
.studio { display: grid; gap: 30px; }
.studio-now { display: flex; align-items: center; gap: 10px; margin: 0 0 6px; font-weight: 600; font-stretch: 94%; }
.facts { margin: 18px 0 0; }
.facts > div { display: grid; grid-template-columns: minmax(6.5em, 32%) 1fr; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.facts dt { color: var(--ash); font-size: var(--t-s); padding-top: 1px; }
.facts dd { margin: 0; overflow-wrap: anywhere; }
.facts a { display: inline-block; padding: 12px 0; margin: -12px 0; }
.studio-actions { display: grid; gap: 10px; margin-top: 22px; }
.studio-photo { margin: 0; max-width: 388px; }
.studio-photo img { width: 100%; border-radius: 4px; }

/* ---------- Aftercare teaser, questions, closing ---------- */
.care p { color: var(--ash); max-width: 52ch; }
.faq-list { margin-top: 22px; border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  min-height: 60px; padding: 14px 0; cursor: pointer; list-style: none;
  font-weight: 620; font-stretch: 92%; font-size: 1.125rem; line-height: 1.3;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; flex: none; width: 12px; height: 12px;
  border-right: 1.8px solid var(--bone); border-bottom: 1.8px solid var(--bone);
  transform: rotate(45deg) translate(-2px, -2px); transition: transform 0.2s ease;
}
.faq details[open] summary::after { transform: rotate(225deg) translate(-2px, -2px); }
.faq details p { margin: 0 0 18px; color: var(--ash); max-width: 64ch; }
.faq details::details-content { block-size: 0; overflow: hidden; transition: block-size 0.25s ease, content-visibility 0.25s allow-discrete; }
.faq details[open]::details-content { block-size: auto; }
@supports (interpolate-size: allow-keywords) { .faq { interpolate-size: allow-keywords; } }
.closing p { color: var(--ash); }
.closing-actions { display: grid; gap: 10px; margin-top: 8px; }

/* ---------- Footer ---------- */
.foot { border-top: 1px solid var(--line); padding: 36px 0 calc(36px + var(--safe-b)); }
.foot-grid { display: grid; gap: 26px; }
.foot-links { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.foot-links a { display: inline-flex; align-items: center; min-height: 44px; color: var(--bone); text-decoration: none; }
.foot-links a:hover { text-decoration: underline; }
.foot-meta { margin: 0; line-height: 1.8; }
body.has-actionbar .foot { padding-bottom: calc(108px + var(--safe-b)); }

/* ---------- Bottom bar on phones ---------- */
.actionbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  display: grid; grid-template-columns: 1fr auto; gap: 10px;
  padding: 10px var(--gutter) calc(10px + var(--safe-b));
  background: rgba(0, 0, 0, 0.94); border-top: 1px solid var(--line);
  transform: translateY(110%); transition: transform 0.25s var(--ease-out);
}
.actionbar.show { transform: none; }
.actionbar-ask { padding: 0 18px; }

/* ---------- Photo viewer ---------- */
.lightbox[open] { width: 100vw; height: 100dvh; background: rgba(0, 0, 0, 0.97); display: grid; }
.lb-inner { display: grid; grid-template-rows: auto 1fr auto; height: 100%; padding: calc(10px + env(safe-area-inset-top, 0px)) 12px calc(12px + var(--safe-b)); }
#lb-img { width: 100%; height: 100%; max-height: calc(100dvh - 150px); object-fit: contain; align-self: center; touch-action: pan-y; }
.lb-bar { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px; }
.lb-cap { margin: 0; text-align: center; font-size: var(--t-s); color: var(--ash); }
.lb-close { justify-self: end; }

/* ---------- Booking and asking ---------- */
.page-book main, .page-ask main { padding-bottom: 40px; }
.book { max-width: 680px; }
.book-head { padding: 8px 0 6px; }
.book-title { font-size: clamp(2.25rem, 9vw, 3rem); margin-bottom: 18px; }
.book-title:focus { outline: none; }
.book-lead { color: var(--ash); margin: -6px 0 24px; }

.progress { list-style: none; margin: 0 0 30px; padding: 0; display: flex; }
.progress li { position: relative; flex: 1 1 0; min-width: 0; padding-top: 22px; font-size: 0.875rem; font-weight: 600; font-stretch: 90%; color: var(--ash); }
.progress li::before {
  content: ""; position: absolute; top: 3px; left: 0; z-index: 1;
  width: 12px; height: 12px; border-radius: 50%;
  border: 2px solid var(--stencil); background: var(--ink);
}
.progress li::after { content: ""; position: absolute; top: 9px; left: 16px; right: 4px; border-top: 2px dashed var(--stencil); }
.progress li:last-child::after { display: none; }
.progress li.done { color: var(--bone); }
.progress li.done::before { border-style: solid; border-color: var(--bone); background: var(--bone); }
.progress li.done::after { border-top-style: solid; border-color: var(--bone); }
.progress li[aria-current="step"] { color: var(--bone); }
.progress li[aria-current="step"]::before { border-color: var(--bone); box-shadow: 0 0 0 3px var(--stencil-soft); }

.step-title { font-size: var(--t-xl); font-stretch: 86%; margin: 0 0 20px; }
/* Steps slide the way you go: forward comes in from the right, back from the left. */
.step.enter-fwd { animation: step-fwd 0.28s var(--ease-out); }
.step.enter-back { animation: step-back 0.28s var(--ease-out); }
@keyframes step-fwd { from { opacity: 0; transform: translateX(28px); } }
@keyframes step-back { from { opacity: 0; transform: translateX(-28px); } }
.step-title:focus { outline: none; }
.photo-list { display: flex; flex-wrap: wrap; gap: 10px; }
.photo-list:empty { display: none; }
.photo-thumb { position: relative; width: 96px; height: 110px; border-radius: var(--r-s); overflow: hidden; background: var(--wet); }
.photo-thumb img { width: 100%; height: 100%; object-fit: cover; }
.photo-thumb button {
  position: absolute; top: 4px; right: 4px; width: 36px; height: 36px;
  display: grid; place-items: center; padding: 0;
  border: 0; border-radius: 50%; background: rgba(0, 0, 0, 0.8); color: var(--bone);
}
.photo-thumb button svg { width: 18px; height: 18px; }
.photo-add { justify-self: start; }
.photo-add svg { width: 20px; height: 20px; }
.photo-add:focus-within { outline: 2px dashed var(--stencil); outline-offset: 3px; }
.photos-field .busy { color: var(--ash); font-size: var(--t-s); margin: 0; }

.step-nav {
  position: sticky; bottom: 0; z-index: 5;
  display: grid; grid-template-columns: auto 1fr; gap: 10px;
  margin-top: 10px; padding: 12px 0 calc(12px + var(--safe-b));
  background: var(--ink); border-top: 1px solid var(--line);
}
.step-nav.first { grid-template-columns: 1fr; }
.form-error {
  margin: 4px 0 8px; padding: 12px 14px;
  border: 1.5px solid var(--danger); border-radius: var(--r-s);
  color: var(--danger); font-weight: 600;
}
.review { margin: 26px 0 18px; padding: 16px 18px; border: 1.5px dashed var(--stencil); border-radius: var(--r-m); }
.review h3 { margin: 0 0 8px; font-size: 1.125rem; }
.review dl { margin: 0; display: grid; gap: 10px; }
.review dl > div { display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; align-items: start; }
.review dt { color: var(--ash); font-size: var(--t-s); grid-column: 1; }
.review dd { margin: 0; grid-column: 1; overflow-wrap: anywhere; }
.review .edit {
  grid-column: 2; grid-row: 1 / span 2; align-self: center;
  min-height: 44px; padding: 0 12px; border: 0; background: transparent; color: var(--bone);
  text-decoration: underline; text-underline-offset: 0.2em;
}
.privacy { margin: 16px 0 6px; }
.hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; opacity: 0; }
.closed-note { margin: 10px 0 30px; }
.closed-note h2 { margin-bottom: 8px; font-size: var(--t-xl); }

.done { padding: 10px 0 30px; }
.done:focus { outline: none; }
.done h1 { margin-bottom: 18px; }
.ref-label { margin: 0; color: var(--ash); }
.ref {
  margin: 4px 0 22px;
  font-family: var(--font); font-weight: 760; font-stretch: 100%; font-size: 2.6rem; line-height: 1;
  letter-spacing: 0.06em;
}
.done h2 { font-size: var(--t-l); margin: 30px 0 12px; }
.next-steps { margin: 0 0 26px; padding-left: 1.3em; display: grid; gap: 10px; color: var(--ash); }
.next-steps li::marker { color: var(--bone); font-weight: 700; }
.done-actions { display: grid; gap: 10px; }
.done .hint { margin-top: 8px; }
.keep-link { margin: 18px 0 0; padding: 14px 16px; border: 1.5px dashed var(--stencil); border-radius: var(--r-m); }
.keep-link p { margin: 0 0 10px; }

.check-booking { margin-top: 40px; padding-top: 30px; border-top: 1px solid var(--line); }
.check-booking h2 { font-size: var(--t-xl); font-stretch: 86%; margin-bottom: 8px; }
.check-booking > p { color: var(--ash); }
.check-result { margin-top: 18px; }
.status-card { padding: 18px; border: 1px solid var(--line); border-radius: var(--r-m); background: var(--wet); }
.status-card h3 { margin: 10px 0 8px; font-size: 1.25rem; }
.status-card p { margin: 0 0 6px; color: var(--ash); }

/* ---------- Aftercare page ---------- */
.article { max-width: 720px; padding-bottom: 60px; }
.article h1 { font-size: clamp(2.6rem, 11vw, 4rem); margin: 12px 0 18px; }
.article h2 { font-size: var(--t-xl); font-stretch: 86%; margin: 44px 0 14px; }
.article ul, .article ol { padding-left: 1.25em; display: grid; gap: 10px; margin: 0 0 18px; max-width: 64ch; }
.article li::marker { color: var(--ash); }
.article .lead { font-size: var(--t-l); line-height: 1.45; }
.warn { margin: 28px 0; padding: 18px; border: 1.5px solid var(--danger); border-radius: var(--r-m); }
.warn h2 { margin-top: 0; color: var(--danger); font-size: var(--t-l); font-stretch: 92%; }
.article-actions { display: grid; gap: 10px; margin-top: 30px; }

/* ---------- 404 ---------- */
.lost { padding: 60px 0; }
.lost h1 { font-size: clamp(2.6rem, 12vw, 4.5rem); margin-bottom: 16px; }
.lost .btn { margin-top: 16px; }

/* ---------- Wider screens ---------- */
@media (min-width: 560px) {
  .closing-actions, .studio-actions, .done-actions { grid-template-columns: auto auto; justify-content: start; }
  .how-actions { justify-items: start; }
  .work-grid { gap: 26px 12px; }
}
@media (min-width: 900px) {
  :root { --gutter: 32px; }
  .top { padding: 20px 0; }
  .top-nav { display: flex; }
  .top .open-status { margin-left: 8px; }
  .top-book { display: inline-flex; }
  main > section { padding-block: 92px; }
  .display { font-size: var(--t-3xl); }
  /* On a wide screen the sheet is a long strip with the logo on one line; the words and buttons sit under it. */
  .hero { grid-template-columns: 1fr; gap: 30px; padding-top: 14px; padding-bottom: 56px; }
  .sheet { padding: 40px 48px 30px; }
  .wm-2 { display: none; }
  .wm-1 { display: block; }
  .wm-stencil path { stroke-width: 7; }
  .sheet-note { position: static; max-width: none; margin-top: 18px; }
  .sheet-note br { display: none; }
  .hero-side { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); column-gap: 64px; row-gap: 14px; align-items: start; }
  .hero-line { grid-column: 1; grid-row: 1 / span 3; font-size: var(--t-xl); line-height: 1.3; }
  .hero-actions, .hero-wa, .threads { grid-column: 2; }
  .threads { margin-top: 4px; }
  .work { padding-top: 40px; }
  .work-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 30px 14px; }
  .prices { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); grid-template-areas: "text flash" "cta flash"; column-gap: 64px; align-items: start; }
  .prices-text { grid-area: text; }
  .flash { grid-area: flash; padding: 18px 30px; }
  .prices-cta { grid-area: cta; }
  .price-row dt { font-size: 2.3rem; }
  .steps { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 28px; margin-top: 36px; }
  .steps li { padding: 62px 0 0; }
  .steps li::before { top: 0; }
  .steps li::after { left: 50px; right: -16px; top: 20px; bottom: auto; border-left: 0; border-top: 1.5px dashed var(--line); }
  .how-actions { grid-auto-flow: column; justify-content: start; align-items: center; gap: 22px; margin-top: 16px; }
  .studio { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); align-items: center; gap: 56px; }
  .faq-list { max-width: 820px; }
  .foot-grid { grid-template-columns: 2fr 1.2fr 1.4fr; align-items: start; }
  .actionbar { display: none; }
  body.has-actionbar .foot { padding-bottom: 44px; }
}
.sheet-sep { display: none; }
@media (min-width: 900px) {
  .sheet-sep { display: inline-block; width: 1.6em; }
}
