/**
 * BookmarkScrub Landing Page - Shared Design System
 * Matches extension UI exactly for brand consistency
 */

/* ============================================================================
   CSS VARIABLES - Shared with Extension
   ============================================================================ */

:root {
  /* Primary Brand */
  --brand-primary: #6366f1;
  --brand-primary-hover: #4f46e5;
  --brand-primary-light: #a5b4fc;
  --brand-primary-bg: rgba(99, 102, 241, 0.12);

  /* Trust & Security (New) */
  --trust-blue: #175DDC;
  --trust-blue-hover: #1349B8;
  --security-green: #10B981;
  --security-green-hover: #059669;

  /* Semantic Colors */
  --color-success: #22C55E;
  --color-warning: #F59E0B;
  --color-danger: #EF4444;
  --color-info: #3B82F6;

  /* Security Status Colors */
  --security-safe: #22C55E;
  --security-caution: #F59E0B;
  --security-warning: #F97316;
  --security-critical: #EF4444;
  --security-scanning: #3B82F6;

  /* Dark Theme (Primary) */
  --bg-primary: #0f1117;
  --bg-secondary: #1a1d26;
  --bg-tertiary: #252936;
  --bg-card: #1e2129;
  --bg-card-hover: #2a2d3a;

  /* Text Colors */
  --text-primary: #ffffff;
  --text-secondary: #b0b8c8;
  --text-muted: #6b7280;

  /* Borders */
  --border-subtle: rgba(255, 255, 255, 0.06);
  --border-medium: rgba(255, 255, 255, 0.12);
  --border-accent: rgba(99, 102, 241, 0.3);

  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.15);
  --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.2);
  --shadow-xl: 0 12px 32px rgba(0, 0, 0, 0.25);
  --shadow-glow: 0 0 20px rgba(99, 102, 241, 0.3);

  /* Typography */
  --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-size-xs: 0.75rem;
  --font-size-sm: 0.875rem;
  --font-size-base: 1rem;
  --font-size-lg: 1.125rem;
  --font-size-xl: 1.25rem;
  --font-size-2xl: 1.5rem;
  --font-size-3xl: 1.875rem;
  --font-size-4xl: 2.25rem;
  --font-size-5xl: 3rem;

  /* Spacing */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;

  /* Border Radius */
  --radius-sm: 0.5rem;
  --radius-md: 0.75rem;
  --radius-lg: 1rem;
  --radius-xl: 1.5rem;
  --radius-full: 9999px;

  /* Transitions */
  --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-base: 200ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 300ms cubic-bezier(0.4, 0, 0.2, 1);
}

/* ============================================================================
   BASE STYLES
   ============================================================================ */

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-family);
  font-size: var(--font-size-base);
  line-height: 1.6;
  color: var(--text-primary);
  background-color: var(--bg-primary);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-feature-settings: 'cv02', 'cv03', 'cv04', 'cv11';
  text-rendering: optimizeLegibility;
}

/* ============================================================================
   TYPOGRAPHY
   ============================================================================ */

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

h1 {
  font-size: var(--font-size-5xl);
  font-weight: 700;
  letter-spacing: -0.03em;
}

h2 {
  font-size: var(--font-size-3xl);
  font-weight: 700;
  letter-spacing: -0.025em;
}

h3 {
  font-size: var(--font-size-xl);
  font-weight: 600;
  letter-spacing: -0.015em;
}

h4 {
  font-size: var(--font-size-lg);
  font-weight: 600;
  letter-spacing: -0.01em;
}

p {
  color: var(--text-secondary);
  line-height: 1.6;
  letter-spacing: -0.01em;
}

/* Body text variants */
.text-lg {
  font-size: var(--font-size-lg);
  line-height: 1.7;
}

.text-sm {
  font-size: var(--font-size-sm);
  line-height: 1.5;
}

.text-xs {
  font-size: var(--font-size-xs);
  line-height: 1.4;
}

a {
  color: var(--brand-primary-light);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--brand-primary);
}

/* ============================================================================
   LAYOUT
   ============================================================================ */

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-6);
}

.section {
  padding: var(--space-20) 0;
}

.section-dark {
  background-color: var(--bg-primary);
}

.section-darker {
  background-color: var(--bg-secondary);
}

/* ============================================================================
   BUTTONS
   ============================================================================ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-6);
  font-family: var(--font-family);
  font-size: var(--font-size-base);
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-base);
}

.btn-lg {
  padding: var(--space-4) var(--space-8);
  font-size: var(--font-size-lg);
}

.btn-primary {
  background-color: var(--brand-primary);
  color: white;
  box-shadow: var(--shadow-md), var(--shadow-glow);
}

.btn-primary:hover {
  background-color: var(--brand-primary-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg), 0 0 30px rgba(99, 102, 241, 0.4);
}

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

.btn-secondary:hover {
  background-color: var(--bg-card);
  border-color: var(--brand-primary);
}

.btn-danger {
  background-color: var(--color-danger);
  color: white;
}

.btn-danger:hover {
  background-color: #dc2626;
}

/* ============================================================================
   CARDS
   ============================================================================ */

.card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  transition: all var(--transition-base);
}

.card:hover {
  border-color: var(--border-medium);
  background-color: var(--bg-card-hover);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.card-highlight {
  border-color: var(--brand-primary);
  box-shadow: var(--shadow-glow);
}

/* ============================================================================
   BADGES
   ============================================================================ */

.badge {
  display: inline-flex;
  align-items: center;
  padding: var(--space-1) var(--space-3);
  font-size: var(--font-size-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-radius: var(--radius-full);
}

.badge-primary {
  background-color: var(--brand-primary);
  color: white;
}

.badge-success {
  background-color: var(--security-green);
  color: white;
}

.badge-warning {
  background-color: var(--color-warning);
  color: #1a1d26;
}

.badge-danger {
  background-color: var(--color-danger);
  color: white;
}

.badge-launch {
  background: linear-gradient(135deg, var(--brand-primary), #8b5cf6);
  color: white;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.8; }
}

/* ============================================================================
   ICONS
   ============================================================================ */

.icon {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

.icon-lg {
  width: 32px;
  height: 32px;
}

.icon-xl {
  width: 48px;
  height: 48px;
}

.icon-box {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: var(--radius-md);
  background-color: var(--brand-primary-bg);
}

.icon-box-danger {
  background-color: rgba(239, 68, 68, 0.12);
}

.icon-box-success {
  background-color: rgba(34, 197, 94, 0.12);
}

.icon-box-warning {
  background-color: rgba(245, 158, 11, 0.12);
}

/* ============================================================================
   UTILITIES
   ============================================================================ */

.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.text-primary { color: var(--text-primary); }
.text-secondary { color: var(--text-secondary); }
.text-muted { color: var(--text-muted); }
.text-accent { color: var(--brand-primary-light); }
.text-danger { color: var(--color-danger); }
.text-success { color: var(--security-green); }

.font-normal { font-weight: 400; }
.font-medium { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }

.mt-2 { margin-top: var(--space-2); }
.mt-4 { margin-top: var(--space-4); }
.mt-6 { margin-top: var(--space-6); }
.mt-8 { margin-top: var(--space-8); }

.mb-2 { margin-bottom: var(--space-2); }
.mb-4 { margin-bottom: var(--space-4); }
.mb-6 { margin-bottom: var(--space-6); }
.mb-8 { margin-bottom: var(--space-8); }

.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.gap-2 { gap: var(--space-2); }
.gap-4 { gap: var(--space-4); }
.gap-6 { gap: var(--space-6); }
.gap-8 { gap: var(--space-8); }

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

.max-w-2xl { max-width: 42rem; }
.max-w-3xl { max-width: 48rem; }
.max-w-4xl { max-width: 56rem; }

.mx-auto { margin-left: auto; margin-right: auto; }

/* ============================================================================
   RESPONSIVE
   ============================================================================ */

@media (max-width: 768px) {
  h1 { font-size: var(--font-size-3xl); }
  h2 { font-size: var(--font-size-2xl); }

  .section {
    padding: var(--space-12) 0;
  }

  .grid-cols-2,
  .grid-cols-3 {
    grid-template-columns: 1fr;
  }

  .btn-lg {
    width: 100%;
  }

  .hide-mobile {
    display: none;
  }
}

@media (min-width: 769px) and (max-width: 1024px) {
  .grid-cols-3 {
    grid-template-columns: repeat(2, 1fr);
  }
}
