/* صفحهٔ بارگذاری و ورود پنل — هم‌زبان با پنل داخلی (گرافیت + نارنجی)، ۲۰۲۶-۱۰-۱۲.
   مستقل از style.css تا قواعد سراسری input/body روی این دو صفحه اثر نگذارند. */
@font-face{font-family:'Vazirmatn';src:url('../fonts/Vazirmatn[wght].woff2') format('woff2-variations'),url('../fonts/Vazirmatn[wght].woff2') format('woff2');font-weight:100 900;font-display:swap}

.ea{
  --bg:#12181b; --text:#eef3f4; --muted:#a3b0b5; --muted-2:#7c8a90;
  --line:#ffffff1a; --field:#0f1416; --field-line:#707d83; /* مرز فیلد ≥۳:۱ روی کارت و خود فیلد */
  --accent:#ff7a3d; --accent-dark:#e0521b; --accent-ink:#ffc2a3;
  --danger:#ff6b7c; --danger-bg:#ff546814; --warn:#ffc15a; --ink:#1c1305; /* متن روی نارنجی: ۵.۳–۷.۹:۱ */
  margin:0; min-height:100vh; min-height:100dvh;
  background:#12181b;
  background-image:radial-gradient(ellipse 80% 60% at 70% -10%,#3a484d66,transparent 60%),radial-gradient(ellipse 60% 50% at 0 100%,#ff7a3d14,transparent 60%),linear-gradient(180deg,#1a2226,#101518);
  color:var(--text); font-family:Vazirmatn,Tahoma,sans-serif; font-size:14px; line-height:1.8;
  -webkit-font-smoothing:antialiased; overflow-x:hidden;
}
.ea *,.ea *::before,.ea *::after{box-sizing:border-box}
.ea::before{content:"";position:fixed;inset:0;z-index:0;pointer-events:none;background:url('../img/eagle/command-background.webp') center/cover no-repeat;opacity:.08;filter:grayscale(1) blur(2px)}
.ea ::selection{background:#ff7a3d55}

.ea-page{position:relative;z-index:1;min-height:100vh;min-height:100dvh;display:grid;grid-template-rows:auto 1fr auto;padding:max(20px,env(safe-area-inset-top)) 24px max(18px,env(safe-area-inset-bottom))}
.ea-top,.ea-foot{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:6px 12px;font-size:12px;color:var(--muted-2)}
.ea-top .ea-ec{letter-spacing:.32em;font-weight:700;font-size:11px}
.ea-foot a{color:var(--muted);text-decoration:none;border-bottom:1px solid #ffffff2e;padding:6px 0}
.ea-foot a:hover,.ea-foot a:focus-visible{color:#fff;border-color:var(--accent);outline:none}
.ea-center{display:flex;flex-direction:column;align-items:center;justify-content:center;padding:28px 0;gap:22px}

/* نشان */
.ea-brand{display:flex;flex-direction:column;align-items:center;text-align:center;gap:6px}
.ea-mark{width:84px;height:70px;filter:drop-shadow(0 0 22px #ff7a3d40)}
.ea-brand h1{margin:6px 0 0;font-size:28px;line-height:1.4;font-weight:850;color:#fff}
.ea-brand p{margin:0;font-size:13px;color:var(--muted)}

/* بارگذاری */
.ea-splash .ea-mark{width:116px;height:96px}
.ea-splash .ea-brand h1{font-size:40px}
.ea-load{width:min(260px,72vw);display:flex;flex-direction:column;gap:10px;align-items:stretch;margin-top:6px}
.ea-track{height:3px;border-radius:3px;background:#ffffff14;overflow:hidden}
.ea-fill{height:100%;width:100%;background:linear-gradient(90deg,var(--accent-dark),var(--accent));transform-origin:right center;transform:scaleX(0);animation:ea-fill var(--ea-dur,1600ms) cubic-bezier(.4,0,.2,1) forwards}
.ea-load-row{display:flex;justify-content:space-between;align-items:center;font-size:11px;color:var(--muted-2)}
.ea-skip{color:var(--muted);text-decoration:none;border-bottom:1px solid #ffffff2e;padding:10px 0;margin:-8px 0}
.ea-skip:hover,.ea-skip:focus-visible{color:#fff;border-color:var(--accent)}
.ea-splash .ea-brand{animation:ea-rise .6s cubic-bezier(.2,.7,.2,1) both}
.ea-splash.leaving .ea-page{opacity:0;transition:opacity .22s ease}
@keyframes ea-fill{to{transform:scaleX(1)}}
@keyframes ea-rise{from{opacity:0;transform:translateY(8px) scale(.98)}to{opacity:1;transform:none}}

/* ورود */
.ea-card{width:min(100%,400px);padding:28px;border-radius:22px;background:linear-gradient(160deg,#2b3538cc,#1b2225d9);border:1px solid var(--line);box-shadow:0 30px 80px #000a,inset 0 1px #ffffff1a;-webkit-backdrop-filter:blur(18px);backdrop-filter:blur(18px);animation:ea-rise .35s ease both}
.ea-card h2{margin:0 0 4px;font-size:17px;font-weight:800;color:#fff}
.ea-card .ea-hint{margin:0 0 20px;font-size:12px;color:var(--muted)}
.ea-alert{display:flex;gap:8px;align-items:flex-start;margin:0 0 16px;padding:10px 12px;border-radius:12px;border:1px solid #ff6b7c55;background:var(--danger-bg);color:#ffd5da;font-size:12.5px;line-height:1.9}
.ea-alert.success{border-color:#4fe08a55;background:#4fe08a14;color:#c9f5da}
.ea-alert svg{flex:none;width:16px;height:16px;margin-top:3px}
.ea-field{display:flex;flex-direction:column;gap:6px;margin-bottom:14px}
.ea-field label{font-size:12px;font-weight:700;color:#d6dee1}
.ea-input{position:relative}
.ea-input input{width:100%;min-height:48px;margin:0;padding:10px 14px;border-radius:12px;border:1px solid var(--field-line);background:var(--field);color:var(--text);font:inherit;font-size:16px; /* زیر ۱۶px سافاری iOS هنگام فوکوس زوم می‌کند */transition:border-color .15s,box-shadow .15s}
.ea-input input::placeholder{color:#6d7b81}
.ea-input input:focus{outline:none;border-color:var(--accent);box-shadow:0 0 0 3px #ff7a3d40}
.ea-input input[aria-invalid=true]{border-color:var(--danger)}
.ea-input input.ea-ltr{direction:ltr;text-align:right}
.ea-input input.ea-ltr:placeholder-shown{direction:rtl}
.ea-input input[type=password],.ea-input input.ea-pw{padding-inline-end:48px;direction:ltr;text-align:right}
.ea-input input.ea-pw:placeholder-shown{direction:rtl}
.ea-eye{position:absolute;inset-inline-end:4px;top:50%;transform:translateY(-50%);width:44px;height:44px;display:grid;place-items:center;border:0;border-radius:10px;background:transparent;color:var(--muted);cursor:pointer}
.ea-eye:hover{color:#fff;background:#ffffff0d}
.ea-eye:focus-visible{outline:2px solid var(--accent);outline-offset:1px}
.ea-eye svg{width:20px;height:20px}
.ea-eye .ea-eye-off{display:none}
.ea-eye[aria-pressed=true] .ea-eye-on{display:none}
.ea-eye[aria-pressed=true] .ea-eye-off{display:block}
.ea-caps,.ea-err{margin:2px 0 0;font-size:12px;line-height:1.7}
.ea-caps{color:var(--warn)}
.ea-err{color:var(--danger)}
.ea-submit{position:relative;width:100%;min-height:48px;margin-top:6px;border:0;border-radius:12px;background:linear-gradient(180deg,#ff8a50,#ec5a1c);color:var(--ink);font:inherit;font-size:15px;font-weight:800;cursor:pointer;box-shadow:0 10px 24px -12px #ff7a3daa;transition:filter .15s,transform .1s}
.ea-submit:hover{filter:brightness(1.07)}
.ea-submit:active{transform:translateY(1px)}
.ea-submit:focus-visible{outline:2px solid #fff;outline-offset:3px}
.ea-help{margin:14px 0 0;font-size:12px;color:var(--muted);text-align:center}
.ea-help a{color:var(--accent-ink)}
.ea-submit[aria-busy=true]{cursor:progress;filter:saturate(.7) brightness(.9)}
.ea-submit .ea-spin{display:none;width:16px;height:16px;border-radius:50%;border:2px solid #1c130555;border-top-color:var(--ink);animation:ea-spin .7s linear infinite;vertical-align:-3px;margin-inline-end:8px}
.ea-submit[aria-busy=true] .ea-spin{display:inline-block}
@keyframes ea-spin{to{transform:rotate(360deg)}}

.ea-noscript{display:block;margin-top:8px;color:var(--accent-ink)}

@media (max-width:520px){
  .ea-page{padding-inline:16px}
  .ea-center{padding:18px 0;gap:18px}
  .ea-card{padding:22px 18px;border-radius:18px}
  .ea-splash .ea-brand h1{font-size:34px}
  .ea-brand h1{font-size:24px}
  .ea-mark{width:72px;height:60px}
}
@media (max-height:620px){.ea-login .ea-brand p{display:none}.ea-login .ea-mark{width:56px;height:46px}}
@media (prefers-reduced-transparency:reduce){.ea-card{-webkit-backdrop-filter:none;backdrop-filter:none;background:#273033}.ea::before{display:none}}
@supports not ((backdrop-filter:blur(1px)) or (-webkit-backdrop-filter:blur(1px))){.ea-card{background:#273033}}
@media (prefers-contrast:more){.ea{--muted:#d0d8db;--muted-2:#b6c1c5;--field-line:#a9b5ba;--line:#ffffff55}.ea-card{background:#1d2427}.ea::before{display:none}}
@media (forced-colors:active){.ea-mark path:first-child{fill:CanvasText}.ea-mark path:nth-child(3){fill:Canvas}.ea-submit,.ea-input input,.ea-card{border:1px solid CanvasText}.ea-fill{background:Highlight}}
@media (prefers-reduced-motion:reduce){.ea *{animation:none!important;transition:none!important}.ea-fill{transform:scaleX(1)}}

/* ---------- 39: staff / resident switch on the auth cards ---------- */
.ea-switch{display:grid;grid-template-columns:1fr 1fr;gap:4px;padding:4px;margin:0 0 18px;border-radius:12px;background:#ffffff0d;border:1px solid #ffffff1a}
.ea-switch a{display:flex;align-items:center;justify-content:center;min-height:42px;border-radius:9px;color:inherit;text-decoration:none;font-weight:700;font-size:14px;opacity:.8}
.ea-switch a[aria-current=page]{background:#ff7a3d;color:#1c1305;opacity:1}
.ea-switch a:not([aria-current]):hover{background:#ffffff12;opacity:1}
.ea-switch a:focus-visible{outline:2px solid #ffb48a;outline-offset:2px}
