/* ============================================================
   Astro Marketing — White Label SEO Marketplace
   Design System
   Deep space · Glassmorphism · Neon accents
   Blend of Stripe / Semrush / Ahrefs / Linear / Apple
   ============================================================ */

:root {
  /* Core palette (per spec) */
  --bg-void: #060B18;        /* Deep Space Blue */
  --bg-deep: #08101f;
  --bg-panel: #0c1426;
  --bg-elevated: #111b30;

  --primary: #4F7BFF;
  --accent: #00E5FF;
  --success: #32D74B;
  --star: #FFB020;

  /* Glass surfaces */
  --glass: rgba(255, 255, 255, 0.035);
  --glass-strong: rgba(255, 255, 255, 0.06);
  --glass-border: rgba(255, 255, 255, 0.08);
  --glass-border-strong: rgba(120, 160, 255, 0.22);

  --accent-grad: linear-gradient(120deg, #4F7BFF 0%, #00E5FF 100%);
  --accent-grad-soft: linear-gradient(120deg, rgba(79, 123, 255, 0.16), rgba(0, 229, 255, 0.10));

  /* Text */
  --text-hi: #F2F5FF;
  --text-mid: #9fb0d0;
  --text-lo: #647294;

  /* Geometry */
  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 22px;
  --maxw: 1200px;

  /* Type */
  --font-head: "Poppins", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --mono: "JetBrains Mono", "SF Mono", ui-monospace, monospace;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: var(--bg-void);
  color: var(--text-hi);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  position: relative;
  min-height: 100vh;
}

/* ---- Ambient space backdrop + constellation ---- */
.starfield {
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(1200px 700px at 80% -8%, rgba(79, 123, 255, 0.22), transparent 60%),
    radial-gradient(900px 600px at 8% 6%, rgba(0, 229, 255, 0.12), transparent 55%),
    radial-gradient(900px 800px at 50% 115%, rgba(79, 123, 255, 0.10), transparent 60%),
    var(--bg-void);
}
.starfield::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(1.4px 1.4px at 20% 30%, rgba(255,255,255,0.8), transparent),
    radial-gradient(1px 1px at 70% 60%, rgba(255,255,255,0.5), transparent),
    radial-gradient(1px 1px at 40% 80%, rgba(255,255,255,0.6), transparent),
    radial-gradient(1.2px 1.2px at 85% 20%, rgba(0,229,255,0.5), transparent),
    radial-gradient(1px 1px at 55% 12%, rgba(255,255,255,0.5), transparent),
    radial-gradient(1px 1px at 12% 70%, rgba(255,255,255,0.4), transparent),
    radial-gradient(1.3px 1.3px at 90% 85%, rgba(79,123,255,0.6), transparent),
    radial-gradient(1px 1px at 33% 50%, rgba(255,255,255,0.4), transparent);
  background-repeat: repeat;
  opacity: 0.7;
}
/* SVG constellation overlay layer (used on hero) */
.constellation {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.5;
}
.constellation line { stroke: rgba(79, 123, 255, 0.35); stroke-width: 1; }
.constellation circle { fill: var(--accent); }
.constellation .pulse { animation: twinkle 3.2s ease-in-out infinite; }
@keyframes twinkle { 0%,100% { opacity: 0.3; } 50% { opacity: 1; } }

/* ---- Layout ---- */
.wrap { width: min(var(--maxw), 92%); margin-inline: auto; position: relative; }
section { padding: 92px 0; position: relative; }

/* ---- Navbar ---- */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(18px);
  background: rgba(6, 11, 24, 0.72);
  border-bottom: 1px solid var(--glass-border);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 70px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.12rem;
  letter-spacing: -0.02em;
  color: var(--text-hi);
  text-decoration: none;
}
.brand-mark {
  width: 32px; height: 32px;
  border-radius: 9px;
  background: var(--accent-grad);
  display: grid;
  place-items: center;
  box-shadow: 0 0 22px rgba(79, 123, 255, 0.6);
  position: relative;
}
.brand-mark::before {
  content: "";
  width: 11px; height: 11px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 12px #fff;
}
.nav-links { display: flex; align-items: center; gap: 28px; }
.nav-links a {
  color: var(--text-mid);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  transition: color 0.2s;
}
.nav-links a:hover, .nav-links a.active { color: var(--text-hi); }
.nav-actions { display: flex; align-items: center; gap: 14px; }

.hamburger { display:none; flex-direction:column; gap:5px; background:none; border:none; cursor:pointer; padding:4px; }
.hamburger span { display:block; width:22px; height:2px; background:var(--text-hi); border-radius:2px; transition:all 0.25s; }
.nav-open .hamburger span:nth-child(1) { transform:translateY(7px) rotate(45deg); }
.nav-open .hamburger span:nth-child(2) { opacity:0; }
.nav-open .hamburger span:nth-child(3) { transform:translateY(-7px) rotate(-45deg); }

/* ---- Buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 12px 22px;
  border-radius: 11px;
  font-size: 0.92rem;
  font-weight: 600;
  font-family: var(--font-body);
  cursor: pointer;
  text-decoration: none;
  border: 1px solid transparent;
  white-space: nowrap;
  transition: transform 0.15s ease, box-shadow 0.2s ease, background 0.2s;
}
.btn-primary {
  background: var(--accent-grad);
  color: #06122b;
  font-weight: 700;
  box-shadow: 0 8px 30px rgba(79, 123, 255, 0.4);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 40px rgba(0, 229, 255, 0.45); }
.btn-ghost {
  background: var(--glass);
  border-color: var(--glass-border-strong);
  color: var(--text-hi);
}
.btn-ghost:hover { background: var(--glass-strong); transform: translateY(-2px); }
.btn-sm { padding: 9px 16px; font-size: 0.84rem; }
.btn-lg { padding: 15px 30px; font-size: 1rem; }
.btn-block { width: 100%; }
.link-quiet { color: var(--text-mid); text-decoration: none; font-size: 0.9rem; font-weight: 500; }
.link-quiet:hover { color: var(--text-hi); }

/* ---- Glass card ---- */
.glass {
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(16px);
}
.card {
  background: linear-gradient(180deg, var(--glass-strong), var(--glass));
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  padding: 28px;
  backdrop-filter: blur(16px);
  transition: transform 0.22s ease, border-color 0.22s, box-shadow 0.22s;
}
.card:hover {
  transform: translateY(-5px);
  border-color: var(--glass-border-strong);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(79,123,255,0.12);
}

/* ---- Pill / badge ---- */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px;
  border-radius: 999px;
  background: var(--glass);
  border: 1px solid var(--glass-border-strong);
  font-size: 0.8rem;
  color: var(--text-mid);
  font-weight: 500;
}
.pill .dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 10px var(--success);
}

/* ---- Headings ---- */
.eyebrow {
  font-family: var(--mono);
  font-size: 0.76rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 16px;
}
h1, h2, h3, h4 { font-family: var(--font-head); letter-spacing: -0.02em; line-height: 1.12; font-weight: 700; }
h1 { font-size: clamp(2.5rem, 5.6vw, 4rem); }
h2 { font-size: clamp(1.9rem, 3.8vw, 2.8rem); }
h3 { font-size: 1.18rem; }
.grad-text {
  background: var(--accent-grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.lead { color: var(--text-mid); font-size: 1.12rem; max-width: 58ch; }
.section-head { max-width: 640px; margin-bottom: 52px; }
.section-head.center { margin-inline: auto; text-align: center; }

/* ---- Feature checklist ---- */
.checks { list-style: none; display: grid; gap: 12px; }
.checks li { display: flex; align-items: center; gap: 11px; color: var(--text-mid); font-size: 1rem; }
.checks .tick {
  width: 22px; height: 22px; border-radius: 50%;
  background: rgba(50, 215, 75, 0.14);
  color: var(--success);
  display: grid; place-items: center;
  font-size: 0.75rem; flex-shrink: 0;
  border: 1px solid rgba(50, 215, 75, 0.3);
}

/* ---- Trust strip ---- */
.trust-row { display: flex; flex-wrap: wrap; gap: 14px 28px; align-items: center; }
.trust-item { display: flex; align-items: center; gap: 10px; font-size: 0.9rem; color: var(--text-mid); }
.trust-item strong { color: var(--text-hi); font-weight: 700; }
.stars { color: var(--star); letter-spacing: 2px; font-size: 0.9rem; }

.logos {
  display: flex; flex-wrap: wrap; gap: 18px 14px;
  align-items: center; justify-content: center;
}
.logo-chip {
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text-mid);
  padding: 12px 22px;
  border: 1px solid var(--glass-border);
  border-radius: 12px;
  background: var(--glass);
  transition: color 0.2s, border-color 0.2s;
}
.logo-chip:hover { color: var(--text-hi); border-color: var(--glass-border-strong); }

/* ---- Grids ---- */
.grid { display: grid; gap: 22px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-6 { grid-template-columns: repeat(6, 1fr); }

/* ---- Category card ---- */
.cat-card { display: flex; flex-direction: column; gap: 8px; }
.cat-icon {
  width: 50px; height: 50px; border-radius: 13px;
  background: var(--accent-grad-soft);
  border: 1px solid var(--glass-border-strong);
  display: grid; place-items: center;
  font-size: 1.5rem; margin-bottom: 8px;
}
.cat-card h3 { font-size: 1.15rem; }
.cat-price { color: var(--text-mid); font-size: 0.92rem; }
.cat-price b { color: var(--accent); font-weight: 700; }
.cat-link {
  margin-top: auto; padding-top: 14px;
  color: var(--primary); font-weight: 600; font-size: 0.9rem;
  text-decoration: none; display: inline-flex; gap: 6px; align-items: center;
}
.cat-card:hover .cat-link { gap: 10px; }
.cat-link { transition: gap 0.2s; }

/* ---- Stat infographic ---- */
.stats-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 0; }
.stat { padding: 28px 18px; text-align: center; border-right: 1px solid var(--glass-border); }
.stat:last-child { border-right: none; }
.stat-num {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: clamp(1.6rem, 3vw, 2.3rem);
  background: var(--accent-grad);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.stat-label { color: var(--text-mid); font-size: 0.86rem; margin-top: 4px; }

/* ---- Pricing ---- */
.price-card { position: relative; display: flex; flex-direction: column; }
.price-card.featured {
  border-color: var(--glass-border-strong);
  box-shadow: 0 0 0 1px rgba(79,123,255,0.25), 0 24px 60px rgba(79,123,255,0.18);
  background: linear-gradient(180deg, rgba(79,123,255,0.10), var(--glass));
}
.price-badge {
  position: absolute; top: -12px; left: 50%; transform: translateX(-50%);
  background: var(--accent-grad); color: #06122b;
  font-size: 0.72rem; font-weight: 700; letter-spacing: 0.06em;
  padding: 5px 14px; border-radius: 999px; text-transform: uppercase;
}
.price-name { font-family: var(--font-head); font-weight: 600; color: var(--text-mid); font-size: 1rem; }
.price-amt { font-family: var(--font-head); font-weight: 700; font-size: 2.6rem; margin: 10px 0 4px; }
.price-amt span { font-size: 1rem; color: var(--text-lo); font-weight: 500; }
.price-feats { list-style: none; display: grid; gap: 13px; margin: 22px 0 26px; }
.price-feats li { display: flex; align-items: center; gap: 10px; color: var(--text-mid); font-size: 0.94rem; }
.price-feats .tick { color: var(--accent); }

/* ---- Table (marketplace) ---- */
.table-wrap { overflow-x: auto; border-radius: var(--radius-lg); border: 1px solid var(--glass-border); background: var(--glass); backdrop-filter: blur(16px); }
table.market { width: 100%; border-collapse: collapse; min-width: 720px; }
table.market thead th {
  text-align: left; padding: 16px 20px;
  font-size: 0.74rem; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--text-lo); font-weight: 600;
  border-bottom: 1px solid var(--glass-border);
  font-family: var(--mono);
}
table.market tbody td { padding: 18px 20px; border-bottom: 1px solid var(--glass-border); font-size: 0.94rem; color: var(--text-mid); }
table.market tbody tr:last-child td { border-bottom: none; }
table.market tbody tr { transition: background 0.18s; }
table.market tbody tr:hover { background: rgba(79, 123, 255, 0.05); }
.site-name { color: var(--text-hi); font-weight: 600; }
.dr-badge {
  display: inline-grid; place-items: center;
  min-width: 40px; padding: 4px 10px; border-radius: 8px;
  font-weight: 700; font-size: 0.85rem; font-family: var(--mono);
}
.dr-hi { background: rgba(50, 215, 75, 0.14); color: var(--success); border: 1px solid rgba(50,215,75,0.3); }
.dr-mid { background: rgba(79, 123, 255, 0.14); color: var(--primary); border: 1px solid rgba(79,123,255,0.3); }
.price-cell { color: var(--text-hi); font-weight: 700; font-family: var(--font-head); }

/* ---- Search + filters (marketplace) ---- */
.search-bar {
  display: flex; align-items: center; gap: 12px;
  padding: 8px 8px 8px 20px;
  background: var(--glass-strong);
  border: 1px solid var(--glass-border-strong);
  border-radius: 16px;
  backdrop-filter: blur(16px);
}
.search-bar input {
  flex: 1; background: transparent; border: none; outline: none;
  color: var(--text-hi); font-size: 1.05rem; font-family: var(--font-body);
}
.search-bar input::placeholder { color: var(--text-lo); }
.chips { display: flex; flex-wrap: wrap; gap: 10px; }
.chip {
  padding: 8px 16px; border-radius: 999px;
  background: var(--glass); border: 1px solid var(--glass-border);
  color: var(--text-mid); font-size: 0.86rem; font-weight: 500;
  cursor: pointer; transition: all 0.18s; user-select: none;
}
.chip:hover { color: var(--text-hi); border-color: var(--glass-border-strong); }
.chip.active { background: var(--accent-grad-soft); border-color: var(--glass-border-strong); color: var(--text-hi); }

.filter-panel { display: grid; gap: 24px; }
.filter-group h4 { font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-lo); margin-bottom: 12px; font-family: var(--mono); font-weight: 600; }
.filter-options { display: flex; flex-wrap: wrap; gap: 8px; }

/* ---- Case study card ---- */
.case-num {
  font-family: var(--font-head); font-weight: 700;
  font-size: 2.6rem;
  background: linear-gradient(120deg, #32D74B, #00E5FF);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* ---- Service card (compact) ---- */
.svc-card { display: flex; gap: 16px; align-items: flex-start; }
.svc-icon {
  width: 44px; height: 44px; border-radius: 12px; flex-shrink: 0;
  background: var(--accent-grad-soft); border: 1px solid var(--glass-border-strong);
  display: grid; place-items: center; font-size: 1.3rem;
}
.svc-card h3 { font-size: 1.05rem; margin-bottom: 3px; }
.svc-card p { color: var(--text-mid); font-size: 0.9rem; }

/* ---- Dashboard mock ---- */
.dash {
  border: 1px solid var(--glass-border-strong); border-radius: var(--radius-lg);
  background: linear-gradient(180deg, var(--bg-elevated), var(--bg-panel));
  overflow: hidden; box-shadow: 0 30px 80px rgba(0,0,0,0.5);
}
.dash-bar { display: flex; align-items: center; gap: 8px; padding: 14px 18px; border-bottom: 1px solid var(--glass-border); }
.dash-dot { width: 11px; height: 11px; border-radius: 50%; }
.dash-body { padding: 22px; display: grid; gap: 16px; }
.dash-metric { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px; background: var(--glass); border: 1px solid var(--glass-border); border-radius: 12px; }
.bar-track { height: 8px; border-radius: 999px; background: rgba(255,255,255,0.06); overflow: hidden; }
.bar-fill { height: 100%; border-radius: 999px; background: var(--accent-grad); }

/* ---- CTA band ---- */
.cta-band {
  border-radius: var(--radius-lg);
  background: linear-gradient(120deg, rgba(79,123,255,0.18), rgba(0,229,255,0.10));
  border: 1px solid var(--glass-border-strong);
  padding: 56px; text-align: center; backdrop-filter: blur(16px);
}

/* ---- Footer ---- */
.footer { border-top: 1px solid var(--glass-border); padding: 64px 0 40px; color: var(--text-lo); font-size: 0.9rem; }
.footer-grid { display: grid; grid-template-columns: 1.6fr repeat(4, 1fr); gap: 36px; margin-bottom: 44px; }
.footer h5 { font-family: var(--font-head); color: var(--text-hi); font-size: 0.92rem; margin-bottom: 16px; font-weight: 600; }
.footer ul { list-style: none; display: grid; gap: 10px; }
.footer a { color: var(--text-mid); text-decoration: none; }
.footer a:hover { color: var(--text-hi); }
.footer-bottom { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 16px; padding-top: 28px; border-top: 1px solid var(--glass-border); }

/* ---- Utility ---- */
.center { text-align: center; }
.mx-auto { margin-inline: auto; }
.mt-s { margin-top: 14px; }
.mt-m { margin-top: 28px; }
.mt-l { margin-top: 48px; }
.muted { color: var(--text-mid); }
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.in { opacity: 1; transform: none; }

.hero-grid { display:grid; grid-template-columns:1.1fr 0.9fr; gap:56px; align-items:center; }
.dash-grid { display:grid; grid-template-columns:0.9fr 1.1fr; gap:48px; align-items:center; }

.desktop-only { display:block; }
.mobile-only { display:none; }

.site-card {
  display:grid; grid-template-columns:1fr auto;
  gap:8px 14px; align-items:center;
  padding:16px; margin-bottom:12px;
  border:1px solid var(--glass-border);
  border-radius:var(--radius);
  background:var(--glass);
}
.site-card .site-name { grid-column:1; font-size:0.95rem; }
.site-card .site-dr { grid-column:2; justify-self:end; }
.site-card .site-meta { grid-column:1 / -1; display:flex; gap:14px; font-size:0.82rem; color:var(--text-mid); }
.site-card .site-meta span { display:flex; align-items:center; gap:4px; }
.site-card .site-action { grid-column:1 / -1; justify-self:end; }

/* ---- Responsive ---- */
@media (max-width: 960px) {
  .grid-3, .grid-6 { grid-template-columns: repeat(2, 1fr); }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .stats-grid { grid-template-columns: repeat(3, 1fr); }
  .stat { border-bottom: 1px solid var(--glass-border); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
.mobile-nav { display:none; position:absolute; top:70px; left:0; right:0; background:rgba(6,11,24,0.97); border-bottom:1px solid var(--glass-border); padding:20px 24px; flex-direction:column; gap:6px; z-index:49; backdrop-filter:blur(18px); }
.mobile-nav a { display:block; padding:12px 14px; border-radius:10px; color:var(--text-mid); text-decoration:none; font-size:0.95rem; font-weight:500; transition:all 0.16s; }
.mobile-nav a:hover, .mobile-nav a.active { background:var(--glass); color:var(--text-hi); }
.mobile-nav .mobile-actions { display:flex; flex-direction:column; gap:10px; margin-top:10px; padding-top:16px; border-top:1px solid var(--glass-border); }
.nav-open .mobile-nav { display:flex; }

@media (max-width: 680px) {
  .nav-links { display: none; }
  .nav-actions .link-quiet, .nav-actions .btn { display:none; }
  .hamburger { display:flex; }
  section { padding: 60px 0; }
  section:first-of-type .wrap { width:92%; }
  .hero-grid { grid-template-columns:1fr; gap:32px; }
  .dash-grid { grid-template-columns:1fr; gap:32px; }
  .search-bar { flex-direction:column; padding:16px; }
  .search-bar input { width:100%; }
  .search-bar .btn { width:100%; }
  .filter-panel { padding:12px; gap:12px; position:static !important; }
  .filter-group { display:flex; align-items:center; gap:8px; }
  .filter-group h4 { font-size:0.7rem; margin-bottom:0; white-space:nowrap; flex-shrink:0; }
  .filter-options { flex-wrap:nowrap; overflow-x:auto; gap:4px; padding-bottom:4px; -webkit-overflow-scrolling:touch; }
  .filter-options .chip { white-space:nowrap; flex-shrink:0; padding:5px 10px; font-size:0.75rem; }
  .desktop-only { display:none; }
  .mobile-only { display:block; }
  .grid-2, .grid-3, .grid-4, .grid-6 { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .cta-band { padding: 36px 24px; }
  .footer-grid { grid-template-columns: 1fr; }
}
