/* ============================================================
   BRISCOE SUPPLY — briscoesupply.com
   One stylesheet for every page.

   TO CHANGE BRAND COLORS: edit the tokens below and nothing else.
   Full brand reference: brand-guide.html
   ============================================================ */

:root {
  /* Brand color tokens */
  --green:       #1D5C4B;   /* Briscoe Green — primary */
  --green-deep:  #143C31;   /* dark panels, footer */
  --green-wash:  #E4EEE9;   /* tinted backgrounds */
  --brass:       #9C7A2E;   /* accent — eyebrows, details. Use sparingly */
  --ink:         #172019;   /* near-black text */
  --slate:       #5A655F;   /* secondary text */
  --paper:       #F6F5F1;   /* page ground — warm bone */
  --white:       #FFFFFF;
  --line:        #DEDBD2;   /* hairlines and card borders */
  --line-strong: #C4C0B4;

  /* Type */
  --f-display: "Libre Franklin", "Helvetica Neue", Arial, sans-serif;
  --f-body: "Source Serif 4", Georgia, serif;
  --f-mono: "IBM Plex Mono", ui-monospace, Menlo, monospace;
}

* { box-sizing: border-box; }

/* Present to screen readers and search engines, invisible on screen.
   Used for section headings the visual design doesn't need. */
.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--f-body);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

img, svg { max-width: 100%; }

a { color: var(--green); text-underline-offset: 0.18em; }
a:focus-visible, button:focus-visible { outline: 2px solid var(--brass); outline-offset: 3px; }

.wrap { max-width: 71rem; margin: 0 auto; padding: 0 1.4rem; }
.wrap-narrow { max-width: 46rem; margin: 0 auto; padding: 0 1.4rem; }

/* ---------- header ---------- */

.site-header {
  background: var(--paper);
  border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 50;
}

.site-header .bar {
  display: flex; align-items: center; gap: 2rem;
  /* horizontal padding must match .wrap — a bare `0` here overrides it */
  padding: 0.9rem 1.4rem;
}

.logo {
  display: flex; align-items: center; gap: 0.7rem;
  text-decoration: none; color: var(--ink);
  margin-right: auto;
}

.logo svg { width: 34px; height: 34px; flex: none; }

.logo .word {
  font-family: var(--f-display);
  font-weight: 700; font-size: 1.05rem; letter-spacing: 0.015em;
  line-height: 1.05;
}

.logo .word small {
  display: block;
  font-weight: 500; font-size: 0.62rem;
  /* Tracked so SUPPLY spans exactly the width of "Briscoe", with the
     left edge optically aligned to the B. Negative right margin removes
     the trailing letter-space so the layout box matches the ink. */
  letter-spacing: 0.481em;
  margin-left: 0.078em;
  margin-right: -0.481em;
  color: var(--green);
}

.site-nav { display: flex; gap: 1.6rem; align-items: center; flex-wrap: wrap; }

/* Mobile menu button — revealed below 46rem */
.nav-toggle {
  display: none;
  margin-left: auto;
  background: none;
  border: 1px solid var(--line-strong);
  border-radius: 3px;
  /* sized to a 44x44 touch target */
  padding: 0.9rem 0.7rem;
  line-height: 0;
  cursor: pointer;
}
.nav-toggle span {
  display: block; width: 20px; height: 2px;
  background: var(--ink); border-radius: 2px;
  transition: transform .18s ease, opacity .18s ease;
}
.nav-toggle span + span { margin-top: 4px; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
@media (prefers-reduced-motion: reduce) { .nav-toggle span { transition: none; } }

.site-nav a {
  font-family: var(--f-display);
  font-size: 0.82rem; font-weight: 600;
  letter-spacing: 0.03em;
  color: var(--ink); text-decoration: none;
  padding: 0.3rem 0;
  border-bottom: 2px solid transparent;
}

.site-nav a:hover { border-bottom-color: var(--brass); }
.site-nav a[aria-current="page"] { border-bottom-color: var(--green); color: var(--green); }

/* The Contact button in the nav — must beat .site-nav a in the cascade */
.site-nav a.btn,
.site-nav a.btn[aria-current="page"] {
  color: var(--white);
  border: 2px solid var(--green);
  border-radius: 3px;
  padding: 0.7rem 1.3rem;
}

.site-nav a.btn:hover { background: var(--green-deep); border-color: var(--green-deep); color: var(--white); }

.btn {
  display: inline-block;
  font-family: var(--f-display);
  font-size: 0.82rem; font-weight: 700; letter-spacing: 0.04em;
  text-decoration: none; text-align: center;
  padding: 0.7rem 1.3rem;
  background: var(--green); color: var(--white);
  border: 2px solid var(--green); border-radius: 3px;
}

.btn:hover { background: var(--green-deep); border-color: var(--green-deep); }

.btn.ghost { background: transparent; color: var(--green); }
.btn.ghost:hover { background: var(--green-wash); }

.btn.on-dark { background: var(--paper); color: var(--green-deep); border-color: var(--paper); }

/* ---------- hero ---------- */

.hero { padding: 5.5rem 0 4.5rem; border-bottom: 1px solid var(--line); position: relative; overflow: hidden; }

.hero-mark {
  position: absolute; right: -2.5rem; top: 50%;
  transform: translateY(-50%) rotate(-4deg);
  width: clamp(15rem, 28vw, 24rem); height: auto;
  color: var(--green); opacity: 0.08;
  pointer-events: none;
}

@media (max-width: 54rem) { .hero-mark { display: none; } }

.hero .wrap { position: relative; }

.eyebrow {
  font-family: var(--f-mono);
  font-size: 0.72rem; letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--brass); margin: 0 0 1.1rem;
}

.hero h1 {
  font-family: var(--f-display);
  font-size: clamp(2.1rem, 5vw, 3.4rem);
  font-weight: 700; line-height: 1.07; letter-spacing: -0.022em;
  margin: 0 0 1.2rem; max-width: 21ch; text-wrap: balance;
}

.hero .lede {
  font-size: 1.14rem; color: var(--slate);
  max-width: 34rem; margin: 0 0 2rem;
}

.hero .actions { display: flex; gap: 0.8rem; flex-wrap: wrap; }

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

.section { padding: 4.2rem 0; }
.section + .section { border-top: 1px solid var(--line); }
.section.tinted { background: var(--green-wash); border-top: 1px solid var(--line); }
.section.dark { background: var(--green-deep); color: var(--paper); }
.section.dark .eyebrow { color: var(--brass); }
.section.dark h2 { color: var(--paper); }
.section.dark p { color: #D3DED8; }

h2.section-title {
  font-family: var(--f-display);
  font-size: clamp(1.5rem, 3vw, 2.1rem);
  font-weight: 700; line-height: 1.15; letter-spacing: -0.018em;
  margin: 0 0 1rem; max-width: 26ch; text-wrap: balance;
}

.section-intro { color: var(--slate); max-width: 40rem; margin: 0 0 2.4rem; }

/* ---------- cards ---------- */

.card-grid {
  display: grid; gap: 1.1rem;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
}

.card {
  background: var(--white);
  border: 1px solid var(--line-strong);
  border-radius: 4px;
  padding: 1.6rem 1.5rem;
  display: flex; flex-direction: column; gap: 0.6rem;
}

.card .k {
  font-family: var(--f-mono);
  font-size: 0.68rem; letter-spacing: 0.18em;
  color: var(--brass);
}

.card h3 {
  font-family: var(--f-display);
  font-size: 1.05rem; font-weight: 700; margin: 0;
}

.card p { margin: 0; font-size: 0.95rem; color: var(--slate); }

/* ---------- standards list (ledger style) ---------- */

.ledger { border-top: 2px solid var(--ink); }

.ledger .row {
  display: grid;
  grid-template-columns: 3rem 14rem 1fr;
  gap: 1.5rem;
  padding: 1.3rem 0;
  border-bottom: 1px solid var(--line);
}

.ledger .row .n { font-family: var(--f-mono); font-size: 0.8rem; color: var(--brass); padding-top: 0.2rem; }
.ledger .row h3 { font-family: var(--f-display); font-size: 1rem; font-weight: 700; margin: 0; }
.ledger .row p { margin: 0; font-size: 0.97rem; color: var(--slate); }

@media (max-width: 44rem) {
  .ledger .row { grid-template-columns: 2.4rem 1fr; }
  .ledger .row p { grid-column: 2; }
}

/* ---------- two-column ---------- */

.split { display: grid; gap: 2.6rem; grid-template-columns: 1fr 1fr; align-items: start; }

/* A details card that should sit beside the body copy rather than level with
   the heading above it. Drops roughly a quarter down the section. */
.facts-col { margin-top: 3rem; }

@media (max-width: 50rem) {
  .split { grid-template-columns: 1fr; }
  /* single column: the card follows the text, so the offset must go */
  .facts-col { margin-top: 0; }
}

/* ---------- prose (About, Privacy) ---------- */

.prose { max-width: 42rem; }
/* The first element in a prose column must not carry its top margin, or the
   column starts lower than whatever sits beside it in a .split grid. */
.prose > :first-child { margin-top: 0; }
.prose p { margin: 0 0 1.1rem; }
.prose h2 {
  font-family: var(--f-display);
  font-size: 1.35rem; font-weight: 700; letter-spacing: -0.01em;
  margin: 2.4rem 0 0.8rem;
}
.prose ul { padding-left: 1.3rem; }
.prose li { margin-bottom: 0.5rem; }

/* ---------- facts block ---------- */

.facts {
  font-family: var(--f-mono);
  font-size: 0.8rem; line-height: 1.9;
  background: var(--white);
  border: 1px solid var(--line-strong);
  border-radius: 4px;
  padding: 1.3rem 1.4rem;
}

.facts b { font-weight: 500; color: var(--slate); display: inline-block; min-width: 9.5rem; }

/* ---------- CTA band ---------- */

.cta-band { text-align: left; }
.cta-band .inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 2rem; flex-wrap: wrap;
}
.cta-band h2 { margin: 0; }

/* ---------- footer ---------- */

.site-footer {
  background: var(--green-deep);
  color: #C7D4CE;
  padding: 3rem 0 2.2rem;
  font-family: var(--f-display);
  font-size: 0.83rem;
}

.site-footer .cols {
  display: grid; gap: 2rem;
  grid-template-columns: 2fr 1fr 1fr;
  margin-bottom: 2.2rem;
}

@media (max-width: 50rem) { .site-footer .cols { grid-template-columns: 1fr; } }

.site-footer h2 {
  font-size: 0.68rem; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--brass); margin: 0 0 0.8rem;
}

.site-footer a { color: #E8EEE9; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 0.5rem; }

.site-footer .legal {
  border-top: 1px solid #2A5346;
  padding-top: 1.4rem;
  font-family: var(--f-mono);
  font-size: 0.7rem; letter-spacing: 0.04em;
  color: #9DB3AA;
  display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap;
}

.footer-logo { display: flex; align-items: center; gap: 0.6rem; margin-bottom: 0.9rem; }
.footer-logo svg { width: 26px; height: 26px; }
.footer-logo span { font-weight: 700; color: var(--paper); letter-spacing: 0.02em; }

/* ---------- mobile nav ---------- */

@media (max-width: 46rem) {

  /* ---- header collapses to logo + menu button ---- */
  .site-header .bar { flex-wrap: nowrap; gap: 1rem; padding: 0.7rem 1.4rem; }
  .logo svg { width: 30px; height: 30px; }
  .nav-toggle { display: block; }

  .site-nav {
    display: none;
    position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    padding: 0.2rem 1.4rem 1.1rem;
    box-shadow: 0 14px 26px rgba(23, 32, 25, 0.08);
  }
  .site-nav.is-open { display: flex; }

  .site-nav a {
    font-size: 0.95rem;
    padding: 0.9rem 0;
    border-bottom: 1px solid var(--line);
  }
  .site-nav a:hover { border-bottom-color: var(--line); }
  .site-nav a[aria-current="page"] { color: var(--green); border-bottom-color: var(--line); }
  .site-nav a.btn,
  .site-nav a.btn[aria-current="page"] {
    margin-top: 1rem; text-align: center;
    border: 2px solid var(--green);
  }

  /* ---- spacing ---- */
  .hero { padding: 2.8rem 0 2.6rem; }
  .section { padding: 2.8rem 0; }
  .hero .actions { gap: 0.7rem; }
  .hero .actions .btn { flex: 1 1 auto; }

  /* label/value pairs stack instead of running off the screen */
  .facts b { display: block; min-width: 0; margin-top: 0.75rem; }
  .facts > b:first-child { margin-top: 0; }

  .cta-band .inner { gap: 1.4rem; }
  .site-footer .cols { gap: 2.2rem; }
}
