/* Water Decision Guide — shared styles */
:root {
  --color-bg: #f7f9fb;
  --color-surface: #ffffff;
  --color-text: #1a2332;
  --color-text-muted: #4a5568;
  --color-border: #dce3eb;
  --color-primary: #0c5c7a;
  --color-primary-hover: #094a63;
  --color-accent: #1a7a5c;
  --color-disclosure-bg: #f0f4f7;
  --color-warning-bg: #fef8e8;
  --color-warning-border: #e6d08a;
  --max-width: 720px;
  --nav-height: 3.5rem;
  --font-sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --line-height: 1.65;
  --radius: 6px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  font-family: var(--font-sans);
  line-height: var(--line-height);
  color: var(--color-text);
  background: var(--color-bg);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

img {
  max-width: 100%;
  height: auto;
}

a {
  color: var(--color-primary);
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}

a:hover {
  color: var(--color-primary-hover);
}

/* Skip link */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--color-primary);
  color: #fff;
  padding: 0.5rem 1rem;
  z-index: 100;
}

.skip-link:focus {
  left: 0.5rem;
  top: 0.5rem;
}

/* Header / Nav */
.site-header {
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  position: sticky;
  top: 0;
  z-index: 50;
}

.header-inner {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: var(--nav-height);
  gap: 1rem;
  flex-wrap: wrap;
}

.site-logo {
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--color-text);
  text-decoration: none;
  letter-spacing: -0.01em;
}

.site-logo:hover {
  color: var(--color-primary);
}

.site-logo span {
  color: var(--color-primary);
  font-weight: 600;
}

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

.site-nav a {
  color: var(--color-text-muted);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  padding: 0.25rem 0;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: var(--color-primary);
}

.site-nav a[aria-current="page"] {
  border-bottom: 2px solid var(--color-primary);
}

/* Main */
main {
  flex: 1;
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 2rem 1.25rem 3rem;
}

.page-wide {
  max-width: 960px;
}

h1 {
  font-size: 1.75rem;
  line-height: 1.25;
  margin: 0 0 1rem;
  letter-spacing: -0.02em;
  font-weight: 700;
}

h2 {
  font-size: 1.25rem;
  margin: 2rem 0 0.75rem;
  font-weight: 650;
  letter-spacing: -0.01em;
}

h3 {
  font-size: 1.05rem;
  margin: 1.5rem 0 0.5rem;
  font-weight: 600;
}

p {
  margin: 0 0 1rem;
  color: var(--color-text);
}

.lead {
  font-size: 1.1rem;
  color: var(--color-text-muted);
  margin-bottom: 1.5rem;
}

ul, ol {
  margin: 0 0 1.25rem;
  padding-left: 1.35rem;
}

li {
  margin-bottom: 0.4rem;
}

li > ul, li > ol {
  margin-top: 0.35rem;
  margin-bottom: 0.35rem;
}

/* Cards / boxes */
.card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 1.25rem 1.35rem;
  margin: 1.25rem 0;
}

.card h2, .card h3 {
  margin-top: 0;
}

.disclosure {
  background: var(--color-disclosure-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 1rem 1.15rem;
  margin: 1.5rem 0;
  font-size: 0.925rem;
}

.disclosure strong {
  display: block;
  margin-bottom: 0.35rem;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--color-text-muted);
}

.note-box {
  background: var(--color-warning-bg);
  border: 1px solid var(--color-warning-border);
  border-radius: var(--radius);
  padding: 1rem 1.15rem;
  margin: 1.25rem 0;
  font-size: 0.95rem;
}

.note-box strong {
  display: block;
  margin-bottom: 0.25rem;
}

/* Comparison table */
.table-wrap {
  overflow-x: auto;
  margin: 1.25rem 0;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  background: var(--color-surface);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.925rem;
}

th, td {
  text-align: left;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--color-border);
  vertical-align: top;
}

th {
  background: var(--color-disclosure-bg);
  font-weight: 600;
  white-space: nowrap;
}

tr:last-child td {
  border-bottom: none;
}

/* Tool teasers */
.teaser-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.85rem;
  margin: 1.25rem 0 1.75rem;
}

@media (min-width: 560px) {
  .teaser-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.teaser {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 1rem 1.1rem;
}

.teaser h3 {
  margin: 0 0 0.4rem;
  font-size: 1rem;
}

.teaser p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--color-text-muted);
}

.teaser .badge {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-accent);
  margin-bottom: 0.35rem;
}

/* Lists of nots / dos */
.checklist {
  list-style: none;
  padding-left: 0;
}

.checklist li {
  padding-left: 1.5rem;
  position: relative;
}

.checklist li::before {
  position: absolute;
  left: 0;
  font-weight: 700;
}

.checklist.do li::before {
  content: "✓";
  color: var(--color-accent);
}

.checklist.dont li::before {
  content: "✗";
  color: #b33;
}

/* Footer */
.site-footer {
  background: var(--color-surface);
  border-top: 1px solid var(--color-border);
  padding: 1.75rem 1.25rem 2rem;
  font-size: 0.85rem;
  color: var(--color-text-muted);
}

.footer-inner {
  max-width: 960px;
  margin: 0 auto;
}

.footer-disclosure {
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--color-border);
  line-height: 1.55;
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
  margin-bottom: 0.85rem;
}

.footer-nav a {
  color: var(--color-text-muted);
  text-decoration: none;
  font-weight: 500;
}

.footer-nav a:hover {
  color: var(--color-primary);
}

.footer-copy {
  margin: 0;
  font-size: 0.8rem;
}

/* Utility */
.muted {
  color: var(--color-text-muted);
}

.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }

@media (min-width: 640px) {
  h1 {
    font-size: 2rem;
  }

  main {
    padding-top: 2.5rem;
  }
}
