/*
  BEARSCAR — public site
  Mascot-first: the bear is now a live-action training-film backdrop. The
  layout keeps BEARSCAR loud, readable, and usable across laptop, desktop,
  tablet, and phone viewports.
*/

:root {
  --bg: #0C0C0E;
  --bg-2: #131316;
  --surface: #161618;
  --surface-2: #1F1F23;
  --border: #25252A;
  --border-strong: #34343B;

  --gold: #C9A86C;
  --gold-bright: #D4B47A;
  --gold-soft: rgba(201, 168, 108, 0.12);
  --gold-glow: rgba(201, 168, 108, 0.22);

  --text: #F5F2EC;
  --text-2: #B8B5AE;
  --text-3: #75726D;
  --text-4: #45433F;

  --max: 1280px;
  --pad: clamp(20px, 4vw, 56px);

  --display: 'Archivo Black', 'Helvetica Neue', sans-serif;
  --body: 'Hanken Grotesk', system-ui, sans-serif;

  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

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

::selection { background: var(--gold); color: #0a0a0a; }

/* ─── Top nav ────────────────────────────────────────────────────── */
.topnav {
  position: relative;
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 24px;
  min-height: 76px;
  padding: 18px var(--pad);
  max-width: var(--max);
  margin: 0 auto;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-right: auto;
}
.brand-icon {
  width: 30px; height: 30px;
  border-radius: 7px;
}
.brand-word {
  font-family: var(--display);
  font-size: 19px;
  letter-spacing: -0.01em;
  color: var(--text);
}
.topnav-links {
  display: flex;
  gap: 26px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-2);
}
.topnav-links a {
  position: relative;
  padding: 6px 0;
  transition: color 0.2s var(--ease);
}
.topnav-links a:hover { color: var(--text); }
.topnav-cta {
  display: inline-flex;
  align-items: center;
  padding: 10px 18px;
  background: var(--gold);
  color: #15110a;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 700;
  transition: background 0.25s var(--ease), transform 0.25s var(--ease);
}
.topnav-cta:hover {
  background: var(--gold-bright);
  transform: translateY(-1px);
}

@media (max-width: 720px) {
  .topnav-links { display: none; }
}

/* ─── Hero ───────────────────────────────────────────────────────── */
.hero {
  position: relative;
  min-height: clamp(600px, calc(100svh - 118px), 820px);
  margin: 0;
  padding: clamp(56px, 7vw, 104px) var(--pad) clamp(50px, 7vw, 92px);
  display: flex;
  align-items: center;
  overflow: hidden;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  isolation: isolate;
}

.hero-media {
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    linear-gradient(90deg, #08080a 0%, #0c0c0e 42%, #12100d 100%),
    url("/videos/bearscar-live-hero-poster.jpg") center / cover;
}

.hero-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
}

.hero-scrim {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(6, 6, 8, 0.98) 0%, rgba(8, 8, 10, 0.88) 27%, rgba(8, 8, 10, 0.46) 56%, rgba(8, 8, 10, 0.3) 100%),
    linear-gradient(180deg, rgba(12, 12, 14, 0.22), rgba(12, 12, 14, 0.92));
  pointer-events: none;
}

.wordmark {
  font-family: var(--display);
  margin: 0;
  font-size: clamp(58px, 8.2vw, 128px);
  letter-spacing: -0.025em;
  line-height: 0.88;
  position: relative;
  z-index: 1;
  display: inline-block;
  white-space: nowrap;
  max-width: 100%;
}
.wm-bear { color: var(--text); }
.wm-scar { color: var(--gold); }

.hero-pitch {
  position: relative;
  z-index: 1;
  max-width: 620px;
  margin-left: max(var(--pad), calc((100vw - var(--max)) / 2 + var(--pad)));
  margin-right: var(--pad);
}

.lead {
  font-family: var(--display);
  font-size: clamp(32px, 4.15vw, 60px);
  line-height: 1.1;
  letter-spacing: -0.018em;
  color: var(--text);
  margin: clamp(18px, 2.6vw, 30px) 0 18px;
}

.lead-sub {
  font-size: clamp(16px, 1.4vw, 18px);
  color: var(--text-2);
  line-height: 1.55;
  max-width: 52ch;
  margin: 0 0 32px;
}
.lead-sub strong {
  color: var(--gold);
  font-weight: 700;
}

.hero-cta-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  align-items: center;
  gap: 18px;
}

.cta-detail {
  font-size: 13px;
  color: var(--text-3);
  letter-spacing: 0.04em;
  font-weight: 500;
}

@media (min-width: 1600px) {
  .hero {
    min-height: min(820px, calc(100svh - 120px));
  }

  .hero-pitch {
    margin-left: max(var(--pad), calc((100vw - var(--max)) / 2 + var(--pad)));
  }
}

@media (max-width: 1180px) {
  .hero {
    min-height: clamp(580px, calc(100svh - 112px), 760px);
  }

  .hero-video,
  .hero-media {
    object-position: 58% center;
    background-position: 58% center;
  }

  .hero-pitch {
    max-width: 560px;
  }

  .wordmark {
    font-size: clamp(56px, 9vw, 104px);
  }

  .lead {
    font-size: clamp(31px, 4.8vw, 54px);
  }
}

@media (max-height: 760px) and (min-width: 860px) {
  .topnav {
    min-height: 68px;
    padding-top: 14px;
    padding-bottom: 14px;
  }

  .hero {
    min-height: calc(100svh - 110px);
    padding-top: 44px;
    padding-bottom: 44px;
  }

  .wordmark {
    font-size: clamp(54px, 7.4vw, 96px);
  }

  .lead {
    font-size: clamp(30px, 3.8vw, 46px);
  }
}

@media (max-width: 900px) {
  .hero {
    align-items: flex-end;
    min-height: 700px;
    padding-top: 250px;
  }

  .hero-video,
  .hero-media {
    object-position: 63% center;
    background-position: 63% center;
  }

  .hero-scrim {
    background:
      linear-gradient(180deg, rgba(8, 8, 10, 0.08) 0%, rgba(8, 8, 10, 0.56) 43%, rgba(8, 8, 10, 0.98) 100%),
      linear-gradient(90deg, rgba(8, 8, 10, 0.62), rgba(8, 8, 10, 0.16));
  }

  .hero-pitch {
    margin: 0;
    max-width: 620px;
  }
}

@media (max-width: 720px) {
  .hero {
    min-height: 680px;
    align-items: flex-end;
    padding-top: 240px;
  }

  .hero-media {
    background-position: 58% center;
  }

  .hero-video {
    object-position: 66% center;
  }

  .hero-scrim {
    background:
      linear-gradient(180deg, rgba(8, 8, 10, 0.12) 0%, rgba(8, 8, 10, 0.68) 42%, rgba(8, 8, 10, 0.98) 100%),
      linear-gradient(90deg, rgba(8, 8, 10, 0.6), rgba(8, 8, 10, 0.18));
  }

  .hero-pitch {
    margin: 0;
    max-width: 100%;
  }

  .wordmark {
    font-size: clamp(40px, 13.2vw, 72px);
    letter-spacing: -0.03em;
  }

  .lead {
    font-size: clamp(22px, 5.8vw, 30px);
    line-height: 1.1;
    max-width: 14ch;
  }

  .lead-sub {
    font-size: 15px;
    max-width: 36ch;
  }

  .hero-cta-row {
    gap: 14px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-video { display: none; }
}

@media (max-width: 420px) {
  .topnav {
    min-height: 66px;
    padding-top: 14px;
    padding-bottom: 14px;
  }

  .brand-word {
    font-size: 17px;
  }

  .topnav-cta {
    padding: 9px 14px;
    font-size: 13px;
  }

  .hero {
    min-height: 660px;
    padding-bottom: 42px;
  }

  .hero-video,
  .hero-media {
    object-position: 69% center;
    background-position: 69% center;
  }

  .wordmark {
    font-size: clamp(38px, 13vw, 60px);
  }

  .lead {
    font-size: clamp(20px, 5.6vw, 28px);
    max-width: 14ch;
  }

  .hero-cta-row {
    gap: 12px;
  }
}

/* ─── App Store badge ───────────────────────────────────────────── */
.appstore {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 12px 22px 12px 18px;
  background: var(--text);
  color: #0a0a0a;
  border-radius: 12px;
  border: 1px solid var(--text);
  transition:
    transform 0.25s var(--ease),
    background 0.25s var(--ease),
    box-shadow 0.3s var(--ease);
}
.appstore-glyph {
  width: 26px;
  height: 26px;
  flex-shrink: 0;
}
.appstore-stack {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1;
}
.appstore-pre {
  font-size: 11px;
  letter-spacing: 0.02em;
  color: rgba(0, 0, 0, 0.55);
  margin-bottom: 4px;
  font-weight: 500;
}
.appstore-name {
  font-family: var(--display);
  font-size: 21px;
  letter-spacing: -0.01em;
}
.appstore:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 40px -18px rgba(201, 168, 108, 0.35);
}
.appstore--lg {
  padding: 16px 28px 16px 22px;
}
.appstore--lg .appstore-glyph { width: 30px; height: 30px; }
.appstore--lg .appstore-name { font-size: 25px; }

/* ─── Visual utilities ───────────────────────────────────────────── */
.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0);
  white-space: nowrap; border: 0;
}

.section-h {
  font-family: var(--display);
  font-size: clamp(28px, 3.8vw, 44px);
  letter-spacing: -0.018em;
  line-height: 1.05;
  margin: 0 0 12px;
  color: var(--text);
}

/* ─── How it works ──────────────────────────────────────────────── */
.howto {
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(50px, 7vw, 90px) var(--pad);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.howto .section-h {
  margin-bottom: 40px;
  text-align: center;
}
.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(24px, 4vw, 56px);
}
.step {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.step-num {
  font-family: var(--display);
  font-size: 64px;
  line-height: 0.9;
  color: var(--gold);
  letter-spacing: -0.04em;
  margin-bottom: 6px;
}
.step-h {
  font-family: var(--display);
  font-size: clamp(22px, 2.4vw, 28px);
  line-height: 1.05;
  letter-spacing: -0.018em;
  color: var(--text);
  margin: 0;
}
.step p {
  margin: 0;
  font-size: 16.5px;
  color: var(--text-2);
  line-height: 1.55;
  max-width: 36ch;
}

@media (max-width: 880px) {
  .steps { grid-template-columns: 1fr; gap: 28px; }
  .step-num { font-size: 52px; }
}

/* ─── Modes strip ────────────────────────────────────────────────── */
.modes {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--pad);
  border-bottom: 1px solid var(--border);
}
.mode {
  padding: 28px 24px;
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: flex-start;
}
.mode:last-child { border-right: 0; }
.mode-label {
  font-family: var(--display);
  font-size: 22px;
  letter-spacing: -0.01em;
  color: var(--text);
}
.mode--accent .mode-label { color: var(--gold); }
.mode p {
  font-size: 14.5px;
  color: var(--text-2);
  line-height: 1.4;
  margin: 0;
}

@media (max-width: 720px) {
  .modes { grid-template-columns: 1fr; }
  .mode {
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }
  .mode:last-child { border-bottom: 0; }
}

/* ─── Features (screenshot grid) ─────────────────────────────────── */
.features {
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(60px, 8vw, 110px) var(--pad);
}
.features-head {
  text-align: center;
  margin-bottom: clamp(40px, 5vw, 60px);
}
.features-head p {
  margin: 0;
  font-size: 16px;
  color: var(--text-2);
  max-width: 50ch;
  margin: 0 auto;
}

/* Flex with center-justify so wrapped items don't leave an orphan slot.
   At full width: 5 in a row. As the viewport shrinks, items wrap and
   re-center as a 3+2 / 2+2+1 / single-column stack — every row reads
   as intentional. */
.feature-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: clamp(16px, 2vw, 24px);
}
.feature-card {
  flex: 1 1 200px;
  max-width: 260px;
  min-width: 180px;
}

.feature-card {
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.feature-card img {
  width: 100%;
  height: auto;
  border-radius: 22px;
  box-shadow:
    0 24px 50px -25px rgba(0, 0, 0, 0.7),
    0 0 0 1px var(--border);
  transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease);
}
.feature-card:hover img {
  transform: translateY(-4px);
  box-shadow:
    0 30px 60px -22px rgba(0, 0, 0, 0.75),
    0 0 0 1px var(--gold-soft);
}
.feature-card figcaption {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 0 4px;
}
.feature-tag {
  align-self: flex-start;
  padding: 3px 10px;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  color: var(--gold);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.feature-card h3 {
  font-family: var(--display);
  font-size: clamp(18px, 1.7vw, 22px);
  line-height: 1.15;
  letter-spacing: -0.012em;
  margin: 0;
  color: var(--text);
}

/* ─── Download CTA ───────────────────────────────────────────────── */
.download {
  position: relative;
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(80px, 10vw, 130px) var(--pad);
  text-align: center;
  border-top: 1px solid var(--border);
  overflow: hidden;
}
.download-bear {
  width: clamp(120px, 14vw, 200px);
  height: auto;
  margin: 0 auto 24px;
  filter: drop-shadow(0 12px 24px rgba(201, 168, 108, 0.18));
  opacity: 0.95;
}
.download-h {
  font-family: var(--display);
  font-size: clamp(40px, 6vw, 84px);
  line-height: 0.96;
  letter-spacing: -0.02em;
  margin: 0 0 16px;
  color: var(--text);
}
.download-sub {
  margin: 0 auto 36px;
  max-width: 36ch;
  color: var(--text-2);
  font-size: 17px;
}

/* ─── Footer ─────────────────────────────────────────────────────── */
.foot {
  border-top: 1px solid var(--border);
  padding: clamp(40px, 6vw, 64px) var(--pad) 32px;
  max-width: var(--max);
  margin: 0 auto;
}
.foot-cols {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 32px;
  margin-bottom: 36px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--border);
}
.foot-col h4 {
  margin: 0 0 14px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--text);
}
.foot-col a {
  display: block;
  color: var(--text-2);
  font-size: 14.5px;
  padding: 4px 0;
  transition: color 0.2s var(--ease);
}
.foot-col a:hover { color: var(--gold); }
.foot-brand { display: flex; flex-direction: column; gap: 8px; }
.foot-mark {
  font-family: var(--display);
  font-size: 24px;
  letter-spacing: -0.015em;
  color: var(--text);
}
.foot-tag {
  font-size: 13.5px;
  color: var(--text-3);
}
.foot-bottom {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--text-3);
}
.foot-bottom a {
  color: var(--gold);
  font-weight: 700;
}

@media (max-width: 720px) {
  .foot-cols {
    grid-template-columns: 1fr 1fr;
    gap: 24px;
  }
  .foot-brand { grid-column: 1 / -1; }
  .foot-bottom { flex-direction: column; }
}

/* ─── Legal/support pages ────────────────────────────────────────── */
.doc {
  max-width: 720px;
  margin: 0 auto;
  padding: clamp(30px, 5vw, 60px) var(--pad) clamp(60px, 8vw, 100px);
}
.doc-eyebrow {
  font-size: 13px;
  font-weight: 600;
  color: var(--gold);
  margin: 0 0 12px;
  letter-spacing: 0.04em;
}
.doc h1 {
  font-family: var(--display);
  font-size: clamp(38px, 6vw, 68px);
  line-height: 0.98;
  letter-spacing: -0.02em;
  margin: 0 0 14px;
}
.doc-meta {
  font-size: 13.5px;
  color: var(--text-3);
  margin: 0 0 40px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border);
}
.doc h2 {
  font-family: var(--display);
  font-size: 21px;
  letter-spacing: -0.01em;
  margin: 36px 0 12px;
  color: var(--text);
}
.doc p {
  margin: 0 0 16px;
  color: var(--text-2);
  font-size: 16.5px;
  line-height: 1.7;
}
.doc ul {
  margin: 0 0 22px;
  padding: 0;
  list-style: none;
}
.doc ul li {
  position: relative;
  padding: 10px 0 10px 22px;
  color: var(--text-2);
  font-size: 16px;
  line-height: 1.55;
  border-top: 1px solid var(--border);
}
.doc ul li:last-child { border-bottom: 1px solid var(--border); }
.doc ul li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 22px;
  width: 10px;
  height: 1px;
  background: var(--gold);
}
.doc a {
  color: var(--gold);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s var(--ease);
}
.doc a:hover { border-bottom-color: var(--gold); }
.doc strong { color: var(--text); }
