/* Sign-in pages (layouts/guest.blade.php) on the EMS design system.
   Scoped to .ems-auth so the Breeze/Tailwind views themselves stay untouched. */
.ems-auth {
    --ems-primary: #2563eb; --ems-primary-hover: #1d4ed8; --ems-primary-ring: rgba(37, 99, 235, .18);
    --ems-sidebar-bg: #1e3a8a; --ems-ink: #0f172a; --ems-text: #334155; --ems-muted: #64748b; --ems-subtle: #94a3b8;
    --ems-border: #e2e8f0; --ems-border-strong: #cbd5e1; --ems-page: #f4f6fa;
    --ems-danger-text: #b91c1c; --ems-success-text: #15803d;
    min-height: 100vh; min-height: 100dvh;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    padding: max(1.5rem, env(safe-area-inset-top)) 1rem max(1.5rem, env(safe-area-inset-bottom));
    background: var(--ems-page);
    color: var(--ems-text);
    font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    font-size: .875rem; -webkit-font-smoothing: antialiased;
}

.ems-auth-brand { display: flex; align-items: center; gap: .65rem; margin-bottom: 1.25rem; color: var(--ems-ink); text-decoration: none; }
.ems-auth-brand-icon { display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 10px; background: var(--ems-sidebar-bg); color: #fff; font-size: 1rem; }
.ems-auth-brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.ems-auth-brand-text strong { font-size: 1.125rem; font-weight: 700; letter-spacing: .01em; }
.ems-auth-brand-text small { color: var(--ems-muted); font-size: .75rem; font-weight: 500; }

.ems-auth-card {
    width: 100%; max-width: 400px; padding: 1.5rem;
    background: #fff; border: 1px solid var(--ems-border); border-radius: 12px;
    box-shadow: 0 1px 3px rgba(15, 23, 42, .06), 0 1px 2px rgba(15, 23, 42, .04);
}

/* Text */
.ems-auth-card .text-sm, .ems-auth-card p, .ems-auth-card div { font-size: .8125rem; }
.ems-auth-card .text-gray-600, .ems-auth-card .text-gray-500 { color: var(--ems-muted); }
.ems-auth-card label { color: var(--ems-text); font-size: .75rem; font-weight: 600; }
.ems-auth-card label.inline-flex { font-weight: 500; }

/* Inputs */
.ems-auth-card input[type="email"],
.ems-auth-card input[type="password"],
.ems-auth-card input[type="text"] {
    height: 40px; padding: 0 .75rem;
    border: 1px solid var(--ems-border-strong); border-radius: 8px;
    color: var(--ems-ink); font-size: 16px; /* no iOS zoom */
    box-shadow: none;
}
.ems-auth-card input[type="email"]:focus,
.ems-auth-card input[type="password"]:focus,
.ems-auth-card input[type="text"]:focus { border-color: var(--ems-primary); box-shadow: 0 0 0 3px var(--ems-primary-ring); outline: 0; }
.ems-auth-card input[type="checkbox"] { width: 16px; height: 16px; border-color: var(--ems-border-strong); border-radius: 4px; color: var(--ems-primary); accent-color: var(--ems-primary); }
.ems-auth-card input[type="checkbox"]:focus { box-shadow: 0 0 0 3px var(--ems-primary-ring); }

/* Buttons and links */
.ems-auth-card button[type="submit"] {
    min-height: 40px; padding: 0 1.25rem;
    background: var(--ems-primary); border: 1px solid var(--ems-primary); border-radius: 8px;
    color: #fff; font-size: .8125rem; font-weight: 600; letter-spacing: 0; text-transform: none;
}
.ems-auth-card button[type="submit"]:hover,
.ems-auth-card button[type="submit"]:focus { background: var(--ems-primary-hover); border-color: var(--ems-primary-hover); box-shadow: 0 0 0 3px var(--ems-primary-ring); }
.ems-auth-card a, .ems-auth-card a.text-gray-600 { color: var(--ems-primary); text-decoration: none; }
.ems-auth-card a:hover { color: var(--ems-primary-hover); text-decoration: underline; }
.ems-auth-card a:focus { box-shadow: 0 0 0 3px var(--ems-primary-ring); border-radius: 4px; outline: 0; }

/* Validation / status messages */
.ems-auth-card ul.text-red-600, .ems-auth-card .text-red-600 { color: var(--ems-danger-text); font-size: .75rem; }
.ems-auth-card .text-green-600 { color: var(--ems-success-text); }

.ems-auth-footer { margin-top: 1.25rem; color: var(--ems-subtle); font-size: .75rem; }

@media (max-width: 420px) {
    .ems-auth { justify-content: flex-start; padding-top: max(2.5rem, env(safe-area-inset-top)); }
    .ems-auth-card { padding: 1.25rem; }
}
