/* ============================================================
   KardKache — App Styles
   Apple Gallery aesthetic · Warm light · Gold accent
   ============================================================ */

/* ============================================================
   NAVBAR — Frosted glass top bar
   ============================================================ */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: oklch(from var(--color-bg) l c h / 0.8);
  backdrop-filter: blur(20px) saturate(1.8);
  -webkit-backdrop-filter: blur(20px) saturate(1.8);
  border-bottom: 1px solid oklch(from var(--color-border) l c h / 0.5);
}
.navbar-inner {
  max-width: var(--content-max);
  margin: 0 auto;
  padding: var(--space-3) var(--space-6);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
}
.navbar-logo {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  text-decoration: none;
  color: var(--color-text);
  font-weight: 600;
  font-size: var(--text-sm);
  transition: opacity var(--transition-interactive);
}
.navbar-logo:hover { opacity: 0.7; }
.navbar-logo-text { letter-spacing: -0.02em; }
.navbar-actions {
  display: flex;
  align-items: center;
  gap: var(--space-1);
}

.nav-icon-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  color: var(--color-text-muted);
  cursor: pointer;
  transition: all var(--transition-interactive);
  position: relative;
}
.nav-icon-btn:hover {
  color: var(--color-text);
  background: var(--color-surface-2);
}
.notif-badge {
  position: absolute;
  top: 2px;
  right: 2px;
  min-width: 16px;
  height: 16px;
  border-radius: var(--radius-full);
  background: var(--color-error);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  padding: 0 4px;
}

/* ============================================================
   HERO SECTION
   ============================================================ */
.hero-section {
  position: relative;
  min-height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: calc(56px + var(--space-10)) var(--space-4) var(--space-10);
  overflow: hidden;
  background: var(--color-bg);
}
.hero-bg {
  display: none;
}
.hero-content {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-5);
  width: 100%;
  max-width: 480px;
  text-align: center;
}

/* Hero Ambient Glow — retained for teal accent glow effect */
.hero-blur-bg {
  position: absolute;
  inset: -100px;
  z-index: 0;
  opacity: 0;
  transition: opacity 1.8s cubic-bezier(0.4, 0, 0.2, 1);
  filter: blur(30px);
}
.hero-blur-bg.active {
  opacity: 0.5;
}
[data-theme="dark"] .hero-blur-bg {
  filter: blur(30px) saturate(1.8);
}
[data-theme="dark"] .hero-blur-bg.active {
  opacity: 0.9;
}

/* Noise texture overlay for depth */
.hero-section::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0.03;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 128px 128px;
}

/* Vignette overlay — soft edge fades into page bg */
.hero-section::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    radial-gradient(ellipse 90% 80% at 50% 45%, transparent 40%, var(--color-bg) 100%);
}

/* KardKache Hero Brand Lockup */
.hero-brand-lockup {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-3);
  animation: float-k 6s ease-in-out infinite;
  position: relative;
  z-index: 2;
}
.hero-logo-lockup {
  flex-shrink: 0;
}
.hero-wordmark {
  font-family: 'Rajdhani', sans-serif;
  font-size: 2.5rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--color-text);
  text-transform: uppercase;
  line-height: 1;
}
@keyframes float-k {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-12px); }
}

/* KardKache Hero Tagline */
.hero-tagline {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  letter-spacing: 0.04em;
  position: relative;
  z-index: 2;
}

/* Hero Pill CTA Buttons */
.hero-pills {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
  position: relative;
  z-index: 2;
  flex-wrap: wrap;
}
.hero-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-6);
  border-radius: var(--radius-full);
  background: oklch(from var(--color-surface) l c h / 0.65);
  backdrop-filter: blur(16px) saturate(1.6);
  -webkit-backdrop-filter: blur(16px) saturate(1.6);
  color: var(--color-text);
  font-size: var(--text-base);
  font-weight: 500;
  border: 1px solid oklch(from var(--color-border) l c h / 0.4);
  cursor: pointer;
  transition: all 0.25s ease;
  white-space: nowrap;
  letter-spacing: 0.01em;
}
.hero-pill:hover {
  background: oklch(from var(--color-surface-2) l c h / 0.8);
  border-color: var(--color-border);
  transform: translateY(-2px);
}
.hero-pill-accent {
  background: oklch(from var(--color-primary) l c h / 0.18);
  border-color: oklch(from var(--color-primary) l c h / 0.5);
  color: var(--color-primary);
}
.hero-pill-accent:hover {
  background: oklch(from var(--color-primary) l c h / 0.28);
  border-color: var(--color-primary);
  color: var(--color-primary);
}

/* Keep hero-action-btn for any legacy references */
.hero-action-btn {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius-full);
  background: oklch(from var(--color-surface) l c h / 0.65);
  backdrop-filter: blur(16px) saturate(1.6);
  -webkit-backdrop-filter: blur(16px) saturate(1.6);
  color: var(--color-text);
  font-size: var(--text-sm);
  font-weight: 500;
  border: 1px solid oklch(from var(--color-border) l c h / 0.4);
  cursor: pointer;
  transition: all 0.25s ease;
  white-space: nowrap;
}
.hero-action-btn:hover {
  background: oklch(from var(--color-surface-2) l c h / 0.8);
  border-color: var(--color-border);
  transform: translateY(-1px);
}
.hero-action-btn svg {
  flex-shrink: 0;
  opacity: 0.7;
}

/* ============================================================
   SECTION LAYOUT
   ============================================================ */
.section-inner {
  max-width: var(--content-max);
  margin: 0 auto;
  padding: 0 var(--space-6);
}
.section-title {
  font-size: var(--text-xl);
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--color-text);
  margin-bottom: var(--space-6);
}

/* ============================================================
   INSIGHTS SECTION
   ============================================================ */
.insights-section {
  padding: var(--space-16) 0;
  background: var(--color-surface-2);
}
.insights-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-4);
}
.insight-panel {
  background: var(--color-surface);
  border-radius: var(--radius-2xl);
  padding: var(--space-6);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--color-divider);
}
.insight-panel-wide {
  grid-column: 1 / -1;
}
.insight-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-4);
}
.insight-panel-title {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text);
  letter-spacing: -0.01em;
  margin-bottom: var(--space-3);
}
.insight-panel-header .insight-panel-title {
  margin-bottom: 0;
}
.insight-chart-range {
  display: flex;
  gap: 2px;
  background: var(--color-surface-2);
  border-radius: var(--radius-full);
  padding: 2px;
}
.insight-range-btn {
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-full);
  font-size: 11px;
  font-weight: 600;
  color: var(--color-text-muted);
  cursor: pointer;
  transition: all var(--transition-interactive);
}
.insight-range-btn:hover { color: var(--color-text); }
.insight-range-btn.active {
  background: var(--color-surface);
  color: var(--color-text);
  box-shadow: var(--shadow-sm);
}

/* Portfolio Chart */
.insight-chart-wrap {
  height: 200px;
  position: relative;
}

/* Sport Breakdown */
.sport-breakdown {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}
.sport-bar-row {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}
.sport-bar-label {
  font-size: var(--text-xs);
  font-weight: 500;
  color: var(--color-text-muted);
  min-width: 80px;
}
.sport-bar-track {
  flex: 1;
  height: 8px;
  background: var(--color-surface-2);
  border-radius: var(--radius-full);
  overflow: hidden;
}
.sport-bar-fill {
  height: 100%;
  border-radius: var(--radius-full);
  background: var(--color-primary);
  transition: width 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}
.sport-bar-value {
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--color-text);
  min-width: 60px;
  text-align: right;
}

/* Grading Stats */
.grading-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-3);
}
.grading-stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: var(--space-3);
  background: var(--color-surface-2);
  border-radius: var(--radius-lg);
}
.grading-stat-num {
  font-size: var(--text-xl);
  font-weight: 700;
  color: var(--color-primary);
  line-height: 1.1;
}
.grading-stat-label {
  font-size: 11px;
  color: var(--color-text-muted);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* Decade Breakdown */
.decade-breakdown {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}
.decade-row {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}
.decade-label {
  font-size: var(--text-xs);
  font-weight: 500;
  color: var(--color-text-muted);
  min-width: 50px;
}
.decade-dots {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}
.decade-dot {
  width: 10px;
  height: 10px;
  border-radius: var(--radius-full);
  background: var(--color-primary);
}

/* Top 5 */
.top5-section {
  margin-top: var(--space-6);
}
.top5-scroll {
  display: flex;
  gap: var(--space-4);
  overflow-x: auto;
  padding-bottom: var(--space-2);
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}
.top5-scroll::-webkit-scrollbar { height: 4px; }
.top5-scroll::-webkit-scrollbar-track { background: transparent; }
.top5-scroll::-webkit-scrollbar-thumb { background: var(--color-border); border-radius: 2px; }

.top5-card {
  flex: 0 0 auto;
  width: 200px;
  scroll-snap-align: start;
  cursor: pointer;
  transition: transform var(--transition-interactive);
}
.top5-card:hover { transform: translateY(-4px); }
.top5-card-img-wrap {
  width: 200px;
  height: 280px;
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  margin-bottom: var(--space-3);
}
.top5-card-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: var(--color-surface-2);
}
.top5-card-name {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text);
}
.top5-card-value {
  font-size: var(--text-sm);
  font-weight: 700;
  color: var(--color-primary);
}

/* ============================================================
   GALLERY SECTION
   ============================================================ */
.gallery-section {
  padding: var(--space-16) 0;
}
.gallery-header {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  justify-content: flex-start;
  gap: var(--space-4);
  margin-bottom: var(--space-6);
}
.gallery-header-top {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: var(--space-3);
  width: 100%;
}
.gallery-header .section-title { margin-bottom: 0; }
.gallery-open-full-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 36px;
  padding: 0 14px;
  border-radius: var(--radius-full);
  border: 1px solid var(--color-primary-soft);
  background: var(--color-primary-highlight);
  color: var(--color-primary);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-decoration: none;
  transition: all var(--transition-interactive);
}
.gallery-open-full-btn:hover {
  transform: translateY(-1px);
  border-color: var(--color-primary);
  color: #fff;
  background: linear-gradient(135deg, var(--color-primary), #4aa5ff);
}
.gallery-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
  width: 100%;
}
.gallery-trait-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-top: var(--space-2);
}
.gallery-trait-chip {
  border: 1px solid var(--color-border);
  background: var(--color-surface);
  color: var(--color-text-muted);
  border-radius: var(--radius-full);
  padding: 4px 10px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: all var(--transition-interactive);
}
.gallery-trait-chip:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
}
.gallery-trait-chip.active {
  background: var(--color-primary-highlight);
  color: var(--color-primary);
  border-color: var(--color-primary-soft);
}
.gallery-results-hint {
  margin-top: var(--space-2);
  font-size: 12px;
  color: var(--color-text-faint);
}
.gallery-search-wrap {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-3);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  min-width: 180px;
}
.gallery-search-wrap svg {
  flex-shrink: 0;
  color: var(--color-text-faint);
}
.gallery-search-input {
  border: none;
  background: none;
  outline: none;
  font-size: var(--text-xs);
  width: 100%;
  color: var(--color-text);
}
.gallery-search-input::placeholder { color: var(--color-text-faint); }

.gallery-filter-select {
  padding: var(--space-2) var(--space-3);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  font-size: var(--text-xs);
  color: var(--color-text);
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  padding-right: var(--space-6);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%236b6b64' stroke-width='2'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 8px center;
}
.gallery-filter-select:focus {
  border-color: var(--color-primary);
}
.gallery-bulk-btn {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  padding: var(--space-2) var(--space-3);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  font-size: var(--text-xs);
  font-weight: 500;
  color: var(--color-text-muted);
  cursor: pointer;
  transition: all var(--transition-interactive);
}
.gallery-bulk-btn:hover {
  color: var(--color-text);
  border-color: var(--color-primary);
}

/* Card Grid */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: var(--space-3);
}
@media (max-width: 768px) { .gallery-grid { grid-template-columns: repeat(2, 1fr); } }

.gallery-card {
  cursor: pointer;
  transition: transform var(--transition-interactive);
  outline: none;
}
.gallery-card:hover { transform: translateY(-6px); }
.gallery-card-highlight {
  animation: cardPulse 0.6s ease;
}
@keyframes cardPulse {
  0% { transform: scale(1); }
  30% { transform: scale(1.04); }
  60% { transform: scale(0.98); }
  100% { transform: scale(1); }
}
.gallery-card:focus-visible { outline: 2px solid var(--color-primary); outline-offset: 4px; border-radius: var(--radius-xl); }

.gallery-card-img-wrap {
  position: relative;
  aspect-ratio: 5 / 7;
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  transition: box-shadow var(--transition-interactive);
  background: var(--color-surface-2);
}
.gallery-card:hover .gallery-card-img-wrap { box-shadow: var(--shadow-card-hover); }
.gallery-card-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  background: var(--color-surface-2);
}
.gallery-card-badge {
  position: absolute;
  bottom: var(--space-2);
  left: var(--space-2);
  padding: 3px 8px;
  background: oklch(0.15 0 0 / 0.75);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  border-radius: var(--radius-full);
}
.gallery-card-forsale {
  position: absolute;
  top: var(--space-2);
  right: var(--space-2);
  padding: 3px 8px;
  background: var(--color-primary);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  border-radius: var(--radius-full);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.gallery-card-watchlist {
  position: absolute;
  top: var(--space-2);
  left: var(--space-2);
  color: var(--color-primary);
}
.gallery-card-info {
  padding: var(--space-3) var(--space-1) 0;
}
.gallery-card-player {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text);
  display: flex;
  align-items: center;
  gap: var(--space-1);
}
.gallery-card-rookie {
  display: inline-flex;
  padding: 1px 5px;
  background: var(--color-primary-highlight);
  color: var(--color-primary);
  font-size: 10px;
  font-weight: 700;
  border-radius: var(--radius-sm);
}
.gallery-card-meta {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}
.gallery-card-traits {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
  min-height: 18px;
}
.gallery-trait-pill {
  display: inline-flex;
  align-items: center;
  padding: 1px 6px;
  border-radius: var(--radius-sm);
  background: var(--color-surface-2);
  border: 1px solid var(--color-border);
  color: var(--color-text-muted);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.03em;
}
.gallery-trait-pill-mono {
  font-family: var(--font-mono);
}
.gallery-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: var(--space-16) var(--space-4);
  color: var(--color-text-faint);
}

/* ============================================================
   MARKET SECTION
   ============================================================ */
.market-section {
  padding: var(--space-16) 0 var(--space-24);
  background: var(--color-surface-2);
}
.market-subsections {
  display: flex;
  flex-direction: column;
  gap: var(--space-10);
}
.market-section-compact .section-inner {
  display: flex;
  flex-direction: column;
  gap: var(--space-5);
}
.market-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
}
.market-intro {
  margin: var(--space-1) 0 0;
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}
.market-header-actions {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}
.market-pulse-bar {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: var(--space-3);
}
.market-pulse-item {
  background: var(--color-surface);
  border: 1px solid var(--color-divider);
  border-radius: var(--radius-lg);
  padding: var(--space-3) var(--space-4);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.market-pulse-label {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}
.market-pulse-value {
  font-size: var(--text-lg);
  font-weight: 700;
  color: var(--color-text);
}
.market-compact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-4);
}
.market-manage-panel {
  background: var(--color-surface);
  border: 1px solid var(--color-divider);
  border-radius: var(--radius-lg);
  padding: var(--space-2) var(--space-3);
}
.market-manage-panel > summary {
  cursor: pointer;
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text);
  list-style: none;
}
.market-manage-panel > summary::-webkit-details-marker { display: none; }
.market-manage-panel > summary::after {
  content: 'Expand';
  float: right;
  font-size: 11px;
  color: var(--color-text-muted);
  font-weight: 500;
}
.market-manage-panel[open] > summary::after {
  content: 'Collapse';
}
.market-manage-panel .alerts-create {
  margin-top: var(--space-3);
}
.market-more-note {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  padding: 0 var(--space-1);
}
.market-sub-title {
  font-size: var(--text-lg);
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: var(--space-4);
}
.market-for-sale-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: var(--space-4);
}
.market-sale-card {
  background: var(--color-surface);
  border-radius: var(--radius-xl);
  padding: var(--space-4);
  border: 1px solid var(--color-divider);
  display: flex;
  align-items: center;
  gap: var(--space-3);
  cursor: pointer;
  transition: all var(--transition-interactive);
}
.market-sale-card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--color-primary);
}
.market-sale-img {
  width: 64px;
  height: 88px;
  border-radius: var(--radius-md);
  object-fit: contain;
  background: var(--color-surface-2);
  flex-shrink: 0;
}
.market-sale-info { flex: 1; min-width: 0; }
.market-sale-name {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.market-sale-meta {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}
.market-sale-price {
  font-size: var(--text-lg);
  font-weight: 700;
  color: var(--color-primary);
}
.market-empty-msg {
  padding: var(--space-8);
  text-align: center;
  color: var(--color-text-faint);
  font-size: var(--text-sm);
}

/* Activity */
.market-activity {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}
.market-footer-note {
  margin-top: var(--space-4);
  color: var(--color-text-faint);
  font-size: var(--text-xs);
  border-top: 1px solid var(--color-divider);
  padding-top: var(--space-3);
}
.activity-item {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  background: var(--color-surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-divider);
}
.activity-icon {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.activity-icon-sale { background: var(--color-primary-highlight); color: var(--color-primary); }
.activity-icon-alert { background: var(--color-error-highlight); color: var(--color-error); }
.activity-icon-info { background: var(--color-surface-2); color: var(--color-text-muted); }
.activity-msg { font-size: var(--text-xs); color: var(--color-text); flex: 1; }
.activity-time { font-size: 11px; color: var(--color-text-faint); white-space: nowrap; }

/* Alerts */
.alerts-create {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-bottom: var(--space-4);
  align-items: center;
}
.alert-price-input {
  padding: var(--space-2) var(--space-3);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  font-size: var(--text-xs);
  color: var(--color-text);
  width: 120px;
}
.alert-price-input:focus { border-color: var(--color-primary); outline: none; }
.alert-create-btn {
  padding: var(--space-2) var(--space-4);
  background: var(--color-primary);
  color: #fff;
  border-radius: var(--radius-full);
  font-size: var(--text-xs);
  font-weight: 600;
  cursor: pointer;
  transition: background var(--transition-interactive);
}
.alert-create-btn:hover { background: var(--color-primary-hover); }

.alerts-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}
.alert-item {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  background: var(--color-surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-divider);
}
.alert-card-name {
  flex: 1;
  font-size: var(--text-xs);
  font-weight: 500;
  color: var(--color-text);
}
.alert-target {
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--color-primary);
}
.alert-direction {
  font-size: 11px;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.alert-triggered {
  font-size: 10px;
  font-weight: 700;
  color: var(--color-success);
  text-transform: uppercase;
}
.alert-delete-btn {
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  color: var(--color-text-faint);
  cursor: pointer;
  transition: all var(--transition-interactive);
}
.alert-delete-btn:hover { color: var(--color-error); background: var(--color-error-highlight); }

@media (max-width: 900px) {
  .market-pulse-bar {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .market-compact-grid {
    grid-template-columns: 1fr;
  }
  .market-header-row {
    flex-direction: column;
    align-items: flex-start;
  }
}
@media (max-width: 560px) {
  .market-pulse-bar {
    grid-template-columns: 1fr;
  }
}

/* ============================================================
   DETAIL SHEET (bottom sheet)
   ============================================================ */
.sheet-overlay {
  position: fixed;
  inset: 0;
  background: oklch(0 0 0 / 0.4);
  z-index: 200;
  opacity: 0;
  transition: opacity 0.35s ease;
}
.sheet-overlay.visible { opacity: 1; }
.detail-sheet {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  max-height: 85vh;
  background: var(--color-surface);
  border-radius: var(--radius-2xl) var(--radius-2xl) 0 0;
  z-index: 201;
  transform: translateY(100%);
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}
.detail-sheet.visible { transform: translateY(0); }
.sheet-handle {
  display: flex;
  justify-content: center;
  padding: var(--space-3) 0 var(--space-1);
}
.sheet-handle-bar {
  width: 36px;
  height: 4px;
  border-radius: 2px;
  background: var(--color-border);
}
.sheet-content {
  padding: 0 var(--space-6) var(--space-8);
  max-width: 600px;
  margin: 0 auto;
}
/* Close button in detail sheet */
.sheet-close-btn {
  position: sticky;
  top: var(--space-3);
  float: right;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  background: var(--color-surface-2);
  color: var(--color-text-muted);
  cursor: pointer;
  transition: all var(--transition-interactive);
  margin: var(--space-2) var(--space-2) 0 0;
}
.sheet-close-btn:hover {
  background: var(--color-surface-offset);
  color: var(--color-text);
}
/* Card image hero at top of detail sheet */
.sheet-card-hero {
  display: flex;
  justify-content: center;
  padding: var(--space-4) 0 var(--space-2);
}
.sheet-card-img {
  max-height: 280px;
  max-width: 200px;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  transition: transform 0.3s ease;
}
.sheet-card-img:hover {
  transform: scale(1.03);
}
.sheet-card-title {
  text-align: center;
  padding: var(--space-2) 0 var(--space-3);
}
.sheet-player-name {
  font-size: var(--text-lg);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--color-text);
  margin: 0;
}
.sheet-player-meta {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  margin: var(--space-1) 0 0;
}
.sheet-tabs {
  display: inline-flex;
  gap: var(--space-1);
  padding: 2px;
  background: var(--color-surface-2);
  border: 1px solid var(--color-border);
  border-radius: 999px;
  margin: 0 0 var(--space-4);
}
.sheet-tab-btn {
  border: none;
  background: transparent;
  color: var(--color-text-muted);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.02em;
  border-radius: 999px;
  padding: 6px 12px;
  cursor: pointer;
}
.sheet-tab-btn.active {
  background: var(--color-primary);
  color: #fff;
}
.sheet-tab-panel { display: none; }
.sheet-tab-panel.active { display: block; }
.sheet-section {
  padding: var(--space-4) 0;
  border-bottom: 1px solid var(--color-divider);
}
.sheet-section:last-child { border-bottom: none; }
.sheet-section-title {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-faint);
  font-weight: 600;
  margin-bottom: var(--space-3);
}
.sheet-row {
  display: flex;
  justify-content: space-between;
  padding: var(--space-2) 0;
}
.sheet-row-label {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}
.sheet-row-value {
  font-size: var(--text-xs);
  font-weight: 500;
  color: var(--color-text);
  text-align: right;
}
.sheet-value-large {
  font-size: var(--text-xl);
  font-weight: 700;
  color: var(--color-text);
  display: flex;
  align-items: baseline;
  gap: var(--space-2);
  margin-bottom: var(--space-3);
}
.sheet-change {
  font-size: var(--text-sm);
  font-weight: 600;
}
.sheet-change.positive { color: var(--color-success); }
.sheet-change.negative { color: var(--color-error); }
.sheet-chart-wrap {
  height: 160px;
  position: relative;
  margin-bottom: var(--space-3);
}
.sheet-range-btns {
  display: flex;
  gap: var(--space-2);
}
.sheet-range-btn {
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-full);
  font-size: 11px;
  font-weight: 600;
  color: var(--color-text-muted);
  background: var(--color-surface-2);
  cursor: pointer;
  transition: all var(--transition-interactive);
}
.sheet-range-btn:hover { color: var(--color-text); }
.sheet-range-btn.active {
  background: var(--color-primary);
  color: #fff;
}
.sheet-trend-kpis {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin: var(--space-3) 0;
}
.sheet-trend-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: 999px;
  padding: 4px 10px;
  border: 1px solid var(--color-border);
  background: var(--color-surface-2);
}
.sheet-trend-chip-label {
  font-size: 10px;
  color: var(--color-text-faint);
  letter-spacing: 0.04em;
}
.sheet-trend-chip-value {
  font-size: 11px;
  font-weight: 700;
}
.sheet-trend-chip.positive .sheet-trend-chip-value { color: var(--color-success); }
.sheet-trend-chip.negative .sheet-trend-chip-value { color: var(--color-error); }
.sheet-trend-chip.neutral .sheet-trend-chip-value { color: var(--color-text-muted); }
.sheet-trend-insights {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-2);
  margin: 0 0 var(--space-3);
}
.sheet-trend-insight {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border: 1px solid var(--color-divider);
  border-radius: var(--radius-base);
  padding: 7px 9px;
  background: var(--color-surface-2);
}
.sheet-trend-label {
  font-size: 10px;
  color: var(--color-text-faint);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.sheet-trend-value {
  font-size: 12px;
  color: var(--color-text);
  font-weight: 600;
}
.sheet-trend-empty {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: var(--space-4);
  color: var(--color-text-muted);
  font-size: 12px;
  line-height: 1.4;
}
.sheet-comp {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) 0;
  border-bottom: 1px solid var(--color-divider);
  font-size: var(--text-xs);
}
.sheet-comp:last-child { border-bottom: none; }
.sheet-comp-img {
  width: 40px; height: 40px; border-radius: 4px;
  object-fit: cover; flex-shrink: 0;
  background: var(--color-surface-secondary);
}
.sheet-comp-info {
  flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px;
}
.sheet-comp-title {
  color: var(--color-text); font-size: var(--text-xs);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  text-decoration: none;
}
a.sheet-comp-title:hover { color: var(--color-primary); text-decoration: underline; }
.sheet-comp-meta {
  color: var(--color-text-faint); font-size: 10px;
}
.sheet-comp-date { color: var(--color-text-muted); flex: 1; }
.sheet-comp-platform { color: var(--color-text-faint); }
.sheet-comp-price { font-weight: 600; color: var(--color-text); flex-shrink: 0; font-size: var(--text-sm); }
.sale-status-active { color: var(--color-primary); font-weight: 600; }
.sheet-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  padding: var(--space-4) 0;
}
.sheet-action-btn {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-full);
  font-size: var(--text-xs);
  font-weight: 500;
  background: var(--color-surface-2);
  color: var(--color-text-muted);
  cursor: pointer;
  transition: all var(--transition-interactive);
  border: 1px solid transparent;
}
.sheet-action-btn:hover {
  background: var(--color-surface-offset);
  color: var(--color-text);
  border-color: var(--color-border);
}
.sheet-action-delete:hover { color: var(--color-error); background: var(--color-error-highlight); }
.sheet-action-delist:hover { color: var(--color-primary); }
.sheet-action-sold:hover { color: var(--color-success); }

/* ============================================================
   SEARCH MODAL
   ============================================================ */
.search-overlay {
  position: fixed;
  inset: 0;
  background: oklch(0 0 0 / 0.4);
  z-index: 300;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 15vh;
  opacity: 0;
  transition: opacity 0.25s ease;
}
.search-overlay.visible { opacity: 1; }
.search-modal {
  background: var(--color-surface);
  border-radius: var(--radius-2xl);
  width: 100%;
  max-width: 560px;
  box-shadow: var(--shadow-xl);
  overflow: hidden;
  margin: 0 var(--space-4);
}
.search-input-wrap {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-4) var(--space-5);
  border-bottom: 1px solid var(--color-divider);
}
.search-input-wrap svg { flex-shrink: 0; color: var(--color-text-faint); }
.search-input {
  flex: 1;
  border: none;
  background: none;
  outline: none;
  font-size: var(--text-base);
  color: var(--color-text);
}
.search-input::placeholder { color: var(--color-text-faint); }
.search-kbd {
  padding: 2px 6px;
  background: var(--color-surface-2);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  font-size: 11px;
  color: var(--color-text-faint);
  font-family: inherit;
}
.search-results {
  max-height: 50vh;
  overflow-y: auto;
}
.search-result {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-5);
  cursor: pointer;
  transition: background var(--transition-interactive);
}
.search-result:hover,
.search-result-active { background: var(--color-surface-2); }
.search-result-active { outline: 2px solid var(--color-primary); outline-offset: -2px; border-radius: var(--radius-sm); }
.search-result-thumb {
  width: 40px;
  height: 56px;
  object-fit: contain;
  background: var(--color-surface-2);
  border-radius: var(--radius-sm);
  flex-shrink: 0;
}
.search-result-info { flex: 1; min-width: 0; }
.search-result-name {
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-text);
  display: flex;
  align-items: center;
  gap: var(--space-2);
}
.search-result-meta { font-size: var(--text-xs); color: var(--color-text-muted); }
.search-result-value {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-primary);
  white-space: nowrap;
}
.search-sale-tag {
  padding: 1px 6px;
  background: var(--color-primary);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  border-radius: var(--radius-full);
}
.search-empty {
  padding: var(--space-8);
  text-align: center;
  color: var(--color-text-faint);
  font-size: var(--text-sm);
}

/* ============================================================
   ADD/EDIT CARD MODALS
   ============================================================ */
.addcard-overlay {
  position: fixed;
  inset: 0;
  z-index: 250;
  background: oklch(0 0 0 / 0.4);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: var(--space-4);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  opacity: 0;
  transition: opacity 0.3s ease;
}
.addcard-overlay.visible { opacity: 1; }
.addcard-modal {
  background: var(--color-surface);
  border-radius: var(--radius-2xl);
  width: 100%;
  max-width: 1160px;
  margin: max(var(--space-2), 1.5vh) 0;
  overflow: visible;
  box-shadow: var(--shadow-xl);
}
.addcard-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-5) var(--space-6) 0;
}
.addcard-header h2 {
  font-size: var(--text-lg);
  font-weight: 700;
  letter-spacing: -0.02em;
}
.addcard-body {
  padding: var(--space-4) var(--space-6) var(--space-6);
}
.addcard-form {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}
.form-group {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  position: relative;
}
.form-group label {
  font-size: var(--text-xs);
  font-weight: 500;
  color: var(--color-text-muted);
}
.form-group input,
.form-group select {
  padding: var(--space-2) var(--space-3);
  background: var(--color-surface-2);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  font-size: var(--text-sm);
  color: var(--color-text);
  transition: border-color var(--transition-interactive);
}
.form-group input:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--color-primary);
}
.form-group input::placeholder { color: var(--color-text-faint); }
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-3);
}
.form-row-checks {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.form-group-check {
  display: flex;
  align-items: stretch;
}
.checkbox-label {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-sm);
  cursor: pointer;
  padding: 10px 12px;
  width: 100%;
  border-radius: var(--radius-md);
  border: 1px solid var(--color-border);
  background: var(--color-surface-2);
  min-height: 40px;
  transition: border-color var(--transition-interactive), background var(--transition-interactive);
}
.checkbox-label:hover {
  border-color: var(--color-primary);
}
.checkbox-label input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: var(--color-primary);
}
.checkbox-label input[type="checkbox"]:checked + span {
  color: var(--color-text);
  font-weight: 600;
}

@media (max-width: 760px) {
  .addcard-modal {
    max-width: 560px;
  }
  .form-row-checks {
    grid-template-columns: 1fr;
  }
}
.league-pills {
  display: flex;
  gap: var(--space-2);
  flex-wrap: nowrap;
  overflow-x: auto;
  padding-bottom: 2px;
}
.league-pills::-webkit-scrollbar { height: 6px; }
.league-pills::-webkit-scrollbar-thumb {
  background: var(--color-border);
  border-radius: var(--radius-full);
}
.league-pill {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-full);
  background: var(--color-surface-2);
  border: 1px solid var(--color-border);
  font-size: var(--text-xs);
  font-weight: 500;
  color: var(--color-text-muted);
  cursor: pointer;
  transition: all var(--transition-interactive);
}
.league-pill:hover { border-color: var(--color-primary); color: var(--color-text); }
.league-pill.active {
  background: var(--color-primary);
  border-color: var(--color-primary);
  color: #fff;
}
.league-pill-icon { font-size: 14px; }
@media (max-width: 760px) {
  .league-pills {
    flex-wrap: wrap;
    overflow-x: visible;
  }
}
.btn-add-card {
  padding: var(--space-3) var(--space-4);
  background: var(--color-primary);
  color: #fff;
  border-radius: var(--radius-lg);
  font-size: var(--text-sm);
  font-weight: 600;
  cursor: pointer;
  transition: background var(--transition-interactive);
  margin-top: var(--space-2);
}
.btn-add-card:hover { background: var(--color-primary-hover); }

/* Dropzone */
.dropzone {
  border: 2px dashed var(--color-border);
  border-radius: var(--radius-xl);
  padding: var(--space-5);
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-interactive);
  position: relative;
  margin-bottom: var(--space-3);
  background: var(--color-surface-2);
}
.dropzone:hover, .dropzone.dragover {
  border-color: var(--color-primary);
  background: var(--color-primary-highlight);
}
.dropzone.has-image { padding: 0; border-style: solid; }
.dropzone-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  color: var(--color-text-faint);
}
.dropzone-content p { font-size: var(--text-sm); font-weight: 500; }
.dropzone-hint { font-size: var(--text-xs); color: var(--color-text-faint); }
.dropzone-preview {
  width: 100%;
  max-height: 220px;
  object-fit: contain;
  border-radius: var(--radius-xl);
}
.dropzone-remove {
  position: absolute;
  top: var(--space-2);
  right: var(--space-2);
  width: 28px;
  height: 28px;
  border-radius: var(--radius-full);
  background: oklch(0 0 0 / 0.6);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.duplicate-warning {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-3);
  background: #fff8e1;
  border: 1px solid #ffe082;
  border-radius: var(--radius-md);
  font-size: var(--text-xs);
  color: #f57f17;
  margin-bottom: var(--space-2);
}
[data-theme="dark"] .duplicate-warning {
  background: #332d1a;
  border-color: #665a26;
  color: #fdd835;
}
.lfs-card-name {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: var(--space-3);
}

/* Autosuggest dropdowns */
.form-group-autosuggest { position: relative; }
.autosuggest-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  z-index: 10;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  max-height: 220px;
  overflow-y: auto;
  margin-top: 4px;
}
.autosuggest-item {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-3);
  cursor: pointer;
  transition: background var(--transition-interactive);
}
.autosuggest-item:hover, .autosuggest-item.active { background: var(--color-surface-2); }
.autosuggest-item-main { flex: 1; min-width: 0; }
.autosuggest-item-name {
  font-size: var(--text-xs);
  font-weight: 500;
  color: var(--color-text);
  display: flex;
  align-items: center;
  gap: var(--space-1);
}
.autosuggest-item-meta { font-size: 11px; color: var(--color-text-faint); }
.autosuggest-empty {
  padding: var(--space-3);
  text-align: center;
  color: var(--color-text-faint);
  font-size: var(--text-xs);
}
.player-badge {
  display: inline-flex;
  padding: 1px 5px;
  font-size: 9px;
  font-weight: 700;
  border-radius: var(--radius-sm);
  text-transform: uppercase;
  letter-spacing: 0.02em;
}
.player-badge-hof { background: #fff3e0; color: #e65100; }
.player-badge-active { background: #e8f5e9; color: #2e7d32; }
[data-theme="dark"] .player-badge-hof { background: #332b1a; color: #ffb74d; }
[data-theme="dark"] .player-badge-active { background: #1a2e1b; color: #66bb6a; }
.tier-badge {
  padding: 2px 6px;
  font-size: 10px;
  font-weight: 600;
  border-radius: var(--radius-sm);
  background: var(--color-surface-2);
  color: var(--color-text-muted);
}
.rarity-dot {
  width: 8px;
  height: 8px;
  border-radius: var(--radius-full);
  flex-shrink: 0;
  background: var(--color-text-faint);
}
.rarity-dot-common { background: #9e9e9e; }
.rarity-dot-uncommon { background: #4caf50; }
.rarity-dot-rare { background: #2196f3; }
.rarity-dot-super-rare { background: #9c27b0; }
.rarity-dot-ultra-rare { background: #f44336; }

/* Bulk Import */
.bulk-upload-zone {
  border: 2px dashed var(--color-border);
  border-radius: var(--radius-xl);
  padding: var(--space-8);
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-interactive);
  background: var(--color-surface-2);
  color: var(--color-text-faint);
}
.bulk-upload-zone:hover { border-color: var(--color-primary); }
.bulk-upload-zone p { font-size: var(--text-sm); font-weight: 500; margin-top: var(--space-2); }
.bulk-preview { margin-top: var(--space-4); }
.bulk-preview-count {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: var(--space-3);
}
.bulk-preview-table {
  max-height: 200px;
  overflow-y: auto;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  font-size: 11px;
}
.bulk-preview-table table { width: 100%; }
.bulk-preview-table th {
  background: var(--color-surface-2);
  padding: var(--space-1) var(--space-2);
  text-align: left;
  font-weight: 600;
  color: var(--color-text-muted);
  position: sticky;
  top: 0;
}
.bulk-preview-table td {
  padding: var(--space-1) var(--space-2);
  border-top: 1px solid var(--color-divider);
  color: var(--color-text);
}
.bulk-progress { margin-top: var(--space-4); }
.bulk-progress-bar {
  height: 6px;
  background: var(--color-surface-2);
  border-radius: var(--radius-full);
  overflow: hidden;
}
.bulk-progress-fill {
  height: 100%;
  background: var(--color-primary);
  border-radius: var(--radius-full);
  width: 0%;
  transition: width 0.3s ease;
}
.bulk-progress-text {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  margin-top: var(--space-2);
  text-align: center;
}

/* ============================================================
   NOTIFICATION PANEL
   ============================================================ */
.notif-overlay {
  position: fixed;
  inset: 0;
  z-index: 250;
  background: oklch(0 0 0 / 0.3);
  opacity: 0;
  transition: opacity 0.25s ease;
}
.notif-overlay.visible { opacity: 1; }
.notif-panel {
  position: fixed;
  top: 56px;
  right: var(--space-4);
  width: 360px;
  max-height: 70vh;
  background: var(--color-surface);
  border-radius: var(--radius-2xl);
  box-shadow: var(--shadow-xl);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  z-index: 251;
}
.notif-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-4) var(--space-5);
  border-bottom: 1px solid var(--color-divider);
}
.notif-panel-header h3 {
  font-size: var(--text-sm);
  font-weight: 600;
}
.notif-panel-actions {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}
.notif-mark-all {
  font-size: 11px;
  color: var(--color-primary);
  font-weight: 500;
  cursor: pointer;
}
.notif-mark-all:hover { text-decoration: underline; }
.notif-list {
  flex: 1;
  overflow-y: auto;
  padding: var(--space-2) 0;
}
.notif-item {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-5);
  transition: background var(--transition-interactive);
  cursor: pointer;
}
.notif-item:hover { background: var(--color-surface-2); }
.notif-item.unread { background: var(--color-primary-highlight); }
.notif-item-dot {
  width: 8px;
  height: 8px;
  border-radius: var(--radius-full);
  background: var(--color-primary);
  flex-shrink: 0;
  margin-top: 6px;
}
.notif-item.read .notif-item-dot { background: transparent; }
.notif-item-msg {
  font-size: var(--text-xs);
  color: var(--color-text);
  flex: 1;
}
.notif-item-time {
  font-size: 11px;
  color: var(--color-text-faint);
  white-space: nowrap;
}
.notif-empty {
  padding: var(--space-8);
  text-align: center;
  color: var(--color-text-faint);
  font-size: var(--text-sm);
}
/* Notification empty state */
.notif-empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: var(--space-10) var(--space-6);
  gap: var(--space-3);
}
.notif-empty-icon {
  color: var(--color-text-faint);
  opacity: 0.45;
  margin-bottom: var(--space-1);
}
.notif-empty-title {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text-muted);
  margin: 0;
}
.notif-empty-sub {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
  text-align: center;
  max-width: 220px;
  line-height: 1.5;
  margin: 0;
}

/* ============================================================
   TOAST NOTIFICATIONS
   ============================================================ */
.toast-container {
  position: fixed;
  bottom: var(--space-6);
  right: var(--space-6);
  z-index: 400;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  pointer-events: none;
}
.toast {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-4);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  font-size: var(--text-xs);
  color: var(--color-text);
  pointer-events: auto;
  transform: translateX(120%);
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}
.toast-visible { transform: translateX(0); }
.toast-icon { display: flex; flex-shrink: 0; }
.toast-success .toast-icon { color: var(--color-success); }
.toast-error .toast-icon { color: var(--color-error); }
.toast-sale .toast-icon { color: var(--color-primary); }
.toast-info .toast-icon { color: var(--color-text-muted); }

/* ============================================================
   USER MENU
   ============================================================ */
.user-menu-wrap { position: relative; }
.user-avatar-btn {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-full);
  overflow: hidden;
  cursor: pointer;
  background: var(--color-primary-highlight);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--color-border);
  transition: border-color var(--transition-interactive);
}
.user-avatar-btn:hover { border-color: var(--color-primary); }
.user-avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: var(--radius-full);
}
.user-avatar-initials {
  font-size: 12px;
  font-weight: 700;
  color: var(--color-primary);
  text-transform: uppercase;
}
.user-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: 240px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
  z-index: 110;
  opacity: 0;
  transform: translateY(-4px) scale(0.95);
  transition: all 0.2s ease;
  pointer-events: none;
}
.user-dropdown.visible {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}
.user-dropdown-header {
  padding: var(--space-4);
}
.user-dropdown-name {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text);
}
.user-dropdown-email {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}
.user-dropdown-role {
  display: inline-block;
  margin-top: var(--space-1);
  padding: 1px 6px;
  font-size: 10px;
  font-weight: 700;
  border-radius: var(--radius-sm);
  text-transform: uppercase;
  background: var(--color-surface-2);
  color: var(--color-text-muted);
}
.role-admin { background: var(--color-primary-highlight); color: var(--color-primary); }
.user-dropdown-divider {
  height: 1px;
  background: var(--color-divider);
}
.user-dropdown-item {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  width: 100%;
  padding: var(--space-3) var(--space-4);
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  cursor: pointer;
  transition: all var(--transition-interactive);
}
.user-dropdown-item:hover { background: var(--color-surface-2); color: var(--color-text); }
.user-dropdown-logout:hover { color: var(--color-error); }

/* ============================================================
   AUTH SCREENS
   ============================================================ */
.auth-login-screen {
  position: fixed;
  inset: 0;
  z-index: 500;
  background: var(--color-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-4);
  transition: opacity 0.4s ease;
}
.auth-login-screen.auth-fade-out { opacity: 0; pointer-events: none; }
.auth-login-card {
  width: 100%;
  max-width: 380px;
}
.auth-login-logo {
  text-align: center;
  margin-bottom: var(--space-8);
}
.auth-login-logo svg,
.auth-login-logo img {
  display: block;
  margin: 0 auto var(--space-3);
  color: var(--color-primary);
}
.auth-login-title {
  font-size: var(--text-xl);
  font-weight: 700;
  letter-spacing: -0.03em;
}
.auth-login-subtitle {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  margin-top: var(--space-1);
}
.auth-login-form {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}
.auth-form-group {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}
.auth-form-group label {
  font-size: var(--text-xs);
  font-weight: 500;
  color: var(--color-text-muted);
}
.auth-form-group input {
  padding: var(--space-3);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  font-size: var(--text-sm);
}
.auth-form-group input:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px oklch(from var(--color-primary) l c h / 0.15);
}
.auth-login-btn {
  padding: var(--space-3);
  background: var(--color-primary);
  color: #fff;
  border-radius: var(--radius-lg);
  font-size: var(--text-sm);
  font-weight: 600;
  cursor: pointer;
  transition: background var(--transition-interactive);
}
.auth-login-btn:hover { background: var(--color-primary-hover); }
.auth-login-btn:disabled { opacity: 0.6; cursor: not-allowed; }
.auth-google-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  width: 100%;
  padding: var(--space-3);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-text);
  cursor: pointer;
  transition: all var(--transition-interactive);
}
.auth-google-btn:hover { background: var(--color-surface-2); }
.auth-google-btn svg { display: inline; }
.auth-divider {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin: var(--space-4) 0;
}
.auth-divider-line { flex: 1; height: 1px; background: var(--color-divider); }
.auth-divider-text { font-size: var(--text-xs); color: var(--color-text-faint); }
.auth-login-message {
  margin-top: var(--space-3);
  padding: var(--space-3);
  border-radius: var(--radius-md);
  font-size: var(--text-xs);
  text-align: center;
}
.auth-msg-error { background: var(--color-error-highlight); color: var(--color-error); }
.auth-msg-success { background: var(--color-success-highlight); color: var(--color-success); }
.auth-msg-info { background: var(--color-surface-2); color: var(--color-text-muted); }
.auth-pending-screen {
  position: fixed;
  inset: 0;
  z-index: 500;
  background: var(--color-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-4);
}
.auth-pending-card { text-align: center; max-width: 400px; }
.auth-pending-icon { margin-bottom: var(--space-4); color: var(--color-primary); }
.auth-denied-icon { color: var(--color-error); }
.auth-pending-title { font-size: var(--text-xl); font-weight: 700; margin-bottom: var(--space-2); }
.auth-pending-msg { font-size: var(--text-sm); color: var(--color-text-muted); }
.auth-pending-user { font-size: var(--text-xs); color: var(--color-text-faint); margin-top: var(--space-2); }
.auth-pending-hint { font-size: var(--text-xs); color: var(--color-text-faint); margin-top: var(--space-1); }
.auth-pending-logout {
  margin-top: var(--space-6);
  padding: var(--space-2) var(--space-4);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  cursor: pointer;
  transition: all var(--transition-interactive);
}
.auth-pending-logout:hover { color: var(--color-error); border-color: var(--color-error); }

/* Admin Modal */
.auth-admin-overlay {
  position: fixed;
  inset: 0;
  z-index: 300;
  background: oklch(0 0 0 / 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-4);
  opacity: 0;
  transition: opacity 0.3s ease;
}
.auth-admin-overlay.visible { opacity: 1; }
.auth-admin-modal {
  background: var(--color-surface);
  border-radius: var(--radius-2xl);
  width: 100%;
  max-width: 480px;
  max-height: 80vh;
  overflow: hidden;
  box-shadow: var(--shadow-xl);
  display: flex;
  flex-direction: column;
}
.auth-admin-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-5) var(--space-6);
  border-bottom: 1px solid var(--color-divider);
}
.auth-admin-header h2 { font-size: var(--text-lg); font-weight: 700; }
.auth-admin-body {
  flex: 1;
  overflow-y: auto;
  padding: var(--space-2) 0;
}
.auth-admin-loading {
  padding: var(--space-8);
  text-align: center;
  color: var(--color-text-faint);
}
.admin-user-row {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-6);
}
.admin-user-row:hover { background: var(--color-surface-2); }
.admin-user-avatar {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  background: var(--color-primary-highlight);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  color: var(--color-primary);
  flex-shrink: 0;
  overflow: hidden;
}
.admin-user-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.admin-user-info { flex: 1; min-width: 0; }
.admin-user-name { font-size: var(--text-sm); font-weight: 500; color: var(--color-text); }
.admin-user-you { font-size: 10px; color: var(--color-text-faint); font-weight: 400; }
.admin-user-email { font-size: var(--text-xs); color: var(--color-text-muted); }
.admin-user-actions { display: flex; align-items: center; gap: var(--space-2); }
.admin-action-btn {
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-full);
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
}
.admin-btn-approve { background: var(--color-success-highlight); color: var(--color-success); }
.admin-btn-approve:hover { background: var(--color-success); color: #fff; }
.admin-btn-deny { background: var(--color-error-highlight); color: var(--color-error); }
.admin-btn-deny:hover { background: var(--color-error); color: #fff; }
.admin-btn-delete { color: var(--color-text-faint); padding: var(--space-1); }
.admin-btn-delete:hover { color: var(--color-error); }
.admin-role-badge {
  padding: 2px 8px;
  font-size: 10px;
  font-weight: 700;
  border-radius: var(--radius-full);
  text-transform: uppercase;
  background: var(--color-surface-2);
  color: var(--color-text-muted);
}
.admin-role-select {
  padding: var(--space-1) var(--space-2);
  font-size: 11px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: var(--color-surface);
  color: var(--color-text);
}

/* ============================================================
   FOOTER
   ============================================================ */
.app-footer {
  padding: var(--space-8) var(--space-6);
  text-align: center;
  font-size: var(--text-xs);
  color: var(--color-text-faint);
}
.app-footer a {
  color: var(--color-text-faint);
  text-decoration: none;
  transition: color var(--transition-interactive);
}
.app-footer a:hover { color: var(--color-text-muted); }

/* ============================================================
   EBAY STORE SECTION
   ============================================================ */
.ebay-section {
  padding: var(--space-12) 0;
  border-top: 1px solid var(--color-divider);
}
.ebay-page {
  min-height: calc(100vh - 72px);
  border-top: none;
  padding-top: calc(64px + var(--space-6));
}
.ebay-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-6);
}
.ebay-store-link {
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-primary);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: var(--space-2);
  transition: color var(--transition-interactive);
}
.ebay-store-link:hover { color: var(--color-primary-hover); }
.ebay-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 280px;
  gap: var(--space-6);
}
.ebay-page .ebay-grid {
  grid-template-columns: minmax(0, 1fr);
}
.ebay-page .ebay-panel-stats {
  grid-column: auto;
}
.ebay-panel {
  background: var(--color-surface);
  border-radius: var(--radius-xl);
  padding: var(--space-6);
  border: 1px solid var(--color-divider);
}
.ebay-panel-title {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: var(--space-4);
  letter-spacing: -0.01em;
}
.ebay-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  margin-bottom: var(--space-4);
}
.ebay-tabs {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--color-divider);
  border-radius: var(--radius-full);
  overflow: hidden;
}
.ebay-tab-btn {
  border: none;
  background: transparent;
  color: var(--color-text-muted);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 7px 12px;
  cursor: pointer;
}
.ebay-tab-btn.active {
  background: var(--color-primary-highlight);
  color: var(--color-primary);
}
.ebay-search-input {
  width: min(340px, 100%);
  border: 1px solid var(--color-divider);
  background: var(--color-surface-elevated);
  color: var(--color-text);
  border-radius: var(--radius-md);
  font-size: var(--text-sm);
  padding: 9px 12px;
}
.ebay-list-count {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  margin-bottom: var(--space-3);
}
.ebay-listing-item, .ebay-sale-item {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) 0;
  border-bottom: 1px solid var(--color-divider);
}
.ebay-listing-item:last-child, .ebay-sale-item:last-child {
  border-bottom: none;
}
.ebay-item-img {
  width: 80px;
  height: 108px;
  object-fit: cover;
  border-radius: 10px;
  flex-shrink: 0;
  border: 1px solid var(--color-divider);
}
.ebay-item-thumb-link {
  display: inline-flex;
  flex-shrink: 0;
  text-decoration: none;
}
.ebay-item-info {
  flex: 1;
  min-width: 0;
}
.ebay-listing-item,
.ebay-sale-item {
  min-width: 0;
}
.ebay-item-name {
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-text);
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  word-break: break-word;
}
.ebay-item-link {
  color: inherit;
  text-decoration: none;
}
.ebay-item-link:hover {
  color: var(--color-primary);
}
.ebay-item-meta {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  margin-top: 4px;
}
.ebay-item-price {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text);
  white-space: nowrap;
}
.ebay-item-open-link {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--color-primary);
  border: 1px solid var(--color-primary-faint);
  border-radius: var(--radius-full);
  padding: 4px 10px;
  text-decoration: none;
  transition: all var(--transition-interactive);
}
.ebay-item-open-link:hover {
  border-color: var(--color-primary);
  background: var(--color-primary-highlight);
}
.ebay-item-status {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  white-space: nowrap;
}
.ebay-item-status.sold {
  background: var(--color-success-highlight);
  color: var(--color-success);
}
.ebay-item-status.active {
  background: var(--color-primary-highlight);
  color: var(--color-primary);
}
.ebay-stat-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-3) 0;
  border-bottom: 1px solid var(--color-divider);
}
.ebay-stat-row:last-child { border-bottom: none; }
.ebay-stat-label {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}
.ebay-stat-value {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text);
}
.ebay-empty {
  color: var(--color-text-faint);
  font-size: var(--text-sm);
  text-align: center;
  padding: var(--space-8) 0;
}

@media (max-width: 900px) {
  .ebay-toolbar {
    flex-direction: column;
    align-items: stretch;
  }
  .ebay-search-input {
    width: 100%;
  }
  .ebay-item-img {
    width: 64px;
    height: 88px;
  }
  .ebay-item-open-link {
    display: none;
  }
}

/* ============================================================
   CONFIRM MODAL (replaces confirm() blocked in iframe sandbox)
   ============================================================ */
.confirm-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: fadeIn 0.2s ease;
}
.confirm-modal {
  background: var(--color-surface);
  border-radius: var(--radius-2xl);
  padding: var(--space-8);
  max-width: 380px;
  width: calc(100% - var(--space-8));
  box-shadow: var(--shadow-xl);
  text-align: center;
}
.confirm-modal-msg {
  font-size: var(--text-base);
  color: var(--color-text);
  margin-bottom: var(--space-6);
  line-height: 1.5;
}
.confirm-modal-actions {
  display: flex;
  gap: var(--space-3);
}
.confirm-modal-btn {
  flex: 1;
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-lg);
  font-weight: 600;
  font-size: var(--text-sm);
  cursor: pointer;
  transition: all var(--transition-interactive);
  border: none;
}
.confirm-modal-cancel {
  background: var(--color-surface-2);
  color: var(--color-text);
}
.confirm-modal-cancel:hover {
  background: var(--color-surface-offset);
}
.confirm-modal-ok {
  background: var(--color-error);
  color: white;
}
.confirm-modal-ok:hover {
  opacity: 0.9;
}
@keyframes fadeIn {
  from { opacity: 0; } to { opacity: 1; }
}

/* ============================================================
   UTILITY
   ============================================================ */
.hidden { display: none !important; }
.positive { color: var(--color-success); }
.negative { color: var(--color-error); }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 768px) {
  .hero-section { min-height: auto; padding-top: calc(56px + var(--space-4)); padding-bottom: var(--space-6); }
  .hero-featured { flex-direction: column; gap: var(--space-4); text-align: center; }
  .hero-featured-card { width: 200px; height: 280px; }
  .hero-featured-info { align-items: center; }
  .hero-featured-name { font-size: var(--text-xl); }
  .hero-actions { flex-wrap: wrap; gap: var(--space-2); }
  .hero-action-btn span { display: none; }
  .hero-action-btn { padding: var(--space-2) var(--space-3); }
  .insights-grid { grid-template-columns: 1fr; }
  .gallery-header { flex-direction: column; align-items: stretch; }
  .gallery-header-top { flex-direction: column; align-items: stretch; }
  .gallery-open-full-btn { width: 100%; }
  .gallery-controls { flex-wrap: wrap; }
  .notif-panel { right: 0; width: 100%; max-width: 100%; border-radius: 0 0 var(--radius-2xl) var(--radius-2xl); }
  .section-inner { padding: 0 var(--space-4); }
  .bulk-btn-text { display: none; }
  .alerts-create { flex-direction: column; align-items: stretch; }
  .alert-price-input { width: 100%; }
  .ebay-grid { grid-template-columns: 1fr; }
  .ebay-panel-stats { order: -1; }
}

@media (max-width: 480px) {
  .hero-featured-card { width: 170px; height: 240px; }
}

/* ============================================================
   QUICK STATS BAR
   ============================================================ */
.quick-stats-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  padding: var(--space-4) var(--space-6);
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
}
.quick-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-1);
  padding: 0 var(--space-8);
  flex: 1;
  max-width: 200px;
}
.quick-stat-label {
  font-size: var(--text-xs);
  font-weight: 500;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.quick-stat-value {
  font-size: var(--text-xl);
  font-weight: 700;
  color: var(--color-text);
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.quick-stat-divider {
  width: 1px;
  height: 32px;
  background: var(--color-border);
  flex-shrink: 0;
}

/* ============================================================
   RECENTLY ADDED SECTION
   ============================================================ */
.recently-added-section {
  padding: var(--space-10) 0;
  background: var(--color-bg);
}
.recently-added-scroll {
  display: flex;
  gap: var(--space-4);
  overflow-x: auto;
  padding-bottom: var(--space-2);
  scrollbar-width: thin;
  scrollbar-color: var(--color-border) transparent;
  -webkit-overflow-scrolling: touch;
}
.recently-added-scroll::-webkit-scrollbar { height: 4px; }
.recently-added-scroll::-webkit-scrollbar-track { background: transparent; }
.recently-added-scroll::-webkit-scrollbar-thumb { background: var(--color-border); border-radius: 2px; }

.recently-added-card {
  flex-shrink: 0;
  width: 140px;
  cursor: pointer;
  border-radius: var(--radius-lg);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.recently-added-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.15);
}
.recently-added-img {
  width: 100%;
  height: 100px;
  object-fit: cover;
  display: block;
  background: var(--color-surface-offset);
}
.recently-added-img-placeholder {
  width: 100%;
  height: 100px;
  background: var(--color-surface-offset);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text-muted);
}
.recently-added-info {
  padding: var(--space-2) var(--space-3);
}
.recently-added-name {
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--color-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 2px;
}
.recently-added-time {
  font-size: 10px;
  color: var(--color-text-muted);
}
.recently-added-empty {
  color: var(--color-text-muted);
  font-size: var(--text-sm);
  padding: var(--space-4) 0;
}

/* ============================================================
   MY ACCOUNT MODAL
   ============================================================ */
.account-modal {
  max-width: 760px;
}
.account-body {
  overflow: visible;
  display: flex;
  flex-direction: column;
  gap: var(--space-6);
}
.account-section {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
  background: var(--color-surface);
}
.account-section-title {
  font-size: var(--text-sm);
  font-weight: 700;
  color: var(--color-primary);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: var(--space-4);
}
.account-section-desc {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  margin: 0 0 var(--space-3);
}
.account-profile-row {
  display: flex;
  align-items: center;
  gap: var(--space-4);
}
.account-avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--color-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--text-lg);
  font-weight: 700;
  color: white;
  flex-shrink: 0;
  overflow: hidden;
}
.account-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.account-profile-info {
  flex: 1;
}
.account-profile-name {
  font-size: var(--text-base);
  font-weight: 600;
  color: var(--color-text);
}
.account-profile-email {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  margin: 2px 0;
}
.account-profile-since {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}
.account-form-grid {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}
.btn-account-export {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-5);
  background: var(--color-surface-offset);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-base);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text);
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}
.btn-account-export:hover {
  background: var(--color-primary);
  border-color: var(--color-primary);
  color: white;
}
.account-save-row {
  display: flex;
  justify-content: flex-end;
  padding-top: var(--space-2);
}

/* Site Infrastructure Panel (Admin Only) */
.site-info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: var(--space-3);
}
.site-info-card {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 8px;
  padding: var(--space-3);
}
.site-info-card-header {
  font-size: 13px;
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: var(--space-2);
  padding-bottom: var(--space-1);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  letter-spacing: 0.02em;
}
.site-info-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 3px 0;
  font-size: 12px;
  gap: var(--space-2);
}
.site-info-label {
  color: var(--color-text-muted);
  flex-shrink: 0;
}
.site-info-value {
  color: var(--color-text);
  text-align: right;
  word-break: break-all;
}
.site-info-value a {
  color: var(--color-primary);
  text-decoration: none;
}
.site-info-value a:hover {
  text-decoration: underline;
}
.site-info-mono {
  font-family: 'SF Mono', 'Fira Code', monospace;
  font-size: 11px;
}
.site-info-pending {
  color: #f59e0b;
  font-weight: 500;
}

/* ============================================================
   CARD TAGS
   ============================================================ */
.sheet-tags-section {
  padding: var(--space-4) 0;
}
.sheet-tags-list {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-bottom: var(--space-3);
  min-height: 28px;
}
.sheet-tag-pill {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: var(--space-1) var(--space-3);
  background: var(--color-primary);
  color: white;
  border-radius: 999px;
  font-size: var(--text-xs);
  font-weight: 600;
  line-height: 1.4;
}
.sheet-tag-remove {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 14px;
  height: 14px;
  background: rgba(255,255,255,0.25);
  border-radius: 50%;
  border: none;
  cursor: pointer;
  color: white;
  font-size: 10px;
  line-height: 1;
  padding: 0;
  flex-shrink: 0;
  transition: background 0.1s;
}
.sheet-tag-remove:hover { background: rgba(255,255,255,0.45); }
.sheet-tags-add {
  display: flex;
  gap: var(--space-2);
  align-items: center;
}
.sheet-tag-input {
  flex: 1;
  padding: var(--space-1) var(--space-3);
  background: var(--color-surface-offset);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-base);
  font-size: var(--text-sm);
  color: var(--color-text);
  outline: none;
  transition: border-color 0.15s;
}
.sheet-tag-input:focus { border-color: var(--color-primary); }
.sheet-tag-add-btn {
  padding: var(--space-1) var(--space-3);
  background: var(--color-primary);
  color: white;
  border: none;
  border-radius: var(--radius-base);
  font-size: var(--text-sm);
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.15s;
  white-space: nowrap;
}
.sheet-tag-add-btn:hover { opacity: 0.85; }
.sheet-tag-empty {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  font-style: italic;
}

/* Share button in detail sheet */
.sheet-action-share {
  background: var(--color-surface-offset);
}

/* ============================================================
   EBAY INTEGRATION NOTES
   ============================================================ */
.ebay-connect-banner {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  padding: var(--space-4) var(--space-5);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  margin-bottom: var(--space-4);
}
.ebay-connect-text {
  flex: 1;
}
.ebay-connect-title {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: 2px;
}
.ebay-connect-sub {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}
.ebay-connect-btn {
  padding: var(--space-2) var(--space-4);
  background: #e53238;
  color: white;
  border: none;
  border-radius: var(--radius-base);
  font-size: var(--text-sm);
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: opacity 0.15s;
}
.ebay-connect-btn:hover { opacity: 0.85; }
.ebay-demo-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: 2px var(--space-2);
  background: rgba(245, 158, 11, 0.15);
  color: #d97706;
  border-radius: var(--radius-base);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-left: var(--space-2);
}
.ebay-coming-soon {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  margin-top: var(--space-3);
  font-style: italic;
  text-align: center;
}

/* ============================================================
   AI SCAN CARD
   ============================================================ */
.addcard-header-actions {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}
.btn-scan-card {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-full);
  background: oklch(from var(--color-primary) l c h / 0.15);
  color: var(--color-primary);
  font-size: var(--text-xs);
  font-weight: 600;
  border: 1px solid oklch(from var(--color-primary) l c h / 0.25);
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
  letter-spacing: 0.02em;
}
.btn-scan-card:hover {
  background: oklch(from var(--color-primary) l c h / 0.25);
  border-color: var(--color-primary);
}
.btn-scan-card svg {
  flex-shrink: 0;
}

/* Scan Status Banner */
.scan-status {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-lg);
  background: oklch(from var(--color-primary) l c h / 0.1);
  border: 1px solid oklch(from var(--color-primary) l c h / 0.2);
  margin-bottom: var(--space-4);
}
.scan-status-spinner {
  width: 18px;
  height: 18px;
  border: 2px solid oklch(from var(--color-primary) l c h / 0.3);
  border-top-color: var(--color-primary);
  border-radius: 50%;
  animation: scanSpin 0.8s linear infinite;
  flex-shrink: 0;
}
@keyframes scanSpin {
  to { transform: rotate(360deg); }
}
.scan-status-text {
  font-size: var(--text-sm);
  color: var(--color-primary);
  font-weight: 500;
}
.scan-status.scan-success {
  background: oklch(from var(--color-success) l c h / 0.1);
  border-color: oklch(from var(--color-success) l c h / 0.25);
}
.scan-status.scan-success .scan-status-spinner {
  display: none;
}
.scan-status.scan-success .scan-status-text {
  color: var(--color-success);
}
.scan-status.scan-success::before {
  content: '';
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--color-success);
  flex-shrink: 0;
  background-image: url("data:image/svg+xml,%3Csvg width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round' xmlns='http://www.w3.org/2000/svg'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E");
  background-size: 12px;
  background-repeat: no-repeat;
  background-position: center;
}
.scan-status.scan-error {
  background: oklch(from var(--color-error) l c h / 0.1);
  border-color: oklch(from var(--color-error) l c h / 0.25);
}
.scan-status.scan-error .scan-status-spinner { display: none; }
.scan-status.scan-error .scan-status-text { color: var(--color-error); }

/* Responsive additions */
@media (max-width: 768px) {
  .quick-stats-bar { flex-wrap: wrap; gap: var(--space-3) 0; }
  .quick-stat { min-width: 50%; }
  .quick-stat-divider { display: none; }
  .account-form-grid { gap: var(--space-3); }
}

/* ============================================================
   INSIGHTS PAGE — Bloomberg Terminal Aesthetic
   ============================================================ */
.ins-page {
  background: #0a0e17;
  min-height: 100vh;
  padding: 0;
  color: #e5e7eb;
  font-family: 'Inter', system-ui, sans-serif;
}

/* Header Row */
.ins-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 16px;
  background: #0d1117;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  gap: 12px;
}
.ins-header-left { display: flex; align-items: baseline; gap: 8px; }
.ins-title {
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 2px;
  color: #f59e0b;
}
.ins-subtitle {
  font-size: 10px;
  letter-spacing: 1px;
  color: #6b7280;
}
.ins-header-center { text-align: center; flex: 1; }
.ins-clock {
  font-family: 'SF Mono', 'Fira Code', 'Cascadia Code', monospace;
  font-size: 12px;
  color: #9ca3af;
  letter-spacing: 0.5px;
}
.ins-header-right { text-align: right; }
.ins-portfolio-label {
  display: block;
  font-size: 9px;
  letter-spacing: 1px;
  color: #6b7280;
  text-transform: uppercase;
}
.ins-portfolio-value {
  font-family: 'SF Mono', 'Fira Code', 'Cascadia Code', monospace;
  font-size: 20px;
  font-weight: 700;
  color: #10b981;
}

/* Ticker Bar */
.ins-ticker-wrap {
  display: none;
}
.ins-ticker-wrap::before,
.ins-ticker-wrap::after {
  display: none;
}

.ins-ticker {
  display: flex;
  gap: 24px;
  white-space: nowrap;
  animation: ins-scroll 30s linear infinite;
  padding: 0 16px;
}
.ins-ticker:hover { animation-play-state: paused; }

@keyframes ins-scroll {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

.ins-ticker-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-family: 'SF Mono', 'Fira Code', 'Cascadia Code', monospace;
  flex-shrink: 0;
}
.ins-ticker-name { color: #e5e7eb; font-weight: 600; }
.ins-ticker-year { color: #6b7280; }
.ins-ticker-price { color: #e5e7eb; }
.ins-ticker-change { font-size: 11px; }
.ins-ticker-change.positive { color: #10b981; }
.ins-ticker-change.negative { color: #ef4444; }
.ins-ticker-spark { vertical-align: middle; }

/* Main Grid */
.ins-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr);
  gap: 12px;
  padding: 14px 16px 10px;
}

/* Panel Base */
.ins-panel {
  background: #111827;
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 8px;
  padding: 14px;
  min-height: 0;
}
.ins-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}
.ins-panel-title {
  display: block;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.5px;
  color: #6b7280;
  text-transform: uppercase;
  margin-bottom: 8px;
}
.ins-panel-header .ins-panel-title { margin-bottom: 0; }

/* Panel Sizes */
.ins-panel-chart { grid-column: 1; grid-row: 1; }
.ins-panel-stats { grid-column: 2; grid-row: 1; }
.ins-panel-ebay { grid-column: 2; grid-row: 2; }
.ins-panel-table { grid-column: 1 / 3; grid-row: 2; }

/* Chart Wraps */
.ins-chart-wrap { position: relative; height: 220px; }
.ins-chart-small { height: 180px; }
.ins-chart-empty {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 14px;
  color: #6b7280;
  font-size: 11px;
  line-height: 1.4;
  font-family: 'Inter', system-ui, sans-serif;
  background: linear-gradient(180deg, rgba(255,255,255,0.01), rgba(255,255,255,0.02));
  border-radius: 3px;
}

/* Range Buttons */
.ins-range-btns { display: flex; gap: 2px; }
.ins-range-btn {
  background: transparent;
  border: 1px solid rgba(255,255,255,0.1);
  color: #6b7280;
  font-size: 10px;
  font-family: 'SF Mono', 'Fira Code', 'Cascadia Code', monospace;
  padding: 2px 8px;
  border-radius: 2px;
  cursor: pointer;
  transition: all 0.15s;
}
.ins-range-btn:hover { color: #e5e7eb; border-color: rgba(255,255,255,0.2); }
.ins-range-btn.active {
  background: #3b82f6;
  color: #fff;
  border-color: #3b82f6;
}

/* Stats Grid */
.ins-stats-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  margin-bottom: 10px;
}
.ins-stats-note {
  color: #7b8496;
  font-size: 11px;
  line-height: 1.35;
}
.ins-stat {
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.04);
  border-radius: 3px;
  padding: 8px;
}
.ins-stat-label {
  display: block;
  font-size: 9px;
  letter-spacing: 0.8px;
  color: #6b7280;
  text-transform: uppercase;
  margin-bottom: 4px;
}
.ins-stat-value {
  font-family: 'SF Mono', 'Fira Code', 'Cascadia Code', monospace;
  font-size: 16px;
  font-weight: 700;
  color: #e5e7eb;
}
.ins-stat-value.positive { color: #10b981; }
.ins-stat-value.negative { color: #ef4444; }
.ins-stat-sub {
  font-size: 10px;
  color: #6b7280;
  margin-top: 2px;
  font-family: 'SF Mono', 'Fira Code', 'Cascadia Code', monospace;
}
.ins-insight-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.ins-insight-item {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.05);
  border-radius: 3px;
  padding: 7px 8px;
}
.ins-insight-copy {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.ins-insight-title {
  color: #d1d5db;
  font-size: 11px;
  font-weight: 600;
  font-family: 'Inter', system-ui, sans-serif;
}
.ins-insight-sub {
  color: #6b7280;
  font-size: 10px;
  line-height: 1.3;
}
.ins-insight-pill {
  flex-shrink: 0;
  color: #a5b4fc;
  border: 1px solid rgba(99,102,241,0.35);
  background: rgba(99,102,241,0.12);
  border-radius: 999px;
  padding: 2px 8px;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.4px;
}
.ins-ticker-empty {
  display: inline-block;
  color: #6b7280;
  font-size: 11px;
  padding: 8px 12px;
}

/* Card Performance Table */
.ins-table-wrap {
  overflow: auto;
  max-height: min(62vh, 720px);
}
.ins-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}
.ins-table th {
  text-align: left;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 1px;
  color: #6b7280;
  padding: 6px 6px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  cursor: pointer;
  user-select: none;
  white-space: nowrap;
  position: sticky;
  top: 0;
  background: #111827;
  z-index: 1;
}
.ins-table th:hover { color: #e5e7eb; }
.ins-table th .ins-sort-arrow { font-size: 8px; margin-left: 2px; }
.ins-table td {
  padding: 6px 6px;
  border-bottom: 1px solid rgba(255,255,255,0.03);
  font-family: 'SF Mono', 'Fira Code', 'Cascadia Code', monospace;
  white-space: nowrap;
}
.ins-table tbody tr { cursor: pointer; transition: background 0.1s; }
.ins-table tbody tr:hover { background: rgba(255,255,255,0.03); }

.ins-table .ins-card-name {
  color: #e5e7eb;
  font-family: 'Inter', system-ui, sans-serif;
  font-weight: 600;
  font-size: 12px;
}
.ins-table .ins-card-set {
  color: #6b7280;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 10px;
  font-weight: 400;
}
.ins-table .ins-val { color: #10b981; }
.ins-table .ins-change-pos { color: #10b981; }
.ins-table .ins-change-neg { color: #ef4444; }
.ins-table .ins-change-zero { color: #6b7280; }
.ins-table .ins-roi-pos { color: #10b981; }
.ins-table .ins-roi-neg { color: #ef4444; }

.ins-sparkline-cell { line-height: 0; }
.ins-sparkline { display: block; }

/* Market Activity Bar */
.ins-market-bar {
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 8px 16px;
  background: #0d1117;
  border-top: 1px solid rgba(255,255,255,0.06);
  font-family: 'SF Mono', 'Fira Code', 'Cascadia Code', monospace;
  font-size: 11px;
  color: #9ca3af;
  margin-top: 8px;
}
.ins-market-bar .ins-mb-label {
  color: #6b7280;
  font-size: 9px;
  letter-spacing: 1px;
  text-transform: uppercase;
}
.ins-market-bar .ins-mb-val {
  color: #e5e7eb;
  font-weight: 600;
}
.ins-market-bar .ins-mb-sep {
  color: rgba(255,255,255,0.1);
}

/* Active nav button for insights */
.nav-icon-btn.ins-active {
  color: #f59e0b;
  background: rgba(245, 158, 11, 0.1);
}

/* eBay Sold Comps Panel */
.ins-ebay-badge {
  display: inline-block;
  font-size: 8px; font-weight: 700; letter-spacing: 1px;
  padding: 1px 6px; border-radius: 2px;
  background: rgba(16, 185, 129, 0.15); color: #10b981;
  animation: ins-pulse 2s ease-in-out infinite;
}
@keyframes ins-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}
.ins-ebay-comps-list {
  display: flex; flex-direction: column;
  max-height: 340px; overflow-y: auto;
  scrollbar-width: thin; scrollbar-color: rgba(255,255,255,0.1) transparent;
}
.ins-ebay-row {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 0;
  border-bottom: 1px solid rgba(255,255,255,0.04);
}
.ins-ebay-row:last-child { border-bottom: none; }
.ins-ebay-thumb {
  width: 32px; height: 32px; border-radius: 3px;
  object-fit: cover; flex-shrink: 0;
  background: rgba(255,255,255,0.04);
}
.ins-ebay-thumb-empty {
  background: rgba(255,255,255,0.04);
}
.ins-ebay-info {
  flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px;
}
.ins-ebay-title {
  font-size: 11px; color: #e5e7eb;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  text-decoration: none;
}
a.ins-ebay-title:hover { color: #3b82f6; text-decoration: underline; }
.ins-ebay-meta {
  font-size: 9px; color: #6b7280;
  font-family: 'SF Mono', 'Fira Code', monospace;
}
.ins-ebay-price {
  font-size: 12px; font-weight: 600; color: #10b981;
  font-family: 'SF Mono', 'Fira Code', monospace;
  flex-shrink: 0;
}
.ins-ebay-stats {
  display: flex; gap: 12px; padding-top: 8px;
  border-top: 1px solid rgba(255,255,255,0.06);
  margin-top: 8px;
}
.ins-ebay-stat {
  font-size: 11px; color: #e5e7eb;
  font-family: 'SF Mono', 'Fira Code', monospace;
}
.ins-ebay-stat-label {
  font-size: 9px; color: #6b7280;
  letter-spacing: 0.5px; margin-right: 4px;
}
.ins-ebay-empty {
  color: #6b7280; font-size: 11px;
  padding: 16px 0; text-align: center;
}
.ins-ebay-loading {
  color: #6b7280; font-size: 11px;
  padding: 16px 0; text-align: center;
}

/* Responsive */
@media (max-width: 1024px) {
  .ins-grid {
    grid-template-columns: 1fr;
  }
  .ins-panel-chart,
  .ins-panel-stats,
  .ins-panel-table,
  .ins-panel-ebay { grid-column: 1; grid-row: auto; }
  .ins-stats-grid { grid-template-columns: 1fr 1fr; }
  .ins-table-wrap { max-height: none; }
}

@media (max-width: 640px) {
  .ins-grid { grid-template-columns: 1fr; gap: 6px; padding: 6px 8px; }
  .ins-panel-chart,
  .ins-panel-stats,
  .ins-panel-table,
  .ins-panel-ebay { grid-column: 1; grid-row: auto; }
  .ins-stats-grid { grid-template-columns: 1fr; }
  .ins-header { flex-wrap: wrap; gap: 6px; }
  .ins-header-center { order: 3; width: 100%; text-align: left; }
  .ins-portfolio-value { font-size: 16px; }
  .ins-table-wrap { max-height: none; }
  .sheet-trend-insights { grid-template-columns: 1fr; }
}

/* ============================================================
   HELP / DOCS PAGE
   ============================================================ */
.help-page {
  min-height: 100vh;
  padding: 80px 24px 60px;
  background: var(--color-bg);
}

.help-container {
  max-width: 720px;
  margin: 0 auto;
}

/* Hero */
.help-hero {
  text-align: center;
  padding: 40px 0 32px;
}
.help-hero-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--color-text-secondary, #8a8f98);
  margin-bottom: 16px;
}
[data-theme="light"] .help-hero-icon {
  background: rgba(0, 0, 0, 0.03);
  border-color: rgba(0, 0, 0, 0.08);
  color: var(--color-text-secondary, #6b7280);
}
.help-hero-title {
  font-size: 28px;
  font-weight: 600;
  color: var(--color-text, #e5e7eb);
  margin: 0 0 8px;
  letter-spacing: -0.02em;
}
.help-hero-sub {
  font-size: 15px;
  color: var(--color-text-secondary, #8a8f98);
  margin: 0;
  line-height: 1.5;
}

/* Quick Nav Pills */
.help-quick-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  padding: 0 0 40px;
}
.help-nav-pill {
  display: inline-block;
  padding: 6px 14px;
  border-radius: 100px;
  font-size: 13px;
  font-weight: 500;
  color: var(--color-text-secondary, #8a8f98);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  text-decoration: none;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
}
.help-nav-pill:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--color-text, #e5e7eb);
  border-color: rgba(255, 255, 255, 0.15);
}
[data-theme="light"] .help-nav-pill {
  background: rgba(0, 0, 0, 0.03);
  border-color: rgba(0, 0, 0, 0.1);
  color: var(--color-text-secondary, #6b7280);
}
[data-theme="light"] .help-nav-pill:hover {
  background: rgba(0, 0, 0, 0.06);
  color: var(--color-text, #111827);
}

/* Sections */
.help-sections {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.help-section {
  padding: 32px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}
.help-section:first-child {
  border-top: none;
}
[data-theme="light"] .help-section {
  border-top-color: rgba(0, 0, 0, 0.08);
}

.help-section-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
  color: var(--color-text-secondary, #8a8f98);
  margin-bottom: 12px;
}
[data-theme="light"] .help-section-icon {
  background: rgba(0, 0, 0, 0.03);
  border-color: rgba(0, 0, 0, 0.08);
}

.help-section h2 {
  font-size: 20px;
  font-weight: 600;
  color: var(--color-text, #e5e7eb);
  margin: 0 0 8px;
  letter-spacing: -0.01em;
}

.help-section > p {
  font-size: 14px;
  color: var(--color-text-secondary, #8a8f98);
  line-height: 1.6;
  margin: 0 0 20px;
}

/* Feature items */
.help-features {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.help-feature {
  padding: 16px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.05);
}
[data-theme="light"] .help-feature {
  background: rgba(0, 0, 0, 0.015);
  border-color: rgba(0, 0, 0, 0.06);
}

.help-feature strong {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--color-text, #e5e7eb);
  margin-bottom: 4px;
}

.help-feature p {
  font-size: 13px;
  color: var(--color-text-secondary, #8a8f98);
  line-height: 1.6;
  margin: 0;
}

.help-feature em {
  color: var(--color-text, #e5e7eb);
  font-style: normal;
  font-weight: 500;
}

/* Keyboard shortcuts */
.help-shortcuts {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.help-shortcut-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.05);
}
[data-theme="light"] .help-shortcut-row {
  background: rgba(0, 0, 0, 0.015);
  border-color: rgba(0, 0, 0, 0.06);
}

.help-kbd-group {
  display: flex;
  align-items: center;
  gap: 6px;
}

.help-shortcut-row kbd,
.help-feature kbd {
  display: inline-block;
  padding: 3px 8px;
  font-size: 12px;
  font-family: inherit;
  font-weight: 600;
  color: var(--color-text, #e5e7eb);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 5px;
  line-height: 1.3;
}
[data-theme="light"] .help-shortcut-row kbd,
[data-theme="light"] .help-feature kbd {
  background: rgba(0, 0, 0, 0.06);
  border-color: rgba(0, 0, 0, 0.12);
  color: var(--color-text, #111827);
}

.help-shortcut-row > span {
  font-size: 13px;
  color: var(--color-text-secondary, #8a8f98);
}

/* Back button */
.help-back-row {
  text-align: center;
  padding: 40px 0 20px;
}

.help-back-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 20px;
  border-radius: 100px;
  font-size: 14px;
  font-weight: 500;
  color: var(--color-text-secondary, #8a8f98);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.help-back-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--color-text, #e5e7eb);
}
[data-theme="light"] .help-back-btn {
  background: rgba(0, 0, 0, 0.03);
  border-color: rgba(0, 0, 0, 0.1);
}
[data-theme="light"] .help-back-btn:hover {
  background: rgba(0, 0, 0, 0.06);
  color: var(--color-text, #111827);
}

/* Help nav active state */
#helpNavBtn.help-active {
  color: var(--color-text, #e5e7eb);
  background: rgba(255, 255, 255, 0.1);
}
[data-theme="light"] #helpNavBtn.help-active {
  color: var(--color-text, #111827);
  background: rgba(0, 0, 0, 0.08);
}

/* Responsive */
@media (max-width: 600px) {
  .help-page { padding: 72px 16px 40px; }
  .help-hero { padding: 24px 0 20px; }
  .help-hero-title { font-size: 22px; }
  .help-container { max-width: 100%; }
  .help-section { padding: 24px 0; }
  .help-section h2 { font-size: 18px; }
  .help-quick-nav { gap: 6px; padding-bottom: 28px; }
  .help-nav-pill { font-size: 12px; padding: 5px 12px; }
}

/* ============================================================
   COMPS → VALUE BRIDGE
   ============================================================ */

/* Per-card "Update Value from Market" button (in detail sheet) */
.comps-market-btn-row {
  display: flex;
  justify-content: flex-end;
  padding: 8px 0 4px;
}

.btn-update-from-comps {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 12px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 500;
  font-family: 'SF Mono', 'Fira Code', 'Cascadia Code', monospace;
  letter-spacing: 0.3px;
  color: #9ca3af;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.btn-update-from-comps:hover {
  background: rgba(16, 185, 129, 0.12);
  color: #10b981;
  border-color: rgba(16, 185, 129, 0.3);
}
.btn-update-from-comps:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}
[data-theme="light"] .btn-update-from-comps {
  color: #6b7280;
  background: rgba(0, 0, 0, 0.03);
  border-color: rgba(0, 0, 0, 0.1);
}
[data-theme="light"] .btn-update-from-comps:hover {
  background: rgba(16, 185, 129, 0.08);
  color: #059669;
  border-color: rgba(16, 185, 129, 0.25);
}

/* Auto-suggest banner when median differs from current value by >10% */
.comps-suggest-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 8px;
  padding: 8px 12px;
  border-radius: 6px;
  background: rgba(59, 130, 246, 0.07);
  border: 1px solid rgba(59, 130, 246, 0.2);
}
.comps-suggest-msg {
  font-size: 11px;
  color: #9ca3af;
  line-height: 1.4;
}
.comps-suggest-msg strong {
  color: #e5e7eb;
  font-weight: 600;
}
[data-theme="light"] .comps-suggest-banner {
  background: rgba(59, 130, 246, 0.05);
  border-color: rgba(59, 130, 246, 0.18);
}
[data-theme="light"] .comps-suggest-msg { color: #6b7280; }
[data-theme="light"] .comps-suggest-msg strong { color: #111827; }

/* "Sync All Values" button in Insights header */
.btn-sync-all-values {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 11px;
  margin-bottom: 6px;
  border-radius: 3px;
  font-size: 10px;
  font-weight: 600;
  font-family: 'SF Mono', 'Fira Code', 'Cascadia Code', monospace;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: #6b7280;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.1);
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.btn-sync-all-values:hover {
  background: rgba(16, 185, 129, 0.1);
  color: #10b981;
  border-color: rgba(16, 185, 129, 0.3);
}
.btn-sync-all-values:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  pointer-events: none;
}
[data-theme="light"] .btn-sync-all-values {
  color: #6b7280;
  border-color: rgba(0, 0, 0, 0.12);
}
[data-theme="light"] .btn-sync-all-values:hover {
  background: rgba(16, 185, 129, 0.07);
  color: #059669;
  border-color: rgba(16, 185, 129, 0.2);
}

/* ============================================================
   FLIP CARD ANIMATION (Detail Sheet)
   ============================================================ */
.sheet-card-hero {
  flex-direction: column;
  align-items: center;
  gap: var(--space-3);
}

.flip-card {
  width: 200px;
  height: 280px;
  perspective: 1000px;
  cursor: pointer;
  flex-shrink: 0;
}

.flip-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  transition: transform 0.6s cubic-bezier(0.4, 0.2, 0.2, 1);
  transform-style: preserve-3d;
}

.flip-card-inner.flipped {
  transform: rotateY(180deg);
}

.flip-card-front,
.flip-card-back {
  position: absolute;
  inset: 0;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-card);
  background: var(--color-surface-2);
}

.flip-card-back {
  transform: rotateY(180deg);
}

.flip-card-front .sheet-card-img,
.flip-card-back .sheet-card-img {
  max-height: 280px;
  max-width: 200px;
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 0;
  box-shadow: none;
}

.flip-card-front .sheet-card-img:hover,
.flip-card-back .sheet-card-img:hover {
  transform: none;
}

/* Flip button */
.flip-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: 5px 14px;
  border-radius: var(--radius-full);
  border: 1px solid var(--color-border);
  background: var(--color-surface-2);
  color: var(--color-text-muted);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
  letter-spacing: 0.02em;
}

.flip-btn:hover {
  background: var(--color-surface-offset);
  color: var(--color-text);
  border-color: var(--color-primary);
}

.flip-btn svg {
  flex-shrink: 0;
  opacity: 0.7;
}

/* ============================================================
   BACK IMAGE DROPZONE (Add/Edit Forms)
   ============================================================ */
.dropzone-back {
  position: relative;
  border: 1.5px dashed var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-3) var(--space-4);
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
  background: var(--color-surface-2);
  margin-top: var(--space-3);
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 56px;
  overflow: hidden;
}

.dropzone-back:hover,
.dropzone-back.dragover {
  border-color: var(--color-primary);
  background: oklch(from var(--color-primary) l c h / 0.06);
}

.dropzone-back.has-image {
  padding: 0;
  border-style: solid;
  min-height: 120px;
}

.dropzone-back-content {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  color: var(--color-text-faint);
  font-size: var(--text-sm);
  pointer-events: none;
  user-select: none;
}

.dropzone-back-content svg {
  flex-shrink: 0;
  opacity: 0.5;
}

.dropzone-back-optional {
  color: var(--color-text-faint);
  font-size: var(--text-xs);
  opacity: 0.7;
}

.dropzone-back-preview {
  width: 100%;
  max-height: 120px;
  object-fit: contain;
  display: block;
  border-radius: var(--radius-lg);
}


/* ============================================================
   HERO OVERRIDES (2026 cleanup)
   ============================================================ */
.auth-login-screen {
  display: none;
}

.hero-section {
  min-height: 44vh;
  align-items: stretch;
  padding-top: calc(56px + var(--space-6));
  padding-bottom: var(--space-6);
}

.hero-content {
  max-width: 1080px;
  gap: var(--space-4);
  text-align: left;
  align-items: stretch;
}

.hero-topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-3);
  flex-wrap: wrap;
}

.hero-brand-lockup {
  animation: none;
  align-items: flex-start;
  gap: var(--space-2);
}

.hero-brand-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  gap: var(--space-4);
}

.hero-panel {
  background: oklch(from var(--color-surface) l c h / 0.72);
  border: 1px solid oklch(from var(--color-border) l c h / 0.55);
  border-radius: var(--radius-2xl);
  padding: var(--space-4);
  backdrop-filter: blur(14px) saturate(1.25);
}

.hero-metrics-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-3);
}

.hero-metric-chip {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: var(--space-3);
  border-radius: var(--radius-xl);
  border: 1px solid oklch(from var(--color-border) l c h / 0.45);
  background: oklch(from var(--color-bg) l c h / 0.55);
}

.hero-metric-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-faint);
}

.hero-metric-value {
  font-size: var(--text-lg);
  font-weight: 700;
  letter-spacing: -0.01em;
}

.hero-mini-rail {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-3);
}

.hero-mini-card {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  border-radius: var(--radius-xl);
  border: 1px solid oklch(from var(--color-border) l c h / 0.45);
  background: oklch(from var(--color-bg) l c h / 0.5);
  padding: var(--space-2);
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.hero-mini-card:hover {
  border-color: var(--color-primary);
}

.hero-mini-card img {
  width: 40px;
  height: 56px;
  object-fit: cover;
  border-radius: 8px;
  flex-shrink: 0;
}

.hero-mini-meta {
  min-width: 0;
}

.hero-mini-meta strong,
.hero-mini-meta span {
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hero-mini-meta strong {
  font-size: 12px;
}

.hero-mini-meta span {
  font-size: 11px;
  color: var(--color-text-faint);
}

.hero-mini-empty {
  grid-column: 1 / -1;
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}

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

@media (max-width: 640px) {
  .hero-mini-rail,
  .hero-metrics-row {
    grid-template-columns: 1fr;
  }
}

.account-admin-details {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-surface-2);
  margin-bottom: var(--space-3);
}
.account-admin-details summary {
  cursor: pointer;
  padding: var(--space-3) var(--space-4);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text);
  list-style: none;
}
.account-admin-details summary::-webkit-details-marker {
  display: none;
}
.account-admin-details summary::after {
  content: 'Show';
  float: right;
  color: var(--color-text-muted);
  font-weight: 500;
}
.account-admin-details[open] summary::after {
  content: 'Hide';
}
.account-admin-details > *:not(summary) {
  padding: 0 var(--space-3) var(--space-3);
}



/* ============================================================
   HERO REDESIGN V2
   ============================================================ */
.hero-section {
  min-height: 52vh;
  padding-top: calc(56px + var(--space-7));
  padding-bottom: var(--space-8);
}
.hero-content {
  max-width: 1160px;
  gap: var(--space-5);
}
.hero-stage {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: var(--space-4);
  align-items: stretch;
}
.hero-copy {
  background: linear-gradient(140deg, oklch(0.97 0.03 70 / 0.85), oklch(0.93 0.08 45 / 0.85));
  border: 1px solid oklch(0.88 0.06 60 / 0.8);
  border-radius: 26px;
  padding: clamp(18px, 2vw, 28px);
  box-shadow: 0 14px 44px oklch(0.45 0.08 38 / 0.14);
}
.hero-headline {
  margin: 10px 0 10px;
  font-size: clamp(26px, 4.1vw, 48px);
  line-height: 1.02;
  letter-spacing: -0.03em;
  font-weight: 800;
  color: oklch(0.21 0.04 28);
  max-width: 18ch;
}
.hero-subhead {
  margin: 0 0 var(--space-4);
  font-size: clamp(14px, 1.5vw, 17px);
  color: oklch(0.35 0.04 30);
  max-width: 60ch;
}
.hero-color-wall {
  border-radius: 26px;
  padding: var(--space-3);
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-3);
  background: linear-gradient(165deg, #111827 0%, #1f2937 38%, #0f172a 100%);
  box-shadow: 0 20px 50px oklch(0.22 0.02 265 / 0.35);
}
.hero-splash {
  min-height: 94px;
  border-radius: 18px;
  display: flex;
  align-items: flex-end;
  justify-content: flex-start;
  padding: 12px;
  color: #fff;
  font-weight: 800;
  letter-spacing: 0.06em;
  font-size: 11px;
  border: 1px solid rgba(255,255,255,0.22);
}
.hero-splash-a { background: linear-gradient(140deg, #f97316, #ef4444); }
.hero-splash-b { background: linear-gradient(140deg, #14b8a6, #22c55e); }
.hero-splash-c { background: linear-gradient(140deg, #0ea5e9, #6366f1); }
.hero-splash-d { background: linear-gradient(140deg, #eab308, #f97316); }
.hero-grid {
  grid-template-columns: 1fr 1fr;
}
.hero-panel {
  background: oklch(from var(--color-surface) l c h / 0.68);
  border-radius: 22px;
}
.hero-panel-title {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--color-text-muted);
  margin-bottom: var(--space-2);
}
@media (max-width: 1024px) {
  .hero-stage {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 640px) {
  .hero-headline {
    max-width: none;
    font-size: clamp(24px, 8vw, 34px);
  }
  .hero-color-wall {
    grid-template-columns: 1fr 1fr;
  }
}


/* ============================================================
   HERO REDESIGN V3 (cleanup after feedback)
   ============================================================ */
.hero-stage-modern {
  display: grid;
  grid-template-columns: 1.25fr 0.75fr;
  gap: var(--space-4);
  align-items: stretch;
}
.hero-copy-modern {
  background: linear-gradient(145deg, oklch(0.19 0.015 270 / 0.88), oklch(0.14 0.02 250 / 0.88));
  border: 1px solid oklch(0.34 0.03 265 / 0.5);
  border-radius: 24px;
  padding: clamp(18px, 2vw, 28px);
  box-shadow: 0 18px 48px oklch(0.1 0.02 260 / 0.42);
}
.hero-copy-modern .hero-tagline {
  color: oklch(0.78 0.02 250);
}
.hero-copy-modern .hero-headline {
  margin: 10px 0 10px;
  font-size: clamp(30px, 4.3vw, 50px);
  line-height: 1.02;
  letter-spacing: -0.03em;
  font-weight: 800;
  max-width: 17ch;
  color: oklch(0.95 0.01 250);
}
.hero-copy-modern .hero-subhead {
  color: oklch(0.79 0.02 250);
  font-size: clamp(14px, 1.4vw, 17px);
  max-width: 62ch;
}
.hero-art {
  border-radius: 24px;
  position: relative;
  overflow: hidden;
  border: 1px solid oklch(0.34 0.04 255 / 0.55);
  background: radial-gradient(circle at 20% 25%, oklch(0.62 0.18 210 / 0.9), transparent 46%),
              radial-gradient(circle at 80% 28%, oklch(0.72 0.19 40 / 0.75), transparent 44%),
              radial-gradient(circle at 55% 80%, oklch(0.58 0.22 320 / 0.65), transparent 52%),
              linear-gradient(150deg, #091126 0%, #11192f 100%);
  min-height: 230px;
}
.hero-orb {
  position: absolute;
  border-radius: 999px;
  filter: blur(22px);
  opacity: 0.9;
}
.hero-orb-a { width: 170px; height: 170px; left: 8%; top: 12%; background: oklch(0.75 0.2 30 / 0.85); }
.hero-orb-b { width: 140px; height: 140px; right: 10%; top: 18%; background: oklch(0.7 0.17 220 / 0.88); }
.hero-orb-c { width: 180px; height: 180px; left: 34%; bottom: 8%; background: oklch(0.64 0.2 320 / 0.72); }
.nav-icon-btn-active {
  border-color: var(--color-primary);
  background: var(--color-primary-highlight);
  color: var(--color-primary);
}
@media (max-width: 1024px) {
  .hero-stage-modern {
    grid-template-columns: 1fr;
  }
  .hero-art {
    min-height: 160px;
  }
}


/* ============================================================
   HERO SIMPLE SAFE MODE
   ============================================================ */
.hero-section {
  padding-top: calc(64px + var(--space-8));
  padding-bottom: var(--space-7);
}
.hero-content-simple {
  max-width: 1160px;
  align-items: stretch;
  text-align: left;
}
.hero-simple-card {
  background: oklch(from var(--color-surface) l c h / 0.74);
  border: 1px solid oklch(from var(--color-border) l c h / 0.5);
  border-radius: 22px;
  padding: clamp(18px, 2vw, 26px);
  backdrop-filter: blur(14px) saturate(1.2);
}
.hero-simple-title {
  margin: 10px 0 10px;
  font-size: clamp(30px, 4.1vw, 46px);
  line-height: 1.04;
  letter-spacing: -0.03em;
  font-weight: 800;
}
.hero-simple-sub {
  margin: 0 0 var(--space-4);
  color: var(--color-text-muted);
  font-size: clamp(14px, 1.4vw, 17px);
}
.hero-content-simple .hero-grid {
  grid-template-columns: 1fr 1fr;
}
@media (max-width: 960px) {
  .hero-content-simple .hero-grid {
    grid-template-columns: 1fr;
  }
}
