/* WhittleWood Woodworks: warm workshop palette, system fonts, no framework. */
:root {
  --bg: #f7f1e8;
  --surface: #fffaf2;
  --ink: #2b1f16;
  --ink-soft: #5c4a3c;
  --muted: #8a7666;
  --line: #e4d7c5;
  --walnut: #3b2a1e;
  --accent: #9a5426;
  --accent-dark: #7a3f19;
  --ok: #2f6b3a;
  --err: #a12a1f;
  --radius: 10px;
  --shadow: 0 1px 2px rgba(59, 42, 30, .08), 0 6px 20px rgba(59, 42, 30, .08);
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color-scheme: light;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 17px/1.6 var(--sans); }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-underline-offset: 2px; }
a:hover { color: var(--accent-dark); }
h1, h2, h3 { font-family: var(--serif); line-height: 1.2; color: var(--walnut); margin: 0 0 .5em; }
h1 { font-size: clamp(2rem, 4vw + 1rem, 2.9rem); }
h2 { font-size: clamp(1.5rem, 2vw + 1rem, 2rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }
.wrap { width: 100%; max-width: 1180px; margin: 0 auto; padding-inline: 20px; }
.section { padding-block: 48px; }
.narrow { max-width: 760px; }
.lede { font-size: 1.15rem; color: var(--ink-soft); max-width: 62ch; }
.muted { color: var(--muted); }
.eyebrow { text-transform: uppercase; letter-spacing: .12em; font-size: .78rem; font-weight: 600; color: var(--accent); margin-bottom: .4em; }
.sr-only, .hp { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--walnut); color: #fff; padding: 8px 14px; border-radius: 6px; z-index: 100; }
.skip:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }

/* Header */
.site-header { background: var(--walnut); color: #f5e9da; position: sticky; top: 0; z-index: 20; box-shadow: 0 2px 10px rgba(0,0,0,.18); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 72px; }
.brand { display: flex; align-items: center; gap: 12px; color: #fff; text-decoration: none; font-family: var(--serif); font-size: 1.3rem; font-weight: 600; }
.brand img { width: 52px; height: 52px; object-fit: contain; background: #fff; border-radius: 50%; padding: 3px; }
.brand:hover { color: #fff; }
.site-nav { display: flex; gap: 4px; flex-wrap: wrap; }
.site-nav a { color: #f1e2cf; text-decoration: none; padding: 8px 12px; border-radius: 6px; font-weight: 500; font-size: .98rem; }
.site-nav a:hover { background: rgba(255,255,255,.08); color: #fff; }
.site-nav a[aria-current="page"] { background: rgba(255,255,255,.14); color: #fff; }
.nav-toggle { display: none; background: none; border: 0; padding: 10px; cursor: pointer; }
.bars, .bars::before, .bars::after { display: block; width: 24px; height: 2px; background: #fff; position: relative; content: ""; transition: transform .2s; }
.bars::before { position: absolute; top: -7px; } .bars::after { position: absolute; top: 7px; }
@media (max-width: 860px) {
  .nav-toggle { display: block; }
  .site-nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--walnut); flex-direction: column; padding: 8px 20px 16px; }
  .site-nav.open { display: flex; }
  .site-nav a { padding: 12px; font-size: 1.05rem; }
}

/* Buttons */
.btn { display: inline-block; background: var(--accent); color: #fff; text-decoration: none; padding: 12px 22px; border-radius: 999px; font-weight: 600; border: 2px solid var(--accent); cursor: pointer; font-size: 1rem; }
.btn:hover { background: var(--accent-dark); border-color: var(--accent-dark); color: #fff; }
.btn-ghost { background: transparent; color: var(--accent); }
.btn-ghost:hover { background: var(--accent); color: #fff; }
.link-arrow { font-weight: 600; text-decoration: none; }

/* Hero */
.hero { background: linear-gradient(160deg, #efe2cf 0%, #f7f1e8 60%); border-bottom: 1px solid var(--line); }
.hero-inner { display: grid; grid-template-columns: 1.4fr 1fr; gap: 40px; align-items: center; padding-block: 64px; }
.hero h1 { margin-bottom: .35em; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 24px; }
.next-show { background: var(--surface); border: 1px solid var(--line); border-left: 5px solid var(--accent); border-radius: var(--radius); padding: 24px 26px; box-shadow: var(--shadow); }
.next-show h2 { font-size: 1.5rem; }
.next-show h2 a { color: var(--walnut); text-decoration: none; }
.next-when { font-weight: 700; font-size: 1.1rem; color: var(--accent-dark); margin-bottom: .3em; }
@media (max-width: 860px) { .hero-inner { grid-template-columns: 1fr; padding-block: 40px; } }

/* Strip of recent work */
.strip { display: grid; grid-template-columns: repeat(8, 1fr); }
.strip a { aspect-ratio: 1; overflow: hidden; }
.strip img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.strip a:hover img { transform: scale(1.05); }
@media (max-width: 860px) { .strip { grid-template-columns: repeat(4, 1fr); } }

.section-head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; flex-wrap: wrap; margin-bottom: 20px; }

/* Gallery cards */
.gallery-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 18px; }
.gallery-cards.large { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); margin-top: 28px; }
.gallery-card { position: relative; display: block; border-radius: var(--radius); overflow: hidden; aspect-ratio: 4 / 3; background: var(--walnut); box-shadow: var(--shadow); text-decoration: none; }
.gallery-card img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s, opacity .35s; opacity: .92; }
.gallery-card:hover img { transform: scale(1.04); opacity: 1; }
.gallery-card span { position: absolute; inset: auto 0 0 0; padding: 40px 16px 14px; background: linear-gradient(transparent, rgba(30, 20, 12, .85)); color: #fff; font-family: var(--serif); font-size: 1.25rem; font-weight: 600; }
.gallery-card small { display: block; font-family: var(--sans); font-size: .8rem; font-weight: 400; opacity: .85; }

/* Photo grid + captions */
.crumbs { font-size: .9rem; color: var(--muted); margin-bottom: .5em; }
.crumbs a { color: var(--muted); }
.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; margin: 28px 0; }
.photo-grid figure { margin: 0; }
.photo-grid a { display: block; aspect-ratio: 1; overflow: hidden; border-radius: 6px; background: var(--line); }
.photo-grid img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.photo-grid a:hover img { transform: scale(1.05); }
.photo-grid.with-captions { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 16px; }
.photo-grid figcaption { font-size: .92rem; text-align: center; padding-top: 6px; color: var(--ink-soft); }
.pill-nav { display: flex; flex-wrap: wrap; gap: 8px; border-top: 1px solid var(--line); padding-top: 24px; }
.pill-nav a { padding: 6px 14px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); text-decoration: none; color: var(--ink-soft); font-size: .95rem; }
.pill-nav a:hover { border-color: var(--accent); color: var(--accent); }

/* Wood list: photo + write-up cards */
.jump-list { display: flex; flex-wrap: wrap; gap: 6px; margin: 24px 0 8px; }
.jump-list a { font-size: .85rem; padding: 4px 10px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); text-decoration: none; color: var(--ink-soft); }
.jump-list a:hover { border-color: var(--accent); color: var(--accent); }
.wood-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 520px), 1fr)); gap: 18px; margin: 24px 0 32px; }
.wood-card { display: flex; gap: 18px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; box-shadow: var(--shadow); scroll-margin-top: 90px; }
.wood-card:target { outline: 3px solid var(--accent); outline-offset: 2px; }
.wood-photo { flex: 0 0 140px; align-self: flex-start; aspect-ratio: 1; border-radius: 8px; overflow: hidden; background: var(--line); }
.wood-photo img { width: 100%; height: 100%; object-fit: cover; }
.wood-text h2 { font-size: 1.3rem; margin-bottom: .3em; }
.wood-text .prose p { font-size: .95rem; margin-bottom: .6em; }
.wood-text .prose strong { color: var(--walnut); }
@media (max-width: 560px) {
  .wood-card { flex-direction: column; }
  .wood-photo { flex-basis: auto; width: 100%; aspect-ratio: 16 / 9; }
}

/* Lightbox */
.lb { position: fixed; inset: 0; background: rgba(15, 10, 6, .94); z-index: 50; display: flex; align-items: center; justify-content: center; flex-direction: column; padding: 16px; }
.lb img { max-width: 100%; max-height: calc(100vh - 110px); object-fit: contain; border-radius: 4px; }
.lb-cap { color: #eee; margin-top: 12px; text-align: center; min-height: 1.5em; }
.lb button { position: absolute; background: rgba(255,255,255,.12); color: #fff; border: 0; width: 48px; height: 48px; border-radius: 50%; font-size: 26px; line-height: 1; cursor: pointer; }
.lb button:hover { background: rgba(255,255,255,.25); }
.lb-close { top: 16px; right: 16px; }
.lb-prev { left: 16px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 16px; top: 50%; transform: translateY(-50%); }
.lb-count { position: absolute; top: 26px; left: 20px; color: #bbb; font-size: .9rem; }

/* Shows */
.show-list { display: grid; gap: 16px; margin-top: 24px; }
.show-card { display: flex; gap: 20px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.show-card.past { box-shadow: none; opacity: .8; }
.show-date { flex: 0 0 76px; text-align: center; background: var(--walnut); color: #fff; border-radius: 8px; padding: 8px 4px; align-self: flex-start; }
.show-date span { display: block; line-height: 1.1; }
.show-date .m { text-transform: uppercase; font-size: .8rem; letter-spacing: .1em; color: #f0c9a4; }
.show-date .d { font-family: var(--serif); font-size: 2rem; font-weight: 700; }
.show-date .y { font-size: .8rem; opacity: .8; }
.show-card.past .show-date { background: var(--muted); }
.show-body h3 { margin-bottom: .2em; }
.show-body h3 a { color: var(--walnut); text-decoration: none; }
.show-body h3 a:hover { color: var(--accent); }
.show-body p { margin: 0 0 .2em; }
.show-when { font-weight: 700; color: var(--accent-dark); }
.show-where, .show-sched { color: var(--ink-soft); }
.past-shows { margin-top: 40px; }
.past-shows summary { cursor: pointer; font-weight: 600; color: var(--ink-soft); }
.show-head { display: flex; gap: 32px; justify-content: space-between; align-items: flex-start; flex-wrap: wrap; margin-bottom: 20px; }
.show-logo { max-width: 220px; max-height: 180px; object-fit: contain; }
.facts { display: grid; grid-template-columns: max-content 1fr; gap: 6px 18px; margin: 0; }
.facts dt { font-weight: 700; color: var(--muted); text-transform: uppercase; font-size: .8rem; letter-spacing: .08em; padding-top: 4px; }
.facts dd { margin: 0; }
.embed { position: relative; aspect-ratio: 16 / 9; margin: 28px 0; border-radius: var(--radius); overflow: hidden; background: var(--line); max-width: 900px; }
.embed.map { aspect-ratio: 16 / 7; }
.embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
@media (max-width: 560px) { .show-card { gap: 14px; padding: 16px; } .show-date { flex-basis: 62px; } .embed.map { aspect-ratio: 4 / 3; } }

/* Prose */
.prose { max-width: 70ch; }
.prose h2, .prose h3 { margin-top: 1.4em; }
.prose ul, .prose ol { padding-left: 1.3em; }
.about-teaser { border-top: 1px solid var(--line); }

/* Notices + forms */
.notice { background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--accent); padding: 14px 18px; border-radius: 8px; margin: 20px 0; }
.notice.ok { border-left-color: var(--ok); }
.notice.error { border-left-color: var(--err); }
.form { margin-top: 24px; }
.field-row { margin-bottom: 18px; }
.field-row.two { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 560px) { .field-row.two { grid-template-columns: 1fr; } }
.form label { display: block; font-weight: 600; font-size: .95rem; color: var(--ink-soft); }
.form input[type=text], .form input[type=email], .form input[type=tel], .form input[type=url], .form input[type=date], .form input[type=password], .form input[type=number], .form textarea, .form select {
  display: block; width: 100%; margin-top: 6px; padding: 11px 13px; border: 1px solid #cdbba5; border-radius: 8px; background: #fff; font: inherit; color: var(--ink); font-weight: 400;
}
.form textarea { resize: vertical; }
.form input:focus, .form textarea:focus, .form select:focus { border-color: var(--accent); outline: 2px solid rgba(154, 84, 38, .25); }
[aria-invalid="true"] { border-color: var(--err) !important; }
.field-error { color: var(--err); font-size: .9rem; margin: 4px 0 0; }

/* Footer */
.site-footer { background: var(--walnut); color: #d9c8b4; margin-top: 40px; }
.footer-inner { display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap; padding-block: 36px 20px; }
.footer-inner strong { color: #fff; font-family: var(--serif); font-size: 1.2rem; }
.footer-inner p { margin: .3em 0 0; max-width: 46ch; }
.footer-links { display: flex; gap: 18px; flex-wrap: wrap; align-items: flex-start; }
.footer-links a { color: #f1e2cf; }
.copyright { font-size: .85rem; padding-block: 14px 24px; border-top: 1px solid rgba(255,255,255,.1); color: #a8957f; }
