/* =====================
   Design Tokens
====================== */
:root {
  --bg: #fff;
  --brand: #ff7900;
  --grey: #00000099;
  --text: #000;
  --muted: #d9d9d9;
  --greydark: #919191;
  --transparent: transparent;
  --shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
  --maxw: 1080px;
  --font: "Helvetica Neue", Arial, system-ui, sans-serif;
}

/* =====================
   Reset + Tipografía
====================== */
*, *::before, *::after { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

main { flex: 1;  }

img { max-width: 100%; display: block; }

a { color: inherit; text-decoration: none; }

p { font-size: 16px; font-weight: 500; }

h1 { font-size: 28px; font-weight: 700; margin: 0; }

h2 { font-size: 24px; font-weight: 500; margin: 0; }

h3 { font-size: 16px; font-weight: 500; line-height: 24px; margin: 0; }

.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: 20px;
}

.accent { color: var(--brand); }
.inactive { outline-color: var(--muted) !important; }

.hidden { display: none !important; }

/* Botón base */
.btn {
  background: var(--brand);
  color: var(--text);
  border: none;
  padding: 12px 24px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  width: 65%;
}

/* =====================
   Topbar + Header
====================== */
.header {
  position: relative;
  top: 0;
  background: var(--text);
  padding: 15px 20px;
}

.logo { width: 100%; max-width: 30px; }

/* =====================
   Formulario
====================== */
.formulario {
  margin: 64px auto;
  display: flex;
  flex-direction: column;
  justify-content: left;
  text-align: left;
  gap: 16px;
  /*min-height: calc(100vh - 160px);*/
  padding-bottom: 80px;
}

.portada { width: 100%; max-width: 100px; }

.identify {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100%;
  max-width: 400px;
  margin-top: 64px;
}

form .phone {
  padding: 12px 16px;
  font-size: 12px;
  border: 1px solid var(--greydark);
  width: 100%;
}

/* =====================
   Suscripciones
====================== */
.suscripciones {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100%;
  max-width: 600px;
  text-align: left;
  margin: 32px 0;
}

.subtitle { color: var(--greydark); letter-spacing: -0.96px; }

.subs-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-self: stretch;
  font-family: var(--font);
  color: var(--text);
}

.subs-card__header {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 10px;
}

.subs-card__title {
  font-size: 16px;
  line-height: 24px;
  font-weight: 400;
  margin: 0;
}

.subs-card__msisdn {
  font-size: 16px;
  line-height: 24px;
  font-weight: 400;
  color: var(--brand);
  margin: 0;
  text-align: center;
}

.subs-card__divider {
  border: 0;
  height: 0;
  outline: 1px var(--muted) solid;
  outline-offset: -1px;
  border-top: 1px solid
}

.subs-card__divider--brand {
  outline-color: var(--brand);
  width: 100%;
  margin: 0;
}

.subs-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.subs-item__info {
  display: flex;
  flex-direction: column;
  gap: 20px;
  min-width: 0;
}

.subs-item__check {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  user-select: none;
  cursor: pointer;
}

.subs-item__check input { position: relative; pointer-events: none; }

.subs-item__name {
  font-size: 16px;
  line-height: 24px;
  font-weight: 700;
  color: var(--text);
}

.subs-item__checkbox {
  width: 20px;
  height: 20px;
  accent-color: var(--brand);
  cursor: pointer;
}

.subs-item__price {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.subs-item__amount {
  font-size: 32px;
  line-height: 32px;
  font-weight: 700;
}

.subs-item__period { font-size: 14px; font-weight: 400; }

.subs-item__meta {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 0;
  margin: 0;
  list-style: none;
}

.subs-item__meta-row {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.subs-item__icon { width: 20px; height: 20px; }

.subs-item__link,
.subs-item__text {
  font-size: 14px;
  font-weight: 400;
  text-decoration: none;
  color: var(--text);
}

/* Estado inactivo (gris) */
.is-inactive .subs-item__name,
.is-inactive .subs-item__amount,
.is-inactive .subs-item__period,
.is-inactive .subs-item__link,
.is-inactive .subs-item__text {
  color: var(--muted);
  text-decoration-color: var(--muted);
}

.is-inactive ul li img { opacity: 0.3; }

.is-inactive {
  border-color: var(--muted);
  background: #fff;
}

.is-inactive .subs-item__icon { stroke: var(--muted); }

/* Acciones */
.subs-item__actions {
  display: flex;
  flex-direction: column;
  gap: 20px;
  align-items: flex-start;
  justify-content: center;
}

/* Botones */
.btn--subscribe {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  height: 44px;
  padding: 12px 24px;
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
  background: var(--brand);
  color: var(--text);
  text-align: center;
  cursor: pointer;
  border: none;
}

.btn--unsubscribe {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  height: 44px;
  padding: 12px 24px;
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
  border: 2px solid transparent;
  background: transparent;
  color: var(--text);
  text-align: center;
  cursor: pointer;
}

.btn--s { width: 150px; cursor: pointer; }

.btn--outline { border-color: var(--text); background: #fff; }

/* Footer de tarjeta */
.subs-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.subs-card__cancel-date { margin: 0; font-size: 14px; color: var(--muted); }

.subs-card__link { font-size: 14px; color: var(--muted); text-decoration: underline; }

/* =====================
   Background + Popups
====================== */
.bkg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.5);
  z-index: 10;
}

.popup {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: var(--bg);
  padding: 20px;
  box-shadow: var(--shadow);
  z-index: 20;
  width: 90%;
  max-width: 400px;
  text-align: left;
}

.popup__title { margin: 0 0 8px; }

.popup__text { font-weight: 400; line-height: 24px; }

.popup__actions { display: flex; gap: 12px; margin-top: 16px; }

.popup__actions button {
  padding: 12px 24px;
  font-size: 14px;
  font-weight: 400;
  line-height: 1;
  color: var(--text);
  text-align: center;
  cursor: pointer;
}

.btn--confirm { background: var(--transparent); border: 2px solid var(--text); }

.btn--cancel { background: var(--brand); border: none; }

.btn--close { background: var(--brand); border: none; width: 60%; }

/* =====================
   Footer
====================== */
footer .foot {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 16px auto;
  padding: 0 8px;
}

.links {
  display: flex;
  gap: 4px;
  justify-content: center;
  width: 100%;
  align-items: center;
  cursor: pointer;
}

.logos {
  display: flex;
  gap: 12px;
  justify-content: center;
  width: 100%;
  cursor: pointer;
}

.logos a { display: inline-flex; }

.logos a .icon { display: block; }

.foot a {
  color: var(--text);
  font-size: 10px;
  font-weight: 700;
  text-align: center;
}


@media (max-width: 370px) {
  .subs-item { flex-wrap: wrap; }
  .subs-item__actions { width: 100%; }
  .btn--s { width: 100%; }
}