/* ==========================================================================
   bramblr.app — shared stylesheet
   Design tokens mirror DESIGN.md §2.1 (Bramblr design system v1.6.x).
   Identity: §16 — mark geometry is contractual (inline SVG sprite in HTML);
   wordmark is LIVE Baloo 2 SemiBold 600 text only, never drawn/outlined.
   Light-only. No trackers. No JavaScript.
   ========================================================================== */

/* ---- Font: Baloo 2 SemiBold 600 (latin subset), self-hosted, OFL ---- */
@font-face {
  font-family: "Baloo 2";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("../assets/fonts/baloo2-semibold-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ---- Tokens (DESIGN.md §2.1 — do not invent values) ---- */
:root {
  --canvas: #fdfaf5;          /* bg/canvas — Warm White */
  --surface: #f5f0e8;         /* bg/surface — Cream */
  --surface-raised: #ffffff;  /* bg/surface-raised — White */
  --text-primary: #1a1612;    /* text/primary — Deep Charcoal */
  --text-body: #524c46;       /* text/body — Warm Umber */
  --text-muted: #6b6560;      /* text/muted — Warm Gray */
  --border: #e8e0d5;          /* border — Soft Taupe */
  --border-strong: #d3c8b6;   /* border/strong — Deep Taupe */
  --primary: #1c5c52;         /* primary — Forest Teal */
  --primary-pressed: #15463e; /* primary/pressed — Deep Teal */
  --primary-tint: #e4eeeb;    /* primary/tint — Teal Wash */
  --secondary: #c9a84c;       /* secondary — Warm Gold (decorative + ring only) */
  --secondary-tint: #f6eeda;  /* secondary/tint — Gold Wash */
  --cream: #fdfaf5;           /* identity: wordmark on charcoal/teal (§16.2) */

  --font-body: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-wordmark: "Baloo 2", "Inter", system-ui, sans-serif; /* §16.2 fallback stack */
}

/* ---- Base ---- */
* { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--canvas);
  color: var(--text-body);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
}

h1, h2, h3 {
  color: var(--text-primary);
  line-height: 1.2;
  margin: 0 0 0.5em;
}

p { margin: 0 0 1em; }

a {
  color: var(--primary);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
}
a:hover { color: var(--primary-pressed); }

:focus-visible {
  outline: 2px solid var(--primary); /* §8.3 — focus ring is always teal */
  outline-offset: 2px;
  border-radius: 2px;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}

.shell {
  max-width: 66rem;
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 5vw, 2.5rem);
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--surface-raised);
  color: var(--primary);
  padding: 0.75rem 1rem;
  border: 2px solid var(--primary);
  border-radius: 8px;
  z-index: 10;
}
.skip-link:focus { left: 1rem; top: 1rem; }

/* ---- Wordmark & lockups (§16) ---- */
.wordmark {
  font-family: var(--font-wordmark);
  font-weight: 600;
  letter-spacing: 0;          /* §16.2 — never add tracking */
  text-transform: none;
  color: var(--text-primary); /* never gold (§16.2) */
  line-height: 1;
}

.lockup { display: inline-flex; align-items: center; }

/* Symbol viewBox is the 240u canvas; the mark itself spans 154x114u, so the
   visible mark height ≈ svg-height × 114/240. Sizes keep the horizontal-lockup
   floor of 120px total width (§16.3). */
.lockup__mark { display: block; height: 66px; width: 66px; color: var(--text-primary); }
.lockup--header { gap: 0.6rem; }
.wordmark--header { font-size: 1.5rem; }

.lockup__mark--hero { height: 168px; width: 168px; }
.lockup--hero { gap: 1.25rem; }
.wordmark--hero { font-size: clamp(2.5rem, 7vw, 4rem); }

.lockup__mark--footer { height: 60px; width: 60px; }
.lockup--footer { gap: 0.6rem; }
.wordmark--footer { font-size: 1.5rem; color: var(--cream); }

/* ---- Header ---- */
.site-header {
  border-bottom: 1px solid var(--border);
  padding-block: 0.9rem;
  background: var(--canvas);
}

/* ---- Hero ---- */
.hero { padding-block: clamp(3rem, 9vw, 5.5rem) clamp(2.5rem, 7vw, 4.5rem); }
.hero .lockup { margin-bottom: 2rem; }

.eyebrow {
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase; /* overline is the one sanctioned all-caps (§8.8) */
  color: var(--primary);
  margin: 0 0 0.75rem;
}

.hero__line {
  font-size: clamp(1.75rem, 4.5vw, 2.5rem);
  font-weight: 700;
  max-width: 21ch;
  margin-bottom: 0.75rem;
}

.hero__support {
  font-size: clamp(1.125rem, 2.5vw, 1.375rem);
  max-width: 38ch;
  margin-bottom: 2.25rem;
}

/* ---- Store badges (PLACEHOLDERS until store approval) ---- */
.store-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.store-badge {
  display: grid;
  grid-template-columns: auto auto;
  grid-template-rows: auto auto;
  column-gap: 0.5rem;
  align-items: center;
  min-height: 3.5rem;
  padding: 0.6rem 1.25rem;
  background: var(--surface-raised);
  border: 2px dashed var(--border-strong); /* dashed = clearly a placeholder */
  border-radius: 12px;
  color: var(--text-primary);
}
.store-badge__small {
  font-size: 0.75rem;
  color: var(--text-muted);
  align-self: end;
  padding-bottom: 0.1rem;
}
.store-badge__large {
  font-size: 1.25rem;
  font-weight: 700;
  align-self: start;
}
.store-badge__note {
  grid-column: 1 / -1;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
  border-top: 1px solid var(--border);
  margin-top: 0.35rem;
  padding-top: 0.3rem;
}

.store-badges__hint {
  font-size: 0.9375rem;
  color: var(--text-muted);
  max-width: 48ch;
}

/* ---- Features ---- */
.features { padding-block: clamp(2rem, 6vw, 3.5rem) clamp(3rem, 8vw, 5rem); }

.section-title {
  font-size: clamp(1.5rem, 3.5vw, 2rem);
  margin-bottom: 0.5rem;
}

.section-rule { /* decorative gold motif — permitted accent (§2.1 secondary) */
  width: 44px;
  height: 3px;
  background: var(--secondary);
  border: none;
  margin: 0 0 2rem;
}

.feature-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 1rem;
}

.feature-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 1.5rem 1.4rem;
}

.feature-card__title {
  font-size: 1.1875rem;
  margin-bottom: 0.5rem;
}

.feature-card p { margin: 0; }

@media (min-width: 40rem) {
  .feature-grid { grid-template-columns: 1fr 1fr; gap: 1.25rem; }
  .feature-card { padding: 1.75rem 1.6rem; }
}

/* ---- Footer (§16.6: mono lockup on charcoal) ---- */
.site-footer {
  background: var(--text-primary); /* charcoal band */
  color: var(--cream);
  padding-block: 2.5rem 2rem;
  margin-top: clamp(2rem, 6vw, 4rem);
}

.site-footer .lockup { margin-bottom: 1.5rem; }
.site-footer .lockup__mark { color: var(--cream); } /* mono variant: ring follows currentColor */

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.75rem;
  margin-bottom: 1.25rem;
  font-weight: 600;
}

.footer-nav a { color: var(--cream); text-decoration: none; }
.footer-nav a:hover { text-decoration: underline; text-decoration-color: var(--secondary); }

.footer-entity { margin-bottom: 0.75rem; }

.footer-note {
  font-size: 0.875rem;
  color: rgba(253, 250, 245, 0.72);
  max-width: 60ch;
  margin: 0;
}

/* ---- Legal pages (privacy / terms) ---- */
.legal { padding-block: clamp(2.5rem, 7vw, 4rem); }

.legal__title { font-size: clamp(1.75rem, 4vw, 2.25rem); margin-bottom: 0.5rem; }

.legal__meta { color: var(--text-muted); font-size: 0.9375rem; margin-bottom: 2rem; }

.legal h2 {
  font-size: 1.25rem;
  margin-top: 2.25rem;
}

.legal h3 { /* long-form subsections (privacy §3) */
  font-size: 1.0625rem;
  margin-top: 1.75rem;
}

.legal p, .legal li { max-width: none; }

.legal .content {
  max-width: 46rem;
  font-size: 1.0625rem;
  line-height: 1.7;
}

.legal .content li + li { margin-top: 0.4rem; } /* breathe between long list items */

.legal address { /* contact block (privacy §12, terms §13) */
  font-style: normal;
}
