/* ===== reconenginesreview.co.za =====
   Shared stylesheet for the consumer warning site.
   Dark, professional, print-friendly. Single source of truth. */

:root {
  --bg: #0d1117;
  --bg-elev: #161b22;
  --bg-elev-2: #1f2630;
  --text: #e6edf3;
  --text-dim: #9da7b3;
  --accent: #ffcc66;
  --danger: #ff7b72;
  --ok: #7ee787;
  --link: #79c0ff;
  --link-hover: #a5d6ff;
  --border: #30363d;
  --border-strong: #4a525d;
  --shadow: rgba(0, 0, 0, 0.28);
  --max-w: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, Helvetica, sans-serif;
  background: radial-gradient(circle at top, #182233 0, var(--bg) 42%);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
}
a { color: var(--link); text-decoration: none; }
a:hover { color: var(--link-hover); text-decoration: underline; }
img { max-width: 100%; height: auto; display: block; }
hr { border: 0; border-top: 1px solid var(--border); margin: 30px 0; }

/* ===== Banner ===== */
.banner {
  background: linear-gradient(90deg, rgba(255, 123, 114, 0.12), transparent);
  border-bottom: 1px solid rgba(255, 123, 114, 0.25);
  padding: 10px 20px;
  font-size: 0.92rem;
  color: var(--text-dim);
  text-align: center;
}
.banner strong { color: var(--accent); }

/* ===== Nav ===== */
nav.main-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(13, 17, 23, 0.94);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
nav.main-nav .nav-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 12px 20px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}
nav.main-nav .brand {
  font-weight: 800;
  font-size: 1.05rem;
  color: var(--text);
  margin-right: auto;
  letter-spacing: -0.01em;
}
nav.main-nav .brand .brand-accent { color: var(--accent); }
nav.main-nav a.nav-link {
  display: inline-block;
  padding: 6px 10px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-dim);
  border-radius: 6px;
}
nav.main-nav a.nav-link:hover { color: var(--text); background: var(--bg-elev-2); text-decoration: none; }
nav.main-nav a.nav-link.active { color: var(--accent); background: rgba(255, 204, 102, 0.08); }

.nav-toggle {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text);
  padding: 6px 10px;
  border-radius: 6px;
  cursor: pointer;
  display: none;
}
@media (max-width: 820px) {
  .nav-toggle { display: inline-block; }
  nav.main-nav .nav-links { display: none; width: 100%; flex-direction: column; padding-top: 8px; }
  nav.main-nav .nav-links.open { display: flex; }
}

/* ===== Layout ===== */
main {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 22px 20px 60px;
}
.page-title {
  font-size: clamp(1.6rem, 3.5vw, 2.4rem);
  letter-spacing: -0.02em;
  margin: 14px 0 8px;
}
.page-lede {
  color: var(--text-dim);
  font-size: 1.05rem;
  max-width: 820px;
  margin: 0 0 22px;
}

/* ===== Hero / counter ===== */
.hero {
  text-align: center;
  padding: 40px 20px 50px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 30px;
}
.hero h1 {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  margin: 0 0 14px;
  letter-spacing: -0.025em;
}
.hero p {
  color: var(--text-dim);
  max-width: 800px;
  margin: 0 auto 28px;
  font-size: 1.05rem;
}
.clock-card {
  max-width: 980px;
  margin: 0 auto;
  padding: clamp(22px, 4vw, 44px);
  border: 1px solid rgba(255, 204, 102, 0.35);
  border-radius: 24px;
  background:
    linear-gradient(135deg, rgba(255, 204, 102, 0.10), transparent 36%),
    linear-gradient(180deg, rgba(31, 38, 48, 0.96), rgba(22, 27, 34, 0.96));
  box-shadow: 0 22px 80px var(--shadow);
}
.clock-label {
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--accent);
  font-weight: 800;
  font-size: 0.84rem;
  margin-bottom: 14px;
}
.counter-row {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px 16px;
  margin: 14px 0 10px;
}
.counter-unit {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 84px;
}
.counter-unit .num {
  font-family: "JetBrains Mono", "Courier New", Courier, monospace;
  font-size: clamp(2rem, 6vw, 4.6rem);
  line-height: 1;
  color: #fff;
  text-shadow: 0 0 28px rgba(255, 204, 102, 0.22);
  font-weight: 800;
}
.counter-unit .lbl {
  margin-top: 6px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 0.72rem;
  color: var(--text-dim);
}
.clock-sub {
  margin-top: 18px;
  color: var(--text-dim);
  font-size: 1rem;
}
.clock-sub strong { color: var(--text); }

/* ===== Victim counter (companion to the clock) ===== */
.victim-counter {
  max-width: 980px;
  margin: 22px auto 0;
  padding: 20px 24px;
  border: 1px solid rgba(255, 204, 102, 0.35);
  border-radius: 20px;
  background:
    linear-gradient(135deg, rgba(255, 204, 102, 0.10), transparent 40%),
    linear-gradient(180deg, rgba(31, 38, 48, 0.96), rgba(22, 27, 34, 0.96));
  box-shadow: 0 12px 40px var(--shadow);
  display: flex;
  align-items: center;
  gap: 22px;
  text-decoration: none;
  color: inherit;
  transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}
.victim-counter:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
  box-shadow: 0 20px 60px rgba(255, 204, 102, 0.15);
  text-decoration: none;
}
.victim-counter-num {
  font-family: "JetBrains Mono", "Courier New", Courier, monospace;
  font-size: clamp(2.6rem, 6.5vw, 4.4rem);
  line-height: 1;
  color: var(--accent);
  font-weight: 800;
  min-width: 84px;
  text-align: center;
  text-shadow: 0 0 28px rgba(255, 204, 102, 0.28);
}
.victim-counter-body {
  flex: 1;
  text-align: left;
  min-width: 0;
}
.victim-counter-lbl {
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--accent);
  font-weight: 800;
  font-size: 0.82rem;
}
.victim-counter-sub {
  color: var(--text);
  font-size: 1.02rem;
  margin-top: 3px;
}
.victim-counter-sub strong { color: var(--accent); }
.victim-counter-arrow {
  color: var(--accent);
  font-size: 1.6rem;
  flex-shrink: 0;
  transition: transform 0.15s ease;
}
.victim-counter:hover .victim-counter-arrow { transform: translate(4px, -4px); }
@media (max-width: 640px) {
  .victim-counter {
    flex-direction: column;
    text-align: center;
    padding: 24px 20px;
    gap: 12px;
  }
  .victim-counter-body { text-align: center; }
  .victim-counter-arrow { display: none; }
}

/* ===== Cost card (companion to the counter) ===== */
.cost-card {
  max-width: 980px;
  margin: 22px auto 0;
  padding: clamp(22px, 4vw, 34px);
  border: 1px solid rgba(255, 123, 114, 0.35);
  border-radius: 24px;
  background:
    linear-gradient(135deg, rgba(255, 123, 114, 0.10), transparent 40%),
    linear-gradient(180deg, rgba(31, 38, 48, 0.96), rgba(22, 27, 34, 0.96));
  box-shadow: 0 22px 80px var(--shadow);
  text-align: center;
}
.cost-label {
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--danger);
  font-weight: 800;
  font-size: 0.84rem;
  margin-bottom: 10px;
}
.cost-total {
  font-family: "JetBrains Mono", "Courier New", Courier, monospace;
  font-size: clamp(2.2rem, 7vw, 5.4rem);
  line-height: 1;
  color: #fff;
  font-weight: 800;
  letter-spacing: -0.01em;
  text-shadow: 0 0 28px rgba(255, 123, 114, 0.22);
}
.cost-sub {
  margin-top: 6px;
  color: var(--text-dim);
  font-size: 0.98rem;
}
.cost-sub strong { color: var(--text); }
.cost-chart-wrap {
  margin: 20px 0 6px;
  padding: 8px 4px;
  background: rgba(13, 17, 23, 0.55);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
}
.cost-chart-wrap svg { display: block; width: 100%; height: auto; }
.cost-breakdown {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 16px;
}
@media (max-width: 720px) { .cost-breakdown { grid-template-columns: repeat(2, 1fr); } }
.cost-pill {
  background: var(--bg-elev-2);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px 12px;
  text-align: center;
}
.cost-pill .cost-pill-num {
  font-family: "JetBrains Mono", "Courier New", monospace;
  font-weight: 800;
  color: var(--danger);
  font-size: clamp(1.05rem, 2.4vw, 1.4rem);
  line-height: 1.1;
}
.cost-pill .cost-pill-lbl {
  color: var(--text);
  font-weight: 700;
  font-size: 0.86rem;
  margin-top: 3px;
}
.cost-pill .cost-pill-note {
  color: var(--text-dim);
  font-size: 0.76rem;
  margin-top: 2px;
}
.cost-note {
  color: var(--text-dim);
  font-size: 0.86rem;
  margin-top: 14px;
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
}

/* ===== Section / card ===== */
section, .card {
  background: rgba(22, 27, 34, 0.9);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 22px;
  margin: 16px 0;
  box-shadow: 0 10px 36px var(--shadow);
}
section.warning, .card.warning {
  border-color: rgba(255, 123, 114, 0.35);
  background: linear-gradient(180deg, rgba(255, 123, 114, 0.08), rgba(22, 27, 34, 0.92));
}
section.ok, .card.ok {
  border-color: rgba(126, 231, 135, 0.35);
  background: linear-gradient(180deg, rgba(126, 231, 135, 0.05), rgba(22, 27, 34, 0.92));
}
section h2, .card h2 {
  margin: 0 0 14px;
  font-size: 1.4rem;
  color: #fff;
  letter-spacing: -0.01em;
}
section h3, .card h3 {
  margin: 18px 0 8px;
  color: var(--accent);
  font-size: 1.08rem;
}
section p, .card p { margin: 0 0 12px; }

/* ===== Grid ===== */
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
@media (max-width: 820px) {
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
}

/* ===== Tags & badges ===== */
.tag {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--bg-elev-2);
  border: 1px solid var(--border);
  color: var(--text-dim);
  font-size: 0.82rem;
  margin: 2px 4px 2px 0;
}
.tag.danger { background: rgba(255, 123, 114, 0.12); border-color: rgba(255, 123, 114, 0.4); color: var(--danger); }
.tag.ok { background: rgba(126, 231, 135, 0.08); border-color: rgba(126, 231, 135, 0.4); color: var(--ok); }
.tag.accent { background: rgba(255, 204, 102, 0.10); border-color: rgba(255, 204, 102, 0.4); color: var(--accent); }

/* ===== Buttons ===== */
.btn {
  display: inline-block;
  padding: 11px 20px;
  font-weight: 700;
  font-size: 0.96rem;
  border-radius: 10px;
  border: 1px solid var(--border-strong);
  background: var(--bg-elev-2);
  color: var(--text);
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.05s ease, background 0.15s ease;
}
.btn:hover { background: var(--bg-elev); text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn-primary {
  background: var(--accent);
  color: #1a1300;
  border-color: var(--accent);
}
.btn-primary:hover { background: #ffd680; color: #1a1300; }
.btn-danger {
  background: var(--danger);
  color: #2a0a07;
  border-color: var(--danger);
}
.btn-row { display: flex; gap: 12px; flex-wrap: wrap; margin: 18px 0; }

/* ===== Tables ===== */
table {
  width: 100%;
  border-collapse: collapse;
  overflow: hidden;
  border-radius: 10px;
  margin: 8px 0;
}
th, td {
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid var(--border);
  padding: 10px 12px;
  font-size: 0.96rem;
}
th { color: var(--accent); background: rgba(255, 204, 102, 0.06); font-weight: 700; }
tr:last-child td { border-bottom: 0; }
td.num { font-variant-numeric: tabular-nums; font-family: "JetBrains Mono", "Courier New", monospace; }
.table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: 10px; }

/* ===== Timeline ===== */
.timeline { position: relative; padding-left: 28px; margin: 16px 0; }
.timeline::before {
  content: "";
  position: absolute;
  left: 8px; top: 4px; bottom: 4px;
  width: 2px;
  background: linear-gradient(180deg, var(--accent), var(--border));
}
.timeline .ev {
  position: relative;
  padding: 4px 0 22px;
}
.timeline .ev::before {
  content: "";
  position: absolute;
  left: -23px; top: 12px;
  width: 10px; height: 10px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px rgba(255, 204, 102, 0.18);
}
.timeline .ev.danger::before { background: var(--danger); box-shadow: 0 0 0 4px rgba(255, 123, 114, 0.18); }
.timeline .ev .date {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.timeline .ev.danger .date { color: var(--danger); }
.timeline .ev .title { font-weight: 700; margin: 2px 0; }
.timeline .ev .body { color: var(--text-dim); font-size: 0.97rem; }
.timeline .ev .quote {
  font-style: italic;
  border-left: 3px solid var(--border-strong);
  margin-top: 8px;
  padding: 6px 12px;
  color: var(--text);
  background: var(--bg-elev-2);
  border-radius: 0 8px 8px 0;
}
.timeline .ev .quote .who { display: block; font-size: 0.78rem; color: var(--text-dim); font-style: normal; margin-top: 4px; }

/* ===== Gallery ===== */
.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
  margin: 14px 0;
}
.gallery figure {
  margin: 0;
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  background: var(--bg-elev);
}
/* Default: document-friendly — let the natural aspect ratio show, cap height,
   letterbox onto a neutral background instead of hard-cropping. */
.gallery figure img {
  width: 100%;
  max-height: 460px;
  object-fit: contain;
  background: #0b1117;
}
/* Opt-in: use class="gallery square" if you specifically want a 1:1 crop. */
.gallery.square figure img {
  aspect-ratio: 1 / 1;
  object-fit: cover;
  max-height: none;
  background: transparent;
}
.gallery figure figcaption { padding: 10px 12px; font-size: 0.86rem; color: var(--text-dim); }

/* ===== Quotes ===== */
blockquote {
  border-left: 4px solid var(--accent);
  margin: 12px 0;
  padding: 8px 16px;
  background: var(--bg-elev-2);
  border-radius: 0 10px 10px 0;
  color: var(--text);
  font-size: 1rem;
}
blockquote cite { display: block; margin-top: 6px; color: var(--text-dim); font-size: 0.85rem; font-style: normal; }

/* ===== Form ===== */
form .field { display: block; margin: 14px 0; }
form label {
  display: block;
  font-weight: 700;
  font-size: 0.94rem;
  margin-bottom: 6px;
  color: var(--text);
}
form label .req { color: var(--danger); }
form input[type="text"], form input[type="email"], form input[type="tel"], form input[type="date"], form input[type="number"], form select, form textarea {
  width: 100%;
  padding: 10px 12px;
  font-size: 0.98rem;
  font-family: inherit;
  background: var(--bg-elev-2);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 8px;
  outline: none;
}
form input:focus, form select:focus, form textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px rgba(255, 204, 102, 0.15);
}
form textarea { resize: vertical; min-height: 130px; line-height: 1.5; }
form .hint { color: var(--text-dim); font-size: 0.84rem; margin-top: 5px; }
form .checkbox-row { display: flex; align-items: flex-start; gap: 8px; }
form .checkbox-row input { margin-top: 4px; }

/* ===== Stat / fact card ===== */
.stat {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px 16px;
  background: var(--bg-elev);
}
.stat .num {
  font-family: "JetBrains Mono", "Courier New", monospace;
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  font-weight: 800;
  color: var(--accent);
}
.stat .lbl { color: var(--text-dim); font-size: 0.92rem; }
.stat.danger .num { color: var(--danger); }

/* ===== Footer ===== */
footer {
  border-top: 1px solid var(--border);
  color: var(--text-dim);
  text-align: center;
  padding: 26px 16px 42px;
  font-size: 0.9rem;
}
footer .footer-inner { max-width: var(--max-w); margin: 0 auto; }
footer .disclaimer { font-size: 0.82rem; max-width: 820px; margin: 14px auto 0; opacity: 0.85; }

/* ===== Print ===== */
@media print {
  body { background: #fff; color: #111; }
  nav.main-nav, .banner, .nav-toggle, .btn-row, footer { display: none; }
  section, .card { background: #fff; color: #111; box-shadow: none; border-color: #ccc; }
  a { color: #0645ad; text-decoration: underline; }
  .clock-card { border: 2px solid #111; background: #fff; box-shadow: none; }
  .counter-unit .num { color: #111; text-shadow: none; }
  th { color: #111; background: #f4f4f4; }
}
