/* Female Fitness: Women Workout — site styles.
   Palette and type scale mirror the app's bloom_ui design tokens. */

@font-face {
  font-family: "Manrope";
  src: url("../fonts/manrope-latin.woff2") format("woff2-variations");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
}

:root {
  /* Rose — BloomColors.rose* */
  --rose-50: #fff1f6;
  --rose-100: #ffe1ec;
  --rose-200: #ffbed3;
  --rose-300: #ff92b6;
  --rose-400: #fa6c9e;
  --rose-500: #f2548b;
  --rose-600: #d93673;
  --rose-700: #b5265c;
  --rose-900: #711f3f;
  --rose-950: #430e22;

  /* Neutral — BloomColors.neutral* */
  --n-0: #ffffff;
  --n-50: #fffbfd;
  --n-100: #f8f4f7;
  --n-200: #ede7ec;
  --n-300: #d9d1d7;
  --n-400: #b0a6ae;
  --n-500: #7b7179;
  --n-600: #60575e;
  --n-700: #443c42;
  --n-800: #2e292d;
  --n-900: #211d20;
  --n-950: #151215;

  --lavender-100: #ece5ff;
  --lavender-500: #8d68f8;
  --mint-100: #ddf8f0;
  --mint-500: #25b993;
  --sky-100: #e2eeff;
  --sky-500: #3d7bd9;
  --peach-100: #ffebdd;
  --peach-500: #e98a4a;

  /* Semantic — light */
  --bg: var(--n-50);
  --surface: var(--n-0);
  --surface-alt: var(--n-100);
  --text: var(--n-900);
  --text-soft: var(--n-600);
  --text-faint: var(--n-500);
  --brand: var(--rose-500);
  --brand-strong: var(--rose-700);
  --on-brand: #ffffff;
  --brand-tint: var(--rose-50);
  --border: var(--n-200);
  --border-strong: var(--n-300);
  --shadow: 0 1px 2px rgb(33 29 32 / 4%), 0 12px 32px -12px rgb(33 29 32 / 10%);
  --shadow-lift: 0 2px 4px rgb(33 29 32 / 5%), 0 24px 48px -20px rgb(114 31 63 / 22%);

  /* Radius — BloomRadius */
  --r-sm: 8px;
  --r-md: 14px;
  --r-lg: 20px;
  --r-xl: 28px;
  --r-pill: 999px;

  --measure: 68ch;
  --page: 1120px;
  --gutter: clamp(1.25rem, 5vw, 3rem);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: var(--n-950);
    --surface: var(--n-900);
    --surface-alt: var(--n-800);
    --text: var(--n-50);
    --text-soft: #cabfc6;
    --text-faint: var(--n-400);
    --brand: var(--rose-300);
    --brand-strong: var(--rose-200);
    --on-brand: var(--rose-950);
    --brand-tint: #2a1620;
    --border: var(--n-800);
    --border-strong: var(--n-700);
    --shadow: 0 1px 2px rgb(0 0 0 / 40%), 0 12px 32px -12px rgb(0 0 0 / 60%);
    --shadow-lift: 0 2px 4px rgb(0 0 0 / 45%), 0 24px 48px -20px rgb(0 0 0 / 70%);
  }
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 5.5rem;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  font-size: 1.0625rem;
  line-height: 1.7;
  font-variation-settings: "wght" 450;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--brand-strong);
  text-underline-offset: 0.18em;
  text-decoration-thickness: 0.07em;
}

a:hover {
  color: var(--brand);
}

:focus-visible {
  outline: 3px solid var(--brand);
  outline-offset: 3px;
  border-radius: var(--r-sm);
}

h1,
h2,
h3,
h4 {
  font-variation-settings: "wght" 780;
  line-height: 1.15;
  letter-spacing: -0.022em;
  margin: 0 0 0.5em;
  color: var(--text);
  text-wrap: balance;
}

h1 {
  font-size: clamp(2.1rem, 1.4rem + 3.2vw, 3.5rem);
}

h2 {
  font-size: clamp(1.5rem, 1.15rem + 1.5vw, 2.05rem);
}

h3 {
  font-size: clamp(1.1rem, 1rem + 0.5vw, 1.3rem);
  font-variation-settings: "wght" 720;
}

p,
li {
  text-wrap: pretty;
}

hr {
  border: 0;
  border-top: 1px solid var(--border);
  margin: 3rem 0;
}

code {
  font-family: Inconsolata, ui-monospace, SFMono-Regular, Menlo, monospace;
  background: var(--surface-alt);
  padding: 0.1em 0.4em;
  border-radius: var(--r-sm);
  font-size: 0.92em;
}

/* ---------- Layout ---------- */

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

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--brand);
  color: var(--on-brand);
  padding: 0.75rem 1.25rem;
  border-radius: 0 0 var(--r-md) 0;
  font-variation-settings: "wght" 700;
  z-index: 100;
}

.skip-link:focus {
  left: 0;
  color: var(--on-brand);
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--border);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  gap: 1rem;
  min-height: 4.25rem;
  flex-wrap: wrap;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  font-variation-settings: "wght" 780;
  font-size: 1.02rem;
  letter-spacing: -0.02em;
  color: var(--text);
  text-decoration: none;
  margin-inline-end: auto;
}

.brand img {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: var(--n-0);
  box-shadow: var(--shadow);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(0.75rem, 2.5vw, 1.5rem);
  font-size: 0.95rem;
}

.site-nav a {
  color: var(--text-soft);
  text-decoration: none;
  font-variation-settings: "wght" 600;
  padding: 0.35rem 0;
  border-bottom: 2px solid transparent;
}

.site-nav a:hover {
  color: var(--brand);
}

.site-nav a[aria-current="page"] {
  color: var(--text);
  border-bottom-color: var(--brand);
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  padding: 0.85rem 1.6rem;
  border-radius: var(--r-pill);
  font-variation-settings: "wght" 720;
  font-size: 1rem;
  line-height: 1.2;
  text-decoration: none;
  border: 1.5px solid transparent;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.btn:active {
  transform: translateY(1px);
}

.btn-primary {
  background: var(--brand);
  color: var(--on-brand);
  box-shadow: var(--shadow-lift);
}

.btn-primary:hover {
  background: var(--rose-600);
  color: var(--on-brand);
}

@media (prefers-color-scheme: dark) {
  .btn-primary:hover {
    background: var(--rose-200);
  }
}

.btn-ghost {
  background: var(--surface);
  color: var(--text);
  border-color: var(--border-strong);
  box-shadow: var(--shadow);
}

.btn-ghost:hover {
  color: var(--text);
  border-color: var(--brand);
}

.btn svg {
  width: 1.15em;
  height: 1.15em;
  flex: none;
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  overflow: hidden;
  padding: clamp(3rem, 8vw, 6rem) 0 clamp(2.5rem, 6vw, 4.5rem);
}

.hero::before,
.hero::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  z-index: 0;
  pointer-events: none;
}

.hero::before {
  width: 46rem;
  height: 46rem;
  top: -26rem;
  right: -16rem;
  background: color-mix(in srgb, var(--rose-300) 42%, transparent);
}

.hero::after {
  width: 32rem;
  height: 32rem;
  bottom: -20rem;
  left: -14rem;
  background: color-mix(in srgb, var(--lavender-500) 16%, transparent);
}

.hero .wrap {
  position: relative;
  z-index: 1;
}

.hero-grid {
  display: grid;
  gap: clamp(2rem, 5vw, 3.5rem);
  align-items: center;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
}

@media (max-width: 860px) {
  .hero-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--brand-tint);
  color: var(--brand-strong);
  border: 1px solid color-mix(in srgb, var(--brand) 26%, transparent);
  border-radius: var(--r-pill);
  padding: 0.4rem 0.95rem;
  font-size: 0.8rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  font-variation-settings: "wght" 720;
  margin-bottom: 1.25rem;
}

.hero h1 .accent {
  color: var(--brand);
  display: block;
}

.lede {
  font-size: clamp(1.05rem, 1rem + 0.4vw, 1.25rem);
  color: var(--text-soft);
  max-width: 42ch;
  margin: 0 0 2rem;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-bottom: 1.5rem;
}

.hero-note {
  font-size: 0.92rem;
  color: var(--text-faint);
  margin: 0;
}

.hero-art {
  display: grid;
  place-items: center;
}

.app-tile {
  position: relative;
  display: grid;
  place-items: center;
  width: min(100%, 22rem);
  aspect-ratio: 1;
  border-radius: clamp(2rem, 6vw, 3.25rem);
  background: linear-gradient(150deg, var(--rose-100), var(--rose-200) 55%, var(--lavender-100));
  box-shadow: var(--shadow-lift);
}

@media (prefers-color-scheme: dark) {
  .app-tile {
    background: linear-gradient(150deg, #3a1a29, #4d1e35 55%, #2c2141);
  }
}

/* The app icon artwork has an opaque white background, so it is presented on a
   deliberate white card rather than floating directly on the gradient. */
.icon-card {
  width: 58%;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  background: var(--n-0);
  border-radius: 24%;
  box-shadow: 0 18px 44px rgb(114 31 63 / 28%);
  overflow: hidden;
}

.icon-card img {
  width: 84%;
}

.tile-badge {
  position: absolute;
  bottom: -0.9rem;
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: var(--r-pill);
  padding: 0.5rem 1.1rem;
  font-size: 0.88rem;
  font-variation-settings: "wght" 700;
  box-shadow: var(--shadow);
  white-space: nowrap;
}

/* ---------- Sections ---------- */

.section {
  padding: clamp(3rem, 7vw, 5rem) 0;
}

.section-tint {
  background: var(--surface-alt);
  border-block: 1px solid var(--border);
}

.section-head {
  max-width: 46ch;
  margin-bottom: clamp(1.75rem, 4vw, 2.75rem);
}

.section-head p {
  color: var(--text-soft);
  margin: 0;
}

.grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  padding: 1.6rem;
  box-shadow: var(--shadow);
}

.card h3 {
  margin-bottom: 0.4rem;
}

.card p {
  margin: 0;
  color: var(--text-soft);
  font-size: 0.98rem;
}

.card-icon {
  width: 2.75rem;
  height: 2.75rem;
  display: grid;
  place-items: center;
  border-radius: var(--r-md);
  margin-bottom: 1rem;
  font-size: 1.35rem;
}

.i-rose {
  background: var(--rose-100);
  color: var(--rose-700);
}

.i-lavender {
  background: var(--lavender-100);
  color: #5a34c9;
}

.i-mint {
  background: var(--mint-100);
  color: #14775e;
}

.i-sky {
  background: var(--sky-100);
  color: #245499;
}

.i-peach {
  background: var(--peach-100);
  color: #a85a22;
}

.stat-row {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr));
  margin-top: 2rem;
}

.stat {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 1.25rem;
  text-align: center;
}

.stat b {
  display: block;
  font-size: 1.75rem;
  font-variation-settings: "wght" 800;
  color: var(--brand);
  letter-spacing: -0.03em;
}

.stat span {
  font-size: 0.88rem;
  color: var(--text-faint);
}

/* ---------- Legal / article pages ---------- */

.page-hero {
  padding: clamp(2.5rem, 6vw, 4rem) 0 clamp(1.5rem, 3vw, 2rem);
  border-bottom: 1px solid var(--border);
  background: linear-gradient(180deg, var(--brand-tint), transparent);
}

.page-hero p {
  color: var(--text-soft);
  max-width: var(--measure);
  margin: 0.5rem 0 0;
}

.updated {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  color: var(--text-faint);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-pill);
  padding: 0.3rem 0.85rem;
  margin-bottom: 1rem;
}

.doc {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: clamp(2rem, 5vw, 3.5rem);
  padding: clamp(2rem, 5vw, 3.5rem) 0 4rem;
}

@media (min-width: 1000px) {
  .doc.has-toc {
    grid-template-columns: 16rem minmax(0, 1fr);
  }
}

.toc {
  font-size: 0.93rem;
}

@media (min-width: 1000px) {
  .toc {
    position: sticky;
    top: 5.5rem;
    align-self: start;
    max-height: calc(100vh - 7rem);
    overflow-y: auto;
  }
}

.toc h2 {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-faint);
  font-variation-settings: "wght" 720;
  margin-bottom: 0.75rem;
}

.toc ol {
  list-style: none;
  margin: 0;
  padding: 0;
  border-left: 2px solid var(--border);
}

.toc li {
  margin: 0;
}

.toc a {
  display: block;
  padding: 0.35rem 0 0.35rem 0.9rem;
  margin-left: -2px;
  border-left: 2px solid transparent;
  color: var(--text-soft);
  text-decoration: none;
  line-height: 1.4;
}

.toc a:hover {
  color: var(--brand);
  border-left-color: var(--brand);
}

.prose {
  max-width: var(--measure);
}

.prose > section + section {
  margin-top: 2.75rem;
}

.prose h2 {
  scroll-margin-top: 5.5rem;
  padding-top: 0.25rem;
}

.prose h3 {
  margin-top: 1.75rem;
  scroll-margin-top: 5.5rem;
}

.prose p,
.prose ul,
.prose ol {
  color: var(--text-soft);
}

.prose ul,
.prose ol {
  padding-left: 1.25rem;
}

.prose li + li {
  margin-top: 0.4rem;
}

.prose li::marker {
  color: var(--brand);
}

.prose strong {
  color: var(--text);
  font-variation-settings: "wght" 700;
}

.prose dl {
  margin: 0;
}

.prose dt {
  font-variation-settings: "wght" 700;
  color: var(--text);
  margin-top: 1rem;
}

.prose dd {
  margin: 0.15rem 0 0;
  color: var(--text-soft);
}

.callout {
  border: 1px solid color-mix(in srgb, var(--brand) 32%, transparent);
  background: var(--brand-tint);
  border-radius: var(--r-lg);
  padding: 1.25rem 1.4rem;
  margin: 1.75rem 0;
}

.callout p:first-child {
  margin-top: 0;
}

.callout p:last-child {
  margin-bottom: 0;
}

.callout strong {
  color: var(--brand-strong);
}

.table-scroll {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  margin: 1.5rem 0;
  background: var(--surface);
}

table {
  border-collapse: collapse;
  width: 100%;
  min-width: 34rem;
  font-size: 0.95rem;
}

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

th {
  font-variation-settings: "wght" 720;
  color: var(--text);
  background: var(--surface-alt);
  white-space: nowrap;
}

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

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

/* ---------- FAQ ---------- */

.faq {
  max-width: var(--measure);
}

.faq details {
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  background: var(--surface);
  padding: 0 1.25rem;
  margin-bottom: 0.75rem;
}

.faq details[open] {
  border-color: color-mix(in srgb, var(--brand) 40%, transparent);
}

.faq summary {
  cursor: pointer;
  list-style: none;
  padding: 1rem 2rem 1rem 0;
  font-variation-settings: "wght" 700;
  color: var(--text);
  position: relative;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::after {
  content: "+";
  position: absolute;
  right: 0.25rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--brand);
  font-size: 1.4rem;
  line-height: 1;
}

.faq details[open] summary::after {
  content: "–";
}

.faq details > *:not(summary) {
  color: var(--text-soft);
  margin-top: 0;
}

.faq details > *:last-child {
  padding-bottom: 1rem;
}

/* ---------- Steps ---------- */

.steps {
  counter-reset: step;
  list-style: none;
  padding: 0;
  max-width: var(--measure);
}

.steps li {
  counter-increment: step;
  position: relative;
  padding-left: 3.25rem;
  min-height: 2.25rem;
}

.steps li + li {
  margin-top: 1.4rem;
}

.steps li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0;
  width: 2.25rem;
  height: 2.25rem;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--brand);
  color: var(--on-brand);
  font-variation-settings: "wght" 780;
  font-size: 0.95rem;
}

/* ---------- Footer ---------- */

.site-footer {
  border-top: 1px solid var(--border);
  background: var(--surface-alt);
  padding: 3rem 0 2.5rem;
  font-size: 0.94rem;
}

.footer-grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
  margin-bottom: 2.25rem;
}

.footer-grid h2 {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-faint);
  font-variation-settings: "wght" 720;
  margin-bottom: 0.85rem;
}

.footer-grid ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.footer-grid li + li {
  margin-top: 0.45rem;
}

.footer-grid a {
  color: var(--text-soft);
  text-decoration: none;
}

.footer-grid a:hover {
  color: var(--brand);
  text-decoration: underline;
}

.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.5rem;
  align-items: center;
  justify-content: space-between;
  color: var(--text-faint);
  font-size: 0.88rem;
}

.footer-bottom p {
  margin: 0;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}
