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

/* CSS Variables matching the app theme */
:root {
  --primary-green: #2E7D32;
  --light-green: #7CB342;
  --accent-green: #4CAF50;
  --background-color: #F1F8E9;
  --white-color: #FFFFFF;
  --text-dark: #1B5E20;
  --text-light: #4E7C59;
  --error-color: #D32F2F;
  --success-color: #388E3C;
  --shadow-light: rgba(46, 125, 50, 0.1);
  --shadow-medium: rgba(46, 125, 50, 0.3);
}

/* Reset and Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  direction: rtl;
  lang: ar;
}

body {
  font-family: 'Cairo', 'Segoe UI', sans-serif;
  background: linear-gradient(135deg, var(--background-color) 0%, var(--white-color) 100%);
  color: var(--text-dark);
  line-height: 1.6;
  min-height: 100vh;
}

/* Typography */
.arabic-text {
  text-align: right;
  direction: rtl;
}

h1 {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 1rem;
}

h2 {
  font-size: 2rem;
  font-weight: 600;
  color: var(--text-dark);
  margin-bottom: 0.8rem;
}

h3 {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--text-dark);
  margin-bottom: 0.6rem;
}

p {
  font-size: 1.1rem;
  color: var(--text-light);
  margin-bottom: 1rem;
  line-height: 1.8;
}

/* Layout */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

.section {
  padding: 4rem 0;
}

/* Header */
.header {
  background: linear-gradient(135deg, var(--primary-green), var(--light-green));
  box-shadow: 0 4px 20px var(--shadow-light);
  position: fixed;
  width: 100%;
  top: 0;
  z-index: 1000;
}

.nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 0;
}

.logo {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.logo img {
  width: 50px;
  height: 50px;
  background: var(--white-color);
  border-radius: 50%;
  padding: 8px;
  box-shadow: 0 4px 12px rgba(255, 255, 255, 0.3);
}

.logo-text {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--white-color);
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 2rem;
}

.nav-links a {
  color: var(--white-color);
  text-decoration: none;
  font-weight: 500;
  font-size: 1.1rem;
  transition: all 0.3s ease;
  padding: 0.5rem 1rem;
  border-radius: 8px;
}

.nav-links a:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

/* Hero Section */
.hero {
  padding: 8rem 0 4rem;
  text-align: center;
  background: linear-gradient(135deg, var(--background-color) 0%, rgba(241, 248, 233, 0.7) 50%, var(--white-color) 100%);
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="hearts" patternUnits="userSpaceOnUse" width="20" height="20"><path d="M10,6 C10,3 8,1 5.5,1 C3,1 1,3 1,6 C1,10 5.5,14 10,18 C14.5,14 19,10 19,6 C19,3 17,1 14.5,1 C12,1 10,3 10,6 Z" fill="rgba(46,125,50,0.05)" /></pattern></defs><rect width="100" height="100" fill="url(%23hearts)" /></svg>') repeat;
  z-index: 1;
}

.hero-content {
  max-width: 900px;
  margin: 0 auto;
  position: relative;
  z-index: 2;
}

.hero-visual {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 3rem;
  margin-bottom: 3rem;
  max-width: 1000px;
  margin-left: auto;
  margin-right: auto;
}

.hero-logo {
  width: 200px;
  height: 200px;
  background: var(--white-color);
  border-radius: 50%;
  padding: 30px;
  box-shadow: 0 20px 60px rgba(46, 125, 50, 0.2);
  display: block;
  margin: 0 auto;
  border: 8px solid rgba(124, 179, 66, 0.3);
  animation: float 3s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
}

.hero-decoration {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  opacity: 0.8;
}

.decoration-item {
  background: var(--white-color);
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 8px 24px rgba(46, 125, 50, 0.1);
  display: flex;
  align-items: center;
  gap: 1rem;
  animation: slideIn 1s ease-out;
}

.decoration-icon {
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, var(--primary-green), var(--accent-green));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white-color);
  font-size: 1.2rem;
}

@keyframes slideIn {
  from { opacity: 0; transform: translateX(50px); }
  to { opacity: 1; transform: translateX(0); }
}

.hero h1 {
  font-size: 4rem;
  margin-bottom: 1.5rem;
  background: linear-gradient(135deg, var(--primary-green), var(--accent-green));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 800;
  line-height: 1.2;
}

.hero-subtitle {
  font-size: 1.8rem;
  margin-bottom: 1rem;
  color: var(--text-dark);
  font-weight: 600;
}

.hero p {
  font-size: 1.2rem;
  margin-bottom: 2.5rem;
  color: var(--text-light);
  line-height: 1.8;
}

.hero-buttons {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 2rem;
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 1rem 2rem;
  background: linear-gradient(135deg, var(--primary-green), var(--accent-green));
  color: var(--white-color);
  text-decoration: none;
  border-radius: 16px;
  font-family: 'Cairo', sans-serif;
  font-weight: 600;
  font-size: 1.1rem;
  box-shadow: 0 8px 24px var(--shadow-medium);
  transition: all 0.3s ease;
  border: none;
  cursor: pointer;
  min-width: 200px;
}

.btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 32px var(--shadow-medium);
}

.btn-outline {
  background: transparent;
  border: 2px solid var(--primary-green);
  color: var(--primary-green);
}

.btn-outline:hover {
  background: var(--primary-green);
  color: var(--white-color);
}

/* Cards */
.card {
  background: var(--white-color);
  border-radius: 16px;
  padding: 2rem;
  box-shadow: 0 8px 32px var(--shadow-light);
  transition: all 0.3s ease;
  border: 1px solid rgba(124, 179, 66, 0.2);
}

.card:hover {
  transform: translateY(-8px);
  box-shadow: 0 16px 48px var(--shadow-medium);
}

/* Features Section */
.features {
  padding: 4rem 0;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.feature-icon {
  width: 60px;
  height: 60px;
  background: linear-gradient(135deg, var(--primary-green), var(--accent-green));
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
  color: var(--white-color);
  font-size: 1.5rem;
}

/* Forms */
.form-group {
  margin-bottom: 1.5rem;
}

.form-label {
  display: block;
  font-weight: 600;
  color: var(--text-dark);
  margin-bottom: 0.5rem;
  text-align: right;
}

.form-input {
  width: 100%;
  padding: 1rem;
  border: 2px solid rgba(124, 179, 66, 0.5);
  border-radius: 12px;
  font-size: 1rem;
  font-family: 'Cairo', sans-serif;
  background: var(--white-color);
  transition: all 0.3s ease;
  text-align: right;
  direction: rtl;
}

select.form-input {
  font-family: 'Cairo', sans-serif;
}

textarea.form-input {
  font-family: 'Cairo', sans-serif;
}

.form-input:focus {
  outline: none;
  border-color: var(--primary-green);
  box-shadow: 0 0 0 3px rgba(46, 125, 50, 0.1);
}

.form-textarea {
  min-height: 120px;
  resize: vertical;
}

/* Footer */
.footer {
  background: var(--primary-green);
  color: var(--white-color);
  text-align: center;
  padding: 3rem 0;
  margin-top: 4rem;
}

.footer p {
  color: rgba(255, 255, 255, 0.9);
}

/* Animations */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in-up {
  animation: fadeInUp 0.6s ease-out;
}

/* Mobile Menu */
.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  color: var(--white-color);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0.5rem;
}

@media (max-width: 768px) {
  .mobile-menu-btn {
    display: block;
  }

  .nav-links {
    position: absolute;
    top: 100%;
    right: 0;
    left: 0;
    background: linear-gradient(135deg, var(--primary-green), var(--light-green));
    flex-direction: column;
    padding: 1rem;
    transform: translateY(-100vh);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
  }

  .nav-links.active {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }

  .nav {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }

  .hero-visual {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .hero-decoration {
    order: -1;
    flex-direction: row;
    justify-content: center;
    flex-wrap: wrap;
  }

  .decoration-item {
    padding: 1rem;
    font-size: 0.9rem;
  }

  .hero-logo {
    width: 150px;
    height: 150px;
    padding: 20px;
  }

  .hero h1 {
    font-size: 2.5rem;
  }

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

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

  .container {
    padding: 0 1rem;
  }

  .features-grid {
    grid-template-columns: 1fr;
  }

  h1 {
    font-size: 2rem;
  }

  h2 {
    font-size: 1.5rem;
  }
}

@media (max-width: 480px) {
  .hero {
    padding: 6rem 0 2rem;
  }

  .hero h1 {
    font-size: 2rem;
  }

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

  .hero-decoration {
    display: none;
  }

  .hero-visual {
    grid-template-columns: 1fr;
  }

  .hero-logo {
    width: 120px;
    height: 120px;
    padding: 15px;
  }

  .btn {
    padding: 0.8rem 1.5rem;
    font-size: 1rem;
    min-width: 160px;
  }

  .hero-buttons {
    flex-direction: column;
    align-items: center;
  }
}

/* Utility Classes */
.text-center {
  text-align: center;
}

.text-right {
  text-align: right;
}

.mb-4 {
  margin-bottom: 2rem;
}

.mt-4 {
  margin-top: 2rem;
}

.hidden {
  display: none;
}

.visible {
  display: block;
}

/* Loading and Success States */
.loading {
  opacity: 0.7;
  pointer-events: none;
}

.success-message {
  background: var(--success-color);
  color: var(--white-color);
  padding: 1rem;
  border-radius: 12px;
  text-align: center;
  margin: 1rem 0;
}

.error-message {
  background: var(--error-color);
  color: var(--white-color);
  padding: 1rem;
  border-radius: 12px;
  text-align: center;
  margin: 1rem 0;
}

/* Accessibility */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Focus states for better accessibility */
.btn:focus,
.form-input:focus,
.nav-links a:focus {
  outline: 3px solid rgba(46, 125, 50, 0.5);
  outline-offset: 2px;
}