/**
 * ════════════════════════════════════════════════════════════════════════════
 * LISTING HUB MEGA-APP — Dynamic Agent Portal Stylesheet (Phase 3)
 * Default: LIGHT MODE (Crisp & Premium) with smooth DARK MODE Toggle
 * public/portal/style.css
 * ════════════════════════════════════════════════════════════════════════════
 */

:root {
  --font: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  /* 💎 CRAFT EASING TOKENS (Emil Kowalski & Apple WWDC) */
  --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-out-quint: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-in-out-smooth: cubic-bezier(0.77, 0, 0.175, 1);
  --ease-drawer-apple: cubic-bezier(0.32, 0.72, 0, 1);
  --ease-button-press: cubic-bezier(0.2, 0, 0, 1);
  --ease-theme: cubic-bezier(0.4, 0, 0.2, 1);

  /* ☀️ LIGHT MODE THEME (DEFAULT) */
  --bg: #F8FAFC;
  --surface: #FFFFFF;
  --surface-card: #FFFFFF;
  --surface-border: #E2E8F0;
  --surface-hover: #F1F5F9;
  --surface-soft: #F8FAFC;
  --surface-inset: #F1F5F9;
  --header-bg: rgba(255, 255, 255, 0.94);

  --primary: #059669;
  --primary-hover: #047857;
  --primary-light: rgba(5, 150, 105, 0.08);
  --primary-tint: rgba(5, 150, 105, 0.15);

  --card-price: #059669;

  --btn-primary-bg: #121212;
  --btn-primary-hover: #2A2A2A;
  --btn-primary-text: #FFFFFF;
  --btn-primary-shadow: 0 4px 14px rgba(18, 18, 18, 0.22);
  --btn-primary-shadow-hover: 0 6px 20px rgba(18, 18, 18, 0.32);

  --text-main: #181C1F;
  --text-body: #3D4349;
  --text-muted: #64748B;
  --text-dim: #94A3B8;

  --success: #059669;
  --success-bg: #ECFDF5;
  --success-border: #A7F3D0;
  --warning: #D97706;
  --warning-bg: #FFFBEB;
  --warning-border: #FDE68A;
  --danger: #DC2626;
  --danger-bg: #FEF2F2;
  --danger-border: #FECACA;

  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-full: 9999px;

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow: 0 1px 3px rgba(0, 0, 0, 0.05), 0 8px 24px -4px rgba(0, 0, 0, 0.06);
  --shadow-hover: 0 0 0 1px rgba(18, 18, 18, 0.2), 0 12px 30px -4px rgba(0, 0, 0, 0.1);
  --shadow-modal: 0 20px 45px -10px rgba(15, 23, 42, 0.18), 0 0 0 1px rgba(0, 0, 0, 0.06);
}

/* 🌙 DARK MODE THEME — Modern Obsidian & Indigo-Sky Palette (Eye-Friendly & High Contrast) */
[data-theme="dark"] {
  --bg: #0B0E14;
  --surface: #151922;
  --surface-card: #151922;
  --surface-border: #222838;
  --surface-hover: #1B202D;
  --surface-soft: #10131B;
  --surface-inset: #0F121A;
  --header-bg: rgba(15, 18, 26, 0.94);

  --primary: #38BDF8;
  --primary-hover: #0EA5E9;
  --primary-light: rgba(56, 189, 248, 0.14);
  --primary-tint: rgba(56, 189, 248, 0.22);
  --accent-purple: #8B5CF6;
  --accent-pink: #EC4899;

  --card-price: #38BDF8;

  /* Button strictly #532ded with pure white text */
  --btn-primary-bg: #532ded;
  --btn-primary-hover: #4321d4;
  --btn-primary-text: #FFFFFF;
  --btn-primary-shadow: 0 4px 16px rgba(83, 45, 237, 0.35);
  --btn-primary-shadow-hover: 0 6px 22px rgba(83, 45, 237, 0.5);

  --text-main: #FFFFFF;
  --text-body: #94A3B8;
  --text-muted: #64748B;
  --text-dim: #475569;

  --success: #10B981;
  --success-bg: rgba(16, 185, 129, 0.14);
  --success-border: rgba(16, 185, 129, 0.32);
  --warning: #F59E0B;
  --warning-bg: rgba(245, 158, 11, 0.14);
  --warning-border: rgba(245, 158, 11, 0.32);
  --danger: #F43F5E;
  --danger-bg: rgba(244, 63, 94, 0.14);
  --danger-border: rgba(244, 63, 94, 0.32);

  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.35);
  --shadow: 0 8px 24px -4px rgba(0, 0, 0, 0.55);
  --shadow-hover: 0 14px 36px -6px rgba(0, 0, 0, 0.65), 0 0 0 1px rgba(56, 189, 248, 0.35);
  --shadow-modal: 0 25px 60px -12px rgba(0, 0, 0, 0.85), 0 0 0 1px rgba(34, 40, 56, 0.8);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  transition: background-color 0.35s cubic-bezier(0.4, 0, 0.2, 1), color 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

body {
  font-family: var(--font);
  background-color: var(--bg);
  color: var(--text-body);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: background-color 0.35s cubic-bezier(0.4, 0, 0.2, 1), color 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Global Smooth Transitions for Theme Toggle */
.header,
.search-hero,
.search-input-wrap,
.listing-card,
.card-body,
.card-footer,
.spec-chip,
.cat-pill,
.select-filter,
.theme-segmented-switch,
.theme-radio-pill,
.detail-container,
.detail-info-wrap,
.spec-box,
.spec-original-card,
.wizard-step-card,
.wizard-progress-card,
.parsed-review-card,
.parsed-input-box,
.form-control,
.modal-card,
.modal-header,
.modal-footer,
.status-radio-label,
.footer {
  transition: background-color 0.35s cubic-bezier(0.4, 0, 0.2, 1),
              border-color 0.35s cubic-bezier(0.4, 0, 0.2, 1),
              color 0.35s cubic-bezier(0.4, 0, 0.2, 1),
              box-shadow 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ══════════════════════════════════════════════════════════════════
   HEADER & NAVIGATION
   ══════════════════════════════════════════════════════════════════ */
.header {
  background-color: var(--header-bg);
  border-bottom: 1px solid var(--surface-border);
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.header-container {
  max-width: 1240px;
  margin: 0 auto;
  padding: 12px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  text-decoration: none;
}

.logo-icon {
  width: 40px;
  height: 40px;
  background: var(--surface-card);
  border: 1.5px solid var(--surface-border);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  flex-shrink: 0;
  padding: 3px;
  transition: all var(--duration-normal) var(--ease-spring);
}

.logo-icon .brand-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: calc(var(--radius-md) - 3px);
  display: block;
}

.brand-title {
  font-size: 16px;
  font-weight: 800;
  color: var(--text-main);
  letter-spacing: -0.3px;
  line-height: 1.2;
}

.brand-sub {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--primary);
  letter-spacing: 0.2px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: transparent;
  border: 1px solid transparent;
  color: var(--text-body);
  font-size: 13.5px;
  font-weight: 600;
  padding: 8px 16px;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all 0.18s ease;
}

.nav-btn:hover {
  background: var(--surface-hover);
  color: var(--text-main);
}

.nav-btn.active {
  background: var(--primary-light);
  color: var(--primary);
  border-color: var(--primary);
  font-weight: 700;
}

/* Theme Segmented Radio Switch */
.theme-segmented-switch {
  display: inline-flex;
  align-items: center;
  background-color: var(--surface-inset);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-full);
  padding: 3px;
  gap: 2px;
  user-select: none;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.theme-radio-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 12px;
  border-radius: var(--radius-full);
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.theme-radio-pill input[type="radio"] {
  display: none;
}

.theme-radio-pill:hover {
  color: var(--text-main);
}

.theme-radio-pill.active {
  background-color: var(--surface);
  color: var(--primary);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.12);
  font-weight: 800;
  transform: scale(1.02);
}

/* Hamburger Button for Mobile */
.hamburger-btn {
  display: none;
  background: var(--surface-inset);
  border: 1px solid var(--surface-border);
  color: var(--text-main);
  border-radius: var(--radius-md);
  width: 40px;
  height: 40px;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
  transition: all 0.18s ease;
}
.hamburger-btn:hover {
  background: var(--surface-hover);
  border-color: var(--primary);
}

/* Mobile Drawer Dropdown */
.mobile-drawer {
  display: none;
  background: var(--header-bg);
  border-bottom: 1px solid var(--surface-border);
  padding: 14px 20px;
  flex-direction: column;
  gap: 8px;
  animation: slideDown 0.2s ease;
}
.mobile-drawer.open {
  display: flex;
}

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

.mobile-nav-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 16px;
  border-radius: var(--radius-md);
  background: var(--surface-inset);
  border: 1px solid var(--surface-border);
  color: var(--text-main);
  font-size: 13.5px;
  font-weight: 700;
  text-align: left;
  cursor: pointer;
  transition: all 0.18s ease;
}
.mobile-nav-btn:hover, .mobile-nav-btn.active {
  background: var(--primary-light);
  border-color: var(--primary);
  color: var(--primary);
}

.mobile-theme-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 4px 2px;
  margin-top: 4px;
  border-top: 1px solid var(--surface-border);
}

.mobile-theme-label {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-muted);
}

/* ══════════════════════════════════════════════════════════════════
   MAIN LAYOUT & BUTTONS
   ══════════════════════════════════════════════════════════════════ */
.main-body {
  max-width: 1240px;
  width: 100%;
  margin: 0 auto;
  padding: 24px;
  flex: 1;
}

.app-view {
  display: none;
  animation: fadeIn 0.2s ease;
}
.app-view.active {
  display: block;
}

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

/* Global Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: var(--radius-md);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  border: 1px solid transparent;
  transition: transform 140ms var(--ease-button-press), background-color 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
  text-decoration: none;
  font-family: inherit;
  white-space: nowrap;
  user-select: none;
  will-change: transform;
}
.btn:active {
  transform: scale(0.97);
}

.btn-primary {
  background-color: var(--btn-primary-bg);
  color: var(--btn-primary-text);
  box-shadow: var(--btn-primary-shadow);
  border: 1px solid transparent;
  border-top: 1px solid rgba(255, 255, 255, 0.22);
}
.btn-primary:hover {
  background-color: var(--btn-primary-hover);
  color: var(--btn-primary-text);
  transform: translateY(-1.5px);
  box-shadow: var(--btn-primary-shadow-hover);
}
.btn-primary:active {
  transform: scale(0.97) translateY(0);
}

.btn-outline {
  background-color: var(--surface);
  border: 1px solid var(--surface-border);
  color: var(--text-main);
}
.btn-outline:hover {
  background-color: var(--surface-hover);
  border-color: var(--primary);
  color: var(--primary);
}

.btn-success {
  background-color: var(--success);
  color: #fff;
}
.btn-success:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}

.btn-danger {
  background-color: var(--danger-bg);
  border-color: var(--danger-border);
  color: var(--danger);
}
.btn-danger:hover {
  background-color: var(--danger);
  color: #fff;
}

.btn-sm {
  padding: 6px 12px;
  font-size: 12.5px;
  border-radius: var(--radius-sm);
}

.btn-lg {
  padding: 14px 24px;
  font-size: 15px;
  border-radius: var(--radius-md);
}

/* ══════════════════════════════════════════════════════════════════
   VIEW 1: SEARCH & CATALOG
   ══════════════════════════════════════════════════════════════════ */
.search-hero {
  background-color: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: 20px;
  padding: 22px 26px;
  margin-bottom: 22px;
  box-shadow: var(--shadow);
}

.hero-header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  gap: 14px;
}

.hero-title {
  font-size: 20px;
  font-weight: 800;
  color: var(--text-main);
  letter-spacing: -0.02em;
  line-height: 1.25;
  margin: 0;
}

.hero-subtitle {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 3px;
}

.counter-badge {
  background-color: var(--primary-light);
  color: var(--primary);
  border: 1px solid var(--primary-tint);
  font-size: 12px;
  font-weight: 700;
  padding: 5px 12px;
  border-radius: var(--radius-full);
  white-space: nowrap;
  flex-shrink: 0;
}

/* Search Bar (Zero Collision, Optical Icon Alignment) */
.search-box-wrap {
  position: relative;
  width: 100%;
  display: flex;
  align-items: center;
}

.search-icon-pos {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: #94a3b8;
  pointer-events: none;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
}

.search-input-lg {
  width: 100% !important;
  height: 42px !important;
  background-color: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 14px !important;
  padding: 0 38px 0 42px !important; /* Strictly prevents collision with icon */
  color: #0f172a !important;
  font-family: inherit !important;
  font-size: 13px !important;
  font-weight: 500 !important;
  outline: none !important;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04) !important;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease !important;
}

.search-input-lg:focus {
  border-color: #0f172a !important;
  background-color: #ffffff !important;
  box-shadow: 0 0 0 2px rgba(15, 23, 42, 0.12) !important;
}

.search-clear-btn {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: #94a3b8;
  font-size: 14px;
  cursor: pointer;
  display: none;
  padding: 4px;
  z-index: 5;
  line-height: 1;
}
.search-clear-btn.show { display: block; }
.search-clear-btn:hover { color: #0f172a; }

/* Category Filter Pills (Vector SVGs, No Scrollbar, Tactile Feedback) */
.category-pills-row, #category-pills-row {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding: 4px 0 4px 0;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none !important;
  -ms-overflow-style: none !important;
}
.category-pills-row::-webkit-scrollbar, #category-pills-row::-webkit-scrollbar {
  display: none !important;
  width: 0 !important;
  height: 0 !important;
}

.cat-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background-color: #ffffff;
  border: 1px solid #e2e8f0;
  color: #334155;
  font-size: 12px;
  font-weight: 600;
  padding: 6px 13px;
  border-radius: 12px;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 140ms cubic-bezier(0.2, 0, 0, 1), background-color 180ms ease, border-color 180ms ease, color 180ms ease, box-shadow 180ms ease;
  user-select: none;
  will-change: transform;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}
.cat-pill svg {
  color: #64748b;
  transition: color 180ms ease;
}
.cat-pill:hover {
  background-color: #f8fafc;
  border-color: #cbd5e1;
  color: #0f172a;
}
.cat-pill:active {
  transform: scale(0.97);
}
.cat-pill.active {
  background-color: #0f172a !important;
  color: #ffffff !important;
  border-color: #0f172a !important;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.15) !important;
}
.cat-pill.active svg {
  color: #ffffff !important;
}

/* Quick Insight Chips (Clean Typography, No Emojis, No Scrollbar) */
.quick-chips-scroll, #quick-chips-row {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding: 2px 0 4px 0;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none !important;
  -ms-overflow-style: none !important;
}
.quick-chips-scroll::-webkit-scrollbar, #quick-chips-row::-webkit-scrollbar {
  display: none !important;
  width: 0 !important;
  height: 0 !important;
}

.quick-chip-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background-color: #ffffff;
  border: 1px solid #e2e8f0;
  color: #475569;
  font-size: 11.5px;
  font-weight: 600;
  padding: 5px 11px;
  border-radius: 10px;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 140ms cubic-bezier(0.2, 0, 0, 1), background-color 180ms ease, border-color 180ms ease, color 180ms ease;
  user-select: none;
  will-change: transform;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.02);
}
.quick-chip-btn:hover {
  background-color: #f8fafc;
  border-color: #cbd5e1;
  color: #0f172a;
}
.quick-chip-btn:active {
  transform: scale(0.97);
}
.quick-chip-btn.active {
  background-color: #0f172a !important;
  color: #ffffff !important;
  border-color: #0f172a !important;
  font-weight: 700;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.15) !important;
}

/* Secondary Filter Bar (Compact & Sleek Card Dropdowns) */
.filter-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 4px 0 12px 0;
  gap: 8px;
}

.filter-left {
  display: flex;
  align-items: center;
  gap: 6px;
  flex: 1;
  min-width: 0;
}

.filter-right {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.select-filter {
  width: 100%;
  appearance: none;
  -webkit-appearance: none;
  background-color: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  color: #334155;
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  padding: 7px 24px 7px 10px;
  outline: none;
  cursor: pointer;
  transition: all 0.18s ease;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
  text-overflow: ellipsis;
  white-space: nowrap;
}
.select-filter:hover, .select-filter:focus {
  border-color: #0f172a;
  color: #0f172a;
}
.select-filter.active-filter {
  background-color: var(--primary-light);
  border-color: var(--primary);
  color: var(--primary);
  font-weight: 700;
}

.filter-gear-btn {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  color: #475569;
  cursor: pointer;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
  transition: all 0.15s ease;
  padding: 0;
  position: relative;
}
.filter-gear-btn:hover {
  background-color: #f8fafc;
  color: #0f172a;
  border-color: #cbd5e1;
}
.filter-gear-btn:active {
  transform: scale(0.96);
}

/* ══════════════════════════════════════════════════════════════════
   LISTINGS GRID & CARDS
   ══════════════════════════════════════════════════════════════════ */
.listings-grid {
  display: flex !important;
  flex-direction: column !important;
  gap: 14px !important;
  width: 100% !important;
}

.listing-card {
  background-color: var(--surface-card);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  transition: transform 0.24s var(--ease-out-quint), box-shadow 0.24s var(--ease-out-quint), border-color 0.18s ease;
  position: relative;
  width: 100%;
  box-sizing: border-box;
  will-change: transform, box-shadow;
  animation: cardCascadeIn 0.32s cubic-bezier(0.16, 1, 0.3, 1) both;
  animation-delay: calc(var(--card-index, 0) * 35ms);
}

@keyframes cardCascadeIn {
  from {
    opacity: 0;
    transform: translateY(14px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.listing-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
  border-color: var(--primary);
}

.listing-card:active {
  transform: translateY(-2px) scale(0.975);
}

.card-thumb-wrap {
  position: relative;
  width: 100%;
  height: 210px;
  background-color: var(--surface-inset);
  overflow: hidden;
  cursor: pointer;
}

.card-thumb-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.listing-card:hover .card-thumb-img {
  transform: scale(1.03);
}

.card-badge-row {
  position: absolute;
  top: 12px;
  left: 12px;
  right: 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  pointer-events: none;
}

.badge {
  font-size: 11.5px;
  font-weight: 800;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  letter-spacing: 0.3px;
  text-transform: uppercase;
}

.badge-area {
  background: rgba(15, 23, 42, 0.85);
  color: #fff;
  backdrop-filter: blur(4px);
}

.badge-status.active {
  background-color: var(--success-bg);
  color: var(--success);
  border: 1px solid var(--success-border);
}

.badge-status.hold {
  background-color: var(--warning-bg);
  color: var(--warning);
  border: 1px solid var(--warning-border);
}

.badge-status.sold {
  background-color: var(--danger-bg);
  color: var(--danger);
  border: 1px solid var(--danger-border);
}

.badge-status-tx {
  background-color: rgba(255, 255, 255, 0.92);
  color: var(--text-main);
  border: 1px solid rgba(0, 0, 0, 0.08);
  font-weight: 800;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.badge-status-tx.badge-tx-jual {
  background-color: rgba(0, 158, 188, 0.12);
  color: var(--primary);
  border: 1px solid rgba(0, 158, 188, 0.32);
}

.badge-status-tx.badge-tx-sewa {
  background-color: rgba(168, 85, 247, 0.12);
  color: #9333ea;
  border: 1px solid rgba(168, 85, 247, 0.32);
}

.badge-status-tx.badge-tx-jual-sewa {
  background-color: rgba(245, 158, 11, 0.14);
  color: #d97706;
  border: 1px solid rgba(245, 158, 11, 0.35);
}

.card-body {
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  flex: 1;
  width: 100%;
  box-sizing: border-box;
  overflow: hidden;
}

.card-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-main);
  letter-spacing: -0.2px;
  line-height: 1.35;
  margin-bottom: 6px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  word-break: break-word;
  cursor: pointer;
}
.card-title:hover { color: var(--primary); }

.card-price {
  font-size: 18.5px;
  font-weight: 800;
  color: var(--card-price);
  letter-spacing: -0.3px;
  margin-bottom: 12px;
}

.card-chips {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
  margin-bottom: 14px;
  margin-top: auto;
  overflow: hidden;
}

.spec-chip {
  background-color: var(--surface-inset);
  color: var(--text-body);
  font-size: 11.5px;
  font-weight: 600;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
}

.spec-chip svg,
.spec-chip .app-icon {
  color: var(--text-muted);
  flex-shrink: 0;
}

.card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 12px;
  border-top: 1px solid var(--surface-border);
  gap: 8px;
  width: 100%;
  box-sizing: border-box;
}

.card-id-text {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-dim);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 130px;
  flex-shrink: 1;
}

.card-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.icon-btn {
  width: 32px !important;
  height: 32px !important;
  min-width: 32px !important;
  min-height: 32px !important;
  max-width: 32px !important;
  max-height: 32px !important;
  border-radius: var(--radius-sm);
  background-color: var(--surface);
  border: 1px solid var(--surface-border);
  color: var(--text-muted);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 !important;
  cursor: pointer;
  transition: all 0.18s ease;
  flex-shrink: 0;
  box-sizing: border-box;
}

.icon-btn svg {
  width: 14px !important;
  height: 14px !important;
  max-width: 14px !important;
  max-height: 14px !important;
  display: block;
  flex-shrink: 0;
}

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

/* Floating Action Button (FAB) */
.fab-upload {
  position: fixed;
  bottom: 28px;
  right: 28px;
  background: var(--btn-primary-bg);
  color: var(--btn-primary-text);
  border: none;
  padding: 14px 22px;
  border-radius: var(--radius-full);
  font-size: 14.5px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  box-shadow: var(--btn-primary-shadow);
  transition: all 0.2s ease;
  z-index: 50;
}
.fab-upload:hover {
  background: var(--btn-primary-hover);
  transform: translateY(-3px) scale(1.02);
  box-shadow: var(--btn-primary-shadow-hover);
}

/* ══════════════════════════════════════════════════════════════════
   VIEW 2: DETAIL LISTING
   ══════════════════════════════════════════════════════════════════ */
.detail-container {
  max-width: 1100px;
  width: 100%;
  margin: 0 auto;
  box-sizing: border-box;
}

.detail-back-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  width: 100%;
}

.detail-more-btn {
  width: 38px;
  height: 38px;
  min-width: 38px;
  min-height: 38px;
  border-radius: var(--radius-md);
  background-color: var(--surface);
  border: 1px solid var(--surface-border);
  color: var(--text-main);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: transform 140ms var(--ease-button-press), background-color 160ms ease, border-color 160ms ease;
  flex-shrink: 0;
  padding: 0;
}
.detail-more-btn:hover, .detail-more-btn:active {
  background-color: var(--surface-hover);
  border-color: var(--primary);
  color: var(--primary);
  transform: scale(0.96);
}

.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: 32px;
  width: 100%;
  max-width: 100%;
}

.detail-gallery-wrap,
.detail-info-wrap {
  min-width: 0;
  max-width: 100%;
  width: 100%;
  box-sizing: border-box;
}

.main-photo-wrap {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  height: auto;
  aspect-ratio: 16 / 10;
  max-height: 420px;
  width: 100%;
  max-width: 100%;
  background-color: var(--surface-inset);
  border: 1px solid var(--surface-border);
  margin-bottom: 12px;
  box-shadow: var(--shadow);
  box-sizing: border-box;
}

.detail-main-img {
  width: 100%;
  height: 100%;
  max-width: 100%;
  object-fit: cover;
  display: block;
}

.detail-thumbs-strip {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  padding: 2px 2px 6px 2px;
  margin-bottom: 20px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.detail-thumbs-strip::-webkit-scrollbar {
  display: none;
}

.thumb-mini-item {
  width: 76px;
  height: 58px;
  min-width: 76px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 2px solid transparent;
  cursor: pointer;
  flex-shrink: 0;
  opacity: 0.75;
  transition: all 0.18s ease;
  box-sizing: border-box;
}
.thumb-mini-item:hover, .thumb-mini-item.active {
  opacity: 1;
  border-color: var(--primary);
}
.thumb-mini-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.detail-header-block {
  margin-bottom: 20px;
}

.detail-badges-row {
  display: flex;
  gap: 8px;
  margin-bottom: 10px;
  align-items: center;
}

.detail-title {
  font-size: 26px;
  font-weight: 800;
  color: var(--text-main);
  letter-spacing: -0.5px;
  line-height: 1.25;
  margin-bottom: 8px;
}

.detail-price {
  font-size: 24px;
  font-weight: 800;
  color: var(--card-price);
  letter-spacing: -0.3px;
  margin-bottom: 20px;
}

.detail-cta-bar {
  display: flex;
  gap: 10px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.detail-specs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 12px;
  margin-bottom: 24px;
}

.spec-box {
  background-color: var(--surface-card);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
  transition: transform 0.18s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.18s ease, border-color 0.18s ease;
}

.spec-box:hover {
  transform: translateY(-2px);
  border-color: var(--primary);
  box-shadow: var(--shadow-sm);
}

.spec-box-top {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 5px;
}

.spec-box-icon {
  color: var(--text-main);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.spec-box-val {
  font-size: 16.5px;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.spec-box-label {
  font-size: 12px;
  font-weight: 600;
  color: #1e40af;
  line-height: 1.3;
}

[data-theme="dark"] .spec-box-label {
  color: #93c5fd;
}

.spec-original-card {
  background-color: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-lg);
  padding: 20px;
  margin-bottom: 24px;
}

.spec-original-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.spec-original-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-main);
}

.spec-original-text {
  font-size: 13.5px;
  color: var(--text-body);
  line-height: 1.6;
  white-space: pre-wrap;
}

/* ══════════════════════════════════════════════════════════════════
   VIEW 3: WIZARD UNGGAH LISTING
   ══════════════════════════════════════════════════════════════════ */
.wizard-container {
  max-width: 800px;
  margin: 0 auto;
}

.wizard-progress-card {
  background-color: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  margin-bottom: 24px;
  box-shadow: var(--shadow-sm);
}

.wizard-top-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.wizard-step-label {
  font-size: 13px;
  font-weight: 700;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.duo-progress-track {
  width: 100%;
  height: 12px;
  background-color: var(--surface-inset);
  border-radius: var(--radius-full);
  overflow: hidden;
  border: 1px solid var(--surface-border);
}

.duo-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--primary), #06D6A0);
  border-radius: var(--radius-full);
  transition: width 0.35s ease;
}

.wizard-step-card {
  display: none;
  background-color: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: var(--shadow);
}
.wizard-step-card.active {
  display: block;
}

.wizard-question-title {
  font-size: 22px;
  font-weight: 800;
  color: var(--text-main);
  letter-spacing: -0.4px;
  margin-bottom: 6px;
}

.wizard-question-sub {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 24px;
}

/* Category Grid Picker */
.category-picker-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 24px;
}

.cat-pick-card {
  background-color: var(--surface-inset);
  border: 2px solid var(--surface-border);
  border-radius: var(--radius-md);
  padding: 16px 12px;
  text-align: center;
  cursor: pointer;
  transition: all 0.18s ease;
  user-select: none;
}
.cat-pick-card:hover {
  border-color: var(--primary);
  background-color: var(--primary-light);
}
.cat-pick-card.selected {
  border-color: var(--primary);
  background-color: var(--primary-light);
  box-shadow: 0 0 0 2px var(--primary);
}

.cat-pick-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 32px;
  margin-bottom: 6px;
  color: var(--text-muted);
  transition: color 180ms ease;
}
.cat-pick-card.selected .cat-pick-icon,
.cat-pick-card:hover .cat-pick-icon {
  color: var(--primary);
}

.cat-pick-title {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-main);
}

/* Form Controls */
.form-group {
  margin-bottom: 20px;
}

.form-label {
  display: block;
  font-size: 13px;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 6px;
}

.form-control {
  width: 100%;
  padding: 11px 14px;
  background-color: var(--surface-inset);
  border: 1.5px solid var(--surface-border);
  border-radius: var(--radius-md);
  color: var(--text-main);
  font-family: inherit;
  font-size: 14px;
  outline: none;
  transition: all 0.18s ease;
}
.form-control:focus {
  border-color: var(--primary);
  background-color: var(--surface);
  box-shadow: 0 0 0 3px var(--primary-light);
}

.form-textarea {
  min-height: 120px;
  resize: vertical;
  line-height: 1.5;
}

.form-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.form-grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}

/* AI Divider Arrow Down Circle */
.ai-divider-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin: 24px 0 16px;
}

.ai-divider-line {
  flex: 1;
  height: 1px;
  background: var(--surface-border);
}

.ai-divider-badge {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--surface);
  border: 1.5px solid var(--surface-border);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-sm);
  transition: all 0.2s ease;
}

.ai-divider-wrap:hover .ai-divider-badge {
  border-color: var(--primary);
  transform: translateY(2px);
}

/* Parsed Fields Review */
.parsed-review-card {
  background-color: var(--surface-inset);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-md);
  padding: 20px;
  margin-top: 10px;
}

.parsed-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.parsed-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--primary);
}

/* Dropzone & Photo Previews */
.dropzone-box {
  border: 2px dashed var(--surface-border);
  border-radius: var(--radius-lg);
  padding: 32px 20px;
  text-align: center;
  background-color: var(--surface-inset);
  cursor: pointer;
  transition: all 0.18s ease;
}
.dropzone-box:hover, .dropzone-box.drag-over {
  border-color: var(--primary);
  background-color: var(--primary-light);
}

.dropzone-icon {
  font-size: 36px;
  margin-bottom: 8px;
}

.dropzone-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 4px;
}

.dropzone-desc {
  font-size: 12.5px;
  color: var(--text-muted);
}

.photo-previews-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
  gap: 12px;
  margin: 18px 0;
}

.photo-preview-item {
  position: relative;
  width: 100%;
  aspect-ratio: 1;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 2px solid var(--surface-border);
  background-color: var(--surface-inset);
}
.photo-preview-item.main-photo {
  border-color: var(--primary);
}
.photo-preview-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.photo-del-btn {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 22px;
  height: 22px;
  border-radius: var(--radius-full);
  background: rgba(220, 38, 38, 0.9);
  color: #fff;
  border: none;
  cursor: pointer;
  display: grid;
  place-items: center;
  font-size: 11px;
}

.submit-summary-box {
  background-color: var(--surface-inset);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-md);
  padding: 16px;
  margin-bottom: 24px;
}

.summary-title {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 8px;
}

.summary-row {
  font-size: 13px;
  color: var(--text-body);
  margin-bottom: 4px;
}

.wizard-footer-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-top: 24px;
}

.celebration-id-badge {
  display: inline-block;
  background-color: var(--surface-inset);
  color: var(--primary);
  font-family: var(--font-mono);
  font-size: 16px;
  font-weight: 700;
  padding: 8px 18px;
  border-radius: var(--radius-full);
  border: 1.5px solid var(--primary);
}

/* ══════════════════════════════════════════════════════════════════
   💎 CRAFT MODAL SYSTEM (Apple WWDC Fluid Physics & Emil Kowalski)
   ══════════════════════════════════════════════════════════════════ */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.48);
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.24s var(--ease-out-quint);
  padding: 16px;
}

[data-theme="dark"] .modal-overlay {
  background: rgba(0, 0, 0, 0.75);
}

.modal-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.modal-card {
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: 22px;
  width: 100%;
  max-width: 440px;
  padding: 24px;
  box-shadow: 0 24px 48px -12px rgba(15, 23, 42, 0.18), 0 0 0 1px rgba(0, 0, 0, 0.04), 0 2px 4px rgba(0, 0, 0, 0.04);
  transform: scale(0.95) translateY(12px);
  opacity: 0;
  transform-origin: center center;
  transition: transform 0.3s var(--ease-out-expo), opacity 0.24s ease-out;
  will-change: transform, opacity;
  position: relative;
  overflow: hidden;
}

[data-theme="dark"] .modal-card {
  background: #151922;
  border: 1px solid #222838;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 28px 60px -12px rgba(0, 0, 0, 0.72), 0 0 0 1px rgba(255, 255, 255, 0.06);
}

.modal-overlay.open .modal-card {
  transform: scale(1) translateY(0);
  opacity: 1;
}

.modal-card.modal-sheet-action {
  max-width: 380px;
  padding: 22px;
}

.modal-card.modal-card-sm {
  max-width: 390px;
  padding: 22px;
}

/* Modal Header */
.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 18px;
}

.modal-header-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.modal-badge-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 3px 8px;
  border-radius: var(--radius-full);
  background: var(--primary-light);
  color: var(--primary);
  border: 1px solid var(--primary-tint);
  width: fit-content;
  margin-bottom: 4px;
}

.modal-badge-pill.badge-pill-warning {
  background: var(--warning-bg);
  color: var(--warning);
  border-color: var(--warning-border);
}

.modal-badge-pill.badge-pill-status {
  background: #ECFDF5;
  color: #059669;
  border-color: #A7F3D0;
}

[data-theme="dark"] .modal-badge-pill.badge-pill-status {
  background: rgba(16, 185, 129, 0.15);
  color: #34D399;
  border-color: rgba(16, 185, 129, 0.25);
}

.modal-badge-pill.badge-pill-danger {
  background: var(--danger-bg);
  color: var(--danger);
  border-color: var(--danger-border);
}

.modal-title {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.025em;
  color: var(--text-main);
  line-height: 1.25;
  margin: 0;
}

.modal-subtitle {
  font-size: 12.5px;
  color: var(--text-muted);
  font-weight: 500;
  line-height: 1.4;
  margin: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  word-break: break-word;
}

/* Sleek Circular Close Button */
.icon-close {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--surface-inset);
  border: 1px solid var(--surface-border);
  color: var(--text-muted);
  cursor: pointer;
  padding: 0;
  flex-shrink: 0;
  transition: all 0.16s var(--ease-button-press);
}

.icon-close:hover {
  background: var(--surface-hover);
  color: var(--text-main);
  border-color: var(--text-dim);
  transform: scale(1.06);
}

.icon-close:active {
  transform: scale(0.92);
}

/* Modal Body */
.modal-body {
  margin-bottom: 20px;
}

/* ══════════════════════════════════════════════════════════════════
   ACTION MENU ROWS (3-Dots Popup)
   ══════════════════════════════════════════════════════════════════ */
.modal-action-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 0;
}

.action-menu-item {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 13px 15px;
  border-radius: 14px;
  background: var(--surface-inset);
  border: 1.5px solid var(--surface-border);
  color: var(--text-main);
  cursor: pointer;
  transition: all 0.18s var(--ease-out-quint);
  text-align: left;
  user-select: none;
  position: relative;
  outline: none;
}

.action-menu-item:hover {
  background: var(--surface);
  border-color: #CBD5E1;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.05);
  transform: translateY(-1.5px);
}

[data-theme="dark"] .action-menu-item:hover {
  background: #1B202D;
  border-color: #334155;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.35);
  transform: translateY(-1.5px);
}

.action-menu-item:active {
  transform: scale(0.98);
}

/* Action Item Left Icon Badges */
.action-item-icon {
  width: 40px;
  height: 40px;
  border-radius: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: transform 0.2s var(--ease-out-expo);
}

.action-menu-item:hover .action-item-icon {
  transform: scale(1.08);
}

/* 1. Edit Action Style */
.action-item-icon.icon-edit {
  background: rgba(0, 158, 188, 0.1);
  color: var(--primary);
  border: 1px solid rgba(0, 158, 188, 0.2);
}

.action-item-edit:hover {
  border-color: var(--primary);
}

/* 2. Status Action Style */
.action-item-icon.icon-status {
  background: rgba(16, 185, 129, 0.1);
  color: #10B981;
  border: 1px solid rgba(16, 185, 129, 0.2);
}

.action-item-status:hover {
  border-color: #10B981;
}

/* 3. Danger (Delete) Action Style */
.action-item-icon.icon-danger {
  background: rgba(220, 38, 38, 0.1);
  color: var(--danger);
  border: 1px solid rgba(220, 38, 38, 0.2);
}

.action-item-danger:hover {
  border-color: var(--danger);
  background: var(--danger-bg);
}

[data-theme="dark"] .action-item-danger:hover {
  background: rgba(220, 38, 38, 0.08);
  border-color: rgba(220, 38, 38, 0.4);
}

/* Middle Text Content */
.action-item-content {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
}

.action-item-title {
  font-size: 14.5px;
  font-weight: 700;
  color: var(--text-main);
  line-height: 1.3;
}

.action-item-danger:hover .action-item-title {
  color: var(--danger);
}

.action-item-sub {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-muted);
  line-height: 1.3;
  margin-top: 1px;
}

/* Right Arrow Indicator */
.action-item-arrow {
  color: var(--text-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease, color 0.2s ease;
  flex-shrink: 0;
}

.action-menu-item:hover .action-item-arrow {
  transform: translateX(3px);
  color: var(--text-main);
}

.action-item-danger:hover .action-item-arrow {
  color: var(--danger);
}

/* ══════════════════════════════════════════════════════════════════
   STATUS RADIO CARDS & PREVIEW BOXES
   ══════════════════════════════════════════════════════════════════ */
.status-radio-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 4px;
}

.status-radio-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 16px;
  border: 1.5px solid var(--surface-border);
  border-radius: 14px;
  background-color: var(--surface-inset);
  cursor: pointer;
  transition: all 0.18s var(--ease-out-quint);
  user-select: none;
}

.status-radio-label:hover {
  background-color: var(--surface-hover);
  border-color: #CBD5E1;
  transform: translateY(-1px);
}

[data-theme="dark"] .status-radio-label:hover {
  border-color: #334155;
}

.status-radio-label.selected {
  border-color: var(--primary);
  background-color: var(--primary-light);
  box-shadow: 0 0 0 1px var(--primary);
}

.status-option-content {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 14px;
  letter-spacing: 0.1px;
}

.status-radio-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.status-radio-label[data-status="ACTIVE"] .status-radio-icon {
  background: rgba(16, 185, 129, 0.12);
  color: #10B981;
}

.status-radio-label[data-status="HOLD"] .status-radio-icon {
  background: rgba(245, 158, 11, 0.12);
  color: #F59E0B;
}

.status-radio-label[data-status="SOLD"] .status-radio-icon {
  background: rgba(239, 68, 68, 0.12);
  color: #EF4444;
}

.status-radio-check {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2px solid var(--surface-border);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.18s ease;
  flex-shrink: 0;
}

.status-radio-label.selected .status-radio-check {
  border-color: var(--primary);
  background-color: var(--primary);
}

.status-radio-label.selected .status-radio-check::after {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: white;
}

/* Modal Preview Box for Delete */
.modal-preview-box {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--surface-inset);
  border: 1.5px solid var(--surface-border);
  border-radius: 14px;
  padding: 14px 16px;
  margin-top: 4px;
}

.preview-box-icon {
  width: 40px;
  height: 40px;
  border-radius: 11px;
  background: var(--primary-light);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.preview-box-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.preview-box-title {
  color: var(--text-main);
  font-size: 14.5px;
  font-weight: 700;
  line-height: 1.3;
}

.preview-box-id {
  font-size: 12px;
  color: var(--text-dim);
  font-family: var(--font-mono);
  margin-top: 2px;
}

/* Modal Footer & Buttons */
.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.modal-footer-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.modal-footer-split .btn {
  width: 100%;
  justify-content: center;
  height: 42px;
  font-size: 14px;
}

/* ══════════════════════════════════════════════════════════════════
   FOOTER & TOAST
   ══════════════════════════════════════════════════════════════════ */
.footer {
  border-top: 1px solid var(--surface-border);
  background-color: var(--surface);
  padding: 24px;
  margin-top: 48px;
}

.footer-container {
  max-width: 1240px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-brand { font-size: 14px; font-weight: 700; color: var(--text-main); }
.footer-copy { font-size: 12px; color: var(--text-muted); margin-top: 2px; }
.footer-link { font-size: 13px; color: var(--primary); text-decoration: none; font-weight: 600; }
.footer-link:hover { text-decoration: underline; }

/* ─── TOAST NOTIFICATION FLOATING ELEGANTLY BELOW HEADER ─── */
.toast-container {
  position: fixed;
  top: 72px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9999;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  width: auto;
  max-width: 520px;
  padding: 0 16px;
  pointer-events: none;
}

.toast {
  position: relative;
  overflow: hidden;
  pointer-events: auto;
  background: var(--surface);
  color: var(--text-main);
  border: 1.5px solid var(--surface-border);
  border-radius: 14px;
  padding: 12px 18px 14px;
  font-size: 13.5px;
  font-weight: 700;
  box-shadow: 0 16px 36px -6px rgba(0, 0, 0, 0.22), 0 4px 12px rgba(0, 0, 0, 0.08);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  animation: toastSlideDown 0.32s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

.toast-progress-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  height: 3px;
  width: 100%;
  transform-origin: left center;
  animation: toastCountdown 3.2s linear forwards;
}

.toast-success .toast-progress-bar { background: #10B981; }
.toast-error .toast-progress-bar { background: #EF4444; }
.toast-warning .toast-progress-bar { background: #F59E0B; }
.toast-info .toast-progress-bar { background: var(--primary); }

@keyframes toastCountdown {
  0% { transform: scaleX(1); }
  100% { transform: scaleX(0); }
}

.toast-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.toast-text {
  line-height: 1.35;
}

.toast-success {
  border-color: rgba(16, 185, 129, 0.4);
  background: rgba(255, 255, 255, 0.96);
  color: #065F46;
}
[data-theme="dark"] .toast-success {
  background: rgba(15, 23, 42, 0.94);
  color: #34D399;
  border-color: rgba(52, 211, 153, 0.35);
}

.toast-error {
  border-color: rgba(239, 68, 68, 0.4);
  background: rgba(255, 255, 255, 0.96);
  color: #991B1B;
}
[data-theme="dark"] .toast-error {
  background: rgba(15, 23, 42, 0.94);
  color: #F87171;
  border-color: rgba(248, 113, 113, 0.35);
}

.toast-warning {
  border-color: rgba(245, 158, 11, 0.4);
  background: rgba(255, 255, 255, 0.96);
  color: #92400E;
}
[data-theme="dark"] .toast-warning {
  background: rgba(15, 23, 42, 0.94);
  color: #FBBF24;
  border-color: rgba(251, 191, 36, 0.35);
}

.toast-info {
  border-color: rgba(59, 130, 246, 0.4);
  background: rgba(255, 255, 255, 0.96);
  color: #1E40AF;
}
[data-theme="dark"] .toast-info {
  background: rgba(15, 23, 42, 0.94);
  color: #60A5FA;
  border-color: rgba(96, 165, 250, 0.35);
}

@keyframes toastSlideDown {
  from {
    transform: translateY(-24px) scale(0.92);
    opacity: 0;
  }
  to {
    transform: translateY(0) scale(1);
    opacity: 1;
  }
}

/* ══════════════════════════════════════════════════════════════════
   MOBILE RESPONSIVE OVERHAUL (Craft Design Engineering & UIX Pro)
   ══════════════════════════════════════════════════════════════════ */
@media (max-width: 768px) {
  /* Layout & Viewport */
  body {
    overflow-x: hidden;
  }
  .main-body {
    padding: 16px 14px 80px;
    max-width: 100%;
  }

  /* Header Navigation */
  .desktop-nav { display: none !important; }
  .hamburger-btn {
    display: inline-flex !important;
    min-width: 44px;
    min-height: 44px;
    align-items: center;
    justify-content: center;
  }
  .header-container {
    padding: 10px 14px;
    gap: 8px;
  }
  .brand-title {
    font-size: 14px;
    line-height: 1.2;
  }
  .brand-sub {
    font-size: 10.5px;
  }
  .logo-icon {
    width: 34px;
    height: 34px;
    border-radius: var(--radius-sm);
  }

  /* Search Hero with proper padding and whitespace */
  .search-hero {
    padding: 18px 16px 16px;
    border-radius: 18px;
    margin-bottom: 16px;
  }
  .hero-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    gap: 8px;
  }
  .hero-title {
    font-size: 15px;
    letter-spacing: -0.015em;
    line-height: 1.25;
    margin-bottom: 0;
    font-weight: 800;
  }
  .hero-sub {
    font-size: 12px;
    line-height: 1.4;
    margin-bottom: 12px;
  }
  .counter-badge {
    font-size: 11px;
    font-weight: 700;
    padding: 4px 9px;
  }

  /* Search Box */
  .search-box-wrap {
    height: 42px;
    margin-bottom: 10px;
  }
  .search-input-lg {
    height: 42px;
    font-size: 13px;
    padding-left: 38px;
    padding-right: 34px;
    border-radius: 11px;
  }
  .search-icon-pos {
    left: 12px;
    width: 16px;
    height: 16px;
  }

  /* Category Filter Pills (Horizontal Touch Swipe) */
  .category-pills-row {
    gap: 6px;
    padding: 2px 0 4px;
    margin-bottom: 0;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .category-pills-row::-webkit-scrollbar {
    display: none;
  }
  .cat-pill {
    padding: 6px 11px;
    min-height: 32px;
    font-size: 12px;
    flex-shrink: 0;
    border-radius: 9px;
  }
  .cat-pill svg {
    width: 13px;
    height: 13px;
  }

  /* Secondary Filter Bar */
  .filter-bar {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    margin-bottom: 16px;
  }
  .filter-left {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }
  .filter-right {
    width: 100%;
  }
  .select-filter {
    height: 40px;
    font-size: 12px;
    padding: 0 10px;
    border-radius: 10px;
    width: 100%;
    min-width: 0;
  }

  /* Listing Cards Grid */
  .listings-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .listing-card {
    border-radius: var(--radius-lg);
  }
  .card-body {
    padding: 14px;
  }
  .card-title {
    font-size: 15.5px;
    margin-bottom: 4px;
  }
  .card-price {
    font-size: 17px;
    margin-bottom: 10px;
  }
  .icon-btn {
    min-width: 36px;
    min-height: 36px;
  }

  /* Detail View Layout & Buttons */
  .detail-container {
    padding: 0;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }
  .detail-back-bar {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
    width: 100%;
    box-sizing: border-box;
  }
  .detail-back-bar .btn-sm {
    min-height: 38px;
    padding: 8px 14px;
    font-size: 13px;
    font-weight: 700;
  }
  .detail-more-btn {
    width: 38px;
    height: 38px;
    min-width: 38px;
    min-height: 38px;
    border-radius: var(--radius-md);
    background-color: var(--surface);
    border: 1px solid var(--surface-border);
    color: var(--text-main);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: var(--shadow-sm);
    flex-shrink: 0;
  }
  .detail-grid {
    grid-template-columns: 1fr;
    gap: 16px;
    width: 100%;
    max-width: 100%;
    min-width: 0;
  }
  .detail-gallery-wrap,
  .detail-info-wrap {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
  }
  .main-photo-wrap {
    height: auto;
    aspect-ratio: 16 / 10;
    max-height: 270px;
    width: 100%;
    max-width: 100%;
    border-radius: var(--radius-md);
    margin-bottom: 10px;
    overflow: hidden;
    box-sizing: border-box;
  }
  .detail-thumbs-strip {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding: 2px 2px 6px 2px;
  }
  .detail-thumbs-strip::-webkit-scrollbar {
    display: none;
  }
  .thumb-mini-item {
    width: 72px;
    height: 54px;
    min-width: 72px;
    border-radius: var(--radius-sm);
    flex-shrink: 0;
    box-sizing: border-box;
  }
  .detail-title {
    font-size: 20px;
    line-height: 1.3;
    letter-spacing: -0.02em;
    margin-bottom: 6px;
  }
  .detail-price {
    font-size: 21px;
    font-weight: 800;
    letter-spacing: -0.02em;
    margin-bottom: 14px;
  }
  .detail-specs-grid {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-bottom: 18px;
  }
  .spec-box {
    padding: 10px 12px;
    border-radius: var(--radius-sm);
  }
  .spec-box-label {
    font-size: 10.5px;
    font-weight: 700;
    margin-bottom: 3px;
  }
  .spec-box-val {
    font-size: 13.5px;
    font-weight: 700;
  }

  /* Detail CTA Stack on Mobile */
  .detail-cta-stack {
    margin-top: 16px;
    gap: 10px;
    width: 100%;
    box-sizing: border-box;
  }
  #detail-btn-send-wa {
    min-height: 50px;
    font-size: 15.5px;
    font-weight: 800;
    border-radius: var(--radius-md);
    width: 100%;
  }
  .detail-cta-stack .btn-outline {
    min-height: 44px;
    font-size: 13.5px;
    font-weight: 700;
    border-radius: var(--radius-md);
  }

  /* Wizard Stepper on Mobile */
  .wizard-container {
    padding: 0;
  }
  .wizard-step-card {
    padding: 18px 14px;
    border-radius: var(--radius-lg);
  }
  .wizard-question-title {
    font-size: 18px;
    margin-bottom: 4px;
  }
  .wizard-question-sub {
    font-size: 12.5px;
    margin-bottom: 16px;
  }
  .category-picker-grid {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }
  .cat-pick-card {
    padding: 14px 10px;
    border-radius: var(--radius-md);
  }
  .cat-pick-title {
    font-size: 12.5px;
  }
  .form-grid-3, .form-grid-2 {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .wizard-footer-nav {
    flex-direction: column-reverse;
    gap: 8px;
    margin-top: 20px;
  }
  .wizard-footer-nav .btn {
    width: 100%;
    min-height: 46px;
    font-size: 14px;
  }
  #btn-parse-ai {
    width: 100%;
    min-height: 48px;
    font-size: 14.5px;
  }
  .dropzone-box {
    padding: 24px 14px;
    border-radius: var(--radius-md);
  }
  .dropzone-title {
    font-size: 13px;
  }
  .dropzone-desc {
    font-size: 11.5px;
  }

  /* Modals on Mobile — iOS Fluid Bottom Sheet Engine */
  .modal-overlay {
    padding: 0 !important;
    align-items: flex-end !important;
    backdrop-filter: blur(14px) !important;
    -webkit-backdrop-filter: blur(14px) !important;
  }
  .modal-card {
    max-width: 100vw !important;
    width: 100% !important;
    border-radius: 24px 24px 0 0 !important;
    padding: 20px 18px calc(env(safe-area-inset-bottom, 16px) + 16px) !important;
    max-height: 88vh !important;
    transform: translateY(100%) !important;
    transition: transform 0.36s cubic-bezier(0.32, 0.72, 0, 1), opacity 0.2s ease !important;
    box-shadow: 0 -12px 40px rgba(0, 0, 0, 0.24) !important;
    border-bottom: none !important;
  }
  .modal-card::before {
    content: "" !important;
    display: block !important;
    width: 38px !important;
    height: 4.5px !important;
    background: var(--surface-border) !important;
    border-radius: 99px !important;
    margin: -4px auto 14px !important;
    opacity: 0.85 !important;
  }
  .modal-overlay.open .modal-card {
    transform: translateY(0) !important;
    opacity: 1 !important;
  }
  .modal-title {
    font-size: 17px;
  }

  /* Floating Action Button (FAB) */
  .fab-upload {
    bottom: 24px;
    right: 18px;
    width: 48px;
    height: 48px;
    min-width: 48px;
    min-height: 48px;
    padding: 0;
    border-radius: var(--radius-full);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.28);
    z-index: 60;
  }
  .fab-upload span {
    display: none;
  }
  .fab-upload svg {
    width: 20px;
    height: 20px;
  }

  /* Toast Notification */
  .toast-container {
    top: 68px;
    bottom: auto;
    left: 50%;
    transform: translateX(-50%);
    width: calc(100% - 24px);
    max-width: 400px;
    padding: 0;
  }
  .toast {
    width: 100%;
    justify-content: center;
    box-sizing: border-box;
    font-size: 13px;
    padding: 10px 16px;
  }
}

/* ══════════════════════════════════════════════════════════════════
   TRI-SIGNAL ACCESSIBILITY SYSTEM (Craft Design Engineering)
   ══════════════════════════════════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.15s !important;
    scroll-behavior: auto !important;
  }
  .modal-card, .listing-card, .toast, .fab-upload, .mobile-drawer {
    transform: none !important;
  }
}

@media (prefers-reduced-transparency: reduce) {
  .header, .modal-card, .badge-area, .status-radio-label {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    background-color: var(--surface) !important;
  }
}

/* ══════════════════════════════════════════════════════════════════
   STATIC APP ICONS VECTOR GRAPHICS SYSTEM (ZERO-CDN ENGINE)
   ══════════════════════════════════════════════════════════════════ */
.app-icon, .icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  vertical-align: middle;
  stroke-width: 2px;
  flex-shrink: 0;
  color: inherit;
}
.icon-xs, .app-icon-xs { width: 12px !important; height: 12px !important; }
.icon-sm, .app-icon-sm { width: 14px !important; height: 14px !important; }
.icon-md, .app-icon-md { width: 18px !important; height: 18px !important; }
.icon-lg, .app-icon-lg { width: 22px !important; height: 22px !important; }
.icon-xl, .app-icon-xl { width: 28px !important; height: 28px !important; }

/* ══════════════════════════════════════════════════════════════════
   SKELETON PRELOADER & LAZY LOAD SHIMMER ANIMATION
   ══════════════════════════════════════════════════════════════════ */
@keyframes shimmerWave {
  0% {
    background-position: -200% 0;
  }
  100% {
    background-position: 200% 0;
  }
}

.skeleton-card {
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-sm);
  animation: fadeIn 280ms cubic-bezier(0.16, 1, 0.3, 1);
}

.skeleton-shimmer {
  background: linear-gradient(
    90deg,
    var(--surface-inset) 20%,
    var(--surface-hover) 50%,
    var(--surface-inset) 80%
  );
  background-size: 200% 100%;
  animation: shimmerWave 1.8s infinite ease-in-out;
  border-radius: var(--radius-sm);
}

.skeleton-thumb {
  width: 100%;
  aspect-ratio: 16 / 10;
  border-radius: 0;
}

.skeleton-body {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.skeleton-line {
  height: 14px;
}

.skeleton-line.badge-line {
  width: 35%;
  height: 18px;
  border-radius: var(--radius-full);
}

.skeleton-line.title-line {
  height: 20px;
  width: 85%;
}

.skeleton-line.price-line {
  height: 24px;
  width: 50%;
}

.skeleton-grid-spec {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 4px;
}

.skeleton-box {
  height: 38px;
  border-radius: var(--radius-md);
}

/* Image Lazy Load Smooth Transition */
.listing-img {
  opacity: 0;
  transition: opacity 300ms cubic-bezier(0.16, 1, 0.3, 1), transform 300ms cubic-bezier(0.16, 1, 0.3, 1);
}
.listing-img.loaded {
  opacity: 1;
}


@media (prefers-contrast: more) {
  .listing-card, .btn, .modal-card, .form-control, .cat-pill {
    border: 2px solid var(--text-main) !important;
  }
}

/* ══════════════════════════════════════════════════════════════════
   GOOGLE KEEP MIGRATION WIZARD STYLES (Phase 4)
   ══════════════════════════════════════════════════════════════════ */
.badge-pill-keep {
  background: var(--primary-light);
  color: var(--primary);
  border: 1px solid rgba(5, 150, 105, 0.2);
}
[data-theme="dark"] .badge-pill-keep {
  background: rgba(5, 150, 105, 0.15);
  color: #34D399;
  border-color: rgba(5, 150, 105, 0.3);
}

.btn-nav-keep {
  background: rgba(245, 158, 11, 0.08);
  border: 1px solid rgba(245, 158, 11, 0.25);
  transition: all 200ms var(--ease-button-press);
}
.btn-nav-keep:hover {
  background: rgba(245, 158, 11, 0.16);
  border-color: #F59E0B;
  transform: translateY(-1px);
}

/* Stepper Tabs */
.keep-stepper-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 18px 0;
  border-bottom: 1px solid var(--surface-border);
}
.keep-step-pill {
  background: none;
  border: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px 12px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  position: relative;
  transition: all 200ms ease;
}
.keep-step-pill .step-num {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--surface-inset);
  color: var(--text-muted);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 11.5px;
  font-weight: 700;
  transition: all 200ms ease;
}
.keep-step-pill.active {
  color: var(--text-main);
  font-weight: 700;
}
.keep-step-pill.active .step-num {
  background: var(--primary);
  color: #FFFFFF;
}
.keep-step-pill.active::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 0;
  right: 0;
  height: 2.5px;
  background: var(--primary);
  border-radius: 2px 2px 0 0;
}
.keep-step-line {
  flex: 1;
  height: 1px;
  background: var(--surface-border);
  margin-bottom: 12px;
}

/* Step Content Panes */
.keep-step-content {
  display: none;
  padding: 18px;
}
.keep-step-content.active {
  display: block;
  animation: fadeIn 220ms var(--ease-out-expo);
}

/* Step 1 Guide Cards */
.keep-guide-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.keep-guide-card {
  display: flex;
  gap: 14px;
  padding: 14px 16px;
  background: var(--surface-inset);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-md);
  transition: border-color 200ms ease;
}
.keep-guide-card:hover {
  border-color: var(--primary);
}
.guide-card-icon {
  width: 28px;
  height: 28px;
  min-width: 28px;
  border-radius: 8px;
  background: var(--surface);
  color: var(--text-main);
  font-weight: 700;
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--surface-border);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}
[data-theme="dark"] .guide-card-icon {
  background: var(--surface-hover);
  color: var(--text-main);
  border-color: var(--surface-border);
}
.guide-card-body {
  flex: 1;
}
.guide-card-title {
  margin: 0 0 4px;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-main);
}
.guide-card-text {
  margin: 0;
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--text-body);
}
.guide-tip-pill {
  margin-top: 8px;
  padding: 6px 10px;
  background: var(--surface);
  border: 1px dashed var(--surface-border);
  border-radius: var(--radius-sm);
  font-size: 11.5px;
  color: var(--text-muted);
}

/* Step 2 Dropzone */
.keep-dropzone {
  border: 2px dashed var(--surface-border);
  border-radius: var(--radius-lg);
  padding: 32px 20px;
  text-align: center;
  background: var(--surface);
  cursor: pointer;
  transition: all 220ms var(--ease-out-expo);
}
.keep-dropzone:hover, .keep-dropzone.dragover {
  border-color: var(--primary);
  background: var(--primary-light);
  transform: scale(1.005);
}

/* Parsed Listing Item Card in Modal */
.keep-listing-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 12px 14px;
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-md);
  transition: all 180ms ease;
}
.keep-listing-card.selected {
  border-color: var(--primary);
  box-shadow: 0 0 0 1px var(--primary);
  background: var(--primary-light);
}
.keep-card-top {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}
.keep-card-checkbox {
  margin-top: 3px;
  width: 16px;
  height: 16px;
  accent-color: var(--primary);
  cursor: pointer;
}
.keep-card-info {
  flex: 1;
}
.keep-card-title-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.keep-card-title {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-main);
}
.keep-card-price {
  font-size: 13px;
  font-weight: 800;
  color: var(--card-price);
}
.keep-spec-chips {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 6px;
}
.keep-spec-chip {
  padding: 2px 7px;
  border-radius: var(--radius-sm);
  background: var(--surface-inset);
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
}
.keep-thumb-strip {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding-top: 4px;
}
.keep-thumb-img {
  width: 50px;
  height: 40px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  border: 1px solid var(--surface-border);
}

/* ══════════════════════════════════════════════════════════════════
   PHASE 1: BUTTON MORPHING COPY FEEDBACK (Emil Kowalski Craft)
   ══════════════════════════════════════════════════════════════════ */
.btn-morph-copied {
  background-color: #059669 !important;
  border-color: #059669 !important;
  color: #FFFFFF !important;
  transform: scale(1.03) !important;
  box-shadow: 0 4px 16px rgba(5, 150, 105, 0.4) !important;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.btn-morph-copied svg {
  stroke: #FFFFFF !important;
  animation: popCheck 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275) both;
}

@keyframes popCheck {
  0% { transform: scale(0.6) rotate(-15deg); opacity: 0; }
  70% { transform: scale(1.2) rotate(4deg); }
  100% { transform: scale(1) rotate(0deg); opacity: 1; }
}

/* ══════════════════════════════════════════════════════════════════
   PHASE 1: FULLSCREEN INTERACTIVE IMAGE LIGHTBOX (Apple WWDC Fluid)
   ══════════════════════════════════════════════════════════════════ */
.lightbox-overlay {
  position: fixed;
  inset: 0;
  background: rgba(6, 9, 15, 0.94);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  z-index: 10000;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 16px 20px;
  box-sizing: border-box;
  animation: lightboxFadeIn 0.24s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  user-select: none;
}

@keyframes lightboxFadeIn {
  from { opacity: 0; transform: scale(0.97); }
  to { opacity: 1; transform: scale(1); }
}

.lightbox-topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 10;
  padding-bottom: 8px;
}

.lightbox-info {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.lightbox-counter {
  background: rgba(255, 255, 255, 0.15);
  color: #FFFFFF;
  font-size: 13px;
  font-weight: 800;
  font-family: var(--font-mono);
  padding: 4px 12px;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  flex-shrink: 0;
}

.lightbox-title {
  color: rgba(255, 255, 255, 0.9);
  font-size: 14.5px;
  font-weight: 700;
  max-width: 480px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lightbox-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.lightbox-btn {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.18s cubic-bezier(0.16, 1, 0.3, 1);
}

.lightbox-btn:hover {
  background: rgba(255, 255, 255, 0.24);
  transform: scale(1.08);
}

.lightbox-btn:active {
  transform: scale(0.92);
}

.lightbox-viewport {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
  min-height: 0;
  margin: 10px 0;
  gap: 12px;
}

.lightbox-nav-btn {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  backdrop-filter: blur(10px);
  flex-shrink: 0;
}

.lightbox-nav-btn:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: scale(1.1);
}

.lightbox-nav-btn:active {
  transform: scale(0.92);
}

.lightbox-img-wrap {
  flex: 1;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  cursor: zoom-in;
}

.lightbox-active-img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border-radius: 12px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.7);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.18s ease;
}

.lightbox-active-img.zoomed {
  transform: scale(1.85);
  cursor: zoom-out;
}

.lightbox-bottom-strip {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  overflow-x: auto;
  padding: 8px 0 4px;
  max-width: 100%;
}

.lightbox-thumb-item {
  width: 58px;
  height: 58px;
  border-radius: 8px;
  overflow: hidden;
  border: 2px solid transparent;
  cursor: pointer;
  opacity: 0.5;
  transition: all 0.18s cubic-bezier(0.16, 1, 0.3, 1);
  flex-shrink: 0;
}

.lightbox-thumb-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.lightbox-thumb-item.active {
  opacity: 1;
  border-color: var(--primary);
  transform: scale(1.12);
  box-shadow: 0 4px 16px rgba(0, 158, 188, 0.5);
}

.lightbox-thumb-item:hover {
  opacity: 0.9;
}

@media (max-width: 768px) {
  .lightbox-overlay {
    padding: 12px;
  }
  .lightbox-nav-btn {
    width: 38px;
    height: 38px;
  }
  .lightbox-thumb-item {
    width: 46px;
    height: 46px;
  }
}

/* ══════════════════════════════════════════════════════════════════
   PHASE 2.4: LIVE PRICE FORMATTER BADGE (Zero-Error Input)
   ══════════════════════════════════════════════════════════════════ */
.price-preview-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(0, 158, 188, 0.08);
  border: 1px solid rgba(0, 158, 188, 0.28);
  border-radius: var(--radius-sm);
  padding: 5px 12px;
  margin-top: 6px;
  animation: priceBadgePop 0.2s cubic-bezier(0.16, 1, 0.3, 1) both;
}

[data-theme="dark"] .price-preview-badge {
  background: rgba(0, 158, 188, 0.14);
  border-color: rgba(56, 189, 248, 0.35);
}

.preview-badge-pill {
  font-weight: 800;
  color: var(--primary);
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.preview-badge-sub {
  font-size: 11.5px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-weight: 600;
}

@keyframes priceBadgePop {
  0% { opacity: 0; transform: translateY(-4px) scale(0.95); }
  100% { opacity: 1; transform: translateY(0) scale(1); }
}

/* ══════════════════════════════════════════════════════════════════
   STATUS TRANSAKSI SEGMENTED CONTROL (JUAL / SEWA / JUAL SEWA)
   ══════════════════════════════════════════════════════════════════ */
.status-segmented-control {
  display: flex;
  background-color: var(--surface-inset);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-md);
  padding: 4px;
  gap: 4px;
}

.status-seg-btn {
  flex: 1;
  padding: 8px 12px;
  font-size: 13px;
  font-weight: 700;
  border-radius: calc(var(--radius-md) - 2px);
  border: none;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.18s cubic-bezier(0.16, 1, 0.3, 1);
  text-align: center;
  user-select: none;
}

.status-seg-btn:hover {
  color: var(--text-main);
  background: var(--surface-hover);
}

.status-seg-btn.active {
  background: var(--text-main);
  color: var(--bg);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.status-seg-btn:active {
  transform: scale(0.97);
}

/* Gear Button for Advanced Filter */
.filter-gear-btn {
  position: relative;
  width: 40px;
  height: 38px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-md);
  flex-shrink: 0;
}

.filter-gear-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
}

.advanced-filter-active-dot {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--primary);
  box-shadow: 0 0 6px rgba(0, 158, 188, 0.8);
}

/* ══════════════════════════════════════════════════════════════════
   ADVANCED FILTER & SORTING MODAL PANEL
   ══════════════════════════════════════════════════════════════════ */
.filter-group-block {
  margin-bottom: 18px;
}

.filter-group-label {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 8px;
  display: block;
}

.filter-exact-hint {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
}

.filter-pill-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.filter-pill-btn {
  padding: 6px 13px;
  font-size: 12.5px;
  font-weight: 600;
  border-radius: var(--radius-full);
  background-color: var(--surface-inset);
  border: 1px solid var(--surface-border);
  color: var(--text-body);
  cursor: pointer;
  transition: all 0.16s cubic-bezier(0.16, 1, 0.3, 1);
  user-select: none;
}

.filter-pill-btn:hover {
  background-color: var(--surface-hover);
  color: var(--text-main);
  border-color: var(--text-dim);
}

.filter-pill-btn.active {
  background-color: var(--text-main);
  color: var(--bg);
  border-color: var(--text-main);
  font-weight: 700;
}

.filter-pill-btn:active {
  transform: scale(0.96);
}

/* Empty State Styling */
.empty-catalog-state {
  grid-column: 1 / -1;
  text-align: center;
  padding: 50px 20px;
  background: var(--surface-card);
  border: 1px dashed var(--surface-border);
  border-radius: var(--radius-lg);
  margin: 10px 0;
}

.empty-state-title {
  font-size: 16px;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 6px;
}

.empty-state-desc {
  font-size: 13px;
  color: var(--text-muted);
  max-width: 400px;
  margin: 0 auto 16px;
}

/* ══════════════════════════════════════════════════════════════════
   SMART METRIC CALCULATOR (Harga / m² Tanah & Bangunan)
   ══════════════════════════════════════════════════════════════════ */
.smart-metric-card {
  background: linear-gradient(135deg, rgba(0, 158, 188, 0.06) 0%, rgba(16, 185, 129, 0.06) 100%);
  border: 1.5px solid rgba(0, 158, 188, 0.25);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  margin-bottom: 18px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.03);
}

[data-theme="dark"] .smart-metric-card {
  background: linear-gradient(135deg, rgba(0, 158, 188, 0.12) 0%, rgba(16, 185, 129, 0.08) 100%);
  border-color: rgba(0, 158, 188, 0.38);
}

.smart-metric-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  flex-wrap: wrap;
  gap: 6px;
}

.smart-metric-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(0, 158, 188, 0.14);
  color: var(--primary);
  font-size: 11.5px;
  font-weight: 800;
  padding: 3px 9px;
  border-radius: var(--radius-full);
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

.smart-metric-sub {
  font-size: 11.5px;
  color: var(--text-muted);
  font-weight: 600;
}

.smart-metric-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 10px;
}

.metric-item-box {
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.metric-item-box:hover {
  transform: translateY(-2px);
  border-color: var(--primary);
}

.metric-item-top {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--primary);
  font-size: 11px;
  font-weight: 700;
  margin-bottom: 4px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.metric-val {
  font-size: 15px;
  font-weight: 800;
  color: var(--text-main);
  letter-spacing: -0.2px;
  line-height: 1.2;
}

.metric-sub {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 3px;
}

/* ══════════════════════════════════════════════════════════════════
   WIZARD LIVE SPEC EXTRACTION CHIPS
   ══════════════════════════════════════════════════════════════════ */
.wizard-live-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: var(--surface);
  border: 1px solid var(--surface-border);
  color: var(--text-main);
  font-size: 12px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
  animation: chipFadeIn 0.22s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes chipFadeIn {
  from {
    opacity: 0;
    transform: scale(0.92);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.wizard-live-chip svg {
  color: var(--primary);
  flex-shrink: 0;
}

.wizard-live-chip strong {
  font-weight: 700;
  color: var(--primary);
}

/* ══════════════════════════════════════════════════════════════════
   FLOATING BACKGROUND TASK ACTIVITY PILL (APPLE FLUID MOTION)
   ══════════════════════════════════════════════════════════════════ */
.keep-bg-task-pill {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 1050;
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--surface);
  border: 1.5px solid var(--primary);
  border-radius: var(--radius-full);
  padding: 8px 14px 8px 12px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.18), 0 0 0 1px rgba(99, 102, 241, 0.15);
  cursor: pointer;
  max-width: 380px;
  width: calc(100vw - 32px);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.28s ease, background 0.2s ease;
  animation: floatPillSlideUp 0.35s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes floatPillSlideUp {
  from {
    opacity: 0;
    transform: translateY(24px) scale(0.94);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.keep-bg-task-pill:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.24), 0 0 0 1.5px var(--primary);
}

.bg-task-icon-pulse {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(245, 158, 11, 0.15);
  color: #D97706;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  animation: taskPulse 1.8s infinite ease-in-out;
}

@keyframes taskPulse {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.4);
  }
  50% {
    transform: scale(1.08);
    box-shadow: 0 0 0 6px rgba(245, 158, 11, 0);
  }
}

.bg-task-details {
  flex: 1;
  min-width: 0;
}

.bg-task-title-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-bottom: 5px;
}

.bg-task-title {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.bg-task-pct {
  font-size: 11.5px;
  font-weight: 800;
  color: var(--primary);
  flex-shrink: 0;
}

.bg-task-progress-track {
  width: 100%;
  height: 5px;
  background: var(--surface-border);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.bg-task-progress-bar {
  height: 100%;
  background: linear-gradient(90deg, #F59E0B, var(--primary));
  border-radius: var(--radius-full);
  transition: width 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

.bg-task-btn-maximize {
  background: var(--surface-inset);
  border: 1px solid var(--surface-border);
  color: var(--text-muted);
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: all 0.18s ease;
}

.bg-task-btn-maximize:hover {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

@media (max-width: 640px) {
  .keep-bg-task-pill {
    bottom: 16px;
    right: 16px;
    left: 16px;
    width: auto;
    max-width: none;
  }
}

/* ══════════════════════════════════════════════════════════════════
   UX PRO MAX - ACTION BAR REFACTOR
   ══════════════════════════════════════════════════════════════════ */
.action-bar-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  overflow-x: auto;
  flex-wrap: nowrap;
  padding-bottom: 2px;
}
.action-bar-dropdown {
  flex: 1 1 auto;
  min-width: 90px;
}
.action-bar-dropdown .select-filter {
  width: 100%;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding-right: 22px;
  padding-left: 8px;
  font-size: 13px;
}
.action-bar-search {
  flex: 1;
  min-width: 0;
  margin-bottom: 0 !important;
}
.action-bar-filter-btn {
  position: relative;
  flex-shrink: 0;
}
.advanced-filter-badge {
  position: absolute;
  top: -6px;
  right: -6px;
  background-color: #10b981;
  color: white;
  font-size: 10px;
  font-weight: 800;
  border-radius: 99px;
  min-width: 18px;
  height: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  border: 1.5px solid #fff;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  animation: badgePop 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}
@keyframes badgePop {
  0% { transform: scale(0); }
  100% { transform: scale(1); }
}

/* Emil Kowalski Craft - Instant Touchdown Tactile Feedback */
.cat-pill {
  transition: transform 140ms cubic-bezier(0.2, 0, 0, 1), background-color 180ms ease, color 180ms ease;
  will-change: transform;
}
.cat-pill:active {
  transform: scale(0.96);
}
.filter-pill-btn {
  transition: transform 140ms cubic-bezier(0.2, 0, 0, 1), background-color 180ms ease, color 180ms ease, border-color 180ms ease;
  will-change: transform;
}
.filter-pill-btn:active {
  transform: scale(0.96);
}

