:root {
  --pine: #1f3a34;
  --pine-dark: #152824;
  --sand: #f6f1e8;
  --paper: #ffffff;
  --ink: #1d2422;
  --muted: #5a6562;
  --line: #ded6c8;
  --accent: #c8601e;
  --accent-dark: #a54c14;
  --radius: 10px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
}
h1, h2, h3 { line-height: 1.2; margin: 0 0 .5em; color: var(--pine-dark); }
h1 { font-size: clamp(2rem, 5vw, 3.1rem); letter-spacing: -.02em; }
h2 { font-size: clamp(1.5rem, 3.2vw, 2.1rem); letter-spacing: -.01em; }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1em; }
a { color: var(--accent-dark); }
ul { padding-left: 1.2em; margin: 0 0 1em; }
li { margin-bottom: .35em; }
address { font-style: normal; }

.wrap { max-width: 1100px; margin: 0 auto; padding: 0 20px; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 12px; top: 12px; background: var(--paper); padding: 8px 12px; z-index: 10; }

/* Header */
.site-header { background: var(--paper); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 5; }
.bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 64px; }
.brand { font-weight: 800; font-size: 1.15rem; color: var(--pine-dark); text-decoration: none; }
.nav { display: flex; align-items: center; gap: 22px; }
.nav a { color: var(--ink); text-decoration: none; font-weight: 600; font-size: .98rem; }
.nav a:hover { color: var(--accent-dark); }
.nav-toggle { display: none; font: inherit; font-weight: 600; background: none; border: 1px solid var(--line); border-radius: 8px; padding: 8px 14px; cursor: pointer; }

/* Buttons */
.btn {
  display: inline-block; background: var(--accent); color: #fff; font-weight: 700;
  text-decoration: none; padding: 13px 22px; border-radius: 8px; border: 0; font-size: 1rem; cursor: pointer; font-family: inherit;
}
.btn:hover { background: var(--accent-dark); }
.nav .btn { color: #fff; }
.btn-small { padding: 9px 16px; }
.btn-ghost { background: transparent; color: #fff; box-shadow: inset 0 0 0 2px rgba(255,255,255,.7); }
.btn-ghost:hover { background: rgba(255,255,255,.12); }
.btn-outline { background: transparent; color: var(--pine-dark); box-shadow: inset 0 0 0 2px var(--pine); }
.btn-outline:hover { background: var(--pine); color: #fff; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 1.4em; }

/* Sections */
.hero { background: linear-gradient(160deg, var(--pine) 0%, var(--pine-dark) 100%); color: #e9efec; padding: 72px 0 80px; }
.hero h1 { color: #fff; max-width: 20ch; }
.hero p.lead { font-size: 1.2rem; max-width: 58ch; color: #d5dfdb; }
.eyebrow { text-transform: uppercase; letter-spacing: .12em; font-size: .8rem; font-weight: 700; color: #f0a56b; margin-bottom: .8em; }
.section { padding: 64px 0; }
.section.alt { background: var(--sand); }
.section-intro { max-width: 68ch; color: var(--muted); margin-bottom: 2em; }
.narrow { max-width: 760px; }

/* Cards and grids */
.grid { display: grid; gap: 22px; }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; display: flex; flex-direction: column; }
.card > .btn, .card > .actions { margin-top: auto; align-self: flex-start; }
.card .tag, .product-info .tag { font-size: .78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--accent-dark); margin-bottom: .6em; }
.price { font-size: 1.5rem; font-weight: 800; color: var(--pine-dark); margin-bottom: .4em; }
.note { font-size: .93rem; color: var(--muted); }
.callout { border-left: 4px solid var(--accent); background: var(--sand); padding: 16px 20px; border-radius: 0 var(--radius) var(--radius) 0; margin: 1.5em 0; }
.section.alt .callout { background: var(--paper); }

/* Photos, renderings and their placeholders */
.media { margin: 0 0 16px; border-radius: var(--radius); overflow: hidden; aspect-ratio: 4 / 3; background: var(--sand); }
.media-wide { aspect-ratio: 16 / 9; }
.media-square { aspect-ratio: 1; }
.media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.media-render { aspect-ratio: 1; background: #fff; border: 1px solid var(--line); }
.media-render img { object-fit: contain; padding: 6%; }
.render-label { font-size: .82rem; color: var(--muted); margin: -8px 0 14px; }
.ph {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
  text-align: center; padding: 16px; border: 2px dashed #b9b1a3; color: var(--muted); font-size: .9rem;
  background: repeating-linear-gradient(45deg, #f6f1e8, #f6f1e8 12px, #efe8da 12px, #efe8da 24px);
}
.ph-kind { font-weight: 800; text-transform: uppercase; letter-spacing: .1em; font-size: .75rem; color: var(--accent-dark); }
.ph code { font-size: .78rem; overflow-wrap: anywhere; }
.hero .ph { background: rgba(255,255,255,.06); border-color: rgba(255,255,255,.4); color: #d5dfdb; }
.hero .ph-kind { color: #f0a56b; }
.hero-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: center; }
.hero-grid .media { margin: 0; }
.gallery { margin-top: 22px; }
.gallery .media { margin: 0; }

/* Gallery carousel ([[gallery: ...]] blocks) */
.gallery-carousel { position: relative; }
.gallery-track {
  display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth;
  gap: 16px; border-radius: var(--radius); scrollbar-width: thin;
}
.gallery-track:focus-visible { outline: 3px solid #f0a56b; outline-offset: 2px; }
.gallery-slide { flex: 0 0 100%; scroll-snap-align: center; margin: 0; }
.gallery-stage { aspect-ratio: 3 / 2; max-height: 70vh; width: 100%; background: var(--pine-dark); border-radius: var(--radius); overflow: hidden; position: relative; }
.gallery-stage img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; display: block; cursor: zoom-in; }
.is-render .gallery-stage { background: #fff; border: 1px solid var(--line); }
.gallery-stage .ph { position: absolute; inset: 0; }
.gallery-slide figcaption { padding: 10px 2px 0; color: var(--muted); font-size: .95rem; }
.gallery-tag, .gallery-off { font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--accent-dark); margin-right: 6px; }
.gallery-off { display: block; background: #b45309; color: #fff; padding: 8px 12px; border-radius: 8px; letter-spacing: 0; text-transform: none; font-size: .9rem; }
.gallery-controls { display: none; align-items: center; justify-content: center; gap: 16px; margin-top: 12px; }
.gallery-carousel.js .gallery-controls { display: flex; }
.gallery-carousel.js .gallery-track { scrollbar-width: none; }
.gallery-carousel.js .gallery-track::-webkit-scrollbar { display: none; }
.gallery-controls button, .lightbox button {
  font: inherit; font-size: 1.6rem; line-height: 1; width: 44px; height: 44px; border-radius: 50%;
  border: 1px solid var(--line); background: var(--paper); color: var(--pine-dark); cursor: pointer;
}
.gallery-controls button:hover { background: var(--pine); color: #fff; }
.gallery-controls button:disabled { opacity: .35; cursor: default; background: var(--paper); color: var(--pine-dark); }
.gallery-controls button:focus-visible, .lightbox button:focus-visible { outline: 3px solid #f0a56b; outline-offset: 2px; }
.gallery-count { min-width: 4.5em; text-align: center; font-weight: 600; color: var(--muted); font-variant-numeric: tabular-nums; }

/* Full-size view (opened by clicking a gallery image) */
.lightbox { width: 100vw; height: 100vh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: rgba(10, 18, 16, .96); color: #e9efec; }
.lightbox::backdrop { background: rgba(10, 18, 16, .9); }
.lightbox[open] { display: flex; flex-direction: column; }
.lightbox-stage { flex: 1; min-height: 0; position: relative; margin: 56px 12px 8px; }
.lightbox-stage img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; display: block; }
.lightbox-caption { text-align: center; padding: 0 16px 6px; color: #d5dfdb; }
.lightbox-caption .gallery-tag { color: #f0a56b; }
.lightbox-bar { display: flex; align-items: center; justify-content: center; gap: 16px; padding: 6px 0 18px; }
.lightbox-bar .gallery-count { color: #d5dfdb; }
.lightbox-close { position: absolute; top: 10px; right: 12px; }

/* Product listings: line page cards and product pages (build.ps1, "Product listings" in README.md) */
.product-list { margin-bottom: 40px; }
.product-list > .note { margin-top: -.3em; }
.product-card { padding: 18px; color: inherit; text-decoration: none; transition: border-color .15s, box-shadow .15s; }
.product-card:hover { border-color: var(--pine); box-shadow: 0 6px 18px rgba(31, 58, 52, .12); }
.product-card .media { margin: -18px -18px 16px; border-radius: var(--radius) var(--radius) 0 0; }
.product-card h4 { font-size: 1.15rem; line-height: 1.25; margin: 0 0 .4em; color: var(--pine-dark); }
.product-card .product-price { margin: auto 0 0; font-weight: 700; color: var(--pine-dark); }
.product-card .gallery-off { margin-bottom: 10px; }
.product-top { padding-top: 28px; }
.crumbs { font-size: .93rem; color: var(--muted); margin-bottom: 18px; }
.product-top .wrap > .gallery-off { margin-bottom: 22px; }
.product-top .wrap > .gallery-off ul { margin: .4em 0 0; }
.product-grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: 40px; align-items: start; }
.product-media { min-width: 0; }
.product-info h1 { font-size: clamp(1.8rem, 4vw, 2.5rem); margin-bottom: .25em; }
.product-fits { font-weight: 600; color: var(--muted); }
.product-status { display: inline-block; font-size: .8rem; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--pine-dark); background: var(--sand); border-radius: 999px; padding: 5px 12px; }
.product-status.is-soon { color: #fff; background: var(--accent-dark); }
.product-info .actions { margin: 0 0 1em; }
table.specs th { background: var(--sand); color: var(--pine-dark); width: 38%; }
.product-details > div { min-width: 0; }
.product-details h3 { margin-top: 1.4em; }
.product-details .table-wrap + h3 { margin-top: 1.6em; }
table.variants td code { font-size: .85rem; white-space: nowrap; }
.section.alt table.specs th { background: var(--paper); border-right: 1px solid var(--line); }

.steps { counter-reset: step; list-style: none; padding: 0; }
.steps li { counter-increment: step; position: relative; padding-left: 52px; margin-bottom: 1.1em; }
.steps li::before {
  content: counter(step); position: absolute; left: 0; top: 0; width: 36px; height: 36px; border-radius: 50%;
  background: var(--pine); color: #fff; font-weight: 700; display: grid; place-items: center;
}

/* Tables */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); }
th, td { text-align: left; padding: 14px 16px; border-bottom: 1px solid var(--line); }
th { background: var(--pine); color: #fff; font-size: .9rem; }
tr:last-child td { border-bottom: 0; }

/* FAQ */
details { border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); padding: 0 20px; margin-bottom: 10px; }
summary { cursor: pointer; font-weight: 700; padding: 16px 0; color: var(--pine-dark); }
details p { margin-bottom: 16px; }

/* Forms */
form.form { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; }
.field { margin-bottom: 16px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
label, legend { display: block; font-weight: 600; font-size: .95rem; margin-bottom: 6px; }
input[type=text], input[type=email], input[type=tel], input[type=date], select, textarea {
  width: 100%; font: inherit; padding: 11px 12px; border: 1px solid #b9b1a3; border-radius: 8px; background: #fff; color: var(--ink);
}
input:focus, select:focus, textarea:focus, .btn:focus-visible, a:focus-visible, summary:focus-visible { outline: 3px solid #f0a56b; outline-offset: 2px; }
textarea { min-height: 130px; resize: vertical; }
fieldset { border: 0; padding: 0; margin: 0 0 16px; }
.checks label { font-weight: 400; display: flex; gap: 8px; align-items: center; margin-bottom: 4px; }
.hidden { position: absolute; left: -9999px; }

/* Footer */
.site-footer { background: var(--pine-dark); color: #c9d4d0; padding: 52px 0 28px; font-size: .95rem; }
.site-footer a { color: #e9efec; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 32px; }
.footer-grid nav a { display: block; text-decoration: none; margin-bottom: 8px; }
.footer-grid nav a:hover { text-decoration: underline; }
.footer-brand { font-weight: 800; font-size: 1.15rem; color: #fff; }
.footer-head { font-weight: 700; color: #fff; text-transform: uppercase; font-size: .8rem; letter-spacing: .1em; }
.legal { margin-top: 32px; padding-top: 22px; border-top: 1px solid rgba(255,255,255,.15); font-size: .85rem; color: #a6b4af; }

@media (max-width: 1000px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 860px) {
  .grid-4, .grid-3, .grid-2, .footer-grid, .field-row, .hero-grid, .product-grid { grid-template-columns: 1fr; }
  .product-grid { gap: 24px; }
  .nav-toggle { display: block; }
  .nav { display: none; position: absolute; left: 0; right: 0; top: 64px; background: var(--paper); border-bottom: 1px solid var(--line); flex-direction: column; align-items: flex-start; padding: 18px 20px; gap: 16px; }
  .nav.open { display: flex; }
  .hero { padding: 48px 0 56px; }
  .section { padding: 44px 0; }
}
