/* Flip Studio — getflipstudio.com */

/* Inter (SIL OFL 1.1, assets/fonts/OFL.txt), subset to Latin and served from this site so no
   third-party font host sees visitors. */
@font-face {
  font-family: "Inter";
  font-weight: 400;
  font-display: swap;
  src: url("assets/fonts/inter-regular.woff2") format("woff2");
}

@font-face {
  font-family: "Inter";
  font-weight: 600;
  font-display: swap;
  src: url("assets/fonts/inter-semibold.woff2") format("woff2");
}

@font-face {
  font-family: "Inter";
  font-weight: 700;
  font-display: swap;
  src: url("assets/fonts/inter-bold.woff2") format("woff2");
}

:root {
  --bg: #08080a;
  --bg-2: #0d0e11;
  --surface: #131418;
  --surface-2: #1a1b20;
  --border: #24262c;
  --border-hi: #34363e;
  --text: #f4f4f5;
  --muted: #9fa1aa;
  --faint: #6b6e78;
  --accent: #55e5c5;
  --accent-hi: #8af2db;
  --accent-lo: #1fb8e8;
  --accent-ink: #032019;
  --accent-soft: rgba(85, 229, 197, 0.12);
  --good: #4ade80;
  --bad: #f87171;
  --radius: 16px;
  --max: 1180px;
  --gutter: 20px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  color-scheme: dark;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 6px;
}

code {
  font-size: 0.92em;
  padding: 1px 6px;
  border-radius: 6px;
  background: var(--surface-2);
}

.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.gradient-text {
  background: linear-gradient(120deg, var(--accent-hi), var(--accent) 40%, var(--accent-lo));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(8, 8, 10, 0.72);
  backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 66px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-weight: 700;
  font-size: 18px;
  white-space: nowrap;
}

.brand:hover {
  text-decoration: none;
}

.brand img {
  width: 34px;
  height: 34px;
}

.nav {
  display: flex;
  align-items: center;
  gap: 24px;
  font-size: 15px;
}

.nav a {
  color: var(--muted);
}

.nav a:hover {
  color: var(--text);
  text-decoration: none;
}

.nav a.btn-primary,
.nav a.btn-primary:hover {
  color: var(--accent-ink);
}

.nav .icon-link {
  display: inline-flex;
}

.nav .icon-link svg {
  width: 20px;
  height: 20px;
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 24px;
  border-radius: 12px;
  font-weight: 600;
  font-size: 16px;
  border: 1px solid transparent;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 0.15s var(--ease), box-shadow 0.15s var(--ease), background 0.15s var(--ease),
    border-color 0.15s var(--ease);
}

.btn:hover {
  text-decoration: none;
  transform: translateY(-2px);
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent-hi), var(--accent) 45%, var(--accent-lo));
  color: var(--accent-ink);
  box-shadow: 0 10px 34px rgba(40, 205, 210, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.35);
}

.btn-primary:hover {
  box-shadow: 0 14px 44px rgba(40, 205, 210, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.35);
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.04);
  border-color: var(--border-hi);
  color: var(--text);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: #4a4d57;
}

.btn-small {
  padding: 9px 16px;
  font-size: 14px;
  border-radius: 10px;
}

.btn svg {
  width: 20px;
  height: 20px;
  flex: none;
}

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

.hero {
  position: relative;
  padding: 72px 0 40px;
  overflow: hidden;
  isolation: isolate;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  /* The blurred glows reach past the hero; fade them out instead of clipping to a hard edge. */
  mask-image: linear-gradient(180deg, #000 60%, transparent);
  -webkit-mask-image: linear-gradient(180deg, #000 60%, transparent);
}

.hero-bg::before,
.hero-bg::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.55;
}

.hero-bg::before {
  width: 620px;
  height: 620px;
  right: -120px;
  top: -160px;
  background: radial-gradient(circle, rgba(85, 229, 197, 0.45), transparent 65%);
  animation: drift 18s ease-in-out infinite alternate;
}

.hero-bg::after {
  width: 520px;
  height: 520px;
  left: -200px;
  bottom: -220px;
  background: radial-gradient(circle, rgba(31, 150, 232, 0.3), transparent 65%);
  animation: drift 22s ease-in-out infinite alternate-reverse;
}

.hero-grid {
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image: linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 30%, #000 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 30%, #000 30%, transparent 75%);
}

@keyframes drift {
  to {
    transform: translate(-60px, 40px) scale(1.08);
  }
}

/* Like the big editors' sites: the pitch on top, centred, and the editor at work underneath, wide. */
.hero-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  justify-items: center;
  gap: 56px;
  text-align: center;
}

.hero-layout > div:first-child {
  max-width: 820px;
}

.hero-layout .lead {
  margin-left: auto;
  margin-right: auto;
  max-width: 680px;
}

.hero-layout .cta-row,
.hero-layout .checks {
  justify-content: center;
}

.hero-layout .hero-visual {
  width: 100%;
  max-width: 1180px;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 22px;
  padding: 6px 14px 6px 8px;
  border: 1px solid var(--border-hi);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  font-size: 14px;
}

.pill b {
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-ink);
  font-size: 12px;
  font-weight: 700;
}

h1 {
  margin: 0 0 20px;
  font-size: clamp(40px, 5.6vw, 68px);
  line-height: 1.04;
  letter-spacing: -0.03em;
}

.lead {
  margin: 0 0 32px;
  max-width: 540px;
  color: var(--muted);
  font-size: clamp(17px, 1.8vw, 20px);
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.checks {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin: 26px 0 0;
  padding: 0;
  list-style: none;
  color: var(--muted);
  font-size: 14px;
}

.checks li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.checks svg {
  width: 16px;
  height: 16px;
  color: var(--accent);
}

.hero-visual {
  position: relative;
  perspective: 1600px;
}

.app-frame {
  position: relative;
  border-radius: 14px;
  border: 1px solid var(--border-hi);
  background: var(--surface);
  box-shadow: 0 40px 120px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(85, 229, 197, 0.06),
    0 0 80px rgba(40, 205, 210, 0.12);
  overflow: hidden;
  transform: rotateX(8deg) scale(0.97);
  transform-origin: 50% 0;
  transition: transform 0.6s var(--ease);
}

.hero-visual:hover .app-frame {
  transform: rotateX(0deg) scale(1);
}

.app-frame .titlebar {
  display: flex;
  align-items: center;
  gap: 7px;
  height: 30px;
  padding: 0 12px;
  background: #0e0f12;
  border-bottom: 1px solid var(--border);
  color: var(--faint);
  font-size: 12px;
}

.app-frame .titlebar img {
  width: 14px;
  height: 14px;
}

.float-chip {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border: 1px solid var(--border-hi);
  border-radius: 12px;
  background: rgba(19, 20, 24, 0.86);
  backdrop-filter: blur(10px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5);
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  animation: bob 6s ease-in-out infinite;
}

.float-chip small {
  display: block;
  color: var(--muted);
  font-weight: 400;
  font-size: 12px;
}

.float-chip .dot {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 9px;
  background: var(--accent-soft);
  color: var(--accent);
}

.float-chip .dot svg {
  width: 16px;
  height: 16px;
}

.chip-a {
  left: -26px;
  bottom: 18%;
}

.chip-b {
  right: -14px;
  top: 12%;
  animation-delay: -3s;
}

@keyframes bob {
  50% {
    transform: translateY(-10px);
  }
}

/* ---------- Stats ---------- */

.stats {
  padding: 28px 0 8px;
}

.stats-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.025), transparent);
}

.stat {
  padding: 22px 18px;
  text-align: center;
}

.stat + .stat {
  border-left: 1px solid var(--border);
}

.stat strong {
  display: block;
  font-size: clamp(26px, 3.4vw, 38px);
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.stat span {
  color: var(--muted);
  font-size: 14px;
}

/* ---------- Sections ---------- */

section {
  padding: 96px 0;
}

.kicker {
  display: block;
  margin-bottom: 12px;
  color: var(--accent);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.section-head {
  max-width: 720px;
  margin: 0 auto 48px;
  text-align: center;
}

.section-title {
  margin: 0 0 14px;
  font-size: clamp(30px, 4.2vw, 48px);
  line-height: 1.1;
  letter-spacing: -0.025em;
}

.section-lead {
  margin: 0;
  color: var(--muted);
  font-size: 18px;
}

/* ---------- Tour ---------- */

/* Stage: the four videos sit on top of each other; the active one fades in with a slow zoom. */
.tour-stage {
  position: relative;
  max-width: 1080px;
  margin: 0 auto;
  aspect-ratio: 16 / 9;
  border: 1px solid var(--border-hi);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface);
  box-shadow: 0 40px 100px rgba(0, 0, 0, 0.6);
}

.tour-stage img,
.tour-stage video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transform: scale(1.04);
  filter: blur(6px);
  transition: opacity 0.6s var(--ease), transform 1.2s var(--ease), filter 0.6s var(--ease);
}

.tour-stage img.is-active,
.tour-stage video.is-active {
  opacity: 1;
  transform: scale(1);
  filter: none;
}

.tour-stage::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.04), inset 0 -80px 120px rgba(8, 8, 10, 0.25);
}

/* Cards under the stage: hover (or tap) one to show its screenshot. */
.tour-tabs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  max-width: 1080px;
  margin: 18px auto 0;
}

.tour-tab {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 24px 18px 26px;
  border: 1px solid transparent;
  border-radius: 14px;
  background: transparent;
  color: var(--faint);
  font: inherit;
  text-align: center;
  cursor: pointer;
  overflow: hidden;
  transition: border-color 0.3s var(--ease), background 0.3s var(--ease), color 0.3s var(--ease),
    transform 0.3s var(--ease);
}

.tour-tab:hover {
  color: var(--muted);
}

.tour-tab > svg {
  width: 30px;
  height: 30px;
  margin-bottom: 14px;
  color: var(--accent);
  opacity: 0.55;
  transition: opacity 0.3s var(--ease), transform 0.4s var(--ease);
}

.tour-tab strong {
  font-size: 17px;
  line-height: 1.3;
  color: inherit;
}

.tour-tab span {
  display: block;
  margin-top: 8px;
  font-size: 14px;
  line-height: 1.5;
}

.tour-tab[aria-selected="true"] {
  border-color: var(--border-hi);
  background: var(--surface);
  color: var(--muted);
  transform: translateY(-2px);
}

.tour-tab[aria-selected="true"] strong {
  color: var(--text);
}

.tour-tab[aria-selected="true"] > svg {
  opacity: 1;
  transform: scale(1.08);
}

/* Progress bar of the automatic rotation, at the bottom of the active card. */
.tour-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent-hi), var(--accent-lo));
  transform: scaleX(0);
  transform-origin: left;
}

.tour-tab[aria-selected="true"] .tour-progress {
  transform: scaleX(1);
  transition: transform var(--tour-interval, 5s) linear;
}

.tour-tabs.is-paused .tour-progress {
  transition: none;
  transform: scaleX(0);
}

.tour-tabs.is-paused .tour-tab[aria-selected="true"] .tour-progress {
  transform: scaleX(1);
}

/* Hero video inside the window frame. */
.app-frame video {
  width: 100%;
  aspect-ratio: 1600 / 840;
  background: #0b0c0e;
}

/* The web editor, under the tour: copy on the left, a screenshot on the right. */
.web-editor {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  align-items: center;
  gap: 48px;
  max-width: 1080px;
  margin: 72px auto 0;
  padding: 36px;
  border: 1px solid var(--border);
  border-radius: 24px;
  background: linear-gradient(180deg, var(--bg-2), var(--bg));
}

.web-editor h3 {
  margin: 10px 0 12px;
  font-size: clamp(24px, 3vw, 32px);
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.web-editor p {
  margin: 0 0 22px;
  color: var(--muted);
}

.web-editor-shot {
  margin: 0;
  border: 1px solid var(--border-hi);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55), 0 0 60px rgba(40, 205, 210, 0.08);
}

.web-editor-shot img {
  width: 100%;
}

/* A looping video behind a block, darkened so the text on top stays readable. */
.has-bg-video {
  position: relative;
  overflow: hidden;
  isolation: isolate;
}

.bg-video {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
}

.has-bg-video::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
}

.web-editor.has-bg-video {
  background: var(--bg);
}

.web-editor.has-bg-video::after {
  background: linear-gradient(90deg, rgba(8, 8, 10, 0.92) 0%, rgba(8, 8, 10, 0.78) 45%, rgba(8, 8, 10, 0.55) 100%);
}

.web-editor.has-bg-video p {
  color: #c9ccd2;
}

/* «Herramientas de editor profesional»: the heading sits on a band with the video behind. */
.section-band {
  max-width: 1080px;
  padding: 72px 32px;
  border: 1px solid var(--border);
  border-radius: 24px;
  background: var(--bg);
}

.section-band::after {
  background: radial-gradient(ellipse at center, rgba(8, 8, 10, 0.62), rgba(8, 8, 10, 0.86));
}

.section-band .section-title,
.section-band .section-lead {
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
}

.section-band .section-lead {
  color: #c9ccd2;
}

.final.has-bg-video::after {
  background: linear-gradient(180deg, var(--bg) 0%, rgba(8, 8, 10, 0.8) 30%, rgba(8, 8, 10, 0.8) 70%, var(--bg) 100%);
}

/* The turquoise glow goes over the darkened video, the content over both. */
.final.has-bg-video::before {
  z-index: 0;
}

.final.has-bg-video > .wrap {
  position: relative;
  z-index: 1;
}

.final.has-bg-video p {
  color: #c9ccd2;
}

@media (max-width: 860px) {
  .section-band {
    padding: 48px 20px;
  }

  .web-editor.has-bg-video::after {
    background: rgba(8, 8, 10, 0.82);
  }
}

@media (max-width: 860px) {
  .web-editor {
    grid-template-columns: 1fr;
    gap: 28px;
    margin-top: 48px;
    padding: 22px;
  }
}

/* ---------- Feature rows ---------- */

.rows {
  display: grid;
  gap: 28px;
}

.row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 56px;
  padding: 36px;
  border: 1px solid var(--border);
  border-radius: 24px;
  background: linear-gradient(180deg, var(--bg-2), var(--bg));
}

.row:nth-child(even) .row-visual {
  order: -1;
}

.row h3 {
  margin: 0 0 12px;
  font-size: clamp(24px, 3vw, 32px);
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.row p {
  margin: 0 0 22px;
  color: var(--muted);
}

.row ul {
  margin: 0 0 26px;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 8px;
  color: #cfd0d6;
  font-size: 15px;
}

.row li {
  display: flex;
  gap: 10px;
}

.row li::before {
  content: "";
  flex: none;
  width: 6px;
  height: 6px;
  margin-top: 9px;
  border-radius: 50%;
  background: var(--accent);
}

.row-visual {
  position: relative;
  min-height: 300px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: radial-gradient(circle at 50% 0%, rgba(85, 229, 197, 0.08), transparent 60%), var(--surface);
  overflow: hidden;
  display: grid;
  place-items: center;
  padding: 28px;
}

/* Visual: transitions mosaic */

.mosaic {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  width: 100%;
}

.tile {
  position: relative;
  aspect-ratio: 16 / 10;
  border-radius: 10px;
  overflow: hidden;
  background: var(--g);
}

.tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--g2);
  animation: var(--anim) 3.2s var(--ease) infinite;
}

.tile span {
  position: absolute;
  z-index: 1;
  left: 8px;
  bottom: 6px;
  font-size: 11px;
  font-weight: 600;
  color: #fff;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.7);
}

@keyframes wipe {
  0%, 25% { clip-path: inset(0 100% 0 0); }
  60%, 100% { clip-path: inset(0 0 0 0); }
}

@keyframes iris {
  0%, 25% { clip-path: circle(0% at 50% 50%); }
  60%, 100% { clip-path: circle(75% at 50% 50%); }
}

@keyframes fade {
  0%, 25% { opacity: 0; }
  60%, 100% { opacity: 1; }
}

@keyframes slide {
  0%, 25% { transform: translateY(100%); }
  60%, 100% { transform: translateY(0); }
}

@keyframes zoomin {
  0%, 25% { transform: scale(0); border-radius: 50%; }
  60%, 100% { transform: scale(1); border-radius: 0; }
}

@keyframes glitch {
  0%, 30% { clip-path: inset(0 0 100% 0); transform: translateX(0); }
  40% { clip-path: inset(20% 0 50% 0); transform: translateX(-8px); }
  50% { clip-path: inset(60% 0 10% 0); transform: translateX(6px); }
  60%, 100% { clip-path: inset(0 0 0 0); transform: translateX(0); }
}

/* Visual: title styles */

.styles {
  display: grid;
  gap: 18px;
  width: 100%;
  text-align: center;
}

.ts {
  font-size: clamp(30px, 4vw, 44px);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.01em;
}

.ts-neon {
  color: #fff6d6;
  text-shadow: 0 0 6px #ffcf33, 0 0 18px #ffb300, 0 0 40px #ff8a00;
  animation: flicker 4s infinite;
}

@keyframes flicker {
  0%, 18%, 22%, 62%, 64%, 100% { opacity: 1; }
  20%, 63% { opacity: 0.55; }
}

.ts-chrome {
  background: linear-gradient(180deg, #fff 0%, #c9ced6 45%, #6f7682 52%, #e7ebf0 70%, #9aa1ad 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 2px 0 #2b2e35);
}

.ts-karaoke {
  background: linear-gradient(90deg, var(--accent) 0 50%, rgba(255, 255, 255, 0.35) 50% 100%);
  background-size: 200% 100%;
  background-position: 100% 0;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: sing 3.5s linear infinite;
}

@keyframes sing {
  to { background-position: 0 0; }
}

.ts-holo {
  background: linear-gradient(110deg, #7cf7ff, #b48cff, #ff8ad8, #ffe27a, #7cf7ff);
  background-size: 300% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: holo 5s linear infinite;
}

@keyframes holo {
  to { background-position: 300% 0; }
}

/* Visual: keyframe curve */

.curve {
  width: 100%;
  max-width: 440px;
}

.curve .track {
  stroke: var(--border-hi);
}

.curve .path {
  stroke: var(--accent);
  stroke-dasharray: 600;
  stroke-dashoffset: 600;
  animation: draw 3.5s var(--ease) infinite;
}

.curve .kf {
  fill: var(--accent);
  stroke: var(--bg);
  stroke-width: 3;
}

.curve .runner {
  fill: #fff;
  offset-path: path("M30 170 C 120 170, 140 40, 220 60 S 330 170, 410 50");
  animation: run 3.5s var(--ease) infinite;
}

@keyframes draw {
  0% { stroke-dashoffset: 600; }
  60%, 100% { stroke-dashoffset: 0; }
}

@keyframes run {
  0% { offset-distance: 0%; opacity: 0; }
  10% { opacity: 1; }
  60% { offset-distance: 100%; opacity: 1; }
  70%, 100% { offset-distance: 100%; opacity: 0; }
}

/* Visual: audio */

.wave {
  display: flex;
  align-items: center;
  gap: 4px;
  width: 100%;
  height: 160px;
}

.wave i {
  flex: 1;
  height: calc(var(--h) * 1%);
  border-radius: 3px;
  background: linear-gradient(180deg, var(--accent-hi), var(--accent-lo));
  animation: pulse 1.6s ease-in-out infinite;
  animation-delay: calc(var(--d) * -0.1s);
  transform-origin: center;
}

@keyframes pulse {
  50% { transform: scaleY(0.45); opacity: 0.7; }
}

.beats {
  display: flex;
  justify-content: space-between;
  width: 100%;
  margin-top: 16px;
}

.beats b {
  width: 2px;
  height: 18px;
  border-radius: 2px;
  background: rgba(122, 200, 255, 0.6);
}

.audio-labels {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.tag {
  padding: 5px 11px;
  border: 1px solid var(--border-hi);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.03);
  color: #d4d5da;
  font-size: 13px;
}

/* Visual: auto captions, word by word */

.caption-demo {
  width: 100%;
  max-width: 420px;
}

.cd-screen {
  position: relative;
  aspect-ratio: 16 / 10;
  border-radius: 14px;
  overflow: hidden;
  background:
    radial-gradient(circle at 70% 25%, rgba(85, 229, 197, 0.25), transparent 45%),
    linear-gradient(160deg, #1b2440, #0b0f1d 70%);
  border: 1px solid var(--border-hi);
}

/* A speaker in silhouette: head and shoulders. */
.cd-person {
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 46%;
  height: 72%;
  transform: translateX(-50%);
  background:
    radial-gradient(circle at 50% 26%, #2c3555 0 19%, transparent 19.5%),
    radial-gradient(ellipse at 50% 100%, #2c3555 0 55%, transparent 55.5%);
  opacity: 0.9;
}

.cd-cap {
  position: absolute;
  left: 6%;
  right: 6%;
  bottom: 12%;
  text-align: center;
  font-size: clamp(16px, 2.1vw, 24px);
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
  word-spacing: 0.12em;
  color: #fff;
  text-shadow: 0 2px 0 #000, 0 0 6px rgba(0, 0, 0, 0.8);
}

.cd-cap span {
  display: inline-block;
  margin: 0 0.06em;
  animation: speak 4.8s var(--ease) infinite;
  animation-delay: calc(var(--i) * 0.6s);
}

/* The word being said lights up and pops, karaoke style. */
@keyframes speak {
  0% { color: #fff; transform: scale(1); }
  4% { color: var(--accent); transform: scale(1.18); }
  12% { color: var(--accent); transform: scale(1); }
  16%, 100% { color: #fff; transform: scale(1); }
}

.cd-cap .cd-key {
  color: var(--accent);
  animation-name: speak-key;
}

@keyframes speak-key {
  0% { transform: scale(1); }
  4% { transform: scale(1.22); }
  12%, 100% { transform: scale(1.06); }
}

/* Extras */

.extras-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.extra {
  display: grid;
  gap: 14px;
  align-content: start;
  padding: 22px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: linear-gradient(180deg, var(--bg-2), var(--bg));
  transition: border-color 0.2s var(--ease), transform 0.2s var(--ease);
}

.extra:hover {
  border-color: var(--border-hi);
  transform: translateY(-2px);
}

.extra-icon {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: var(--accent-soft);
  color: var(--accent);
}

.extra-icon svg {
  width: 22px;
  height: 22px;
}

.extra h3 {
  margin: 0 0 6px;
  font-size: 17px;
  line-height: 1.25;
}

.extra-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.extra-size {
  display: inline-block;
  padding: 1px 8px;
  border: 1px solid var(--border-hi);
  border-radius: 999px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}

.extra p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

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

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

/* Visual: export */

.export-card {
  width: 100%;
  max-width: 420px;
  padding: 22px;
  border: 1px solid var(--border-hi);
  border-radius: 14px;
  background: var(--bg-2);
}

.export-card .head {
  display: flex;
  justify-content: space-between;
  margin-bottom: 16px;
  font-weight: 600;
}

.export-card .head span {
  color: var(--muted);
  font-weight: 400;
  font-size: 14px;
}

.formats {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

.formats .tag.on {
  border-color: rgba(85, 229, 197, 0.55);
  background: var(--accent-soft);
  color: var(--accent);
}

.bar {
  height: 8px;
  border-radius: 999px;
  background: var(--surface-2);
  overflow: hidden;
}

.bar i {
  display: block;
  height: 100%;
  width: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--accent-hi), var(--accent-lo));
  animation: progress 4s var(--ease) infinite;
}

@keyframes progress {
  0% { width: 0; }
  70%, 100% { width: 100%; }
}

.export-card .foot {
  display: flex;
  justify-content: space-between;
  margin-top: 12px;
  color: var(--muted);
  font-size: 13px;
}

.export-card .done {
  color: var(--good);
  animation: done 4s infinite;
}

@keyframes done {
  0%, 69% { opacity: 0; }
  72%, 100% { opacity: 1; }
}

/* ---------- Comparison ---------- */

.compare {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  max-width: 940px;
  margin: 0 auto;
}

.compare-card {
  padding: 30px;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: var(--surface);
}

.compare-card.us {
  border-color: rgba(85, 229, 197, 0.5);
  background: linear-gradient(180deg, rgba(85, 229, 197, 0.08), var(--surface) 55%);
  box-shadow: 0 30px 80px rgba(40, 200, 215, 0.08);
}

.compare-card h3 {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 18px;
  font-size: 20px;
}

.compare-card h3 img {
  width: 28px;
  height: 28px;
}

.compare-card ul {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 12px;
}

.compare-card li {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  color: #cfd0d6;
}

.compare-card li svg {
  flex: none;
  width: 20px;
  height: 20px;
  margin-top: 2px;
}

.compare-card .no svg {
  color: var(--bad);
}

.compare-card .yes svg {
  color: var(--good);
}

.compare-card.them li {
  color: var(--muted);
}

/* ---------- Roadmap ---------- */

.timeline {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

/* Four stages side by side need room; in between, two by two (the connecting line only reads
   as one row, so it goes). */
@media (max-width: 1100px) and (min-width: 981px) {
  .timeline {
    grid-template-columns: repeat(2, 1fr);
  }

  .timeline::before {
    display: none;
  }
}

.timeline::before {
  content: "";
  position: absolute;
  left: 4%;
  right: 4%;
  top: 22px;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), var(--accent) 42%, var(--border-hi) 62%, var(--border) 100%);
}

.stage {
  position: relative;
  padding-top: 56px;
}

.stage::before {
  content: "";
  position: absolute;
  top: 14px;
  left: 24px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 3px solid var(--bg);
  background: var(--border-hi);
  box-shadow: 0 0 0 2px var(--border-hi);
}

.stage.now::before {
  background: var(--accent);
  box-shadow: 0 0 0 2px var(--accent), 0 0 24px rgba(85, 229, 197, 0.6);
}

.stage-card {
  height: 100%;
  padding: 24px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: var(--surface);
}

.stage-card .when {
  color: var(--accent);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.stage-card h3 {
  margin: 6px 0 12px;
  font-size: 20px;
}

.stage-card ul {
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
  font-size: 15px;
}

.stage-card li + li {
  margin-top: 6px;
}

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

.faq-layout {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 56px;
  align-items: start;
}

.faq-layout .section-title {
  text-align: left;
}

.faq-side p {
  color: var(--muted);
}

.faq details {
  border-bottom: 1px solid var(--border);
}

.faq summary {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 22px 0;
  cursor: pointer;
  font-weight: 600;
  font-size: 17px;
  list-style: none;
}

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

.faq summary::after {
  content: "";
  flex: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--accent-soft)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffc400' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='M12 7v10M7 12h10'/%3E%3C/svg%3E")
    center / 14px no-repeat;
  transition: transform 0.25s var(--ease);
}

.faq details[open] summary::after {
  transform: rotate(45deg);
}

.faq details p {
  margin: -6px 0 22px;
  color: var(--muted);
}

/* ---------- Final CTA ---------- */

.final {
  position: relative;
  padding: 110px 0;
  text-align: center;
  overflow: hidden;
  isolation: isolate;
}

.final::before {
  content: "";
  position: absolute;
  inset: 10% 15%;
  z-index: -1;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(60, 215, 205, 0.22), transparent);
  filter: blur(40px);
}

.final img {
  width: 108px;
  height: 108px;
  margin: 0 auto 24px;
  filter: drop-shadow(0 16px 50px rgba(40, 205, 210, 0.45));
}

.final .section-title {
  margin-bottom: 12px;
}

.final p {
  margin: 0 auto 32px;
  max-width: 560px;
  color: var(--muted);
}

.final .cta-row {
  justify-content: center;
}

.note {
  margin: 22px auto 0;
  max-width: 620px;
  padding: 14px 18px;
  border-left: 3px solid var(--accent);
  background: rgba(85, 229, 197, 0.06);
  border-radius: 8px;
  color: var(--muted);
  font-size: 14px;
  text-align: left;
}

.cta-meta {
  margin-top: 16px;
  color: var(--muted);
  font-size: 14px;
}

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

.site-footer {
  position: relative;
  border-top: 1px solid var(--border);
  padding: 56px 0 0;
  color: var(--muted);
  font-size: 14px;
  overflow: hidden;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 32px;
}

.footer-grid h4 {
  margin: 0 0 14px;
  color: var(--text);
  font-size: 14px;
}

.footer-grid ul {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 10px;
}

.footer-grid a {
  color: var(--muted);
}

.footer-grid a:hover,
.footer-grid .brand {
  color: var(--text);
}

.footer-brand p {
  max-width: 300px;
  margin: 14px 0 0;
}

.wordmark {
  margin: 48px 0 -0.18em;
  font-size: clamp(64px, 17vw, 230px);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.05em;
  text-align: center;
  white-space: nowrap;
  color: transparent;
  -webkit-text-stroke: 1px rgba(85, 229, 197, 0.5);
  background: linear-gradient(180deg, rgba(85, 229, 197, 0.26), rgba(31, 184, 232, 0.04) 80%);
  -webkit-background-clip: text;
  background-clip: text;
  user-select: none;
}

.footer-bottom {
  position: relative;
  padding: 20px 0 28px;
  border-top: 1px solid var(--border);
  background: var(--bg);
}

.footer-bottom-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
}

/* Legal pages keep the simpler footer */

.footer-simple .wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 18px;
  padding-bottom: 40px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
}

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

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

/* ---------- Legal pages ---------- */

.legal {
  max-width: 780px;
  margin: 0 auto;
  padding: 56px var(--gutter) 80px;
}

.legal h1 {
  font-size: clamp(30px, 5vw, 42px);
}

.legal h2 {
  margin-top: 40px;
  font-size: 22px;
}

.legal p,
.legal li {
  color: #c9cad0;
}

.legal .updated {
  color: var(--muted);
  font-size: 15px;
}

/* ---------- Release notes (novedades.html) ---------- */

.release {
  padding-top: 8px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  margin-top: 40px;
}

.release:first-of-type {
  border-top: 0;
}

.release h3 {
  margin-top: 26px;
  font-size: 17px;
}

.release code {
  font-size: 0.9em;
}

.release-toc a {
  white-space: nowrap;
}

/* ---------- Reveal on scroll (main.js adds .in) ---------- */

.js .reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}

.js .reveal.in {
  opacity: 1;
  transform: none;
}

/* ---------- Responsive ---------- */

@media (max-width: 980px) {
  .hero-layout,
  .row,
  .faq-layout {
    grid-template-columns: 1fr;
  }

  .hero-layout {
    gap: 56px;
  }

  .row {
    gap: 28px;
    padding: 24px;
  }

  .row:nth-child(even) .row-visual {
    order: 0;
  }

  .tour-tabs {
    grid-template-columns: 1fr 1fr;
  }

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

  .timeline::before {
    left: 32px;
    right: auto;
    top: 0;
    bottom: 0;
    width: 2px;
    height: auto;
    background: linear-gradient(180deg, var(--accent), var(--border) 70%);
  }

  .stage {
    padding: 0 0 0 64px;
  }

  .stage::before {
    top: 26px;
    left: 24px;
  }

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

  .footer-brand {
    grid-column: 1 / -1;
  }
}

/* The page links need about 1000 px next to the logo and the two buttons; below that they
   would push the page sideways, so only the buttons stay. */
@media (max-width: 1040px) {
  .nav .nav-hide {
    display: none;
  }
}

/* .btn spaces its children with a gap: the label's second half follows straight on. */
.nav .nav-long {
  margin-left: calc(-10px + 0.28em);
}

@media (max-width: 720px) {
  .nav .nav-long {
    display: none;
  }

  .nav {
    gap: 10px;
  }

  .nav .btn-small {
    padding: 8px 12px;
  }

  section {
    padding: 72px 0;
  }

  .hero {
    padding-top: 48px;
  }

  .btn {
    width: 100%;
  }

  .nav .btn {
    width: auto;
  }

  .app-frame,
  .hero-visual:hover .app-frame {
    transform: none;
  }

  .chip-a {
    left: 8px;
    bottom: -22px;
  }

  .chip-b {
    right: 8px;
    top: -22px;
  }

  .stats-row {
    grid-template-columns: 1fr 1fr;
  }

  .stat:nth-child(3) {
    border-left: 0;
  }

  .stat:nth-child(n + 3) {
    border-top: 1px solid var(--border);
  }

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

  /* 2 × 2 compact cards, so the screenshot stays on screen while they change. */
  .tour-tabs {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }

  .tour-tab {
    padding: 16px 10px 18px;
  }

  .tour-tab > svg {
    width: 24px;
    height: 24px;
    margin-bottom: 8px;
  }

  .tour-tab strong {
    font-size: 15px;
  }

  .tour-tab span {
    display: none;
  }

  .row-visual {
    min-height: 240px;
    padding: 20px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .cd-cap span {
    animation: none;
  }

  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }

  .js .reveal {
    opacity: 1;
    transform: none;
  }

  .curve .path {
    stroke-dashoffset: 0;
  }

  .bar i {
    width: 100%;
  }

  .export-card .done {
    opacity: 1;
  }
}

@media (max-width: 360px) {
  .brand {
    font-size: 16px;
    gap: 8px;
  }

  .nav .btn-small {
    padding: 7px 10px;
    font-size: 13px;
  }
}

/* ---------- Guide (guia.html) ---------- */

.legal.guide {
  max-width: 1080px;
}

.guide-toc {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 8px 32px;
  margin: 32px 0 8px;
  padding: 20px 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.guide-toc h2 {
  margin: 4px 0 8px;
  font-size: 15px;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.guide-toc ol {
  margin: 0;
  padding-left: 22px;
}

.guide-toc li {
  margin: 3px 0;
}

.guide-part {
  margin-top: 72px !important;
  padding-top: 24px;
  border-top: 1px solid var(--border-hi);
  font-size: clamp(24px, 3.4vw, 30px) !important;
  color: var(--accent);
}

.guide-step {
  margin-top: 48px;
  scroll-margin-top: 80px;
}

.guide-step > h2 {
  display: flex;
  align-items: center;
  gap: 12px;
}

.guide-step .num {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--accent-ink);
  font-size: 16px;
  font-weight: 700;
}

.guide-step h3 {
  margin-top: 28px;
  font-size: 17px;
}

.guide figure {
  margin: 20px 0;
}

.guide figure img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--bg-2);
}

.guide figcaption {
  margin-top: 10px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
}

.guide-split {
  display: grid;
  grid-template-columns: minmax(0, 46%) minmax(0, 1fr);
  gap: 28px;
  align-items: start;
  margin: 20px 0;
}

.guide-split > figure {
  margin: 0;
}

.guide-split > figure.tall {
  max-width: 400px;
}

.guide-split > figure.narrow {
  max-width: 290px;
}

.guide-split:has(> figure.tall),
.guide-split:has(> figure.narrow) {
  grid-template-columns: auto minmax(0, 1fr);
}

.guide-split > div > :first-child {
  margin-top: 0;
}

.guide-grid3 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
}

.guide-grid3 figure {
  margin: 0;
}

.guide .legend {
  padding-left: 0;
  list-style: none;
  counter-reset: legend;
}

.guide .legend > li {
  position: relative;
  margin: 10px 0;
  padding-left: 40px;
  counter-increment: legend;
}

.guide .legend > li::before {
  content: counter(legend);
  position: absolute;
  left: 0;
  top: 1px;
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--accent-ink);
  font-size: 13px;
  font-weight: 700;
}

.guide .legend-cols {
  columns: 2 320px;
  column-gap: 32px;
}

.guide .legend-cols > li {
  break-inside: avoid;
}

.guide .cols2 {
  columns: 2 300px;
  column-gap: 32px;
}

.guide .tip {
  padding: 14px 18px;
  background: var(--accent-soft);
  border-left: 3px solid var(--accent);
  border-radius: 8px;
}

.guide kbd {
  display: inline-block;
  min-width: 22px;
  padding: 1px 7px;
  font-family: inherit;
  font-size: 0.82em;
  font-weight: 600;
  line-height: 1.6;
  text-align: center;
  color: var(--text);
  background: var(--surface-2);
  border: 1px solid var(--border-hi);
  border-bottom-width: 2px;
  border-radius: 6px;
}

.guide .table-wrap {
  overflow-x: auto;
}

.guide table.keys {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
}

.guide table.keys th {
  padding: 18px 10px 8px;
  text-align: left;
  color: var(--accent);
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.guide table.keys td {
  padding: 7px 10px;
  border-top: 1px solid var(--border);
  color: #c9cad0;
  vertical-align: middle;
}

.guide table.keys td:nth-child(odd) {
  white-space: nowrap;
}

@media (max-width: 760px) {
  .guide-split,
  .guide-split:has(> figure.tall),
  .guide-split:has(> figure.narrow) {
    grid-template-columns: 1fr;
  }

  .guide-split > figure.tall,
  .guide-split > figure.narrow {
    max-width: 340px;
    margin: 0 auto;
  }
}

/* The web editor is simpler than the app (2026-11-01): a short note under its buttons. */
.web-note {
  margin: 14px auto 0;
  max-width: 520px;
  text-align: center;
  color: var(--muted);
  font-size: 13px;
}

.web-editor-note {
  margin: 14px 0 18px;
  max-width: none;
}

.footer-github {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.footer-github svg {
  width: 15px;
  height: 15px;
}

/* On a phone the logo alone, so «Guía» and the two buttons fit beside it. */
@media (max-width: 440px) {
  .site-header .brand-name {
    display: none;
  }
}

/* ----- Academia Flip Studio (academia/, built by tools/academia/build.py) ----- */
.legal.academy {
  max-width: 980px;
}

.acad-kicker {
  margin: 0 0 6px;
  color: var(--accent);
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.acad-lead {
  font-size: 18px;
  color: var(--muted);
}

.acad-icon {
  color: var(--accent);
  flex: none;
}

.acad-resume {
  margin: 20px 0 0;
}

.acad-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
  margin: 32px 0;
}

.acad-card {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.acad-card[data-level="intermedio"] .acad-icon { color: var(--accent-lo); }
.acad-card[data-level="avanzado"] .acad-icon { color: #f5a524; }

.acad-card-top {
  display: flex;
  align-items: center;
  gap: 10px;
}

.acad-level {
  color: var(--faint);
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.acad-card h2 {
  margin: 8px 0 4px !important;
  font-size: 24px !important;
}

.acad-card p {
  margin: 4px 0;
  color: var(--muted);
}

.acad-learn {
  margin: 8px 0 12px;
  padding-left: 18px;
  font-size: 15px;
}

.acad-learn li {
  margin: 3px 0;
}

.acad-count {
  font-size: 14px;
  color: var(--faint) !important;
}

.acad-card .btn {
  margin-top: auto;
  align-self: flex-start;
}

.acad-topics {
  padding: 20px 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.acad-topics ol {
  columns: 2;
  margin: 8px 0 12px;
}

.acad-crumbs {
  margin-bottom: 16px;
  color: var(--faint);
  font-size: 14px;
}

.acad-course-head {
  display: flex;
  align-items: center;
  gap: 14px;
}

.acad-course-head h1 {
  margin: 0;
}

.acad-progress {
  margin: 20px 0;
}

.acad-bar {
  height: 8px;
  background: var(--surface-2);
  border-radius: 99px;
  overflow: hidden;
}

.acad-bar span {
  display: block;
  width: 0;
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--accent-lo));
  transition: width 0.4s var(--ease);
}

.acad-progress p {
  margin: 6px 0 0;
  color: var(--faint);
  font-size: 14px;
}

.acad-index {
  list-style: none;
  margin: 16px 0;
  padding: 0;
}

.acad-item {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  margin: 0 0 10px;
  padding: 16px 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
}

.acad-item > div {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.acad-num {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 700;
}

.acad-item.done .acad-num {
  background: var(--accent);
  color: var(--accent-ink);
}

.acad-item.soon {
  opacity: 0.55;
}

.acad-topic {
  color: var(--faint);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.acad-desc,
.acad-soon {
  color: var(--muted);
  font-size: 15px;
}

.acad-soon {
  font-style: italic;
}

.acad-goal {
  margin: 20px 0;
  padding: 16px 20px;
  background: var(--accent-soft);
  border-left: 3px solid var(--accent);
  border-radius: 8px;
}

.acad-goal p {
  margin: 4px 0 0;
}

.acad-sec {
  margin-top: 40px;
}

.acad-steps > li {
  margin: 10px 0;
}

.acad-figure img {
  cursor: zoom-in;
}

.acad-table {
  overflow-x: auto;
}

.acad-table table {
  width: 100%;
  border-collapse: collapse;
}

.acad-table th,
.acad-table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  text-align: left;
  vertical-align: top;
}

.acad-table th {
  width: 32%;
  color: var(--text);
  font-weight: 600;
}

.acad-exercise {
  padding: 20px 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.acad-done.is-done {
  background: var(--surface-2);
  color: var(--accent);
}

.acad-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin: 48px 0 16px;
}

.acad-nav a {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 16px 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  text-decoration: none;
}

.acad-nav a:hover {
  border-color: var(--accent);
}

.acad-nav a span {
  color: var(--faint);
  font-size: 13px;
}

.acad-nav-next {
  text-align: right;
}

.acad-back {
  color: var(--muted);
}

.acad-lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(0, 0, 0, 0.88);
  overflow: auto;
}

.acad-lightbox[hidden] {
  display: none;
}

.acad-lightbox img {
  max-width: 100%;
  max-height: calc(100vh - 48px);
  border-radius: 8px;
  cursor: zoom-in;
}

.acad-lightbox img.full {
  max-width: none;
  max-height: none;
  cursor: zoom-out;
}

.acad-close {
  position: fixed;
  top: 12px;
  right: 16px;
  width: 44px;
  height: 44px;
  border: 1px solid var(--border-hi);
  border-radius: 50%;
  background: var(--surface);
  color: var(--text);
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
}

body.acad-noscroll {
  overflow: hidden;
}

@media (max-width: 640px) {
  .acad-topics ol {
    columns: 1;
  }

  .acad-nav {
    grid-template-columns: 1fr;
  }

  .acad-nav-next {
    text-align: left;
  }

  .acad-table th {
    width: 40%;
  }
}

.acad-figure img {
  width: auto;
  max-width: 100%;
  margin: 0 auto;
}

.acad-sec > h2 {
  margin-top: 0;
}

.acad-steps .acad-figure {
  max-width: 520px;
}

@media (max-width: 480px) {
  .acad-hide-sm {
    display: none;
  }
}
