:root {
  color-scheme: light;
  --brand: #078f91;
  --brand-deep: #056d70;
  --brand-soft: #e5f8f6;
  --ink: #172b39;
  --muted: #697b86;
  --line: #e5ebee;
  --canvas: #f5f8f9;
  --surface: #ffffff;
  --success: #187b57;
  --danger: #b83b49;
  --warning: #98600c;
  --radius-sm: 12px;
  --radius-md: 18px;
  --radius-lg: 24px;
  --shadow-card: 0 8px 26px rgba(19, 52, 64, .07);
  --shadow-soft: 0 3px 12px rgba(19, 52, 64, .06);
  --content-width: 1040px;
  font-family: "Tajawal", "Noto Sans Arabic", "Segoe UI", Tahoma, sans-serif;
  font-synthesis: none;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 90px; background: var(--canvas); }
body { margin: 0; min-width: 320px; color: var(--ink); background: var(--canvas); font-size: 15px; line-height: 1.7; -webkit-font-smoothing: antialiased; }
button, input, select, textarea { font: inherit; }
button, a, input, select, textarea { -webkit-tap-highlight-color: transparent; }
button, select { cursor: pointer; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
h1, h2, h3, p { margin-top: 0; }
h1, h2, h3 { line-height: 1.35; letter-spacing: -.025em; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid rgba(7, 143, 145, .32); outline-offset: 3px; }
.skip-link { position: absolute; z-index: 100; top: -80px; right: 16px; padding: 8px 14px; background: white; border-radius: 10px; }
.skip-link:focus { top: 10px; }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.app-header { position: sticky; z-index: 30; top: 0; display: grid; grid-template-columns: 48px 1fr 48px; align-items: center; min-height: 70px; max-width: var(--content-width); margin: 0 auto; padding: 8px 18px; background: rgba(245,248,249,.92); backdrop-filter: blur(14px); }
.icon-button { display: inline-grid; place-items: center; width: 42px; height: 42px; border: 1px solid transparent; border-radius: 14px; background: transparent; color: var(--ink); font-size: 24px; line-height: 1; }
.icon-button:hover { background: var(--brand-soft); }
.brand { display: inline-flex; gap: 9px; justify-self: center; align-items: center; }
.brand-mark { display: grid; flex: 0 0 42px; place-items: center; width: 42px; height: 42px; border-radius: 15px 15px 15px 7px; color: white; background: linear-gradient(145deg, #0cb0ae, #08757f); box-shadow: 0 6px 14px rgba(7,143,145,.2); font-size: 26px; font-weight: 900; }
.brand-copy { display: grid; gap: 0; text-align: right; line-height: 1.2; }
.brand-copy strong { font-size: 18px; font-weight: 900; }
.brand-copy small { margin-top: 4px; font-size: 10px; color: var(--muted); font-weight: 600; }
.page-shell { max-width: var(--content-width); min-height: calc(100vh - 140px); margin: 0 auto; padding: 0 18px 92px; }
.button { display: inline-flex; justify-content: center; align-items: center; gap: 10px; min-height: 46px; padding: 10px 18px; border: 1px solid transparent; border-radius: 14px; font-weight: 800; line-height: 1.3; transition: transform .16s ease, background .16s ease, box-shadow .16s ease; }
.button:hover { transform: translateY(-1px); }
.button-primary { color: #fff; background: var(--brand); box-shadow: 0 6px 14px rgba(7,143,145,.16); }
.button-primary:hover { background: var(--brand-deep); }
.button-light { color: var(--brand-deep); background: #fff; box-shadow: 0 5px 14px rgba(0,0,0,.08); }
.button-small { min-height: 38px; padding: 8px 13px; border-radius: 11px; font-size: 13px; white-space: nowrap; }
.button-wide { width: 100%; }
.text-button { color: var(--muted); font-size: 13px; font-weight: 700; }
.muted-copy, .section-subtitle { color: var(--muted); }
.eyebrow { margin: 0 0 5px; color: var(--brand); font-size: 12px; font-weight: 900; letter-spacing: .02em; }
.flash-stack { display: grid; gap: 8px; margin: 8px 0 16px; }
.flash { padding: 11px 14px; border: 1px solid var(--line); border-radius: 13px; background: white; font-size: 13px; }
.flash-success { color: var(--success); border-color: #bdebd9; background: #f0fcf7; }
.flash-error { color: var(--danger); border-color: #f3c8cd; background: #fff4f5; }
.flash-info { color: var(--brand-deep); border-color: #c8eeee; background: #f0fbfb; }
.bottom-nav { position: fixed; z-index: 25; right: 0; bottom: 0; left: 0; display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); padding: 8px max(10px, env(safe-area-inset-right)) calc(7px + env(safe-area-inset-bottom)) max(10px, env(safe-area-inset-left)); border-top: 1px solid rgba(222,232,234,.9); background: rgba(255,255,255,.96); backdrop-filter: blur(18px); box-shadow: 0 -6px 22px rgba(22,52,64,.04); }
.bottom-nav-item { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; min-height: 48px; color: #70818b; }
.bottom-nav-item span { font-size: 23px; line-height: 1.15; font-weight: 700; }
.bottom-nav-item small { font-size: 10px; font-weight: 700; }
.bottom-nav-item.is-active { color: var(--brand); }
.bottom-nav-primary span { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 10px; color: white; background: var(--brand); font-size: 22px; }
.drawer-scrim { position: fixed; z-index: 39; inset: 0; display: none; background: rgba(8, 26, 36, .35); }
.app-drawer { position: fixed; z-index: 40; top: 0; right: 0; bottom: 0; width: min(330px, 88vw); padding: 22px 18px; background: white; box-shadow: -14px 0 45px rgba(18,47,57,.13); transform: translateX(110%); visibility: hidden; transition: transform .22s ease, visibility .22s ease; }
.drawer-open .app-drawer { visibility: visible; transform: translateX(0); }
.drawer-open .drawer-scrim { display: block; }
.drawer-heading { display: flex; align-items: center; gap: 10px; padding-bottom: 20px; border-bottom: 1px solid var(--line); }
.drawer-heading > div { display: grid; flex: 1; }
.drawer-heading small { color: var(--muted); font-size: 12px; }
.drawer-links { display: grid; gap: 6px; padding: 18px 0; }
.drawer-links a, .drawer-logout button { display: flex; align-items: center; gap: 12px; width: 100%; padding: 12px; border: 0; border-radius: 12px; background: transparent; text-align: right; color: var(--ink); font-weight: 700; }
.drawer-links a:hover, .drawer-logout button:hover { background: var(--brand-soft); color: var(--brand-deep); }
.drawer-links a:first-child { background: var(--brand-soft); color: var(--brand-deep); }
.drawer-logout { margin: 0; }
.drawer-note { padding: 14px; border-radius: 14px; color: var(--muted); background: var(--canvas); font-size: 12px; }
.toast-region { position: fixed; z-index: 60; right: 16px; bottom: calc(82px + env(safe-area-inset-bottom)); left: 16px; display: grid; justify-items: center; pointer-events: none; }
.toast { max-width: 440px; padding: 10px 16px; color: white; border-radius: 12px; background: #203946; box-shadow: var(--shadow-card); font-size: 13px; }
@media (min-width: 760px) {
  .app-header { min-height: 82px; padding-inline: 24px; }
  .brand { justify-self: start; }
  .page-shell { padding: 8px 24px 60px; }
  .bottom-nav { display: none; }
  .page-shell { min-height: calc(100vh - 90px); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
}
