/* ============================================================
   Orion Sport - design system
   Warm, clean, friendly. Follows the Badger ideology: monochrome
   warmth with a single accent. Poppins for display, Quicksand
   for body. Accent is Betelgeuse burnt orange.
   ============================================================ */

:root {
  --bg: #faf9f7;
  --surface: #ffffff;
  --ink: #16140f;
  --ink-soft: #4a463e;
  --muted: #8a857a;
  --line: #e9e6df;
  --line-strong: #d9d5cc;

  --accent: #e8622c;
  --accent-soft: #fdeee6;
  --accent-ink: #a34f1d;

  --chip-bg: #f4f2ec;

  --radius: 14px;
  --radius-sm: 9px;
  --shadow: 0 1px 2px rgba(22, 20, 15, 0.04), 0 8px 24px rgba(22, 20, 15, 0.06);

  --font-display: "Poppins", sans-serif;
  --font-body: "Quicksand", sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; scrollbar-gutter: stable; }

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--ink);
  font-size: 16px;
  font-weight: 500;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img, svg { display: block; }

a { color: inherit; text-decoration: none; }

.wrap {
  width: 100%;
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 20px;
}

/* ---------- type ---------- */

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

h1 { font-size: clamp(2rem, 5.5vw, 3.1rem); }
h2 { font-size: clamp(1.35rem, 3.5vw, 1.7rem); }
h3 { font-size: 1.05rem; }

.lede {
  font-size: clamp(1rem, 2.5vw, 1.15rem);
  color: var(--ink-soft);
  max-width: 34em;
}

.kicker {
  font-family: var(--font-display);
  font-size: 0.76rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--accent-ink);
  margin-bottom: 12px;
}

.muted { color: var(--muted); }

/* ---------- logo ---------- */

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: -0.02em;
}

/* placeholder mark: an O in a circle, swap for the real logo later */
.logo-mark {
  width: 32px;
  height: 32px;
  border: 2.5px solid var(--ink);
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--ink);
  flex: none;
}

.logo-mark--small {
  width: 22px;
  height: 22px;
  border-width: 2px;
  font-size: 0.65rem;
  border-color: var(--muted);
  color: var(--muted);
}

/* ---------- buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.92rem;
  padding: 12px 24px;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.1s ease;
}

.btn:active { transform: scale(0.98); }

.btn-primary {
  background: var(--accent);
  color: #ffffff;
}

.btn-primary:hover { background: #d1531f; }

.btn-dark {
  background: var(--ink);
  color: var(--bg);
  font-size: 0.82rem;
  padding: 9px 18px;
}

.btn-dark:hover { background: #2e2a22; }

.btn-ghost {
  background: transparent;
  color: var(--ink-soft);
}

.btn-ghost:hover { color: var(--ink); }

/* ---------- header ---------- */

.site-header {
  border-bottom: 0.5px solid var(--line);
  background: var(--bg);
  position: sticky;
  top: 0;
  z-index: 20;
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 62px;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 24px;
}

.site-nav a {
  font-family: var(--font-display);
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--muted);
  transition: color 0.15s ease;
}

.site-nav a:hover,
.site-nav a.active { color: var(--ink); }

/* the nav pill must keep light text - .site-nav a otherwise outranks .btn-dark */
.site-nav a.btn-dark { color: var(--bg); }

.site-nav a.btn-dark:hover {
  color: #ffffff;
  background: #2e2a22;
}

/* ---------- hero ---------- */

.hero {
  text-align: center;
  padding: 72px 0 64px;
}

.hero .lede { margin: 16px auto 28px; }

.hero-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}

/* ---------- tool sections ---------- */

.tools-section { padding: 26px 0; }

.tools-section:last-of-type { padding-bottom: 64px; }

.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}

.section-link {
  font-family: var(--font-display);
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--accent-ink);
}

.section-link:hover { color: var(--accent); }

.chip {
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 600;
  padding: 3px 12px;
  border-radius: 999px;
  background: var(--chip-bg);
  color: var(--muted);
  white-space: nowrap;
}

.chip-accent {
  background: var(--accent-soft);
  color: var(--accent-ink);
}

.tool-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 14px;
}

.tool-card {
  display: block;
  background: var(--surface);
  border: 0.5px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: 0 1px 2px rgba(22, 20, 15, 0.04);
  transition: box-shadow 0.15s ease, transform 0.15s ease, border-color 0.15s ease;
}

.tool-card:hover {
  box-shadow: var(--shadow);
  transform: translateY(-2px);
  border-color: var(--line-strong);
}

.tool-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.tool-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--chip-bg);
  color: var(--ink-soft);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.tool-icon svg {
  width: 19px;
  height: 19px;
  stroke: currentColor;
  stroke-width: 2;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.tool-card h3 { margin-bottom: 4px; font-size: 0.95rem; font-weight: 600; }

.tool-card p {
  color: var(--muted);
  font-size: 0.83rem;
  line-height: 1.55;
}

.tool-card--featured .tool-icon {
  background: var(--accent-soft);
  color: var(--accent-ink);
}

.tool-card--soon {
  background: transparent;
  border: 1.5px dashed var(--line-strong);
  box-shadow: none;
  cursor: default;
}

.tool-card--soon:hover {
  box-shadow: none;
  transform: none;
  border-color: var(--line-strong);
}

.tool-card--soon h3 { color: var(--ink-soft); }

.tool-card--soon .tool-icon { color: var(--muted); }

/* ---------- footer ---------- */

.site-footer {
  border-top: 0.5px solid var(--line);
  padding: 22px 0;
}

.site-footer .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 0.8rem;
}

.footer-links {
  display: flex;
  gap: 18px;
}

.footer-links a {
  color: var(--muted);
  font-size: 0.8rem;
}

.footer-links a:hover { color: var(--ink); }

/* ---------- photo banners ---------- */
/* Placeholder slots: drop the JPG into public/assets/ with the filename
   shown on the slot and it appears automatically (background-image covers
   the label). Keep files under ~300KB. */

.photo-banner {
  border-radius: var(--radius);
  background-color: var(--chip-bg);
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.photo-banner span {
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--muted);
  text-align: center;
  padding: 12px;
}

.photo-banner--hero {
  aspect-ratio: 5 / 2;
  margin: 40px auto 0;
  max-width: 1040px;
}

.photo-banner--tool {
  aspect-ratio: 16 / 5;
  margin: 0 0 34px;
}

@media (max-width: 640px) {
  .photo-banner--hero { aspect-ratio: 16 / 10; }
  .photo-banner--tool { aspect-ratio: 16 / 9; }
}

/* ---------- tool pages ---------- */

.tool-page { padding: 40px 0 64px; }

.breadcrumb {
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--muted);
  margin-bottom: 22px;
}

.breadcrumb a:hover { color: var(--ink); }

.breadcrumb .sep { margin: 0 6px; color: var(--line-strong); }

.tool-page h1 { font-size: clamp(1.7rem, 4.5vw, 2.4rem); }

.tool-page .lede { margin: 14px 0 30px; }

.tool-panel {
  background: var(--surface);
  border: 0.5px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 28px;
  margin-bottom: 34px;
}

.field-row {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  margin-bottom: 18px;
}

.field {
  flex: 1;
  min-width: 150px;
}

.field label {
  display: block;
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--ink-soft);
}

/* kill the native number spinners - they clash with the theme */
.field input[type="number"] {
  appearance: textfield;
  -moz-appearance: textfield;
}

.field input[type="number"]::-webkit-outer-spin-button,
.field input[type="number"]::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.field input[type="number"],
.field select {
  width: 100%;
  padding: 11px 14px;
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 1rem;
  color: var(--ink);
  background: var(--bg);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  outline: none;
}

.field input:focus,
.field select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.unit-inputs { display: flex; gap: 8px; }

.unit-inputs input { flex: 1; }

.seg {
  display: inline-flex;
  background: var(--chip-bg);
  border-radius: 999px;
  padding: 3px;
  gap: 2px;
}

.seg button {
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 600;
  padding: 7px 18px;
  border: none;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}

.seg button.on {
  background: var(--surface);
  color: var(--ink);
  box-shadow: 0 1px 2px rgba(22, 20, 15, 0.08);
}

.field-hint {
  font-size: 0.75rem;
  color: var(--muted);
  margin-top: 5px;
}

/* results */

.results { display: none; }

.results.show { display: block; }

.result-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
  margin-top: 8px;
}

.brand-result {
  background: var(--bg);
  border: 0.5px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 16px;
}

.brand-result .brand {
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  margin-bottom: 6px;
}

.brand-result .size {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.1;
}

.brand-result .size small {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--muted);
}

.brand-result .fit-note {
  font-size: 0.76rem;
  color: var(--ink-soft);
  margin-top: 6px;
  line-height: 1.45;
}

.brand-result.no-match .size { color: var(--muted); font-size: 1.05rem; }

.result-meta {
  font-size: 0.8rem;
  color: var(--muted);
  margin-top: 16px;
}

/* content sections below tools */

.tool-content { max-width: 760px; }

.tool-content h2 {
  font-size: 1.3rem;
  margin: 38px 0 12px;
}

.tool-content h3 { margin: 26px 0 8px; }

.tool-content p {
  color: var(--ink-soft);
  font-size: 0.95rem;
  margin-bottom: 12px;
}

.tool-content ul {
  margin: 0 0 12px 20px;
  color: var(--ink-soft);
  font-size: 0.95rem;
}

.tool-content li { margin-bottom: 6px; }

.chart-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
  margin: 14px 0 6px;
  background: var(--surface);
  border: 0.5px solid var(--line);
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.chart-table th {
  font-family: var(--font-display);
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  text-align: left;
  color: var(--muted);
  background: var(--chip-bg);
  padding: 9px 12px;
}

.chart-table td {
  padding: 8px 12px;
  border-top: 0.5px solid var(--line);
  color: var(--ink-soft);
}

.chart-table td:first-child {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--ink);
}

.table-scroll { overflow-x: auto; }

.note-box {
  background: var(--accent-soft);
  border-radius: var(--radius-sm);
  padding: 14px 18px;
  font-size: 0.85rem;
  color: var(--accent-ink);
  margin: 16px 0;
}

/* splits table reuse */
.chart-table tr.highlight td { background: var(--accent-soft); }

/* ---------- responsive ---------- */

@media (max-width: 640px) {
  .site-nav a:not(.btn) { display: none; }
  .hero { padding: 52px 0 44px; }
  .tool-grid { grid-template-columns: 1fr 1fr; }
  .tool-panel { padding: 20px; }
}

@media (max-width: 440px) {
  .tool-grid { grid-template-columns: 1fr; }
}
