/* KingsEye sign-in. Loaded after keycloak.v2's styles: the frame and sign-in form are ours (ke-*), and the
   PatternFly pieces Keycloak's other pages use (set password, info, error) are given the same look below. */

:root {
  --ke-page: #0f1522;
  --ke-page-2: #131b2b;
  --ke-card: rgba(22, 30, 46, 0.72);
  --ke-card-solid: #161e2e;
  --ke-line: rgba(148, 163, 184, 0.14);
  --ke-line-strong: rgba(148, 163, 184, 0.26);
  --ke-field: rgba(11, 17, 28, 0.55);
  --ke-field-hover: rgba(11, 17, 28, 0.72);
  --ke-ink: #e8edf5;
  --ke-soft: #c3ccda;
  --ke-muted: #8f9bb0;
  --ke-dim: #64718a;

  --ke-violet: #8b5cf6;
  --ke-blue: #3b82f6;
  --ke-cyan: #22d3ee;
  --ke-focus: #6ea2ff;
  --ke-brand: linear-gradient(120deg, #8b5cf6 0%, #4f7cf7 48%, #22c3ec 100%);

  --ke-danger: #f87171;
  --ke-danger-bg: rgba(239, 68, 68, 0.1);
  --ke-danger-line: rgba(248, 113, 113, 0.32);
  --ke-success: #34d399;
  --ke-warning: #fbbf24;

  --ke-radius: 12px;
  --ke-font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* ---------- Page and backdrop ---------- */

html.kingseye,
.kingseye body {
  min-height: 100%;
  background: var(--ke-page);
}

.kingseye body.ke-body {
  margin: 0;
  background:
    radial-gradient(1200px 700px at 50% -10%, #1a2540 0%, transparent 60%),
    linear-gradient(180deg, var(--ke-page-2) 0%, var(--ke-page) 100%);
  background-attachment: fixed;
  color: var(--ke-ink);
  font-family: var(--ke-font);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.ke-backdrop {
  position: fixed;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
}

.ke-glow {
  position: absolute;
  width: 42vmax;
  height: 42vmax;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.32;
  will-change: transform;
}

.ke-glow-violet {
  top: -14vmax;
  left: -10vmax;
  background: radial-gradient(circle, rgba(139, 92, 246, 0.9), transparent 65%);
  animation: ke-drift-a 26s ease-in-out infinite alternate;
}

.ke-glow-blue {
  bottom: -18vmax;
  right: -12vmax;
  background: radial-gradient(circle, rgba(59, 130, 246, 0.85), transparent 65%);
  animation: ke-drift-b 30s ease-in-out infinite alternate;
}

.ke-glow-cyan {
  top: 38%;
  left: 58%;
  width: 26vmax;
  height: 26vmax;
  opacity: 0.18;
  background: radial-gradient(circle, rgba(34, 211, 238, 0.9), transparent 65%);
  animation: ke-drift-c 22s ease-in-out infinite alternate;
}

/* A faint surveillance grid, fading out towards the edges. */
.ke-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(148, 163, 184, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 163, 184, 0.06) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 45%, #000 20%, transparent 75%);
  mask-image: radial-gradient(ellipse 70% 60% at 50% 45%, #000 20%, transparent 75%);
}

@keyframes ke-drift-a { to { transform: translate(8vmax, 6vmax) scale(1.08); } }
@keyframes ke-drift-b { to { transform: translate(-7vmax, -5vmax) scale(1.12); } }
@keyframes ke-drift-c { to { transform: translate(-10vmax, 4vmax) scale(0.9); } }

/* ---------- Layout (in place of PatternFly's login grid) ---------- */

.kingseye .pf-v5-c-login.ke-login {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  min-height: 100dvh;
  padding: 2.5rem 1rem;
  background: none;
}

.kingseye .pf-v5-c-login__container.ke-container {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  width: 100%;
  max-width: 27rem;
  padding: 0;
  margin: 0 auto;
  grid-template-columns: none;
}

/* ---------- Brand ---------- */

.kingseye .ke-brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
  padding: 0;
  margin: 0 0 1.75rem;
  text-align: center;
  animation: ke-rise 0.7s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}

.ke-logo {
  display: block;
  width: 220px;
  max-width: 70%;
  height: auto;
  filter: drop-shadow(0 6px 24px rgba(79, 124, 247, 0.28));
}

.ke-tagline {
  margin: 0;
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ke-muted);
}

/* ---------- Card ---------- */

.kingseye .pf-v5-c-login__main.ke-card {
  position: relative;
  box-sizing: border-box;
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 2rem 2rem 1.75rem;
  border: 1px solid transparent;
  border-radius: 20px;
  background:
    linear-gradient(var(--ke-card), var(--ke-card)) padding-box,
    linear-gradient(140deg, rgba(139, 92, 246, 0.42), rgba(148, 163, 184, 0.12) 38%, rgba(148, 163, 184, 0.1) 62%, rgba(34, 211, 238, 0.38)) border-box;
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  backdrop-filter: blur(18px) saturate(140%);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.05) inset,
    0 24px 60px -12px rgba(2, 6, 16, 0.65),
    0 0 0 1px rgba(2, 6, 16, 0.25);
  transition: box-shadow 0.35s ease;
  animation: ke-rise 0.7s 0.08s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}

.kingseye .ke-card:focus-within {
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.05) inset,
    0 24px 60px -12px rgba(2, 6, 16, 0.65),
    0 0 48px -10px rgba(79, 124, 247, 0.35);
}

@keyframes ke-rise {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: none; }
}

.kingseye .pf-v5-c-login__main-header.ke-card-header {
  display: block;
  padding: 0;
  margin: 0 0 1.5rem;
  border: 0;
}

.kingseye .ke-title,
.kingseye #kc-page-title {
  margin: 0;
  font-family: var(--ke-font);
  font-size: 1.5rem;
  font-weight: 650;
  line-height: 1.25;
  letter-spacing: -0.01em;
  color: var(--ke-ink);
}

.ke-subtitle {
  margin: 0.4rem 0 0;
  font-size: 0.9rem;
  color: var(--ke-muted);
}

.kingseye .pf-v5-c-login__main-body.ke-card-body {
  padding: 0;
}

.kingseye .ke-card .pf-v5-c-login__main-footer {
  padding: 0;
}

/* ---------- The sign-in form ---------- */

.ke-form {
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
}

.ke-field {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.ke-label-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
}

.ke-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--ke-soft);
  letter-spacing: 0.01em;
}

.ke-link,
.kingseye .ke-card a:not(.pf-v5-c-button) {
  color: #8fb4ff;
  font-size: 0.82rem;
  text-decoration: none;
  transition: color 0.2s ease;
}

.ke-link:hover,
.kingseye .ke-card a:not(.pf-v5-c-button):hover {
  color: #b9d0ff;
  text-decoration: underline;
}

.ke-control {
  position: relative;
  display: flex;
  align-items: center;
  border: 1px solid var(--ke-line-strong);
  border-radius: var(--ke-radius);
  background: var(--ke-field);
  transition: border-color 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

.ke-control:hover {
  background: var(--ke-field-hover);
  border-color: rgba(148, 163, 184, 0.36);
}

.ke-control:focus-within {
  border-color: var(--ke-focus);
  background: var(--ke-field-hover);
  box-shadow: 0 0 0 4px rgba(110, 162, 255, 0.16);
}

.ke-control.is-invalid {
  border-color: var(--ke-danger-line);
}

.ke-control.is-invalid:focus-within {
  border-color: var(--ke-danger);
  box-shadow: 0 0 0 4px rgba(248, 113, 113, 0.14);
}

.ke-control-icon {
  flex: none;
  width: 18px;
  height: 18px;
  margin-left: 0.9rem;
  fill: none;
  stroke: var(--ke-dim);
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: stroke 0.2s ease;
}

.ke-control:focus-within .ke-control-icon {
  stroke: var(--ke-focus);
}

.ke-input {
  flex: 1;
  min-width: 0;
  height: 2.9rem;
  padding: 0 0.9rem 0 0.7rem;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ke-ink);
  font: inherit;
  font-size: 0.95rem;
}

.ke-input::placeholder {
  color: var(--ke-dim);
  opacity: 1;
}

/* Browsers' own autofill colours would break the dark field. */
.ke-input:-webkit-autofill,
.ke-input:-webkit-autofill:hover,
.ke-input:-webkit-autofill:focus {
  -webkit-text-fill-color: var(--ke-ink);
  caret-color: var(--ke-ink);
  -webkit-box-shadow: 0 0 0 100px #121a29 inset;
  transition: background-color 9999s ease-out;
}

.ke-reveal {
  display: grid;
  place-items: center;
  flex: none;
  width: 2.5rem;
  height: 2.5rem;
  margin-right: 0.25rem;
  padding: 0;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: var(--ke-dim);
  cursor: pointer;
  transition: color 0.2s ease, background-color 0.2s ease;
}

.ke-reveal:hover {
  color: var(--ke-soft);
  background: rgba(148, 163, 184, 0.08);
}

.ke-reveal:focus-visible {
  outline: 2px solid var(--ke-focus);
  outline-offset: -2px;
}

/* The eye: open while the password shows, crossed out while hidden (passwordVisibility.js swaps the class). */
.ke-eye {
  display: block;
  width: 18px;
  height: 18px;
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 3l18 18'/%3E%3Cpath d='M10.6 6.1A9.8 9.8 0 0 1 12 6c5 0 8.5 4 9.5 6-.4.9-1.3 2.2-2.6 3.4M6.4 7.6C4.6 8.9 3.2 10.7 2.5 12c1 2 4.5 6 9.5 6 1.6 0 3-.4 4.2-1'/%3E%3Cpath d='M9.9 9.9a3 3 0 0 0 4.2 4.2'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 3l18 18'/%3E%3Cpath d='M10.6 6.1A9.8 9.8 0 0 1 12 6c5 0 8.5 4 9.5 6-.4.9-1.3 2.2-2.6 3.4M6.4 7.6C4.6 8.9 3.2 10.7 2.5 12c1 2 4.5 6 9.5 6 1.6 0 3-.4 4.2-1'/%3E%3Cpath d='M9.9 9.9a3 3 0 0 0 4.2 4.2'/%3E%3C/svg%3E") center / contain no-repeat;
}

.ke-eye.is-open {
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M2.5 12C3.5 10 7 6 12 6s8.5 4 9.5 6c-1 2-4.5 6-9.5 6s-8.5-4-9.5-6z'/%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M2.5 12C3.5 10 7 6 12 6s8.5 4 9.5 6c-1 2-4.5 6-9.5 6s-8.5-4-9.5-6z'/%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3C/svg%3E");
}

.ke-check {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-size: 0.85rem;
  color: var(--ke-soft);
  cursor: pointer;
  user-select: none;
}

.ke-check input {
  width: 1rem;
  height: 1rem;
  margin: 0;
  accent-color: var(--ke-blue);
}

/* The sign-in button: the logo's gradient, a light sweep on hover, a spinner while it waits. */
.ke-submit {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  width: 100%;
  height: 3rem;
  margin-top: 0.4rem;
  padding: 0 1.25rem;
  overflow: hidden;
  border: 0;
  border-radius: var(--ke-radius);
  background: var(--ke-brand);
  background-size: 140% 100%;
  background-position: 0% 0;
  color: #fff;
  font: inherit;
  font-size: 0.97rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  cursor: pointer;
  box-shadow: 0 10px 28px -10px rgba(79, 124, 247, 0.75), 0 1px 0 rgba(255, 255, 255, 0.18) inset;
  transition: background-position 0.5s ease, box-shadow 0.25s ease, transform 0.15s ease;
}

.ke-submit::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: -60%;
  width: 45%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.22), transparent);
  transform: skewX(-18deg);
  transition: left 0.7s ease;
}

.ke-submit:hover {
  background-position: 100% 0;
  box-shadow: 0 14px 34px -10px rgba(79, 124, 247, 0.9), 0 1px 0 rgba(255, 255, 255, 0.2) inset;
}

.ke-submit:hover::after {
  left: 120%;
}

.ke-submit:active {
  transform: translateY(1px);
}

.ke-submit:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 2px;
}

.ke-submit-arrow {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform 0.25s ease;
}

.ke-submit:hover .ke-submit-arrow {
  transform: translateX(3px);
}

.ke-submit-busy {
  display: none;
  align-items: center;
  gap: 0.6rem;
}

.ke-submit.is-busy {
  cursor: progress;
  opacity: 0.92;
}

.ke-submit.is-busy .ke-submit-label,
.ke-submit.is-busy .ke-submit-arrow {
  display: none;
}

.ke-submit.is-busy .ke-submit-busy {
  display: inline-flex;
}

.ke-spinner {
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255, 255, 255, 0.35);
  border-top-color: #fff;
  border-radius: 50%;
  animation: ke-spin 0.7s linear infinite;
}

@keyframes ke-spin { to { transform: rotate(360deg); } }

/* The form's own error (wrong email or password). */
.ke-alert {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--ke-danger-line);
  border-radius: var(--ke-radius);
  background: var(--ke-danger-bg);
  color: #fecaca;
  font-size: 0.87rem;
  line-height: 1.45;
  animation: ke-shake 0.4s ease both;
}

.ke-alert svg {
  flex: none;
  width: 18px;
  height: 18px;
  margin-top: 1px;
  fill: none;
  stroke: var(--ke-danger);
  stroke-width: 2;
  stroke-linecap: round;
}

@keyframes ke-shake {
  0%, 100% { transform: none; }
  25% { transform: translateX(-4px); }
  50% { transform: translateX(4px); }
  75% { transform: translateX(-2px); }
}

/* ---------- Footer ---------- */

.ke-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  margin-top: 1.5rem;
  font-size: 0.76rem;
  color: var(--ke-dim);
  animation: ke-rise 0.7s 0.16s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}

.ke-footer svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ---------- Keycloak's other pages (PatternFly), in the same look ---------- */

.kingseye.pf-v5-theme-dark {
  --pf-v5-global--FontFamily--text: var(--ke-font);
  --pf-v5-global--FontFamily--heading: var(--ke-font);
  --pf-v5-global--Color--100: var(--ke-ink);
  --pf-v5-global--Color--200: var(--ke-muted);
  --pf-v5-global--BackgroundColor--100: transparent;
  --pf-v5-global--BorderColor--100: var(--ke-line-strong);
  --pf-v5-global--link--Color: #8fb4ff;
  --pf-v5-global--link--Color--hover: #b9d0ff;
  --pf-v5-global--primary-color--100: var(--ke-blue);
  --pf-v5-c-login__main--BackgroundColor: transparent;
}

.kingseye .ke-card .pf-v5-c-form {
  gap: 1.15rem;
}

.kingseye .ke-card .pf-v5-c-form__label,
.kingseye .ke-card .pf-v5-c-form__label-text {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--ke-soft);
}

.kingseye .ke-card .pf-v5-c-form-control {
  --pf-v5-c-form-control--BackgroundColor: var(--ke-field);
  --pf-v5-c-form-control--Color: var(--ke-ink);
  --pf-v5-c-form-control--PaddingTop: 0.7rem;
  --pf-v5-c-form-control--PaddingBottom: 0.7rem;
  --pf-v5-c-form-control--before--BorderColor: var(--ke-line-strong);
  --pf-v5-c-form-control--after--BorderColor: transparent;
  --pf-v5-c-form-control--hover--after--BorderColor: transparent;
  --pf-v5-c-form-control--focus--after--BorderColor: transparent;
  --pf-v5-c-form-control--after--BorderBottomColor: transparent;
  --pf-v5-c-form-control--hover--after--BorderBottomColor: transparent;
  --pf-v5-c-form-control--focus--after--BorderBottomColor: transparent;
  --pf-v5-c-form-control--focus--after--BorderBottomWidth: 0;
  border-radius: var(--ke-radius);
  transition: box-shadow 0.2s ease;
}

.kingseye .ke-card .pf-v5-c-form-control::before,
.kingseye .ke-card .pf-v5-c-form-control::after {
  border-radius: var(--ke-radius);
}

.kingseye .ke-card .pf-v5-c-form-control:focus-within {
  --pf-v5-c-form-control--before--BorderColor: var(--ke-focus);
  box-shadow: 0 0 0 4px rgba(110, 162, 255, 0.16);
}

.kingseye .ke-card .pf-v5-c-form-control.pf-m-error {
  --pf-v5-c-form-control--before--BorderColor: var(--ke-danger-line);
  --pf-v5-c-form-control--m-error--after--BorderBottomColor: transparent;
  --pf-v5-c-form-control--m-error--hover--after--BorderBottomColor: transparent;
}

.kingseye .ke-card .pf-v5-c-check__label {
  font-size: 0.85rem;
  color: var(--ke-soft);
}

.kingseye .ke-card .pf-v5-c-check__input {
  accent-color: var(--ke-blue);
}

.kingseye .ke-card .pf-v5-c-input-group {
  gap: 0.4rem;
}

.kingseye .ke-card .pf-v5-c-button.pf-m-control {
  --pf-v5-c-button--m-control--BackgroundColor: var(--ke-field);
  --pf-v5-c-button--m-control--after--BorderColor: var(--ke-line-strong);
  --pf-v5-c-button--m-control--after--BorderBottomColor: var(--ke-line-strong);
  --pf-v5-c-button--m-control--hover--after--BorderBottomColor: var(--ke-line-strong);
  --pf-v5-c-button--m-control--focus--after--BorderBottomColor: var(--ke-focus);
  --pf-v5-c-button--m-control--hover--after--BorderBottomWidth: 1px;
  --pf-v5-c-button--m-control--focus--after--BorderBottomWidth: 1px;
  --pf-v5-c-button--BorderRadius: var(--ke-radius);
  color: var(--ke-muted);
}

.kingseye .ke-card .pf-v5-c-button.pf-m-control::after {
  border-radius: var(--ke-radius);
}

.kingseye .ke-card .pf-v5-c-button.pf-m-primary {
  --pf-v5-c-button--BorderRadius: var(--ke-radius);
  --pf-v5-c-button--PaddingTop: 0.75rem;
  --pf-v5-c-button--PaddingBottom: 0.75rem;
  background: var(--ke-brand);
  background-size: 140% 100%;
  color: #fff;
  font-weight: 600;
  box-shadow: 0 10px 28px -10px rgba(79, 124, 247, 0.75);
  transition: background-position 0.5s ease, box-shadow 0.25s ease;
}

.kingseye .ke-card .pf-v5-c-button.pf-m-primary:hover {
  background-position: 100% 0;
  box-shadow: 0 14px 34px -10px rgba(79, 124, 247, 0.9);
}

.kingseye .ke-card .pf-v5-c-button.pf-m-secondary {
  --pf-v5-c-button--BorderRadius: var(--ke-radius);
  --pf-v5-c-button--m-secondary--Color: var(--ke-soft);
  --pf-v5-c-button--m-secondary--hover--Color: var(--ke-ink);
  --pf-v5-c-button--m-secondary--after--BorderColor: var(--ke-line-strong);
  --pf-v5-c-button--m-secondary--hover--after--BorderColor: rgba(148, 163, 184, 0.45);
  --pf-v5-c-button--m-secondary--BackgroundColor: transparent;
}

.kingseye .ke-card .pf-v5-c-form__actions {
  margin-top: 0.4rem;
}

/* Keycloak's notices (expired page, account locked, set your password, ...). */
.kingseye .ke-card .pf-v5-c-alert {
  --pf-v5-c-alert--BackgroundColor: rgba(59, 130, 246, 0.08);
  --pf-v5-c-alert--BoxShadow: none;
  --pf-v5-c-alert--BorderTopWidth: 0;
  --pf-v5-c-alert--PaddingTop: 0.75rem;
  --pf-v5-c-alert--PaddingRight: 0.9rem;
  --pf-v5-c-alert--PaddingBottom: 0.75rem;
  --pf-v5-c-alert--PaddingLeft: 0.9rem;
  border: 1px solid rgba(96, 165, 250, 0.3);
  border-radius: var(--ke-radius);
  font-size: 0.87rem;
}

.kingseye .ke-card .pf-v5-c-alert.pf-m-danger {
  --pf-v5-c-alert--BackgroundColor: var(--ke-danger-bg);
  --pf-v5-c-alert__icon--Color: var(--ke-danger);
  --pf-v5-c-alert__title--Color: #fecaca;
  border-color: var(--ke-danger-line);
}

.kingseye .ke-card .pf-v5-c-alert.pf-m-warning {
  --pf-v5-c-alert--BackgroundColor: rgba(251, 191, 36, 0.08);
  --pf-v5-c-alert__icon--Color: var(--ke-warning);
  --pf-v5-c-alert__title--Color: #fde68a;
  border-color: rgba(251, 191, 36, 0.3);
}

.kingseye .ke-card .pf-v5-c-alert.pf-m-success {
  --pf-v5-c-alert--BackgroundColor: rgba(52, 211, 153, 0.08);
  --pf-v5-c-alert__icon--Color: var(--ke-success);
  --pf-v5-c-alert__title--Color: #a7f3d0;
  border-color: rgba(52, 211, 153, 0.3);
}

.kingseye .ke-card .pf-v5-c-alert.pf-m-info {
  --pf-v5-c-alert__icon--Color: #60a5fa;
  --pf-v5-c-alert__title--Color: #bfdbfe;
}

.kingseye .ke-card .pf-v5-c-alert__title {
  font-weight: 500;
}

.kingseye .ke-card .pf-v5-c-helper-text__item.pf-m-error,
.kingseye .ke-card .pf-v5-c-helper-text__item-text.pf-m-error {
  color: var(--ke-danger);
}

.kingseye .ke-card #kc-info-message p,
.kingseye .ke-card .instruction {
  color: var(--ke-soft);
  line-height: 1.55;
}

/* ---------- Small screens and reduced motion ---------- */

@media (max-width: 480px) {
  .kingseye .pf-v5-c-login.ke-login {
    align-items: flex-start;
    padding-top: 3rem;
  }

  .kingseye .pf-v5-c-login__main.ke-card {
    padding: 1.6rem 1.25rem 1.4rem;
    border-radius: 16px;
  }

  .ke-logo {
    width: 180px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .ke-glow,
  .ke-brand,
  .ke-card,
  .ke-footer,
  .ke-alert {
    animation: none !important;
  }

  .ke-submit,
  .ke-submit::after,
  .ke-submit-arrow {
    transition: none;
  }
}
