/* WasteOps marketing site — shared design system (Round 3).
   Mix of Direction A (Enterprise Clarity: restraint, thin-border cards,
   product-chrome panels) and Direction C (Civic Trust: serif display
   headline, warm trustworthy palette). Light mode is the default theme;
   dark is an explicit opt-in toggle, not the default. */

:root,
[data-theme="light"] {
  --bg: #fbfaf7;
  --panel: #ffffff;
  --ink: #15231d;
  --muted: #5c6b63;
  --line: #dfe3dc;
  --accent: #1f5f3f;
  --accent-soft: #e7efe7;
  --navy: #13293d;
  --navy-ink: #eef3ee;
  --navy-muted: #aebcb3;
  --shadow: 0 20px 50px -30px rgba(10, 13, 16, 0.25);
}

[data-theme="dark"] {
  --bg: #0e1512;
  --panel: #141c18;
  --ink: #eef2ee;
  --muted: #8aa196;
  --line: #223029;
  --accent: #4ecf8e;
  --accent-soft: rgba(78, 207, 142, 0.12);
  --navy: #0b2a3e;
  --navy-ink: #eef3ee;
  --navy-muted: #9fb6ac;
  --shadow: 0 20px 50px -30px rgba(0, 0, 0, 0.6);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.6 -apple-system, "Segoe UI", system-ui, Helvetica, Arial, sans-serif;
  transition: background .25s ease, color .25s ease;
}
.serif, h1, .hero h1, h2 {
  font-family: Georgia, "Iowan Old Style", "Times New Roman", serif;
}
a { color: inherit; }
.wrap { max-width: 1100px; margin: 0 auto; padding: 0 32px; }

/* Header / nav */
header {
  position: sticky; top: 0; z-index: 10;
  background: var(--panel);
  border-bottom: 1px solid var(--line);
}
header .wrap { height: 74px; display: flex; align-items: center; justify-content: space-between; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 17px; letter-spacing: -.01em; font-family: inherit; }
.brand img { width: 26px; height: 26px; border-radius: 5px; }
nav.main { display: flex; align-items: center; gap: 26px; }
nav.main a.link { font-size: 14px; color: var(--muted); text-decoration: none; }
nav.main a.link:hover { color: var(--ink); }
nav.main a.link.current { color: var(--ink); font-weight: 600; }
.nav-actions { display: flex; align-items: center; gap: 10px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 10px 18px; border-radius: 7px; font-size: 14px; font-weight: 600;
  text-decoration: none; border: 1px solid transparent; white-space: nowrap;
  cursor: pointer; font-family: -apple-system, "Segoe UI", system-ui, sans-serif;
}
.btn.solid { background: var(--accent); color: #fff; }
[data-theme="dark"] .btn.solid { color: #07140d; }
.btn.solid:hover { opacity: .9; }
.btn.ghost { border-color: var(--line); color: var(--ink); background: transparent; }
.btn.ghost:hover { border-color: var(--accent); }
.btn.lg { padding: 13px 24px; font-size: 15px; border-radius: 8px; }
.btn.icon { padding: 9px 11px; font-size: 13px; }

/* Hero */
.hero { padding: 84px 0 0; }
.hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 56px; align-items: center; }
.badge {
  display: inline-flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 700;
  color: var(--accent); border: 1px solid var(--accent-soft); background: var(--accent-soft);
  padding: 7px 13px; border-radius: 5px; margin-bottom: 26px; letter-spacing: .02em;
  text-transform: uppercase; font-family: -apple-system, sans-serif;
}
.hero h1 { font-size: 46px; line-height: 1.16; letter-spacing: -.01em; margin: 0 0 20px; font-weight: 400; }
.hero p.lead { font-size: 17.5px; color: var(--muted); margin: 0 0 16px; max-width: 540px; }
.scope-note {
  font-size: 14.5px; color: var(--muted); margin: 0 0 32px; padding-left: 14px;
  border-left: 2px solid var(--line); max-width: 480px;
}
.cta-row { display: flex; gap: 12px; flex-wrap: wrap; }
.dev-note { font-size: 13.5px; color: var(--muted); margin: 16px 0 0; max-width: 480px; }

/* Product chrome panel (hero visual) */
.product-frame {
  border: 1px solid var(--line); border-radius: 12px; background: var(--panel);
  box-shadow: var(--shadow); overflow: hidden;
}
.chrome { display: flex; gap: 6px; padding: 13px 16px; border-bottom: 1px solid var(--line); }
.chrome span { width: 9px; height: 9px; border-radius: 50%; background: var(--line); }
.product-shot { position: relative; width: 100%; aspect-ratio: 12 / 5; overflow: hidden; background: var(--panel); display: flex; align-items: center; }
.product-shot img { width: 100%; height: auto; object-fit: contain; display: block; }
.product-shot img.dark-only { display: none; }
[data-theme="dark"] .product-shot img.light-only { display: none; }
[data-theme="dark"] .product-shot img.dark-only { display: block; }

/* Scenario callout */
#scenario { padding: 56px 0 0; }
#how { padding-top: 48px; }
.scenario-box {
  border: 1px solid var(--line); border-left: 3px solid var(--accent);
  background: var(--panel); border-radius: 10px; padding: 32px 36px; max-width: 760px;
}
.scenario-box p { margin: 0 0 12px; font-size: 15.5px; color: var(--ink); font-family: -apple-system, sans-serif; }
.scenario-box p:last-child { margin-bottom: 0; }
.scenario-box .scenario-point { color: var(--muted); font-size: 14.5px; }

/* Contract-shape cards */
.shape-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.shape-card {
  background: var(--accent-soft); border: 1px solid var(--line); border-left: 4px solid var(--accent);
  border-radius: 12px; padding: 30px 26px;
}
.shape-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; }
.shape-card .num {
  width: 34px; height: 34px; border-radius: 50%; background: var(--panel); border: 1px solid var(--line);
  display: flex; align-items: center; justify-content: center;
  font-family: Georgia, serif; font-size: 16px; color: var(--accent); margin: 0;
}
.shape-icon { color: var(--accent); }
.shape-card h3 { font-size: 17px; margin: 0 0 10px; font-weight: 700; font-family: -apple-system, sans-serif; }
.shape-card p { font-size: 14px; color: var(--muted); margin: 0; font-family: -apple-system, sans-serif; }

/* Stat strip */
.strip { margin-top: 64px; padding: 24px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.strip .wrap { display: flex; justify-content: space-between; color: var(--muted); font-size: 13px; flex-wrap: wrap; gap: 16px; }
.strip strong { color: var(--ink); font-size: 14.5px; display: block; font-family: Georgia, serif; font-weight: 400; }

/* Sections */
section { padding: 84px 0; }
.kicker {
  font-size: 12.5px; font-weight: 700; color: var(--accent); text-transform: uppercase;
  letter-spacing: .07em; margin: 0 0 14px; font-family: -apple-system, sans-serif;
}
h2 { font-size: 30px; letter-spacing: -.005em; margin: 0 0 16px; max-width: 640px; font-weight: 400; }
p.sublead { color: var(--muted); font-size: 15.5px; max-width: 580px; margin: 0 0 48px; }

.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.card { background: var(--panel); padding: 28px; }
.num { font-family: Georgia, serif; font-size: 26px; color: var(--accent); margin-bottom: 12px; }
.card h3 { font-size: 16.5px; margin: 0 0 10px; font-weight: 700; font-family: -apple-system, sans-serif; }
.card p { font-size: 14px; color: var(--muted); margin: 0; }

.modules { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.module { border-left: 3px solid var(--accent); padding-left: 20px; }
.module .tag { font-size: 11px; font-weight: 700; color: var(--accent); text-transform: uppercase; letter-spacing: .05em; font-family: -apple-system, sans-serif; }
.module h3 { font-size: 18px; margin: 10px 0 14px; font-weight: 400; }
.module ul { margin: 0; padding-left: 16px; color: var(--muted); font-size: 14px; font-family: -apple-system, sans-serif; }
.module li { margin-bottom: 8px; }

.roadmap-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 24px; }
.r-module { border: 1px solid var(--line); border-radius: 10px; padding: 26px; background: var(--panel); }
.r-module .tag { font-size: 11px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; font-family: -apple-system, sans-serif; }
.r-module h3 { font-size: 19px; margin: 10px 0 10px; font-weight: 400; }
.r-module p { color: var(--muted); font-size: 14px; margin: 0; font-family: -apple-system, sans-serif; }

.assurance { background: var(--navy); color: var(--navy-ink); border-radius: 10px; padding: 50px; }
.assurance h2 { color: #fff; max-width: 600px; }
.assurance p.sublead { color: var(--navy-muted); }
.a-sub { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--navy-muted); margin: 28px 0 14px; font-family: -apple-system, sans-serif; }
.a-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; font-family: -apple-system, sans-serif; }
.a-item { font-size: 13.5px; }
.a-item .t { font-weight: 700; margin-bottom: 6px; font-size: 14.5px; }
.a-item .d { color: var(--navy-muted); }
.a-roadmap-note { color: var(--navy-muted); font-size: 13.5px; margin: 0; max-width: 620px; font-family: -apple-system, sans-serif; }

.closing { text-align: center; padding: 96px 0; }
.closing h2 { margin: 0 auto 14px; max-width: 600px; text-align: center; }
.closing p { color: var(--muted); max-width: 480px; margin: 0 auto 10px; font-family: -apple-system, sans-serif; }
.closing .cta-row { justify-content: center; margin-top: 24px; }
.closing .dev-note { max-width: 480px; margin: 16px auto 0; }
.closing .also { margin-top: 28px; font-size: 14px; }
.closing .also a { color: var(--accent); font-weight: 600; text-decoration: none; }

.contact-form {
  max-width: 600px; margin: 40px auto 0; text-align: left;
  background: var(--panel); border: 1px solid var(--line); border-radius: 16px;
  box-shadow: var(--shadow); padding: 40px 44px 36px;
}
.contact-form .cf-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px 18px; margin-bottom: 20px; }
.contact-form label {
  display: flex; flex-direction: column; gap: 7px; font-size: 12px; font-weight: 700;
  color: var(--muted); text-transform: uppercase; letter-spacing: .04em;
  font-family: -apple-system, sans-serif;
}
.contact-form .opt { font-weight: 400; text-transform: none; letter-spacing: 0; color: var(--muted); }
.contact-form input, .contact-form select, .contact-form textarea {
  font: 15px/1.4 -apple-system, "Segoe UI", system-ui, sans-serif; padding: 12px 14px;
  border: 1px solid var(--line); border-radius: 9px; background: var(--bg); color: var(--ink);
  transition: border-color .15s ease, box-shadow .15s ease, background .15s ease;
}
.contact-form input:hover, .contact-form select:hover, .contact-form textarea:hover { border-color: var(--muted); }
.contact-form input:focus, .contact-form select:focus, .contact-form textarea:focus {
  outline: none; border-color: var(--accent); background: var(--panel);
  box-shadow: 0 0 0 3px var(--accent-soft);
}
.contact-form .cf-message { display: flex; flex-direction: column; gap: 7px; font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; font-family: -apple-system, sans-serif; margin-bottom: 20px; }
.contact-form textarea { resize: vertical; font-weight: 400; }
.contact-form .cf-turnstile { margin: 4px 0 22px; display: flex; justify-content: center; }
.contact-form .cta-row { justify-content: center; }
.contact-form #cf-submit { min-width: 200px; }
.cf-status { min-height: 20px; font-size: 14px; margin-top: 16px; font-family: -apple-system, sans-serif; text-align: center; }
.cf-status.ok { color: var(--accent); }
.cf-status.err { color: #c0432f; }
#cf-submit[disabled] { opacity: .55; cursor: not-allowed; }
@media (max-width: 600px) {
  .contact-form .cf-grid { grid-template-columns: 1fr; }
  .contact-form { padding: 28px 22px 26px; border-radius: 14px; }
}

footer { border-top: 1px solid var(--line); padding: 30px 0; font-size: 13px; color: var(--muted); }
footer .wrap { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 14px; }
footer nav { display: flex; gap: 20px; }
footer a { text-decoration: none; }
footer a:hover { color: var(--ink); }

/* Long-form page intro (vision / how-it-works) */
.page-hero { padding: 72px 0 56px; border-bottom: 1px solid var(--line); }
.page-hero h1 { font-size: 42px; margin: 0 0 18px; max-width: 680px; }
.page-hero p.lead { font-size: 17px; color: var(--muted); max-width: 620px; margin: 0; }

/* How-it-works long-form feature rows */
.feature-row { display: grid; grid-template-columns: 1fr 1.25fr; gap: 56px; align-items: center; padding: 72px 0; border-top: 1px solid var(--line); }
.feature-row.reverse { grid-template-columns: 1.25fr 1fr; }
.feature-row.reverse .feature-text { order: 2; }
.feature-row.reverse .feature-shot { order: 1; }
.feature-text .kicker { margin-bottom: 12px; }
.feature-text h2, .feature-text h3 { font-size: 26px; margin: 0 0 14px; font-weight: 400; }
.feature-text p { color: var(--muted); font-size: 15px; margin: 0 0 14px; max-width: 480px; }
.feature-text p:last-child { margin-bottom: 0; }
.feature-text p.brief { color: var(--ink); font-size: 15.5px; max-width: 480px; }
.feature-text .why { font-size: 14px; color: var(--ink); background: var(--accent-soft); border-radius: 8px; padding: 14px 16px; margin-top: 4px; max-width: 480px; }
.feature-shot {
  border: 1px solid var(--line); border-radius: 12px; overflow: hidden; box-shadow: var(--shadow);
  background: var(--bg); display: flex; align-items: center; justify-content: center;
}
.feature-shot img { display: block; width: 100%; height: auto; object-fit: contain; }
.feature-note {
  border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow);
  background: var(--panel); display: flex; align-items: center;
  justify-content: center; padding: 28px 32px; align-self: stretch;
}
.feature-note p {
  font-size: 16px; line-height: 1.55; color: var(--ink); font-family: -apple-system, sans-serif;
  text-align: left; max-width: 360px; margin: 0;
}

/* Scannable read-more */
details.more { margin-top: 2px; }
details.more summary {
  cursor: pointer; font-size: 13.5px; font-weight: 700; color: var(--accent);
  list-style: none; font-family: -apple-system, sans-serif; user-select: none;
  display: inline-flex; align-items: center; gap: 6px;
}
details.more summary::-webkit-details-marker { display: none; }
details.more summary::marker { content: ""; }
details.more summary::after { content: "+"; font-weight: 700; }
details.more[open] summary::after { content: "\2013"; }
details.more .more-body { padding-top: 16px; }
details.more .more-body p { color: var(--muted); font-size: 14.5px; margin: 0 0 14px; max-width: 480px; }
details.more .more-body p:last-child { margin-bottom: 0; }
details.more .more-body p.why { font-size: 14px; color: var(--ink); background: var(--accent-soft); border-radius: 8px; padding: 14px 16px; margin-top: 4px; max-width: 480px; }
.intro-block { max-width: 680px; }
.intro-block p { color: var(--muted); font-size: 15.5px; }
.in-short { background: var(--navy); color: var(--navy-ink); border-radius: 10px; padding: 48px; margin-top: 20px; }
.in-short h2 { color: #fff; }
.in-short p { color: var(--navy-muted); font-size: 15px; max-width: 640px; margin: 0; }

/* Scroll reveal */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-visible { opacity: 1; transform: none; }

@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero h1 { font-size: 32px; }
  .grid3, .modules, .a-grid, .roadmap-grid, .shape-grid { grid-template-columns: 1fr; }
  .feature-row, .feature-row.reverse { grid-template-columns: 1fr; }
  .feature-row.reverse .feature-text, .feature-row.reverse .feature-shot { order: unset; }
  nav.main { gap: 16px; }
}
