/* STL Water Softener Reviews - editorial review blog styles */
/* Palette: white, navy #1e3a8a, gold #d4a017, gray #6b7280 */

:root {
  --navy: #1e3a8a;
  --navy-deep: #172c66;
  --gold: #d4a017;
  --gold-deep: #8a6a10;
  --gold-wash: rgba(212, 160, 23, 0.09);
  --gray: #6b7280;
  --ink: #333d4d;
  --line: #e5e7eb;
  --navy-wash: #f0f4fb;
  --serif: 'Merriweather', Georgia, 'Times New Roman', serif;
  --sans: 'Work Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--serif);
  font-size: 17px;
  line-height: 1.75;
  color: var(--ink);
  background: #ffffff;
}

[hidden] {
  display: none !important;
}

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

a {
  color: var(--navy);
}

:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 2px;
  border-radius: 2px;
}

.container {
  max-width: 820px;
  margin: 0 auto;
  padding: 0 20px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--navy);
  color: #fff;
  padding: 10px 16px;
  font-family: var(--sans);
  font-weight: 600;
  z-index: 100;
}

.skip-link:focus {
  left: 12px;
  top: 12px;
}

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

.gold-rule {
  height: 5px;
  background: var(--gold);
}

.masthead {
  border-bottom: 3px double var(--navy);
  background: #fff;
}

.masthead-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
  padding: 18px 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.brand-mark {
  width: 38px;
  height: 38px;
  flex: none;
}

.brand-name {
  font-family: var(--sans);
  font-weight: 800;
  font-size: 20px;
  letter-spacing: -0.01em;
  color: var(--navy);
  line-height: 1.15;
}

.brand-tag {
  font-family: var(--serif);
  font-style: italic;
  font-size: 12.5px;
  color: var(--gray);
  line-height: 1.3;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 22px;
  flex-wrap: wrap;
}

.site-nav a {
  font-family: var(--sans);
  font-weight: 600;
  font-size: 14.5px;
  color: var(--gray);
  text-decoration: none;
}

.site-nav a:hover {
  color: var(--navy);
}

.site-nav a.nav-cta {
  background: var(--navy);
  color: #fff;
  padding: 9px 16px;
  border-radius: 8px;
}

.site-nav a.nav-cta:hover {
  background: var(--navy-deep);
  color: #fff;
}

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

.hero {
  padding: 44px 0 8px;
}

.kicker {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold-deep);
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.kicker .kicker-sep {
  color: var(--line);
}

.kicker a {
  color: var(--gray);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: none;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.kicker a:hover {
  color: var(--navy);
}

h1 {
  font-family: var(--sans);
  font-weight: 800;
  font-size: clamp(30px, 5.4vw, 44px);
  line-height: 1.12;
  letter-spacing: -0.02em;
  color: var(--navy);
  margin: 14px 0 18px;
}

.lede {
  font-size: 18px;
  line-height: 1.8;
  color: var(--ink);
}

.byline {
  margin-top: 16px;
  font-family: var(--sans);
  font-size: 13.5px;
  color: var(--gray);
}

.byline strong {
  color: var(--ink);
  font-weight: 600;
}

/* Criteria chips */

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 22px;
}

.chip {
  font-family: var(--sans);
  font-weight: 600;
  font-size: 12.5px;
  color: var(--navy);
  background: var(--navy-wash);
  border: 1px solid #ccd7ef;
  border-radius: 999px;
  padding: 6px 13px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.chip .chip-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--gold);
  flex: none;
}

/* At-a-glance index card */

.glance {
  margin: 34px 0 10px;
  border: 1px solid var(--line);
  border-left: 4px solid var(--gold);
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 1px 3px rgba(30, 58, 138, 0.06);
  padding: 22px 26px;
}

.glance h2 {
  font-family: var(--sans);
  font-weight: 800;
  font-size: 13px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gray);
  margin-bottom: 12px;
}

.glance ol {
  list-style: none;
  counter-reset: glance;
  display: grid;
  gap: 8px;
}

.glance li {
  counter-increment: glance;
  display: flex;
  align-items: baseline;
  gap: 10px;
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.45;
}

.glance li::before {
  content: counter(glance);
  font-weight: 800;
  font-size: 13px;
  color: #fff;
  background: var(--navy);
  border-radius: 50%;
  width: 21px;
  height: 21px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  transform: translateY(3px);
}

.glance li:first-child::before {
  background: var(--gold);
  color: #2c2205;
}

.glance li a {
  font-weight: 600;
  text-decoration: none;
  color: var(--navy);
}

.glance li a:hover {
  text-decoration: underline;
  text-decoration-color: var(--gold);
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

.glance li .glance-note {
  color: var(--gray);
  font-size: 13.5px;
}

/* ---------- Section titles ---------- */

.section {
  padding: 44px 0 0;
}

.section-title {
  font-family: var(--sans);
  font-weight: 800;
  font-size: 27px;
  letter-spacing: -0.015em;
  color: var(--navy);
  margin-bottom: 8px;
}

.section-title::after {
  content: "";
  display: block;
  width: 52px;
  height: 4px;
  background: var(--gold);
  border-radius: 2px;
  margin-top: 10px;
}

.section-sub {
  color: var(--gray);
  font-size: 15.5px;
  margin-bottom: 26px;
  max-width: 620px;
}

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

.review-list {
  display: grid;
  gap: 30px;
}

.review-card {
  position: relative;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  padding: 30px 32px;
  box-shadow: 0 1px 3px rgba(30, 58, 138, 0.05);
  scroll-margin-top: 24px;
}

.review-card.top-pick {
  border: 2px solid var(--navy);
  box-shadow: 0 10px 34px rgba(30, 58, 138, 0.12);
}

.ribbon {
  position: absolute;
  top: -14px;
  left: 26px;
  background: var(--gold);
  color: #2c2205;
  font-family: var(--sans);
  font-weight: 800;
  font-size: 11.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 6px 14px;
  border-radius: 999px;
  box-shadow: 0 2px 6px rgba(138, 106, 16, 0.3);
}

.review-head {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.rank-badge {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--navy);
  color: #fff;
  font-family: var(--sans);
  font-weight: 800;
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: none;
  margin-top: 3px;
}

.top-pick .rank-badge {
  background: var(--gold);
  color: #2c2205;
}

.review-title h2 {
  font-family: var(--sans);
  font-weight: 800;
  font-size: 24px;
  letter-spacing: -0.015em;
  line-height: 1.2;
  color: var(--navy);
}

.review-title h2 a {
  color: var(--navy);
  text-decoration: none;
}

.review-title h2 a:hover {
  text-decoration: underline;
  text-decoration-color: var(--gold);
  text-decoration-thickness: 3px;
  text-underline-offset: 4px;
}

.meta-line {
  font-family: var(--sans);
  font-weight: 500;
  font-size: 13px;
  color: var(--gray);
  margin-top: 3px;
}

.rating-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 9px;
}

/* Stars */

.stars {
  display: inline-flex;
  align-items: center;
  gap: 2px;
}

.stars svg {
  width: 21px;
  height: 21px;
  flex: none;
}

.stars .stars-num {
  font-family: var(--sans);
  font-weight: 800;
  font-size: 16px;
  color: var(--navy);
  margin-left: 6px;
}

.stars .stars-outof {
  font-family: var(--sans);
  font-weight: 500;
  font-size: 12.5px;
  color: var(--gray);
}

.stars-sm svg {
  width: 15px;
  height: 15px;
}

.stars-sm .stars-num {
  font-size: 13px;
  margin-left: 4px;
}

.qual-label {
  display: inline-block;
  font-family: var(--sans);
  font-weight: 600;
  font-size: 12.5px;
  color: var(--gold-deep);
  background: var(--gold-wash);
  border: 1px solid rgba(212, 160, 23, 0.45);
  border-radius: 999px;
  padding: 4px 12px;
}

.not-scored {
  font-family: var(--sans);
  font-size: 12px;
  color: var(--gray);
}

/* Review body */

.review-body {
  margin-top: 18px;
}

.review-body p {
  margin-bottom: 14px;
}

.review-body p:last-child {
  margin-bottom: 0;
}

mark {
  background: linear-gradient(180deg, transparent 58%, rgba(212, 160, 23, 0.32) 58%);
  color: inherit;
  padding: 0 2px;
}

/* Verdict box: the notebook annotation */

.verdict {
  margin-top: 20px;
  background: var(--gold-wash);
  border-left: 4px solid var(--gold);
  border-radius: 0 10px 10px 0;
  padding: 15px 19px;
}

.verdict-label {
  font-family: var(--sans);
  font-weight: 800;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold-deep);
}

.verdict p {
  font-style: italic;
  font-size: 16px;
  line-height: 1.65;
  margin-top: 5px;
}

/* Pros */

.pros {
  margin-top: 22px;
  border-top: 1px dashed #d7dbe3;
  padding-top: 17px;
}

.pros h3 {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gray);
  margin-bottom: 10px;
}

.pros ul {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px 22px;
}

.pros li {
  display: flex;
  gap: 9px;
  align-items: flex-start;
  font-size: 15px;
  line-height: 1.55;
}

.pros li svg {
  width: 17px;
  height: 17px;
  flex: none;
  color: var(--gold-deep);
  margin-top: 4px;
}

/* Card CTA row */

.card-cta {
  margin-top: 22px;
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.btn {
  display: inline-block;
  font-family: var(--sans);
  font-weight: 700;
  font-size: 15px;
  line-height: 1;
  padding: 13px 22px;
  border-radius: 9px;
  text-decoration: none;
  border: 0;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease, transform 0.15s ease;
}

.btn-solid {
  background: var(--navy);
  color: #fff;
}

.btn-solid:hover {
  background: var(--navy-deep);
}

.btn-outline {
  background: #fff;
  color: var(--navy);
  box-shadow: inset 0 0 0 2px var(--navy);
}

.btn-outline:hover {
  background: var(--navy-wash);
}

.btn-gold {
  background: var(--gold);
  color: #2c2205;
}

.btn-gold:hover {
  background: #c2920f;
}

.tel-link {
  font-family: var(--sans);
  font-weight: 600;
  font-size: 15px;
  color: var(--navy);
  text-decoration: none;
}

.tel-link:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ---------- Quote panel ---------- */

.quote-section {
  padding: 52px 0 0;
  scroll-margin-top: 16px;
}

.quote-panel {
  background: var(--navy);
  border-radius: 16px;
  padding: 40px 36px;
  color: #fff;
}

.quote-panel h2 {
  font-family: var(--sans);
  font-weight: 800;
  font-size: 26px;
  letter-spacing: -0.015em;
  line-height: 1.2;
  color: #fff;
}

.quote-panel .quote-sub {
  color: #c8d3ef;
  font-size: 15.5px;
  margin-top: 10px;
  max-width: 560px;
}

.quote-form {
  margin-top: 24px;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 14px;
}

.field label {
  display: block;
  font-family: var(--sans);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.02em;
  color: #dbe3f7;
  margin-bottom: 6px;
}

.field input {
  width: 100%;
  font-family: var(--sans);
  font-size: 16px;
  color: #1f2430;
  background: #fff;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 8px;
  padding: 13px 14px;
}

.field input::placeholder {
  color: #9aa3b5;
}

.form-actions {
  margin-top: 18px;
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}

.form-actions .btn {
  font-size: 16px;
  padding: 15px 26px;
}

.form-actions .btn:disabled {
  opacity: 0.7;
  cursor: wait;
}

.quote-alt {
  font-family: var(--sans);
  font-size: 14px;
  color: #c8d3ef;
}

.quote-alt a {
  color: var(--gold);
  font-weight: 700;
  text-decoration: none;
}

.quote-alt a:hover {
  text-decoration: underline;
}

.form-error {
  margin-top: 14px;
  font-family: var(--sans);
  font-weight: 600;
  font-size: 14px;
  color: #ffd9c2;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 10px 14px;
}

.form-fineprint {
  margin-top: 16px;
  font-family: var(--sans);
  font-size: 12.5px;
  line-height: 1.6;
  color: #a9b6dd;
  max-width: 560px;
}

.form-success {
  margin-top: 24px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(212, 160, 23, 0.65);
  border-radius: 12px;
  padding: 24px 26px;
}

.form-success .success-head {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-family: var(--sans);
  font-weight: 800;
  font-size: 19px;
  line-height: 1.35;
  color: #fff;
}

.form-success .success-head svg {
  width: 26px;
  height: 26px;
  flex: none;
  color: var(--gold);
  margin-top: 2px;
}

.form-success p {
  margin-top: 10px;
  font-size: 15px;
  color: #c8d3ef;
}

.form-success a {
  color: var(--gold);
  font-weight: 700;
}

/* ---------- FAQ ---------- */

.faq-list {
  border-top: 1px solid var(--line);
}

.faq-list details {
  border-bottom: 1px solid var(--line);
}

.faq-list summary {
  list-style: none;
  cursor: pointer;
  font-family: var(--sans);
  font-weight: 600;
  font-size: 16.5px;
  color: var(--navy);
  padding: 18px 34px 18px 2px;
  position: relative;
}

.faq-list summary::-webkit-details-marker {
  display: none;
}

.faq-list summary::after {
  content: "+";
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  font-weight: 700;
  font-size: 20px;
  color: var(--gold-deep);
  transition: transform 0.15s ease;
}

.faq-list details[open] summary::after {
  content: "-";
}

.faq-list .faq-answer {
  padding: 0 2px 20px;
  font-size: 16px;
  color: var(--ink);
}

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

.site-footer {
  margin-top: 64px;
  border-top: 3px double var(--navy);
  padding: 34px 0 44px;
  background: #fff;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--sans);
  font-weight: 800;
  font-size: 16px;
  color: var(--navy);
}

.footer-brand svg {
  width: 26px;
  height: 26px;
}

.disclosure {
  margin-top: 14px;
  font-family: var(--sans);
  font-size: 13.5px;
  line-height: 1.7;
  color: var(--gray);
  max-width: 660px;
}

.footer-links {
  margin-top: 16px;
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  font-family: var(--sans);
  font-size: 13.5px;
}

.footer-links a {
  color: var(--navy);
  font-weight: 600;
  text-decoration: none;
}

.footer-links a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.footer-copy {
  margin-top: 18px;
  font-family: var(--sans);
  font-size: 12.5px;
  color: var(--gray);
}

/* ---------- Sticky mobile CTA ---------- */

.sticky-cta {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 60;
  display: none;
  background: var(--navy);
  padding: 10px 14px calc(10px + env(safe-area-inset-bottom));
  box-shadow: 0 -6px 20px rgba(23, 44, 102, 0.28);
  transition: transform 0.25s ease;
}

.sticky-cta a {
  display: block;
  text-align: center;
  background: var(--gold);
  color: #2c2205;
  font-family: var(--sans);
  font-weight: 800;
  font-size: 15px;
  padding: 14px 16px;
  border-radius: 10px;
  text-decoration: none;
}

.sticky-cta.is-hidden {
  transform: translateY(120%);
}

/* ---------- Methodology page ---------- */

.article {
  padding: 44px 0 0;
}

.article h1 {
  margin-bottom: 14px;
}

.article .lede {
  max-width: 660px;
}

.article h2 {
  font-family: var(--sans);
  font-weight: 800;
  font-size: 23px;
  letter-spacing: -0.015em;
  color: var(--navy);
  margin: 42px 0 14px;
}

.article p {
  margin-bottom: 15px;
  max-width: 680px;
}

.article ul {
  margin: 0 0 15px 22px;
}

.article li {
  margin-bottom: 7px;
}

.table-wrap {
  overflow-x: auto;
  margin: 8px 0 10px;
}

.criteria-table {
  width: 100%;
  min-width: 560px;
  border-collapse: collapse;
  font-family: var(--sans);
  font-size: 15px;
}

.criteria-table th {
  text-align: left;
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gray);
  border-bottom: 2px solid var(--navy);
  padding: 10px 12px;
}

.criteria-table td {
  border-bottom: 1px solid var(--line);
  padding: 15px 12px;
  vertical-align: top;
  line-height: 1.6;
}

.criteria-table td.crit-name {
  font-weight: 700;
  color: var(--navy);
  white-space: nowrap;
}

.criteria-table td.crit-weight {
  font-weight: 800;
  font-size: 17px;
  color: var(--gold-deep);
  white-space: nowrap;
}

.plain-statement {
  background: var(--navy-wash);
  border-left: 4px solid var(--navy);
  border-radius: 0 10px 10px 0;
  padding: 16px 20px;
  margin: 8px 0 16px;
  font-style: italic;
}

/* ---------- Responsive ---------- */

@media (max-width: 760px) {
  body.page-home {
    padding-bottom: 88px;
  }

  .sticky-cta {
    display: block;
  }

  .masthead-inner {
    padding: 14px 0;
  }

  .site-nav {
    gap: 14px;
  }

  .review-card {
    padding: 24px 20px;
  }

  .review-head {
    gap: 12px;
  }

  .rank-badge {
    width: 34px;
    height: 34px;
    font-size: 16px;
  }

  .pros ul {
    grid-template-columns: 1fr;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .quote-panel {
    padding: 30px 22px;
  }

  .form-actions .btn {
    width: 100%;
    text-align: center;
  }
}

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

  .btn,
  .sticky-cta,
  .faq-list summary::after {
    transition: none;
  }
}
