/* PatentSignal Design System */

/* ============================================
   Design Tokens
   ============================================ */

:root {
  /* Colors - Modern SaaS */
  --color-primary: #3B82F6;        /* Blue-500 */
  --color-primary-dark: #2563EB;   /* Blue-600 */
  --color-primary-light: #60A5FA;  /* Blue-400 */
  --color-secondary: #6366F1;      /* Indigo-500 */
  --color-accent: #10B981;         /* Emerald-500 */
  --color-warning: #F59E0B;        /* Amber-500 - for disclaimers */
  --color-danger: #EF4444;         /* Red-500 */
  --color-success: #10B981;        /* Emerald-500 */
  
  /* Grays */
  --color-dark: #0F172A;           /* Slate-900 */
  --color-gray-900: #111827;
  --color-gray-800: #1F2937;
  --color-gray-700: #374151;
  --color-gray-600: #4B5563;
  --color-gray-500: #6B7280;
  --color-gray-400: #9CA3AF;
  --color-gray-300: #D1D5DB;
  --color-gray-200: #E5E7EB;
  --color-gray-100: #F3F4F6;
  --color-gray-50: #F9FAFB;
  --color-light: #F8FAFC;          /* Slate-50 */
  --color-white: #FFFFFF;
  
  /* Typography */
  --font-headline: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', 'Courier New', monospace;
  
  /* Spacing */
  --spacing-xs: 0.25rem;   /* 4px */
  --spacing-sm: 0.5rem;     /* 8px */
  --spacing-md: 1rem;      /* 16px */
  --spacing-lg: 1.5rem;    /* 24px */
  --spacing-xl: 2rem;      /* 32px */
  --spacing-2xl: 3rem;     /* 48px */
  --spacing-3xl: 4rem;     /* 64px */
  
  /* Border Radius */
  --radius-sm: 0.375rem;   /* 6px */
  --radius-md: 0.5rem;     /* 8px */
  --radius-lg: 0.75rem;    /* 12px */
  --radius-xl: 1rem;       /* 16px */
  --radius-full: 9999px;
  
  /* Shadows */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  
  /* Transitions */
  --transition-fast: 150ms ease-in-out;
  --transition-base: 200ms ease-in-out;
  --transition-slow: 300ms ease-in-out;
}

/* ============================================
   Base Styles
   ============================================ */

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

body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-gray-900);
  background-color: var(--color-light);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-headline);
  font-weight: 700;
  line-height: 1.2;
  color: var(--color-dark);
  margin-bottom: var(--spacing-md);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }
h5 { font-size: 1.125rem; }
h6 { font-size: 1rem; }

p {
  margin-bottom: var(--spacing-md);
  color: var(--color-gray-700);
}

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

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

ul, ol {
  margin-left: var(--spacing-lg);
  margin-bottom: var(--spacing-md);
}

li {
  margin-bottom: var(--spacing-sm);
  color: var(--color-gray-700);
}

/* ============================================
   Container & Layout
   ============================================ */

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--spacing-lg);
}

/* ============================================
   Header
   ============================================ */

header {
  background-color: var(--color-white);
  border-bottom: 1px solid var(--color-gray-200);
  padding: var(--spacing-lg) 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow-sm);
}

header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-family: var(--font-headline);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-dark);
  text-decoration: none;
  background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  display: inline-block;
  transition: opacity var(--transition-fast);
}

.logo:hover {
  opacity: 0.8;
}

nav {
  display: flex;
  gap: var(--spacing-lg);
  align-items: center;
}

nav a {
  color: var(--color-gray-700);
  font-weight: 500;
  font-size: 0.9375rem;
}

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

/* ============================================
   Buttons
   ============================================ */

.btn {
  display: inline-block;
  padding: var(--spacing-sm) var(--spacing-lg);
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 0.9375rem;
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-base);
  border: none;
  text-decoration: none;
}

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

.btn-primary:hover {
  background-color: var(--color-primary-dark);
  color: var(--color-white);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

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

.btn-secondary:hover {
  background-color: var(--color-primary);
  color: var(--color-white);
}

.btn-large {
  padding: var(--spacing-md) var(--spacing-xl);
  font-size: 1rem;
}

/* ============================================
   Forms
   ============================================ */

input[type="text"],
input[type="email"],
input[type="number"],
textarea {
  width: 100%;
  padding: var(--spacing-sm) var(--spacing-md);
  border: 2px solid var(--color-gray-300);
  border-radius: var(--radius-md);
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--color-gray-900);
  transition: border-color var(--transition-fast);
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="number"]:focus,
textarea:focus {
  outline: none;
  border-color: var(--color-primary);
}

input[type="text"]::placeholder,
input[type="email"]::placeholder,
input[type="number"]::placeholder,
textarea::placeholder {
  color: var(--color-gray-400);
}

/* Patent Number Input (Monospace) */
.patent-input {
  font-family: var(--font-mono);
  font-size: 1.125rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

/* ============================================
   Cards
   ============================================ */

.card {
  background-color: var(--color-white);
  border-radius: var(--radius-lg);
  padding: var(--spacing-xl);
  box-shadow: var(--shadow-md);
  transition: box-shadow var(--transition-base);
}

.card:hover {
  box-shadow: var(--shadow-lg);
}

.card-header {
  margin-bottom: var(--spacing-lg);
  padding-bottom: var(--spacing-md);
  border-bottom: 1px solid var(--color-gray-200);
}

/* ============================================
   Pricing Cards
   ============================================ */

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--spacing-xl);
  margin: var(--spacing-2xl) 0;
}

.pricing-card {
  background-color: var(--color-white);
  border-radius: var(--radius-lg);
  padding: var(--spacing-xl);
  box-shadow: var(--shadow-md);
  position: relative;
  transition: transform var(--transition-base), box-shadow var(--transition-base);
}

.pricing-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-xl);
}

.pricing-card.featured {
  border: 2px solid var(--color-primary);
  transform: scale(1.05);
}

.pricing-badge {
  position: absolute;
  top: -12px;
  right: var(--spacing-lg);
  background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
  color: var(--color-white);
  padding: var(--spacing-xs) var(--spacing-md);
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.pricing-price {
  font-size: 3rem;
  font-weight: 700;
  color: var(--color-dark);
  margin: var(--spacing-md) 0;
}

.pricing-price-strikethrough {
  font-size: 1.5rem;
  color: var(--color-gray-400);
  text-decoration: line-through;
  margin-right: var(--spacing-sm);
}

.pricing-price-label {
  font-size: 0.875rem;
  color: var(--color-gray-500);
  font-weight: 500;
}

.pricing-features {
  list-style: none;
  margin: var(--spacing-lg) 0;
  padding: 0;
}

.pricing-features li {
  padding: var(--spacing-sm) 0;
  color: var(--color-gray-700);
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
}

.pricing-features li::before {
  content: "✓";
  color: var(--color-success);
  font-weight: 700;
  font-size: 1.25rem;
}

/* ============================================
   Hero Section
   ============================================ */

.hero {
  text-align: center;
  padding: var(--spacing-3xl) 0;
  background: linear-gradient(135deg, var(--color-light) 0%, var(--color-white) 100%);
}

.hero h1 {
  font-size: 3.5rem;
  margin-bottom: var(--spacing-lg);
  background: linear-gradient(135deg, var(--color-dark), var(--color-primary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero p {
  font-size: 1.25rem;
  color: var(--color-gray-600);
  margin-bottom: var(--spacing-xl);
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

.hero-input-group {
  display: flex;
  gap: var(--spacing-md);
  max-width: 600px;
  margin: var(--spacing-xl) auto;
  align-items: stretch;
}

.hero-input-group input {
  flex: 1;
  padding: var(--spacing-md) var(--spacing-lg);
  font-size: 1.125rem;
}

.hero-input-group .btn {
  padding: var(--spacing-md) var(--spacing-xl);
  font-size: 1.125rem;
  white-space: nowrap;
}

/* ============================================
   Sections
   ============================================ */

.section {
  padding: var(--spacing-3xl) 0;
}

.section-title {
  text-align: center;
  margin-bottom: var(--spacing-2xl);
}

.section-title h2 {
  font-size: 2.5rem;
  margin-bottom: var(--spacing-md);
}

.section-title p {
  font-size: 1.125rem;
  color: var(--color-gray-600);
  max-width: 600px;
  margin: 0 auto;
}

/* ============================================
   Features Grid
   ============================================ */

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: var(--spacing-xl);
  margin: var(--spacing-2xl) 0;
}

.feature-card {
  padding: var(--spacing-xl);
  background-color: var(--color-white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition-base), box-shadow var(--transition-base);
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.feature-icon {
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--spacing-md);
  color: var(--color-white);
  font-size: 1.5rem;
}

/* ============================================
   Legal Pages
   ============================================ */

.legal-page {
  max-width: 800px;
  margin: var(--spacing-2xl) auto;
  padding: var(--spacing-xl);
  background-color: var(--color-white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}

.legal-page h1 {
  margin-bottom: var(--spacing-sm);
}

.last-updated {
  color: var(--color-gray-500);
  font-size: 0.875rem;
  margin-bottom: var(--spacing-xl);
}

.legal-page section {
  margin-bottom: var(--spacing-2xl);
}

.legal-page section h2 {
  color: var(--color-primary);
  margin-top: var(--spacing-xl);
  margin-bottom: var(--spacing-md);
}

.legal-page section h3 {
  margin-top: var(--spacing-lg);
  margin-bottom: var(--spacing-sm);
  color: var(--color-gray-800);
}

.legal-page strong {
  color: var(--color-dark);
  font-weight: 600;
}

/* ============================================
   Footer
   ============================================ */

footer {
  background-color: var(--color-dark);
  color: var(--color-gray-300);
  padding: var(--spacing-3xl) 0 var(--spacing-xl);
  margin-top: var(--spacing-3xl);
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--spacing-xl);
  margin-bottom: var(--spacing-xl);
}

.footer-section h3,
.footer-section h4 {
  color: var(--color-white);
  margin-bottom: var(--spacing-md);
}

.footer-section a {
  display: block;
  color: var(--color-gray-400);
  margin-bottom: var(--spacing-sm);
  transition: color var(--transition-fast);
}

.footer-section a:hover {
  color: var(--color-white);
}

.footer-disclaimer {
  background-color: var(--color-gray-800);
  padding: var(--spacing-lg);
  border-radius: var(--radius-md);
  margin: var(--spacing-xl) 0;
  border-left: 4px solid var(--color-warning);
}

.footer-disclaimer p {
  color: var(--color-gray-300);
  font-size: 0.875rem;
  margin: 0;
}

.footer-disclaimer strong {
  color: var(--color-warning);
}

.footer-copyright {
  text-align: center;
  padding-top: var(--spacing-lg);
  border-top: 1px solid var(--color-gray-700);
  color: var(--color-gray-500);
  font-size: 0.875rem;
}

/* ============================================
   Disclaimer Banner (For In-App Use)
   ============================================ */

.disclaimer-banner {
  background-color: #FEF3C7; /* Amber-100 */
  border-left: 4px solid var(--color-warning);
  padding: var(--spacing-md) var(--spacing-lg);
  margin: var(--spacing-lg) 0;
  border-radius: var(--radius-md);
}

.disclaimer-banner p {
  margin: 0;
  color: var(--color-gray-800);
  font-size: 0.9375rem;
}

.disclaimer-banner strong {
  color: var(--color-warning);
}

/* ============================================
   Loading Animation
   ============================================ */

.loading-steps {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-md);
  margin: var(--spacing-xl) 0;
}

.loading-step {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  padding: var(--spacing-md);
  background-color: var(--color-white);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}

.loading-step.completed {
  opacity: 0.7;
}

.loading-step-icon {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  flex-shrink: 0;
}

.loading-step-icon.check {
  background-color: var(--color-success);
  color: var(--color-white);
}

.loading-step-icon.spinner {
  border: 3px solid var(--color-gray-200);
  border-top-color: var(--color-primary);
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.loading-step-text {
  flex: 1;
  color: var(--color-gray-700);
  font-weight: 500;
}

/* ============================================
   Teaser Cards (Blur Effect)
   ============================================ */

.teaser-card {
  background-color: var(--color-white);
  border-radius: var(--radius-lg);
  padding: var(--spacing-xl);
  box-shadow: var(--shadow-md);
  margin-bottom: var(--spacing-lg);
  position: relative;
}

.teaser-card.blurred {
  filter: blur(4px);
  pointer-events: none;
  opacity: 0.6;
}

.teaser-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--spacing-md);
}

.teaser-card-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--color-dark);
}

.teaser-card-confidence {
  padding: var(--spacing-xs) var(--spacing-md);
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
}

.teaser-card-confidence.high {
  background-color: #D1FAE5; /* Emerald-100 */
  color: #065F46; /* Emerald-800 */
}

.teaser-card-confidence.medium {
  background-color: #FEF3C7; /* Amber-100 */
  color: #92400E; /* Amber-800 */
}

.teaser-card-confidence.low {
  background-color: #FEE2E2; /* Red-100 */
  color: #991B1B; /* Red-800 */
}

.teaser-card-topic {
  color: var(--color-gray-600);
  font-size: 0.875rem;
  margin-bottom: var(--spacing-md);
}

.teaser-card-evidence {
  color: var(--color-gray-500);
  font-size: 0.875rem;
  font-style: italic;
}

/* ============================================
   Email Gate Modal
   ============================================ */

.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: var(--spacing-lg);
}

.modal {
  background-color: var(--color-white);
  border-radius: var(--radius-lg);
  padding: var(--spacing-2xl);
  max-width: 500px;
  width: 100%;
  box-shadow: var(--shadow-xl);
  animation: modalSlideIn var(--transition-slow);
}

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

.modal-header {
  margin-bottom: var(--spacing-lg);
}

.modal-header h2 {
  margin-bottom: var(--spacing-sm);
}

.modal-header p {
  color: var(--color-gray-600);
  margin: 0;
}

.modal-form {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-md);
}

.modal-form input {
  width: 100%;
}

.modal-form .btn {
  width: 100%;
}

.modal-close {
  position: absolute;
  top: var(--spacing-md);
  right: var(--spacing-md);
  background: none;
  border: none;
  font-size: 1.5rem;
  color: var(--color-gray-400);
  cursor: pointer;
  padding: var(--spacing-xs);
  line-height: 1;
}

.modal-close:hover {
  color: var(--color-gray-600);
}

/* ============================================
   Responsive Design
   ============================================ */

@media (max-width: 768px) {
  .hero h1 {
    font-size: 2.5rem;
  }
  
  .hero-input-group {
    flex-direction: column;
  }
  
  .pricing-grid {
    grid-template-columns: 1fr;
  }
  
  .pricing-card.featured {
    transform: none;
  }
  
  .features-grid {
    grid-template-columns: 1fr;
  }
  
  nav {
    flex-direction: column;
    gap: var(--spacing-sm);
  }
}

/* ============================================
   Utility Classes
   ============================================ */

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

.mt-sm { margin-top: var(--spacing-sm); }
.mt-md { margin-top: var(--spacing-md); }
.mt-lg { margin-top: var(--spacing-lg); }
.mt-xl { margin-top: var(--spacing-xl); }

.mb-sm { margin-bottom: var(--spacing-sm); }
.mb-md { margin-bottom: var(--spacing-md); }
.mb-lg { margin-bottom: var(--spacing-lg); }
.mb-xl { margin-bottom: var(--spacing-xl); }

.hidden { display: none; }
.visible { display: block; }

