/**
 * Main Styles - CCN Landing Page
 */

/* ==========================================================================
   Reset & Base
   ========================================================================== */

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-family);
  font-size: var(--font-size-base);
  line-height: var(--line-height);
  color: var(--text-primary);
  background: var(--background);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: var(--primary-text);
  text-decoration: none;
  transition: color var(--transition-fast);
}

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

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

ul, ol {
  list-style: none;
}

/* ==========================================================================
   Container
   ========================================================================== */

.container {
  width: 100%;
  max-width: var(--container-xl);
  margin: 0 auto;
  padding: 0 var(--spacing-md);
}

/* ==========================================================================
   Navigation
   ========================================================================== */

.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: var(--nav-bg);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  z-index: var(--z-fixed);
  transition: box-shadow var(--transition-base);
}

.nav.scrolled {
  box-shadow: var(--shadow-md);
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--nav-gap);
  /* the bar's 1px border is inside --nav-h, which the home blocks subtract */
  height: calc(var(--nav-h) - 1px);
  max-width: var(--container-xl);
  margin: 0 auto;
  padding: 0 var(--spacing-md);
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  min-height: 36px;
  font-weight: 600;
  font-size: calc(var(--nav-font) + 3px);
  color: var(--text-primary);
}

.nav-logo img {
  width: var(--nav-logo);
  height: var(--nav-logo);
}

.nav-logo:hover {
  color: var(--text-primary);
}

/* "for AWS" edition tag on the brand wordmark */
.logo-edition {
  display: inline-block;
  font-size: 0.55em;
  font-weight: 700;
  color: var(--accent-text);
  background: var(--primary-light);
  padding: 1px 6px;
  border-radius: 6px;
  margin-left: 6px;
  vertical-align: middle;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: var(--nav-gap);
}

/* the link box stays 36 px tall as a tap target while the bar shrinks */
.nav-links a {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  color: var(--text-secondary);
  font-size: var(--nav-font);
  font-weight: 500;
  position: relative;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--primary-gradient);
  transition: width var(--transition-base);
}

.nav-links a:hover {
  color: var(--primary-text);
}

.nav-links a:hover::after {
  width: 100%;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: clamp(8px, calc(2px + 0.84vh), 16px);
}

.nav-actions .btn {
  min-height: 36px;
  padding: 0 clamp(14px, calc(4px + 1.4vh), 24px);
  font-size: var(--nav-font);
}

.lang-selector {
  min-height: 36px;
  padding: var(--spacing-xs) var(--spacing-sm);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--card-bg);
  color: var(--text-secondary);
  font-size: var(--nav-font);
  cursor: pointer;
  transition: border-color var(--transition-fast);
}

/* Appearance toggle next to the language selector (same icons and cycle as the extension) */
.theme-toggle {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--card-bg);
  color: var(--text-secondary);
  line-height: 1;
  cursor: pointer;
  transition: border-color var(--transition-fast), color var(--transition-fast);
}
.theme-toggle svg { width: 18px; height: 18px; display: block; }
.theme-toggle:hover { border-color: var(--primary-text); color: var(--text-primary); }
.theme-toggle:focus-visible { outline: none; box-shadow: 0 0 0 3px var(--focus-ring); }
.theme-toggle[data-mode="manual"] { border-color: var(--primary-text); }
html { background: var(--background); }
body { transition: background-color var(--transition-base), color var(--transition-base); }

.lang-selector:hover {
  border-color: var(--primary-text);
}

.lang-selector:focus {
  outline: none;
  border-color: var(--primary-text);
  box-shadow: 0 0 0 3px var(--focus-ring);
}

/* Mobile menu toggle */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  min-width: 40px;
  min-height: 40px;
  padding: var(--spacing-sm);
  background: none;
  border: none;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text-primary);
}

/* ==========================================================================
   Buttons
   ========================================================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-sm);
  padding: var(--spacing-sm) var(--spacing-lg);
  font-family: inherit;
  font-size: var(--font-size-sm);
  font-weight: 600;
  text-decoration: none;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: color var(--transition-base), background-color var(--transition-base), border-color var(--transition-base), box-shadow var(--transition-base), transform var(--transition-base), opacity var(--transition-base);
}

.btn-primary {
  background: var(--primary-gradient);
  color: var(--on-brand); /* dark text on the orange gradient: ≥ 6:1 in both themes */
  box-shadow: 0 2px 4px color-mix(in srgb, var(--ccn-brand) 30%, transparent);
}

.btn-primary:hover {
  box-shadow: 0 4px 12px color-mix(in srgb, var(--ccn-brand) 40%, transparent);
  color: var(--on-brand);
}

.btn-secondary {
  background: var(--card-bg);
  color: var(--primary-text);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  border-color: var(--primary-text);
  background: var(--background);
}

.btn-lg {
  padding: var(--spacing-md) var(--spacing-xl);
  font-size: var(--font-size-base);
}

.btn-icon {
  width: 20px;
  height: 20px;
}

/* ==========================================================================
   Hero Section
   ========================================================================== */

.hero {
  padding: var(--site-hero-top) 0 var(--site-section-y);
  background: linear-gradient(180deg, var(--card-bg) 0%, var(--background) 100%);
  text-align: center;
}

.hero-content {
  max-width: 800px;
  margin: 0 auto;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--spacing-xs);
  padding: var(--spacing-xs) var(--spacing-md);
  background: var(--success-light);
  color: var(--success-text);
  font-size: var(--font-size-sm);
  font-weight: 600;
  border-radius: var(--radius-full);
}

/* the small line that answers the pain points block, above the brand */
.hero-eyebrow {
  font-size: var(--font-size-sm);
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--text-secondary);
  margin-bottom: var(--spacing-sm);
}

.hero-title {
  font-size: var(--font-size-5xl);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: var(--spacing-lg);
  background: var(--primary-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* the brand as the title: it may wrap between the name and the edition, never inside a word */
.hero-brand-edition {
  display: inline-block;
  white-space: nowrap;
  font-size: 0.5em;
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1;
  vertical-align: 0.35em;
  margin-left: 0.15em;
  padding: 0.2em 0.5em 0.25em;
  border-radius: 0.4em;
  background: var(--primary-light);
  color: var(--accent-text);
  -webkit-text-fill-color: var(--accent-text);
}

/* the former headline, now under the brand */
.hero-headline {
  font-size: var(--font-size-2xl);
  font-weight: 600;
  line-height: 1.3;
  color: var(--text-primary);
  margin-bottom: var(--spacing-md);
  text-wrap: balance;
}

.hero-subtitle {
  font-size: var(--font-size-xl);
  color: var(--text-secondary);
  margin-bottom: var(--spacing-xl);
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
  text-wrap: balance;
}

/* Phrase lists (data-i18n-parts): the title and the time line break only at their phrase boundary */
.hero-title .i18n-part,
.hero-value .i18n-part {
  display: block;
  text-wrap: balance;
}

/* between block lines a <wbr> would make an empty line of its own */
.hero-title wbr,
.hero-value wbr {
  display: none;
}

/* the summary is one line per tier (free, then Prime) */
.hero-subtitle .i18n-part {
  display: block;
  text-wrap: balance;
}

.hero-subtitle wbr {
  display: none;
}

.hero-subtitle .features-category-badge {
  display: inline-block;
  vertical-align: 0.15em;
  margin-right: 0.25em;
  line-height: 1.4;
}

.hero-value {
  font-size: var(--font-size-lg);
  font-weight: 600;
  color: var(--accent-text);
  max-width: 760px;
  margin: 0 auto var(--spacing-xl);
  line-height: 1.5;
}

.hero-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-md);
}

/* the free-start badge (with the trial terms) sits right under the install button */
.hero-offer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-xs) var(--spacing-md);
}

.hero-note-asterisk {
  font-size: var(--font-size-xs);
  color: var(--text-muted);
  max-width: 600px;
  margin: var(--spacing-lg) auto 0;
  line-height: 1.4;
}

/* ==========================================================================
   Section Common
   ========================================================================== */

.section {
  padding: var(--site-section-y) 0;
}

.section-header {
  text-align: center;
  max-width: 600px;
  margin: 0 auto var(--site-header-gap);
}

.section-title {
  font-size: var(--font-size-3xl);
  font-weight: 700;
  margin-bottom: var(--site-heading-gap);
  color: var(--text-primary);
}

.section-subtitle {
  font-size: var(--font-size-lg);
  color: var(--text-secondary);
}

/* ==========================================================================
   Features Section
   ========================================================================== */

.features {
  background: var(--card-bg);
}

/* Pain Points: distinguish "problem" icons from "solution" feature icons */
.painpoints .feature-icon {
  background: var(--primary-light);
}

.painpoints .feature-icon svg {
  color: var(--accent-text);
}

.features-category {
  margin-bottom: var(--site-header-gap);
}

.features-category:last-child {
  margin-bottom: 0;
}

.features-category-header {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-xl);
}

.features-category-title {
  font-size: var(--font-size-xl);
  font-weight: 600;
}

.features-category-badge {
  padding: var(--spacing-xs) var(--spacing-sm);
  font-size: var(--font-size-xs);
  font-weight: 600;
  text-transform: uppercase;
  border-radius: var(--radius-sm);
}

.badge-free {
  background: var(--success-light);
  color: var(--success-text);
}

.badge-prime {
  background: var(--accent-gradient);
  color: var(--on-brand);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: var(--spacing-lg);
}

/* Pain points: fixed 2×2 grid, centered */
.painpoints .features-grid {
  grid-template-columns: repeat(2, 1fr);
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
}

.feature-card {
  padding: var(--spacing-lg);
  background: var(--background);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  transition: color var(--transition-base), background-color var(--transition-base), border-color var(--transition-base), box-shadow var(--transition-base), transform var(--transition-base), opacity var(--transition-base);
}

.feature-card:hover {
  border-color: var(--primary-text);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.feature-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--primary-gradient);
  border-radius: var(--radius-md);
  margin-bottom: var(--spacing-md);
}

.feature-icon svg {
  width: 24px;
  height: 24px;
  color: var(--text-inverse);
}

.feature-title {
  font-size: var(--font-size-lg);
  font-weight: 600;
  margin-bottom: var(--spacing-sm);
}

.feature-desc {
  color: var(--text-secondary);
  font-size: var(--font-size-sm);
}

/* the invitation note: the inviter's bonus, then the friend's on a line of its own */
.invite-note-lines .i18n-part {
  display: block;
  text-wrap: balance;
}

.invite-note-lines wbr {
  display: none;
}

/* one key group per line (Vim Mode card) */
.feature-desc-lines .i18n-part {
  display: block;
}

.feature-desc-lines wbr {
  display: none;
}

/* ==========================================================================
   Pricing Section
   ========================================================================== */

.pricing {
  background: var(--background);
}

/* the block opens with the trial sentence itself (no subtitle), so it gets a wider measure, balanced wraps and
   one step less than the section-title scale; otherwise the sentence would read as body copy on a phone */
#pricing .section-header {
  max-width: 900px;
}

#pricing .section-title {
  font-size: clamp(20px, calc(10px + 1.9vw), 30px);
  line-height: 1.3;
  text-wrap: balance;
  margin-bottom: 0;
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--spacing-lg);
  max-width: 960px;
  margin: 0 auto;
}

.pricing-grid-4 {
  grid-template-columns: repeat(4, 1fr);
}

.pricing-grid-3 {
  grid-template-columns: repeat(3, 1fr);
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

.pricing-card {
  background: var(--card-bg);
  border-radius: var(--radius-xl);
  border: 1px solid var(--border);
  padding: var(--spacing-lg);
  text-align: center;
  position: relative;
  transition: color var(--transition-base), background-color var(--transition-base), border-color var(--transition-base), box-shadow var(--transition-base), transform var(--transition-base), opacity var(--transition-base);
  display: flex;
  flex-direction: column;
}

.pricing-card:hover {
  border-color: var(--primary-text);
  box-shadow: var(--shadow-lg);
}

.pricing-card.popular {
  border-color: var(--primary-text);
  box-shadow: var(--shadow-lg);
}

.pricing-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  padding: var(--spacing-xs) var(--spacing-md);
  background: var(--primary-gradient);
  color: var(--on-brand);
  font-size: var(--font-size-xs);
  font-weight: 600;
  border-radius: var(--radius-full);
  white-space: nowrap;
}

.pricing-title {
  font-size: var(--font-size-xl);
  font-weight: 600;
  margin-bottom: var(--spacing-md);
}

.pricing-price {
  margin-bottom: var(--spacing-lg);
}

.pricing-amount {
  font-size: var(--font-size-3xl);
  font-weight: 700;
  color: var(--primary-text);
}

.pricing-period {
  font-size: var(--font-size-sm);
  color: var(--text-muted);
}

/* Lifetime card while the early bird runs (js/campaign.js): list price struck, one link to the offer block */
.pricing-card.is-promo {
  cursor: pointer;
}

.pricing-card.is-promo .pricing-price {
  margin-bottom: var(--spacing-sm);
}



.pricing-promo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  align-self: center;
  min-height: 32px;
  margin: 0 0 var(--spacing-sm);
  padding: 2px 14px;
  border: 1px solid color-mix(in srgb, var(--ccn-brand) 45%, var(--border));
  border-radius: var(--radius-full);
  background: color-mix(in srgb, var(--ccn-brand) 10%, var(--card-bg));
  color: var(--primary-text);
  font-size: var(--font-size-sm);
  font-weight: 600;
  transition: background-color var(--ccn-dur-2) var(--ccn-ease-out), border-color var(--ccn-dur-2) var(--ccn-ease-out);
}

.pricing-promo[hidden] {
  display: none;
}

.pricing-promo:hover,
.pricing-card.is-promo:hover .pricing-promo {
  background: color-mix(in srgb, var(--ccn-brand) 18%, var(--card-bg));
  border-color: var(--ccn-brand);
}

.pricing-promo:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px var(--focus-ring);
}


.pricing-savings {
  display: inline-block;
  font-size: var(--font-size-xs);
  font-weight: 600;
  color: var(--accent-text);
  background: var(--primary-light);
  padding: 4px 12px;
  border-radius: 12px;
  margin-bottom: var(--spacing-sm);
  white-space: pre-line;
  text-align: center;
  line-height: 1.4;
}

.pricing-desc {
  font-size: var(--font-size-sm);
  color: var(--text-secondary);
  margin-bottom: var(--spacing-md);
  flex-grow: 1;
}

.pricing-features {
  margin-bottom: var(--spacing-xl);
  text-align: left;
}

.pricing-features li {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  padding: var(--spacing-sm) 0;
  color: var(--text-secondary);
  font-size: var(--font-size-sm);
}

.pricing-features li svg {
  width: 16px;
  height: 16px;
  color: var(--success-text);
  flex-shrink: 0;
}

.pricing-card .btn {
  width: 100%;
}

/* ==========================================================================
   Download Section
   ========================================================================== */

.download {
  background: var(--card-bg);
}

/* cards keep their own height (no stretch), so the visitor's card is visibly taller as well as wider */
.download-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: var(--spacing-md);
}

/* the other browsers: compact and secondary */
.download-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: var(--background);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  color: var(--text-primary);
  font-weight: 500;
  transition: color var(--transition-base), background-color var(--transition-base), border-color var(--transition-base), box-shadow var(--transition-base), opacity var(--transition-base);
}

.download-btn:hover {
  border-color: var(--primary-text);
  background: var(--card-bg);
  box-shadow: var(--shadow-md);
  color: var(--text-primary);
}

.download-btn.coming-soon {
  opacity: 0.72;
  cursor: not-allowed;
}

.download-btn.coming-soon:hover {
  box-shadow: none;
}

.download-btn img {
  width: 40px;
  height: 40px;
  flex: none;
}

.download-btn-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.download-btn-label {
  font-size: 12px;
  color: var(--text-muted);
}

.download-btn-store {
  font-size: 15px;
  font-weight: 600;
  white-space: nowrap;
}

/* "Your browser" tag: only on the visitor's card */
.download-btn-yours {
  display: none;
}

/* the visitor's browser: first, about 1.5 times the others, filled like the primary button */
.download-btn.is-yours {
  opacity: 1;
  min-width: 300px;
  gap: 16px;
  padding: 18px 26px;
  border-color: transparent;
  background: var(--primary-gradient);
  color: var(--ccn-text-on-brand);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--ccn-brand) 22%, transparent), var(--shadow-md);
}

.download-btn.is-yours:hover {
  color: var(--ccn-text-on-brand);
  background: var(--primary-gradient);
}

.download-btn.is-yours img {
  width: 64px;
  height: 64px;
  padding: 6px;
  border-radius: var(--radius-full);
  background: var(--ccn-gray-0);
}

.download-btn.is-yours .download-btn-yours {
  display: inline-block;
  margin-bottom: 4px;
  padding: 1px 8px;
  border-radius: var(--radius-full);
  background: color-mix(in srgb, var(--ccn-text-on-brand) 14%, transparent);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.download-btn.is-yours .download-btn-label {
  font-size: 14px;
  color: inherit;
  opacity: 0.85;
}

.download-btn.is-yours .download-btn-store {
  font-size: 22px;
  font-weight: 700;
}

/* narrow desktops: a smaller base keeps four cards on one row clear of the section dots */
@media (min-width: 769px) and (max-width: 1199px) {
  .download-grid {
    gap: 12px;
  }

  .download-btn {
    padding: 8px 12px;
    gap: 8px;
  }

  .download-btn img {
    width: 36px;
    height: 36px;
  }

  .download-btn-store {
    font-size: 14px;
  }

  .download-btn.is-yours {
    min-width: 270px;
    padding: 16px 22px;
    gap: 14px;
  }

  .download-btn.is-yours img {
    width: 56px;
    height: 56px;
  }

  .download-btn.is-yours .download-btn-store {
    font-size: 20px;
  }
}

.download-note {
  margin: var(--spacing-md) auto 0;
  max-width: 640px;
  text-align: center;
  font-size: var(--font-size-sm);
  color: var(--text-secondary);
}

/* ==========================================================================
   FAQ Section
   ========================================================================== */

.faq {
  background: var(--background);
}

.faq-list {
  max-width: 800px;
  margin: 0 auto;
}

.faq-item {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  margin-bottom: var(--spacing-md);
  overflow: hidden;
}

.faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: var(--spacing-lg);
  background: none;
  border: none;
  font-family: inherit;
  font-size: var(--font-size-base);
  font-weight: 600;
  color: var(--text-primary);
  text-align: left;
  cursor: pointer;
  transition: background var(--transition-fast);
}

.faq-question:hover {
  background: var(--background);
}

.faq-icon {
  width: 20px;
  height: 20px;
  color: var(--text-muted);
  transition: transform var(--transition-base);
}

.faq-item.active .faq-icon {
  transform: rotate(180deg);
}

.faq-answer {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows var(--transition-slow), padding-bottom var(--transition-slow);
}

.faq-item.active .faq-answer {
  grid-template-rows: 1fr;
  padding-bottom: var(--spacing-lg);
}

/* the padding lives on the row, not the clipped content, or a closed item still shows a padding-high slice */
.faq-answer-content {
  min-height: 0;
  overflow: hidden;
  padding: 0 var(--spacing-lg);
  color: var(--text-secondary);
  line-height: 1.7;
}

/* ==========================================================================
   Footer
   ========================================================================== */

.footer {
  background: var(--footer-bg);
  color: var(--footer-text);
  padding: var(--site-section-y) 0 var(--site-block-gap);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: var(--site-header-gap);
  margin-bottom: var(--site-header-gap);
}

.footer-brand {
  max-width: 300px;
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  font-size: var(--font-size-lg);
  font-weight: 600;
  margin-bottom: var(--spacing-md);
  color: var(--footer-text);
}

.footer-logo img {
  width: 32px;
  height: 32px;
}

.footer-desc {
  color: var(--footer-muted);
  font-size: var(--font-size-sm);
  margin-bottom: var(--spacing-md);
}

.footer-heading {
  font-size: var(--font-size-sm);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: var(--spacing-md);
  color: var(--footer-muted);
}

.footer-links a {
  display: block;
  color: var(--footer-muted);
  font-size: var(--font-size-sm);
  padding: var(--spacing-xs) 0;
  transition: color var(--transition-fast);
}

.footer-links a:hover {
  color: var(--footer-text);
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: var(--spacing-xl);
  border-top: 1px solid var(--footer-border);
}

/* under the brand line, one blank line apart and in the same size */
.footer-disclaimer {
  font-size: var(--font-size-sm);
  color: var(--footer-muted);
  margin-top: var(--spacing-md);
}

.footer-copyright {
  font-size: var(--font-size-sm);
  color: var(--footer-muted);
}

/* ==========================================================================
   Utilities
   ========================================================================== */

.text-center { text-align: center; }
.text-gradient {
  background: var(--primary-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hidden { display: none !important; }

/* Scroll to top button */
.scroll-top {
  position: fixed;
  bottom: var(--spacing-lg);
  right: var(--spacing-lg);
  width: 48px;
  height: 48px;
  background: var(--primary-gradient);
  color: var(--text-inverse);
  border: none;
  border-radius: var(--radius-full);
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transition: color var(--transition-base), background-color var(--transition-base), border-color var(--transition-base), box-shadow var(--transition-base), transform var(--transition-base), opacity var(--transition-base);
  z-index: var(--z-fixed);
  box-shadow: var(--shadow-lg);
}

.scroll-top.visible {
  opacity: 1;
  visibility: visible;
}

.scroll-top:hover {
  filter: brightness(1.05);
}

.scroll-top svg {
  width: 24px;
  height: 24px;
}

/* ==========================================================================
   Page Hero (About, Privacy pages)
   ========================================================================== */

.page-hero {
  padding: var(--site-hero-top) 0 var(--site-hero-bottom);
  background: linear-gradient(180deg, var(--card-bg) 0%, var(--background) 100%);
  text-align: center;
}

.page-hero-title {
  font-size: var(--font-size-4xl);
  font-weight: 700;
  margin-bottom: var(--site-heading-gap);
  background: var(--primary-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.page-hero-subtitle {
  font-size: var(--font-size-lg);
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto;
}

.page-hero-meta {
  font-size: var(--font-size-sm);
  color: var(--text-muted);
  margin-top: var(--spacing-md);
}

/* About page rhythm: one 32px step between blocks, 16px inside headers */
.about-section {
  padding: var(--site-section-y-compact) 0;
}

.about-section-flush {
  padding-top: 0;
}

.about-section-last {
  padding-bottom: var(--site-section-y);
}

.about-section .section-header {
  margin-bottom: var(--site-block-gap);
}

.about-section .section-title {
  margin-bottom: var(--site-heading-gap);
}

/* ==========================================================================
   Stats Grid (About page)
   ========================================================================== */

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: var(--spacing-lg);
}

.stat-card {
  text-align: center;
  padding: var(--spacing-xl);
  background: var(--card-bg);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  transition: color var(--transition-base), background-color var(--transition-base), border-color var(--transition-base), box-shadow var(--transition-base), transform var(--transition-base), opacity var(--transition-base);
}

.stat-card:hover {
  border-color: var(--primary-text);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.stat-number {
  font-size: var(--font-size-4xl);
  font-weight: 700;
  color: var(--primary-text);
  margin-bottom: var(--spacing-xs);
}

.stat-label {
  font-size: var(--font-size-sm);
  color: var(--text-secondary);
}

/* ==========================================================================
   Quick Links (About page)
   ========================================================================== */

.quick-links {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--spacing-md);
  margin: var(--spacing-2xl) 0;
}

.quick-link {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  padding: var(--spacing-md);
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  color: var(--text-primary);
  transition: color var(--transition-base), background-color var(--transition-base), border-color var(--transition-base), box-shadow var(--transition-base), transform var(--transition-base), opacity var(--transition-base);
}

.quick-link:hover {
  border-color: var(--primary-text);
  background: var(--background);
  color: var(--primary-text);
}

.quick-link svg {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

/* ==========================================================================
   Privacy Page Styles
   ========================================================================== */

.privacy-content {
  max-width: 800px;
  margin: 0 auto;
  padding: 0;
}

.privacy-section {
  scroll-margin-top: 96px;
  margin-bottom: var(--site-header-gap);
}

.privacy-section-title {
  font-size: var(--font-size-xl);
  font-weight: 600;
  margin-bottom: var(--spacing-md);
  padding-bottom: var(--spacing-sm);
  border-bottom: 2px solid var(--primary);
  display: inline-block;
}

.privacy-section p {
  color: var(--text-secondary);
  margin-bottom: var(--spacing-md);
  line-height: 1.7;
}

/* bullets hang in the margin so list text lines up with the paragraphs around it */
.privacy-section ul {
  margin-bottom: var(--spacing-md);
  padding-left: 1.1em;
  list-style: disc outside;
}

.privacy-section li::marker {
  color: var(--text-muted);
}

.privacy-section li > ul {
  margin: var(--spacing-xs) 0 0;
  list-style-type: circle;
}

.privacy-section li > ul > li {
  margin-bottom: var(--spacing-xs);
}

.privacy-section li {
  color: var(--text-secondary);
  margin-bottom: var(--spacing-sm);
  line-height: 1.7;
}

.privacy-highlight {
  background: var(--primary-light);
  border-left: 4px solid var(--primary);
  padding: var(--spacing-md) var(--spacing-lg);
  margin: var(--spacing-lg) 0;
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
}

.privacy-highlight p {
  margin-bottom: 0;
  color: var(--text-primary);
  font-weight: 500;
}

.privacy-list-check li {
  list-style: none;
  position: relative;
  padding-left: var(--spacing-lg);
}

.privacy-list-check li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--success-text);
  font-weight: 700;
}

.privacy-list-cross li::before {
  content: '✗';
  color: var(--danger);
}

/* ==========================================================================
   About Page Hero
   ========================================================================== */

.about-hero {
  padding: var(--site-hero-top) 0 var(--site-hero-bottom);
  background: linear-gradient(180deg, var(--card-bg) 0%, var(--background) 100%);
  text-align: center;
}

.about-logo {
  width: 64px;
  height: 64px;
  margin: 0 auto var(--spacing-md);
}

.about-product-name {
  font-size: var(--font-size-3xl);
  font-weight: 700;
  margin-bottom: var(--spacing-sm);
  background: var(--primary-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.about-version {
  display: inline-block;
  padding: var(--spacing-xs) var(--spacing-md);
  background: var(--primary-light);
  color: var(--primary-text);
  font-size: var(--font-size-sm);
  font-weight: 600;
  border-radius: var(--radius-full);
}

/* ==========================================================================
   Mission Section (About page)
   ========================================================================== */

.mission-section {
  padding: 0 0 var(--site-section-y-compact);
  text-align: center;
}

.mission-text {
  font-size: var(--font-size-xl);
  color: var(--text-secondary);
  max-width: 700px;
  margin: 0 auto;
  line-height: 1.8;
}

/* ==========================================================================
   License Section (About page)
   ========================================================================== */

.license-section {
  padding: var(--spacing-xl);
  background: var(--card-bg);
  border-radius: var(--radius-xl);
  border: 1px solid var(--border);
}

.license-title {
  font-size: var(--font-size-lg);
  font-weight: 600;
  margin-bottom: var(--spacing-md);
}

.license-list {
  list-style: disc;
  padding-left: var(--spacing-lg);
  color: var(--text-secondary);
  font-size: var(--font-size-sm);
  line-height: 1.7;
}

.license-list li + li {
  margin-top: var(--spacing-xs);
}

.license-list a,
.about-contact a {
  color: var(--primary-text);
  text-decoration: underline;
}

.about-contact {
  margin-top: var(--spacing-md);
  text-align: center;
  color: var(--text-secondary);
  font-size: var(--font-size-sm);
}

.license-text {
  color: var(--text-secondary);
  font-size: var(--font-size-sm);
  line-height: 1.7;
}

/* Privacy policy: grouped "Data We Collect" sub-headings (task 3.16) */
.privacy-subsection-title {
  margin: 1.25rem 0 0.4rem;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-primary);
}

/* Pricing footnotes and the "all questions" link under the home FAQ */
.pricing-notes {
  max-width: 720px;
  margin: var(--spacing-xl) auto 0;
  text-align: center;
  color: var(--text-secondary);
  font-size: var(--font-size-sm);
}

.pricing-notes p {
  margin: var(--spacing-xs) 0;
}

.pricing-notes a,
.pricing-compare a,
.faq-more a {
  color: var(--primary-text);
  text-decoration: underline;
}

/* the link under the pricing headline, straight to the limits page */
.pricing-compare {
  margin-top: var(--spacing-sm);
  font-size: var(--font-size-sm);
}

.faq-more {
  text-align: center;
  margin-top: var(--spacing-lg);
}

/* ==========================================================================
   Home page: section snapping, section dots, fade-in, feature rows
   (docs/design/ui-design-language.md §3.3; motion §4 J1)
   ========================================================================== */

/* no CSS snapping: js/home-pager.js pages one block per gesture on desktop; phones scroll normally */
html:has(body.page-home) {
  scroll-padding-top: var(--nav-h);
}

.page-home .snap-section:not(.footer) {
  min-height: calc(100vh - var(--nav-h));
  min-height: calc(100svh - var(--nav-h));
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* the first screen sits under the fixed header */
.page-home .painpoints.snap-section {
  min-height: 100vh;
  min-height: 100svh;
  padding-top: var(--site-hero-top);
}

.page-home .hero {
  padding: var(--site-section-y) 0;
}

/* the line under the pain points that leads into the hero block */
.painpoints-bridge {
  margin-top: var(--spacing-xl);
  text-align: center;
}

.painpoints-bridge a {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 var(--spacing-md);
  border-radius: var(--radius-full);
  font-size: var(--font-size-lg);
  font-weight: 600;
  color: var(--accent-text);
  text-decoration: none;
  transition: background-color var(--ccn-dur-2) var(--ccn-ease-out), color var(--ccn-dur-2) var(--ccn-ease-out);
}

.painpoints-bridge a:hover {
  background: var(--primary-light);
}

.painpoints-bridge a:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px var(--focus-ring);
}

/* J1: a section fades in once when it reaches the viewport (js/main.js adds .reveal-on unless motion is reduced) */
.reveal-on .snap-section > .container {
  transition: opacity var(--ccn-dur-5) var(--ccn-ease-out), transform var(--ccn-dur-5) var(--ccn-ease-out);
}

.reveal-on .snap-section:not(.is-revealed) > .container {
  opacity: 0;
  transform: translateY(16px);
}

@media (prefers-reduced-motion: reduce) {
  .reveal-on .snap-section:not(.is-revealed) > .container {
    opacity: 1;
    transform: none;
  }
}

/* J2: one block per gesture on desktop (js/home-pager.js): the next block slides over the current one (transform
   only, Web Animations), the covered block shrinks and dims slightly, then the page jumps under the arrived block */
.page-home {
  --home-slide-dur: 700ms;
  --home-slide-ease: cubic-bezier(0.65, 0, 0.35, 1);
  /* reduced motion: the switch still moves, briefly and plainly (no scale, shade or parallax) */
  --home-slide-dur-reduced: 200ms;
  --home-slide-ease-reduced: cubic-bezier(0.2, 0, 0, 1);
}

/* every block is a layer the incoming one can cover; the first block needs its own opaque background for that */
.pager-on .snap-section {
  position: relative;
}

.pager-on .painpoints.snap-section {
  background-color: var(--background);
}

.pager-sliding .pager-incoming,
.pager-sliding .pager-covered,
.pager-sliding .pager-moving {
  will-change: transform;
}

.pager-sliding .pager-incoming {
  z-index: 2;
  box-shadow: 0 0 32px rgb(0 0 0 / 0.2);
}

.pager-shade {
  position: fixed;
  inset: 0;
  z-index: 1;
  background: rgb(0 0 0);
  opacity: 0;
  pointer-events: none;
}

.pager-sliding .pager-shade {
  will-change: opacity;
}

/* Paged desktop (the gate of js/home-pager.js): every block owns one screen below the header. Padding, gaps and
   type follow the window through --home-u (1 % of a 16:9 frame that fits the window), so each block fits one
   screen from 1280 x 720 up; the clamp() maximums stop the growth on very large screens, where the content keeps
   --home-max and stays centred both ways. */
@media (min-width: 840px) and (min-height: 520px) {
  .page-home {
    --home-u: min(1vw, 1.778vh);
    --home-pad-y: clamp(12px, 3.2vh, 56px);
    --home-pad-x: clamp(56px, 4.5vw, 112px);
    --home-max: clamp(960px, 68vw, 1440px);
    --home-gap: clamp(8px, calc(0.9 * var(--home-u)), 20px);
    --home-title: clamp(22px, calc(2.1 * var(--home-u)), 40px);
    --home-subtitle: clamp(14px, calc(1.15 * var(--home-u)), 20px);
    --home-card-title: clamp(14px, calc(1.1 * var(--home-u)), 20px);
    --home-card-text: clamp(13px, calc(1 * var(--home-u)), 17px);
    --site-hero-top: calc(var(--nav-h) + var(--home-pad-y));
    --site-section-y: var(--home-pad-y);
    --site-section-y-compact: var(--home-pad-y);
    --site-header-gap: clamp(12px, calc(1.9 * var(--home-u)), 40px);
    --site-block-gap: var(--home-gap);
  }

  .page-home .snap-section:not(.footer):not(.painpoints) {
    padding-top: var(--home-pad-y);
    padding-bottom: var(--home-pad-y);
  }

  .page-home .painpoints.snap-section {
    padding-bottom: var(--home-pad-y);
  }

  body.page-home .snap-section > .container {
    max-width: calc(var(--home-max) + 2 * var(--home-pad-x));
    padding-left: var(--home-pad-x);
    padding-right: var(--home-pad-x);
  }

  .page-home .section-header {
    max-width: clamp(600px, calc(56 * var(--home-u)), 960px);
  }

  .page-home .section-title {
    font-size: var(--home-title);
  }

  .page-home .section-subtitle {
    font-size: var(--home-subtitle);
  }

  /* pain points: the 2 x 2 cards share the first screen with the header */
  .page-home .painpoints .features-grid {
    max-width: clamp(720px, calc(64 * var(--home-u)), 1080px);
    gap: calc(1.6 * var(--home-gap));
  }

  .page-home .painpoints .feature-card {
    padding: clamp(12px, calc(1.8 * var(--home-u)), 32px);
  }

  .page-home .painpoints .feature-icon {
    width: clamp(36px, calc(3.6 * var(--home-u)), 56px);
    height: clamp(36px, calc(3.6 * var(--home-u)), 56px);
    margin-bottom: clamp(8px, calc(1.2 * var(--home-u)), 20px);
  }

  .page-home .painpoints .feature-icon svg {
    width: 50%;
    height: 50%;
  }

  .page-home .painpoints .feature-title {
    font-size: clamp(16px, calc(1.35 * var(--home-u)), 22px);
  }

  .page-home .painpoints .feature-desc {
    font-size: var(--home-card-text);
  }

  .page-home .painpoints-bridge {
    margin-top: clamp(8px, calc(1.6 * var(--home-u)), 28px);
  }

  .page-home .painpoints-bridge a {
    font-size: clamp(14px, calc(1.25 * var(--home-u)), 21px);
  }

  /* hero */
  .page-home .hero-content {
    max-width: clamp(800px, calc(64 * var(--home-u)), 1120px);
  }

  .page-home .hero-badge {
    font-size: clamp(13px, calc(1 * var(--home-u)), 16px);
  }

  .page-home .hero-eyebrow {
    font-size: clamp(13px, calc(1.1 * var(--home-u)), 18px);
    margin-bottom: clamp(6px, calc(0.9 * var(--home-u)), 16px);
  }

  .page-home .hero-title {
    font-size: clamp(34px, calc(4.2 * var(--home-u)), 68px);
    margin-bottom: clamp(6px, calc(1 * var(--home-u)), 18px);
  }

  .page-home .hero-headline {
    font-size: clamp(18px, calc(1.9 * var(--home-u)), 32px);
    margin-bottom: clamp(10px, calc(1.9 * var(--home-u)), 32px);
  }

  .page-home .hero-subtitle {
    max-width: none;
    font-size: clamp(16px, calc(1.5 * var(--home-u)), 24px);
    margin-bottom: clamp(12px, calc(2.4 * var(--home-u)), 40px);
  }

  .page-home .hero-value {
    font-size: clamp(15px, calc(1.35 * var(--home-u)), 21px);
    margin-bottom: clamp(12px, calc(2.4 * var(--home-u)), 40px);
  }

  .page-home .hero-actions {
    margin-bottom: clamp(8px, calc(1.2 * var(--home-u)), 20px);
  }

  .page-home .hero-note-asterisk {
    margin-top: clamp(10px, calc(2 * var(--home-u)), 36px);
  }

  .page-home .hero-actions .btn-lg {
    font-size: clamp(15px, calc(1.2 * var(--home-u)), 19px);
    padding: clamp(10px, calc(1.1 * var(--home-u)), 18px) clamp(24px, calc(2.4 * var(--home-u)), 40px);
  }

  .page-home .hero-note-asterisk {
    font-size: clamp(13px, calc(1 * var(--home-u)), 16px);
  }

  /* pricing: the three plans stay on one row */
  .page-home .pricing-grid-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  /* the early-bird tag stays on one line beside the lifetime price, so that column gets a little more room */
  .page-home .pricing-grid-3:has(.pricing-card-lifetime.is-promo) {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.2fr);
  }

  .page-home .pricing-grid {
    max-width: clamp(900px, calc(70 * var(--home-u)), 1200px);
    gap: calc(1.6 * var(--home-gap));
  }

  .page-home .pricing-card {
    padding: clamp(16px, calc(1.9 * var(--home-u)), 32px);
  }

  .page-home .pricing-title {
    font-size: clamp(17px, calc(1.5 * var(--home-u)), 24px);
  }

  .page-home .pricing-amount {
    font-size: clamp(26px, calc(2.5 * var(--home-u)), 40px);
  }

  .page-home .pricing-desc,
  .page-home .pricing-period,
  .page-home .pricing-notes {
    font-size: var(--home-card-text);
  }

  .page-home .pricing-notes {
    max-width: clamp(800px, calc(70 * var(--home-u)), 1100px);
  }

  /* download: the early-bird card and the store cards */
  .page-home .campaign-compact .campaign-card {
    max-width: clamp(880px, calc(68 * var(--home-u)), 1120px);
  }

  .page-home .campaign-compact .campaign-lead,
  .page-home .download-note {
    font-size: var(--home-card-text);
  }

  /* the four store cards keep one row */
  .page-home .download-grid {
    flex-wrap: nowrap;
  }

  /* the ten home questions in two columns so the block fits one screen; an open answer grows its row */
  .page-home .faq .section-header {
    margin-bottom: var(--site-block-gap);
  }

  .page-home .faq-list {
    max-width: clamp(1040px, calc(80 * var(--home-u)), 1360px);
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--spacing-sm) var(--spacing-md);
    align-items: start;
  }

  .page-home .faq-item {
    margin-bottom: 0;
  }

  .page-home .faq-question {
    padding: clamp(10px, calc(1.1 * var(--home-u)), 18px) var(--spacing-md) clamp(10px, calc(1.1 * var(--home-u)), 18px) 20px;
    gap: var(--spacing-sm);
    font-size: clamp(14px, calc(1.15 * var(--home-u)), 18px);
  }

  .page-home .faq-icon {
    flex: none;
  }

  .page-home .faq-answer-content {
    padding: 0 20px;
    font-size: var(--home-card-text);
  }

  .page-home .faq-more {
    margin-top: var(--site-block-gap);
  }
}

/* the smallest paged windows (a 1342 px window at 150 % scaling is about 895 CSS px): the store cards shrink one
   more step so the four stay on one row and the early-bird + download block fits one screen */
@media (min-width: 840px) and (max-width: 999px) and (min-height: 520px) {
  .page-home .download-grid {
    gap: 8px;
  }

  .page-home .download-btn {
    padding: 6px 10px;
  }

  .page-home .download-btn.is-yours {
    min-width: 0;
    padding: 12px 16px;
    gap: 10px;
  }

  .page-home .download-btn.is-yours img {
    width: 52px;
    height: 52px;
  }

  .page-home .download-btn.is-yours .download-btn-store {
    font-size: 18px;
  }
}

/* Section dots: fixed on the right, one button per section; hidden on narrow screens */
.section-dots {
  position: fixed;
  right: var(--spacing-md);
  top: 50%;
  transform: translateY(-50%);
  z-index: var(--z-sticky);
}

.section-dots ul {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-xs);
}

.section-dot {
  position: relative;
  display: block;
  width: 24px;
  height: 24px;
  padding: 0;
  border: 0;
  border-radius: var(--radius-full);
  background: none;
  cursor: pointer;
}

.section-dot::before {
  content: "";
  position: absolute;
  inset: 7px;
  border-radius: var(--radius-full);
  background: var(--border-hover);
  transition: background-color var(--ccn-dur-3) var(--ccn-ease-out), transform var(--ccn-dur-3) var(--ccn-ease-out);
}

.section-dot:hover::before {
  background: var(--text-secondary);
}

.section-dot.is-active::before {
  background: var(--primary);
  transform: scale(1.4);
}

.section-dot:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px var(--focus-ring);
}

/* K1: the topic label is a pill that grows out of the dot toward the page (leftward, so it never leaves the window):
   a clip-path reveal from the dot side with a short slide and fade, collapsing back the same way */
.section-dot-tip {
  position: absolute;
  right: calc(100% + 4px);
  top: 50%;
  transform: translate(8px, -50%);
  padding: 5px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  background: var(--card-bg);
  background: color-mix(in srgb, var(--card-bg) 78%, transparent);
  -webkit-backdrop-filter: blur(10px) saturate(1.4);
  backdrop-filter: blur(10px) saturate(1.4);
  box-shadow: 0 4px 16px rgb(0 0 0 / 0.16);
  color: var(--text-primary);
  font-size: var(--font-size-xs);
  font-weight: 600;
  line-height: 1.4;
  white-space: nowrap;
  opacity: 0;
  clip-path: inset(0 0 0 100% round 999px);
  pointer-events: none;
  transition: opacity var(--ccn-dur-2) var(--ccn-ease-in), transform var(--ccn-dur-2) var(--ccn-ease-in), clip-path var(--ccn-dur-2) var(--ccn-ease-in);
}

.section-dot:hover .section-dot-tip,
.section-dot:focus-visible .section-dot-tip {
  opacity: 1;
  transform: translate(0, -50%);
  clip-path: inset(0 0 0 0 round 999px);
  transition: opacity calc(var(--ccn-dur-3) + 40ms) var(--ccn-ease-out), transform calc(var(--ccn-dur-3) + 40ms) var(--ccn-ease-out), clip-path calc(var(--ccn-dur-3) + 40ms) var(--ccn-ease-out);
}

@media (prefers-reduced-motion: reduce) {
  .section-dot-tip,
  .section-dot:hover .section-dot-tip,
  .section-dot:focus-visible .section-dot-tip {
    transition: none;
  }
}

@media (max-width: 767px) {
  .section-dots {
    display: none;
  }
}

/* Feature cards, free and Prime alike: icon + title and a one- or two-line sentence anchored at the top left,
   the demo frame below */
.page-home .features .features-category-header {
  margin-bottom: var(--spacing-md);
}

.feature-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--spacing-md);
}

.feature-tile {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  gap: var(--spacing-md);
  min-width: 0;
  padding: var(--spacing-md);
  background: var(--background);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}

/* icon and title on one line, the sentence below, all from the top left */
.feature-tile-text {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  align-content: start;
  column-gap: 10px;
  row-gap: 6px;
  min-width: 0;
  text-align: left;
}

.feature-tile .feature-desc {
  grid-column: 1 / -1;
}

.feature-tile .feature-icon {
  width: 32px;
  height: 32px;
  margin: 0;
}

.feature-tile .feature-icon svg {
  width: 56%;
  height: 56%;
}

.feature-tile .feature-title {
  font-size: var(--font-size-base);
  margin: 0;
}

.feature-tile .feature-desc {
  font-size: var(--font-size-sm);
  line-height: 1.5;
  margin: 0;
}

/* the frame is a window onto a picture larger than itself: the video covers it and keeps its own centre, so every
   card ratio is filled without bars (the desktop paged layout gives the frame its height instead) */
.feature-demo {
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 3 / 2;
  width: 100%;
  min-height: 0;
  padding: var(--spacing-sm);
  border: 1px dashed var(--border-hover);
  border-radius: var(--radius-md);
  background: var(--background-alt);
}

/* the placeholder names the demo that will be recorded for this card */
.feature-demo-label {
  font-size: var(--font-size-xs);
  line-height: 1.4;
  color: var(--text-muted);
  text-align: center;
  letter-spacing: 0.02em;
}

/* a frame with a demo (js/demo-viewer.js): looping thumbnail that fills the frame, opens the viewer on click */
.feature-demo[data-demo] {
  position: relative;
  overflow: hidden;
  padding: 0;
  border-style: solid;
  border-color: var(--border);
  cursor: pointer;
  transition: border-color var(--ccn-dur-2) var(--ccn-ease-out), box-shadow var(--ccn-dur-2) var(--ccn-ease-out);
}

.feature-demo[data-demo]:hover {
  border-color: var(--ccn-brand);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--ccn-brand) 18%, transparent);
}

.feature-demo[data-demo]:focus-visible {
  outline: none;
  border-color: var(--ccn-brand);
  box-shadow: 0 0 0 3px var(--focus-ring);
}

/* before the demos are published (js/demo-viewer.js DEMOS_LIVE) the frame is the plain placeholder box again:
   dashed edge, the note centred in it, and no affordance suggesting there is something to open */
.feature-demo.is-placeholder {
  padding: var(--spacing-sm);
  border-style: dashed;
  border-color: var(--border-hover);
  cursor: default;
}

.feature-demo.is-placeholder:hover,
.feature-demo.is-placeholder:focus-visible {
  border-color: var(--border-hover);
  box-shadow: none;
}

.feature-demo-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  /* the picture is taller than the frame: pin its top so the short card still shows the bar and the menu that drops
     from it, and a taller card only reveals more below (the recording keeps its interesting part at the top) */
  object-fit: cover;
  object-position: 50% 0%;
  pointer-events: none;
}

/* the picture is never covered: js/demo-viewer.js hides the note visually once the thumbnail fills the frame, keeping
   it only as the frame's description for assistive tech */

/* the play icon shows on a still poster (reduced motion) and while the pointer is on a frame */
.feature-demo-play {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  margin: -22px 0 0 -22px;
  border-radius: 50%;
  color: var(--ccn-text-on-brand);
  background: var(--ccn-brand);
  box-shadow: var(--shadow-lg);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--ccn-dur-2) var(--ccn-ease-out);
}

.feature-demo-play svg {
  width: 20px;
  height: 20px;
  margin-left: 2px;
}

.feature-demo.is-static .feature-demo-play,
.feature-demo[data-demo]:hover .feature-demo-play,
.feature-demo[data-demo]:focus-visible .feature-demo-play {
  opacity: 1;
}

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

/* demo viewer: a full-window modal dialog; the shade dims the page, the card text sits above the enlarged video.
   The page is not set to overflow: hidden (that moves the layout by the scrollbar width): js/home-pager.js drops
   wheel gestures while locked and js/demo-viewer.js drops scroll keys; touch-action stops touch panning */
.demo-viewer {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--text-primary);
  overflow: hidden;
  overscroll-behavior: contain;
  touch-action: none;
}

.demo-viewer::backdrop {
  background: transparent;
}

.demo-viewer-shade {
  position: absolute;
  inset: 0;
  background: var(--overlay);
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
}

.demo-viewer-stage {
  --demo-w: min(80vw, 1280px, calc((100vh - 220px) * 16 / 9));
  --demo-w: min(80vw, 1280px, calc((100dvh - 220px) * 16 / 9));
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  width: 100%;
  height: 100%;
  padding: 24px 16px;
  pointer-events: none;
}

.demo-viewer-head,
.demo-viewer-frame {
  pointer-events: auto;
  will-change: transform;
}

.demo-viewer-head {
  width: var(--demo-w);
  padding: 12px 18px;
  text-align: left;
  background: var(--background);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  transform-origin: 0 0;
}

.demo-viewer-title {
  margin: 0 0 4px;
  font-size: var(--font-size-lg);
  line-height: 1.3;
}

.demo-viewer-desc {
  margin: 0;
  font-size: var(--font-size-sm);
  line-height: 1.5;
  color: var(--text-secondary);
}

.demo-viewer-frame {
  width: var(--demo-w);
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #000;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  transform-origin: 0 0;
}

.demo-viewer-video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* The full demo's subtitles are page text, not pixels: one picture serves every language, the card is drawn over
   the video and re-worded when the visitor switches language. Sizes mirror the compositor's 1920 px frame
   (--sub-u, set by js/demo-viewer.js, is the frame width over 1920). */
.demo-subs {
  position: absolute;
  left: 50%;
  bottom: calc(60 * var(--sub-u, 1) * 1px);
  width: max-content;
  max-width: 64%;
  box-sizing: border-box;
  padding: calc(14 * var(--sub-u, 1) * 1px) calc(26 * var(--sub-u, 1) * 1px);
  border: 1px solid rgb(255 255 255 / 0.22);
  border-radius: calc(16 * var(--sub-u, 1) * 1px);
  background: rgb(17 24 39 / 0.55);
  -webkit-backdrop-filter: blur(calc(18 * var(--sub-u, 1) * 1px));
  backdrop-filter: blur(calc(18 * var(--sub-u, 1) * 1px));
  box-shadow: 0 calc(12 * var(--sub-u, 1) * 1px) calc(34 * var(--sub-u, 1) * 1px) rgb(15 23 42 / 0.28);
  text-align: center;
  transform: translateX(-50%);
  opacity: 0;
  pointer-events: none;
}

.demo-subs-feature {
  color: #fff;
  font-weight: 700;
  font-size: calc(40 * var(--sub-u, 1) * 1px);
  line-height: 1.25;
  letter-spacing: 0.01em;
}

/* the action line never wraps: the viewer shrinks it down to 24/32 until it fits the card */
.demo-subs-action {
  margin-top: calc(6 * var(--sub-u, 1) * 1px);
  color: rgb(255 255 255 / 0.88);
  font-weight: 600;
  font-size: calc(32 * var(--sub-u, 1) * var(--sub-scale, 1) * 1px);
  line-height: 1.32;
  white-space: nowrap;
}

.demo-subs-action:empty { display: none; }

.demo-viewer-close {
  position: absolute;
  top: 16px;
  right: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 50%;
  color: var(--text-primary);
  background: var(--background);
  box-shadow: var(--shadow-lg);
  cursor: pointer;
  transition: border-color var(--ccn-dur-2) var(--ccn-ease-out), color var(--ccn-dur-2) var(--ccn-ease-out), box-shadow var(--ccn-dur-2) var(--ccn-ease-out);
}

.demo-viewer-close svg {
  width: 20px;
  height: 20px;
}

.demo-viewer-close:hover {
  border-color: var(--ccn-brand);
  color: var(--primary-text);
}

.demo-viewer-close:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px var(--focus-ring);
}

/* phones: the video spans the window width */
@media (max-width: 639px) {
  .demo-viewer-stage {
    --demo-w: 100%;
    padding: 72px 0 16px;
  }

  .demo-viewer-head {
    width: calc(100% - 32px);
  }

  .demo-viewer-frame {
    border-radius: 0;
  }
}

@media (min-width: 640px) {
  .feature-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Prime cards are one row each, as wide as two free cards: text in the left third, the demo frame in the right
   two thirds; phones keep the text on top and the frame below */
@media (min-width: 768px) {
  .feature-grid-prime {
    grid-template-columns: minmax(0, 1fr);
  }

  .feature-grid-prime .feature-tile {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
    align-items: start;
    column-gap: var(--spacing-lg);
  }
}

@media (max-width: 767px) {
  .page-home .features.snap-section {
    min-height: 0;
  }
}

/* paged desktop: the free and the Prime block are exactly one screen each; the six free cards in 3 rows x 2 columns
   and the three wide Prime cards in 3 rows share the same row height, and the demo frames take the room that is left */
@media (min-width: 840px) and (min-height: 520px) {
  .page-home .features.snap-section {
    height: calc(100vh - var(--nav-h));
    height: calc(100svh - var(--nav-h));
    justify-content: flex-start;
  }

  .page-home .features > .container,
  .page-home .features .features-category {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-height: 0;
    width: 100%;
  }

  .page-home .features .features-category-header {
    margin-bottom: var(--site-block-gap);
  }

  .page-home .features .features-category-title {
    font-size: clamp(18px, calc(1.7 * var(--home-u)), 30px);
  }

  .page-home .features .features-category-badge {
    font-size: clamp(11px, calc(0.85 * var(--home-u)), 14px);
  }

  .page-home .feature-grid {
    gap: var(--home-gap) calc(1.4 * var(--home-gap));
  }

  .page-home .feature-grid-free {
    flex: 1 1 auto;
    min-height: 0;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: repeat(3, minmax(0, 1fr));
  }

  .page-home .feature-grid-prime {
    flex: 1 1 auto;
    min-height: 0;
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: repeat(3, minmax(0, 1fr));
  }

  .page-home .feature-grid-prime .feature-tile {
    align-items: stretch;
    column-gap: calc(1.4 * var(--home-gap));
  }

  .page-home .feature-grid-prime .feature-tile-text {
    align-self: start;
  }

  .page-home .feature-grid-prime .feature-demo {
    aspect-ratio: auto;
    height: 100%;
    min-height: 28px;
  }

  .page-home .feature-tile {
    gap: clamp(6px, calc(0.8 * var(--home-u)), 16px);
    padding: clamp(8px, calc(1.1 * var(--home-u)), 20px) clamp(10px, calc(1.3 * var(--home-u)), 24px);
    min-height: 0;
  }

  .page-home .feature-tile .feature-icon {
    width: clamp(26px, calc(2.4 * var(--home-u)), 40px);
    height: clamp(26px, calc(2.4 * var(--home-u)), 40px);
  }

  .page-home .feature-tile-text {
    column-gap: clamp(8px, calc(0.8 * var(--home-u)), 14px);
    row-gap: clamp(4px, calc(0.5 * var(--home-u)), 10px);
  }

  .page-home .feature-tile .feature-title {
    font-size: var(--home-card-title);
  }

  .page-home .feature-tile .feature-desc {
    font-size: var(--home-card-text);
  }

  /* a free card is split in half: the icon, title and sentence on the left, the demo window on the right */
  .page-home .feature-grid-free .feature-tile {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    grid-template-rows: minmax(0, 1fr);
    align-items: stretch;
    column-gap: calc(1.4 * var(--home-gap));
  }

  .page-home .feature-grid-free .feature-tile-text {
    align-self: start;
    min-height: 0;
  }

  /* a title that wraps keeps the icon on the title's first line instead of centring it in the two-line row */
  .page-home .feature-grid-free .feature-tile-text .feature-icon {
    align-self: start;
  }

  .page-home .feature-grid-free .feature-demo {
    aspect-ratio: auto;
    height: 100%;
    min-height: 28px;
  }

  .page-home .feature-demo-label {
    font-size: clamp(11px, calc(0.85 * var(--home-u)), 14px);
  }
}

/* room for the section dots on the right wherever they show (the paged layout sets its own) */
@media (min-width: 768px) {
  .page-home .snap-section > .container {
    padding-left: 56px;
    padding-right: 56px;
  }
}

/* FAQ page: compact hero, numbered categories, formatted answers */
.page-hero-compact {
  padding: var(--site-hero-top) 0 var(--site-hero-bottom);
}

.page-hero-compact .page-hero-title {
  margin-bottom: 0;
}

/* a page section right under its page hero starts at once: the hero already ends with --site-hero-bottom */
.page-hero + .section {
  padding-top: 0;
}

.faq-category {
  margin-bottom: var(--site-header-gap);
}

.faq-category:last-child {
  margin-bottom: 0;
}

.faq-category-title {
  display: flex;
  gap: var(--spacing-sm);
  font-size: var(--font-size-xl);
  font-weight: 700;
  margin-bottom: var(--spacing-md);
  color: var(--text-primary);
}

.faq-category-num,
.faq-num {
  color: var(--primary-text);
  font-variant-numeric: tabular-nums;
}

.faq-q-label {
  display: flex;
  align-items: baseline;
  gap: var(--spacing-sm);
}

.faq-num {
  flex: none;
  min-width: 2.25em;
  font-weight: 600;
}

.faq-num:empty {
  display: none;
}

.faq-answer-content p,
.faq-answer-content ul {
  margin-bottom: var(--spacing-sm);
}

.faq-answer-content > :last-child {
  margin-bottom: 0;
}

.faq-answer-content ul {
  list-style: disc;
  padding-left: 1.25em;
}

.faq-answer-content li + li {
  margin-top: 2px;
}

/* the "we never store" list of the data-security answer: a cross instead of bullets */
.faq-answer-content[data-i18n-rich="faq.q2.answer"] ul,
#q2 .faq-answer-content ul {
  list-style: none;
  padding-left: 0;
}

.faq-answer-content[data-i18n-rich="faq.q2.answer"] li,
#q2 .faq-answer-content li {
  position: relative;
  padding-left: 1.7em;
}

.faq-answer-content[data-i18n-rich="faq.q2.answer"] li::before,
#q2 .faq-answer-content li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.2em;
  width: 1.15em;
  height: 1.15em;
  background-color: var(--text-muted);
  -webkit-mask: var(--never-icon) center / contain no-repeat;
  mask: var(--never-icon) center / contain no-repeat;
  --never-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M18 6 6 18'/%3E%3Cpath d='m6 6 12 12'/%3E%3C/svg%3E");
}

/* footer link to the offers page: only while an offer runs (js/main.js) */
[data-offers-link][hidden] {
  display: none !important;
}

/* ==========================================================================
   Home: flip cards, merged hero badge, Lifetime corner tag and the motion set (js/home-motion.js)
   Every motion here is off under prefers-reduced-motion: the JS gate (html.motion-on) is only set without it,
   and the CSS-only parts carry their own reduced-motion rule.
   ========================================================================== */

.page-home {
  --home-flip-dur: 500ms;
  --home-flip-ease: cubic-bezier(0.45, 0, 0.2, 1);
  --home-slide-parallax: 0.3;
  --home-stagger-step: 65ms;
  --home-stagger-dur: 450ms;
  --home-brand-dur: 1100ms;
  --home-count-dur: 1200ms;
}

/* J9: a pain point turns over to its CCN fix. Both faces share one grid cell, so the card is as tall as the
   taller face; only the inner layer rotates. */
.pain-card {
  perspective: 1200px;
  border-radius: var(--radius-lg);
  cursor: default;
}

.pain-card:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px var(--focus-ring);
}

.pain-card-inner {
  display: grid;
  height: 100%;
  transform-style: preserve-3d;
  transition: transform var(--home-flip-dur) var(--home-flip-ease);
}

.pain-face {
  grid-area: 1 / 1;
  position: relative;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
}

/* the front keeps the feature-card look but not its hover lift: the flip is the hover response */
.painpoints .pain-front.feature-card,
.painpoints .pain-front.feature-card:hover {
  transform: none;
  box-shadow: none;
}

.pain-back {
  transform: rotateY(180deg);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: var(--spacing-lg);
  border-radius: var(--radius-lg);
  border: 1px solid color-mix(in srgb, var(--ccn-brand) 45%, var(--border));
  background: color-mix(in srgb, var(--ccn-brand) 9%, var(--background));
}

.pain-fix-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: var(--font-size-xs);
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--accent-text);
  margin-bottom: var(--spacing-xs);
}

.pain-fix-label svg {
  width: 16px;
  height: 16px;
  flex: none;
}

.pain-fix-name {
  font-size: var(--font-size-lg);
  font-weight: 700;
  color: var(--primary-text);
  margin-bottom: var(--spacing-xs);
}

.pain-fix-line {
  color: var(--text-secondary);
  line-height: 1.5;
}

/* the flip itself (J9) is driven by .is-flipped, set by home-motion.js only after a 2 s hover, a click or
   Enter / Space (J11); a plain hover must not turn the card */
.pain-card.is-flipped .pain-card-inner {
  transform: rotateY(180deg);
}

.painpoints-hint {
  margin-top: var(--spacing-md);
  text-align: center;
  font-size: var(--font-size-sm);
  color: var(--text-muted);
}

/* reduced motion: no turn, the fix fades over the problem */
@media (prefers-reduced-motion: reduce) {
  .pain-card-inner,
  .pain-card.is-flipped .pain-card-inner {
    transform: none;
    transition: none;
  }

  .pain-back {
    transform: none;
    opacity: 0;
    transition: opacity var(--ccn-dur-2) linear;
  }

  .pain-front {
    transition: opacity var(--ccn-dur-2) linear;
  }

  .pain-card.is-flipped .pain-back {
    opacity: 1;
  }

  .pain-card.is-flipped .pain-front {
    opacity: 0;
  }
}

/* the merged free-start badge may wrap on narrow screens */
.hero-offer .hero-badge {
  text-align: left;
  line-height: 1.4;
}

/* Lifetime: price and period stay centred like the other cards; the early-bird tag sits outside the flow on the
   price's top-right corner, right above the period (js/campaign.js pulls it left when the card is too narrow), and
   the strike plus the tag play once the card has settled on screen (J12) */
.pricing-card.is-promo .pricing-price {
  display: inline-block;
  padding-top: 10px;
}

.pricing-card.is-promo .pricing-amount-box {
  position: relative;
}

/* pulled left over the price (narrow card), the tag rises above the digits instead of covering them */
.pricing-card.is-promo.promo-pulled .pricing-amount-box .pricing-promo {
  bottom: calc(100% + 0.9em);
}

.pricing-amount-box .pricing-promo {
  position: absolute;
  left: calc(100% + 4px - var(--promo-pull, 0px));
  bottom: calc(100% + 2px);
  min-height: 24px;
  margin: 0;
  padding: 2px 8px;
  border-radius: 10px;
  font-size: var(--font-size-xs);
  line-height: 1.2;
  white-space: nowrap;
  gap: 4px;
  opacity: 0;
  transform: translateY(6px) scale(0.7);
  transform-origin: left bottom;
}

.pricing-card.is-promo .pricing-amount {
  position: relative;
  transition: color 600ms ease-out;
}

.pricing-card.is-promo .pricing-amount::after {
  content: "";
  position: absolute;
  left: -2px;
  right: -2px;
  top: 52%;
  height: 2px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 600ms ease-out;
}

.pricing-card.is-promo.is-promo-shown .pricing-amount {
  color: var(--text-muted);
}

.pricing-card.is-promo.is-promo-shown .pricing-amount::after {
  transform: scaleX(1);
}

.pricing-card.is-promo.is-promo-shown .pricing-amount-box .pricing-promo {
  opacity: 1;
  transform: none;
  transition: opacity 280ms cubic-bezier(0.2, 0, 0, 1) 600ms, transform 280ms cubic-bezier(0.2, 0, 0, 1) 600ms;
}

@media (prefers-reduced-motion: reduce) {
  .pricing-card.is-promo .pricing-amount,
  .pricing-card.is-promo .pricing-amount::after,
  .pricing-card.is-promo.is-promo-shown .pricing-amount-box .pricing-promo {
    transition: none;
  }
}

@media (min-width: 840px) and (min-height: 520px) {
  .page-home .pain-back {
    padding: clamp(12px, calc(1.8 * var(--home-u)), 32px);
  }

  .page-home .pain-fix-name {
    font-size: clamp(16px, calc(1.35 * var(--home-u)), 22px);
  }

  .page-home .pain-fix-line {
    font-size: var(--home-card-text);
  }

  .page-home .painpoints-hint {
    margin-top: clamp(6px, calc(1 * var(--home-u)), 16px);
    font-size: clamp(12px, calc(0.95 * var(--home-u)), 15px);
  }

  .page-home .painpoints-hint + .painpoints-bridge {
    margin-top: clamp(4px, calc(0.6 * var(--home-u)), 12px);
  }
}

/* J3: cards of a block rise and sharpen in with a stagger when the block becomes active. The hidden start is
   only applied for one frame by js/home-motion.js (.mo-pending), so a block it never touches stays visible. */
.motion-on .mo-pending .mo-item {
  opacity: 0;
  translate: 0 12px;
  filter: blur(6px);
  transition: none;
}

.motion-on .mo-play .mo-item {
  transition: opacity var(--home-stagger-dur) var(--ccn-ease-out), translate var(--home-stagger-dur) var(--ccn-ease-out), filter var(--home-stagger-dur) var(--ccn-ease-out);
  transition-delay: calc(var(--mo-base, 0ms) + var(--mo-i, 0) * var(--home-stagger-step));
}

/* J4: the brand sweeps in from the left (a soft mask edge travels across the letters), then the headline
   follows word by word */
.motion-on .hero-title.mo-brand-play {
  -webkit-mask-image: linear-gradient(90deg, #000 0 40%, transparent 60% 100%);
  mask-image: linear-gradient(90deg, #000 0 40%, transparent 60% 100%);
  -webkit-mask-size: 250% 100%;
  mask-size: 250% 100%;
  animation: ccn-home-brand-sweep var(--home-brand-dur) var(--ccn-ease-out) both;
}

@keyframes ccn-home-brand-sweep {
  from {
    -webkit-mask-position: 100% 0;
    mask-position: 100% 0;
  }
  to {
    -webkit-mask-position: 0 0;
    mask-position: 0 0;
  }
}

.mo-word {
  display: inline-block;
}

.motion-on .mo-words-pending .mo-word {
  opacity: 0;
  translate: 0 0.4em;
  filter: blur(4px);
}

.motion-on .mo-words-play .mo-word {
  transition: opacity 420ms var(--ccn-ease-out), translate 420ms var(--ccn-ease-out), filter 420ms var(--ccn-ease-out);
  transition-delay: calc(var(--mo-base, 0ms) + var(--mo-i, 0) * 45ms);
}

/* J5: a counter shows its running value over the real number, which stays in the text for copy and screen
   readers; tabular figures keep the width still */
.mo-count {
  position: relative;
  display: inline-block;
  font-variant-numeric: tabular-nums;
}

.mo-count[data-n] {
  color: transparent;
}

.mo-count[data-n]::after {
  content: attr(data-n);
  content: attr(data-n) / "";
  position: absolute;
  right: 0;
  top: 0;
  color: var(--text-secondary);
}

/* J6: a soft light sweeps across Install Free every 4 s while the hero is on screen */
.hero .hero-actions .btn-primary {
  position: relative;
  overflow: hidden;
  isolation: isolate;
}

.motion-on .hero .hero-actions .btn-primary::after {
  content: "";
  position: absolute;
  inset: -20% auto -20% 0;
  width: 45%;
  background: linear-gradient(100deg, transparent 0%, rgb(255 255 255 / 0.38) 50%, transparent 100%);
  transform: translateX(-130%) skewX(-18deg);
  pointer-events: none;
  animation: ccn-home-shine 4s var(--ccn-ease-standard) 1.2s infinite;
  animation-play-state: paused;
}

.motion-on .hero.mo-live .hero-actions .btn-primary::after {
  animation-play-state: running;
}

@keyframes ccn-home-shine {
  0% { transform: translateX(-130%) skewX(-18deg); }
  22% { transform: translateX(330%) skewX(-18deg); }
  100% { transform: translateX(330%) skewX(-18deg); }
}

/* J7: a faint brand glow follows the pointer behind the hero, and cards light up under the pointer */
.page-home .hero {
  position: relative;
  overflow: clip;
}

.page-home .hero > .container {
  position: relative;
  z-index: 1;
}

.hero-glow {
  position: absolute;
  left: 0;
  top: 0;
  width: 720px;
  height: 720px;
  margin: -360px 0 0 -360px;
  border-radius: 50%;
  background: radial-gradient(closest-side, color-mix(in srgb, var(--ccn-brand) 13%, transparent), transparent);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--ccn-dur-5) var(--ccn-ease-out);
}

.hero-glow.is-on {
  opacity: 1;
}

.mo-spot {
  position: relative;
}

.mo-spot::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(260px circle at var(--mx, 50%) var(--my, 50%), color-mix(in srgb, var(--ccn-brand) 12%, transparent), transparent 70%);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--ccn-dur-3) var(--ccn-ease-out);
}

.motion-on .mo-spot:hover::after,
.motion-on .pain-card:hover .mo-spot::after,
.motion-on .pain-card:focus-visible .mo-spot::after {
  opacity: 1;
}

/* J2 + parallax: the incoming block clips its inner layer, which trails the block by about a third */
.pager-sliding .pager-incoming {
  overflow: clip;
}

.pager-sliding .pager-parallax {
  will-change: transform;
}

@media (prefers-reduced-motion: reduce) {
  .hero .hero-actions .btn-primary::after,
  .hero-glow,
  .mo-spot::after {
    display: none;
  }

  .hero-title.mo-brand-play {
    animation: none;
    -webkit-mask-image: none;
    mask-image: none;
  }
}

/* ==========================================================================
   Long-page table of contents (js/doc-toc.js, enabled per page with [data-doc-toc-root])
   ========================================================================== */

.doc-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--site-block-gap);
}

.doc-layout > * {
  min-width: 0;
}

.doc-layout [data-toc] {
  scroll-margin-top: calc(var(--nav-h) + 24px);
}

.doc-toc-details {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
}

.doc-toc-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px var(--spacing-md);
  font-weight: 600;
  color: var(--text-primary);
  cursor: pointer;
  list-style: none;
}

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

.doc-toc-summary::after {
  content: "";
  width: 8px;
  height: 8px;
  border-right: 2px solid var(--text-muted);
  border-bottom: 2px solid var(--text-muted);
  transform: rotate(45deg);
}

.doc-toc-details[open] > .doc-toc-summary::after {
  transform: rotate(-135deg);
}

.doc-toc-details[open] > .doc-toc-summary {
  border-bottom: 1px solid var(--border);
}

.doc-toc-nav {
  padding: var(--spacing-sm) 0;
}

.doc-toc-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.doc-toc-item a {
  display: block;
  padding: 6px var(--spacing-md);
  border-left: 2px solid transparent;
  color: var(--text-secondary);
  font-size: var(--font-size-sm);
  line-height: 1.4;
  overflow-wrap: anywhere;
  transition: color var(--ccn-dur-2) var(--ccn-ease-out), border-color var(--ccn-dur-2) var(--ccn-ease-out);
}

.doc-toc-item-l2 a {
  padding-left: calc(var(--spacing-md) + var(--spacing-md));
  font-size: 13px;
}

.doc-toc-item a:hover {
  color: var(--text-primary);
}

.doc-toc-item a:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: -2px;
}

.doc-toc-item a.is-active {
  color: var(--primary-text);
  border-left-color: var(--primary);
  font-weight: 600;
}

@media (min-width: 960px) {
  .doc-layout {
    grid-template-columns: 240px minmax(0, 800px);
    justify-content: center;
    gap: 48px;
  }

  .doc-toc {
    position: sticky;
    top: calc(var(--nav-h) + 24px);
    align-self: start;
    max-height: calc(100vh - var(--nav-h) - 48px);
    overflow-y: auto;
  }

  .doc-toc-details {
    background: transparent;
    border: 0;
    border-radius: 0;
  }

  .doc-toc-summary {
    display: none;
  }

  .doc-toc-nav {
    padding: 0;
    border-left: 1px solid var(--border);
  }

  .doc-toc-item a {
    margin-left: -1px;
  }

  .doc-layout .privacy-content {
    margin: 0;
  }
}

/* Reading layout of the privacy page: body indented under its heading, a further step under each sub-heading.
   Scoped to .doc-layout so the other legal pages keep their flat layout. */
.doc-layout .privacy-content {
  --doc-indent: 1.25rem;
  --doc-measure: 720px;
}

.doc-layout .privacy-section {
  margin-bottom: calc(var(--site-header-gap) + var(--spacing-md));
}

.doc-layout .privacy-section > :not(.privacy-section-title) {
  margin-left: var(--doc-indent);
  max-width: var(--doc-measure);
}

.doc-layout .privacy-subsection-title {
  margin-top: var(--spacing-xl);
  margin-bottom: var(--spacing-sm);
}

/* Needs the section in the selector to outrank the one-step indent rule above */
.doc-layout .privacy-section > .privacy-subsection-title ~ :is(p, ul, ol) {
  margin-left: calc(var(--doc-indent) * 2);
  max-width: calc(var(--doc-measure) - var(--doc-indent));
}

.doc-layout .privacy-section p,
.doc-layout .privacy-section li {
  line-height: 1.7;
}

.doc-layout .privacy-section p {
  margin-bottom: 0.95em;
}

.doc-layout .privacy-section li > ul {
  margin-left: var(--doc-indent);
}

:lang(ja) .doc-layout .privacy-section p,
:lang(ja) .doc-layout .privacy-section li,
:lang(zh-CN) .doc-layout .privacy-section p,
:lang(zh-CN) .doc-layout .privacy-section li {
  line-height: 1.8;
}

@media (max-width: 639px) {
  .doc-layout .privacy-content {
    --doc-indent: 0.625rem;
  }
}
