/* Citas DentStudio — app instalable y avisos (2026-10-21) */

/* Banner «Activar avisos / Instalar app» arriba del contenido */
.cd-banner {
  display: flex; align-items: center; gap: 14px;
  margin: 0 0 20px; padding: 14px 16px;
  background: #0B1829; color: #fff; border-radius: 18px;
  box-shadow: 0 12px 28px rgba(11, 24, 41, .14);
}
.cd-banner[hidden] { display: none !important; }
.cd-banner-ic { width: 44px; height: 44px; border-radius: 12px; flex-shrink: 0; }
.cd-banner-tx { flex: 1; min-width: 0; font-size: 13.5px; line-height: 1.45; color: #C9D6E6; }
.cd-banner-tx b { color: #fff; }
.cd-banner-bt { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.cd-b {
  min-height: 40px; padding: 0 16px; border-radius: 11px; border: 1px solid transparent;
  font-weight: 700; font-size: 13px; line-height: 1; font-family: inherit; cursor: pointer; white-space: nowrap;
}
.cd-b-pri { background: #00C9A7; color: #063F38; }
.cd-b-pri:hover { background: #2BD8B9; }
.cd-b-sec { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .3); }
.cd-b-sec:hover { background: rgba(255, 255, 255, .08); }
.cd-b-x { background: transparent; color: #8FA3BC; padding: 0 10px; }
.cd-b-x:hover { color: #fff; }
.cd-b:disabled { opacity: .6; cursor: wait; }

@media (max-width: 640px) {
  .cd-banner { flex-wrap: wrap; padding: 14px; gap: 12px; border-radius: 16px; }
  .cd-banner-tx { flex-basis: calc(100% - 60px); }
  .cd-banner-bt { width: 100%; justify-content: stretch; }
  .cd-banner-bt .cd-b-pri, .cd-banner-bt .cd-b-sec { flex: 1; min-height: 44px; }
}

/* Guías paso a paso (modal) */
.cd-pasos { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.cd-pasos li { display: flex; align-items: flex-start; gap: 12px; font-size: 14px; line-height: 1.5; color: var(--text-2, #526377); }
.cd-pasos b { color: var(--text, #102033); }
.cd-paso-n {
  width: 26px; height: 26px; border-radius: 50%; background: #0B1829; color: #fff;
  font-size: 12px; font-weight: 800; display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.cd-paso-ic {
  width: 34px; height: 34px; border-radius: 10px; background: #EEF6F4; color: #00876F;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.cd-paso-ic svg { width: 18px; height: 18px; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.cd-guia-nota { margin: 16px 0 0; padding: 10px 12px; border-radius: 10px; background: #F4F7FB; font-size: 12.5px; color: var(--text-2, #526377); }

/* Tarjeta «Avisos en este dispositivo» (Mi Perfil) */
.cd-estado { font-size: 13.5px; line-height: 1.5; padding: 10px 12px; border-radius: 12px; border: 1px solid; }
.cd-estado.ok   { background: #F0FDF4; border-color: #BBF7D0; color: #166534; }
.cd-estado.warn { background: #FFFBEB; border-color: #FDE68A; color: #92400E; }
.cd-estado.mal  { background: #FEF2F2; border-color: #FECACA; color: #991B1B; }
.cd-estado.gris { background: #F8FAFC; border-color: #E2E8F0; color: #526377; }
.cd-acciones { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.cd-chip { display: inline-block; font-size: 10.5px; font-weight: 800; padding: 1px 8px; border-radius: 99px; background: #0B1829; color: #fff; vertical-align: 1px; }
.cd-lista-t { font-size: 11px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--text-3, #8A99AA); margin: 16px 0 6px; }
.cd-disp { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 9px 0; border-top: 1px solid var(--border, #E6EDF4); font-size: 13px; font-weight: 600; color: var(--text, #102033); }
.cd-disp small { display: block; font-weight: 400; color: var(--text-3, #8A99AA); font-size: 11.5px; }
.cd-disp .cd-b-x { color: #B91C1C; min-height: 36px; }

/* La campana «timbra» cuando llega un aviso con la app abierta */
@keyframes cdTimbre {
  0%, 100% { transform: rotate(0); }
  15% { transform: rotate(14deg); } 30% { transform: rotate(-12deg); }
  45% { transform: rotate(9deg); } 60% { transform: rotate(-6deg); } 75% { transform: rotate(3deg); }
}
.cd-timbre svg { animation: cdTimbre .9s ease; transform-origin: 50% 10%; }

/* ── Versión en el encabezado ── */
.app-ver {
  flex-shrink: 0; border: 1px solid var(--border, #E6EDF4); background: #F4F7FB; color: #64748B;
  font: 700 10.5px/1 Inter, system-ui, sans-serif; letter-spacing: .02em;
  padding: 4px 7px; border-radius: 99px; cursor: pointer; white-space: nowrap;
}
.app-ver:hover { color: #0B1829; border-color: #C7D6E3; background: #fff; }
.app-ver.hay-nueva { background: #00C9A7; border-color: #00C9A7; color: #063F38; }

/* ── Modal de actualización ── */
.cd-ver-ov {
  position: fixed; inset: 0; z-index: 100050; display: flex; align-items: center; justify-content: center;
  padding: 18px; background: rgba(9, 24, 43, .58); backdrop-filter: blur(6px);
  opacity: 0; transition: opacity .18s ease;
}
.cd-ver-ov.on { opacity: 1; }
.cd-ver-box {
  width: min(420px, 100%); max-height: calc(100dvh - 36px); overflow-y: auto;
  background: #fff; border-radius: 24px; padding: 26px 22px 18px; text-align: center;
  box-shadow: 0 30px 80px rgba(11, 24, 41, .35);
  transform: translateY(10px) scale(.98); transition: transform .22s cubic-bezier(.34, 1.3, .64, 1);
  font-family: Inter, system-ui, sans-serif;
}
.cd-ver-ov.on .cd-ver-box { transform: none; }
.cd-ver-ic { width: 64px; height: 64px; border-radius: 17px; margin: 0 auto 12px; display: block; box-shadow: 0 10px 24px rgba(11, 24, 41, .22); }
.cd-ver-t { font-family: 'Syne', Inter, sans-serif; font-weight: 800; font-size: 19px; color: #0B1829; letter-spacing: -.02em; }
.cd-ver-sub { margin-top: 6px; font-size: 13.5px; color: #526377; line-height: 1.5; }
.cd-ver-sub b { color: #0B1829; }
.cd-ver-notas { list-style: disc; text-align: left; margin: 16px 0 0; padding: 12px 14px 12px 32px; background: #F4F7FB; border-radius: 14px; font-size: 13px; line-height: 1.5; color: #334155; }
.cd-ver-notas li + li { margin-top: 6px; }
.cd-ver-pie { margin-top: 12px; font-size: 12px; color: #8A99AA; }
.cd-ver-bt { display: flex; flex-direction: column; gap: 6px; margin-top: 18px; }
.cd-ver-bt .cd-b { min-height: 48px; font-size: 14.5px; width: 100%; }
.cd-ver-bt .cd-b-x { color: #64748B; min-height: 40px; }
.cd-ver-bt .cd-b-x:hover { color: #0B1829; }
@media (max-width: 480px) {
  .cd-ver-ov { align-items: flex-end; padding: 0; }
  .cd-ver-box { width: 100%; border-radius: 24px 24px 0 0; padding-bottom: calc(18px + env(safe-area-inset-bottom)); }
}
