/* =========================================================
   أمد للتمويل — تصميم فاخر مطابق للموك أب
   Dark Navy + Gold Luxury FinTech
   ========================================================= */

/* ---------------------------------------------------------
   1) Variables
   --------------------------------------------------------- */
:root,
html[data-theme="dark"] {
  --bg: #070b18;
  --bg-2: #0b1224;
  --panel: #10182c;
  --panel-2: #141e35;
  --card: rgba(255, 255, 255, 0.04);
  --gold: #d6b37a;
  --gold-2: #e7c896;
  --gold-deep: #b8924f;
  --purple: #7c5cff;
  --purple-soft: rgba(124, 92, 255, 0.28);
  --heading: #d6b37a;
  --cta-bg: linear-gradient(135deg, #f0d7a8, #d6b37a 45%, #b8924f);
  --cta-color: #1a1408;
  --cta-shadow: 0 12px 30px rgba(214, 179, 122, 0.28);
  --white: #ffffff;
  --text: #f4f6fb;
  --muted: #b7beca;
  --border: rgba(214, 179, 122, 0.22);
  --border-soft: rgba(255, 255, 255, 0.08);
  --shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
  --nav-bg: rgba(7, 11, 24, 0.78);
  --input-bg: rgba(0, 0, 0, 0.25);
  --surface: rgba(255, 255, 255, 0.03);
  --bg-image:
    radial-gradient(900px 500px at 85% 0%, rgba(124, 92, 255, 0.16), transparent 55%),
    radial-gradient(700px 420px at 10% 20%, rgba(214, 179, 122, 0.08), transparent 50%),
    linear-gradient(180deg, #070b18 0%, #090f1f 40%, #070b18 100%);
  --radius: 18px;
  --radius-lg: 28px;
  --container: 1180px;
  --nav-h: 84px;
  --font: "Cairo", "Segoe UI", Tahoma, sans-serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --focus: 0 0 0 3px rgba(214, 179, 122, 0.35);
}

html[data-theme="light"] {
  --bg: #f7f8fc;
  --bg-2: #ffffff;
  --panel: #ffffff;
  --panel-2: #f3f5fb;
  --card: #ffffff;
  --gold: #c5a059;
  --gold-2: #d6b37a;
  --gold-deep: #a8843f;
  --purple: #4b3fe4;
  --purple-soft: rgba(75, 63, 228, 0.12);
  --heading: #3b44d1;
  --cta-bg: linear-gradient(135deg, #2a2a9a, #1a1a80 50%, #14146a);
  --cta-color: #ffffff;
  --cta-shadow: 0 14px 30px rgba(26, 26, 128, 0.25);
  --white: #ffffff;
  --text: #1a1a4a;
  --muted: #6b728a;
  --border: rgba(59, 68, 209, 0.14);
  --border-soft: rgba(26, 26, 80, 0.08);
  --shadow: 0 18px 50px rgba(26, 32, 80, 0.1);
  --nav-bg: rgba(255, 255, 255, 0.86);
  --input-bg: #f4f6fb;
  --surface: #ffffff;
  --bg-image:
    radial-gradient(800px 420px at 90% 0%, rgba(75, 63, 228, 0.08), transparent 55%),
    radial-gradient(700px 380px at 0% 20%, rgba(197, 160, 89, 0.08), transparent 50%),
    linear-gradient(180deg, #f7f8fc 0%, #ffffff 45%, #f4f6fb 100%);
  --focus: 0 0 0 3px rgba(59, 68, 209, 0.28);
}

/* ---------------------------------------------------------
   2) Reset & Base
   --------------------------------------------------------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + 12px);
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background: var(--bg-image);
  line-height: 1.8;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  transition: background 0.35s var(--ease), color 0.25s var(--ease);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
  transition: 0.25s var(--ease);
}

button,
input,
textarea {
  font: inherit;
  color: inherit;
}

ul,
ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

h1,
h2,
h3 {
  margin: 0;
  line-height: 1.35;
  font-weight: 800;
}

p {
  margin: 0;
  color: var(--muted);
}

:focus-visible {
  outline: none;
  box-shadow: var(--focus);
  border-radius: 10px;
}

.skip-link {
  position: absolute;
  top: -120px;
  right: 16px;
  z-index: 9999;
  background: var(--gold);
  color: #1a1408;
  padding: 0.75rem 1rem;
  border-radius: 10px;
  font-weight: 700;
}

.skip-link:focus {
  top: 14px;
}

/* ---------------------------------------------------------
   3) Layout helpers
   --------------------------------------------------------- */
.container {
  width: min(100% - 2.5rem, var(--container));
  margin-inline: auto;
}

.section {
  padding: clamp(4rem, 8vw, 6.5rem) 0;
}

.section__header {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 2.8rem;
}

.section__header h1,
.section__header h2 {
  font-size: clamp(1.9rem, 3.5vw, 2.7rem);
  color: var(--heading);
  margin-bottom: 0.75rem;
}

.page-main {
  min-height: calc(100vh - var(--nav-h) - 220px);
}

.page-block {
  padding: clamp(3rem, 6vw, 5rem) 0;
}

.navbar__links a.is-active {
  color: var(--heading);
  background: var(--purple-soft);
}

.section__header p {
  font-size: 1.05rem;
}

.card {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.02));
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
}

/* ---------------------------------------------------------
   4) Buttons
   --------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  min-height: 48px;
  padding: 0.8rem 1.35rem;
  border-radius: 999px;
  border: 1px solid transparent;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), background 0.25s var(--ease),
    border-color 0.25s var(--ease);
}

.btn--sm {
  min-height: 42px;
  padding: 0.55rem 1.1rem;
  font-size: 0.92rem;
}

.btn--lg {
  min-height: 56px;
  padding: 0.95rem 1.8rem;
  font-size: 1.05rem;
}

.btn--gold {
  background: var(--cta-bg);
  color: var(--cta-color);
  box-shadow: var(--cta-shadow);
}

.btn--gold:hover {
  transform: translateY(-2px);
  filter: brightness(1.05);
}

.btn--ghost {
  background: transparent;
  border-color: var(--border-soft);
  color: var(--text);
}

.btn--ghost:hover {
  border-color: var(--heading);
  color: var(--heading);
}

.btn--block {
  width: 100%;
}

/* ---------------------------------------------------------
   5) Navbar
   --------------------------------------------------------- */
.navbar {
  position: sticky;
  top: 0;
  z-index: 1000;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  background: var(--nav-bg);
  border-bottom: 1px solid var(--border-soft);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  overflow: visible;
}

/* Theme toggle */
.theme-toggle {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  border: 1px solid var(--border-soft);
  background: var(--surface);
  color: var(--heading);
  display: inline-grid;
  place-items: center;
  cursor: pointer;
  position: relative;
  transition: transform 0.25s var(--ease), border-color 0.25s var(--ease), background 0.25s var(--ease);
}

.theme-toggle:hover {
  transform: translateY(-1px);
  border-color: var(--border);
}

.theme-toggle__icon {
  display: none;
  line-height: 0;
}

html[data-theme="dark"] .theme-toggle__icon--sun,
html[data-theme="light"] .theme-toggle__icon--moon {
  display: inline-flex;
}

.navbar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  width: min(100% - 2.5rem, var(--container));
}

.navbar__brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
}

.navbar__brand img {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  object-fit: cover;
}

.navbar__brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.navbar__brand-text strong {
  font-size: 1.05rem;
}

.navbar__brand-text small {
  color: var(--muted);
  font-size: 0.78rem;
}

.navbar__toggle {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.navbar__burger {
  display: none;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  border: 1px solid var(--border-soft);
  background: rgba(255, 255, 255, 0.03);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  cursor: pointer;
}

.navbar__burger span {
  width: 18px;
  height: 2px;
  background: var(--white);
  border-radius: 2px;
}

.navbar__nav {
  display: flex;
  align-items: center;
  gap: 1.2rem;
}

.navbar__links {
  display: flex;
  align-items: center;
  gap: 0.2rem;
}

.navbar__links a {
  padding: 0.5rem 0.8rem;
  border-radius: 999px;
  color: var(--muted);
  font-weight: 600;
  font-size: 0.95rem;
}

.navbar__links a:hover {
  color: var(--heading);
  background: var(--purple-soft);
}

.navbar__actions {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  overflow: visible;
}

.navbar__inner,
.navbar__nav {
  overflow: visible;
}

/* ---------------------------------------------------------
   6) Hero
   --------------------------------------------------------- */
.hero {
  position: relative;
  padding: clamp(2.5rem, 6vw, 4.5rem) 0 clamp(3rem, 6vw, 5rem);
  overflow: hidden;
}

.hero__orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  pointer-events: none;
}

.hero__orb--1 {
  width: 420px;
  height: 420px;
  background: rgba(124, 92, 255, 0.28);
  top: -80px;
  left: 8%;
  animation: pulse 8s ease-in-out infinite;
}

.hero__orb--2 {
  width: 280px;
  height: 280px;
  background: rgba(214, 179, 122, 0.14);
  bottom: 0;
  right: 12%;
  animation: pulse 9s ease-in-out infinite 1s;
}

.hero__grid {
  position: relative;
  z-index: 1;
}

.hero__panel {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: center;
}

.hero h1 {
  font-size: clamp(2.4rem, 5.2vw, 4rem);
  color: var(--heading);
  max-width: 10ch;
  margin-bottom: 1rem;
}

.hero__title-light,
.hero__subtitle--light,
.hero__range,
.hero__badge,
.hero__phone--light {
  display: none;
}

.hero__subtitle {
  max-width: 34rem;
  font-size: clamp(1rem, 1.5vw, 1.15rem);
  margin-bottom: 1.8rem;
}

.hero__range {
  color: var(--heading);
  font-weight: 700;
  margin: 0 0 0.9rem;
}

.hero__badge {
  display: none;
  align-items: center;
  gap: 0.4rem;
  width: fit-content;
  margin-bottom: 1.2rem;
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
  background: rgba(75, 63, 228, 0.1);
  color: var(--purple);
  font-size: 0.88rem;
  font-weight: 700;
}

.hero__perks {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.8rem;
  margin-top: 2.2rem;
}

.hero__perks li {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.55rem;
  text-align: center;
  color: var(--text);
  font-weight: 600;
  font-size: 0.9rem;
}

.perk-icon {
  width: 54px;
  height: 54px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  color: var(--heading);
  background: var(--purple-soft);
  border: 1px solid var(--border);
  box-shadow: inset 0 0 20px rgba(124, 92, 255, 0.06);
}

.perk-icon svg {
  width: 24px;
  height: 24px;
}

.hero__visual {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 420px;
}

.hero__rings {
  position: absolute;
  width: min(92%, 420px);
  aspect-ratio: 1;
  border-radius: 50%;
  background:
    radial-gradient(circle at center, rgba(124, 92, 255, 0.28) 0%, rgba(124, 92, 255, 0.08) 35%, transparent 60%),
    conic-gradient(from 180deg, transparent, rgba(214, 179, 122, 0.25), transparent 40%, rgba(124, 92, 255, 0.35), transparent 70%);
  filter: blur(0.2px);
  animation: spin 18s linear infinite;
}

.hero__rings::before,
.hero__rings::after {
  content: "";
  position: absolute;
  inset: 12%;
  border-radius: 50%;
  border: 1px solid rgba(214, 179, 122, 0.25);
}

.hero__rings::after {
  inset: 24%;
  border-color: rgba(124, 92, 255, 0.35);
}

.hero__phone {
  position: relative;
  z-index: 1;
  width: min(100%, 460px);
  animation: float 6s ease-in-out infinite;
  filter: drop-shadow(0 30px 50px rgba(0, 0, 0, 0.55));
}

/* ---------------------------------------------------------
   7) Promo banner
   --------------------------------------------------------- */
.promo {
  padding: 0 0 2rem;
}

.promo__card {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 1.5rem;
  align-items: center;
  padding: clamp(1.4rem, 3vw, 2.2rem);
  border-radius: 30px;
  background:
    linear-gradient(120deg, rgba(20, 28, 52, 0.95), rgba(12, 18, 36, 0.95)),
    var(--panel);
  border: 1px solid rgba(214, 179, 122, 0.2);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.promo__label {
  color: var(--muted);
  font-weight: 600;
  margin-bottom: 0.35rem;
}

.promo__amount {
  display: flex;
  align-items: baseline;
  gap: 0.7rem;
  flex-wrap: wrap;
  margin-bottom: 0.8rem;
}

.promo__amount span {
  font-size: clamp(2.8rem, 6vw, 4.4rem);
  font-weight: 800;
  line-height: 1;
  color: var(--gold);
}

.promo__amount small {
  font-size: 1.2rem;
  color: var(--gold-2);
  font-weight: 700;
}

.promo__text {
  max-width: 34rem;
  margin-bottom: 1.4rem;
}

.seo-block {
  padding: clamp(2.5rem, 5vw, 4rem) 0;
}

.seo-block__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

.seo-block__grid article {
  padding: 1.25rem 1.35rem;
  border-radius: 18px;
  border: 1px solid var(--border-soft);
  background: var(--surface);
}

.seo-block__grid h3 {
  margin: 0 0 0.55rem;
  font-size: 1.05rem;
  color: var(--heading);
}

.seo-block__grid p {
  margin: 0;
  color: var(--muted);
  line-height: 1.8;
  font-size: 0.95rem;
}

.seo-block__grid a {
  color: var(--heading);
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 3px;
}

@media (max-width: 900px) {
  .seo-block__grid {
    grid-template-columns: 1fr;
  }
}

.promo__media img {
  width: 100%;
  max-width: 420px;
  margin-inline: auto;
  border-radius: 20px;
  object-fit: cover;
}

/* ---------------------------------------------------------
   8) About
   --------------------------------------------------------- */
.about__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: center;
  margin-bottom: 2rem;
}

.about__media img {
  width: 100%;
  border-radius: 28px;
  border: 1px solid rgba(214, 179, 122, 0.18);
  box-shadow: var(--shadow);
  object-fit: cover;
  aspect-ratio: 4 / 3;
}

.about__content h1,
.about__content h2 {
  color: var(--heading);
  font-size: clamp(1.9rem, 3.4vw, 2.6rem);
  margin-bottom: 1rem;
}

.about__content p + p {
  margin-top: 0.9rem;
}

.about__content .btn {
  margin-top: 1.5rem;
}

.about__content .eyebrow {
  margin-bottom: 0.75rem;
}

.about__content p + p {
  margin-top: 0.85rem;
}

.about__pillars {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.1rem;
  margin-top: 2.2rem;
}

.about-card {
  padding: 1.5rem;
}

.about-card h2 {
  color: var(--heading);
  font-size: 1.2rem;
  margin-bottom: 0.75rem;
}

.page-about .about__stats {
  margin-top: 2.5rem;
}

.page-programs .programs,
.page-contact .contact,
.page-terms .terms {
  display: flex;
  align-items: center;
}

.page-programs .programs > .container,
.page-contact .contact > .container,
.page-terms .terms > .container {
  width: min(100% - 2.5rem, var(--container));
  margin-inline: auto;
}

.about__stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}

.stat {
  text-align: center;
  padding: 1.4rem 1rem;
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.015));
  border: 1px solid rgba(214, 179, 122, 0.22);
  transition: transform 0.3s var(--ease), border-color 0.3s var(--ease);
}

.stat:hover {
  transform: translateY(-5px);
  border-color: rgba(214, 179, 122, 0.45);
}

.stat strong {
  display: block;
  color: var(--gold);
  font-size: clamp(1.25rem, 2.2vw, 1.7rem);
  font-weight: 800;
  margin-bottom: 0.3rem;
}

.stat span {
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 600;
}

/* ---------------------------------------------------------
   9) Programs
   --------------------------------------------------------- */
.programs__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.1rem;
}

.programs__grid--three {
  grid-template-columns: repeat(3, 1fr);
}

.program-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.85rem;
  padding: 1.8rem 1.2rem;
  border-radius: 24px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.02));
  border: 1px solid rgba(214, 179, 122, 0.18);
  box-shadow: var(--shadow);
  transition: transform 0.3s var(--ease), border-color 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

.program-card:hover {
  transform: translateY(-8px);
  border-color: rgba(214, 179, 122, 0.45);
  box-shadow: 0 22px 50px rgba(214, 179, 122, 0.12);
}

.program-card__icon {
  width: 68px;
  height: 68px;
  border-radius: 20px;
  display: grid;
  place-items: center;
  color: var(--gold);
  background: rgba(214, 179, 122, 0.08);
  border: 1px solid rgba(214, 179, 122, 0.3);
}

.program-card__icon svg {
  width: 30px;
  height: 30px;
}

.program-card h2,
.program-card h3 {
  font-size: 1.2rem;
  color: var(--white);
}

.program-card p {
  flex: 1;
  font-size: 0.95rem;
}

/* ---------------------------------------------------------
   10) Contact
   --------------------------------------------------------- */
.contact__grid {
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  gap: 1.3rem;
  align-items: stretch;
}

.contact__info,
.contact__form {
  padding: 1.6rem;
}

.contact__info ul {
  display: grid;
  gap: 1rem;
}

.contact__info li {
  display: flex;
  gap: 0.9rem;
  align-items: flex-start;
}

.contact__icon {
  width: 46px;
  height: 46px;
  flex: 0 0 46px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: var(--gold);
  background: rgba(214, 179, 122, 0.08);
  border: 1px solid rgba(214, 179, 122, 0.28);
}

.contact__icon svg {
  width: 22px;
  height: 22px;
}

.contact__info strong {
  display: block;
  color: var(--gold);
  margin-bottom: 0.15rem;
  font-size: 0.95rem;
}

.contact__info a:hover {
  color: var(--gold-2);
}

.contact__social {
  display: flex;
  gap: 0.7rem;
  margin-top: 1.5rem;
}

.contact__social a,
.footer__social a {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: var(--gold);
  border: 1px solid rgba(214, 179, 122, 0.28);
  background: rgba(214, 179, 122, 0.06);
}

.contact__social a:hover,
.footer__social a:hover {
  background: rgba(214, 179, 122, 0.16);
  transform: translateY(-2px);
}

.contact__form {
  display: grid;
  gap: 0.95rem;
}

.form-field {
  display: grid;
  gap: 0.4rem;
}

.form-field label {
  font-weight: 700;
  font-size: 0.95rem;
}

.form-field input,
.form-field textarea {
  width: 100%;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(0, 0, 0, 0.25);
  padding: 0.9rem 1rem;
  transition: border-color 0.25s var(--ease), background 0.25s var(--ease);
}

.form-field input:focus,
.form-field textarea:focus {
  outline: none;
  border-color: rgba(214, 179, 122, 0.55);
  background: rgba(214, 179, 122, 0.05);
  box-shadow: var(--focus);
}

.form-field textarea {
  resize: vertical;
  min-height: 130px;
}

/* ---------------------------------------------------------
   11) Terms accordion
   --------------------------------------------------------- */
.accordion {
  display: grid;
  gap: 0.8rem;
  max-width: 900px;
  margin-inline: auto;
}

.accordion__item {
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(214, 179, 122, 0.18);
  overflow: hidden;
}

.accordion__item summary {
  list-style: none;
  cursor: pointer;
  padding: 1.1rem 1.3rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.accordion__item summary::-webkit-details-marker {
  display: none;
}

.accordion__item summary::after {
  content: "▾";
  color: var(--gold);
  transition: transform 0.25s var(--ease);
}

.accordion__item[open] summary::after {
  transform: rotate(180deg);
}

.accordion__item[open] {
  border-color: rgba(214, 179, 122, 0.4);
}

.accordion__item p {
  padding: 0 1.3rem 1.2rem;
}

.accordion__item a {
  color: var(--gold);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.terms-list {
  list-style: disc;
  padding: 0 1.3rem 1.2rem 0;
  display: grid;
  gap: 0.45rem;
  color: var(--muted);
}

.terms-list li {
  padding-inline-start: 0.2rem;
}

.table-wrap {
  padding: 0 1.3rem 1rem;
  overflow-x: auto;
}

.fees-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 420px;
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: 14px;
  overflow: hidden;
}

.fees-table caption {
  text-align: start;
  margin-bottom: 0.7rem;
  color: var(--heading);
  font-weight: 700;
}

.fees-table th,
.fees-table td {
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--border-soft);
  text-align: start;
}

.fees-table th {
  background: var(--purple-soft);
  color: var(--heading);
  font-weight: 800;
}

.fees-table td {
  color: var(--muted);
}

.fees-table tr:last-child td {
  border-bottom: none;
}

.terms-note,
.terms-example {
  padding: 0 1.3rem 1.2rem;
  color: var(--muted);
}

.terms-example {
  margin: 0 1.3rem 1.2rem;
  padding: 1rem 1.1rem;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: var(--purple-soft);
}

.terms-example h2 {
  font-size: 1rem;
  color: var(--heading);
  margin-bottom: 0.6rem;
}

.terms-example .terms-list {
  padding: 0;
}

.terms-footer-note {
  text-align: center;
  margin-top: 2rem;
  color: var(--heading);
  font-weight: 700;
}

/* ---------------------------------------------------------
   12) Footer
   --------------------------------------------------------- */
.footer {
  margin-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding-top: 3rem;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.015), transparent);
}

.footer__grid {
  display: grid;
  grid-template-columns: 1.1fr 1.5fr;
  gap: 2rem;
  padding-bottom: 2rem;
}

.footer__logo {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.9rem;
}

.footer__logo img {
  width: 58px;
  height: 58px;
  border-radius: 16px;
  object-fit: cover;
}

.footer__logo span {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.footer__logo strong {
  font-size: 1.05rem;
}

.footer__logo small {
  color: var(--muted);
}

.footer__brand p {
  max-width: 36ch;
}

.footer__nav {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.2rem;
}

.footer__nav h2 {
  font-size: 1rem;
  color: var(--gold);
  margin-bottom: 0.9rem;
}

.footer__nav ul {
  display: grid;
  gap: 0.5rem;
}

.footer__nav a,
.footer__nav span {
  color: var(--muted);
  font-size: 0.95rem;
}

.footer__nav a:hover {
  color: var(--gold);
}

.footer__bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding: 1.1rem 0 1.5rem;
}

.footer__bottom-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.footer__social {
  display: flex;
  gap: 0.6rem;
}

/* ---------------------------------------------------------
   13) Legal / 404 pages
   --------------------------------------------------------- */
.legal.section,
.error-page.section {
  padding-top: 3rem;
}

.legal__wrap,
.error-page__panel {
  border-radius: var(--radius-lg);
  padding: clamp(1.6rem, 4vw, 2.8rem);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.02));
  border: 1px solid rgba(214, 179, 122, 0.18);
  box-shadow: var(--shadow);
}

.section__header--start {
  text-align: start;
  margin-inline: 0;
}

.section__header--start h1 {
  color: var(--gold);
  font-size: clamp(1.9rem, 3.5vw, 2.6rem);
}

.legal__content {
  display: grid;
  gap: 1rem;
}

.legal__content h2 {
  color: var(--gold-2);
  font-size: 1.2rem;
  margin-top: 0.6rem;
}

.legal__content ul {
  list-style: disc;
  padding-inline-start: 1.3rem;
  display: grid;
  gap: 0.35rem;
}

.legal__content li,
.legal__content p {
  color: var(--muted);
}

.legal__content a {
  color: var(--gold);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.error-page {
  min-height: calc(100vh - 220px);
  display: grid;
  align-items: center;
}

.error-page__panel {
  text-align: center;
  max-width: 720px;
  margin-inline: auto;
}

.error-page__code {
  font-size: clamp(4rem, 12vw, 7rem);
  font-weight: 800;
  line-height: 1;
  color: var(--gold);
  margin-bottom: 0.4rem;
}

.error-page h1 {
  margin-bottom: 0.8rem;
}

.error-page__actions {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-top: 1.5rem;
}

/* ---------------------------------------------------------
   14) Animations
   --------------------------------------------------------- */
@keyframes float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-14px);
  }
}

@keyframes pulse {
  0%,
  100% {
    opacity: 0.55;
    transform: scale(1);
  }
  50% {
    opacity: 0.9;
    transform: scale(1.08);
  }
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* ---------------------------------------------------------
   15) Responsive
   --------------------------------------------------------- */
@media (max-width: 1100px) {
  .hero__panel,
  .promo__card,
  .about__grid,
  .contact__grid,
  .footer__grid {
    grid-template-columns: 1fr;
  }

  .hero h1 {
    max-width: 14ch;
  }

  .hero__visual {
    order: -1;
  }

  .programs__grid,
  .programs__grid--three,
  .about__stats,
  .about__pillars {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 900px) {
  .navbar__burger {
    display: inline-flex;
  }

  .navbar__nav {
    position: absolute;
    top: calc(var(--nav-h) + 8px);
    right: 1.25rem;
    left: 1.25rem;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0.9rem;
    padding: 1rem;
    border-radius: 18px;
    background: rgba(10, 15, 30, 0.97);
    border: 1px solid rgba(214, 179, 122, 0.2);
    box-shadow: var(--shadow);
  }

  .navbar__links,
  .navbar__actions {
    flex-direction: column;
    align-items: stretch;
  }

  .navbar__toggle:checked ~ .navbar__nav {
    display: flex;
  }

  .hero__perks {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 640px) {
  .container {
    width: min(100% - 1.4rem, var(--container));
  }

  .programs__grid,
  .programs__grid--three,
  .about__stats,
  .about__pillars,
  .footer__nav {
    grid-template-columns: 1fr;
  }

  .navbar__brand-text small {
    display: none;
  }

  .btn--lg,
  .btn--block,
  .promo .btn {
    width: 100%;
  }

  .footer__bottom-inner {
    justify-content: center;
    text-align: center;
  }
}

/* ---------------------------------------------------------
   16) Apply page — اطلب تمويلك
   --------------------------------------------------------- */
.page-apply .footer {
  margin-top: 0;
}

.apply-main {
  width: 100%;
  min-height: calc(100vh - var(--nav-h));
  display: grid;
  place-items: center;
  padding: clamp(1.5rem, 4vw, 3rem) 1.25rem;
}

.apply {
  width: 100%;
  display: grid;
  place-items: center;
}

.apply__shell {
  width: min(100%, 480px);
  margin-inline: auto;
  padding: clamp(1.5rem, 4vw, 2.2rem);
  border-radius: 28px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.02));
  border: 1px solid var(--border-soft);
  box-shadow: var(--shadow);
}

.apply__header {
  text-align: center;
  margin-bottom: 1.5rem;
}

.apply__header .eyebrow {
  justify-content: center;
  width: 100%;
}

.apply__header h1 {
  color: var(--heading);
  font-size: clamp(1.85rem, 4vw, 2.4rem);
  margin-bottom: 0.55rem;
}

.apply__header p {
  color: var(--muted);
  font-size: 1rem;
}

.apply__form {
  display: grid;
  gap: 0.7rem;
  margin-bottom: 1.35rem;
}

.apply__label {
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--text);
  text-align: start;
}

.phone-field {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-height: 58px;
  padding: 0.35rem 1rem;
  border-radius: 16px;
  border: 1px solid var(--border-soft);
  background: rgba(255, 255, 255, 0.03);
}

.phone-field__code {
  font-weight: 800;
  color: var(--heading);
  flex: 0 0 auto;
  direction: ltr;
}

.phone-field__divider {
  width: 1px;
  height: 28px;
  background: var(--border-soft);
}

.phone-field input {
  flex: 1;
  border: 0;
  outline: none;
  background: transparent;
  min-width: 0;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text);
  padding: 0.7rem 0;
}

.phone-field:focus-within {
  border-color: rgba(214, 179, 122, 0.45);
  box-shadow: var(--focus);
}

.apply__hint {
  font-size: 0.86rem;
  color: var(--muted);
  text-align: start;
  margin: 0;
}

.btn--send {
  width: 100%;
  min-height: 56px;
  margin-top: 0.35rem;
  border: 0;
  border-radius: 16px;
  background: linear-gradient(135deg, #ff9f2e, #f97316 45%, #ea580c);
  color: #fff;
  font-family: var(--font);
  font-size: 1.15rem;
  font-weight: 800;
  box-shadow: 0 14px 30px rgba(249, 115, 22, 0.35);
  cursor: pointer;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

.btn--send:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 36px rgba(249, 115, 22, 0.45);
}

.apply__download {
  border-radius: 24px;
  padding: 1.5rem 1.25rem 1.35rem;
  text-align: center;
  color: #fff;
  background:
    radial-gradient(circle at 12% 18%, rgba(255, 255, 255, 0.18), transparent 35%),
    linear-gradient(145deg, #22c3dc, #0ea5b7 50%, #0b8ea3);
  box-shadow: 0 18px 40px rgba(14, 165, 183, 0.25);
}

.apply__download h2 {
  font-size: 1.35rem;
  margin-bottom: 0.35rem;
  color: #fff;
}

.apply__download > p {
  color: rgba(255, 255, 255, 0.92);
  margin-bottom: 1.1rem;
  font-size: 0.95rem;
}

.store-stack {
  display: grid;
  gap: 0.65rem;
}

.store-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  min-height: 54px;
  padding: 0.65rem 1rem;
  border-radius: 14px;
  background: #111827;
  color: #fff;
  transition: transform 0.25s var(--ease), background 0.25s var(--ease);
}

.store-badge:hover {
  transform: translateY(-2px);
  background: #000;
}

.store-badge span {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1.15;
}

.store-badge small {
  font-size: 0.68rem;
  opacity: 0.85;
}

.store-badge strong {
  font-size: 1rem;
}

.apply__brand {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin-top: 1.4rem;
  text-align: start;
}

.apply__brand img {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  object-fit: cover;
}

.apply__brand strong {
  display: block;
  color: var(--heading);
  font-size: 1.05rem;
}

.apply__brand span {
  color: var(--muted);
  font-size: 0.88rem;
}

.apply__alert {
  padding: 0.9rem 1rem;
  border-radius: 14px;
  margin-bottom: 1rem;
  font-weight: 600;
  text-align: center;
}

.apply__alert--success {
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.35);
  color: #6ee7b7;
}

.apply__alert--error {
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: #fca5a5;
}

html[data-theme="light"] .apply__shell {
  background: #ffffff;
  border-color: rgba(26, 26, 80, 0.08);
  box-shadow: 0 20px 50px rgba(26, 32, 80, 0.1);
}

html[data-theme="light"] .phone-field {
  background: #f4f6fb;
}

html[data-theme="light"] .apply__alert--success {
  color: #059669;
}

html[data-theme="light"] .apply__alert--error {
  color: #dc2626;
}

/* ---------------------------------------------------------
   17) Light theme refinements
   --------------------------------------------------------- */
html[data-theme="light"] .hero__title-dark,
html[data-theme="light"] .hero__subtitle--dark,
html[data-theme="light"] .hero__phone--dark,
html[data-theme="light"] .hero__perks {
  display: none;
}

html[data-theme="light"] .hero__title-light,
html[data-theme="light"] .hero__subtitle--light,
html[data-theme="light"] .hero__phone--light {
  display: block;
}

html[data-theme="light"] .hero__badge {
  display: inline-flex;
}

html[data-theme="light"] .hero__panel {
  background: #ffffff;
  border: 1px solid rgba(26, 26, 80, 0.06);
  border-radius: 32px;
  padding: clamp(1.4rem, 3vw, 2.4rem);
  box-shadow: 0 24px 60px rgba(26, 32, 80, 0.08);
}

html[data-theme="light"] .hero h1 {
  max-width: 12ch;
}

html[data-theme="light"] .hero__subtitle--light {
  margin-bottom: 0.7rem;
  color: var(--muted);
}

html[data-theme="light"] .card,
html[data-theme="light"] .program-card,
html[data-theme="light"] .stat,
html[data-theme="light"] .accordion__item,
html[data-theme="light"] .promo__card,
html[data-theme="light"] .legal__wrap,
html[data-theme="light"] .error-page__panel {
  background: #ffffff;
  border-color: rgba(26, 26, 80, 0.08);
  box-shadow: 0 16px 40px rgba(26, 32, 80, 0.08);
}

html[data-theme="light"] .about__content h1,
html[data-theme="light"] .about__content h2,
html[data-theme="light"] .stat strong,
html[data-theme="light"] .promo__amount span,
html[data-theme="light"] .promo__amount small,
html[data-theme="light"] .contact__info strong,
html[data-theme="light"] .footer__nav h2,
html[data-theme="light"] .legal__content h2,
html[data-theme="light"] .error-page__code,
html[data-theme="light"] .section__header--start h1 {
  color: var(--heading);
}

html[data-theme="light"] .program-card__icon,
html[data-theme="light"] .contact__icon,
html[data-theme="light"] .contact__social a,
html[data-theme="light"] .footer__social a {
  color: var(--purple);
  background: rgba(75, 63, 228, 0.08);
  border-color: rgba(75, 63, 228, 0.2);
}

html[data-theme="light"] .form-field input,
html[data-theme="light"] .form-field textarea {
  background: var(--input-bg);
  border-color: rgba(26, 26, 80, 0.1);
  color: var(--text);
}

html[data-theme="light"] .form-field input:focus,
html[data-theme="light"] .form-field textarea:focus {
  border-color: rgba(59, 68, 209, 0.45);
  background: #ffffff;
}

html[data-theme="light"] .footer {
  background: linear-gradient(180deg, rgba(75, 63, 228, 0.03), transparent);
}

html[data-theme="light"] .navbar__burger span {
  background: var(--text);
}

html[data-theme="light"] .promo__card {
  background: linear-gradient(120deg, #ffffff, #f4f6fb);
}

html[data-theme="light"] .accordion__item summary::after,
html[data-theme="light"] .navbar__brand-text strong {
  color: var(--heading);
}

html[data-theme="dark"] .hero__phone--light {
  display: none;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition-duration: 0.01ms !important;
  }
}
