/* ==========================================================================
   بهاچین — Landing Page Styles
   RTL · Vazirmatn · Light/Dark theme based on the plugin palette
   ========================================================================== */

@font-face {
  font-family: 'Vazirmatn';
  src: url('../fonts/Vazirmatn-var.woff2') format('woff2');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --blue:        #2563eb;
  --blue-dark:   #1d4ed8;
  --blue-deeper: #1e3a8a;
  --blue-mid:    #3b82f6;
  --blue-light:  #eff6ff;
  --blue-pale:   #dbeafe;

  --green:       #16a34a;
  --green-soft:  #dcfce7;
  --red:         #dc2626;
  --red-soft:    #fee2e2;
  --amber:       #d97706;
  --amber-soft:  #fef9c3;

  --bg:          #f1f5f9;
  --surface:     #ffffff;
  --surface-2:   #f8fafc;
  --text:        #1e293b;
  --muted:       #64748b;
  --border:      #e2e8f0;

  --hero-grad: linear-gradient(165deg, #dbeafe 0%, #bfdbfe 32%, #e0efff 62%, #eff6ff 100%);
  --nav-bg: rgba(255, 255, 255, .82);

  --shadow-sm: 0 1px 3px rgba(15, 23, 42, .06), 0 1px 2px rgba(15, 23, 42, .04);
  --shadow-md: 0 10px 30px -8px rgba(15, 23, 42, .14);
  --shadow-lg: 0 24px 60px -18px rgba(15, 23, 42, .22);

  --radius:    16px;
  --radius-sm: 10px;
  --nav-h:     68px;
  --font: 'Vazirmatn', Tahoma, 'Segoe UI', Arial, sans-serif;
}

[data-theme="dark"] {
  --blue-light: #132038;
  --blue-pale:  #1b2c4d;

  --green-soft: #0b2e1d;
  --red-soft:   #3a1216;
  --amber-soft: #3a2a08;

  --bg:        #0b1120;
  --surface:   #111a2c;
  --surface-2: #0e1626;
  --text:      #e6edf6;
  --muted:     #93a4bd;
  --border:    #28324d;

  --hero-grad: linear-gradient(165deg, #0b1120 0%, #0f1e3c 42%, #0c1529 100%);
  --nav-bg: rgba(11, 17, 32, .82);

  --shadow-sm: 0 1px 3px rgba(0, 0, 0, .35);
  --shadow-md: 0 10px 30px -8px rgba(0, 0, 0, .5);
  --shadow-lg: 0 24px 60px -18px rgba(0, 0, 0, .6);
}

/* ---------- Reset & base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 16px); }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.85;
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; }
a { color: var(--blue); text-decoration: none; }
h1, h2, h3, h4 { margin: 0; line-height: 1.45; }
p { margin: 0; }
ul { margin: 0; padding: 0; }
button, input, select { font-family: inherit; }
button { cursor: pointer; }
code {
  direction: ltr; unicode-bidi: embed;
  background: var(--blue-light); color: var(--blue-dark);
  padding: 1px 6px; border-radius: 5px; font-size: .85em;
}
:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
::selection { background: var(--blue-pale); color: var(--blue-deeper); }

.icon-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.ic {
  width: 1.15em; height: 1.15em;
  fill: none; stroke: currentColor;
  stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round;
  vertical-align: -2px; flex-shrink: 0;
}

.container { max-width: 1180px; margin: 0 auto; padding: 0 24px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 46px; padding: 0 22px;
  border-radius: 11px; border: 1.5px solid transparent;
  font-size: 14px; font-weight: 700; line-height: 1;
  cursor: pointer; white-space: nowrap;
  transition: transform .15s, box-shadow .15s, background .15s, border-color .15s, color .15s;
}
.btn .ic { width: 1.1em; height: 1.1em; }
.btn-primary {
  background: linear-gradient(135deg, var(--blue-dark) 0%, var(--blue-mid) 100%);
  color: #fff; box-shadow: 0 6px 18px -6px rgba(37, 99, 235, .55);
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 10px 24px -6px rgba(37, 99, 235, .6); }
.btn-secondary {
  background: var(--surface); color: var(--blue); border-color: var(--blue);
}
.btn-secondary:hover { background: var(--blue-light); transform: translateY(-1px); }
.btn-ghost {
  background: var(--surface); color: var(--muted); border-color: var(--border);
}
.btn-ghost:hover { border-color: #94a3b8; color: var(--text); background: var(--bg); }
.btn-light { background: #fff; color: var(--blue-deeper); box-shadow: 0 10px 24px -8px rgba(2, 6, 23, .4); }
.btn-light:hover { transform: translateY(-1px); background: #f8fafc; }
.btn-outline-light { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .55); }
.btn-outline-light:hover { background: rgba(255, 255, 255, .12); }
.btn-sm { height: 38px; padding: 0 14px; font-size: 12.5px; border-radius: 9px; }
.btn-xs { height: 28px; padding: 0 10px; font-size: 11px; border-radius: 7px; }

/* ---------- Nav ---------- */
.site-nav {
  position: sticky; top: 0; z-index: 100;
  background: var(--nav-bg);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}
.nav-inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; height: var(--nav-h); }
.brand { display: inline-flex; align-items: center; gap: 11px; }
.brand-logo {
  width: 42px; height: 42px; border-radius: 12px;
  display: grid; place-items: center;
  background: linear-gradient(145deg, var(--blue-dark) 0%, var(--blue-mid) 100%);
  color: #fff; font-size: 20px;
  box-shadow: 0 6px 16px -4px rgba(37, 99, 235, .5), inset 0 1px 0 rgba(255, 255, 255, .25);
}
.brand-logo .ic { width: 21px; height: 21px; }
.brand-text { display: flex; flex-direction: column; line-height: 1.35; }
.brand-text strong { font-size: 17px; font-weight: 900; color: var(--blue-deeper); letter-spacing: -.3px; }
[data-theme="dark"] .brand-text strong { color: #dbeafe; }
.brand-text small { font-size: 10.5px; color: var(--muted); }

.nav-links { display: flex; align-items: center; gap: 4px; }
.nav-links a {
  font-size: 13px; font-weight: 600; color: var(--muted);
  padding: 8px 12px; border-radius: 8px;
  transition: color .15s, background .15s;
}
.nav-links a:hover { color: var(--blue); background: var(--blue-light); }
.nav-links a.is-active { color: var(--blue); background: var(--blue-light); }

.nav-actions { display: flex; align-items: center; gap: 10px; }
.theme-toggle {
  width: 38px; height: 38px; border-radius: 10px;
  display: grid; place-items: center;
  background: var(--surface); border: 1px solid var(--border); color: var(--muted);
  transition: color .15s, border-color .15s;
}
.theme-toggle:hover { color: var(--blue); border-color: var(--blue); }
.theme-toggle .ic { width: 18px; height: 18px; }
.theme-toggle .icon-sun { display: none; }
[data-theme="dark"] .theme-toggle .icon-moon { display: none; }
[data-theme="dark"] .theme-toggle .icon-sun { display: block; }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  background: var(--hero-grad);
  padding: 64px 0 128px;
}
.hero-blob {
  position: absolute; border-radius: 50%; pointer-events: none;
  filter: blur(2px);
}
.blob-1 { width: 380px; height: 380px; top: -140px; right: -80px; background: radial-gradient(circle, rgba(255,255,255,.55), transparent 65%); }
.blob-2 { width: 260px; height: 260px; bottom: 60px; left: -90px; background: radial-gradient(circle, rgba(37,99,235,.12), transparent 65%); }
.blob-3 { width: 140px; height: 140px; top: 120px; left: 22%; background: radial-gradient(circle, rgba(255,255,255,.5), transparent 70%); }
[data-theme="dark"] .blob-1 { background: radial-gradient(circle, rgba(59,130,246,.18), transparent 65%); }
[data-theme="dark"] .blob-2 { background: radial-gradient(circle, rgba(37,99,235,.28), transparent 65%); }
[data-theme="dark"] .blob-3 { background: radial-gradient(circle, rgba(147,197,253,.10), transparent 70%); }

.hero-grid {
  position: relative; z-index: 2;
  display: grid; grid-template-columns: 1.03fr .97fr;
  gap: 54px; align-items: center;
}
.eyebrow {
  display: inline-flex; align-items: center; gap: 7px;
  background: var(--surface); border: 1px solid var(--border);
  color: var(--blue); font-size: 12px; font-weight: 700;
  padding: 6px 14px; border-radius: 999px; margin-bottom: 20px;
  box-shadow: var(--shadow-sm);
}
.eyebrow .ic { width: 15px; height: 15px; }
.hero .eyebrow { background: rgba(255,255,255,.62); border-color: rgba(255,255,255,.8); color: var(--blue-deeper); }
[data-theme="dark"] .hero .eyebrow { background: rgba(20,29,46,.6); border-color: rgba(147,197,253,.22); color: #c7d2fe; }

.hero h1 {
  font-size: clamp(30px, 4vw, 47px);
  font-weight: 900; line-height: 1.42; letter-spacing: -1px;
  color: var(--blue-deeper); margin-bottom: 18px;
}
[data-theme="dark"] .hero h1 { color: #eaf2ff; }
.hero h1 em {
  font-style: normal; color: var(--blue);
  background: linear-gradient(transparent 64%, rgba(37,99,235,.16) 64%);
  padding: 0 3px;
}
[data-theme="dark"] .hero h1 em { color: #93c5fd; background: linear-gradient(transparent 64%, rgba(59,130,246,.22) 64%); }
.hero-sub { font-size: 15.5px; color: #3b5273; max-width: 56ch; }
[data-theme="dark"] .hero-sub { color: #a8b9d4; }

.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin: 26px 0 20px; }
.hero-checks { display: flex; flex-wrap: wrap; gap: 8px 20px; list-style: none; font-size: 12.5px; color: #47607f; }
[data-theme="dark"] .hero-checks { color: #93a4bd; }
.hero-checks .ic { color: var(--green); width: 15px; height: 15px; }

.hero-stats {
  display: grid; grid-template-columns: repeat(3, auto);
  gap: 0; margin-top: 36px; padding-top: 24px;
  border-top: 1px dashed rgba(37, 99, 235, .22);
  width: fit-content;
}
.stat { padding: 0 26px; border-left: 1px solid rgba(37, 99, 235, .16); }
.stat:first-child { padding-right: 0; }
.stat:last-child { border-left: none; }
.stat strong { display: block; font-size: 27px; font-weight: 900; color: var(--blue-deeper); line-height: 1.3; }
[data-theme="dark"] .stat strong { color: #dbeafe; }
.stat span { font-size: 11px; color: #5a7297; }
[data-theme="dark"] .stat span { color: #8fa2c1; }

/* Hero visual */
.hero-visual { position: relative; }
.browser-frame {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 15px;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}
.hero-frame { transform: rotate(-.6deg); }
.browser-bar {
  display: flex; align-items: center; gap: 12px;
  padding: 8px 12px; background: var(--surface-2);
  border-bottom: 1px solid var(--border);
}
.dots { display: inline-flex; gap: 5px; }
.dots i { width: 8px; height: 8px; border-radius: 50%; background: #fca5a5; }
.dots i:nth-child(2) { background: #fcd34d; }
.dots i:nth-child(3) { background: #86efac; }
.addr {
  flex: 1; direction: ltr; text-align: center;
  height: 24px; line-height: 24px;
  background: var(--bg); border: 1px solid var(--border); border-radius: 6px;
  font-size: 9.5px; color: var(--muted);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  padding: 0 10px;
}
.mini-app { padding: 13px 14px 15px; }
.mini-head { display: flex; align-items: center; gap: 9px; margin-bottom: 10px; }
.mini-logo {
  width: 34px; height: 34px; border-radius: 10px;
  display: grid; place-items: center; color: #fff; font-size: 15px;
  background: linear-gradient(145deg, var(--blue-dark), var(--blue-mid));
  box-shadow: 0 4px 10px -2px rgba(37,99,235,.45);
}
.mini-logo .ic { width: 17px; height: 17px; }
.mini-title { display: flex; flex-direction: column; line-height: 1.3; }
.mini-title strong { font-size: 13.5px; font-weight: 900; color: var(--blue-deeper); }
[data-theme="dark"] .mini-title strong { color: #dbeafe; }
.mini-title small { font-size: 9px; color: var(--muted); }
.mini-toolbar { display: flex; gap: 6px; margin-bottom: 10px; }
.mini-search {
  flex: 1; display: inline-flex; align-items: center; gap: 5px;
  height: 28px; padding: 0 9px; border-radius: 7px;
  background: var(--bg); border: 1px solid var(--border);
  font-size: 9.5px; color: #94a3b8; overflow: hidden; white-space: nowrap; text-overflow: ellipsis;
}
.mini-search .ic { width: 12px; height: 12px; }
.mini-pill {
  display: inline-flex; align-items: center; height: 28px; padding: 0 10px;
  border-radius: 7px; border: 1px solid var(--border); background: var(--surface);
  font-size: 9.5px; color: var(--muted); white-space: nowrap;
}
.mini-table { width: 100%; border-collapse: collapse; font-size: 10.5px; }
.mini-table th {
  background: var(--blue-light); color: var(--blue-deeper);
  font-size: 9.5px; font-weight: 700; padding: 6px 7px; text-align: right;
  border-bottom: 2px solid var(--blue-pale);
}
[data-theme="dark"] .mini-table th { color: #bfdbfe; }
.mini-table td { padding: 6px 7px; border-bottom: 1px solid var(--border); color: var(--text); white-space: nowrap; }
.mini-table tbody tr:nth-child(even) td { background: var(--surface-2); }
.mini-table tbody tr.row-hl td { background: var(--blue-pale); }
.mini-table .c-check { width: 26px; text-align: center; }
.mini-check {
  display: inline-block; width: 13px; height: 13px; border-radius: 4px;
  border: 1.5px solid #cbd5e1; vertical-align: -2px;
}
.mini-check.on { background: var(--blue); border-color: var(--blue); position: relative; }
.mini-check.on::after {
  content: ""; position: absolute; inset: 2px 3px 4px 2px;
  border-left: 1.6px solid #fff; border-bottom: 1.6px solid #fff;
  transform: rotate(-45deg);
}
.mini-thumb {
  display: inline-block; width: 20px; height: 20px; border-radius: 6px;
  margin-left: 6px; vertical-align: -5px;
  background: linear-gradient(145deg, #93c5fd, #2563eb);
}
.t1 { background: linear-gradient(145deg, #93c5fd, #2563eb); }
.t2 { background: linear-gradient(145deg, #c4b5fd, #7c3aed); }
.t3 { background: linear-gradient(145deg, #6ee7b7, #059669); }
.t4 { background: linear-gradient(145deg, #fcd34d, #d97706); }
.t5 { background: linear-gradient(145deg, #f9a8d4, #db2777); }
.t6 { background: linear-gradient(145deg, #a5b4fc, #4f46e5); }

.badge {
  display: inline-block; padding: 1.5px 8px; border-radius: 999px;
  font-size: 9px; font-weight: 700; line-height: 1.7; white-space: nowrap;
}
.s-in { background: var(--green-soft); color: var(--green); }
.s-out { background: var(--red-soft); color: var(--red); }
.s-low { background: var(--amber-soft); color: var(--amber); }
.p-pub { background: var(--green-soft); color: var(--green); }
.p-draft { background: var(--blue-light); color: var(--muted); }
.cell-range { direction: ltr; unicode-bidi: embed; font-size: 9.5px; color: var(--muted); }
.cell-edit { direction: ltr; unicode-bidi: embed; text-align: left; }
.mini-table .cell-edit:hover {
  outline: 1.5px dashed var(--blue); border-radius: 4px;
  background: var(--blue-light);
}
.flash { animation: cellFlash .9s ease; }
@keyframes cellFlash {
  0% { box-shadow: 0 0 0 0 rgba(22,163,74,.55); background: var(--green-soft); }
  70% { box-shadow: 0 0 0 5px rgba(22,163,74,.12); background: var(--green-soft); }
  100% { box-shadow: none; }
}

.float-chip {
  position: absolute; z-index: 3;
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 999px; padding: 8px 14px;
  font-size: 11.5px; font-weight: 700; color: var(--text);
  box-shadow: var(--shadow-md);
  animation: floaty 5s ease-in-out infinite;
}
.float-chip .ic { width: 14px; height: 14px; }
.chip-saved { top: 15%; left: -26px; color: var(--green); border-color: var(--green-soft); }
.chip-undo { bottom: -16px; right: 40px; color: var(--amber); border-color: #fde68a; animation-delay: -2.2s; }
.chip-off { top: 56%; left: -34px; color: var(--red); border-color: var(--red-soft); animation-delay: -3.6s; direction: ltr; }
@keyframes floaty {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-7px); }
}

.hero-wave { position: absolute; bottom: -1px; left: 0; width: 100%; height: 90px; display: block; }
.wave-1 { fill: rgba(147, 197, 253, .42); }
.wave-2 { fill: var(--bg); }
[data-theme="dark"] .wave-1 { fill: rgba(37, 99, 235, .16); }

/* ---------- Sections ---------- */
.section { padding: 92px 0; }
.section-head { max-width: 740px; margin: 0 auto 48px; text-align: center; }
.section-head h2 {
  font-size: clamp(24px, 3vw, 33px); font-weight: 900; letter-spacing: -.6px;
  color: var(--text); margin-bottom: 12px;
}
.section-head p { font-size: 14.5px; color: var(--muted); }

/* ---------- Pain ---------- */
.pain-section { padding-top: 64px; }
.pain-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.pain-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 28px 26px;
  box-shadow: var(--shadow-sm);
  transition: transform .2s, box-shadow .2s, border-color .2s;
}
.pain-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); border-color: #fecaca; }
[data-theme="dark"] .pain-card:hover { border-color: #7f1d1d; }
.pain-icon {
  width: 46px; height: 46px; border-radius: 13px;
  display: grid; place-items: center; margin-bottom: 16px; font-size: 20px;
}
.pain-icon.red { background: var(--red-soft); color: var(--red); }
.pain-card h3 { font-size: 16px; font-weight: 800; margin-bottom: 8px; }
.pain-card p { font-size: 13px; color: var(--muted); }

/* ---------- Features: interactive showcase ---------- */
.features-section { background: var(--surface-2); overflow: clip; }
.showcase {
  display: grid;
  grid-template-columns: 330px minmax(0, 1fr);
  gap: 18px;
  align-items: stretch;
}
.show-tabs { display: flex; flex-direction: column; gap: 12px; }
.show-tab {
  position: relative; overflow: hidden; display: flex; align-items: center; gap: 12px;
  text-align: start; font-family: inherit; color: var(--text); cursor: pointer;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 16px; padding: 14px 16px;
  transition: transform .25s, border-color .25s, background .25s, box-shadow .25s;
}
.show-tab:hover { border-color: var(--blue-pale); transform: translateX(-3px); }
.show-tab.active {
  background: linear-gradient(150deg, #1e40af, #2563eb 60%, #3b82f6);
  border-color: transparent; color: #fff;
  box-shadow: 0 18px 36px -20px rgba(37, 99, 235, .95);
}
.st-icon {
  width: 42px; height: 42px; border-radius: 12px; flex: none;
  display: grid; place-items: center;
  background: var(--blue-light); color: var(--blue);
  transition: background .25s, color .25s;
}
.show-tab.active .st-icon { background: rgba(255, 255, 255, .16); color: #fff; }
.st-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.st-text b { font-size: 13.5px; font-weight: 800; }
.st-text i { font-style: normal; font-size: 11.3px; color: var(--muted); }
.show-tab.active .st-text i { color: #cfe0ff; }
.st-bar { position: absolute; inset: auto 0 0 0; height: 3px; }
.st-bar span { display: block; height: 100%; width: 0; background: rgba(255, 255, 255, .85); }
.show-tab.active .st-bar span { animation: tabProg 6s linear forwards; }
@keyframes tabProg { from { width: 0; } to { width: 100%; } }

.show-stage { position: relative; min-height: 420px; }
.stage-glow {
  position: absolute; width: 260px; height: 260px; border-radius: 50%;
  filter: blur(60px); opacity: .45; pointer-events: none; z-index: 0;
}
.stage-glow-a { background: #93c5fd; top: -40px; inset-inline-start: -30px; animation: floatA 9s ease-in-out infinite; }
.stage-glow-b { background: #c7d2fe; bottom: -50px; inset-inline-end: -20px; animation: floatB 12s ease-in-out infinite; }
@keyframes floatA { 50% { transform: translate(26px, -18px) scale(1.08); } }
@keyframes floatB { 50% { transform: translate(-20px, 22px) scale(1.1); } }

.show-frame {
  position: relative; z-index: 1; height: 100%;
  display: flex; flex-direction: column;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 18px; overflow: hidden;
  box-shadow: var(--shadow-lg);
}
.show-frame .browser-bar { justify-content: flex-start; }
.live-dot {
  margin-inline-start: auto; display: inline-flex; align-items: center; gap: 6px;
  font-size: 10.5px; font-weight: 800; color: var(--green);
}
.live-dot i {
  width: 7px; height: 7px; border-radius: 50%; background: var(--green);
  animation: livePulse 1.9s infinite;
}
@keyframes livePulse {
  0% { box-shadow: 0 0 0 0 rgba(22, 163, 74, .45); }
  70% { box-shadow: 0 0 0 8px rgba(22, 163, 74, 0); }
  100% { box-shadow: 0 0 0 0 rgba(22, 163, 74, 0); }
}

.scene-wrap { position: relative; flex: 1; display: flex; flex-direction: column; justify-content: center; padding: 20px; min-height: 320px; }
.scene { display: none; width: 100%; }
.scene.active { display: block; animation: sceneIn .5s cubic-bezier(.2, .7, .3, 1) both; }
@keyframes sceneIn { from { opacity: 0; transform: translateY(14px) scale(.99); } to { opacity: 1; transform: none; } }

.mini-table { border: 1px solid var(--border); border-radius: 12px; overflow: hidden; }
.mt-head, .mt-row { display: grid; grid-template-columns: 1.6fr .9fr 1fr .5fr; gap: 8px; align-items: center; }
.mt-head { padding: 9px 12px; background: var(--surface-2); font-size: 10.5px; font-weight: 700; color: var(--muted); }
.mt-row { padding: 12px; border-top: 1px solid var(--border); font-size: 12px; }
.mt-name { font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mt-old { color: var(--muted); text-decoration: line-through; font-size: 11px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.mt-new { color: var(--green); font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; }
.mt-tag { justify-self: start; font-size: 10px; font-weight: 800; color: var(--green); background: var(--green-soft); border-radius: 999px; padding: 2px 7px; white-space: nowrap; }

.scene-foot { display: flex; align-items: center; gap: 10px; margin-top: 14px; }
.sf-chip { font-size: 11px; font-weight: 700; color: var(--blue); background: var(--blue-light); border-radius: 999px; padding: 5px 10px; white-space: nowrap; }
.sf-progress { flex: 1; height: 6px; border-radius: 99px; background: var(--border); overflow: hidden; }
.sf-progress i { display: block; height: 100%; width: 0; border-radius: 99px; background: linear-gradient(90deg, var(--blue), var(--green)); transition: width 1.1s ease; }
.sf-btn {
  border: 0; font-family: inherit; font-size: 11.5px; font-weight: 800; color: #fff;
  background: var(--blue); border-radius: 10px; padding: 9px 14px;
  box-shadow: 0 12px 22px -14px rgba(37, 99, 235, .95); white-space: nowrap;
}
.sf-btn.ghost { background: var(--surface-2); color: var(--text); border: 1px solid var(--border); box-shadow: none; }

.edit-row {
  display: flex; align-items: center; gap: 10px;
  background: var(--surface-2); border: 1px solid var(--border);
  border-radius: 12px; padding: 12px;
}
.er-label { font-size: 11px; color: var(--muted); white-space: nowrap; }
.er-input {
  flex: 1; display: flex; align-items: center; min-height: 38px;
  background: var(--surface); border: 1.5px solid var(--blue); border-radius: 9px;
  padding: 8px 12px; font-size: 14px; font-weight: 800;
  box-shadow: 0 0 0 4px rgba(37, 99, 235, .10);
}
.er-caret { width: 2px; height: 16px; background: var(--blue); margin-inline-start: 2px; animation: erCaret 1s steps(2) infinite; }
@keyframes erCaret { 50% { opacity: 0; } }
.er-ok {
  width: 26px; height: 26px; border-radius: 50%; flex: none;
  display: grid; place-items: center; font-weight: 900;
  background: var(--green-soft); color: var(--green);
}
.er-ok.pop { animation: okPop .55s ease; }
@keyframes okPop { 40% { transform: scale(1.28); box-shadow: 0 0 0 6px rgba(22, 163, 74, .16); } }
.edit-hint { margin: 12px 2px 16px; font-size: 11px; color: var(--muted); }
.edit-hint kbd {
  font-family: inherit; font-size: 10px; color: var(--text);
  background: var(--surface); border: 1px solid var(--border); border-bottom-width: 2px;
  border-radius: 6px; padding: 1px 6px;
}
.edit-rows { display: flex; flex-direction: column; gap: 8px; }
.er-line {
  display: flex; align-items: center; gap: 10px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 10px; padding: 9px 12px; font-size: 12px;
}
.er-line > span:first-child { width: 52px; color: var(--muted); font-size: 11px; }
.er-line b { font-weight: 700; font-variant-numeric: tabular-nums; }
.er-line small { font-weight: 500; font-size: 10px; color: var(--muted); }
.er-pill {
  margin-inline-start: auto; font-size: 10px; color: var(--muted);
  background: var(--surface-2); border: 1px solid var(--border);
  border-radius: 999px; padding: 3px 8px; white-space: nowrap;
}
.er-pill.green { background: var(--green-soft); border-color: transparent; color: var(--green); font-weight: 700; }

.tl { display: flex; flex-direction: column; gap: 10px; }
.tl-item {
  display: flex; align-items: center; gap: 10px; opacity: 0;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 11px; padding: 11px 12px;
}
.scene.run .tl-item { animation: tlIn .55s cubic-bezier(.2, .7, .3, 1) forwards; }
.scene.run .tl-item:nth-child(1) { animation-delay: .06s; }
.scene.run .tl-item:nth-child(2) { animation-delay: .18s; }
.scene.run .tl-item:nth-child(3) { animation-delay: .30s; }
@keyframes tlIn { from { opacity: 0; transform: translateX(20px); } to { opacity: 1; transform: none; } }
.tl-dot { width: 8px; height: 8px; border-radius: 50%; flex: none; background: var(--blue); box-shadow: 0 0 0 3px var(--blue-pale); }
.tl-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.tl-body b { font-size: 11.5px; font-weight: 800; }
.tl-body small { font-size: 10.5px; color: var(--muted); }
.tl-undo {
  margin-inline-start: auto; white-space: nowrap; font-size: 10px; font-weight: 700;
  color: var(--blue); background: var(--blue-light);
  border: 1px solid var(--blue-pale); border-radius: 999px; padding: 4px 9px;
}
.scene.run .tl-undo { animation: undoPulse 1.6s ease .7s 1; }
@keyframes undoPulse { 50% { box-shadow: 0 0 0 6px rgba(37, 99, 235, .14); } }

.stock-list { display: flex; flex-direction: column; gap: 9px; }
.stock-item {
  display: flex; align-items: center; gap: 10px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 11px; padding: 10px 12px; font-size: 11.8px;
}
.si-thumb { width: 30px; height: 30px; border-radius: 8px; flex: none; }
.si-thumb.a { background: linear-gradient(135deg, #dbeafe, #93c5fd); }
.si-thumb.b { background: linear-gradient(135deg, #fef3c7, #fcd34d); }
.si-thumb.c { background: linear-gradient(135deg, #dcfce7, #86efac); }
.si-name { font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.si-qty { margin-inline-start: auto; font-weight: 800; font-variant-numeric: tabular-nums; }
.si-toggle {
  position: relative; width: 36px; height: 20px; border-radius: 99px; flex: none;
  background: var(--border); transition: background .25s;
}
.si-toggle i {
  position: absolute; top: 2px; inset-inline-start: 2px;
  width: 16px; height: 16px; border-radius: 50%;
  background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .25);
  transition: inset-inline-start .25s;
}
.si-toggle.on { background: var(--green); }
.si-toggle.on i { inset-inline-start: 18px; }

.feat-marquee {
  margin-top: 22px; overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
}
.marquee-track { display: flex; gap: 10px; width: max-content; direction: ltr; animation: marquee 40s linear infinite; }
.feat-marquee:hover .marquee-track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(-50%); } }
.mq-chip {
  display: inline-flex; align-items: center; gap: 7px; white-space: nowrap;
  font-size: 11.5px; color: var(--text); background: var(--surface);
  border: 1px solid var(--border); border-radius: 999px; padding: 8px 13px;
}
.mq-chip .ic { width: 14px; height: 14px; color: var(--blue); }

@media (max-width: 980px) {
  .showcase { grid-template-columns: 1fr; }
  .show-tabs { display: grid; grid-template-columns: 1fr 1fr; }
  .show-stage { min-height: 0; }
  .scene-wrap { min-height: 0; }
}
@media (max-width: 620px) {
  .show-tabs { grid-template-columns: 1fr 1fr; gap: 8px; }
  .show-tab { padding: 10px 11px; gap: 8px; border-radius: 13px; }
  .st-icon { width: 34px; height: 34px; border-radius: 10px; font-size: 16px; }
  .st-text b { font-size: 12px; }
  .st-text i { display: none; }
  .scene-wrap { padding: 13px; }
  .mt-head, .mt-row { grid-template-columns: 1.5fr .8fr 1fr; }
  .mt-head span:last-child, .mt-tag { display: none; }
  .mt-row { padding: 10px; font-size: 11px; }
  .scene-foot { flex-wrap: wrap; }
  .sf-progress { display: none; }
  .sf-btn { margin-inline-start: auto; }
  .edit-row { gap: 7px; padding: 9px; }
  .er-label { font-size: 10px; }
  .er-input { font-size: 12px; min-height: 34px; }
  .tl-body small { font-size: 9.8px; }
  .tl-undo { font-size: 9.5px; padding: 3px 7px; }
}

@media (prefers-reduced-motion: reduce) {
  .marquee-track, .stage-glow, .live-dot i, .er-caret { animation: none !important; }
  .show-tab.active .st-bar span { animation: none; width: 100%; }
  .scene.active { animation: none; }
  .scene.run .tl-item { animation: none; opacity: 1; }
}

/* ---------- Gallery ---------- */
.gallery-tabs {
  display: flex; gap: 8px; flex-wrap: nowrap;
  overflow-x: auto; padding: 4px 2px 14px;
  scrollbar-width: thin;
}
.g-tab {
  display: inline-flex; align-items: center; gap: 6px; flex-shrink: 0;
  height: 38px; padding: 0 14px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 9px; color: var(--muted);
  font-size: 12.5px; font-weight: 600;
  font-family: inherit; cursor: pointer; appearance: none; -webkit-appearance: none;
  transition: all .15s;
}
.g-tab .ic { width: 15px; height: 15px; }
.g-tab:hover { color: var(--blue); border-color: var(--blue-pale); }
.g-tab.active {
  background: var(--blue-light); color: var(--blue);
  border-color: var(--blue-pale); font-weight: 700;
  box-shadow: inset 0 0 0 1px rgba(37,99,235,.12);
}
.gallery-frame { max-width: 1000px; margin: 0 auto; }
.gallery-stage { background: var(--bg); }
.shot { margin: 0; display: none; }
.shot.active { display: block; }
.shot img {
  width: 100%; display: block;
  max-height: 600px; object-fit: cover; object-position: top center;
  background: var(--bg);
}
.shot-fallback {
  display: none; min-height: 420px;
  align-items: center; justify-content: center; flex-direction: column; gap: 12px;
  color: var(--muted); font-size: 13px;
  background:
    radial-gradient(circle at 25% 20%, var(--blue-light), transparent 55%),
    var(--surface);
}
.shot-fallback .ic { width: 44px; height: 44px; color: #94a3b8; }
.shot.no-img img { display: none; }
.shot.no-img .shot-fallback { display: flex; }
.shot figcaption {
  display: flex; flex-direction: column; gap: 3px;
  padding: 14px 20px 16px; background: var(--surface);
  border-top: 1px solid var(--border);
}
.shot figcaption strong { font-size: 13.5px; font-weight: 800; }
.shot figcaption span { font-size: 12px; color: var(--muted); }

/* ---------- Demo ---------- */
.demo-section { background: var(--surface-2); }
.demo-shell {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  box-shadow: var(--shadow-md);
  overflow: hidden;
}
.demo-topbar {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 13px 18px; border-bottom: 1px solid var(--border);
  background: var(--surface);
  flex-wrap: wrap;
}
.demo-brand { display: flex; align-items: center; gap: 10px; }
.demo-brand strong { display: block; font-size: 14.5px; font-weight: 900; color: var(--blue-deeper); }
[data-theme="dark"] .demo-brand strong { color: #dbeafe; }
.demo-brand small { display: block; font-size: 10px; color: var(--muted); }
.demo-top-actions { display: flex; align-items: center; gap: 12px; }
.demo-saved-count { font-size: 11.5px; color: var(--muted); }
.demo-saved-count b { color: var(--blue); }

.demo-tabs {
  display: flex; gap: 2px; padding: 0 14px;
  border-bottom: 1px solid var(--border); background: var(--surface);
  overflow-x: auto;
}
.demo-tab {
  display: inline-flex; align-items: center; gap: 6px; flex-shrink: 0;
  padding: 10px 13px 9px; font-size: 12.5px; font-weight: 600;
  color: var(--muted); margin-bottom: -1px;
  appearance: none; -webkit-appearance: none; background: transparent;
  border: 0; border-bottom: 2px solid transparent; font-family: inherit; cursor: pointer;
}
.demo-tab .ic { width: 14px; height: 14px; }
.demo-tab.active { color: var(--blue); border-bottom-color: var(--blue); font-weight: 700; }

.demo-toolbar {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  padding: 12px 14px; border-bottom: 1px solid var(--border);
}
.demo-search-wrap {
  position: relative; flex: 1; min-width: 210px; max-width: 360px;
}
.demo-search-wrap .ic {
  position: absolute; right: 11px; top: 50%; transform: translateY(-50%);
  width: 15px; height: 15px; color: #94a3b8; pointer-events: none;
}
.demo-search-wrap input {
  width: 100%; height: 36px; padding: 0 34px 0 12px;
  border: 1px solid var(--border); border-radius: 9px;
  background: var(--bg); color: var(--text); font-size: 12.5px;
  transition: border-color .15s, box-shadow .15s, background .15s;
}
.demo-search-wrap input:focus {
  outline: none; border-color: var(--blue);
  background: var(--surface); box-shadow: 0 0 0 3px rgba(37,99,235,.1);
}
.demo-select, .demo-input {
  height: 36px; padding: 0 10px;
  border: 1px solid var(--border); border-radius: 8px;
  background: var(--surface); color: var(--text); font-size: 12.5px;
}
.demo-select:focus, .demo-input:focus {
  outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(37,99,235,.1);
}
#demo-history-btn { margin-right: auto; }
.pill-count {
  display: inline-grid; place-items: center; min-width: 18px; height: 18px;
  padding: 0 5px; border-radius: 999px;
  background: var(--blue); color: #fff; font-size: 10px; font-weight: 700;
  line-height: 1;
}

.demo-hintbar {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 16px; font-size: 11.5px; color: var(--blue-deeper);
  background: var(--blue-light); border-bottom: 1px solid var(--border);
}
[data-theme="dark"] .demo-hintbar { color: #bfdbfe; }
.demo-hintbar .ic { width: 15px; height: 15px; color: var(--blue); }

.demo-bulkbar[hidden], .demo-preview[hidden] { display: none !important; }
.demo-bulkbar {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  padding: 10px 14px;
  background: var(--blue-light);
  border-bottom: 1px solid var(--border);
}
.bulk-count { font-size: 12px; font-weight: 800; color: var(--blue-deeper); }
[data-theme="dark"] .bulk-count { color: #bfdbfe; }
.demo-bulkbar .demo-input { width: 120px; }
.demo-bulkbar .demo-select { max-width: 230px; }

.demo-preview {
  padding: 8px 16px;
  background: var(--surface-2);
  border-bottom: 1px solid var(--border);
  font-size: 11.5px;
}
.pv-row {
  display: flex; justify-content: space-between; gap: 16px;
  padding: 5px 0; border-bottom: 1px dashed var(--border);
}
.pv-row:last-child { border-bottom: none; }
.pv-name { color: var(--text); font-weight: 600; }
.pv-diff { direction: ltr; unicode-bidi: embed; }
.pv-before { color: var(--muted); text-decoration: line-through; }
.pv-arrow { color: #cbd5e1; margin: 0 5px; }
.pv-after { color: var(--green); font-weight: 700; }
.pv-note { color: var(--muted); padding: 4px 0; }

.demo-table-wrap { overflow-x: auto; }
.demo-table {
  width: 100%; min-width: 880px; border-collapse: collapse;
  font-size: 12.5px;
}
.demo-table thead th {
  background: var(--blue-light); color: var(--blue-deeper);
  font-size: 11.5px; font-weight: 700; text-align: right;
  padding: 10px 9px; border-bottom: 2px solid var(--blue-pale);
  white-space: nowrap;
}
[data-theme="dark"] .demo-table thead th { color: #bfdbfe; }
.demo-table td {
  padding: 9px 9px; border-bottom: 1px solid var(--border);
  vertical-align: middle; white-space: nowrap;
}
.demo-table tbody tr { transition: background .12s; }
.demo-table tbody tr:hover > td { background: var(--blue-light); }
.demo-table tbody tr.selected > td { background: var(--blue-pale); }
.demo-table tbody tr.var-row { display: none; }
.demo-table tbody tr.var-row.open { display: table-row; }
.demo-table tbody tr.var-row > td { background: var(--surface-2); font-size: 12px; }
.demo-table tbody tr.var-row:hover > td { background: var(--blue-light); }
.demo-table .col-check { width: 40px; text-align: center; }
.demo-table .col-actions { width: 74px; text-align: center; }
.demo-table input[type="checkbox"] { accent-color: var(--blue); width: 14px; height: 14px; cursor: pointer; }

.prod-cell { display: flex; align-items: center; gap: 9px; }
.demo-thumb {
  width: 30px; height: 30px; border-radius: 8px; flex-shrink: 0;
  background: linear-gradient(145deg, #93c5fd, #2563eb);
  display: grid; place-items: center;
  color: rgba(255,255,255,.9); font-size: 11px; font-weight: 800;
}
.prod-meta { display: flex; flex-direction: column; line-height: 1.5; min-width: 0; }
.prod-meta strong { font-size: 12.5px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; }
.prod-sub { display: flex; align-items: center; gap: 6px; font-size: 9.5px; color: var(--muted); }
.type-badge {
  display: inline-block; padding: 0 6px; border-radius: 5px;
  background: var(--blue-light); color: var(--blue);
  font-size: 9px; font-weight: 700; line-height: 1.8;
}
.type-badge.simple { background: var(--bg); color: var(--muted); }
.var-toggle {
  display: inline-flex; align-items: center; gap: 3px;
  border: none; background: transparent; padding: 0;
  color: var(--blue); font-size: 9.5px; font-weight: 700;
}
.var-toggle .ic { width: 11px; height: 11px; transition: transform .18s; }
.var-toggle.open .ic { transform: rotate(180deg); }

.cell-val {
  display: inline-block; padding: 2px 6px; margin: -2px -6px;
  border-radius: 6px; cursor: text;
  transition: background .12s, outline-color .12s;
}
td.editable:hover .cell-val {
  background: var(--blue-light);
  outline: 1.5px dashed var(--blue);
}
.cell-price { direction: ltr; unicode-bidi: embed; text-align: left; font-weight: 600; }
.cell-price small { font-size: 9px; color: var(--muted); font-weight: 400; margin-right: 3px; }
.cell-price.is-changed { color: var(--green); }

.inline-input {
  width: 100%; min-width: 90px; height: 28px;
  border: 2px solid var(--blue); border-radius: 6px;
  background: var(--surface); color: var(--text);
  font-size: 12px; font-family: inherit; padding: 0 7px;
}
.inline-input.ltr { direction: ltr; text-align: left; }
.inline-input:focus { outline: none; box-shadow: 0 0 0 3px rgba(37,99,235,.14); }

.stock-btn, .status-btn {
  border: none; border-radius: 999px; padding: 3px 12px;
  font-size: 10.5px; font-weight: 700; font-family: inherit;
  cursor: pointer; transition: transform .12s, opacity .12s;
}
.stock-btn:hover, .status-btn:hover { transform: scale(1.05); opacity: .9; }
.stock-btn.in { background: var(--green-soft); color: var(--green); }
.stock-btn.out { background: var(--red-soft); color: var(--red); }
.stock-btn.low { background: var(--amber-soft); color: var(--amber); }
.status-btn.pub { background: var(--green-soft); color: var(--green); }
.status-btn.draft { background: var(--bg); color: var(--muted); }
.stock-qty { font-size: 10px; color: var(--muted); margin-top: 1px; }

.discount-chip {
  display: inline-block; padding: 2px 8px; border-radius: 6px;
  background: var(--red-soft); color: var(--red);
  font-size: 10.5px; font-weight: 700; direction: ltr;
}
.discount-none { color: #cbd5e1; }

.row-hist-btn {
  width: 28px; height: 28px; border-radius: 7px;
  display: inline-grid; place-items: center;
  background: var(--surface); border: 1px solid var(--border);
  color: var(--muted); font-size: 14px;
  transition: all .15s;
}
.row-hist-btn:hover { color: var(--amber); border-color: #fcd34d; background: var(--amber-soft); }
.row-hist-btn .ic { width: 14px; height: 14px; }

tr.row-flash > td { animation: rowFlash .9s ease; }
@keyframes rowFlash {
  0% { background: var(--green-soft); }
  100% { background: transparent; }
}

.demo-statusbar {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  flex-wrap: wrap;
  padding: 9px 14px; font-size: 11.5px; color: var(--muted);
  border-top: 1px solid var(--border);
  background: var(--surface);
}
.demo-status-hint { font-size: 10.5px; color: #94a3b8; }
.demo-empty { text-align: center; padding: 34px 12px; color: var(--muted); font-size: 12.5px; }

/* ---------- Drawer ---------- */
.drawer-backdrop {
  position: fixed; inset: 0; z-index: 190;
  background: rgba(2, 6, 23, .45);
  opacity: 0; transition: opacity .2s;
}
.drawer-backdrop.show { opacity: 1; }
.demo-drawer {
  position: fixed; top: 0; left: 0; bottom: 0; z-index: 200;
  width: 390px; max-width: 94vw;
  background: var(--surface);
  box-shadow: 20px 0 50px -20px rgba(2, 6, 23, .45);
  transform: translateX(-105%);
  transition: transform .25s ease;
  display: flex; flex-direction: column;
}
.demo-drawer.open { transform: translateX(0); }
.drawer-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 16px;
  background: linear-gradient(135deg, var(--blue-deeper), var(--blue-mid));
  color: #fff;
}
.drawer-head h3 { font-size: 14px; font-weight: 800; display: flex; align-items: center; gap: 8px; }
.drawer-head .ic { width: 17px; height: 17px; }
.drawer-close {
  width: 28px; height: 28px; border-radius: 7px;
  background: rgba(255,255,255,.18); border: 1px solid rgba(255,255,255,.3);
  color: #fff; font-size: 16px; line-height: 1;
}
.drawer-close:hover { background: rgba(255,255,255,.32); }
.drawer-sub {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 8px 14px; border-bottom: 1px solid var(--border);
  font-size: 11.5px; color: var(--muted);
  background: var(--surface-2);
}
.drawer-list { overflow-y: auto; flex: 1; }
.drawer-empty {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  padding: 48px 20px; color: var(--muted); font-size: 12.5px; text-align: center;
}
.drawer-empty .ic { width: 34px; height: 34px; color: #cbd5e1; }
.hist-entry {
  padding: 11px 14px; border-bottom: 1px solid var(--border);
  transition: background .12s;
}
.hist-entry:hover { background: var(--blue-light); }
.hist-entry.is-group { border-right: 3px solid var(--blue); }
.hist-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.hist-title { font-size: 12px; font-weight: 700; color: var(--text); }
.hist-time { font-size: 10px; color: var(--muted); direction: ltr; unicode-bidi: embed; }
.hist-changes { margin: 5px 0 6px; font-size: 11px; color: var(--muted); }
.hist-line { display: flex; align-items: center; gap: 5px; flex-wrap: wrap; padding: 1px 0; }
.hist-line .before { color: var(--muted); text-decoration: line-through; direction: ltr; unicode-bidi: embed; }
.hist-line .arrow { color: #cbd5e1; }
.hist-line .after { color: var(--green); font-weight: 700; direction: ltr; unicode-bidi: embed; }
.hist-field { color: var(--blue-dark); font-weight: 600; }
.hist-undo {
  border: 1px solid #fcd34d; background: #fffbeb; color: #92400e;
  border-radius: 6px; font-size: 10.5px; font-weight: 700;
  padding: 3px 9px; transition: all .15s;
}
[data-theme="dark"] .hist-undo { background: #3a2a08; color: #fcd34d; border-color: #78530a; }
.hist-undo:hover { background: #fef3c7; border-color: #f59e0b; }
[data-theme="dark"] .hist-undo:hover { background: #4a350a; }

/* ---------- Compare ---------- */
.compare-table-wrap {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); overflow: auto;
  box-shadow: var(--shadow-sm);
}
.compare-table { width: 100%; min-width: 720px; border-collapse: collapse; font-size: 12.8px; }
.compare-table th {
  padding: 16px 18px; text-align: right; font-size: 13px; font-weight: 800;
  color: var(--text); border-bottom: 1px solid var(--border);
  background: var(--surface-2);
}
.compare-table th.cmp-qpm { background: var(--blue-light); }
.cmp-woo, .cmp-brand { display: inline-flex; align-items: center; gap: 7px; }
.cmp-woo { color: var(--muted); font-weight: 700; }
.cmp-brand { color: var(--blue); }
.compare-table td { padding: 12px 18px; border-bottom: 1px solid var(--border); }
.compare-table tbody tr:last-child td { border-bottom: none; }
.compare-table tbody tr:hover td { background: var(--surface-2); }
.compare-table td:nth-child(2), .compare-table td:nth-child(3) { width: 24%; }
.compare-table td .ic { width: 14px; height: 14px; vertical-align: -2px; margin-left: 4px; }
.compare-table td.yes { color: var(--green); font-weight: 700; background: rgba(22, 163, 74, .04); }
.compare-table td.no { color: var(--muted); }

/* ---------- Steps ---------- */
.install-section { background: var(--surface-2); }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.step {
  position: relative;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 28px 26px;
  box-shadow: var(--shadow-sm);
}
.step-num {
  display: grid; place-items: center;
  width: 42px; height: 42px; border-radius: 12px;
  background: linear-gradient(135deg, var(--blue-dark), var(--blue-mid));
  color: #fff; font-size: 18px; font-weight: 900;
  box-shadow: 0 6px 14px -4px rgba(37, 99, 235, .45);
  margin-bottom: 16px;
}
.step h3 { font-size: 15.5px; font-weight: 800; margin-bottom: 7px; }
.step p { font-size: 12.8px; color: var(--muted); }

/* ---------- FAQ ---------- */
.faq-grid { display: grid; grid-template-columns: .85fr 1.15fr; gap: 52px; align-items: start; }
.faq-intro h2 { font-size: clamp(24px, 3vw, 32px); font-weight: 900; margin-bottom: 12px; letter-spacing: -.5px; }
.faq-intro p { font-size: 13.5px; color: var(--muted); max-width: 34ch; }
.faq-item {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 12px; margin-bottom: 10px;
  transition: border-color .15s, box-shadow .15s;
}
.faq-item[open] { border-color: var(--blue-pale); box-shadow: var(--shadow-sm); }
.faq-item summary {
  list-style: none; cursor: pointer;
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 15px 18px; font-size: 13.5px; font-weight: 700; color: var(--text);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary .ic { width: 16px; height: 16px; color: var(--muted); transition: transform .2s; }
.faq-item[open] summary { color: var(--blue-deeper); }
[data-theme="dark"] .faq-item[open] summary { color: #bfdbfe; }
.faq-item[open] summary .ic { transform: rotate(180deg); color: var(--blue); }
.faq-body { padding: 0 18px 16px; font-size: 12.8px; color: var(--muted); line-height: 1.9; }

/* ---------- Purchase ---------- */
.purchase-panel {
  position: relative; overflow: hidden;
  background: linear-gradient(135deg, var(--blue-deeper) 0%, var(--blue-dark) 45%, var(--blue-mid) 100%);
  border-radius: 26px;
  padding: 52px 52px;
  color: #fff;
  display: grid; grid-template-columns: 1.25fr .75fr;
  gap: 40px; align-items: center;
  box-shadow: 0 30px 70px -25px rgba(30, 58, 138, .55);
}
.purchase-panel::before {
  content: ""; position: absolute; width: 420px; height: 420px; border-radius: 50%;
  background: rgba(255,255,255,.07); top: -180px; left: -120px;
}
.purchase-panel::after {
  content: ""; position: absolute; width: 260px; height: 260px; border-radius: 50%;
  border: 1px solid rgba(255,255,255,.12); bottom: -120px; right: 24%;
}
.purchase-copy { position: relative; z-index: 1; }
.eyebrow.light {
  background: rgba(255,255,255,.14); border-color: rgba(255,255,255,.28);
  color: #dbeafe; box-shadow: none;
}
.purchase-copy h2 { font-size: clamp(23px, 2.7vw, 31px); font-weight: 900; color: #fff; line-height: 1.55; margin-bottom: 12px; letter-spacing: -.5px; }
.purchase-copy > p { color: rgba(255,255,255,.82); font-size: 14px; max-width: 56ch; }
.purchase-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.purchase-note { margin-top: 16px !important; font-size: 11px !important; color: rgba(255,255,255,.62) !important; }
.purchase-art { position: relative; min-height: 230px; z-index: 1; }
.art-logo {
  position: absolute; inset: 50% auto auto 50%; transform: translate(50%, -50%);
  width: 124px; height: 124px; border-radius: 34px;
  background: rgba(255,255,255,.14);
  border: 1px solid rgba(255,255,255,.28);
  display: grid; place-items: center;
  box-shadow: 0 20px 40px -16px rgba(2, 6, 23, .4), inset 0 1px 0 rgba(255,255,255,.2);
  backdrop-filter: blur(6px);
}
.art-logo .ic { width: 58px; height: 58px; color: #fff; stroke-width: 1.6; }
.art-chip {
  position: absolute; display: inline-flex; align-items: center; gap: 6px;
  background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.26);
  border-radius: 999px; padding: 8px 14px;
  font-size: 11.5px; font-weight: 700; color: #fff;
  backdrop-filter: blur(4px);
  animation: floaty 5.5s ease-in-out infinite;
}
.art-chip .ic { width: 14px; height: 14px; }
.art-chip.c1 { top: 8%; right: 4%; }
.art-chip.c2 { bottom: 12%; left: 2%; animation-delay: -1.8s; }
.art-chip.c3 { top: 60%; right: -2%; animation-delay: -3.4s; }

/* ---------- Footer ---------- */
.site-footer { background: var(--surface); border-top: 1px solid var(--border); padding-top: 54px; }
.footer-grid { display: grid; grid-template-columns: 1.5fr .8fr 1fr; gap: 36px; }
.footer-brand p { font-size: 12.5px; color: var(--muted); margin-top: 14px; max-width: 40ch; }
.footer-links h3, .footer-req h3 { font-size: 13px; font-weight: 800; margin-bottom: 12px; }
.footer-links { display: flex; flex-direction: column; align-items: flex-start; }
.footer-links a { font-size: 12.5px; color: var(--muted); padding: 4px 0; }
.footer-links a:hover { color: var(--blue); }
.footer-req ul { list-style: none; }
.footer-req li { font-size: 12.5px; color: var(--muted); padding: 3px 0; }
.footer-req li::before { content: "✓"; color: var(--green); margin-left: 7px; font-weight: 700; }
.footer-bottom {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin-top: 42px; padding: 16px 0;
  border-top: 1px solid var(--border);
  font-size: 11.5px; color: var(--muted);
}
.footer-bottom a { color: var(--muted); }
.footer-bottom a:hover { color: var(--blue); }

/* ---------- Toast ---------- */
.toast {
  position: fixed; bottom: 26px; left: 50%; transform: translate(-50%, 14px);
  z-index: 300; pointer-events: none;
  background: #0f172a; color: #f8fafc;
  border: 1px solid rgba(255,255,255,.12);
  padding: 10px 20px; border-radius: 11px;
  font-size: 12.5px; font-weight: 600;
  box-shadow: 0 16px 40px -12px rgba(2, 6, 23, .6);
  opacity: 0; transition: opacity .2s, transform .2s;
  display: flex; align-items: center; gap: 8px;
  max-width: 92vw;
}
.toast .ic { width: 15px; height: 15px; color: #86efac; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.error .ic { color: #fca5a5; }

/* ---------- Reveal ---------- */
html.js-reveal .reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
html.js-reveal .reveal.in { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .hero-grid { grid-template-columns: minmax(0, 1fr); gap: 46px; }
  .hero-copy, .hero-visual { min-width: 0; }
  .hero-visual { max-width: 640px; margin: 0 auto; width: 100%; }
  .hero { padding-top: 48px; }
  .hero-stats { margin-top: 30px; }
  .pain-grid { grid-template-columns: 1fr; }
  .faq-grid { grid-template-columns: 1fr; gap: 28px; }
  .faq-intro p { max-width: none; }
  .purchase-panel { grid-template-columns: 1fr; padding: 42px 34px; }
  .purchase-art { display: none; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 860px) {
  .nav-links { display: none; }
  .section { padding: 72px 0; }
  .steps { grid-template-columns: 1fr; }
  .float-chip { display: none; }
  .hero-frame { transform: none; }
}
@media (max-width: 680px) {
  .section-head { margin-bottom: 36px; }
  .hero { padding-bottom: 100px; }
  .hero h1 { letter-spacing: -.4px; }
  .hero-stats { grid-template-columns: repeat(3, 1fr); width: 100%; }
  .stat { padding: 0 14px; text-align: center; }
  .stat strong { font-size: 22px; }
  .browser-bar .addr { display: none; }
  .demo-toolbar { gap: 6px; }
  #demo-history-btn { margin-right: 0; }
  .demo-topbar { align-items: flex-start; }
  .demo-statusbar { flex-direction: column; align-items: flex-start; gap: 4px; }
  .nav-cta { display: none; }
  .site-nav .brand-text small { display: none; }
  .footer-grid { grid-template-columns: 1fr; gap: 26px; }
  .section-head h2 { font-size: 23px; }
  .compare-table td, .compare-table th { padding: 10px 12px; }
  .g-tab { font-size: 11.5px; height: 36px; }
}
@media (max-width: 420px) {
  .container { padding: 0 16px; }
  .hero-cta .btn { width: 100%; }
  .hero-stats { grid-template-columns: 1fr; gap: 10px; }
  .stat { border-left: none; border-bottom: 1px dashed rgba(37,99,235,.16); padding: 6px 0; }
  .stat:last-child { border-bottom: none; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
  html.js-reveal .reveal { opacity: 1; transform: none; }
}

/* ==========================================================================
   v2 — Visual upgrades, sticky CTA, lightbox, plugin-faithful demo
   ========================================================================== */

/* ---------- Scroll progress ---------- */
.scroll-progress {
  position: fixed; top: 0; right: 0; left: 0; height: 3px;
  z-index: 210; pointer-events: none;
}
.scroll-progress i {
  display: block; height: 100%; width: 0;
  background: linear-gradient(90deg, var(--blue-deeper), var(--blue-mid) 60%, #60a5fa);
  box-shadow: 0 0 12px rgba(59, 130, 246, .55);
  transition: width .08s linear;
}

/* ---------- Hero texture ---------- */
.hero::after {
  content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background-image: radial-gradient(rgba(37, 99, 235, .13) 1px, transparent 1px);
  background-size: 22px 22px;
  -webkit-mask-image: linear-gradient(180deg, transparent 4%, #000 34%, transparent 88%);
  mask-image: linear-gradient(180deg, transparent 4%, #000 34%, transparent 88%);
}
[data-theme="dark"] .hero::after { background-image: radial-gradient(rgba(147, 197, 253, .12) 1px, transparent 1px); }
.hero .browser-frame { box-shadow: 0 40px 90px -30px rgba(2, 6, 23, .38); }
[data-theme="dark"] .hero .browser-frame { box-shadow: 0 40px 90px -30px rgba(0, 0, 0, .75); }
.hero h1 em { box-shadow: inset 0 -.18em 0 rgba(37, 99, 235, .16); background: none; }
[data-theme="dark"] .hero h1 em { box-shadow: inset 0 -.18em 0 rgba(59, 130, 246, .24); }

/* ---------- Section head polish ---------- */
.section-head .eyebrow { position: relative; }
.section-head h2 { position: relative; }
.section-head h2::after {
  content: ""; display: block; width: 54px; height: 4px; border-radius: 99px;
  margin: 14px auto 0;
  background: linear-gradient(90deg, var(--blue-dark), #60a5fa);
}

/* ---------- Trust strip ---------- */
.trust-strip { position: relative; z-index: 5; margin-top: -68px; }
.trust-inner {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center;
  gap: 8px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 14px 18px;
  box-shadow: var(--shadow-lg);
}
.trust-chip {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 6px 13px; border-radius: 999px;
  background: var(--bg); color: var(--text);
  font-size: 12px; font-weight: 700; white-space: nowrap;
}
.trust-chip .ic { width: 15px; height: 15px; color: var(--blue); }
[data-theme="dark"] .trust-chip { background: var(--blue-light); }

/* ---------- Sticky purchase CTA ---------- */
.scroll-buy {
  position: fixed; bottom: 16px; left: 0; right: 0; z-index: 160;
  opacity: 0; transform: translateY(24px); pointer-events: none;
  transition: opacity .25s ease, transform .25s ease;
}
.scroll-buy.show { opacity: 1; transform: none; pointer-events: auto; }
.scroll-buy-inner {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  max-width: 760px;
  padding: 10px 16px;
  border-radius: 15px;
  background: linear-gradient(135deg, rgba(30, 58, 138, .97), rgba(29, 78, 216, .97) 55%, rgba(59, 130, 246, .97));
  border: 1px solid rgba(255, 255, 255, .18);
  box-shadow: 0 22px 50px -16px rgba(2, 6, 23, .55);
  backdrop-filter: blur(8px);
}
.scroll-buy-text { display: flex; flex-direction: column; line-height: 1.5; min-width: 0; }
.scroll-buy-text strong { color: #fff; font-size: 13px; font-weight: 800; }
.scroll-buy-text span { color: rgba(255, 255, 255, .72); font-size: 11px; }
.scroll-buy .btn-light { flex-shrink: 0; }

/* ---------- Gallery zoom ---------- */
.shot { position: relative; }
.shot img { cursor: zoom-in; }
.shot-zoom {
  position: absolute; top: 12px; left: 12px;
  display: inline-flex; align-items: center; gap: 6px;
  padding: 7px 13px; border-radius: 999px;
  background: rgba(15, 23, 42, .74); color: #fff; border: 1px solid rgba(255, 255, 255, .22);
  font-size: 11.5px; font-weight: 700; font-family: inherit;
  opacity: 0; transform: translateY(-4px);
  transition: opacity .18s, transform .18s, background .18s;
  backdrop-filter: blur(6px);
}
.shot-zoom .ic { width: 14px; height: 14px; }
.shot:hover .shot-zoom, .shot-zoom:focus-visible { opacity: 1; transform: none; }
.shot-zoom:hover { background: rgba(15, 23, 42, .9); }
@media (hover: none) { .shot-zoom { opacity: 1; transform: none; } }

/* ---------- Lightbox ---------- */
.lightbox {
  position: fixed; inset: 0; z-index: 400;
  background: rgba(2, 6, 23, .9);
  display: flex; flex-direction: column;
  opacity: 0; transition: opacity .2s;
}
.lightbox[hidden] { display: none !important; }
.lightbox.open { opacity: 1; }
.lb-stage {
  flex: 1; overflow: auto; display: flex; align-items: flex-start; justify-content: center;
  padding: 54px 20px 20px;
}
.lb-stage img {
  width: min(1400px, 100%); height: auto; max-width: none;
  border-radius: 10px; background: #fff;
  box-shadow: 0 30px 80px -20px rgba(0, 0, 0, .6);
  cursor: zoom-in;
}
.lightbox.is-zoom .lb-stage img { width: 1900px; cursor: zoom-out; }
.lb-close {
  position: absolute; top: 12px; left: 14px; z-index: 2;
  width: 38px; height: 38px; border-radius: 10px;
  background: rgba(255, 255, 255, .12); color: #fff;
  border: 1px solid rgba(255, 255, 255, .25);
  font-size: 20px; line-height: 1; font-family: inherit;
}
.lb-close:hover { background: rgba(255, 255, 255, .22); }
.lb-caption { text-align: center; color: #cbd5e1; font-size: 12px; padding: 0 20px 18px; }
body.lb-open { overflow: hidden; }

/* ---------- Demo: views & action bar ---------- */
.demo-view[hidden] { display: none !important; }
.demo-viewhead {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  flex-wrap: wrap;
  padding: 13px 16px;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
}
.demo-viewhead h3 {
  display: flex; align-items: center; gap: 8px;
  font-size: 13.5px; font-weight: 800; color: var(--blue-deeper);
}
[data-theme="dark"] .demo-viewhead h3 { color: #bfdbfe; }
.demo-viewhead h3 .ic { width: 16px; height: 16px; }
.viewhead-actions { display: flex; align-items: center; gap: 8px; }
.chip-note {
  font-size: 10.5px; color: var(--muted);
  background: var(--bg); border: 1px solid var(--border);
  padding: 3px 10px; border-radius: 999px;
}
.demo-actionbar {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 9px 14px;
  background: var(--surface-2);
  border-bottom: 1px solid var(--border);
}
.demo-selectall {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 12px; font-weight: 700; color: var(--text); cursor: pointer;
}
.demo-selectall input { accent-color: var(--blue); width: 14px; height: 14px; }
.sel-chip {
  display: inline-flex; align-items: center; gap: 5px;
  background: var(--blue);
  color: #fff; border-radius: 999px;
  padding: 2px 10px; font-size: 11px; font-weight: 700;
}
.sel-chip b { background: rgba(255, 255, 255, .24); border-radius: 999px; padding: 0 6px; font-size: 10.5px; }
.demo-actionbar-right { margin-right: auto; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
#demo-bulk-toggle.is-open { background: var(--blue-deeper); }
.demo-round { display: inline-flex; align-items: center; gap: 6px; }
.demo-bulkbar .demo-round .demo-select { max-width: 118px; }
.demo-bulkbar #demo-bulk-cat { max-width: 160px; }
.bulk-count { white-space: nowrap; }

/* ---------- Demo table: plugin columns ---------- */
.demo-section .container { max-width: 1300px; }
.demo-table { min-width: 1230px; }
.demo-table thead th { padding: 9px 7px; }
.demo-table td { padding: 8px 7px; }
.demo-table .col-id { width: 40px; text-align: center; color: var(--muted); font-size: 11px; }
.demo-table th small { font-weight: 500; opacity: .75; font-size: 9.5px; }
.demo-table tbody tr > td:nth-child(4) { min-width: 210px; max-width: 280px; }
.demo-table .col-actions { width: 70px; }
.cell-id span { font-size: 11px; color: var(--muted); }
.cell-time { font-size: 10.5px; color: var(--muted); white-space: nowrap; }
.cell-muted { color: var(--muted); font-size: 11.5px; }
td.cell-empty .cell-val { color: #cbd5e1; }
.cat-chip {
  display: inline-block; padding: 2px 8px; border-radius: 6px;
  font-size: 10.5px; font-weight: 700; white-space: nowrap;
}
.cat-chip.c1 { background: #fef3c7; color: #b45309; }
.cat-chip.c2 { background: #dbeafe; color: #1d4ed8; }
.cat-chip.c3 { background: #ede9fe; color: #6d28d9; }
.cat-chip.c4 { background: #dcfce7; color: #15803d; }
.cat-chip.c5 { background: #f1f5f9; color: #475569; }
[data-theme="dark"] .cat-chip.c1 { background: #3a2a08; color: #fcd34d; }
[data-theme="dark"] .cat-chip.c2 { background: #142a4d; color: #93c5fd; }
[data-theme="dark"] .cat-chip.c3 { background: #2a1f47; color: #c4b5fd; }
[data-theme="dark"] .cat-chip.c4 { background: #0b2e1d; color: #86efac; }
[data-theme="dark"] .cat-chip.c5 { background: #1e293b; color: #cbd5e1; }
.demo-thumb.c1 { background: linear-gradient(145deg, #fbbf24, #d97706); }
.demo-thumb.c2 { background: linear-gradient(145deg, #60a5fa, #1d4ed8); }
.demo-thumb.c3 { background: linear-gradient(145deg, #a78bfa, #6d28d9); }
.demo-thumb.c4 { background: linear-gradient(145deg, #4ade80, #15803d); }
.demo-thumb.c5 { background: linear-gradient(145deg, #94a3b8, #475569); }
.row-act {
  width: 27px; height: 27px; border-radius: 7px;
  display: inline-grid; place-items: center;
  background: var(--surface); border: 1px solid var(--border); color: var(--muted);
  transition: all .15s;
}
.row-act + .row-act { margin-right: 4px; }
.row-act .ic { width: 13px; height: 13px; }
.row-act:hover { color: var(--blue); border-color: var(--blue-pale); background: var(--blue-light); }
.row-act.danger:hover { color: var(--red); border-color: #fecaca; background: var(--red-soft); }
.var-row .var-name { font-size: 11px; }
.col-actions.nowrap { white-space: nowrap; }

/* ---------- Demo: history & trash ---------- */
.hist-table { min-width: 960px; font-size: 11.5px; }
.hist-table .col-actions { width: 112px; }
.hist-before { color: var(--muted); text-decoration: line-through; }
.hist-after { color: var(--green); font-weight: 700; }
.hist-table td { padding: 8px 9px; }
.kind-chip {
  display: inline-block; padding: 1px 8px; border-radius: 5px;
  font-size: 9.5px; font-weight: 700;
}
.kind-chip.bulk { background: var(--blue-pale); color: var(--blue-dark); }
.kind-chip.single { background: var(--bg); color: var(--muted); }
[data-theme="dark"] .kind-chip.bulk { background: #1b2c4d; color: #bfdbfe; }
.trash-table { min-width: 760px; }
.btn-danger-ghost { background: var(--surface); color: var(--red); border-color: #fecaca; }
.btn-danger-ghost:hover { background: var(--red-soft); border-color: #fca5a5; }
.pv-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 4px 0 8px; margin-bottom: 6px;
  border-bottom: 1px solid var(--border);
  font-weight: 800; color: var(--blue-deeper);
  font-size: 11.5px;
}
[data-theme="dark"] .pv-head { color: #bfdbfe; }
.sel-chip[hidden], .demo-round[hidden], .demo-bulkbar [hidden] { display: none !important; }

/* ---------- Demo: settings cards ---------- */
.ds-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; padding: 14px; background: var(--surface-2); }
.ds-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 12px; padding: 14px 16px;
}
.ds-card h4 { font-size: 12.5px; font-weight: 800; color: var(--blue-deeper); margin-bottom: 6px; }
[data-theme="dark"] .ds-card h4 { color: #bfdbfe; }
.ds-row {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 8px 0; border-bottom: 1px dashed var(--border);
  font-size: 11.5px; color: var(--muted);
}
.ds-card .ds-row:last-child { border-bottom: none; padding-bottom: 2px; }
.ds-num { width: 72px; text-align: center; height: 30px !important; }
.ds-row .demo-select { height: 30px; max-width: 150px; }
.ds-toggle { position: relative; display: inline-block; flex-shrink: 0; }
.ds-toggle input { position: absolute; opacity: 0; width: 0; height: 0; }
.ds-toggle i {
  display: block; width: 36px; height: 20px; border-radius: 999px;
  background: var(--border); position: relative; cursor: pointer;
  transition: background .18s;
}
.ds-toggle i::after {
  content: ""; position: absolute; top: 2px; right: 2px;
  width: 16px; height: 16px; border-radius: 50%; background: #fff;
  box-shadow: 0 1px 3px rgba(15, 23, 42, .25);
  transition: transform .18s;
}
.ds-toggle input:checked + i { background: var(--blue); }
.ds-toggle input:checked + i::after { transform: translateX(-16px); }

/* ---------- Quick editor modal ---------- */
.qe-overlay {
  position: fixed; inset: 0; z-index: 350;
  background: rgba(2, 6, 23, .55);
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
  opacity: 0; transition: opacity .18s;
}
.qe-overlay[hidden] { display: none !important; }
.qe-overlay.open { opacity: 1; }
.qe-modal {
  width: min(660px, 100%); max-height: 88vh;
  display: flex; flex-direction: column;
  background: var(--surface); border-radius: 16px;
  box-shadow: 0 40px 90px -24px rgba(2, 6, 23, .6);
  overflow: hidden;
  transform: translateY(12px); transition: transform .18s;
}
.qe-overlay.open .qe-modal { transform: none; }
.qe-head {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 12px 16px;
  background: linear-gradient(135deg, var(--blue-deeper), var(--blue-dark) 60%, var(--blue-mid));
  color: #fff;
}
.qe-head h3 { font-size: 13.5px; font-weight: 800; display: flex; align-items: center; gap: 7px; min-width: 0; }
.qe-head h3 .ic { width: 16px; height: 16px; flex-shrink: 0; }
.qe-head h3 span { color: #dbeafe; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.qe-close {
  width: 28px; height: 28px; border-radius: 7px; flex-shrink: 0;
  background: rgba(255, 255, 255, .18); color: #fff;
  border: 1px solid rgba(255, 255, 255, .3);
  font-size: 16px; line-height: 1; font-family: inherit;
}
.qe-close:hover { background: rgba(255, 255, 255, .32); }
.qe-body { overflow-y: auto; padding: 8px 14px 14px; background: var(--surface-2); }
.qe-acc { background: var(--surface); border: 1px solid var(--border); border-radius: 10px; margin-top: 8px; }
.qe-acc summary {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 9px 12px; font-size: 12px; font-weight: 700; color: var(--text);
  cursor: pointer; list-style: none;
}
.qe-acc summary::-webkit-details-marker { display: none; }
.qe-acc .chev { width: 14px; height: 14px; color: var(--muted); transition: transform .2s; }
.qe-acc[open] .chev { transform: rotate(180deg); }
.qe-acc-body { padding: 0 12px 12px; }
.qe-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding-top: 4px; }
.qe-grid label {
  display: flex; flex-direction: column; gap: 4px;
  font-size: 11px; font-weight: 600; color: var(--muted);
}
.qe-grid .demo-input, .qe-grid .demo-select { height: 32px; font-size: 12px; }
.qe-span { grid-column: 1 / -1; }
.qe-foot {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  padding: 10px 16px;
  border-top: 1px solid var(--border); background: var(--surface);
}
.qe-note { font-size: 10.5px; color: var(--muted); margin-left: auto; }
body.qe-open { overflow: hidden; }
body.has-scroll-buy .toast { bottom: 84px; }
body.qe-open .scroll-buy, body.lb-open .scroll-buy { opacity: 0 !important; pointer-events: none !important; }

/* ---------- Extra polish ---------- */
.purchase-panel .btn-light:hover { box-shadow: 0 14px 34px -10px rgba(2, 6, 23, .55); }
.demo-shell { box-shadow: 0 30px 70px -30px rgba(15, 23, 42, .3); }
[data-theme="dark"] .demo-shell { box-shadow: 0 30px 70px -30px rgba(0, 0, 0, .7); }

@media (max-width: 860px) {
  .scroll-buy-text span { display: none; }
  .ds-grid { grid-template-columns: 1fr; }
  .demo-table { min-width: 1060px; }
}
@media (max-width: 680px) {
  .trust-strip { margin-top: -46px; }
  .trust-inner { padding: 10px; gap: 6px; justify-content: flex-start; }
  .trust-chip { font-size: 10.5px; padding: 5px 10px; }
  .demo-tabs, .gallery-tabs { flex-wrap: wrap; overflow: visible; padding-bottom: 8px; }
  .demo-tabs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); padding: 0; margin-bottom: 0; }
  .demo-tab { justify-content: center; padding: 11px 8px; margin: 0; border-bottom: 1px solid var(--border); border-radius: 0; }
  .demo-tab.active { border-bottom-color: var(--border); box-shadow: inset 0 -2px 0 var(--blue); background: var(--blue-light); }
  .demo-tab, .g-tab { flex-shrink: 1; }
  .scroll-buy { bottom: 10px; }
  .scroll-buy-inner { padding: 8px 12px; gap: 10px; }
  .scroll-buy-text strong { font-size: 11.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .scroll-buy .btn { height: 34px; padding: 0 12px; font-size: 12px; }
  .shot img { max-height: 330px; }
  .lb-stage { padding: 50px 0 12px; }
  .lb-stage img { border-radius: 0; }
  .shot-zoom { font-size: 10.5px; padding: 5px 10px; }
  .demo-actionbar-right { width: 100%; margin-right: 0; }
  .demo-actionbar-right .btn { flex: 1; }
  .demo-bulkbar .demo-select { max-width: none; flex: 1 1 140px; }
  .demo-bulkbar .demo-input { flex: 1 1 90px; width: auto; }
  .qe-overlay { padding: 0; align-items: flex-end; }
  .qe-modal { max-height: 94vh; border-radius: 16px 16px 0 0; }
  .qe-grid { grid-template-columns: 1fr; }
  .qe-note { width: 100%; margin-left: 0; order: 3; }
  .demo-table { min-width: 980px; }
  .pv-name { max-width: 55%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
}
@media (max-width: 420px) {
  .scroll-buy-text { display: none; }
  .scroll-buy-inner { justify-content: center; }
  .scroll-buy .btn { width: 100%; }
}

/* ==========================================================================
   v3 — Motion pass: live demo, gallery carousel, hero & section micro-motion
   ========================================================================== */

/* ---------- Section head shimmer ---------- */
.section-head h2::after {
  background-image: linear-gradient(90deg, var(--blue-dark), #60a5fa, var(--blue-dark));
  background-size: 200% 100%;
  animation: barShine 5.5s linear infinite;
}
@keyframes barShine { to { background-position: -200% 0; } }

/* ---------- Hero: tilt + shimmer ---------- */
.hero-frame {
  --tilt-x: 0deg; --tilt-y: 0deg;
  transform: perspective(1100px) rotateX(var(--tilt-x)) rotateY(var(--tilt-y)) rotate(-.6deg);
  transition: transform .4s cubic-bezier(.2, .7, .3, 1);
}
.hero-cta .btn-primary {
  background: linear-gradient(110deg, var(--blue-dark) 0%, var(--blue-mid) 38%, #7cb2ff 50%, var(--blue-mid) 62%, var(--blue-dark) 100%);
  background-size: 220% 100%;
  animation: ctaShine 6.5s ease-in-out infinite;
}
@keyframes ctaShine { 0%, 100% { background-position: 0% 0; } 50% { background-position: 100% 0; } }

/* ---------- Trust strip float ---------- */
.trust-chip { animation: chipFloat 6.5s ease-in-out infinite; }
.trust-chip:nth-child(2) { animation-delay: -.7s; }
.trust-chip:nth-child(3) { animation-delay: -1.4s; }
.trust-chip:nth-child(4) { animation-delay: -2.1s; }
.trust-chip:nth-child(5) { animation-delay: -2.8s; }
.trust-chip:nth-child(6) { animation-delay: -3.5s; }
@keyframes chipFloat { 50% { transform: translateY(-3px); } }

/* ---------- Pain cards ---------- */
.pain-card { position: relative; overflow: hidden; }
.pain-card::before {
  content: ""; position: absolute; inset: 0 0 auto 0; height: 3px;
  background: linear-gradient(90deg, var(--blue), #60a5fa);
  transform: scaleX(0); transform-origin: right;
  transition: transform .35s ease;
}
.pain-card:hover::before { transform: scaleX(1); }
.pain-icon { transition: transform .3s ease; }
.pain-card:hover .pain-icon { transform: rotate(-7deg) scale(1.07); }
html.js-reveal .pain-grid .reveal:nth-child(2) { transition-delay: .08s; }
html.js-reveal .pain-grid .reveal:nth-child(3) { transition-delay: .16s; }

/* ---------- Gallery: crossfade, arrows, auto progress ---------- */
.gallery-frame { position: relative; }
.gal-counter {
  font-size: 10px; font-weight: 700; color: var(--muted);
  direction: ltr; background: var(--bg); border: 1px solid var(--border);
  border-radius: 999px; padding: 2px 9px; white-space: nowrap;
}
.gal-nav {
  position: absolute; top: 42%; z-index: 4;
  width: 38px; height: 38px; border-radius: 50%;
  display: grid; place-items: center;
  background: rgba(15, 23, 42, .55); color: #fff;
  border: 1px solid rgba(255, 255, 255, .28);
  backdrop-filter: blur(6px);
  opacity: 0; transform: scale(.92);
  transition: opacity .2s, transform .2s, background .2s;
}
.gal-nav .ic { width: 18px; height: 18px; }
.gal-prev { inset-inline-start: 14px; }
.gal-next { inset-inline-end: 14px; }
.gal-prev .ic { transform: rotate(-90deg); }
.gal-next .ic { transform: rotate(90deg); }
.gallery-frame:hover .gal-nav, .gal-nav:focus-visible { opacity: 1; transform: none; }
.gal-nav:hover { background: rgba(15, 23, 42, .85); }
@media (hover: none) { .gal-nav { opacity: 1; transform: none; } }

.gal-progress {
  position: absolute; inset-inline: 0; bottom: -1px; height: 2px; z-index: 5;
  opacity: 0; transition: opacity .25s; pointer-events: none;
}
.gallery-frame.auto .gal-progress { opacity: 1; }
.gal-progress i {
  display: block; height: 100%; width: 100%;
  background: linear-gradient(90deg, var(--blue), #60a5fa);
  transform: scaleX(0); transform-origin: right;
}
.gallery-frame.auto .gal-progress i { animation: galProg 7s linear forwards; }
@keyframes galProg { to { transform: scaleX(1); } }

.shot.active { animation: shotIn .5s cubic-bezier(.2, .7, .3, 1) both; }
@keyframes shotIn { from { opacity: .3; transform: scale(1.012); } to { opacity: 1; transform: none; } }
.shot.active figcaption strong { animation: capIn .45s .08s both; }
.shot.active figcaption span { animation: capIn .45s .16s both; }
@keyframes capIn { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: none; } }
.g-tab .ic { transition: transform .2s; }
.g-tab:hover .ic { transform: scale(1.14); }
.g-tab.active { background: linear-gradient(135deg, var(--blue-light), rgba(37, 99, 235, .07)); }

/* ---------- Demo: guide, aura, live chip, views ---------- */
.demo-section { overflow-x: clip; overflow-y: visible; }
.demo-wrap { position: relative; }
.demo-aura {
  position: absolute; width: 420px; height: 420px; border-radius: 50%;
  filter: blur(70px); opacity: .5; pointer-events: none; z-index: 0;
}
.demo-aura.aura-a { background: #bfdbfe; top: -70px; inset-inline-start: -90px; animation: floatA 11s ease-in-out infinite; }
.demo-aura.aura-b { background: #c7d2fe; bottom: -80px; inset-inline-end: -70px; animation: floatB 14s ease-in-out infinite; }
[data-theme="dark"] .demo-aura { opacity: .3; }
.demo-wrap .demo-shell { position: relative; z-index: 1; transition: box-shadow .25s, border-color .25s; }
.demo-wrap .demo-shell:focus-within {
  border-color: var(--blue-pale);
  box-shadow: 0 30px 70px -30px rgba(15, 23, 42, .3), 0 0 0 4px rgba(37, 99, 235, .07);
}

.demo-guide {
  display: flex; align-items: center; justify-content: center; gap: 12px;
  flex-wrap: wrap; margin: -16px 0 18px;
}
.dg-title {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12px; font-weight: 800; color: var(--blue);
}
.dg-title .ic { width: 15px; height: 15px; }
.dg-steps { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.dg-step {
  display: inline-flex; align-items: center; gap: 7px;
  font-family: inherit; font-size: 11.5px; font-weight: 700; color: var(--text);
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 999px; padding: 7px 12px;
  transition: border-color .2s, box-shadow .2s, transform .15s, background .2s;
}
.dg-step:hover { border-color: var(--blue-pale); transform: translateY(-1px); }
.dg-num {
  width: 21px; height: 21px; border-radius: 50%; flex: none;
  display: grid; place-items: center;
  background: var(--blue-light); color: var(--blue);
  font-size: 10.5px; font-weight: 800;
  transition: background .2s, color .2s;
}
.dg-arrow { width: 13px; height: 13px; color: #94a3b8; }
.dg-step.is-next {
  border-color: var(--blue);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, .1);
  animation: dgPulse 1.7s ease-in-out infinite;
}
@keyframes dgPulse { 50% { box-shadow: 0 0 0 7px rgba(37, 99, 235, .02); } }
.dg-step.is-done .dg-num { background: var(--green); color: #fff; font-size: 0; }
.dg-step.is-done .dg-num::before { content: "✓"; font-size: 11px; }

.demo-live {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 10.5px; font-weight: 800; color: var(--green);
  background: var(--green-soft); border-radius: 999px; padding: 3px 10px;
}
.demo-live i { width: 6px; height: 6px; border-radius: 50%; background: var(--green); animation: livePulse 1.9s infinite; }

.demo-view:not([hidden]) { animation: viewIn .38s cubic-bezier(.2, .7, .3, 1) both; }
@keyframes viewIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.demo-bulkbar:not([hidden]), .demo-preview:not([hidden]) { animation: barIn .28s ease both; }
@keyframes barIn { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
.pill-count, .demo-saved-count, .chip-note { will-change: transform; }
.demo-saved-count, .chip-note { display: inline-block; }
.pill-count.bump, .demo-saved-count.bump { animation: bump .55s cubic-bezier(.2, .7, .3, 1); }
@keyframes bump { 40% { transform: scale(1.28); } }
#demo-apply-btn.pulse-hint { animation: hintPulse 1.15s ease 2; }
@keyframes hintPulse { 50% { box-shadow: 0 0 0 7px rgba(37, 99, 235, .16); } }

.demo-tab { transition: color .15s, background .15s; }
.demo-tab:hover { background: var(--surface-2); }
.demo-thumb { transition: transform .18s ease; }
.demo-table tbody tr:hover .demo-thumb { transform: scale(1.08) rotate(-3deg); }
.demo-hintbar .ic { animation: hintWiggle 4.5s ease-in-out infinite; }
@keyframes hintWiggle { 0%, 86%, 100% { transform: rotate(0); } 90% { transform: rotate(-14deg); } 94% { transform: rotate(11deg); } }

/* ---------- Compare rows ---------- */
.compare-table-wrap.reveal.in tbody tr { animation: cmpRow .5s cubic-bezier(.2, .7, .3, 1) both; }
.compare-table-wrap.reveal.in tbody tr:nth-child(1) { animation-delay: .02s; }
.compare-table-wrap.reveal.in tbody tr:nth-child(2) { animation-delay: .07s; }
.compare-table-wrap.reveal.in tbody tr:nth-child(3) { animation-delay: .12s; }
.compare-table-wrap.reveal.in tbody tr:nth-child(4) { animation-delay: .17s; }
.compare-table-wrap.reveal.in tbody tr:nth-child(5) { animation-delay: .22s; }
.compare-table-wrap.reveal.in tbody tr:nth-child(6) { animation-delay: .27s; }
.compare-table-wrap.reveal.in tbody tr:nth-child(7) { animation-delay: .32s; }
.compare-table-wrap.reveal.in tbody tr:nth-child(8) { animation-delay: .37s; }
.compare-table-wrap.reveal.in tbody tr:nth-child(9) { animation-delay: .42s; }
.compare-table-wrap.reveal.in tbody tr:nth-child(10) { animation-delay: .47s; }
@keyframes cmpRow { from { opacity: 0; transform: translateX(12px); } to { opacity: 1; transform: none; } }

/* ---------- Install steps ---------- */
.steps { position: relative; }
.steps::before {
  content: ""; position: absolute; top: 49px; inset-inline: 46px; height: 2px; z-index: 0;
  background-image: repeating-linear-gradient(90deg, rgba(37, 99, 235, .45) 0 8px, transparent 8px 17px);
  background-size: 34px 2px;
  animation: dashFlow 1.1s linear infinite;
}
@keyframes dashFlow { to { background-position: -34px 0; } }
.step { z-index: 1; transition: transform .2s, box-shadow .2s; }
.step:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.step-num { position: relative; }
.step-num::after {
  content: ""; position: absolute; inset: -4px; border-radius: 14px;
  border: 1.5px solid rgba(37, 99, 235, .35);
  animation: numRing 2.6s ease-out infinite;
}
.step:nth-child(2) .step-num::after { animation-delay: .55s; }
.step:nth-child(3) .step-num::after { animation-delay: 1.1s; }
@keyframes numRing { 0% { opacity: .85; transform: scale(1); } 70%, 100% { opacity: 0; transform: scale(1.4); } }
html.js-reveal .step.reveal:nth-child(2) { transition-delay: .1s; }
html.js-reveal .step.reveal:nth-child(3) { transition-delay: .2s; }

/* ---------- FAQ ---------- */
.faq-body { overflow: hidden; transition: height .3s cubic-bezier(.2, .7, .3, 1); }
.faq-item { transition: border-color .15s, box-shadow .15s, transform .18s; }
.faq-item:hover { transform: translateX(-2px); }
.faq-item summary .ic { transition: transform .25s, color .2s; }

/* ---------- Purchase ---------- */
.purchase-panel::before { animation: artFloat 13s ease-in-out infinite; }
.purchase-panel::after { animation: artFloat2 17s ease-in-out infinite; }
@keyframes artFloat { 50% { transform: translate(30px, 24px); } }
@keyframes artFloat2 { 50% { transform: translate(-18px, -22px); } }
.purchase-panel .art-logo { animation: artBreath 6s ease-in-out infinite; }
@keyframes artBreath { 50% { transform: translate(50%, -50%) scale(1.045); } }
.art-logo::after {
  content: ""; position: absolute; inset: -10px; border-radius: 44px;
  border: 1.5px solid rgba(255, 255, 255, .26);
  animation: numRing 3.4s ease-out infinite;
}
.purchase-actions .btn-light { position: relative; overflow: hidden; }
.purchase-actions .btn-light::after {
  content: ""; position: absolute; top: 0; bottom: 0; width: 55%; left: -80%;
  background: linear-gradient(100deg, transparent, rgba(37, 99, 235, .16), transparent);
  transform: skewX(-14deg);
  animation: btnSheen 4.8s ease-in-out infinite;
}
@keyframes btnSheen { 0%, 62% { left: -80%; } 88%, 100% { left: 125%; } }

/* ---------- Footer ---------- */
.footer-links a { transition: color .15s, transform .15s; }
.footer-links a:hover { transform: translateX(-3px); }

/* ---------- v3 responsive ---------- */
@media (max-width: 860px) {
  .hero-frame { transform: none; }
  .steps::before { display: none; }
}
@media (max-width: 680px) {
  .demo-guide { justify-content: flex-start; margin-top: -6px; }
  .dg-steps { width: 100%; flex-wrap: nowrap; overflow-x: auto; padding-bottom: 3px; scrollbar-width: none; }
  .dg-step { flex-shrink: 0; font-size: 11px; padding: 6px 10px; }
  .dg-arrow { display: none; }
  .demo-live { display: none; }
  .gal-counter { display: none; }
  .gal-nav { width: 34px; height: 34px; }
}
