@import url('https://fonts.googleapis.com/css2?family=Baloo+Bhaijaan+2:wght@400;500;600;700&display=swap');

:root {
  --primary-green: #27ae60;
  --dark-green: #084a3b;
  --white: #ffffff;
  --light-gray: #f8f9fa;
  --text-dark: #1a1a1a;
  --text-muted: #6c757d;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  height: 100%;
}

body {
  font-family: 'Baloo Bhaijaan 2', 'SF Arabic', 'Segoe UI', system-ui, sans-serif;
  background-color: var(--white);
  color: var(--text-dark);
  line-height: 1.6;
}

/* Landing Page - Full Screen, No Scroll */
body.landing {
  overflow: hidden;
}

.hero {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background:
    linear-gradient(135deg, rgba(8, 74, 59, 0.93) 0%, rgba(39, 174, 96, 0.9) 100%),
    url('/images/pattern.png');
  background-size: cover;
  background-position: center;
  color: var(--white);
  padding: 20px;
  position: relative;
}

/* Minimal Landing Nav */
.landing-nav {
  position: absolute;
  top: 24px;
  left: 24px;
  right: 24px;
  display: flex;
  justify-content: center;
  gap: 32px;
}

[dir="rtl"] .landing-nav {
  flex-direction: row-reverse;
}

.landing-nav a {
  color: var(--white);
  text-decoration: none;
  font-size: 0.95rem;
  opacity: 0.85;
  transition: opacity 0.2s;
}

.landing-nav a:hover {
  opacity: 1;
}

/* Hero Content */
.hero-content {
  text-align: center;
  max-width: 500px;
}

.hero-icon {
  width: 120px;
  height: 120px;
  margin: 0 auto 24px;
}

.hero-icon img {
  width: 100%;
  height: 100%;
  border-radius: 26px;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.25);
}

.hero h1 {
  font-size: 3.5rem;
  font-weight: 700;
  margin-bottom: 8px;
  letter-spacing: -0.02em;
}

.hero .subtitle {
  font-size: 1.2rem;
  opacity: 0.9;
  margin-bottom: 36px;
}

/* Store Buttons */
.store-buttons {
  display: flex;
  gap: 16px;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
}

.store-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 40px;
  transition: transform 0.2s ease, opacity 0.2s;
}

.store-btn:hover {
  transform: scale(1.05);
}

.store-btn img {
  height: 40px;
  width: auto;
}

/* Google Play has built-in padding, scale to match visually */
.store-btn img[alt*="Google Play"] {
  height: 60px;
  margin: -10px 0;
}

/* Landing Footer */
.landing-footer {
  position: absolute;
  bottom: 24px;
  left: 0;
  right: 0;
  text-align: center;
}

.landing-footer p {
  font-size: 0.85rem;
  opacity: 0.6;
}

/* ========== Legal Pages ========== */

/* Minimal page navigation - matches landing nav */
.page-nav {
  background: var(--primary-green);
  padding: 16px 24px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 32px;
  position: sticky;
  top: 0;
  z-index: 100;
}

.page-nav a {
  color: var(--white);
  text-decoration: none;
  font-size: 0.95rem;
  opacity: 0.85;
  transition: opacity 0.2s;
}

.page-nav a:hover {
  opacity: 1;
}

/* Page footer */
.page-footer {
  background: var(--dark-green);
  padding: 24px;
  text-align: center;
}

.page-footer p {
  color: var(--white);
  opacity: 0.6;
  font-size: 0.85rem;
  margin: 0;
}

/* Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Legal Pages */
.legal-page {
  padding: 48px 0 80px;
  min-height: calc(100vh - 140px);
}

.legal-page h1 {
  color: var(--dark-green);
  font-size: 2.2rem;
  margin-bottom: 8px;
}

.legal-page .last-updated {
  color: var(--text-muted);
  margin-bottom: 40px;
  font-size: 0.9rem;
}

.legal-page h2 {
  color: var(--dark-green);
  font-size: 1.4rem;
  margin: 36px 0 14px;
  padding-top: 20px;
  border-top: 1px solid #eee;
}

.legal-page h2:first-of-type {
  border-top: none;
  padding-top: 0;
}

.legal-page p,
.legal-page li {
  color: var(--text-dark);
  margin-bottom: 14px;
  line-height: 1.8;
}

[dir="rtl"] .legal-page ul {
  padding-right: 24px;
  padding-left: 0;
}

[dir="ltr"] .legal-page ul {
  padding-left: 24px;
  padding-right: 0;
}

.legal-page li {
  margin-bottom: 8px;
}

/* Language Toggle */
.lang-toggle {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-bottom: 40px;
}

.lang-btn {
  padding: 10px 24px;
  border: 2px solid var(--primary-green);
  background: transparent;
  color: var(--primary-green);
  border-radius: 8px;
  cursor: pointer;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  transition: all 0.2s;
}

.lang-btn.active {
  background: var(--primary-green);
  color: var(--white);
}

.lang-btn:hover:not(.active) {
  background: rgba(39, 174, 96, 0.1);
}

.lang-content {
  display: none;
}

.lang-content.active {
  display: block;
}

/* Footer */
.footer {
  background: var(--dark-green);
  color: var(--white);
  padding: 32px 0;
  text-align: center;
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 32px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.footer-links a {
  color: var(--white);
  text-decoration: none;
  opacity: 0.85;
  font-size: 0.95rem;
  transition: opacity 0.2s;
}

.footer-links a:hover {
  opacity: 1;
}

.footer p {
  opacity: 0.6;
  font-size: 0.85rem;
}

/* RTL Support */
[dir="rtl"] {
  text-align: right;
}

[dir="ltr"] {
  text-align: left;
}

/* Responsive */
@media (max-width: 768px) {
  .hero h1 {
    font-size: 2.5rem;
  }

  .hero .subtitle {
    font-size: 1.1rem;
  }

  .hero-icon {
    width: 100px;
    height: 100px;
  }

  .store-buttons {
    flex-direction: column;
  }

  .landing-nav {
    gap: 24px;
  }

  .header .container,
  [dir="rtl"] .header .container {
    flex-direction: column;
    gap: 12px;
  }

  .nav-links,
  [dir="rtl"] .nav-links {
    flex-direction: row;
    gap: 16px;
  }

  .legal-page h1 {
    font-size: 1.75rem;
  }

  .footer-links {
    flex-direction: column;
    gap: 12px;
  }
}
