/* ═══ Remímídò design system — extracted from index.html, single source of truth for every page ═══ */
* {
      margin: 0;
      padding: 0;
      box-sizing: border-box;
    }
    :root {
      --cream: #FFF0F5;
      --dark: #2D2040;
      --pink: #FFAFCC;
      --pink-light: #FFC8DD;
      --purple: #CDB4DB;
      --blue: #BDE0FE;
      --blue-deep: #A2D2FF;
      --mid: rgba(45, 32, 64, 0.55);
      --faint: rgba(45, 32, 64, 0.06);
      --white: #FFFFFF;
      --border: rgba(45, 32, 64, 0.1);
    }

    html,
    body {
      font-family: 'DM Sans', sans-serif;
      background: var(--cream);
      color: var(--dark);
      min-height: 100vh;
      -webkit-font-smoothing: antialiased;
    }

    /* NAV */
    .nav {
      padding: 1.2rem 2.5rem;
      display: flex;
      align-items: center;
      justify-content: space-between;
      border-bottom: 1px solid var(--border);
      background: var(--cream);
      position: sticky;
      top: 0;
      z-index: 100;
    }

    .logo {
      font-size: 1.1rem;
      font-weight: 900;
      letter-spacing: -0.5px;
      color: var(--dark);
      cursor: pointer;
      display: flex;
      align-items: center;
      gap: 0.5rem;
    }

    .logo img {
      width: 28px;
      height: 28px;
      object-fit: contain;
      display: block;
      flex-shrink: 0;
    }

    .logo span {
      color: var(--pink);
    }

    .nav-right {
      display: flex;
      align-items: center;
      gap: 1.2rem;
    }

    .lang-pills {
      display: flex;
      gap: 0.4rem;
    }

    .lang-pill {
      padding: 0.35rem 0.85rem;
      border-radius: 20px;
      border: 1.5px solid var(--border);
      font-size: 0.78rem;
      font-weight: 700;
      cursor: pointer;
      transition: all 0.2s;
      background: transparent;
      color: var(--mid);
      font-family: 'DM Sans', sans-serif;
    }

    .lang-pill.active {
      background: var(--dark);
      color: var(--white);
      border-color: var(--dark);
    }

    .lang-pill:hover:not(.active) {
      border-color: var(--purple);
      color: var(--dark);
    }

    /* BUTTONS */
    .btn {
      display: inline-flex;
      align-items: center;
      gap: 8px;
      padding: 0.8rem 1.6rem;
      background: var(--dark);
      color: var(--white);
      font-family: 'DM Sans', sans-serif;
      font-size: 0.9rem;
      font-weight: 700;
      border: none;
      border-radius: 8px;
      cursor: pointer;
      transition: background 0.2s, transform 0.15s;
    }

    .btn:hover {
      background: #4A3560;
      transform: translateY(-1px);
    }

    .btn-ghost {
      background: transparent;
      color: var(--dark);
      border: 1.5px solid var(--border);
      padding: 0.55rem 1.1rem;
      font-size: 0.85rem;
    }

    .btn-ghost:hover {
      background: var(--faint);
      transform: none;
    }

    .btn-pink {
      background: var(--pink);
      color: var(--dark);
    }

    .btn-pink:hover {
      background: var(--pink-light);
      color: var(--dark);
    }

    .divider {
      height: 1px;
      background: var(--border);
      margin: 0 2.5rem;
    }

    .section {
      padding: 3rem 2.5rem;
      max-width: 900px;
      margin: 0 auto;
      width: 100%;
    }

    .section-label {
      font-size: 0.72rem;
      font-weight: 700;
      letter-spacing: 2.5px;
      text-transform: uppercase;
      color: var(--purple);
      margin-bottom: 1rem;
    }

    .section-title {
      font-size: 1.6rem;
      font-weight: 900;
      letter-spacing: -0.5px;
      margin-bottom: 0.4rem;
    }

    .section-sub {
      font-size: 0.95rem;
      color: var(--mid);
      margin-bottom: 2rem;
    }

    /* HERO */
    .hero {
      padding: 5rem 2.5rem 4rem;
      max-width: 820px;
      margin: 0 auto;
      text-align: center;
    }

    .hero-tag {
      display: inline-block;
      background: var(--purple);
      color: var(--dark);
      font-size: 0.72rem;
      font-weight: 700;
      letter-spacing: 2px;
      text-transform: uppercase;
      padding: 0.4rem 1rem;
      border-radius: 20px;
      margin-bottom: 1.5rem;
    }

    .hero h1 {
      font-size: clamp(2.6rem, 6vw, 4.2rem);
      font-weight: 900;
      line-height: 1.06;
      letter-spacing: -2px;
      margin-bottom: 1.2rem;
    }

    .hero h1 em {
      font-style: normal;
      color: var(--pink);
    }

    .hero p {
      font-size: 1.1rem;
      line-height: 1.75;
      color: var(--mid);
      max-width: 520px;
      margin: 0 auto 2.5rem;
    }

    .hero-actions {
      display: flex;
      gap: 1rem;
      justify-content: center;
      flex-wrap: wrap;
    }

    /* LANG CARDS */
    .lang-cards {
      display: grid;
      grid-template-columns: repeat(4, 1fr);
      gap: 1rem;
    }

    .lang-card {
      background: var(--white);
      border: 2px solid var(--border);
      border-radius: 16px;
      padding: 1.6rem 1rem;
      cursor: pointer;
      transition: all 0.2s;
      text-align: center;
    }

    .lang-card:hover {
      border-color: var(--purple);
      transform: translateY(-3px);
      box-shadow: 0 8px 24px rgba(205, 180, 219, 0.3);
    }

    .lang-card.selected {
      border-color: var(--dark);
      background: var(--dark);
      color: var(--white);
    }

    .lang-card-icon {
      font-size: 2rem;
      margin-bottom: 0.7rem;
    }

    .lang-card-name {
      font-size: 1rem;
      font-weight: 900;
      margin-bottom: 0.25rem;
    }

    .lang-card-sub {
      font-size: 0.75rem;
      color: var(--mid);
    }

    .lang-card.selected .lang-card-sub {
      color: rgba(255, 255, 255, 0.55);
    }

    /* CATEGORIES */
    .categories-grid {
      display: grid;
      grid-template-columns: repeat(2, 1fr);
      gap: 1rem;
    }

    .cat-card {
      background: var(--white);
      border: 2px solid var(--border);
      border-radius: 14px;
      padding: 1.4rem 1.5rem;
      cursor: pointer;
      transition: all 0.2s;
      display: flex;
      align-items: center;
      gap: 1rem;
    }

    .cat-card:hover {
      border-color: var(--pink);
      transform: translateX(4px);
    }

    .cat-card.selected {
      border-color: var(--pink);
      background: #FFF5F8;
    }

    .cat-icon {
      width: 48px;
      height: 48px;
      border-radius: 12px;
      display: flex;
      align-items: center;
      justify-content: center;
      font-size: 1.4rem;
      flex-shrink: 0;
    }

    .cat-name {
      font-size: 0.95rem;
      font-weight: 700;
      margin-bottom: 0.2rem;
    }

    .cat-count {
      font-size: 0.75rem;
      color: var(--mid);
    }

    .cat-arrow {
      color: var(--mid);
      font-size: 1.1rem;
    }

    /* STORIES */
    .stories-list {
      display: flex;
      flex-direction: column;
      gap: 0.8rem;
    }

    .story-row {
      background: var(--white);
      border: 1.5px solid var(--border);
      border-radius: 12px;
      padding: 1.2rem 1.4rem;
      display: flex;
      align-items: center;
      gap: 1.2rem;
      cursor: pointer;
      transition: all 0.2s;
    }

    .story-row:hover {
      border-color: var(--purple);
      box-shadow: 0 4px 16px rgba(205, 180, 219, 0.2);
    }

    .story-play-icon {
      width: 40px;
      height: 40px;
      border-radius: 50%;
      background: var(--dark);
      display: flex;
      align-items: center;
      justify-content: center;
      flex-shrink: 0;
      transition: background 0.2s;
    }

    .story-row:hover .story-play-icon {
      background: #4A3560;
    }

    .play-tri-sm {
      width: 0;
      height: 0;
      border-style: solid;
      border-width: 7px 0 7px 13px;
      border-color: transparent transparent transparent white;
      margin-left: 2px;
    }

    .story-info {
      flex: 1;
    }

    .story-title {
      font-size: 0.95rem;
      font-weight: 700;
      margin-bottom: 0.2rem;
    }

    .story-meta {
      font-size: 0.75rem;
      color: var(--mid);
    }

    .coming-soon-badge {
      font-size: 0.65rem;
      font-weight: 700;
      letter-spacing: 1px;
      text-transform: uppercase;
      background: var(--faint);
      color: var(--mid);
      padding: 0.25rem 0.6rem;
      border-radius: 6px;
      white-space: nowrap;
    }

    /* ORIGIN STRIP — the family entry point */
    .origin-strip {
      margin: 0 2.5rem 0;
      background: var(--white);
      border: 1.5px solid var(--border);
      border-radius: 16px;
      padding: 1.6rem 2rem;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 2rem;
      max-width: 856px;
      margin-left: auto;
      margin-right: auto;
      cursor: pointer;
      transition: border-color 0.2s, box-shadow 0.2s;
    }

    .origin-strip:hover {
      border-color: var(--purple);
      box-shadow: 0 4px 20px rgba(205, 180, 219, 0.2);
    }

    .origin-left {
      display: flex;
      align-items: center;
      gap: 1.2rem;
    }

    .origin-dot {
      width: 10px;
      height: 10px;
      border-radius: 50%;
      background: var(--pink);
      flex-shrink: 0;
      box-shadow: 0 0 0 4px rgba(255, 175, 204, 0.2);
    }

    .origin-text {}

    .origin-label {
      font-size: 0.68rem;
      font-weight: 700;
      letter-spacing: 2px;
      text-transform: uppercase;
      color: var(--purple);
      margin-bottom: 0.25rem;
    }

    .origin-headline {
      font-size: 0.95rem;
      font-weight: 700;
      color: var(--dark);
      margin-bottom: 0.1rem;
    }

    .origin-sub {
      font-size: 0.8rem;
      color: var(--mid);
    }

    .origin-cta {
      font-size: 0.8rem;
      font-weight: 700;
      color: var(--purple);
      white-space: nowrap;
      display: flex;
      align-items: center;
      gap: 4px;
      flex-shrink: 0;
    }

    /* PLAYER */
    #player {
      background: var(--cream);
    }

    .player-top {
      background: var(--dark);
      padding: 3rem 2rem 2.5rem;
      text-align: center;
      color: var(--white);
    }

    .player-cat-tag {
      display: inline-block;
      background: rgba(255, 255, 255, 0.12);
      color: rgba(255, 255, 255, 0.7);
      font-size: 0.72rem;
      font-weight: 700;
      letter-spacing: 2px;
      text-transform: uppercase;
      padding: 0.35rem 0.8rem;
      border-radius: 20px;
      margin-bottom: 1.5rem;
    }

    .player-title {
      font-size: clamp(1.4rem, 3vw, 2rem);
      font-weight: 900;
      letter-spacing: -0.5px;
      line-height: 1.2;
      margin-bottom: 0.5rem;
    }

    .player-lang {
      font-size: 0.85rem;
      color: rgba(255, 255, 255, 0.5);
    }

    .player-body {
      flex: 1;
      max-width: 520px;
      margin: 0 auto;
      width: 100%;
      padding: 2.5rem 1.5rem;
    }

    .coming-soon-card {
      background: var(--white);
      border-radius: 20px;
      padding: 3rem 2rem;
      text-align: center;
      border: 1.5px solid var(--border);
    }

    .cs-icon {
      font-size: 2.5rem;
      margin-bottom: 1rem;
    }

    .cs-title {
      font-size: 1.1rem;
      font-weight: 900;
      margin-bottom: 0.5rem;
    }

    .cs-text {
      font-size: 0.9rem;
      color: var(--mid);
      line-height: 1.7;
      margin-bottom: 1.5rem;
    }

    .email-row {
      display: flex;
      gap: 0.5rem;
      max-width: 340px;
      margin: 0 auto;
    }

    .email-input {
      flex: 1;
      padding: 0.75rem 1rem;
      border: 1.5px solid var(--border);
      border-radius: 8px;
      font-family: 'DM Sans', sans-serif;
      font-size: 0.88rem;
      background: var(--cream);
      color: var(--dark);
      outline: none;
    }

    .email-input:focus {
      border-color: var(--purple);
    }

    /* HOW IT WORKS */
    #how-it-works {
      background: var(--cream);
    }

    .hiw-hero {
      background: var(--dark);
      padding: 4rem 2.5rem 3rem;
      text-align: center;
      color: var(--white);
    }

    .hiw-hero h2 {
      font-size: clamp(2rem, 5vw, 3rem);
      font-weight: 900;
      letter-spacing: -1px;
      margin-bottom: 1rem;
    }

    .hiw-hero p {
      font-size: 1rem;
      color: rgba(255, 255, 255, 0.6);
      max-width: 460px;
      margin: 0 auto;
      line-height: 1.7;
    }

    .hiw-body {
      max-width: 800px;
      margin: 0 auto;
      padding: 3rem 2.5rem;
    }

    .hiw-grid {
      display: grid;
      grid-template-columns: repeat(2, 1fr);
      gap: 1.5rem;
      margin-bottom: 3rem;
    }

    .hiw-card {
      background: var(--white);
      border: 1.5px solid var(--border);
      border-radius: 16px;
      padding: 2rem 1.8rem;
    }

    .hiw-num {
      font-size: 0.72rem;
      font-weight: 700;
      letter-spacing: 2px;
      text-transform: uppercase;
      color: var(--purple);
      margin-bottom: 1rem;
    }

    .hiw-card h3 {
      font-size: 1.05rem;
      font-weight: 900;
      margin-bottom: 0.5rem;
    }

    .hiw-card p {
      font-size: 0.88rem;
      color: var(--mid);
      line-height: 1.7;
    }

    .pricing-section {
      background: var(--white);
      border-radius: 20px;
      padding: 2.5rem;
      border: 1.5px solid var(--border);
    }

    .pricing-section h3 {
      font-size: 1.3rem;
      font-weight: 900;
      margin-bottom: 0.4rem;
    }

    .pricing-section>p {
      font-size: 0.9rem;
      color: var(--mid);
      margin-bottom: 2rem;
    }

    .pricing-tiers {
      display: grid;
      grid-template-columns: repeat(2, 1fr);
      gap: 1rem;
    }

    .tier {
      border: 2px solid var(--border);
      border-radius: 14px;
      padding: 1.5rem;
      text-align: center;
    }

    .tier.featured {
      border-color: var(--dark);
      background: var(--dark);
      color: var(--white);
    }

    .tier-name {
      font-size: 0.75rem;
      font-weight: 700;
      letter-spacing: 2px;
      text-transform: uppercase;
      color: var(--mid);
      margin-bottom: 0.5rem;
    }

    .tier.featured .tier-name {
      color: rgba(255, 255, 255, 0.5);
    }

    .tier-price {
      font-size: 2rem;
      font-weight: 900;
      letter-spacing: -1px;
      margin-bottom: 0.3rem;
    }

    .tier-per {
      font-size: 0.75rem;
      color: var(--mid);
      margin-bottom: 1rem;
    }

    .tier.featured .tier-per {
      color: rgba(255, 255, 255, 0.5);
    }

    .tier-features {
      font-size: 0.82rem;
      color: var(--mid);
      line-height: 1.9;
      text-align: left;
    }

    .tier.featured .tier-features {
      color: rgba(255, 255, 255, 0.7);
    }

    .footer {
      padding: 2.5rem 2.5rem;
      text-align: center;
      border-top: 1px solid var(--border);
      margin-top: 0;
      display: flex;
      flex-direction: column;
      gap: 0.5rem;
    }

    .footer-top {
      font-size: 0.85rem;
      font-weight: 700;
      color: var(--dark);
    }

    .footer-contact {
      font-size: 0.82rem;
      color: var(--mid);
    }

    .footer-contact a {
      color: var(--dark);
      font-weight: 700;
      text-decoration: none;
      border-bottom: 1.5px solid var(--pink);
      padding-bottom: 1px;
      transition: color 0.2s, border-color 0.2s;
    }

    .footer-contact a:hover {
      color: var(--purple);
      border-color: var(--purple);
    }

    .footer-copy {
      font-size: 0.72rem;
      color: rgba(45, 32, 64, 0.3);
      margin-top: 0.25rem;
    }

    /* ORIGIN STORY SECTION */
    .origin-story-section {
      background: var(--dark);
      padding: 5rem 2.5rem;
      margin-top: 3rem;
    }

    .origin-story-inner {
      max-width: 620px;
      margin: 0 auto;
    }

    .origin-story-label {
      font-size: 0.72rem;
      font-weight: 700;
      letter-spacing: 2.5px;
      text-transform: uppercase;
      color: var(--pink);
      margin-bottom: 1.2rem;
    }

    .origin-story-heading {
      font-size: clamp(1.8rem, 4vw, 2.6rem);
      font-weight: 900;
      letter-spacing: -1px;
      line-height: 1.1;
      color: var(--white);
      margin-bottom: 2rem;
    }

    .origin-story-body {
      display: flex;
      flex-direction: column;
      gap: 1.2rem;
      margin-bottom: 2.5rem;
    }

    .origin-story-body p {
      font-size: 1rem;
      line-height: 1.85;
      color: rgba(255, 255, 255, 0.65);
    }

    .origin-story-body p em {
      font-style: italic;
      color: rgba(255, 255, 255, 0.9);
    }

    .origin-story-cta {
      display: inline-flex;
      align-items: center;
      background: transparent;
      border: 1.5px solid rgba(255, 255, 255, 0.2);
      color: rgba(255, 255, 255, 0.8);
      font-family: 'DM Sans', sans-serif;
      font-size: 0.9rem;
      font-weight: 700;
      padding: 0.75rem 1.5rem;
      border-radius: 8px;
      cursor: pointer;
      transition: all 0.2s;
    }

    .origin-story-cta:hover {
      border-color: var(--pink);
      color: var(--pink);
    }

    /* AUTH */
    .nav-auth-btn {
      padding: 0.35rem 0.9rem;
      border-radius: 20px;
      border: 1.5px solid var(--border);
      font-size: 0.78rem;
      font-weight: 700;
      cursor: pointer;
      transition: all 0.2s;
      background: transparent;
      color: var(--mid);
      font-family: 'DM Sans', sans-serif;
      white-space: nowrap;
    }

    .nav-auth-btn:hover {
      border-color: var(--pink);
      color: var(--dark);
    }

    .nav-auth-btn.signed-in {
      background: var(--dark);
      color: var(--white);
      border-color: var(--dark);
    }

    @media (max-width: 700px) {
      .lang-cards {
        grid-template-columns: repeat(2, 1fr);
      }

      .categories-grid {
        grid-template-columns: 1fr;
      }

      .hero {
        padding: 3rem 1.5rem 2.5rem;
      }

      .section {
        padding: 2rem 1.5rem;
      }

      .nav {
        padding: 1rem 1.2rem;
      }

      .hiw-grid {
        grid-template-columns: 1fr;
      }

      .pricing-tiers {
        grid-template-columns: 1fr;
      }

      .email-row {
        flex-direction: column;
      }

      .origin-strip {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
        margin: 0 1.5rem;
      }
    }

    /* ══ PLATFORM AUDIO PLAYER (ported from demo) ══ */
    .audio-box {
      background: var(--white);
      border-radius: 20px;
      padding: 2rem 1.8rem;
      width: 100%;
      border: 1.5px solid var(--border);
      text-align: center;
    }
    .audio-title { font-size: 1rem; font-weight: 700; margin-bottom: 0.3rem; color: var(--dark); }
    .audio-hint { font-size: 0.8rem; color: rgba(45, 32, 64, 0.38); margin-bottom: 1.8rem; }
    .play-area { display: flex; align-items: center; justify-content: center; gap: 1rem; margin-bottom: 1.6rem; }
    .wave-bars { display: flex; gap: 3px; align-items: flex-end; height: 26px; }
    .wb { width: 4px; border-radius: 2px; background: var(--purple); animation: wv 0.75s ease-in-out infinite; }
    .wb:nth-child(2) { animation-delay: .1s; }
    .wb:nth-child(3) { animation-delay: .2s; }
    .wb:nth-child(4) { animation-delay: .3s; }
    .wb:nth-child(5) { animation-delay: .15s; }
    @keyframes wv { 0%, 100% { height: 5px; } 50% { height: 22px; } }
    .play-btn {
      width: 64px; height: 64px; border-radius: 50%;
      background: var(--dark); border: none; cursor: pointer;
      display: flex; align-items: center; justify-content: center;
      transition: transform 0.2s, background 0.2s; flex-shrink: 0;
    }
    .play-btn:hover { transform: scale(1.07); background: #4A3560; }
    .play-tri { width: 0; height: 0; border-style: solid; border-width: 11px 0 11px 20px; border-color: transparent transparent transparent var(--cream); margin-left: 3px; }
    .pause-duo { display: flex; gap: 5px; align-items: center; }
    .pause-bar { width: 5px; height: 20px; background: var(--cream); border-radius: 2px; }
    .prog-track { width: 100%; height: 5px; background: rgba(45, 32, 64, 0.09); border-radius: 3px; cursor: pointer; margin-bottom: 0.4rem; }
    .prog-fill { height: 100%; background: var(--purple); border-radius: 3px; width: 0%; transition: width 0.2s linear; }
    .time-row { display: flex; justify-content: space-between; font-size: 0.72rem; color: rgba(45, 32, 64, 0.38); margin-bottom: 1.2rem; }
    .speed-row { display: flex; justify-content: center; gap: 0.5rem; }
    .speed-pill {
      padding: 0.3rem 0.8rem; border-radius: 20px;
      border: 1.5px solid var(--border); background: transparent;
      font-family: 'DM Sans', sans-serif; font-size: 0.75rem; font-weight: 700;
      color: var(--mid); cursor: pointer; transition: all 0.15s;
    }
    .speed-pill:hover { border-color: var(--purple); color: var(--dark); }
    .speed-pill.active { background: var(--dark); color: var(--white); border-color: var(--dark); }
    .ambience-section { margin-top: 1.4rem; padding-top: 1.4rem; border-top: 1px solid var(--border); }
    .ambience-label {
      font-size: 0.68rem; font-weight: 700; letter-spacing: 2px;
      text-transform: uppercase; color: rgba(45, 32, 64, 0.35);
      margin-bottom: 0.8rem; text-align: center;
    }
    .ambience-row { display: flex; justify-content: center; gap: 0.6rem; flex-wrap: wrap; }
    .ambience-pill {
      display: inline-flex; align-items: center; gap: 0.4rem;
      padding: 0.45rem 1rem; border-radius: 50px;
      border: 1.5px solid var(--border); background: transparent;
      font-family: 'DM Sans', sans-serif; font-size: 0.82rem; font-weight: 600;
      color: var(--mid); cursor: pointer; transition: all 0.2s;
    }
    .ambience-pill:hover { border-color: var(--purple); color: var(--dark); }
    .ambience-pill.active { background: var(--purple); color: var(--dark); border-color: var(--purple); font-weight: 700; }
    .ambience-icon { font-size: 0.9rem; }
    audio { display: none; }

    /* ══ STORY-ROW READY / SOON STATES ══ */
    .story-row--soon .story-play-icon { background: var(--faint); }
    .story-row--soon .play-tri-sm { border-color: transparent transparent transparent rgba(45, 32, 64, 0.3); }
    .story-row--soon:hover .story-play-icon { background: rgba(45, 32, 64, 0.12); }
    .story-row--ready { border-color: rgba(255, 175, 204, 0.5); }
    .listen-badge {
      font-size: 0.65rem; font-weight: 700; letter-spacing: 1px; text-transform: uppercase;
      background: var(--pink); color: var(--dark); padding: 0.25rem 0.6rem; border-radius: 6px; white-space: nowrap;
    }
    .pro-lock {
      display: inline-flex; align-items: center; gap: 3px;
      font-size: 0.58rem; font-weight: 700; letter-spacing: 1px; text-transform: uppercase;
      color: var(--purple); margin-left: 6px; vertical-align: middle;
    }

    /* ══ UPGRADE MODAL ══ */
    .modal-overlay {
      position: fixed; inset: 0; background: rgba(45, 32, 64, 0.55);
      display: none; align-items: center; justify-content: center; z-index: 200; padding: 1.5rem;
    }
    .modal-overlay.active { display: flex; }
    .modal-card {
      background: var(--white); border-radius: 20px; padding: 2.5rem 2rem;
      max-width: 400px; width: 100%; text-align: center; position: relative;
      box-shadow: 0 20px 60px rgba(45, 32, 64, 0.3);
    }
    .modal-close {
      position: absolute; top: 0.9rem; right: 1.1rem; background: none; border: none;
      font-size: 1.5rem; color: var(--mid); cursor: pointer; line-height: 1; font-family: inherit;
    }
    .modal-close:hover { color: var(--dark); }
    .modal-icon { font-size: 2.2rem; margin-bottom: 0.8rem; }
    .modal-title { font-size: 1.3rem; font-weight: 900; letter-spacing: -0.5px; margin-bottom: 0.5rem; }
    .modal-text { font-size: 0.92rem; line-height: 1.7; color: var(--mid); margin-bottom: 1.5rem; }
    .modal-price { font-size: 1.8rem; font-weight: 900; margin-bottom: 0.2rem; }
    .modal-price span { font-size: 0.8rem; font-weight: 500; color: var(--mid); }
    .modal-features {
      text-align: left; font-size: 0.85rem; color: var(--mid); line-height: 1.9;
      background: var(--cream); border-radius: 12px; padding: 1rem 1.2rem; margin: 1.2rem 0 1.5rem;
    }

    /* ══ AUTH MODAL ══ */
    .auth-google {
      width: 100%; display: flex; align-items: center; justify-content: center; gap: 0.6rem;
      padding: 0.75rem; border: 1.5px solid var(--border); border-radius: 8px; background: var(--white);
      font-family: inherit; font-size: 0.9rem; font-weight: 700; color: var(--dark); cursor: pointer;
      transition: border-color 0.2s;
    }
    .auth-google:hover { border-color: var(--purple); }
    .auth-divider { display: flex; align-items: center; gap: 0.6rem; margin: 1.1rem 0; color: var(--mid); font-size: 0.7rem; text-transform: uppercase; letter-spacing: 1px; }
    .auth-divider::before, .auth-divider::after { content: ''; flex: 1; height: 1px; background: var(--border); }
    .auth-tabs { display: flex; border: 1.5px solid var(--border); border-radius: 10px; overflow: hidden; margin-bottom: 1rem; }
    .auth-tab { flex: 1; padding: 0.6rem; font-family: inherit; font-size: 0.85rem; font-weight: 700; background: transparent; border: none; color: var(--mid); cursor: pointer; transition: all 0.15s; }
    .auth-tab.active { background: var(--dark); color: var(--white); }
    .auth-field {
      width: 100%; padding: 0.8rem 1rem; margin-bottom: 0.7rem;
      border: 1.5px solid var(--border); border-radius: 8px; font-family: inherit;
      font-size: 0.9rem; background: var(--cream); color: var(--dark); outline: none;
    }
    .auth-field:focus { border-color: var(--purple); }
    .auth-msg { font-size: 0.8rem; margin-bottom: 0.7rem; min-height: 1rem; line-height: 1.5; }
    .auth-msg.err { color: #C0392B; }
    .auth-msg.ok { color: #1E8449; }
    .auth-link { background: none; border: none; color: var(--purple); font-family: inherit; font-size: 0.8rem; font-weight: 700; cursor: pointer; padding: 0; }
    .auth-link:hover { text-decoration: underline; }

    /* ══ ACCOUNT ══ */
    .acct-row { display: flex; justify-content: space-between; align-items: center; padding: 0.8rem 0; border-bottom: 1px solid var(--border); font-size: 0.9rem; }
    .acct-row:last-of-type { border-bottom: none; }
    .acct-label { color: var(--mid); }
    .acct-value { font-weight: 700; color: var(--dark); }
    .plan-badge { font-size: 0.62rem; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; padding: 0.28rem 0.65rem; border-radius: 6px; }
    .plan-badge.pro { background: var(--pink); color: var(--dark); }
    .plan-badge.free { background: var(--faint); color: var(--mid); }
    .nav-auth-btn.signed-in::after { content: ' ▾'; opacity: 0.6; }

    /* ══ TOAST ══ */
    .toast {
      position: fixed; left: 50%; bottom: 2rem; transform: translateX(-50%) translateY(1rem);
      background: var(--dark); color: var(--white); padding: 0.9rem 1.4rem; border-radius: 10px;
      font-size: 0.88rem; font-weight: 600; box-shadow: 0 8px 30px rgba(45, 32, 64, 0.35);
      opacity: 0; pointer-events: none; transition: opacity 0.25s, transform 0.25s; z-index: 300;
      max-width: 90%; text-align: center;
    }
    .toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ═══════════ v2 additions — multi-page shell ═══════════ */

/* Accessibility */
.skip-link { position: absolute; left: -9999px; top: 0; background: var(--dark); color: #fff; padding: 0.6rem 1rem; border-radius: 0 0 10px 0; z-index: 999; font-weight: 700; }
.skip-link:focus { left: 0; }
:focus-visible { outline: 3px solid var(--blue-deep); outline-offset: 2px; border-radius: 4px; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
}

/* Nav links (real pages) */
.nav a { text-decoration: none; }
.nav-links { display: flex; align-items: center; gap: 1.4rem; }
.nav-link { font-size: 0.86rem; font-weight: 700; color: var(--mid); padding: 0.35rem 0.2rem; border-bottom: 2px solid transparent; transition: color 0.15s; }
.nav-link:hover { color: var(--dark); }
.nav-link[aria-current="page"] { color: var(--dark); border-bottom-color: var(--pink); }
.logo { text-decoration: none; }
@media (max-width: 700px) {
  .nav { padding: 1rem 1.2rem; flex-wrap: wrap; gap: 0.6rem; }
  .nav-links { gap: 0.9rem; order: 3; width: 100%; justify-content: center; padding-top: 0.2rem; }
  .nav-link { font-size: 0.82rem; }
}

/* Page scaffolding */
.page { min-height: 100vh; display: flex; flex-direction: column; }
.page-main { flex: 1; }
.page-head { text-align: center; padding: 3.2rem 2rem 0.6rem; }
.page-head h1 { font-size: clamp(1.9rem, 4.5vw, 2.7rem); font-weight: 900; letter-spacing: -1px; }
.page-head p { color: var(--mid); max-width: 560px; margin: 0.7rem auto 0; line-height: 1.6; }
.page-body { width: 100%; max-width: 956px; margin: 0 auto; padding: 1.5rem 2.5rem 4rem; }
@media (max-width: 700px) { .page-body { padding: 1.2rem 1.2rem 3rem; } }

/* Cards & panels */
.panel { background: var(--white); border: 1px solid var(--border); border-radius: 20px; padding: 1.6rem; }
.panel + .panel { margin-top: 1.1rem; }
.panel-title { font-size: 0.78rem; font-weight: 800; letter-spacing: 1.5px; text-transform: uppercase; color: var(--mid); margin-bottom: 1rem; }
.panel-row { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 0.85rem 0; border-bottom: 1px solid var(--faint); }
.panel-row:last-child { border-bottom: none; }
.panel-row .k { font-size: 0.85rem; color: var(--mid); font-weight: 500; }
.panel-row .v { font-size: 0.92rem; font-weight: 700; text-align: right; word-break: break-word; }

/* Forms */
.field-label { display: block; font-size: 0.78rem; font-weight: 800; letter-spacing: 0.8px; text-transform: uppercase; color: var(--mid); margin: 1.1rem 0 0.4rem; }
.field { width: 100%; padding: 0.85rem 1rem; border: 1.5px solid var(--border); border-radius: 12px; font-family: inherit; font-size: 0.95rem; color: var(--dark); background: var(--white); transition: border-color 0.15s; }
.field:focus { outline: none; border-color: var(--purple); }
.field-hint { font-size: 0.78rem; color: var(--mid); margin-top: 0.35rem; }
.form-msg { min-height: 1.2rem; font-size: 0.85rem; font-weight: 600; margin-top: 0.7rem; }
.form-msg.ok { color: #2e7d52; }
.form-msg.err { color: #c0392b; }

/* Buttons (extends .btn) */
.btn:disabled { opacity: 0.55; cursor: not-allowed; transform: none !important; }
.btn-danger { background: #fff; color: #c0392b; border: 1.5px solid rgba(192, 57, 43, 0.35); }
.btn-danger:hover { background: rgba(192, 57, 43, 0.06); }
.btn-sm { padding: 0.5rem 0.95rem; font-size: 0.82rem; border-radius: 10px; }

/* Plan / usage */
.plan-hero { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.plan-hero-name { font-size: 1.5rem; font-weight: 900; letter-spacing: -0.5px; }
.plan-hero-sub { color: var(--mid); font-size: 0.88rem; margin-top: 0.2rem; }
.usage-track { height: 10px; background: var(--faint); border-radius: 99px; overflow: hidden; margin-top: 0.9rem; }
.usage-fill { height: 100%; background: linear-gradient(90deg, var(--pink), var(--purple)); border-radius: 99px; transition: width 0.4s; }
.usage-caption { display: flex; justify-content: space-between; font-size: 0.78rem; color: var(--mid); margin-top: 0.45rem; font-weight: 600; }

/* Avatar disc (profile + history) */
.disc { width: 46px; height: 46px; border-radius: 50%; background: var(--purple); color: var(--dark); display: flex; align-items: center; justify-content: center; font-weight: 900; font-size: 1rem; flex-shrink: 0; }
.disc.lg { width: 72px; height: 72px; font-size: 1.5rem; }
.disc.pink { background: var(--pink); } .disc.blue { background: var(--blue); } .disc.cream { background: var(--pink-light); }

/* History rows */
.history-row { display: flex; align-items: center; gap: 0.9rem; padding: 0.8rem 0; border-bottom: 1px solid var(--faint); }
.history-row:last-child { border-bottom: none; }
.history-title { font-weight: 700; font-size: 0.94rem; }
.history-meta { font-size: 0.78rem; color: var(--mid); margin-top: 0.15rem; }
.history-when { margin-left: auto; font-size: 0.78rem; color: var(--mid); white-space: nowrap; font-weight: 600; }

/* Empty states */
.empty { text-align: center; padding: 2.2rem 1rem; color: var(--mid); }
.empty .empty-icon { font-size: 1.8rem; margin-bottom: 0.5rem; }
.empty p { font-size: 0.9rem; line-height: 1.55; max-width: 380px; margin: 0 auto; }

/* Recorder */
.rec-stage { text-align: center; padding: 1.4rem 0 0.4rem; }
.rec-mic-btn { width: 92px; height: 92px; border-radius: 50%; border: none; cursor: pointer; background: var(--pink); display: inline-flex; align-items: center; justify-content: center; transition: transform 0.15s, background 0.2s; box-shadow: 0 10px 30px rgba(255, 175, 204, 0.5); }
.rec-mic-btn:hover { transform: scale(1.05); }
.rec-mic-btn.recording { background: #e74c3c; box-shadow: 0 10px 30px rgba(231, 76, 60, 0.4); animation: rec-pulse 1.6s infinite; }
@keyframes rec-pulse { 0% { transform: scale(1); } 50% { transform: scale(1.06); } 100% { transform: scale(1); } }
.rec-timer { font-size: 2rem; font-weight: 900; letter-spacing: 1px; margin-top: 1rem; font-variant-numeric: tabular-nums; }
.rec-hint { color: var(--mid); font-size: 0.85rem; margin-top: 0.3rem; }
.rec-level { display: flex; gap: 4px; align-items: flex-end; justify-content: center; height: 34px; margin-top: 1rem; }
.rec-level .lv { width: 6px; height: 6px; border-radius: 3px; background: var(--purple); transition: height 0.08s; }
.rec-quota { margin-top: 1.6rem; }

/* Pills of storyteller choices */
.chip-row { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.chip { padding: 0.5rem 1rem; border-radius: 99px; border: 1.5px solid var(--border); background: var(--white); font-family: inherit; font-weight: 700; font-size: 0.85rem; color: var(--mid); cursor: pointer; transition: all 0.15s; }
.chip.active { background: var(--dark); color: var(--cream); border-color: var(--dark); }

/* Banners */
.banner { display: flex; gap: 0.8rem; align-items: flex-start; border-radius: 14px; padding: 0.95rem 1.1rem; font-size: 0.87rem; line-height: 1.5; }
.banner.info { background: rgba(189, 224, 254, 0.35); border: 1px solid rgba(162, 210, 255, 0.7); }
.banner.warn { background: rgba(255, 200, 221, 0.3); border: 1px solid rgba(255, 175, 204, 0.6); }
.banner b { font-weight: 800; }

/* Footer (shared) */
.site-footer { border-top: 1px solid var(--border); padding: 2.6rem 2.5rem 2.2rem; text-align: center; margin-top: auto; }
.site-footer .f-brand { font-weight: 900; font-size: 1rem; }
.site-footer .f-brand span { color: var(--pink); }
.footer-nav { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.4rem 1.4rem; margin: 1rem 0 0.9rem; }
.footer-nav a { font-size: 0.82rem; font-weight: 600; color: var(--mid); text-decoration: none; }
.footer-nav a:hover { color: var(--dark); }
.f-copy { font-size: 0.76rem; color: var(--mid); }
.f-contact { font-size: 0.82rem; color: var(--mid); margin-top: 0.3rem; }
.f-contact a { color: var(--dark); font-weight: 700; }

/* Legal prose */
.prose { max-width: 720px; margin: 0 auto; line-height: 1.75; font-size: 0.95rem; }
.prose h2 { font-size: 1.15rem; font-weight: 900; margin: 2rem 0 0.6rem; letter-spacing: -0.3px; }
.prose p, .prose li { color: rgba(45, 32, 64, 0.8); }
.prose ul { padding-left: 1.2rem; margin: 0.5rem 0 1rem; }
.prose .updated { font-size: 0.8rem; color: var(--mid); font-weight: 600; }

/* 404 */
.notfound { text-align: center; padding: 6rem 2rem; }
.notfound .code { font-size: 5rem; font-weight: 900; letter-spacing: -3px; color: var(--pink); }

/* Story page extras */
.story-actions { display: flex; gap: 0.6rem; justify-content: center; flex-wrap: wrap; margin-top: 1.1rem; }
.more-stories { max-width: 640px; margin: 2.5rem auto 0; width: 100%; }
.more-label { font-size: 0.78rem; font-weight: 800; letter-spacing: 1.5px; text-transform: uppercase; color: var(--mid); margin-bottom: 0.8rem; text-align: center; }

/* Library deep-link steps stay as-is; ensure sections animate subtly */
.section { scroll-margin-top: 90px; }

/* Loading skeleton */
.skel { background: linear-gradient(90deg, var(--faint) 25%, rgba(45,32,64,0.1) 50%, var(--faint) 75%); background-size: 200% 100%; animation: skel 1.2s infinite; border-radius: 10px; }
@keyframes skel { from { background-position: 200% 0; } to { background-position: -200% 0; } }
