:root {
  --navy: #2a3841;
  --navy-2: #344750;
  --gold: #d0ac6e;
  --gold-soft: #f5efe5;
  --ink: #213139;
  --muted: #7b898f;
  --line: #e1e7e9;
  --red: #c35656;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: "Tajawal", sans-serif;
  color: var(--ink);
  background: #eef2f3;
}

.login-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(390px, 46%) 1fr;
}

.login-brand {
  background: linear-gradient(145deg, rgba(42, 56, 65, .97), rgba(36, 52, 61, .99)), url("assets/zad-logo.jpg") center/cover;
  color: #fff;
  padding: 54px 72px;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
}

.login-brand::before {
  content: "Z";
  position: absolute;
  font-size: 540px;
  font-weight: 800;
  color: rgba(208, 172, 110, .035);
  line-height: .8;
  left: -55px;
  bottom: -120px;
}

.login-brand > img {
  width: 250px;
  height: 94px;
  object-fit: cover;
  position: relative;
  z-index: 1;
}

.brand-message {
  margin: auto 0;
  position: relative;
  z-index: 1;
}

.brand-message > span {
  color: var(--gold);
  font-size: 12px;
  letter-spacing: 2px;
  font-weight: 800;
}

.brand-message h1 {
  font-size: 46px;
  line-height: 1.35;
  margin: 12px 0;
}

.brand-message p {
  color: #bdc8cc;
  font-size: 16px;
  max-width: 430px;
  line-height: 1.8;
}

.brand-schedule {
  display: flex;
  align-items: center;
  border: 1px solid rgba(255, 255, 255, .11);
  background: rgba(255, 255, 255, .05);
  border-radius: 14px;
  padding: 14px 16px;
  position: relative;
  z-index: 1;
}

.brand-schedule i {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: rgba(208, 172, 110, .13);
  color: var(--gold);
  display: grid;
  place-items: center;
  font-style: normal;
  margin-left: 11px;
}

.brand-schedule strong,
.brand-schedule span { display: block; }
.brand-schedule strong { font-size: 13px; }
.brand-schedule span { font-size: 11px; color: #bac7cc; margin-top: 3px; }

.login-panel {
  display: grid;
  place-items: center;
  padding: 48px;
  background: #f7f9f9;
}

.login-card {
  width: min(100%, 590px);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 26px;
  padding: 76px 52px 42px;
  box-shadow: 0 24px 70px rgba(42, 56, 65, .11);
  position: relative;
}

.login-mobile-logo { display: none; }
.login-eyebrow { font-size: 12px; color: #9b753b; font-weight: 700; }
.login-card h2 { font-size: 34px; margin: 7px 0; }
.login-subtitle { margin: 0 0 26px; color: var(--muted); font-size: 14px; line-height: 1.6; }

.portal-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  background: #f3f6f6;
  border-radius: 15px;
  padding: 6px;
  margin-bottom: 26px;
}

.portal-tabs button {
  border: 0;
  background: transparent;
  border-radius: 10px;
  padding: 14px 12px;
  font-family: inherit;
  color: var(--muted);
  cursor: pointer;
}

.portal-tabs i,
.portal-tabs span { display: block; font-style: normal; }
.portal-tabs i { font-size: 21px; }
.portal-tabs span { font-size: 12px; margin-top: 4px; }
.portal-tabs button.active { background: var(--navy); color: #fff; box-shadow: 0 6px 14px rgba(42, 56, 65, .15); }

.login-card form > label {
  display: block;
  font-size: 13px;
  font-weight: 700;
  margin-top: 18px;
}

.login-card input {
  width: 100%;
  display: block;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 12px;
  padding: 15px 16px;
  margin-top: 8px;
  min-height: 52px;
  font: 500 15px "Tajawal";
  outline: none;
}

.login-card input:focus { border-color: var(--gold); box-shadow: 0 0 0 3px var(--gold-soft); }
.password-field { position: relative; }
.password-field input { padding-left: 52px; }
.password-field button {
  position: absolute;
  left: 9px;
  top: 16px;
  border: 0;
  background: transparent;
  color: var(--muted);
  width: 34px;
  height: 34px;
  cursor: pointer;
}

.login-options { display: flex; align-items: center; margin: 16px 0; }
.secure-note { font-size: 11px; color: var(--muted); }
.login-options button { margin-right: auto; border: 0; background: none; color: #966f33; font: 600 11px "Tajawal"; cursor: pointer; }

.login-submit {
  width: 100%;
  border: 0;
  background: var(--gold);
  color: var(--navy);
  border-radius: 12px;
  min-height: 52px;
  padding: 15px 18px;
  font: 800 14px "Tajawal";
  cursor: pointer;
  display: flex;
  justify-content: center;
  gap: 8px;
}

.login-submit:disabled { opacity: .62; cursor: wait; }
.first-login-note { margin-top: 17px; padding: 14px 15px; border: 1px solid #eadbc0; background: var(--gold-soft); border-radius: 11px; color: #765a2d; font-size: 11.5px; line-height: 1.7; }
.change-icon { width: 58px; height: 58px; border-radius: 17px; background: var(--navy); color: var(--gold); display: grid; place-items: center; font-size: 25px; font-weight: 800; margin-bottom: 17px; }
.password-policy { font-size: 11px; color: var(--muted); line-height: 1.7; margin: 12px 0 16px; }
.logout-link { display: block; margin: 14px auto 0; border: 0; background: transparent; color: var(--muted); font: 600 11px "Tajawal"; cursor: pointer; }

.login-alert { display: none; background: #fbecec; color: var(--red); border-radius: 10px; padding: 13px; margin-top: 14px; font-size: 12px; }
.login-alert.show { display: block; }
.login-alert[data-kind="info"] { background: #eef4f6; color: #49616b; }
.login-alert[data-kind="success"] { background: #e9f5f0; color: #2f7f63; }

.login-card footer { text-align: center; color: #a0aaae; font-size: 9px; margin-top: 25px; padding-top: 17px; border-top: 1px solid var(--line); }
.login-card > .login-language-switcher { position: absolute; top: 24px; inset-inline-end: 28px; z-index: 2; }
html[dir="ltr"] .login-submit [aria-hidden="true"] { transform: rotate(180deg); }
.login-card [hidden] { display: none !important; }

@media (max-width: 850px) {
  .login-shell { grid-template-columns: 1fr; }
  .login-brand { display: none; }
  .login-panel { padding: 20px; }
  .login-card { padding: 72px 28px 30px; }
  .login-mobile-logo { display: block; background: var(--navy); border-radius: 14px; padding: 8px; margin-bottom: 24px; text-align: center; }
  .login-mobile-logo img { width: 170px; height: 58px; object-fit: cover; }
  .login-card h2 { font-size: 29px; }
  .login-card > .login-language-switcher { top: 21px; inset-inline-end: 24px; }
}

@media (max-height: 780px) and (min-width: 851px) {
  .login-card { padding-top: 64px; padding-bottom: 30px; }
  .login-card h2 { font-size: 30px; }
  .login-card form > label { margin-top: 13px; }
  .portal-tabs { margin-bottom: 18px; }
  .first-login-note { margin-top: 12px; }
  .login-card footer { margin-top: 16px; }
}
