@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@400;500;600;700;800;900&display=swap');

:root {
  --bg-primary: #08090C;
  --bg-secondary: #0F1117;
  --bg-tertiary: #161922;
  --bg-card: rgba(22, 25, 34, 0.65);
  --bg-card-hover: rgba(30, 35, 48, 0.85);
  --border-color: rgba(255, 255, 255, 0.08);
  --border-hover: rgba(99, 102, 241, 0.4);

  --text-primary: #F8FAFC;
  --text-secondary: #94A3B8;
  --text-muted: #64748B;

  --accent-indigo: #6366F1;
  --accent-purple: #A855F7;
  --accent-cyan: #06B6D4;
  --accent-emerald: #10B981;
  --accent-rose: #F43F5E;

  --gradient-primary: linear-gradient(135deg, #6366F1 0%, #A855F7 50%, #06B6D4 100%);
  --gradient-glow: linear-gradient(135deg, rgba(99, 102, 241, 0.25) 0%, rgba(168, 85, 247, 0.25) 50%, rgba(6, 182, 212, 0.25) 100%);
  --gradient-text: linear-gradient(135deg, #FFFFFF 0%, #E2E8F0 60%, #94A3B8 100%);
  --gradient-accent-text: linear-gradient(135deg, #818CF8 0%, #C084FC 50%, #22D3EE 100%);

  --shadow-lg: 0 20px 40px -15px rgba(0, 0, 0, 0.7);
  --shadow-glow: 0 0 30px -5px rgba(99, 102, 241, 0.3);
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-full: 9999px;

  --transition-fast: 0.15s ease;
  --transition-normal: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  background-color: var(--bg-primary);
  color: var(--text-primary);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  line-height: 1.6;
  overflow-x: hidden;
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Background Atmospheric Glow - High Performance Zero-Blur Radial Gradients */
.background-glow {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
  background:
    radial-gradient(circle at 15% 15%, rgba(99, 102, 241, 0.12) 0%, transparent 45%),
    radial-gradient(circle at 85% 85%, rgba(168, 85, 247, 0.10) 0%, transparent 45%),
    radial-gradient(circle at 60% 40%, rgba(6, 182, 212, 0.08) 0%, transparent 40%);
}

.glow-orb {
  display: none;
}

/* Container & Typography */
.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
  position: relative;
  z-index: 10;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  line-height: 1.2;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.section-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  background: rgba(99, 102, 241, 0.12);
  border: 1px solid rgba(99, 102, 241, 0.3);
  color: #818CF8;
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 16px;
}

.section-tag::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #818CF8;
  box-shadow: 0 0 8px #818CF8;
}

.gradient-text {
  background: var(--gradient-accent-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  display: inline-block;
}

/* Navigation */
.navbar {
  position: sticky;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  background: rgba(8, 9, 12, 0.96);
  border-bottom: 1px solid var(--border-color);
  transition: var(--transition-normal);
}

.navbar.scrolled {
  background: rgba(8, 9, 12, 0.95);
  box-shadow: 0 10px 30px -10px rgba(0,0,0,0.5);
  border-bottom: 1px solid rgba(255,255,255,0.12);
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 80px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  font-family: 'Outfit', sans-serif;
  font-weight: 800;
  font-size: 1.5rem;
  color: var(--text-primary);
  letter-spacing: -0.03em;
}

.logo-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: var(--gradient-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 900;
  font-size: 1.25rem;
  box-shadow: 0 4px 15px -3px rgba(99, 102, 241, 0.5);
  position: relative;
  overflow: hidden;
}

.logo-icon::after {
  content: '';
  position: absolute;
  top: 0;
  left: -50%;
  width: 40%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
  transform: skewX(-20deg);
  animation: shine 4s infinite;
}

@keyframes shine {
  0%, 80% { left: -100%; }
  100% { left: 200%; }
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
}

.nav-link {
  color: var(--text-secondary);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  transition: var(--transition-fast);
  position: relative;
}

.nav-link:hover,
.nav-link.active {
  color: var(--text-primary);
}

.nav-link.active::after {
  content: '';
  position: absolute;
  bottom: -6px;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--gradient-primary);
  border-radius: var(--radius-full);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 22px;
  border-radius: var(--radius-full);
  font-family: 'Outfit', sans-serif;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  cursor: pointer;
  transition: var(--transition-normal);
  border: none;
  outline: none;
}

.btn-primary {
  background: var(--gradient-primary);
  color: #fff;
  box-shadow: 0 4px 20px -4px rgba(168, 85, 247, 0.4);
  position: relative;
  overflow: hidden;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px -4px rgba(168, 85, 247, 0.6);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

/* Mobile Menu Toggle */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 1.5rem;
  cursor: pointer;
}

/* Hero Section */
.hero {
  padding: 100px 0 80px;
  position: relative;
  overflow: hidden;
}

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

.hero-content h1 {
  font-size: clamp(2.5rem, 4.5vw, 4.2rem);
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 24px;
}

.hero-content p {
  font-size: 1.18rem;
  color: var(--text-secondary);
  max-width: 580px;
  margin-bottom: 36px;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 48px;
}

.hero-trust {
  display: flex;
  align-items: center;
  gap: 24px;
  padding-top: 24px;
  border-top: 1px solid var(--border-color);
}

.trust-item {
  display: flex;
  flex-direction: column;
}

.trust-val {
  font-family: 'Outfit', sans-serif;
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-primary);
}

.trust-label {
  font-size: 0.82rem;
  color: var(--text-muted);
}

/* Interactive Campaign Simulator Card (Hero Right) */
.hero-visual {
  position: relative;
}

.platform-window {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg), 0 0 50px -15px rgba(99, 102, 241, 0.3);
  position: relative;
}

.window-header {
  background: rgba(22, 25, 34, 0.8);
  padding: 14px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-color);
}

.window-dots {
  display: flex;
  gap: 8px;
}

.dot {
  width: 11px;
  height: 11px;
  border-radius: 50%;
}

.dot-red { background: #FF5F56; }
.dot-yellow { background: #FFBD2E; }
.dot-green { background: #27C93F; }

.window-title {
  font-size: 0.8rem;
  font-family: 'Outfit', sans-serif;
  font-weight: 600;
  color: var(--text-secondary);
  letter-spacing: 0.04em;
}

.status-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--accent-emerald);
  background: rgba(16, 185, 129, 0.12);
  padding: 4px 10px;
  border-radius: var(--radius-full);
}

.status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-emerald);
  box-shadow: 0 0 8px var(--accent-emerald);
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.85); }
}

.window-body {
  padding: 24px;
}

.metrics-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

.metric-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-md);
  padding: 16px;
  transition: var(--transition-fast);
}

.metric-card:hover {
  border-color: rgba(99, 102, 241, 0.3);
  background: rgba(255, 255, 255, 0.05);
}

.metric-label {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.metric-value {
  font-family: 'Outfit', sans-serif;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
}

.metric-change {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--accent-emerald);
  display: flex;
  align-items: center;
  gap: 3px;
}

.campaign-feed {
  background: #0B0D12;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 16px;
  font-family: 'Consolas', 'Monaco', monospace;
  font-size: 0.8rem;
}

.feed-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  color: var(--text-muted);
}

.log-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 0;
  border-bottom: 1px solid rgba(255,255,255,0.03);
}

.log-item:last-child {
  border-bottom: none;
}

.log-tag {
  color: var(--accent-cyan);
  font-weight: 600;
}

.log-time {
  color: var(--text-muted);
  font-size: 0.72rem;
}

/* Sections Global */
.section {
  padding: 100px 0;
  position: relative;
}

.section-header {
  text-align: center;
  max-width: 720px;
  margin: 0 auto 60px;
}

.section-header h2 {
  font-size: clamp(2rem, 3.5vw, 3rem);
  margin-bottom: 16px;
}

.section-header p {
  font-size: 1.1rem;
  color: var(--text-secondary);
}

/* Services Grid */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.service-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 36px 28px;
  transition: var(--transition-normal);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: var(--gradient-primary);
  opacity: 0;
  transition: var(--transition-normal);
}

.service-card:hover {
  transform: translateY(-6px);
  background: var(--bg-card-hover);
  border-color: var(--border-hover);
  box-shadow: var(--shadow-glow);
}

.service-card:hover::before {
  opacity: 1;
}

.service-icon {
  width: 60px;
  height: 60px;
  border-radius: var(--radius-md);
  background: rgba(99, 102, 241, 0.1);
  border: 1px solid rgba(99, 102, 241, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-indigo);
  font-size: 1.5rem;
  margin-bottom: 24px;
}

.service-card:nth-child(2) .service-icon {
  background: rgba(168, 85, 247, 0.1);
  border-color: rgba(168, 85, 247, 0.25);
  color: var(--accent-purple);
}

.service-card:nth-child(3) .service-icon {
  background: rgba(6, 182, 212, 0.1);
  border-color: rgba(6, 182, 212, 0.25);
  color: var(--accent-cyan);
}

.service-card h3 {
  font-size: 1.45rem;
  margin-bottom: 12px;
}

.service-card p {
  color: var(--text-secondary);
  margin-bottom: 24px;
  flex-grow: 1;
}

.service-features {
  list-style: none;
  border-top: 1px solid var(--border-color);
  padding-top: 20px;
}

.service-features li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.9rem;
  color: var(--text-primary);
  margin-bottom: 10px;
}

.service-features li svg {
  color: var(--accent-emerald);
  flex-shrink: 0;
}

/* Technology Suite / TikTok API Justification Section */
.tech-section {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
  position: relative;
  overflow: hidden;
}

.tech-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 60px;
}

.tech-content h2 {
  font-size: clamp(2rem, 3.2vw, 2.8rem);
  margin-bottom: 20px;
}

.tech-content > p {
  font-size: 1.1rem;
  color: var(--text-secondary);
  margin-bottom: 32px;
  line-height: 1.7;
}

.tech-stack-boxes {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.tech-box {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 20px 24px;
  display: flex;
  align-items: flex-start;
  gap: 18px;
  transition: var(--transition-fast);
}

.tech-box:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(99, 102, 241, 0.35);
}

.tech-box-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: rgba(99, 102, 241, 0.15);
  color: #818CF8;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.tech-box h4 {
  font-size: 1.15rem;
  margin-bottom: 6px;
}

.tech-box p {
  font-size: 0.92rem;
  color: var(--text-secondary);
}

/* Architecture Visualizer Card */
.arch-card {
  background: #0A0C10;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-lg);
}

.arch-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
}

.arch-title {
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text-primary);
}

.arch-flow {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.arch-node {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.arch-node.active {
  border-color: var(--accent-indigo);
  background: rgba(99, 102, 241, 0.08);
  box-shadow: 0 0 20px -5px rgba(99, 102, 241, 0.3);
}

.node-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.node-badge {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 6px;
  background: rgba(255,255,255,0.1);
  color: #fff;
  text-transform: uppercase;
}

.node-title {
  font-weight: 600;
  color: var(--text-primary);
}

.node-sub {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.arch-arrow {
  text-align: center;
  color: var(--text-muted);
  font-size: 1.2rem;
  animation: bounceDown 1.5s infinite;
}

@keyframes bounceDown {
  0%, 100% { transform: translateY(0); opacity: 0.7; }
  50% { transform: translateY(4px); opacity: 1; }
}

/* Compliance Banner */
.compliance-banner {
  background: linear-gradient(90deg, rgba(99, 102, 241, 0.15), rgba(168, 85, 247, 0.15));
  border: 1px solid rgba(99, 102, 241, 0.3);
  border-radius: var(--radius-lg);
  padding: 36px 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin: 60px 0;
}

.compliance-info h3 {
  font-size: 1.5rem;
  margin-bottom: 8px;
}

.compliance-info p {
  color: var(--text-secondary);
  max-width: 650px;
}

/* Legal / Privacy / Terms Specific Styles */
.legal-page {
  padding: 80px 0 120px;
}

.legal-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 56px 64px;
  box-shadow: var(--shadow-lg);
  max-width: 940px;
  margin: 0 auto;
}

.legal-card h1 {
  font-size: 2.5rem;
  margin-bottom: 8px;
}

.legal-updated {
  color: var(--accent-cyan);
  font-weight: 600;
  font-size: 0.95rem;
  margin-bottom: 40px;
  display: inline-block;
}

.legal-content h2 {
  font-size: 1.5rem;
  margin: 36px 0 16px;
  color: var(--text-primary);
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 10px;
}

.legal-content p {
  color: var(--text-secondary);
  margin-bottom: 18px;
  line-height: 1.75;
  font-size: 1.05rem;
}

.legal-content ul {
  margin: 12px 0 24px 24px;
  color: var(--text-secondary);
}

.legal-content li {
  margin-bottom: 12px;
  line-height: 1.6;
}

.legal-content a {
  color: var(--accent-indigo);
  text-decoration: none;
  font-weight: 500;
}

.legal-content a:hover {
  text-decoration: underline;
  color: #818CF8;
}

/* Global Footer - CRITICAL FOR TIKTOK COMPLIANCE */
.global-footer {
  background: #050608;
  border-top: 1px solid var(--border-color);
  padding: 70px 0 36px;
  margin-top: auto;
  position: relative;
  z-index: 20;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.5fr;
  gap: 48px;
  margin-bottom: 48px;
}

.footer-col h4 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 20px;
}

.footer-col p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: 16px;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-links li a {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.95rem;
  transition: var(--transition-fast);
}

.footer-links li a:hover {
  color: var(--text-primary);
  padding-left: 4px;
}

/* Highlighted footer legal links for TikTok compliance */
.legal-footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.legal-footer-links li a {
  color: var(--text-primary);
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: var(--transition-fast);
}

.legal-footer-links li a:hover {
  color: var(--accent-cyan);
}

.footer-contact-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  color: var(--text-secondary);
  font-size: 0.92rem;
  margin-bottom: 14px;
}

.footer-contact-item svg {
  color: var(--accent-indigo);
  flex-shrink: 0;
  margin-top: 3px;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding-top: 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  color: var(--text-muted);
  font-size: 0.88rem;
}

.footer-legal-bar {
  display: flex;
  align-items: center;
  gap: 24px;
}

.footer-legal-bar a {
  color: var(--text-secondary);
  text-decoration: none;
  font-weight: 500;
  transition: var(--transition-fast);
}

.footer-legal-bar a:hover {
  color: #fff;
  text-decoration: underline;
}

/* Responsive Styles */
@media (max-width: 1024px) {
  .hero-grid,
  .tech-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }

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

@media (max-width: 768px) {
  .nav-links, .nav-actions {
    display: none;
  }

  .menu-toggle {
    display: block;
  }

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

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

  .legal-card {
    padding: 32px 24px;
  }

  .compliance-banner {
    flex-direction: column;
    text-align: center;
  }
}
