/* Design System & Base Variables */
:root {
  --primary: #6366f1;
  --primary-hover: #4f46e5;
  --primary-soft: rgba(99, 102, 241, 0.15);
  
  --success: #10b981;
  --success-hover: #059669;
  --success-soft: rgba(16, 185, 129, 0.15);
  
  --danger: #ef4444;
  --danger-hover: #dc2626;
  --danger-soft: rgba(239, 68, 68, 0.15);
  
  --warning: #f59e0b;
  
  /* Dark Mode Default values */
  --bg-app: #09090b;
  --bg-card: rgba(24, 24, 27, 0.75);
  --border-color: rgba(63, 63, 70, 0.4);
  --text-main: #f4f4f5;
  --text-muted: #a1a1aa;
  --text-light: #71717a;
  --shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
  --glass-blur: blur(12px);
  --input-bg: #18181b;
  --header-bg: rgba(9, 9, 11, 0.8);
  --nav-bg: rgba(18, 18, 24, 0.85);
  --row-hover: rgba(255, 255, 255, 0.02);
}

.light-theme {
  --bg-app: #f4f5f7;
  --bg-card: rgba(255, 255, 255, 0.8);
  --border-color: rgba(226, 232, 240, 0.8);
  --text-main: #1e293b;
  --text-muted: #64748b;
  --text-light: #94a3b8;
  --shadow: 0 8px 30px 0 rgba(0, 0, 0, 0.06);
  --glass-blur: blur(16px);
  --input-bg: #f8fafc;
  --header-bg: rgba(244, 245, 247, 0.8);
  --nav-bg: rgba(255, 255, 255, 0.9);
  --row-hover: rgba(0, 0, 0, 0.02);
}

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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background-color: var(--bg-app);
  color: var(--text-main);
  min-height: 100vh;
  min-height: -webkit-fill-available; /* Fix iOS 100vh bug */
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  transition: background-color 0.3s, color 0.3s;
}

html {
  height: -webkit-fill-available;
}

/* Scrollbar styling */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: var(--border-color);
  border-radius: 3px;
}

/* App Container */
.app-container {
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 600px; /* Mobile focused max-width */
  margin: 0 auto;
  min-height: 100vh;
  position: relative;
  border-left: 1px solid var(--border-color);
  border-right: 1px solid var(--border-color);
  background-color: var(--bg-app);
}

/* Header */
.app-header {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 20px;
  background-color: var(--header-bg);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border-bottom: 1px solid var(--border-color);
}

.logo-area {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo-icon {
  background: linear-gradient(135deg, var(--primary), #a855f7);
  color: white;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.logo-text h1 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  line-height: 1.1;
}

.logo-text h1 span {
  color: var(--primary);
}

.logo-text p {
  font-size: 0.7rem;
  color: var(--text-muted);
  margin-top: 2px;
}

.theme-toggle {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--input-bg);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  cursor: pointer;
  transition: transform 0.2s;
}

.theme-toggle:active {
  transform: scale(0.9);
}

/* Content Area */
.app-content {
  flex: 1;
  padding: 16px 16px 90px 16px; /* 90px bottom padding to clear the nav bar */
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Navigation Bar */
.app-nav {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 72px;
  background-color: var(--nav-bg);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border-top: 1px solid var(--border-color);
  display: flex;
  justify-content: space-around;
  align-items: center;
  padding-bottom: env(safe-area-inset-bottom, 0); /* Support iPhone notch */
  z-index: 100;
}

.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  background: none;
  border: none;
  color: var(--text-light);
  cursor: pointer;
  flex: 1;
  padding: 8px 0;
  transition: color 0.2s, transform 0.1s;
}

.nav-item i {
  width: 22px;
  height: 22px;
  transition: transform 0.2s;
}

.nav-item span {
  font-size: 0.72rem;
  font-weight: 500;
}

.nav-item.active {
  color: var(--primary);
}

.nav-item.active i {
  transform: translateY(-2px);
}

/* Tab Management */
.tab-pane {
  display: none;
  animation: fadeIn 0.3s ease-out;
  flex-direction: column;
  gap: 16px;
}

.tab-pane.active {
  display: flex;
}

/* Glass Panels */
.glass-panel {
  background-color: var(--bg-card);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 16px;
  box-shadow: var(--shadow);
}

/* Accordion Layout */
.accordion-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
}

.title-with-icon {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-size: 0.95rem;
}

.title-with-icon i {
  color: var(--primary);
}

.arrow-icon {
  transition: transform 0.2s;
}

.accordion-header.active .arrow-icon {
  transform: rotate(180deg);
}

.accordion-content {
  margin-top: 14px;
  border-top: 1px solid var(--border-color);
  padding-top: 14px;
  animation: slideDown 0.25s ease-out;
}

/* Cards Headers */
.card-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}

.card-title h3 {
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.2px;
}

.card-title i {
  color: var(--primary);
  width: 20px;
  height: 20px;
}

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

.card-title-between h3 {
  font-size: 1rem;
  font-weight: 600;
}

/* General Descriptions */
.description {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.5;
  margin-bottom: 16px;
}

/* Inputs and Forms */
.input-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 14px;
}

.input-group label {
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text-muted);
}

.input-group input,
.input-with-action input {
  background-color: var(--input-bg);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 10px 12px;
  color: var(--text-main);
  font-size: 0.9rem;
  width: 100%;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  user-select: text; /* Allow user text selection/typing on mobile */
}

.input-group input:focus,
.input-with-action input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-soft);
}

.input-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.input-with-action {
  display: flex;
  gap: 8px;
  width: 100%;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 10px;
  font-size: 0.9rem;
  font-weight: 600;
  padding: 12px 20px;
  border: none;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
  min-height: 44px; /* Touch target size */
}

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

.btn-primary {
  background-color: var(--primary);
  color: white;
}

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

.btn-success {
  background-color: var(--success);
  color: white;
}

.btn-success:hover {
  background-color: var(--success-hover);
}

.btn-danger {
  background-color: var(--danger);
  color: white;
}

.btn-danger:hover {
  background-color: var(--danger-hover);
}

.btn-secondary {
  background-color: var(--input-bg);
  border: 1px solid var(--border-color);
  color: var(--text-main);
}

.btn-secondary:hover {
  background-color: var(--border-color);
}

.btn-lg {
  padding: 14px 24px;
  font-size: 0.98rem;
}

.btn-sm {
  padding: 8px 14px;
  font-size: 0.8rem;
  min-height: auto;
}

.w-full {
  width: 100%;
}

.icon-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background-color 0.2s, color 0.2s;
}

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

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

/* Scanner Layout */
.scanner-card {
  display: flex;
  flex-direction: column;
  gap: 14px;
  overflow: hidden;
}

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

.status-indicator {
  font-size: 0.78rem;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 20px;
  background-color: var(--input-bg);
  border: 1px solid var(--border-color);
}

.status-indicator.live .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--success);
  box-shadow: 0 0 8px var(--success);
  animation: pulse 1.5s infinite;
}

.status-indicator.offline .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--text-light);
}

.scanner-actions {
  display: flex;
  gap: 8px;
}

/* HTML5 Qrcode Viewport Styling */
.camera-viewport-container {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3; /* Fixed camera aspect ratio */
  border-radius: 12px;
  overflow: hidden;
  background-color: #000;
  border: 1px solid var(--border-color);
}

#reader {
  width: 100% !important;
  height: 100% !important;
  border: none !important;
}

#reader video {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
}

/* Hide html5-qrcode standard overlays and controls */
#reader__dashboard,
#reader__camera_permission_button,
#reader__status_span {
  display: none !important;
}

/* Custom overlay styles */
.scanner-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  z-index: 10;
  pointer-events: none;
  background: rgba(0, 0, 0, 0.4);
}

.scan-target-box {
  width: 70%;
  height: 50%;
  max-width: 320px;
  max-height: 180px;
  position: relative;
  box-shadow: 0 0 0 999px rgba(0, 0, 0, 0.5); /* Outer shadow mask */
  border-radius: 4px;
}

/* Corner Indicators */
.corner {
  position: absolute;
  width: 20px;
  height: 20px;
  border-color: var(--success);
  border-style: solid;
  pointer-events: none;
}

.top-left {
  top: -2px;
  left: -2px;
  border-width: 4px 0 0 4px;
  border-top-left-radius: 8px;
}

.top-right {
  top: -2px;
  right: -2px;
  border-width: 4px 4px 0 0;
  border-top-right-radius: 8px;
}

.bottom-left {
  bottom: -2px;
  left: -2px;
  border-width: 0 0 4px 4px;
  border-bottom-left-radius: 8px;
}

.bottom-right {
  bottom: -2px;
  right: -2px;
  border-width: 0 4px 4px 0;
  border-bottom-right-radius: 8px;
}

/* Scanning Moving Laser Line */
.scan-line {
  position: absolute;
  left: 5%;
  width: 90%;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--success), transparent);
  box-shadow: 0 0 10px 1px var(--success);
  animation: scanMove 2s infinite ease-in-out;
}

.scan-instructions {
  margin-top: 16px;
  color: white;
  font-size: 0.72rem;
  background-color: rgba(0, 0, 0, 0.6);
  padding: 6px 14px;
  border-radius: 20px;
  letter-spacing: 0.5px;
  text-align: center;
  max-width: 90%;
}

.scanner-controls {
  display: flex;
  gap: 10px;
  justify-content: center;
}

/* Result Panel Card */
.result-card {
  animation: slideUp 0.3s ease-out;
}

.text-success {
  color: var(--success) !important;
}

.result-details {
  background-color: var(--input-bg);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 14px;
}

.result-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.result-field-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.result-field .label {
  font-size: 0.72rem;
  color: var(--text-light);
  font-weight: 500;
}

.result-field .value {
  font-size: 0.9rem;
  font-weight: 600;
}

.barcode-text {
  font-family: monospace;
  font-size: 1.1rem !important;
  color: var(--primary) !important;
}

.name-edit-group {
  display: flex;
  align-items: center;
  gap: 8px;
}

.edit-name-btn {
  width: 28px;
  height: 28px;
  opacity: 0.7;
}

.hidden-input {
  background-color: var(--bg-app) !important;
  border: 1px solid var(--primary) !important;
  padding: 6px 10px !important;
  font-size: 0.88rem !important;
  border-radius: 6px !important;
  margin-top: 4px;
}

/* Quantity Control Widget */
.quantity-controller-wrapper {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: var(--input-bg);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 10px 14px;
  margin-bottom: 16px;
}

.quantity-controller-wrapper .label {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-muted);
}

.quantity-controller {
  display: flex;
  align-items: center;
  background-color: var(--bg-app);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  overflow: hidden;
  height: 38px;
}

.qty-btn {
  background: none;
  border: none;
  color: var(--text-main);
  width: 38px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.qty-btn:active {
  background-color: var(--border-color);
}

.quantity-controller input {
  width: 50px;
  height: 100%;
  border: none;
  background: none;
  text-align: center;
  color: var(--text-main);
  font-weight: 700;
  font-size: 0.95rem;
  outline: none;
  -moz-appearance: textfield;
}

.quantity-controller input::-webkit-outer-spin-button,
.quantity-controller input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.result-actions {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: 12px;
}

/* Settings Items */
.settings-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.setting-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid var(--border-color);
  cursor: pointer;
}

.setting-item:last-child {
  border-bottom: none;
}

.setting-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  max-width: 80%;
}

.setting-text .title {
  font-size: 0.85rem;
  font-weight: 600;
}

.setting-text .desc {
  font-size: 0.72rem;
  color: var(--text-light);
  line-height: 1.3;
}

/* iOS Toggle Switch */
.ios-switch {
  position: relative;
  width: 46px;
  height: 24px;
  -webkit-appearance: none;
  background-color: var(--border-color);
  outline: none;
  border-radius: 12px;
  transition: background-color 0.25s;
  cursor: pointer;
}

.ios-switch:checked {
  background-color: var(--success);
}

.ios-switch::before {
  content: '';
  position: absolute;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  top: 2px;
  left: 2px;
  background-color: white;
  transition: transform 0.25s;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.4);
}

.ios-switch:checked::before {
  transform: translateX(22px);
}

/* Product DB Stats & View Styles */
.stats-mini-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  margin-bottom: 14px;
}

.stat-mini-card {
  background-color: var(--input-bg);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.stat-label {
  font-size: 0.72rem;
  color: var(--text-light);
  font-weight: 500;
}

.stat-value {
  font-size: 1.25rem;
  font-weight: 700;
}

.db-buttons-grid {
  display: grid;
  grid-template-columns: 1.2fr 1.2fr 1fr;
  gap: 10px;
}

.file-upload-btn {
  margin: 0;
  text-align: center;
}

/* Table Containers */
.search-bar-wrapper {
  position: relative;
  width: 100%;
  margin-bottom: 14px;
}

.search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-light);
  width: 18px;
  height: 18px;
}

.search-bar-wrapper input {
  padding-left: 38px;
  background-color: var(--input-bg);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding-top: 12px;
  padding-bottom: 12px;
  color: var(--text-main);
  font-size: 0.88rem;
  width: 100%;
  outline: none;
  user-select: text;
}

.table-container {
  width: 100%;
  overflow-x: auto;
  border-radius: 10px;
  border: 1px solid var(--border-color);
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.8rem;
}

.data-table th {
  background-color: var(--input-bg);
  color: var(--text-muted);
  font-weight: 600;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border-color);
  white-space: nowrap;
}

.data-table td {
  padding: 12px;
  border-bottom: 1px solid var(--border-color);
  color: var(--text-main);
  vertical-align: middle;
  user-select: text;
}

.data-table tr:last-child td {
  border-bottom: none;
}

.data-table tr:hover {
  background-color: var(--row-hover);
}

.empty-row {
  text-align: center;
  color: var(--text-light);
  padding: 30px !important;
  font-style: italic;
}

.barcode-col {
  font-family: monospace;
  color: var(--primary);
  font-weight: 500;
}

.spec-badge {
  display: inline-block;
  background-color: var(--border-color);
  color: var(--text-muted);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 0.7rem;
}

/* History and Metrics Dashboard */
.metrics-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 16px;
}

.metric-card {
  background-color: var(--input-bg);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 14px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.metric-icon {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.bg-primary-soft {
  background-color: var(--primary-soft);
  color: var(--primary);
}

.bg-success-soft {
  background-color: var(--success-soft);
  color: var(--success);
}

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

.metric-info .value {
  font-size: 1.15rem;
  font-weight: 700;
}

.metric-info .label {
  font-size: 0.72rem;
  color: var(--text-light);
}

.export-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.badge {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 4px 8px;
  border-radius: 6px;
  background-color: var(--primary-soft);
  color: var(--primary);
}

.history-item-details {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.history-item-details .name {
  font-weight: 600;
}

.history-item-details .barcode {
  font-family: monospace;
  font-size: 0.72rem;
  color: var(--text-light);
}

.history-time {
  font-size: 0.7rem;
  color: var(--text-light);
  white-space: nowrap;
}

/* History quantity widget inside table */
.history-qty-edit {
  display: flex;
  align-items: center;
  border: 1px solid var(--border-color);
  border-radius: 6px;
  overflow: hidden;
  width: 80px;
  height: 28px;
}

.history-qty-edit button {
  background: none;
  border: none;
  color: var(--text-main);
  width: 24px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.history-qty-edit input {
  flex: 1;
  width: 100%;
  border: none;
  background: var(--input-bg);
  text-align: center;
  color: var(--text-main);
  font-size: 0.75rem;
  font-weight: 600;
  outline: none;
}

/* Toast Messages */
.toast {
  position: fixed;
  bottom: 86px; /* Positioned just above the navigation bar */
  left: 50%;
  transform: translateX(-50%) translateY(100px);
  background-color: rgba(24, 24, 27, 0.95);
  border: 1px solid var(--border-color);
  color: white;
  padding: 10px 20px;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 500;
  z-index: 999;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
  transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  pointer-events: none;
  white-space: nowrap;
}

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

.toast.toast-error {
  border-color: var(--danger);
  background-color: rgba(20, 10, 10, 0.95);
}

.toast.toast-success {
  border-color: var(--success);
  background-color: rgba(10, 20, 10, 0.95);
}

/* Utility Helpers */
.hidden {
  display: none !important;
}

/* Animations */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

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

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

@keyframes pulse {
  0% { transform: scale(1); opacity: 1; box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
  70% { transform: scale(1.1); opacity: 0.8; box-shadow: 0 0 0 6px rgba(16, 185, 129, 0); }
  100% { transform: scale(1); opacity: 1; box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

@keyframes scanMove {
  0% { top: 5%; }
  50% { top: 92%; }
  100% { top: 5%; }
}

/* Password Login Screen Styles */
.login-overlay {
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  right: 0;
  width: 100%;
  height: 100%;
  background-color: var(--bg-app);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 99999;
  padding: 20px;
  transition: opacity 0.4s ease, visibility 0.4s ease;
}

.login-overlay.fade-out {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.login-card {
  width: 100%;
  max-width: 360px;
  padding: 32px 24px;
  text-align: center;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
  animation: slideUp 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.login-footer {
  margin-top: 24px;
  font-size: 0.72rem;
  color: var(--text-light);
  line-height: 1.4;
  letter-spacing: 0.2px;
}

