/* ==========================================================================
   BizForge AI - Ultra-Premium Design System & Mobile Simulator Styles
   ========================================================================== */

:root {
  --font-main: 'Pretendard', -apple-system, BlinkMacSystemFont, system-ui, Roboto, sans-serif;

  /* Theme Palette */
  --bg-dark: #0b0f19;
  --bg-card: rgba(18, 24, 38, 0.75);
  --bg-card-hover: rgba(28, 36, 56, 0.85);
  --bg-elevated: #1a2234;
  --border-color: rgba(255, 255, 255, 0.08);
  --border-highlight: rgba(129, 140, 248, 0.3);

  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;

  /* Accent Gradients & Neons */
  --accent-primary: #6366f1;
  --accent-primary-hover: #4f46e5;
  --accent-gradient: linear-gradient(135deg, #6366f1 0%, #a855f7 50%, #ec4899 100%);
  --agent-glow: 0 8px 32px rgba(99, 102, 241, 0.25);

  --success: #10b981;
  --warning: #f59e0b;
  --danger: #ef4444;

  /* Mobile App Theme (Dynamic per store) */
  --store-theme: #4f46e5;
  --store-accent: #818cf8;

  /* Device Dimensions */
  --phone-width: 380px;
  --phone-height: 780px;
  --phone-radius: 48px;
}

/* Reset & Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-main);
  background-color: var(--bg-dark);
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

/* Background Atmospheric Glows */
.bg-ambient-lights {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.light-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.18;
}

.orb-1 {
  width: 500px;
  height: 500px;
  top: -100px;
  left: 10%;
  background: #6366f1;
}

.orb-2 {
  width: 450px;
  height: 450px;
  bottom: -50px;
  right: 15%;
  background: #ec4899;
}

.orb-3 {
  width: 350px;
  height: 350px;
  top: 40%;
  left: 45%;
  background: #06b6d4;
  opacity: 0.12;
}

/* App Header */
.global-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(11, 15, 25, 0.85);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-color);
  padding: 14px 28px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.header-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-icon-box {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: var(--accent-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.4);
}

.brand-title {
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, #ffffff 30%, #94a3b8 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.brand-subtitle {
  font-size: 0.75rem;
  color: #38bdf8;
  font-weight: 600;
  background: rgba(56, 189, 248, 0.1);
  padding: 2px 8px;
  border-radius: 20px;
  border: 1px solid rgba(56, 189, 248, 0.2);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.btn-header-action {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s ease;
}

.btn-header-action:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.2);
}

.btn-header-primary {
  background: var(--accent-gradient);
  border: none;
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.35);
}

.btn-header-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(99, 102, 241, 0.45);
}

/* Main Studio Layout */
.studio-container {
  position: relative;
  z-index: 10;
  max-width: 1480px;
  margin: 0 auto;
  padding: 24px;
  display: grid;
  grid-template-columns: 1fr 460px;
  gap: 32px;
  align-items: start;
}

@media (max-width: 1100px) {
  .studio-container {
    grid-template-columns: 1fr;
    justify-items: center;
  }
}

/* ==========================================================================
   Left Panel: Agent Control Studio
   ========================================================================== */

.agent-studio-panel {
  display: flex;
  flex-direction: column;
  gap: 24px;
  width: 100%;
}

.glass-card {
  background: var(--bg-card);
  backdrop-filter: blur(20px);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  padding: 24px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
  transition: border-color 0.2s ease;
}

.glass-card:hover {
  border-color: rgba(255, 255, 255, 0.12);
}

.card-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.heading-title-group {
  display: flex;
  align-items: center;
  gap: 10px;
}

.heading-icon {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: rgba(99, 102, 241, 0.15);
  color: #818cf8;
  display: flex;
  align-items: center;
  justify-content: center;
}

.card-heading h2 {
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.card-heading .badge-hint {
  font-size: 0.72rem;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.05);
  padding: 3px 8px;
  border-radius: 6px;
}

/* Presets Grid */
.presets-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}

.preset-chip-btn {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-color);
  border-radius: 14px;
  padding: 12px 14px;
  text-align: left;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text-primary);
  transition: all 0.2s ease;
}

.preset-chip-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.18);
  transform: translateY(-2px);
}

.preset-chip-btn.active {
  background: rgba(99, 102, 241, 0.15);
  border-color: var(--accent-primary);
  box-shadow: 0 0 16px rgba(99, 102, 241, 0.3);
}

.preset-icon {
  font-size: 1.4rem;
}

.preset-info {
  display: flex;
  flex-direction: column;
}

.preset-name {
  font-size: 0.85rem;
  font-weight: 600;
}

.preset-sub {
  font-size: 0.7rem;
  color: var(--text-muted);
}

.preset-chip-btn {
  position: relative;
}

.add-new-preset-btn {
  border: 1px dashed rgba(129, 140, 248, 0.5) !important;
  background: rgba(99, 102, 241, 0.06) !important;
}

.add-new-preset-btn:hover {
  background: rgba(99, 102, 241, 0.16) !important;
  border-color: rgba(129, 140, 248, 0.8) !important;
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(99, 102, 241, 0.25);
}

.custom-preset {
  border-color: rgba(16, 185, 129, 0.3);
}

.badge-custom-tag {
  background: rgba(16, 185, 129, 0.18);
  color: #34d399;
  font-size: 0.58rem;
  padding: 1px 5px;
  border-radius: 4px;
  font-weight: 700;
  display: inline-block;
}

.btn-delete-preset {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
  cursor: pointer;
  border: 1px solid rgba(239, 68, 68, 0.3);
  transition: all 0.15s ease;
}

.btn-delete-preset:hover {
  background: #ef4444;
  color: #ffffff;
  transform: scale(1.1);
}

.template-pill-btn {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #e2e8f0;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 0.76rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.template-pill-btn:hover {
  background: rgba(99, 102, 241, 0.25);
  border-color: #818cf8;
  color: #ffffff;
  transform: translateY(-1px);
}

/* Input Form Fields */
.form-grid-two {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 16px;
}

@media (max-width: 640px) {
  .form-grid-two {
    grid-template-columns: 1fr;
  }
}

.form-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-field label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.form-input-studio, .form-textarea-studio {
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 10px 14px;
  color: var(--text-primary);
  font-size: 0.88rem;
  font-family: inherit;
  transition: all 0.2s ease;
}

.form-input-studio:focus, .form-textarea-studio:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2);
}

.form-textarea-studio {
  min-height: 72px;
  resize: vertical;
}

/* Feature Checkbox Chips */
.module-chips-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}

.module-checkbox-label {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 0.78rem;
  cursor: pointer;
  user-select: none;
  transition: all 0.2s ease;
}

.module-checkbox-label:has(input:checked) {
  background: rgba(16, 185, 129, 0.12);
  border-color: rgba(16, 185, 129, 0.4);
  color: #34d399;
}

/* Theme Colors Palette */
.color-swatches-group {
  display: flex;
  gap: 10px;
  margin-top: 8px;
}

.color-swatch-btn {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all 0.2s ease;
}

.color-swatch-btn:hover {
  transform: scale(1.15);
}

.color-swatch-btn.active {
  border-color: #ffffff;
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

/* Agent Action Trigger */
.agent-generate-cta-box {
  margin-top: 24px;
}

.btn-agent-launch {
  width: 100%;
  padding: 16px 24px;
  background: var(--accent-gradient);
  border: none;
  border-radius: 14px;
  color: #ffffff;
  font-size: 1rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  cursor: pointer;
  box-shadow: 0 8px 28px rgba(99, 102, 241, 0.4);
  transition: all 0.25s ease;
}

.btn-agent-launch:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 34px rgba(99, 102, 241, 0.55);
}

.btn-agent-launch:active {
  transform: translateY(0);
}

/* Agent Thinking / Pipeline Progress Bar */
.agent-pipeline-box {
  background: rgba(15, 23, 42, 0.9);
  border: 1px solid var(--border-highlight);
  border-radius: 16px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.pipeline-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.pipeline-title {
  font-size: 0.88rem;
  font-weight: 700;
  color: #818cf8;
  display: flex;
  align-items: center;
  gap: 8px;
}

.pipeline-progress-track {
  width: 100%;
  height: 8px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  overflow: hidden;
}

.pipeline-progress-fill {
  height: 100%;
  width: 0%;
  background: var(--accent-gradient);
  border-radius: 10px;
  transition: width 0.3s ease;
}

.pipeline-step-desc {
  font-size: 0.78rem;
  color: var(--text-secondary);
}

/* Diagnosis Report Card */
.diagnosis-report-card {
  border-left: 4px solid var(--accent-primary);
}

.report-points-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 12px;
}

.report-point-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.84rem;
  color: var(--text-secondary);
  line-height: 1.45;
}

.point-check {
  color: #34d399;
  font-weight: bold;
}

/* Export & QR Sharing Bar */
.export-sharing-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

@media (max-width: 600px) {
  .export-sharing-grid {
    grid-template-columns: 1fr;
  }
}

.btn-export-option {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--text-primary);
  text-align: left;
  transition: all 0.2s ease;
}

.btn-export-option:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

.export-opt-icon {
  font-size: 1.4rem;
}

.export-opt-text h4 {
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 2px;
}

.export-opt-text p {
  font-size: 0.72rem;
  color: var(--text-muted);
}

/* ==========================================================================
   Right Panel: Smartphone Simulator Frame
   ========================================================================== */

.phone-simulator-column {
  position: sticky;
  top: 90px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  width: 100%;
}

.simulator-toolbar {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(18, 24, 38, 0.85);
  backdrop-filter: blur(12px);
  padding: 6px 12px;
  border-radius: 30px;
  border: 1px solid var(--border-color);
}

.sim-btn-tool {
  background: transparent;
  border: none;
  color: var(--text-muted);
  padding: 6px 10px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 5px;
  transition: all 0.2s ease;
}

.sim-btn-tool:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.06);
}

.sim-btn-tool.active {
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.12);
}

/* The Realistic Smartphone Mockup Shell */
.phone-bezel-frame {
  width: var(--phone-width);
  height: var(--phone-height);
  background: #0f141f;
  border-radius: var(--phone-radius);
  border: 12px solid #1e2638;
  box-shadow: 
    0 0 0 2px rgba(255, 255, 255, 0.1),
    0 25px 60px -10px rgba(0, 0, 0, 0.8),
    0 0 50px rgba(99, 102, 241, 0.15);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

/* Side button accents */
.phone-bezel-frame::before {
  content: '';
  position: absolute;
  top: 110px;
  left: -15px;
  width: 3px;
  height: 50px;
  background: #2a344d;
  border-radius: 3px 0 0 3px;
}

.phone-bezel-frame::after {
  content: '';
  position: absolute;
  top: 175px;
  left: -15px;
  width: 3px;
  height: 50px;
  background: #2a344d;
  border-radius: 3px 0 0 3px;
}

/* ==========================================================================
   Mobile Web App UI Inside Smartphone Screen
   ========================================================================== */

.phone-viewport-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  background: #0d121d;
  color: #f1f5f9;
  height: 100%;
  position: relative;
  overflow: hidden;
  user-select: none;
}

/* Phone Status Bar */
.phone-status-bar {
  height: 44px;
  padding: 0 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.74rem;
  font-weight: 600;
  z-index: 30;
  background: rgba(13, 18, 29, 0.8);
  backdrop-filter: blur(10px);
}

.phone-time {
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.01em;
}

.phone-dynamic-island {
  width: 80px;
  height: 18px;
  background: #000000;
  border-radius: 12px;
}

.phone-status-icons {
  display: flex;
  align-items: center;
  gap: 6px;
}

.offline-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
  padding: 2px 6px;
  border-radius: 10px;
  font-size: 0.65rem;
  font-weight: 700;
}

/* App Header */
.phone-app-header {
  padding: 8px 16px 12px;
  background: rgba(13, 18, 29, 0.95);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  z-index: 25;
}

.header-main {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.header-owner-badge {
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--store-accent);
  background: rgba(129, 140, 248, 0.12);
  padding: 2px 7px;
  border-radius: 6px;
  display: inline-block;
  margin-bottom: 2px;
}

.header-store-name {
  font-size: 1.1rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 250px;
}

.header-quick-action-btn {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--store-theme);
  border: none;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.15s ease;
}

.header-quick-action-btn:active {
  transform: scale(0.92);
}

/* Main Content Area */
.phone-content-area {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  scrollbar-width: none;
}

.phone-content-area::-webkit-scrollbar {
  display: none;
}

/* Quick 1-touch Preset Bar */
.quick-preset-bar {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.quick-title {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-secondary);
}

.quick-buttons-scroll {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 4px;
  scrollbar-width: none;
}

.quick-buttons-scroll::-webkit-scrollbar {
  display: none;
}

.quick-btn {
  white-space: nowrap;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-primary);
  padding: 7px 12px;
  border-radius: 20px;
  font-size: 0.76rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.quick-btn:active {
  background: var(--store-theme);
  color: #fff;
  transform: scale(0.96);
}

/* Search Box */
.search-box {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 8px 12px;
}

.search-box input {
  flex: 1;
  background: transparent;
  border: none;
  color: #ffffff;
  font-size: 0.82rem;
  outline: none;
}

.btn-clear-search {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
}

/* Category Pills Bar */
.category-pills-bar {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  scrollbar-width: none;
  padding-bottom: 2px;
}

.cat-pill {
  white-space: nowrap;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text-secondary);
  padding: 5px 11px;
  border-radius: 14px;
  font-size: 0.72rem;
  font-weight: 600;
  cursor: pointer;
}

.cat-pill.active {
  background: rgba(255, 255, 255, 0.15);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.3);
}

/* POS Items Grid */
.items-pos-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.item-pos-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 14px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 110px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.item-pos-card:active {
  transform: scale(0.97);
  background: rgba(255, 255, 255, 0.08);
}

.item-pos-card.selected {
  border-color: var(--store-accent);
  background: rgba(129, 140, 248, 0.08);
}

.item-card-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.65rem;
}

.item-card-cat {
  color: var(--text-muted);
}

.badge-stock {
  color: var(--text-secondary);
}

.badge-low-stock {
  color: #f87171;
  font-weight: 700;
}

.item-card-name {
  font-size: 0.85rem;
  font-weight: 700;
  line-height: 1.25;
  margin: 6px 0;
}

.item-card-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.item-card-price {
  font-size: 0.82rem;
  font-weight: 800;
  color: #38bdf8;
}

.btn-add-circle {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  border: none;
  color: #fff;
  font-size: 0.8rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cart-qty-badge {
  background: var(--store-theme);
  width: 100%;
  height: 100%;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
}

/* Floating Bottom Cart Bar */
.pos-cart-bar {
  position: absolute;
  bottom: 66px;
  left: 12px;
  right: 12px;
  background: rgba(20, 26, 40, 0.96);
  border: 1px solid var(--border-highlight);
  border-radius: 16px;
  padding: 10px 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 40;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(16px);
}

.cart-info {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
}

.cart-badge {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--store-theme);
  color: #fff;
  font-weight: 800;
  font-size: 0.82rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cart-amount-box {
  display: flex;
  flex-direction: column;
}

.cart-label {
  font-size: 0.65rem;
  color: var(--text-muted);
}

.cart-total {
  font-size: 0.95rem;
  font-weight: 800;
  color: #f8fafc;
}

.cart-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-cart-clear {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 6px;
}

.btn-cart-checkout {
  background: var(--store-theme);
  border: none;
  color: #ffffff;
  padding: 8px 14px;
  border-radius: 10px;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
}

/* Phone Bottom Navigation */
.phone-bottom-nav {
  height: 60px;
  background: rgba(13, 18, 29, 0.95);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  justify-content: space-around;
  align-items: center;
  z-index: 35;
}

.nav-tab {
  background: transparent;
  border: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.15s ease;
}

.nav-tab.active {
  color: var(--store-accent);
}

.nav-tab:active {
  transform: scale(0.9);
}

.nav-label {
  font-size: 0.65rem;
  font-weight: 600;
}

/* Smartphone Home Indicator Bar */
.phone-home-indicator {
  height: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(13, 18, 29, 0.95);
}

.phone-home-indicator::after {
  content: '';
  width: 120px;
  height: 4px;
  background: rgba(255, 255, 255, 0.3);
  border-radius: 4px;
}

/* Inventory Cards */
.inventory-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.inventory-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 14px;
  padding: 12px;
}

.inventory-card.low-stock {
  border-color: rgba(239, 68, 68, 0.4);
  background: rgba(239, 68, 68, 0.05);
}

.inv-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.72rem;
  color: var(--text-muted);
}

.inv-name {
  font-size: 0.9rem;
  font-weight: 700;
  margin: 4px 0 8px;
}

.inv-pricing {
  font-size: 0.78rem;
  display: flex;
  gap: 12px;
  color: var(--text-secondary);
}

.inv-stock-control {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 10px;
  padding-top: 8px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.stepper {
  display: flex;
  align-items: center;
  gap: 10px;
}

.btn-step {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  border: none;
  color: #fff;
  font-weight: 700;
  cursor: pointer;
}

/* Customer / Reservation Cards */
.customer-cards-list, .reservation-timeline {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.cust-card, .res-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 14px;
  padding: 12px;
}

.cust-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.cust-name {
  font-size: 0.9rem;
  font-weight: 700;
}

.cust-phone {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.cust-stamps-badge {
  font-size: 0.72rem;
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
  padding: 3px 8px;
  border-radius: 12px;
  font-weight: 700;
}

.cust-metrics {
  display: flex;
  gap: 12px;
  font-size: 0.74rem;
  color: var(--text-secondary);
  margin: 6px 0;
}

.cust-notes {
  background: rgba(0, 0, 0, 0.25);
  border-radius: 8px;
  padding: 6px 8px;
  font-size: 0.72rem;
  color: #cbd5e1;
  display: flex;
  gap: 6px;
  margin-bottom: 8px;
}

.cust-actions {
  display: flex;
  gap: 6px;
}

.btn-cust-action {
  flex: 1;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  padding: 6px;
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--text-primary);
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}

/* Closing Tab Hero & Metrics */
.closing-summary-hero {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.2) 0%, rgba(168, 85, 247, 0.15) 100%);
  border: 1px solid var(--border-highlight);
  border-radius: 18px;
  padding: 18px;
  text-align: center;
}

.hero-date {
  font-size: 0.72rem;
  color: #cbd5e1;
  font-weight: 600;
}

.hero-sales {
  font-size: 1.8rem;
  font-weight: 800;
  margin: 4px 0 8px;
  letter-spacing: -0.02em;
}

.hero-submetrics {
  display: flex;
  justify-content: center;
  gap: 10px;
  font-size: 0.74rem;
  color: var(--text-secondary);
}

.metric-tiles-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.metric-tile {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 12px;
  padding: 12px;
  display: flex;
  flex-direction: column;
}

.tile-label {
  font-size: 0.68rem;
  color: var(--text-muted);
}

.tile-val {
  font-size: 1.05rem;
  font-weight: 700;
}

.tile-val.expense {
  color: #f87171;
}

.tile-val.profit {
  color: #34d399;
}

.section-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 14px;
  padding: 14px;
}

.card-title {
  font-size: 0.82rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.card-desc {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-bottom: 12px;
}

/* Modals inside Phone */
.phone-modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  z-index: 100;
  display: flex;
  align-items: flex-end;
}

.phone-modal-overlay.hidden,
.hidden,
dialog.hidden {
  display: none !important;
}

/* Global Dialog Modals (Outside Phone Simulator) */
.global-modal-dialog {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  border: none;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  padding: 0;
  margin: 0;
}

.global-modal-dialog.hidden {
  display: none !important;
}

.modal-box {
  width: 100%;
  background: #141b2a;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 24px 24px 0 0;
  padding: 20px;
  max-height: 85%;
  overflow-y: auto;
  box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.8);
}

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

.btn-close-modal {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 1.1rem;
  cursor: pointer;
}

.modal-footer {
  display: flex;
  gap: 10px;
  margin-top: 20px;
}

.btn-modal-cancel {
  flex: 1;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  padding: 10px;
  border-radius: 10px;
  cursor: pointer;
  font-weight: 600;
}

.btn-modal-confirm {
  flex: 2;
  background: var(--store-theme);
  border: none;
  color: #fff;
  padding: 10px;
  border-radius: 10px;
  cursor: pointer;
  font-weight: 700;
}

/* Receipt Paper Styling */
.receipt-paper {
  background: #ffffff;
  color: #1e293b;
  border-radius: 12px;
  padding: 18px 14px;
  font-family: 'Courier New', Courier, monospace;
}

.receipt-header {
  text-align: center;
}

.receipt-header h3 {
  font-size: 1.1rem;
  margin-bottom: 2px;
}

.receipt-sub {
  font-size: 0.75rem;
  color: #64748b;
}

.receipt-meta {
  display: flex;
  flex-direction: column;
  font-size: 0.72rem;
  margin-top: 8px;
  text-align: left;
}

.receipt-divider {
  text-align: center;
  color: #94a3b8;
  letter-spacing: -2px;
  margin: 6px 0;
}

.receipt-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.8rem;
  margin: 3px 0;
}

.receipt-total-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.95rem;
  font-weight: bold;
}

.receipt-footer {
  text-align: center;
  font-size: 0.68rem;
  color: #64748b;
  margin-top: 10px;
}

/* Phone Toast */
.phone-toast {
  position: absolute;
  top: 60px;
  left: 20px;
  right: 20px;
  background: rgba(15, 23, 42, 0.95);
  border: 1px solid var(--store-accent);
  color: #ffffff;
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 0.78rem;
  font-weight: 600;
  text-align: center;
  z-index: 999;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
  opacity: 0;
  transform: translateY(-10px);
  transition: all 0.25s ease;
  pointer-events: none;
}

.phone-toast.show {
  opacity: 1;
  transform: translateY(0);
}

/* Utility Animations */
.animate-scale-up {
  animation: scaleUp 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes scaleUp {
  from { transform: scale(0.95); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

.animate-slide-up {
  animation: slideUp 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slideUp {
  from { transform: translateY(100%); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

/* Buttons in Settings */
.btn-action-outline {
  width: 100%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-primary);
  padding: 10px 12px;
  border-radius: 10px;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  text-align: center;
}

.btn-action-outline:active {
  background: rgba(255, 255, 255, 0.12);
}

.button-group-vertical {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.btn-primary-full {
  width: 100%;
  background: var(--store-theme);
  border: none;
  color: #ffffff;
  padding: 12px;
  border-radius: 12px;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  margin-top: 8px;
}

.btn-secondary-full {
  width: 100%;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #ffffff;
  padding: 12px;
  border-radius: 12px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
}

.btn-primary-sm {
  background: var(--store-theme);
  border: none;
  color: #ffffff;
  padding: 6px 12px;
  border-radius: 8px;
  font-size: 0.74rem;
  font-weight: 700;
  cursor: pointer;
}

/* Pay row breakdown */
.pay-breakdown-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pay-row {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.76rem;
}

.pay-name {
  width: 50px;
  color: var(--text-secondary);
}

.pay-bar-wrapper {
  flex: 1;
  height: 6px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 6px;
  overflow: hidden;
}

.pay-bar {
  height: 100%;
  background: var(--store-accent);
}

.pay-amount {
  width: 80px;
  text-align: right;
  font-weight: 700;
}

/* Top items */
.top-items-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.top-item-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
}

.top-rank {
  width: 18px;
  height: 18px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.68rem;
  font-weight: bold;
}

.top-rank.rank-1 { background: #fbbf24; color: #000; }
.top-rank.rank-2 { background: #cbd5e1; color: #000; }
.top-rank.rank-3 { background: #b45309; color: #fff; }

.top-name { flex: 1; }
.top-count { font-weight: 700; color: #38bdf8; }

/* Serverless status card */
.status-card-serverless {
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.25);
  border-radius: 14px;
  padding: 14px;
}

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

.badge-serverless-active {
  display: flex;
  align-items: center;
  gap: 4px;
  color: #34d399;
  font-size: 0.75rem;
  font-weight: 700;
}

.storage-engine {
  font-size: 0.68rem;
  color: var(--text-muted);
}

.serverless-desc {
  font-size: 0.72rem;
  color: #cbd5e1;
  line-height: 1.45;
  margin-bottom: 10px;
}

.serverless-counters {
  display: flex;
  justify-content: space-between;
  font-size: 0.72rem;
  color: var(--text-secondary);
  border-top: 1px solid rgba(16, 185, 129, 0.15);
  padding-top: 8px;
}

/* Guide steps */
.guide-steps {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.guide-step {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 0.72rem;
  color: var(--text-secondary);
}

.step-num {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  padding: 2px 6px;
  border-radius: 4px;
  font-weight: bold;
}

/* Community IT Cooperative & Disclaimer Styles */
.community-info-card {
  background: rgba(99, 102, 241, 0.06);
  border: 1px solid rgba(129, 140, 248, 0.25);
  border-radius: 14px;
  padding: 14px;
}

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

.community-org-name {
  font-size: 0.84rem;
  font-weight: 700;
  color: #a5b4fc;
}

.community-purpose-text {
  font-size: 0.72rem;
  color: #cbd5e1;
  line-height: 1.5;
  margin-bottom: 10px;
}

.disclaimer-card {
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 10px 12px;
  margin-bottom: 12px;
}

.disclaimer-title {
  font-size: 0.7rem;
  font-weight: 700;
  color: #94a3b8;
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.disclaimer-content {
  font-size: 0.66rem;
  color: #94a3b8;
  line-height: 1.45;
}

.community-contact-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.contact-label {
  font-size: 0.7rem;
  color: var(--text-muted);
}

.btn-contact-custom {
  background: rgba(99, 102, 241, 0.2);
  border: 1px solid rgba(129, 140, 248, 0.4);
  color: #c7d2fe;
  padding: 6px 12px;
  border-radius: 8px;
  font-size: 0.72rem;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: all 0.2s ease;
}

.btn-contact-custom:hover {
  background: rgba(99, 102, 241, 0.35);
  color: #ffffff;
}

/* 10 Feature Modules UI Enhancements in Smartphone */
.discount-selector-bar {
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: rgba(239, 68, 68, 0.08);
  border: 1px dashed rgba(239, 68, 68, 0.3);
  border-radius: 12px;
  padding: 8px 10px;
  margin-bottom: 6px;
}

.discount-title {
  font-size: 0.72rem;
  font-weight: 700;
  color: #f87171;
}

.discount-pills {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  scrollbar-width: none;
}

.discount-pills::-webkit-scrollbar {
  display: none;
}

.discount-pill {
  white-space: nowrap;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #cbd5e1;
  padding: 4px 9px;
  border-radius: 12px;
  font-size: 0.7rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.discount-pill.active {
  background: #ef4444;
  color: #ffffff;
  border-color: #ef4444;
  font-weight: 700;
  box-shadow: 0 0 10px rgba(239, 68, 68, 0.4);
}

/* Reminders & D-Day Block */
.reminders-block {
  background: rgba(245, 158, 11, 0.08);
  border: 1px solid rgba(245, 158, 11, 0.25);
  border-radius: 14px;
  padding: 12px;
  margin-bottom: 12px;
}

.reminders-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
}

.reminder-card {
  background: rgba(0, 0, 0, 0.25);
  border-radius: 10px;
  padding: 8px 10px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.dday-badge {
  background: rgba(245, 158, 11, 0.2);
  color: #fbbf24;
  font-size: 0.7rem;
  font-weight: 800;
  padding: 3px 7px;
  border-radius: 6px;
}

.dday-badge.urgent {
  background: #ef4444;
  color: #ffffff;
  animation: pulse 1.5s infinite;
}

@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.05); }
  100% { transform: scale(1); }
}

.reminder-info {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.reminder-info strong {
  font-size: 0.78rem;
  color: #f1f5f9;
}

.rem-cat {
  font-size: 0.65rem;
  color: var(--text-muted);
}

.btn-rem-check {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: rgba(16, 185, 129, 0.2);
  border: 1px solid rgba(16, 185, 129, 0.4);
  color: #34d399;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.75rem;
}

/* Expenses itemized list in Closing */
.expense-item-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 10px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 8px;
  font-size: 0.75rem;
}

.expense-item-name {
  color: #cbd5e1;
}

.expense-item-amt {
  color: #f87171;
  font-weight: 700;
}

/* Header Active Module Badge */
.header-mod-count-badge {
  font-size: 0.62rem;
  background: rgba(99, 102, 241, 0.2);
  border: 1px solid rgba(129, 140, 248, 0.4);
  color: #c7d2fe;
  padding: 2px 7px;
  border-radius: 10px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

/* Active Modules Tags Grid in Settings */
.active-modules-tags-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.active-mod-tag {
  font-size: 0.68rem;
  padding: 4px 8px;
  border-radius: 8px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  transition: all 0.2s ease;
}

.active-mod-tag.on {
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.4);
  color: #34d399;
}

.active-mod-tag.off {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #64748b;
  text-decoration: line-through;
  opacity: 0.6;
}

/* Module Checkbox Label Highlight in Studio */
.module-checkbox-label.is-active {
  background: rgba(99, 102, 241, 0.18) !important;
  border-color: #818cf8 !important;
  color: #ffffff !important;
  font-weight: 700;
  box-shadow: 0 0 10px rgba(99, 102, 241, 0.25);
}


