/* Product storytelling for the homepage below its existing hero and the
   Retakes feature. These styles do not change the hero or other articles. */

.product-heading { max-width: 1000px; }
.product-heading h2,
.feature-detail-heading h2 {
  font-size: clamp(42px, 5.4vw, 80px);
  font-weight: 450;
  line-height: 1.04;
  letter-spacing: -.055em;
  text-wrap: balance;
}
.product-heading h2 > span,
.feature-header h1 > span,
.feature-detail-heading h2 > span { color: var(--muted); }
.product-heading > p:not(.product-kicker) {
  max-width: 540px;
  margin-top: 26px;
  padding: 0;
  font-size: 19px;
  line-height: 1.65;
  color: var(--muted);
  text-wrap: pretty;
}
.product-kicker { margin-bottom: 20px; color: var(--accent-text); font-size: 14px; line-height: 1.5; font-weight: 500; }
.retake-spotlight { padding-block: 96px 136px; }
.retake-spotlight .product-heading { margin-bottom: 48px; }
.product-section-link { display: flex; justify-content: flex-end; padding-top: 26px; }
.product-section-link .text-link { font-size: 16px; }

/* A native capture and an explanation, never a simulated app interface. */
.retake-story {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: center;
  overflow: hidden;
  border-radius: 24px;
  background: var(--surface);
}
.retake-screen {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  align-self: stretch;
  padding: 58px 30px 28px;
  margin: 0;
  background: color-mix(in srgb, var(--surface) 60%, var(--paper));
}
.product-phone {
  width: min(100%, 310px);
  border: 5px solid #242328;
  border-radius: 44px;
  background: #17171b;
  overflow: hidden;
  box-shadow: 0 28px 42px -24px rgb(10 8 19 / .4);
}
.product-phone img { display: block; width: 100%; height: auto; }
.retake-screen figcaption { margin-top: 25px; color: var(--muted); font-size: 12px; line-height: 1.5; text-align: center; }
.retake-walkthrough { min-width: 0; padding: 50px clamp(28px, 4.5vw, 68px); }
.retake-steps { list-style: none; margin: 0; padding: 0; counter-reset: retake-step; }
.retake-steps > li { counter-increment: retake-step; padding: 25px 0; border-top: 1px solid var(--line); }
.retake-steps > li:first-child { border-top: 0; }
.retake-steps h3 { display: flex; align-items: baseline; gap: 18px; font-size: clamp(23px, 2.1vw, 30px); line-height: 1.2; letter-spacing: -.025em; font-weight: 450; }
.retake-steps h3::before { content: "0" counter(retake-step); flex: 0 0 20px; color: var(--accent-text); font-size: 12px; font-weight: 500; letter-spacing: 0; }
.retake-steps h3 button { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; width: 100%; padding: 2px 0; color: var(--muted); text-align: left; font: inherit; letter-spacing: inherit; transition: color .2s ease; }
.retake-steps h3 button::after { content: ""; width: 8px; height: 8px; margin: 0 3px 4px; flex-shrink: 0; border: solid currentColor; border-width: 0 1.5px 1.5px 0; transform: rotate(45deg); }
.retake-steps h3 button[aria-expanded="true"]::after { transform: rotate(225deg); margin-bottom: 0; }
.retake-steps h3 button:hover,
.retake-steps h3 button[aria-expanded="true"] { color: var(--ink); }
.retake-steps p { margin: 18px 0 0 38px; color: var(--muted); font-size: 16px; line-height: 1.7; text-wrap: pretty; }
.is-interactive .retake-steps { min-height: 322px; }
.has-interacted .retake-steps .is-current [data-retake-detail] { animation: product-enter .45s cubic-bezier(.22, 1, .36, 1) both; }
.retake-diagram { margin: 28px 0 0; }
.retake-track { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 8px; }
.retake-track > div { display: flex; flex-direction: column; justify-content: space-between; gap: 16px; padding: 15px 16px; border-radius: 6px; font-size: 12px; line-height: 1.4; }
.retake-kept { color: var(--ink); background: color-mix(in srgb, var(--lime) 18%, var(--paper)); }
.retake-last { border: 1px solid var(--line); background: var(--paper); color: var(--muted); transition: transform .5s cubic-bezier(.22, 1, .36, 1), background .35s, border-color .35s; }
.retake-track-line { height: 3px; width: 100%; background: currentColor; opacity: .3; border-radius: 3px; transform-origin: left; transition: transform .55s cubic-bezier(.22, 1, .36, 1), opacity .35s; }
[data-retake-phase="1"] .retake-last { transform: translateY(5px); border-style: dashed; background: transparent; }
[data-retake-phase="1"] .retake-last .retake-track-line { transform: scaleX(0); opacity: 0; }
[data-retake-phase="2"] .retake-last { background: var(--lime); color: #0a0813; border-color: var(--lime); }
.retake-diagram figcaption { min-height: 58px; margin-top: 15px; color: var(--muted); font-size: 12px; line-height: 1.6; }
.retake-boundary { padding-top: 19px; border-top: 1px solid var(--line); color: var(--muted); font-size: 12px; line-height: 1.7; }

/* Feature pages can introduce the product at full width, then return to the
   established reading column for instructions, evidence and qualifications. */
.feature-page { padding-top: 28px; }
.feature-header { display: block; max-width: 1000px; margin: 0; padding: 0 0 62px; }
.feature-header .breadcrumb { margin-bottom: 60px; }
.feature-header .product-kicker { margin-bottom: 20px; }
.feature-header h1 { font-size: clamp(48px, 7.1vw, 104px); line-height: 1.02; letter-spacing: -.06em; font-weight: 450; text-wrap: balance; }
.feature-header .article-lede { max-width: 580px; font-size: 21px; }
.feature-header-links { display: flex; flex-wrap: wrap; gap: 18px 32px; margin-top: 28px; }
.feature-header-links .text-link { font-size: 15px; }
.feature-header .article-meta { border-top: 0; padding-top: 0; margin-top: 32px; }
.feature-demonstration { scroll-margin-top: 30px; }
.feature-section-title { margin: 0 0 25px; font-size: clamp(25px, 2.5vw, 36px); line-height: 1.2; font-weight: 450; letter-spacing: -.035em; }
.feature-detail-heading { margin: 112px 0 58px; }
.feature-detail-heading h2 { font-size: clamp(38px, 4.7vw, 64px); }
.feature-page .article-layout { border-top: 1px solid var(--line); padding-top: 48px; }

/* The homepage's existing interactions keep their behavior; the hierarchy
   and presentation now give each chapter more room. */
.home-story .studio-section { padding-top: 0; padding-bottom: 130px; }
.home-story .studio-tabs { gap: 26px; margin-top: 44px; }
.home-story .studio-tabs button { position: relative; border-radius: 0; background: transparent; padding: 20px 8px; color: var(--muted); }
.home-story .studio-tabs button::after { content: ""; position: absolute; inset: auto 0 -1px; height: 3px; background: var(--accent-text); transform: scaleX(0); transform-origin: left; transition: transform .4s cubic-bezier(.22, 1, .36, 1); }
.home-story .studio-tabs button[aria-selected="true"] { color: var(--ink); }
.home-story .studio-tabs button[aria-selected="true"]::after { transform: scaleX(1); }
.home-story .studio-tabs button[aria-selected="true"] > span { color: var(--accent-text); }
.home-story .studio-panel { grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); border-bottom: 0; }
.home-story .has-interacted .studio-panel.is-active { animation: product-enter .55s cubic-bezier(.22, 1, .36, 1) both; }
.home-story .studio-copy { padding-right: 60px; }
.home-story .studio-copy h3 { font-size: clamp(30px, 3.2vw, 44px); line-height: 1.12; max-width: 12ch; letter-spacing: -.04em; text-wrap: balance; }
.home-story .studio-copy p { max-width: 400px; }
.home-story .studio-copy small { max-width: 400px; font-size: 12px; }
.home-story .studio-copy li { align-items: flex-start; }
.home-story .studio-display { border-radius: 20px; }
.home-story .captions-section { padding-top: 0; padding-bottom: 128px; }
.home-story .caption-photo { border-radius: 20px; }
.home-story .captions-layout { grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: clamp(40px, 7vw, 100px); align-items: center; }
.home-story .caption-count > span { font-size: clamp(100px, 9vw, 150px); }
.home-story .native-section { padding-block: 94px 100px; }
.home-story .native-features article { padding-block: 30px; }
.home-story .native-features p { font-size: 16px; line-height: 1.7; }
.home-story .native-features h3 { font-size: 25px; line-height: 1.2; }
.home-story .compatibility { max-width: 740px; margin-inline: auto; font-size: 12px; }
.home-story .explore-section { padding-block: 100px; }
.home-story .explore-heading > p { max-width: 540px; }
.explore-paths { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 30px; margin-top: 48px; }
.explore-paths > a { display: flex; flex-direction: column; padding: 30px 0 32px; border-top: 1px solid var(--line); }
.explore-paths > a > span:first-child { color: var(--muted); font-size: 13px; line-height: 1.5; }
.explore-paths strong { display: block; margin: 21px 0 28px; max-width: 17ch; font-size: clamp(24px, 2.4vw, 34px); font-weight: 450; line-height: 1.2; letter-spacing: -.035em; text-wrap: balance; }
.explore-path-link { display: flex; align-items: center; gap: 12px; margin-top: auto; font-size: 14px; }
.explore-path-link svg { color: var(--accent-text); flex-shrink: 0; transition: transform .25s ease; }
@media (hover: hover) {
  .explore-paths > a:hover .explore-path-link svg { transform: translate(3px, -3px); }
}
.home-story .explore-grid { gap: 40px; padding-top: 40px; margin-top: 25px; border-top: 1px solid var(--line); }
.home-story .explore-card { padding: 0; background: none; border-radius: 0; }
.home-story .explore-card h3 { font-size: 22px; }
.home-story .explore-card li a { border-bottom: 0; font-size: 13px; }
.home-story .explore-card ul { border-top: 0; margin-top: 12px; }
.home-story .origin-section { padding-block: 75px 90px; border-block: 1px solid var(--line); }
.home-story .origin-story .text-link { margin-top: 24px; font-size: 14px; text-decoration: none; }

@keyframes product-enter {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 1000px) {
  .retake-walkthrough { padding: 30px; }
  .retake-screen { padding: 40px 24px 25px; }
  .product-phone { width: min(100%, 270px); border-radius: 38px; }
  .retake-steps h3 { font-size: 24px; gap: 12px; }
  .retake-steps p { font-size: 15px; margin-left: 32px; }
  .retake-steps > li { padding-block: 21px; }
  .retake-track > div { padding: 12px; }
  .feature-header .article-lede { font-size: 19px; }
  .home-story .studio-copy { padding-right: 30px; }
  .home-story .studio-copy small { font-size: 11px; }
  .home-story .captions-layout { gap: 36px; }
  .home-story .caption-count > span { font-size: 100px; }
  .home-story .native-features article { grid-template-columns: 28px minmax(160px, .8fr) 1fr; gap: 20px; }
  .home-story .native-features p { font-size: 15px; }
  .home-story .native-features h3 { font-size: 23px; }
  .home-story .explore-grid { gap: 32px; }
}

@media (max-width: 700px) {
  .product-heading h2 { font-size: clamp(37px, 9.7vw, 58px); letter-spacing: -.05em; }
  .product-heading > p:not(.product-kicker) { font-size: 17px; margin-top: 22px; }
  .product-kicker { font-size: 12px; margin-bottom: 16px; }
  .retake-spotlight { padding-block: 54px 80px; }
  .retake-spotlight .product-heading { margin-bottom: 30px; }
  .retake-story { grid-template-columns: minmax(0, 1fr); border-radius: 18px; }
  .retake-screen { padding: 36px 28px 22px; }
  .product-phone { width: min(100%, 235px); border-width: 4px; border-radius: 33px; }
  .retake-screen figcaption { font-size: 11px; margin-top: 20px; }
  .retake-walkthrough { padding: 8px 24px 28px; }
  .retake-steps h3 { font-size: 23px; }
  .retake-steps h3 button { min-height: 44px; align-items: center; }
  .retake-steps > li { padding-block: 16px; }
  .retake-steps p { margin-top: 12px; font-size: 15px; }
  .is-interactive .retake-steps { min-height: 315px; }
  .retake-diagram { margin-top: 12px; }
  .retake-diagram figcaption { min-height: 60px; }
  .product-section-link { justify-content: flex-start; padding-top: 24px; }
  .product-section-link .text-link { font-size: 14px; }
  .feature-page { padding-top: 12px; }
  .feature-header { padding-bottom: 42px; }
  .feature-header .breadcrumb { margin-bottom: 32px; }
  .feature-header h1 { font-size: clamp(45px, 12vw, 76px); letter-spacing: -.055em; }
  .feature-header .article-lede { font-size: 18px; margin-top: 24px; }
  .feature-header-links { gap: 16px; margin-top: 24px; }
  .feature-header-links .text-link { font-size: 14px; }
  .feature-section-title { font-size: 26px; margin-bottom: 20px; }
  .feature-detail-heading { margin: 68px 0 32px; }
  .feature-detail-heading h2 { font-size: 37px; }
  .feature-page .article-layout { padding-top: 28px; }
  .home-story .studio-section { padding-bottom: 80px; }
  .home-story .studio-tabs { gap: 12px; margin-top: 28px; }
  .home-story .studio-tabs button { padding: 16px 2px; gap: 8px; }
  .home-story .studio-copy { padding: 30px 0; min-height: 0; }
  .home-story .studio-copy h3 { max-width: 16ch; font-size: 34px; }
  .home-story .studio-copy p { font-size: 16px; }
  .home-story .studio-copy small { font-size: 12px; }
  .home-story .studio-display { height: 520px; margin-bottom: 0; border-radius: 18px; }
  .home-story .studio-display .screen-phone { width: 195px; }
  .home-story .captions-section { padding-bottom: 80px; }
  .home-story .captions-layout { gap: 38px; }
  .home-story .caption-count > span { font-size: 110px; }
  .home-story .native-section { padding-block: 65px; }
  .home-story .native-features article { grid-template-columns: 26px minmax(0, 1fr); column-gap: 16px; row-gap: 12px; }
  .home-story .native-features p { grid-column: 2; }
  .home-story .native-features h3 { font-size: 23px; }
  .home-story .native-features article > a { margin-top: 0; }
  .home-story .explore-section { padding-block: 65px; }
  .explore-paths { grid-template-columns: minmax(0, 1fr); gap: 0; margin-top: 30px; }
  .explore-paths > a { padding-block: 25px; }
  .explore-paths strong { font-size: 29px; max-width: 22ch; margin-block: 16px 20px; }
  .home-story .explore-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 30px 24px; }
  .home-story .explore-card h3 { font-size: 21px; }
  .home-story .explore-card > p { font-size: 13px; }
  .home-story .origin-section { padding-block: 55px; }
}

@media (prefers-reduced-motion: reduce) {
  .has-interacted .retake-steps .is-current [data-retake-detail],
  .home-story .has-interacted .studio-panel.is-active { animation: none; }
  .retake-last, .retake-track-line,
  .home-story .studio-tabs button::after { transition: none; transform: none; }
  .explore-paths > a:hover .explore-path-link svg { transform: none; }
}
