/* Element defaults shared by every page. Tokens come from app-theme.css. */
* { box-sizing: border-box; }

html, body { margin: 0; padding: 0; }

html { overflow-y: scroll; }

body {
  font-family: "Plus Jakarta Sans", "Cairo", "Helvetica Neue", sans-serif;
  background: var(--bg); color: var(--ink); line-height: var(--lh-body);
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}

button, input, select, textarea {
  font-family: inherit;
  line-height: var(--lh-compact);
}

a { color: var(--brand); text-decoration: none; }

a:hover { color: var(--brand-strong); text-decoration: underline; }

h1[tabindex="-1"]:focus { outline: none; }

:where(:focus-visible) {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}

::-webkit-scrollbar { width: 10px; height: 10px; }

::-webkit-scrollbar-thumb { background: var(--line); border-radius: 8px; border: 2px solid transparent; background-clip: padding-box; }

/* Native date/time inputs read right-to-left, with the picker icon on the start side. */
[dir="rtl"] input[type="date"], [dir="rtl"] input[type="time"], [dir="rtl"] input[type="datetime-local"] {
  direction: rtl;
  text-align: right;
}

[dir="rtl"] input[type="date"]::-webkit-datetime-edit, [dir="rtl"] input[type="time"]::-webkit-datetime-edit, [dir="rtl"] input[type="datetime-local"]::-webkit-datetime-edit, [dir="rtl"] input[type="date"]::-webkit-datetime-edit-fields-wrapper, [dir="rtl"] input[type="time"]::-webkit-datetime-edit-fields-wrapper, [dir="rtl"] input[type="datetime-local"]::-webkit-datetime-edit-fields-wrapper {
  direction: rtl;
  text-align: right;
}

[dir="rtl"] input[type="date"]::-webkit-calendar-picker-indicator, [dir="rtl"] input[type="time"]::-webkit-calendar-picker-indicator, [dir="rtl"] input[type="datetime-local"]::-webkit-calendar-picker-indicator {
  order: -1;
  margin-inline: 0 0.35rem;
}

@keyframes app-pop { from { opacity: 0; transform: scale(0.96) translateY(6px); } to { opacity: 1; transform: scale(1) translateY(0); } }

@keyframes ish-spin { to { transform: rotate(360deg); } }

@media (max-width: 720px) {
  html { overflow-y: auto; }
}
