/* ============================================================
   Musa Quran Academy — Custom Styles
   Palette, typography, layout, components, responsiveness
   ============================================================ */

:root {
  --green: #0F5C4D;
  --green-dark: #174D3C;
  --gold: #C8A45D;
  --gold-light: #E8D4A2;
  --ivory: #FAF7F2;
  --white: #FFFFFF;
  --text-dark: #1F2937;
  --text-gray: #4B5563;

  --shadow-sm: 0 4px 14px rgba(15, 92, 77, 0.08);
  --shadow-md: 0 14px 40px rgba(15, 92, 77, 0.12);
  --shadow-lg: 0 24px 60px rgba(15, 92, 77, 0.18);
  --radius: 18px;
  --radius-sm: 12px;

  --font-head: "Playfair Display", Georgia, serif;
  --font-body: "Poppins", system-ui, -apple-system, "Segoe UI", sans-serif;
}

/* ---------- Base ---------- */
* { scroll-behavior: smooth; }

html { scroll-padding-top: 84px; }

body {
  font-family: var(--font-body);
  color: var(--text-dark);
  background: var(--ivory);
  line-height: 1.7;
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, .brand-name, .footer-name {
  font-family: var(--font-head);
  font-weight: 700;
  color: var(--green-dark);
  letter-spacing: -0.01em;
}

p { color: var(--text-gray); }

a { text-decoration: none; transition: color .25s ease, transform .25s ease; }

.text-gold { color: var(--gold) !important; }

/* ---------- Buttons ---------- */
.btn {
  font-family: var(--font-body);
  font-weight: 600;
  border-radius: 999px;
  padding: 0.7rem 1.6rem;
  border: none;
  transition: transform .2s ease, box-shadow .25s ease, background .25s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}
.btn:active { transform: translateY(1px); }
.btn-lg { padding: 0.9rem 2rem; font-size: 1.02rem; }
.btn-sm { padding: 0.5rem 1.2rem; font-size: 0.9rem; }

.btn-gold {
  background: linear-gradient(135deg, var(--gold-light), var(--gold));
  color: var(--green-dark);
  box-shadow: 0 10px 24px rgba(200, 164, 93, 0.35);
}
.btn-gold:hover {
  color: var(--green-dark);
  transform: translateY(-3px);
  box-shadow: 0 16px 32px rgba(200, 164, 93, 0.45);
}

.btn-green {
  background: linear-gradient(135deg, var(--green), var(--green-dark));
  color: var(--white);
  box-shadow: 0 10px 24px rgba(15, 92, 77, 0.3);
}
.btn-green:hover {
  color: var(--white);
  transform: translateY(-3px);
  box-shadow: 0 16px 32px rgba(15, 92, 77, 0.4);
}

.btn-whatsapp {
  background: #25D366;
  color: #fff;
  box-shadow: 0 10px 24px rgba(37, 211, 102, 0.35);
}
.btn-whatsapp:hover {
  background: #1ebe5b;
  color: #fff;
  transform: translateY(-3px);
  box-shadow: 0 16px 32px rgba(37, 211, 102, 0.45);
}

/* ---------- Navbar ---------- */
.mqa-navbar {
  background: rgba(250, 247, 242, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  padding: 0.6rem 0;
  transition: background .3s ease, box-shadow .3s ease, padding .3s ease;
  border-bottom: 1px solid rgba(15, 92, 77, 0.06);
}
.mqa-navbar.scrolled {
  background: rgba(250, 247, 242, 0.97);
  box-shadow: var(--shadow-sm);
  padding: 0.35rem 0;
}
.brand-logo { border-radius: 50%; object-fit: cover; background: var(--white); box-shadow: 0 4px 12px rgba(15,92,77,0.12); }
.navbar-brand .brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-name { font-size: 1.15rem; color: var(--green-dark); }
.brand-tag { font-size: 0.68rem; color: var(--gold); font-weight: 500; letter-spacing: 0.02em; }

.mqa-navbar .nav-link {
  color: var(--text-dark);
  font-weight: 500;
  margin: 0 0.35rem;
  position: relative;
  padding: 0.4rem 0.2rem;
}
.mqa-navbar .nav-link::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 0; height: 2px;
  background: var(--gold);
  transition: width .25s ease;
}
.mqa-navbar .nav-link:hover,
.mqa-navbar .nav-link.active { color: var(--green); }
.mqa-navbar .nav-link:hover::after,
.mqa-navbar .nav-link.active::after { width: 100%; }
.navbar-toggler { border: none; font-size: 1.6rem; color: var(--green); box-shadow: none !important; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding: 170px 0 90px;
  background:
    radial-gradient(1200px 600px at 80% -10%, rgba(200,164,93,0.18), transparent 60%),
    linear-gradient(160deg, #ffffff 0%, var(--ivory) 60%, #f3eee4 100%);
  overflow: hidden;
}
.hero-pattern {
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='80' height='80' viewBox='0 0 80 80'%3E%3Cpath d='M40 0l12 28 28 12-28 12-12 28-12-28L0 40l28-12z' fill='none' stroke='%230F5C4D' stroke-width='1' opacity='0.05'/%3E%3C/svg%3E");
  background-size: 80px 80px;
  pointer-events: none;
}
.hero-content { position: relative; z-index: 2; }
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(15, 92, 77, 0.08);
  color: var(--green);
  font-weight: 600;
  font-size: 0.85rem;
  padding: 0.45rem 1rem;
  border-radius: 999px;
  margin-bottom: 1.3rem;
}
.hero-title {
  font-size: clamp(2.3rem, 5vw, 3.6rem);
  line-height: 1.12;
  margin-bottom: 1.2rem;
}
.hero-subtitle {
  font-size: 1.18rem;
  color: var(--text-gray);
  max-width: 560px;
  margin-bottom: 2rem;
}
.hero-trust li { font-size: 0.92rem; font-weight: 500; color: var(--text-dark); }

.hero-card {
  position: relative;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  border: 1px solid rgba(200, 164, 93, 0.25);
}
.hero-card-glow {
  position: absolute;
  inset: -2px;
  border-radius: var(--radius);
  background: linear-gradient(135deg, rgba(200,164,93,0.25), rgba(15,92,77,0.12));
  filter: blur(18px);
  z-index: -1;
}
.hero-card-inner { padding: 2rem; }
.hero-card-list li {
  padding: 0.4rem 0;
  color: var(--text-dark);
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}
.hero-card-list i { color: var(--green); }

/* ---------- Sections ---------- */
.section { padding: 90px 0; position: relative; }
.section-ivory { background: linear-gradient(180deg, #fff 0%, var(--ivory) 100%); }
.section-head { max-width: 720px; margin: 0 auto 1rem; }
.eyebrow {
  display: inline-block;
  font-weight: 600;
  font-size: 0.82rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.6rem;
}
.eyebrow-light { color: var(--gold-light); }
.section-title { font-size: clamp(1.8rem, 3.5vw, 2.6rem); margin-bottom: 0.8rem; }
.section-sub { font-size: 1.05rem; color: var(--text-gray); }

/* decorative divider under titles */
.section-title::after {
  content: "";
  display: block;
  width: 70px; height: 3px;
  margin: 0.9rem auto 0;
  background: linear-gradient(90deg, var(--gold), var(--gold-light));
  border-radius: 2px;
}

/* ---------- About / Teacher ---------- */
.teacher-card {
  background: linear-gradient(160deg, var(--green), var(--green-dark));
  color: #fff;
  border-radius: var(--radius);
  padding: 2.5rem 2rem;
  text-align: center;
  box-shadow: var(--shadow-md);
  position: relative;
  overflow: hidden;
}
.teacher-card::before {
  content: "";
  position: absolute;
  top: -40px; right: -40px;
  width: 160px; height: 160px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cpath d='M80 10l18 52 52 18-52 18-18 52-18-52L10 80l52-18z' fill='none' stroke='%23C8A45D' stroke-width='2' opacity='0.25'/%3E%3C/svg%3E");
}
.teacher-avatar {
  width: 160px; height: 160px;
  margin: 0 auto 1.2rem;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--gold-light), var(--gold));
  padding: 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 26px rgba(0,0,0,0.25);
}
.teacher-avatar img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  object-position: center 20%;
  background: var(--white);
}
.teacher-name { color: #fff; margin-bottom: 0.2rem; }
.teacher-role { color: var(--gold-light); font-weight: 500; margin-bottom: 1.6rem; }
.teacher-stats {
  display: flex;
  justify-content: space-around;
  border-top: 1px solid rgba(255,255,255,0.18);
  padding-top: 1.4rem;
}
.teacher-stats > div { display: flex; flex-direction: column; }
.stat-num { font-family: var(--font-head); font-size: 1.7rem; font-weight: 800; color: var(--gold-light); }
.stat-label { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.06em; color: rgba(255,255,255,0.75); }

.feature-list li {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  font-weight: 500;
  color: var(--text-dark);
}
.feature-list i {
  flex-shrink: 0;
  width: 38px; height: 38px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 10px;
  background: rgba(15,92,77,0.08);
  color: var(--green);
  font-size: 1.05rem;
}

/* ---------- Courses ---------- */
.course-card {
  height: 100%;
  background: var(--white);
  border: 1px solid rgba(15,92,77,0.07);
  border-radius: var(--radius);
  padding: 1.8rem 1.5rem;
  box-shadow: var(--shadow-sm);
  transition: transform .3s ease, box-shadow .3s ease, border-color .3s ease;
}
.course-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-md);
  border-color: rgba(200,164,93,0.5);
}
.course-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px; height: 56px;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(200,164,93,0.18), rgba(15,92,77,0.1));
  color: var(--green);
  font-size: 1.6rem;
  margin-bottom: 1.1rem;
}
.course-title { font-size: 1.15rem; margin-bottom: 0.5rem; }
.course-text { font-size: 0.92rem; margin-bottom: 0; }

/* ---------- Why Choose Us ---------- */
.section-green {
  background: linear-gradient(160deg, var(--green-dark), var(--green));
  overflow: hidden;
}
.why-pattern {
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='90' height='90' viewBox='0 0 90 90'%3E%3Cpath d='M45 0l13 32 32 13-32 13-13 32-13-32L0 45l32-13z' fill='none' stroke='%23ffffff' stroke-width='1' opacity='0.05'/%3E%3C/svg%3E");
  background-size: 90px 90px;
  pointer-events: none;
}
.why-card {
  height: 100%;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: var(--radius);
  padding: 1.8rem 1.6rem;
  backdrop-filter: blur(6px);
  transition: transform .3s ease, background .3s ease, border-color .3s ease;
}
.why-card:hover {
  transform: translateY(-6px);
  background: rgba(255,255,255,0.1);
  border-color: rgba(200,164,93,0.5);
}
.why-card i { font-size: 2rem; color: var(--gold-light); margin-bottom: 1rem; display: block; }
.why-title { color: #fff; font-size: 1.18rem; margin-bottom: 0.5rem; }
.why-card p { color: rgba(255,255,255,0.78); margin-bottom: 0; font-size: 0.93rem; }
.why-card-wide {
  display: flex;
  align-items: center;
  gap: 1.4rem;
  flex-wrap: wrap;
}
.why-card-wide i { margin-bottom: 0; }

.countries { text-align: center; }
.countries-label { display: block; color: rgba(255,255,255,0.7); font-size: 0.9rem; margin-bottom: 1rem; }
.countries-list { display: flex; justify-content: center; flex-wrap: wrap; gap: 0.8rem; }
.country-pill {
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(200,164,93,0.4);
  color: #fff;
  padding: 0.5rem 1.2rem;
  border-radius: 999px;
  font-weight: 500;
  font-size: 0.95rem;
}

/* ---------- Contact ---------- */
.contact-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 2.2rem;
  box-shadow: var(--shadow-md);
  border: 1px solid rgba(15,92,77,0.06);
}
.form-label { font-weight: 500; font-size: 0.88rem; color: var(--text-dark); margin-bottom: 0.3rem; }
.form-control, .form-select {
  border-radius: var(--radius-sm);
  border: 1.5px solid #e6e1d6;
  padding: 0.7rem 0.95rem;
  background: #fdfcfa;
  transition: border-color .2s ease, box-shadow .2s ease;
}
.form-control:focus, .form-select:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 0.2rem rgba(200,164,93,0.18);
  background: #fff;
}
.form-text { color: var(--text-gray); }

.info-card {
  height: 100%;
  background: linear-gradient(160deg, var(--green), var(--green-dark));
  color: #fff;
  border-radius: var(--radius);
  padding: 2.2rem;
  box-shadow: var(--shadow-md);
}
.info-card h3, .info-card h4 { color: #fff; }
.info-list li { display: flex; align-items: center; gap: 1rem; margin-bottom: 1.3rem; }
.info-icon {
  flex-shrink: 0;
  width: 46px; height: 46px;
  border-radius: 12px;
  background: rgba(255,255,255,0.12);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.3rem;
  color: var(--gold-light);
}
.info-label { display: block; font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.06em; color: rgba(255,255,255,0.65); }
.info-list a { color: #fff; font-weight: 500; }
.info-list a:hover { color: var(--gold-light); }
.info-card hr { border-color: rgba(255,255,255,0.18); }

/* ---------- Social ---------- */
.social-links { display: flex; gap: 0.6rem; flex-wrap: wrap; }
.social-btn {
  width: 42px; height: 42px;
  border-radius: 12px;
  display: inline-flex; align-items: center; justify-content: center;
  background: rgba(255,255,255,0.12);
  color: #fff;
  font-size: 1.15rem;
  transition: transform .2s ease, background .25s ease;
}
.social-btn:hover { transform: translateY(-3px); background: var(--gold); color: var(--green-dark); }
.social-btn-sm { width: 38px; height: 38px; font-size: 1rem; }

/* ---------- Footer ---------- */
.footer {
  background: #0c3f33;
  color: rgba(255,255,255,0.78);
  padding: 60px 0 26px;
}
.footer-name { color: #fff; font-size: 1.25rem; }
.footer-slogan { color: var(--gold-light); font-weight: 500; font-style: italic; margin-bottom: 0.6rem; }
.footer-text { font-size: 0.92rem; color: rgba(255,255,255,0.6); }
.footer-head { color: #fff; font-family: var(--font-body); font-weight: 600; font-size: 1rem; margin-bottom: 1rem; }
.footer-links li { margin-bottom: 0.6rem; }
.footer-links a { color: rgba(255,255,255,0.7); font-size: 0.92rem; display: inline-flex; align-items: center; gap: 0.45rem; }
.footer-links a:hover { color: var(--gold-light); }
.footer .social-btn { background: rgba(255,255,255,0.08); }
.footer-divider { border-color: rgba(255,255,255,0.12); margin: 2rem 0 1.2rem; }
.footer-copy { font-size: 0.85rem; color: rgba(255,255,255,0.55); }

/* ---------- Floating WhatsApp ---------- */
.whatsapp-float {
  position: fixed;
  right: 22px; bottom: 22px;
  width: 58px; height: 58px;
  border-radius: 50%;
  background: #25D366;
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.8rem;
  box-shadow: 0 10px 30px rgba(37,211,102,0.5);
  z-index: 1030;
  animation: pulse 2.4s infinite;
}
.whatsapp-float:hover { color: #fff; transform: scale(1.08); }
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(37,211,102,0.5); }
  70% { box-shadow: 0 0 0 16px rgba(37,211,102,0); }
  100% { box-shadow: 0 0 0 0 rgba(37,211,102,0); }
}

/* ---------- Scroll reveal ---------- */
.reveal { opacity: 0; transform: translateY(30px); transition: opacity .7s ease, transform .7s ease; }
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ---------- Responsive ---------- */
@media (max-width: 991.98px) {
  .mqa-navbar {
    background: rgba(250, 247, 242, 0.98);
    box-shadow: var(--shadow-sm);
  }
  .navbar-collapse {
    background: var(--white);
    margin-top: 0.6rem;
    border-radius: var(--radius-sm);
    padding: 1rem 1.2rem;
    box-shadow: var(--shadow-md);
  }
  .mqa-navbar .nav-link { margin: 0.2rem 0; }
  .hero { padding: 140px 0 70px; text-align: center; }
  .hero-subtitle { margin-left: auto; margin-right: auto; }
  .hero-cta, .hero-trust { justify-content: center; }
  .hero-card { margin-top: 1rem; }
}

@media (max-width: 575.98px) {
  .brand-name { font-size: 1rem; }
  .brand-tag { font-size: 0.62rem; }
  .section { padding: 64px 0; }
  .hero-card-inner, .contact-card, .info-card { padding: 1.5rem; }
  .btn-lg { padding: 0.8rem 1.5rem; font-size: 0.95rem; }
  .whatsapp-float { width: 52px; height: 52px; font-size: 1.6rem; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; scroll-behavior: auto !important; }
  .reveal { transition: none; opacity: 1; transform: none; }
}
