@font-face {
  font-family: Dealer Arabic;
  src: url('/assets/arabic.ttf') format('truetype');
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: Dealer Arabic;
  src: url('/assets/arabic-bold.ttf') format('truetype');
  font-weight: 700;
  font-display: swap;
}
:root {
  color-scheme: light;
  --ink: #17362e;
  --forest: #163a31;
  --muted: #495b53;
  --line: #b7c3bc;
  --focus: #4d7628;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  place-items: center;
  padding: clamp(16px, 4vw, 48px);
  font: 1rem/1.55 system-ui, -apple-system, 'Segoe UI', sans-serif;
  color: var(--ink);
  background: #edf1ec;
}
html[dir='rtl'] body { font-family: 'Dealer Arabic', system-ui, sans-serif; }
.access-card {
  width: min(100%, 31rem);
  border: 1px solid #ced8d0;
  border-radius: 16px;
  background: white;
  box-shadow: 0 12px 34px #163a3112;
  overflow: hidden;
}
.identity {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 18px;
  padding: 18px clamp(20px, 5vw, 34px);
  background: var(--forest);
  color: #fff;
}
.identity img { display: block; width: clamp(116px, 33vw, 174px); height: auto; }
.language-field { display: grid; gap: 2px; }
.language-field label { font-size: .81rem; color: #e3ece4; }
.language-field select {
  min-width: 6.5rem;
  min-height: 40px;
  padding: 4px 8px;
  color: white;
  background: #24483f;
  border: 1px solid #849a90;
  border-radius: 6px;
}
.language-field option { color: #172d25; background: white; }
.panel { padding: clamp(24px, 5vw, 36px); }
h1 { margin: 0 0 1.15rem; font-size: clamp(1.55rem, 3.5vw, 1.95rem); line-height: 1.32; }
.intro { color: var(--muted); margin: -.45rem 0 1.4rem; }
form { display: grid; gap: 1rem; }
.field { display: grid; gap: .35rem; }
.field label { font-weight: 700; }
input, button, select { font: inherit; }
input {
  width: 100%;
  min-width: 0;
  min-height: 46px;
  padding: .55rem .7rem;
  background: #fff;
  color: #172d25;
  border: 1px solid var(--line);
  border-radius: 7px;
}
:where(input, button, select, a):focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.identity select:focus-visible { outline-color: #d7edb6; }
input[aria-invalid='true'] { border-color: #a12b28; }
.password-row { display: flex; gap: .5rem; align-items: stretch; }
.toggle { border: 1px solid var(--line); border-radius: 7px; background: #f5f7f4; color: var(--forest); padding: .4rem .75rem; cursor: pointer; }
.field small { color: var(--muted); }
.submit { margin-top: .3rem; min-height: 48px; padding: .65rem 1rem; border: 0; border-radius: 7px; color: white; background: var(--forest); font-weight: 700; cursor: pointer; }
.submit:hover:not(:disabled) { background: #244f41; }
.submit:disabled { opacity: .67; cursor: default; }
.form-error { padding: .7rem .8rem; margin: 0 0 1rem; border-inline-start: 3px solid #a12b28; border-radius: 3px; color: #7d221c; background: #fff3f0; }
.login-link { margin-top: .8rem; min-height: 42px; display: inline-flex; align-items: center; color: #245842; text-underline-offset: .18em; }
@media (max-width: 320px) {
  .identity { padding: 14px 16px; }
  .panel { padding: 20px 15px; }
}
