/* ============================================
   Let Me Know When - Design System
   ============================================ */

/* Import Inter font */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

/* ============================================
   CSS Variables - Light Theme (Default)
   ============================================ */
:root {
  /* Background colors */
  --bg-primary: #FDF6E3;
  --bg-secondary: #FEF9E7;
  --bg-card: #FFFDF7;

  /* Text colors */
  --text-primary: #1A1A1A;
  --text-secondary: #5C5C5C;
  --text-muted: #8A8A8A;

  /* Border colors */
  --border-primary: #1A1A1A;
  --border-light: #E5E5E5;

  /* Accent colors */
  --accent-primary: #F5A623;    /* Orange - primary CTA */
  --accent-coral: #E85D5D;      /* Coral red */
  --accent-mint: #4ECDC4;       /* Mint green */
  --accent-purple: #7C6EE6;     /* Purple */

  /* Status colors */
  --status-success: #4ECDC4;
  --status-warning: #F5A623;
  --status-error: #E85D5D;
  --status-info: #7C6EE6;

  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.07);
  --shadow-lg: 0 10px 20px rgba(0, 0, 0, 0.1);

  /* Spacing */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 9999px;

  /* Border width */
  --border-width: 2px;
}

/* ============================================
   CSS Variables - Dark Theme
   ============================================ */
html.dark {
  --bg-primary: #1A1A1A;
  --bg-secondary: #242424;
  --bg-card: #2A2A2A;

  --text-primary: #F5F5F5;
  --text-secondary: #B0B0B0;
  --text-muted: #707070;

  --border-primary: #F5F5F5;
  --border-light: #3A3A3A;

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.2);
  --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 10px 20px rgba(0, 0, 0, 0.4);
}

/* ============================================
   Reset & Base Styles
   ============================================ */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  line-height: 1.6;
  color: var(--text-primary);
  background-color: var(--bg-primary);
  min-height: 100vh;
  transition: background-color 0.3s ease, color 0.3s ease;
}

/* ============================================
   Typography
   ============================================ */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.2;
  color: var(--text-primary);
}

h1 {
  font-size: 3rem;
  letter-spacing: -0.02em;
}

h2 {
  font-size: 2rem;
  letter-spacing: -0.01em;
}

h3 {
  font-size: 1.5rem;
}

p {
  color: var(--text-secondary);
}

/* ============================================
   Layout
   ============================================ */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.page-center {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

/* ============================================
   Cards
   ============================================ */
.card {
  background: var(--bg-card);
  border: var(--border-width) solid var(--border-primary);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.card-lg {
  padding: 3rem 2.5rem;
  max-width: 480px;
  width: 100%;
}

/* ============================================
   Buttons
   ============================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.875rem 1.75rem;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  border: var(--border-width) solid transparent;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(124, 110, 230, 0.3);
}

.btn-primary {
  background: var(--accent-primary);
  color: var(--text-primary);
  border-color: var(--border-primary);
}

.btn-primary:hover {
  background: #E09620;
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

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

.btn-secondary:hover {
  background: var(--bg-secondary);
  transform: translateY(-2px);
}

.btn-ghost {
  background: transparent;
  color: var(--text-primary);
  border-color: transparent;
}

.btn-ghost:hover {
  background: var(--bg-secondary);
}

/* Button sizes */
.btn-sm {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
}

.btn-lg {
  padding: 1rem 2.5rem;
  font-size: 1.125rem;
}

/* ============================================
   Form Elements
   ============================================ */
.form-group {
  margin-bottom: 1.5rem;
}

.form-label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
  color: var(--text-primary);
}

.form-input {
  width: 100%;
  padding: 0.875rem 1rem;
  font-family: inherit;
  font-size: 1rem;
  color: var(--text-primary);
  background: var(--bg-secondary);
  border: var(--border-width) solid var(--border-light);
  border-radius: var(--radius-md);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-input:focus {
  outline: none;
  border-color: var(--accent-purple);
  box-shadow: 0 0 0 3px rgba(124, 110, 230, 0.15);
}

.form-input::placeholder {
  color: var(--text-muted);
}

.form-hint {
  margin-top: 0.5rem;
  font-size: 0.875rem;
  color: var(--text-muted);
}

.form-error {
  color: var(--status-error);
}

/* ============================================
   Theme Toggle
   ============================================ */
.theme-toggle {
  position: fixed;
  top: 1.5rem;
  right: 1.5rem;
  z-index: 100;
}

.theme-toggle-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  background: var(--bg-card);
  border: var(--border-width) solid var(--border-primary);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: transform 0.2s ease;
}

.theme-toggle-btn:hover {
  transform: scale(1.05);
}

.theme-toggle-btn svg {
  width: 24px;
  height: 24px;
  color: var(--text-primary);
}

/* Hide icons based on theme */
.theme-toggle-btn .icon-sun {
  display: none;
}

html.dark .theme-toggle-btn .icon-moon {
  display: none;
}

html.dark .theme-toggle-btn .icon-sun {
  display: block;
}

/* ============================================
   Pulse Animation
   ============================================ */
@keyframes pulse-ring {
  0% {
    transform: scale(0.8);
    opacity: 1;
  }
  100% {
    transform: scale(2);
    opacity: 0;
  }
}

@keyframes pulse-dot {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.1);
  }
}

.pulse-container {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.pulse-dot {
  width: 12px;
  height: 12px;
  background: var(--accent-mint);
  border-radius: 50%;
  animation: pulse-dot 2s ease-in-out infinite;
}

.pulse-ring {
  position: absolute;
  width: 12px;
  height: 12px;
  background: var(--accent-mint);
  border-radius: 50%;
  animation: pulse-ring 2s ease-out infinite;
}

.pulse-ring:nth-child(2) {
  animation-delay: 0.5s;
}

.pulse-ring:nth-child(3) {
  animation-delay: 1s;
}

/* Pulse variants */
.pulse-container.pulse-coral .pulse-dot,
.pulse-container.pulse-coral .pulse-ring {
  background: var(--accent-coral);
}

.pulse-container.pulse-orange .pulse-dot,
.pulse-container.pulse-orange .pulse-ring {
  background: var(--accent-primary);
}

.pulse-container.pulse-purple .pulse-dot,
.pulse-container.pulse-purple .pulse-ring {
  background: var(--accent-purple);
}

/* Large pulse for hero sections */
.pulse-lg .pulse-dot {
  width: 20px;
  height: 20px;
}

.pulse-lg .pulse-ring {
  width: 20px;
  height: 20px;
}

/* ============================================
   Status Badges
   ============================================ */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.25rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-radius: var(--radius-full);
  border: var(--border-width) solid var(--border-primary);
}

.badge-success {
  background: var(--status-success);
  color: var(--text-primary);
}

.badge-warning {
  background: var(--status-warning);
  color: var(--text-primary);
}

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

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

/* ============================================
   Utility Classes
   ============================================ */
.text-center {
  text-align: center;
}

.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }

.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }

.flex {
  display: flex;
}

.flex-center {
  display: flex;
  align-items: center;
  justify-content: center;
}

.gap-1 { gap: 0.5rem; }
.gap-2 { gap: 1rem; }
.gap-3 { gap: 1.5rem; }

/* ============================================
   Responsive
   ============================================ */
@media (max-width: 640px) {
  h1 {
    font-size: 2.25rem;
  }

  h2 {
    font-size: 1.5rem;
  }

  .card {
    padding: 1.5rem;
  }

  .card-lg {
    padding: 2rem 1.5rem;
  }

  .btn {
    padding: 0.75rem 1.5rem;
  }
}
