/* ===========================================================
   دفتر الأمانة - الأنماط الأساسية
   =========================================================== */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  background-color: var(--color-paper);
  color: var(--color-ink);
  line-height: 1.6;
  direction: rtl;
  min-height: 100vh;
  /* نسيج ورقي خفيف جداً */
  background-image:
    repeating-linear-gradient(
      0deg,
      transparent,
      transparent 31px,
      var(--color-line-soft) 31px,
      var(--color-line-soft) 32px
    );
  background-attachment: local;
}

img { max-width: 100%; display: block; }

a { color: inherit; text-decoration: none; }

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

input, select, textarea {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}

ul { list-style: none; }

/* تركيز واضح بلوحة المفاتيح - إتاحة */
:focus-visible {
  outline: 2px solid var(--color-brass);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

/* تقليل الحركة لمن يفضل ذلك */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* الأرقام دايمًا بنفس العرض عشان تتساوى بصريًا في الجداول */
.figure,
.amount {
  font-feature-settings: "tnum" 1;
  font-variant-numeric: tabular-nums;
  font-family: var(--font-numeric);
  direction: ltr;
  unicode-bidi: plaintext;
}

.container {
  width: 100%;
  max-width: 880px;
  margin: 0 auto;
  padding: 0 var(--space-5);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
}
