/* ===== Zephlet shared base styles ===== */
:root {
  --bg: #F1ECDE;
  --bg-2: #E6DFC9;
  --ink: #1F2118;
  --ink-soft: #2F3326;
  --muted: #5A5D52;
  --line: #1B1D14;
  --rule: #C9C0A6;
  --orange: #E55A1F;
  --orange-soft: #FFE2CC;
  --dark: #2B2419;
  --dark-2: #3A2F22;
  --leaf: #3F6E4F;
  --leaf-deep: #2F5B3F;
  --moss: #BFCFAE;
  --paper: #FAF5E6;
}

* { box-sizing: border-box; }
html, body {
  margin: 0;
  padding: 0;
  /* Mobile safety net: never let a rogue wide element scroll the whole page sideways. */
  overflow-x: hidden;
}
body {
  background: var(--bg);
  color: var(--ink);
  font-family: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 40px; }

/* ===== Header ===== */
header.site { padding: 28px 0 12px; }
.header-row {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
}
.logo {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-weight: 700;
  font-size: 25px;
  letter-spacing: -0.02em;
  color: var(--ink);
}
.logo .logo-badge {
  height: 32px;
  width: auto;
  display: block;
  transition: transform 200ms ease;
}
.logo:hover .logo-badge { transform: rotate(-4deg) scale(1.04); }
.logo .logo-word { line-height: 1; }

nav.primary {
  display: flex;
  gap: 38px;
  align-items: center;
  justify-content: center;
}
nav.primary a {
  font-size: 14px;
  font-weight: 500;
  color: var(--ink);
  position: relative;
  padding: 6px 0;
}
nav.primary a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 2px;
  background: var(--orange);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 220ms ease;
}
nav.primary a:hover::after,
nav.primary a[aria-current="page"]::after { transform: scaleX(1); }
nav.primary a[aria-current="page"] { color: var(--orange); font-weight: 700; }

.header-cta { display: flex; align-items: center; justify-content: flex-end; gap: 16px; }
.nav-welcome {
  font-size: 16px;
  color: var(--ink-soft);
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.nav-welcome::before {
  content: "";
  width: 9px; height: 9px;
  background: var(--leaf);
  border-radius: 50%;
  box-shadow: 0 0 0 3px rgba(63, 110, 79, 0.18);
  flex: 0 0 9px;
}
.nav-welcome strong { color: var(--ink); font-weight: 700; }

/* ===== Buttons (smooth, no offset shadow, 14px radius) ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 26px;
  border-radius: 9999px;
  font-weight: 600;
  font-size: 15px;
  font-family: inherit;
  cursor: pointer;
  border: 1.5px solid transparent;
  background: transparent;
  line-height: 1;
  transition: background 180ms ease, border-color 180ms ease, color 180ms ease, transform 120ms ease;
}
.btn:active { transform: translateY(1px); }
.btn-primary {
  background: var(--orange);
  color: #fff;
  border-color: var(--orange);
}
.btn-primary:hover { background: #C84817; border-color: #C84817; }
.btn-ghost {
  color: var(--orange);
  border-color: var(--orange);
  background: var(--orange-soft);
}
.btn-ghost:hover { background: #FFD3B3; }
.btn .arrow { transition: transform 200ms ease; }
.btn:hover .arrow { transform: translateX(3px); }

/* ===== Page hero (interior pages) ===== */
.page-hero { padding: 50px 0 40px; }
.eyebrow {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin: 0 0 18px;
  color: var(--ink-soft);
}
.eyebrow .u {
  color: var(--orange);
  border-bottom: 2px solid var(--orange);
  padding-bottom: 3px;
}
h1.page-h {
  font-size: 56px;
  line-height: 1.05;
  margin: 0 0 22px;
  font-weight: 800;
  letter-spacing: -0.025em;
  max-width: 880px;
}
h1.page-h .accent { color: var(--orange); position: relative; display: inline-block; }
h1.page-h .accent::after {
  content: "";
  position: absolute;
  left: -2%; right: -2%; bottom: -6px;
  height: 4px;
  background: var(--orange);
  border-radius: 4px;
  transform: skewX(-8deg);
}
.page-lede {
  font-size: 17px;
  line-height: 1.7;
  color: var(--ink-soft);
  max-width: 640px;
  margin: 0;
}

/* ===== Section header ===== */
.section-eyebrow {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--orange);
  margin-bottom: 10px;
}
h2.section-h {
  font-size: 32px;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 0 0 28px;
  line-height: 1.15;
}
h2.section-h .accent { color: var(--orange); }
.rule { height: 1px; background: var(--rule); margin: 36px 0; }

/* ===== Cards ===== */
.card {
  background: var(--paper);
  border: 1.5px solid var(--ink);
  border-radius: 14px;
  padding: 26px;
}
.card.dark { background: var(--dark); color: #F5EFE5; border-color: var(--dark); }
.card.dark h3, .card.dark h4 { color: #fff; }
.card.dark p { color: #C7C2B6; }
.card .badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 4px 10px;
  background: var(--orange-soft);
  color: var(--orange);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* ===== Footer ===== */
footer.site {
  border-top: 1.5px solid var(--leaf);
  padding: 22px 0 36px;
  margin-top: 40px;
}
.foot-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
  font-size: 13px;
  flex-wrap: wrap;
}
.foot-left { display: flex; align-items: center; gap: 12px; color: var(--ink-soft); }
.foot-left .code { color: var(--orange); }
.foot-right {
  display: flex;
  align-items: center;
  gap: 24px;
  color: var(--ink-soft);
  flex-wrap: wrap;
  justify-content: flex-end;
}
.foot-right a { transition: color 180ms ease; }
.foot-right a:hover { color: var(--orange); }

@media (max-width: 700px) {
  .foot-row { flex-direction: column; align-items: flex-start; gap: 16px; }
  .foot-right { justify-content: flex-start; gap: 14px 22px; }
}

/* ===== Utility ===== */
.kbd {
  font-family: inherit;
  font-size: 11px;
  padding: 2px 6px;
  background: var(--bg-2);
  border: 1px solid var(--rule);
  border-radius: 4px;
}
.note-handwritten { font-family: 'Caveat', cursive; font-weight: 500; font-size: 22px; line-height: 1.15; }

@media (max-width: 1080px) {
  h1.page-h { font-size: 42px; }
}
@media (max-width: 640px) {
  .wrap { padding: 0 20px; }
  nav.primary { display: none; }
  .header-row { grid-template-columns: 1fr auto; gap: 12px; }
  h1.page-h { font-size: 34px; }

  /* Header-only fixes so the orange CTA stops bleeding past the right edge.
     Scoped to .header-cta .btn so other buttons on the page are unaffected. */
  .nav-welcome { display: none; }
  .logo { font-size: 21px; }
  .logo .logo-badge { height: 26px; }
  .header-cta .btn { padding: 11px 18px; font-size: 14px; gap: 8px; }
}
