/* CSS Variables - Matching React Theme */
:root {
  --background: hsl(45, 100%, 65%);
  --foreground: hsl(0, 0%, 20%);
  
  --card: hsl(0, 0%, 100%);
  --card-foreground: hsl(0, 0%, 20%);
  
  --primary: hsl(330, 85%, 55%);
  --primary-foreground: hsl(0, 0%, 100%);
  
  --secondary: hsl(0, 0%, 100%);
  --secondary-foreground: hsl(0, 0%, 20%);
  
  --muted: hsl(45, 60%, 75%);
  --muted-foreground: hsl(0, 0%, 35%);
  
  --accent: hsl(160, 70%, 45%);
  --accent-foreground: hsl(0, 0%, 100%);
  
  --border: hsl(45, 40%, 55%);
  --input: hsl(0, 0%, 95%);
  --ring: hsl(330, 85%, 55%);
  
  --radius: 0.5rem;
}

/* Reset */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  border-color: var(--border);
}

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

body {
  font-family: Arial, Helvetica, sans-serif;
  background-color: var(--background);
  color: var(--foreground);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

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

.container-sm {
  max-width: 896px;
}

.container-md {
  max-width: 1024px;
}

.container-lg {
  max-width: 1280px;
}

/* Icons */
.icon {
  width: 1.25rem;
  height: 1.25rem;
  flex-shrink: 0;
}

.icon-lg {
  width: 1.75rem;
  height: 1.75rem;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.625rem 1rem;
  border-radius: var(--radius);
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  border: none;
  transition: all 0.2s;
  white-space: nowrap;
}

.btn-primary {
  background-color: var(--primary);
  color: var(--primary-foreground) !important;
}

.btn-primary:hover {
  opacity: 0.9;
}

.btn-lg {
  height: 2.75rem;
  padding: 0.5rem 3rem;
  font-size: 1rem;
}

.btn-ghost {
  background-color: transparent;
  color: var(--foreground);
}

.btn-ghost:hover {
  background-color: var(--muted);
}

.btn-sm {
  height: 2.25rem;
  padding: 0.375rem 0.75rem;
  font-size: 0.875rem;
}

/* Header */
.header {
  background-color: var(--secondary);
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--border);
  position: relative;
}

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

.logo {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary);
  text-decoration: none;
}

/* Navigation */
.nav-desktop {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.nav-desktop a {
  font-size: 0.875rem;
  color:hsl(0deg 0% 0%);
  opacity: 0.9;
  text-decoration: none;
  transition: opacity 0.2s;
}

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

.nav-mobile {
  display: none;
  align-items: center;
  gap: 0.75rem;
}

.hamburger-btn {
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Drawer */
.drawer-overlay {
  position: fixed;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.8);
  z-index: 50;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s;
}

.drawer-overlay.active {
  opacity: 1;
  visibility: visible;
}

/* Prevent any drawer/overlay flash during language (dir) switching */
html.drawer-freeze .drawer-overlay,
html.drawer-freeze .drawer {
  transition: none !important;
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

html.drawer-freeze .drawer {
  transform: translateX(100%) !important;
}

.drawer {
  position: fixed;
  top: 0;
  width: 18rem;
  height: 100%;
  background-color: var(--secondary);
  z-index: 50;
  padding: 1.5rem;
  transition: transform 0.5s ease-in-out, opacity 0.2s ease-in-out;
  box-shadow: -4px 0 20px rgba(0, 0, 0, 0.1);

  /* Keep the drawer on the right for BOTH languages.
     Otherwise, switching dir="rtl" ↔ dir="ltr" changes the base transform
     (100% -> -100%) and the transition animates it through the viewport. */
  right: 0;
  left: auto;
  transform: translateX(100%);

  /* Prevent any visual "flash" during dir (rtl/ltr) switching */
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.drawer.active {
  transform: translateX(0);
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.drawer-close {
  position: absolute;
  top: 1rem;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0.25rem;
  opacity: 0.7;
  transition: opacity 0.2s;

  /* Match the React sheet close button placement */
  right: 1rem;
  left: auto;
}

.drawer-close:hover {
  opacity: 1;
}



.drawer-nav {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-top: 2rem;
}

.drawer-nav a {
  font-size: 0.875rem;
  color: var(--foreground);
  text-decoration: none;
  padding: 0.5rem 0;
}

.drawer-nav a:hover {
  color: var(--primary);
}

.drawer-nav .btn {
  justify-content: flex-start;
}

/* Main Content */
.main-content {
  flex: 1;
}

/* Hero */
.hero {
  padding: 5rem 1.5rem;
  background-color: var(--background);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
  max-width: 1024px;
  margin: 0 auto;
}

.hero-title {
  font-size: 3rem;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 1.5rem;
}

.hero-subtitle {
  font-size: 1.125rem;
  color: var(--muted-foreground);
  margin-bottom: 2rem;
  line-height: 1.7;
}

.hero-card {
      border-radius: 1rem;
    padding: 0rem;
    text-align: center;
}

.hero-stat {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 0.5rem;
}

.hero-stat-label {
  color: var(--muted-foreground);
}

/* Features */
.features {
  background-color: var(--secondary);
  padding: 4rem 1.5rem;
}

.features-container {
  max-width: 896px;
  margin: 0 auto;
}

.features-list {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.feature-card {
  background-color: var(--card);
  border-radius: 0.75rem;
  padding: 1.5rem;
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  border: 1px solid var(--border);
  transition: box-shadow 0.2s;
}

.feature-card:hover {
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.feature-icon-wrapper {
  width: 3.5rem;
  height: 3.5rem;
  flex-shrink: 0;
  background-color: var(--accent);
  border-radius: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.feature-icon-wrapper svg {
  width: 1.75rem;
  height: 1.75rem;
  color: var(--accent-foreground);
  stroke-width: 1.5;
}

.feature-title {
  font-size: 1.125rem;
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.feature-desc {
  font-size: 0.875rem;
  color: var(--muted-foreground);
}

/* Steps */
.steps {
  padding: 4rem 1.5rem;
  background-color: var(--background);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.steps-container {
  max-width: 1024px;
  margin: 0 auto;
}

.steps-header {
  margin-bottom: 2.5rem;
}

.steps-title {
  font-size: 1.875rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
}

.steps-subtitle {
  color: var(--muted-foreground);
}

.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.step-card {
  background-color: var(--secondary);
  border-radius: 0.75rem;
  padding: 1.5rem;
  border-left: 4px solid var(--primary);
}

[dir="rtl"] .step-card {
  border-left: none;
  border-right: 4px solid var(--primary);
}

.step-number {
  font-size: 1.875rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 0.75rem;
}

.step-title {
  font-size: 1.125rem;
  font-weight: 600;
}

/* Contact */
.contact {
  padding: 4rem 1.5rem;
  background-color: var(--background);
}

.contact-container {
  max-width: 768px;
  margin: 0 auto;
  text-align: center;
}

.contact-title {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
}

.contact-box {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  background-color: var(--secondary);
  padding: 1rem 1.5rem;
  border-radius: 0.5rem;
  border: 1px solid var(--border);
}

.contact-box svg {
  width: 1.25rem;
  height: 1.25rem;
  color: var(--primary);
}

.contact-box a {
  font-weight: 500;
  color: var(--foreground);
  text-decoration: none;
  transition: color 0.2s;
}

.contact-box a:hover {
  color: var(--primary);
}

/* About */
.about-section {
  padding: 5rem 1.5rem;
  flex: 1;
}

.about-container {
  max-width: 1024px;
  margin: 0 auto;
}

.about-title {
  font-size: 2.5rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 3rem;
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}




.about-card {
      border-radius: 1rem;
    padding: 0rem;
    text-align: center;
}

.about-card-emoji {
  font-size: 3.75rem;
  margin-bottom: 1rem;
}

.about-card-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 0.25rem;
}

.about-card-subtitle {
  color: var(--muted-foreground);
}

.about-content {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.about-content p {
  line-height: 1.7;
}

.about-content p:first-child {
  font-size: 1.125rem;
  color: var(--foreground);
}

.about-content p:not(:first-child) {
  color: var(--muted-foreground);
}

/* Legal Pages */
.legal-section {
  padding: 5rem 1.5rem;
  flex: 1;
}

.legal-container {
  max-width: 1024px;
  margin: 0 auto;
}

.legal-section h1 {
  font-size: 2.5rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 2rem;
}

.legal-section p {
  color: var(--muted-foreground);
  max-width: 800px;
  margin: 0 auto;
  text-align: center;
  line-height: 1.7;
}

/* Footer */
.footer {
  background-color: var(--secondary);
  padding: 1.5rem;
  border-top: 1px solid var(--border);
  margin-top: auto;
}

.footer-content {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1.5rem;
  max-width: 896px;
  margin: 0 auto;
}

.footer-divider {
  color: var(--muted-foreground);
}

.footer a {
  font-size: 0.875rem;
  color: var(--muted-foreground);
  text-decoration: none;
  transition: color 0.2s;
}

.footer a:hover {
  color: var(--foreground);
}

/* Responsive */
@media (max-width: 768px) {
  .nav-desktop {
    display: none;
  }

  .nav-mobile {
    display: flex;
  }

  .hero-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .hero-title {
    font-size: 2.25rem;
  }

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

  .about-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }
}

/* Language Toggle Label */
.lang-toggle .lang-label {
  font-weight: 500;
}
