/* CondoPackage Theme: Base Primary #25354f */
:root {
  --primary: #25354f;
  --primary-hover: #1b273b;
  --primary-light: #344869;
  --primary-subtle: #eef2f7;
  
  --secondary: #0ea5e9;
  --accent: #6366f1;
  
  --success: #10b981;
  --success-light: #ecfdf5;
  --warning: #f59e0b;
  --warning-light: #fffbeb;
  --danger: #ef4444;
  --danger-light: #fef2f2;
  
  --bg-main: #f8fafc;
  --bg-card: #ffffff;
  --text-main: #0f172a;
  --text-muted: #64748b;
  --border: #e2e8f0;
  
  --font-family: 'Plus Jakarta Sans', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-full: 9999px;
  
  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
}

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

body {
  font-family: var(--font-family);
  background-color: var(--bg-main);
  color: var(--text-main);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  padding-bottom: 85px; /* space for mobile bottom nav */
}

/* ========================================================
   App Header (Fixed with Condominium & Active Doorman)
======================================================== */
.app-header {
  background: var(--primary);
  color: white;
  padding: 12px 16px;
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: 0 2px 10px rgba(0,0,0,0.18);
}

.header-container {
  max-width: 680px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

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

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

.brand-logo-icon {
  background: rgba(255, 255, 255, 0.15);
  width: 38px;
  height: 38px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  backdrop-filter: blur(4px);
  border: 1px solid rgba(255,255,255,0.2);
}

.brand-titles h1 {
  font-size: 1.1rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  display: flex;
  align-items: center;
  gap: 6px;
}

.brand-tag {
  font-size: 0.65rem;
  background: rgba(255,255,255,0.2);
  padding: 2px 6px;
  border-radius: var(--radius-full);
  text-transform: uppercase;
  font-weight: 700;
}

.brand-subtitle {
  font-size: 0.72rem;
  color: rgba(255,255,255,0.8);
}

/* Fixed Doorman Bar in Header */
.header-doorman-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(255, 255, 255, 0.1);
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.15);
  font-size: 0.78rem;
}

.doorman-current-info {
  display: flex;
  align-items: center;
  gap: 6px;
}

.btn-switch-doorman {
  background: rgba(255, 255, 255, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: white;
  padding: 3px 8px;
  border-radius: var(--radius-full);
  font-size: 0.72rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-switch-doorman:hover {
  background: rgba(255, 255, 255, 0.35);
}

/* Main Container */
.main-wrapper {
  max-width: 680px;
  margin: 0 auto;
  padding: 16px;
}

/* ========================================================
   Login Screen
======================================================== */
.login-screen-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: linear-gradient(135deg, #1b273b, #25354f, #344869);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.login-card {
  background: #ffffff;
  border-radius: 24px;
  width: 100%;
  max-width: 440px;
  padding: 32px 24px;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.25);
  text-align: center;
}

.login-icon-box {
  width: 64px;
  height: 64px;
  background: var(--primary-subtle);
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  margin: 0 auto 16px;
  border: 1px solid rgba(37, 53, 79, 0.1);
  transition: transform 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

.login-icon-box:hover {
  transform: translateY(-2px);
  background: rgba(37, 53, 79, 0.15);
  box-shadow: 0 4px 12px rgba(37, 53, 79, 0.12);
}

#btnLoginSystemInfoFooter:hover {
  opacity: 0.82;
}

#btnLoginSystemInfoFooter:hover > div:first-child {
  transform: translateY(-1px);
  background: rgba(30, 41, 59, 0.14) !important;
}

/* ========================================================
   Speed Dial Floating Action Button (+)
======================================================== */
.fab-container {
  position: fixed;
  bottom: 80px;
  right: 20px;
  z-index: 45;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 12px;
  pointer-events: none;
}

.fab-main-btn {
  pointer-events: auto;
  background: var(--primary);
  color: white;
  width: 58px;
  height: 58px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 20px rgba(37, 53, 79, 0.45);
  font-size: 26px;
  border: none;
  cursor: pointer;
  transition: transform 0.25s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.fab-main-btn.open {
  transform: rotate(45deg);
  background: #dc2626;
}

.fab-options {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
  opacity: 0;
  pointer-events: none;
  transform: translateY(16px);
  transition: all 0.25s ease;
}

.fab-container.open .fab-options {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.fab-action-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.fab-action-label {
  background: white;
  color: var(--primary);
  font-weight: 700;
  font-size: 0.82rem;
  padding: 6px 12px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border);
  white-space: nowrap;
}

.fab-sub-btn {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  border: none;
  cursor: pointer;
  box-shadow: var(--shadow-md);
  font-size: 20px;
  transition: transform 0.15s;
}

.fab-sub-btn:hover {
  transform: scale(1.08);
}

.fab-sub-package {
  background: var(--primary);
}

.fab-sub-qrcode {
  background: #0ea5e9;
}

.fab-backdrop {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(15, 23, 42, 0.4);
  backdrop-filter: blur(2px);
  z-index: 42;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
}

.fab-backdrop.active {
  opacity: 1;
  pointer-events: auto;
}

/* ========================================================
   Camera & Photo Capture Section
======================================================== */
.photo-capture-card {
  background: #ffffff;
  border: 2px dashed #94a3b8;
  border-radius: 16px;
  padding: 16px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
  margin-bottom: 16px;
  position: relative;
  overflow: hidden;
}

.photo-capture-card:hover {
  border-color: var(--primary);
  background: var(--primary-subtle);
}

.photo-preview-box {
  width: 100%;
  max-height: 220px;
  border-radius: 12px;
  object-fit: cover;
  border: 1px solid var(--border);
  display: none;
  margin-top: 10px;
}

.ocr-scanner-status {
  display: none;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1e40af;
  padding: 8px 12px;
  border-radius: 10px;
  font-size: 0.8rem;
  font-weight: 600;
  margin-top: 10px;
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.ocr-detected-alert {
  display: none;
  background: #ecfdf5;
  border: 1px solid #6ee7b7;
  color: #065f46;
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 0.82rem;
  margin-top: 10px;
  text-align: left;
}

.ocr-notfound-alert {
  display: none;
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  color: #475569;
  padding: 11px 14px;
  border-radius: 12px;
  font-size: 0.82rem;
  margin-top: 10px;
  text-align: left;
}

/* ========================================================
   QR Code Camera Reader Viewport (Retirada)
======================================================== */
.qr-reader-wrapper {
  background: #ffffff;
  border-radius: 18px;
  padding: 16px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  margin-bottom: 16px;
}

#qrCameraViewport {
  width: 100% !important;
  border-radius: 14px;
  overflow: hidden;
  background: #000;
}

/* Dashboard Summary Cards */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-bottom: 20px;
}

@media (max-width: 500px) {
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.stat-card {
  background: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 12px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  cursor: pointer;
  user-select: none;
  transition: transform 0.15s, box-shadow 0.15s, border-color 0.15s, background-color 0.15s;
}

.stat-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: #94a3b8;
}

.stat-card:active {
  transform: translateY(0);
}

.stat-card.active-stat-card {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(37, 53, 79, 0.2), var(--shadow-sm);
}

.stat-card.stat-bulky {
  border-left: 4px solid var(--danger);
  background: linear-gradient(to bottom, #ffffff, #fff5f5);
}

.stat-card.stat-bulky.active-stat-card {
  border-color: var(--danger);
  box-shadow: 0 0 0 2px rgba(239, 68, 68, 0.22), var(--shadow-sm);
}

.stat-card.stat-overdue {
  border-left: 4px solid var(--warning);
  background: linear-gradient(to bottom, #ffffff, #fffbeb);
}

.stat-card.stat-overdue.active-stat-card {
  border-color: var(--warning);
  box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.25), var(--shadow-sm);
}

.stat-title {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.stat-value {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--primary);
  margin-top: 4px;
}

.stat-bulky .stat-value { color: var(--danger); }
.stat-overdue .stat-value { color: #d97706; }

/* Filter Tabs */
.filter-tabs {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 6px;
  margin-bottom: 16px;
  scrollbar-width: none;
}
.filter-tabs::-webkit-scrollbar { display: none; }

.filter-chip {
  background: var(--bg-card);
  border: 1px solid var(--border);
  padding: 7px 14px;
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  white-space: nowrap;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s;
}

.filter-chip.active {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
  box-shadow: 0 2px 6px rgba(37, 53, 79, 0.25);
}

.chip-count {
  background: rgba(0, 0, 0, 0.08);
  padding: 1px 6px;
  border-radius: var(--radius-full);
  font-size: 0.72rem;
}
.filter-chip.active .chip-count {
  background: rgba(255, 255, 255, 0.25);
  color: white;
}

/* Search Bar */
.search-box-wrapper {
  position: relative;
  margin-bottom: 16px;
}

.search-input {
  width: 100%;
  padding: 12px 16px 12px 42px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: var(--bg-card);
  font-size: 0.9rem;
  font-family: inherit;
  box-shadow: var(--shadow-sm);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.search-input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(37, 53, 79, 0.15);
}

.search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 16px;
}

/* Package Feed Cards */
.package-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.package-card {
  background: var(--bg-card);
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  padding: 16px;
  position: relative;
  transition: transform 0.15s, box-shadow 0.15s;
}

.package-card:active {
  transform: scale(0.99);
}

.package-card.bulky-border {
  border-left: 5px solid var(--danger);
}

.package-card.overdue-border {
  border-left: 5px solid var(--warning);
}

.package-card.delivered-border {
  border-left: 5px solid var(--success);
  opacity: 0.85;
}

.package-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 10px;
}

.destination-badge {
  background: var(--primary-subtle);
  color: var(--primary);
  font-weight: 800;
  font-size: 0.92rem;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid rgba(37, 53, 79, 0.15);
}

.tracking-code-pill {
  font-family: monospace;
  font-weight: 700;
  font-size: 0.82rem;
  background: #f1f5f9;
  color: #334155;
  padding: 3px 8px;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  cursor: pointer;
  user-select: none;
  transition: all 0.15s ease;
  border: 1px solid #e2e8f0;
}

.tracking-code-pill:hover {
  background: #e2e8f0;
  color: var(--primary);
  border-color: #cbd5e1;
  transform: translateY(-1px);
}

.tracking-code-pill:active {
  transform: translateY(0);
}

.recipient-name {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 4px;
}

.package-details-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 10px;
}

.detail-item {
  display: flex;
  align-items: center;
  gap: 4px;
}

/* Badges */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 8px;
  border-radius: var(--radius-full);
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
}

.badge-bulky {
  background: var(--danger-light);
  color: var(--danger);
  border: 1px solid rgba(239, 68, 68, 0.3);
  animation: pulse-bulky 2s infinite;
}

@keyframes pulse-bulky {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.8; }
}

.badge-overdue {
  background: var(--warning-light);
  color: #b45309;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.badge-delivered {
  background: var(--success-light);
  color: var(--success);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.package-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px dashed var(--border);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 14px;
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  font-weight: 600;
  font-family: inherit;
  border: none;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
}

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

.btn-secondary {
  background: #f1f5f9;
  color: #334155;
}
.btn-secondary:hover {
  background: #e2e8f0;
}

.btn-danger {
  background: #fef2f2;
  color: var(--danger);
  border: 1px solid #fecaca;
}
.btn-danger:hover {
  background: #fee2e2;
}

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

.btn-whatsapp {
  background: #25D366;
  color: white;
  font-weight: 700;
}
.btn-whatsapp:hover {
  background: #1ebc59;
}

.btn-sm {
  padding: 6px 10px;
  font-size: 0.78rem;
  border-radius: var(--radius-sm);
}

.btn-block {
  width: 100%;
}

/* Mobile Bottom Navigation Bar (Portaria, Retirada, Ajustes) */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 65px;
  background: #ffffff;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-around;
  align-items: center;
  z-index: 40;
  box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.05);
}

.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  transition: all 0.15s;
  background: none;
  border: none;
  cursor: pointer;
  flex: 1;
}

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

.nav-item.active .nav-icon {
  background: var(--primary-subtle);
  color: var(--primary);
  border-radius: var(--radius-md);
}

.nav-icon {
  font-size: 20px;
  width: 34px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

/* Forms & Modals */
.form-group {
  position: relative;
  margin-bottom: 14px;
  text-align: left;
  cursor: text;
}

.form-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 700;
  color: #334155;
  margin-bottom: 6px;
  cursor: pointer;
  user-select: none;
}

.form-input, .form-select, .form-textarea {
  width: 100%;
  display: block;
  min-height: 48px;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: #ffffff;
  font-family: inherit;
  font-size: 16px; /* Prevents auto-zoom on mobile and ensures entire field is interactive */
  line-height: normal; /* Normal line-height ensures natural vertical caret centering and click handling */
  outline: none;
  box-sizing: border-box;
  -webkit-appearance: none;
  appearance: none;
  -webkit-user-select: text;
  user-select: text;
  touch-action: manipulation;
  cursor: text;
  pointer-events: auto;
  position: relative;
  z-index: 1;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.form-select {
  cursor: pointer;
}

.form-input:focus, .form-select:focus, .form-textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(37, 53, 79, 0.15);
}

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

/* Bulky Package Toggle Box */
.bulky-toggle-box {
  background: #fff5f5;
  border: 2px dashed #fca5a5;
  border-radius: var(--radius-md);
  padding: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 14px 0;
  cursor: pointer;
}

.bulky-toggle-info {
  display: flex;
  align-items: center;
  gap: 10px;
}

.bulky-toggle-icon {
  font-size: 22px;
  color: var(--danger);
}

.switch {
  position: relative;
  display: inline-block;
  width: 48px;
  height: 26px;
}
.switch input { opacity: 0; width: 0; height: 0; }
.slider {
  position: absolute; cursor: pointer; top: 0; left: 0; right: 0; bottom: 0;
  background-color: #cbd5e1;
  transition: .3s;
  border-radius: 34px;
}
.slider:before {
  position: absolute; content: ""; height: 20px; width: 20px; left: 3px; bottom: 3px;
  background-color: white;
  transition: .3s;
  border-radius: 50%;
}
input:checked + .slider { background-color: var(--danger); }
input:checked + .slider:before { transform: translateX(22px); }

/* Modal Backdrop */
.modal-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(4px);
  display: none !important;
  align-items: flex-end;
  justify-content: center;
  z-index: 999;
  opacity: 0;
  pointer-events: none !important;
  transition: opacity 0.25s ease;
}

@media (min-width: 640px) {
  .modal-overlay {
    align-items: center;
  }
}

.modal-overlay.active {
  display: flex !important;
  opacity: 1;
  pointer-events: auto !important;
}

.modal-content {
  background: white;
  width: 100%;
  max-width: 520px;
  border-radius: 24px 24px 0 0;
  padding: 24px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
  transform: translateY(100%);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@media (min-width: 640px) {
  .modal-content {
    border-radius: var(--radius-lg);
    transform: scale(0.95);
  }
}

.modal-overlay.active .modal-content {
  transform: translateY(0);
}
@media (min-width: 640px) {
  .modal-overlay.active .modal-content {
    transform: scale(1);
  }
}

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

.modal-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--primary);
}

.btn-close-modal {
  background: #f1f5f9;
  border: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
}

/* Doorman Chips */
.doorman-chips-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 10px 0;
}

.doorman-chip {
  background: #f1f5f9;
  border: 1px solid var(--border);
  padding: 6px 12px;
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--primary);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.15s;
}

.doorman-chip.active {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
}

.doorman-chip-remove {
  color: #94a3b8;
  cursor: pointer;
  padding: 2px;
  font-size: 11px;
}
.doorman-chip-remove:hover {
  color: var(--danger);
}

/* Advanced Settings Accordion */
details.advanced-settings-accordion summary {
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

details.advanced-settings-accordion summary::-webkit-details-marker {
  display: none;
}

details.advanced-settings-accordion summary::after {
  content: '▼';
  font-size: 0.72rem;
  color: var(--text-muted);
  transition: transform 0.2s;
}

details.advanced-settings-accordion[open] summary::after {
  transform: rotate(180deg);
}

.package-card:hover {
  border-color: #cbd5e1;
  box-shadow: var(--shadow-md);
}

/* ========================================================
   Vertical Visual Timeline Component
======================================================== */
.timeline {
  position: relative;
  padding-left: 28px;
  margin-top: 14px;
}

.timeline-item {
  position: relative;
  margin-bottom: 22px;
}

.timeline-item:not(:last-child)::before {
  content: '';
  position: absolute;
  top: 14px;
  bottom: -36px;
  left: -15px;
  width: 2px;
  background: #cbd5e1;
  z-index: 1;
}

.timeline-item:last-child {
  margin-bottom: 0;
}

.timeline-marker {
  position: absolute;
  left: -28px;
  top: 0;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: white;
  border: 2px solid var(--primary);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.08);
  z-index: 2;
}

.timeline-marker.delivered {
  border-color: var(--primary);
  background: var(--primary);
  color: #ffffff;
}

.timeline-marker.pending {
  border: 2px dashed #94a3b8;
  background: #f8fafc;
  color: #94a3b8;
}

.timeline-content {
  background: #f8fafc;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 10px 14px;
  margin-left: 10px;
}

.timeline-time {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-muted);
  margin-bottom: 2px;
}

.timeline-title {
  font-size: 0.88rem;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 2px;
}

.timeline-description {
  font-size: 0.78rem;
  color: #475569;
}

.timeline-actor {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 4px;
}

