/* =========================================================================
   Brandon Aday — site styles
   Mirrors the React/Tailwind tokens. White canvas, ink, warm hairlines,
   Instrument Serif italic reserved for titles, Inter elsewhere.
   ========================================================================= */

:root {
  --bg: #FFFFFF;
  --paper: #FAF9F6;
  --panel: #141414;
  --rule: #E8E3DA;
  --text: #141414;
  --text-inverse: #FFFFFF;
  --subtle: #6B6B6B;
  --faint: #9A9A9A;
  --error: #B14B47;

  --gutter: 24px;
  --gutter-mobile: 16px;
  --max: 1400px;

  --font-sans: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  --font-serif: 'Instrument Serif', Georgia, serif;
  --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
}

*, *::before, *::after {
  box-sizing: border-box;
  border-color: var(--rule);
}

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-feature-settings: "ss01", "cv11";
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img { max-width: 100%; display: block; }

::selection { background: var(--text); color: var(--bg); }

a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }

:focus-visible {
  outline: 1px solid var(--text);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ---------- typography utilities ---------- */

.heading {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.005em;
  line-height: 1.1;
}
.title {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.005em;
  line-height: 1.15;
}
.eyebrow {
  font-family: var(--font-sans);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.6875rem;
  color: var(--subtle);
}
.catalog {
  font-family: var(--font-mono);
  font-weight: 400;
  letter-spacing: 0;
  font-size: 0.75rem;
  color: var(--subtle);
  font-variant-numeric: tabular-nums;
}
.text-subtle { color: var(--subtle); }
.text-faint  { color: var(--faint); }
.text-error  { color: var(--error); }
.title-link { color: inherit; }
.title-link:hover { color: var(--subtle); }

/* ---------- layout ---------- */

.container { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
@media (max-width: 768px) { .container { padding: 0 var(--gutter-mobile); } }

.section { padding-top: 4rem; padding-bottom: 4rem; }
.section--lg { padding-top: 6rem; padding-bottom: 6rem; }
.section--xl { padding-top: 7rem; padding-bottom: 7rem; }
.section--hero { padding-top: 7rem; padding-bottom: 4rem; }
.section--ruled { border-top: 1px solid var(--rule); }

.row { display: flex; align-items: flex-end; justify-content: space-between; gap: 1.5rem; }
.row--start { align-items: flex-start; }
.row--center { align-items: center; }
.row--ruled { border-top: 1px solid var(--rule); padding-top: 2rem; margin-bottom: 3rem; }

.stack { display: flex; flex-direction: column; gap: 1rem; }
.stack--md { gap: 1.5rem; }
.stack--lg { gap: 2.5rem; }
.stack--xl { gap: 4rem; }

.grid-12 {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 2.5rem;
}
@media (max-width: 1024px) {
  .grid-12 { grid-template-columns: 1fr; gap: 2rem; }
}

.col-5 { grid-column: span 5 / span 5; }
.col-6 { grid-column: span 6 / span 6; }
.col-7 { grid-column: span 7 / span 7; }
@media (max-width: 1024px) {
  .col-5, .col-6, .col-7 { grid-column: span 1 / span 1; }
}

/* ---------- site header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--rule);
}
.site-header__inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter);
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}
.site-header__brand {
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
  flex-shrink: 0;
}
.site-header__brand .title { font-size: 1.25rem; }
@media (min-width: 768px) {
  .site-header__brand .title { font-size: 1.5rem; }
}
.site-header__nav {
  display: flex;
  align-items: center;
  gap: 2rem;
}
.site-header__nav a {
  font-size: 0.875rem;
  color: var(--text);
  transition: color 0.2s ease;
}
.site-header__nav a:hover { color: var(--subtle); }
.site-header__mobile { display: none; align-items: center; gap: 1rem; overflow-x: auto; }
.site-header__mobile a { font-size: 0.875rem; color: var(--subtle); white-space: nowrap; }
.site-header__mobile a:hover { color: var(--text); }

@media (max-width: 768px) {
  .site-header__brand .title + .eyebrow { display: none; }
  .site-header__nav { display: none; }
  .site-header__mobile { display: flex; }
}

/* ---------- footer ---------- */

.site-footer {
  border-top: 1px solid var(--rule);
  background: var(--bg);
  padding: 5rem var(--gutter) 2.5rem;
  margin-top: 6rem;
}
.site-footer__inner { max-width: var(--max); margin: 0 auto; }
.site-footer__grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 3rem;
}
@media (max-width: 768px) {
  .site-footer__grid { grid-template-columns: 1fr; }
}
.site-footer__lead { grid-column: span 7 / span 7; }
.site-footer__nav-block { grid-column: span 5 / span 5; }
@media (max-width: 1024px) {
  .site-footer__lead, .site-footer__nav-block { grid-column: span 1; }
}
.site-footer__bottom {
  margin-top: 5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--rule);
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
@media (max-width: 640px) {
  .site-footer__bottom { flex-direction: column-reverse; align-items: flex-start; }
}
.site-footer nav { display: flex; flex-wrap: wrap; gap: 1.5rem; margin-top: 3rem; }
.site-footer nav a { font-size: 0.875rem; color: var(--subtle); }
.site-footer nav a:hover { color: var(--text); }
.site-footer .socials { display: flex; align-items: center; gap: 1.25rem; }
.site-footer .socials a { color: var(--faint); }
.site-footer .socials a:hover { color: var(--text); }

/* ---------- buttons / links ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-sans);
  font-size: 0.875rem;
  padding: 0.875rem 2rem;
  background: var(--text);
  color: var(--bg);
  border: 1px solid var(--text);
  transition: background 0.2s ease, color 0.2s ease, gap 0.2s ease;
}
.btn:hover { background: var(--bg); color: var(--text); }
.btn:disabled { opacity: 0.4; cursor: not-allowed; }

.btn--secondary {
  background: transparent;
  color: var(--text);
}
.btn--secondary:hover { background: var(--text); color: var(--bg); }

.link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  color: var(--text);
  border-bottom: 1px solid var(--text);
  padding-bottom: 2px;
  transition: gap 0.2s ease;
}
.link:hover { gap: 0.75rem; }

.link-quiet {
  font-size: 0.875rem;
  color: var(--subtle);
  transition: color 0.2s ease;
}
.link-quiet:hover { color: var(--text); }

/* ---------- hero ---------- */

.hero-title {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.005em;
  line-height: 1.02;
  font-size: clamp(2.75rem, 6.5vw, 5.5rem);
  max-width: 48rem;
  margin: 0;
}
.hero-lead {
  font-size: 1.125rem;
  line-height: 1.6;
  color: var(--subtle);
  max-width: 36rem;
  margin: 2rem 0 0;
}

/* ---------- gallery (uniform tile + lightbox) ---------- */

.gallery {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem 2rem;
}
@media (min-width: 768px) {
  .gallery--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .gallery--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 1024px) {
  .gallery--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
.gallery--captions-below { gap: 3.5rem 2rem; }

.gallery__item {
  display: flex;
  flex-direction: column;
  text-align: left;
  background: transparent;
  border: 0;
  padding: 0;
  cursor: pointer;
}
.gallery__media {
  position: relative;
  width: 100%;
  background: var(--paper);
  overflow: hidden;
}
.gallery__media--4-5 { aspect-ratio: 4 / 5; }
.gallery__media--4-3 { aspect-ratio: 4 / 3; }
.gallery__media--1-1 { aspect-ratio: 1 / 1; }
.gallery__media img,
.gallery__media .img-fill {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}
.gallery__item:hover .gallery__media img { transform: scale(1.02); }
.gallery__caption { margin-top: 1rem; }
.gallery__caption .title { font-size: 1.125rem; }
.gallery__caption .catalog { margin-top: 0.25rem; }

.figure-caption-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  margin-top: 1rem;
}

/* ---------- lightbox ---------- */

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 50;
  background: rgba(20, 20, 20, 0.95);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  display: none;
  flex-direction: column;
}
.lightbox.is-open { display: flex; }
.lightbox__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem var(--gutter);
  color: var(--text-inverse);
  flex-shrink: 0;
}
.lightbox__top .catalog { color: rgba(255,255,255,0.7); }
.lightbox__stage {
  flex: 1;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 1rem;
  min-height: 0;
}
.lightbox__stage img {
  max-width: 92vw;
  max-height: 70vh;
  object-fit: contain;
  width: auto;
  height: auto;
}
.lightbox__nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: 0;
  color: rgba(255,255,255,0.8);
  padding: 0.75rem;
  font-size: 2rem;
  line-height: 1;
}
.lightbox__nav:hover { color: var(--text-inverse); }
.lightbox__nav--prev { left: 0.75rem; }
.lightbox__nav--next { right: 0.75rem; }
@media (min-width: 768px) {
  .lightbox__nav--prev { left: 1.5rem; }
  .lightbox__nav--next { right: 1.5rem; }
}
.lightbox__close {
  background: transparent;
  border: 0;
  color: var(--text-inverse);
  padding: 0.5rem;
  font-size: 1.25rem;
}
.lightbox__caption {
  padding: 1.5rem var(--gutter);
  color: var(--text-inverse);
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  flex-shrink: 0;
}
@media (min-width: 768px) {
  .lightbox__caption {
    flex-direction: row;
    align-items: flex-end;
    justify-content: space-between;
    gap: 0.75rem;
  }
}
.lightbox__caption .title { font-size: 1.5rem; color: var(--text-inverse); line-height: 1.2; }
.lightbox__caption .catalog { color: rgba(255,255,255,0.7); }
.lightbox__caption a {
  color: var(--text-inverse);
  border-bottom: 1px solid var(--text-inverse);
  padding-bottom: 2px;
  font-size: 0.875rem;
  align-self: flex-start;
}

/* ---------- form ---------- */

.form { display: flex; flex-direction: column; gap: 4rem; }
.form-section {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 3rem;
  border-top: 1px solid var(--rule);
  padding-top: 3rem;
}
@media (max-width: 1024px) { .form-section { grid-template-columns: 1fr; gap: 1.5rem; } }
.form-section__label { grid-column: span 5 / span 5; }
.form-section__body  { grid-column: span 7 / span 7; }
@media (max-width: 1024px) {
  .form-section__label, .form-section__body { grid-column: span 1 / span 1; }
}
.form-section__title {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: 1.5rem;
  line-height: 1.3;
  margin-top: 0.75rem;
  max-width: 24rem;
}

.field { display: block; }
.field + .field { margin-top: 1.5rem; }
.field__label,
.form label.field__label {
  display: block;
  font-family: var(--font-sans);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.6875rem;
  color: var(--subtle);
  margin-bottom: 0.5rem;
}
.field__required { color: rgba(20,20,20,0.4); margin-left: 4px; }

.input, .textarea, .select {
  width: 100%;
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--rule);
  padding: 0.5rem 0;
  font-family: var(--font-sans);
  font-size: 0.875rem;
  color: var(--text);
  outline: none;
}
.input:focus, .textarea:focus, .select:focus { border-bottom-color: var(--text); }
.input::placeholder, .textarea::placeholder { color: var(--faint); }
.input--mono { font-family: var(--font-mono); }
.input--error { border-bottom-color: var(--error); }
.textarea { resize: none; line-height: 1.5; }

.field__error { font-family: var(--font-mono); font-size: 0.75rem; color: var(--error); margin-top: 0.5rem; }

.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.5rem; }
@media (max-width: 640px) { .grid-2 { grid-template-columns: 1fr; } }
.grid-span-2 { grid-column: 1 / -1; }

/* chips */
.chips { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.chip {
  background: transparent;
  border: 1px solid var(--rule);
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  color: var(--subtle);
  white-space: nowrap;
  transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}
.chip:hover { color: var(--text); border-color: var(--text); }
.chip[aria-pressed="true"] {
  background: var(--text);
  color: var(--bg);
  border-color: var(--text);
}

/* radio cards */
.radio-cards { display: grid; grid-template-columns: 1fr; gap: 0.75rem; }
@media (min-width: 640px) { .radio-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.radio-card {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding: 1.25rem;
  background: transparent;
  border: 1px solid var(--rule);
  text-align: left;
  transition: border-color 0.2s ease, background 0.2s ease, color 0.2s ease;
}
.radio-card:hover { border-color: var(--text); }
.radio-card[aria-pressed="true"] {
  border-color: var(--text);
  background: var(--text);
  color: var(--bg);
}
.radio-card .title { font-size: 1.125rem; line-height: 1.2; }
.radio-card .desc { font-size: 0.875rem; line-height: 1.4; color: var(--subtle); }
.radio-card[aria-pressed="true"] .desc { color: rgba(255,255,255,0.75); }

.checkbox-row { display: flex; align-items: flex-start; gap: 0.75rem; padding-top: 0.5rem; cursor: pointer; }
.checkbox-row input { margin-top: 4px; accent-color: var(--text); }
.checkbox-row span { font-size: 0.875rem; color: var(--text); }

/* form footer */
.form-footer {
  border-top: 1px solid var(--rule);
  padding-top: 2.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}
@media (min-width: 768px) {
  .form-footer { flex-direction: row; align-items: flex-end; justify-content: space-between; }
}

/* ---------- about / press blocks ---------- */

.blockquote-pull {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(1.5rem, 3vw, 2rem);
  line-height: 1.25;
  border-left: 1px solid var(--text);
  padding-left: 1.5rem;
  margin: 1rem 0;
  max-width: 32rem;
}

.influences-list {
  list-style: none;
  padding: 1.5rem 0 0;
  border-top: 1px solid var(--rule);
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem 1.5rem;
  max-width: 36rem;
  margin: 0;
}
@media (min-width: 768px) {
  .influences-list { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
.influences-list li {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.125rem;
}

/* ---------- success state ---------- */
.success { display: none; }
.success.is-shown { display: block; }
.form.is-hidden { display: none; }

/* ---------- utilities ---------- */
.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; }
.hidden { display: none !important; }
.mt-0 { margin-top: 0; }
.mt-2 { margin-top: 0.5rem; }
.mt-4 { margin-top: 1rem; }
.mt-6 { margin-top: 1.5rem; }
.mt-8 { margin-top: 2rem; }
.mt-10 { margin-top: 2.5rem; }
.mt-12 { margin-top: 3rem; }
.mt-16 { margin-top: 4rem; }
.mb-3 { margin-bottom: 0.75rem; }
.mb-5 { margin-bottom: 1.25rem; }
.mb-6 { margin-bottom: 1.5rem; }
.gap-6 { gap: 1.5rem; }
.gap-10 { gap: 2.5rem; }
.body-text { font-size: 1rem; line-height: 1.7; color: var(--text); max-width: 36rem; }
.body-text + .body-text { margin-top: 1.25rem; }
.body-text--lg { font-size: 1.125rem; }
.figcaption { font-family: var(--font-mono); font-size: 0.75rem; color: var(--subtle); margin-top: 0.75rem; max-width: 28rem; }
