/*
 * Landing de Dicard Empresas (/empresas).
 * Se apoya en static/css/index/landing.css (tokens --lp-*, encabezado, escenas, ficha, preguntas y pie)
 * y solo agrega las piezas propias con el prefijo `em-`. Mobile first: lo base es para 375px.
 */

/* ── Encabezado ── */
.em-header-login {
  min-height: 44px;
  padding: 0 4px;
  border: 0;
  background: none;
  color: var(--lp-ink-2);
  font-size: 14px;
  font-weight: 500;
}
/* "Entrar" y "Ver precio" se turnan el mismo lugar: el oculto no ocupa espacio (a 320px no caben los dos). */
.lp-header.lp-has-cta .em-header-login { display: none; }
.lp-header:not(.lp-has-cta) .lp-header__cta { display: none; }
.lp-header.lp-is-dark .em-header-login { color: #f5f5f7; }

.em-eyebrow {
  margin: 0 0 12px;
  color: var(--lp-signal-ink);
  font-size: 12px;
  font-weight: 650;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.em-link-btn { border: 0; background: none; padding: 0; }

/* ── Hero: tres tarjetas iguales, una por persona ── */
.em-hero { padding-bottom: 0; overflow: hidden; }
.em-fan {
  position: relative;
  height: 360px;
  margin-top: 44px;
  /* La tarjeta sale de abajo: se recorta para que la escena siguiente la "corte". */
  -webkit-mask-image: linear-gradient(#000 78%, transparent);
  mask-image: linear-gradient(#000 78%, transparent);
}
.em-fan__card {
  position: absolute;
  left: 50%;
  top: 0;
  width: 200px;
  height: auto;
  border-radius: 26px;
  transform: translateX(-50%);
  box-shadow: 0 30px 60px -24px rgba(0, 0, 0, .35);
}
.em-fan__card--left,
.em-fan__card--right { top: 34px; width: 170px; opacity: .55; filter: saturate(.6); }
.em-fan__card--left { transform: translateX(-112%) rotate(-7deg); }
.em-fan__card--right { transform: translateX(12%) rotate(7deg); }

/* ── Pasos ── */
.em-steps { margin: 36px 0 0; padding: 0; list-style: none; display: grid; gap: 12px; }
.em-step {
  padding: 20px;
  border-radius: 22px;
  background: var(--lp-bg);
  display: grid;
  grid-template-columns: 36px 1fr;
  gap: 14px;
  align-items: start;
}
.em-step__n {
  width: 36px; height: 36px;
  border-radius: 50%;
  display: grid; place-items: center;
  background: var(--lp-paper);
  font-size: 15px; font-weight: 650;
}
/* La captura ocupa todo el ancho de la tarjeta, debajo del número y el texto. */
.em-step__shot { grid-column: 1 / -1; align-self: start; margin-top: 6px; border-radius: 22px; box-shadow: 0 0 0 1px var(--lp-hair), 0 24px 48px -28px rgba(0, 0, 0, .3); }
.em-step h3 { font-size: 18px; font-weight: 650; letter-spacing: -.015em; line-height: 1.25; }
.em-step p { margin-top: 4px; color: var(--lp-muted); font-size: 15px; line-height: 1.45; }

/* ── Panel de ejemplo (escena oscura) ── */
/* Capturas reales del panel (datos de demostración) */
.em-shots { margin: 40px auto 0; max-width: 320px; display: grid; gap: 14px; }
.em-shots__img { border-radius: 28px; box-shadow: 0 30px 60px -30px rgba(0, 0, 0, .6); }
/* Sobre la escena negra el botón oscuro de siempre no se vería. */
.em-shots__cta { margin-top: 10px; background: #f5f5f7; color: var(--lp-ink); }
.em-shots__cta:hover { background: #fff; }

/* ── Precio ── */
.em-price {
  margin: 36px auto 0;
  max-width: 400px;
  padding: 24px 20px 20px;
  border-radius: 28px;
  background: var(--lp-bg);
  text-align: center;
}
.em-price__label { display: block; font-size: 15px; font-weight: 600; }
.em-stepper {
  margin: 14px auto 0;
  max-width: 260px;
  display: grid;
  grid-template-columns: 52px 1fr 52px;
  align-items: center;
  gap: 8px;
}
.em-stepper__btn {
  width: 52px; height: 52px;
  border: 0; border-radius: 50%;
  background: var(--lp-paper);
  color: var(--lp-ink);
  font-size: 24px; line-height: 1;
  transition: background .2s, transform .2s var(--lp-ease);
}
.em-stepper__btn:active { transform: scale(.94); }
.em-stepper__btn:disabled { opacity: .35; cursor: default; }
.em-stepper__input {
  width: 100%; min-width: 0; height: 56px;
  border: 0; border-radius: 16px;
  background: none;
  color: var(--lp-ink);
  text-align: center;
  font-size: 40px !important; font-weight: 650; letter-spacing: -.03em;
  font-variant-numeric: tabular-nums;
  -moz-appearance: textfield;
  appearance: textfield;
}
.em-stepper__input::-webkit-outer-spin-button,
.em-stepper__input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.em-stepper__input:focus-visible { outline: 2px solid var(--lp-focus); outline-offset: 0; }
.em-price__total { margin-top: 18px; display: flex; align-items: baseline; justify-content: center; gap: 6px; }
.em-price__total b { font-size: 28px; font-weight: 650; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.em-price__total span { color: var(--lp-muted); font-size: 15px; }
.em-price__hint { margin-top: 4px; color: var(--lp-muted); font-size: 13px; }
.em-price__hint.is-error { color: #b42318; }
.em-price__cta { width: 100%; margin-top: 20px; }
.em-price__error { margin-top: 10px; color: #c62828; font-size: 13px; text-align: center; }
.em-price__error:empty { display: none; }
.em-price__note { margin-top: 12px; color: var(--lp-muted); font-size: 12px; }

/* ── Hojas (checkout y entrar) ──
   En móvil suben desde abajo; en escritorio quedan centradas. */
.em-sheet {
  width: 100%;
  max-width: 100%;
  max-height: calc(100dvh - 24px);
  margin: auto 0 0;
  padding: 0;
  border: 0;
  border-radius: 24px 24px 0 0;
  background: var(--lp-bg);
  color: var(--lp-ink);
  font-family: var(--lp-font);
  overflow-y: auto;
  overscroll-behavior: contain;
}
.em-sheet::backdrop { background: rgba(0, 0, 0, .4); }
.em-sheet[open] { animation: em-sheet-in .32s var(--lp-ease); }
@keyframes em-sheet-in { from { transform: translateY(40px); opacity: 0; } }
.em-sheet__body { padding: 22px 20px calc(20px + env(safe-area-inset-bottom)); display: grid; gap: 14px; }
.em-sheet__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.em-sheet__title { margin: 0; font-size: 22px; font-weight: 650; letter-spacing: -.02em; line-height: 1.2; }
.em-sheet__sub { margin: 4px 0 0; color: var(--lp-muted); font-size: 14px; line-height: 1.4; }
.em-sheet__close {
  width: 36px; height: 36px; flex: none; margin: -4px -6px 0 0;
  border: 0; border-radius: 50%;
  background: var(--lp-paper); color: var(--lp-ink);
  font-size: 22px; line-height: 1; cursor: pointer;
}
.em-field { display: grid; gap: 6px; }
.em-field span { font-size: 13px; font-weight: 600; color: var(--lp-ink-2); }
.em-field input {
  width: 100%; height: 50px; padding: 0 14px;
  border: 1px solid var(--lp-line); border-radius: 14px;
  background: var(--lp-bg); color: var(--lp-ink);
  font-size: 16px;
  transition: border-color .15s, box-shadow .15s;
}
.em-field input::placeholder { color: #8e8e93; }
.em-field input:focus { outline: none; border-color: var(--lp-focus); box-shadow: 0 0 0 3px rgba(0, 113, 227, .18); }
.em-sheet__error { min-height: 18px; margin: 0; color: #c62828; font-size: 13px; }
.em-sheet__error:empty { min-height: 0; }
.em-sheet__error--ok { color: #1d1d1f; }
.em-sheet__submit { width: 100%; }
.em-sheet__submit:disabled { opacity: .55; cursor: progress; }
.em-sheet__legal { margin: 0; color: var(--lp-muted); font-size: 12px; line-height: 1.45; text-align: center; }
.em-sheet__legal a, .em-sheet__aside { color: var(--lp-ink-2); text-decoration: underline; text-underline-offset: 2px; }
.em-sheet__aside { justify-self: center; min-height: 40px; display: inline-flex; align-items: center; font-size: 14px; }

/* ── Pantallas pequeñas (320px) ── */
@media (max-width: 359px) {
  .em-fan { height: 320px; }
  .em-fan__card { width: 176px; }
  .em-fan__card--left, .em-fan__card--right { width: 150px; }
  .em-price { padding-inline: 16px; }
}

/* Logo + "Equipos"/"Teams" + "Entrar" + selector de idioma necesitan ~367px: por debajo la etiqueta se
   oculta siempre (a 360px ya se pisaba con "Entrar"), no solo cuando "Ver precio" ocupa su lugar. */
@media (max-width: 367px) {
  .lp-header .lp-brand span { display: none; }
}

/* With the language switch and the CTA, "Equipos"/"Teams" only fits from 414px. */
@media (max-width: 413px) {
  .lp-header.lp-has-cta .lp-brand span { display: none; }
}

/* ── Escritorio ── */
@media (min-width: 834px) {
  .em-header-login { font-size: 13px; }
  .lp-header.lp-has-cta .em-header-login { display: inline-flex; }
  .em-fan { height: 470px; margin-top: 56px; }
  .em-fan__card { width: 250px; }
  .em-fan__card--left, .em-fan__card--right { top: 40px; width: 220px; }
  .em-fan__card--left { transform: translateX(-120%) rotate(-7deg); }
  .em-fan__card--right { transform: translateX(20%) rotate(7deg); }

  .em-steps { margin-top: 56px; grid-template-columns: repeat(3, 1fr); gap: 20px; }
  .em-step { padding: 28px; grid-template-columns: 1fr; gap: 18px; }
  .em-step h3 { font-size: 21px; }
  .em-step p { font-size: 16px; }

  .em-shots { margin: 0; max-width: 380px; justify-self: center; }
  .em-price { margin-top: 48px; padding: 32px 32px 28px; }

  .em-sheet {
    width: min(440px, calc(100% - 48px));
    margin: auto;
    border-radius: 24px;
    box-shadow: 0 30px 80px rgba(0, 0, 0, .2);
  }
  .em-sheet__body { padding: 28px; }
}

@media (prefers-reduced-motion: reduce) {
  .em-sheet[open] { animation: none; }
}
