/* ==========================================================================
   AutoPR Slack AI — Design System & Custom CSS
   Style: Dark Mode (OLED / Slate) + Electric Accents
   Typography: Inter + Fira Code
   ========================================================================== */

:root {
  /* Dark Color Palette */
  --bg-dark: #090d16;
  --bg-card: rgba(18, 25, 41, 0.75);
  --bg-card-hover: rgba(28, 38, 62, 0.85);
  --bg-terminal: #05080f;
  
  /* Brand Colors */
  --slack-aubergine: #4A154B;
  --slack-auburn-hover: #611f69;
  --cloudflare-orange: #F38020;
  --github-dark: #24292e;
  --antigravity-purple: #818cf8;
  
  --primary: #6366f1; /* Indigo */
  --primary-hover: #4f46e5;
  --accent-emerald: #10b981; /* Success Green */
  --accent-cyan: #06b6d4; /* Cyan Glow */
  --accent-purple: #a855f7; /* Purple Glow */
  
  /* Text & Border */
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --text-dim: #64748b;
  --border: rgba(255, 255, 255, 0.08);
  --border-active: rgba(99, 102, 241, 0.4);
  
  /* Fonts & Radius */
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'Fira Code', monospace;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-full: 9999px;
  
  /* Shadows & Glows */
  --shadow-card: 0 20px 40px -15px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 50px rgba(99, 102, 241, 0.15);
}

/* Reset & Global */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  color-scheme: dark;
}

body {
  background-color: var(--bg-dark);
  color: var(--text-main);
  font-family: var(--font-sans);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
  -webkit-font-smoothing: antialiased;
}

/* Background Ambient Glows */
.ambient-glow {
  position: fixed;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.glow-orb-1 {
  position: absolute;
  top: -150px;
  left: 50%;
  transform: translateX(-50%);
  width: 900px;
  height: 600px;
  background: radial-gradient(circle, rgba(99, 102, 241, 0.18) 0%, rgba(168, 85, 247, 0.1) 40%, transparent 70%);
  filter: blur(90px);
}

.glow-orb-2 {
  position: absolute;
  top: 40%;
  left: -100px;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(243, 128, 32, 0.12) 0%, transparent 65%);
  filter: blur(100px);
}

.glow-orb-3 {
  position: absolute;
  top: 70%;
  right: -100px;
  width: 700px;
  height: 700px;
  background: radial-gradient(circle, rgba(99, 102, 241, 0.12) 0%, transparent 65%);
  filter: blur(120px);
}

/* Typography Helpers */
h1, h2, h3, h4 {
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-main);
}

.gradient-text {
  background: linear-gradient(135deg, #ffffff 0%, #cbd5e1 50%, #818cf8 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.gradient-accent-text {
  background: linear-gradient(135deg, #818cf8 0%, #c084fc 50%, #34d399 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
  position: relative;
  z-index: 1;
}

/* Header & Navbar */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(9, 13, 22, 0.85);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  padding: 1.1rem 0;
  transition: all 0.3s ease;
}

.navbar .nav-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: var(--text-main);
  font-weight: 700;
  font-size: 1.25rem;
}

.brand-icon {
  width: 42px;
  height: 42px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.15);
}

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

.nav-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  transition: color 0.2s ease;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 0.7rem 1.4rem;
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  border: 1px solid transparent;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), #4f46e5);
  color: #ffffff;
  box-shadow: 0 8px 20px -4px rgba(99, 102, 241, 0.5);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 25px -4px rgba(99, 102, 241, 0.7);
  background: linear-gradient(135deg, #6366f1, #4338ca);
}

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

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

.btn-slack {
  background: var(--slack-aubergine);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.2);
}

.btn-slack:hover {
  background: var(--slack-auburn-hover);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px -4px rgba(74, 21, 75, 0.6);
}

/* Hero Section */
.hero {
  padding: 5rem 0 4rem;
  text-align: center;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.8rem;
  padding: 0.5rem 1.2rem;
  border-radius: var(--radius-full);
  background: rgba(99, 102, 241, 0.1);
  border: 1px solid rgba(99, 102, 241, 0.25);
  color: #a5b4fc;
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 2rem;
}

.hero-badge .logo-strip {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.hero-badge .pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-emerald);
  box-shadow: 0 0 10px var(--accent-emerald);
}

.hero h1 {
  font-size: 3.8rem;
  line-height: 1.15;
  margin-bottom: 1.5rem;
  max-width: 960px;
  margin-left: auto;
  margin-right: auto;
}

.hero p.lead {
  font-size: 1.25rem;
  color: var(--text-muted);
  max-width: 760px;
  margin: 0 auto 2.5rem;
  font-weight: 400;
}

.hero-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.25rem;
  margin-bottom: 4rem;
  flex-wrap: wrap;
}

/* Interactive Slack Simulator Widget */
.demo-section {
  margin: 2rem 0 6rem;
}

.slack-window {
  background: #1a1d21;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card), var(--shadow-glow);
  overflow: hidden;
  max-width: 980px;
  margin: 0 auto;
}

.slack-header {
  background: #121519;
  padding: 0.9rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.slack-header-left {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.window-controls {
  display: flex;
  gap: 6px;
}

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

.dot-red { background: #ed6a5e; }
.dot-yellow { background: #f5bf4f; }
.dot-green { background: #61c554; }

.channel-title {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.slack-body {
  padding: 2rem;
  min-height: 420px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.messages-list {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  max-height: 420px;
  overflow-y: auto;
}

.message-item {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  animation: fadeIn 0.4s ease-out;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.avatar {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1rem;
  flex-shrink: 0;
}

.avatar-user {
  background: linear-gradient(135deg, #f43f5e, #e11d48);
  color: white;
}

.avatar-bot {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
}

.msg-content {
  flex: 1;
}

.msg-header {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 0.3rem;
}

.sender-name {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--text-main);
}

.bot-tag {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-muted);
  font-size: 0.7rem;
  padding: 0.1rem 0.4rem;
  border-radius: 4px;
  font-weight: 600;
  text-transform: uppercase;
}

.msg-time {
  font-size: 0.75rem;
  color: var(--text-dim);
}

.msg-text {
  font-size: 0.95rem;
  color: #d1d5db;
}

.slack-cmd {
  font-family: var(--font-mono);
  background: #0f1217;
  padding: 0.4rem 0.7rem;
  border-radius: 6px;
  color: #38bdf8;
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: inline-block;
}

.slack-attachment {
  margin-top: 0.8rem;
  background: #111418;
  border-left: 4px solid var(--accent-emerald);
  border-radius: 0 8px 8px 0;
  padding: 1rem 1.25rem;
}

.attachment-title {
  font-weight: 600;
  color: #34d399;
  font-size: 0.95rem;
  margin-bottom: 0.4rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.diff-preview {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  background: #090c10;
  padding: 0.8rem;
  border-radius: 6px;
  margin-top: 0.6rem;
  overflow-x: auto;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.diff-add { color: #4ade80; }
.diff-del { color: #f87171; }
.diff-info { color: #94a3b8; }

/* Simulator Control Prompt Bar */
.simulator-bar {
  background: #121519;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 1.25rem 1.5rem;
}

.prompt-chips {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 1rem;
  flex-wrap: wrap;
  align-items: center;
}

.chip-label {
  font-size: 0.8rem;
  color: var(--text-dim);
  font-weight: 600;
}

.chip {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-muted);
  padding: 0.35rem 0.8rem;
  border-radius: var(--radius-full);
  font-size: 0.825rem;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: var(--font-mono);
}

.chip:hover {
  background: rgba(99, 102, 241, 0.15);
  border-color: var(--primary);
  color: var(--text-main);
}

.input-box-wrapper {
  display: flex;
  gap: 0.75rem;
}

.slack-input {
  flex: 1;
  background: #0b0e13;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 10px;
  padding: 0.8rem 1.2rem;
  color: var(--text-main);
  font-family: var(--font-mono);
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.2s ease;
}

.slack-input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2);
}

/* Features Grid */
.features-section {
  padding: 5rem 0;
}

.section-header {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 4rem;
}

.section-header h2 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

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

.grid-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 2rem;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 2.25rem;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
}

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

.icon-wrapper {
  width: 58px;
  height: 58px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
}

.icon-wrapper-slack {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.18);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
}
.icon-wrapper-cloudflare { background: rgba(243, 128, 32, 0.2); border-color: rgba(243, 128, 32, 0.4); }
.icon-wrapper-antigravity { background: rgba(168, 85, 247, 0.2); border-color: rgba(168, 85, 247, 0.4); }
.icon-wrapper-github { background: rgba(255, 255, 255, 0.1); border-color: rgba(255, 255, 255, 0.2); }

.feature-card h3 {
  font-size: 1.35rem;
  margin-bottom: 0.75rem;
}

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

/* Architecture Flow Section */
.architecture-section {
  padding: 5rem 0;
  background: rgba(18, 25, 41, 0.4);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  border-radius: var(--radius-lg);
  margin: 3rem 0;
}

.flow-diagram {
  display: flex;
  align-items: stretch;
  justify-content: space-between;
  gap: 1.25rem;
  margin-top: 3rem;
  flex-wrap: wrap;
}

.flow-step {
  flex: 1;
  min-width: 220px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 2.25rem 1.5rem 1.75rem;
  text-align: center;
  position: relative;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
}

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

.flow-number {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--primary);
  color: white;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  font-size: 0.85rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 10px rgba(99, 102, 241, 0.4);
}

.flow-logo-badge {
  width: 64px;
  height: 64px;
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.2rem;
  border: 1px solid rgba(255, 255, 255, 0.15);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
}

/* User Uploaded Slack SVG Container */
.badge-slack {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.2);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
}

.badge-cloudflare {
  background: rgba(243, 128, 32, 0.18);
  border-color: rgba(243, 128, 32, 0.45);
}

.badge-antigravity {
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.25), rgba(99, 102, 241, 0.25));
  border-color: rgba(168, 85, 247, 0.5);
}

.badge-github {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.25);
}

.flow-step h4 {
  font-size: 1.15rem;
  margin-bottom: 0.6rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.flow-step p {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.flow-arrow {
  color: var(--primary);
  font-size: 1.5rem;
  opacity: 0.7;
  align-self: center;
}

/* Quick Setup Tabbed Section */
.setup-section {
  padding: 5rem 0;
}

.setup-box {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.setup-tabs {
  display: flex;
  background: rgba(10, 14, 24, 0.6);
  border-bottom: 1px solid var(--border);
}

.tab-btn {
  padding: 1.2rem 2rem;
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.tab-btn:hover {
  color: var(--text-main);
}

.tab-btn.active {
  color: #818cf8;
  border-bottom-color: var(--primary);
  background: rgba(99, 102, 241, 0.05);
}

.setup-content {
  padding: 2.5rem;
}

.tab-pane {
  display: none;
}

.tab-pane.active {
  display: block;
}

.code-block {
  background: var(--bg-terminal);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-sm);
  padding: 1.25rem 1.5rem;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: #38bdf8;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 1rem;
}

.copy-btn {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-main);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.8rem;
  font-weight: 500;
  transition: all 0.2s ease;
}

.copy-btn:hover {
  background: var(--primary);
  border-color: var(--primary);
}

/* Footer */
.footer {
  border-top: 1px solid var(--border);
  padding: 4rem 0 2rem;
  margin-top: 4rem;
  color: var(--text-muted);
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.status-indicator {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.2);
  padding: 0.3rem 0.8rem;
  border-radius: var(--radius-full);
  color: #4ade80;
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 8px #22c55e;
}

/* Responsive Media Queries */
@media (max-width: 900px) {
  .hero h1 { font-size: 2.8rem; }
  .flow-diagram { flex-direction: column; }
  .flow-arrow { transform: rotate(90deg); margin: 0.5rem 0; }
  .nav-links { display: none; }
}

@media (max-width: 600px) {
  .hero h1 { font-size: 2.2rem; }
  .hero p.lead { font-size: 1rem; }
  .slack-body { padding: 1.25rem; }
  .setup-content { padding: 1.5rem; }
}
