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

:root {
  /* Warm, paper-like palette matching the app */
  --color-bg: #fdfcfa;
  --color-surface: #ffffff;
  --color-surface-elevated: #f5f4f2;
  --color-text: #2d2d2d;
  --color-text-muted: #78716c;
  --color-border: #e7e5e4;
  --color-accent: #b45309;
  --color-accent-hover: #92400e;
  --color-accent-light: #fef3c7;
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --shadow-sm: 0 1px 2px 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);
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-text);
  background: var(--color-bg);
}

/* Container */
.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Header */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(250, 250, 250, 0.9);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--color-border);
}

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

.logo {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-text);
  letter-spacing: -0.02em;
}

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

.nav a {
  color: var(--color-text-muted);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  transition: color 0.15s;
}

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

.nav-download {
  background: var(--color-text);
  color: white !important;
  padding: 8px 16px;
  border-radius: var(--radius-md);
}

.nav-download:hover {
  background: #333 !important;
  color: white !important;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 24px;
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
  transition: all 0.15s;
  cursor: pointer;
  border: none;
}

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

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

.btn-large {
  padding: 16px 32px;
  font-size: 1.1rem;
}

/* Beta Badge */
.beta-badge {
  display: inline-block;
  padding: 4px 12px;
  background: var(--color-accent-light);
  color: var(--color-accent);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-radius: 100px;
  margin-bottom: 16px;
}

/* Hero Section */
.hero {
  padding: 160px 0 80px;
  text-align: center;
}

.hero h1 {
  font-size: clamp(2.5rem, 6vw, 4rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: 24px;
}

.hero-subtitle {
  font-size: 1.25rem;
  color: var(--color-text-muted);
  max-width: 640px;
  margin: 0 auto 40px;
  line-height: 1.6;
}

.hero-cta {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.version-note {
  font-size: 0.875rem;
  color: var(--color-text-muted);
}

/* Interactive Demo */
.demo-hero {
  padding: 0 0 80px;
}

.demo-window {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  max-width: 900px;
  margin: 0 auto;
  overflow: hidden;
}

.demo-titlebar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: var(--color-surface-elevated);
  border-bottom: 1px solid var(--color-border);
}

.demo-traffic-lights {
  display: flex;
  gap: 8px;
}

.demo-traffic-lights .light {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.demo-traffic-lights .red { background: #ff5f57; }
.demo-traffic-lights .yellow { background: #ffbd2e; }
.demo-traffic-lights .green { background: #28c840; }

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

.demo-content {
  display: grid;
  grid-template-columns: 1fr 280px;
  min-height: 300px;
}

@media (max-width: 768px) {
  .demo-content {
    grid-template-columns: 1fr;
  }
  .demo-margin {
    border-left: none !important;
    border-top: 1px solid var(--color-border);
  }
}

.demo-editor {
  padding: 32px;
  font-family: 'Georgia', serif;
  font-size: 1.1rem;
  line-height: 1.7;
  color: var(--color-text);
}

.demo-text {
  margin: 0;
  max-width: 50ch;
}

.demo-highlight {
  background: var(--color-accent-light);
  padding: 2px 0;
  border-radius: 2px;
}

.demo-margin {
  background: var(--color-surface-elevated);
  border-left: 1px solid var(--color-border);
  padding: 24px 16px;
  display: flex;
  flex-direction: column;
}

.demo-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.demo-card-recording {
  padding: 16px;
  text-align: center;
}

.demo-card-recording.hidden {
  display: none;
}

.demo-recording-header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 12px;
}

.demo-mode {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-accent);
}

.demo-recording-dot {
  width: 6px;
  height: 6px;
  background: var(--color-accent);
  border-radius: 50%;
  animation: pulse 1.5s ease-in-out infinite;
}

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

#demo-waveform {
  display: block;
  margin: 0 auto 8px;
}

.demo-hint {
  font-size: 0.75rem;
  color: var(--color-text-muted);
}

.demo-card-conversation {
  padding: 12px;
  display: none;
  flex-direction: column;
  gap: 10px;
}

.demo-card-conversation.visible {
  display: flex;
}

.demo-message {
  font-size: 0.85rem;
  line-height: 1.5;
  padding: 8px 12px;
  border-radius: var(--radius-md);
}

.demo-message.user {
  background: var(--color-surface-elevated);
  color: var(--color-text-muted);
  font-style: italic;
  align-self: flex-end;
  max-width: 90%;
}

.demo-message.assistant {
  color: var(--color-text);
}

.demo-message:empty {
  display: none;
}

.typing-cursor {
  display: inline-block;
  width: 2px;
  height: 1em;
  background: var(--color-accent);
  margin-left: 2px;
  animation: blink 0.8s ease-in-out infinite;
  vertical-align: text-bottom;
}

@keyframes blink {
  0%, 50% { opacity: 1; }
  51%, 100% { opacity: 0; }
}

/* Suggestion card */
.demo-card-suggestion {
  display: none;
  border-top: 1px solid var(--color-border);
  padding: 12px;
  background: var(--color-surface-elevated);
}

.demo-card-suggestion.visible {
  display: block;
}

.demo-suggestion-label {
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-accent);
  margin-bottom: 8px;
}

.demo-suggestion-content {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  padding: 10px;
  font-size: 0.8rem;
  line-height: 1.5;
  color: var(--color-text);
  margin-bottom: 10px;
}

.demo-suggestion-actions {
  display: flex;
  gap: 6px;
}

.demo-btn-accept,
.demo-btn-reject {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 6px 10px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s;
  background: var(--color-surface);
  color: var(--color-text-muted);
}

.demo-btn-accept {
  background: #d1fae5;
  border-color: #059669;
  color: #059669;
}

.demo-btn-accept:hover {
  background: #059669;
  color: white;
}

.demo-btn-accept.clicked {
  background: #059669;
  color: white;
  transform: scale(0.95);
}

.demo-btn-reject:hover {
  background: var(--color-surface-elevated);
}

/* Text transition animation */
.demo-highlight.changing {
  animation: text-flash 0.6s ease-out;
}

@keyframes text-flash {
  0% { background: #d1fae5; }
  100% { background: var(--color-accent-light); }
}

.demo-highlight.accepted {
  background: #d1fae5;
  transition: background 0.3s ease;
}

/* Features Section */
.features {
  padding: 80px 0;
  background: var(--color-surface);
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}

.features h2 {
  font-size: 2rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 48px;
  letter-spacing: -0.02em;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 32px;
}

@media (max-width: 768px) {
  .features-grid {
    grid-template-columns: 1fr;
  }
}

.feature-card {
  padding: 32px;
  background: var(--color-bg);
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border);
}

.feature-icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-accent-light);
  color: var(--color-accent);
  border-radius: var(--radius-sm);
  margin-bottom: 16px;
}

.feature-card h3 {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 12px;
  letter-spacing: -0.01em;
}

.feature-card p {
  color: var(--color-text-muted);
  font-size: 0.95rem;
  line-height: 1.6;
}

.feature-card em {
  color: var(--color-text);
  font-style: normal;
  font-weight: 500;
}

.feature-shortcut {
  margin-top: 20px;
  display: flex;
  gap: 6px;
}

kbd {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 28px;
  padding: 4px 8px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: 0.8rem;
  font-weight: 500;
  box-shadow: 0 1px 0 var(--color-border);
}

/* How It Works Section */
.how-it-works {
  padding: 80px 0;
}

.how-it-works h2 {
  font-size: 2rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 48px;
  letter-spacing: -0.02em;
}

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  margin-bottom: 48px;
}

@media (max-width: 768px) {
  .steps {
    grid-template-columns: 1fr;
  }
}

.step {
  text-align: center;
}

.step-number {
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--color-text);
  color: white;
  font-weight: 600;
  font-size: 1rem;
  border-radius: 50%;
  margin-bottom: 16px;
}

.step h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 8px;
}

.step p {
  color: var(--color-text-muted);
  font-size: 0.95rem;
}

/* Tech Section */
.tech-section {
  padding: 80px 0;
  background: var(--color-surface);
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}

.tech-section h2 {
  font-size: 2rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 48px;
  letter-spacing: -0.02em;
}

.tech-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

@media (max-width: 768px) {
  .tech-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .tech-grid {
    grid-template-columns: 1fr;
  }
}

.tech-item {
  text-align: center;
  padding: 24px;
}

.tech-item strong {
  display: block;
  font-size: 1rem;
  margin-bottom: 8px;
}

.tech-item p {
  color: var(--color-text-muted);
  font-size: 0.875rem;
}

/* Download Section */
.download {
  padding: 100px 0;
  text-align: center;
}

.download h2 {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}

.download-note {
  color: var(--color-text-muted);
  margin-bottom: 32px;
  font-size: 1.1rem;
}

.download-buttons {
  margin-bottom: 48px;
}

.requirements {
  max-width: 320px;
  margin: 0 auto;
  text-align: left;
  padding: 24px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
}

.requirements h4 {
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 12px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-text-muted);
}

.requirements ul {
  list-style: none;
}

.requirements li {
  padding: 8px 0;
  color: var(--color-text-muted);
  font-size: 0.9rem;
  border-bottom: 1px solid var(--color-border);
}

.requirements li:last-child {
  border-bottom: none;
}

/* Footer */
.footer {
  padding: 48px 0;
  text-align: center;
  border-top: 1px solid var(--color-border);
}

.footer p {
  color: var(--color-text-muted);
  font-size: 0.9rem;
}

.footer a {
  color: var(--color-text);
  text-decoration: none;
  font-weight: 500;
}

.footer a:hover {
  text-decoration: underline;
}

.footer-note {
  margin-top: 8px;
  font-size: 0.8rem !important;
}

/* Coming Soon Section */
.coming-soon {
  padding: 80px 0;
  background: var(--color-surface);
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}

.coming-soon h2 {
  font-size: 2rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}

.coming-soon-badge {
  display: block;
  text-align: center;
  margin-bottom: 12px;
  padding: 4px 12px;
  background: linear-gradient(135deg, #e0e7ff 0%, #c7d2fe 100%);
  color: #4338ca;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  border-radius: 100px;
  width: fit-content;
  margin-left: auto;
  margin-right: auto;
}

.coming-soon-intro {
  text-align: center;
  font-size: 1.1rem;
  color: var(--color-text-muted);
  max-width: 560px;
  margin: 0 auto 48px;
  line-height: 1.6;
}

.agents-preview {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-bottom: 40px;
}

@media (max-width: 768px) {
  .agents-preview {
    grid-template-columns: 1fr;
    max-width: 400px;
    margin-left: auto;
    margin-right: auto;
  }
}

.agent-card {
  padding: 24px;
  background: var(--color-bg);
  border-radius: var(--radius-md);
  border: 1px solid var(--color-border);
  text-align: center;
}

.agent-icon {
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #e0e7ff 0%, #c7d2fe 100%);
  color: #4338ca;
  border-radius: var(--radius-sm);
  margin-bottom: 16px;
}

.agent-card h4 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 8px;
  letter-spacing: -0.01em;
}

.agent-card p {
  color: var(--color-text-muted);
  font-size: 0.875rem;
  line-height: 1.5;
  margin: 0;
}

.coming-soon-note {
  text-align: center;
  font-size: 0.9rem;
  color: var(--color-text-muted);
  max-width: 520px;
  margin: 0 auto;
  font-style: italic;
}

/* Responsive */
@media (max-width: 768px) {
  .hero {
    padding: 120px 0 60px;
  }

  .hero h1 {
    font-size: 2rem;
  }

  .hero-subtitle {
    font-size: 1.1rem;
  }

  .nav {
    gap: 16px;
  }

  .nav a:not(.nav-download) {
    display: none;
  }
}
