/* Página /comprar y avisos de acceso. Va aparte de Tailwind porque solo se usa en estas páginas. */
.rw-comprar {
  margin: 0;
  background: #ffffff;
  color: #0f0f11;
  font-family: "Inter", system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

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

.rw-comprar [hidden] {
  display: none;
}

.rw-comprar :focus-visible {
  outline: 2px solid #fd5c00;
  outline-offset: 2px;
}

.rw-hdr {
  background: #fd5c00;
}

.rw-hdr-in {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  max-width: 1120px;
  margin: 0 auto;
  padding: 14px 24px;
}

.rw-hdr img {
  display: block;
  width: auto;
  height: 30px;
}

.rw-hdr-volver {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: #ffffff;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}

.rw-hdr-volver:hover {
  text-decoration: underline;
}

/* Dos mitades que llegan al borde; el contenido se alinea con el ancho del encabezado */
.rw-pagina {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
}

.rw-res {
  display: grid;
  align-content: start;
  gap: 22px;
  padding: 48px 56px 56px max(24px, calc((100vw - 1120px) / 2 + 24px));
}

.rw-pago-col {
  padding: 48px max(24px, calc((100vw - 1120px) / 2 + 24px)) 56px 56px;
  border-left: 1px solid #e5e7eb;
  background: #f8f9fa;
}

.rw-pago-in {
  max-width: 500px;
}

.rw-cabeza {
  display: grid;
  gap: 12px;
}

.rw-cabeza h1 {
  margin: 0;
  font-size: 34px;
  font-weight: 900;
  letter-spacing: -0.035em;
  line-height: 1.05;
}

.rw-precio {
  margin: 0;
  font-size: 60px;
  font-weight: 900;
  letter-spacing: -0.045em;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.rw-precio small {
  margin-left: 6px;
  color: #52525b;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0;
}

.rw-toggle {
  display: none;
}

.rw-mas {
  display: grid;
  gap: 22px;
}

.rw-fila {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 8px 0;
  color: #52525b;
  font-size: 15px;
}

.rw-fila span:last-child {
  flex: none;
  font-variant-numeric: tabular-nums;
}

.rw-fila.rw-total {
  margin-top: 8px;
  padding-top: 14px;
  border-top: 1px solid #e5e7eb;
  color: #0f0f11;
  font-size: 18px;
  font-weight: 800;
}

.rw-lista {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  font-size: 15px;
  line-height: 1.4;
  list-style: none;
}

.rw-lista li {
  position: relative;
  padding-left: 28px;
}

.rw-lista li::before {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 7px;
  height: 12px;
  border: solid #fd5c00;
  border-width: 0 2.5px 2.5px 0;
  transform: rotate(40deg);
}

.rw-garantia,
.rw-nota {
  margin: 0;
  color: #52525b;
  font-size: 14px;
  line-height: 1.45;
}

.rw-garantia b {
  color: #0f0f11;
}

.rw-nota {
  font-size: 13px;
}

.rw-pago-titulo {
  margin: 0 0 16px;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.rw-alerta {
  margin: 0 0 12px;
  padding: 12px 16px;
  border-radius: 12px;
  background: #fef2f2;
  color: #991b1b;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.45;
}

.rw-alerta a {
  color: inherit;
}

.rw-cargando {
  padding: 56px 0;
  color: #52525b;
  font-size: 15px;
  text-align: center;
}

.rw-seguro {
  margin: 16px 0 0;
  color: #52525b;
  font-size: 13px;
  line-height: 1.45;
  text-align: center;
}

.rw-ftr {
  padding: 24px;
  border-top: 1px solid #e5e7eb;
  color: #52525b;
  font-size: 13px;
  text-align: center;
}

.rw-ftr p {
  margin: 6px 0 0;
}

.rw-ftr a {
  color: inherit;
}

/* Celular y tableta: el precio arriba, el detalle plegado y el formulario de inmediato */
@media (max-width: 860px) {
  .rw-pagina {
    grid-template-columns: minmax(0, 1fr);
  }

  .rw-res {
    gap: 4px;
    padding: 16px 16px 8px;
    border-bottom: 1px solid #e5e7eb;
  }

  .rw-pago-col {
    padding: 20px 16px 40px;
    border-left: 0;
  }

  .rw-pago-in {
    max-width: none;
  }

  .rw-cabeza {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
  }

  .rw-cabeza h1 {
    font-size: 22px;
    letter-spacing: -0.02em;
  }

  .rw-precio {
    flex: none;
    font-size: 26px;
    letter-spacing: -0.03em;
  }

  .rw-precio small {
    margin-left: 4px;
    font-size: 13px;
  }

  .rw-toggle {
    display: inline-flex;
    align-items: center;
    justify-self: start;
    min-height: 44px;
    padding: 0;
    border: 0;
    background: none;
    color: #c94a00;
    font: inherit;
    font-size: 14px;
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 3px;
    cursor: pointer;
  }

  .rw-mas {
    display: none;
    gap: 16px;
    padding-bottom: 12px;
  }

  .rw-res.rw-ver .rw-mas {
    display: grid;
  }

  .rw-pago-titulo {
    font-size: 20px;
  }
}

@media (max-width: 640px) {
  .rw-hdr-in {
    padding: 8px 16px;
  }

  .rw-hdr img {
    height: 20px;
  }
}

/* Avisos de api/acceso.php */
.rw-aviso {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100dvh;
  margin: 0;
  padding: 16px;
  box-sizing: border-box;
  background: #f8f9fa;
  color: #0f0f11;
  font-family: "Inter", system-ui, sans-serif;
}

.rw-aviso-caja {
  width: min(520px, 100%);
  padding: 40px 28px;
  box-sizing: border-box;
  border: 1px solid #e5e7eb;
  border-radius: 24px;
  background: #ffffff;
  text-align: center;
}

.rw-aviso-logo {
  width: auto;
  height: 32px;
  padding: 8px 12px;
  border-radius: 10px;
  background: #fd5c00;
}

.rw-aviso-caja h1 {
  margin: 24px 0 0;
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.rw-aviso-caja p {
  margin: 12px 0 0;
  color: #52525b;
  font-size: 16px;
  line-height: 1.5;
}

.rw-aviso-boton {
  display: inline-block;
  margin-top: 24px;
  padding: 14px 24px;
  border-radius: 16px;
  background: #fd5c00;
  color: #ffffff;
  font-weight: 700;
  text-decoration: none;
}

.rw-aviso-caja .rw-aviso-ayuda {
  margin-top: 20px;
  font-size: 14px;
}

.rw-aviso-ayuda a {
  color: #fd5c00;
  font-weight: 600;
}
