/* =============================================
   Base64Coder Landing Page — Styles
   ============================================= */

/* --- CSS Variables --- */
:root {
  --bg-primary: #0a0a0f;
  --bg-secondary: #111118;
  --bg-card: #16161f;
  --bg-card-hover: #1e1e2a;
  --bg-elevated: #1c1c28;
  --border: #252536;
  --border-light: #2e2e42;
  
  --text-primary: #e8e8ed;
  --text-secondary: #a0a0b4;
  --text-muted: #6b6b80;
  
  --accent: #34d399;
  --accent-glow: rgba(52, 211, 153, 0.25);
  --accent-dim: rgba(52, 211, 153, 0.1);
  --green: #34d399;
  --green-dim: rgba(52, 211, 153, 0.15);
  --red: #f87171;
  --yellow: #fbbf24;
  --orange: #fb923c;
  --purple: #a78bfa;
  --pink: #f472b6;
  
  --radius-sm: 8px;
  --radius: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  
  --transition: 0.2s ease;
  --transition-slow: 0.35s ease;
  
  --max-width: 1200px;
  --nav-height: 64px;
}

/* --- Reset & Base --- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--nav-height);
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { 
  text-decoration: none; 
  color: inherit; 
}

img { 
  display: block; 
  max-width: 100%; 
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: var(--radius);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all var(--transition);
  white-space: nowrap;
}

.btn-primary {
  background: var(--accent);
  color: #0a0a0f;
  box-shadow: 0 0 20px var(--accent-glow);
}
.btn-primary:hover {
  background: #6ee7b7;
  box-shadow: 0 0 30px rgba(52, 211, 153, 0.4);
  transform: translateY(-1px);
}

.btn-outline {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border-light);
}
.btn-outline:hover {
  background: var(--bg-card);
  border-color: var(--text-muted);
  transform: translateY(-1px);
}

.btn-lg {
  padding: 14px 28px;
  font-size: 1rem;
  border-radius: var(--radius-lg);
}

/* --- Navigation --- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  height: var(--nav-height);
  transition: background var(--transition-slow), box-shadow var(--transition-slow);
}
.nav.scrolled {
  background: rgba(10, 10, 15, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 1px 0 var(--border);
}

.nav-container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text-primary);
}

.nav-logo span {
   margin-top: 5px;
}

.nav-links {
  display: flex;
  gap: 32px;
}

.nav-links a {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: color var(--transition);
}
.nav-links a:hover { color: var(--text-primary); }

.nav-cta {
  font-size: 0.85rem !important;
  padding: 8px 16px !important;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: var(--transition);
}

/* --- Hero --- */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 120px 24px 80px;
  position: relative;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 50% -20%, rgba(52, 211, 153, 0.08), transparent),
    radial-gradient(ellipse 40% 50% at 80% 80%, rgba(16, 185, 129, 0.06), transparent),
    radial-gradient(ellipse 30% 40% at 20% 50%, rgba(52, 211, 153, 0.04), transparent);
  pointer-events: none;
}

.hero-container {
  max-width: var(--max-width);
  position: relative;
  z-index: 1;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--green-dim);
  color: var(--green);
  padding: 6px 14px;
  border-radius: 100px;
  font-size: 0.8rem;
  font-weight: 600;
  margin-bottom: 28px;
  border: 1px solid rgba(52, 211, 153, 0.2);
}

.hero-title {
  font-size: clamp(2.2rem, 5vw, 3.4rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
  margin-bottom: 20px;
}

.hero-highlight {
  background: linear-gradient(135deg, var(--accent), #10b981);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: 1.1rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 32px;
  max-width: 520px;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 48px;
}

.hero-stats {
  display: flex;
  gap: 36px;
}

.stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.stat-value {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--text-primary);
  font-family: 'JetBrains Mono', 'Fira Code', monospace;
}
.stat-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* Hero Visual Card */
.hero-visual {
  position: relative;
  z-index: 1;
  margin-left: 60px;
  display: none;
}

@media (min-width: 1024px) {
  .hero {
    justify-content: center;
    gap: 40px;
  }
  .hero-visual {
    display: block;
  }
}

.hero-card {
  background: #333;
  border: 1px solid #555;
  border-radius: var(--radius-xl);
  width: 380px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  overflow: hidden;
}

.hero-card-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  background: #3d3d3d;
  border-bottom: 1px solid #555;
}

.hero-card-dots {
  display: flex;
  gap: 6px;
}
.hero-card-dots span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.hero-card-dots span:nth-child(1) { background: #f87171; }
.hero-card-dots span:nth-child(2) { background: #fbbf24; }
.hero-card-dots span:nth-child(3) { background: #34d399; }

.hero-card-title {
  font-size: 0.75rem;
  color: #aaa;
  margin-left: 8px;
}

.hero-card-body {
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* --- Hero Card Internals --- */
.hc-label {
  display: block;
  font-size: 0.7rem;
  font-weight: 600;
  color: #ccc;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 5px;
}

.hc-textarea {
  background: #454545;
  border: 1px solid #888;
  border-radius: 5px;
  padding: 10px 12px;
  min-height: 48px;
}

.hc-placeholder {
  font-size: 0.8rem;
  color: #999;
}

.hc-formats {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.hc-fmt {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: #3d3d3d;
  border: none;
  border-radius: 5px;
  transition: background 0.1s;
  cursor: default;
}
.hc-fmt img {
  filter: invert(90%);
  transition: filter 0.1s;
}
.hc-fmt.active {
  background: #4d4d4d;
}
.hc-fmt.active img { filter: invert(100%); }
.hc-fmt:hover { background: #4d4d4d; }
.hc-fmt:hover img { filter: invert(100%); }

.hc-result-box {
  background: #454545;
  border: 1px solid #888;
  border-radius: 5px;
  padding: 10px 12px;
  min-height: 42px;
  display: flex;
  align-items: center;
}

.hc-result-text {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.78rem;
  color: #ccc;
  word-break: break-all;
}
.hc-result-text.accent { color: #34d399; }

.hc-actions {
  display: flex;
  gap: 6px;
  margin-top: 8px;
}

.hc-action {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: #3d3d3d;
  border: none;
  border-radius: 5px;
  cursor: default;
  transition: background 0.1s;
}
.hc-action img {
  filter: invert(90%);
  transition: filter 0.1s;
}
.hc-action:hover { background: #4d4d4d; }
.hc-action:hover img { filter: invert(100%); }

.hc-footer {
  display: flex;
  justify-content: flex-end;
  padding-top: 2px;
  border-top: 1px solid transparent;
}

.hc-char-count {
  font-size: 0.7rem;
  color: #999;
}

/* --- Section Common --- */
.section-container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.section-header {
  text-align: center;
  margin-bottom: 56px;
}
.section-header h2 {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
}
.section-header p {
  color: var(--text-secondary);
  font-size: 1.05rem;
  max-width: 500px;
  margin: 0 auto;
}

.highlight {
  background: linear-gradient(135deg, var(--accent), #10b981);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* --- Video Showcase --- */
.video-showcase {
  padding: 80px 0;
  background: var(--bg-primary);
}

.video-wrapper {
  position: relative;
  max-width: 840px;
  margin: 0 auto;
}

.video-card {
  display: block;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 0 40px rgba(0, 0, 0, 0.5), 0 0 80px var(--accent-glow);
  border: 1px solid var(--border);
  transition: all var(--transition-slow);
  background: var(--bg-card);
}

.video-card:hover {
  border-color: var(--accent);
  box-shadow: 0 0 40px rgba(0, 0, 0, 0.5), 0 0 100px var(--accent-glow);
  transform: translateY(-2px);
}

.video-thumbnail {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #000;
}

.video-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.video-card:hover .video-thumbnail img {
  transform: scale(1.05);
}

.video-play-btn {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 80px;
  height: 80px;
  background: rgba(0, 0, 0, 0.7);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  transition: all var(--transition);
  backdrop-filter: blur(4px);
}

.video-card:hover .video-play-btn {
  background: var(--accent);
  color: #0a0a0f;
  transform: translate(-50%, -50%) scale(1.1);
}

.video-play-btn svg {
  margin-left: 4px;
}

.video-info {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 20px;
  color: var(--text-secondary);
  font-size: 0.9rem;
  border-top: 1px solid var(--border);
}

.video-info svg {
  color: var(--accent);
  flex-shrink: 0;
}

/* --- Features --- */
.features {
  padding: 100px 0;
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  transition: all var(--transition);
}
.feature-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-light);
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
}

.feature-icon {
  filter: brightness(0) invert(1);
  width: 52px;
  height: 52px;
  background: var(--accent-dim);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
}

.feature-card h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 10px;
}
.feature-card p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.65;
}

/* --- Supported Formats --- */
.formats {
  padding: 80px 0;
}

.formats-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
}

.format-item {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 20px;
  font-weight: 500;
  font-size: 0.9rem;
  transition: all var(--transition);
}
.format-item:hover {
  border-color: var(--accent);
  background: var(--bg-card-hover);
  transform: translateY(-1px);
}
.format-item img {
   filter: brightness(0) invert(1);
}

/* =============================================
   Try It — Live Demo (mirrors extension UI exactly)
   ============================================= */
.try-it {
  padding: 80px 0 100px;
  background: var(--bg-primary);
}

/* Card container — mimics the extension's popup page background */
.demo-card {
  max-width: 860px;
  margin: 0 auto;
  background: #333333;
  border: 1px solid #444;
  border-radius: var(--radius-xl);
  padding: 20px 28px 28px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
}

/* Drop overlay */
#demo-drop-overlay {
  position: fixed;
  z-index: 99;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  background: rgba(0, 0, 0, 0.5);
}

#demo-drop-overlay.active { display: flex; }

#demo-drop-overlay img {
  width: 120px;
  filter: invert(90%);
}

#demo-drop-overlay p {
  font-size: 1.1rem;
  font-weight: 700;
  color: #fff;
  margin-top: 10px;
}

/* Action areas — exactly like extension */
.demo-action-area {
  display: flex;
  flex-direction: column;
  width: 100%;
  margin-bottom: 6px;
  position: relative;
}

.demo-action-area .demo-action-area-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.demo-action-area .demo-action-area-header label {
  font-size: 1.5rem;
  font-weight: 700;
  color: #fff;
  margin: 0.5em 0;
  cursor: default;
}

.demo-action-area .demo-action-area-body {
  width: 100%;
  display: flex;
  flex-direction: column;
  position: relative;
}

/* Buttons — exactly like extension: 45x45, gray bg, no border */
.demo-btn {
  background: #3d3d3d;
  border: none;
  width: 45px;
  height: 45px;
  cursor: pointer;
  font-size: 20px;
  text-align: center;
  border-radius: 5px;
  margin-left: 5px;
  color: #fff;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  transition: background 0.1s;
  padding-top: 2px;
}

.demo-btn:hover {
  background: #4d4d4d !important;
}

.demo-btn img {
  width: 22px;
  height: 22px;
  filter: invert(90%);
}

.demo-btn span {
  font-size: 12px;
  display: block;
  margin-top: -2px;
  color: #ccc;
}

.demo-btn-panel {
  display: flex;
  align-items: center;
}

/* Textareas — extension style: #454545 bg, white text, gray border */
#demo-source,
#demo-result {
  word-wrap: break-word;
  overflow-x: hidden;
  overflow-y: auto;
  resize: vertical;
  width: 100%;
  min-height: 120px;
  max-height: 200px;
  border-radius: 5px;
  border: 1px solid #888;
  background: #454545;
  color: #fff;
  padding: 6px 8px;
  font-size: 13px;
  white-space: pre-wrap;
  font-family: 'Consolas', 'Courier New', monospace;
  outline: none;
  line-height: 1.4;
}

#demo-source:focus,
#demo-result:focus {
  border-color: #aaa;
}

#demo-source::placeholder {
  color: #999;
  font-family: 'Consolas', 'Courier New', monospace;
}

#demo-result:empty::before {
  content: 'Convert something to see the result here…';
  color: #999;
  font-family: 'Consolas', 'Courier New', monospace;
  pointer-events: none;
}

#demo-source-length,
#demo-result-length {
  position: absolute;
  right: 2px;
  bottom: -18px;
  color: #aaa;
  font-size: 0.7rem;
  font-family: 'Consolas', 'Courier New', monospace;
}

/* Convert actions row — like extension: 62x62 buttons */
.demo-actions {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  padding: 4px 0;
  width: auto;
}

.demo-convert-btn {
  width: 62px;
  height: 62px;
  background: #3d3d3d;
  margin-left: 0;
  border-radius: 5px;
}

.demo-convert-btn:hover {
  background: #4d4d4d !important;
}

.demo-convert-btn img {
  width: 34px;
  height: 34px;
}

.demo-convert-btn span {
  font-size: 12px;
  margin-top: -3px;
}

.demo-convert-btn.active {
  background: #4d4d4d !important;
}

.demo-btn.disabled {
  opacity: 0.35;
  cursor: not-allowed;
  pointer-events: none;
}

/* File info — shown when file is loaded, source hidden */
.demo-file-info {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 12px 0;
  gap: 6px;
}

.demo-file-info.active {
  display: flex;
}

.demo-file-info img {
  width: 28px;
  height: 28px;
  filter: invert(90%);
}

.demo-file-info label {
  font-size: 0.85rem !important;
  font-weight: 600 !important;
  color: #ccc;
  margin: 0 !important;
}

/* Source hidden state */
#demo-source[style*="display: none"] + #demo-source-length {
  display: none !important;
}

.demo-result-img-container {
  display: none;
  align-items: center;
  gap: 12px;
  padding: 8px;
  margin-top: 6px;
  background: #454545;
  border-radius: 5px;
  border: 1px solid #888;
}

.demo-result-img-container.active { display: flex; }

#demo-result-img {
  max-width: 160px;
  max-height: 120px;
  object-fit: contain;
}

.demo-result-img-meta {
  display: flex;
  flex-direction: column;
  font-size: 0.75rem;
  color: #ccc;
  gap: 3px;
}

.demo-result-img-meta strong {
  color: #fff;
  margin-bottom: 2px;
}

/* Floating panel */
.demo-floating-panel {
  position: fixed;
  bottom: 16px;
  right: 16px;
  display: flex;
  flex-direction: column;
  z-index: 50;
}

.demo-floating-panel .demo-btn {
  margin-top: 4px;
  background: #3d3d3d;
  border: none;
  border-radius: 5px;
  width: 42px;
  height: 42px;
}

.demo-floating-panel .demo-btn:hover {
  background: #4d4d4d !important;
}

.demo-floating-panel .demo-btn img {
  width: 20px;
  height: 20px;
}

.demo-floating-panel .demo-btn svg {
  width: 20px;
  height: 20px;
  stroke: #ccc;
}

/* Install banner */
.try-install-banner {
  text-align: center;
  margin-top: 28px;
  padding: 14px 20px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid #444;
  border-radius: var(--radius);
}

.try-install-banner p {
  color: #ccc;
  font-size: 0.88rem;
}

.try-install-banner a {
  color: var(--accent);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.try-install-banner a:hover {
  color: #6ee7b7;
}

/* =============================================
   Context Menu Section
   ============================================= */
.context-section {
  padding: 100px 0;
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.context-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.context-text h2 {
  font-size: clamp(1.6rem, 3.5vw, 2.2rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
}

.context-text > p {
  color: var(--text-secondary);
  margin-bottom: 24px;
  line-height: 1.7;
}

.context-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.context-features li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.5;
}

.context-features li strong {
  color: var(--text-primary);
}

/* --- Context Menu Visual Card --- */
.context-menu-card {
  background: #333333;
  border: 1px solid #555;
  border-radius: var(--radius-lg);
  padding: 6px 0;
  width: 260px;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.5);
  margin: 0 auto;
}

.context-menu-item {
  padding: 8px 16px;
  font-size: 0.82rem;
  color: #eee;
  cursor: default;
  transition: background 0.1s;
}

.context-menu-item:hover {
  background: #4d4d4d;
}

.context-menu-item.highlight-item {
  background: #4d4d4d;
  border-left: 3px solid var(--accent);
}

.context-menu-divider {
  height: 1px;
  background: #555;
  margin: 4px 12px;
}

.context-menu-item.muted {
  color: var(--text-muted);
}

.context-menu-divider {
  height: 1px;
  background: var(--border);
  margin: 4px 12px;
}

/* --- Responsive for new sections --- */
@media (max-width: 900px) {
  .context-content {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .context-visual {
    order: -1;
  }
}

@media (max-width: 768px) {
  .demo-card {
    padding: 12px 14px 18px;
    border-radius: var(--radius-lg);
  }
  .demo-action-area .demo-action-area-header label {
    font-size: 1.1rem;
  }
  .demo-convert-btn {
    width: 50px;
    height: 50px;
  }
  .demo-convert-btn img {
    width: 26px;
    height: 26px;
  }
  .demo-convert-btn span {
    font-size: 10px;
  }
  .demo-btn {
    width: 38px;
    height: 38px;
  }
  .demo-btn img {
    width: 18px;
    height: 18px;
  }
  .demo-btn span {
    font-size: 10px;
  }
  #demo-source,
  #demo-result {
    min-height: 80px;
    font-size: 12px;
    padding: 5px 6px;
  }
  .demo-floating-panel {
    display: none;
  }
  .context-menu-card {
    width: 100%;
    max-width: 260px;
  }
}

/* --- JWT Section --- */
.jwt-section {
  padding: 100px 0;
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.jwt-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.jwt-text h2 {
  font-size: clamp(1.6rem, 3.5vw, 2.2rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
}
.jwt-text > p {
  color: var(--text-secondary);
  margin-bottom: 24px;
  line-height: 1.7;
}

.jwt-features, .image-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.jwt-features li, .image-features li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  color: var(--text-secondary);
  font-size: 0.95rem;
}

/* JWT Visual Card */
.jwt-card {
  background: #333;
  border: 1px solid #555;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
}

.jwt-card-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  background: #3d3d3d;
  border-bottom: 1px solid #555;
  font-size: 0.8rem;
  color: #aaa;
}

.jwt-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.jwt-dot.red { background: #f87171; }
.jwt-dot.yellow { background: #fbbf24; }
.jwt-dot.green { background: #34d399; }

.jwt-card-body {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.jwt-segment {
  background: #454545;
  border-radius: 5px;
  padding: 12px 14px;
  border: 1px solid #888;
}

.jwt-label {
  display: inline-block;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  padding: 2px 8px;
  border-radius: 4px;
  margin-bottom: 8px;
  font-family: 'JetBrains Mono', monospace;
}
.jwt-label.header { background: rgba(251, 146, 60, 0.15); color: var(--orange); }
.jwt-label.payload { background: rgba(167, 139, 250, 0.15); color: var(--purple); }

.jwt-segment code {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.78rem;
  color: #ccc;
  line-height: 1.6;
  display: block;
}

/* --- Image Section --- */
.image-section {
  padding: 100px 0;
}

.image-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.image-text h2 {
  font-size: clamp(1.6rem, 3.5vw, 2.2rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
}
.image-text > p {
  color: var(--text-secondary);
  margin-bottom: 24px;
  line-height: 1.7;
}

/* Image Demo Browser */
.image-demo-browser {
  background: #333;
  border: 1px solid #555;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
}

.browser-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: #3d3d3d;
  border-bottom: 1px solid #555;
}

.browser-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.browser-dot.red { background: #f87171; }
.browser-dot.yellow { background: #fbbf24; }
.browser-dot.green { background: #34d399; }

.browser-url {
  font-size: 0.7rem;
  color: #aaa;
  margin-left: 8px;
  background: #454545;
  padding: 4px 10px;
  border-radius: 6px;
  flex: 1;
}

.browser-content {
  position: relative;
  padding: 12px;
  background: #1a1a2e;
}

.browser-img {
  width: 100%;
  height: 160px;
  background: linear-gradient(135deg, #2d2d4a, #1e3a5f, #2d4a3e);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
}
.browser-img::after {
  content: '🖼️';
  font-size: 3rem;
  opacity: 0.6;
}

.context-menu {
  position: absolute;
  bottom: 24px;
  left: 24px;
  background: #333;
  border: 1px solid #555;
  border-radius: 6px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.6);
  overflow: hidden;
}

.ctx-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  font-size: 0.8rem;
  white-space: nowrap;
  color: #eee;
}
.ctx-item kbd {
  margin-left: auto;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.7rem;
  padding: 2px 6px;
  background: #454545;
  border-radius: 4px;
  color: var(--text-muted);
  border: 1px solid var(--border);
}
.ctx-item:hover {
  background: #4d4d4d;
}

/* --- CTA Section --- */
.cta {
  padding: 100px 0;
}

.cta-card {
  background: linear-gradient(135deg, rgba(52, 211, 153, 0.08), rgba(16, 185, 129, 0.06));
  border: 1px solid var(--border-light);
  border-radius: var(--radius-xl);
  padding: 56px 40px;
  text-align: center;
}

.cta-card h2 {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
}

.cta-card > p {
  color: var(--text-secondary);
  font-size: 1.05rem;
  margin-bottom: 32px;
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
}

.cta-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

.cta-privacy {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 500;
}

.cta-privacy svg {
   margin-left: -35px;
}

/* --- FAQ --- */
.faq {
  padding: 100px 0;
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.faq-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 16px;
  max-width: 900px;
  margin: 0 auto;
}

.faq-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  transition: var(--transition);
}
.faq-item:hover {
  border-color: var(--border-light);
}

.faq-item h3 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 8px;
}
.faq-item p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.65;
}

/* --- Footer --- */
.footer {
  padding: 60px 0 32px;
  background: var(--bg-primary);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 40px;
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}
.footer-logo span {
  font-weight: 700;
  font-size: 1.1rem;
}

.footer-brand p {
  color: var(--text-muted);
  font-size: 0.9rem;
  max-width: 280px;
}

.footer-links h4 {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 14px;
}
.footer-links a {
  display: block;
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 10px;
  transition: color var(--transition);
}
.footer-links a:hover { color: var(--text-primary); }

.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 24px;
  text-align: center;
}
.footer-bottom p {
  color: var(--text-muted);
  font-size: 0.8rem;
}

/* --- Responsive --- */
@media (max-width: 900px) {
  .jwt-content,
  .image-content {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .image-visual { order: -1; }
  
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }
}

@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-cta { display: none; }
  .nav-toggle { display: flex; }
  
  .nav.open .nav-links {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: var(--nav-height);
    left: 0;
    right: 0;
    background: var(--bg-card);
    border-bottom: 1px solid var(--border);
    padding: 20px 24px;
    gap: 16px;
  }
  .nav.open .nav-cta {
    display: flex;
  }
  
  .hero {
    padding: 100px 20px 60px;
    flex-direction: column;
    text-align: center;
  }
  .hero-container {
    max-width: 100%;
  }
  .hero-subtitle {
    max-width: 100%;
  }
  .hero-actions {
    justify-content: center;
  }
  .hero-stats {
    justify-content: center;
    flex-wrap: wrap;
    gap: 20px;
  }
  .hero-visual {
    margin-left: 0;
    margin-top: 40px;
  }
  .hero-card {
    width: 100%;
    max-width: 380px;
  }
  
  .cta-card {
    padding: 36px 24px;
  }
  
  .features-grid {
    grid-template-columns: 1fr;
  }
  
  .faq-grid {
    grid-template-columns: 1fr;
  }
  
  .footer-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .hero-title {
    font-size: 1.8rem;
  }
  .hero-actions {
    flex-direction: column;
  }
  .hero-actions .btn {
    justify-content: center;
  }
  .section-header h2 {
    font-size: 1.5rem;
  }
  .video-showcase {
    padding: 50px 16px;
  }
}

/* --- Animations --- */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.feature-card, .faq-item, .format-item {
  animation: fadeInUp 0.5s ease backwards;
}

.feature-card:nth-child(1) { animation-delay: 0.05s; }
.feature-card:nth-child(2) { animation-delay: 0.1s; }
.feature-card:nth-child(3) { animation-delay: 0.15s; }
.feature-card:nth-child(4) { animation-delay: 0.2s; }
.feature-card:nth-child(5) { animation-delay: 0.25s; }
.feature-card:nth-child(6) { animation-delay: 0.3s; }

