/* ══════════════════════════════════════════════════════════════
   SCREENS.CSS — Pantallas de inicio (código, login, pendiente)
   ══════════════════════════════════════════════════════════════ */

.screen {
  position: fixed; inset: 0;
  background: var(--bg);
  z-index: 900;
  display: flex; align-items: center; justify-content: center;
  padding: 1rem;
}

.screen-box {
  background: var(--card);
  border: 1px solid var(--border);
  padding: 2.5rem;
  max-width: 440px; width: 100%;
  animation: fadeIn .3s ease;
  box-shadow: var(--shadow-md);
}

.screen-logo { display: flex; align-items: center; gap: .85rem; margin-bottom: 2rem; }

.screen-badge {
  background: var(--accent); color: #fff;
  font-family: 'Space Mono', monospace;
  font-size: .8rem; font-weight: 700;
  padding: .3rem .85rem;
  clip-path: polygon(0 0, calc(100% - 8px) 0, 100% 100%, 0 100%);
}

.screen-title { font-size: 1.25rem; font-weight: 800; letter-spacing: .04em; }
.screen-title span { color: var(--accent); }
.screen-sub {
  font-family: 'Space Mono', monospace;
  font-size: .62rem; color: var(--muted);
  text-transform: uppercase; letter-spacing: .1em; margin-top: .2rem;
}

/* ── Step: código ── */
.code-step { display: flex; flex-direction: column; gap: 1.25rem; }
.code-step h2 {
  font-size: .85rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .08em; color: var(--muted);
  border-bottom: 1px solid var(--border); padding-bottom: .75rem;
}

.code-input {
  font-family: 'Space Mono', monospace;
  font-size: 1.6rem; letter-spacing: .35em;
  text-align: center; padding: .85rem;
  text-transform: uppercase;
  border: 2px solid var(--border);
  background: var(--input-bg); color: var(--text); width: 100%;
  outline: none; transition: border-color .2s;
}
.code-input:focus { border-color: var(--accent); }

.code-hint {
  font-family: 'Space Mono', monospace;
  font-size: .67rem; color: var(--muted);
  text-align: center; line-height: 1.6; margin-top: .5rem;
}

.screen-error {
  color: var(--accent);
  font-family: 'Space Mono', monospace;
  font-size: .75rem; text-align: center; min-height: 1.2em;
}

/* ── Step: ambulancia ── */
.code-ambs { display: flex; flex-direction: column; gap: .6rem; margin-top: .5rem; }
.code-amb-opt {
  display: flex; align-items: center; gap: .75rem;
  background: var(--input-bg);
  border: 2px solid var(--border);
  padding: .75rem 1rem; cursor: pointer;
  transition: border-color .2s;
}
.code-amb-opt:hover { border-color: var(--blue); }
.code-amb-opt.sel   { border-color: var(--accent); }
.code-amb-icon { font-size: 1.4rem; }
.code-amb-info { flex: 1; }
.code-amb-name { font-weight: 700; font-size: .9rem; }
.code-amb-desc {
  font-family: 'Space Mono', monospace;
  font-size: .65rem; color: var(--muted); margin-top: .1rem;
}

/* ── Login form ── */
.login-form { display: flex; flex-direction: column; gap: .9rem; }
.login-section-title {
  font-family: 'Space Mono', monospace;
  font-size: .75rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .08em; color: var(--muted);
  border-bottom: 1px solid var(--border); padding-bottom: .75rem;
}
.login-footer {
  margin-top: 1.25rem;
  font-family: 'Space Mono', monospace;
  font-size: .63rem; color: var(--muted); text-align: center;
}

.back-btn {
  background: none; border: none;
  color: var(--muted);
  font-family: 'Space Mono', monospace; font-size: .7rem;
  cursor: pointer; text-align: left; padding: 0;
  margin-bottom: .25rem;
  display: flex; align-items: center; gap: .4rem;
}
.back-btn:hover { color: var(--text); }

/* ── Pantalla pendiente ── */
.device-id-display {
  font-family: 'Space Mono', monospace;
  font-size: .9rem; font-weight: 700;
  background: var(--input-bg);
  border: 2px solid var(--accent2);
  padding: .75rem 1rem; letter-spacing: .05em; margin-bottom: 1rem;
}

/* ── Notificación flotante ── */
.notif-bubble {
  position: fixed; top: 80px; right: 1.5rem;
  background: var(--card);
  border: 1px solid var(--accent2); border-left: 4px solid var(--accent2);
  padding: .75rem 1.1rem; z-index: 800;
  font-family: 'Space Mono', monospace; font-size: .72rem; color: var(--accent2);
  max-width: 320px; line-height: 1.6;
  transform: translateX(400px); transition: transform .4s;
}
.notif-bubble.show { transform: translateX(0); }

@media (max-width: 640px) {
  .screen-box { padding: 1.5rem; }
}
