*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  height: 100%;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  height: 100%;
  margin: 0;
  overflow: hidden;
  overscroll-behavior: none;
  font-family: var(--font-sans);
  font-size: var(--fs-md);
  line-height: 1.5;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  transition:
    background-color var(--duration) var(--ease),
    color var(--duration) var(--ease);
}

h1,
h2,
h3,
h4,
p,
figure,
dl,
dd,
ul,
ol {
  margin: 0;
}

ul,
ol {
  padding: 0;
  list-style: none;
}

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

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

button {
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
  touch-action: manipulation;
}

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

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

[hidden] {
  display: none !important; /* atribut hidden harus menang atas display milik komponen */
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* Setiap tulisan "jejak imani" memakai Martel (aturan brand); sisanya Mulish. */
.brand {
  font-family: var(--font-brand);
  font-weight: 800;
  letter-spacing: -0.01em;
  white-space: nowrap;
}

.icon {
  flex: none;
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentcolor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.icon--sm {
  width: 18px;
  height: 18px;
}

.icon--xs {
  width: 14px;
  height: 14px;
}

.icon--lg {
  width: 28px;
  height: 28px;
}

.icon--xl {
  width: 40px;
  height: 40px;
  stroke-width: 1.4;
}

.arabic {
  font-family: var(--font-arabic);
  font-size: 26px;
  line-height: 2;
  direction: rtl;
  text-align: right;
}

.num {
  font-variant-numeric: tabular-nums;
}

/* !important disengaja: preferensi reduced motion harus mengalahkan semua animasi komponen. */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    transition-duration: 1ms !important;
  }
}
