/* ---------- CSS Variables ---------- */
:root {
  --gradient: linear-gradient(135deg, #4f46e5, #9333ea);
  --primary-color: #4f46e5;
  --secondary-color: #9333ea;
  --text-dark: #f9fafb; /* Changed to light for dark mode */
  --text-light: #f9fafb;
  --text-muted: #a0aec0; /* A lighter grey for muted text */
  --background-light: #111827; /* Dark background */
  --background-alt: #1f2937;  /* Slightly lighter dark background */
  --border-light: #374151; /* Darker border color */
  --radius-small: 8px;
  --radius-medium: 14px;
  --radius-large: 20px;
  --space-unit: 4px;
  --max-w: 1240px;
  --shadow-subtle: 0 2px 8px rgba(0,0,0,.3);
  --shadow-medium: 0 6px 18px rgba(0,0,0,.4);
  --shadow-strong: 0 10px 25px rgba(0,0,0,.5);
  font-family: "Inter", "Roboto", system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.6;
}

/* ---------- Global Styles & Resets ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--text-dark);
  background-color: var(--background-light);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ---------- Layout ---------- */
.section {
  padding: calc(var(--space-unit) * 15) 1rem;
  max-width: var(--max-w);
  margin: auto;
  text-align: center;
}
.alt-bg { background-color: var(--background-alt); }
h1, h2, h3, h4 { font-weight: 700; margin: 0 0 calc(var(--space-unit) * 4); line-height: 1.3; }
h1 { font-size: 2.75rem; }
h2 { font-size: 2rem; margin-bottom: calc(var(--space-unit) * 10); }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.125rem; }
p { margin: 0 0 calc(var(--space-unit) * 6); color: var(--text-muted); }
.grid-3 { display: grid; gap: calc(var(--space-unit) * 6); grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }

/* ---------- Navbar ---------- */
.navbar {
  position: sticky; top: 0;
  background-color: rgba(17, 24, 39, 0.85); /* Dark transparent background */
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  z-index: 1000; border-bottom: 1px solid var(--border-light);
  transition: box-shadow 0.3s ease; width: 100%;
}
.navbar-content {
  display: flex; justify-content: space-between; align-items: center;
  padding: calc(var(--space-unit) * 4) calc(var(--space-unit) * 6);
  max-width: var(--max-w); margin: auto;
}
body.scrolled .navbar { box-shadow: var(--shadow-subtle); }
.navbar .logo { font-size: 1.75rem; font-weight: 700; text-decoration: none; color: var(--primary-color); }
.navbar #mainNav { display: flex; align-items: center; }
.navbar #mainNav a {
  margin-right: calc(var(--space-unit) * 5); text-decoration: none;
  color: var(--text-dark); font-weight: 500; position: relative;
  padding: calc(var(--space-unit) * 2) 0; transition: color 0.3s ease;
}
.navbar #mainNav a::after {
  content: ''; position: absolute; bottom: 0; left: 0;
  width: 0; height: 2px; background: var(--gradient);
  transition: width 0.3s ease;
}
.navbar #mainNav a:hover { color: var(--primary-color); }
.navbar #mainNav a:hover::after { width: 100%; }
.navbar #mainNav .nav-cta { margin-left: calc(var(--space-unit) * 3); }
#navToggle {
  display: none; background: none; border: none;
  font-size: 1.75rem; color: var(--text-dark); cursor: pointer;
  padding: calc(var(--space-unit) * 2);
}

/* ---------- Hero ---------- */
.hero {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-around;
  padding: calc(var(--space-unit) * 20) 1rem calc(var(--space-unit) * 15);
  color: var(--text-light); text-align: left; min-height: 80vh;
}
.hero-content { max-width: 560px; margin-bottom: calc(var(--space-unit) * 10); }
.hero h1 { font-size: 3.25rem; line-height: 1.2; margin-bottom: calc(var(--space-unit) * 5); }
.hero p { font-size: 1.125rem; color: rgba(249, 250, 251, 0.85); margin-bottom: calc(var(--space-unit) * 8); }
.hero .btn-primary { padding: calc(var(--space-unit) * 4) calc(var(--space-unit) * 8); font-size: 1.125rem; }
.hero-image-container { max-width: 420px; perspective: 1000px; }
.hero-image-container img {
  width: 100%; height: auto; border-radius: var(--radius-large);
  box-shadow: var(--shadow-strong);
  transition: transform 0.4s ease-out, box-shadow 0.4s ease-out;
}
.hero-image-container:hover img {
  transform: rotateY(5deg) rotateX(2deg) scale(1.03);
  box-shadow: 0 20px 40px rgba(0,0,0,.2);
}
.gradient-bg { background: var(--gradient); }

/* ---------- Cards ---------- */
.card {
  background: var(--background-alt); /* Changed for dark mode */
  padding: calc(var(--space-unit) * 7) calc(var(--space-unit) * 6);
  border-radius: var(--radius-medium); box-shadow: var(--shadow-medium);
  text-align: left; transition: transform 0.3s ease, box-shadow 0.3s ease;
  overflow: hidden; display: flex; flex-direction: column; align-items: flex-start;
  border: 1px solid var(--border-light);
}
.card:hover { transform: translateY(-8px); box-shadow: var(--shadow-strong); }

/* Material Symbols Styling */
.material-symbols-rounded {
  font-family: 'Material Symbols Rounded';
  font-weight: normal; font-style: normal; font-size: 24px;
  line-height: 1; letter-spacing: normal; text-transform: none;
  display: inline-block; white-space: nowrap; word-wrap: normal;
  direction: ltr; -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility; -moz-osx-font-smoothing: grayscale;
  font-feature-settings: 'liga';
}

.card .icon-feature {
  font-size: 2.8rem;
  margin-bottom: calc(var(--space-unit) * 4);
  color: var(--primary-color);
  line-height: 1;
}
.card h3 { margin-bottom: calc(var(--space-unit) * 3); color: var(--text-light); }

/* ---------- Pricing Cards ---------- */
.price-card {
  background: var(--background-alt); /* Changed for dark mode */
  padding: calc(var(--space-unit) * 8) calc(var(--space-unit) * 6);
  border-radius: var(--radius-large); box-shadow: var(--shadow-medium);
  display: flex; flex-direction: column; justify-content: space-between;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  position: relative; overflow: hidden;
  border: 1px solid var(--border-light);
}
.price-card:hover { transform: translateY(-8px) scale(1.02); box-shadow: var(--shadow-strong); }
.price-card.featured {
  background: var(--gradient); color: var(--text-light);
  transform: scale(1.05); box-shadow: var(--shadow-strong);
  border: none;
}
.price-card h3 { color: var(--text-light); }
.price-card.coming-soon { opacity: 0.65; }
.price-card.coming-soon .btn {
  background: #4B5563 !important; color: #9CA3AF !important;
  cursor: not-allowed !important; pointer-events: none; border: none !important;
}
.price-card.coming-soon .btn:hover { transform: none; box-shadow: none; }
.price-card .coming-soon-badge {
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%, -50%) rotate(-10deg);
  background-color: var(--secondary-color); color: var(--text-light);
  padding: calc(var(--space-unit) * 2.5) calc(var(--space-unit) * 5);
  border-radius: var(--radius-small); font-size: 1.1rem; font-weight: 700;
  text-align: center; z-index: 10; box-shadow: var(--shadow-medium); white-space: nowrap;
}
.price-card.featured.coming-soon .coming-soon-badge {
  background-color: var(--background-light); color: var(--primary-color);
}
.price-card.featured::before {
  content: "Most Popular"; position: absolute;
  top: calc(var(--space-unit) * 4); left: 50%; transform: translateX(-50%);
  background-color: var(--secondary-color); color: var(--text-light);
  padding: calc(var(--space-unit)*1.5) calc(var(--space-unit)*3);
  border-radius: var(--radius-small); font-size: 0.875rem; font-weight: 600; z-index: 5;
}
.price-card.featured.coming-soon::before { display: none; }
.price-card h3 { font-size: 1.75rem; }
.price-card.featured h3, .price-card.featured p, .price-card.featured .price { color: var(--text-light); }
.price {
  font-size: 2.5rem; font-weight: 700;
  margin: var(--space-unit) 0 calc(var(--space-unit) * 4);
  color: var(--primary-color);
}
.price-card.featured .price { color: var(--text-light); }
.price-card p { margin-bottom: calc(var(--space-unit) * 6); flex-grow: 1; }
.price-card .small {
  font-size: 0.875rem; color: var(--text-muted);
  margin-top: calc(var(--space-unit) * 5); text-align: center;
}
.price-card.featured .small { color: rgba(249, 250, 251, 0.85); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: calc(var(--space-unit) * 3) calc(var(--space-unit) * 6);
  border-radius: var(--radius-medium); font-weight: 600; text-decoration: none;
  border: none; cursor: pointer;
  transition: transform 0.2s ease, background-color 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
  text-align: center;
}
.btn:hover { transform: translateY(-2px); box-shadow: var(--shadow-medium); }
.btn-primary { background: var(--gradient); color: var(--text-light); }
.btn-primary:hover { background: linear-gradient(135deg, #5a52e8, #a042ed); box-shadow: var(--shadow-strong); }
.btn-secondary { background-color: var(--primary-color); color: var(--text-light); }
.btn-secondary:hover { background-color: var(--secondary-color); }
.price-card.featured .btn-primary { background: var(--background-light); color: var(--primary-color); }
.price-card.featured .btn-primary:hover { background: #E5E7EB; color: var(--secondary-color); }

/* ---------- Footer ---------- */
.footer {
  background: #111827; /* Darker footer background */
  color: #a0aec0;
  padding: calc(var(--space-unit) * 12) 1rem;
  font-size: 0.925rem; text-align: center;
  border-top: 1px solid var(--border-light);
}
.footer-content {
  display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-start;
  gap: calc(var(--space-unit) * 8); max-width: var(--max-w);
  margin: 0 auto calc(var(--space-unit) * 8); text-align: left;
}
.footer-column { flex: 1; min-width: 200px; }
.footer-column h4 { color: var(--text-light); margin-bottom: calc(var(--space-unit) * 4); font-size: 1.1rem; }
.footer-column p, .footer-column ul { margin-bottom: calc(var(--space-unit) * 3); }
.footer-column ul { list-style: none; padding: 0; }
.footer-column ul li { margin-bottom: calc(var(--space-unit) * 2); }
.footer a { color: var(--primary-color); text-decoration: none; transition: color 0.3s ease; }
.footer a:hover { color: var(--secondary-color); text-decoration: underline; }
.footer .copyright {
  margin-top: calc(var(--space-unit) * 10); padding-top: calc(var(--space-unit) * 6);
  border-top: 1px solid #4a5568; font-size: 0.875rem; color: #718096;
  text-align: center; width: 100%;
}

/* ---------- Responsive ---------- */
@media (max-width: 768px) {
  h1 { font-size: 2.5rem; }
  .hero h1 { font-size: 2.75rem; }
  .hero { text-align: center; padding-top: calc(var(--space-unit) * 12); padding-bottom: calc(var(--space-unit) * 10); }
  .hero-content { margin-right: 0; max-width: 100%; }
  .hero-image-container { margin: calc(var(--space-unit) * 10) auto 0; }
  .footer-content { flex-direction: column; align-items: center; text-align: center; }
  .footer-column { width: 100%; max-width: 350px; margin-bottom: calc(var(--space-unit) * 6); }
}
@media (max-width: 640px) {
  .navbar-content { padding: calc(var(--space-unit) * 3) calc(var(--space-unit) * 4); }
  #navToggle { display: block; }
  .navbar #mainNav {
    display: none; flex-direction: column; position: absolute;
    top: 100%; left: 0; width: 100%;
    background: var(--background-alt); /* Mobile nav dark background */
    box-shadow: var(--shadow-medium);
    padding: calc(var(--space-unit) * 4) 0; border-top: 1px solid var(--border-light);
  }
  .navbar #mainNav.open { display: flex; animation: slideDownMobileNav 0.3s ease-out forwards; }
  @keyframes slideDownMobileNav { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: translateY(0); } }
  .navbar #mainNav a { margin: calc(var(--space-unit) * 3) calc(var(--space-unit) * 6); text-align: center; width: calc(100% - (var(--space-unit) * 12)); }
  .navbar #mainNav a::after { display: none; }
  .navbar #mainNav .nav-cta { margin: calc(var(--space-unit) * 3) calc(var(--space-unit) * 6); width: calc(100% - (var(--space-unit) * 12)); }
  .navbar #mainNav .nav-cta .btn { display: block; width: 100%; }
  .grid-3 { grid-template-columns: 1fr; }
}

/* Legal pages specific styles */
.legal-section {
  padding: calc(var(--space-unit)*10) 1rem; max-width: 800px;
  margin: calc(var(--space-unit)*10) auto; background-color: var(--background-alt);
  border-radius: var(--radius-medium); box-shadow: var(--shadow-medium); text-align: left;
  border: 1px solid var(--border-light);
}
.legal-section h1 { font-size: 2rem; margin-bottom: calc(var(--space-unit)*8); color: var(--primary-color); }
.legal-section h2 {
  font-size: 1.5rem; margin-top: calc(var(--space-unit)*8); margin-bottom: calc(var(--space-unit)*3);
  color: var(--text-dark); border-bottom: 1px solid var(--border-light); padding-bottom: var(--space-unit);
}
.legal-section p, .legal-section ul { margin-bottom: calc(var(--space-unit)*4); line-height: 1.7; }
.legal-section ul { padding-left: calc(var(--space-unit)*5); }
.legal-section a { color: var(--primary-color); text-decoration: none; font-weight: 500; }
.legal-section a:hover { text-decoration: underline; color: var(--secondary-color); }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border-width: 0;
}
.legal-section table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: calc(var(--space-unit)*4);
    font-size: 0.9em;
}
.legal-section th, .legal-section td {
    border: 1px solid var(--border-light);
    padding: calc(var(--space-unit)*2);
    text-align: left;
}
.legal-section th {
    background-color: var(--background-light);
}

/* ---------- Feature Showcase (New Section) ---------- */
.feature-showcase {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--space-unit) * 10);
  margin-bottom: calc(var(--space-unit) * 20);
  text-align: left;
}
.feature-showcase:last-child {
  margin-bottom: 0;
}
.feature-showcase .text-content {
  flex: 1;
  min-width: 300px;
}
.feature-showcase .text-content h3 {
  font-size: 1.8rem;
  color: var(--text-light);
  margin-bottom: calc(var(--space-unit) * 4);
}
.feature-showcase .image-content {
  flex: 1.2;
  min-width: 300px;
  max-width: 550px; /* --- FIX for large screens --- */
  margin: 0 auto;    /* --- Helps center the image in its column --- */
}
.feature-showcase .image-content img {
  width: 100%;
  border-radius: var(--radius-medium);
  box-shadow: var(--shadow-strong);
}

/* Alternating layout for even-numbered features */
.feature-showcase:nth-child(even) {
  flex-direction: row-reverse;
}

@media (max-width: 768px) {
  .feature-showcase,
  .feature-showcase:nth-child(even) {
    flex-direction: column;
    text-align: center;
  }
  .feature-showcase .text-content {
    margin-bottom: calc(var(--space-unit) * 8);
  }
}