/* =====================================================
   Apna Darzii — Base Styles
   ===================================================== */

:root {
  --bg: #0f1020;
  --bg2: #1a1b35;
  --card: rgba(255, 255, 255, 0.06);
  --border: rgba(255, 255, 255, 0.1);
  --text: #f1f5f9;
  --muted: #94a3b8;
  --primary: #6366f1;
  --primary2: #8b5cf6;
  --success: #22c55e;
  --warn: #f59e0b;
  --danger: #ef4444;
  --radius: 16px;
  --shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

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

html, body {
  min-height: 100vh;
  overflow-x: hidden;
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
}

html[dir="rtl"] body {
  font-family: 'Noto Nastaliq Urdu', 'Inter', serif;
}

.hidden { display: none !important; }


/* =====================================================
   LANGUAGE TOGGLE + RTL
   ===================================================== */

.lang-toggle {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 100;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 8px 16px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  backdrop-filter: blur(10px);
  transition: all 0.2s;
  font-family: inherit;
}

.lang-toggle:hover {
  background: rgba(255, 255, 255, 0.14);
  transform: translateY(-1px);
}

html[dir="rtl"] .lang-toggle {
  right: auto;
  left: 16px;
}



html[dir="rtl"] input[type="number"],
html[dir="rtl"] input[type="tel"],
html[dir="rtl"] .order-code {
  direction: ltr;
  text-align: right;
  font-family: 'Inter', monospace;
}

/* =====================================================
   VIEW LAYOUT
   ===================================================== */

.view {
  max-width: 980px;
  margin: 0 auto;
  padding: 24px 20px 80px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* =====================================================
   LANDING PAGE
   ===================================================== */

.landing-hero {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding-top: 40px;
  padding-bottom: 40px;
  animation: landingFadeIn 0.8s ease forwards;
  opacity: 0;
}

@keyframes landingFadeIn {
  to { opacity: 1; }
}

.landing-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 16px;
  border-radius: 999px;
  background: rgba(99, 102, 241, 0.12);
  border: 1px solid rgba(99, 102, 241, 0.3);
  color: #c7d2fe;
  font-size: 13px;
  font-weight: 500;
  margin-bottom: 22px;
  backdrop-filter: blur(10px);
}

.landing-badge .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 10px #22c55e;
  animation: pulseDot 2s ease-in-out infinite;
}

@keyframes pulseDot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%      { opacity: 0.6; transform: scale(1.3); }
}

.landing-title {
  font-size: clamp(42px, 10vw, 78px);
  font-weight: 800;
  letter-spacing: -2px;
  line-height: 1.05;
  background: linear-gradient(135deg, #ffffff 20%, #a5b4fc 60%, #c4b5fd 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  margin-bottom: 14px;
}

html[dir="rtl"] .landing-title {
  font-family: 'Noto Nastaliq Urdu', serif;
  letter-spacing: 0;
  line-height: 1.4;
}

.landing-subtitle {
  font-size: clamp(15px, 2.5vw, 18px);
  color: var(--muted);
  max-width: 500px;
  margin: 0 auto 40px;
  line-height: 1.6;
}

.landing-cta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  width: 100%;
  max-width: 640px;
  margin-bottom: 50px;
}

@media (max-width: 560px) {
  .landing-cta { grid-template-columns: 1fr; }
}

.cta-card {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 20px 18px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--card);
  backdrop-filter: blur(14px);
  cursor: pointer;
  text-align: left;
  color: var(--text);
  font-family: inherit;
  transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
  overflow: hidden;
}

html[dir="rtl"] .cta-card { text-align: right; }

.cta-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, transparent 0%, rgba(139, 92, 246, 0.15) 100%);
  opacity: 0;
  transition: opacity 0.3s;
}

.cta-card:hover {
  transform: translateY(-4px);
  border-color: rgba(139, 92, 246, 0.5);
  box-shadow: 0 16px 40px rgba(99, 102, 241, 0.25);
}

.cta-card:hover::before { opacity: 1; }
.cta-card:active { transform: translateY(-2px) scale(0.98); }

.tailor-card {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.12), rgba(139, 92, 246, 0.08));
}

.customer-card {
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.1), rgba(99, 102, 241, 0.06));
}

.customer-card:hover {
  border-color: rgba(34, 197, 94, 0.5);
  box-shadow: 0 16px 40px rgba(34, 197, 94, 0.2);
}

.cta-icon {
  font-size: 28px;
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border);
  flex-shrink: 0;
  position: relative;
  z-index: 1;
}

.cta-text { flex: 1; position: relative; z-index: 1; }

.cta-text h3 {
  font-size: 17px;
  font-weight: 700;
  margin-bottom: 3px;
  line-height: 1.3;
}

.cta-text p {
  font-size: 12.5px;
  color: var(--muted);
  line-height: 1.3;
}

.cta-arrow {
  font-size: 20px;
  color: var(--muted);
  transition: all 0.3s;
  position: relative;
  z-index: 1;
}

.cta-card:hover .cta-arrow {
  color: #fff;
  transform: translateX(4px);
}

html[dir="rtl"] .cta-arrow { transform: scaleX(-1); }
html[dir="rtl"] .cta-card:hover .cta-arrow { transform: scaleX(-1) translateX(4px); }

.landing-features {
  display: flex;
  justify-content: center;
  gap: 32px;
  flex-wrap: wrap;
  margin-bottom: 30px;
}

.feature {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 12.5px;
  font-weight: 500;
}

.feature-icon { font-size: 22px; filter: grayscale(0.2); }

.landing-footer {
  text-align: center;
  padding: 20px 0 10px;
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.3px;
  margin-top: auto;
}

.landing-footer p {
  background: linear-gradient(135deg, #6366f1, #c4b5fd);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-weight: 600;
  display: inline-block;
}

/* =====================================================
   AUTH VIEW
   ===================================================== */

.back-btn {
  background: transparent;
  border: none;
  color: var(--muted);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  padding: 8px 12px;
  margin-bottom: 12px;
  border-radius: 8px;
  font-family: inherit;
  align-self: flex-start;
  transition: all 0.2s;
}

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

html[dir="rtl"] .back-btn { align-self: flex-end; }

.auth-card {
  max-width: 440px;
  width: 100%;
  margin: 20px auto;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  backdrop-filter: blur(14px);
  box-shadow: var(--shadow);
  animation: authSlideUp 0.5s ease forwards;
}

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

.auth-tabs {
  display: flex;
  background: rgba(0, 0, 0, 0.25);
  border-radius: 12px;
  padding: 4px;
  margin-bottom: 22px;
  border: 1px solid var(--border);
}

.auth-tab {
  flex: 1;
  padding: 10px 12px;
  border: none;
  background: transparent;
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
  border-radius: 9px;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.25s;
}

.auth-tab.active {
  background: linear-gradient(135deg, var(--primary), var(--primary2));
  color: #fff;
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.4);
}

.auth-form { display: flex; flex-direction: column; }

/* =====================================================
   FORM FIELDS
   ===================================================== */

.field { margin-bottom: 14px; }

.field label {
  display: block;
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 6px;
  font-weight: 500;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 12px 14px;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid var(--border);
  color: #fff;
  font-size: 15px;
  font-family: inherit;
  outline: none;
  transition: all 0.2s;
  resize: vertical;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15);
}

.field input::placeholder,
.field textarea::placeholder {
  color: rgba(148, 163, 184, 0.5);
}

/* =====================================================
   BUTTONS
   ===================================================== */

.btn {
  border: none;
  cursor: pointer;
  font-size: 15px;
  font-weight: 600;
  padding: 12px 22px;
  border-radius: 12px;
  transition: all 0.2s;
  font-family: inherit;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.btn.primary {
  background: linear-gradient(135deg, var(--primary), var(--primary2));
  color: #fff;
  box-shadow: 0 8px 22px rgba(99, 102, 241, 0.4);
}

.btn.primary:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 12px 28px rgba(99, 102, 241, 0.5);
}

.btn.primary:disabled { opacity: 0.6; cursor: wait; }

.btn.google {
  background: #fff;
  color: #111;
  margin-top: 4px;
}

.btn.google:hover {
  background: #f1f5f9;
  transform: translateY(-1px);
}

.btn.full { width: 100%; }

/* =====================================================
   AUTH DIVIDER + ERROR
   ===================================================== */

.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 18px 0 4px;
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.auth-divider::before,
.auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border);
}

.auth-error {
  margin-top: 14px;
  padding: 10px 14px;
  border-radius: 10px;
  background: rgba(239, 68, 68, 0.12);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: #fca5a5;
  font-size: 13.5px;
  text-align: center;
  line-height: 1.4;
}

.auth-error.hidden { display: none; }

/* =====================================================
   BUTTON LOADING SPINNER
   ===================================================== */

.btn.loading {
  position: relative;
  color: transparent !important;
  pointer-events: none;
}

.btn.loading::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 18px;
  height: 18px;
  margin: -9px 0 0 -9px;
  border: 2.5px solid rgba(255, 255, 255, 0.35);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

.btn.google.loading::after {
  border-color: rgba(0, 0, 0, 0.2);
  border-top-color: #111;
}

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

/* =====================================================
   REMEMBER ME + FORGOT PASSWORD
   ===================================================== */

.auth-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.checkbox-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-size: 13.5px;
  color: var(--text);
  user-select: none;
  padding: 4px 0;
}

.checkbox-label input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.checkbox-box {
  width: 18px;
  height: 18px;
  border-radius: 5px;
  border: 1.5px solid var(--border);
  background: rgba(0, 0, 0, 0.25);
  display: inline-grid;
  place-items: center;
  transition: all 0.2s;
  flex-shrink: 0;
}

.checkbox-box::after {
  content: "";
  width: 5px;
  height: 9px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg) scale(0);
  transform-origin: center;
  transition: transform 0.15s;
  margin-top: -2px;
}

.checkbox-label input[type="checkbox"]:checked + .checkbox-box {
  background: linear-gradient(135deg, var(--primary), var(--primary2));
  border-color: var(--primary);
}

.checkbox-label input[type="checkbox"]:checked + .checkbox-box::after {
  transform: rotate(45deg) scale(1);
}

.checkbox-label input[type="checkbox"]:focus-visible + .checkbox-box {
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.25);
}

.link-btn {
  background: none;
  border: none;
  color: #a5b4fc;
  font-size: 13.5px;
  font-weight: 500;
  cursor: pointer;
  padding: 4px 0;
  font-family: inherit;
  transition: color 0.2s;
  text-decoration: none;
}

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

/* =====================================================
   MODAL (Forgot Password)
   ===================================================== */

.modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(8px);
  display: grid;
  place-items: center;
  padding: 20px;
  z-index: 9998;
  animation: modalFadeIn 0.25s ease;
}

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

.modal.hidden { display: none; }

.modal-box {
  position: relative;
  background: #1a1b35;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px 22px;
  max-width: 420px;
  width: 100%;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  animation: modalPop 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes modalPop {
  from { opacity: 0; transform: scale(0.92) translateY(10px); }
  to   { opacity: 1; transform: scale(1) translateY(0); }
}

.modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  color: var(--muted);
  cursor: pointer;
  font-size: 14px;
  display: grid;
  place-items: center;
  transition: all 0.2s;
  font-family: inherit;
}

.modal-close:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text);
}

html[dir="rtl"] .modal-close {
  right: auto;
  left: 12px;
}

.modal-box h2 {
  font-size: 20px;
  margin-bottom: 10px;
  padding-right: 36px;
}

html[dir="rtl"] .modal-box h2 {
  padding-right: 0;
  padding-left: 36px;
}

.modal-hint {
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.5;
  margin-bottom: 18px;
}

.modal-msg {
  margin-top: 14px;
  padding: 10px 14px;
  border-radius: 10px;
  font-size: 13.5px;
  text-align: center;
  line-height: 1.5;
}

.modal-msg.success {
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.3);
  color: #86efac;
}

.modal-msg.error {
  background: rgba(239, 68, 68, 0.12);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: #fca5a5;
}

.modal-msg.hidden { display: none; }

/* =====================================================
   TOAST
   ===================================================== */

.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(100px);
  background: rgba(20, 20, 40, 0.95);
  color: #fff;
  padding: 12px 22px;
  border-radius: 12px;
  border: 1px solid var(--border);
  backdrop-filter: blur(14px);
  font-size: 14px;
  z-index: 9999;
  opacity: 0;
  transition: all 0.4s cubic-bezier(0.22, 1, 0.36, 1);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
  max-width: calc(100vw - 40px);
  text-align: center;
}

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

.toast.success { border-color: rgba(34, 197, 94, 0.4); }
.toast.error   { border-color: rgba(239, 68, 68, 0.4); }
.toast.info    { border-color: rgba(99, 102, 241, 0.4); }
/* =====================================================
   DASHBOARD
   ===================================================== */

.dash-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 16px;
  padding: 16px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  backdrop-filter: blur(14px);
}

.dash-user {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.dash-avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--primary2));
  display: grid;
  place-items: center;
  font-size: 22px;
  flex-shrink: 0;
  overflow: hidden;
  border: 2px solid rgba(255,255,255,0.15);
}

.dash-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.dash-user-info { min-width: 0; }

.dash-user-info h2 {
  font-size: 17px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dash-user-info p {
  font-size: 12.5px;
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dash-actions {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}

.icon-btn {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border);
  color: var(--text);
  font-size: 16px;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: all 0.2s;
  font-family: inherit;
  padding: 0;
}

.icon-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  transform: translateY(-1px);
}

.icon-btn.small {
  width: 32px;
  height: 32px;
  font-size: 13px;
}

/* Tailor code chip */
.tailor-code-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(99, 102, 241, 0.1);
  border: 1px solid rgba(99, 102, 241, 0.3);
  margin-bottom: 18px;
  font-size: 13px;
  align-self: flex-start;
}

html[dir="rtl"] .tailor-code-chip { align-self: flex-end; }

.tailor-code-chip .order-code {
  font-family: 'Inter', monospace;
  font-weight: 700;
  color: #c7d2fe;
  letter-spacing: 0.5px;
}

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

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

.stat-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 12px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  backdrop-filter: blur(10px);
  transition: all 0.2s;
}

.stat-card:hover {
  border-color: rgba(139, 92, 246, 0.4);
  transform: translateY(-2px);
}

.stat-icon {
  font-size: 20px;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 10px;
  flex-shrink: 0;
}

.stat-info h3 {
  font-size: 18px;
  font-weight: 800;
  line-height: 1;
}

.stat-info p {
  font-size: 11px;
  color: var(--muted);
  margin-top: 3px;
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

/* Big new order button */
.btn.big {
  padding: 14px 22px;
  font-size: 15.5px;
  margin-bottom: 20px;
}

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

.chip {
  padding: 8px 16px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.2s;
  white-space: nowrap;
  flex-shrink: 0;
}

.chip:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text);
}

.chip.active {
  background: linear-gradient(135deg, var(--primary), var(--primary2));
  border-color: transparent;
  color: #fff;
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.4);
}

/* Orders list */
.orders-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.empty-state {
  padding: 60px 20px;
  text-align: center;
  background: var(--card);
  border: 1px dashed var(--border);
  border-radius: var(--radius);
}

.empty-icon {
  font-size: 48px;
  margin-bottom: 12px;
  opacity: 0.5;
}

.empty-state p {
  color: var(--muted);
  font-size: 14px;
}
/* =====================================================
   ORDER CARD + ORDER MODAL (Step 10)
   ===================================================== */

.row2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

@media (max-width: 460px) {
  .row2 { grid-template-columns: 1fr; }
}

/* ===== Order Card ===== */
.order-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  backdrop-filter: blur(14px);
  transition: all 0.25s cubic-bezier(0.22, 1, 0.36, 1);
  animation: orderIn 0.35s ease forwards;
  opacity: 0;
  transform: translateY(10px);
}

@keyframes orderIn {
  to { opacity: 1; transform: translateY(0); }
}

.order-card:hover {
  border-color: rgba(139, 92, 246, 0.35);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
}

.order-card.delayed {
  border-color: rgba(245, 158, 11, 0.45);
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.06), rgba(255,255,255,0.03));
}

.order-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.order-customer {
  min-width: 0;
  flex: 1;
}

.order-customer h4 {
  font-size: 16px;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.order-customer p {
  font-size: 12.5px;
  color: var(--muted);
  margin-top: 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.order-code-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(99, 102, 241, 0.12);
  border: 1px solid rgba(99, 102, 241, 0.3);
  color: #c7d2fe;
  font-family: 'Inter', monospace;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.5px;
  cursor: pointer;
  transition: all 0.2s;
  flex-shrink: 0;
}

.order-code-chip:hover {
  background: rgba(99, 102, 241, 0.22);
}

/* Status badge */
.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.3px;
  margin-bottom: 12px;
}

.status-badge .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 8px currentColor;
}

.status-received  { background: rgba(148, 163, 184, 0.12); color: #cbd5e1; }
.status-measured  { background: rgba(59, 130, 246, 0.12);  color: #93c5fd; }
.status-cutting   { background: rgba(139, 92, 246, 0.12);  color: #c4b5fd; }
.status-stitching { background: rgba(236, 72, 153, 0.12);  color: #f9a8d4; }
.status-finishing { background: rgba(245, 158, 11, 0.12);  color: #fcd34d; }
.status-ready     { background: rgba(34, 197, 94, 0.12);   color: #86efac; }
.status-delivered { background: rgba(20, 184, 166, 0.12);  color: #5eead4; }
.status-onhold    { background: rgba(245, 158, 11, 0.15);  color: #fbbf24; }
.status-cancelled { background: rgba(239, 68, 68, 0.12);   color: #fca5a5; }

/* Order meta */
.order-meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 12px;
  font-size: 12.5px;
}

.order-meta .meta-item {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
}

.order-meta .meta-item strong {
  color: var(--text);
  font-weight: 600;
}

.order-meta .meta-item.delay {
  color: #fbbf24;
  font-weight: 600;
}

.order-amounts {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.amount-pill {
  padding: 5px 12px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  color: var(--muted);
}

.amount-pill.rate      { color: #c7d2fe; }
.amount-pill.advance   { color: #86efac; }
.amount-pill.remaining { color: #fca5a5; }

/* Order actions */
.order-actions {
  display: flex;
  gap: 8px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}

.order-actions .btn {
  flex: 1;
  padding: 9px 12px;
  font-size: 13px;
  border-radius: 10px;
}

.btn.ghost {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  color: var(--text);
}

.btn.ghost:hover {
  background: rgba(255, 255, 255, 0.1);
}

.btn.danger {
  background: rgba(239, 68, 68, 0.12);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: #fca5a5;
}

.btn.danger:hover {
  background: rgba(239, 68, 68, 0.2);
}

.btn.mini {
  padding: 6px 10px;
  font-size: 12px;
  border-radius: 8px;
}


/* =====================================================
   STATUS UPDATE MODAL + TIMELINE (Step 11)
   ===================================================== */

.order-info-mini {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px 14px;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid var(--border);
  border-radius: 12px;
  margin-bottom: 16px;
  font-size: 13px;
  color: var(--muted);
}

.order-info-mini .row {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

.order-info-mini .row strong {
  color: var(--text);
  font-weight: 600;
}

/* ===== Status flow selector ===== */
.status-flow {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 14px;
}

.status-option {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  font-family: inherit;
  text-align: left;
  position: relative;
}

html[dir="rtl"] .status-option { text-align: right; }

.status-option:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(139, 92, 246, 0.4);
}

.status-option .icon {
  width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
  font-size: 14px;
  flex-shrink: 0;
}

.status-option.current {
  border-color: rgba(99, 102, 241, 0.5);
  background: rgba(99, 102, 241, 0.1);
  opacity: 0.7;
  cursor: default;
}

.status-option.current::after {
  content: "✓";
  position: absolute;
  top: 6px;
  right: 8px;
  color: #86efac;
  font-size: 11px;
  font-weight: 800;
}

html[dir="rtl"] .status-option.current::after {
  right: auto;
  left: 8px;
}

.status-option.selected {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.25), rgba(139, 92, 246, 0.2));
  border-color: var(--primary);
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.25);
}

.status-option.danger {
  color: #fca5a5;
}
.status-option.danger:hover {
  border-color: rgba(239, 68, 68, 0.5);
  background: rgba(239, 68, 68, 0.1);
}

.status-option.warn {
  color: #fbbf24;
}
.status-option.warn:hover {
  border-color: rgba(245, 158, 11, 0.5);
  background: rgba(245, 158, 11, 0.1);
}

/* ===== Timeline ===== */
.timeline {
  position: relative;
  padding-left: 28px;
  margin-top: 8px;
}

html[dir="rtl"] .timeline {
  padding-left: 0;
  padding-right: 28px;
}

.timeline::before {
  content: "";
  position: absolute;
  top: 6px;
  bottom: 6px;
  left: 10px;
  width: 2px;
  background: linear-gradient(180deg, var(--primary), var(--primary2), transparent);
  border-radius: 999px;
}

html[dir="rtl"] .timeline::before {
  left: auto;
  right: 10px;
}

.timeline-item {
  position: relative;
  padding-bottom: 18px;
  animation: tlIn 0.35s ease forwards;
  opacity: 0;
  transform: translateY(6px);
}

@keyframes tlIn {
  to { opacity: 1; transform: translateY(0); }
}

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

.timeline-item::before {
  content: "";
  position: absolute;
  top: 4px;
  left: -23px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--primary);
  border: 3px solid #1a1b35;
  box-shadow: 0 0 0 1px var(--primary), 0 0 12px rgba(99, 102, 241, 0.5);
}

html[dir="rtl"] .timeline-item::before {
  left: auto;
  right: -23px;
}

.timeline-item.current::before {
  background: #86efac;
  box-shadow: 0 0 0 1px #86efac, 0 0 16px rgba(34, 197, 94, 0.7);
}

.timeline-item.onhold::before {
  background: #fbbf24;
  box-shadow: 0 0 0 1px #fbbf24, 0 0 12px rgba(245, 158, 11, 0.6);
}

.timeline-item.cancelled::before {
  background: #ef4444;
  box-shadow: 0 0 0 1px #ef4444, 0 0 12px rgba(239, 68, 68, 0.6);
}

.timeline-item h5 {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 3px;
}

.timeline-item .time {
  font-size: 11.5px;
  color: var(--muted);
}

.timeline-item .reason {
  margin-top: 6px;
  padding: 8px 10px;
  background: rgba(245, 158, 11, 0.1);
  border-left: 3px solid #fbbf24;
  border-radius: 6px;
  font-size: 12.5px;
  color: #fcd34d;
  line-height: 1.5;
}

html[dir="rtl"] .timeline-item .reason {
  border-left: none;
  border-right: 3px solid #fbbf24;
}

/* ===== View details button in order card ===== */
.order-actions .btn.timeline-btn {
  color: #a5b4fc;
}
/* =====================================================
   STATUS MODAL — Fix (Step 11)
   ===================================================== */

#statusModal .modal-box,
#timelineModal .modal-box,
#orderModal .modal-box,
#profileModal .modal-box {
  max-height: 90vh;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  padding-bottom: 0;
}

#statusModal .modal-box > *:not(#statusConfirmBtn),
#timelineModal .modal-box > *:not(.modal-close) {
  flex-shrink: 0;
}

/* Confirm button ko sticky karein */
#statusModal #statusConfirmBtn {
  position: sticky;
  bottom: 0;
  margin-top: 16px;
  z-index: 3;
}

/* Ek subtle gradient backdrop button ke peeche taake content na dikhe */
#statusModal #statusConfirmBtn::before {
  content: "";
  position: absolute;
  top: -14px;
  left: -22px;
  right: -22px;
  height: 14px;
  background: linear-gradient(to bottom, transparent, #1a1b35);
  pointer-events: none;
}

/* Scrollbar ko patla aur theme ke rang me */
#statusModal .modal-box::-webkit-scrollbar,
#timelineModal .modal-box::-webkit-scrollbar,
#orderModal .modal-box::-webkit-scrollbar,
#profileModal .modal-box::-webkit-scrollbar {
  width: 6px;
}

#statusModal .modal-box::-webkit-scrollbar-thumb,
#timelineModal .modal-box::-webkit-scrollbar-thumb,
#orderModal .modal-box::-webkit-scrollbar-thumb,
#profileModal .modal-box::-webkit-scrollbar-thumb {
  background: rgba(139, 92, 246, 0.35);
  border-radius: 999px;
}

#statusModal .modal-box::-webkit-scrollbar-track,
#timelineModal .modal-box::-webkit-scrollbar-track,
#orderModal .modal-box::-webkit-scrollbar-track,
#profileModal .modal-box::-webkit-scrollbar-track {
  background: transparent;
}

/* Modal scroll hone par bhi close button theek jagah rahe */
#statusModal .modal-close,
#timelineModal .modal-close,
#orderModal .modal-close,
#profileModal .modal-close {
  position: sticky;
  top: 0;
  float: right;
  z-index: 4;
}

html[dir="rtl"] #statusModal .modal-close,
html[dir="rtl"] #timelineModal .modal-close,
html[dir="rtl"] #orderModal .modal-close,
html[dir="rtl"] #profileModal .modal-close {
  float: left;
}

/* Status reason box ke liye thoda compact */
#statusModal #reasonWrap {
  margin-top: 4px;
  margin-bottom: 4px;
}

#statusModal #statusReason {
  min-height: 60px;
}

/* Chhoti screens (mobile) ke liye extra safety */
@media (max-height: 640px) {
  #statusModal .modal-box,
  #timelineModal .modal-box,
  #orderModal .modal-box {
    max-height: 95vh;
    padding: 20px 18px 0;
  }

  .status-flow {
    gap: 6px;
  }

  .status-option {
    padding: 8px 10px;
    font-size: 12px;
  }
}
/* =====================================================
   CUSTOMER FLOW — Mobile-First (Step 12)
   ===================================================== */

/* Customer header */
.customer-header {
  text-align: center;
  padding: 8px 0 20px;
}

.customer-header h2 {
  font-size: clamp(22px, 6vw, 30px);
  font-weight: 800;
  line-height: 1.2;
  background: linear-gradient(135deg, #fff 20%, #a5b4fc 70%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  margin-bottom: 6px;
}

.customer-header p {
  font-size: 13.5px;
  line-height: 1.5;
  max-width: 420px;
  margin: 0 auto;
}

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

.search-wrap input {
  width: 100%;
  padding: 14px 16px 14px 44px;
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid var(--border);
  color: #fff;
  font-size: 15px;
  font-family: inherit;
  outline: none;
  transition: all 0.2s;
  min-height: 48px;
}

html[dir="rtl"] .search-wrap input {
  padding: 14px 44px 14px 16px;
}

.search-wrap input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15);
}

.search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 16px;
  opacity: 0.5;
  pointer-events: none;
}

html[dir="rtl"] .search-icon {
  left: auto;
  right: 14px;
}

/* Tailor list */
.tailors-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.tailor-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  backdrop-filter: blur(14px);
  transition: all 0.25s;
  animation: orderIn 0.35s ease forwards;
  opacity: 0;
  transform: translateY(10px);
}

.tailor-card:hover {
  border-color: rgba(139, 92, 246, 0.35);
}

.tailor-card-top {
  display: flex;
  gap: 14px;
  margin-bottom: 14px;
  align-items: center;
}

.tailor-avatar {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--primary2));
  display: grid;
  place-items: center;
  font-size: 24px;
  flex-shrink: 0;
  overflow: hidden;
  border: 2px solid rgba(255, 255, 255, 0.15);
}

.tailor-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.tailor-info {
  flex: 1;
  min-width: 0;
}

.tailor-info h3 {
  font-size: 16px;
  font-weight: 700;
  line-height: 1.25;
  margin-bottom: 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.tailor-info .shop-name {
  font-size: 13px;
  color: #c7d2fe;
  font-weight: 600;
  margin-bottom: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.tailor-info .city {
  font-size: 12px;
  color: var(--muted);
}

.tailor-card-details {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 12px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  margin-bottom: 14px;
  font-size: 12.5px;
  color: var(--muted);
}

.tailor-card-details .detail-row {
  display: flex;
  align-items: center;
  gap: 8px;
  line-height: 1.4;
}

.tailor-card-details .detail-row strong {
  color: var(--text);
  font-weight: 500;
  word-break: break-word;
}

.tailor-card-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.tailor-card-actions .btn {
  padding: 12px 14px;
  font-size: 13.5px;
  min-height: 44px;
}

.tailor-card-actions .btn.primary-track {
  grid-column: 1 / -1;
  background: linear-gradient(135deg, var(--primary), var(--primary2));
  color: #fff;
  box-shadow: 0 6px 18px rgba(99, 102, 241, 0.35);
}

.btn.call {
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.3);
  color: #86efac;
  text-decoration: none;
}

.btn.whatsapp {
  background: rgba(37, 211, 102, 0.12);
  border: 1px solid rgba(37, 211, 102, 0.3);
  color: #6ee7b7;
  text-decoration: none;
}

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

/* Track card */
.track-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 20px;
  backdrop-filter: blur(14px);
  box-shadow: var(--shadow);
}

.field-help {
  font-size: 11.5px;
  color: var(--muted);
  margin-top: 6px;
  line-height: 1.4;
}

/* =====================================================
   RESULT PAGE
   ===================================================== */

.result-status-card {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.15), rgba(139, 92, 246, 0.1));
  border: 1px solid rgba(99, 102, 241, 0.35);
  border-radius: var(--radius);
  padding: 24px 20px;
  text-align: center;
  margin-bottom: 16px;
  position: relative;
  overflow: hidden;
}

.result-status-card.delayed {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.15), rgba(251, 191, 36, 0.08));
  border-color: rgba(245, 158, 11, 0.4);
}

.result-status-card.delivered {
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.15), rgba(20, 184, 166, 0.08));
  border-color: rgba(34, 197, 94, 0.4);
}

.result-status-icon {
  font-size: 44px;
  margin-bottom: 8px;
  line-height: 1;
}

.result-status-label {
  font-size: 12px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 6px;
}

.result-status-value {
  font-size: clamp(22px, 6vw, 30px);
  font-weight: 800;
  line-height: 1.2;
  background: linear-gradient(135deg, #fff, #c7d2fe);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  margin-bottom: 14px;
}

.result-code-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--border);
  font-family: 'Inter', monospace;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 1px;
  color: #c7d2fe;
  cursor: pointer;
}

/* Info grid */
.result-info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 16px;
}

.result-info-item {
  padding: 12px 14px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
}

.result-info-item .label {
  font-size: 10.5px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.6px;
  margin-bottom: 4px;
}

.result-info-item .value {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.3;
  word-break: break-word;
}

.result-info-item .value.warn { color: #fbbf24; }
.result-info-item .value.success { color: #86efac; }

/* Delay notice */
.delay-notice {
  display: flex;
  gap: 12px;
  padding: 14px 16px;
  background: rgba(245, 158, 11, 0.1);
  border: 1px solid rgba(245, 158, 11, 0.35);
  border-radius: 12px;
  margin-bottom: 16px;
  animation: orderIn 0.4s ease forwards;
  opacity: 0;
  transform: translateY(10px);
}

.delay-notice .icon {
  font-size: 22px;
  flex-shrink: 0;
  line-height: 1;
}

.delay-notice .content h5 {
  font-size: 13.5px;
  font-weight: 700;
  color: #fbbf24;
  margin-bottom: 4px;
}

.delay-notice .content p {
  font-size: 12.5px;
  color: #fcd34d;
  line-height: 1.5;
}

/* Result section */
.result-section {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 16px;
  margin-bottom: 16px;
}

.result-section h3 {
  font-size: 14px;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.8px;
  margin-bottom: 14px;
}

/* Tailor info block in result */
.tailor-mini {
  display: flex;
  gap: 12px;
  align-items: center;
}

.tailor-mini .tailor-avatar {
  width: 50px;
  height: 50px;
  font-size: 20px;
}

.tailor-mini-info {
  flex: 1;
  min-width: 0;
}

.tailor-mini-info h4 {
  font-size: 15px;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 3px;
}

.tailor-mini-info p {
  font-size: 12.5px;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Result actions - sticky bottom mobile */
.result-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 8px;
}

.result-actions .btn {
  min-height: 50px;
  font-size: 14.5px;
}

/* Mobile tweaks */
@media (max-width: 420px) {
  .result-info-grid {
    grid-template-columns: 1fr;
  }

  .result-info-item {
    padding: 10px 12px;
  }

  .track-card {
    padding: 18px 16px;
  }
}
/* =====================================================
   URDU / RTL FIX — Noto Nastaliq tall glyphs
   ===================================================== */

/* Urdu headings ko extra line-height chahiye */
html[dir="rtl"] h1,
html[dir="rtl"] h2,
html[dir="rtl"] h3,
html[dir="rtl"] h4,
html[dir="rtl"] h5 {
  line-height: 1.9;
  padding-top: 4px;
  padding-bottom: 4px;
  overflow: visible;
}

/* Landing title */
html[dir="rtl"] .landing-title {
  font-family: 'Noto Nastaliq Urdu', serif;
  letter-spacing: 0;
  line-height: 2.1;
  padding: 12px 8px;
  display: block;
  overflow: visible;
}

/* Customer header heading */
html[dir="rtl"] .customer-header h2 {
  line-height: 2.2;
  padding: 10px 6px 4px;
  overflow: visible;
}

html[dir="rtl"] .customer-header p {
  line-height: 2;
  padding: 4px 6px 8px;
}


/* Auth card headings */
html[dir="rtl"] .auth-card h2,
html[dir="rtl"] .modal-box h2 {
  line-height: 2;
  padding: 4px 0;
}

html[dir="rtl"] .modal-box h2 {
  padding-right: 0;
  padding-left: 36px;
}

/* CTA card titles */
html[dir="rtl"] .cta-text h3 {
  line-height: 1.9;
}

/* Stat card labels */
html[dir="rtl"] .stat-info p {
  line-height: 1.7;
  letter-spacing: 0;
}

/* Status badge / chips */
html[dir="rtl"] .chip {
  line-height: 1.7;
  padding-top: 6px;
  padding-bottom: 6px;
}

/* Buttons */
html[dir="rtl"] .btn {
  line-height: 1.9;
  padding-top: 14px;
  padding-bottom: 14px;
}

/* Form labels */
html[dir="rtl"] .field label {
  line-height: 1.9;
}

/* Field help text */
html[dir="rtl"] .field-help {
  line-height: 1.9;
}

/* Empty state */
html[dir="rtl"] .empty-state p {
  line-height: 1.9;
}

/* Toast */
html[dir="rtl"] .toast {
  line-height: 1.8;
}

/* Error message */
html[dir="rtl"] .auth-error {
  line-height: 1.9;
}

/* Order card titles */
html[dir="rtl"] .order-customer h4 {
  line-height: 1.9;
}

html[dir="rtl"] .order-info-mini {
  line-height: 1.9;
}

/* Result page */
html[dir="rtl"] .result-status-value {
  line-height: 2;
  padding: 8px 0;
}

html[dir="rtl"] .result-status-label {
  letter-spacing: 0;
  line-height: 1.8;
}

html[dir="rtl"] .result-info-item .label {
  letter-spacing: 0;
  line-height: 1.8;
}

html[dir="rtl"] .result-info-item .value {
  line-height: 1.8;
}

html[dir="rtl"] .result-section h3 {
  letter-spacing: 0;
  line-height: 2;
}

html[dir="rtl"] .tailor-info h3,
html[dir="rtl"] .tailor-mini-info h4 {
  line-height: 1.9;
}

html[dir="rtl"] .tailor-info .shop-name,
html[dir="rtl"] .tailor-info .city {
  line-height: 1.8;
}

html[dir="rtl"] .tailor-card-details .detail-row {
  line-height: 1.9;
}

html[dir="rtl"] .delay-notice .content h5,
html[dir="rtl"] .delay-notice .content p {
  line-height: 1.9;
}

/* Splash taglines - aur zyada space */
html[dir="rtl"] .splash-tagline-ur {
  line-height: 2;
  padding: 4px 8px;
}

/* Timeline items */
html[dir="rtl"] .timeline-item h5 {
  line-height: 1.9;
}

html[dir="rtl"] .timeline-item .reason {
  line-height: 1.9;
}

/* Status option */
html[dir="rtl"] .status-option {
  line-height: 1.8;
  padding-top: 12px;
  padding-bottom: 12px;
}

/* View section padding - top/bottom extra */
html[dir="rtl"] .view {
  padding-top: 32px;
}

/* Landing badge */
html[dir="rtl"] .landing-badge {
  line-height: 1.8;
  padding: 10px 18px;
}

/* Footer */
html[dir="rtl"] .landing-footer p {
  line-height: 1.9;
}
/* =====================================================
   PWA INSTALL BANNER (Step 13)
   ===================================================== */

.install-banner {
  position: fixed;
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%) translateY(200%);
  width: calc(100% - 32px);
  max-width: 460px;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.15), rgba(139, 92, 246, 0.1));
  border: 1px solid rgba(139, 92, 246, 0.4);
  border-radius: 16px;
  padding: 14px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  backdrop-filter: blur(14px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
  z-index: 9997;
  transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.3s;
  opacity: 0;
}

.install-banner:not(.hidden) {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

.install-banner.hidden {
  display: flex !important;
  transform: translateX(-50%) translateY(200%);
  opacity: 0;
  pointer-events: none;
}

.install-content {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  flex: 1;
}

.install-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--primary), var(--primary2));
  display: grid;
  place-items: center;
  font-size: 20px;
  flex-shrink: 0;
}

.install-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.install-text strong {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text);
}

.install-text span {
  font-size: 11.5px;
  color: var(--muted);
  line-height: 1.3;
}

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

.install-actions .btn.mini {
  padding: 8px 14px;
  font-size: 12.5px;
  min-height: 36px;
  border-radius: 10px;
}

/* Small phone ke liye stack */
@media (max-width: 380px) {
  .install-banner {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }
  .install-actions {
    justify-content: flex-end;
  }
}
/* =====================================================
   STEP 13.5 — NEW HOME + VISUAL TRACKING
   ===================================================== */

/* ===== HOME ===== */
.home-header {
  text-align: center;
  padding: 20px 8px 24px;
}

.brand-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 8px;
}

.brand-icon {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--primary), var(--primary2));
  display: grid;
  place-items: center;
  font-size: 22px;
  box-shadow: 0 8px 22px rgba(99, 102, 241, 0.4);
}

.brand-title {
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: clamp(26px, 8vw, 38px);
  font-weight: 700;
  background: linear-gradient(135deg, #ffffff 20%, #a5b4fc 70%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  line-height: 1.6;
  padding: 4px 8px;
}

.home-subtitle {
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: 14px;
  color: var(--muted);
  line-height: 1.9;
  padding: 0 8px;
}

/* Token search card */
.token-card {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.15), rgba(139, 92, 246, 0.1));
  border: 1.5px solid rgba(99, 102, 241, 0.4);
  border-radius: 20px;
  padding: 22px 18px;
  margin-bottom: 20px;
  box-shadow: 0 12px 34px rgba(99, 102, 241, 0.15);
  animation: cardIn 0.5s cubic-bezier(0.22, 1, 0.36, 1) forwards;
  opacity: 0;
  transform: translateY(14px);
}

@keyframes cardIn {
  to { opacity: 1; transform: translateY(0); }
}

.token-label {
  display: block;
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: 17px;
  font-weight: 700;
  color: #e0e7ff;
  margin-bottom: 12px;
  text-align: center;
  line-height: 1.8;
}

.token-input-wrap {
  position: relative;
  display: flex;
  gap: 10px;
  align-items: stretch;
}

.token-input {
  flex: 1;
  padding: 18px 16px;
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.35);
  border: 2px solid rgba(255, 255, 255, 0.12);
  color: #fff;
  font-family: 'Inter', monospace;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: 3px;
  text-align: center;
  outline: none;
  transition: all 0.2s;
  min-width: 0;
  min-height: 60px;
  text-transform: uppercase;
}

.token-input:focus {
  border-color: var(--primary);
  background: rgba(0, 0, 0, 0.5);
  box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.2);
}

.token-input::placeholder {
  letter-spacing: 2px;
  font-weight: 600;
  color: rgba(148, 163, 184, 0.5);
}

.token-search-btn {
  min-width: 68px;
  min-height: 60px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--primary), var(--primary2));
  border: none;
  color: #fff;
  font-size: 26px;
  cursor: pointer;
  box-shadow: 0 8px 22px rgba(99, 102, 241, 0.4);
  transition: all 0.2s;
  display: grid;
  place-items: center;
  padding: 0;
}

.token-search-btn:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(99, 102, 241, 0.55);
}

.token-search-btn:active:not(:disabled) {
  transform: scale(0.95);
}

.token-search-btn.loading {
  color: transparent;
  position: relative;
}

.token-search-btn.loading::after {
  content: "";
  position: absolute;
  width: 22px; height: 22px;
  border: 3px solid rgba(255,255,255,0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

.token-help {
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: 12.5px;
  color: var(--muted);
  text-align: center;
  margin-top: 10px;
  line-height: 1.8;
}

.token-error {
  margin-top: 12px;
  padding: 12px 14px;
  border-radius: 10px;
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.4);
  color: #fca5a5;
  font-size: 13.5px;
  text-align: center;
  font-family: 'Noto Nastaliq Urdu', serif;
  line-height: 1.8;
}

/* OR divider */
.or-divider {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 18px 0;
  color: var(--muted);
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: 14px;
  line-height: 1.8;
}

.or-divider::before,
.or-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border);
}

/* Home action buttons */
.home-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 24px;
}

.home-action-btn {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px 18px;
  border-radius: 16px;
  border: 1.5px solid var(--border);
  background: var(--card);
  backdrop-filter: blur(14px);
  cursor: pointer;
  color: var(--text);
  font-family: inherit;
  text-align: inherit;
  transition: all 0.25s cubic-bezier(0.22, 1, 0.36, 1);
  min-height: 76px;
}

.home-action-btn:hover {
  transform: translateY(-2px);
  border-color: rgba(139, 92, 246, 0.5);
  box-shadow: 0 12px 30px rgba(99, 102, 241, 0.25);
}

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

.home-action-btn.tailor {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.14), rgba(139, 92, 246, 0.08));
}

.home-action-btn.customer {
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.1), rgba(99, 102, 241, 0.06));
}

.home-action-btn .action-icon {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border);
  font-size: 24px;
  flex-shrink: 0;
}

.home-action-btn .action-text {
  flex: 1;
  min-width: 0;
}

.home-action-btn .action-text strong {
  display: block;
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.9;
}

.home-action-btn .action-text small {
  display: block;
  font-size: 11.5px;
  color: var(--muted);
  margin-top: 2px;
  line-height: 1.5;
}

.home-action-btn .action-arrow {
  font-size: 26px;
  color: var(--muted);
  font-weight: 300;
  line-height: 1;
  transition: transform 0.2s;
}

.home-action-btn:hover .action-arrow {
  color: #fff;
  transform: translateX(-4px);
}

html[dir="ltr"] .home-action-btn .action-arrow {
  transform: scaleX(-1);
}
html[dir="ltr"] .home-action-btn:hover .action-arrow {
  transform: scaleX(-1) translateX(-4px);
}

/* =====================================================
   RESULT — VISUAL TRACKING
   ===================================================== */

.hero-status {
  text-align: center;
  padding: 28px 18px 22px;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.18), rgba(139, 92, 246, 0.12));
  border: 1.5px solid rgba(99, 102, 241, 0.4);
  border-radius: 22px;
  margin-bottom: 18px;
  position: relative;
  overflow: hidden;
  animation: heroIn 0.6s cubic-bezier(0.22, 1, 0.36, 1) forwards;
  opacity: 0;
  transform: scale(0.94);
}

@keyframes heroIn {
  to { opacity: 1; transform: scale(1); }
}

.hero-status.success {
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.22), rgba(20, 184, 166, 0.14));
  border-color: rgba(34, 197, 94, 0.5);
}

.hero-status.delayed {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.2), rgba(251, 191, 36, 0.12));
  border-color: rgba(245, 158, 11, 0.5);
}

.hero-status.cancelled {
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.18), rgba(220, 38, 38, 0.12));
  border-color: rgba(239, 68, 68, 0.5);
}

.hero-icon {
  font-size: 76px;
  line-height: 1;
  margin-bottom: 12px;
  display: inline-block;
  animation: iconBob 2s ease-in-out infinite;
  filter: drop-shadow(0 8px 20px rgba(0, 0, 0, 0.4));
}

@keyframes iconBob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

.hero-status.success .hero-icon {
  animation: successPop 1.4s ease-in-out infinite;
}

@keyframes successPop {
  0%, 100% { transform: scale(1) rotate(0); }
  50% { transform: scale(1.12) rotate(6deg); }
}

.hero-text {
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: clamp(20px, 6vw, 28px);
  font-weight: 700;
  color: var(--text);
  line-height: 2;
  padding: 4px 8px;
  margin-bottom: 14px;
}

/* Voice button */
.voice-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 24px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  border: 1.5px solid rgba(255, 255, 255, 0.25);
  color: #fff;
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  min-height: 50px;
  backdrop-filter: blur(8px);
}

.voice-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

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

/* Phase tracker */
.phase-tracker-wrap {
  margin-bottom: 20px;
  animation: cardIn 0.6s 0.15s cubic-bezier(0.22, 1, 0.36, 1) forwards;
  opacity: 0;
}

.phase-tracker {
  display: flex;
  justify-content: space-between;
  position: relative;
  padding: 22px 6px 18px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 18px;
  backdrop-filter: blur(12px);
  overflow: hidden;
}

.phase-tracker::before {
  content: "";
  position: absolute;
  top: 42px;
  left: 26px;
  right: 26px;
  height: 3px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 2px;
  z-index: 0;
}

.progress-line {
  position: absolute;
  top: 42px;
  left: 26px;
  height: 3px;
  background: linear-gradient(90deg, #22c55e, #86efac);
  border-radius: 2px;
  z-index: 1;
  transition: width 0.8s cubic-bezier(0.22, 1, 0.36, 1);
  box-shadow: 0 0 12px rgba(34, 197, 94, 0.6);
  max-width: calc(100% - 52px);
}

.phase-node {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  flex: 1;
  min-width: 0;
}

.phase-node .icon-circle {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #1a1b35;
  border: 2.5px solid rgba(255, 255, 255, 0.12);
  font-size: 18px;
  transition: all 0.4s;
  color: var(--muted);
}

.phase-node.done .icon-circle {
  background: linear-gradient(135deg, #22c55e, #16a34a);
  border-color: #22c55e;
  color: #fff;
  font-weight: 900;
  font-size: 22px;
  box-shadow: 0 0 18px rgba(34, 197, 94, 0.5);
}

.phase-node.current .icon-circle {
  background: linear-gradient(135deg, var(--primary), var(--primary2));
  border-color: var(--primary2);
  color: #fff;
  box-shadow: 0 0 22px rgba(139, 92, 246, 0.8), 0 0 0 6px rgba(139, 92, 246, 0.15);
  animation: phasePulse 1.6s ease-in-out infinite;
}

@keyframes phasePulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.12); }
}

.phase-node .phase-label {
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: 10.5px;
  font-weight: 600;
  color: var(--muted);
  text-align: center;
  line-height: 1.6;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.phase-node.done .phase-label { color: #86efac; }
.phase-node.current .phase-label {
  color: #c4b5fd;
  font-weight: 800;
}

/* Tracker badges */
.tracker-badge {
  display: block;
  margin-top: 12px;
  padding: 10px 16px;
  border-radius: 12px;
  text-align: center;
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.8;
}

.tracker-badge.warn {
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.4);
  color: #fcd34d;
}

.tracker-badge.danger {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.4);
  color: #fca5a5;
}

/* Result info grid full width item */
.result-info-item.full {
  grid-column: 1 / -1;
}

/* Result code chip full-width */
.result-code-chip.full-width {
  display: flex;
  width: 100%;
  justify-content: center;
  gap: 12px;
  padding: 16px;
  margin-top: 8px;
  border-radius: 14px;
  background: var(--card);
  border: 1px solid var(--border);
  font-size: 16px;
  font-weight: 700;
  color: #c7d2fe;
  cursor: pointer;
  min-height: 54px;
  transition: all 0.2s;
}

.result-code-chip.full-width:hover {
  border-color: var(--primary);
  background: rgba(99, 102, 241, 0.08);
}

/* Bigger call/whatsapp buttons */
.btn.call.big,
.btn.whatsapp.big {
  min-height: 54px;
  font-size: 15px;
  font-weight: 700;
  padding: 14px 18px;
}

/* RTL — back button arrow */
html[dir="rtl"] .back-btn span:first-child {
  /* handled inline with '›' */
}

/* Mobile tweaks */
@media (max-width: 400px) {
  .brand-title { font-size: 26px; }
  .hero-icon { font-size: 64px; }
  .hero-text { font-size: 18px; }
  .phase-node .icon-circle { width: 38px; height: 38px; font-size: 15px; }
  .phase-node.done .icon-circle { font-size: 18px; }
  .phase-node .phase-label { font-size: 9.5px; }
  .phase-tracker::before,
  .progress-line { top: 38px; left: 22px; right: 22px; }
  .token-input { font-size: 18px; letter-spacing: 2px; }
  .voice-btn { font-size: 14px; padding: 12px 18px; }
}
/* =====================================================
   SPLASH — MODERN CLEAN (v2)
   ===================================================== */

.splash {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: grid;
  place-items: center;
  overflow: hidden;
  opacity: 1;
  transition: opacity 0.5s ease;
  background: #0b0d20;
}

.splash.fade-out {
  opacity: 0;
  pointer-events: none;
}

/* Background layers */
.splash-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(900px 600px at 50% 30%, rgba(99, 102, 241, 0.25) 0%, transparent 60%),
    radial-gradient(700px 500px at 50% 90%, rgba(139, 92, 246, 0.18) 0%, transparent 55%),
    #0b0d20;
  animation: bgBreathe 4s ease-in-out infinite;
}

@keyframes bgBreathe {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.06); }
}

.splash-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(circle at 1px 1px, rgba(255,255,255,0.035) 1px, transparent 0);
  background-size: 18px 18px;
  pointer-events: none;
  opacity: 0.6;
}

/* Content */
.splash-content {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 24px;
  animation: splashIn 0.9s cubic-bezier(0.22, 1, 0.36, 1) forwards;
  opacity: 0;
  transform: scale(0.85);
}

@keyframes splashIn {
  0% {
    opacity: 0;
    transform: scale(0.85);
  }
  60% {
    opacity: 1;
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

.splash-logo {
  width: 130px;
  height: 130px;
  margin-bottom: 20px;
  position: relative;
  display: grid;
  place-items: center;
}

.splash-logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  animation: logoGlow 2.5s ease-in-out infinite alternate;
  filter: drop-shadow(0 12px 30px rgba(139, 92, 246, 0.5));
}

@keyframes logoGlow {
  0%   { filter: drop-shadow(0 0 12px rgba(139, 92, 246, 0.3)); }
  100% { filter: drop-shadow(0 0 28px rgba(196, 181, 253, 0.7)); }
}

/* App name — Urdu */
.splash-name {
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: clamp(34px, 9vw, 52px);
  font-weight: 700;
  line-height: 1.8;
  padding: 6px 12px;
  background: linear-gradient(135deg, #ffffff 20%, #c7d2fe 60%, #c4b5fd 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  margin-bottom: 4px;
  text-shadow: 0 0 40px rgba(196, 181, 253, 0.4);
  animation: nameGlow 2.5s ease-in-out infinite alternate;
}

@keyframes nameGlow {
  0%   { filter: drop-shadow(0 0 8px rgba(139, 92, 246, 0.3)); }
  100% { filter: drop-shadow(0 0 20px rgba(196, 181, 253, 0.6)); }
}

/* App name — English small */
.splash-en {
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 500;
  color: rgba(199, 210, 254, 0.6);
  letter-spacing: 3px;
  text-transform: uppercase;
  margin-bottom: 22px;
  animation: enFade 1.2s 0.3s ease forwards;
  opacity: 0;
}

@keyframes enFade {
  to { opacity: 1; }
}

/* Tagline */
.splash-line {
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: 15px;
  font-weight: 500;
  color: #a5b4fc;
  line-height: 2;
  padding: 4px 8px;
  margin-bottom: 28px;
  animation: enFade 1.2s 0.5s ease forwards;
  opacity: 0;
}

/* Loading dots */
.splash-dots {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: center;
}

.splash-dots span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: linear-gradient(135deg, #818cf8, #c4b5fd);
  animation: dotPulse 1.2s ease-in-out infinite;
  box-shadow: 0 0 12px rgba(139, 92, 246, 0.6);
}

.splash-dots span:nth-child(1) { animation-delay: 0s; }
.splash-dots span:nth-child(2) { animation-delay: 0.2s; }
.splash-dots span:nth-child(3) { animation-delay: 0.4s; }

@keyframes dotPulse {
  0%, 100% {
    transform: scale(0.8);
    opacity: 0.4;
  }
  50% {
    transform: scale(1.3);
    opacity: 1;
  }
}

/* Powered footer */
.splash-powered {
  position: absolute;
  bottom: 22px;
  left: 0;
  right: 0;
  text-align: center;
  font-family: 'Inter', sans-serif;
  font-size: 11.5px;
  color: rgba(148, 163, 184, 0.7);
  letter-spacing: 0.5px;
  z-index: 2;
  animation: enFade 1.2s 0.8s ease forwards;
  opacity: 0;
}

.splash-powered strong {
  background: linear-gradient(135deg, #818cf8, #c4b5fd);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-weight: 700;
}

/* Small screens */
@media (max-width: 400px) {
  .splash-logo { width: 100px; height: 100px; }
  .splash-name { font-size: 32px; }
  .splash-line { font-size: 13px; }
  .splash-en { font-size: 11px; letter-spacing: 2px; }
}

/* Splash RTL — Urdu hai to sirf lang check */
html[dir="rtl"] .splash-name {
  line-height: 2;
}
/* =====================================================
   DELAY NOTICE WITH REASON (Step 14.5)
   ===================================================== */

.delay-notice.with-reason {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.12), rgba(251, 191, 36, 0.08));
  border-color: rgba(245, 158, 11, 0.45);
}

.delay-notice.with-reason .content {
  flex: 1;
  min-width: 0;
}

.reason-box {
  margin-top: 8px;
  padding: 12px 14px;
  background: rgba(0, 0, 0, 0.25);
  border-radius: 10px;
  border: 1px solid rgba(245, 158, 11, 0.25);
  display: flex;
  align-items: flex-start;
  gap: 10px;
  position: relative;
}

.reason-label {
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: 12px;
  font-weight: 700;
  color: #fbbf24;
  margin-bottom: 4px;
  line-height: 1.6;
  flex-shrink: 0;
}

.reason-text {
  flex: 1;
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: 14.5px;
  font-weight: 600;
  color: #fcd34d;
  line-height: 2;
  padding: 0 4px;
  word-break: break-word;
}

.reason-voice-btn {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: linear-gradient(135deg, #f59e0b, #fbbf24);
  border: none;
  color: #fff;
  font-size: 18px;
  cursor: pointer;
  display: grid;
  place-items: center;
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.4);
  transition: all 0.2s;
  padding: 0;
}

.reason-voice-btn:hover {
  transform: scale(1.08);
  box-shadow: 0 6px 16px rgba(245, 158, 11, 0.5);
}

.reason-voice-btn:active {
  transform: scale(0.94);
}

/* Stack reason label + text on mobile */
@media (max-width: 400px) {
  .reason-box {
    flex-direction: column;
    align-items: stretch;
  }
  .reason-voice-btn {
    align-self: flex-end;
    width: 44px;
    height: 44px;
  }
  .reason-text {
    font-size: 13.5px;
  }
}
/* =====================================================
   QUICK REASON CHIPS + REASON BOX v2 (Step 14.6)
   ===================================================== */

/* Reason chips in status modal */
.reason-chips {
  margin-bottom: 12px;
}

.reason-chips-label,
.reason-custom-label {
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: 12.5px;
  font-weight: 700;
  color: #c7d2fe;
  margin-bottom: 8px;
  line-height: 1.8;
}

.reason-custom-label {
  margin-top: 14px;
  color: #94a3b8;
  font-weight: 600;
}

.reason-chips-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}

.reason-chip {
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border);
  color: var(--text);
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  text-align: start;
  transition: all 0.2s;
  line-height: 1.8;
  min-height: 44px;
  display: flex;
  align-items: center;
}

.reason-chip:hover {
  background: rgba(139, 92, 246, 0.1);
  border-color: rgba(139, 92, 246, 0.4);
}

.reason-chip:active {
  transform: scale(0.97);
}

.reason-chip.active {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.25), rgba(139, 92, 246, 0.2));
  border-color: var(--primary);
  color: #fff;
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

/* ===== Reason box (customer side) — v2 ===== */

.reason-box {
  margin-top: 10px;
  padding: 12px 14px;
  background: rgba(0, 0, 0, 0.28);
  border-radius: 12px;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.reason-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
}

.reason-label {
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: 12px;
  font-weight: 700;
  color: #fbbf24;
  line-height: 1.8;
  padding: 2px 0;
}

.reason-text {
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: 15px;
  font-weight: 600;
  color: #fcd34d;
  line-height: 2.1;
  padding: 2px 4px;
  word-break: break-word;
}

.reason-voice-btn {
  flex-shrink: 0;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: linear-gradient(135deg, #f59e0b, #fbbf24);
  border: none;
  color: #fff;
  font-size: 18px;
  cursor: pointer;
  display: grid;
  place-items: center;
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.4);
  transition: all 0.2s;
  padding: 0;
}

.reason-voice-btn:hover {
  transform: scale(1.08);
}

.reason-voice-btn:active {
  transform: scale(0.92);
}

/* Small phones */
@media (max-width: 400px) {
  .reason-chips-grid {
    grid-template-columns: 1fr;
  }
  .reason-text {
    font-size: 14px;
  }
}
/* =====================================================
   FULL-SCREEN LOADING OVERLAY
   ===================================================== */

.loading-overlay {
  position: fixed;
  inset: 0;
  background: rgba(11, 13, 32, 0.9);
  backdrop-filter: blur(8px);
  display: grid;
  place-items: center;
  z-index: 99999;
  animation: fadeIn 0.2s ease;
}

.loading-overlay.hidden {
  display: none;
}

.loading-spinner {
  width: 60px;
  height: 60px;
  border: 4px solid rgba(139, 92, 246, 0.2);
  border-top-color: #8b5cf6;
  border-radius: 50%;
  animation: spin 0.9s linear infinite;
  margin-bottom: 18px;
}

.loading-text {
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: 16px;
  font-weight: 600;
  color: #c7d2fe;
  line-height: 1.9;
  text-align: center;
  padding: 0 20px;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
/* =====================================================
   UPDATE BANNER (PWA new version)
   ===================================================== */

.update-banner {
  position: fixed;
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%) translateY(200%);
  width: calc(100% - 32px);
  max-width: 460px;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.2), rgba(139, 92, 246, 0.15));
  border: 1.5px solid rgba(139, 92, 246, 0.5);
  border-radius: 16px;
  padding: 12px 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  backdrop-filter: blur(14px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
  z-index: 99998;
  transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}

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

.update-content {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  min-width: 0;
}

.update-icon {
  font-size: 22px;
  animation: spin 2s linear infinite;
}

.update-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.update-text strong {
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: 13.5px;
  font-weight: 700;
  color: #fff;
  line-height: 1.6;
}

.update-text span {
  font-size: 11px;
  color: #c7d2fe;
}

.update-banner .btn.mini {
  padding: 8px 16px;
  font-size: 12.5px;
  min-height: 36px;
  border-radius: 10px;
  flex-shrink: 0;
}
/* =====================================================
   CUSTOMER SEARCH (Feature 1)
   ===================================================== */

/* ===== Order form — phone search ===== */
.phone-search-wrap {
  position: relative;
  display: flex;
  gap: 8px;
}

.phone-search-wrap input {
  flex: 1;
  min-width: 0;
}

.phone-search-btn {
  flex-shrink: 0;
  width: 48px;
  min-height: 44px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--primary), var(--primary2));
  border: none;
  color: #fff;
  font-size: 18px;
  cursor: pointer;
  transition: all 0.2s;
  display: grid;
  place-items: center;
  padding: 0;
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.35);
}

.phone-search-btn:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(99, 102, 241, 0.5);
}

.phone-search-btn:active:not(:disabled) {
  transform: scale(0.95);
}

.phone-search-btn:disabled {
  opacity: 0.6;
  cursor: wait;
}

.phone-search-btn.loading {
  color: transparent;
  position: relative;
}

.phone-search-btn.loading::after {
  content: "";
  position: absolute;
  width: 18px;
  height: 18px;
  border: 2.5px solid rgba(255, 255, 255, 0.35);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

/* ===== Customer status message ===== */
.customer-status {
  margin-top: 10px;
  padding: 10px 14px;
  border-radius: 10px;
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.9;
  display: flex;
  align-items: center;
  gap: 8px;
}

.customer-status.found {
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.35);
  color: #86efac;
}

.customer-status.new {
  background: rgba(99, 102, 241, 0.12);
  border: 1px solid rgba(99, 102, 241, 0.35);
  color: #c7d2fe;
}

.customer-status.hidden {
  display: none;
}

/* ===== Dashboard customer search bar ===== */
.customer-search-bar {
  position: relative;
  margin-bottom: 14px;
}

.customer-search-bar input {
  width: 100%;
  padding: 14px 44px 14px 16px;
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.28);
  border: 1.5px solid var(--border);
  color: #fff;
  font-size: 15px;
  font-family: 'Noto Nastaliq Urdu', serif;
  outline: none;
  transition: all 0.2s;
  min-height: 52px;
  line-height: 1.9;
}

html[dir="rtl"] .customer-search-bar input {
  padding: 14px 16px 14px 44px;
}

.customer-search-bar input:focus {
  border-color: var(--primary);
  background: rgba(0, 0, 0, 0.4);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15);
}

.customer-search-bar input::placeholder {
  color: rgba(148, 163, 184, 0.55);
}

.customer-search-bar .search-icon-sm {
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 16px;
  opacity: 0.5;
  pointer-events: none;
}

html[dir="rtl"] .customer-search-bar .search-icon-sm {
  right: auto;
  left: 16px;
}

.customer-search-bar .clear-search-btn {
  position: absolute;
  right: 44px;
  top: 50%;
  transform: translateY(-50%);
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: none;
  color: var(--muted);
  font-size: 14px;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: all 0.2s;
  padding: 0;
}

html[dir="rtl"] .customer-search-bar .clear-search-btn {
  right: auto;
  left: 44px;
}

.customer-search-bar .clear-search-btn:hover {
  background: rgba(255, 255, 255, 0.15);
  color: var(--text);
}

.customer-search-bar .clear-search-btn.hidden {
  display: none;
}

/* Search result count chip */
.search-result-chip {
  display: inline-block;
  margin-bottom: 12px;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(99, 102, 241, 0.12);
  border: 1px solid rgba(99, 102, 241, 0.3);
  color: #c7d2fe;
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: 12.5px;
  font-weight: 600;
  line-height: 1.9;
}
/* =====================================================
   MEASUREMENTS SECTION (Feature 2)
   ===================================================== */

.measurements-section {
  margin-bottom: 16px;
  padding: 16px 14px;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.08), rgba(139, 92, 246, 0.05));
  border: 1.5px solid rgba(99, 102, 241, 0.25);
  border-radius: 14px;
}

.measurements-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(99, 102, 241, 0.2);
}

.measurements-icon {
  font-size: 20px;
}

.measurements-header h3 {
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: 15px;
  font-weight: 700;
  color: #c7d2fe;
  line-height: 1.8;
  margin: 0;
}

/* Grid of 11 text fields */
.measurements-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 14px;
}

@media (max-width: 480px) {
  .measurements-grid {
    grid-template-columns: 1fr;
    gap: 8px;
  }
}

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

.measure-field label {
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: 12px;
  color: #a5b4fc;
  font-weight: 600;
  line-height: 1.8;
  padding: 0 2px;
}

.measure-field input {
  width: 100%;
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--border);
  color: #fff;
  font-family: 'Inter', monospace;
  font-size: 16px;
  font-weight: 700;
  text-align: center;
  outline: none;
  transition: all 0.2s;
  min-height: 46px;
  letter-spacing: 0.5px;
}

.measure-field input:focus {
  border-color: var(--primary);
  background: rgba(0, 0, 0, 0.5);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2);
}

.measure-field input::placeholder {
  color: rgba(148, 163, 184, 0.4);
  font-weight: 400;
}

/* Pocket checkboxes */
.pocket-checks {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  padding-top: 12px;
  border-top: 1px solid rgba(99, 102, 241, 0.2);
}

@media (max-width: 480px) {
  .pocket-checks {
    grid-template-columns: 1fr;
  }
}

.pocket-check {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid var(--border);
  cursor: pointer;
  transition: all 0.2s;
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  user-select: none;
  min-height: 46px;
  line-height: 1.9;
}

.pocket-check:hover {
  background: rgba(139, 92, 246, 0.08);
  border-color: rgba(139, 92, 246, 0.4);
}

.pocket-check input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.pocket-box {
  width: 20px;
  height: 20px;
  border-radius: 6px;
  border: 1.5px solid var(--border);
  background: rgba(0, 0, 0, 0.3);
  display: inline-grid;
  place-items: center;
  transition: all 0.2s;
  flex-shrink: 0;
}

.pocket-box::after {
  content: "";
  width: 5px;
  height: 10px;
  border: solid #fff;
  border-width: 0 2.5px 2.5px 0;
  transform: rotate(45deg) scale(0);
  transform-origin: center;
  transition: transform 0.15s;
  margin-top: -2px;
}

.pocket-check input[type="checkbox"]:checked + .pocket-box {
  background: linear-gradient(135deg, var(--primary), var(--primary2));
  border-color: var(--primary);
  box-shadow: 0 0 12px rgba(99, 102, 241, 0.5);
}

.pocket-check input[type="checkbox"]:checked + .pocket-box::after {
  transform: rotate(45deg) scale(1);
}

.pocket-check input[type="checkbox"]:checked ~ span:last-child {
  color: #c4b5fd;
  font-weight: 700;
}
/* =====================================================
   ORDER SERIAL NUMBER (Feature 4)
   ===================================================== */

.order-serial-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  flex: 1;
}

.order-serial {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 48px;
  height: 48px;
  padding: 0 10px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--primary), var(--primary2));
  color: #fff;
  font-family: 'Inter', sans-serif;
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -0.5px;
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.4);
  flex-shrink: 0;
  line-height: 1;
  border: 1.5px solid rgba(255, 255, 255, 0.15);
}

/* Delayed order → amber serial */
.order-card.delayed .order-serial {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.4);
}

/* Small phones */
@media (max-width: 400px) {
  .order-serial {
    min-width: 42px;
    height: 42px;
    font-size: 14px;
    padding: 0 8px;
    border-radius: 10px;
  }
  .order-serial-wrap {
    gap: 10px;
  }
}
/* =====================================================
   FORGOT MODAL — WhatsApp Contact
   ===================================================== */

.forgot-contact {
  margin: 16px 0;
  padding: 14px 16px;
  background: rgba(0, 0, 0, 0.25);
  border: 1.5px solid rgba(37, 211, 102, 0.35);
  border-radius: 14px;
  text-align: center;
}

.forgot-phone-label {
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: 12px;
  color: #86efac;
  margin-bottom: 6px;
  letter-spacing: 0.5px;
  line-height: 1.8;
}

.forgot-phone {
  font-family: 'Inter', monospace;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 2px;
  color: #fff;
  text-shadow: 0 0 20px rgba(37, 211, 102, 0.4);
  direction: ltr;
}

.btn.whatsapp.full {
  background: linear-gradient(135deg, #25d366, #128c7e);
  color: #fff;
  box-shadow: 0 8px 22px rgba(37, 211, 102, 0.4);
  min-height: 52px;
  font-family: 'Noto Nastaliq Urdu', serif;
  font-size: 15px;
  font-weight: 700;
  text-decoration: none;
  line-height: 1.9;
}

.btn.whatsapp.full:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 28px rgba(37, 211, 102, 0.55);
}