/* Bede & Co — bedeandco.co.uk
   Editorial, ledger-like: serif throughout, small-caps sans for wayfinding,
   roman-numeral registry rows, gold ampersand as the one ornament.
   No JavaScript, no external requests. Light and dark via prefers-color-scheme. */

:root {
  color-scheme: light dark;
  --paper: #f7f3ec;
  --ink: #221e18;
  --muted: #6f6759;
  --rule: #ddd5c6;
  --rule-strong: #221e18;
  --accent: #94391f;      /* madder red — links */
  --gold: #a8863d;        /* ornament and hairlines only */
  --gold-text: #7c6327;   /* gold that passes contrast as small text */
  --serif: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Palatino, Georgia, "Times New Roman", serif;
  --sans: ui-sans-serif, system-ui, -apple-system, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #171310;
    --ink: #e8e1d2;
    --muted: #a1977f;
    --rule: #362f26;
    --rule-strong: #e8e1d2;
    --accent: #d99270;
    --gold: #b39355;
    --gold-text: #bfa065;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  overflow-x: hidden; /* the hero ghost ampersand bleeds past the column */
  background: var(--paper);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.wrap {
  max-width: 46rem;
  margin: 0 auto;
  padding: 0 1.375rem;
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover { text-decoration-thickness: 2px; }

::selection { background: var(--gold); color: var(--paper); }

/* ---- Masthead ------------------------------------------------------------ */

.masthead {
  text-align: center;
  padding-top: 3.25rem;
}

.masthead .kicker .chunk { white-space: nowrap; }

.masthead .kicker {
  font-family: var(--sans);
  font-size: 0.68rem;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 0.9rem;
}

.masthead h1 {
  font-size: clamp(2.7rem, 8vw, 4rem);
  font-weight: 500;
  letter-spacing: 0.04em;
  line-height: 1.1;
  margin: 0 0 1.4rem;
}

.masthead .amp {
  font-style: italic;
  color: var(--gold);
  padding: 0 0.06em;
}

/* Newspaper thick–thin double rule under the masthead */
.masthead hr {
  border: 0;
  height: 3px;
  border-top: 2.5px solid var(--rule-strong);
  border-bottom: 1px solid var(--rule-strong);
  margin: 0;
}

/* ---- Hero ---------------------------------------------------------------- */

.hero {
  position: relative;
  padding: 4rem 0 1rem;
}

.hero .ghost {
  position: absolute;
  z-index: -1;
  right: -1.5rem;
  top: -1.5rem;
  font-size: 17rem;
  line-height: 1;
  font-style: italic;
  color: var(--gold);
  opacity: 0.08;
  user-select: none;
  pointer-events: none;
}

.hero h2 {
  font-size: clamp(1.7rem, 4.5vw, 2.25rem);
  font-weight: 500;
  line-height: 1.3;
  margin: 0 0 1.1rem;
  max-width: 30ch;
}

.hero p {
  font-size: 1.125rem;
  max-width: 52ch;
  margin: 0;
}

/* ---- Section labels ------------------------------------------------------ */

h2.label {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-family: var(--sans);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--gold-text);
  margin: 4rem 0 1.6rem;
}

h2.label::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--rule);
}

/* ---- Company registry ---------------------------------------------------- */

.registry {
  list-style: none;
  margin: 0;
  padding: 0;
}

.registry li {
  display: grid;
  grid-template-columns: 2.5rem 1fr auto;
  column-gap: 1.1rem;
  border-top: 1px solid var(--rule);
  padding: 1.4rem 0 1.5rem;
}

.registry li:last-child { border-bottom: 1px solid var(--rule); }

.registry .num {
  font-style: italic;
  color: var(--gold-text);
  padding-top: 0.3rem;
}

.registry h3 {
  margin: 0 0 0.35rem;
  font-size: 1.3rem;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.registry .co p {
  margin: 0;
  color: var(--muted);
  font-size: 0.98rem;
  max-width: 33rem;
}

.registry .meta {
  text-align: right;
  font-family: var(--sans);
  padding-top: 0.4rem;
}

.registry .meta .tag {
  display: block;
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.5rem;
}

.registry .meta a { font-size: 0.85rem; }

@media (max-width: 40rem) {
  .registry li {
    grid-template-columns: 1.6rem 1fr;
    row-gap: 0.6rem;
  }
  .registry .meta {
    grid-column: 2;
    text-align: left;
    padding-top: 0;
  }
  .registry .meta .tag { display: inline; margin-right: 0.9rem; }
  .hero .ghost { font-size: 11rem; right: -0.5rem; }
}

/* ---- Prose sections ------------------------------------------------------ */

section p { max-width: 60ch; }

.writeus { margin-top: 1.3rem; }

/* ---- Footer -------------------------------------------------------------- */

footer {
  margin-top: 5rem;
  border-top: 1px solid var(--rule);
  padding: 1.6rem 0 3.5rem;
  font-family: var(--sans);
  font-size: 0.82rem;
  color: var(--muted);
}

footer .row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 2rem;
  justify-content: space-between;
}

footer a { color: inherit; }
footer a:hover { color: var(--accent); }
footer .also { margin-top: 0.4rem; font-size: 0.75rem; }
