/* Pixi Tattoos — single stylesheet.
   Light, gallery-forward, photography-first. One accent colour. */

/* ---------- Fonts (self-hosted, variable) ---------- */
@font-face {
  font-family: "Inter";
  src: url("assets/fonts/inter-latin.woff2") format("woff2");
  font-weight: 400 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Playfair Display";
  src: url("assets/fonts/playfair-latin.woff2") format("woff2");
  font-weight: 400 900;
  font-style: normal;
  font-display: swap;
}

/* ---------- Tokens ---------- */
:root {
  --bg: #ffffff;
  --ink: #1a1a1a;
  --muted: #6e6e6e;
  --line: #e8e8e8;
  --accent: #a6365a;       /* dusty rose — AA on white (6.3:1) */
  --accent-soft: #fdf3f6;
  --todo-bg: #fff8e1;
  --todo-edge: #b98a00;
  --serif: "Playfair Display", Georgia, "Times New Roman", serif;
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --measure: 62ch;
  --pad: clamp(1rem, 4vw, 2.5rem);
}

/* ---------- Base ---------- */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-underline-offset: 3px; }
a:hover { color: var(--ink); }

h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 600;
  line-height: 1.12;
  letter-spacing: 0;
  margin: 0 0 0.5em;
}
h1 { font-size: clamp(2.2rem, 6vw, 3.8rem); }
h2 { font-size: clamp(1.5rem, 3.5vw, 2.2rem); }
h3 { font-size: 1.15rem; }

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--ink);
  color: #fff;
  padding: 0.6rem 1rem;
  z-index: 100;
}
.skip-link:focus { left: 0; }

/* ---------- Visible TODO blocks (content gaps from brief.md) ---------- */
.todo {
  background: var(--todo-bg);
  border-left: 4px solid var(--todo-edge);
  padding: 0.75rem 1rem;
  margin: 1rem 0;
  font-size: 0.9rem;
  color: #5c4500;
  border-radius: 0 4px 4px 0;
}
.todo::before {
  content: "TODO — ";
  font-weight: 600;
}

/* ---------- Header / nav ---------- */
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem var(--pad);
  border-bottom: 1px solid var(--line);
  position: relative;
  background: var(--bg);
}
.wordmark {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.3rem;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: -0.01em;
}
.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0.5rem 0.65rem;
  cursor: pointer;
  line-height: 0;
}
.nav-toggle svg { width: 22px; height: 22px; stroke: var(--ink); }
.site-nav ul {
  display: flex;
  gap: clamp(1rem, 3vw, 2rem);
  list-style: none;
  margin: 0;
  padding: 0;
}
.site-nav a {
  color: var(--ink);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
}
.site-nav a:hover { color: var(--accent); }
.site-nav a[aria-current="page"] {
  color: var(--accent);
  border-bottom: 2px solid var(--accent);
  padding-bottom: 2px;
}

@media (max-width: 719px) {
  .nav-toggle { display: block; }
  .site-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg);
    border-bottom: 1px solid var(--line);
    z-index: 50;
  }
  .site-nav.open { display: block; }
  .site-nav ul {
    flex-direction: column;
    gap: 0;
    padding: 0.5rem 0;
  }
  .site-nav a {
    display: block;
    padding: 0.85rem var(--pad);
    font-size: 1.05rem;
  }
  .site-nav a[aria-current="page"] {
    border-bottom: none;
    border-left: 3px solid var(--accent);
    padding-left: calc(var(--pad) - 3px);
  }
}

/* ---------- Layout helpers ---------- */
.wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--pad);
}
.prose { max-width: var(--measure); }
main { min-height: 60vh; }
.section { margin: clamp(2.5rem, 7vw, 5rem) 0; }
.section-lead {
  color: var(--muted);
  max-width: var(--measure);
  margin-top: -0.25rem;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
  padding: 0.8rem 1.6rem;
  border: none;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.15s ease;
}
.btn:hover { background: #8c2c4b; color: #fff; }
.btn:focus-visible { outline: 3px solid var(--ink); outline-offset: 2px; }

/* ---------- Hero (home) ---------- */
.hero {
  position: relative;
  height: min(78vh, 720px);
  overflow: hidden;
}
.hero picture, .hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
}
.hero-overlay {
  position: absolute;
  inset: auto 0 0 0;
  padding: clamp(4rem, 10vw, 6rem) var(--pad) clamp(1.5rem, 4vw, 2.5rem);
  background: linear-gradient(to top, rgba(255,255,255,0.96) 25%, rgba(255,255,255,0.75) 60%, rgba(255,255,255,0) 100%);
}
.hero-overlay .inner {
  max-width: 1200px;
  margin: 0 auto;
}
.hero h1 { margin-bottom: 0.15em; }
.hero .strap {
  font-size: clamp(1rem, 2.5vw, 1.2rem);
  color: var(--ink);
  margin: 0 0 1.1rem;
  max-width: 34ch;
}
@media (min-width: 900px) {
  .hero { height: min(85vh, 820px); }
  .hero picture, .hero img { object-position: center 24%; }
  /* Wide screens: fade from the left so the artwork stays unwashed */
  .hero-overlay {
    inset: 0;
    display: flex;
    align-items: flex-end;
    background: linear-gradient(to right, rgba(255,255,255,0.95) 18%, rgba(255,255,255,0.6) 38%, rgba(255,255,255,0) 62%);
  }
  .hero-overlay .inner { margin: 0; width: 100%; max-width: 1200px; margin-inline: auto; }
}

/* ---------- Preview grid (home) ---------- */
.preview-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: clamp(0.6rem, 2vw, 1.25rem);
}
@media (min-width: 720px) {
  .preview-grid { grid-template-columns: repeat(3, 1fr); }
}
.preview-grid a { display: block; }
.preview-grid img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 4px;
}
.preview-grid a:focus-visible img,
.gallery-grid a:focus-visible img {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}
.see-all { margin-top: 1.5rem; }

/* ---------- Intro (home) ---------- */
.intro {
  display: grid;
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: start;
}
.intro img { border-radius: 6px; }
@media (min-width: 720px) {
  .intro { grid-template-columns: minmax(240px, 340px) 1fr; }
  .intro--text { grid-template-columns: 1fr; }
}

/* ---------- Gallery ---------- */
/* Row-major grid so Pixi's chosen order reads left-to-right, top-to-bottom. */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: clamp(0.6rem, 2vw, 1.25rem);
  align-items: start;
}
@media (min-width: 900px) { .gallery-grid { grid-template-columns: repeat(3, 1fr); } }
.gallery-grid figure { margin: 0; }
.gallery-grid a { display: block; }
.gallery-grid img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 4px;
}
/* Flash sheets & sketches keep their natural proportions — no cropping of drawings. */
.gallery-grid--natural img { aspect-ratio: auto; object-fit: initial; }

/* ---------- Lightbox ---------- */
.lightbox {
  border: none;
  padding: 0;
  background: rgba(20, 20, 20, 0.92);
  max-width: 100vw;
  max-height: 100vh;
  width: 100vw;
  height: 100vh;
  margin: 0;
}
.lightbox::backdrop { background: rgba(20, 20, 20, 0.92); }
.lightbox .frame {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  padding: 3.5rem 1rem 1rem;
}
.lightbox img {
  max-width: min(92vw, 1100px);
  max-height: 78vh;
  width: auto;
  height: auto;
  border-radius: 4px;
}
.lightbox .lb-close,
.lightbox .lb-prev,
.lightbox .lb-next {
  position: absolute;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  border: none;
  border-radius: 999px;
  width: 44px;
  height: 44px;
  font-size: 1.3rem;
  line-height: 1;
  cursor: pointer;
  display: grid;
  place-items: center;
}
.lightbox .lb-close:hover,
.lightbox .lb-prev:hover,
.lightbox .lb-next:hover { background: rgba(255, 255, 255, 0.28); }
.lightbox .lb-close { top: 0.75rem; right: 0.75rem; }
.lightbox .lb-prev { left: 0.75rem; top: 50%; transform: translateY(-50%); }
.lightbox .lb-next { right: 0.75rem; top: 50%; transform: translateY(-50%); }
.lightbox button:focus-visible { outline: 3px solid #fff; outline-offset: 2px; }

/* ---------- Forms (booking) ---------- */
.how-to-book { margin: 1.5rem 0 2.25rem; }
.how-to-book h2 { font-size: 1.35rem; }
.how-to-book ul { padding-left: 1.2rem; }
.form-grid {
  display: grid;
  gap: 1.25rem;
  max-width: 640px;
}
.field label {
  display: block;
  font-weight: 600;
  font-size: 0.95rem;
  margin-bottom: 0.35rem;
}
.field .hint {
  font-weight: 400;
  color: var(--muted);
  font-size: 0.85rem;
  display: block;
}
.field input[type="text"],
.field input[type="email"],
.field select,
.field textarea {
  width: 100%;
  font: inherit;
  color: var(--ink);
  background: #fff;
  border: 1px solid #c9c9c9;
  border-radius: 6px;
  padding: 0.65rem 0.8rem;
}
.field textarea { min-height: 7.5rem; resize: vertical; }
.field input:focus-visible,
.field select:focus-visible,
.field textarea:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 1px;
}
fieldset.field {
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0.85rem 1rem 1rem;
  margin: 0;
}
fieldset.field legend { font-weight: 600; font-size: 0.95rem; padding: 0 0.35rem; }
.radio-row { display: flex; gap: 1.25rem; margin-top: 0.25rem; }
.radio-row label { font-weight: 400; display: flex; align-items: center; gap: 0.4rem; }
.form-status { font-weight: 500; margin-top: 0.75rem; }
.form-status.error { color: #a02020; }
.form-status.ok { color: #1d6b3a; }

.placeholder-block {
  border: 2px dashed var(--line);
  border-radius: 8px;
  padding: 2.5rem var(--pad);
  text-align: center;
  color: var(--muted);
}

/* ---------- Info / FAQ ---------- */
.info-section { border-top: 1px solid var(--line); padding-top: 2rem; }
.info-section:first-of-type { border-top: none; padding-top: 0; }

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--line);
  margin-top: clamp(3rem, 8vw, 5rem);
  padding: 2rem var(--pad) 2.5rem;
  color: var(--muted);
  font-size: 0.9rem;
}
.site-footer .inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 2rem;
  justify-content: space-between;
  align-items: baseline;
}
.site-footer a { color: var(--ink); font-weight: 500; }
.site-footer a:hover { color: var(--accent); }
