/* Mismos tokens que AppColors (miluno-app/lib/theme/app_theme.dart) */
:root {
  --brandD: #1E3530;
  --brand: #4E7A6B;
  --accent: #B8892A;
  --success: #2E7048;
  --danger: #C02020;
  --white: #FFFFFF;
  --text-2: rgba(255, 255, 255, 0.65);
  --text-3: rgba(255, 255, 255, 0.45);
  --glass: rgba(255, 255, 255, 0.06);
  --glass-border: rgba(255, 255, 255, 0.14);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  min-height: 100%;
  background: var(--brandD);
  color: var(--white);
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}

body { overflow-x: hidden; position: relative; }

.blob {
  position: fixed;
  border-radius: 50%;
  pointer-events: none;
}
.blob-tr {
  width: 360px; height: 360px; top: -120px; right: -100px;
  background: radial-gradient(circle, rgba(78, 122, 107, 0.16), transparent 70%);
}
.blob-bl {
  width: 300px; height: 300px; bottom: -100px; left: -100px;
  background: radial-gradient(circle, rgba(184, 137, 42, 0.10), transparent 70%);
}

.wrap {
  position: relative;
  max-width: 420px;
  margin: 0 auto;
  padding: max(56px, env(safe-area-inset-top)) 28px 40px;
}

.brand { display: flex; align-items: center; gap: 12px; margin-bottom: 40px; }
.brand-mark {
  width: 44px; height: 44px;
  display: grid; place-items: center;
  font-size: 22px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.10);
}
.brand-name { font-size: 10px; letter-spacing: 0.16em; font-weight: 600; color: rgba(255, 255, 255, 0.55); }
.brand-sub { font-size: 12px; color: rgba(255, 255, 255, 0.5); margin-top: 2px; }

h1 {
  font-size: 32px;
  font-weight: 600;
  line-height: 1.08;
  letter-spacing: -0.02em;
  margin: 0 0 12px;
}
h1 em { font-style: italic; color: var(--accent); }

.lead { font-size: 14.5px; line-height: 1.55; color: var(--text-2); margin: 0 0 28px; }
.lead strong { color: var(--white); font-weight: 600; }
.hint { font-size: 12.5px; line-height: 1.5; color: var(--text-3); margin: 18px 0 0; }

.icon {
  width: 56px; height: 56px;
  display: grid; place-items: center;
  border-radius: 18px;
  font-size: 26px; font-weight: 700;
  margin-bottom: 24px;
}
.icon-ok { background: rgba(46, 112, 72, 0.25); color: #8FD3A8; border: 1px solid rgba(143, 211, 168, 0.3); }
.icon-error { background: rgba(192, 32, 32, 0.18); color: #FF9A9A; border: 1px solid rgba(255, 154, 154, 0.3); }

.spinner {
  width: 32px; height: 32px;
  border-radius: 50%;
  border: 3px solid rgba(255, 255, 255, 0.15);
  border-top-color: var(--white);
  animation: spin 0.8s linear infinite;
  margin-bottom: 24px;
}
@keyframes spin { to { transform: rotate(360deg); } }

.btn {
  display: flex; align-items: center; justify-content: center;
  width: 100%;
  padding: 15px 20px;
  border-radius: 14px;
  font: inherit; font-size: 15px; font-weight: 600;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: opacity 0.2s;
}
.btn:disabled { opacity: 0.6; cursor: default; }
.btn-primary { background: var(--white); color: var(--brandD); box-shadow: 0 8px 24px rgba(0, 0, 0, 0.28); }
.btn-secondary { background: var(--glass); color: var(--white); border: 1px solid var(--glass-border); }

.field-label {
  display: block;
  font-size: 11px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
  margin: 0 0 8px;
}
.field {
  display: flex; align-items: center;
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: 14px;
  margin-bottom: 16px;
  transition: border-color 0.2s;
}
.field:focus-within { border-color: rgba(255, 255, 255, 0.5); }
.field.invalid { border-color: var(--danger); }
.field input {
  flex: 1; min-width: 0;
  background: transparent; border: none; outline: none;
  color: var(--white);
  font: inherit; font-size: 16px; /* 16px evita el zoom de iOS */
  padding: 14px;
}
.field input::placeholder { color: rgba(255, 255, 255, 0.28); }
.toggle {
  background: none; border: none; cursor: pointer;
  color: rgba(255, 255, 255, 0.5);
  font: inherit; font-size: 12.5px; font-weight: 500;
  padding: 0 14px;
}

.error {
  font-size: 13px; line-height: 1.45;
  color: rgba(255, 255, 255, 0.92);
  background: rgba(192, 32, 32, 0.18);
  border: 1px solid rgba(192, 32, 32, 0.35);
  border-radius: 10px;
  padding: 10px 14px;
  margin: 0 0 16px;
}

[hidden] { display: none !important; }
