/* ===========================
   Hidayah – Shared Styles
   Theme: Dark Gold (matches app)
   =========================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

/* ── Reset & Root ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:         #0D0F1A;
  --bg2:        #111423;
  --surface:    #1A1D2E;
  --surface2:   #22253A;
  --gold:       #C9A84C;
  --gold-light: #E8C97A;
  --gold-dim:   rgba(201,168,76,0.12);
  --gold-dim2:  rgba(201,168,76,0.22);
  --blue:       #3A7BD5;
  --green:      #4CAF50;
  --text:       #FFFFFF;
  --text2:      #C5C8D8;
  --text3:      #8B8FA8;
  --border:     rgba(201,168,76,0.15);
  --border2:    rgba(255,255,255,0.07);
  --radius:     16px;
  --radius-sm:  10px;
  --radius-lg:  24px;
  --shadow:     0 8px 32px rgba(0,0,0,0.5);
  --shadow-gold:0 4px 24px rgba(201,168,76,0.18);
  --font:       'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

html { scroll-behavior: smooth; font-size: 16px; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: var(--gold); text-decoration: none; transition: color .2s; }
a:hover { color: var(--gold-light); }
img { max-width: 100%; display: block; }

/* ── Typography ── */
h1, h2, h3, h4 { font-weight: 700; line-height: 1.2; }
h1 { font-size: clamp(2rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.5rem, 3.5vw, 2.5rem); }
h3 { font-size: 1.25rem; }
p  { color: var(--text2); }

.gold { color: var(--gold); }
.gradient-text {
  background: linear-gradient(135deg, var(--gold), var(--gold-light));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── Layout ── */
.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}

section { padding: 80px 0; }

/* ── Navbar ── */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  padding: 16px 0;
  background: rgba(13,15,26,0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border2);
  transition: background .3s;
}
.navbar.scrolled { background: rgba(13,15,26,0.97); }

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.2rem;
  color: var(--text);
}
.nav-logo .logo-icon {
  width: 36px; height: 36px;
  background: linear-gradient(135deg, var(--gold), #A07830);
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
}
.nav-links a {
  color: var(--text2);
  font-size: .93rem;
  font-weight: 500;
  transition: color .2s;
}
.nav-links a:hover { color: var(--gold); }

.nav-cta {
  background: linear-gradient(135deg, var(--gold), #A07830);
  color: #0D0F1A !important;
  padding: 9px 22px;
  border-radius: 50px;
  font-weight: 700 !important;
  font-size: .88rem !important;
  transition: transform .2s, box-shadow .2s !important;
}
.nav-cta:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-gold);
  color: #0D0F1A !important;
}

.nav-hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 6px;
  background: none;
  border: none;
}
.nav-hamburger span {
  display: block;
  width: 24px; height: 2px;
  background: var(--text2);
  border-radius: 2px;
  transition: .3s;
}

/* ── Mobile Nav ── */
.mobile-nav {
  display: none;
  flex-direction: column;
  gap: 0;
  background: var(--bg2);
  border-bottom: 1px solid var(--border2);
  overflow: hidden;
  max-height: 0;
  transition: max-height .35s ease;
}
.mobile-nav.open { max-height: 400px; }
.mobile-nav a {
  padding: 14px 24px;
  color: var(--text2);
  font-size: 1rem;
  border-bottom: 1px solid var(--border2);
  transition: background .2s;
}
.mobile-nav a:hover, .mobile-nav a:last-child { background: var(--surface); }

/* ── Hero ── */
.hero {
  padding-top: 120px;
  padding-bottom: 80px;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  top: -200px; left: 50%;
  transform: translateX(-50%);
  width: 900px; height: 900px;
  background: radial-gradient(ellipse, rgba(201,168,76,0.06) 0%, transparent 70%);
  pointer-events: none;
}

.hero .container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 60px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--gold-dim);
  border: 1px solid var(--border);
  color: var(--gold);
  padding: 6px 16px;
  border-radius: 50px;
  font-size: .82rem;
  font-weight: 600;
  margin-bottom: 20px;
  letter-spacing: .03em;
}
.hero-badge span { font-size: 1rem; }

.hero-title {
  margin-bottom: 18px;
  letter-spacing: -.02em;
}

.hero-sub {
  font-size: 1.08rem;
  color: var(--text2);
  max-width: 480px;
  margin-bottom: 36px;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: linear-gradient(135deg, var(--gold), #A07830);
  color: #0D0F1A;
  padding: 14px 28px;
  border-radius: 50px;
  font-weight: 700;
  font-size: 1rem;
  transition: transform .2s, box-shadow .2s;
  box-shadow: 0 4px 20px rgba(201,168,76,0.25);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(201,168,76,0.35);
  color: #0D0F1A;
}
.btn-primary svg { width: 22px; height: 22px; fill: #0D0F1A; }

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border2);
  padding: 14px 28px;
  border-radius: 50px;
  font-weight: 600;
  font-size: .95rem;
  transition: background .2s, border-color .2s;
}
.btn-secondary:hover {
  background: var(--surface2);
  border-color: var(--border);
  color: var(--text);
}

.hero-stats {
  display: flex;
  gap: 32px;
  margin-top: 44px;
  padding-top: 32px;
  border-top: 1px solid var(--border2);
}
.stat-item { display: flex; flex-direction: column; gap: 2px; }
.stat-num {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--gold);
  line-height: 1;
}
.stat-label { font-size: .78rem; color: var(--text3); text-transform: uppercase; letter-spacing: .06em; }

/* Phone mockup */
.hero-visual {
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
}

.phone-frame {
  width: 260px;
  height: 530px;
  background: linear-gradient(160deg, #1E2235, #141726);
  border-radius: 44px;
  border: 2px solid rgba(201,168,76,0.3);
  box-shadow:
    0 0 0 8px rgba(201,168,76,0.04),
    0 40px 80px rgba(0,0,0,0.6),
    inset 0 1px 0 rgba(255,255,255,0.08);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.phone-notch {
  width: 100px; height: 26px;
  background: #0D0F1A;
  border-radius: 0 0 20px 20px;
  margin: 0 auto;
  flex-shrink: 0;
}
.phone-screen {
  flex: 1;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  overflow: hidden;
}

.mock-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 4px 0;
}
.mock-title {
  display: flex; align-items: center; gap: 8px;
  font-size: .72rem; font-weight: 700;
}
.mock-title .icon { font-size: .85rem; }
.mock-badge {
  background: linear-gradient(135deg, var(--gold), #A07830);
  color: #0D0F1A;
  font-size: .55rem; font-weight: 700;
  padding: 3px 9px; border-radius: 50px;
}

.mock-card {
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 14px;
  padding: 12px;
}
.mock-card-title {
  font-size: .62rem; font-weight: 600;
  color: var(--text2); margin-bottom: 6px;
}
.mock-prayer-time {
  font-size: 1.3rem; font-weight: 800;
  color: var(--gold); text-align: center;
  padding: 4px 0;
}
.mock-prayer-label {
  font-size: .58rem; color: var(--text3);
  text-align: center; margin-top: 2px;
}
.mock-row {
  display: flex; justify-content: space-between;
  margin-top: 8px;
}
.mock-cell {
  text-align: center;
}
.mock-cell .time { font-size: .65rem; font-weight: 600; color: var(--text); }
.mock-cell .lbl { font-size: .5rem; color: var(--text3); }

.mock-quran {
  background: linear-gradient(135deg, rgba(201,168,76,0.12), rgba(201,168,76,0.05));
  border: 1px solid rgba(201,168,76,0.2);
  border-radius: 14px;
  padding: 12px;
  text-align: center;
}
.mock-arabic {
  font-size: .78rem; color: var(--gold-light);
  font-family: 'Noto Naskh Arabic', serif;
  line-height: 1.8;
  direction: rtl;
}
.mock-trans { font-size: .52rem; color: var(--text3); margin-top: 4px; font-style: italic; }

.mock-tabs {
  display: flex; gap: 6px; margin-top: auto;
  padding-top: 6px; border-top: 1px solid rgba(255,255,255,0.06);
}
.mock-tab {
  flex: 1; text-align: center;
  font-size: .45rem; color: var(--text3); padding: 4px 0;
}
.mock-tab.active { color: var(--gold); font-weight: 600; }

/* Glow behind phone */
.phone-glow {
  position: absolute;
  width: 300px; height: 300px;
  background: radial-gradient(ellipse, rgba(201,168,76,0.15) 0%, transparent 70%);
  z-index: -1;
}

/* ── Features Section ── */
.features { background: var(--bg2); }

.section-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--gold);
  font-size: .82rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: 12px;
}
.section-label::before {
  content: '';
  display: block;
  width: 24px; height: 2px;
  background: var(--gold);
  border-radius: 2px;
}

.section-header { margin-bottom: 56px; }
.section-header h2 { margin-bottom: 12px; }
.section-header p { color: var(--text3); max-width: 500px; }

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 20px;
}

.feature-card {
  background: var(--surface);
  border: 1px solid var(--border2);
  border-radius: var(--radius);
  padding: 28px 24px;
  transition: transform .25s, border-color .25s, box-shadow .25s;
  position: relative;
  overflow: hidden;
}
.feature-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
  opacity: 0;
  transition: opacity .3s;
}
.feature-card:hover {
  transform: translateY(-4px);
  border-color: var(--border);
  box-shadow: 0 12px 40px rgba(0,0,0,0.35), 0 0 0 1px rgba(201,168,76,0.1);
}
.feature-card:hover::before { opacity: 1; }

.feature-icon {
  font-size: 2rem;
  margin-bottom: 14px;
  display: block;
}
.feature-card h3 {
  font-size: 1.05rem;
  margin-bottom: 8px;
}
.feature-card p {
  font-size: .88rem;
  line-height: 1.55;
  color: var(--text3);
}

/* ── CTA Banner ── */
.cta-section {
  background: linear-gradient(135deg, #1A1520 0%, #0D0F1A 50%, #1A1520 100%);
  border-top: 1px solid var(--border2);
  border-bottom: 1px solid var(--border2);
  text-align: center;
  position: relative;
  overflow: hidden;
}
.cta-section::before {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 600px; height: 600px;
  background: radial-gradient(ellipse, rgba(201,168,76,0.07) 0%, transparent 65%);
  pointer-events: none;
}
.cta-section h2 { margin-bottom: 14px; }
.cta-section p { color: var(--text3); max-width: 480px; margin: 0 auto 36px; }
.cta-actions { display: flex; justify-content: center; gap: 16px; flex-wrap: wrap; }

/* ── Footer ── */
.footer {
  padding: 48px 0 32px;
  border-top: 1px solid var(--border2);
  background: var(--bg);
}
.footer .container {
  display: flex;
  flex-direction: column;
  gap: 28px;
}
.footer-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 24px;
}
.footer-brand p {
  font-size: .875rem;
  color: var(--text3);
  max-width: 280px;
  margin-top: 10px;
  line-height: 1.6;
}
.footer-links {
  display: flex;
  gap: 48px;
  flex-wrap: wrap;
}
.footer-col h4 {
  font-size: .75rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--text3);
  margin-bottom: 14px;
  font-weight: 600;
}
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.footer-col ul a {
  color: var(--text2);
  font-size: .88rem;
  transition: color .2s;
}
.footer-col ul a:hover { color: var(--gold); }

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 24px;
  border-top: 1px solid var(--border2);
  font-size: .82rem;
  color: var(--text3);
}
.footer-bottom a { color: var(--text3); }
.footer-bottom a:hover { color: var(--gold); }

/* ── Legal Pages ── */
.legal-page { padding-top: 100px; }
.legal-header {
  padding: 60px 0 40px;
  border-bottom: 1px solid var(--border2);
  margin-bottom: 0;
}
.legal-header .badge {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--gold-dim); border: 1px solid var(--border);
  color: var(--gold); padding: 5px 14px;
  border-radius: 50px; font-size: .78rem; font-weight: 600;
  margin-bottom: 16px;
}
.legal-header h1 { margin-bottom: 8px; font-size: clamp(1.6rem, 4vw, 2.4rem); }
.legal-header p { color: var(--text3); font-size: .9rem; }

.legal-body {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 48px;
  padding: 48px 0 80px;
  align-items: start;
}

.legal-toc {
  position: sticky;
  top: 90px;
  background: var(--surface);
  border: 1px solid var(--border2);
  border-radius: var(--radius);
  padding: 20px;
}
.legal-toc h4 {
  font-size: .75rem; text-transform: uppercase;
  letter-spacing: .08em; color: var(--text3);
  margin-bottom: 14px; font-weight: 600;
}
.legal-toc ul { list-style: none; display: flex; flex-direction: column; gap: 6px; }
.legal-toc ul a {
  color: var(--text3); font-size: .83rem;
  padding: 4px 8px; border-radius: 6px;
  display: block; transition: background .2s, color .2s;
}
.legal-toc ul a:hover { background: var(--surface2); color: var(--gold); }

.legal-content { min-width: 0; }
.legal-content section {
  padding: 0 0 48px;
  border-bottom: 1px solid var(--border2);
  margin-bottom: 0;
}
.legal-content section:last-child { border-bottom: none; padding-bottom: 0; }
.legal-content h2 {
  font-size: 1.3rem; margin-bottom: 14px;
  color: var(--text); padding-top: 8px;
}
.legal-content h3 { font-size: 1rem; color: var(--text2); margin: 20px 0 8px; }
.legal-content p { color: var(--text2); margin-bottom: 14px; font-size: .93rem; line-height: 1.75; }
.legal-content ul {
  list-style: none; display: flex; flex-direction: column; gap: 8px;
  margin-bottom: 14px; padding-left: 4px;
}
.legal-content ul li {
  color: var(--text2); font-size: .93rem; line-height: 1.65;
  padding-left: 20px; position: relative;
}
.legal-content ul li::before {
  content: '▸';
  position: absolute; left: 0;
  color: var(--gold); font-size: .7rem; top: 4px;
}

.info-box {
  background: var(--gold-dim);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  margin: 16px 0;
  display: flex; gap: 12px; align-items: flex-start;
}
.info-box .icon { font-size: 1.1rem; flex-shrink: 0; margin-top: 1px; }
.info-box p { margin: 0; color: var(--text2); font-size: .88rem; }

.contact-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  display: flex; align-items: center; gap: 16px;
  margin-top: 16px;
}
.contact-card .mail-icon {
  width: 44px; height: 44px;
  background: var(--gold-dim2);
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.3rem;
  flex-shrink: 0;
}
.contact-card h4 { font-size: .9rem; margin-bottom: 4px; }
.contact-card a { color: var(--gold); font-size: .9rem; }

/* ── Scroll progress bar ── */
#scroll-progress {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--gold), var(--gold-light));
  transform-origin: left;
  transform: scaleX(0);
  z-index: 9999;
  transition: transform .1s linear;
}

/* ── Utility ── */
.text-center { text-align: center; }
.mt-4 { margin-top: 16px; }
.mt-8 { margin-top: 32px; }

/* ── Animations ── */
.fade-up {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .6s ease, transform .6s ease;
}
.fade-up.visible { opacity: 1; transform: translateY(0); }

/* ── Responsive ── */
@media (max-width: 900px) {
  .hero .container { grid-template-columns: 1fr; text-align: center; gap: 48px; }
  .hero-sub { margin: 0 auto 36px; }
  .hero-actions { justify-content: center; }
  .hero-stats { justify-content: center; }
  .hero-visual { order: -1; }
  .phone-frame { width: 220px; height: 450px; }

  .legal-body { grid-template-columns: 1fr; }
  .legal-toc { position: static; }

  .footer-top { flex-direction: column; }
}

@media (max-width: 640px) {
  .nav-links { display: none; }
  .nav-hamburger { display: flex; }
  .mobile-nav { display: flex; }

  section { padding: 60px 0; }
  .features-grid { grid-template-columns: 1fr; }

  .hero-stats { gap: 24px; }
  .footer-links { gap: 32px; }
  .footer-bottom { flex-direction: column; text-align: center; gap: 8px; }
}
