/* Customer Portal Styles */

.app-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100vh;
  gap: 20px;
}
.loading-logo { font-size: 56px; animation: pulse 1.5s ease-in-out infinite; }
@keyframes pulse { 0%,100%{transform:scale(1)} 50%{transform:scale(1.1)} }

/* Auth Page */
.auth-page {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
}
.auth-brand {
  background: linear-gradient(135deg, var(--primary) 0%, #7c3aed 100%);
  padding: 60px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  color: white;
  position: relative;
  overflow: hidden;
}
.auth-brand::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 600px; height: 600px;
  background: rgba(255,255,255,0.05);
  border-radius: 50%;
}
.auth-brand-logo { font-size: 40px; font-weight: 800; display: flex; align-items: center; gap: 12px; }
.auth-brand h1 { font-size: 42px; font-weight: 800; line-height: 1.2; margin: auto 0; }
.auth-brand p { font-size: 18px; opacity: 0.8; margin-top: 12px; }
.auth-features { display: flex; flex-direction: column; gap: 16px; }
.auth-feature { display: flex; align-items: center; gap: 12px; font-size: 15px; }
.auth-feature-icon { width: 36px; height: 36px; background: rgba(255,255,255,0.15); border-radius: 8px; display: flex; align-items: center; justify-content: center; }
.auth-form-side {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
  background: var(--bg);
}
.auth-form-box {
  width: 100%;
  max-width: 420px;
}
.auth-form-box h2 { font-size: 28px; font-weight: 800; margin-bottom: 8px; }
.auth-form-box p { color: var(--text-secondary); margin-bottom: 32px; }
.auth-tabs {
  display: flex;
  background: var(--border);
  border-radius: 8px;
  padding: 3px;
  margin-bottom: 28px;
}
.auth-tab {
  flex: 1;
  padding: 8px;
  text-align: center;
  border-radius: 6px;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  transition: all 0.2s;
}
.auth-tab.active { background: var(--card); color: var(--text); box-shadow: var(--shadow-sm); }

/* Layout */
.customer-layout {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
.main-content {
  flex: 1;
  overflow-y: auto;
  padding-bottom: 72px;
}
.bottom-nav {
  display: flex;
  align-items: center;
  justify-content: space-around;
  background: var(--card);
  border-top: 1px solid var(--border);
  padding: 6px 8px 10px;
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 500;
  backdrop-filter: blur(12px);
}
.bn-item {
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  padding: 6px 14px; border-radius: 10px;
  background: none; border: none; cursor: pointer;
  color: var(--text-secondary); flex: 1;
  transition: all 0.15s;
}
.bn-item:hover { color: #6366f1; background: rgba(99,102,241,0.08); }
.bn-active { color: #6366f1 !important; }
.bn-icon { font-size: 20px; line-height: 1; }
.bn-label { font-size: 10px; font-weight: 600; }
.bn-center-btn {
  width: 52px; height: 52px;
  background: linear-gradient(135deg, #6366f1, #8b5cf6) !important;
  border-radius: 50% !important;
  display: flex; align-items: center; justify-content: center;
  padding: 0 !important; margin-top: -20px; flex: 0 0 52px;
  box-shadow: 0 4px 16px rgba(99,102,241,0.45);
}
.bn-center-btn:hover { transform: scale(1.08) translateY(-2px) !important; box-shadow: 0 8px 24px rgba(99,102,241,0.55) !important; }
.bn-plus { color: white; font-size: 28px; font-weight: 300; line-height: 1; }
.bn-icon-wrap { position: relative; display: flex; align-items: center; justify-content: center; }
.bn-badge {
  position: absolute; top: -6px; right: -8px;
  min-width: 16px; height: 16px;
  background: #ef4444; color: white;
  border-radius: 100px; font-size: 9px; font-weight: 800;
  display: flex; align-items: center; justify-content: center;
  padding: 0 3px; border: 2px solid var(--card);
}
.bn-item.bn-active .bn-icon { filter: none; }
.bn-item.bn-active .bn-label { color: #6366f1; font-weight: 800; }
.sidebar { display: none; }
.sidebar-logo {
  padding: 0 20px 24px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  margin-bottom: 16px;
}
.sidebar-logo-text { font-size: 20px; font-weight: 800; color: white; display: flex; align-items: center; gap: 10px; }
.sidebar-logo-sub { font-size: 11px; color: var(--sidebar-text); margin-top: 2px; text-transform: uppercase; letter-spacing: 1px; }
.sidebar-nav { flex: 1; padding: 0 12px; }
.sidebar-label {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.5px;
  color: rgba(148,163,184,0.5);
  text-transform: uppercase;
  padding: 16px 8px 8px;
}
.sidebar-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  color: var(--sidebar-text);
  font-weight: 500;
  transition: all 0.15s;
  cursor: pointer;
  margin-bottom: 2px;
  border: none;
  background: none;
  width: 100%;
  text-align: left;
  font-size: 14px;
}
.sidebar-item:hover { background: var(--sidebar-hover); color: white; }
.sidebar-item.active { background: rgba(79,70,229,0.25); color: white; }
.sidebar-item.active .sidebar-icon { color: var(--primary); }
.sidebar-icon { font-size: 18px; flex-shrink: 0; }
.sidebar-badge {
  margin-left: auto;
  background: var(--primary);
  color: white;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 100px;
}
.sidebar-footer {
  padding: 16px 20px;
  border-top: 1px solid rgba(255,255,255,0.08);
  margin-top: auto;
}
.sidebar-user { display: flex; align-items: center; gap: 12px; }
.sidebar-avatar {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: var(--primary);
  color: white;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 14px;
  flex-shrink: 0;
}
.sidebar-user-name { font-size: 13px; font-weight: 600; color: white; }
.sidebar-user-email { font-size: 11px; color: var(--sidebar-text); }
.sidebar-logout { margin-left: auto; background: none; border: none; color: var(--sidebar-text); font-size: 18px; cursor: pointer; transition: color 0.15s; }
.sidebar-logout:hover { color: var(--error); }

/* Main content */
.main-content { overflow-y: auto; }
.page-header {
  background: var(--card);
  padding: 24px 32px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 100;
}
.page-title { font-size: 22px; font-weight: 800; }
.page-subtitle { font-size: 13px; color: var(--text-secondary); margin-top: 2px; }
.page-body { padding: 32px 32px 100px; }

/* Hero section */
.hero-banner {
  background: linear-gradient(135deg, var(--primary) 0%, #7c3aed 100%);
  border-radius: var(--radius-lg);
  padding: 32px;
  color: white;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 32px;
  overflow: hidden;
  position: relative;
}
.hero-banner::before {
  content: '🖨️';
  position: absolute;
  right: -20px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 120px;
  opacity: 0.15;
}
.hero-text h2 { font-size: 24px; font-weight: 800; margin-bottom: 6px; }
.hero-text p { opacity: 0.85; font-size: 15px; margin-bottom: 20px; }

/* Order form */
.order-stepper { display: flex; gap: 0; margin-bottom: 32px; }
.step-item {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 12px;
}
.step-item:not(:last-child)::after {
  content: '';
  flex: 1;
  height: 2px;
  background: var(--border);
}
.step-item.active:not(:last-child)::after,
.step-item.done:not(:last-child)::after { background: var(--primary); }
.step-num {
  width: 32px; height: 32px;
  border-radius: 50%;
  background: var(--border);
  color: var(--text-secondary);
  display: flex; align-items: center; justify-content: center;
  font-size: 13px;
  font-weight: 700;
  flex-shrink: 0;
}
.step-item.active .step-num { background: var(--primary); color: white; }
.step-item.done .step-num { background: var(--success); color: white; }
.step-label { font-size: 13px; font-weight: 600; white-space: nowrap; }
.step-item.active .step-label { color: var(--primary); }
.step-item.done .step-label { color: var(--success); }

/* File list */
.file-list { display: flex; flex-direction: column; gap: 10px; margin-top: 16px; }
.file-item {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--card-2);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  border: 1px solid var(--border);
}
.file-icon { font-size: 24px; flex-shrink: 0; }
.file-info { flex: 1; min-width: 0; }
.file-name { font-size: 13px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-meta { font-size: 11px; color: var(--text-secondary); }
.file-remove { background: none; border: none; color: var(--error); font-size: 18px; cursor: pointer; flex-shrink: 0; opacity: 0.6; transition: opacity 0.2s; }
.file-remove:hover { opacity: 1; }
.upload-progress { margin-top: 8px; }

/* Print settings */
.settings-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.option-group { display: flex; gap: 8px; flex-wrap: wrap; }
.option-btn {
  padding: 8px 16px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--card);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
  color: var(--text);
}
.option-btn:hover { border-color: var(--primary); color: var(--primary); }
.option-btn.selected { border-color: var(--primary); background: var(--primary-light); color: var(--primary); }
.copies-control { display: flex; align-items: center; gap: 0; border: 1.5px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; width: fit-content; }
.copies-btn { width: 36px; height: 36px; border: none; background: var(--card-2); font-size: 18px; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.copies-btn:hover { background: var(--border); }
.copies-num { min-width: 48px; text-align: center; font-weight: 700; border: none; border-left: 1.5px solid var(--border); border-right: 1.5px solid var(--border); padding: 8px; font-size: 15px; }

/* Price summary */
.price-card {
  background: var(--card);
  border-radius: var(--radius);
  border: 2px solid var(--primary);
  overflow: hidden;
}
.price-header {
  background: var(--primary);
  color: white;
  padding: 16px 20px;
  font-weight: 700;
  font-size: 15px;
  display: flex; align-items: center; gap: 8px;
}
.price-body { padding: 20px; }
.price-row { display: flex; justify-content: space-between; align-items: center; padding: 8px 0; font-size: 14px; }
.price-row.total { font-size: 20px; font-weight: 800; color: var(--primary); padding-top: 16px; border-top: 2px solid var(--border); margin-top: 8px; }
.price-divider { border: none; border-top: 1px dashed var(--border); margin: 8px 0; }

/* Order tracking */
.tracking-timeline { display: flex; flex-direction: column; gap: 0; }
.tracking-step { display: flex; gap: 16px; }
.tracking-step-left { display: flex; flex-direction: column; align-items: center; }
.tracking-dot {
  width: 20px; height: 20px;
  border-radius: 50%;
  background: var(--border);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  font-size: 10px;
}
.tracking-dot.done { background: var(--success); color: white; }
.tracking-dot.active { background: var(--primary); color: white; animation: trackingPulse 1.5s ease infinite; }
@keyframes trackingPulse { 0%,100%{box-shadow:0 0 0 0 rgba(79,70,229,0.4)} 50%{box-shadow:0 0 0 8px rgba(79,70,229,0)} }
.tracking-line { width: 2px; flex: 1; background: var(--border); margin: 4px 0; min-height: 32px; }
.tracking-line.done { background: var(--success); }
.tracking-content { padding-bottom: 24px; }
.tracking-label { font-weight: 700; font-size: 14px; }
.tracking-time { font-size: 12px; color: var(--text-secondary); margin-top: 2px; }
.tracking-step:last-child .tracking-line { display: none; }

/* Notifications */
.topbar-notif {
  position: relative;
  cursor: pointer;
  width: 40px; height: 40px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  background: var(--card);
  border: 1.5px solid var(--border);
  font-size: 18px;
}
.notif-badge {
  position: absolute;
  top: -4px; right: -4px;
  width: 18px; height: 18px;
  background: var(--error);
  color: white;
  border-radius: 50%;
  font-size: 10px;
  font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}

/* Refer & earn */
.refer-card {
  background: linear-gradient(135deg, #f59e0b 0%, #ef4444 100%);
  border-radius: var(--radius);
  padding: 20px;
  color: white;
}
.refer-card h4 { font-size: 16px; font-weight: 800; margin-bottom: 6px; }
.refer-card p { font-size: 13px; opacity: 0.9; margin-bottom: 14px; }
.refer-card .btn { background: white; color: #f59e0b; font-weight: 700; }

/* How it works */
.how-steps { display: flex; gap: 24px; align-items: flex-start; }
.how-step { flex: 1; text-align: center; }
.how-icon { font-size: 36px; margin-bottom: 12px; }
.how-title { font-size: 13px; font-weight: 700; margin-bottom: 4px; }
.how-desc { font-size: 12px; color: var(--text-secondary); }
.how-arrow { color: var(--border); font-size: 24px; margin-top: 16px; }

/* Recent orders card */
.order-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
}
.order-card:last-child { border-bottom: none; }
.order-card-num { font-family: var(--font-mono); font-weight: 700; font-size: 14px; }
.order-card-meta { font-size: 12px; color: var(--text-secondary); margin-top: 2px; }
.order-card-amount { font-weight: 800; font-size: 15px; margin-left: auto; color: var(--primary); font-family: var(--font-mono); }
.order-card-chevron { color: var(--text-tertiary); font-size: 16px; }

/* Mobile nav */
@media (max-width: 768px) {
  .auth-page { grid-template-columns: 1fr; }
  .auth-brand { display: none; }
  .customer-layout { grid-template-columns: 1fr; }
  .sidebar { position: fixed; bottom: 0; top: auto; left: 0; right: 0; height: 64px; flex-direction: row; padding: 0; z-index: 200; }
  .sidebar-logo, .sidebar-label, .sidebar-user-email, .sidebar-badge, .sidebar-footer { display: none; }
  .sidebar-nav { display: flex; padding: 0; }
  .sidebar-item { flex-direction: column; gap: 4px; padding: 8px 12px; font-size: 10px; flex: 1; justify-content: center; }
  .sidebar-icon { font-size: 22px; }
  .main-content { padding-bottom: 80px; }
  .page-body { padding: 20px 16px; }
  .settings-grid { grid-template-columns: 1fr; }
  .hero-banner { flex-direction: column; align-items: flex-start; }
}

/* ========================================
   PRINTEXPRESS DASHBOARD STYLES
   ======================================== */

/* Override layout for PrintExpress dashboard */
.pe-layout {
  display: flex;
  flex-direction: column;
  min-height: calc(100vh - 72px);
}

/* TOP BAR */
.pe-topbar {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 12px 20px;
  background: var(--card);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 200;
}
.pe-topbar-left { display: flex; align-items: center; gap: 16px; flex-shrink: 0; }
.pe-logo { display: flex; align-items: center; gap: 6px; }
.pe-logo-p {
  width: 32px; height: 32px;
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  color: white;
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 16px;
}
.pe-logo-text { font-size: 17px; font-weight: 800; color: var(--text); }
.pe-location {
  display: flex; align-items: center; gap: 4px;
  font-size: 12px; color: var(--text-secondary);
  cursor: pointer; padding: 4px 8px;
  border-radius: 6px; border: 1px solid var(--border);
}
.pe-topbar-search {
  flex: 1;
  position: relative;
}
.pe-search-icon { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); font-size: 14px; opacity: 0.5; }
.pe-search-input {
  width: 100%;
  padding: 9px 14px 9px 36px;
  border: 1.5px solid var(--border);
  border-radius: 10px;
  font-size: 13px;
  background: var(--card-2);
  color: var(--text);
  outline: none;
  transition: border-color 0.2s;
}
.pe-search-input:focus { border-color: #6366f1; }
.pe-topbar-right { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.pe-upload-btn {
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  color: white; border: none;
  padding: 9px 18px; border-radius: 10px;
  font-size: 13px; font-weight: 700;
  cursor: pointer; white-space: nowrap;
  transition: transform 0.2s, box-shadow 0.2s;
}
.pe-upload-btn:hover { transform: translateY(-1px); box-shadow: 0 4px 16px rgba(99,102,241,0.4); }
.pe-cart { position: relative; padding: 8px; cursor: pointer; font-size: 18px; }
.pe-cart-badge {
  position: absolute; top: 0; right: 0;
  width: 16px; height: 16px;
  background: #ef4444; color: white;
  border-radius: 50%; font-size: 9px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}
.pe-user-chip {
  display: flex; align-items: center; gap: 8px;
  padding: 5px 10px; border-radius: 24px;
  border: 1.5px solid var(--border); cursor: pointer;
  font-size: 13px; font-weight: 600;
}
.pe-signout-btn {
  display: flex; align-items: center; gap: 6px;
  padding: 7px 14px; border-radius: 10px;
  border: 1.5px solid #fecaca;
  background: #fff5f5; color: #dc2626;
  font-size: 13px; font-weight: 700;
  cursor: pointer; white-space: nowrap;
  transition: all 0.2s;
}
.pe-signout-btn:hover {
  background: #dc2626; color: white;
  border-color: #dc2626;
  box-shadow: 0 4px 12px rgba(220,38,38,0.25);
  transform: translateY(-1px);
}
.pe-signout-icon { font-size: 15px; line-height: 1; }
.pe-signout-label { font-size: 13px; }
.pe-user-avatar {
  width: 28px; height: 28px; border-radius: 50%;
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  color: white; display: flex; align-items: center;
  justify-content: center; font-weight: 700; font-size: 12px;
}

/* BODY LAYOUT — no sidebar, 2 columns */
.pe-body {
  display: grid;
  grid-template-columns: 1fr 280px;
  flex: 1;
  min-height: 0;
  overflow: hidden;
}

/* BOTTOM NAV BAR */
.pe-bottom-nav {
  display: flex;
  align-items: center;
  justify-content: space-around;
  background: var(--card);
  border-top: 1px solid var(--border);
  padding: 6px 0 8px;
  position: sticky;
  bottom: 0;
  z-index: 300;
  flex-shrink: 0;
}
.pe-bn-item {
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  padding: 6px 12px; border-radius: 10px;
  background: none; border: none; cursor: pointer;
  color: var(--text-secondary); font-size: 12px; font-weight: 600;
  transition: all 0.15s; min-width: 52px;
}
.pe-bn-item:hover { color: #6366f1; background: #f0f4ff; }
.pe-bn-active { color: #6366f1 !important; }
.pe-bn-icon { font-size: 20px; line-height: 1; }
.pe-bn-label { font-size: 10px; font-weight: 600; }
.pe-bn-center {
  width: 48px; height: 48px;
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  border-radius: 50% !important;
  display: flex; align-items: center; justify-content: center;
  padding: 0; margin-top: -18px;
  box-shadow: 0 4px 14px rgba(99,102,241,0.4);
  flex-shrink: 0;
}
.pe-bn-plus { color: white; font-size: 26px; line-height: 1; font-weight: 300; margin-top: -2px; }

/* MAIN CONTENT */
.pe-main {
  overflow-y: auto;
  padding: 20px 24px 80px;
  display: flex; flex-direction: column; gap: 24px;
}

/* HERO BANNER */
.pe-hero {
  background: linear-gradient(135deg, #6366f1 0%, #a855f7 60%, #ec4899 100%);
  border-radius: 16px;
  padding: 32px 36px;
  color: white;
  display: flex; align-items: center;
  position: relative; overflow: hidden;
  min-height: 180px;
}
.pe-hero::before {
  content: '';
  position: absolute; inset: 0;
  background: radial-gradient(circle at 70% 50%, rgba(255,255,255,0.08) 0%, transparent 60%);
}
.pe-hero-content { flex: 1; position: relative; z-index: 1; }
.pe-hero-title { font-size: 28px; font-weight: 900; line-height: 1.15; margin-bottom: 10px; }
.pe-hero-accent { color: #fde68a; }
.pe-hero-sub { font-size: 14px; opacity: 0.85; margin-bottom: 20px; line-height: 1.5; }
.pe-hero-btns { display: flex; gap: 10px; flex-wrap: wrap; }
.pe-hero-primary {
  background: white; color: #6366f1;
  border: none; padding: 10px 20px; border-radius: 10px;
  font-size: 13px; font-weight: 700; cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}
.pe-hero-primary:hover { transform: translateY(-1px); box-shadow: 0 6px 20px rgba(0,0,0,0.15); }
.pe-hero-secondary {
  background: rgba(255,255,255,0.15);
  border: 1.5px solid rgba(255,255,255,0.4);
  color: white; padding: 10px 20px; border-radius: 10px;
  font-size: 13px; font-weight: 700; cursor: pointer;
  backdrop-filter: blur(4px);
  transition: background 0.2s;
}
.pe-hero-secondary:hover { background: rgba(255,255,255,0.25); }
.pe-hero-visual {
  flex-shrink: 0; position: relative; z-index: 1;
  margin-left: 20px;
}
.pe-printer-wrap {
  position: relative; width: 200px; height: 180px;
  display: flex; align-items: center; justify-content: center;
  /* Gradient matching the hero so the white JPEG background vanishes */
  background: linear-gradient(135deg, #7c7ff5 0%, #b56ef8 55%, #ee6cac 100%);
  border-radius: 20px;
  overflow: hidden;
}
.pe-printer-img {
  width: 200px;
  height: 180px;
  object-fit: contain;
  /* multiply blends white pixels with the gradient underneath */
  mix-blend-mode: multiply;
  animation: floatDoc 3.5s ease-in-out infinite;
  filter: drop-shadow(0 8px 18px rgba(80,40,160,0.30));
}
@keyframes floatDoc {
  0%,100% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
}
.pe-hero-dots {
  position: absolute; bottom: 16px; left: 50%;
  transform: translateX(-50%);
  display: flex; gap: 6px;
}
.pe-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: rgba(255,255,255,0.4);
}
.pe-dot.active { background: white; }

/* SECTIONS */
.pe-section {}
.pe-sec-hdr {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 14px;
}
.pe-sec-hdr h3 { font-size: 16px; font-weight: 800; }
.pe-view-all {
  font-size: 12px; font-weight: 700; color: #6366f1;
  background: none; border: none; cursor: pointer; padding: 4px 0;
}
.pe-view-all:hover { text-decoration: underline; }

/* SERVICES GRID */
.pe-services-grid {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 10px;
}
.pe-svc-chip {
  display: flex; flex-direction: column; align-items: center;
  gap: 8px; padding: 12px 8px; border-radius: 12px;
  cursor: pointer; transition: transform 0.2s, box-shadow 0.2s;
}
.pe-svc-chip:hover { transform: translateY(-2px); box-shadow: 0 4px 16px rgba(0,0,0,0.08); }
.pe-svc-icon {
  width: 44px; height: 44px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 22px;
}
.pe-svc-label { font-size: 11px; font-weight: 700; text-align: center; line-height: 1.3; color: var(--text); }

/* HOW IT WORKS */
.pe-how-row {
  display: flex; align-items: flex-start;
  background: var(--card); border-radius: 14px;
  padding: 20px 16px; border: 1px solid var(--border);
  overflow-x: auto;
}
.pe-how-step {
  flex: 1; min-width: 80px;
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  text-align: center;
}
.pe-how-num-badge {
  width: 22px; height: 22px; border-radius: 50%;
  background: #6366f1; color: white;
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 800;
}
.pe-how-icon {
  width: 48px; height: 48px; border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 22px;
}
.pe-how-title { font-size: 12px; font-weight: 700; }
.pe-how-desc { font-size: 10px; color: var(--text-secondary); line-height: 1.3; }
.pe-how-arrow { color: var(--border); font-size: 20px; margin-top: 30px; padding: 0 4px; flex-shrink: 0; }

/* OFFERS */
.pe-offers-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}
.pe-offer {
  border-radius: 14px; padding: 16px;
  display: flex; flex-direction: column; gap: 4px;
  position: relative; overflow: hidden;
}
.pe-offer-emoji { font-size: 28px; margin-bottom: 4px; }
.pe-offer-head { font-size: 16px; font-weight: 800; }
.pe-offer-info { font-size: 12px; opacity: 0.8; line-height: 1.3; }
.pe-offer-code { font-size: 11px; margin-top: 4px; }
.pe-offer-cta {
  margin-top: 8px; padding: 7px 14px;
  border-radius: 8px; border: none;
  font-size: 12px; font-weight: 700;
  cursor: pointer; align-self: flex-start;
  transition: opacity 0.2s;
}
.pe-offer-cta:hover { opacity: 0.85; }
.pe-offer-pink { background: #fff0f5; color: #be185d; }
.pe-offer-pink .pe-offer-cta { background: #ec4899; color: white; }
.pe-offer-green { background: #f0fff4; color: #065f46; }
.pe-offer-green .pe-offer-cta { background: #10b981; color: white; }
.pe-offer-blue { background: #f0f9ff; color: #0c4a6e; }
.pe-offer-blue .pe-offer-cta { background: #0ea5e9; color: white; }
.pe-offer-orange { background: #fff7ed; color: #9a3412; }
.pe-offer-orange .pe-offer-cta { background: #f97316; color: white; }

/* PRICING */
.pe-price-row {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 10px;
}
.pe-price-tile {
  background: var(--card); border: 1px solid var(--border);
  border-radius: 12px; padding: 16px 12px;
  text-align: center; cursor: default;
  transition: box-shadow 0.2s;
}
.pe-price-tile:hover { box-shadow: 0 4px 16px rgba(0,0,0,0.06); }
.pe-ptile-icon { font-size: 24px; margin-bottom: 6px; }
.pe-ptile-name { font-size: 11px; font-weight: 600; color: var(--text-secondary); margin-bottom: 6px; }
.pe-ptile-val { font-size: 20px; font-weight: 900; color: #6366f1; }
.pe-ptile-val small { font-size: 11px; font-weight: 500; color: var(--text-secondary); }
.pe-ptile-accent { background: #f0f4ff; border-color: #c7d2fe; }
.pe-ptile-cta {
  background: linear-gradient(135deg, #6366f1, #8b5cf6) !important;
  border: none; cursor: pointer;
}
.pe-ptile-cta .pe-ptile-icon { filter: none; }

/* TEMPLATES */
.pe-templates-row {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 12px;
}
.pe-tpl-card {
  border-radius: 14px; padding: 16px 12px;
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  cursor: pointer; transition: transform 0.2s, box-shadow 0.2s;
  border: 1px solid rgba(0,0,0,0.04);
}
.pe-tpl-card:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(0,0,0,0.08); }
.pe-tpl-icon { font-size: 36px; }
.pe-tpl-name { font-size: 11px; font-weight: 700; text-align: center; color: var(--text); line-height: 1.3; }
.pe-tpl-btn {
  background: rgba(99,102,241,0.1); color: #6366f1;
  border: none; padding: 4px 10px; border-radius: 6px;
  font-size: 11px; font-weight: 700; cursor: pointer;
  margin-top: 2px;
}

/* RIGHT PANEL */
.pe-right {
  overflow-y: auto;
  padding: 16px 16px 80px;
  display: flex; flex-direction: column; gap: 14px;
  border-left: 1px solid var(--border);
  background: var(--bg);
}
.pe-right-card {
  background: var(--card);
  border-radius: 14px; padding: 16px;
  border: 1px solid var(--border);
}

/* OFFERS OF THE DAY */
.pe-day-offers { }
.pe-do-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 12px;
}
.pe-do-title { font-size: 13px; font-weight: 800; }
.pe-countdown { display: flex; align-items: center; gap: 4px; }
.pe-cd-seg {
  display: flex; flex-direction: column; align-items: center;
  background: var(--card-2); border-radius: 6px; padding: 3px 6px;
}
.pe-cd-seg span { font-size: 14px; font-weight: 800; color: #6366f1; font-family: var(--font-mono); line-height: 1; }
.pe-cd-seg small { font-size: 8px; color: var(--text-secondary); font-weight: 600; }
.pe-mega-sale {
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  border-radius: 12px; padding: 16px;
  display: flex; align-items: center; justify-content: space-between;
  color: white; position: relative; overflow: hidden;
}
.pe-limited-tag {
  background: #fde68a; color: #92400e;
  font-size: 9px; font-weight: 800;
  padding: 2px 6px; border-radius: 4px;
  display: inline-block; margin-bottom: 6px;
}
.pe-mega-headline { font-size: 14px; font-weight: 800; margin-bottom: 2px; }
.pe-mega-upto { font-size: 11px; opacity: 0.8; }
.pe-mega-pct { font-size: 36px; font-weight: 900; line-height: 1; }
.pe-mega-pct span { font-size: 20px; }
.pe-mega-detail { font-size: 11px; opacity: 0.85; margin-bottom: 10px; }
.pe-mega-shopbtn {
  background: white; color: #6366f1;
  border: none; padding: 7px 14px; border-radius: 8px;
  font-size: 12px; font-weight: 700; cursor: pointer;
  display: inline-block;
}
.pe-mega-gift { font-size: 48px; opacity: 0.9; flex-shrink: 0; }

/* RECENT ORDER */
.pe-rc-hdr { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.pe-recent-order { display: flex; flex-direction: column; gap: 10px; }
.pe-ro-info { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; }
.pe-ro-num { font-size: 14px; font-weight: 800; }
.pe-ro-meta { font-size: 11px; color: var(--text-secondary); margin-top: 2px; }
.pe-ro-date { font-size: 11px; color: var(--text-tertiary); margin-top: 2px; }
.pe-ro-timeline {
  display: flex; gap: 0;
  align-items: flex-start;
  overflow-x: auto;
  padding-bottom: 4px;
}
.pe-ro-step {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  flex: 1; min-width: 44px;
  position: relative;
}
.pe-ro-step:not(:last-child)::after {
  content: '';
  position: absolute;
  top: 8px; left: calc(50% + 8px);
  width: calc(100% - 16px); height: 2px;
  background: var(--border);
  z-index: 0;
}
.pe-ro-step.done:not(:last-child)::after { background: #10b981; }
.pe-ro-step.active:not(:last-child)::after { background: linear-gradient(90deg, #6366f1, var(--border)); }
.pe-ro-dot {
  width: 18px; height: 18px; border-radius: 50%;
  background: var(--border); border: 2px solid var(--border);
  z-index: 1; display: flex; align-items: center; justify-content: center;
  font-size: 9px;
}
.pe-dot-done { background: #10b981 !important; border-color: #10b981 !important; color: white; }
.pe-dot-active {
  background: #6366f1 !important; border-color: #6366f1 !important; color: white;
  box-shadow: 0 0 0 4px rgba(99,102,241,0.15);
  animation: orderPulse 1.5s ease infinite;
}
@keyframes orderPulse { 0%,100%{box-shadow:0 0 0 4px rgba(99,102,241,0.15)} 50%{box-shadow:0 0 0 8px rgba(99,102,241,0)} }
.pe-ro-slabel { font-size: 9px; font-weight: 700; color: var(--text-secondary); text-align: center; }
.pe-ro-bell {
  background: #f0fdf4; border: 1px solid #bbf7d0;
  border-radius: 8px; padding: 8px 10px;
  font-size: 11px; color: #166534;
  display: flex; align-items: center; gap: 6px;
}

/* WALLET */
.pe-wallet-row {
  display: flex; align-items: center; justify-content: space-between;
}
.pe-wallet-lbl { font-size: 12px; color: var(--text-secondary); margin-bottom: 4px; }
.pe-wallet-amt { font-size: 22px; font-weight: 900; color: #6366f1; font-family: var(--font-mono); }
.pe-add-money {
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  color: white; border: none;
  padding: 8px 16px; border-radius: 8px;
  font-size: 12px; font-weight: 700; cursor: pointer;
}

/* TRUST GRID */
.pe-trust-grid-card {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.pe-trust-item {
  background: var(--card); border: 1px solid var(--border);
  border-radius: 10px; padding: 10px;
  display: flex; align-items: center; gap: 8px;
  font-size: 11px; line-height: 1.3;
}
.pe-trust-item > span { font-size: 20px; flex-shrink: 0; }
.pe-trust-item b { font-size: 11px; }
.pe-trust-item small { color: var(--text-secondary); font-size: 10px; }

/* BULK BANNER */
.pe-bulk-card {
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  border: none; color: white;
  display: flex; align-items: center; justify-content: space-between;
}
.pe-bulk-title { font-size: 14px; font-weight: 800; margin-bottom: 4px; }
.pe-bulk-sub { font-size: 11px; opacity: 0.85; margin-bottom: 10px; line-height: 1.4; }

/* RESPONSIVE */
@media (max-width: 1200px) {
  .pe-body { grid-template-columns: 1fr 250px; }
  .pe-services-grid { grid-template-columns: repeat(4, 1fr); }
  .pe-price-row { grid-template-columns: repeat(3, 1fr); }
  .pe-templates-row { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 900px) {
  .pe-body { grid-template-columns: 1fr; }
  .pe-right { display: none; }
  .pe-offers-row { grid-template-columns: repeat(2, 1fr); }
  .pe-how-row { flex-wrap: wrap; }
}
@media (max-width: 600px) {
  .pe-topbar { padding: 8px 12px; }
  .pe-topbar-search { display: none; }
  .pe-hero { flex-direction: column; }
  .pe-hero-visual { display: none; }
  .pe-services-grid { grid-template-columns: repeat(4, 1fr); }
  .pe-main { padding-bottom: 80px; }
}

/* Delete & retry buttons */
.file-actions { display: flex; align-items: center; gap: 6px; flex-shrink: 0; }

.file-delete-btn {
  background: none;
  border: 1.5px solid #fecaca;
  color: #ef4444;
  border-radius: 8px;
  padding: 5px 8px;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.15s;
  line-height: 1;
}
.file-delete-btn:hover {
  background: #ef4444;
  color: white;
  border-color: #ef4444;
  transform: scale(1.05);
}

.file-retry-btn {
  background: none;
  border: 1.5px solid #fbbf24;
  color: #d97706;
  border-radius: 8px;
  padding: 5px 10px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s;
}
.file-retry-btn:hover {
  background: #fbbf24;
  color: white;
  border-color: #fbbf24;
}

/* Status chips inside file-meta */
.file-status-ready  { color: #059669; font-weight: 600; }
.file-status-error  { color: #dc2626; font-weight: 600; }
.file-status-uploading { color: #d97706; font-weight: 600; display: inline-flex; align-items: center; gap: 4px; }

/* Mini spinner for uploading state */
.spinner-xs {
  display: inline-block;
  width: 10px; height: 10px;
  border: 2px solid #fde68a;
  border-top-color: #d97706;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

/* Upload progress bar */
.file-upload-progress {
  width: 80px; height: 4px;
  background: var(--border);
  border-radius: 2px;
  overflow: hidden;
}
.file-upload-bar {
  height: 100%;
  background: linear-gradient(90deg, #6366f1, #8b5cf6);
  border-radius: 2px;
  width: 0%;
  transition: width 0.3s;
  animation: uploadPulse 1.2s ease-in-out infinite;
}
@keyframes uploadPulse {
  0%   { width: 20%; }
  50%  { width: 75%; }
  100% { width: 20%; }
}

/* Keep old .file-remove for backward compat */
.file-remove {
  background: none; border: none; cursor: pointer;
  color: var(--text-tertiary); font-size: 16px; padding: 4px;
  border-radius: 4px; flex-shrink: 0;
  transition: color 0.15s, background 0.15s;
}
.file-remove:hover { color: var(--error); background: #fee2e2; }
/* ── Cancel Order ──────────────────────────────────────────────────────────── */
.cancel-order-btn {
  background: #fff5f5;
  color: #dc2626;
  border: 1.5px solid #fecaca;
  font-weight: 700;
  transition: all 0.15s;
}
.cancel-order-btn:hover {
  background: #dc2626;
  color: white;
  border-color: #dc2626;
}

.cancel-confirm-btn {
  background: #dc2626;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
}
.cancel-confirm-btn:hover {
  background: #b91c1c;
  box-shadow: 0 4px 12px rgba(220,38,38,0.3);
  transform: translateY(-1px);
}
.cancel-confirm-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

.cancel-modal-body {
  padding: 8px 0 4px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
}
.cancel-icon {
  font-size: 48px;
  margin-bottom: 10px;
}
.cancel-warning {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}
.cancel-refund-note {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  padding: 10px 14px;
  font-size: 12px;
  color: #1d4ed8;
  font-weight: 600;
  width: 100%;
  text-align: left;
}
.cancel-actions {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin-top: 20px;
  width: 100%;
}
.cancel-actions .btn-secondary {
  flex: 1;
}
.cancel-actions .cancel-confirm-btn {
  flex: 1;
}
