/* Rhentto account page (email verification, password reset). The app's
   palette: sage #7A9E7E, deep green #2A6F5E, warm orange #F4A261. */
:root {
  --primary: #7A9E7E;
  --deep: #2A6F5E;
  --accent: #F4A261;
  --error: #DC2626;
  --bg: #F7F7F4;
  --text: #1F2320;
  --muted: #5F6B61;
  --line: #E3E7E2;
  color-scheme: light;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; min-height: 100%; }
body {
  color: var(--text);
  font: 16px/1.5 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background:
    radial-gradient(1100px 520px at 50% -180px, #DCEBDD 0%, rgba(220, 235, 221, 0) 70%),
    var(--bg);
  -webkit-font-smoothing: antialiased;
}
.page {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: max(28px, env(safe-area-inset-top)) 16px max(24px, env(safe-area-inset-bottom));
}
.brand {
  display: flex; align-items: center; gap: 10px;
  font-weight: 700; font-size: 1.3rem; letter-spacing: -0.01em; color: var(--deep);
  margin: 8px 0 24px;
}
.brand img { border-radius: 10px; }
.card {
  width: 100%; max-width: 440px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 32px 24px 24px;
  box-shadow: 0 1px 2px rgba(31, 35, 32, 0.04), 0 12px 32px rgba(42, 111, 94, 0.08);
  text-align: center;
  animation: rise 360ms ease-out both;
}
@keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .card, .badge { animation: none !important; } }

.badge {
  width: 68px; height: 68px; margin: 0 auto 18px;
  border-radius: 50%;
  display: grid; place-items: center;
  background: #EEF4EE;
  color: var(--deep);
}
.badge > * { grid-area: 1 / 1; display: none; }
.badge[data-kind="wait"] .spinner,
.badge[data-kind="ok"] .icon-ok,
.badge[data-kind="key"] .icon-key,
.badge[data-kind="mail"] .icon-mail,
.badge[data-kind="error"] .icon-error { display: block; }
.badge[data-kind="ok"] { background: var(--deep); color: #fff; animation: pop 420ms cubic-bezier(.2, 1.4, .4, 1) both; }
.badge[data-kind="key"], .badge[data-kind="mail"] { background: #FDEBDC; color: #B5602A; }
.badge[data-kind="error"] { background: #FDE2E2; color: var(--error); }
@keyframes pop { from { transform: scale(0.6); } to { transform: scale(1); } }
.icon { width: 32px; height: 32px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.badge[data-kind="ok"] .icon { stroke-width: 2.6; }
.spinner {
  width: 30px; height: 30px; border-radius: 50%;
  border: 3px solid #D3E2D4; border-top-color: var(--deep);
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

h1 { font-size: 1.4rem; line-height: 1.25; margin: 0 0 8px; letter-spacing: -0.01em; }
.text { color: var(--muted); margin: 0 0 4px; overflow-wrap: anywhere; }
.text strong { color: var(--text); font-weight: 600; }

form { text-align: left; margin-top: 20px; }
label { display: block; font-size: 0.9rem; font-weight: 600; margin: 0 0 6px; }
.field { position: relative; margin-bottom: 8px; }
input {
  font: inherit; width: 100%;
  padding: 12px 14px; padding-right: 64px;
  border: 1px solid #CFD8CF; border-radius: 12px; background: #fff; color: var(--text);
  transition: border-color 120ms, box-shadow 120ms;
}
input:focus { outline: none; border-color: var(--deep); box-shadow: 0 0 0 3px rgba(42, 111, 94, 0.15); }
.toggle {
  position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
  font: inherit; font-size: 0.85rem; font-weight: 600; color: var(--deep);
  background: none; border: 0; padding: 8px 10px; border-radius: 8px; cursor: pointer;
}
.toggle:hover { background: #EEF4EE; }
.meter { height: 4px; background: var(--line); border-radius: 4px; overflow: hidden; margin: 2px 0 6px; }
.meter span { display: block; height: 100%; width: 0; background: var(--error); transition: width 200ms, background 200ms; }
.hint { font-size: 0.85rem; color: var(--muted); margin: 0 0 16px; }
.form-error { color: var(--error); font-size: 0.9rem; min-height: 1.2em; margin: 4px 0 10px; }

button.primary, a.primary, a.secondary, button.secondary {
  font: inherit; font-weight: 600;
  display: block; width: 100%;
  padding: 13px 16px; border-radius: 12px;
  text-align: center; text-decoration: none; cursor: pointer;
  border: 1px solid transparent;
  transition: filter 120ms, transform 60ms;
}
.primary { background: var(--deep); color: #fff; }
.primary:hover { filter: brightness(1.08); }
.primary:active { transform: translateY(1px); }
.primary:disabled { opacity: 0.6; cursor: default; filter: none; }
.secondary { background: #fff; color: var(--deep); border-color: #CFD8CF !important; }
.actions { display: grid; gap: 10px; margin-top: 22px; }
.actions:empty { display: none; }
.note {
  margin-top: 18px; padding: 12px 14px;
  background: #F2F6F2; border-radius: 12px;
  font-size: 0.9rem; color: var(--muted); text-align: left;
}

.foot { margin-top: auto; padding-top: 28px; font-size: 0.85rem; color: var(--muted); text-align: center; }
.foot a { color: var(--deep); font-weight: 600; text-decoration: none; }

@media (min-width: 520px) {
  .page { padding-top: 64px; }
  .card { padding: 40px 36px 32px; }
}
