.rf-auth-page {
  isolation: isolate;
  position: relative;
  display: flex;
  justify-content: center;
  min-height: 100vh;
  min-height: 100dvh;
  width: 100%;
  overflow: hidden;
  color: #f8fafc;
  background:
    radial-gradient(ellipse at 17% 43%, #0b446b 0%, transparent 48%),
    radial-gradient(ellipse at 76% 87%, #07375c 0%, transparent 52%),
    linear-gradient(147deg, #041a30 0%, #062745 52%, #031a30 100%);
}

.rf-auth-art { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: -1; }
.rf-auth-glow-line { filter: drop-shadow(0 0 8px #ffd08b); }
.rf-auth-content { width: 100%; max-width: 550px; padding: 40px 22px 52px; display: flex; flex-direction: column; align-items: center; }
.rf-auth-security { display: inline-flex; align-items: center; justify-content: center; gap: 11px; border: 1px solid #e6ad5b; border-radius: 999px; padding: 9px 24px; font-size: 13px; font-weight: 800; letter-spacing: .08em; box-shadow: inset 0 0 0 1px #65491c, 0 0 12px #df9d512a; }
.rf-auth-security svg { color: #f7b65f; }
.rf-auth-brand { margin: 31px auto 27px; width: 150px; height: 150px; padding: 6px; overflow: hidden; border-radius: 34px; border: 1.5px solid #f7c679; background: linear-gradient(130deg,#00426d,#021b33 75%); box-shadow: 0 0 0 5px #dba45315, 0 0 32px #f6bc714b, inset 0 0 16px #dba45370; }
.rf-auth-brand img { width: 100%; height: 100%; border-radius: 28px; object-fit: cover; }
.rf-auth-heading { width: 100%; text-align: center; }
.rf-auth-heading h1 { font-size: clamp(28px, 6.8vw, 41px); line-height: 1.16; font-weight: 800; letter-spacing: -.035em; color: #fff; text-wrap: balance; }
.rf-auth-heading h1 span { display: block; color: #f7c477; text-shadow: 0 2px 14px #dd8b3361; }
.rf-auth-gold-rule { width: 135px; height: 2px; margin: 17px auto 13px; background: linear-gradient(90deg, transparent, #ffd59a 50%, transparent); box-shadow: 0 1px 12px #ffd59a; }
.rf-auth-heading p { font-size: clamp(14px, 3.5vw, 17px); color: #e8edf5; }
.rf-auth-panel { width: 100%; margin-top: 27px; padding: 31px 28px 29px; border: 2px solid #f3f5fb; border-radius: 30px; color: #071c3d; background: linear-gradient(130deg,#e8edf6 0%,#c8d3e2 54%,#e5ebf5 100%); box-shadow: 0 18px 45px #00122493, inset 0 2px 18px #ffffff83; }
.rf-auth-form { display: grid; gap: 21px; }
.rf-auth-field { display: grid; gap: 9px; }
.rf-auth-label { display: flex; align-items: center; gap: 12px; font-size: 15px; color: #081c3e; font-weight: 800; }
.rf-auth-label svg { color: #08244d; flex: none; }
.rf-auth-input-wrap { position: relative; }
.rf-auth-input { width: 100%; height: 55px; min-width: 0; border: 1.5px solid #8f9ab0; border-radius: 15px; background: #fff; color: #0b254a; padding: 0 17px; font-size: 15px; outline: none; box-shadow: inset 0 1px 4px #162a4a0b; }
.rf-auth-input::placeholder { color: #79869e; }
.rf-auth-input:focus-visible { border-color: #097b91; box-shadow: 0 0 0 3px #11b9c33a; }
.rf-auth-input:disabled { opacity: .65; }
.rf-auth-input-with-icon { padding-right: 53px; }
.rf-auth-eye { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); width: 42px; height: 42px; display: grid; place-items: center; border-radius: 11px; color: #748199; }
.rf-auth-eye:hover, .rf-auth-eye:focus-visible { background: #e5edf7; color: #075d79; }
.rf-auth-forgot { margin-top: -8px; justify-self: end; color: #087f87; font-weight: 800; font-size: 13px; }
.rf-auth-forgot:hover, .rf-auth-forgot:focus-visible { text-decoration: underline; }
.rf-auth-submit { width: 100%; height: 62px; display: flex; align-items: center; justify-content: center; gap: 16px; padding: 0 16px; color: #fff; font-weight: 800; font-size: 23px; border-radius: 999px; background: linear-gradient(108deg,#04284b 3%,#035b77 63%,#08a7ad 100%); box-shadow: 0 12px 19px #092b4b59; transition: transform .15s, filter .15s; }
.rf-auth-submit svg { color: #22f8e9; }
.rf-auth-submit:hover:not(:disabled) { filter: brightness(1.08); }
.rf-auth-submit:active:not(:disabled) { transform: translateY(1px); }
.rf-auth-submit:disabled { cursor: wait; opacity: .65; }
.rf-auth-alert { display: flex; align-items: flex-start; gap: 9px; padding: 12px 13px; margin-bottom: 19px; font-size: 13px; line-height: 1.45; border-radius: 12px; font-weight: 600; }
.rf-auth-alert svg { flex: none; margin-top: 1px; }
.rf-auth-alert-error { color: #8a1730; background: #fff1f2; border: 1px solid #fecdd3; }
.rf-auth-alert-success { color: #075b45; background: #e1f7ee; border: 1px solid #88d9ba; }
.rf-auth-helper { font-size: 13px; line-height: 1.55; color: #42536d; margin-bottom: 20px; }
.rf-auth-back { display: inline-flex; align-items: center; gap: 9px; font-weight: 700; font-size: 14px; margin-top: 30px; padding: 8px; color: #eaf0f7; }
.rf-auth-back:hover, .rf-auth-back:focus-visible { color: #ffd192; }
.rf-auth-footer { text-align: center; color: #b8c6d8; font-size: 12px; margin-top: 45px; }
.rf-auth-footer span { margin: 0 6px; }
.rf-auth-secondary { display: block; margin: 17px auto 0; color: #07577b; font-weight: 750; font-size: 13px; }
.rf-auth-secondary:hover { text-decoration: underline; }
.rf-auth-demo { border-top: 1px solid #aab6c9; margin-top: 22px; padding-top: 15px; display: grid; gap: 8px; }
.rf-auth-demo button { padding: 9px; background: #fff9; border: 1px solid #abc; border-radius: 10px; color: #0c2949; font-size: 12px; }
.rf-auth-demo p { color: #334763; font-size: 11px; text-align: center; font-weight: 700; }
@media (max-width: 440px) {
  .rf-auth-content { padding: 28px 19px 38px; }
  .rf-auth-security { padding: 8px 18px; font-size: 12px; }
  .rf-auth-brand { width: 133px; height: 133px; margin-top: 25px; margin-bottom: 26px; border-radius: 30px; }
  .rf-auth-brand img { border-radius: 25px; }
  .rf-auth-panel { padding: 25px 19px 26px; border-radius: 26px; margin-top: 23px; }
  .rf-auth-input { height: 53px; }
  .rf-auth-submit { height: 59px; }
  .rf-auth-footer { margin-top: 38px; }
}
@media (prefers-reduced-motion: reduce) { .rf-auth-submit { transition: none; } }

/* Recovery screen is isolated from the signed-in application while the
   temporary password-recovery session is active. */
html.rf-recover-active #root { display: none !important; }
.rf-reset-overlay { position: fixed; inset: 0; z-index: 999999; overflow-y: auto; background: #041a30; }
.rf-reset-overlay [hidden] { display: none !important; }
.rf-auth-symbol { display: inline-flex; align-items: center; justify-content: center; min-width: 22px; font-size: 19px; color: #06274b; }
.rf-auth-submit .rf-auth-symbol { color: #20f7e6; font-size: 26px; }
.rf-auth-submit:disabled { opacity: .6; cursor: not-allowed; }

/* V55: all login controls fit in a short iPhone/Safari viewport. The rules
   change only spacing and typography; sign-in and recovery stay unchanged. */
@media (max-width: 480px) {
  .rf-auth-content {
    max-width: 420px;
    padding: max(12px, 2.5dvh) 16px max(10px, 2dvh);
  }
  .rf-auth-security {
    min-height: 30px;
    padding: 5px 15px;
    gap: 7px;
    font-size: 11px;
    line-height: 1.2;
  }
  .rf-auth-security svg { width: 17px; height: 17px; }
  .rf-auth-brand {
    width: clamp(94px, 14dvh, 112px);
    height: clamp(94px, 14dvh, 112px);
    margin: 11px auto 12px;
    padding: 4px;
    border-radius: 25px;
  }
  .rf-auth-brand img { border-radius: 20px; }
  .rf-auth-heading h1 {
    font-size: clamp(26px, 7.6vw, 33px);
    line-height: 1.09;
    letter-spacing: -.04em;
  }
  .rf-auth-gold-rule { width: 108px; margin: 9px auto 7px; }
  .rf-auth-heading p { font-size: 13px; line-height: 1.35; }
  .rf-auth-panel {
    margin-top: 14px;
    padding: 18px 17px 19px;
    border-radius: 25px;
    border-width: 1.5px;
  }
  .rf-auth-form { gap: 13px; }
  .rf-auth-field { gap: 5px; }
  .rf-auth-label { gap: 8px; font-size: 13px; }
  .rf-auth-label svg { width: 18px; height: 18px; }
  .rf-auth-input {
    height: 46px;
    border-radius: 13px;
    padding: 0 13px;
    font-size: 14px;
  }
  .rf-auth-eye { width: 40px; height: 40px; }
  .rf-auth-forgot {
    margin-top: -4px;
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    font-size: 12px;
  }
  .rf-auth-submit {
    height: 51px;
    gap: 12px;
    font-size: 19px;
    box-shadow: 0 8px 16px #092b4b52;
  }
  .rf-auth-submit svg { width: 23px; height: 23px; }
  .rf-auth-back {
    margin-top: 12px;
    min-height: 36px;
    padding: 6px 8px;
    font-size: 12px;
  }
  .rf-auth-footer { margin-top: 12px; font-size: 10px; }
}

@media (max-width: 440px) and (max-height: 760px) {
  .rf-auth-content { padding-top: 10px; padding-bottom: 10px; }
  .rf-auth-security { min-height: 28px; }
  .rf-auth-brand { width: 96px; height: 96px; margin: 8px auto 11px; }
  .rf-auth-heading h1 { font-size: 27px; }
  .rf-auth-gold-rule { margin: 8px auto 6px; }
  .rf-auth-panel { margin-top: 10px; padding: 15px 15px 16px; }
  .rf-auth-form { gap: 10px; }
  .rf-auth-field { gap: 4px; }
  .rf-auth-input { height: 44px; }
  .rf-auth-submit { height: 47px; font-size: 18px; }
  .rf-auth-back { margin-top: 6px; }
  .rf-auth-footer { display: none; }
}
