/* Basic reset and theme */
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; font-family: 'Inter', 'Outfit', system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif; color: #0f172a; background: #ffffff; }
a { color: inherit; text-decoration: none; }

/* CSS Variables */
:root {
  --primary: #0057FF;
  --primary-hover: #0043cc;
  --accent: #16a34a;
  --accent-2: #22c55e;
  --fg: #0f172a;
  --fg-2: #475569;
  --line: #e2e8f0;
  --bg: #ffffff;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: 'Inter', sans-serif; line-height: 1.6; color: #1e293b; margin: 0; }
.container { width: 100%; max-width: 1100px; margin: 0 auto; padding: 0 20px; }

/* Header & Navigation */
.site-header { 
  background: rgba(255, 255, 255, 0.98); 
  backdrop-filter: blur(10px);
  box-shadow: 0 1px 0 rgba(0,0,0,0.05); 
  position: sticky; 
  top: 0; 
  z-index: 1000; 
}
.header-content { 
  display: flex; 
  justify-content: space-between; 
  align-items: center; 
  padding: 1.5rem 40px; 
  max-width: 1400px;
  margin: 0 auto;
}
.logo { display: flex; align-items: center; gap: 0.5rem; flex-shrink: 0; }
.logo img, .logo-img { height: 68px; width: auto; display: block; }
.nav { 
  display: flex; 
  gap: 0.25rem; 
  align-items: center; 
  font-size: 0.9rem;
  margin-left: auto;
}
.nav a { 
  text-decoration: none; 
  color: #64748b; 
  font-weight: 500; 
  transition: all 0.2s; 
  padding: 0.5rem 0.875rem;
  border-radius: 6px;
  white-space: nowrap;
}
.nav a:hover { color: #10b981; background: #f0fdf4; }

/* Dropdown Menu - Click-based */
.nav-item { 
  position: relative;
  display: inline-block;
}
.nav-item > a { 
  display: flex !important; 
  align-items: center; 
  gap: 4px; 
  cursor: pointer;
  padding: 0.5rem 0.875rem;
  border-radius: 6px;
  color: #64748b;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.2s;
  white-space: nowrap;
}
.nav-item > a:hover {
  color: #10b981;
  background: #f0fdf4;
}
.nav-item.active > a {
  color: #10b981;
  background: #f0fdf4;
}
.nav-item .dropdown-arrow { 
  font-size: 10px; 
  transition: transform 0.2s;
  margin-left: 2px;
}
.nav-item.active .dropdown-arrow { 
  transform: rotate(180deg); 
}
.dropdown-menu { 
  position: absolute; 
  top: 100%; 
  left: 0; 
  background: white; 
  border: 1px solid #e2e8f0; 
  border-radius: 8px; 
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1); 
  min-width: 240px; 
  opacity: 0; 
  visibility: hidden; 
  transform: translateY(-8px); 
  transition: all 0.2s ease-in-out; 
  margin-top: 8px;
  z-index: 1001;
  pointer-events: none;
}
.nav-item.active .dropdown-menu { 
  opacity: 1; 
  visibility: visible; 
  transform: translateY(0);
  pointer-events: auto;
}
.dropdown-menu a { 
  display: block; 
  padding: 12px 16px; 
  color: #475569; 
  border-radius: 6px; 
  margin: 4px; 
  font-size: 0.9rem;
  transition: all 0.2s;
  text-decoration: none;
}
.dropdown-menu a:hover { 
  background: #f0fdf4; 
  color: #10b981; 
}

/* Main Content */
main { position: relative; }

/* Hero Section */
.hero { padding: 96px 0 72px; background: linear-gradient(180deg, #f8fbff 0%, #ffffff 50%); text-align: center; }
.hero h1 { margin: 0 0 12px; font-size: 40px; line-height: 1.15; font-weight: 700; }
.hero p { margin: 0 auto 24px; max-width: 720px; color: #334155; font-size: 18px; }
.cta-group { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.btn { 
  display: inline-block; 
  padding: 0.625rem 1.5rem; 
  border-radius: 6px; 
  text-decoration: none; 
  font-weight: 600; 
  transition: all 0.2s; 
  font-size: 0.9rem;
  white-space: nowrap;
  border: 1px solid transparent;
}
.nav .btn.primary {
  background: #10b981; 
  color: white; 
  box-shadow: 0 1px 3px rgba(16,185,129,0.3);
  margin-left: 0.5rem;
}
.nav .btn.primary:hover { 
  background: #059669; 
  box-shadow: 0 4px 12px rgba(16,185,129,0.4);
  transform: translateY(-1px);
}
.btn.primary { background: #10b981; color: #ffffff; }
.btn.primary:hover { background: #059669; transform: translateY(-1px); box-shadow: 0 4px 12px rgba(16,185,129,0.3); }
.btn.secondary { background: #e2e8f0; color: #0f172a; }
.btn.secondary:hover { background: #cbd5e1; }
.btn.ghost { background: transparent; border: 1px solid var(--accent); color: var(--accent); }
.btn.ghost:hover { background: rgba(34, 197, 94, 0.08); }

/* SSS Hero with Background */
.hero.sss-hero { 
  position: relative; 
  min-height: 90vh; 
  display: flex;
  align-items: center;
  background: linear-gradient(rgba(255,255,255,.75), rgba(255,255,255,.80)), url('/images/hero_grid.jpg') center/cover no-repeat;
  padding: 6rem 0 4rem;
}
.hero.sss-hero .container {
  width: 100%;
}
.eyebrow { color: var(--accent); font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; font-size: 12px; margin-bottom: 8px; }

/* Content Sections */
.features { padding: 56px 0; }
.block { padding: 56px 0; }
.block.alt { background: #f8fafc; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }

/* Grid & Cards */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.grid { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.card { padding: 22px; border-radius: 14px; border: 1px solid var(--line); background: #ffffff; box-shadow: 0 2px 6px rgba(15, 23, 42, 0.04); }
.card h3, .card h4 { margin-top: 0; margin-bottom: 8px; }
.card p { margin: 0; color: var(--fg-2); line-height: 1.6; }

/* Typography */
h3.title { font-family: 'Outfit', system-ui, sans-serif; font-size: 24px; margin: 0 0 10px; font-weight: 700; }
p.lead { color: var(--fg-2); margin: 0; line-height: 1.7; }

/* How It Works */
.how { padding: 32px 0 80px; }
.step { padding: 22px; border-radius: 14px; border: 1px dashed var(--line); background: #f8fafc; text-align: center; }
.step-num { width: 36px; height: 36px; border-radius: 999px; background: #0ea5e9; color: white; display: inline-flex; align-items: center; justify-content: center; font-weight: 700; margin-bottom: 10px; }

/* SSS Specific - Pie Charts */
.pie { --size: 240px; width: var(--size); height: var(--size); border-radius: 50%; border: 1px solid var(--line); box-shadow: inset 0 0 0 6px #ffffff; }
.pie-caption { text-align: center; margin-top: 8px; color: var(--fg-2); font-size: 12px; }
.legend-item { display: flex; align-items: center; gap: 6px; color: var(--fg-2); font-size: 12px; }
.legend-swatch { width: 14px; height: 14px; border-radius: 3px; border: 1px solid rgba(0,0,0,.08); }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding: 24px 0; background: #ffffff; text-align: center; color: var(--fg-2); }
.site-footer a:hover { color: var(--primary); }

/* Newsletter/Subscribe */
#stay-updated { text-align: center; padding: 40px 20px; background: #f8fafc; border-top: 1px solid var(--line); }

/* Responsive */
@media (max-width: 1024px) {
  .nav a:not(.btn) { padding: 0.5rem 0.75rem; font-size: 0.875rem; }
  .header-content { padding: 1.25rem 30px; }
}

@media (max-width: 900px) {
  .grid-3 { grid-template-columns: 1fr; }
  .header-content { padding: 1.25rem 20px; }
  .nav { display: none; }
  .logo img, .logo-img { height: 50px; }
  .hero h1 { font-size: 32px; }
  .pie { --size: 200px; }
}

@media (max-width: 480px) {
  .container { padding: 0 16px; }
  .hero { padding: 60px 0 48px; }
  .pie { --size: 180px; }
}
