/* ============================================================
   QuranPath Academy — Design Tokens
   Palette drawn from manuscript illumination + mosque tilework,
   not the generic cream/terracotta AI default.
   ============================================================ */
:root {
  --ink:          #16242E;   /* deep navy-charcoal, primary text */
  --ink-soft:     #3C4E58;   /* secondary text */
  --teal:         #0F5C56;   /* primary brand — tilework teal */
  --teal-dark:    #0A3F3B;   /* hover / deep accents */
  --teal-tint:    #E4EEEC;   /* pale teal panels */
  --gold:         #C1912B;   /* illumination gold leaf */
  --gold-light:   #E3B85C;   /* highlight gold */
  --parchment:    #F6F1E4;   /* manuscript page background */
  --parchment-2:  #EFE7D3;   /* deeper parchment for contrast blocks */
  --white:        #FFFDF8;
  --line:         #DCD2B8;   /* hairline borders on parchment */
  --line-dark:    rgba(255,253,248,0.16);

  /* tajweed rule colors — used in the recitation signature + legend */
  --tw-ghunnah:   #2E7D4F;   /* nasal sound — green */
  --tw-qalqalah:  #C1662B;   /* echo/bounce — burnt orange */
  --tw-madd:      #2A5FA5;   /* elongation — blue */
  --tw-ikhfa:     #7A4FA0;   /* concealment — violet */

  --radius-sm: 6px;
  --radius-md: 14px;
  --radius-lg: 26px;

  --shadow-soft: 0 10px 30px -12px rgba(22,36,46,0.18);
  --shadow-card: 0 2px 0 var(--line), 0 14px 30px -18px rgba(22,36,46,0.22);

  --font-display: 'Amiri', 'Noto Naskh Arabic', serif;
  --font-body: 'Work Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'IBM Plex Mono', ui-monospace, monospace;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--parchment);
  -webkit-font-smoothing: antialiased;
  line-height: 1.6;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.15;
  margin: 0 0 0.5em;
  color: var(--teal-dark);
  letter-spacing: 0.2px;
}
p { margin: 0 0 1em; color: var(--ink-soft); }
.eyebrow {
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.72rem;
  color: var(--gold);
  font-weight: 600;
}
.container {
  width: 100%;
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 24px;
}
:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
}

/* ============================================================
   Star motif divider (girih-inspired, drawn once, reused)
   ============================================================ */
.star-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin: 0 auto;
  opacity: 0.75;
}
.star-divider .line { width: 64px; height: 1px; background: var(--line); }
.star-divider svg { width: 18px; height: 18px; }

/* ============================================================
   Header / Nav
   ============================================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(246, 241, 228, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  max-width: 1160px;
  margin: 0 auto;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
}
.brand svg { width: 34px; height: 34px; flex-shrink: 0; }
.brand-text { display: flex; flex-direction: column; line-height: 1.05; }
.brand-text strong {
  font-family: var(--font-display);
  font-size: 1.18rem;
  color: var(--teal-dark);
}
.brand-text span {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.08em;
  color: var(--gold);
  text-transform: uppercase;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 30px;
  font-size: 0.95rem;
  font-weight: 500;
}
.nav-links a { color: var(--ink-soft); position: relative; padding: 4px 0; }
.nav-links a:hover, .nav-links a.active { color: var(--teal-dark); }
.nav-links a.active::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -6px;
  height: 2px;
  background: var(--gold);
}
.nav-cta {
  display: flex;
  gap: 12px;
  align-items: center;
}
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}
.nav-toggle svg { width: 26px; height: 26px; color: var(--teal-dark); }

@media (max-width: 860px) {
  .nav-links { display: none; }
  .nav-toggle { display: block; }
  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 100%; left: 0; right: 0;
    background: var(--parchment);
    padding: 20px 24px;
    border-bottom: 1px solid var(--line);
    gap: 18px;
  }
}

/* ============================================================
   Buttons
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 12px 22px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--teal); color: var(--white); box-shadow: var(--shadow-soft); }
.btn-primary:hover { background: var(--teal-dark); }
.btn-gold { background: var(--gold); color: var(--white); }
.btn-gold:hover { background: #A9791F; }
.btn-outline { background: transparent; border-color: var(--teal); color: var(--teal-dark); }
.btn-outline:hover { background: var(--teal-tint); }
.btn-ghost { background: transparent; color: var(--ink-soft); }
.btn-ghost:hover { color: var(--teal-dark); }
.btn-sm { padding: 8px 16px; font-size: 0.85rem; }
.btn-block { width: 100%; }

/* ============================================================
   Hero — tajweed recitation signature
   ============================================================ */
.hero {
  padding: 76px 0 60px;
  position: relative;
  overflow: hidden;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 56px;
  align-items: center;
}
.hero h1 {
  font-size: clamp(2.1rem, 4vw, 3.1rem);
  margin-bottom: 0.4em;
}
.hero h1 .accent { color: var(--gold); }
.hero-lede { font-size: 1.08rem; max-width: 46ch; }
.hero-actions { display: flex; gap: 14px; margin-top: 28px; flex-wrap: wrap; }
.hero-trust {
  display: flex;
  gap: 26px;
  margin-top: 40px;
  flex-wrap: wrap;
}
.hero-trust .stat strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.5rem;
  color: var(--teal-dark);
}
.hero-trust .stat span {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

/* the recitation card: signature element */
.recitation-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 34px 30px;
  box-shadow: var(--shadow-card);
  position: relative;
}
.recitation-card .card-label {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ink-soft);
  margin-bottom: 18px;
  display: flex;
  justify-content: space-between;
}
.arabic-line {
  direction: rtl;
  font-family: var(--font-display);
  font-size: 2.1rem;
  line-height: 2.1;
  text-align: right;
  margin-bottom: 8px;
}
.arabic-line span {
  opacity: 0;
  animation: riseIn 0.6s ease forwards;
}
@keyframes riseIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}
.tw-ghunnah  { color: var(--tw-ghunnah); }
.tw-qalqalah { color: var(--tw-qalqalah); }
.tw-madd     { color: var(--tw-madd); }
.tw-ikhfa    { color: var(--tw-ikhfa); }
.tw-plain    { color: var(--ink); }

.translit {
  font-family: var(--font-body);
  font-style: italic;
  color: var(--ink-soft);
  font-size: 0.92rem;
  text-align: right;
  margin-bottom: 20px;
}
.tw-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  border-top: 1px dashed var(--line);
  padding-top: 16px;
}
.tw-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  padding: 5px 10px;
  border-radius: 100px;
  background: var(--parchment);
  border: 1px solid var(--line);
  cursor: default;
  transition: background 0.15s ease, transform 0.15s ease;
}
.tw-chip:hover { transform: translateY(-1px); }
.tw-chip .dot { width: 8px; height: 8px; border-radius: 50%; }

/* ============================================================
   Sections generic
   ============================================================ */
.section { padding: 70px 0; }
.section-alt { background: var(--white); }
.section-dark {
  background: var(--teal-dark);
  color: var(--white);
}
.section-dark h2, .section-dark h3 { color: var(--white); }
.section-dark p { color: rgba(255,253,248,0.78); }
.section-head { max-width: 620px; margin: 0 auto 46px; text-align: center; }
.section-head h2 { font-size: clamp(1.7rem, 3vw, 2.3rem); }

/* Path / audience cards */
.path-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.path-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 30px 26px;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.path-card .icon-badge {
  width: 46px; height: 46px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  background: var(--teal-tint);
  color: var(--teal-dark);
}
.path-card .icon-badge svg { width: 24px; height: 24px; }
.path-card h3 { font-size: 1.2rem; margin-bottom: 2px; }
.path-card ul { margin: 4px 0 0; padding-left: 18px; color: var(--ink-soft); font-size: 0.92rem; }
.path-card ul li { margin-bottom: 4px; }
.path-card .btn { margin-top: auto; align-self: flex-start; }

/* Course grid */
.course-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}
.course-card {
  background: var(--parchment);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 26px;
  transition: box-shadow 0.15s ease, transform 0.15s ease;
}
.course-card:hover { box-shadow: var(--shadow-card); transform: translateY(-2px); }
.course-card .tag {
  font-family: var(--font-mono);
  font-size: 0.64rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--gold);
  display: inline-block;
  margin-bottom: 10px;
}
.course-card h3 { font-size: 1.15rem; margin-bottom: 6px; }
.course-card .meta {
  display: flex;
  gap: 16px;
  margin-top: 16px;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--ink-soft);
  border-top: 1px solid var(--line);
  padding-top: 14px;
}

/* Steps */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.step {
  padding: 24px 20px;
  border-left: 2px solid var(--gold);
}
.step .num {
  font-family: var(--font-mono);
  color: var(--gold);
  font-size: 0.85rem;
  margin-bottom: 6px;
}
.step h4 { font-size: 1.02rem; margin-bottom: 6px; }
.step p { font-size: 0.9rem; margin: 0; }

/* Testimonials */
.testimonial-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.testimonial {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 26px;
  box-shadow: var(--shadow-card);
}
.testimonial p { font-style: italic; color: var(--ink); font-size: 0.96rem; }
.testimonial .who {
  display: flex; align-items: center; gap: 10px; margin-top: 16px;
  font-family: var(--font-mono); font-size: 0.75rem; color: var(--ink-soft);
}
.testimonial .avatar {
  width: 34px; height: 34px; border-radius: 50%;
  background: var(--teal-tint); color: var(--teal-dark);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display); font-weight: 700;
}

/* CTA band */
.cta-band {
  background: var(--teal);
  border-radius: var(--radius-lg);
  padding: 50px 44px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
  color: var(--white);
  flex-wrap: wrap;
}
.cta-band h2 { color: var(--white); margin-bottom: 6px; }
.cta-band p { color: rgba(255,253,248,0.82); margin: 0; }

/* Forms */
.form-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 40px;
  box-shadow: var(--shadow-card);
}
.form-row { margin-bottom: 18px; }
.form-row label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--teal-dark);
  margin-bottom: 6px;
}
.form-row input, .form-row select, .form-row textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: 0.95rem;
  background: var(--parchment);
  color: var(--ink);
}
.form-row input:focus, .form-row select:focus, .form-row textarea:focus {
  outline: 2px solid var(--teal);
  border-color: var(--teal);
  background: var(--white);
}
.form-two { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }

/* Footer */
.site-footer {
  background: var(--ink);
  color: rgba(255,253,248,0.72);
  padding: 56px 0 26px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: 36px;
  padding-bottom: 36px;
  border-bottom: 1px solid rgba(255,253,248,0.12);
}
.footer-grid h4 {
  color: var(--white);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 16px;
}
.footer-grid ul { list-style: none; padding: 0; margin: 0; }
.footer-grid li { margin-bottom: 10px; font-size: 0.9rem; }
.footer-grid a:hover { color: var(--gold-light); }
.footer-brand p { color: rgba(255,253,248,0.6); font-size: 0.88rem; max-width: 32ch; }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  padding-top: 22px;
  font-size: 0.78rem;
  color: rgba(255,253,248,0.5);
  flex-wrap: wrap;
  gap: 10px;
}

/* Badges */
.badge-row { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 18px; }
.badge {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: var(--font-mono); font-size: 0.68rem;
  padding: 6px 12px; border-radius: 100px;
  border: 1px solid var(--line-dark);
  color: rgba(255,253,248,0.85);
}

/* Social icons row (footer) */
.social-row { display: flex; gap: 10px; margin-top: 20px; }
.social-icon {
  width: 38px; height: 38px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  background: rgba(255,253,248,0.08);
  border: 1px solid rgba(255,253,248,0.14);
  color: rgba(255,253,248,0.85);
  transition: background 0.15s ease, transform 0.15s ease;
}
.social-icon:hover { background: var(--gold); color: var(--ink); transform: translateY(-2px); }
.social-icon svg { width: 18px; height: 18px; }

/* Page hero (interior pages) */
.page-hero {
  padding: 54px 0 40px;
  text-align: center;
}
.page-hero .eyebrow { display: block; margin-bottom: 10px; }
.page-hero h1 { font-size: clamp(1.9rem, 3.4vw, 2.6rem); }
.page-hero p { max-width: 56ch; margin: 0 auto; }

/* Audit banner (reusable, ties into free-audit CTA) */
.audit-banner {
  display: flex;
  align-items: center;
  gap: 22px;
  background: var(--parchment-2);
  border: 1px dashed var(--gold);
  border-radius: var(--radius-md);
  padding: 24px 28px;
  margin: 40px 0;
}
.audit-banner .icon { flex-shrink: 0; width: 44px; height: 44px; color: var(--gold); }
.audit-banner h3 { margin-bottom: 4px; font-size: 1.05rem; }
.audit-banner p { margin: 0; font-size: 0.9rem; }
.audit-banner .btn { margin-left: auto; flex-shrink: 0; }

/* Utility */
.mt-0 { margin-top: 0; }
.text-center { text-align: center; }
.mx-auto { margin-left: auto; margin-right: auto; }

@media (max-width: 980px) {
  .hero-grid { grid-template-columns: 1fr; }
  .path-grid, .course-grid, .testimonial-grid { grid-template-columns: 1fr 1fr; }
  .steps { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .form-two { grid-template-columns: 1fr; }
  .cta-band { flex-direction: column; align-items: flex-start; }
  .audit-banner { flex-direction: column; align-items: flex-start; }
  .audit-banner .btn { margin-left: 0; }
}
@media (max-width: 620px) {
  .path-grid, .course-grid, .testimonial-grid, .steps { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .arabic-line { font-size: 1.5rem; }
}

/* ============================================================
   Teacher spotlight
   ============================================================ */
.teacher-spotlight {
  max-width: 720px;
  margin: 0 auto;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 40px;
  box-shadow: var(--shadow-card);
  display: flex;
  gap: 30px;
  align-items: center;
}
.teacher-avatar {
  width: 92px; height: 92px;
  border-radius: 50%;
  background: var(--teal-tint);
  color: var(--teal-dark);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display); font-weight: 700; font-size: 2rem;
  flex-shrink: 0;
  border: 2px solid var(--gold);
}
.teacher-info h3 { font-size: 1.25rem; margin-bottom: 2px; }
.teacher-role {
  font-family: var(--font-mono); font-size: 0.7rem; text-transform: uppercase;
  letter-spacing: 0.06em; color: var(--gold); margin-bottom: 10px; display: block;
}
.teacher-info p { font-size: 0.94rem; margin-bottom: 0; }
@media (max-width: 620px) {
  .teacher-spotlight { flex-direction: column; text-align: center; padding: 30px 24px; }
}

/* ============================================================
   Blog
   ============================================================ */
.blog-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.blog-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  transition: transform 0.15s ease;
}
.blog-card:hover { transform: translateY(-3px); }
.blog-cover {
  height: 150px;
  background: linear-gradient(135deg, var(--teal-dark), var(--teal));
  display: flex; align-items: center; justify-content: center;
  position: relative;
  overflow: hidden;
}
.blog-cover svg { width: 46px; height: 46px; color: rgba(246,241,228,0.85); position: relative; z-index: 2; }
.blog-cover::before {
  content: "";
  position: absolute; inset: 0;
  background-image: radial-gradient(rgba(227,184,92,0.18) 1.5px, transparent 1.5px);
  background-size: 18px 18px;
}
.blog-card-body { padding: 22px 22px 24px; display: flex; flex-direction: column; flex-grow: 1; }
.blog-meta {
  font-family: var(--font-mono); font-size: 0.66rem; text-transform: uppercase;
  letter-spacing: 0.06em; color: var(--gold); margin-bottom: 8px;
}
.blog-card-body h3 { font-size: 1.1rem; margin-bottom: 8px; }
.blog-card-body p { font-size: 0.88rem; flex-grow: 1; }
.blog-read { font-size: 0.85rem; font-weight: 600; color: var(--teal-dark); margin-top: 10px; }

/* Article page */
.article-hero { padding: 54px 0 20px; }
.article-meta {
  display: flex; gap: 16px; align-items: center;
  font-family: var(--font-mono); font-size: 0.72rem; color: var(--ink-soft);
  text-transform: uppercase; letter-spacing: 0.05em;
  margin-bottom: 18px;
}
.article-hero h1 { font-size: clamp(1.9rem, 3.6vw, 2.6rem); max-width: 30ch; }
.article-lede { font-size: 1.08rem; max-width: 62ch; }
.article-body {
  max-width: 680px;
  margin: 0 auto;
  padding: 10px 0 50px;
}
.article-body h2 {
  font-size: 1.4rem;
  margin-top: 2em;
  margin-bottom: 0.6em;
}
.article-body p { font-size: 1.02rem; color: var(--ink); margin-bottom: 1.3em; }
.article-body ul { margin: 0 0 1.3em; padding-left: 22px; }
.article-body li { margin-bottom: 0.5em; color: var(--ink); }
.article-body blockquote {
  border-left: 3px solid var(--gold);
  margin: 1.8em 0;
  padding: 4px 0 4px 20px;
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.15rem;
  color: var(--teal-dark);
}
.article-share {
  display: flex; gap: 10px; align-items: center; margin: 30px 0;
  padding: 18px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
}
.article-share span { font-family: var(--font-mono); font-size: 0.72rem; text-transform: uppercase; color: var(--ink-soft); }
.related-posts { max-width: 680px; margin: 0 auto; padding-bottom: 60px; }
.related-posts h3 { font-size: 1.1rem; margin-bottom: 16px; }

/* ============================================================
   Floating WhatsApp button
   ============================================================ */
.whatsapp-float {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 90;
  display: flex;
  align-items: center;
  gap: 10px;
  background: #25D366;
  color: #fff;
  padding: 13px 18px;
  border-radius: 100px;
  box-shadow: 0 10px 26px -10px rgba(22,36,46,0.4);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.9rem;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.whatsapp-float:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 30px -10px rgba(22,36,46,0.48);
}
.whatsapp-float svg { width: 22px; height: 22px; flex-shrink: 0; }
.whatsapp-float .wa-text { white-space: nowrap; }
@media (max-width: 620px) {
  .whatsapp-float { bottom: 18px; right: 18px; padding: 13px; }
  .whatsapp-float .wa-text { display: none; }
}
