/* Retexta: deep navy, neon speed lines, messy speech becoming finished text. */
.w-retexta { --accent: #6A5AF9; --accent-text: #4F46E5; --accent-ink: #fff; --r-ink: #07052B; --r-ink2: #120B4A; --r-paper: #F4F1EA; --r-cyan: #22D3F5; --r-violet: #8A5CFF; --r-mag: #FF4FD8; background: var(--r-paper); }
.w-retexta h1 em, .w-retexta h2 em { background: linear-gradient(90deg, var(--r-cyan), var(--r-violet) 55%, var(--r-mag)); -webkit-background-clip: text; background-clip: text; color: transparent; padding-right: 0.06em; }
.w-retexta .paper h2 em { background: linear-gradient(90deg, #4F46E5, #8A5CFF 60%, #D63AB8); -webkit-background-clip: text; background-clip: text; }
.w-retexta .dark { background: var(--r-ink); }
.w-retexta .dark .eyebrow { color: var(--r-cyan); }
.w-retexta .eyebrow { color: #4F46E5; }

.r-hero { position: relative; overflow: hidden; isolation: isolate; padding: calc(var(--header-h) + clamp(28px, 6vw, 72px)) 0 clamp(64px, 9vw, 120px);
  background: radial-gradient(70% 60% at 80% 10%, rgba(138, 92, 255, 0.35), transparent 70%), radial-gradient(60% 50% at 0% 100%, rgba(34, 211, 245, 0.18), transparent 70%), var(--r-ink); color: var(--on-dark); }
#streaks { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; opacity: 0.9; }
.r-hero .split { align-items: center; }
@media (min-width: 821px) { .r-hero .split { grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); } }
.r-hero h1 { margin-top: 18px; max-width: 13ch; }
.r-hero .lede { margin-top: 20px; color: #C9C6E4; }
.r-hero .crumbs { color: #A9A4D6; }
.w-retexta .r-hero .eyebrow { color: var(--r-cyan); }
.r-hero .get-note { color: #C9C6E4; }
.r-hero .get-note span::before { background: var(--r-cyan); }

/* ------------------------------------------------------------ the demo */
.demo { position: relative; border-radius: 28px; padding: 18px; background: linear-gradient(160deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.03)); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.12), 0 40px 90px -40px rgba(0, 0, 0, 0.8); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px); }
.demo .tabs { display: flex; gap: 6px; padding: 4px; border-radius: 999px; background: rgba(0, 0, 0, 0.25); width: max-content; max-width: 100%; overflow-x: auto; }
.demo .tab { border: 0; cursor: pointer; padding: 8px 14px; border-radius: 999px; background: none; color: #C9C6E4; font-weight: 700; font-size: var(--fs-xs); white-space: nowrap; }
.demo .tab[aria-selected="true"] { background: #fff; color: var(--r-ink); }
.rec { margin-top: 14px; display: grid; grid-template-columns: auto 1fr auto; gap: 14px; align-items: center; padding: 12px 16px; border-radius: 18px; background: rgba(7, 5, 43, 0.55); }
.rec .dot { width: 12px; height: 12px; border-radius: 50%; background: #FF4D6D; box-shadow: 0 0 0 0 rgba(255, 77, 109, 0.6); }
.demo[data-state="rec"] .rec .dot { animation: recpulse 1.2s infinite; }
@keyframes recpulse { 0% { box-shadow: 0 0 0 0 rgba(255, 77, 109, 0.6); } 100% { box-shadow: 0 0 0 12px rgba(255, 77, 109, 0); } }
.wave { display: flex; align-items: center; gap: 3px; height: 34px; overflow: hidden; }
.wave i { flex: 1; min-width: 2px; max-width: 5px; height: 12%; border-radius: 3px; background: linear-gradient(var(--r-cyan), var(--r-violet)); transition: height 0.12s linear; }
.rec .time { font-variant-numeric: tabular-nums; font-weight: 700; font-size: var(--fs-xs); color: #C9C6E4; }
.raw { margin-top: 14px; min-height: 5.2em; padding: 0 4px; font-size: var(--fs-sm); line-height: 1.6; color: #B9B4E3; }
.raw .w { opacity: 0; transition: opacity 0.18s; }
.raw .w.on { opacity: 1; }
.raw .f { color: #8E88C2; }
.raw .f.cut { text-decoration: line-through; text-decoration-color: var(--r-mag); text-decoration-thickness: 2px; opacity: 0.55; }
.arrow { display: flex; align-items: center; gap: 10px; margin: 8px 4px 12px; font-size: var(--fs-xs); font-weight: 750; letter-spacing: 0.12em; text-transform: uppercase; color: var(--r-cyan); opacity: 0.4; transition: opacity 0.4s; }
.arrow::before, .arrow::after { content: ""; height: 1px; flex: 1; background: linear-gradient(90deg, transparent, rgba(34, 211, 245, 0.6), transparent); }
.demo[data-state="write"] .arrow, .demo[data-state="done"] .arrow { opacity: 1; }
.out { position: relative; border-radius: 18px; padding: 18px 20px; background: #fff; color: #14161F; min-height: 212px; box-shadow: 0 20px 40px -24px rgba(0, 0, 0, 0.6); overflow: hidden; }
.out .kind { font-size: var(--fs-xs); font-weight: 750; letter-spacing: 0.1em; text-transform: uppercase; color: #4F46E5; }
.out .ttl { margin-top: 6px; font-weight: 800; font-size: 1.05rem; }
.out .ln { margin-top: 8px; font-size: var(--fs-sm); line-height: 1.55; color: #2B2D3A; opacity: 0; transform: translateY(6px); transition: opacity 0.4s var(--ease), transform 0.4s var(--ease); }
.out .ln.on { opacity: 1; transform: none; }
.out .ln b { font-weight: 800; }
.out .shimmer { position: absolute; inset: 0; background: linear-gradient(100deg, transparent 30%, rgba(124, 108, 255, 0.18) 50%, transparent 70%); background-size: 250% 100%; opacity: 0; pointer-events: none; }
.demo[data-state="write"] .out .shimmer { opacity: 1; animation: shimmer 1.2s linear infinite; }
@keyframes shimmer { from { background-position: 120% 0; } to { background-position: -120% 0; } }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.chips span { padding: 5px 10px; border-radius: 999px; font-size: 0.75rem; font-weight: 750; background: rgba(34, 211, 245, 0.12); color: #A8F0FF; box-shadow: inset 0 0 0 1px rgba(34, 211, 245, 0.25); opacity: 0; transform: scale(0.9); transition: opacity 0.35s, transform 0.35s var(--ease); }
.chips span.on { opacity: 1; transform: none; }
.demo .note { margin-top: 12px; font-size: 0.75rem; color: #B3AEDB; }
.chips { min-height: 28px; }

/* ------------------------------------------------------------ formats */
.paper { background: var(--r-paper); }
.formats { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: 14px; }
.format { padding: 24px; border-radius: 22px; background: #fff; box-shadow: inset 0 0 0 1px rgba(20, 22, 31, 0.08); transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease); }
.format:hover { transform: translateY(-4px); box-shadow: inset 0 0 0 1px rgba(20, 22, 31, 0.08), 0 26px 50px -30px rgba(40, 30, 120, 0.4); }
.format .ico { width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; background: linear-gradient(135deg, rgba(34, 211, 245, 0.18), rgba(138, 92, 255, 0.2)); color: #4F46E5; margin-bottom: 16px; }
.format .ico svg { width: 22px; height: 22px; }
.format h3 { margin-bottom: 6px; }
.format p { color: #545769; font-size: var(--fs-sm); }

/* inputs flow */
.flow { display: grid; grid-template-columns: 1fr auto 1fr; gap: clamp(16px, 4vw, 48px); align-items: center; }
.flow .col { display: grid; gap: 10px; }
.flow .col span { display: flex; align-items: center; gap: 10px; padding: 12px 16px; border-radius: 16px; background: rgba(255, 255, 255, 0.06); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.1); font-weight: 700; font-size: var(--fs-sm); }
.flow .col span::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--r-cyan); box-shadow: 0 0 12px var(--r-cyan); }
.flow .col.outs span::before { background: var(--r-mag); box-shadow: 0 0 12px var(--r-mag); }
.flow .core { width: clamp(96px, 14vw, 150px); aspect-ratio: 1; border-radius: 30px; background: url(/assets/img/icon-retexta.webp) center/cover; box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.12), 0 0 80px rgba(138, 92, 255, 0.6); animation: core 4s ease-in-out infinite; }
@keyframes core { 0%, 100% { box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.12), 0 0 60px rgba(138, 92, 255, 0.45); } 50% { box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.2), 0 0 110px rgba(34, 211, 245, 0.55); } }
@media (max-width: 700px) { .flow { grid-template-columns: 1fr; justify-items: center; } .flow .col { width: 100%; grid-template-columns: 1fr 1fr; } }

/* languages marquee */
.langs { overflow: hidden; mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); -webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); margin-top: 28px; }
.langs .track { display: flex; gap: 12px; width: max-content; animation: marquee 40s linear infinite; }
.langs .track span { padding: 10px 18px; border-radius: 999px; font-family: var(--serif); font-size: 1.15rem; background: rgba(255, 255, 255, 0.06); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.1); white-space: nowrap; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* free vs pro */
.tiers { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: 16px; }
.tier { padding: clamp(24px, 3vw, 34px); border-radius: 26px; background: #fff; box-shadow: inset 0 0 0 1px rgba(20, 22, 31, 0.08); }
.tier.pro { background: linear-gradient(160deg, #1B1160, #07052B); color: #fff; box-shadow: 0 30px 70px -40px rgba(40, 20, 120, 0.8); }
.tier h3 { font-family: var(--serif); font-weight: 450; font-size: 1.6rem; }
.tier p { margin-top: 8px; color: #545769; font-size: var(--fs-sm); }
.tier.pro p { color: #C9C6E4; }
.tier ul { margin: 18px 0 0; padding: 0; list-style: none; display: grid; gap: 10px; font-size: var(--fs-sm); }
.tier li { display: flex; gap: 10px; }
.tier li::before { content: ""; flex: none; width: 18px; height: 18px; margin-top: 2px; border-radius: 50%; background: #4F46E5 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M6 10.5l2.6 2.6L14 7.6' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/100% no-repeat; }
.tier.pro li::before { background-color: var(--r-violet); }

.honest { display: flex; gap: 16px; align-items: flex-start; padding: 22px 24px; border-radius: 20px; background: rgba(79, 70, 229, 0.06); box-shadow: inset 0 0 0 1px rgba(79, 70, 229, 0.15); color: #2B2D3A; font-size: var(--fs-sm); }
.honest b { display: block; margin-bottom: 4px; }

.w-retexta .gallery { display: flex; gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 8px var(--gutter) 24px; margin-inline: calc(var(--gutter) * -1); scrollbar-width: none; }
.w-retexta .gallery img { flex: none; width: min(240px, 62vw); height: auto; aspect-ratio: 9 / 16; border-radius: 22px; scroll-snap-align: center; box-shadow: 0 24px 50px -28px rgba(20, 8, 60, 0.55); }
.w-retexta .final { background: radial-gradient(60% 80% at 50% 100%, rgba(138, 92, 255, 0.35), transparent 70%), var(--r-ink); color: #fff; }
.w-retexta .final .get-note { color: #C9C6E4; }

/* while recording, the output card shows where the text will go */
.demo[data-state="rec"] .out .body::before { content: ""; display: block; height: 104px; margin-top: 12px; border-radius: 8px;
  background: repeating-linear-gradient(180deg, #EEF0F6 0 12px, transparent 12px 26px); mask-image: linear-gradient(90deg, #000 70%, transparent); -webkit-mask-image: linear-gradient(90deg, #000 70%, transparent); animation: pulse 1.4s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: 0.45; } }
