/* Tri-State Fire Guide — independent fire-protection service directory
   Design: clean, trade-professional. Paper, slate ink, one fire red. System fonts. */

:root {
  --paper: #f7f6f3;
  --paper-deep: #eeece6;
  --ink: #1d1e20;
  --ink-soft: #4f5257;
  --ink-faint: #84878d;
  --line: #d8d5cd;
  --red: #a8352a;
  --red-deep: #82261d;
  --red-wash: #f6e4e1;
  --slate: #2c3e50;
  --slate-deep: #1f2f3d;
  --slate-wash: #e3e9ee;
  --amber: #9a6b0f;
  --amber-wash: #f7ecd6;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --wrap: 64rem;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.65;
}

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

.skip {
  position: absolute; left: -9999px; top: 0;
  background: var(--ink); color: var(--paper);
  padding: .5rem 1rem; z-index: 10;
}
.skip:focus { left: 0; }

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

.mast { border-bottom: 1px solid var(--line); background: var(--paper); }
.mast-inner {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 1rem; padding: 1rem 1.25rem; max-width: var(--wrap); margin: 0 auto;
}
.wordmark {
  font-family: var(--serif); font-weight: 700; font-size: 1.35rem;
  letter-spacing: .01em; color: var(--ink); text-decoration: none; white-space: nowrap;
}
.wordmark .mark { color: var(--red); }
.mast nav { display: flex; flex-wrap: wrap; gap: .25rem 1.1rem; font-size: .92rem; }
.mast nav a { color: var(--ink-soft); text-decoration: none; }
.mast nav a:hover { color: var(--ink); text-decoration: underline; }

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

.hero { padding: 3.5rem 0 3rem; border-bottom: 1px solid var(--line); }
.kicker {
  font-size: .78rem; font-weight: 700; letter-spacing: .14em;
  text-transform: uppercase; color: var(--red); margin: 0 0 .9rem;
}
.hero h1 {
  font-family: var(--serif); font-size: clamp(2rem, 5vw, 3.1rem);
  line-height: 1.12; margin: 0 0 1rem; max-width: 24ch;
}
.lede { font-size: 1.15rem; color: var(--ink-soft); max-width: 58ch; margin: 0 0 1.5rem; }
.hero-ctas { display: flex; flex-wrap: wrap; gap: .75rem; align-items: center; }

.btn {
  display: inline-block; padding: .7rem 1.3rem; border-radius: 4px;
  background: var(--red); color: #fff; text-decoration: none;
  font-weight: 600; font-size: 1rem; border: 1px solid var(--red-deep);
  cursor: pointer; font-family: inherit;
}
.btn:hover { background: var(--red-deep); }
.btn-ghost {
  background: transparent; color: var(--red-deep);
  border: 1px solid var(--red);
}
.btn-ghost:hover { background: var(--red-wash); }
.btn-danger { color: var(--red-deep); }
.btn-big { font-size: 1.05rem; padding: .8rem 1.6rem; }

.note-band {
  background: var(--amber-wash); border: 1px solid #e5d3ab; border-radius: 6px;
  padding: .8rem 1.1rem; font-size: .95rem; color: #6b4a10; margin: 1.5rem 0 0;
}
.warn-band {
  background: var(--red-wash); border: 1px solid #e0b6b0; border-radius: 6px;
  padding: .8rem 1.1rem; font-size: .95rem; color: var(--red-deep); margin: 1.5rem 0 0;
}

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

section.band { padding: 3rem 0; }
section.band + section.band { border-top: 1px solid var(--line); }
.band h2 {
  font-family: var(--serif); font-size: 1.7rem; line-height: 1.25; margin: 0 0 .5rem;
}
.band .sub { color: var(--ink-soft); margin: 0 0 1.75rem; max-width: 60ch; }

.grid-3 { display: grid; gap: 1.25rem; grid-template-columns: 1fr; }
@media (min-width: 720px) { .grid-3 { grid-template-columns: repeat(3, 1fr); } }

.card {
  background: #fff; border: 1px solid var(--line); border-radius: 6px;
  padding: 1.25rem; display: flex; flex-direction: column; gap: .5rem;
}
.card h3 { margin: 0; font-size: 1.08rem; font-family: var(--serif); }
.card h3 a { color: var(--ink); text-decoration: none; }
.card h3 a:hover { text-decoration: underline; }
.card p { margin: 0; color: var(--ink-soft); font-size: .95rem; }
.card .more {
  margin-top: auto; padding-top: .5rem; font-size: .92rem; font-weight: 600;
  color: var(--red-deep); text-decoration: none;
}
.card .more:hover { text-decoration: underline; }

/* ---------- provider directory ---------- */

.filterbar {
  background: #fff; border: 1px solid var(--line); border-radius: 6px;
  padding: 1rem 1.1rem; margin: 0 0 1.5rem;
  display: flex; flex-wrap: wrap; gap: .75rem 1.25rem; align-items: center;
}
.filterbar label { font-size: .9rem; font-weight: 600; display: inline-flex; align-items: center; gap: .4rem; }
.filterbar select, .filterbar input[type="search"] {
  font: inherit; font-size: .95rem; padding: .45rem .6rem;
  border: 1px solid var(--line); border-radius: 4px; background: var(--paper); color: var(--ink);
}
.filterbar input[type="search"] { min-width: 13rem; }
.filterbar .count { margin-left: auto; color: var(--ink-faint); font-size: .9rem; }
.no-results { display: none; padding: 2rem 0; color: var(--ink-soft); }

.prov-list { display: grid; gap: 1.1rem; grid-template-columns: 1fr; }
@media (min-width: 720px) { .prov-list { grid-template-columns: 1fr 1fr; } }

.prov-card {
  background: #fff; border: 1px solid var(--line); border-radius: 6px;
  padding: 1.2rem 1.25rem; display: flex; flex-direction: column; gap: .6rem;
  position: relative;
}
.prov-card h3 { margin: 0; font-family: var(--serif); font-size: 1.15rem; line-height: 1.3; }
.prov-card h3 a { color: var(--ink); text-decoration: none; }
.prov-card h3 a:hover { text-decoration: underline; }
.prov-loc { font-size: .88rem; color: var(--ink-faint); letter-spacing: .02em; }
.facts { display: grid; gap: .3rem; font-size: .92rem; margin: .25rem 0 0; padding: 0; }
.facts div { display: flex; gap: .5rem; }
.facts dt { flex: 0 0 8.5rem; color: var(--ink-faint); margin: 0; }
.facts dd { margin: 0; color: var(--ink-soft); }
.aspub { color: var(--ink-faint); font-size: .85rem; }
.stamp {
  display: inline-flex; align-items: center; gap: .45rem;
  font-size: .8rem; font-weight: 600; letter-spacing: .02em; color: var(--slate-deep);
}
.stamp .dot { width: .5rem; height: .5rem; border-radius: 50%; background: var(--slate); }
.part-tag {
  position: absolute; top: .8rem; right: .9rem;
  font-size: .72rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
  color: #fff; background: var(--slate); border-radius: 3px; padding: .15rem .45rem;
}

/* ---------- provider detail ---------- */

.crumb { font-size: .9rem; color: var(--ink-faint); margin: 1.25rem 0 0; }
.crumb a { color: var(--ink-soft); }
.detail-head { padding: 2.25rem 0 1.5rem; border-bottom: 1px solid var(--line); }
.detail-head h1 { font-family: var(--serif); font-size: clamp(1.7rem, 4vw, 2.4rem); margin: .4rem 0 .4rem; }
.detail-grid { display: grid; gap: 2rem; grid-template-columns: 1fr; padding: 2rem 0 3rem; }
@media (min-width: 860px) { .detail-grid { grid-template-columns: 1.6fr 1fr; } }
.sec-h { font-family: var(--serif); font-size: 1.3rem; margin: 1.8rem 0 .6rem; }

.qtable { width: 100%; border-collapse: collapse; font-size: .95rem; background: #fff; border: 1px solid var(--line); border-radius: 6px; overflow: hidden; }
.qtable th, .qtable td { text-align: left; padding: .65rem .8rem; border-bottom: 1px solid var(--paper-deep); vertical-align: top; }
.qtable tr:last-child th, .qtable tr:last-child td { border-bottom: 0; }
.qtable th { width: 42%; color: var(--ink-faint); font-weight: 600; background: var(--paper); }

.sidebox { background: #fff; border: 1px solid var(--line); border-radius: 6px; padding: 1.1rem 1.2rem; margin: 0 0 1.25rem; }
.sidebox h2 { font-family: var(--serif); font-size: 1.15rem; margin: 0 0 .5rem; }
.sidebox p, .sidebox li { font-size: .93rem; color: var(--ink-soft); }
.sidebox ul { margin: .4rem 0 0; padding-left: 1.1rem; }
.sidebox .fine { margin: .6rem 0 0; }
.src-list { font-size: .85rem; word-break: break-all; }
.part-box { border-color: var(--slate); border-width: 2px; }

/* ---------- prose pages ---------- */

.prose { padding: 2.25rem 0 3.5rem; }
.prose h1 { font-family: var(--serif); font-size: clamp(1.9rem, 4.5vw, 2.6rem); line-height: 1.15; margin: .35rem 0 1rem; }
.prose h2 { font-family: var(--serif); font-size: 1.45rem; margin: 2.2rem 0 .6rem; }
.prose h3 { font-size: 1.08rem; margin: 1.6rem 0 .4rem; }
.prose p, .prose li { color: var(--ink-soft); }
.prose strong { color: var(--ink); }
.prose a { color: var(--red-deep); }
.prose ul, .prose ol { padding-left: 1.35rem; }
.prose li { margin: .35rem 0; }
.prose .srcnote { font-size: .85rem; color: var(--ink-faint); border-top: 1px solid var(--line); margin-top: 2.5rem; padding-top: 1rem; }
.prose .srcnote a { color: var(--ink-faint); }
.prose-list li { margin: .5rem 0; }

.callout {
  background: var(--slate-wash); border-left: 3px solid var(--slate);
  padding: .9rem 1.1rem; border-radius: 0 6px 6px 0; margin: 1.5rem 0; color: var(--slate-deep);
  font-size: .98rem;
}

/* ---------- request form ---------- */

.inq-form fieldset {
  border: 1px solid var(--line); border-radius: 6px; background: #fff;
  margin: 0 0 1.5rem; padding: 1.25rem 1.25rem 1.4rem;
}
.inq-form legend {
  font-family: var(--serif); font-weight: 700; font-size: 1.1rem;
  padding: 0 .5rem; background: var(--paper);
}
.inq-form label { display: block; font-weight: 600; font-size: .95rem; margin: 0 0 1rem; }
.inq-form label .hint { display: block; font-weight: 400; color: var(--ink-faint); font-size: .85rem; }
.inq-form input[type="text"], .inq-form input[type="email"], .inq-form input[type="tel"],
.inq-form select, .inq-form textarea {
  display: block; width: 100%; margin-top: .35rem;
  font: inherit; font-size: .98rem; padding: .55rem .7rem;
  border: 1px solid var(--line); border-radius: 4px; background: var(--paper); color: var(--ink);
}
.inq-form textarea { resize: vertical; }
.inq-form label.consent { font-weight: 400; font-size: .9rem; color: var(--ink-soft); }
.inq-form label.consent input { margin-right: .5rem; }
.inq-form .hp { position: absolute; left: -9999px; height: 0; width: 0; opacity: 0; }
.inq-form .fine { color: var(--ink-faint); font-size: .85rem; }
.form-error {
  background: var(--red-wash); color: var(--red-deep); border: 1px solid #e0b6b0;
  padding: .6rem .9rem; border-radius: 4px; font-size: .92rem;
}
.prov-pick {
  display: flex; gap: .6rem; align-items: flex-start;
  padding: .6rem .7rem; border: 1px solid var(--line); border-radius: 4px;
  margin: 0 0 .5rem; font-size: .95rem; background: var(--paper);
}
.prov-pick input { margin-top: .3rem; }
.prov-pick .pl { font-weight: 600; display: block; }
.prov-pick .ps { color: var(--ink-faint); font-size: .85rem; font-weight: 400; display: block; }
.inq-done { background: var(--slate-wash); border: 1px solid var(--slate); border-radius: 6px; padding: 1.5rem; margin: 1rem 0 3rem; }
.inq-done h2 { font-family: var(--serif); margin: 0 0 .5rem; }

/* ---------- compare tool ---------- */

.cmp-toolbar { display: flex; flex-wrap: wrap; gap: .6rem; align-items: center; margin: 0 0 1.5rem; }
.cmp-table-wrap { overflow-x: auto; background: #fff; border: 1px solid var(--line); border-radius: 6px; }
table.cmp { border-collapse: collapse; width: 100%; font-size: .92rem; min-width: 40rem; }
table.cmp th, table.cmp td { border: 1px solid var(--paper-deep); padding: .55rem .65rem; vertical-align: top; text-align: left; }
table.cmp thead th { background: var(--slate); color: #fff; font-family: var(--serif); font-size: 1rem; }
table.cmp tbody th { width: 9.5rem; background: var(--paper); color: var(--ink-faint); font-weight: 600; font-size: .85rem; }
table.cmp td input, table.cmp td textarea {
  width: 100%; font: inherit; font-size: .92rem; padding: .35rem .45rem;
  border: 1px solid transparent; border-radius: 3px; background: transparent; color: var(--ink);
}
table.cmp td input:hover, table.cmp td textarea:hover { border-color: var(--line); }
table.cmp td input:focus, table.cmp td textarea:focus { border-color: var(--slate); background: var(--paper); outline: none; }
table.cmp td textarea { resize: vertical; min-height: 4.2rem; }
.cmp-remove {
  background: none; border: 1px solid #e0b6b0; color: var(--red-deep); border-radius: 3px;
  font-size: .78rem; padding: .15rem .5rem; cursor: pointer; float: right;
}
.cmp-remove:hover { background: var(--red-wash); }
.cmp-empty { color: var(--ink-soft); background: #fff; border: 1px dashed var(--line); border-radius: 6px; padding: 2rem 1.5rem; text-align: center; }

@media print {
  .mast nav, .hero-ctas, .foot, .note-band, .warn-band, .btn, .cmp-toolbar, .skip { display: none !important; }
  body { background: #fff; font-size: 11pt; }
  .prose { padding: 0; }
  a { color: #000; text-decoration: none; }
  table.cmp td input, table.cmp td textarea { border: 0; }
}

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

.foot { border-top: 1px solid var(--line); background: var(--paper-deep); margin-top: 2rem; }
.foot-inner {
  max-width: var(--wrap); margin: 0 auto; padding: 2rem 1.25rem;
  display: grid; gap: 1.5rem; grid-template-columns: 1fr;
}
@media (min-width: 720px) { .foot-inner { grid-template-columns: 2fr 1fr; } }
.foot .wordmark { font-size: 1.15rem; }
.foot-line { color: var(--ink-faint); font-size: .9rem; max-width: 52ch; margin: .4rem 0 0; }
.foot nav { display: grid; gap: .45rem; font-size: .92rem; align-content: start; }
.foot nav a { color: var(--ink-soft); text-decoration: none; }
.foot nav a:hover { color: var(--ink); text-decoration: underline; }
.fine { color: var(--ink-faint); font-size: .82rem; margin: 1rem 0 0; }
