/* WL Platform login theme – aligns Keycloak form with wl-frontend login styling */

:root {
  --wl-font: "Inter", system-ui, -apple-system, sans-serif;
  --wl-primary: #0f0f0f;
  --wl-primary-contrast: #ffffff;
  --wl-accent: #4338ca; /* matches high-indigo */
  --wl-surface: #ffffff;
  --wl-surface-muted: #f3f4f6;
  --wl-border: #e5e7eb;
  --wl-radius: 14px;
  --wl-shadow: 0 22px 70px rgba(15, 15, 15, 0.12);
}

body {
  font-family: var(--wl-font);
  background:
    radial-gradient(circle at 15% 20%, #e0e7ff 0, transparent 32%),
    radial-gradient(circle at 82% 18%, #dbeafe 0, transparent 30%),
    radial-gradient(circle at 20% 80%, #e0f2fe 0, transparent 30%),
    linear-gradient(180deg, #f8fafc 0%, #eef2f7 40%, #e5e7eb 100%);
  min-height: 100vh;
  color: #111827;
}

body.login-pf {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(32px, 6vh, 96px) 16px;
  min-height: 100vh;
}

.login-pf-page,
.login-pf {
  background: transparent !important;
}

.login-pf body {
  background: transparent !important;
}

#kc-container-wrapper,
#kc-container,
#kc-content {
  width: 100%;
}

.wl-login-shell {
  display: flex;
  justify-content: center;
  width: 100%;
}

.wl-card {
  border: none !important;
  border-radius: var(--wl-radius);
  box-shadow: none !important;
  background: var(--wl-surface);
  padding: 32px 36px;
  max-width: 420px;
  width: 100%;
}

.card-pf {
  border: none !important;
  box-shadow: none !important;
  background: transparent !important;
}

#kc-header,
#kc-header-wrapper {
  display: none !important;
}

#kc-page-title {
  font-weight: 700;
  color: var(--wl-primary);
}

#kc-header-wrapper {
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-items: center;
  color: var(--wl-primary);
  font-weight: 600;
}

.login-pf-page .login-pf-header {
  margin-bottom: 12px;
}

.card-pf form {
  margin-top: 8px;
}

.form-group label {
  font-weight: 500;
  color: #111827;
}

.form-control {
  border-radius: 8px;
  border: 1px solid #cbd5e1;
  padding: 12px 14px;
  box-shadow: none;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}

.form-control:focus {
  border-color: var(--wl-accent);
  box-shadow: 0 0 0 2px rgba(67, 56, 202, 0.18);
}

.btn-primary {
  background: var(--wl-primary);
  color: var(--wl-primary-contrast);
  border: none;
  border-radius: 12px;
  padding: 12px 16px;
  font-weight: 600;
  width: 100%;
  box-shadow: 0 12px 24px rgba(15, 15, 15, 0.18);
  transition: transform 120ms ease, box-shadow 120ms ease, background-color 120ms ease;
}

.btn-primary:hover,
.btn-primary:focus {
  background: #0b1324;
  transform: translateY(-1px);
  box-shadow: 0 16px 28px rgba(15, 15, 15, 0.2);
  color: var(--wl-primary-contrast);
}

.btn {
  height: auto;
}

.wl-login-shell .list-unstyled {
  padding-left: 0;
}

.wl-header {
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-items: center;
  margin-top: clamp(16px, 5vh, 72px);
  margin-bottom: 16px;
  text-align: center;
}

.wl-logo-circle {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: #000;
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 700;
  letter-spacing: 0.5px;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.18);
}

.wl-heading {
  font-weight: 700;
  font-size: 1.4rem;
  color: var(--wl-primary);
  margin: 0;
}

.wl-logo-image {
  width: 200px;
  height: auto;
  margin-bottom: 4px;
}

.wl-subtitle {
  margin: 0;
  color: #4b5563;
}

.wl-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.wl-forgot a {
  color: var(--wl-accent);
  font-weight: 600;
}

.wl-signup {
  display: flex;
  gap: 8px;
  justify-content: center;
  margin-top: 12px;
  color: #4b5563;
}

.wl-signup a {
  color: var(--wl-accent);
  font-weight: 700;
}

.wl-social-btn {
  text-align: center;
  padding: 10px 12px;
}

.login-pf-page .login-pf-signup a,
.login-pf-page .kc-registration a {
  color: var(--wl-accent);
  font-weight: 600;
}

.checkbox label {
  color: #111827;
}

.alert-error {
  border-radius: 12px;
  border: 1px solid #fecdd3;
  background: #fef2f2;
  color: #991b1b;
}

#kc-social-providers {
  margin-top: 12px;
}

#kc-social-providers ul {
  gap: 10px;
}

#kc-social-providers .btn {
  border-radius: 12px;
  border: 1px solid var(--wl-border);
  color: #111827;
  background: var(--wl-surface-muted);
}

#kc-social-providers .btn:hover {
  border-color: var(--wl-accent);
  color: var(--wl-primary);
}

.login-pf-page .login-pf-brand {
  max-width: 64px;
  margin-bottom: 8px;
}

.login-pf-page .list-view-pf-icon-lg {
  width: 64px;
  height: 64px;
}
