/* ===== GrepSys Modern Theme ===== */

:root {
  --bg-dark: #0a1628;
  --bg-card: rgba(15, 23, 42, 0.9);
  --bg-header: rgba(255, 255, 255, 0.98);
  
  --text-primary: #e5e7eb;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  
  /* Header specific text colors */
  --text-nav: #334155;
  --text-nav-hover: #0f172a;
  
  /* Green Palette (Professional) */
  --accent: #16a34a;       /* Green 600 */
  --accent-light: #22c55e; /* Green 500 */
  --accent-dark: #15803d;  /* Green 700 */
  
  --accent-glow: rgba(22, 163, 74, 0.4);
  
  --border-color: rgba(148, 163, 184, 0.25);
  --border-accent: rgba(34, 197, 94, 0.4);
  
  --shadow-card: 0 20px 50px rgba(0, 0, 0, 0.4);
  
  --radius-sm: 0.5rem;
  --radius-md: 0.75rem;
  --radius-lg: 1rem;
  --radius-full: 999px;
  --max-width: 1200px;
}

* {
  box-sizing: border-box;
}

body {
  font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  margin: 0;
  padding: 0;
  line-height: 1.6;
  background: var(--bg-dark);
  color: var(--text-primary);
  font-size: 16px;
}

a {
  color: var(--accent-light);
  text-decoration: none;
  transition: color 0.2s;
}

a:hover {
  color: #6ee7b7; /* Emerald 300 */
}

h1, h2, h3, h4, h5, h6 {
  margin: 0 0 1rem;
  line-height: 1.2;
}

p {
  margin: 0 0 1rem;
}

img {
  max-width: 100%;
  height: auto;
}

/* ===== Header & Navigation ===== */
.site-header {
  background: var(--bg-header);
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid rgba(226, 232, 240, 0.8);
  backdrop-filter: blur(12px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0.75rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

.site-logo img {
  height: 38px;
  width: auto;
  display: block;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.site-nav a,
.nav-dropdown > span {
  padding: 0.5rem 0.9rem;
  font-size: 0.9rem;
  color: var(--text-nav);
  font-weight: 500;
  border-radius: var(--radius-sm);
  transition: color 0.2s, background 0.2s;
  cursor: pointer;
}

.site-nav a:hover,
.nav-dropdown:hover > span {
  color: var(--accent-dark);
  background: rgba(0, 0, 0, 0.05);
}

.site-nav a.active {
  color: var(--accent-dark);
  background: rgba(16, 185, 129, 0.1);
}

.nav-dropdown {
  position: relative;
}

.nav-dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 200px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: var(--radius-md);
  padding: 0.5rem 0;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.nav-dropdown:hover .nav-dropdown-menu {
  display: block;
}

.nav-dropdown-menu a {
  display: block;
  padding: 0.6rem 1rem;
  font-size: 0.85rem;
  color: var(--text-nav);
}

.nav-dropdown-menu a:hover {
  background: #f8fafc;
  color: var(--accent-dark);
}

.header-cta {
  display: flex;
  gap: 0.75rem;
}

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.65rem 1.3rem;
  border-radius: var(--radius-full);
  font-weight: 600;
  font-size: 0.9rem;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  color: #fff;
  /* box-shadow: 0 4px 12px var(--accent-glow); */
}

.btn-primary:hover {
  background: linear-gradient(135deg, var(--accent-dark), #047857);
  transform: translateY(-1px);
  /* box-shadow: 0 6px 16px var(--accent-glow); */
  color: #fff;
}

.btn-secondary {
  background: transparent;
  color: var(--text-primary);
  border-color: var(--border-color);
}

.btn-secondary:hover {
  background: rgba(255,255,255,0.05);
  border-color: var(--text-secondary);
}

.btn-outline {
  background: transparent;
  color: var(--accent-light);
  border-color: var(--accent);
}

.btn-outline:hover {
  background: var(--accent);
  color: #fff;
}

.btn-lg {
  padding: 0.85rem 1.8rem;
  font-size: 1rem;
}

/* ===== Layout ===== */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section {
  padding: 5rem 1.5rem;
}

.section-sm {
  padding: 3rem 1.5rem;
}

.section-alt {
  background: radial-gradient(ellipse at top left, rgba(52, 211, 153, 0.06), transparent 50%),
              radial-gradient(ellipse at bottom right, rgba(5, 150, 105, 0.08), transparent 50%);
}

.section-header {
  max-width: 720px;
  margin-bottom: 3rem;
}

.section-header.center {
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.section-title {
  font-size: 2.25rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

.section-subtitle {
  font-size: 1.1rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* ===== Hero ===== */
.hero {
  padding: 6rem 1.5rem 5rem;
  background: radial-gradient(ellipse at top left, rgba(52, 211, 153, 0.15), transparent 50%),
              radial-gradient(ellipse at bottom right, rgba(5, 150, 105, 0.2), var(--bg-dark) 70%);
}

.hero-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 3rem;
  align-items: center;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0.9rem;
  background: rgba(5, 150, 105, 0.15);
  border: 1px solid var(--border-accent);
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  color: var(--accent-light);
  margin-bottom: 1.25rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.hero-title {
  font-size: 3rem;
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 1.25rem;
}

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

.hero-subtitle {
  font-size: 1.15rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 1.5rem;
  max-width: 540px;
}

.hero-features {
  list-style: none;
  padding: 0;
  margin: 0 0 2rem;
}

.hero-features li {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 0.6rem;
  color: var(--text-secondary);
}

.hero-features li::before {
  content: "✓";
  color: var(--accent-light);
  font-weight: 700;
}

.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
}

.hero-visual {
  display: flex;
  justify-content: center;
}

.hero-cards {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  width: 100%;
  max-width: 380px;
}

.hero-card {
  background: linear-gradient(135deg, rgba(5, 150, 105, 0.25), rgba(52, 211, 153, 0.1));
  border: 1px solid var(--border-accent);
  border-radius: var(--radius-lg);
  padding: 1.25rem 1.5rem;
  box-shadow: 0 20px 50px rgba(2, 44, 34, 0.5);
  transition: transform 0.2s;
}

.hero-card:hover {
  transform: translateY(-2px);
}

.hero-card h3 {
  font-size: 1rem;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
}

.hero-card p {
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin: 0;
}

/* ===== Grid ===== */
.grid {
  display: grid;
  gap: 1.5rem;
}

.grid-2 {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.grid-3 {
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.grid-4 {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

/* ===== Cards ===== */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  box-shadow: var(--shadow-card);
  transition: transform 0.2s, border-color 0.2s;
}

.card:hover {
  transform: translateY(-4px);
  border-color: var(--border-accent);
}

.card-icon {
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
  font-size: 1.5rem;
  color: white;
  box-shadow: 0 8px 20px rgba(16, 185, 129, 0.3);
}

.card h3 {
  font-size: 1.15rem;
  margin-bottom: 0.75rem;
}

.card p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  margin: 0;
}

.card-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin-top: 1rem;
  font-size: 0.9rem;
  color: var(--accent-light);
  font-weight: 500;
}

.card-link:hover {
  gap: 0.6rem;
}

/* Product Card */
.product-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 2rem;
  text-align: center;
  transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s;
}

.product-card:hover {
  transform: translateY(-6px);
  border-color: var(--border-accent);
  box-shadow: 0 25px 60px rgba(16, 185, 129, 0.15);
}

.product-card h3 {
  font-size: 1.35rem;
  margin-bottom: 0.75rem;
}

.product-card p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  margin-bottom: 1.25rem;
}

/* ===== Feature List ===== */
.feature-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.feature-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.6rem 0;
  border-bottom: 1px solid var(--border-color);
}

.feature-list li:last-child {
  border-bottom: none;
}

.feature-list li::before {
  content: "✓";
  color: var(--accent-light);
  font-weight: 700;
  flex-shrink: 0;
}

/* ===== Stats ===== */
.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 2rem;
  text-align: center;
}

.stat-item h3 {
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--accent-light);
  margin-bottom: 0.25rem;
}

.stat-item p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin: 0;
}

/* ===== CTA Section ===== */
.cta-section {
  background: linear-gradient(135deg, rgba(5, 150, 105, 0.15), rgba(52, 211, 153, 0.08));
  border: 1px solid var(--border-accent);
  border-radius: var(--radius-lg);
  padding: 3rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  box-shadow: 0 0 40px rgba(16, 185, 129, 0.1);
}

.cta-section h2 {
  font-size: 1.75rem;
  margin-bottom: 0.5rem;
}

.cta-section p {
  color: var(--text-secondary);
  margin: 0;
  max-width: 500px;
}

.cta-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

/* ===== Page Header ===== */
.page-header {
  padding: 4rem 1.5rem 3rem;
  background: radial-gradient(ellipse at top, rgba(52, 211, 153, 0.1), transparent 60%);
  text-align: center;
}

.page-header h1 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.page-header p {
  font-size: 1.1rem;
  color: var(--text-secondary);
  max-width: 640px;
  margin: 0 auto;
}

/* ===== Two Column Layout ===== */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}

.two-col.reverse {
  direction: rtl;
}

.two-col.reverse > * {
  direction: ltr;
}

/* ===== Footer ===== */
.site-footer {
  background: #020617; /* Very dark footer */
  border-top: 1px solid var(--border-color);
  padding: 4rem 1.5rem 1.5rem;
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
}

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

.footer-brand p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin: 1rem 0;
  max-width: 280px;
}

.footer-social {
  display: flex;
  gap: 0.75rem;
  margin-top: 1rem;
}

.footer-social a {
  width: 36px;
  height: 36px;
  background: rgba(255,255,255,0.08);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  transition: background 0.2s, color 0.2s;
}

.footer-social a:hover {
  background: var(--accent);
  color: #fff;
}

.footer-col h4 {
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #fff;
  margin-bottom: 1rem;
}

.footer-col ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-col li {
  margin-bottom: 0.6rem;
}

.footer-col a {
  color: var(--text-secondary);
  font-size: 0.9rem;
}

.footer-col a:hover {
  color: var(--accent-light);
}

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.05);
  padding-top: 1.5rem;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* ===== Form ===== */
.form-group {
  margin-bottom: 1.25rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.4rem;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 0.7rem 1rem;
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font: inherit;
  transition: border-color 0.2s;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 2px var(--accent-glow);
}

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

/* ===== Contact Info ===== */
.contact-info {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.contact-item {
  display: flex;
  gap: 1rem;
}

.contact-item-icon {
  width: 44px;
  height: 44px;
  background: rgba(5, 150, 105, 0.15);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-light);
  flex-shrink: 0;
}

.contact-item h4 {
  font-size: 0.95rem;
  margin-bottom: 0.25rem;
}

.contact-item p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin: 0;
}

/* ===== Mobile Menu Toggle ===== */
.menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 30px;
  height: 21px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  z-index: 101;
}

.menu-toggle span {
  display: block;
  width: 100%;
  height: 3px;
  background: var(--text-nav);
  border-radius: 3px;
  transition: all 0.3s;
}

/* ===== Responsive ===== */
@media (max-width: 900px) {
  .site-header {
    position: relative;
  }

  .header-inner {
    flex-wrap: wrap;
    padding: 1rem 1.5rem;
  }

  .menu-toggle {
    display: flex;
  }

  .site-nav,
  .header-cta {
    display: none;
    width: 100%;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    padding: 1rem 0;
    border-top: 1px solid var(--border-color);
    margin-top: 1rem;
    animation: slideDown 0.3s ease-out forwards;
  }

  .site-header.nav-open .site-nav,
  .site-header.nav-open .header-cta {
    display: flex;
  }
  
  .site-header.nav-open .header-cta {
    border-top: none;
    margin-top: 0;
    padding-top: 0;
  }

  @keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
  }

  .site-nav a,
  .nav-dropdown > span {
    text-align: center;
    padding: 0.75rem;
    width: 100%;
    display: block;
  }

  .nav-dropdown {
    width: 100%;
    text-align: center;
  }

  .nav-dropdown-menu {
    position: static;
    display: none; /* Hidden by default on mobile too, can be toggled or just shown */
    background: rgba(0,0,0,0.03);
    box-shadow: none;
    border: none;
    padding: 0.5rem 0;
  }
  
  .nav-dropdown:hover .nav-dropdown-menu,
  .nav-dropdown.active .nav-dropdown-menu {
    display: block;
  }
  
  .nav-dropdown-menu a {
    padding-left: 0;
    color: var(--text-muted);
  }

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

  .hero-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    order: 1; /* Ensure content is first */
  }

  .hero-visual {
    order: 2; /* Ensure visual is second */
    margin-top: 2rem;
    margin-bottom: 0;
  }

  .hero-cards {
    margin: 0 auto;
  }

  .two-col {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 600px) {
  .hero-title {
    font-size: 2rem;
  }
  
  .section {
    padding: 3.5rem 1rem;
  }
  
  .section-title {
    font-size: 1.75rem;
  }

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

  .footer-brand {
    align-items: center;
  }

  .footer-social {
    justify-content: center;
  }
  
  .footer-bottom {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 0.5rem;
  }
}

/* Accent Color */
:root {
  --accent: #2ecc71;
  --accent-light: #34c759;
  --accent-glow: #2ecc71;
}
