/* Type 2 Collective marketing site. Tokens match the app (app/src/constants/theme.ts). */
:root {
  --background: #0b0d0f;
  --surface: #17191c;
  --elevated: #202328;
  --text: #f5f6f7;
  --text-secondary: #b1b5bc;
  --text-tertiary: #858b93;
  --border: #34383e;
  --divider: #292d32;
  --accent: #ff6b3d;
  --accent-pressed: #e9572e;
  --accent-soft: #ff8a65;
  --on-accent: #0b0d0f;
  --radius-card: 16px;
  --radius-nested: 12px;
  --max: 1040px;
  --gutter: 20px;
}

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

html {
  color-scheme: dark;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--background);
  color: var(--text);
  font: 16px/1.55 -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, "Helvetica Neue", Arial,
    sans-serif;
}

a {
  color: var(--accent);
  text-underline-offset: 3px;
}

a:focus-visible,
.button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 8px;
}

.wrap {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

@media (max-width: 359px) {
  :root {
    --gutter: 16px;
  }
}

/* Header */
.site-header {
  border-bottom: 1px solid var(--divider);
}

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

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  text-decoration: none;
  font-weight: 700;
  font-size: 17px;
}

.brand img {
  width: 32px;
  height: 32px;
  border-radius: 8px;
}

/* Buttons */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 18px;
  border-radius: 16px;
  border: 1px solid transparent;
  font-weight: 600;
  font-size: 15px;
  text-decoration: none;
  white-space: nowrap;
}

.button-primary {
  background: var(--accent);
  color: var(--on-accent);
}

.button-primary:hover {
  background: var(--accent-pressed);
}

.button-large {
  min-height: 52px;
  padding: 0 24px;
  font-size: 16px;
}

.button-secondary {
  border-color: var(--border);
  color: var(--text);
}

.button-secondary:hover {
  background: var(--elevated);
}

/* Hero */
.hero {
  padding: 72px 0 56px;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--accent-soft);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.hero h1 {
  margin: 0;
  max-width: 14ch;
  font-size: clamp(36px, 8vw, 64px);
  line-height: 1.05;
  letter-spacing: -0.02em;
}

.hero .lede {
  max-width: 56ch;
  margin: 20px 0 32px;
  color: var(--text-secondary);
  font-size: clamp(17px, 2.4vw, 20px);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 16px;
}

.note {
  color: var(--text-tertiary);
  font-size: 14px;
}

/* Sections */
section + section {
  border-top: 1px solid var(--divider);
}

.section {
  padding: 56px 0;
}

.section h2 {
  margin: 0 0 8px;
  font-size: clamp(24px, 4vw, 32px);
  letter-spacing: -0.01em;
}

.section .intro {
  max-width: 60ch;
  margin: 0 0 32px;
  color: var(--text-secondary);
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  padding: 20px;
}

.card h3 {
  margin: 12px 0 6px;
  font-size: 17px;
}

.card p {
  margin: 0;
  color: var(--text-secondary);
  font-size: 15px;
}

.icon {
  width: 24px;
  height: 24px;
  color: var(--accent);
}

/* Coach preview: mirrors the app's recommendation card */
.preview {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
  align-items: start;
}

.recommendation {
  background: var(--elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-nested);
  padding: 16px;
}

.recommendation .label {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 8px;
  color: var(--accent-soft);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.recommendation .headline {
  margin: 0 0 6px;
  font-weight: 600;
  font-size: 17px;
}

.recommendation .why {
  margin: 0;
  color: var(--text-secondary);
  font-size: 14px;
}

.steps {
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: step;
}

.steps li {
  position: relative;
  padding: 0 0 20px 44px;
  color: var(--text-secondary);
}

.steps li strong {
  display: block;
  color: var(--text);
}

.steps li::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0;
  width: 28px;
  height: 28px;
  border: 1px solid var(--border);
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--divider);
  padding: 32px 0 48px;
  color: var(--text-tertiary);
  font-size: 14px;
}

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

.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
}

.site-footer a {
  color: var(--text-secondary);
}

/* Policy pages */
.doc {
  max-width: 720px;
  padding: 48px var(--gutter) 64px;
  margin: 0 auto;
}

.doc h1 {
  margin: 0 0 8px;
  font-size: clamp(30px, 6vw, 40px);
  letter-spacing: -0.01em;
}

.doc .updated {
  margin: 0 0 32px;
  color: var(--text-tertiary);
  font-size: 14px;
}

.doc h2 {
  margin: 40px 0 12px;
  font-size: 21px;
}

.doc h3 {
  margin: 24px 0 8px;
  font-size: 17px;
}

.doc p,
.doc li {
  color: var(--text-secondary);
}

.doc strong {
  color: var(--text);
}

.doc ul {
  padding-left: 22px;
}

.doc li + li {
  margin-top: 6px;
}

.summary {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  padding: 4px 20px;
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius-nested);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
}

th,
td {
  text-align: left;
  vertical-align: top;
  padding: 12px 14px;
  border-bottom: 1px solid var(--divider);
}

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

th {
  color: var(--text);
  background: var(--surface);
  font-weight: 600;
}

td {
  color: var(--text-secondary);
}

@media (prefers-reduced-motion: no-preference) {
  .button {
    transition: background-color 120ms ease;
  }
}
