:root {
  --cream: #FAF3E6;
  --cream2: #F3E9D8;
  --terracotta: #C1622D;
  --terracotta-dk: #9C4A1F;
  --sage: #748266;
  --sage-dk: #57624B;
  --brown: #4A3B2C;
  --ink: #3A2E22;
  --line: #D8C6A8;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: 'Source Sans 3', 'Segoe UI', Helvetica, Arial, sans-serif;
  font-size: 17px;
  line-height: 1.65;
}

.wrap {
  max-width: 760px;
  margin: 0 auto;
  padding: 0 20px;
}

header.site {
  background: var(--brown);
  border-bottom: 5px solid var(--terracotta);
}

header.site .wrap {
  padding-top: 20px;
  padding-bottom: 20px;
}

header.site .header-inner {
  display: flex;
  align-items: center;
  gap: 14px;
}

header.site .brand-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 2px solid var(--terracotta);
  background: var(--cream2);
  flex: none;
  display: block;
}

header.site .brand-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

header.site a.brand {
  color: var(--cream);
  text-decoration: none;
  font-family: 'Playfair Display', Georgia, 'Times New Roman', serif;
  font-size: 1.7rem;
  font-weight: 700;
  letter-spacing: 0.3px;
  line-height: 1.15;
}

header.site .tagline {
  color: #D9C6A8;
  font-size: 0.95rem;
  margin-top: 4px;
}

main { padding-bottom: 20px; }
main.wrap { padding-top: 40px; }

/* Homepage hero */
.hero {
  position: relative;
  width: 100%;
  height: 360px;
  overflow: hidden;
  background: var(--brown);
}
.hero-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 42%;
}
.hero-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-end;
  background: linear-gradient(180deg, rgba(58,46,34,0.05) 0%, rgba(58,46,34,0.55) 65%, rgba(58,46,34,0.85) 100%);
}
.hero-overlay .wrap { padding-top: 0; padding-bottom: 30px; }
.hero-title {
  font-family: 'Playfair Display', Georgia, 'Times New Roman', serif;
  color: #fff;
  font-size: 2.3rem;
  line-height: 1.2;
  margin: 0 0 8px;
  text-shadow: 0 2px 10px rgba(0,0,0,0.35);
}
.hero-sub {
  color: var(--cream2);
  font-size: 1.05rem;
  max-width: 560px;
  margin: 0;
  text-shadow: 0 1px 6px rgba(0,0,0,0.35);
}

.home-body { padding-top: 34px; }

h1 {
  font-family: 'Playfair Display', Georgia, 'Times New Roman', serif;
  color: var(--terracotta-dk);
  font-size: 2.1rem;
  line-height: 1.25;
  margin: 0 0 10px;
}

h2 {
  font-family: 'Playfair Display', Georgia, 'Times New Roman', serif;
  color: var(--terracotta-dk);
  font-size: 1.45rem;
  margin: 2em 0 0.6em;
  border-bottom: 2px solid var(--line);
  padding-bottom: 6px;
}

h3 {
  font-family: 'Playfair Display', Georgia, 'Times New Roman', serif;
  color: var(--sage-dk);
  font-size: 1.15rem;
  margin: 1.6em 0 0.5em;
}

p { margin: 0 0 1.1em; }

a { color: var(--terracotta-dk); }
a:hover { color: var(--terracotta); }

.dek {
  font-size: 1.1rem;
  color: var(--sage-dk);
  font-style: italic;
  margin-bottom: 1.6em;
}

.meta {
  font-size: 0.85rem;
  color: #8a7a63;
  margin-bottom: 2em;
  text-transform: uppercase;
  letter-spacing: 0.4px;
}
.meta .sep { margin: 0 6px; opacity: 0.6; }
.meta time { color: #8a7a63; }

ul, ol { padding-left: 1.3em; }
li { margin-bottom: 0.5em; }

table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.2em 0 1.8em;
  font-size: 0.95rem;
  background: white;
}
th, td {
  border: 1px solid var(--line);
  padding: 8px 10px;
  text-align: left;
}
th {
  background: var(--cream2);
  color: var(--terracotta-dk);
  font-weight: 700;
}

.callout {
  background: var(--cream2);
  border-left: 4px solid var(--sage);
  padding: 14px 18px;
  margin: 1.6em 0;
  font-size: 0.95rem;
  color: var(--sage-dk);
}

.callout strong { color: var(--brown); }

.cta-box {
  background: white;
  border: 1.5px solid var(--terracotta);
  border-radius: 6px;
  padding: 20px 22px;
  margin: 2.2em 0;
}
.cta-box h3 {
  margin-top: 0;
  color: var(--terracotta-dk);
}
.cta-box a.btn {
  display: inline-block;
  margin-top: 8px;
  background: var(--terracotta);
  color: white;
  text-decoration: none;
  font-weight: 600;
  padding: 10px 18px;
  border-radius: 4px;
}
.cta-box a.btn:hover { background: var(--terracotta-dk); color: white; }

.sources {
  font-size: 0.85rem;
  color: #8a7a63;
  margin-top: 2.5em;
  padding-top: 1em;
  border-top: 1px solid var(--line);
}
.sources li { margin-bottom: 0.3em; }

footer.site {
  border-top: 3px solid var(--line);
  margin-top: 3em;
  padding: 26px 0 40px;
  color: #8a7a63;
  font-size: 0.9rem;
}
footer.site a { color: var(--sage-dk); }

.article-grid {
  display: flex;
  flex-direction: column;
  gap: 18px;
  margin-top: 1.8em;
}
.article-card {
  background: white;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 18px 20px;
  text-decoration: none;
  display: block;
  color: var(--ink);
}
.article-card:hover { border-color: var(--terracotta); }
.card-date {
  font-size: 0.78rem;
  color: var(--sage-dk);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 600;
  margin-bottom: 6px;
}
.article-card h2 {
  margin: 0 0 6px;
  border: none;
  padding: 0;
  font-size: 1.25rem;
}
.article-card p { margin: 0; color: var(--sage-dk); font-size: 0.95rem; }

.shop-banner {
  background: var(--sage);
  color: white;
  border-radius: 6px;
  padding: 18px 20px;
  margin: 2em 0;
}
.shop-banner a { color: white; text-decoration: underline; font-weight: 600; }

@media (max-width: 600px) {
  .hero { height: 300px; }
  .hero-title { font-size: 1.7rem; }
  .hero-sub { font-size: 0.95rem; }
}

.signup-box {
  background: var(--cream2);
  border: 1px solid var(--line);
  border-left: 5px solid var(--terracotta);
  border-radius: 6px;
  padding: 20px 22px;
  margin: 2em 0;
}
.signup-box h3 { margin: 0 0 6px; font-family: 'Playfair Display', serif; color: var(--brown); }
.signup-box p { margin: 0 0 12px; }
.signup-box form { display: flex; gap: 10px; flex-wrap: wrap; }
.signup-box input[type=email] {
  flex: 1 1 240px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 4px;
  font: inherit;
}
a.btn, button.btn {
  display: inline-block;
  background: var(--terracotta);
  color: white;
  text-decoration: none;
  font: inherit;
  font-weight: 600;
  padding: 10px 18px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
}
a.btn:hover, button.btn:hover { background: var(--terracotta-dk); color: white; }
.signup-box .signup-fine { font-size: 0.85rem; color: var(--sage-dk); margin: 12px 0 0; }

/* ---- 2026-10-28: navigation, heroes, related, hubs, tools ---- */
.topnav { background: var(--cream2); border-bottom: 1px solid var(--line); }
.topnav-inner { display: flex; gap: 4px; overflow-x: auto; white-space: nowrap; padding-top: 8px; padding-bottom: 8px; scrollbar-width: none; }
.topnav-inner::-webkit-scrollbar { display: none; }
.topnav a { color: var(--brown); text-decoration: none; font-weight: 600; font-size: 0.92rem; padding: 6px 10px; border-radius: 4px; }
.topnav a:hover { background: white; color: var(--terracotta-dk); }
.topnav a.on { background: white; color: var(--terracotta-dk); box-shadow: inset 0 -2px 0 var(--terracotta); }
.topnav a.tools { color: var(--terracotta-dk); }
.meta a { color: #8a7a63; text-decoration: none; }
.meta a:hover { color: var(--terracotta-dk); text-decoration: underline; }
.crumbs { font-size: 0.85rem; color: #8a7a63; margin-bottom: 1.2em; text-transform: uppercase; letter-spacing: 0.4px; }
.crumbs a { color: #8a7a63; text-decoration: none; }
.crumbs a:hover { color: var(--terracotta-dk); text-decoration: underline; }
.crumbs .sep { margin: 0 6px; opacity: 0.6; }
.article-hero { margin: 0 0 1.8em; }
.article-hero img { width: 100%; height: auto; display: block; border-radius: 6px; aspect-ratio: 3 / 2; object-fit: cover; background: var(--cream2); }
.related { margin: 2.6em 0 1em; }
.related h2 { margin-top: 0; }
.rel-tool { font-weight: 600; }
.rel-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
.rel-card { display: block; background: white; border: 1px solid var(--line); border-radius: 6px; overflow: hidden; text-decoration: none; color: var(--ink); }
.rel-card:hover { border-color: var(--terracotta); }
.rel-card img { display: block; width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; background: var(--cream2); }
.rel-card span { display: block; padding: 10px 12px; font-family: 'Playfair Display', Georgia, serif; font-weight: 700; color: var(--terracotta-dk); line-height: 1.3; }
.rel-all { margin-top: 12px; font-weight: 600; }
.article-card.has-thumb { display: grid; grid-template-columns: 150px 1fr; gap: 16px; align-items: start; }
.article-card .thumb { width: 150px; height: 100px; object-fit: cover; border-radius: 4px; display: block; background: var(--cream2); }
.topic-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin: 1.4em 0 2em; }
.topic-tile { position: relative; display: block; border-radius: 6px; overflow: hidden; text-decoration: none; aspect-ratio: 3 / 2; background: var(--brown); }
.topic-tile img { width: 100%; height: 100%; object-fit: cover; display: block; }
.topic-tile span { position: absolute; left: 0; right: 0; bottom: 0; padding: 26px 12px 10px; color: white; font-family: 'Playfair Display', Georgia, serif; font-weight: 700; font-size: 1.1rem; background: linear-gradient(180deg, rgba(58,46,34,0) 0%, rgba(58,46,34,0.85) 70%); }
.topic-tile small { display: block; font-family: 'Source Sans 3', sans-serif; font-weight: 400; font-size: 0.82rem; opacity: 0.9; }
.section-title { font-family: 'Playfair Display', Georgia, serif; color: var(--terracotta-dk); font-size: 1.45rem; margin: 1.6em 0 0.2em; border-bottom: 2px solid var(--line); padding-bottom: 6px; }
.tool-card { display: block; background: white; border: 1.5px solid var(--terracotta); border-radius: 6px; padding: 16px 20px; margin: 0 0 14px; text-decoration: none; color: var(--ink); }
.tool-card:hover { background: #fffaf3; }
.tool-card strong { display: block; font-family: 'Playfair Display', Georgia, serif; color: var(--terracotta-dk); font-size: 1.2rem; }
.calc { background: white; border: 1px solid var(--line); border-radius: 6px; padding: 18px 20px; margin: 1.4em 0; }
.calc .row > * { min-width: 0; }
.calc .row { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px 16px; }
.calc label { display: block; font-weight: 600; font-size: 0.92rem; color: var(--brown); }
.calc input, .calc select { width: 100%; margin-top: 4px; padding: 9px 10px; border: 1px solid var(--line); border-radius: 4px; font: inherit; background: #fff; }
.calc .hint { font-size: 0.82rem; color: #8a7a63; font-weight: 400; }
.calc fieldset { border: none; padding: 0; margin: 0 0 12px; }
.result { background: var(--cream2); border-left: 5px solid var(--terracotta); border-radius: 6px; padding: 16px 20px; margin: 1.2em 0; }
.result .big { font-family: 'Playfair Display', Georgia, serif; font-size: 1.7rem; color: var(--terracotta-dk); line-height: 1.2; }
.result table { margin: 0.8em 0 0.4em; }
td.num, th.num { text-align: right; white-space: nowrap; }
tr.best td { background: #fff4e8; font-weight: 600; }
.table-scroll { overflow-x: auto; }
@media (max-width: 600px) {
  .rel-grid, .topic-grid, .calc .row { grid-template-columns: 1fr 1fr; }
  .calc .row { grid-template-columns: 1fr; }
  .article-card.has-thumb { grid-template-columns: 96px 1fr; gap: 12px; }
  .article-card .thumb { width: 96px; height: 64px; }
}
.result td.num { white-space: normal; text-align: right; }
