/* Formula Studio · mobile-first product page */
.fs-page {
  --fs-accent: color-mix(in srgb, var(--brand) 72%, var(--brand-2));
  --fs-accent-soft: color-mix(in srgb, var(--fs-accent) 13%, transparent);
  --fs-line: color-mix(in srgb, var(--line) 84%, transparent);
}

.fs-hero {
  position: relative;
  overflow: hidden;
  background: var(--bg-deep);
  color: var(--on-brand);
  padding-block: clamp(56px, 11vw, 108px) clamp(44px, 8vw, 82px);
}

.fs-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(50% 50% at 12% 0%, color-mix(in srgb, var(--brand) 48%, transparent), transparent 66%),
    radial-gradient(42% 48% at 92% 10%, color-mix(in srgb, var(--brand-2) 28%, transparent), transparent 68%),
    linear-gradient(145deg, transparent 44%, color-mix(in srgb, var(--brand-3) 16%, transparent));
}

.fs-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: .16;
  background-image:
    linear-gradient(color-mix(in srgb, var(--on-brand) 15%, transparent) 1px, transparent 1px),
    linear-gradient(90deg, color-mix(in srgb, var(--on-brand) 15%, transparent) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(black, transparent 88%);
}

.fs-hero__in,
.fs-section,
.fs-band,
.fs-proof,
.fs-faq,
.fs-cta {
  position: relative;
  z-index: 1;
}

.fs-hero__grid {
  display: grid;
  gap: clamp(30px, 6vw, 58px);
}

.fs-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-height: 34px;
  padding: 7px 13px;
  border-radius: var(--r-pill);
  border: 1px solid color-mix(in srgb, var(--brand-2) 36%, transparent);
  background: color-mix(in srgb, var(--brand-2) 9%, transparent);
  color: var(--brand-2);
  font-size: var(--fs-xs);
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.fs-eyebrow::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--brand-2);
  box-shadow: 0 0 18px var(--brand-2);
}

.fs-title {
  max-width: 780px;
  margin: var(--sp-5) 0 var(--sp-4);
  font-size: clamp(38px, 9.6vw, 76px);
  line-height: 1.03;
  letter-spacing: -.045em;
  color: var(--on-brand);
  text-wrap: balance;
}

.fs-title em {
  display: inline;
  color: var(--brand-2);
  font-style: normal;
}

.fs-lede {
  max-width: 680px;
  color: color-mix(in srgb, var(--on-brand) 72%, transparent);
  font-size: clamp(var(--fs-md), 2.8vw, var(--fs-xl));
  line-height: 1.62;
}

.fs-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-3);
  margin-top: var(--sp-5);
}

.fs-notes {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2) var(--sp-4);
  margin-top: var(--sp-4);
  color: color-mix(in srgb, var(--on-brand) 58%, transparent);
  font-size: var(--fs-xs);
}

.fs-notes span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.fs-notes span::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--brand-2);
}

.fs-window {
  position: relative;
  border: 1px solid color-mix(in srgb, var(--on-brand) 17%, transparent);
  border-radius: var(--r-xl);
  background: color-mix(in srgb, var(--bg-deep) 84%, var(--surface));
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

.fs-window__bar {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  padding-inline: 16px;
  border-bottom: 1px solid color-mix(in srgb, var(--on-brand) 12%, transparent);
}

.fs-window__bar i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: color-mix(in srgb, var(--on-brand) 22%, transparent);
}

.fs-window__bar b {
  margin-inline-start: auto;
  color: color-mix(in srgb, var(--on-brand) 58%, transparent);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
}

.fs-window__body {
  display: grid;
  gap: 1px;
  background: color-mix(in srgb, var(--on-brand) 10%, transparent);
}

.fs-window__shot {
  min-height: 260px;
  overflow: hidden;
  background: var(--surface);
}

.fs-window__shot img {
  width: 100%;
  height: 100%;
  min-height: 260px;
  object-fit: cover;
  object-position: top center;
}

.fs-pipeline {
  display: grid;
  gap: 1px;
  background: color-mix(in srgb, var(--on-brand) 10%, transparent);
}

.fs-pipeline__step {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 55px;
  padding: 10px 16px;
  background: color-mix(in srgb, var(--bg-deep) 90%, var(--surface));
  color: color-mix(in srgb, var(--on-brand) 76%, transparent);
  font-size: var(--fs-sm);
}

.fs-pipeline__step span {
  display: grid;
  place-items: center;
  width: 29px;
  height: 29px;
  flex: 0 0 29px;
  border-radius: 9px;
  background: var(--fs-accent);
  color: var(--bg-deep);
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 800;
}

.fs-metrics {
  position: relative;
  z-index: 2;
  margin-top: calc(var(--sp-6) * -1);
  padding-bottom: var(--sp-6);
}

.fs-metrics__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background: var(--surface);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.fs-metric {
  min-width: 0;
  padding: 20px 18px;
  border-bottom: 1px solid var(--line-soft);
}

.fs-metric:nth-child(odd) {
  border-inline-end: 1px solid var(--line-soft);
}

.fs-metric:nth-last-child(-n+2) {
  border-bottom: 0;
}

.fs-metric b {
  display: block;
  color: var(--brand-text);
  font-family: var(--font-display);
  font-size: clamp(26px, 6vw, 38px);
  letter-spacing: -.035em;
  line-height: 1;
}

.fs-metric span {
  display: block;
  margin-top: 8px;
  color: var(--muted);
  font-size: var(--fs-xs);
  line-height: 1.45;
}

.fs-section {
  padding-block: clamp(52px, 8vw, 88px);
}

.fs-section--soft {
  background: var(--bg-soft);
}

.fs-section-head {
  max-width: 720px;
  margin-bottom: clamp(26px, 4vw, 42px);
}

.fs-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: var(--sp-3);
  color: var(--brand-text);
  font-size: var(--fs-xs);
  font-weight: 700;
  letter-spacing: .13em;
  text-transform: uppercase;
}

.fs-kicker::before {
  content: "";
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: var(--brand);
}

.fs-section-head h2 {
  font-size: clamp(30px, 6vw, 46px);
  line-height: 1.12;
  letter-spacing: -.035em;
  text-wrap: balance;
}

.fs-section-head p {
  margin-top: var(--sp-3);
  color: var(--muted);
  font-size: var(--fs-md);
}

.fs-market,
.fs-stack,
.fs-offers,
.fs-flow,
.fs-fit,
.fs-faq__grid {
  display: grid;
  gap: var(--sp-4);
}

.fs-market {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
}

.fs-market__item,
.fs-stack__item,
.fs-fit__col,
.fs-faq details {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.fs-market__item {
  padding: 22px;
}

.fs-market__item b,
.fs-stack__item b {
  display: block;
  font-size: var(--fs-lg);
  line-height: 1.35;
}

.fs-market__item p,
.fs-stack__item p {
  margin-top: 9px;
  color: var(--muted);
  font-size: var(--fs-sm);
}

.fs-stack {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 245px), 1fr));
}

.fs-stack__item {
  padding: 24px;
}

.fs-stack__num {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  margin-bottom: 16px;
  border-radius: 11px;
  background: var(--fs-accent-soft);
  color: var(--brand-text);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 800;
}

.fs-offers {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr));
}

.fs-offer {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--r-xl);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.fs-offer--featured {
  border-color: color-mix(in srgb, var(--brand) 52%, var(--line));
  box-shadow: var(--shadow);
}

.fs-offer__badge {
  align-self: flex-start;
  margin-bottom: 12px;
  padding: 5px 10px;
  border-radius: var(--r-pill);
  background: var(--brand-soft);
  color: var(--brand-text);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .05em;
}

.fs-offer h3 {
  font-size: var(--fs-lg);
}

.fs-offer__price {
  margin-top: 15px;
  color: var(--text);
  font-family: var(--font-display);
  font-size: clamp(34px, 7vw, 47px);
  letter-spacing: -.04em;
  line-height: 1;
}

.fs-offer__price small {
  margin-inline-start: 4px;
  color: var(--muted);
  font-family: var(--font-body);
  font-size: var(--fs-xs);
  font-weight: 500;
  letter-spacing: 0;
}

.fs-offer__desc {
  margin-top: var(--sp-3);
  color: var(--muted);
  font-size: var(--fs-sm);
}

.fs-offer ul {
  display: grid;
  gap: 9px;
  margin-top: var(--sp-4);
  padding-top: var(--sp-4);
  border-top: 1px solid var(--line-soft);
}

.fs-offer li {
  display: flex;
  gap: 9px;
  color: var(--text-2);
  font-size: var(--fs-sm);
}

.fs-offer li::before {
  content: "";
  width: 7px;
  height: 7px;
  flex: 0 0 7px;
  margin-top: .48em;
  border-radius: 50%;
  background: var(--fs-accent);
}

.fs-proof {
  padding-block: clamp(52px, 8vw, 88px);
  background: var(--bg-deep);
  color: var(--on-brand);
}

.fs-proof .fs-section-head p {
  color: color-mix(in srgb, var(--on-brand) 58%, transparent);
}

.fs-proof .fs-kicker {
  color: var(--brand-2);
}

.fs-proof .fs-kicker::before {
  background: var(--brand-2);
}

.fs-proof__grid {
  display: grid;
  gap: var(--sp-4);
}

.fs-proof__card {
  display: grid;
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--on-brand) 13%, transparent);
  border-radius: var(--r-xl);
  background: color-mix(in srgb, var(--bg-deep) 88%, var(--surface));
}

.fs-proof__copy {
  padding: 24px;
}

.fs-proof__copy span {
  color: var(--brand-2);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .1em;
}

.fs-proof__copy h3 {
  margin-top: 11px;
  color: var(--on-brand);
  font-size: var(--fs-xl);
}

.fs-proof__copy p {
  margin-top: 9px;
  color: color-mix(in srgb, var(--on-brand) 61%, transparent);
  font-size: var(--fs-sm);
}

.fs-proof__image {
  min-height: 235px;
  overflow: hidden;
  border-top: 1px solid color-mix(in srgb, var(--on-brand) 11%, transparent);
  background: var(--surface);
}

.fs-proof__image img {
  width: 100%;
  height: 100%;
  min-height: 235px;
  object-fit: cover;
  object-position: top center;
}

.fs-flow {
  counter-reset: fs-flow;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 215px), 1fr));
}

.fs-flow__item {
  position: relative;
  min-width: 0;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background: var(--surface);
}

.fs-flow__item::before {
  counter-increment: fs-flow;
  content: "0" counter(fs-flow);
  display: block;
  margin-bottom: 22px;
  color: var(--brand-text);
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 800;
}

.fs-flow__item b {
  display: block;
  font-size: var(--fs-lg);
}

.fs-flow__item p {
  margin-top: 8px;
  color: var(--muted);
  font-size: var(--fs-sm);
}

.fs-fit {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
}

.fs-fit__col {
  padding: 24px;
}

.fs-fit__col h3 {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: var(--fs-lg);
}

.fs-fit__mark {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 9px;
  background: color-mix(in srgb, var(--ok) 14%, transparent);
  color: var(--ok);
  font-size: 15px;
}

.fs-fit__col--no .fs-fit__mark {
  background: color-mix(in srgb, var(--err) 13%, transparent);
  color: var(--err);
}

.fs-fit__col ul {
  display: grid;
  gap: 11px;
  margin-top: var(--sp-4);
}

.fs-fit__col li {
  color: var(--text-2);
  font-size: var(--fs-sm);
}

.fs-compliance {
  margin-top: var(--sp-4);
  padding: 22px;
  border: 1px solid color-mix(in srgb, var(--warn) 38%, var(--line));
  border-radius: var(--r-lg);
  background: color-mix(in srgb, var(--warn) 8%, var(--surface));
}

.fs-compliance b {
  display: block;
  font-size: var(--fs-md);
}

.fs-compliance p {
  margin-top: 7px;
  color: var(--muted);
  font-size: var(--fs-sm);
}

.fs-faq {
  padding-block: clamp(48px, 8vw, 84px);
  background: var(--bg-soft);
}

.fs-faq__grid {
  grid-template-columns: minmax(0, 1fr);
}

.fs-faq details {
  padding: 0 20px;
}

.fs-faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 62px;
  cursor: pointer;
  font-weight: 600;
  list-style: none;
}

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

.fs-faq summary::after {
  content: "+";
  flex: 0 0 auto;
  color: var(--brand-text);
  font-size: 21px;
}

.fs-faq details[open] summary::after {
  content: "−";
}

.fs-faq details p {
  padding: 0 0 20px;
  color: var(--muted);
  font-size: var(--fs-sm);
}

.fs-cta {
  padding-block: clamp(52px, 9vw, 92px);
  background:
    radial-gradient(50% 60% at 12% 0%, color-mix(in srgb, var(--brand) 15%, transparent), transparent 72%),
    radial-gradient(50% 60% at 92% 100%, color-mix(in srgb, var(--brand-2) 12%, transparent), transparent 72%),
    var(--bg);
}

.fs-cta__grid {
  display: grid;
  gap: clamp(26px, 5vw, 54px);
}

.fs-cta__copy h2 {
  margin-top: var(--sp-2);
  font-size: clamp(32px, 6vw, 50px);
  line-height: 1.1;
  letter-spacing: -.04em;
  text-wrap: balance;
}

.fs-cta__copy p {
  margin-top: var(--sp-3);
  color: var(--muted);
  font-size: var(--fs-md);
}

.fs-form {
  display: grid;
  gap: var(--sp-3);
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: var(--r-xl);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.fs-form .field {
  min-width: 0;
}

.fs-form label {
  display: block;
  margin-bottom: 7px;
  color: var(--text-2);
  font-size: var(--fs-xs);
  font-weight: 600;
}

.fs-form input,
.fs-form textarea {
  width: 100%;
  min-height: 46px;
  padding: 11px 12px;
  border: 1px solid var(--input-line);
  border-radius: var(--r-sm);
  background: var(--input-bg);
  color: var(--text);
  outline: none;
  transition: border-color .18s var(--ease), box-shadow .18s var(--ease);
}

.fs-form textarea {
  min-height: 126px;
  resize: vertical;
}

.fs-form input:focus,
.fs-form textarea:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--fs-accent-soft);
}

.fs-form .err {
  color: var(--err);
  font-size: var(--fs-xs);
}

.fs-form__note {
  color: var(--dim);
  font-size: var(--fs-xs);
  text-align: center;
}

.fs-alert {
  padding: 13px 15px;
  border-radius: var(--r-sm);
  font-size: var(--fs-sm);
}

.fs-alert--ok {
  background: color-mix(in srgb, var(--ok) 11%, var(--surface));
  color: var(--ok);
}

.fs-alert--err {
  background: color-mix(in srgb, var(--err) 10%, var(--surface));
  color: var(--err);
}

@media (min-width: 560px) {
  .fs-metrics__grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .fs-metric {
    border-bottom: 0;
    border-inline-end: 1px solid var(--line-soft);
  }

  .fs-metric:last-child {
    border-inline-end: 0;
  }
}

@media (min-width: 760px) {
  .fs-window__body {
    grid-template-columns: minmax(0, 1fr) 270px;
  }

  .fs-window__shot,
  .fs-window__shot img {
    min-height: 390px;
  }

  .fs-proof__card {
    grid-template-columns: minmax(0, .78fr) minmax(0, 1.22fr);
    align-items: stretch;
  }

  .fs-proof__image {
    border-top: 0;
    border-inline-start: 1px solid color-mix(in srgb, var(--on-brand) 11%, transparent);
  }

  .fs-faq__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
  }

  .fs-faq details:last-child:nth-child(odd) {
    grid-column: 1 / -1;
  }
}

@media (min-width: 980px) {
  .fs-hero__grid {
    grid-template-columns: minmax(0, .92fr) minmax(420px, 1.08fr);
    align-items: center;
  }

  .fs-title {
    font-size: clamp(58px, 6.2vw, 82px);
  }

  .fs-cta__grid {
    grid-template-columns: minmax(0, .82fr) minmax(390px, 1.18fr);
    align-items: start;
  }

  .fs-form {
    padding: 28px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .fs-page *,
  .fs-page *::before,
  .fs-page *::after {
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
  }
}
