:root {
  color-scheme: light;
  --blue: #2563eb;
  --blue-dark: #1d4ed8;
  --ink: #17233b;
  --muted: #64748b;
  --line: #e4eaf3;
  --soft: #f5f8ff;
  --font: 'Inter', 'Segoe UI', system-ui, -apple-system, Roboto, 'Helvetica Neue', Arial, sans-serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: #fff; color: var(--ink); font-family: var(--font); line-height: 1.6; }
a { color: inherit; text-decoration: none; }
.topbar { height: 76px; padding: 0 max(5vw, calc((100% - 1180px)/2)); display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); background: #fff; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-size: 17px; font-weight: 800; letter-spacing: -.5px; }
.brand small { display: block; color: var(--muted); font-size: 9px; letter-spacing: 2px; line-height: 1; }
.brand-mark { display: inline-grid; place-items: center; flex: 0 0 38px; width: 38px; height: 38px; background: transparent; }
.brand-mark svg { display: block; width: 100%; height: 100%; }
.topbar nav { display: flex; align-items: center; gap: 28px; color: #526078; font-size: 14px; font-weight: 600; }
.topbar nav a:hover, footer a:hover { color: var(--blue); }
.nav-cta { padding: 10px 16px; border-radius: 9px; background: var(--blue); color: white !important; }
.hero { max-width: 1180px; margin: auto; padding: 86px 28px 76px; display: grid; grid-template-columns: 1.05fr .95fr; align-items: center; gap: 60px; }
.eyebrow { color: var(--blue); font-size: 11px; font-weight: 800; letter-spacing: 1.8px; }
.hero h1 { margin: 16px 0; max-width: 620px; font-size: clamp(42px, 5vw, 64px); letter-spacing: -3px; line-height: 1.08; }
.hero h1 span { color: var(--blue); }
.hero-copy > p { max-width: 550px; color: var(--muted); font-size: 18px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.button { display: inline-flex; justify-content: center; align-items: center; gap: 10px; border: 0; border-radius: 9px; padding: 13px 19px; font: inherit; font-size: 14px; font-weight: 750; cursor: pointer; transition: .18s ease; }
.button:hover { transform: translateY(-2px); }
.primary { background: var(--blue); color: #fff; }
.primary:hover { background: var(--blue-dark); }
.secondary { background: #eef3ff; color: var(--blue-dark); }
.hero-note { margin-top: 20px; color: var(--muted); font-size: 12px; }
.hero-note span { color: #16a36a; font-weight: 900; margin-right: 5px; }
.hero-art { position: relative; padding: 24px; border-radius: 26px; background: linear-gradient(140deg, #eaf1ff, #f5f8ff 65%, #e8f4ff); }
.code-window { overflow: hidden; border: 1px solid #dce5f4; border-radius: 14px; background: #fff; box-shadow: 0 24px 55px #203d751a; }
.window-head { height: 43px; display: flex; align-items: center; gap: 6px; padding: 0 14px; border-bottom: 1px solid var(--line); }
.window-head i { width: 8px; height: 8px; border-radius: 50%; background: #f28b82; }
.window-head i:nth-child(2) { background: #fbbc4f; }
.window-head i:nth-child(3) { background: #81c995; }
.window-head span { margin-left: 12px; color: var(--muted); font-size: 11px; }
.code-lines { padding: 25px 18px; font: 13px/2.1 ui-monospace, SFMono-Regular, Consolas, monospace; color: #334155; }
.code-lines b { display: inline-block; width: 25px; color: #a0aec0; font-weight: 400; }
.purple { color: #8b5cf6; }.green { color: #0c9b70; }.blue { color: #2563eb; }
.code-result { padding: 12px 18px; border-top: 1px solid var(--line); color: #64748b; font-size: 12px; }
.code-result span { color: #16a36a; }
.floating-tag { position: absolute; right: -15px; bottom: 15px; padding: 11px 16px; border: 1px solid var(--line); border-radius: 10px; background: white; box-shadow: 0 10px 30px #1e3a8a16; color: var(--blue-dark); font-size: 12px; font-weight: 750; }
.trust-strip { display: grid; grid-template-columns: repeat(4,1fr); gap: 20px; padding: 28px max(5vw, calc((100% - 1120px)/2)); background: #f7f9fd; border-block: 1px solid var(--line); }
.trust-strip div { display: flex; flex-direction: column; align-items: center; text-align: center; }
.trust-strip strong { color: var(--blue-dark); font-size: 19px; }
.trust-strip span { color: var(--muted); font-size: 12px; }
.section, .experience-section, .steps-section { max-width: 1180px; margin: auto; padding: 82px 28px; }
.section-heading { margin-bottom: 32px; text-align: center; }
.section-heading h2 { margin: 9px 0; font-size: clamp(27px, 3.4vw, 38px); letter-spacing: -1.3px; }
.section-heading p { margin: 0; color: var(--muted); }
.course-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 16px; }
.course-card { padding: 22px; border: 1px solid var(--line); border-radius: 13px; background: white; }
.course-card .course-number { display: grid; place-items: center; width: 37px; height: 37px; margin-bottom: 15px; border-radius: 10px; background: #edf3ff; color: var(--blue); font-weight: 850; }
.course-card h3 { margin: 0 0 7px; font-size: 16px; }
.course-card p { margin: 0; color: var(--muted); font-size: 13px; }
.loading-card { grid-column: 1/-1; padding: 30px; text-align: center; color: var(--muted); }
.experience-section { max-width: none; padding-inline: max(28px, calc((100% - 1124px)/2)); background: var(--soft); }
.lesson-card, .editor-card { max-width: 1124px; margin: 18px auto 0; padding: 25px; border: 1px solid var(--line); border-radius: 15px; background: #fff; }
.lesson-heading { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.lesson-label { color: var(--blue); font-size: 10px; font-weight: 800; letter-spacing: 1.4px; }
.lesson-heading h3 { margin: 3px 0; font-size: 22px; }
.duration { padding: 6px 10px; border-radius: 20px; background: #f1f5fb; color: var(--muted); font-size: 11px; white-space: nowrap; }
.lesson-content { margin-top: 15px; color: #475569; font-size: 14px; }
.lesson-content p { margin: 10px 0; }
.lesson-content pre { overflow-x: auto; padding: 13px; border-radius: 9px; background: #f4f6fb; color: #1e3a8a; }
.lesson-content .lesson-tip { padding: 12px 15px; border-left: 3px solid #e8ad35; border-radius: 5px; background: #fff9e9; }
.editor-card { margin-top: 20px; }
.editor-heading { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-bottom: 20px; }
.editor-heading h3 { margin: 4px 0; font-size: 20px; }
.editor-heading p { margin: 0; color: var(--muted); font-size: 13px; }
.editor-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.editor-pane, .preview-pane { overflow: hidden; border: 1px solid #dfe6f0; border-radius: 10px; background: #fff; }
.pane-title { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 13px; border-bottom: 1px solid #e6ebf2; background: #f8fafd; color: #526078; font-size: 11px; font-weight: 750; }
.file-dot { width: 8px; height: 8px; margin-right: auto; border-radius: 50%; background: #e6a23c; }
.css-dot { background: #3b82f6; }.js-dot { background: #eab308; }
.editor-pane textarea { display: block; width: 100%; height: 210px; resize: vertical; padding: 15px; border: 0; outline: 0; background: #fff; color: #26354d; font: 12px/1.7 ui-monospace, SFMono-Regular, Consolas, monospace; tab-size: 2; }
.preview-status { color: #0b9460; font-size: 9px; letter-spacing: .8px; }
.preview { min-height: 210px; background: white; }
.preview-frame { display: block; width: 100%; height: 210px; border: 0; background: white; }
.console-panel { margin-top: 12px; overflow: hidden; border: 1px solid #e1e7f0; border-radius: 9px; }
.console-panel pre { min-height: 40px; margin: 0; padding: 12px; color: #475569; background: #fbfcfe; white-space: pre-wrap; font: 12px/1.5 ui-monospace, monospace; }
.privacy-note { margin: 12px 0 0; color: var(--muted); font-size: 11px; }
.steps-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: 15px; }
.steps-grid article { padding: 22px; border: 1px solid var(--line); border-radius: 12px; }
.steps-grid article > span { color: var(--blue); font-size: 12px; font-weight: 850; }
.steps-grid h3 { margin: 9px 0 4px; }
.steps-grid p { margin: 0; color: var(--muted); font-size: 13px; }
.final-cta { padding: 70px 20px; background: #1e3a8a; color: white; text-align: center; }
.final-cta .eyebrow { color: #bfdbfe; }
.final-cta h2 { margin: 10px 0; font-size: clamp(27px,4vw,40px); letter-spacing: -1px; }
.final-cta p { color: #dbeafe; }
.white-button { margin-top: 14px; background: white; color: #1d4ed8; }
.final-cta small { display: block; margin-top: 12px; color: #bfdbfe; }
footer { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 24px max(5vw, calc((100% - 1120px)/2)); color: var(--muted); font-size: 11px; }
footer .brand { color: var(--ink); font-size: 14px; }
footer .brand-mark { flex-basis: 31px; width: 31px; height: 31px; }
@media (max-width: 800px) {
  .hero { grid-template-columns: 1fr; gap: 35px; padding-top: 55px; }
  .hero-art { max-width: 560px; width: 100%; margin: auto; }
  .course-grid { grid-template-columns: repeat(2,1fr); }
  .steps-grid { grid-template-columns: repeat(2,1fr); }
  .trust-strip { grid-template-columns: repeat(2,1fr); }
}
@media (max-width: 560px) {
  .topbar { height: auto; min-height: 68px; padding: 12px 17px; }
  .topbar nav { gap: 12px; font-size: 12px; }
  .topbar nav a:not(.nav-cta) { display: none; }
  .nav-cta { padding: 9px 11px; }
  .hero { padding: 48px 20px; }
  .hero h1 { font-size: 43px; letter-spacing: -2px; }
  .hero-copy > p { font-size: 15px; }
  .hero-art { padding: 13px; }
  .code-lines { padding: 17px 10px; font-size: 10px; }
  .trust-strip { padding: 22px 10px; }
  .course-grid, .steps-grid, .editor-grid { grid-template-columns: 1fr; }
  .section, .experience-section, .steps-section { padding: 55px 17px; }
  .lesson-card, .editor-card { padding: 16px; }
  .editor-heading { align-items: flex-start; flex-direction: column; }
  .editor-heading .button { width: 100%; }
  .lesson-heading { align-items: flex-start; flex-direction: column; gap: 5px; }
  footer { align-items: flex-start; flex-direction: column; padding: 22px; }
}

/* =====================================================
   CODEHUB — NUEVA PRESENTACIÓN DE LA DEMO
   ===================================================== */

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(14px);
  background: rgb(255 255 255 / 94%);
}

.hero {
  position: relative;
  padding-top: 100px;
  padding-bottom: 94px;
}

.hero-copy {
  position: relative;
  z-index: 1;
}

.hero h1 {
  max-width: 650px;
  font-size: clamp(44px, 5.2vw, 68px);
  letter-spacing: -3.4px;
  line-height: 1.04;
}

.hero h1 span {
  display: inline;
  background: linear-gradient(100deg, #2563eb, #5794f7);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-copy > p {
  max-width: 535px;
  font-size: 17px;
  line-height: 1.8;
}

.hero-main-cta {
  min-height: 51px;
  padding-inline: 23px;
  box-shadow: 0 9px 22px rgb(37 99 235 / 20%);
}

.hero-highlights {
  display: flex;
  flex-wrap: wrap;
  gap: 17px;
  margin-top: 24px;
  color: #53647d;
  font-size: 12px;
  font-weight: 650;
}

.hero-art {
  padding: 31px;
  border: 1px solid #e1eaff;
  background:
    radial-gradient(circle at 85% 15%, rgb(91 145 255 / 18%), transparent 35%),
    linear-gradient(145deg, #edf3ff, #f8faff 60%, #e8f2ff);
}

.hero-art-label {
  margin-bottom: 15px;
  color: #627795;
  font-size: 10px;
  font-weight: 850;
  letter-spacing: 1.6px;
}

.hero-side-note {
  margin-top: 19px;
  color: #71819b;
  text-align: center;
  font-size: 10px;
  font-weight: 850;
  letter-spacing: 1.7px;
}

.hero-side-note span {
  padding-inline: 7px;
  color: var(--blue);
}

.floating-tag {
  right: -9px;
  bottom: 55px;
}

.trust-strip {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 15px;
  padding-top: 29px;
  padding-bottom: 29px;
  background: linear-gradient(110deg, #f7f9ff, #f0f5ff);
}

.stat-item {
  min-height: 82px;
  justify-content: center;
  gap: 4px;
  padding: 12px 8px;
  border-right: 1px solid #dfe7f5;
}

.stat-item:last-child {
  border-right: 0;
}

.stat-item strong {
  font-size: clamp(20px, 2.5vw, 27px);
  line-height: 1.2;
  letter-spacing: -.8px;
}

.stat-item:last-child strong {
  font-size: 19px;
}

.stat-item span {
  font-size: 12px;
}

.section-heading h2 {
  line-height: 1.2;
}

.steps-section .section-heading p {
  max-width: 610px;
  margin: 10px auto 0;
  color: var(--muted);
}

.steps-grid article {
  position: relative;
  overflow: hidden;
  min-height: 178px;
  background: linear-gradient(150deg, #fff, #f9fbff);
  transition: transform .2s ease, box-shadow .2s ease;
}

.steps-grid article:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 30px rgb(30 58 138 / 8%);
}

.steps-grid article > span {
  display: inline-grid;
  place-items: center;
  width: 35px;
  height: 35px;
  border-radius: 10px;
  background: #edf3ff;
}

.final-cta {
  background:
    radial-gradient(circle at 15% 15%, rgb(96 165 250 / 20%), transparent 30%),
    radial-gradient(circle at 90% 80%, rgb(96 165 250 / 17%), transparent 32%),
    #1e3a8a;
}

@media (max-width: 800px) {
  .hero {
    padding-top: 65px;
    padding-bottom: 65px;
  }

  .stat-item:nth-child(2) {
    border-right: 0;
  }
}

@media (max-width: 560px) {
  .hero h1 {
    font-size: 43px;
    letter-spacing: -2.2px;
  }

  .hero-highlights {
    gap: 10px;
  }

  .hero-art {
    padding: 17px;
  }

  .trust-strip {
    gap: 5px;
  }

  .stat-item {
    min-height: 76px;
    padding: 10px 4px;
  }

  .stat-item strong {
    font-size: 21px;
  }

  .stat-item:last-child strong {
    font-size: 16px;
  }

  .stat-item span {
    font-size: 10px;
  }

  .floating-tag {
    right: -3px;
    bottom: 30px;
  }
}

/* Identidad corporativa CodeHub */
:root {
  --brand: #2EA3F2;
  --blue: #006799;
  --blue-dark: #004f75;
  --soft: #eaf7ff;
  --line: #d5e8f4;
  --font: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;
}

.brand-logo {
  display: block;
  width: 148px;
  height: auto;
  object-fit: contain;
}

.brand {
  gap: 0;
}

.nav-cta,
.button:not(.white-button) {
  background: #006799;
}

.eyebrow,
.course-icon {
  color: #006799;
}

a:focus-visible,
button:focus-visible {
  outline: 3px solid #2EA3F2;
  outline-offset: 3px;
}

/* CodeHub · colores oficiales del logotipo */
:root {
  --brand: #76B31E;
  --blue: #76B31E;
  --blue-dark: #184A12;
  --ink: #184A12;
  --soft: #F3F8E9;
  --line: #E5F0D0;
}

.nav-cta,
.button:not(.white-button) {
  background: #76B31E;
  color: #fff;
}

.nav-cta:hover,
.button:not(.white-button):hover {
  background: #184A12;
}

.eyebrow {
  color: #76B31E;
}

.course-card:hover {
  border-color: #76B31E;
}

::selection {
  background: #C8D200;
  color: #184A12;
}
