/* WindThorn: Clothing Photography. Editorial, warm-neutral, light only.
   Rebuilt from the owner's Squarespace site (Clarkson v2); tokens follow
   docs/DESIGN_BRIEF.md. No inline styles anywhere (the CSP forbids them).
   No scroll or entrance animations, as on the original. */

/* Free substitutes for Adobe's quatera-display (wide decorative capitals
   whose lowercase render as small caps): Cinzel Decorative for the large
   WINDTHORN wordmark, Cinzel for the header title and headings. */
@font-face {
  font-family: "WT Wordmark";
  src: url("/static/fonts/cinzel-decorative-700-latin.woff2") format("woff2");
  font-weight: 700; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "WT Display";
  src: url("/static/fonts/cinzel-400-700-latin.woff2") format("woff2");
  font-weight: 400 700; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Work Sans";
  src: url("/static/fonts/work-sans-var-latin.woff2") format("woff2");
  font-weight: 400 600; font-style: normal; font-display: swap;
}

:root {
  color-scheme: light;

  --white: #ffffff;
  --black: #000000;
  --accent: #f4f4f4;        /* "bright" band: Select Works */
  --light-accent: #6d6559;  /* warm taupe: footer, solid buttons */
  --ink-2: #3d3d3d;
  --line: #000000;
  --danger: #a31c1c;

  --bg: var(--white);
  --fg: var(--black);

  --font-display: "WT Display", "quatera-display", Georgia, "Times New Roman", serif;
  --font-wordmark: "WT Wordmark", "WT Display", "quatera-display", Georgia, serif;
  --font-body: "Work Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;

  --h1: clamp(2.6rem, 1.6rem + 4vw, 4.5rem);
  --h2: clamp(2rem, 1.4rem + 2.6vw, 3.2rem);
  --h3: clamp(1.5rem, 1.2rem + 1.2vw, 2rem);
  --large: 1.2rem;
  --meta: .85rem;

  --pad: 3vw;               /* page side padding, as on the original */
  --wide: 1500px;
  --radius-btn: 15px;
}

.theme-white  { --bg: var(--white);        --fg: var(--black); }
.theme-bright { --bg: var(--accent);       --fg: var(--black); }
.theme-black  { --bg: var(--black);        --fg: var(--white); }
.theme-taupe  { --bg: var(--light-accent); --fg: var(--white); }
.theme-white, .theme-bright, .theme-black, .theme-taupe { background: var(--bg); color: var(--fg); }

/* Base ------------------------------------------------------------------ */

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--white); color: var(--black);
  font-family: var(--font-body); font-weight: 500; font-size: 1rem; line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-underline-offset: .2em; }
h1, h2, h3, .wordmark {
  margin: 0; font-family: var(--font-display); font-weight: 400;
  letter-spacing: .01em; line-height: 1.2;
}
p { margin: 0 0 1rem; }
:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; }

.wrap { width: 100%; max-width: calc(var(--wide) + 2 * var(--pad)); margin-inline: auto; padding-inline: var(--pad); }
.narrow { max-width: calc(42rem + 2 * var(--pad)); }
.center { text-align: center; }
.large { font-size: var(--large); }
.note { font-size: var(--meta); margin: 1rem 0; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
.skip {
  position: absolute; left: 1rem; top: 1rem; z-index: 100; transform: translateY(-200%);
  background: var(--black); color: var(--white); padding: .6rem 1rem; text-decoration: none;
}
.skip:focus { transform: none; }
.hp { position: absolute; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }

/* Header: title left, nav right, inset ---------------------------------- */

.site-header { border-bottom: 1px solid rgba(0, 0, 0, .55); }
.header-inner {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem 1.5rem; flex-wrap: wrap;
  padding-block: 1.15rem;
}
.header-end {
  display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap;
  gap: clamp(.85rem, 2vw, 1.6rem) clamp(1rem, 2.4vw, 2.2rem);
}
/* Small "CLOTHING PHOTOGRAPHY BY": Cinzel draws lowercase as small caps. */
.site-title {
  font-family: var(--font-display); font-size: var(--large); font-weight: 600;
  letter-spacing: .02em; text-decoration: none;
}
.nav { display: flex; gap: clamp(1rem, 2.4vw, 2.2rem); flex-wrap: wrap; }
.nav a {
  font-size: var(--meta); font-weight: 500; letter-spacing: .08em; text-transform: uppercase;
  text-decoration: none; padding-block: .2rem; border-bottom: 1px solid transparent;
}
.nav a:hover, .nav a[aria-current] { border-bottom-color: currentColor; }
.social {
  display: flex; align-items: center; gap: .7rem;
  list-style: none; margin: 0; padding: 0;
}
.social a {
  display: inline-flex; align-items: center; justify-content: center;
  width: 1.85rem; height: 1.85rem; color: inherit; text-decoration: none;
}
.social a:hover { opacity: .6; }
.social-icon { width: 1.05rem; height: 1.05rem; display: block; }

/* Wordmark band on every page ------------------------------------------- */

/* The large WINDTHORN wordmark spans the page width under the header. */
/* Top padding clears the Cinzel Decorative swash, which draws above the
   em box and was colliding with the header rule. */
.wordmark-band { padding-block: clamp(1.65rem, 3.4vw, 3.5rem) clamp(.75rem, 2vw, 1.5rem); }
.wordmark {
  font-family: var(--font-wordmark); font-weight: 700; text-transform: uppercase;
  font-size: clamp(2.6rem, 11.2vw, 11rem); line-height: 1.1; letter-spacing: .01em;
  text-align: center; white-space: nowrap;
}

/* Buttons --------------------------------------------------------------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: .95rem 1.9rem; border-radius: var(--radius-btn);
  font: inherit; font-size: var(--meta); font-weight: 500; letter-spacing: .08em;
  text-transform: uppercase; text-decoration: none; cursor: pointer;
  border: 1px solid currentColor; background: transparent; color: inherit;
  transition: background-color .2s, color .2s, border-color .2s;
}
.btn-outline:hover { background: var(--fg); color: var(--bg); }
.btn-solid { background: var(--light-accent); border-color: var(--light-accent); color: var(--white); }
.btn-solid:hover { background: #564f45; border-color: #564f45; }
.btn-on-dark:hover { background: var(--white); color: var(--light-accent); }
.btn:disabled { opacity: .6; cursor: progress; }

/* Home: hero ------------------------------------------------------------ */

/* Frame is about a third taller than the previous clamp(22rem, 62vh, 44rem)
   so the crop extends down the shirt. object-position stays top-weighted,
   which keeps the head and the white space above it. max-height stops a
   tall phone from cropping the sides once the whole plate is in frame. */
.hero {
  position: relative; overflow: hidden; background: var(--accent);
  height: clamp(29.33rem, 82.67vh, 58.67rem);
  max-height: calc(100vw * 3991 / 2500);
}
.hero-img { width: 100%; height: 100%; object-fit: cover; object-position: 45.5% 7.2%; }

/* Home: Select Works ---------------------------------------------------- */

.select-works { padding-block: clamp(3.5rem, 8vw, 7rem); }
.section-heading { font-size: var(--h2); text-align: center; margin-bottom: clamp(2rem, 5vw, 4rem); }
.works-row {
  list-style: none; margin: 0 auto; padding: 0;
  /* Same row width as before (the 1300px cap inside the page padding). */
  width: min(1300px, calc(100vw - 6vw));
  display: grid; gap: clamp(2.5rem, 6vw, 3rem); grid-template-columns: minmax(0, 1fr);
}
.work { margin: 0; }
.work a { display: block; }
.work img { width: 100%; aspect-ratio: 2 / 3; object-fit: cover; }
.work figcaption {
  margin-top: .9rem; font-size: var(--meta); letter-spacing: .08em; text-transform: uppercase;
}
/* Mobile: captions alternate centre / left / right, as on the original. */
.works-row li:nth-child(1) figcaption { text-align: center; }
.works-row li:nth-child(2) figcaption { text-align: left; }
.works-row li:nth-child(3) figcaption { text-align: right; }
@media (min-width: 768px) {
  .works-row { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; }
  /* A slight overlap, echoing the 26-column layout of the original. */
  .works-row li:nth-child(1) { margin-right: -1.5vw; margin-top: 4vw; position: relative; z-index: 1; }
  .works-row li:nth-child(2) { position: relative; z-index: 2; padding-inline: 1.5vw; }
  .works-row li:nth-child(3) { margin-left: -1.5vw; margin-top: 4vw; position: relative; z-index: 1; }
  /* Each plate is 25% wider than its column and grows inward, so the row
     stays inside the viewport and the photos overlap a little more. */
  .works-row li:nth-child(1) .work img { width: 125%; max-width: none; }
  .works-row li:nth-child(2) .work img { width: 125%; max-width: none; margin-left: -12.5%; }
  .works-row li:nth-child(3) .work img { width: 125%; max-width: none; margin-left: -25%; }
  .works-row li figcaption { text-align: center; }
  .works-row li:nth-child(n) figcaption { text-align: center; }
}

/* Home: image pair (full-bleed, no gap) --------------------------------- */

.pair { display: grid; grid-template-columns: minmax(0, 1fr); }
.pair-cell img { width: 100%; aspect-ratio: 2 / 3; object-fit: cover; }
@media (min-width: 768px) { .pair { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Home: closing band ---------------------------------------------------- */

.closing {
  position: relative; overflow: hidden; isolation: isolate;
  min-height: clamp(30rem, 90vh, 60rem); display: grid; align-items: center;
}
.closing-img {
  position: absolute; inset: 0; z-index: -2;
  width: 100%; height: 100%; object-fit: cover; object-position: center;
}
/* The photo is mostly white backdrop: a dark wash keeps the white heading
   readable (>= 4.5:1 behind the text). */
.closing::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(90deg, rgba(0, 0, 0, .35) 0%, rgba(0, 0, 0, .62) 55%, rgba(0, 0, 0, .7) 100%);
}
.closing-inner { display: grid; grid-template-columns: minmax(0, 1fr); padding-block: 4rem; }
.closing-heading { font-size: var(--h1); text-align: center; text-wrap: balance; }
@media (min-width: 768px) {
  .closing-inner { grid-template-columns: 1fr 1fr; }
  .closing-heading { grid-column: 2; }
}

/* Inner pages ----------------------------------------------------------- */

.page { padding-block: 0 clamp(2rem, 5vw, 4rem); }
.page-title { font-size: var(--h1); margin-bottom: clamp(1.5rem, 4vw, 2.5rem); }
.center .page-title { text-align: center; }
.bio p { font-size: var(--large); }
.empty { font-size: var(--large); padding-block: 3rem; }

.works-grid {
  list-style: none; margin: 0; padding: 0;
  display: grid; gap: clamp(.75rem, 1.5vw, 1.5rem); grid-template-columns: minmax(0, 1fr);
}
/* Eight portraits: two columns fill every row. Three left an empty slot. */
@media (min-width: 640px) { .works-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.works-item { display: block; overflow: hidden; background: var(--accent); }
.works-item img { width: 100%; aspect-ratio: 2 / 3; object-fit: cover; transition: opacity .2s; }
.works-item:hover img { opacity: .9; }

.portrait { padding-block: 0 clamp(2rem, 5vw, 4rem); }
.portrait-img { width: 100%; max-width: 1300px; margin-inline: auto; }
.signoff { text-align: center; font-size: var(--large); margin: 2rem 0 0; }

.services { padding-block: clamp(3rem, 7vw, 6rem); }
.service-list {
  list-style: none; margin: 0 0 3rem; padding: 0;
  display: grid; gap: 2.5rem; grid-template-columns: minmax(0, 1fr);
}
@media (min-width: 768px) { .service-list { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.service-name { font-size: var(--h3); margin-bottom: .6rem; }

/* Contact (About page) -------------------------------------------------- */

.contact { padding-block: clamp(3rem, 7vw, 6rem); scroll-margin-top: 1rem; }
.contact-grid { display: grid; gap: 2rem; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 900px) { .contact-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr); gap: 4rem; } }
.contact-title { font-size: var(--h1); }

.form { display: grid; gap: 1.4rem; }
.name-fields { border: 0; margin: 0; padding: 0; display: grid; gap: 1rem; grid-template-columns: 1fr 1fr; }
.name-fields legend { padding: 0; margin-bottom: .6rem; font-size: var(--meta); }
.field label, .check label { display: block; font-size: var(--meta); margin-bottom: .4rem; }
.req { color: var(--ink-2); }
.field input, .field textarea, .newsletter-form input {
  width: 100%; font: inherit; font-weight: 400; padding: .9rem 1rem;
  border: 1px solid var(--black); border-radius: 0; background: var(--white); color: var(--black);
}
.field textarea { resize: vertical; min-height: 9rem; }
.field.invalid input, .field.invalid textarea { border-color: var(--danger); border-width: 2px; }
.check { display: flex; gap: .6rem; align-items: center; }
.check label { margin: 0; }
.check input { width: 1.1rem; height: 1.1rem; accent-color: var(--light-accent); }
.error { color: var(--danger); font-size: var(--meta); margin: .4rem 0 0; }
.notice { border: 2px solid var(--danger); padding: .8rem 1rem; color: var(--danger); background: var(--white); }

/* Footer: newsletter, nav, wordmark ------------------------------------- */

.site-footer { padding-block: clamp(3rem, 7vw, 5.5rem) 2rem; }
.site-footer a { color: var(--white); }
.newsletter { max-width: 40rem; margin-inline: auto; text-align: center; }
.meta-heading {
  font-family: var(--font-body); font-weight: 500; font-size: var(--large);
  letter-spacing: .12em; text-transform: uppercase; margin-bottom: .8rem;
}
.newsletter-form { display: flex; gap: .75rem; flex-wrap: wrap; justify-content: center; margin-top: 1.5rem; }
.newsletter-form input { flex: 1 1 16rem; max-width: 26rem; }
.newsletter-form.solo { margin-bottom: 1rem; }
.footer-bottom {
  display: flex; justify-content: space-between; align-items: center; gap: 1.5rem; flex-wrap: wrap;
  margin-top: clamp(3rem, 7vw, 5rem); padding-top: 2rem; border-top: 1px solid rgba(255, 255, 255, .45);
}
.footer-nav { display: flex; gap: 1.8rem; flex-wrap: wrap; }
.footer-nav a {
  font-size: var(--meta); letter-spacing: .08em; text-transform: uppercase; text-decoration: none;
}
.footer-nav a:hover { text-decoration: underline; }
.footer-wordmark { font-family: var(--font-display); font-size: var(--h3); text-decoration: none; }
.fine { margin: 1.5rem 0 0; font-size: .8rem; opacity: .9; }

/* Small screens --------------------------------------------------------- */

@media (max-width: 640px) {
  .header-inner, .header-end { justify-content: center; text-align: center; }
  .nav { justify-content: center; }
  .nav a { padding: .7rem .2rem; }
  .social a { width: 2.75rem; height: 2.75rem; }
  .name-fields { grid-template-columns: 1fr; }
  /* Decorative capitals are wide; keep WINDTHORN on one line without overflow. */
  .wordmark { font-size: clamp(1.7rem, 9.6vw, 2.8rem); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: .01ms !important; animation: none !important; }
}
