/* Base: tokens, reset, shared primitives (brand: flat, white, black, one red accent) */
:root {
  --white: #ffffff;
  --black: #000000;
  --red: #c8102e;
  --red-dark: #a30d25;
  --gray-line: #e5e5e5;
  --font-display: "Montserrat", system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans Arabic", Arial, sans-serif;
  --font-body: "Montserrat", system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans Arabic", Arial, sans-serif;
  --radius-lg: 2rem;
  --radius-pill: 999px;
  --gutter: clamp(1rem, 4vw, 2rem);
  --max-width: 72rem;
  --dir: 1; /* flips to -1 in RTL for directional motion */
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--white);
  color: var(--black);
  font-family: var(--font-body);
  line-height: 1.5;
}

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

a {
  color: inherit;
}

:focus-visible {
  outline: 3px solid var(--red);
  outline-offset: 3px;
}

.container {
  width: 100%;
  max-width: var(--max-width);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.btn {
  display: inline-block;
  padding: 0.85rem 2rem;
  border: 2px solid var(--black);
  border-radius: var(--radius-pill);
  background: var(--black);
  color: var(--white);
  font: 600 1rem/1.2 var(--font-body);
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.2s, color 0.2s, border-color 0.2s;
}

.btn:hover {
  background: var(--white);
  color: var(--black);
}

.btn--outline {
  background: var(--white);
  color: var(--black);
}

.btn--outline:hover {
  background: var(--black);
  color: var(--white);
}

.btn--sm {
  padding: 0.5rem 1.25rem;
  font-size: 0.9rem;
}

[hidden] {
  display: none !important;
}

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

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  * {
    transition: none !important;
    animation: none !important;
  }
}

/* ---------- Accessibility: skip link, shown when it gets keyboard focus ---------- */
.skip-link {
  position: absolute;
  z-index: 5000;
  inset-block-start: -5rem;
  inset-inline-start: 0.75rem;
  padding: 0.6rem 1.2rem;
  border: 2px solid var(--black);
  border-radius: var(--radius-pill);
  background: var(--white);
  color: var(--black);
  font: 700 0.95rem/1.2 var(--font-body);
  text-decoration: none;
}

.skip-link:focus,
.skip-link:focus-visible {
  inset-block-start: 0.75rem;
}

/* the page content takes focus after the skip link, without a ring around the whole page */
main:focus {
  outline: none;
}
