/* =========================================================================
   DMC Institute — Landing cursos online en vivo
   Medidas de escritorio tomadas del diseño original (lienzo de 1920 px).
   ========================================================================= */

/* ---------- Fuentes (OFL, autoalojadas) ----------
   El diseño usa Neue Plak y Panton (licencias comerciales). Se emplean
   equivalentes libres; si DMC dispone de las licencias web, agregue sus
   @font-face y anteponga el nombre en las variables --font-*. */
@font-face {
  font-family: "Barlow Semi Condensed";
  font-style: normal; font-weight: 400; font-display: swap;
  src: url("../fonts/barlow-semi-condensed-latin-400-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Barlow Semi Condensed";
  font-style: normal; font-weight: 700; font-display: swap;
  src: url("../fonts/barlow-semi-condensed-latin-700-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Barlow Semi Condensed";
  font-style: normal; font-weight: 800; font-display: swap;
  src: url("../fonts/barlow-semi-condensed-latin-800-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Barlow";
  font-style: normal; font-weight: 600; font-display: swap;
  src: url("../fonts/barlow-latin-600-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Barlow";
  font-style: normal; font-weight: 700; font-display: swap;
  src: url("../fonts/barlow-latin-700-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Outfit";
  font-style: normal; font-weight: 100 900; font-display: swap;
  src: url("../fonts/outfit-latin-wght-normal.woff2") format("woff2");
}

/* ---------- Tokens ---------- */
:root {
  --c-blue: #0068ff;
  --c-cyan: #00edff;
  --c-navy: #041f48;
  --c-navy-2: #022047;
  --c-slate: #62749c;
  --c-slate-on-bg: #5b6d95;    /* mismo tono, contraste AA sobre #f2f4fa */
  --c-slate-dark: #4b6080;
  --c-green: #23843a;          /* #39b54a del diseño, oscurecido para contraste AA (4.7:1) */
  --c-bg: #f2f4fa;
  --c-white: #fff;
  --c-border: #cad0de;
  --c-error: #c62828;
  --c-success: #1b7f35;
  --c-hero: #04142e;

  --grad-btn: linear-gradient(90deg, #0ac4f2 0%, #0a44fe 100%);

  --font-narrow: "Barlow Semi Condensed", "Arial Narrow", Arial, sans-serif;  /* Neue Plak Narrow */
  --font-wide: "Barlow", Arial, sans-serif;                                    /* Neue Plak */
  --font-body: "Outfit", "Segoe UI", Arial, sans-serif;                        /* Panton */

  --container: 1282px;
  --gutter: 20px;
  --radius-card: 24px;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 350;
  line-height: 1.35;
  color: var(--c-navy);
  background: var(--c-bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; }
h1, h2, h3, p, ul { margin: 0; }
ul { padding: 0; list-style: none; }
a { color: inherit; }
button, input, select { font: inherit; color: inherit; }

.container {
  width: 100%;
  max-width: calc(var(--container) + var(--gutter) * 2);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.sr-only {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 100;
  background: var(--c-navy); color: #fff; padding: 10px 16px; border-radius: 6px;
  text-decoration: none; font-weight: 600;
}
.skip-link:focus { top: 12px; }

:focus-visible { outline: 3px solid var(--c-blue); outline-offset: 3px; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 12px;
  border: 0; border-radius: 6px;
  background: var(--grad-btn);
  color: #fff; text-decoration: none; cursor: pointer;
  font-family: var(--font-wide); font-weight: 600;
  transition: filter .2s ease, transform .2s ease, box-shadow .2s ease;
  -webkit-tap-highlight-color: transparent;
}
.btn:hover { filter: brightness(1.08); box-shadow: 0 8px 22px rgba(10, 80, 254, .28); }
.btn:active { transform: translateY(1px); }

.btn--header { height: 54px; padding: 0 25px; font-size: 22.4px; }

/* ---------- Header ---------- */
.site-header { background: var(--c-bg); }
.site-header__inner {
  height: 128px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.site-header__logo { display: block; margin-top: 7px; flex-shrink: 1; min-width: 0; }
.site-header__logo img { width: 345px; height: auto; }
.site-header .btn--header { margin-top: 9px; margin-right: -1px; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  color: #fff;
  background-color: var(--c-hero);
  background-image:
    radial-gradient(ellipse 40% 55% at 33% 100%, rgba(0, 72, 200, .42), transparent 70%),
    radial-gradient(ellipse 50% 70% at 55% 70%, rgba(0, 60, 170, .30), transparent 75%),
    linear-gradient(90deg, rgba(4, 18, 42, .9) 0%, rgba(4, 18, 42, 0) 35%, rgba(4, 18, 42, 0) 70%, rgba(4, 18, 42, .7) 100%),
    linear-gradient(180deg, #04122a 0%, #051a3d 100%);
  overflow: hidden;
  isolation: isolate;
}
/* textura de cuadrícula fina del diseño */
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background-image:
    linear-gradient(rgba(120, 170, 255, .05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(120, 170, 255, .05) 1px, transparent 1px);
  background-size: 5px 5px;
}
.hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 552px;
  gap: 40px;
  min-height: 656px;
  padding-top: 68px;
  padding-bottom: 55px;
}
.hero__copy { padding-top: 34px; }
.hero__title {
  font-family: var(--font-narrow); font-weight: 800;
  font-size: 66px; line-height: 68px; letter-spacing: -.6px;
  text-transform: uppercase;
}
.hero__title-line { display: block; }
.hero__title-line--accent { color: var(--c-blue); }
.hero__lead {
  margin-top: 14px; max-width: 600px;
  font-size: 18.4px; line-height: 22.5px; font-weight: 300; letter-spacing: -.1px;
}
.hero__visual {
  position: relative;
  display: flex; align-items: flex-start;
  margin-top: 13px;
}
.hero__robot {
  width: 321px; height: auto; aspect-ratio: 400 / 370;
  margin-left: -2px; flex-shrink: 0;
}
.benefits { display: grid; gap: 13px; margin: 74px 0 0 -3px; position: relative; }
.benefits__item {
  display: flex; align-items: center; gap: 9px;
  width: 216px; height: 52px; padding: 0 16px 0 19px;
  border: 1px solid rgba(70, 150, 255, .42);
  border-radius: 6px;
  background: rgba(12, 48, 112, .32);
  box-shadow: 0 0 8px rgba(0, 120, 255, .18);
  font-weight: 600; font-size: 16px;
}
.benefits__icon { width: 13px; height: 10px; color: var(--c-cyan); flex-shrink: 0; }

/* ---------- Formulario ---------- */
.form-card {
  align-self: start;
  background: #fff; color: var(--c-navy);
  border-radius: 22px;
  padding: 53px 37px 58px;
  box-shadow: 0 20px 50px rgba(0, 8, 30, .25);
  min-height: 532px;
  scroll-margin-top: 24px;
}
.form-card:focus { outline: none; }
.form-card__title {
  font-family: var(--font-narrow); font-weight: 700;
  font-size: 27.6px; line-height: 34px; letter-spacing: -.3px;
}
.form-card__intro {
  margin-top: 13px; max-width: 420px;
  font-size: 14.3px; line-height: 17.2px; color: var(--c-slate);
}
.coupon-form { margin-top: 23px; }
.field { position: relative; }
.field + .field { margin-top: 2px; }
.field__label {
  display: block; margin-bottom: 9px;
  font-weight: 700; font-size: 14.3px; line-height: 18px; color: var(--c-navy);
}
.field__control {
  display: block; width: 100%; height: 54px;
  padding: 0 16px;
  border: 1px solid var(--c-border); border-radius: 10px;
  background: #fff;
  font-size: 16px; color: var(--c-navy);
  transition: border-color .15s ease, box-shadow .15s ease;
}
input.field__control { font-size: 14.3px; }
@media (max-width: 767px) { input.field__control, .field__select select.field__control { font-size: 16px; } } /* evita zoom en iOS */
.field__control::placeholder { color: var(--c-slate); opacity: 1; }
.field__control:hover { border-color: #9aa7c2; }
.field__control:focus { outline: none; border-color: var(--c-blue); box-shadow: 0 0 0 3px rgba(0, 104, 255, .18); }
.field__control[aria-invalid="true"] { border-color: var(--c-error); }
.field__control[aria-invalid="true"]:focus { box-shadow: 0 0 0 3px rgba(198, 40, 40, .15); }

.field__select { position: relative; }
.field__select select {
  appearance: none; -webkit-appearance: none;
  padding-right: 44px; cursor: pointer;
  font-size: 14.3px; text-overflow: ellipsis;
}
.field__select select:invalid, .field__select select.is-placeholder { color: var(--c-slate); }
.field__select option { color: var(--c-navy); }
.field__select::after {
  content: ""; position: absolute; right: 20px; top: 50%;
  width: 8px; height: 8px; margin-top: -6px;
  border-right: 1.2px solid var(--c-slate); border-bottom: 1.2px solid var(--c-slate);
  transform: rotate(45deg); pointer-events: none;
}

.field__error {
  min-height: 15px; padding: 2px 2px 0;
  font-size: 12.5px; line-height: 16px; color: var(--c-error);
}

/* Botón deshabilitado cuando COURSES_WRITES_ENABLED=false. */
.btn--submit:disabled { cursor: not-allowed; opacity: .6; }

.field--check {
  display: grid; grid-template-columns: 16px 1fr; column-gap: 11px;
  align-items: start; padding-left: 4px;
}
.check {
  appearance: none; -webkit-appearance: none;
  width: 14px; height: 14px; margin: 1px 0 0;
  border: 1px solid #8f9bb5; border-radius: 2px; background: #fff;
  cursor: pointer; display: grid; place-content: center;
}
.check::before {
  content: ""; width: 8px; height: 5px; margin-top: -2px;
  border-left: 2px solid #fff; border-bottom: 2px solid #fff;
  transform: rotate(-45deg) scale(0); transition: transform .12s ease;
}
.check:checked { background: var(--c-blue); border-color: var(--c-blue); }
.check:checked::before { transform: rotate(-45deg) scale(1); }
.check[aria-invalid="true"] { border-color: var(--c-error); }
.check__label { font-size: 12.5px; line-height: 15px; color: var(--c-slate); cursor: pointer; }
.check__label a { color: var(--c-blue); text-underline-offset: 2px; }
.field--check .field__error { grid-column: 2; }
.field--check { margin-bottom: 4px; }

.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.btn--submit {
  position: relative;
  width: 100%; height: 64px; margin-top: 4px;
  border-radius: 8px;
  font-size: 26px; gap: 16px;
}
.btn__arrow { width: 9px; height: 15px; }
.btn__spinner {
  display: none; width: 22px; height: 22px;
  border: 3px solid rgba(255, 255, 255, .45); border-top-color: #fff; border-radius: 50%;
  animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.coupon-form.is-loading .btn--submit { cursor: progress; filter: saturate(.85); }
.coupon-form.is-loading .btn__arrow { display: none; }
.coupon-form.is-loading .btn__spinner { display: block; }
.btn[disabled] { cursor: not-allowed; }

.form-status {
  margin-top: 14px; padding: 12px 14px; border-radius: 10px;
  font-size: 14px; line-height: 1.4;
}
.form-status.is-success { background: #e8f6ec; color: var(--c-success); border: 1px solid #b7e1c1; }
.form-status.is-error { background: #fdecec; color: var(--c-error); border: 1px solid #f3c2c2; }

.form-card.is-highlight { animation: pulse 1.1s ease; }
@keyframes pulse {
  0% { box-shadow: 0 20px 50px rgba(0, 8, 30, .25), 0 0 0 0 rgba(0, 200, 255, .7); }
  100% { box-shadow: 0 20px 50px rgba(0, 8, 30, .25), 0 0 0 18px rgba(0, 200, 255, 0); }
}

/* ---------- Cifras ---------- */
.stats { padding-top: 57px; }
.stats__box {
  display: grid; grid-template-columns: repeat(3, 1fr);
  min-height: 131px; padding: 20px 0;
  background: #fff; border-radius: 14px;
  align-items: center;
}
.stats__item {
  position: relative;
  display: flex; flex-direction: column; align-items: center; text-align: center;
  color: var(--c-slate);
}
.stats__item + .stats__item::before {
  content: ""; position: absolute; left: 0; top: 50%;
  width: 1.5px; height: 70px; margin-top: -35px;
  background: linear-gradient(180deg, rgba(0, 104, 255, .15), #0068ff 50%, rgba(0, 104, 255, .15));
}
.stats__value {
  font-family: var(--font-wide); font-weight: 700;
  font-size: 40px; line-height: 40px;
}
.stats__label { margin-top: 1px; font-size: 23.7px; line-height: 29px; }

/* ---------- Catálogo ---------- */
.catalog { padding: 90px 0 0; }
.catalog__head { text-align: center; }
.catalog__eyebrow {
  font-size: 23.4px; line-height: 29px; letter-spacing: 2.6px;
  text-transform: uppercase; color: var(--c-navy);
}
.catalog__title {
  margin-top: 6px;
  font-family: var(--font-wide); font-weight: 700;
  font-size: 50.8px; line-height: 52px; letter-spacing: -.4px;
  color: var(--c-blue);
}
.catalog__sub { margin-top: 12px; font-size: 23.7px; line-height: 29px; color: var(--c-slate-on-bg); }

.filters {
  display: flex; justify-content: center; flex-wrap: wrap; gap: 28px;
  margin-top: 42px;
}
.chip {
  min-width: 179px; height: 48px; padding: 0 22px;
  border: 0; border-radius: 999px; background: #fff;
  font-size: 16px; color: var(--c-slate); cursor: pointer;
  transition: background-color .2s ease, color .2s ease, box-shadow .2s ease;
}
.chip:hover { color: var(--c-blue); box-shadow: 0 4px 14px rgba(4, 31, 72, .08); }
.chip.is-active, .chip[aria-pressed="true"] { background: var(--c-blue); color: #fff; }

.course-grid {
  display: grid;
  grid-template-columns: repeat(3, 360px);
  justify-content: center;
  gap: 52px 49px;
  margin-top: 69px;
}
.course-card {
  display: flex; flex-direction: column;
  background: #fff; border-radius: var(--radius-card);
  overflow: hidden;
  transition: box-shadow .25s ease, transform .25s ease;
}
.course-card:hover { box-shadow: 0 16px 40px rgba(4, 31, 72, .10); transform: translateY(-3px); }
.course-card[hidden] { display: none; }
.course-card.is-entering { animation: cardIn .35s ease both; }
@keyframes cardIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

.course-card__img {
  width: 100%; height: auto; aspect-ratio: 360 / 149; object-fit: cover;
  background: #e6eaf3;
}
.course-card__body {
  flex: 1; display: flex; flex-direction: column; align-items: flex-start;
  padding: 43px 39px 46px 37px;
}
.badge {
  padding: 4px 8px 5px; border-radius: 3px;
  background: var(--c-blue); color: #fff;
  font-size: 13.5px; line-height: 16px;
}
.course-card__title {
  margin-top: 16px;
  font-family: var(--font-narrow); font-weight: 700;
  font-size: 26.1px; line-height: 25px; letter-spacing: -.2px;
  color: var(--c-blue);
}
.course-card__meta {
  display: flex; align-items: center; gap: 0;
  margin-top: 4px; font-size: 12.2px; line-height: 15px; color: var(--c-navy-2);
}
.course-card__sep { width: 1px; height: 13px; margin: 0 6px; background: var(--c-slate); }
.course-card__desc {
  margin-top: 14px; font-size: 13.9px; line-height: 16.7px; color: var(--c-slate);
  max-width: 290px;
}
.course-card__pricing { margin-top: 26px; margin-bottom: 20px; width: 100%; }
.course-card__offer { display: flex; align-items: baseline; gap: 0; line-height: 20px; }
.course-card__discount {
  width: 137px; flex-shrink: 0;
  font-weight: 700; font-size: 16.1px; color: var(--c-green);
}
.course-card__old {
  font-family: var(--font-narrow); font-size: 18.5px; color: var(--c-slate);
  text-decoration-thickness: 1px;
}
.course-card__price {
  margin-top: 0;
  font-family: var(--font-narrow); font-weight: 400;
  font-size: 48px; line-height: 56px; color: var(--c-navy-2); letter-spacing: -.3px;
}
.btn--card {
  align-self: stretch; margin-top: auto;
  height: 36px; border-radius: 4px; font-size: 17.1px;
}

.catalog__notes {
  margin-top: 46px; text-align: center;
  font-size: 17.6px; line-height: 25.6px; color: var(--c-slate-on-bg);
}
.catalog__notes a { color: inherit; text-underline-offset: 2px; }

/* ---------- Footer ---------- */
.site-footer {
  margin-top: 106px;
  background: var(--c-slate-dark); color: #fff;
  text-align: center;
}
.site-footer .container {
  min-height: 128px; display: flex; align-items: center; justify-content: center;
  padding-block: 24px;
}
.site-footer p { font-size: 24px; line-height: 1.3; font-weight: 300; }

/* =========================================================================
   Responsive
   ========================================================================= */

/* Laptop / tablet horizontal */
@media (max-width: 1279px) {
  .hero__grid { grid-template-columns: minmax(0, 1fr) minmax(400px, 480px); gap: 32px; }
  .hero__title { font-size: 58px; line-height: 58px; }
  .hero__robot { width: 270px; }
  .benefits { margin-top: 48px; }
  .benefits__item { width: auto; min-width: 200px; white-space: nowrap; }
  .course-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px 28px; }
  .course-card__body { padding: 32px 28px 36px; }
  .course-card__discount { width: auto; margin-right: 24px; }
}

@media (max-width: 1023px) {
  .site-header__inner { height: 96px; }
  .site-header__logo img { width: 260px; }
  .btn--header { height: 46px; padding: 0 18px; font-size: 18px; }
  .site-header .btn--header { margin-top: 4px; }

  .hero__grid { grid-template-columns: minmax(0, 1fr); gap: 32px; padding-top: 48px; padding-bottom: 56px; min-height: 0; }
  .hero__copy { padding-top: 0; text-align: center; }
  .hero__lead { margin-inline: auto; }
  .hero__visual { justify-content: center; }
  .form-card { width: 100%; max-width: 560px; justify-self: center; min-height: 0; }

  .course-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px 24px; }
  .stats__value { font-size: 32px; line-height: 36px; }
  .stats__label { font-size: 18px; line-height: 24px; }
  .catalog { padding-top: 64px; }
  .catalog__title { font-size: 40px; line-height: 44px; }
  .catalog__eyebrow, .catalog__sub { font-size: 19px; line-height: 25px; }
  .filters { gap: 12px; }
  .chip { min-width: 0; padding: 0 26px; }
  .site-footer { margin-top: 72px; }
  .site-footer p { font-size: 18px; }
}

/* Móvil */
@media (max-width: 767px) {
  :root { --gutter: 16px; --radius-card: 18px; }
  .site-header__inner { height: 72px; }
  .site-header__logo { margin-top: 0; }
  .site-header__logo img { width: 168px; }
  .btn--header { height: 42px; padding: 0 14px; font-size: 15px; border-radius: 6px; }
  .site-header .btn--header { margin-top: 0; }

  .hero__grid { padding-top: 36px; padding-bottom: 40px; gap: 24px; }
  .hero__title { font-size: clamp(38px, 11.4vw, 52px); line-height: 1; }
  .hero__lead { font-size: 16.5px; line-height: 22px; margin-top: 14px; }
  .hero__visual { flex-direction: column; align-items: center; margin-top: 12px; }
  .hero__robot { width: 220px; margin: 0; }
  /* Los 3 distintivos no caben en una fila entre 381 y 767 px: pasan a la siguiente fila en lugar de desbordar. */
  .benefits { margin: -6px 0 0; display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
  .benefits__item {
    width: auto; height: 40px; padding: 0 10px; gap: 6px;
    font-size: 13px; white-space: nowrap;
  }
  .benefits__icon { width: 11px; height: 9px; }

  .form-card { padding: 32px 20px 28px; border-radius: 18px; }
  .form-card__title { font-size: 26px; line-height: 30px; }
  .btn--submit { height: 56px; font-size: 21px; }
  .check__label { font-size: 13px; line-height: 17px; }

  .stats { padding-top: 32px; }
  .stats__box { grid-template-columns: 1fr; padding: 8px 20px; }
  .stats__item { padding: 16px 0; }
  .stats__item + .stats__item::before {
    left: 15%; right: 15%; top: 0; width: auto; height: 1px; margin: 0;
    background: linear-gradient(90deg, rgba(0, 104, 255, .1), #0068ff 50%, rgba(0, 104, 255, .1));
  }
  .stats__value { font-size: 30px; line-height: 34px; }
  .stats__label { font-size: 17px; }

  .catalog { padding-top: 52px; }
  .catalog__eyebrow { font-size: 14px; line-height: 20px; letter-spacing: 2px; }
  .catalog__title { font-size: 30px; line-height: 34px; margin-top: 8px; }
  .catalog__sub { font-size: 16.5px; line-height: 22px; }
  .filters {
    flex-wrap: nowrap; justify-content: flex-start; gap: 10px;
    margin: 28px calc(var(--gutter) * -1) 0; padding: 4px var(--gutter);
    overflow-x: auto; scroll-snap-type: x proximity; scrollbar-width: none;
  }
  .filters::-webkit-scrollbar { display: none; }
  .chip { min-width: 0; height: 44px; flex-shrink: 0; scroll-snap-align: start; font-size: 15px; padding: 0 18px; }

  .course-grid { grid-template-columns: 1fr; gap: 24px; margin-top: 32px; }
  .course-card__body { padding: 26px 22px 26px; }
  .course-card__desc { max-width: none; }
  .btn--card { height: 46px; font-size: 17px; }
  .catalog__notes { font-size: 14px; line-height: 20px; margin-top: 32px; }
  .catalog__notes p + p { margin-top: 6px; }
  .site-footer { margin-top: 56px; }
  .site-footer .container { min-height: 96px; }
  .site-footer p { font-size: 15px; }
}

@media (max-width: 380px) {
  .site-header__logo img { width: 148px; }
  .btn--header { padding: 0 12px; font-size: 14px; }
  .benefits { display: grid; grid-template-columns: 1fr; }
  .benefits__item { justify-content: center; }
}
