/* ==========================================================================
   BILLFAST - KIRANA BILLING & UDHAAR KHATA DESIGN SYSTEM (FIGMA PIXEL-PERFECT)
   ========================================================================== */

:root {
  --bg-app: #f8fafc;
  --bg-card: #ffffff;
  --text-main: #0f172a;
  --text-muted: #64748b;
  --text-sub: #94a3b8;
  --brand-primary: #2563eb;
  --brand-dark: #1e3a8a;
  --brand-light: #eff6ff;
  --brand-border: #bfdbfe;
  
  --green-success: #16a34a;
  --green-dark: #15803d;
  --green-deep: #166534;
  --green-bg: #dcfce7;
  --green-subtle: #f0fdf4;
  
  --red-danger: #dc2626;
  --red-dark: #b91c1c;
  --red-bg: #fef2f2;
  --red-border: #fee2e2;

  --border-light: #e2e8f0;
  --border-subtle: #f1f5f9;
  --handle-gray: #cbd5e1;
  --scrim-color: rgba(15, 23, 42, 0.42);

  --font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --radius-pill: 24px;
}

/* Base Reset */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

body {
  font-family: var(--font-family);
  background-color: #0f172a; /* Outer desktop bg */
  color: var(--text-main);
  line-height: 1.4;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: flex-start;
}

/* App Viewport Container (Matches Figma 390px Mobile View) */
.app-viewport {
  width: 100%;
  max-width: 420px;
  min-height: 100vh;
  background-color: var(--bg-app);
  position: relative;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
}

@media (max-width: 420px) {
  .app-viewport {
    box-shadow: none;
  }
}

/* Top Status Bar */
.status-bar {
  height: 30px;
  width: 100%;
  padding: 8px 22px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-main);
  background-color: var(--bg-app);
  z-index: 20;
  user-select: none;
}

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

.battery-icon {
  font-size: 13px;
}

/* App Content Area */
.app-content {
  flex: 1;
  overflow-y: auto;
  padding: 0 20px 105px 20px; /* 105px padding to clear bottom navigation */
}

/* Screen View Toggling */
.screen-view {
  display: none;
  animation: fadeIn 0.15s ease-in-out;
}

.screen-view.active {
  display: block;
}

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

/* ==========================================================================
   COMMON COMPONENTS & UTILITIES
   ========================================================================== */

/* Buttons & Badges */
.icon-btn-circle {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-main);
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.icon-btn-circle:hover {
  background: var(--border-subtle);
}

.icon-btn-circle:active {
  transform: scale(0.95);
}

.btn-primary-circle {
  background: var(--brand-primary);
  border-color: var(--brand-primary);
  color: #ffffff;
}

.btn-primary-circle:hover {
  background: #1d4ed8;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  font-size: 11px;
  font-weight: 600;
  line-height: 16px;
  white-space: nowrap;
}

.badge-online {
  background-color: var(--green-bg);
  color: var(--green-dark);
}

.badge-offline {
  background-color: #fef3c7;
  color: #92400e;
}

.badge-sync-count {
  background-color: #eff6ff;
  color: #1d4ed8;
  border: 1px solid #bfdbfe;
  cursor: pointer;
  animation: pulse-sync 2s infinite ease-in-out;
}

.badge-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: var(--green-dark);
  display: inline-block;
}

.badge-dot.badge-dot-offline {
  background-color: #d97706;
}

/* Offline Status & Auto-Sync Banner */
.offline-banner {
  background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 100%);
  border-bottom: 1px solid #fde68a;
  padding: 10px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  z-index: 50;
  transition: all 0.3s ease;
}

.offline-banner.banner-synced {
  background: linear-gradient(135deg, #f0fdf4 0%, #dcfce7 100%);
  border-bottom-color: #bbf7d0;
}

.offline-banner-content {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
}

.offline-pulse-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background-color: #d97706;
  flex-shrink: 0;
  box-shadow: 0 0 0 0 rgba(217, 119, 6, 0.4);
  animation: offline-pulse 1.8s infinite;
}

.offline-pulse-dot.dot-online {
  background-color: var(--green-success);
  box-shadow: 0 0 0 0 rgba(22, 163, 74, 0.4);
  animation: online-pulse 1.8s infinite;
}

@keyframes offline-pulse {
  0% { box-shadow: 0 0 0 0 rgba(217, 119, 6, 0.7); }
  70% { box-shadow: 0 0 0 7px rgba(217, 119, 6, 0); }
  100% { box-shadow: 0 0 0 0 rgba(217, 119, 6, 0); }
}

@keyframes online-pulse {
  0% { box-shadow: 0 0 0 0 rgba(22, 163, 74, 0.7); }
  70% { box-shadow: 0 0 0 7px rgba(22, 163, 74, 0); }
  100% { box-shadow: 0 0 0 0 rgba(22, 163, 74, 0); }
}

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

.offline-banner-info {
  display: flex;
  flex-direction: column;
}

.offline-banner-text {
  font-size: 13px;
  font-weight: 700;
  color: #92400e;
  line-height: 16px;
}

.offline-banner.banner-synced .offline-banner-text {
  color: var(--green-deep);
}

.offline-banner-sub {
  font-size: 11px;
  color: #b45309;
  line-height: 14px;
}

.offline-banner.banner-synced .offline-banner-sub {
  color: var(--green-dark);
}

.btn-sync-action {
  background-color: var(--brand-primary);
  color: #ffffff;
  border: none;
  border-radius: var(--radius-pill);
  padding: 6px 14px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  box-shadow: 0 2px 6px rgba(37, 99, 235, 0.25);
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: all 0.2s ease;
}

.btn-sync-action:hover {
  background-color: var(--brand-dark);
}

.offline-failed-list {
  display: grid;
  flex-basis: 100%;
  gap: 8px;
}

.offline-failed-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 10px;
  background: #fff;
  border: 1px solid var(--red-border);
  border-radius: var(--radius-sm);
}

.offline-failed-info {
  display: grid;
  gap: 2px;
  min-width: 0;
  font-size: 11px;
}

.offline-failed-info strong {
  overflow-wrap: anywhere;
}

.offline-failed-info span {
  color: var(--red-dark);
  overflow-wrap: anywhere;
}

.offline-failed-actions {
  display: flex;
  flex-shrink: 0;
  gap: 6px;
}

.offline-failed-actions button {
  padding: 5px 8px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  background: var(--bg-card);
  color: var(--text-main);
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
}

.btn-sync-action:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.badge-paid {
  background-color: var(--green-bg);
  color: var(--green-dark);
}

.badge-udhaar {
  background-color: var(--red-bg);
  color: var(--red-danger);
}

.badge-light-green {
  background-color: var(--green-bg);
  color: var(--green-deep);
  font-size: 10px;
}

/* Typography Helpers */
.text-green { color: var(--green-success); }
.text-green-sub { color: var(--green-dark); }
.text-red { color: var(--red-danger); }
.text-brand { color: var(--brand-primary); }
.text-dark { color: var(--text-main); }
.text-muted { color: var(--text-muted); }
.text-small { font-size: 10px; }
.font-bold { font-weight: 700; }
.label-upper {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

/* Section Header Rows */
.screen-header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 0 16px 0;
}

.screen-title {
  font-size: 25px;
  font-weight: 700;
  line-height: 31px;
  color: var(--text-main);
}

.screen-subtitle {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 2px;
}

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

.section-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-main);
}

.btn-text-link {
  background: none;
  border: none;
  font-size: 12px;
  font-weight: 600;
  color: var(--brand-primary);
  cursor: pointer;
  padding: 4px 8px;
}

.btn-text-link:hover {
  text-decoration: underline;
}

/* ==========================================================================
   SCREEN 1: HOME DASHBOARD
   ========================================================================== */

.store-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 0 16px 0;
}

.brand-tag {
  font-size: 11px;
  font-weight: 700;
  color: var(--brand-primary);
  display: block;
}

.store-name {
  font-size: 20px;
  font-weight: 700;
  line-height: 24px;
  color: var(--text-main);
  margin-top: 2px;
}

.store-tagline {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 2px;
}

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

/* Today Overview Grid */
.today-overview-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 18px;
}

.stat-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 14px 16px;
  min-height: 110px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.clickable-card {
  cursor: pointer;
  transition: transform 0.15s ease, border-color 0.15s ease;
}

.clickable-card:hover {
  border-color: #cbd5e1;
  transform: translateY(-1px);
}

.clickable-card:active {
  transform: scale(0.98);
}

.stat-label {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-muted);
}

.stat-value {
  font-size: 25px;
  font-weight: 700;
  line-height: 31px;
  margin: 4px 0;
}

.stat-sub {
  font-size: 10px;
  font-weight: 500;
}

/* Quick Bill Card */
.quick-bill-card {
  background-color: var(--brand-light);
  border: 1px solid #dbeafe;
  border-radius: var(--radius-xl);
  padding: 16px;
  margin-bottom: 22px;
}

.quick-bill-title {
  font-size: 17px;
  font-weight: 700;
  line-height: 21px;
  color: var(--brand-dark);
}

.quick-bill-subtitle {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 2px;
  margin-bottom: 12px;
}

.voice-input-container {
  background-color: var(--bg-card);
  border: 1px solid var(--brand-border);
  border-radius: var(--radius-lg);
  padding: 10px 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 80px;
  box-shadow: 0 1px 3px rgba(37, 99, 235, 0.05);
}

.input-text-area {
  flex: 1;
  display: flex;
}

.quick-add-textarea {
  width: 100%;
  border: none;
  outline: none;
  resize: none;
  font-family: inherit;
  font-size: 12px;
  font-weight: 500;
  color: var(--text-main);
  background: transparent;
  line-height: 17px;
}

.quick-add-textarea::placeholder {
  color: #94a3b8;
  font-size: 11px;
}

.mic-circle-btn {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background-color: var(--brand-primary);
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  cursor: pointer;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
  transition: all 0.2s ease;
}

.mic-circle-btn:hover {
  background-color: #1d4ed8;
  transform: scale(1.04);
}

.mic-circle-btn:active {
  transform: scale(0.96);
}

/* Mic Recording Active State */
.mic-circle-btn.recording {
  background-color: var(--red-danger);
  animation: pulseRecording 1.2s infinite ease-in-out;
  box-shadow: 0 0 16px rgba(220, 38, 38, 0.5);
}

@keyframes pulseRecording {
  0% { transform: scale(1); }
  50% { transform: scale(1.1); }
  100% { transform: scale(1); }
}

.quick-bill-action-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 10px;
  padding: 0 2px;
}

.voice-status-hint {
  font-size: 10px;
  color: var(--text-muted);
}

.btn-parse-action {
  background: var(--brand-dark);
  color: #ffffff;
  border: none;
  font-size: 11px;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: background 0.15s ease;
}

.btn-parse-action:hover {
  background: #172554;
}

/* Recent Bills List */
.bills-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.bill-item-row {
  background-color: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 9px 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  transition: all 0.15s ease;
}

.bill-item-row:hover {
  border-color: #cbd5e1;
  background-color: #ffffff;
}

.bill-customer-col {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.bill-customer-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-main);
}

.bill-time {
  font-size: 10px;
  color: var(--text-muted);
}

.bill-amount-col {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 3px;
}

.bill-amount-val {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-main);
}

.loading-placeholder {
  text-align: center;
  font-size: 12px;
  color: var(--text-muted);
  padding: 24px 0;
}

/* ==========================================================================
   SCREEN 2: UDHAAR KHATA
   ========================================================================== */

.credit-overview-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 16px;
  display: flex;
  align-items: center;
  margin-bottom: 14px;
}

.credit-col {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.vertical-divider {
  width: 1px;
  height: 56px;
  background-color: var(--border-light);
  margin: 0 16px;
}

.amount-hero {
  font-size: 29px;
  font-weight: 700;
  line-height: 35px;
  margin-top: 4px;
}

.amount-sub {
  font-size: 21px;
  font-weight: 700;
  line-height: 26px;
  margin-top: 2px;
}

.label-muted {
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
}

.count-tag {
  font-size: 10px;
  font-weight: 500;
  margin-top: 2px;
}

/* Search input */
.search-input-wrapper {
  background-color: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  height: 48px;
  padding: 0 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.search-input {
  flex: 1;
  border: none;
  outline: none;
  font-family: inherit;
  font-size: 14px;
  color: var(--text-main);
  background: transparent;
}

.search-input::placeholder {
  color: var(--text-muted);
}

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

/* Filter pills row */
.filter-pills-row {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.filter-pill {
  height: 40px;
  padding: 0 18px;
  border-radius: var(--radius-pill);
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  border: 1px solid var(--border-light);
  background-color: var(--bg-card);
  color: var(--text-muted);
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s ease;
}

.filter-pill.active {
  background-color: var(--brand-dark);
  border-color: var(--brand-dark);
  color: #ffffff;
}

/* Customer cards */
.customer-cards-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.customer-card-row {
  background-color: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  height: 72px;
  padding: 12px 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  transition: all 0.15s ease;
}

.customer-card-row:hover {
  border-color: #cbd5e1;
}

.customer-meta-col {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.cust-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-main);
}

.cust-last-bill {
  font-size: 10px;
  color: var(--text-muted);
}

.customer-udhaar-col {
  display: flex;
  align-items: center;
  gap: 10px;
}

.udhaar-details {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
}

.udhaar-val {
  font-size: 17px;
  font-weight: 700;
  color: var(--red-danger);
}

.udhaar-due-hint {
  font-size: 10px;
  color: var(--text-muted);
}

.chevron-icon-box {
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-sub);
}

/* ==========================================================================
   SCREEN 3: REPORTS
   ========================================================================== */

.segmented-control {
  background-color: var(--border-light);
  border-radius: 12px;
  height: 48px;
  padding: 4px;
  display: flex;
  margin-bottom: 16px;
}

.segment-btn {
  flex: 1;
  border: none;
  border-radius: 8px;
  background: transparent;
  font-family: inherit;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.15s ease;
}

.segment-btn.active {
  background-color: #ffffff;
  color: var(--brand-dark);
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.report-summary-hero {
  background-color: var(--brand-dark);
  border-radius: 18px;
  padding: 18px;
  color: #ffffff;
  margin-bottom: 16px;
}

.summary-top-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.text-blue-100 { color: #bfdbfe; }
.text-blue-200 { color: #dbeafe; }

.hero-amount {
  font-size: 34px;
  font-weight: 700;
  line-height: 41px;
  margin: 8px 0 12px 0;
}

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

/* 7-Day Chart */
.chart-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 16px;
  height: 220px;
  margin-bottom: 16px;
  display: flex;
  flex-direction: column;
}

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

.chart-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-main);
}

.chart-today-label {
  font-size: 11px;
  font-weight: 600;
}

.chart-body {
  flex: 1;
  position: relative;
  display: flex;
  align-items: flex-end;
  padding-left: 36px;
}

.gridline-row {
  position: absolute;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  pointer-events: none;
}

.grid-label {
  width: 32px;
  font-size: 9px;
  color: var(--text-muted);
}

.grid-line {
  flex: 1;
  height: 1px;
  background-color: var(--border-subtle);
}

.chart-bars-container {
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  z-index: 2;
  padding-bottom: 18px; /* space for day labels */
}

.bar-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  flex: 1;
}

.bar-pillar {
  width: 22px;
  background-color: #bfdbfe;
  border-radius: 5px 5px 0 0;
  transition: height 0.4s ease, background 0.2s ease;
  min-height: 4px;
}

.bar-pillar.today-bar {
  background-color: var(--brand-primary);
}

.bar-pillar:hover {
  filter: brightness(0.92);
}

.bar-day-label {
  font-size: 9px;
  color: var(--text-muted);
  position: absolute;
  bottom: 0;
}

.bar-col.today-col .bar-day-label {
  color: var(--brand-primary);
  font-weight: 600;
}

/* Payment split */
.payment-split-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 16px;
  margin-bottom: 16px;
}

.card-inner-title {
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 14px;
}

.split-progress-bar {
  height: 8px;
  border-radius: 4px;
  display: flex;
  overflow: hidden;
  margin-bottom: 14px;
  background-color: var(--border-light);
}

.segment-cash {
  background-color: var(--green-success);
}

.segment-credit {
  background-color: var(--red-danger);
}

.split-legends-row {
  display: flex;
  justify-content: space-between;
}

.split-legend-item {
  display: flex;
  align-items: center;
  gap: 6px;
}

.legend-dot {
  width: 7px;
  height: 7px;
  border-radius: 3px;
}

.dot-cash { background-color: var(--green-success); }
.dot-credit { background-color: var(--red-danger); }

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

.legend-name {
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
}

.legend-val {
  font-size: 13px;
  font-weight: 700;
}

/* Collections card */
.collections-card {
  background-color: var(--green-subtle);
  border: 1px solid var(--green-bg);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.collection-status-icon {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background-color: var(--green-bg);
  display: flex;
  align-items: center;
  justify-content: center;
}

.collection-meta {
  flex: 1;
}

.collection-title {
  font-size: 12px;
  font-weight: 600;
  color: var(--green-deep);
}

.collection-subtitle {
  font-size: 10px;
  color: var(--green-dark);
}

.collection-amount {
  font-size: 18px;
  font-weight: 700;
}

/* ==========================================================================
   SCREEN 5: BILL RECEIPT / CASH MEMO
   ========================================================================== */

.receipt-header-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 0 16px 0;
}

.receipt-heading {
  font-size: 22px;
  font-weight: 700;
  line-height: 27px;
}

.receipt-subheading {
  font-size: 11px;
  color: var(--text-muted);
}

/* Modern Paper receipt container */
.cash-memo-paper {
  background-color: #ffffff;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 0;
  overflow: hidden;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.05), 0 8px 10px -6px rgba(0, 0, 0, 0.01);
  margin-bottom: 20px;
}

/* Modern Invoice Header Strip */
.invoice-header-strip {
  background: linear-gradient(135deg, #1D4ED8 0%, #1E40AF 100%);
  color: #ffffff;
  padding: 18px 20px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}

.invoice-header-main {
  flex: 1;
}

.invoice-doc-type {
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #93c5fd;
  display: block;
  margin-bottom: 3px;
}

.invoice-shop-title {
  font-size: 20px;
  font-weight: 800;
  color: #ffffff;
  line-height: 1.2;
  margin: 0 0 3px 0;
}

.invoice-shop-address {
  font-size: 11px;
  color: #e0e7ff;
  margin: 0;
  line-height: 1.3;
}

.invoice-shop-phone {
  font-size: 11px;
  color: #bfdbfe;
  margin: 3px 0 0 0;
  font-weight: 500;
}

/* Status Badges & Stamps */
.invoice-status-stamp {
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 6px 12px;
  border-radius: 8px;
  white-space: nowrap;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.12);
  transform: rotate(-3deg);
  display: inline-block;
}

.invoice-status-stamp.stamp-paid {
  background: #ecfdf5;
  color: #047857;
  border: 2px solid #059669;
}

.invoice-status-stamp.stamp-udhaar {
  background: #fef2f2;
  color: #dc2626;
  border: 2px solid #dc2626;
}

.invoice-status-stamp.stamp-jama {
  background: #eff6ff;
  color: #1d4ed8;
  border: 2px solid #2563eb;
}

.memo-meta-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 20px;
  background-color: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
  font-size: 12px;
  color: var(--text-main);
  font-weight: 600;
}

.memo-bill-time {
  font-size: 11px;
  font-weight: 400;
  color: var(--text-muted);
}

.memo-customer-box {
  padding: 12px 20px 4px;
}

.memo-bill-to-tag {
  font-size: 10px;
  font-weight: 700;
  color: var(--text-muted);
  letter-spacing: 0.8px;
}

.memo-customer-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 3px;
}

.memo-customer-name {
  font-size: 14px;
  font-weight: 700;
  color: #0f172a;
}

.memo-customer-phone {
  font-size: 12px;
  color: #475569;
  font-weight: 500;
}

.memo-divider {
  height: 1px;
  background-color: var(--border-light);
  margin: 12px 20px;
}

.memo-divider.dashed {
  background: none;
  border-top: 1px dashed #cbd5e1;
  margin: 12px 20px;
}

/* Itemized Table */
.memo-table-container {
  padding: 0 20px;
  margin-top: 4px;
}

.memo-table-head {
  display: grid;
  grid-template-columns: 2.4fr 0.9fr 1fr 1.1fr;
  font-size: 10px;
  font-weight: 700;
  color: #475569;
  padding: 8px 10px;
  background-color: #f1f5f9;
  border-radius: 6px;
  letter-spacing: 0.5px;
}

.memo-table-row {
  display: grid;
  grid-template-columns: 2.4fr 0.9fr 1fr 1.1fr;
  align-items: center;
  padding: 9px 10px;
  border-bottom: 1px solid #f1f5f9;
  border-radius: 4px;
}

.memo-table-row:nth-child(even) {
  background-color: #f8fafc;
}

.memo-table-head .col-amount,
.memo-table-row .col-amount {
  text-align: right;
}

.memo-table-head .col-rate,
.memo-table-row .col-rate,
.memo-table-head .col-qty,
.memo-table-row .col-qty {
  text-align: center;
}

.memo-table-row .col-item {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-main);
}

.memo-table-row .col-qty,
.memo-table-row .col-rate {
  font-size: 12px;
  color: var(--text-muted);
}

.memo-table-row .col-amount {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-main);
}

/* Dedicated Jama Parchi Breakdown Card */
.jama-settlement-card {
  margin: 8px 20px 14px;
  padding: 16px;
  background: linear-gradient(180deg, #f0fdf4 0%, #ecfdf5 100%);
  border: 1.5px solid #a7f3d0;
  border-radius: 12px;
}

.jama-badge-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 700;
  color: #065f46;
  margin-bottom: 12px;
}

.jama-amount-highlight {
  text-align: center;
  padding: 12px;
  background: #ffffff;
  border-radius: 10px;
  border: 1px solid #d1fae5;
  box-shadow: 0 2px 6px rgba(16, 185, 129, 0.08);
}

.jama-label {
  font-size: 11px;
  font-weight: 600;
  color: #059669;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  display: block;
}

.jama-big-amount {
  font-size: 32px;
  font-weight: 800;
  color: #047857;
  margin: 4px 0 6px;
  display: block;
}

.jama-mode-badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  background: #dcfce7;
  color: #15803d;
  border: 1px solid #86efac;
  text-transform: uppercase;
}

.jama-breakdown-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1.2fr;
  gap: 8px;
  margin-top: 12px;
}

.jama-grid-item {
  background: #ffffff;
  padding: 8px 6px;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
  text-align: center;
}

.jama-grid-item.highlight {
  background: #fff7ed;
  border-color: #fed7aa;
}

.grid-label {
  font-size: 10px;
  font-weight: 600;
  color: #64748b;
  display: block;
  margin-bottom: 3px;
}

.grid-value {
  font-size: 14px;
  font-weight: 700;
  color: #0f172a;
}

.jama-note-row {
  margin-top: 10px;
  padding-top: 8px;
  border-top: 1px dashed #bbf7d0;
  display: flex;
  gap: 6px;
  font-size: 11px;
}

.grid-note-text {
  color: #1e293b;
  font-weight: 500;
}

/* Memo Totals */
.memo-totals-block {
  padding: 0 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.memo-total-line {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

.memo-total-label {
  font-size: 14px;
  font-weight: 600;
}

.memo-total-val {
  font-size: 26px;
  font-weight: 800;
  line-height: 32px;
}

.memo-paid-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--green-dark);
}

.memo-paid-val {
  font-size: 16px;
  font-weight: 700;
}

.memo-udhaar-banner {
  background-color: var(--red-bg);
  border-radius: 10px;
  padding: 10px 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--red-danger);
  margin: 4px 0;
  border: 1px solid #fecaca;
}

.memo-udhaar-label {
  font-size: 13px;
  font-weight: 600;
}

.memo-udhaar-val {
  font-size: 20px;
  font-weight: 800;
}

.memo-due-label {
  font-size: 11px;
  color: var(--text-muted);
}

.memo-due-val {
  font-size: 12px;
  font-weight: 600;
}

.memo-footer-greeting {
  text-align: center;
  font-size: 12px;
  font-weight: 600;
  color: #475569;
  margin-top: 14px;
  padding: 0 20px;
}

.invoice-footer-brand {
  text-align: center;
  font-size: 10px;
  font-weight: 600;
  color: #94a3b8;
  padding: 10px 20px 14px;
  letter-spacing: 0.3px;
}

/* Payment Mode Toggle in Modal */
.payment-mode-toggle-group {
  display: flex;
  gap: 10px;
  margin-top: 4px;
}

.mode-toggle-btn {
  flex: 1;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 8px;
  border: 1.5px solid #cbd5e1;
  background: #f8fafc;
  font-size: 13px;
  font-weight: 600;
  color: #475569;
  cursor: pointer;
  transition: all 0.2s;
}

.mode-toggle-btn.active {
  background: #eff6ff;
  border-color: #2563eb;
  color: #1d4ed8;
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.15);
}

/* Receipt Actions Footer */
.receipt-actions-footer {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.btn-action-lg {
  height: 52px;
  border-radius: var(--radius-md);
  border: none;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.15s ease;
}

.btn-whatsapp {
  background-color: var(--green-success);
  color: #ffffff;
}

.btn-whatsapp:hover {
  background-color: var(--green-dark);
}

.btn-primary {
  background-color: var(--brand-primary);
  color: #ffffff;
}

.btn-primary:hover {
  background-color: #1d4ed8;
}

/* ==========================================================================
   BOTTOM NAVIGATION
   ========================================================================== */

.bottom-navigation {
  position: fixed;
  bottom: 0;
  width: 100%;
  max-width: 420px;
  height: 88px;
  background-color: #ffffff;
  border-top: 1px solid var(--border-light);
  display: flex;
  justify-content: space-around;
  align-items: flex-start;
  padding: 8px 16px 0 16px;
  z-index: 30;
}

.nav-tab {
  flex: 1;
  height: 58px;
  background: transparent;
  border: none;
  border-radius: 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  cursor: pointer;
  color: var(--text-muted);
  font-family: inherit;
  transition: all 0.15s ease;
}

.nav-tab.active {
  background-color: var(--brand-light);
  color: var(--brand-primary);
}

.nav-tab.active .nav-icon {
  color: var(--brand-primary);
}

.nav-label {
  font-size: 11px;
  font-weight: 500;
}

.nav-tab.active .nav-label {
  font-weight: 600;
}

.home-indicator-bar {
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
  width: 132px;
  height: 4px;
  background-color: var(--text-main);
  border-radius: 2px;
}

/* ==========================================================================
   MODALS / BOTTOM SHEETS
   ========================================================================== */

.modal-scrim {
  position: fixed;
  inset: 0;
  background-color: var(--scrim-color);
  z-index: 50;
  display: flex;
  justify-content: center;
  align-items: flex-end;
  animation: fadeInScrim 0.2s ease-out;
}

@keyframes fadeInScrim {
  from { opacity: 0; }
  to { opacity: 1; }
}

.bottom-sheet-container {
  width: 100%;
  max-width: 420px;
  max-height: 88vh;
  background-color: #ffffff;
  border-radius: 24px 24px 0 0;
  padding: 12px 20px 24px 20px;
  display: flex;
  flex-direction: column;
  position: relative;
  animation: slideUpSheet 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.bottom-sheet-container.mini-sheet {
  max-height: 85vh;
}

@keyframes slideUpSheet {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

.sheet-drag-handle {
  width: 40px;
  height: 4px;
  background-color: var(--handle-gray);
  border-radius: 2px;
  margin: 0 auto 12px auto;
  cursor: grab;
}

.sheet-header-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 14px;
}

.sheet-title {
  font-size: 22px;
  font-weight: 700;
  line-height: 27px;
  color: var(--text-main);
}

.sheet-subtitle {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 2px;
}

.btn-close-sheet {
  background: var(--bg-app);
  border: none;
  width: 36px;
  height: 36px;
}

.sheet-scrollable-body {
  overflow-y: auto;
  padding-right: 2px;
  max-height: calc(88vh - 100px);
}

/* Form inputs inside sheet */
.form-group {
  margin-bottom: 12px;
}

.form-label {
  display: block;
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
  margin-bottom: 5px;
}

.form-input {
  width: 100%;
  height: 48px;
  background-color: var(--bg-app);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 0 14px;
  font-family: inherit;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-main);
  outline: none;
}

.form-input:focus {
  border-color: var(--brand-primary);
  background-color: #ffffff;
}

.phone-input-group {
  display: flex;
  align-items: center;
  height: 48px;
  background-color: var(--bg-app);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 0 14px;
}

.phone-prefix {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
}

.phone-divider {
  width: 1px;
  height: 24px;
  background-color: var(--border-light);
  margin: 0 12px;
}

.phone-input {
  flex: 1;
  border: none;
  outline: none;
  background: transparent;
  font-family: inherit;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-main);
}

/* Confirm Items Table */
.confirm-items-header {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.5px;
  margin-top: 14px;
  margin-bottom: 4px;
  padding: 0 4px;
}

.confirm-items-list {
  display: flex;
  flex-direction: column;
}

.confirm-item-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid var(--border-light);
}

.confirm-item-info {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 8px;
}

.confirm-item-name-input {
  font-family: inherit;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-main);
  border: 1px solid transparent;
  border-radius: 4px;
  padding: 3px 6px;
  background: transparent;
  width: 160px;
}

.confirm-item-name-input:focus {
  background: var(--bg-app);
  border-color: var(--brand-primary);
  outline: none;
}

.confirm-item-amt-box {
  display: flex;
  align-items: center;
  gap: 8px;
}

.confirm-item-price-input {
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-main);
  width: 75px;
  text-align: right;
  border: 1px solid transparent;
  border-radius: 4px;
  padding: 3px 6px;
  background: transparent;
}

.confirm-item-price-input:focus {
  background: var(--bg-app);
  border-color: var(--brand-primary);
  outline: none;
}

.btn-item-action {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-item-action:hover {
  background-color: var(--border-subtle);
  color: var(--text-main);
}

.btn-item-delete:hover {
  color: var(--red-danger);
}

.btn-add-item-link {
  background: none;
  border: none;
  color: var(--brand-primary);
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  padding: 10px 0;
  margin-bottom: 12px;
}

.btn-add-item-link:hover {
  text-decoration: underline;
}

/* Totals box in sheet */
.confirm-totals-box {
  background-color: var(--bg-app);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
}

.confirm-total-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.calc-label {
  font-size: 12px;
  color: var(--text-muted);
}

.calc-val {
  font-size: 14px;
  color: var(--text-main);
}

.inline-edit-amount {
  display: flex;
  align-items: center;
  font-size: 14px;
  font-weight: 600;
}

.inline-amt-input {
  width: 75px;
  text-align: right;
  border: 1px solid var(--border-light);
  border-radius: 6px;
  padding: 2px 6px;
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-main);
  background: #ffffff;
}

.inline-amt-input:focus {
  border-color: var(--brand-primary);
  outline: none;
}

.inline-date-input {
  width: 100px;
  text-align: right;
  border: 1px solid var(--border-light);
  border-radius: 6px;
  padding: 2px 6px;
  font-family: inherit;
  font-size: 12px;
  color: var(--text-main);
  background: #ffffff;
}

/* Confirm Action Buttons */
.confirm-buttons-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 14px;
}

.btn-sheet-action {
  height: 48px;
  border-radius: var(--radius-md);
  border: none;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.15s ease;
}

.btn-save-bill {
  background-color: var(--brand-primary);
  color: #ffffff;
}

.btn-save-bill:hover {
  background-color: #1d4ed8;
}

.btn-save-whatsapp {
  background-color: var(--green-success);
  color: #ffffff;
}

.btn-save-whatsapp:hover {
  background-color: var(--green-dark);
}

.sheet-reminder-note {
  font-size: 11px;
  color: var(--text-muted);
  text-align: center;
  margin-top: 4px;
}

.sheet-bottom-indicator {
  width: 132px;
  height: 4px;
  background-color: var(--text-main);
  border-radius: 2px;
  margin: 12px auto 0 auto;
}

.current-udhaar-badge {
  background-color: var(--red-bg);
  border: 1px solid var(--red-border);
  border-radius: 10px;
  padding: 10px 14px;
  font-size: 13px;
  margin-bottom: 14px;
  display: flex;
  justify-content: space-between;
}

/* Toast Notifications */
.toast-notification {
  position: fixed;
  top: 40px;
  left: 50%;
  transform: translateX(-50%) translateY(-20px);
  background-color: rgba(15, 23, 42, 0.92);
  color: #ffffff;
  padding: 10px 18px;
  border-radius: var(--radius-pill);
  font-size: 12px;
  font-weight: 600;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.2);
  z-index: 100;
  pointer-events: none;
  opacity: 0;
  transition: all 0.25s ease;
}

.toast-notification.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ==========================================================================
   AUTH SCREEN (LOGIN / SIGNUP) & PROFILE DRAWER
   ========================================================================== */

#view-auth {
  padding: 24px 16px 40px;
  min-height: calc(100vh - 30px);
  background: linear-gradient(180deg, #eff6ff 0%, #f8fafc 100%);
}

.auth-hero-card {
  display: flex;
  flex-direction: column;
  align-items: stretch;
}

.auth-logo-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.auth-brand {
  font-size: 26px;
  font-weight: 800;
  color: var(--brand-dark);
  letter-spacing: -0.5px;
}

.auth-tagline-pill {
  background: var(--brand-border);
  color: var(--brand-dark);
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: var(--radius-pill);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.auth-hero-title {
  font-size: 22px;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.25;
  margin-bottom: 6px;
}

.auth-hero-desc {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.45;
  margin-bottom: 20px;
}

/* Tabs toggle */
.auth-tabs-toggle {
  display: flex;
  background-color: #e2e8f0;
  border-radius: var(--radius-pill);
  padding: 4px;
  gap: 4px;
  margin-bottom: 18px;
}

.auth-tab-btn {
  flex: 1;
  border: none;
  background: transparent;
  padding: 10px 14px;
  border-radius: var(--radius-pill);
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: center;
}

.auth-tab-btn.active {
  background-color: #ffffff;
  color: var(--brand-primary);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
}

/* Auth Form Card */
.auth-form-card {
  background-color: #ffffff;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: 0 4px 16px rgba(15, 23, 42, 0.06);
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.password-input-group {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
}

.password-input-group .password-field {
  padding-right: 44px;
}

.btn-toggle-pwd {
  position: absolute;
  right: 10px;
  background: transparent;
  border: none;
  font-size: 16px;
  cursor: pointer;
  color: var(--text-sub);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6px;
  border-radius: 6px;
  transition: color 0.15s ease;
}

.btn-toggle-pwd:hover {
  color: var(--text-main);
}

.btn-auth-submit {
  width: 100%;
  margin-top: 6px;
  font-weight: 700;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.28);
}

.demo-chip-box {
  background: #f8fafc;
  border: 1px dashed var(--brand-border);
  border-radius: var(--radius-md);
  padding: 10px 12px;
  text-align: center;
  font-size: 12px;
  color: var(--brand-dark);
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
}

.demo-chip-box:hover {
  background: var(--brand-light);
  border-color: var(--brand-primary);
}

/* Profile Modal & Logout Button */
.mini-sheet {
  max-width: 420px;
}

.profile-card-box {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px;
  background-color: var(--bg-app);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  margin-bottom: 8px;
}

.profile-avatar-circle {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--brand-dark) 0%, var(--brand-primary) 100%);
  color: #ffffff;
  font-size: 20px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.25);
}

.profile-text-meta {
  display: flex;
  flex-direction: column;
  gap: 2px;
  overflow: hidden;
}

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

.profile-shop-sub {
  font-size: 13px;
  color: var(--text-muted);
}

.btn-danger-outline {
  border: 1.5px solid var(--red-border);
  color: var(--red-danger);
  background-color: transparent;
  transition: all 0.2s ease;
}

.btn-danger-outline:hover,
.btn-danger-outline:active {
  background-color: var(--red-bg);
  border-color: var(--red-danger);
}

/* ==========================================================================
   SILENT 2-BUTTON HOME, PWA, FAST BILLING, DIRECT KHATA & DIRECT UPI UPGRADE
   ========================================================================== */

/* Header Plan Badge */
.plan-header-badge {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  color: #ffffff;
  border: none;
  font-family: inherit;
  font-size: 11px;
  font-weight: 700;
  padding: 5px 9px;
  border-radius: var(--radius-pill);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 3px;
  box-shadow: 0 2px 6px rgba(217, 119, 6, 0.3);
  transition: transform 0.15s ease;
}

.plan-header-badge:active {
  transform: scale(0.96);
}

/* Expiry Alert Banner */
.expiry-alert-banner {
  background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 100%);
  border: 1px solid #fde68a;
  border-radius: var(--radius-md);
  padding: 10px 12px;
  margin: 10px 16px 2px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.1);
  animation: fadeIn 0.2s ease-in-out;
}

.expiry-banner-content {
  display: flex;
  align-items: center;
  gap: 8px;
}

.expiry-banner-icon {
  font-size: 20px;
}

.expiry-banner-text {
  display: flex;
  flex-direction: column;
}

.expiry-banner-text strong {
  font-size: 12px;
  font-weight: 700;
  color: #92400e;
}

.expiry-banner-text span {
  font-size: 11px;
  color: #b45309;
}

.btn-banner-action {
  background-color: #d97706;
  color: #ffffff;
  border: none;
  border-radius: var(--radius-pill);
  padding: 6px 12px;
  font-family: inherit;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
}

/* Silent 2-Button Primary Actions (Kirana Touch-Friendly) */
.home-action-buttons-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  padding: 0 16px;
  margin-top: 14px;
}

.home-hero-action-btn {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: space-between;
  min-height: 105px;
  padding: 14px 12px;
  border-radius: var(--radius-lg);
  border: none;
  font-family: inherit;
  text-align: left;
  cursor: pointer;
  color: #ffffff;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.1);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  overflow: hidden;
}

.home-hero-action-btn:active {
  transform: scale(0.98);
}

.btn-hero-counter {
  background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 100%);
}

.btn-hero-khata {
  background: linear-gradient(135deg, #991b1b 0%, #dc2626 100%);
}

.hero-btn-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  background: rgba(255, 255, 255, 0.22);
  color: #ffffff;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: var(--radius-pill);
  letter-spacing: 0.3px;
}

.hero-btn-icon {
  font-size: 24px;
  margin-bottom: 8px;
}

.hero-btn-content {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.hero-btn-title {
  font-size: 16px;
  font-weight: 800;
  line-height: 1.2;
}

.hero-btn-sub {
  font-size: 11px;
  opacity: 0.88;
  line-height: 1.2;
}

.hero-btn-chevron {
  position: absolute;
  bottom: 12px;
  right: 12px;
  font-size: 16px;
  font-weight: 800;
  opacity: 0.85;
}

/* Subtle Compact Quick Bar */
.compact-quick-bar {
  display: flex;
  gap: 8px;
  align-items: center;
  padding: 0 16px;
  margin-top: 12px;
}

.compact-input-wrapper {
  flex: 1;
  display: flex;
  align-items: center;
  background-color: #ffffff;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-pill);
  height: 44px;
  padding: 0 8px 0 12px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
}

.compact-search-icon {
  font-size: 13px;
  margin-right: 6px;
  opacity: 0.6;
}

.compact-quick-input {
  flex: 1;
  border: none;
  outline: none;
  background: transparent;
  font-family: inherit;
  font-size: 12px;
  color: var(--text-main);
}

.compact-mic-icon-btn {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: none;
  background-color: var(--brand-light);
  color: var(--brand-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
}

.compact-mic-icon-btn.recording {
  background-color: var(--red-danger);
  color: #ffffff;
  animation: pulseMic 1.2s infinite;
}

.btn-compact-parse {
  height: 44px;
  padding: 0 14px;
  background-color: var(--brand-primary);
  color: #ffffff;
  border: none;
  border-radius: var(--radius-pill);
  font-family: inherit;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
}

.compact-voice-hint {
  font-size: 10.5px;
  color: var(--text-muted);
  text-align: center;
  margin-top: 4px;
  padding: 0 16px;
}

/* Fast Billing Modal Styles */
.large-sheet {
  max-height: 92vh;
}

.fast-billing-body {
  padding-bottom: 24px;
}

.calculator-card-box {
  background-color: var(--bg-app);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 12px;
  margin-bottom: 14px;
}

.calc-header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11px;
}

.calc-label {
  font-weight: 700;
  color: var(--text-main);
}

.calc-hint {
  color: var(--text-muted);
}

.calc-input-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: #ffffff;
  border: 1.5px solid var(--brand-border);
  border-radius: 10px;
  padding: 8px 12px;
  margin: 8px 0;
}

.calc-display-input {
  flex: 1;
  border: none;
  outline: none;
  font-family: inherit;
  font-size: 18px;
  font-weight: 700;
  color: var(--text-main);
  background: transparent;
}

.calc-instant-total {
  font-size: 20px;
  font-weight: 800;
  color: var(--green-dark);
}

.calc-buttons-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
}

.calc-btn {
  height: 42px;
  background-color: #ffffff;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: 16px;
  font-weight: 600;
  color: var(--text-main);
  cursor: pointer;
  transition: all 0.1s ease;
}

.calc-btn:active {
  background-color: var(--border-light);
  transform: scale(0.97);
}

.calc-btn.calc-op {
  background-color: var(--brand-light);
  color: var(--brand-primary);
  font-weight: 700;
}

.calc-btn.calc-clear {
  background-color: var(--red-bg);
  color: var(--red-danger);
  font-weight: 700;
}

.calc-btn.calc-equal {
  background-color: var(--brand-primary);
  color: #ffffff;
  font-weight: 700;
}

.calc-btn.calc-add-bill {
  background-color: var(--green-success);
  color: #ffffff;
  font-weight: 700;
  font-size: 13px;
}

/* Item Search & Favourites */
.item-search-fav-section {
  margin-bottom: 14px;
}

.fav-items-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 6px 0;
}

.fav-title {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-muted);
}

.fav-items-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  max-height: 110px;
  overflow-y: auto;
  padding: 2px 0;
}

.fav-item-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  background-color: #ffffff;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-pill);
  font-size: 12px;
  font-weight: 600;
  color: var(--text-main);
  cursor: pointer;
  user-select: none;
  transition: all 0.15s ease;
}

.fav-item-chip:hover,
.fav-item-chip:active {
  background-color: var(--brand-light);
  border-color: var(--brand-primary);
  color: var(--brand-primary);
}

.fav-item-price {
  color: var(--green-dark);
  font-weight: 700;
}

.custom-item-row {
  display: flex;
  gap: 6px;
  align-items: center;
}

.custom-item-row .item-rate-input {
  width: 90px;
}

.btn-add-item-action {
  height: 48px;
  padding: 0 14px;
  white-space: nowrap;
}

/* Bill Summary Card */
.fast-bill-summary-card {
  background-color: #ffffff;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 12px;
  margin-bottom: 14px;
}

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

.summary-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-main);
}

.summary-count {
  font-size: 11px;
  color: var(--text-muted);
}

.fast-items-list {
  max-height: 140px;
  overflow-y: auto;
  margin-bottom: 10px;
}

.fast-item-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 0;
  border-bottom: 1px solid var(--border-subtle);
  font-size: 13px;
}

.fast-item-row .item-name {
  font-weight: 600;
  color: var(--text-main);
}

.fast-item-row .item-qty-rate {
  font-size: 11px;
  color: var(--text-muted);
}

.fast-item-row .item-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.fast-item-row .item-amount {
  font-weight: 700;
  color: var(--text-main);
}

.fast-item-row .btn-del-item {
  background: transparent;
  border: none;
  color: var(--red-danger);
  cursor: pointer;
  font-size: 16px;
  padding: 2px 4px;
}

.empty-fast-items-hint {
  font-size: 12px;
  color: var(--text-sub);
  text-align: center;
  padding: 12px 0;
}

.fast-total-banner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 10px;
  border-top: 2px dashed var(--border-light);
  font-size: 14px;
  font-weight: 700;
  color: var(--text-main);
}

.fast-total-amount {
  font-size: 22px;
  font-weight: 800;
  color: var(--green-dark);
}

/* Checkout 1-Tap Buttons */
.fast-checkout-actions {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 14px;
}

.btn-fast-checkout {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 10px 4px;
  border-radius: var(--radius-md);
  border: none;
  color: #ffffff;
  cursor: pointer;
  transition: transform 0.15s ease;
}

.btn-fast-checkout:active {
  transform: scale(0.96);
}

.btn-pay-cash {
  background: linear-gradient(135deg, #15803d 0%, #16a34a 100%);
}

.btn-pay-upi {
  background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 100%);
}

.btn-pay-udhaar {
  background: linear-gradient(135deg, #991b1b 0%, #dc2626 100%);
}

.checkout-icon {
  font-size: 20px;
  margin-bottom: 4px;
}

.checkout-text {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.checkout-text strong {
  font-size: 12px;
  font-weight: 700;
}

.checkout-text span {
  font-size: 10px;
  opacity: 0.9;
}

.btn-whatsapp-action {
  background-color: #25D366;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 700;
}

.powered-by-tag {
  text-align: center;
  font-size: 10.5px;
  color: var(--text-sub);
  margin-top: 6px;
}

/* Direct Khata Modal Styles */
.big-amount-input-box {
  display: flex;
  align-items: center;
  height: 64px;
  background-color: var(--bg-app);
  border: 2px solid var(--brand-primary);
  border-radius: var(--radius-md);
  padding: 0 16px;
  margin-bottom: 8px;
}

.big-amount-input-box .currency-symbol {
  font-size: 28px;
  font-weight: 800;
  color: var(--brand-primary);
  margin-right: 6px;
}

.big-amount-field {
  flex: 1;
  border: none;
  outline: none;
  background: transparent;
  font-family: inherit;
  font-size: 32px;
  font-weight: 800;
  color: var(--text-main);
}

.quick-chip-row {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.amt-chip {
  padding: 6px 12px;
  background-color: #ffffff;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-pill);
  font-family: inherit;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-main);
  cursor: pointer;
  transition: all 0.15s ease;
}

.amt-chip:active {
  background-color: var(--brand-light);
  border-color: var(--brand-primary);
  color: var(--brand-primary);
}

.direct-khata-action-buttons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 18px;
}

.btn-khata-direct {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  height: 56px;
  border-radius: var(--radius-md);
  border: none;
  color: #ffffff;
  cursor: pointer;
  transition: transform 0.15s ease;
}

.btn-khata-direct:active {
  transform: scale(0.97);
}

.btn-khata-udhaar-diya {
  background: linear-gradient(135deg, #991b1b 0%, #dc2626 100%);
}

.btn-khata-paisa-mila {
  background: linear-gradient(135deg, #15803d 0%, #16a34a 100%);
}

.btn-khata-icon {
  font-size: 22px;
}

.btn-khata-text {
  display: flex;
  flex-direction: column;
  text-align: left;
}

.btn-khata-text strong {
  font-size: 14px;
  font-weight: 800;
}

.btn-khata-text span {
  font-size: 11px;
  opacity: 0.9;
}

/* Premium Upgrade Modal Styles */
.current-plan-card-box {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: var(--bg-app);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  margin-bottom: 14px;
}

.current-plan-info {
  display: flex;
  flex-direction: column;
}

.plan-status-title {
  font-size: 16px;
  font-weight: 800;
  color: var(--text-main);
}

.plan-status-sub {
  font-size: 12px;
  color: var(--text-muted);
}

.plan-badge-pill {
  background: var(--brand-border);
  color: var(--brand-dark);
  font-size: 11px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
}

.plan-billing-cycle-toggle {
  display: flex;
  background-color: #e2e8f0;
  border-radius: var(--radius-pill);
  padding: 4px;
  gap: 4px;
  margin-bottom: 16px;
}

.cycle-tab-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border: none;
  background: transparent;
  padding: 10px 12px;
  border-radius: var(--radius-pill);
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.2s ease;
}

.cycle-tab-btn.active {
  background-color: #ffffff;
  color: var(--brand-primary);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
}

.cycle-saving-chip {
  background-color: #dcfce7;
  color: #15803d;
  font-size: 10px;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: var(--radius-pill);
}

.pricing-card {
  background-color: #ffffff;
  border: 1.5px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 18px;
  margin-bottom: 16px;
}

.pricing-card.basic-card.active-card {
  border-color: var(--brand-primary);
  box-shadow: 0 4px 18px rgba(37, 99, 235, 0.12);
}

.pricing-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 12px;
}

.popular-tag {
  font-size: 10px;
  font-weight: 800;
  color: var(--brand-primary);
  letter-spacing: 0.5px;
}

.pricing-title {
  font-size: 20px;
  font-weight: 800;
  color: var(--text-main);
}

.pricing-price-box {
  display: flex;
  align-items: baseline;
  gap: 2px;
}

.price-val {
  font-size: 26px;
  font-weight: 800;
  color: var(--brand-primary);
}

.price-cycle {
  font-size: 13px;
  color: var(--text-muted);
  font-weight: 600;
}

.pricing-features-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 12.5px;
  color: var(--text-main);
  padding: 10px 0;
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
}

.pricing-features-list li {
  display: flex;
  align-items: center;
  gap: 6px;
}

/* UPI Payment Box */
.upi-payment-box {
  background: #eff6ff;
  border: 1px dashed var(--brand-border);
  border-radius: var(--radius-md);
  padding: 14px;
  margin-top: 14px;
}

.upi-qr-wrapper {
  display: flex;
  align-items: center;
  gap: 14px;
}

.qr-placeholder-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  background-color: #ffffff;
  padding: 8px;
  border-radius: 8px;
  border: 1px solid var(--border-light);
}

.qr-caption {
  font-size: 10px;
  font-weight: 700;
  color: var(--brand-dark);
  margin-top: 4px;
}

.upi-meta {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.upi-id-label {
  font-size: 11px;
  color: var(--text-muted);
}

.upi-id-value {
  font-size: 14px;
  color: var(--brand-dark);
  letter-spacing: 0.2px;
}

.upi-verified-badge {
  font-size: 11px;
  color: var(--green-dark);
  font-weight: 700;
  margin-top: 2px;
}

.btn-upi-deeplink-action {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 48px;
  background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 100%);
  color: #ffffff;
  text-decoration: none;
  border-radius: var(--radius-md);
  font-size: 13px;
  font-weight: 700;
  margin-top: 12px;
  box-shadow: 0 3px 10px rgba(37, 99, 235, 0.25);
  transition: transform 0.15s ease;
}

.btn-upi-deeplink-action:active {
  transform: scale(0.98);
}

/* UTR Verification Box */
.utr-verification-box {
  margin-top: 14px;
}

.utr-input-group {
  display: flex;
  gap: 8px;
}

.utr-field {
  font-family: inherit;
  font-weight: 700;
  letter-spacing: 1px;
}

.btn-submit-utr {
  background-color: var(--green-success);
  color: #ffffff;
  white-space: nowrap;
  padding: 0 16px;
  font-weight: 700;
}

.utr-help-hint {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 6px;
}

/* Upcoming Locked Plans */
.upcoming-plans-heading {
  font-size: 14px;
  font-weight: 800;
  color: var(--text-main);
  margin: 18px 0 10px;
}

.upcoming-plans-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.locked-card {
  background-color: var(--bg-app);
  border: 1px dashed var(--border-light);
}

.locked-badge-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.badge-locked {
  background-color: #f1f5f9;
  color: #64748b;
  font-size: 10px;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: var(--radius-pill);
}

.locked-price {
  font-size: 14px;
  font-weight: 800;
  color: var(--text-main);
}

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

.locked-desc {
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.4;
  margin-bottom: 10px;
}

.btn-waitlist-action {
  width: 100%;
  height: 40px;
  background-color: #ffffff;
  border: 1.5px solid var(--brand-primary);
  color: var(--brand-primary);
  border-radius: var(--radius-md);
  font-family: inherit;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-waitlist-action:hover,
.btn-waitlist-action:active {
  background-color: var(--brand-light);
}

/* ==========================================================================
   DPDP ACT 2023 CONSENT & LEGAL MODAL STYLES
   ========================================================================== */

/* Signup Consent Checkbox */
.consent-checkbox-group {
  margin-top: 10px;
  margin-bottom: 16px;
}

.consent-label {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  cursor: pointer;
  user-select: none;
}

.consent-checkbox {
  width: 18px;
  height: 18px;
  margin-top: 2px;
  accent-color: var(--brand-primary);
  cursor: pointer;
  flex-shrink: 0;
}

.consent-text {
  font-size: 12px;
  line-height: 1.45;
  color: var(--text-muted);
}

.consent-text a,
.legal-trigger {
  color: var(--brand-primary);
  text-decoration: underline;
  font-weight: 600;
  cursor: pointer;
}

/* Auth Legal Footer */
.auth-legal-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 22px;
  padding-top: 14px;
  border-top: 1px solid var(--border-light);
  font-size: 11px;
}

.footer-legal-link {
  color: var(--text-muted);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.15s ease;
}

.footer-legal-link:hover {
  color: var(--brand-primary);
  text-decoration: underline;
}

.legal-dot {
  color: var(--border-light);
  font-size: 12px;
}

/* Profile Drawer Menu & DPDP Options */
.profile-section-divider {
  height: 1px;
  background-color: var(--border-light);
  margin: 16px 0;
}

.profile-section-heading {
  display: block;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.5px;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.profile-nav-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.profile-menu-item {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 10px 12px;
  background-color: var(--bg-app);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  text-align: left;
  cursor: pointer;
  transition: all 0.15s ease;
  font-family: inherit;
}

.profile-menu-item:hover,
.profile-menu-item:active {
  background-color: var(--brand-light);
  border-color: rgba(37, 99, 235, 0.25);
}

.menu-icon {
  font-size: 18px;
  flex-shrink: 0;
}

.menu-text {
  flex: 1;
  min-width: 0;
}

.menu-title {
  display: block;
  font-size: 13px;
  font-weight: 700;
  color: var(--text-main);
  line-height: 1.2;
}

.menu-sub {
  display: block;
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.menu-arrow {
  font-size: 16px;
  color: var(--text-muted);
  font-weight: bold;
}

.btn-text-danger-link {
  background: none;
  border: none;
  color: var(--accent-red);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  padding: 6px 10px;
  text-decoration: underline;
  transition: opacity 0.15s ease;
}

.btn-text-danger-link:hover {
  opacity: 0.8;
}

/* Legal Modals & Content Layout */
.legal-sheet-container {
  max-height: 90vh;
}

.legal-modal-body {
  padding-bottom: 24px;
}

.legal-highlight-card {
  background-color: #f0fdf4;
  border: 1px solid #bbf7d0;
  color: #166534;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  font-size: 12px;
  line-height: 1.45;
  margin-bottom: 16px;
}

.legal-section-block {
  margin-bottom: 16px;
}

.legal-section-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 6px;
}

.legal-text {
  font-size: 12px;
  line-height: 1.5;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.legal-list {
  padding-left: 18px;
  margin: 6px 0;
  font-size: 12px;
  line-height: 1.5;
  color: var(--text-main);
}

.legal-list li {
  margin-bottom: 5px;
}

.legal-contact-card {
  background-color: var(--bg-app);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 10px 14px;
  font-size: 12px;
  line-height: 1.5;
}

.legal-contact-card p {
  margin-bottom: 3px;
}

.legal-link-text {
  color: var(--brand-primary);
  font-weight: 700;
  text-decoration: underline;
}

.legal-modal-actions {
  margin-top: 20px;
}

/* About Screen Features Grid */
.about-features-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 10px;
}

.about-feature-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  background: var(--bg-app);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 10px 12px;
}

.about-feature-icon {
  font-size: 20px;
  flex-shrink: 0;
}

.about-feature-item strong {
  display: block;
  font-size: 13px;
  color: var(--text-main);
  margin-bottom: 2px;
}

.about-feature-item p {
  font-size: 11px;
  color: var(--text-muted);
  line-height: 1.35;
  margin: 0;
}

/* Support Screen Cards */
.support-channels-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.support-card-item {
  background: var(--bg-app);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 12px;
}

.support-card-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.support-icon {
  font-size: 20px;
  flex-shrink: 0;
}

.support-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 2px;
}

.support-sub {
  font-size: 11px;
  color: var(--text-muted);
}

.btn-whatsapp-support {
  background-color: #10b981;
  color: #ffffff;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font-weight: 700;
  font-size: 13px;
  height: 42px;
  border-radius: var(--radius-md);
  transition: opacity 0.15s ease;
}

.btn-whatsapp-support:hover {
  opacity: 0.9;
}

.btn-secondary-action {
  background-color: #ffffff;
  color: var(--brand-primary);
  border: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font-weight: 600;
  font-size: 13px;
  height: 40px;
  border-radius: var(--radius-md);
  transition: background-color 0.15s ease;
}

.btn-secondary-action:hover {
  background-color: var(--brand-light);
}

.support-sla {
  display: block;
  font-size: 10px;
  color: var(--text-muted);
  margin-top: 6px;
  text-align: right;
}

/* Account Deletion Modal */
.deletion-warning-card {
  background-color: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: var(--radius-md);
  padding: 14px;
  display: flex;
  gap: 12px;
}

.warning-icon-big {
  font-size: 28px;
  flex-shrink: 0;
}

.warning-title {
  font-size: 14px;
  font-weight: 800;
  color: #991b1b;
  margin-bottom: 4px;
}

.warning-text {
  font-size: 12px;
  color: #7f1d1d;
  line-height: 1.4;
  margin-bottom: 8px;
}

.warning-list {
  padding-left: 18px;
  font-size: 11px;
  color: #7f1d1d;
  line-height: 1.45;
  margin: 0;
}

.warning-list li {
  margin-bottom: 4px;
}

.btn-danger-action {
  background-color: var(--accent-red);
  color: #ffffff;
  border: none;
  font-weight: 700;
  font-size: 13px;
  height: 46px;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: opacity 0.15s ease;
}

.btn-danger-action:disabled {
  background-color: #fca5a5;
  cursor: not-allowed;
  opacity: 0.7;
}

.btn-danger-action:not(:disabled):hover {
  opacity: 0.9;
}

/* Customer Payment History in Modal */
.customer-payment-history-wrap {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px dashed var(--border-light);
}

.history-section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.history-header-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.history-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-main);
}

.history-count-badge {
  font-size: 11px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 12px;
  background: #f1f5f9;
  color: #475569;
}

.history-header-tip {
  font-size: 11px;
  color: var(--text-muted);
}

.customer-payment-history-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 240px;
  overflow-y: auto;
  padding-right: 2px;
}

.empty-history-placeholder {
  text-align: center;
  padding: 16px;
  font-size: 12px;
  color: var(--text-muted);
  background: #f8fafc;
  border-radius: 8px;
  border: 1px dashed #cbd5e1;
}

.payment-history-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 12px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.payment-history-row:hover {
  background: #f8fafc;
  border-color: #cbd5e1;
  transform: translateY(-1px);
}

.payment-history-row:active {
  transform: scale(0.99);
}

.pay-hist-left {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.pay-hist-top-row {
  display: flex;
  align-items: center;
  gap: 6px;
}

.pay-rcp-badge {
  font-size: 11px;
  font-weight: 700;
  color: #1d4ed8;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  padding: 2px 6px;
  border-radius: 4px;
}

.pay-mode-tag {
  font-size: 10px;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 4px;
}

.pay-mode-tag.mode-cash {
  background: #f0fdf4;
  color: #166534;
  border: 1px solid #bbf7d0;
}

.pay-mode-tag.mode-upi {
  background: #faf5ff;
  color: #6b21a8;
  border: 1px solid #e9d5ff;
}

.pay-hist-date {
  font-size: 11px;
  color: #64748b;
}

.pay-hist-note {
  font-size: 10px;
  color: #94a3b8;
  font-style: italic;
}

.pay-hist-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
}

.pay-hist-amount {
  font-size: 14px;
  font-weight: 700;
}

.pay-hist-action {
  font-size: 11px;
  font-weight: 600;
  color: #2563eb;
}

/* ==========================================================================
   PRINT MEDIA QUERY (Clean thermal/paper print for Receipt)
   ========================================================================== */
@media print {
  body {
    background: #ffffff !important;
    color: #000000 !important;
  }

  .status-bar,
  .bottom-navigation,
  .receipt-header-row,
  .receipt-actions-footer,
  .modal-scrim,
  .btn-text-link,
  #view-home,
  #view-udhaar,
  #view-reports {
    display: none !important;
  }

  .app-viewport {
    max-width: 100% !important;
    width: 100% !important;
    box-shadow: none !important;
    min-height: auto !important;
  }

  .app-content {
    padding: 0 !important;
  }

  #view-receipt {
    display: block !important;
  }

  .cash-memo-paper {
    border: none !important;
    box-shadow: none !important;
    padding: 0 !important;
    margin: 0 !important;
  }
}


/* ==========================================================================
   WHATSAPP REMIND BUTTON, DYNAMIC UPI QR ON RECEIPT & PROFILE UPI SETTINGS
   ========================================================================== */
.btn-remind-wa {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background-color: #dcfce7;
  color: #15803d;
  border: 1px solid #86efac;
  border-radius: 999px;
  padding: 5px 10px;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s ease;
}

.btn-remind-wa:hover {
  background-color: #bbf7d0;
}

.btn-remind-wa:active {
  transform: scale(0.96);
}

.current-udhaar-badge {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.profile-upi-settings {
  margin-top: 14px;
  padding: 12px;
  background: #f8fafc;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
}

.btn-save-upi {
  width: auto !important;
  min-width: 72px;
  padding: 0 16px !important;
  background: var(--brand-primary);
  color: #ffffff;
  font-size: 13px;
  font-weight: 700;
}

/* Dynamic UPI QR Box inside Receipt */
.memo-upi-qr-box {
  margin: 14px 0 10px;
  padding: 12px;
  background: #f8fafc;
  border: 1px dashed #cbd5e1;
  border-radius: 12px;
}

.memo-upi-qr-inner {
  display: flex;
  align-items: center;
  gap: 14px;
}

.memo-upi-qr-canvas {
  width: 96px;
  height: 96px;
  flex-shrink: 0;
  background: #ffffff;
  padding: 4px;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.memo-upi-qr-canvas img,
.memo-upi-qr-canvas canvas {
  width: 88px !important;
  height: 88px !important;
  display: block;
}

.memo-upi-qr-meta {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.memo-upi-qr-title {
  font-size: 12px;
  font-weight: 800;
  color: #0f172a;
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

.memo-upi-qr-id {
  font-size: 12px;
  font-weight: 600;
  color: #475569;
  word-break: break-all;
}

.memo-upi-qr-amount {
  font-size: 14px;
  font-weight: 800;
  color: #1d4ed8;
}


/* ==========================================================================
   INVENTORY, LOW-STOCK ALERTS & BARCODE SCANNER UI
   ========================================================================== */
.low-stock-alert-banner {
  background: linear-gradient(135deg, #fff7ed 0%, #ffedd5 100%);
  border: 1px solid #fdba74;
  border-radius: var(--radius-md);
  padding: 10px 12px;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.low-stock-banner-content {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.low-stock-banner-icon {
  font-size: 20px;
  flex-shrink: 0;
}

.low-stock-banner-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.low-stock-banner-text strong {
  font-size: 13px;
  font-weight: 700;
  color: #9a3412;
}

.low-stock-banner-text span {
  font-size: 12px;
  color: #c2410c;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.btn-low-stock-action {
  background-color: #ea580c;
  color: #ffffff;
  border: none;
  border-radius: var(--radius-pill);
  padding: 6px 12px;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
}

.search-scan-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-scan-barcode {
  background: #eff6ff;
  color: #1d4ed8;
  border: 1px solid #bfdbfe;
  border-radius: var(--radius-sm);
  padding: 9px 12px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.btn-scan-barcode:hover {
  background: #dbeafe;
}

.btn-stock-chip {
  background: #f1f5f9;
  color: #334155;
  border: 1px solid #cbd5e1;
  border-radius: 999px;
  padding: 3px 10px;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
}

.inventory-form-card {
  background: #f8fafc;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 12px;
  margin-bottom: 12px;
}

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

.inventory-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.inventory-filter-row {
  display: flex;
  gap: 8px;
  margin-bottom: 10px;
}

.inventory-list-container {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-bottom: 16px;
}

.inventory-item-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  background: #ffffff;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
}

.inventory-item-row.is-low-stock {
  border-color: #fdba74;
  background: #fff7ed;
}

.inv-item-meta {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.inv-item-name {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-main);
}

.inv-item-sub {
  font-size: 11px;
  color: var(--text-muted);
}

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

.inv-stock-pill {
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 999px;
}

.inv-stock-pill.ok {
  background: #dcfce7;
  color: #15803d;
}

.inv-stock-pill.low {
  background: #fee2e2;
  color: #b91c1c;
}

.inv-stock-pill.untracked {
  background: #f1f5f9;
  color: #64748b;
}

.btn-inv-mini {
  border: 1px solid var(--border-light);
  background: #ffffff;
  color: var(--text-main);
  border-radius: 6px;
  padding: 4px 8px;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
}

.barcode-reader-region {
  width: 100%;
  min-height: 220px;
  background: #0f172a;
  border-radius: var(--radius-md);
  overflow: hidden;
  margin-bottom: 10px;
}

.scanner-status-text {
  font-size: 12px;
  color: var(--text-muted);
  text-align: center;
  margin-bottom: 12px;
}

.manual-barcode-box {
  padding-top: 10px;
  border-top: 1px dashed var(--border-light);
}


/* ==========================================================================
   NET PROFIT & EXPENSES REPORT CARD
   ========================================================================== */
.profit-summary-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 16px;
  margin-top: 14px;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
}

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

.btn-manage-expenses {
  background: #fef2f2;
  color: #dc2626;
  border: 1px solid #fecaca;
  border-radius: 999px;
  padding: 5px 12px;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
}

.btn-manage-expenses:hover {
  background: #fee2e2;
}

.profit-metrics-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.profit-metric-item {
  background: #f8fafc;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 10px 8px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  text-align: center;
}

.profit-metric-item.highlight {
  background: #eff6ff;
  border-color: #bfdbfe;
}

.profit-metric-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
}

.profit-metric-val {
  font-size: 15px;
  font-weight: 800;
}


/* ==========================================================================
   GST INVOICE & DATA EXPORT (CSV) UI
   ========================================================================== */
.invoice-shop-gstin {
  font-size: 11px;
  font-weight: 700;
  color: #dbeafe;
  margin-top: 2px;
  letter-spacing: 0.4px;
}

.export-buttons-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
}

.btn-export-csv {
  background: #ffffff;
  color: #1e293b;
  border: 1px solid var(--border-light);
  border-radius: 8px;
  padding: 8px 6px;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  text-align: center;
  transition: all 0.15s ease;
}

.btn-export-csv:hover {
  background: #eff6ff;
  border-color: #93c5fd;
  color: #1d4ed8;
}
