:root {
  --cream: #F7E9DC;
  --caramel: #C98B6B;
  --blue: #2F5D8C;
  --blue-dark: #234769;
  --ink: #2B2420;
  --muted: #5E5048;
  --white: #FFFFFF;
  --radius: 14px;
  --serif: Georgia, "Times New Roman", "Noto Naskh Arabic", serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans Arabic", Tahoma, Arial, sans-serif;
}

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

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

body {
  margin: 0;
  font-family: var(--sans);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--cream);
  overflow-x: hidden;
  overflow-wrap: anywhere;
}

img, svg, video, iframe { max-width: 100%; height: auto; }

h1, h2, h3 {
  font-family: var(--serif);
  line-height: 1.25;
  color: var(--blue-dark);
  margin: 0 0 .6em;
}
h1 { font-size: clamp(1.8rem, 7vw, 3rem); }
h2 { font-size: clamp(1.5rem, 5.5vw, 2.2rem); }
h3 { font-size: 1.2rem; }

p { margin: 0 0 1em; }

a { color: var(--blue); }
a:focus-visible, button:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 2px;
}

.skip-link {
  position: absolute;
  inset-inline-start: 8px;
  top: -60px;
  background: var(--blue);
  color: var(--white);
  padding: 8px 12px;
  border-radius: 8px;
  z-index: 100;
}
.skip-link:focus { top: 8px; }

.container {
  width: 100%;
  max-width: 960px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Header & navigation */
.site-header {
  position: relative;
  z-index: 10;
  background: rgba(247, 233, 220, .97);
  border-bottom: 1px solid rgba(201, 139, 107, .45);
}
.header-inner {
  max-width: 960px;
  margin: 0 auto;
  padding: 10px 12px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.brand {
  margin: 0;
  font-family: var(--serif);
  font-size: 1.05rem;
  font-weight: 700;
  text-align: center;
  max-width: 100%;
}
.brand a { color: var(--blue-dark); text-decoration: none; }

.lang-switch {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px;
  max-width: 100%;
}
.lang-switch button {
  font: inherit;
  font-size: .85rem;
  padding: 4px 10px;
  min-height: 32px;
  border: 1px solid var(--blue);
  border-radius: 999px;
  background: transparent;
  color: var(--blue);
  cursor: pointer;
}
.lang-switch button[aria-pressed="true"] {
  background: var(--blue);
  color: var(--white);
}

.main-nav { width: 100%; max-width: 100%; }
.main-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2px 6px;
}
.main-nav a {
  display: inline-block;
  padding: 6px 8px;
  font-size: .88rem;
  color: var(--ink);
  text-decoration: none;
  border-radius: 8px;
  white-space: nowrap;
}
.main-nav a:hover, .main-nav a:focus-visible {
  background: rgba(201, 139, 107, .25);
  color: var(--blue-dark);
}

/* Sections */
.hero {
  padding: 56px 0 48px;
  text-align: center;
  background:
    radial-gradient(circle at 20% 0%, rgba(201, 139, 107, .28), transparent 60%),
    radial-gradient(circle at 90% 100%, rgba(47, 93, 140, .14), transparent 55%);
}
.slogan {
  font-size: 1.15rem;
  color: var(--muted);
  max-width: 36ch;
  margin-inline: auto;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: 24px;
}

.section { padding: 48px 0; }
.section-alt { background: rgba(255, 255, 255, .55); }

.btn {
  display: inline-block;
  font: inherit;
  font-weight: 600;
  padding: 12px 20px;
  border-radius: 999px;
  text-decoration: none;
  border: 2px solid var(--blue);
  max-width: 100%;
  cursor: pointer;
}
.btn-primary { background: var(--blue); color: var(--white); }
.btn-primary:hover { background: var(--blue-dark); }
.btn-ghost { background: transparent; color: var(--blue-dark); }
.btn[disabled] {
  cursor: not-allowed;
  background: #8A8F96;
  border-color: #8A8F96;
  color: var(--white);
}

.card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 20px;
  border-top: 4px solid var(--caramel);
  box-shadow: 0 4px 14px rgba(43, 36, 32, .06);
  max-width: 100%;
}
.card p:last-child { margin-bottom: 0; }
.placeholder { text-align: center; }

.muted { color: var(--muted); }
.nowrap { white-space: nowrap; unicode-bidi: isolate; }

.features {
  list-style: none;
  padding: 0;
  margin: 0 0 24px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.features li {
  background: var(--white);
  border: 1px solid rgba(201, 139, 107, .6);
  border-radius: 999px;
  padding: 6px 14px;
  font-size: .92rem;
}

.grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

.site-footer {
  text-align: center;
  padding: 20px 12px;
  font-size: .8rem;
  color: var(--muted);
}
.site-footer p { margin: 0; }
.site-footer a { color: var(--blue); }

/* RTL */
[dir="rtl"] body, html[dir="rtl"] { font-family: var(--sans); }
html[dir="rtl"] h1, html[dir="rtl"] h2, html[dir="rtl"] h3, html[dir="rtl"] .brand {
  font-family: "Noto Naskh Arabic", "Amiri", var(--serif);
}

@media (min-width: 720px) {
  .site-header { position: sticky; top: 0; }
  section[id] { scroll-margin-top: 130px; }
  .header-inner { justify-content: space-between; }
  .main-nav a { font-size: .95rem; }
  .grid { grid-template-columns: repeat(3, 1fr); }
  .hero { padding: 96px 0 80px; }
  .section { padding: 72px 0; }
}

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