/* ============================================================
   DESIGN TOKENS
   ============================================================ */
:root {
  --canvas:      #E4DCC8;   /* page background — warm plaster */
  --paper:       #F6F1E4;   /* card background — raw paper */
  --ink:         #2A2419;   /* primary text — warm umber-black */
  --ink-soft:    #5B5240;   /* secondary text */
  --moss:        #55603D;   /* primary accent — deep olive */
  --moss-dark:   #3E4630;
  --clay:        #A24E36;   /* secondary accent — brick/rust */
  --gold:        #A9812F;   /* highlight — aged gold */
  --line:        rgba(42, 36, 25, 0.14);

  --serif: 'Fraunces', serif;
  --sans:  'Work Sans', sans-serif;

  --max: 1180px;
  --edge: clamp(20px, 5vw, 64px);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--canvas);
  color: var(--ink);
  font-family: var(--sans);
  font-weight: 400;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

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

a { color: inherit; }

.eyebrow {
  font-family: var(--serif);
  font-style: italic;
  font-size: 15px;
  letter-spacing: 0.02em;
  color: var(--clay);
  margin: 0 0 10px;
}

h1, h2, h3 { font-family: var(--serif); font-weight: 500; margin: 0; }

/* Paper grain overlay, sits above the canvas colour, below content */
.grain-defs { position: absolute; width: 0; height: 0; }
.grain-overlay {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  filter: url(#grain);
  opacity: 0.5;
  mix-blend-mode: multiply;
}

/* Hand-drawn brush underline, used as the signature motif throughout */
.brush-underline {
  width: 130px;
  height: 12px;
  display: block;
  margin-top: 6px;
}
.brush-underline path {
  fill: none;
  stroke: var(--gold);
  stroke-width: 3;
  stroke-linecap: round;
}
.brush-underline--lg { width: 200px; height: 15px; margin: 10px auto 0; }

/* ============================================================
   NAV
   ============================================================ */
.nav {
  position: relative;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 28px var(--edge) 10px;
  max-width: var(--max);
  margin: 0 auto;
}
.nav__mark { text-decoration: none; color: var(--ink); }
.nav__name {
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 600;
  letter-spacing: 0.01em;
}
.nav__links { display: flex; gap: 32px; }
.nav__links a {
  text-decoration: none;
  font-size: 15px;
  color: var(--ink-soft);
  transition: color 0.2s ease;
}
.nav__links a:hover { color: var(--clay); }

@media (max-width: 640px) {
  .nav { flex-direction: column; align-items: flex-start; gap: 14px; }
  .nav__links { gap: 20px; font-size: 14px; }
}

/* ============================================================
   HERO
   ============================================================ */
.hero {
  position: relative;
  z-index: 2;
  max-width: var(--max);
  margin: 0 auto;
  padding: 40px var(--edge) 90px;
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: 60px;
  align-items: center;
}
.hero__title {
  font-size: clamp(40px, 6vw, 68px);
  line-height: 1.04;
  letter-spacing: -0.01em;
}
.hero__title em {
  font-style: italic;
  color: var(--moss);
}
.hero__sub {
  max-width: 42ch;
  color: var(--ink-soft);
  font-size: 17px;
  margin: 22px 0 32px;
}
.hero__actions { display: flex; gap: 16px; flex-wrap: wrap; }

.btn {
  display: inline-block;
  padding: 13px 26px;
  border-radius: 2px;
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 500;
  text-decoration: none;
  transition: transform 0.15s ease, background 0.2s ease, color 0.2s ease;
}
.btn--primary { background: var(--moss); color: var(--paper); }
.btn--primary:hover { background: var(--moss-dark); transform: translateY(-1px); }
.btn--ghost { background: transparent; color: var(--ink); border: 1px solid var(--line); }
.btn--ghost:hover { border-color: var(--ink); }

@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; padding-bottom: 50px; }
  .hero__art { order: -1; }
}

/* ============================================================
   ART FRAMES (used for hero image, portrait, and gallery cards)
   ============================================================ */
.art-frame {
  position: relative;
  background: var(--paper);
  border: 1px solid var(--line);
  overflow: hidden;
  box-shadow: 0 18px 40px -22px rgba(42, 36, 25, 0.35);
}
.art-frame img { width: 100%; height: 100%; object-fit: cover; }
.art-frame.is-empty img { display: none; }
.art-frame .placeholder-label { display: none; }
.art-frame.is-empty .placeholder-label {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 20px;
  height: 100%;
  color: var(--ink-soft);
  font-size: 13px;
  background:
    repeating-linear-gradient(135deg, transparent, transparent 10px, rgba(42,36,25,0.05) 10px, rgba(42,36,25,0.05) 11px);
}
.art-frame.is-empty .placeholder-label code {
  background: var(--canvas);
  padding: 2px 6px;
  border-radius: 2px;
}

.art-frame--hero { aspect-ratio: 4 / 5; }
.art-frame--portrait { aspect-ratio: 3 / 4; max-width: 380px; }

/* ============================================================
   GALLERY
   ============================================================ */
.gallery-section {
  position: relative;
  z-index: 2;
  max-width: var(--max);
  margin: 0 auto;
  padding: 40px var(--edge) 100px;
}
.section-head { text-align: center; margin-bottom: 48px; }
.section-head h2 { font-size: clamp(30px, 4vw, 42px); }
.section-head .eyebrow { text-align: center; }

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 36px;
}

.card {
  display: flex;
  flex-direction: column;
}
.card__frame { aspect-ratio: 4 / 5; margin-bottom: 16px; }
.card__row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
}
.card__title {
  font-family: var(--serif);
  font-size: 19px;
  font-weight: 500;
  margin: 0;
}
.card__price {
  font-family: var(--serif);
  font-style: italic;
  color: var(--clay);
  white-space: nowrap;
}
.card__meta {
  font-size: 13px;
  color: var(--ink-soft);
  margin: 4px 0 14px;
}
.card__actions { margin-top: auto; display: flex; gap: 10px; align-items: center; }

.tag {
  display: inline-block;
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 5px 10px;
  border-radius: 2px;
  border: 1px solid var(--line);
  color: var(--ink-soft);
}
.tag--sold { border-color: var(--clay); color: var(--clay); }

.buy-btn {
  display: inline-block;
  padding: 10px 20px;
  background: var(--ink);
  color: var(--paper);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  border-radius: 2px;
  transition: background 0.2s ease;
}
.buy-btn:hover { background: var(--moss-dark); }
.buy-btn.is-disabled {
  pointer-events: none;
  background: transparent;
  color: var(--ink-soft);
  border: 1px solid var(--line);
}

.gallery-empty {
  text-align: center;
  padding: 60px 20px;
  color: var(--ink-soft);
  border: 1px dashed var(--line);
  border-radius: 4px;
}

/* ============================================================
   ABOUT
   ============================================================ */
.about {
  position: relative;
  z-index: 2;
  max-width: var(--max);
  margin: 0 auto;
  padding: 60px var(--edge) 100px;
  display: grid;
  grid-template-columns: 380px 1fr;
  gap: 64px;
  align-items: start;
}
.about__text p { color: var(--ink-soft); font-size: 16px; max-width: 56ch; }
.about__text h2 { font-size: clamp(28px, 3.4vw, 38px); margin-bottom: 18px; }
.about__facts {
  list-style: none;
  padding: 0;
  margin: 28px 0 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 15px;
}
.about__facts span {
  display: inline-block;
  width: 130px;
  color: var(--gold);
  font-family: var(--serif);
  font-style: italic;
}

@media (max-width: 800px) {
  .about { grid-template-columns: 1fr; }
  .art-frame--portrait { max-width: 260px; }
}

/* ============================================================
   COMMISSION
   ============================================================ */
.commission {
  position: relative;
  z-index: 2;
  background: var(--moss);
  color: var(--paper);
}
.commission__inner {
  max-width: 640px;
  margin: 0 auto;
  text-align: center;
  padding: 90px var(--edge);
}
.commission .eyebrow { color: var(--gold); text-align: center; }
.commission h2 { font-size: clamp(30px, 4vw, 42px); margin-bottom: 18px; }
.commission p { color: rgba(246, 241, 228, 0.85); font-size: 16px; margin-bottom: 30px; }
.commission .btn--primary { background: var(--gold); color: var(--ink); }
.commission .btn--primary:hover { background: #bd9540; }

/* ============================================================
   CONTACT
   ============================================================ */
.contact {
  position: relative;
  z-index: 2;
  max-width: 640px;
  margin: 0 auto;
  text-align: center;
  padding: 100px var(--edge) 80px;
}
.contact h2 { font-size: clamp(30px, 4vw, 40px); }
.contact__sub { color: var(--ink-soft); margin: 14px 0 24px; }
.contact__email {
  font-family: var(--serif);
  font-style: italic;
  font-size: 22px;
  color: var(--clay);
  text-decoration: none;
  border-bottom: 1px solid var(--clay);
  padding-bottom: 2px;
}
.contact__social { margin-top: 26px; }
.contact__social a { font-size: 14px; color: var(--ink-soft); text-decoration: none; }
.contact__social a:hover { color: var(--ink); }

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 30px var(--edge) 50px;
  color: var(--ink-soft);
  font-size: 13px;
}
.footer .brush-underline { margin: 0 auto 14px; }

/* ============================================================
   ACCESSIBILITY
   ============================================================ */
a:focus-visible, button:focus-visible {
  outline: 2px solid var(--moss);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
