@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&display=swap');

/* --- Root Variable Definitions (Default Dark Mode) --- */
:root {
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  
  /* Theme Tokens */
  --bg-main: #070a13;
  --bg-secondary: #0d1222;
  --bg-card: rgba(15, 22, 42, 0.65);
  --bg-input: rgba(30, 41, 59, 0.5);
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --border-color: rgba(255, 255, 255, 0.06);
  --border-hover: rgba(255, 255, 255, 0.12);
  --shadow-main: 0 20px 40px -15px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 25px rgba(99, 102, 241, 0.15);
  --glass-blur: 16px;
  
  /* Dynamic Accent Colors (Default: Indigo HSL: 245, 80%, 60%) */
  --accent-h: 245;
  --accent-s: 80%;
  --accent-l: 60%;
  --accent-color: hsl(var(--accent-h), var(--accent-s), var(--accent-l));
  --accent-hover: hsl(var(--accent-h), var(--accent-s), calc(var(--accent-l) - 8%));
  --accent-soft: hsla(var(--accent-h), var(--accent-s), var(--accent-l), 0.1);
  --accent-soft-border: hsla(var(--accent-h), var(--accent-s), var(--accent-l), 0.2);
  --accent-gradient: linear-gradient(135deg, hsl(var(--accent-h), var(--accent-s), var(--accent-l)) 0%, hsl(calc(var(--accent-h) + 30), var(--accent-s), calc(var(--accent-l) - 5%)) 100%);
  
  /* Feature Color Accents */
  --color-analytics: #8b5cf6;
  --color-stock: #10b981;
  --color-sales: #0ea5e9;
  --color-loyalty: #f59e0b;
  --color-compliance: #ec4899;
}

/* --- Light Mode Tokens Override --- */
html.light-theme {
  --bg-main: #f8fafc;
  --bg-secondary: #f1f5f9;
  --bg-card: rgba(255, 255, 255, 0.75);
  --bg-input: rgba(255, 255, 255, 0.9);
  --text-main: #0f172a;
  --text-muted: #64748b;
  --border-color: rgba(0, 0, 0, 0.08);
  --border-hover: rgba(0, 0, 0, 0.15);
  --shadow-main: 0 20px 40px -15px rgba(15, 23, 42, 0.08);
  --shadow-glow: 0 0 25px hsla(var(--accent-h), var(--accent-s), var(--accent-l), 0.1);
  --accent-l: 55%; /* Slightly darker text for light mode contrast */
  --accent-soft: hsla(var(--accent-h), var(--accent-s), var(--accent-l), 0.06);
  --accent-soft-border: hsla(var(--accent-h), var(--accent-s), var(--accent-l), 0.15);
}

/* --- Reset & Global --- */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  transition: background-color 0.3s ease, border-color 0.3s ease;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-main);
  color: var(--text-main);
  line-height: 1.6;
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

/* --- Typography --- */
h1, h2, h3, h4 {
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.25;
}

.gradient-text {
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* --- Layout & Utilities --- */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.section {
  padding: 100px 0;
  position: relative;
}

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

.section-title {
  font-size: 2.5rem;
  margin-bottom: 16px;
}

.section-subtitle {
  font-size: 1.125rem;
  color: var(--text-muted);
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 28px;
  border-radius: 9999px;
  font-weight: 600;
  font-size: 0.975rem;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  border: 1px solid transparent;
  gap: 8px;
}

.btn-primary {
  background: var(--accent-gradient);
  color: #ffffff;
  box-shadow: 0 4px 14px 0 hsla(var(--accent-h), var(--accent-s), var(--accent-l), 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px 0 hsla(var(--accent-h), var(--accent-s), var(--accent-l), 0.45), var(--shadow-glow);
}

.btn-secondary {
  background-color: var(--accent-soft);
  color: var(--accent-color);
  border-color: var(--accent-soft-border);
}

.btn-secondary:hover {
  background-color: hsla(var(--accent-h), var(--accent-s), var(--accent-l), 0.18);
  transform: translateY(-2px);
}

.btn-outline {
  background-color: transparent;
  color: var(--text-main);
  border-color: var(--border-color);
}

.btn-outline:hover {
  border-color: var(--accent-color);
  color: var(--accent-color);
  background-color: var(--accent-soft);
  transform: translateY(-2px);
}

/* --- Navigation Header --- */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background-color: var(--bg-card);
  backdrop-filter: blur(var(--glass-blur));
  border-bottom: 1px solid var(--border-color);
  transition: all 0.3s ease;
}

.header-scrolled {
  padding: 12px 0;
  box-shadow: var(--shadow-main);
}

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

.logo {
  display: flex;
  align-items: center;
  font-weight: 800;
  font-size: 1.35rem;
  letter-spacing: -0.03em;
  gap: 8px;
}

.logo-icon {
  width: 32px;
  height: 32px;
  background: var(--accent-gradient);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 800;
  font-size: 1.1rem;
}

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

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

.nav-links a:hover,
.nav-links a.active {
  color: var(--accent-color);
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -6px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent-gradient);
  transition: width 0.2s ease;
}

.nav-links a:hover::after,
.nav-links a.active::after {
  width: 100%;
}

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

/* Theme Switcher Toggle */
.theme-toggle {
  background: none;
  border: 1px solid var(--border-color);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-main);
  transition: all 0.2s ease;
}

.theme-toggle:hover {
  border-color: var(--accent-color);
  color: var(--accent-color);
  background-color: var(--accent-soft);
}

.theme-toggle .sun-icon {
  display: none;
}

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

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

/* --- Hero Section --- */
.hero {
  padding: 160px 0 100px 0;
  background: radial-gradient(circle at 80% 20%, hsla(var(--accent-h), var(--accent-s), var(--accent-l), 0.08) 0%, transparent 50%),
              radial-gradient(circle at 10% 80%, hsla(245, 80%, 60%, 0.03) 0%, transparent 40%);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  align-items: center;
  gap: 60px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  padding: 6px 16px;
  border-radius: 9999px;
  background-color: var(--accent-soft);
  color: var(--accent-color);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border: 1px solid var(--accent-soft-border);
  margin-bottom: 24px;
}

.hero-title {
  font-size: 3.8rem;
  line-height: 1.1;
  font-weight: 800;
  margin-bottom: 24px;
  letter-spacing: -0.04em;
}

.hero-description {
  font-size: 1.2rem;
  color: var(--text-muted);
  margin-bottom: 40px;
  max-width: 560px;
}

.hero-buttons {
  display: flex;
  gap: 16px;
  margin-bottom: 40px;
}

/* Brand Logo Ticker */
.hero-brands {
  border-top: 1px solid var(--border-color);
  padding-top: 24px;
}

.hero-brands-text {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 16px;
  font-weight: 600;
}

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

.brand-logo {
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text-muted);
  opacity: 0.6;
}

/* Custom CSS Device Mockup for Hero Gallery */
.device-mockup {
  position: relative;
  background: #1e293b;
  border-radius: 16px;
  padding: 6px;
  box-shadow: var(--shadow-main), 0 0 40px rgba(0, 0, 0, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.1);
  transform: perspective(1000px) rotateY(-5deg) rotateX(5deg);
  transition: all 0.5s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.device-mockup:hover {
  transform: perspective(1000px) rotateY(0deg) rotateX(0deg) scale(1.02);
  box-shadow: var(--shadow-main), 0 0 50px hsla(var(--accent-h), var(--accent-s), var(--accent-l), 0.15);
}

.device-header {
  height: 24px;
  display: flex;
  align-items: center;
  padding: 0 12px;
  background: #0f172a;
  border-top-left-radius: 12px;
  border-top-right-radius: 12px;
  gap: 6px;
}

.device-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}
.device-dot.red { background: #ef4444; }
.device-dot.yellow { background: #f59e0b; }
.device-dot.green { background: #10b981; }

.device-content {
  background: #090d16;
  border-bottom-left-radius: 12px;
  border-bottom-right-radius: 12px;
  overflow: hidden;
  position: relative;
  aspect-ratio: 16 / 9;
}

.device-slider {
  display: flex;
  width: 500%;
  height: 100%;
  transition: transform 0.8s cubic-bezier(0.77, 0, 0.175, 1);
}

.device-slide {
  width: 20%;
  height: 100%;
  flex-shrink: 0;
}

.device-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.device-nav {
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 10;
}

.device-nav-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  cursor: pointer;
  border: none;
  transition: all 0.3s ease;
}

.device-nav-dot.active {
  background: var(--accent-color);
  width: 20px;
  border-radius: 4px;
}

/* --- Features Grid Section --- */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 32px;
}

.feature-card {
  background: var(--bg-card);
  backdrop-filter: blur(var(--glass-blur));
  border: 1px solid var(--border-color);
  border-radius: 20px;
  padding: 32px;
  position: relative;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: var(--shadow-main);
  display: flex;
  flex-direction: column;
}

.feature-card:hover {
  transform: translateY(-6px);
  border-color: var(--accent-soft-border);
  box-shadow: var(--shadow-main), var(--shadow-glow);
}

.feature-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: var(--accent-gradient);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.feature-card:hover::before {
  opacity: 1;
}

.feature-icon-wrapper {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  margin-bottom: 24px;
  font-size: 1.25rem;
}

.feature-title {
  font-size: 1.35rem;
  margin-bottom: 12px;
}

.feature-description {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 24px;
  flex-grow: 1;
}

.feature-list {
  list-style: none;
  border-top: 1px solid var(--border-color);
  padding-top: 20px;
}

.feature-list-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.9rem;
  color: var(--text-main);
  margin-bottom: 12px;
}

.feature-list-item:last-child {
  margin-bottom: 0;
}

.feature-list-check {
  color: var(--accent-color);
  flex-shrink: 0;
  margin-top: 3px;
  font-weight: bold;
}

.feature-list-item strong {
  display: block;
  font-weight: 600;
  margin-bottom: 2px;
}

.feature-list-item span {
  color: var(--text-muted);
}

/* --- Interactive Workspace Sandbox --- */
.sandbox {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
  position: relative;
  overflow: hidden;
}

.sandbox-layout {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 60px;
  align-items: flex-start;
}

.sandbox-controls {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

.sandbox-control-card {
  background: var(--bg-card);
  backdrop-filter: blur(var(--glass-blur));
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 24px;
}

.sandbox-control-card.active-panel {
  border-color: var(--accent-soft-border);
  box-shadow: 0 0 20px hsla(var(--accent-h), var(--accent-s), var(--accent-l), 0.1);
}

.sandbox-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
  cursor: pointer;
}

.sandbox-header h3 {
  font-size: 1.15rem;
  font-weight: 700;
}

.sandbox-icon {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background-color: var(--accent-soft);
  color: var(--accent-color);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}

.sandbox-body {
  margin-top: 16px;
}

/* Styles for individual simulators */
/* 1. Theme Settings accent dots */
.accent-picker {
  display: flex;
  gap: 16px;
  margin-top: 12px;
}

.accent-dot {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 2px solid transparent;
  cursor: pointer;
  position: relative;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.accent-dot:hover {
  transform: scale(1.15);
}

.accent-dot.active {
  border-color: var(--text-main);
  transform: scale(1.1);
}

.accent-dot::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: white;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.accent-dot.active::after {
  opacity: 1;
}

.dot-indigo { background-color: hsl(245, 80%, 60%); }
.dot-emerald { background-color: hsl(150, 80%, 40%); }
.dot-ocean { background-color: hsl(200, 85%, 50%); }
.dot-orange { background-color: hsl(25, 90%, 55%); }
.dot-purple { background-color: hsl(275, 75%, 60%); }

/* 2. Number Series Inputs */
.form-group {
  margin-bottom: 16px;
}

.form-group:last-child {
  margin-bottom: 0;
}

.form-label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.form-input {
  width: 100%;
  padding: 10px 14px;
  border-radius: 8px;
  border: 1px solid var(--border-color);
  background-color: var(--bg-input);
  color: var(--text-main);
  font-family: inherit;
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.2s ease;
}

.form-input:focus {
  border-color: var(--accent-color);
}

/* 3. Invoice Layout select */
.form-select {
  width: 100%;
  padding: 10px 14px;
  border-radius: 8px;
  border: 1px solid var(--border-color);
  background-color: var(--bg-input);
  color: var(--text-main);
  font-family: inherit;
  font-size: 0.95rem;
  outline: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2394a3b8'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 16px;
  cursor: pointer;
}

.form-select:focus {
  border-color: var(--accent-color);
}

/* 4. SMTP configuration */
.smtp-btn-row {
  margin-top: 16px;
}

/* Sandbox Visualizer Output Panel */
.sandbox-visualizer {
  position: sticky;
  top: 100px;
  background: #0f172a;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: var(--shadow-main);
  overflow: hidden;
}

.visualizer-header {
  background: #090d16;
  padding: 16px 24px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.visualizer-title {
  font-size: 0.9rem;
  font-weight: 700;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 8px;
}

.visualizer-title::before {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-color);
  box-shadow: 0 0 8px var(--accent-color);
}

.visualizer-body {
  padding: 32px;
  min-height: 420px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle at center, rgba(15, 23, 42, 0.8) 0%, #070a13 100%);
}

/* Virtual invoice rendering */
.virtual-invoice {
  width: 100%;
  max-width: 360px;
  background: #ffffff;
  color: #1e293b;
  border-radius: 12px;
  padding: 24px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.25);
  font-size: 0.85rem;
  transition: all 0.3s ease;
  position: relative;
}

/* Theme styling for mock invoice */
.virtual-invoice.layout-standard {
  font-family: var(--font-sans);
  border-top: 6px solid var(--accent-color);
}

.virtual-invoice.layout-thermal {
  font-family: 'Courier New', Courier, monospace;
  background: #fdfdfd;
  border-top: 1px dashed #64748b;
  border-bottom: 1px dashed #64748b;
  color: #000;
}

.virtual-invoice.layout-modern {
  font-family: var(--font-sans);
  background: linear-gradient(to bottom, #fafafa 0%, #ffffff 100%);
  border-left: 6px solid var(--accent-color);
}

.invoice-header {
  display: flex;
  justify-content: space-between;
  border-bottom: 1px solid #e2e8f0;
  padding-bottom: 16px;
  margin-bottom: 16px;
}

.layout-thermal .invoice-header {
  flex-direction: column;
  align-items: center;
  border-bottom: 1px dashed #000;
  text-align: center;
}

.invoice-logo {
  font-weight: 800;
  font-size: 1rem;
}

.layout-standard .invoice-logo { color: var(--accent-color); }
.layout-modern .invoice-logo { color: #0f172a; font-weight: 900; }
.layout-thermal .invoice-logo { color: #000; text-transform: uppercase; }

.invoice-meta {
  text-align: right;
}

.layout-thermal .invoice-meta {
  text-align: center;
  margin-top: 8px;
}

.invoice-meta div {
  margin-bottom: 4px;
}

.invoice-items {
  margin-bottom: 20px;
}

.invoice-item-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 8px;
}

.invoice-item-name {
  font-weight: 500;
}

.layout-thermal .invoice-item-row {
  border-bottom: 1px dotted #000;
  padding-bottom: 4px;
}

.invoice-totals {
  border-top: 1px solid #e2e8f0;
  padding-top: 12px;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
}

.layout-thermal .invoice-totals {
  border-top: 1px dashed #000;
}

.invoice-total-row {
  display: flex;
  justify-content: space-between;
  width: 140px;
}

.invoice-total-row.grand {
  font-weight: 700;
  font-size: 1rem;
  color: #0f172a;
}

.layout-standard .invoice-total-row.grand { color: var(--accent-color); }

/* Virtual number series rendering */
.virtual-numbers {
  text-align: center;
  width: 100%;
}

.virtual-counter {
  font-size: 3.5rem;
  font-weight: 800;
  font-family: monospace;
  letter-spacing: 0.05em;
  color: #fff;
  text-shadow: 0 0 20px hsla(var(--accent-h), var(--accent-s), var(--accent-l), 0.5);
  margin-bottom: 16px;
}

.virtual-series-list {
  background: rgba(0, 0, 0, 0.2);
  border-radius: 12px;
  padding: 16px;
  max-width: 320px;
  margin: 0 auto;
  text-align: left;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.virtual-series-item {
  display: flex;
  justify-content: space-between;
  font-family: monospace;
  font-size: 0.95rem;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.virtual-series-item:last-child {
  margin-bottom: 0;
}

.virtual-series-item.active {
  color: var(--accent-color);
  font-weight: 700;
}

/* Virtual Email rendering */
.virtual-email {
  width: 100%;
  max-width: 360px;
  background: #1e293b;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.35);
  overflow: hidden;
  text-align: left;
}

.email-header {
  background: #0f172a;
  padding: 12px 16px;
  font-size: 0.8rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.email-header-line {
  margin-bottom: 6px;
  color: var(--text-muted);
}

.email-header-line:last-child {
  margin-bottom: 0;
}

.email-header-line span {
  color: #fff;
  font-weight: 500;
}

.email-body {
  padding: 20px;
  background: #ffffff;
  color: #334155;
  font-size: 0.85rem;
}

.email-status {
  padding: 12px 16px;
  background: #0f172a;
  color: var(--text-muted);
  font-size: 0.8rem;
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.email-status-light {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #64748b;
}

.email-status.ready .email-status-light { background: #eab308; box-shadow: 0 0 8px #eab308; }
.email-status.sending .email-status-light { background: #3b82f6; box-shadow: 0 0 8px #3b82f6; animation: pulse 1s infinite alternate; }
.email-status.success .email-status-light { background: #10b981; box-shadow: 0 0 8px #10b981; }

@keyframes pulse {
  0% { opacity: 0.4; }
  100% { opacity: 1; }
}

/* --- Screenshot Gallery Section --- */
.gallery {
  background: radial-gradient(circle at 20% 80%, hsla(var(--accent-h), var(--accent-s), var(--accent-l), 0.04) 0%, transparent 40%);
}

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

.gallery-card {
  background: var(--bg-card);
  backdrop-filter: blur(var(--glass-blur));
  border: 1px solid var(--border-color);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow-main);
  transition: all 0.3s ease;
}

.gallery-card:hover {
  transform: translateY(-4px);
  border-color: var(--accent-soft-border);
  box-shadow: var(--shadow-main), 0 0 20px hsla(var(--accent-h), var(--accent-s), var(--accent-l), 0.1);
}

.gallery-image-wrapper {
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-bottom: 1px solid var(--border-color);
  background: #090d16;
  cursor: zoom-in;
  position: relative;
}

.gallery-image-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.gallery-card:hover .gallery-image-wrapper img {
  transform: scale(1.05);
}

.gallery-info {
  padding: 20px;
}

.gallery-badge {
  display: inline-block;
  padding: 4px 10px;
  background-color: var(--accent-soft);
  color: var(--accent-color);
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: 4px;
  margin-bottom: 8px;
  border: 1px solid var(--accent-soft-border);
}

.gallery-title {
  font-size: 1.15rem;
  margin-bottom: 8px;
}

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

/* --- CTA Section --- */
.cta {
  background: var(--accent-gradient);
  color: #ffffff;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.cta::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(circle at 20% 30%, rgba(255, 255, 255, 0.15) 0%, transparent 40%),
              radial-gradient(circle at 80% 70%, rgba(0, 0, 0, 0.25) 0%, transparent 50%);
}

.cta-content {
  position: relative;
  z-index: 2;
  max-width: 650px;
  margin: 0 auto;
}

.cta-title {
  font-size: 2.75rem;
  margin-bottom: 16px;
  font-weight: 800;
}

.cta-desc {
  font-size: 1.15rem;
  margin-bottom: 32px;
  opacity: 0.9;
}

.cta .btn-primary {
  background: #ffffff;
  color: #0b0f19;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.15);
}

.cta .btn-primary:hover {
  background: #f8fafc;
  color: #0b0f19;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
}

.cta .btn-outline {
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.4);
}

.cta .btn-outline:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: #ffffff;
  color: #ffffff;
}

/* --- Footer --- */
.footer {
  background-color: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  padding: 60px 0 30px 0;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.1fr 1.4fr;
  gap: 60px;
  margin-bottom: 40px;
}

.footer-col h4 {
  color: var(--text-main);
  margin-bottom: 20px;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.footer-desc {
  margin-top: 16px;
  font-size: 0.875rem;
}

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: 12px;
}

.footer-links a {
  transition: color 0.2s ease;
}

.footer-links a:hover {
  color: var(--accent-color);
}

.footer-bottom {
  border-top: 1px solid var(--border-color);
  padding-top: 30px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.85rem;
}

/* --- Lightbox Modal --- */
.lightbox {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(7, 10, 19, 0.9);
  backdrop-filter: blur(8px);
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 40px;
}

.lightbox.active {
  display: flex;
}

.lightbox-content {
  max-width: 90%;
  max-height: 80vh;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.8);
  object-fit: contain;
}

.lightbox-close {
  position: absolute;
  top: 30px;
  right: 30px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  border: none;
  color: #fff;
  font-size: 1.5rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.2s ease;
}

.lightbox-close:hover {
  background: rgba(255, 255, 255, 0.2);
}

/* --- Media Queries for Mobile Responsiveness --- */
@media (max-width: 1024px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 40px;
    text-align: center;
  }
  
  .hero-description {
    margin-left: auto;
    margin-right: auto;
  }
  
  .hero-buttons {
    justify-content: center;
  }
  
  .brand-logos {
    justify-content: center;
  }
  
  .device-mockup {
    transform: none;
    max-width: 600px;
    margin: 0 auto;
  }
  
  .device-mockup:hover {
    transform: scale(1.01);
  }
  
  .sandbox-layout {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  
  .sandbox-visualizer {
    position: static;
  }
}

@media (max-width: 768px) {
  .section {
    padding: 60px 0;
  }
  
  .hero-title {
    font-size: 2.8rem;
  }
  
  .nav-links {
    display: none; /* In a real app we'd add a mobile hamburger menu */
  }
  
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }
  
  .footer-bottom {
    flex-direction: column;
    gap: 16px;
    text-align: center;
  }
}

/* --- Footer Demo Form Styling --- */
.footer-demo-col {
  display: flex;
  justify-content: flex-end;
}

.footer-demo-card {
  width: 100%;
  max-width: 480px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 24px;
  box-shadow: var(--shadow-main);
  backdrop-filter: blur(var(--glass-blur));
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.footer-demo-card:hover {
  border-color: var(--accent-soft-border);
  box-shadow: var(--shadow-main), 0 0 20px hsla(var(--accent-h), var(--accent-s), var(--accent-l), 0.05);
}

html.light-theme .footer-demo-card {
  background: rgba(0, 0, 0, 0.015);
}

.footer-demo-card h4 {
  color: var(--text-main);
  margin-bottom: 4px;
  font-size: 1.15rem;
  font-weight: 700;
}

.footer-form-group {
  margin-bottom: 12px;
}

.footer-input {
  font-size: 0.85rem;
  padding: 10px 14px;
}

.footer-btn {
  transition: all 0.25s ease;
}

@media (max-width: 768px) {
  .footer-demo-col {
    justify-content: center;
  }
}
