/* RhythmForge — shared styles */

:root {
  --bg-primary: #000000;
  --bg-card: #1C1C1E;
  --bg-card-hover: #2C2C2E;
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-gold: rgba(255, 214, 10, 0.45);

  --text-primary: #FFFFFF;
  --text-secondary: #8E8E93;
  --text-tertiary: #6E6E73;

  --accent-gold: #FFD60A;
  --accent-gold-warm: #FF9500;
  --accent-blue: #0A84FF;
  --accent-green: #30D158;
  --accent-cyan: #64D2FF;

  --gradient-gold: linear-gradient(135deg, #FFD60A, #FF9500);
  --gradient-hero: radial-gradient(
    ellipse 90% 60% at 50% 0%,
    rgba(60, 40, 120, 0.35) 0%,
    rgba(20, 20, 50, 0.15) 35%,
    rgba(0, 0, 0, 0) 70%
  );

  --section-gap: 120px;
  --content-max-width: 1080px;
  --reading-max-width: 720px;

  --radius-card: 16px;
  --radius-feature: 12px;

  --shadow-screenshot: 0 20px 60px rgba(0, 0, 0, 0.5);
  --shadow-icon-glow: 0 0 60px rgba(255, 214, 10, 0.25);
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  background: var(--bg-primary);
  color: var(--text-primary);
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'SF Pro Text', 'Segoe UI', sans-serif;
  font-size: 17px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100vh;
  overflow-x: hidden;
}

a {
  color: var(--accent-blue);
  text-decoration: none;
  transition: opacity 0.15s ease;
}

a:hover {
  opacity: 0.75;
}

a:focus-visible,
.cta-button:focus-visible,
.app-store-badge:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--accent-gold);
  outline-offset: 3px;
  border-radius: 4px;
}

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

.container {
  max-width: var(--content-max-width);
  margin: 0 auto;
  padding: 0 24px;
}

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

.hero {
  position: relative;
  padding: 96px 24px 56px;
  text-align: center;
  isolation: isolate;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--gradient-hero);
  z-index: -1;
  pointer-events: none;
}

.hero__inner {
  max-width: var(--content-max-width);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 48px;
  width: 100%;
}

.hero__copy {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  width: 100%;
  min-width: 0;
}

.hero__shot {
  flex: 0 0 auto;
  max-width: 240px;
  filter: drop-shadow(0 24px 60px rgba(0, 0, 0, 0.55));
}

.hero__shot img {
  width: 100%;
  height: auto;
}

@media (min-width: 900px) {
  .hero {
    padding: 112px 32px 72px;
  }

  .hero__inner {
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 72px;
  }

  .hero__copy {
    align-items: flex-start;
    text-align: left;
    flex: 1 1 0;
    max-width: 560px;
  }

  .hero__shot {
    max-width: 300px;
  }
}


.hero__title {
  margin-bottom: 16px;
  line-height: 0;
}

.hero__wordmark {
  width: clamp(280px, 46vw, 480px);
  height: auto;
  display: block;
  margin: 0 auto;
  filter: drop-shadow(0 6px 22px rgba(0, 0, 0, 0.55));
}

@media (min-width: 900px) {
  .hero__wordmark {
    margin: 0;
  }
}

.hero__tagline {
  color: var(--accent-gold);
  font-size: clamp(22px, 3.2vw, 28px);
  font-weight: 500;
  margin-bottom: 28px;
  letter-spacing: -0.015em;
}

.hero__description {
  color: var(--text-secondary);
  font-size: 18px;
  line-height: 1.55;
  width: 100%;
  max-width: 620px;
  margin: 0 auto 40px;
}

@media (min-width: 900px) {
  .hero__description {
    margin: 0 0 32px;
  }
}

.app-store-badge {
  display: inline-block;
  height: 56px;
  transition: transform 0.15s ease, opacity 0.15s ease;
}

.app-store-badge:hover {
  transform: translateY(-1px);
  opacity: 1;
}

.app-store-badge img {
  height: 100%;
  width: auto;
}

.hero__trial {
  display: block;
  margin-top: 14px;
  color: var(--text-secondary);
  font-size: 15px;
  letter-spacing: 0.005em;
}

/* ----- Trust strip ----- */

.trust-strip {
  text-align: center;
  padding: 32px 24px 56px;
  color: var(--text-secondary);
  font-size: 14px;
  letter-spacing: 0.01em;
}

.trust-strip__sep {
  margin: 0 14px;
  opacity: 0.6;
}

/* ----- Section base ----- */

section {
  padding: 64px 0;
}

.section-title {
  font-size: clamp(28px, 4vw, 36px);
  font-weight: 700;
  letter-spacing: -0.02em;
  text-align: center;
  margin-bottom: 48px;
}

/* ----- Screenshots ----- */

.screenshots {
  padding: 24px 0 80px;
}

.screenshots__row {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 24px;
  max-width: var(--content-max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.screenshots__item {
  flex: 1 1 0;
  max-width: 260px;
  filter: drop-shadow(0 20px 60px rgba(0, 0, 0, 0.5));
  transition: transform 0.3s ease;
}

.screenshots__item img {
  width: 100%;
  height: auto;
}

.screenshots__item--left {
  transform: rotate(-5deg) translateY(20px);
}

.screenshots__item--right {
  transform: rotate(5deg) translateY(20px);
}

.screenshots__item--center {
  z-index: 2;
  max-width: 380px;
  transform: scale(1.05);
  filter: drop-shadow(0 0 40px rgba(255, 214, 10, 0.3))
          drop-shadow(0 24px 60px rgba(0, 0, 0, 0.55));
}

.screenshots__item--placeholder {
  aspect-ratio: 9 / 19.5;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 36px;
  display: grid;
  place-items: center;
  color: var(--text-tertiary);
  font-size: 13px;
  text-align: center;
  padding: 24px;
}

.screenshots__caption {
  margin-top: 16px;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.screenshots__caption-label {
  color: var(--text-primary);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.screenshots__caption-text {
  color: var(--text-tertiary);
  font-size: 13px;
  letter-spacing: 0.01em;
  line-height: 1.4;
}

.screenshots__item--center .screenshots__caption-label {
  color: var(--accent-gold);
}

@media (max-width: 900px) {
  .screenshots__row {
    gap: 16px;
  }
  .screenshots__item--left,
  .screenshots__item--right,
  .screenshots__item--center {
    transform: none;
  }
}

@media (max-width: 640px) {
  .screenshots__row {
    flex-direction: column;
    gap: 32px;
  }
  .screenshots__item {
    max-width: 280px;
    width: 100%;
  }
}

/* ----- How it works ----- */

.how-it-works {
  padding: 80px 24px 40px;
  max-width: var(--content-max-width);
  margin: 0 auto;
}

.how-it-works__title {
  font-size: clamp(28px, 4vw, 36px);
  font-weight: 700;
  letter-spacing: -0.02em;
  text-align: center;
  margin-bottom: 48px;
}

.how-it-works__list {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.how-it-works__step {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 16px;
}

.how-it-works__num {
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--gradient-gold);
  color: #000;
  font-weight: 700;
  font-size: 22px;
  box-shadow: 0 8px 20px rgba(255, 214, 10, 0.3);
}

.how-it-works__heading {
  color: var(--text-primary);
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin: 4px 0 0;
}

.how-it-works__text {
  color: var(--text-secondary);
  font-size: 16px;
  line-height: 1.55;
  max-width: 280px;
  margin: 0;
}

@media (max-width: 720px) {
  .how-it-works__list {
    grid-template-columns: 1fr;
    gap: 28px;
    max-width: 320px;
    margin: 0 auto;
  }
}

/* ----- Features ----- */

.features {
  padding: 80px 0;
}

.features__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  max-width: var(--content-max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-feature);
  padding: 28px 28px 30px;
  transition: background 0.2s ease, border-color 0.2s ease;
}

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

.feature-card__icon {
  font-size: 32px;
  line-height: 1;
  margin-bottom: 16px;
  display: block;
}

.feature-card__title {
  font-size: 19px;
  font-weight: 600;
  margin-bottom: 8px;
  letter-spacing: -0.01em;
}

.feature-card__body {
  color: var(--text-secondary);
  font-size: 15px;
  line-height: 1.55;
}

@media (max-width: 720px) {
  .features__grid {
    grid-template-columns: 1fr;
  }
}

/* ----- For who ----- */

.for-who {
  padding: 56px 24px;
  max-width: 820px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  text-align: center;
  width: 100%;
  min-width: 0;
}

.for-who__icon,
.for-who__icon-fallback {
  width: 128px;
  height: 128px;
  flex: 0 0 auto;
  border-radius: 14px;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.06),
    0 0 16px rgba(255, 214, 210, 0.35),
    0 0 80px rgba(120, 80, 220, 0.25),
    0 14px 30px rgba(0, 0, 0, 0.6);
}

.for-who__icon-fallback {
  background: var(--gradient-gold);
  display: grid;
  place-items: center;
  font-size: 32px;
}

.for-who__text {
  font-size: clamp(20px, 2.4vw, 24px);
  line-height: 1.45;
  font-style: italic;
  font-weight: 400;
  color: var(--text-secondary);
  letter-spacing: -0.005em;
  margin: 0;
  width: 100%;
  max-width: 640px;
}

@media (min-width: 720px) {
  .for-who {
    flex-direction: row;
    justify-content: center;
    text-align: left;
    gap: 24px;
  }
}

/* ----- Pricing ----- */

.pricing {
  padding: 80px 0;
}

.pricing__lead {
  text-align: center;
  max-width: 640px;
  margin: 56px auto 0;
  padding: 0 24px;
}

.pricing__lead-title {
  font-size: clamp(28px, 4vw, 36px);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
}

.pricing__lead-sub {
  color: var(--text-secondary);
  font-size: 18px;
  line-height: 1.55;
  margin-bottom: 28px;
}

.pricing__lead .cta-button {
  margin-bottom: 16px;
}

.pricing__lead-tiers {
  color: var(--text-tertiary);
  font-size: 14px;
  letter-spacing: 0.01em;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 6px 14px;
  row-gap: 4px;
}

.pricing__lead-sep {
  opacity: 0.5;
}

@media (max-width: 480px) {
  .pricing__lead-sep {
    display: none;
  }
}

.pricing__lead-save {
  color: var(--accent-gold);
  font-weight: 600;
  margin-left: 4px;
}

.pricing__intro {
  max-width: 640px;
  margin: 0 auto 40px;
  padding: 0 24px;
  text-align: center;
}

.pricing__intro-title {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--accent-gold);
  margin-bottom: 14px;
}

.pricing__intro-body {
  color: var(--text-primary);
  font-size: 16px;
  line-height: 1.6;
  margin-bottom: 10px;
}

.pricing__intro-body--muted {
  color: var(--text-secondary);
  margin-bottom: 0;
}

.pricing__grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 0;
  max-width: 700px;
  margin: 0 auto;
  padding: 0 24px;
}

.pricing__col {
  padding: 32px 20px 24px;
  text-align: center;
  position: relative;
}

.pricing__col--label {
  text-align: right;
  padding-left: 4px;
  padding-right: 16px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.pricing__col--pro {
  background: var(--bg-card);
  border: 1px solid var(--border-gold);
  border-bottom: none;
  border-radius: var(--radius-card) var(--radius-card) 0 0;
  box-shadow: 0 24px 60px rgba(255, 214, 10, 0.06);
}

.pricing__plan-name {
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-secondary);
  margin-bottom: 8px;
  font-weight: 600;
}

.pricing__col--pro .pricing__plan-name {
  color: var(--accent-gold);
}

.pricing__price {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 24px;
  letter-spacing: -0.01em;
}

.pricing__price--free {
  color: var(--text-secondary);
  font-weight: 600;
}

.pricing__price-period {
  font-size: 14px;
  color: var(--text-secondary);
  font-weight: 400;
}

.pricing__row {
  display: contents;
}

.pricing__cell {
  padding: 14px 12px;
  border-top: 1px solid var(--border-subtle);
  font-size: 15px;
  text-align: center;
}

.pricing__cell--label {
  text-align: right;
  color: var(--text-secondary);
  padding-right: 16px;
  font-weight: 500;
}

.pricing__cell--pro {
  background: var(--bg-card);
  border-left: 1px solid var(--border-gold);
  border-right: 1px solid var(--border-gold);
}

.pricing__cell--pro-last {
  border-bottom: 1px solid var(--border-gold);
  border-bottom-left-radius: var(--radius-card);
  border-bottom-right-radius: var(--radius-card);
}

.cta-button {
  display: inline-block;
  background: var(--gradient-gold);
  color: #000;
  font-weight: 600;
  font-size: 16px;
  padding: 14px 28px;
  border-radius: 999px;
  letter-spacing: -0.005em;
  transition: transform 0.15s ease, box-shadow 0.15s ease, opacity 0.15s ease;
  box-shadow: 0 8px 24px rgba(255, 214, 10, 0.2);
}

.cta-button:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 32px rgba(255, 214, 10, 0.3);
  opacity: 1;
}

@media (max-width: 640px) {
  /* Switch to single-column stacked layout on mobile */
  .pricing__grid {
    display: flex;
    flex-direction: column;
    gap: 0;
    padding: 0 16px;
    max-width: 480px;
  }

  /* Hide the desktop header row entirely on mobile — header is per-row */
  .pricing__col {
    display: none;
  }

  /* Each cell becomes a flex row: label on left, value on right */
  .pricing__cell {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding: 14px 0;
    border-top: 1px solid var(--border-subtle);
    border-left: none;
    border-right: none;
    text-align: left;
    font-size: 15px;
    background: transparent;
  }

  /* The label cell becomes a section header for each comparison */
  .pricing__cell--label {
    padding: 22px 0 6px;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-tertiary);
    border-top: none;
    text-align: left;
    font-weight: 600;
  }

  /* Free and PRO cells get prefix labels via ::before */
  .pricing__cell--free::before {
    content: "Free";
    color: var(--text-tertiary);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-right: 12px;
    flex: 0 0 auto;
  }

  .pricing__cell--pro::before {
    content: "PRO";
    color: var(--accent-gold);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 700;
    margin-right: 12px;
    flex: 0 0 auto;
  }

  /* Free and PRO cells: value text is right-aligned via flex */
  .pricing__cell--free,
  .pricing__cell--pro {
    color: var(--text-primary);
    text-align: right;
  }

  .pricing__cell--free {
    color: var(--text-secondary);
  }

  /* Strip border-radius and border treatments from PRO column on mobile —
     the comparison no longer reads as "column" so the column treatment
     becomes visual noise. The accent comes from "PRO" label color. */
  .pricing__cell--pro {
    background: transparent;
    border-radius: 0;
  }

  .pricing__cell--pro-last {
    border-bottom: none;
    border-radius: 0;
  }
}

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

.faq {
  padding: 64px 24px 80px;
  max-width: 760px;
  margin: 0 auto;
}

.faq__title {
  font-size: clamp(28px, 4vw, 36px);
  font-weight: 700;
  letter-spacing: -0.02em;
  text-align: center;
  margin-bottom: 40px;
}

.faq__list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.faq__item {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-feature);
  overflow: hidden;
  transition: border-color 0.2s ease;
}

.faq__item[open] {
  border-color: rgba(255, 214, 10, 0.25);
}

.faq__question {
  cursor: pointer;
  padding: 18px 20px;
  font-weight: 600;
  font-size: 17px;
  line-height: 1.4;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  color: var(--text-primary);
}

.faq__question::-webkit-details-marker {
  display: none;
}

.faq__question::after {
  content: '+';
  color: var(--accent-gold);
  font-size: 24px;
  font-weight: 300;
  line-height: 1;
  flex: 0 0 auto;
}

.faq__item[open] .faq__question::after {
  content: '−';
}

.faq__answer {
  padding: 0 20px 20px;
  color: var(--text-secondary);
  font-size: 16px;
  line-height: 1.6;
}

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

.site-footer {
  border-top: 1px solid var(--border-subtle);
  padding: 48px 24px 64px;
  text-align: center;
  color: var(--text-tertiary);
  font-size: 14px;
}

.site-footer__brand {
  font-weight: 600;
  font-size: 16px;
  color: var(--text-primary);
  margin-bottom: 16px;
  letter-spacing: -0.01em;
  line-height: 0;
}

.site-footer__wordmark {
  height: 32px;
  width: auto;
  margin: 0 auto;
  display: inline-block;
  opacity: 0.85;
}

.site-footer__links {
  margin-bottom: 16px;
}

.site-footer__links a {
  color: var(--text-secondary);
  margin: 0 6px;
}

.site-footer__sep {
  color: var(--text-tertiary);
  opacity: 0.6;
  margin: 0 4px;
}

.site-footer__system-note {
  color: var(--text-tertiary);
  font-size: 13px;
  margin-bottom: 16px;
  letter-spacing: 0.01em;
}

/* ----- Legal pages (privacy, terms) ----- */

.legal {
  max-width: var(--reading-max-width);
  margin: 0 auto;
  padding: 64px 24px 96px;
  font-size: 17px;
  line-height: 1.7;
  color: var(--text-primary);
}

.legal__home {
  display: inline-block;
  margin-bottom: 40px;
  line-height: 0;
  transition: opacity 0.15s ease;
}

.legal__home:hover {
  opacity: 0.85;
}

.legal__wordmark {
  height: 28px;
  width: auto;
  display: block;
}

.legal h1 {
  font-size: 36px;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
}

.legal h2 {
  font-size: 20px;
  font-weight: 600;
  letter-spacing: -0.01em;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-top: 48px;
  margin-bottom: 16px;
  color: var(--text-primary);
}

.legal h3 {
  font-size: 17px;
  font-weight: 600;
  margin-top: 28px;
  margin-bottom: 12px;
  color: var(--text-primary);
}

.legal p {
  color: var(--text-primary);
  margin-bottom: 18px;
}

.legal p.muted,
.legal .legal__updated {
  color: var(--text-secondary);
  font-size: 15px;
  margin-bottom: 32px;
}

.legal ul {
  margin: 0 0 18px 0;
  padding-left: 22px;
  color: var(--text-primary);
}

.legal ul li {
  margin-bottom: 10px;
}

.legal ul li::marker {
  color: var(--text-tertiary);
}

.legal a {
  color: var(--accent-blue);
  word-break: break-word;
}

.legal__summary {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-feature);
  padding: 20px 24px 8px;
  margin: 24px 0 32px;
}

.legal__summary h2 {
  margin-top: 0;
  margin-bottom: 12px;
  font-size: 13px;
}

.legal__summary ul {
  margin-bottom: 12px;
}

/* ----- Mobile CTA bar (mobile-only, fixed) ----- */

.mobile-cta {
  display: none;
}

@media (max-width: 720px) {
  .mobile-cta {
    display: flex;
    position: fixed;
    bottom: 16px;
    left: 16px;
    right: 16px;
    z-index: 100;
    background: var(--gradient-gold);
    color: #000;
    padding: 14px 20px;
    border-radius: 999px;
    align-items: center;
    justify-content: space-between;
    font-weight: 600;
    font-size: 15px;
    box-shadow: 0 8px 24px rgba(255, 214, 10, 0.3),
                0 16px 40px rgba(0, 0, 0, 0.4);
    text-decoration: none;
    transform: translateY(120%);
    animation: mobileCtaSlideIn 0.4s ease 1.5s forwards;
  }

  .mobile-cta__arrow {
    font-size: 18px;
    line-height: 1;
  }

  .mobile-cta:hover {
    opacity: 1;
  }

  /* Reserve space at bottom of page so footer doesn't sit under the bar */
  body {
    padding-bottom: 80px;
  }
}

@keyframes mobileCtaSlideIn {
  to {
    transform: translateY(0);
  }
}
