/* ============================================================
   OILFIELD PROS design system
   Type + palette matched to the live oilfieldpros.com site:
   Outfit display, Inter body, deep blood-red #9b0000/#b30000,
   petroleum-navy accent #0a2434, charcoal + grayscale neutrals,
   photo-led hero, soft white cards on a light ground.
   BEM naming. html at 62.5% so 1rem = 10px.
   Fonts load from /assets/fonts/fonts.css (local woff2).
   ============================================================ */

:root {
  --primary: #9b0000;
  --primary-bright: #b30000;
  --primary-soft: #f2f2f2;   /* heading accents on dark stay near-white, matching the live site */
  --secondary: #121212;
  --navy: #0a2434;           /* petroleum-navy base color from the live site */
  --tertiary: #404040;

  --bg-body: #ffffff;
  --bg-surface: #f5f5f5;
  --bg-dark: #0f0f0f;      /* neutral near-black chrome (header/footer/dark bands) - NO warm/brown tint */
  --bg-dark-2: #1a1a1a;    /* raised neutral near-black for strips/panels */

  --text-body: #404040;
  --text-title: #121212;
  --text-invert: #ffffff;
  --text-muted: #6b6b6b;

  --border-primary: #e4e4e4;
  --border-strong: #121212;
  --shadow-primary: 0 1px 3px rgba(18,18,18,0.06), 0 8px 24px rgba(18,18,18,0.06);
  --shadow-hover: 0 2px 6px rgba(18,18,18,0.08), 0 14px 34px rgba(18,18,18,0.10);

  --text-xs: clamp(1.1rem, 1rem + 0.2vw, 1.2rem);
  --text-s:  clamp(1.3rem, 1.2rem + 0.3vw, 1.5rem);
  --text-m:  clamp(1.5rem, 1.4rem + 0.4vw, 1.7rem);
  --text-l:  clamp(1.8rem, 1.6rem + 0.7vw, 2.4rem);
  --text-xl: clamp(2.4rem, 2rem + 1.4vw, 3.6rem);
  --text-2xl: clamp(3.2rem, 2.4rem + 2.6vw, 5.6rem);
  --text-3xl: clamp(4.8rem, 3.2rem + 6vw, 11.4rem);

  --space-xs: clamp(0.4rem, 0.4rem + 0.2vw, 0.8rem);
  --space-s:  clamp(0.8rem, 0.7rem + 0.4vw, 1.2rem);
  --space-m:  clamp(1.6rem, 1.4rem + 0.6vw, 2.4rem);
  --space-l:  clamp(2.4rem, 2rem + 1.2vw, 4rem);
  --space-xl: clamp(4rem, 3.2rem + 2.4vw, 6.4rem);
  --space-2xl: clamp(6.4rem, 4.8rem + 4vw, 10.4rem);
  --space-3xl: clamp(9.6rem, 7rem + 6vw, 14.4rem);

  --gap-xs: 0.8rem;
  --gap-s: 1.2rem;
  --gap-m: clamp(1.6rem, 1.4rem + 0.6vw, 2.4rem);
  --gap-l: clamp(2.4rem, 2rem + 1.2vw, 4rem);
  --gap-xl: clamp(4rem, 3.2rem + 2.4vw, 6.4rem);

  --radius-xs: 0.2rem;
  --radius-s: 0.4rem;
  --radius-m: 0.8rem;
  --radius-l: 1.2rem;
  --radius-xl: 1.6rem;

  --font-display: "Outfit", "Inter", -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-body: "Inter", -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-mono: "Inter", -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  --measure: 60ch;
  --container: 122rem;
}

/* ---------- reset & base ---------- */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { font-size: 62.5%; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-body);
  font-size: var(--text-m);
  line-height: 1.65;
  color: var(--text-body);
  background: var(--bg-body);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
button { font: inherit; }
:focus-visible { outline: 3px solid var(--primary); outline-offset: 3px; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}

.container { max-width: var(--container); margin-inline: auto; padding-inline: var(--space-m); }
.container--narrow { max-width: 84rem; }

.u-visually-hidden {
  position: absolute; width: 1px; height: 1px; margin: -1px;
  clip-path: inset(50%); overflow: hidden; white-space: nowrap;
}

/* Keyboard skip link: off-screen until focused, then pinned top-left. */
.skip-link {
  position: absolute; left: var(--space-s); top: -6rem; z-index: 100;
  background: var(--primary); color: #fff; text-decoration: none;
  font-family: var(--font-display); font-weight: 600; font-size: var(--text-s);
  padding: 0.9rem 1.6rem; border-radius: var(--radius-s);
  transition: top 0.15s ease;
}
.skip-link:focus { top: var(--space-s); }

/* ---------- type helpers ---------- */
.kicker {
  display: inline-block; font-family: var(--font-mono); font-size: var(--text-xs);
  letter-spacing: 0.22em; text-transform: none; color: var(--primary);
  border-top: 3px solid var(--primary); padding-top: 0.8rem; margin-bottom: var(--space-s);
}
.prose { max-width: var(--measure); }
.prose h2 { font-family: var(--font-display); font-weight: 600; font-size: var(--text-xl); text-transform: none; letter-spacing: 0.01em; color: var(--text-title); margin: var(--space-l) 0 var(--space-s); line-height: 1.1; }
.prose h3 { font-family: var(--font-display); font-weight: 600; font-size: var(--text-l); text-transform: none; letter-spacing: 0.01em; color: var(--text-title); margin: var(--space-m) 0 var(--space-xs); line-height: 1.15; }
.prose p, .prose ul, .prose ol { margin-bottom: var(--space-s); }
.prose ul, .prose ol { padding-left: 2.2rem; }
.prose a { color: var(--primary); }
.prose a:hover { color: var(--primary-bright); }
.prose blockquote { border-left: 3px solid var(--primary); padding-left: var(--space-m); color: var(--text-muted); margin-bottom: var(--space-s); }
.prose code { font-family: var(--font-mono); font-size: 0.9em; background: var(--bg-surface); padding: 0.2rem 0.5rem; border-radius: var(--radius-xs); }
.prose pre { background: var(--bg-surface); border: 1px solid var(--border-primary); border-radius: var(--radius-s); padding: var(--space-m); overflow-x: auto; margin-bottom: var(--space-s); }
.prose pre code { background: none; padding: 0; }
.prose img { border-radius: var(--radius-m); margin-block: var(--space-m); }
.prose hr { border: 0; border-top: 1px solid var(--border-primary); margin-block: var(--space-l); }

/* Spec tables. The wrapper scrolls itself so a wide table never scrolls the page. */
.tablewrap { overflow-x: auto; margin-bottom: var(--space-m); -webkit-overflow-scrolling: touch; }
.prose table { border-collapse: collapse; width: 100%; min-width: 30rem; font-size: var(--text-s); }
.prose thead th { font-family: var(--font-display); font-weight: 700; font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-muted); text-align: left; padding: 0 var(--space-s) var(--space-xs); border-bottom: 2px solid var(--border-primary); white-space: nowrap; }
.prose tbody td { padding: var(--space-xs) var(--space-s); border-bottom: 1px solid var(--border-primary); vertical-align: top; }
.prose tbody tr:last-child td { border-bottom: 0; }
.prose tbody td:first-child { font-weight: 600; color: var(--text-title); }

/* ---------- buttons ---------- */
.btn {
  display: inline-block; cursor: pointer; text-decoration: none; border: 0;
  font-family: var(--font-display); font-weight: 600; font-size: var(--text-l);
  letter-spacing: 0.06em; text-transform: none; line-height: 1;
  padding: 1.2rem 2.4rem; border-radius: var(--radius-s);
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
.btn--primary { background: var(--primary); color: #fff; }
.btn--primary:hover { background: var(--primary-bright); }
.btn--dark { background: var(--secondary); color: #fff; }
.btn--dark:hover { background: var(--tertiary); }
.btn--ghost { background: transparent; color: var(--text-title); border: 1px solid var(--border-strong); }
.btn--ghost:hover { background: var(--secondary); color: #fff; }
.btn--ghost-invert { background: transparent; color: #fff; border: 1px solid rgba(255,255,255,0.7); }
.btn--ghost-invert:hover { background: var(--primary); border-color: var(--primary); }
.btn--small { font-size: var(--text-m); padding: 0.9rem 1.6rem; }

/* ---------- header ---------- */
.header { position: relative; z-index: 40; background: var(--bg-dark); border-bottom: 3px solid var(--primary); }
/* Homepage previously floated the header over the photo; now it's a solid bar above it. */
.header--overlay { position: relative; inset: auto; background: var(--bg-dark); }
.header__inner { display: flex; align-items: center; gap: var(--gap-m); padding-block: var(--space-m); }
.brand { text-decoration: none; display: flex; align-items: center; gap: 1rem; }
.brand__badge {
  font-family: var(--font-display); font-weight: 700; font-size: 2rem; line-height: 1;
  background: var(--primary); color: #fff; padding: 0.6rem 0.8rem;
  border-radius: var(--radius-s); letter-spacing: 0.03em;
}
.brand__name {
  font-family: var(--font-display); font-weight: 700; font-size: 2.4rem; letter-spacing: 0.03em;
  color: var(--text-invert); text-transform: none; white-space: nowrap;
}
.brand__name em { font-style: normal; color: #d42a2a; text-transform: uppercase; } /* matches footer "Pros" accent */
.header__cta {
  display: none; /* hidden on mobile; lives in the nav drawer instead */
  margin-left: auto; text-decoration: none;
  font-family: var(--font-display); font-weight: 600; font-size: var(--text-m); letter-spacing: 0.08em; text-transform: none;
  color: var(--text-invert); border: 1px solid rgba(255,255,255,0.7); border-radius: var(--radius-s); padding: 0.9rem 1.6rem;
  transition: background 0.15s ease, border-color 0.15s ease;
  white-space: nowrap;
}
.header__cta:hover { background: var(--primary); border-color: var(--primary); }
.header__toggle {
  display: grid; place-items: center; gap: 0; cursor: pointer;
  margin-left: auto;
  background: transparent; border: 1px solid rgba(255,255,255,0.7); border-radius: var(--radius-s);
  color: #fff; width: 4rem; height: 4rem; font-size: 1.8rem; line-height: 1;
}
.nav__link--cta { color: #fff; }
.nav__link--cta::before { content: "+ "; color: var(--primary-bright); }
.nav { display: none; }
.nav--open {
  display: block; position: absolute; top: 100%; left: 0; right: 0;
  background: var(--bg-dark); border-top: 1px solid rgba(255,255,255,0.15);
  padding: var(--space-s) var(--space-m) var(--space-m);
}
.nav__link {
  display: block; color: rgba(255,255,255,0.92); text-decoration: none;
  font-family: var(--font-display); font-weight: 500; font-size: 1.8rem; letter-spacing: 0.06em; text-transform: none;
  padding-block: 1rem; border-bottom: 1px solid rgba(255,255,255,0.1);
}
.nav__link:hover { color: #fff; }
@media (min-width: 1000px) {
  .header__cta { display: inline-block; }
  .header__toggle { display: none; }
  .nav, .nav--open {
    display: flex; position: static; gap: var(--gap-m); margin-left: var(--space-l);
    background: transparent; border: 0; padding: 0;
  }
  .nav__link { padding-block: 0; border: 0; font-size: 1.7rem; }
  .nav__link--cta { display: none; } /* desktop uses the standalone header button */
  .nav__link:hover { text-decoration: underline; text-underline-offset: 0.5em; text-decoration-color: var(--primary-bright); text-decoration-thickness: 3px; }
}

/* ---------- photo hero (home) ---------- */
.hero { position: relative; background: var(--bg-dark); color: var(--text-invert); overflow: hidden; }
.hero__photo {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; object-position: center 30%;
  filter: contrast(1.05) saturate(0.9);
}
.hero__scrim {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(12,12,12,0.48) 0%, rgba(12,12,12,0.52) 42%, rgba(12,12,12,0.92) 100%);
}
.hero__inner { position: relative; padding-block: clamp(6.4rem, 4rem + 6vw, 11rem) clamp(2.4rem, 1.6rem + 2vw, 4rem); }
.hero__kicker {
  font-family: var(--font-mono); font-size: var(--text-xs); letter-spacing: 0.22em; text-transform: none;
  color: #c9c4bf; margin-bottom: var(--space-m);
}
.hero__title {
  font-family: var(--font-display); font-weight: 700;
  font-size: var(--text-2xl); line-height: 0.95; text-transform: none;
  letter-spacing: 0.01em; max-width: 16ch;
  text-shadow: 0 2px 24px rgba(0,0,0,0.35);
}
.hero__title em { font-style: normal; color: var(--primary-bright); }
.hero__lede { max-width: 52ch; margin-top: var(--space-m); font-size: var(--text-l); line-height: 1.5; color: rgba(255,255,255,0.88); }
.hero__stats {
  position: relative; display: grid; grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid rgba(255,255,255,0.35); margin-top: var(--space-xl);
}
.hero__stat { padding: var(--space-m) var(--space-s); border-right: 1px solid rgba(255,255,255,0.2); }
.hero__stat:last-child { border-right: 0; }
.hero__stat b { display: block; font-family: var(--font-display); font-weight: 600; font-size: var(--text-xl); letter-spacing: 0.02em; color: #fff; }
.hero__stat span { font-family: var(--font-mono); font-size: var(--text-xs); text-transform: none; letter-spacing: 0.12em; color: rgba(255,255,255,0.65); }

/* ---------- page head (inner pages) ---------- */
.pagehead { background: var(--bg-dark); color: var(--text-invert); }
.pagehead__inner { padding-block: var(--space-xl); }
.pagehead__title {
  font-family: var(--font-display); font-weight: 700; font-size: var(--text-2xl);
  line-height: 1; text-transform: none; letter-spacing: 0.01em;
}
.pagehead__title em { font-style: normal; color: var(--primary-soft); }
.pagehead__note { margin-top: var(--space-s); color: rgba(255,255,255,0.8); max-width: var(--measure); font-size: var(--text-s); }
.pagehead__kicker {
  font-family: var(--font-mono); font-size: var(--text-xs); letter-spacing: 0.22em; text-transform: none;
  color: #c9c4bf; margin-bottom: var(--space-s);
}

/* ---------- breadcrumbs ---------- */
.crumbs { font-family: var(--font-mono); font-size: var(--text-xs); text-transform: none; letter-spacing: 0.08em; color: rgba(255,255,255,0.6); margin-bottom: var(--space-s); }
.crumbs a { color: rgba(255,255,255,0.8); text-decoration: none; }
.crumbs a:hover { color: #fff; text-decoration: underline; }

/* ---------- search bar ---------- */
.search {
  display: flex; margin-top: var(--space-l); max-width: 64rem;
  background: #fff; border-radius: var(--radius-s); overflow: hidden;
  box-shadow: 0 10px 30px rgba(0,0,0,0.25);
}
.search--flat { box-shadow: var(--shadow-primary); border: 1px solid var(--border-primary); margin-top: 0; }
.search__input {
  flex: 1; min-width: 0; border: 0; font: inherit; font-size: var(--text-m);
  padding: 1.6rem 1.6rem; color: var(--text-title);
}
.search__input:focus { outline: none; }
.search:focus-within { outline: 3px solid var(--primary-bright); outline-offset: 3px; }
.search__btn {
  border: 0; cursor: pointer; background: var(--primary); color: #fff;
  font-family: var(--font-display); font-weight: 600; font-size: var(--text-l); letter-spacing: 0.08em; text-transform: none;
  padding: 0 2.6rem; transition: background 0.15s ease;
}
.search__btn:hover { background: var(--primary-bright); }

/* ---------- sections ---------- */
.section { padding-block: var(--space-2xl); }
.section--tint { background: var(--bg-surface); }
.section__head { margin-bottom: var(--space-l); }
.section__title {
  font-family: var(--font-display); font-weight: 600; font-size: var(--text-2xl);
  line-height: 1; text-transform: none; letter-spacing: 0.01em; color: var(--text-title);
}
.section__sub { margin-top: var(--space-s); max-width: var(--measure); }
.section__more {
  display: inline-block; margin-top: var(--space-l); text-decoration: none;
  font-family: var(--font-display); font-weight: 600; font-size: var(--text-l); letter-spacing: 0.06em; text-transform: none;
  color: var(--text-title); border-bottom: 3px solid var(--primary); padding-bottom: 0.2rem;
}
.section__more:hover { color: var(--primary); }

/* ---------- category tiles ---------- */
.cats { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--gap-s); }
.cat {
  min-width: 0;
  background: var(--bg-body); border: 1px solid var(--border-primary); border-radius: var(--radius-m);
  box-shadow: var(--shadow-primary);
  padding: 1.6rem 1.4rem; text-decoration: none;
  display: grid; gap: 0.4rem; align-content: start;
  transition: background 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}
.cat:hover { background: var(--primary); box-shadow: var(--shadow-hover); transform: translateY(-2px); }
.cat__name { font-family: var(--font-display); font-weight: 600; font-size: var(--text-l); line-height: 1.05; text-transform: none; letter-spacing: 0.02em; color: var(--text-title); overflow-wrap: anywhere; -webkit-hyphens: auto; hyphens: auto; }
.cat__count { font-family: var(--font-mono); font-size: var(--text-xs); letter-spacing: 0.1em; text-transform: none; color: var(--text-muted); }
.cat__desc { font-size: var(--text-s); color: var(--text-body); }
.cat:hover .cat__name, .cat:hover .cat__count, .cat:hover .cat__desc { color: #fff; }
@media (min-width: 500px) { .cats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 700px) { .cats { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1000px) { .cats { grid-template-columns: repeat(4, minmax(0, 1fr)); } .cats--three { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* ---------- category list ---------- */
.catlist { list-style: none; margin: 0; padding: 0; counter-reset: cat; }
.catlist__item {
  position: relative;
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-s);
  padding: var(--space-l) 0 var(--space-l) var(--space-l);
  border-top: 1px solid var(--border-primary);
}
.catlist__item:last-child { border-bottom: 1px solid var(--border-primary); }
/* red index rule down the left edge */
.catlist__item::before {
  counter-increment: cat;
  content: counter(cat, decimal-leading-zero);
  position: absolute;
  left: 0; top: var(--space-l);
  font-family: var(--font-mono); font-size: var(--text-xs); font-weight: 600;
  letter-spacing: 0.12em; color: var(--text-muted);
}
.catlist__item::after {
  content: ""; position: absolute; left: -1px; top: -1px; bottom: -1px; width: 2px;
  background: var(--primary); opacity: 0; transition: opacity 0.15s ease;
}
.catlist__item:hover::after { opacity: 1; }
.catlist__item:hover::before { color: var(--primary); }

.catlist__head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.4rem var(--gap-m); justify-content: space-between; }
.catlist__name {
  font-family: var(--font-display); font-weight: 600; font-size: var(--text-l);
  line-height: 1.1; letter-spacing: 0.01em; color: var(--text-title); text-decoration: none;
}
.catlist__name:hover { color: var(--primary); }
.catlist__count {
  flex: none;
  font-family: var(--font-mono); font-size: var(--text-xs); font-weight: 500;
  letter-spacing: 0.06em; color: var(--text-muted); white-space: nowrap;
}
.catlist__count strong { color: var(--text-title); font-weight: 600; }
.catlist__desc { margin: 0; font-size: var(--text-s); color: var(--text-body); max-width: var(--measure); }
.catlist__children { list-style: none; margin: 0.2rem 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.6rem; }
.catlist__children a {
  display: inline-block;
  font-size: var(--text-xs); line-height: 1.4; color: var(--text-body); text-decoration: none;
  padding: 0.5rem 1rem;
  background: var(--bg-surface); border: 1px solid var(--border-primary); border-radius: 999px;
  transition: background 0.12s ease, color 0.12s ease, border-color 0.12s ease;
}
.catlist__children a:hover { background: var(--navy); border-color: var(--navy); color: #fff; }
@media (min-width: 700px) {
  .catlist__item { padding-left: 5.6rem; }
  .catlist__item::before { font-size: var(--text-s); }
}
.catlist__item { scroll-margin-top: var(--space-l); }

/* ---------- directory layout (sidebar + list) ---------- */
.dirlayout { display: grid; grid-template-columns: 1fr; gap: var(--gap-l); }
.dirside { display: grid; gap: var(--gap-m); align-content: start; }
.dirside__search { margin: 0; }
.dirside__nav { display: none; }
.dirside__label {
  font-family: var(--font-mono); font-size: var(--text-xs); font-weight: 600;
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-muted);
  padding-bottom: var(--space-s); border-bottom: 1px solid var(--border-primary); margin-bottom: 0.4rem;
}
.dirside__nav ul { list-style: none; margin: 0; padding: 0; }
.dirside__nav a {
  display: flex; align-items: baseline; justify-content: space-between; gap: 1rem;
  padding: 0.7rem 0.4rem; text-decoration: none; border-radius: var(--radius-s);
  color: var(--text-body); font-size: var(--text-s); line-height: 1.25;
  transition: background 0.12s ease, color 0.12s ease;
}
.dirside__nav a:hover { background: var(--bg-surface); color: var(--primary); }
.dirside__nav-count { flex: none; font-family: var(--font-mono); font-size: var(--text-xs); color: var(--text-muted); }
.dirside__nav a:hover .dirside__nav-count { color: var(--primary); }

.dirside__cta {
  background: var(--navy); color: #fff; border-radius: var(--radius-m);
  padding: var(--space-m); display: grid; gap: 0.8rem; align-content: start;
}
.dirside__cta-title { font-family: var(--font-display); font-weight: 600; font-size: var(--text-l); line-height: 1.1; }
.dirside__cta-note { font-size: var(--text-s); color: rgba(255,255,255,0.78); line-height: 1.5; }
.dirside__cta .btn { justify-self: start; margin-top: 0.2rem; }

@media (min-width: 900px) {
  .dirlayout { grid-template-columns: minmax(0, 1fr) 30rem; gap: var(--gap-xl); align-items: start; }
  .dirmain { grid-column: 1; grid-row: 1; }
  .dirside { grid-column: 2; grid-row: 1; position: sticky; top: var(--space-m); }
  .dirside__nav { display: block; }
}

/* ---------- listing cards ---------- */
.cards { display: grid; gap: var(--gap-m); }
.card {
  min-width: 0;
  background: var(--bg-body); border: 1px solid var(--border-primary); border-radius: var(--radius-m);
  box-shadow: var(--shadow-primary); text-decoration: none;
  display: grid; gap: 0.8rem; padding: var(--space-m); align-content: start;
  transition: box-shadow 0.15s ease, transform 0.15s ease;
}
.card:hover { box-shadow: var(--shadow-hover); transform: translateY(-2px); }
.card__top { display: flex; justify-content: space-between; align-items: flex-start; gap: var(--gap-s); }
.card__heading { display: flex; flex-direction: column; gap: 0.2rem; min-width: 0; }
.card__logo { flex: none; height: 5.6rem; width: auto; max-width: 12rem; object-fit: contain; object-position: right center; border-radius: var(--radius-s); }
.card__avatar {
  width: 5.6rem; height: 5.6rem; border-radius: var(--radius-s); flex: none;
  background: var(--bg-surface); color: var(--primary);
  display: grid; place-items: center;
  font-family: var(--font-display); font-weight: 700; font-size: 2rem; text-transform: none;
}
.card__name { font-family: var(--font-display); font-weight: 600; font-size: clamp(1.6rem, 1.45rem + 0.5vw, 2rem); line-height: 1.05; text-transform: none; letter-spacing: 0.02em; color: var(--text-title); overflow-wrap: anywhere; -webkit-hyphens: auto; hyphens: auto; }
.card__city { font-family: var(--font-mono); font-size: var(--text-xs); letter-spacing: 0.08em; text-transform: none; color: var(--primary); white-space: nowrap; }
.card__desc { font-size: var(--text-s); }
.card__tags { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-top: 0.4rem; }
.tag {
  font-family: var(--font-mono); font-size: var(--text-xs); text-transform: none; letter-spacing: 0.05em;
  background: var(--bg-surface); border-radius: var(--radius-s); padding: 0.3rem 0.9rem; color: var(--tertiary);
  text-decoration: none;
}
a.tag:hover { background: var(--primary); color: #fff; }
@media (min-width: 700px) { .cards { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1000px) { .cards { grid-template-columns: repeat(3, 1fr); } .cards--two { grid-template-columns: 1fr 1fr; } }

/* ---------- photo interlude band ---------- */
.interlude { position: relative; background: var(--bg-dark); color: var(--text-invert); overflow: hidden; }
.interlude__photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 65%; filter: saturate(0.85); }
.interlude__scrim { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(18,18,18,0.88) 0%, rgba(18,18,18,0.55) 60%, rgba(18,18,18,0.25) 100%); }
.interlude__inner { position: relative; padding-block: var(--space-2xl); }
.interlude__line {
  font-family: var(--font-display); font-weight: 600; font-size: var(--text-xl);
  line-height: 1.1; text-transform: none; letter-spacing: 0.01em; max-width: 26ch;
}
.interlude__line em { font-style: normal; color: var(--primary-soft); }
.interlude__note { margin-top: var(--space-s); font-size: var(--text-s); color: rgba(255,255,255,0.8); max-width: 48ch; }
.interlude__cta { margin-top: var(--space-m); }

/* ---------- article list rows ---------- */
.posts { display: grid; border-top: 1px solid var(--border-primary); }
.post { padding: var(--space-l) 0; border-bottom: 1px solid var(--border-primary); text-decoration: none; display: grid; gap: 0.6rem; }
.post__date { font-family: var(--font-mono); font-size: var(--text-xs); letter-spacing: 0.15em; text-transform: none; color: var(--primary); }
.post__title {
  font-family: var(--font-display); font-weight: 600; font-size: var(--text-xl);
  line-height: 1.05; text-transform: none; letter-spacing: 0.01em; color: var(--text-title);
  transition: color 0.15s ease;
}
.post:hover .post__title { color: var(--primary); }
.post__excerpt { font-size: var(--text-s); max-width: var(--measure); }

/* ---------- resources ---------- */
.tools { display: grid; gap: var(--gap-s); }
.tool {
  display: flex; align-items: baseline; gap: var(--gap-s);
  background: var(--bg-body); border: 1px solid var(--border-primary); border-radius: var(--radius-m);
  box-shadow: var(--shadow-primary);
  padding: 1.2rem 1.6rem; text-decoration: none;
  transition: box-shadow 0.15s ease;
}
.tool:hover { box-shadow: var(--shadow-hover); }
.tool__type {
  font-family: var(--font-mono); font-size: var(--text-xs); letter-spacing: 0.1em; text-transform: none;
  color: #fff; background: var(--primary); border-radius: var(--radius-xs); padding: 0.2rem 0.8rem; flex: none;
}
.tool__name { font-weight: 700; color: var(--text-title); }
.tool__note { color: var(--text-muted); font-size: var(--text-s); margin-left: auto; display: none; }
@media (min-width: 700px) { .tools { grid-template-columns: 1fr 1fr; } .tool__note { display: block; } }

/* ---------- company page ---------- */
.company { display: grid; gap: var(--gap-l); }
.company__main { min-width: 0; }
.company__aside { display: grid; gap: var(--gap-m); align-content: start; }
.contactbox {
  background: var(--bg-body); border: 1px solid var(--border-primary); border-radius: var(--radius-m);
  box-shadow: var(--shadow-primary); padding: var(--space-m);
}
.contactbox__title { font-family: var(--font-display); font-weight: 600; font-size: var(--text-l); text-transform: none; letter-spacing: 0.02em; color: var(--text-title); margin-bottom: var(--space-s); }
.contactbox__row { display: grid; gap: 0.2rem; padding-block: var(--space-s); border-top: 1px solid var(--border-primary); }
.contactbox__label { font-family: var(--font-mono); font-size: var(--text-xs); letter-spacing: 0.12em; text-transform: none; color: var(--text-muted); }
.contactbox__value { color: var(--text-title); word-break: break-word; }
.contactbox__value a { color: var(--primary); text-decoration: none; }
.contactbox__value a:hover { text-decoration: underline; }
@media (min-width: 1000px) { .company { grid-template-columns: minmax(0, 2fr) 1fr; align-items: start; } }

/* ---------- forms ---------- */
.form { display: grid; gap: var(--space-m); max-width: 64rem; }
.form--card {
  background: var(--bg-body); border: 1px solid var(--border-primary); border-radius: var(--radius-m);
  box-shadow: var(--shadow-primary); padding: var(--space-l);
}
.field { display: grid; gap: 0.5rem; }
.field__label { font-family: var(--font-display); font-weight: 600; font-size: 1.6rem; letter-spacing: 0.04em; text-transform: none; color: var(--text-title); }
.field__hint { font-size: var(--text-xs); color: var(--text-muted); }
.field__input, .field__textarea, .field__select {
  width: 100%; font: inherit; font-size: var(--text-m); color: var(--text-title);
  background: var(--bg-body); border: 1px solid #c9c9c9; border-radius: var(--radius-s);
  padding: 1.1rem 1.4rem;
}
.field__textarea { min-height: 14rem; resize: vertical; }
.field__textarea--compact { min-height: 5.5rem; max-width: 32rem; }
.field__input:focus, .field__textarea:focus, .field__select:focus { outline: 3px solid var(--primary); outline-offset: 1px; border-color: var(--primary); }
.field--error .field__input, .field--error .field__textarea { border-color: var(--primary-bright); }
.field__error { font-size: var(--text-xs); color: var(--primary-bright); font-weight: 600; }
.form__row { display: grid; gap: var(--space-m); }
@media (min-width: 700px) { .form__row { grid-template-columns: 1fr 1fr; } }
.checks { display: grid; gap: 0.6rem; }
.check { display: flex; gap: 0.8rem; align-items: baseline; font-size: var(--text-s); }
.check input { width: 1.6rem; height: 1.6rem; accent-color: var(--primary); flex: none; transform: translateY(0.2rem); }

.notice { border-radius: var(--radius-m); padding: var(--space-m); font-size: var(--text-s); border: 1px solid; }
.notice--ok { background: #f0f7f0; border-color: #bfdcbf; color: #1e4620; }
.notice--error { background: #fdf1f0; border-color: #f0c4c0; color: #7e1414; }
.notice--info { background: var(--bg-surface); border-color: var(--border-primary); color: var(--tertiary); }

/* ---------- empty state ---------- */
.empty {
  border: 1px dashed #c9c9c9; border-radius: var(--radius-m);
  padding: var(--space-l); text-align: center; color: var(--text-muted); font-size: var(--text-s);
  display: grid; gap: var(--space-s); justify-items: center;
}
.empty__title { font-family: var(--font-display); font-weight: 600; font-size: var(--text-l); text-transform: none; letter-spacing: 0.02em; color: var(--text-title); }

/* ---------- pagination ---------- */
.pager { display: flex; gap: var(--gap-xs); flex-wrap: wrap; margin-top: var(--space-l); }
.pager__link {
  font-family: var(--font-mono); font-size: var(--text-s); text-decoration: none;
  border: 1px solid var(--border-primary); border-radius: var(--radius-s);
  padding: 0.6rem 1.2rem; color: var(--text-title);
}
.pager__link:hover { border-color: var(--primary); color: var(--primary); }
.pager__link--current { background: var(--secondary); color: #fff; border-color: var(--secondary); }
.pager__gap { font-family: var(--font-mono); font-size: var(--text-s); color: var(--text-muted); padding: 0.6rem 0.4rem; align-self: center; }

/* ---------- newsletter band ---------- */
.newsletter { background: var(--primary); color: var(--text-invert); }
.newsletter__inner { padding-block: var(--space-2xl); display: grid; gap: var(--gap-l); }
.newsletter__title { font-family: var(--font-display); font-weight: 600; font-size: var(--text-2xl); line-height: 1; text-transform: none; letter-spacing: 0.01em; }
.newsletter__title em { font-style: normal; color: var(--primary-soft); }
.newsletter__note { color: rgba(255,255,255,0.75); font-size: var(--text-s); max-width: 46ch; margin-top: var(--space-s); }
.newsletter__form { display: flex; flex-wrap: wrap; gap: var(--gap-s); align-content: center; }
.newsletter__input { flex: 1 1 24rem; border: 0; border-radius: var(--radius-s); font: inherit; font-size: var(--text-m); padding: 1.4rem 1.6rem; }
.newsletter__btn {
  border: 0; cursor: pointer; background: #fff; color: var(--primary); border-radius: var(--radius-s);
  font-family: var(--font-display); font-weight: 600; font-size: var(--text-l); letter-spacing: 0.08em; text-transform: none;
  padding: 1.2rem 2.8rem; transition: background 0.15s ease;
}
.newsletter__btn:hover { background: var(--primary-soft); }
@media (min-width: 1000px) { .newsletter__inner { grid-template-columns: 1.2fr 1fr; align-items: center; } }

/* ---------- footer ---------- */
.footer { background: var(--bg-dark); color: rgba(255,255,255,0.72); }
.footer__inner { display: grid; gap: var(--gap-l); padding-block: var(--space-xl); }
.footer__cols { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--gap-l); }
.footer__heading { font-family: var(--font-display); font-weight: 600; font-size: var(--text-m); letter-spacing: 0.1em; color: var(--text-invert); margin-bottom: var(--space-s); }
.footer__link { display: block; text-decoration: none; font-size: var(--text-s); padding-block: 0.3rem; color: rgba(255,255,255,0.72); }
.footer__link:hover { color: var(--primary-bright); }
.footer__brandname { font-family: var(--font-display); font-weight: 700; font-size: 2.6rem; letter-spacing: 0.03em; color: var(--text-invert); }
.footer__brandname em { font-style: normal; color: #d42a2a; text-transform: uppercase; } /* brighter than --primary-bright to clear 3:1 on the dark footer */
.footer__tag { font-family: var(--font-mono); font-size: var(--text-xs); letter-spacing: 0.1em; color: rgba(255,255,255,0.5); margin-top: var(--space-s); }
.footer__legal { border-top: 1px solid rgba(255,255,255,0.1); padding-block: var(--space-m); font-family: var(--font-mono); font-size: var(--text-xs); letter-spacing: 0.05em; color: rgba(255,255,255,0.5); display: flex; flex-wrap: wrap; gap: var(--space-s) var(--space-m); align-items: center; justify-content: space-between; }
.footer__legal-left { display: inline-flex; flex-wrap: wrap; align-items: center; gap: var(--space-s) var(--space-l); }
.footer__legal-links { display: flex; flex-wrap: wrap; gap: var(--space-s) var(--space-m); }
.footer__legal-links a { color: rgba(255,255,255,0.6); text-decoration: none; }
.footer__legal-links a:hover { color: var(--primary-bright); }
.footer__madein { display: inline-flex; align-items: center; gap: 0.7rem; color: rgba(255,255,255,0.6); text-decoration: none; }
.footer__madein:hover { color: var(--primary-bright); }
.footer__flag { width: 2.4rem; height: 1.6rem; border-radius: 1px; box-shadow: 0 0 0 1px rgba(255,255,255,0.15); flex: none; display: block; }
@media (min-width: 700px) { .footer__cols { grid-template-columns: repeat(4, 1fr); } }
@media (min-width: 1000px) { .footer__inner { grid-template-columns: 1fr 2fr; } }

/* Commodity price ticker (home) --------------------------------------- */
.ticker {
  background: var(--navy);
  color: var(--text-invert);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.ticker__inner {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-s) var(--space-m);
  padding-block: var(--space-s);
}
.ticker__label {
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: none;
  letter-spacing: 0.09em;
  color: rgba(255, 255, 255, 0.55);
}
.ticker__list {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-s) var(--space-l);
  margin: 0;
  padding: 0;
  list-style: none;
}
.ticker__item {
  display: flex;
  align-items: baseline;
  gap: 0.7rem;
  font-size: var(--text-s);
}
.ticker__name { color: rgba(255, 255, 255, 0.72); }
.ticker__price { font-weight: 700; font-variant-numeric: tabular-nums; }
.ticker__chg {
  font-size: var(--text-xs);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.ticker__chg--up { color: #3ad07a; }
.ticker__chg--down { color: #ff6b6b; }
.ticker__ts {
  margin-left: auto;
  font-size: var(--text-xs);
  color: rgba(255, 255, 255, 0.45);
}

/* Featured card highlight (logo styling lives with .card above) --------- */
.card--featured { border: 2px solid var(--primary); }

/* ---------- category listing rows (list layout) ---------- */
.listrows { border-top: 1px solid var(--border-primary); }
.listrow {
  display: flex; gap: 1.6rem; align-items: center; text-decoration: none; color: var(--text-body);
  padding: 1.6rem 0.4rem 1.6rem 0; border-bottom: 1px solid var(--border-primary); position: relative;
}
.listrow:hover { background: var(--bg-surface); }
.listrow--feat { padding-left: 1.6rem; }
.listrow--feat::before { content: ""; position: absolute; left: 0; top: 1rem; bottom: 1rem; width: 3px; background: var(--primary); border-radius: 3px; }
.listrow__logo { flex: none; height: 8rem; width: auto; max-width: 18rem; object-fit: contain; background: #fff; border: 1px solid var(--border-primary); border-radius: var(--radius-m); padding: 0.4rem; }
.listrow__mono { flex: none; width: 7.2rem; height: 7.2rem; display: grid; place-items: center; background: var(--bg-surface); border-radius: var(--radius-m); font-family: var(--font-display); font-weight: 700; font-size: 1.9rem; color: #a2a09b; letter-spacing: 0.02em; }
.listrow__body { flex: 1; min-width: 0; }
.listrow__top { display: flex; align-items: baseline; gap: 1rem; flex-wrap: wrap; }
.listrow__name { font-family: var(--font-display); font-weight: 700; font-size: 1.8rem; line-height: 1.1; letter-spacing: 0.005em; color: var(--text-title); }
.listrow:hover .listrow__name { color: var(--primary); }
.listrow__city { font-size: var(--text-xs); color: var(--text-muted); }
.listrow__city::before { content: ""; display: inline-block; width: 4px; height: 4px; border-radius: 50%; background: #c9c9c9; margin: 0 0.8rem 0.2rem 0; vertical-align: middle; }
.listrow__desc { display: block; color: var(--text-body); font-size: var(--text-s); margin-top: 0.3rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 56ch; }
.listrow__tags { display: flex; gap: 0.6rem; flex-wrap: wrap; margin-top: 0.8rem; }
.listrow__cta { flex: none; align-self: center; color: var(--text-muted); font-size: 2.4rem; line-height: 1; padding-left: 0.6rem; }
.listrow:hover .listrow__cta { color: var(--primary); }
@media (max-width: 560px) { .listrow__desc { white-space: normal; } .listrow__cta { display: none; } }

/* ---------- Category page: two-column layout + sidebar --------------- */
.termlayout { display: grid; gap: var(--space-l); grid-template-columns: 1fr; }
@media (min-width: 900px) { .termlayout { grid-template-columns: minmax(0, 2fr) 1fr; align-items: start; } }
.termlayout__main { min-width: 0; }
/* Next to the sidebar the main column is narrower: cap cards at 2-up. */
@media (min-width: 900px) { .termlayout__main .cards { grid-template-columns: 1fr 1fr; } }
.termlayout__side { display: grid; gap: var(--gap-m); min-width: 0; }
@media (min-width: 900px) { .termlayout__side { position: sticky; top: var(--space-m); } }

.side {
  background: var(--bg-body); border: 1px solid var(--border-primary); border-radius: var(--radius-m);
  box-shadow: var(--shadow-primary); padding: var(--space-m);
}
.side__title {
  font-family: var(--font-body); font-weight: 700; font-size: var(--text-xs); letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--text-title);
  padding-bottom: var(--space-s); border-bottom: 1px solid var(--border-primary);
}
.side__list { display: grid; }
.side__row {
  display: flex; justify-content: space-between; align-items: center; gap: var(--gap-s);
  padding: 0.85rem 0; border-top: 1px solid var(--border-primary);
  font-size: var(--text-s); color: var(--text-body); text-decoration: none;
}
.side__row:first-child { border-top: none; }
.side__name { overflow-wrap: anywhere; }
.side__row:hover .side__name { color: var(--primary); }
.side__count {
  font-family: var(--font-body); font-size: var(--text-xs); color: var(--text-muted);
  background: var(--bg-surface); border-radius: 999px; padding: 0.2rem 0.8rem; flex: none;
  font-variant-numeric: tabular-nums;
}
.side--cta { display: grid; gap: 0.5rem; border-top: 3px solid var(--primary); }
.side__eyebrow {
  font-family: var(--font-body); font-weight: 700; font-size: var(--text-xs); letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--primary);
}
.side__k { font-family: var(--font-display); font-weight: 700; font-size: var(--text-l); line-height: 1.1; color: var(--text-title); letter-spacing: 0.01em; }
.side--cta p { font-size: var(--text-s); color: var(--text-body); margin: 0.2rem 0 var(--space-s); }
.side__btn {
  justify-self: start; font-family: var(--font-display); font-weight: 600; font-size: var(--text-s);
  background: var(--primary); color: #fff; text-decoration: none; padding: 0.9rem 1.6rem; border-radius: var(--radius-s);
}
.side__btn:hover { background: var(--primary-bright); }

/* ---------- Blog sidebar (wider rail, dispatch list, directory panel) - */
@media (min-width: 900px) { .termlayout--blog { grid-template-columns: minmax(0, 2fr) 1fr; } }

.side__post { display: grid; gap: 0.3rem; padding: 0.9rem 0; border-top: 1px solid var(--border-primary); text-decoration: none; }
.side__post:first-child { border-top: none; padding-top: 0.2rem; }
.side__pdate { font-size: var(--text-xs); letter-spacing: 0.12em; text-transform: uppercase; font-weight: 700; color: var(--primary); }
.side__ptitle { font-family: var(--font-display); font-weight: 600; font-size: var(--text-s); line-height: 1.25; color: var(--text-title); }
.side__post:hover .side__ptitle { color: var(--primary); }

.dirpromo {
  background: var(--navy); color: #fff; border-top: 3px solid var(--primary);
  border-radius: var(--radius-m); box-shadow: var(--shadow-primary);
  padding: var(--space-m); display: grid; gap: var(--space-s);
}
.dirpromo__h { font-family: var(--font-display); font-weight: 700; font-size: var(--text-l); line-height: 1.08; letter-spacing: 0.01em; color: #fff; margin: 0; }
.dirpromo__p { font-size: var(--text-s); line-height: 1.5; color: rgba(255,255,255,0.75); margin: 0; }
.dirpromo__n { color: #fff; font-weight: 700; }
.dirpromo__links { display: grid; gap: 0.7rem; margin-top: 0.4rem; }
.dirpromo__a { font-family: var(--font-display); font-weight: 600; font-size: var(--text-s); color: #fff; text-decoration: none; display: inline-flex; align-items: center; gap: 0.5rem; }
.dirpromo__a .arw { color: #ff9c93; transition: transform 0.15s ease; }
.dirpromo__a:hover { text-decoration: underline; text-underline-offset: 3px; }
.dirpromo__a:hover .arw { transform: translateX(3px); }
.dirpromo__a--muted { color: rgba(255,255,255,0.72); font-weight: 500; }
.dirpromo__a--muted:hover { color: #fff; }

/* ---------- Category Sponsor block (petroleum-navy feature card) ------ */
.sponsors { display: grid; gap: var(--gap-m); margin-bottom: var(--space-l); }
.sponsor {
  background: var(--navy); border-radius: var(--radius-m); box-shadow: var(--shadow-primary);
  padding: clamp(2rem, 3vw, 3.2rem); display: flex; gap: var(--space-l); align-items: center; flex-wrap: wrap;
}
.sponsor__logo {
  width: 16rem; height: 13rem; padding: 1.8rem; flex: none;
  background: #fff; border-radius: var(--radius-m); overflow: hidden;
}
.sponsor__logo img { width: 100%; height: 100%; object-fit: contain; object-position: center; display: block; }
.sponsor__body { flex: 1 1 34rem; min-width: 0; display: grid; gap: 0.8rem; }
.sponsor__tab {
  justify-self: start; font-family: var(--font-body); font-weight: 700; font-size: var(--text-xs);
  letter-spacing: 0.16em; text-transform: uppercase; color: #fff; background: var(--primary);
  border-radius: var(--radius-s); padding: 0.4rem 0.95rem;
}
.sponsor__name {
  font-family: var(--font-display); font-weight: 700; font-size: clamp(2.2rem, 1.8rem + 1.4vw, 2.9rem);
  color: #fff; line-height: 1.05; letter-spacing: 0.01em; text-decoration: none; overflow-wrap: anywhere;
}
.sponsor__name:hover { color: var(--primary-soft); }
.sponsor__city { font-family: var(--font-body); font-weight: 500; font-size: var(--text-xs); letter-spacing: 0.08em; text-transform: uppercase; color: #ff9c93; }
.sponsor__desc { font-size: var(--text-m); line-height: 1.5; color: rgba(255, 255, 255, 0.82); max-width: 58ch; }
.sponsor__tags { display: flex; flex-wrap: wrap; gap: 0.6rem; }
.sponsor__tags .tag { background: rgba(255, 255, 255, 0.08); color: rgba(255, 255, 255, 0.85); border: 1px solid rgba(255, 255, 255, 0.2); }
.sponsor__cta {
  justify-self: start; margin-top: 0.4rem; font-family: var(--font-display); font-weight: 600; font-size: var(--text-s);
  color: #fff; background: var(--primary); padding: 1rem 1.9rem; border-radius: var(--radius-s); text-decoration: none;
}
.sponsor__cta:hover { background: var(--primary-bright); }

/* Listing (single company) page logo ------------------------------------ */
.listing__logo {
  display: block;
  width: auto;
  max-width: min(100%, 38rem);
  max-height: 18rem;
  object-fit: contain;
  object-position: left center;
  margin-bottom: var(--space-m);
}

/* ---------- Listing plans (/add-listing) ---------------------------- */
.plans { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--gap-m); margin-top: var(--space-l); }
@media (min-width: 820px) { .plans { grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: start; } }
.plan {
  min-width: 0; background: var(--bg-body);
  border: 1px solid var(--border-primary); border-radius: var(--radius-l);
  box-shadow: var(--shadow-primary); padding: var(--space-l);
  display: flex; flex-direction: column;
}
.plan--featured { border: 2px solid var(--primary); box-shadow: var(--shadow-hover); position: relative; }
.plan__badge {
  position: absolute; top: 0; right: var(--space-m); transform: translateY(-50%);
  background: var(--primary); color: #fff;
  font-family: var(--font-mono); font-size: var(--text-xs); letter-spacing: 0.08em; text-transform: uppercase;
  padding: 0.4rem 1rem; border-radius: var(--radius-s);
}
.plan__name { font-family: var(--font-display); font-weight: 700; font-size: var(--text-l); text-transform: none; letter-spacing: 0.02em; color: var(--text-title); }
.plan__price { display: flex; align-items: baseline; flex-wrap: wrap; gap: 0.6rem; margin-top: var(--space-xs); }
.plan__amount { font-family: var(--font-display); font-weight: 800; font-size: var(--text-2xl); line-height: 1; color: var(--text-title); }
.plan__period { font-size: var(--text-m); color: var(--text-muted); }
.plan__was { font-size: var(--text-m); color: var(--text-muted); text-decoration: line-through; }
.plan__note { font-size: var(--text-s); color: var(--text-muted); margin-top: var(--space-xs); }
.plan__features { list-style: none; padding: 0; margin: var(--space-m) 0; display: flex; flex-direction: column; gap: 0.8rem; flex: 1 1 auto; }
.plan__features li { position: relative; padding-left: 2.6rem; font-size: var(--text-s); line-height: 1.4; }
.plan__features li::before { content: "\2713"; position: absolute; left: 0; top: 0; color: var(--primary); font-weight: 700; }
.plan__cta { margin-top: var(--space-m); }
.plan__cta .btn { width: 100%; }
.plan__fineprint { font-size: var(--text-s); color: var(--text-muted); }

.adslot { margin-top: var(--space-l); }

/* ============================================================
   Home (editorial) — magazine-style front page. Scoped to
   body.home-ed where it overrides shared components; new
   component classes below don't collide with anything global.
   ============================================================ */

/* hero: red tab kicker + serif headline (homepage only) */
.home-ed .hero__tab {
  display: inline-block; background: var(--primary); color: #fff;
  font-family: var(--font-display); font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.11em; font-size: var(--text-xs); padding: 0.6rem 1.3rem; border-radius: var(--radius-s);
}
.home-ed .hero__title {
  font-family: var(--font-display); font-weight: 700; letter-spacing: -0.01em;
  max-width: 20ch; margin-top: 1.8rem; line-height: 1.02;
}
.home-ed .hero__title em { font-style: normal; color: #fff; border-bottom: 0.5rem solid var(--primary); padding-bottom: 0.2rem; }
.home-ed .hero__lede { max-width: 58ch; }

/* directory-at-a-glance strip */
.glancebar { background: var(--bg-dark); color: #fff; }
.glancebar__grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; background: rgba(255,255,255,0.12); }
@media (min-width: 760px) { .glancebar__grid--3 { grid-template-columns: repeat(3, 1fr); } .glancebar__grid--4 { grid-template-columns: repeat(4, 1fr); } }
/* fourth glancebar stat: the three market prices, compact */
.gstat--prices { display: flex; flex-direction: column; justify-content: center; }
.gprices { display: flex; flex-direction: column; gap: 0.4rem; }
.gprice { display: flex; align-items: baseline; justify-content: space-between; gap: 1.2rem; font-family: var(--font-mono); line-height: 1.1; }
.gprice__lbl { font-size: var(--text-xs); text-transform: uppercase; letter-spacing: 0.06em; color: rgba(255,255,255,0.6); white-space: nowrap; }
.gprice__val { font-size: var(--text-s); font-weight: 700; color: #fff; font-variant-numeric: tabular-nums; }
.gprice__chg { font-size: 1rem; margin-left: 0.4rem; }
.gprice__chg--up { color: #e0b96a; }
.gprice__chg--down { color: var(--primary-bright); }
.gstat { background: var(--bg-dark); padding: var(--space-m) var(--space-s); }
.gstat b { display: block; font-family: var(--font-display); font-weight: 700; font-size: var(--text-2xl); line-height: 1; font-variant-numeric: tabular-nums; color: #fff; }
.gstat span { display: block; margin-top: 0.8rem; font-family: var(--font-mono); font-size: var(--text-xs); text-transform: uppercase; letter-spacing: 0.1em; color: rgba(255,255,255,0.6); }

/* tighter section rhythm than the global .section */
.sec { padding-block: var(--space-xl); }
.sec--tint { background: var(--bg-surface); }

/* editorial section header: kicker + rule + optional more link */
.dept { display: flex; align-items: center; gap: var(--gap-s); margin-bottom: var(--space-l); }
.dept__k { font-family: var(--font-display); font-weight: 800; text-transform: uppercase; letter-spacing: 0.14em; font-size: var(--text-s); color: var(--primary); white-space: nowrap; margin: 0; line-height: inherit; }
.dept__rule { flex: 1 1 auto; height: 1px; background: var(--border-primary); }
.dept__more { font-family: var(--font-mono); font-size: var(--text-xs); color: var(--text-muted); text-decoration: none; white-space: nowrap; }
.dept__more:hover { color: var(--primary); }

/* browse-by-category grid */
.catgrid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; background: var(--border-primary); border: 1px solid var(--border-primary); border-radius: var(--radius-m); overflow: hidden; }
@media (min-width: 620px) { .catgrid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 980px) { .catgrid { grid-template-columns: repeat(4, 1fr); } }
.cat { background: var(--bg-body); padding: 1.6rem 1.8rem; text-decoration: none; display: flex; flex-direction: column; gap: 0.4rem; transition: background 0.12s ease; }
.cat:hover { background: var(--bg-surface); }
.cat b { font-family: var(--font-display); font-weight: 600; font-size: var(--text-m); color: var(--text-title); line-height: 1.15; }
.cat__blurb {
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  font-family: var(--font-body); font-size: var(--text-xs); line-height: 1.35; color: var(--text-body);
}
.cat span { font-family: var(--font-mono); font-size: var(--text-xs); color: var(--text-muted); }
.home-ed .catgrid .cat span { margin-top: auto; padding-top: 0.4rem; }

/* company spotlight (two featured, side by side) */
.spotlight { display: grid; grid-template-columns: 1fr; gap: var(--gap-m); }
@media (min-width: 820px) { .spotlight { grid-template-columns: 1fr 1fr; } }
.spotco { display: grid; grid-template-columns: 15rem 1fr; gap: var(--gap-m); background: var(--bg-dark); border-radius: var(--radius-l); padding: var(--space-m); color: #fff; text-decoration: none; align-items: start; transition: transform 0.15s ease; }
.spotco:hover { transform: translateY(-2px); }
.spotco__logo { width: 100%; height: 8rem; background: #fff; border-radius: var(--radius-m); display: grid; place-items: center; overflow: hidden; }
.spotco__logo img { max-width: 100%; max-height: 100%; object-fit: contain; padding: 0.8rem; box-sizing: border-box; }
.spotco__logo span { font-family: var(--font-display); font-weight: 800; color: var(--bg-dark); text-align: center; font-size: var(--text-m); }
.spotco__body { display: flex; flex-direction: column; align-items: flex-start; min-width: 0; }
.spotco__k { display: inline-block; background: var(--primary); color: #fff; font-family: var(--font-display); font-weight: 800; text-transform: uppercase; letter-spacing: 0.09em; font-size: var(--text-xs); padding: 0.3rem 0.9rem; border-radius: var(--radius-xs); }
.spotco__name { font-family: var(--font-display); font-weight: 700; font-size: var(--text-l); margin-top: 0.9rem; color: #fff; line-height: 1.12; }
.spotco__desc { color: rgba(255,255,255,0.82); font-size: var(--text-s); margin-top: 0.6rem; }
.spotco__loc { font-family: var(--font-mono); font-size: var(--text-xs); text-transform: uppercase; letter-spacing: 0.08em; color: rgba(255,255,255,0.55); margin-top: 0.8rem; }
.spotco__cta { margin-top: 1.2rem; color: #fff; font-family: var(--font-display); font-weight: 700; font-size: var(--text-s); border-bottom: 2px solid var(--primary); padding-bottom: 0.2rem; }

/* dispatches (articles) — editorial column, no colored band */
.dispatches { display: grid; grid-template-columns: 1fr; gap: 0; }
@media (min-width: 760px) { .dispatches { grid-template-columns: repeat(3, 1fr); gap: var(--gap-l); } }
.dispatch { display: flex; flex-direction: column; text-decoration: none; border-top: 2px solid var(--text-title); padding-top: 1.2rem; padding-bottom: var(--space-m); border-bottom: 1px solid var(--border-primary); }
@media (min-width: 760px) { .dispatch { border-bottom: 0; padding-bottom: 0; } }
/* shared article-item pieces (home dispatches + resources articles) */
.dispatch__k, .reslead__k { font-family: var(--font-mono); font-size: var(--text-xs); text-transform: uppercase; letter-spacing: 0.08em; color: var(--primary); }
.dispatch__title, .reslead__title, .resrow__title { font-family: var(--font-display); color: var(--text-title); transition: color 0.15s ease; }
.dispatch:hover .dispatch__title, .reslead:hover .reslead__title, .resrow:hover .resrow__title { color: var(--primary); }
.dispatch__read, .reslead__read, .ev__link { font-family: var(--font-display); font-weight: 700; font-size: var(--text-xs); text-transform: uppercase; letter-spacing: 0.06em; color: var(--primary); }
.dispatch__title { font-weight: 700; font-size: var(--text-l); line-height: 1.22; margin-top: 1rem; }
.dispatch__excerpt { font-size: var(--text-s); color: var(--text-body); margin-top: 0.8rem; }
.dispatch__read { margin-top: auto; padding-top: 1.2rem; }

/* new on the board (recent listings) */
.board { border-top: 1px solid var(--border-primary); }
.brow { display: flex; gap: var(--gap-s); align-items: center; padding: 1.2rem 0.2rem; border-bottom: 1px solid var(--border-primary); text-decoration: none; }
.brow:hover { background: var(--bg-surface); }
.brow__mono { width: 4.4rem; height: 4.4rem; flex: none; border-radius: var(--radius-s); background: var(--bg-surface); display: grid; place-items: center; overflow: hidden; font-family: var(--font-display); font-weight: 800; color: var(--primary); font-size: var(--text-m); }
.brow__mono img { max-width: 100%; max-height: 100%; object-fit: contain; padding: 0.4rem; }
.brow__b { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 0.4rem; }
.brow__n { font-family: var(--font-display); font-weight: 700; color: var(--text-title); font-size: var(--text-m); line-height: 1.2; }
.brow__c { font-family: var(--font-mono); font-size: var(--text-xs); color: var(--text-muted); line-height: 1.2; }
.brow__t { font-family: var(--font-mono); font-size: var(--text-xs); color: var(--text-muted); white-space: nowrap; }

/* town browse + resources (two-up) */
.twoup { display: grid; grid-template-columns: 1fr; gap: var(--gap-l); }
@media (min-width: 860px) { .twoup { grid-template-columns: 1fr 1fr; } }
.chips { display: flex; gap: 0.8rem; flex-wrap: wrap; }
.chip { border: 1px solid var(--border-primary); border-radius: 999px; padding: 0.7rem 1.4rem; font-size: var(--text-s); color: var(--text-body); text-decoration: none; }
.chip:hover { border-color: var(--primary); color: var(--primary); }
.chip b { font-family: var(--font-mono); color: var(--text-muted); font-weight: 700; margin-left: 0.6rem; font-size: var(--text-xs); }
.rescards { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.res { border: 1px solid var(--border-primary); border-radius: var(--radius-m); padding: 1.3rem 1.4rem; text-decoration: none; display: block; }
.res:hover { background: var(--bg-surface); }
.res b { font-family: var(--font-display); font-weight: 600; color: var(--text-title); font-size: var(--text-s); display: block; }
.res span { font-family: var(--font-mono); color: var(--text-muted); font-size: var(--text-xs); }

/* events */
.events { display: grid; grid-template-columns: 1fr; gap: 1rem; }
.ev { display: flex; gap: var(--gap-s); align-items: center; border: 1px solid var(--border-primary); border-radius: var(--radius-m); padding: 1.2rem 1.4rem; background: var(--bg-body); text-decoration: none; transition: border-color 0.12s ease, background 0.12s ease; scroll-margin-top: var(--space-l); }
.ev:hover { border-color: var(--primary); background: var(--bg-surface); }
.ev__date { font-family: var(--font-display); text-align: center; flex: none; width: 5.2rem; color: var(--primary); }
.ev__date b { display: block; font-size: var(--text-xl); line-height: 1; }
.ev__date span { font-size: var(--text-xs); text-transform: uppercase; letter-spacing: 0.05em; }
.ev__b b { font-family: var(--font-display); font-weight: 600; color: var(--text-title); font-size: var(--text-m); display: block; }
.ev__b span { font-family: var(--font-mono); color: var(--text-muted); font-size: var(--text-xs); }
.ev__link { display: block; margin-top: 0.8rem; text-decoration: none; }
.ev__link:hover { text-decoration: underline; }
.ev-add { display: block; margin-top: 1rem; text-align: center; border: 1px dashed var(--border-primary); border-radius: var(--radius-m); padding: 1.4rem; text-decoration: none; color: var(--primary); font-family: var(--font-display); font-weight: 700; font-size: var(--text-s); }
.ev-add:hover { background: var(--bg-surface); border-color: var(--primary); }
.ev-add span { display: block; margin-top: 0.3rem; color: var(--text-muted); font-weight: 400; font-family: var(--font-mono); font-size: var(--text-xs); }

/* ============================================================
   Resources page: prominent articles + compact tools list
   ============================================================ */
/* lead article */
.reslead { display: block; text-decoration: none; border-top: 2px solid var(--text-title); padding-top: var(--space-s); margin-bottom: var(--space-l); }
.reslead__title { display: block; font-weight: 600; font-size: var(--text-xl); line-height: 1.1; margin-top: 0.6rem; }
.reslead__ex { display: block; font-size: var(--text-s); color: var(--text-body); margin-top: 0.8rem; max-width: 60ch; }
.reslead__read { display: inline-block; margin-top: 1rem; }
/* compact article rows */
.reslist { display: grid; border-top: 1px solid var(--border-primary); }
.resrow { display: flex; gap: var(--gap-s); align-items: baseline; padding: 1.1rem 0; border-bottom: 1px solid var(--border-primary); text-decoration: none; }
.resrow__date { font-family: var(--font-mono); font-size: var(--text-xs); color: var(--text-muted); white-space: nowrap; flex: none; width: 10rem; }
.resrow__title { font-weight: 600; font-size: var(--text-m); }
/* tools: narrow label + wide links */
.resgroups { display: grid; gap: 0; }
.resgroup { display: grid; grid-template-columns: 1fr; gap: 0.6rem; padding-block: var(--space-s); border-top: 1px solid var(--border-primary); }
.resgroup:last-child { border-bottom: 1px solid var(--border-primary); }
@media (min-width: 640px) { .resgroup { grid-template-columns: 14rem 1fr; gap: var(--gap-m); } }
.resgroup__label { font-family: var(--font-display); font-weight: 700; font-size: var(--text-xs); text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-muted); padding-top: 0.2rem; }
.resgroup__links { display: grid; gap: 1rem; }
.reslink { text-decoration: none; display: block; }
.reslink__name { font-family: var(--font-display); font-weight: 600; font-size: var(--text-m); color: var(--text-title); transition: color 0.15s ease; }
.reslink:hover .reslink__name { color: var(--primary); }
.reslink__ext { font-size: 0.8em; color: var(--text-muted); }
.reslink__note { display: block; font-size: var(--text-xs); color: var(--text-muted); margin-top: 0.2rem; }

.dept__k--link { text-decoration: none; }
.dept__k--link:hover { text-decoration: underline; }

/* A-Z company index: dense two/three-column link list. Exists for crawl depth, so it
   stays compact and text-only rather than using the heavier listing-row treatment. */
.azlist { list-style: none; margin: 0 0 var(--space-m); padding: 0; columns: 3; column-gap: var(--gap-l); }
.azlist li { break-inside: avoid; margin-bottom: var(--space-2xs); font-size: var(--text-s); line-height: 1.5; }
.azlist a { color: var(--text-primary); text-decoration: none; }
.azlist a:hover { color: var(--primary); text-decoration: underline; }
.azlist__loc { color: var(--text-muted); font-size: var(--text-xs); display: block; }
@media (max-width: 900px) { .azlist { columns: 2; } }
@media (max-width: 560px) { .azlist { columns: 1; } }

/* AdSense units. Centred, with breathing room so an ad never crowds real content.
   min-height reserves space to limit layout shift when the unit fills. */
.adslot { margin: var(--space-xl) auto 0; max-width: var(--container-max, 1200px); padding: 0 var(--space-m); }
.adslot--horizontal { min-height: 90px; }
.adslot--square { min-height: 250px; }
.adslot--vertical { min-height: 600px; }

/* ============================================================
   Listing page ("call sheet")
   The page has one job: get a buyer to phone the company. So the number is the
   second-largest element after the name, and sits above the description at every
   breakpoint. Everything else stays quiet.
   ============================================================ */

.lst { padding-block: var(--space-l) var(--space-xl); }
.lst .crumbs { margin-bottom: var(--space-m); }

/* --- identity: logo + name + place, one block --- */
.lst__id {
  /* Stacked, not side by side: a wide wordmark pushed the company name far to the
     right and broke the left edge the rest of the page reads against. */
  display: flex; flex-direction: column; align-items: flex-start;
  gap: var(--space-m); margin-bottom: var(--space-l);
}
.lst__logo {
  width: auto; height: auto;
  /* Height is the honest constraint: wordmarks are wide, icon marks are square,
     so capping height keeps both reading at a similar visual weight. */
  max-height: clamp(9rem, 6rem + 6vw, 15rem);
  max-width: min(100%, 34rem);
  object-fit: contain; object-position: left center;
}
.lst__mono {
  display: grid; place-items: center; flex: none;
  width: clamp(9rem, 6rem + 6vw, 15rem); height: clamp(9rem, 6rem + 6vw, 15rem);
  background: var(--bg-dark); color: var(--text-invert); border-radius: var(--radius-s);
  font-family: var(--font-display); font-weight: 800; font-size: var(--text-xl); letter-spacing: 0.02em;
}
.lst__idtext { min-width: 0; }
.lst__name {
  font-family: var(--font-display); font-weight: 800; font-size: var(--text-xl);
  line-height: 1.05; color: var(--text-title); margin: 0;
}
.lst__meta {
  display: flex; flex-wrap: wrap; align-items: center; gap: var(--gap-xs);
  margin: var(--space-xs) 0 0; font-family: var(--font-mono);
  font-size: var(--text-xs); letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-muted);
}
.lst__basin { color: var(--primary); }
.lst__basin::before, .lst__cat::before { content: "·"; margin-right: var(--gap-xs); color: var(--border-primary); }
.lst__cat { color: var(--text-muted); text-decoration: none; }
.lst__cat:hover { color: var(--primary); }

/* --- two column, call sheet first on mobile --- */
.lst__grid { display: grid; gap: var(--gap-l); }
.lst__body { min-width: 0; order: 2; }
.lst__aside { display: grid; gap: var(--gap-m); align-content: start; order: 1; }
@media (min-width: 1000px) {
  .lst__grid { grid-template-columns: minmax(0, 2fr) minmax(28rem, 1fr); align-items: start; }
  .lst__body { order: 1; }
  .lst__aside { order: 2; position: sticky; top: var(--space-m); }
}

/* --- the signature: the number --- */
.callsheet {
  border: 2px solid var(--border-strong); border-radius: var(--radius-m);
  padding: var(--space-m); background: var(--bg-body);
}
.callsheet__k {
  display: block; font-family: var(--font-mono); font-size: var(--text-xs);
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--text-muted); margin-bottom: var(--space-xs);
}
.callsheet__tel {
  display: block; font-family: var(--font-display); font-weight: 800;
  font-size: clamp(2.8rem, 2.2rem + 1.8vw, 4rem); line-height: 1;
  letter-spacing: -0.02em; color: var(--text-title); text-decoration: none; word-break: break-word;
}
.callsheet__tel:hover, .callsheet__tel:focus-visible { color: var(--primary); }
.callsheet__site {
  display: block; margin-top: var(--space-m); padding-top: var(--space-s);
  border-top: 1px solid var(--border-primary);
  font-family: var(--font-mono); font-size: var(--text-s); color: var(--primary);
  text-decoration: none; word-break: break-all;
}
.callsheet__site:hover { text-decoration: underline; }
.callsheet__addr {
  margin: var(--space-s) 0 0; padding-top: var(--space-s); border-top: 1px solid var(--border-primary);
  font-size: var(--text-s); color: var(--text-body); line-height: 1.5;
}
.callsheet__none { margin: 0; font-size: var(--text-s); color: var(--text-muted); }

/* --- owner box --- */
.ownbox { background: var(--bg-surface); border-radius: var(--radius-m); padding: var(--space-m); }
.ownbox__title { font-family: var(--font-display); font-weight: 600; font-size: var(--text-m); color: var(--text-title); margin: 0 0 var(--space-xs); }
.ownbox p { margin: 0 0 var(--space-s); font-size: var(--text-s); color: var(--text-body); }
.ownbox__note { margin-top: var(--space-m); color: var(--text-muted); font-size: var(--text-xs); }

/* --- body blocks --- */
.lst__lede { margin: 0 0 var(--space-m); font-size: var(--text-l); line-height: 1.4; color: var(--text-title); }
.lst__block { margin-top: var(--space-l); }
.lst__blocktitle {
  font-family: var(--font-mono); font-size: var(--text-xs); font-weight: 400;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--text-muted);
  margin: 0 0 var(--space-s); padding-bottom: var(--space-xs); border-bottom: 1px solid var(--border-primary);
}
.lst__pills { display: flex; flex-wrap: wrap; gap: var(--gap-xs); list-style: none; margin: 0; padding: 0; }
.lst__pills li {
  font-family: var(--font-mono); font-size: var(--text-xs); letter-spacing: 0.05em;
  background: var(--bg-surface); border-radius: var(--radius-s); padding: 0.4rem 1rem; color: var(--tertiary);
}
.lst__pills--link li { padding: 0; background: none; }
.lst__pills--link a {
  display: inline-block; background: var(--bg-surface); border-radius: var(--radius-s);
  padding: 0.4rem 1rem; color: var(--tertiary); text-decoration: none;
}
.lst__pills--link a:hover { background: var(--primary); color: #fff; }
.lst__block--quiet .lst__blocktitle { border-bottom: 0; margin-bottom: var(--space-xs); }
.lst__inline { margin: 0; font-size: var(--text-s); color: var(--text-muted); line-height: 1.6; }

.draftbar { background: #b24a24; color: #fff; text-align: center; padding: var(--space-s) var(--space-m); font-weight: 600; }
