/* ============================================================
   MotoHub AI — Garage-grade editorial design system
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Archivo:wght@500;600;700;800;900&family=IBM+Plex+Mono:wght@400;500;600&family=IBM+Plex+Sans:wght@400;500;600;700&display=swap');

:root {
  /* --- Surfaces (warm near-black) --- */
  --bg:            oklch(0.16 0.008 60);
  --bg-2:          oklch(0.20 0.009 60);
  --panel:         oklch(0.23 0.010 62);
  --panel-2:       oklch(0.27 0.011 62);
  --line:          oklch(0.34 0.012 62);
  --line-soft:     oklch(0.30 0.010 62);

  /* --- Text --- */
  --ink:           oklch(0.96 0.004 70);
  --ink-2:         oklch(0.80 0.006 70);
  --ink-3:         oklch(0.64 0.008 70);
  --ink-4:         oklch(0.50 0.008 70);

  /* --- Accents (shared L/C, varied hue) --- */
  --orange:        oklch(0.72 0.175 48);
  --orange-bright: oklch(0.78 0.175 55);
  --cyan:          oklch(0.72 0.13 220);
  --green:         oklch(0.72 0.15 150);
  --orange-dim:    oklch(0.72 0.175 48 / 0.14);
  --cyan-dim:      oklch(0.72 0.13 220 / 0.14);

  /* --- Type --- */
  --display: 'Archivo', system-ui, sans-serif;
  --body: 'IBM Plex Sans', system-ui, sans-serif;
  --mono: 'IBM Plex Mono', ui-monospace, monospace;

  /* --- Geometry --- */
  --r-sm: 4px;
  --r: 8px;
  --r-lg: 14px;
  --maxw: 1240px;
  --shadow: 0 1px 0 oklch(1 0 0 / 0.04) inset, 0 18px 40px -24px oklch(0 0 0 / 0.8);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

h1, h2, h3, h4 { font-family: var(--display); line-height: 1.05; margin: 0; letter-spacing: -0.01em; }

::selection { background: var(--orange); color: #1a1208; }

/* ---------- Layout ---------- */
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 28px; }
.wrap-narrow { max-width: 820px; margin: 0 auto; padding: 0 28px; }

.eyebrow {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--orange-bright);
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.eyebrow::before {
  content: "";
  width: 22px; height: 1px;
  background: var(--orange);
  display: inline-block;
}

/* ---------- Buttons ---------- */
.btn {
  font-family: var(--body);
  font-weight: 600;
  font-size: 15px;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 12px 20px;
  border-radius: var(--r);
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform .12s ease, background .15s ease, border-color .15s ease;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--orange); color: #1a1208; border-color: var(--orange-bright); }
.btn-primary:hover { background: var(--orange-bright); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--ink-3); background: var(--panel); }
.btn-block { width: 100%; justify-content: center; }
.btn-lg { padding: 15px 26px; font-size: 16px; }

.chip {
  font-family: var(--mono);
  font-size: 12.5px;
  letter-spacing: 0.02em;
  padding: 7px 13px;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--ink-2);
  background: var(--panel);
  transition: border-color .15s, color .15s, background .15s;
  cursor: pointer;
  white-space: nowrap;
}
.chip:hover { border-color: var(--orange); color: var(--ink); }
.chip.active { background: var(--orange); color: #1a1208; border-color: var(--orange); }

/* ---------- Placeholder imagery ---------- */
.ph {
  position: relative;
  background-color: var(--panel);
  background-image: repeating-linear-gradient(
    -45deg,
    oklch(0.30 0.01 62) 0 1px,
    transparent 1px 11px
  );
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  color: var(--ink-4);
}
.ph span {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  background: var(--bg);
  padding: 4px 9px;
  border-radius: 3px;
  border: 1px solid var(--line);
  color: var(--ink-3);
}

/* ---------- Header ---------- */
.topbar {
  background: var(--bg-2);
  border-bottom: 1px solid var(--line-soft);
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  color: var(--ink-3);
}
.topbar .wrap { display: flex; align-items: center; justify-content: space-between; height: 38px; }
.topbar a { color: var(--ink-2); }
.topbar a:hover { color: var(--orange-bright); }
.topbar .tb-right { display: flex; gap: 22px; }

header.site {
  position: sticky;
  top: 0;
  z-index: 50;
  background: oklch(0.16 0.008 60 / 0.86);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line-soft);
}
header.site .wrap { display: flex; align-items: center; gap: 28px; height: 72px; }

.logo { display: flex; align-items: center; gap: 11px; font-family: var(--display); font-weight: 900; font-size: 22px; letter-spacing: -0.02em; }
.logo .mark {
  width: 34px; height: 34px;
  border-radius: 7px;
  background: var(--orange);
  color: #1a1208;
  display: grid; place-items: center;
  font-size: 17px; font-weight: 900;
  transform: skewX(-7deg);
}
.logo .mark span { transform: skewX(7deg); }
.logo b { color: var(--orange-bright); font-weight: 900; }

nav.main { display: flex; gap: 4px; margin-left: 8px; }
nav.main a {
  font-weight: 600; font-size: 15px; color: var(--ink-2);
  padding: 9px 13px; border-radius: var(--r-sm);
  transition: color .15s, background .15s;
}
nav.main a:hover { color: var(--ink); background: var(--panel); }
nav.main a.active { color: var(--orange-bright); }

.header-tools { margin-left: auto; display: flex; align-items: center; gap: 12px; }
.search-mini {
  display: flex; align-items: center; gap: 9px;
  background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--r); padding: 9px 13px;
  min-width: 0; flex-shrink: 1; max-width: 240px;
  color: var(--ink-4); font-size: 14px; cursor: text;
  transition: border-color .15s; overflow: hidden;
}
.search-mini span:not(.k) { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.search-mini:hover { border-color: var(--ink-4); }
.search-mini .k { margin-left: auto; font-family: var(--mono); font-size: 11px; border: 1px solid var(--line); padding: 1px 6px; border-radius: 4px; }

.icon { width: 18px; height: 18px; stroke: currentColor; fill: none; stroke-width: 1.8; flex: none; }
.icon-sm { width: 15px; height: 15px; }

/* ---------- Ad slot ---------- */
.adslot {
  border: 1px dashed var(--line);
  border-radius: var(--r);
  background:
    repeating-linear-gradient(-45deg, oklch(0.21 0.008 60) 0 1px, transparent 1px 14px);
  color: var(--ink-4);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase;
  gap: 10px;
}
.adslot::before, .adslot::after { content: "·····"; color: var(--line); letter-spacing: 0.2em; }
.adslot.leaderboard { height: 96px; }
.adslot.inline { height: 124px; margin: 14px 0; }

/* ---------- Footer ---------- */
footer.site { background: var(--bg-2); border-top: 1px solid var(--line-soft); margin-top: 90px; }
footer.site .wrap { padding-top: 64px; padding-bottom: 40px; }
.foot-grid { display: grid; grid-template-columns: 1.6fr repeat(4, 1fr); gap: 40px; }
.foot-grid h5 { font-family: var(--mono); font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-3); margin: 0 0 16px; font-weight: 600; }
.foot-grid ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.foot-grid a { color: var(--ink-2); font-size: 14.5px; }
.foot-grid a:hover { color: var(--orange-bright); }
.foot-about p { color: var(--ink-3); font-size: 14.5px; max-width: 320px; margin: 16px 0 0; line-height: 1.7; }
.foot-bottom { border-top: 1px solid var(--line-soft); margin-top: 48px; padding-top: 26px; display: flex; justify-content: space-between; align-items: center; color: var(--ink-4); font-size: 13px; font-family: var(--mono); letter-spacing: 0.03em; }
.foot-disclosure { background: var(--panel); border: 1px solid var(--line-soft); border-radius: var(--r); padding: 14px 18px; color: var(--ink-3); font-size: 13px; margin-top: 34px; line-height: 1.6; }

/* ---------- Section headers ---------- */
.sec-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 32px; }
.sec-head h2 { font-size: clamp(28px, 3.4vw, 40px); font-weight: 800; }
.sec-head p { color: var(--ink-3); margin: 10px 0 0; max-width: 520px; }
.sec-head .more { font-family: var(--mono); font-size: 13px; color: var(--orange-bright); display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; }
.sec-head .more:hover { gap: 11px; }

section.block { padding: 76px 0; }
section.block.tight { padding: 52px 0; }

/* ---------- Utility ---------- */
.divider { height: 1px; background: var(--line-soft); border: 0; margin: 0; }
.rule-mono { font-family: var(--mono); font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-4); }
.badge {
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase;
  padding: 4px 9px; border-radius: 5px; font-weight: 500;
}
.badge.orange { background: var(--orange-dim); color: var(--orange-bright); }
.badge.cyan { background: var(--cyan-dim); color: var(--cyan); }
.badge.line { border: 1px solid var(--line); color: var(--ink-3); }
.star { color: var(--orange-bright); }

@media (max-width: 1080px) {
  nav.main, .search-mini { display: none; }
}
@media (max-width: 920px) {
  .foot-grid { grid-template-columns: 1fr 1fr; }
  .foot-about { grid-column: 1 / -1; }
}
@media (max-width: 720px) {
  .wrap, .wrap-narrow { padding: 0 18px; }
  body { font-size: 16px; }
  section.block { padding: 52px 0; }
}
