/*
 * Estilo de las páginas de daida-auth (enlace del correo y avisos). Mismos tokens --da-* y
 * clases .da- que la pantalla de acceso compartida de app-conventions/auth/ui, que pinta cada app.
 *
 * Solo lee los tokens --da-*. Cada app cambia los tokens, nunca el markup.
 */

:root {
  /* Solo tema claro, como daidapartners.com. */
  color-scheme: light;
  /* Tema «daida»: los colores, la letra y el radio de daidapartners.com. */
  --da-font: "Instrument Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --da-bg: #f8f8f3;
  --da-surface: #ffffff;
  --da-ink: #151816;
  --da-ink-muted: #4f5b54;
  --da-edge: #7a9171;
  --da-accent: #006747;
  --da-accent-ink: #f8f8f3;
  --da-danger: #a5371b;
  --da-radius: 14px;
  --da-focus: #006747;
}

/* Instrument Sans (OFL 1.1, ver instrument-sans.OFL.txt), servida por daida-auth: nada de fuentes de terceros. */
@font-face {
  font-family: "Instrument Sans";
  font-style: normal;
  font-display: swap;
  font-weight: 400 700;
  src: url("instrument-sans.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

body {
  margin: 0;
  background: var(--da-bg);
}

.da-auth {
  box-sizing: border-box;
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: 24px 16px;
  font-family: var(--da-font);
  color: var(--da-ink);
  background: var(--da-bg);
  -webkit-font-smoothing: antialiased;
}

.da-auth *,
.da-auth *::before,
.da-auth *::after {
  box-sizing: border-box;
}

.da-card {
  width: min(380px, 100%);
  display: grid;
  gap: 16px;
  padding: 32px 24px;
  background: var(--da-surface);
  border: 1px solid var(--da-edge);
  border-radius: var(--da-radius);
}

/* Wordmark «daida /»: letras en --da-ink y barra en --da-accent. */
.da-logo {
  justify-self: center;
  display: block;
  width: auto;
  height: 32px;
  margin-bottom: 4px;
  color: var(--da-ink);
}

.da-logo [data-accent] {
  fill: var(--da-accent);
}

.da-title {
  margin: 0;
  font-size: 1.375rem;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.015em;
  text-align: center;
  text-wrap: balance;
}

.da-auth form {
  margin: 0;
}

.da-confirm {
  display: grid;
  gap: 16px;
}

/* «Entrando…» mientras verify.js envía el formulario: una banda de tinta barre el texto. */
.da-status {
  margin: 0;
  font-size: 1rem;
  font-weight: 500;
  text-align: center;
  color: var(--da-ink-muted);
}

.da-status [data-shimmer] {
  color: transparent;
  background: linear-gradient(90deg, var(--da-ink-muted) 0%, var(--da-ink-muted) 35%, var(--da-ink) 50%, var(--da-ink-muted) 65%, var(--da-ink-muted) 100%);
  background-size: 250% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  animation: da-shimmer 1.4s linear infinite;
}

@keyframes da-shimmer {
  from { background-position: 100% 0; }
  to { background-position: -150% 0; }
}

/* Botón principal (solo el de respaldo sin JS de la página del enlace). */
.da-button {
  width: 100%;
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 16px;
  font: inherit;
  font-size: 1rem;
  font-weight: 600;
  color: var(--da-accent-ink);
  background: var(--da-accent);
  border: 1px solid var(--da-accent);
  border-radius: var(--da-radius);
  cursor: pointer;
  transition: opacity 150ms ease;
}

.da-button:hover {
  opacity: 0.9;
}

.da-hint {
  margin: 0;
  font-size: 0.9375rem;
  line-height: 1.5;
  text-align: center;
  color: var(--da-ink-muted);
}

.da-link {
  justify-self: center;
  /* Zona táctil de 44px sin cambiar cómo se ve el texto. */
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 8px;
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--da-ink);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.da-link:hover {
  text-decoration-thickness: 2px;
}

.da-button:focus-visible,
.da-link:focus-visible {
  outline: 2px solid var(--da-focus);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  .da-auth *,
  .da-auth *::before,
  .da-auth *::after {
    animation: none !important;
    transition: none !important;
  }

  .da-status [data-shimmer] {
    color: var(--da-ink-muted);
    background: none;
  }
}
