/* ===========================================================
   Vintage Vulcan Oil Heater Website — stylesheet
   Palette is deliberately drawn from the subject: the amber
   glow of a heater's glass front, aged brochure paper, and
   brass fittings.
   =========================================================== */

:root {
  --ember: #b54a1e;
  --ember-dark: #8f3a16;
  --ember-light: #d97a44;
  --brass: #8c6b3f;
  --paper: #fbf7f0;
  --paper-deep: #f3ecdf;
  --ink: #241b15;
  --ink-soft: #57493d;
  --line: #e4d9c6;
  --white: #ffffff;

  --serif: "Playfair Display", Georgia, "Times New Roman", serif;
  --sans: "Source Sans 3", "Segoe UI", Arial, sans-serif;

  --max-width: 1100px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--sans);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

a { color: var(--ember-dark); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3 {
  font-family: var(--serif);
  color: var(--ink);
  line-height: 1.2;
  margin: 0 0 0.5em;
}

h1 { font-size: clamp(2rem, 4vw, 3rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2rem); }
h3 { font-size: 1.15rem; }

p { margin: 0 0 1em; }

.wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* ---------- header / nav ---------- */
header.site-header {
  background: var(--ink);
  color: var(--paper);
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 3px solid var(--ember);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.85rem 1.5rem;
  max-width: var(--max-width);
  margin: 0 auto;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--white);
  font-family: var(--serif);
  font-size: 1.35rem;
  font-weight: 700;
}
.brand:hover { text-decoration: none; color: var(--ember-light); }

.brand .flame {
  color: var(--ember);
  font-size: 1.4rem;
}

nav.site-nav ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  margin: 0;
  padding: 0;
}

nav.site-nav a {
  color: var(--paper-deep);
  font-size: 0.95rem;
  padding: 0.5rem 0.7rem;
  border-radius: 4px;
  display: block;
}
nav.site-nav a:hover,
nav.site-nav a.active {
  background: rgba(255,255,255,0.08);
  color: var(--white);
  text-decoration: none;
}
nav.site-nav a.active { border-bottom: 2px solid var(--ember); }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--paper-deep);
  color: var(--paper);
  font-size: 1rem;
  padding: 0.4rem 0.7rem;
  border-radius: 4px;
  cursor: pointer;
}

@media (max-width: 820px) {
  .nav-toggle { display: block; }
  nav.site-nav {
    display: none;
    width: 100%;
  }
  nav.site-nav.open { display: block; }
  nav.site-nav ul { flex-direction: column; gap: 0; padding: 0.5rem 0 1rem; }
  .header-inner { flex-wrap: wrap; }
}

/* ---------- hero ---------- */
.hero {
  background: linear-gradient(160deg, var(--ink) 0%, #3a2c22 60%, var(--ember-dark) 130%);
  color: var(--paper);
  padding: 3.5rem 0;
}
.hero .wrap {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 2.5rem;
  align-items: center;
}
.hero h1 { color: var(--white); }
.hero .eyebrow {
  font-family: var(--sans);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.8rem;
  color: var(--ember-light);
  font-weight: 600;
  margin-bottom: 0.6rem;
}
.hero p.lead { font-size: 1.1rem; color: var(--paper-deep); max-width: 46ch; }
.hero-figure img {
  border-radius: 6px;
  box-shadow: 0 18px 40px rgba(0,0,0,0.35);
}
@media (max-width: 780px) {
  .hero .wrap { grid-template-columns: 1fr; }
}

/* ---------- page header (non-home pages) ---------- */
.page-header {
  background: var(--paper-deep);
  border-bottom: 1px solid var(--line);
  padding: 2.4rem 0 2rem;
}
.page-header .eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--brass);
  margin-bottom: 0.4rem;
}
.page-header p.lead { max-width: 65ch; color: var(--ink-soft); font-size: 1.05rem; }

/* ---------- generic sections ---------- */
main { padding: 3rem 0 4rem; }
section + section { margin-top: 3rem; }

.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 1.6rem;
}

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
@media (max-width: 780px) {
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
}

.callout {
  background: var(--paper-deep);
  border-left: 4px solid var(--ember);
  padding: 1.1rem 1.3rem;
  border-radius: 4px;
  margin: 1.5rem 0;
}
.callout.warn { border-left-color: #a13324; background: #fbeae6; }
.callout p:last-child { margin-bottom: 0; }

.btn {
  display: inline-block;
  background: var(--ember);
  color: var(--white);
  padding: 0.65rem 1.3rem;
  border-radius: 5px;
  font-weight: 600;
  font-size: 0.95rem;
}
.btn:hover { background: var(--ember-dark); text-decoration: none; }
.btn.secondary {
  background: transparent;
  color: var(--ink);
  border: 1.5px solid var(--ink);
}
.btn.secondary:hover { background: var(--ink); color: var(--white); }

/* ---------- model table ---------- */
.model-table { width: 100%; border-collapse: collapse; margin-top: 1rem; }
.model-table th, .model-table td {
  text-align: left;
  padding: 0.9rem 1rem;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
}
.model-table th {
  font-family: var(--sans);
  text-transform: uppercase;
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  color: var(--brass);
  border-bottom: 2px solid var(--brass);
}
.model-table img {
  width: 110px;
  height: 82px;
  object-fit: cover;
  border-radius: 4px;
}
.model-table td.model-name { font-weight: 600; }

/* ---------- gallery ---------- */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.1rem;
}
.gallery-item {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
}
.gallery-item img { aspect-ratio: 4 / 3; object-fit: cover; width: 100%; }
.gallery-caption { padding: 0.7rem 0.85rem; }
.gallery-caption .cap-title { font-weight: 600; font-size: 0.92rem; }
.gallery-caption .cap-note { font-size: 0.82rem; color: var(--ink-soft); margin-top: 0.2rem; }

.lightbox {
  position: fixed; inset: 0; background: rgba(20,14,10,0.92);
  display: none; align-items: center; justify-content: center;
  z-index: 100; padding: 2rem;
}
.lightbox.open { display: flex; }
.lightbox img { max-height: 82vh; max-width: 90vw; border-radius: 6px; }
.lightbox-cap { color: var(--paper); text-align: center; margin-top: 0.8rem; max-width: 70ch; }
.lightbox-close {
  position: absolute; top: 1.2rem; right: 1.5rem;
  background: none; border: none; color: var(--paper);
  font-size: 2rem; cursor: pointer; line-height: 1;
}

/* ---------- downloads list ---------- */
.download-list { list-style: none; margin: 0; padding: 0; }
.download-list li {
  padding: 0.85rem 0; border-bottom: 1px solid var(--line);
}
.download-list .file-name { font-weight: 600; }
.download-list .file-name a { font-weight: 600; }
.download-list .file-meta { font-size: 0.85rem; color: var(--ink-soft); }

/* ---------- footer ---------- */
footer.site-footer {
  background: var(--ink);
  color: var(--paper-deep);
  padding: 2.4rem 0;
  margin-top: 3rem;
}
footer.site-footer .wrap {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1.5rem;
}
footer.site-footer a { color: var(--ember-light); }
footer.site-footer .foot-note { font-size: 0.85rem; color: #a99786; max-width: 50ch; }
footer.site-footer h3 { color: var(--paper); font-size: 1rem; margin-bottom: 0.5rem; }

.orphan-note { font-size: 0.85rem; color: var(--ink-soft); font-style: italic; margin-top: 0.6rem; }

/* ---------- hit counter (old-fashioned page counter) ---------- */
.hit-counter-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  margin: 2.5rem auto 0;
  text-align: center;
}
.hit-counter {
  display: inline-flex;
  gap: 3px;
  background: #0a0a0a;
  padding: 8px 10px;
  border-radius: 4px;
  border: 3px solid #3a3a3a;
  box-shadow: inset 0 0 8px rgba(0,0,0,0.9), 0 2px 4px rgba(0,0,0,0.3);
}
.hit-counter .digit {
  font-family: "Courier New", Courier, monospace;
  font-weight: 700;
  font-size: 1.5rem;
  line-height: 1;
  color: #4dff5a;
  background: #000;
  padding: 4px 3px;
  border-radius: 2px;
  min-width: 0.85ch;
  text-align: center;
  text-shadow: 0 0 6px rgba(77,255,90,0.75), 0 0 2px rgba(77,255,90,0.9);
}
.hit-counter-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ink-soft);
  margin: 0;
}
