/* ═══════════════════════════════════════════════════════════════
   KLYR — PORTAL STYLES
   Shared by: dashboard.html (client) + admin.html (admin)
   Design system tokens inherited from style.css
═══════════════════════════════════════════════════════════════ */

/* ─── RESET / BASE ──────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: #F7F6F2;
  color: #1D2329;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* ─── PORTAL HEADER ─────────────────────────────────────────── */
.portal-header {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  height: 60px;
  background: #ffffff;
  border-bottom: 1px solid #E8ECEB;
}

.portal-header__logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}
.portal-header__logo-img {
  height: 28px;
  width: auto;
}

.portal-header__right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.portal-header__wa {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.portal-header__wa .wa-icon-img {
  width: 16px;
  height: 16px;
}

#dashSignOut {
  display: flex;
  align-items: center;
  gap: 6px;
}

#dashSignOut:hover {
  color: #e03535;
  border-color: #fca5a5;
  background: #fff0f0;
}

.admin-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  background: #1D2329;
  color: #ffffff;
  border-radius: 100px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.ref-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  background: #F0EFEA;
  border-radius: 100px;
  font-size: 12px;
  font-weight: 600;
  color: #5a6470;
  letter-spacing: .03em;
}

/* ─── STATUS BADGES ─────────────────────────────────────────── */
.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 100px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .03em;
  white-space: nowrap;
}

.status-badge::before {
  content: '';
  display: block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}

.status-badge--submitted   { background: #FFF8EC; color: #B8770A; }
.status-badge--reviewing   { background: #EEF4FF; color: #3D6FCC; }
.status-badge--info_requested { background: #FFF3F0; color: #C0401A; }
.status-badge--accepted    { background: #EDFAF9; color: #1E8A84; }
.status-badge--preview_sent  { background: #F5F0FF; color: #6B3FC7; }
.status-badge--preview_declined { background: #FFF0F0; color: #C41A1A; }
.status-badge--preview_approved { background: #EDFAF9; color: #1E8A84; }
.status-badge--payment_pending  { background: #FFF8EC; color: #B8770A; }
.status-badge--completed   { background: #EDFAF9; color: #157A55; }

/* ─── BUTTONS ───────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 10px 20px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: opacity .18s, transform .12s, box-shadow .18s;
  white-space: nowrap;
}
.btn:active { transform: scale(.97); }
.btn:disabled { opacity: .45; cursor: not-allowed; pointer-events: none; }

.btn--teal  { background: #2D9C95; color: #fff; }
.btn--teal:hover { opacity: .88; box-shadow: 0 4px 16px rgba(45,156,149,.28); }

.btn--dark  { background: #1D2329; color: #fff; }
.btn--dark:hover { opacity: .85; }

.btn--ghost {
  background: transparent;
  color: #1D2329;
  border: 1.5px solid #D0D4D8;
}
.btn--ghost:hover { background: #F0EFEA; }

.btn--danger { background: #FFF0F0; color: #C41A1A; border: 1.5px solid #FCCFCF; }
.btn--danger:hover { background: #FCCFCF; }

.btn--amber { background: #F4A340; color: #fff; }
.btn--amber:hover { opacity: .88; }

.btn--sm { padding: 7px 14px; font-size: 13px; border-radius: 8px; }
.btn--lg { padding: 14px 28px; font-size: 15px; }
.btn--full { width: 100%; }

/* ─── INPUTS & TEXTAREAS ────────────────────────────────────── */
.field { display: flex; flex-direction: column; gap: 6px; }
.field label {
  font-size: 13px;
  font-weight: 600;
  color: #5a6470;
}
.field input,
.field textarea,
.field select {
  width: 100%;
  padding: 10px 14px;
  border: 1.5px solid #D0D4D8;
  border-radius: 10px;
  font-family: inherit;
  font-size: 14px;
  color: #1D2329;
  background: #ffffff;
  transition: border-color .18s, box-shadow .18s;
  outline: none;
  resize: vertical;
}
.field input:focus,
.field textarea:focus,
.field select:focus {
  border-color: #2D9C95;
  box-shadow: 0 0 0 3px rgba(45,156,149,.12);
}
.field input::placeholder,
.field textarea::placeholder { color: #9aa4ae; }

/* ─── DROPZONE (shared with configurator) ───────────────────── */
.prt-dropzone {
  border: 1.5px dashed #C8CDD2;
  border-radius: 12px;
  padding: 20px;
  text-align: center;
  cursor: pointer;
  transition: border-color .2s, background .2s;
}
.prt-dropzone:hover, .prt-dropzone.drag-over {
  border-color: #2D9C95;
  background: rgba(45,156,149,.04);
}
.prt-dropzone input { display: none; }
.prt-dropzone__icon { color: #9aa4ae; margin-bottom: 8px; }
.prt-dropzone__label {
  font-size: 14px;
  color: #5a6470;
}
.prt-dropzone__label span { color: #2D9C95; font-weight: 600; }
.prt-dropzone__hint { font-size: 12px; color: #9aa4ae; margin-top: 4px; }
.prt-dropzone__selected {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 500;
  color: #1D2329;
}
.prt-dropzone__selected-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.prt-dropzone__remove {
  background: none;
  border: none;
  color: #9aa4ae;
  cursor: pointer;
  font-size: 16px;
  line-height: 1;
  padding: 2px;
}
.prt-dropzone__remove:hover { color: #C41A1A; }

/* ─── FILE LIST (multiple selected) ────────────────────────────*/
.file-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 8px;
}
.file-list__item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  background: #F0EFEA;
  border-radius: 8px;
  font-size: 13px;
}
.file-list__item-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-list__remove {
  background: none;
  border: none;
  color: #9aa4ae;
  cursor: pointer;
  font-size: 14px;
}
.file-list__remove:hover { color: #C41A1A; }


/* ═══════════════════════════════════════════════════════════════
   CLIENT DASHBOARD
═══════════════════════════════════════════════════════════════ */

/* ─── LOOKUP SCREEN (no ref in URL) ────────────────────────── */
.lookup-screen {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - 60px);
  padding: 40px 24px;
  text-align: center;
}
.lookup-screen__icon {
  width: 64px;
  height: 64px;
  background: #EDFAF9;
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
  color: #2D9C95;
}
.lookup-screen h1 {
  font-size: 26px;
  font-weight: 700;
  margin-bottom: 8px;
}
.lookup-screen p { color: #5a6470; margin-bottom: 28px; max-width: 360px; }
.lookup-form {
  display: flex;
  gap: 10px;
  max-width: 400px;
  width: 100%;
}
.lookup-form input {
  flex: 1;
  padding: 12px 16px;
  border: 1.5px solid #D0D4D8;
  border-radius: 10px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .05em;
  outline: none;
  transition: border-color .18s;
}
.lookup-form input:focus { border-color: #2D9C95; }
.lookup-err {
  margin-top: 12px;
  font-size: 13px;
  color: #C41A1A;
  display: none;
}
.lookup-err.visible { display: block; }

/* ─── DASHBOARD MAIN ────────────────────────────────────────── */
.dashboard {
  max-width: 720px;
  margin: 0 auto;
  padding: 32px 24px 80px;
}

/* ─── ORDER HERO ────────────────────────────────────────────── */
.order-hero {
  background: #ffffff;
  border-radius: 16px;
  padding: 28px;
  margin-bottom: 20px;
  box-shadow: 0 2px 12px rgba(29,35,41,.06), 0 1px 3px rgba(29,35,41,.04);
}
.order-hero__top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 20px;
}
.order-hero__meta { flex: 1; }
.order-hero__greeting {
  font-size: 13px;
  color: #9aa4ae;
  margin-bottom: 4px;
}
.order-hero__name {
  font-size: 22px;
  font-weight: 700;
  color: #1D2329;
  margin-bottom: 6px;
}
.order-hero__pkg {
  font-size: 13px;
  color: #5a6470;
}

/* ─── STATUS TRACKER ────────────────────────────────────────── */
.tracker {
  display: flex;
  align-items: flex-start;
  gap: 0;
  overflow-x: auto;
  padding-bottom: 2px;
}
.tracker::-webkit-scrollbar { display: none; }

.tracker__step {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
  min-width: 80px;
  position: relative;
}

/* connector line between steps */
.tracker__step::before {
  content: '';
  position: absolute;
  top: 15px;
  right: 50%;
  left: -50%;
  height: 2px;
  background: #E8ECEB;
  z-index: 0;
}
.tracker__step:first-child::before { display: none; }
.tracker__step.done::before  { background: #2D9C95; }
.tracker__step.active::before { background: #2D9C95; }

.tracker__dot {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #E8ECEB;
  border: 2px solid #E8ECEB;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1;
  transition: all .25s;
  color: #9aa4ae;
  flex-shrink: 0;
}
.tracker__step.done  .tracker__dot {
  background: #2D9C95;
  border-color: #2D9C95;
  color: #fff;
}
.tracker__step.active .tracker__dot {
  background: #fff;
  border-color: #2D9C95;
  color: #2D9C95;
  box-shadow: 0 0 0 4px rgba(45,156,149,.14);
}
.tracker__step.warn .tracker__dot {
  background: #fff;
  border-color: #F4A340;
  color: #F4A340;
  box-shadow: 0 0 0 4px rgba(244,163,64,.14);
}

.tracker__label {
  margin-top: 8px;
  font-size: 10px;
  font-weight: 600;
  color: #9aa4ae;
  text-align: center;
  line-height: 1.3;
  max-width: 72px;
  letter-spacing: .02em;
}
.tracker__step.done  .tracker__label { color: #2D9C95; }
.tracker__step.active .tracker__label { color: #1D2329; }
.tracker__step.warn  .tracker__label { color: #B8770A; }

/* ─── STATUS MESSAGE BANNER ─────────────────────────────────── */
.status-banner {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 16px 20px;
  border-radius: 12px;
  margin-bottom: 20px;
  background: #F0EFEA;
}
.status-banner--teal  { background: #EDFAF9; }
.status-banner--amber { background: #FFF8EC; }
.status-banner--red   { background: #FFF0F0; }
.status-banner--purple { background: #F5F0FF; }

.status-banner__icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.status-banner--teal   .status-banner__icon { background: #C8F0ED; color: #1E8A84; }
.status-banner--amber  .status-banner__icon { background: #FDEACD; color: #B8770A; }
.status-banner--red    .status-banner__icon { background: #FCCFCF; color: #C41A1A; }
.status-banner--purple .status-banner__icon { background: #E4D8FF; color: #6B3FC7; }

.status-banner__title {
  font-size: 15px;
  font-weight: 700;
  color: #1D2329;
  margin-bottom: 3px;
}
.status-banner__desc { font-size: 13px; color: #5a6470; line-height: 1.5; }

/* ─── ACTION ZONE ───────────────────────────────────────────── */
.action-zone {
  background: #ffffff;
  border-radius: 16px;
  padding: 24px;
  margin-bottom: 20px;
  box-shadow: 0 2px 12px rgba(29,35,41,.06), 0 1px 3px rgba(29,35,41,.04);
  border-top: 3px solid #2D9C95;
}
.action-zone--amber { border-top-color: #F4A340; }
.action-zone--red   { border-top-color: #E04040; }

.action-zone__title {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 4px;
}
.action-zone__desc {
  font-size: 13px;
  color: #5a6470;
  margin-bottom: 20px;
  line-height: 1.5;
}

/* Preview images in action zone */
.preview-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}
.preview-gallery__img {
  width: 100%;
  aspect-ratio: 16/10;
  object-fit: cover;
  border-radius: 10px;
  border: 1px solid #E8ECEB;
  cursor: pointer;
  transition: transform .2s, box-shadow .2s;
}
.preview-gallery__img:hover {
  transform: scale(1.02);
  box-shadow: 0 8px 24px rgba(29,35,41,.12);
}

.action-zone__btns {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

/* Pay now button */
.pay-btn {
  background: #157A55;
  color: #fff;
  padding: 14px 28px;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  transition: opacity .18s, box-shadow .18s;
}
.pay-btn:hover { opacity: .88; box-shadow: 0 6px 20px rgba(21,122,85,.28); }

/* Pay button — clicked/disabled state */
.pay-btn--clicked {
  background: #C8CDD2;
  color: #5a6470;
  cursor: not-allowed;
  pointer-events: none;
  box-shadow: none;
  opacity: 1;
}

/* Fallback link under grayed pay button */
.pay-fallback {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: 480px;
}
.pay-fallback__note {
  font-size: 13px;
  color: #5a6470;
  line-height: 1.5;
}
.pay-fallback__row {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #F0EFEA;
  border: 1px solid #D0D4D8;
  border-radius: 10px;
  padding: 10px 14px;
  overflow: hidden;
}
.pay-fallback__url {
  flex: 1;
  font-size: 13px;
  color: #5a6470;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  user-select: all;
}
.pay-fallback__copy {
  background: #1D2329;
  color: #fff;
  border: none;
  border-radius: 7px;
  padding: 6px 12px;
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  transition: opacity .15s;
}
.pay-fallback__copy:hover { opacity: .82; }

/* ─── ACTIVITY FEED ─────────────────────────────────────────── */
.feed-section {
  background: #ffffff;
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 2px 12px rgba(29,35,41,.06), 0 1px 3px rgba(29,35,41,.04);
}
.feed-section__title {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: #9aa4ae;
  margin-bottom: 20px;
}

.feed { display: flex; flex-direction: column; gap: 0; }

.feed__item {
  display: flex;
  gap: 14px;
  padding-bottom: 24px;
  position: relative;
}
/* vertical timeline line */
.feed__item::before {
  content: '';
  position: absolute;
  left: 15px;
  top: 32px;
  bottom: 0;
  width: 1px;
  background: #E8ECEB;
}
.feed__item:last-child::before { display: none; }

.feed__icon {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  z-index: 1;
}
.feed__icon--status  { background: #EDFAF9; color: #1E8A84; }
.feed__icon--message { background: #EEF4FF; color: #3D6FCC; }
.feed__icon--info    { background: #FFF8EC; color: #B8770A; }
.feed__icon--response{ background: #F0EFEA; color: #5a6470; }
.feed__icon--preview { background: #F5F0FF; color: #6B3FC7; }
.feed__icon--payment { background: #FFF8EC; color: #B8770A; }
.feed__icon--client  { background: #F0EFEA; color: #5a6470; }

.feed__body { flex: 1; min-width: 0; }
.feed__header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 4px;
}
.feed__who {
  font-size: 12px;
  font-weight: 700;
  color: #1D2329;
}
.feed__when {
  font-size: 11px;
  color: #9aa4ae;
}
.feed__text {
  font-size: 14px;
  color: #1D2329;
  line-height: 1.55;
  white-space: pre-wrap;
  word-break: break-word;
}
.feed__text--muted { color: #5a6470; font-style: italic; }

/* File attachments in feed */
.feed__files {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}
.feed__file-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 10px;
  background: #F0EFEA;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 500;
  color: #5a6470;
  text-decoration: none;
}
.feed__file-link:hover { background: #E8ECEB; color: #1D2329; }

/* Inline preview thumbnails in feed */
.feed__thumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}
.feed__thumb {
  width: 80px;
  height: 60px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid #E8ECEB;
  cursor: pointer;
  transition: transform .15s;
}
.feed__thumb:hover { transform: scale(1.05); }

/* Status change item */
.feed__status-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 100px;
  font-size: 12px;
  font-weight: 700;
}

/* Empty feed */
.feed--empty {
  text-align: center;
  padding: 32px 0;
  color: #9aa4ae;
  font-size: 14px;
}

/* ─── LIGHTBOX ──────────────────────────────────────────────── */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(0,0,0,.88);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s;
}
.lightbox.open {
  opacity: 1;
  pointer-events: all;
}
.lightbox__img {
  max-width: 100%;
  max-height: 90vh;
  object-fit: contain;
  border-radius: 8px;
}
.lightbox__close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255,255,255,.15);
  border: none;
  color: #fff;
  cursor: pointer;
  font-size: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.lightbox__close:hover { background: rgba(255,255,255,.25); }

/* ─── SPINNER ───────────────────────────────────────────────── */
.spinner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 64px 24px;
  gap: 16px;
  color: #9aa4ae;
  font-size: 14px;
}
.spinner__ring {
  width: 36px;
  height: 36px;
  border: 3px solid #E8ECEB;
  border-top-color: #2D9C95;
  border-radius: 50%;
  animation: spin .75s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ─── ERROR STATE ───────────────────────────────────────────── */
.error-state {
  text-align: center;
  padding: 64px 24px;
}
.error-state__icon { font-size: 40px; margin-bottom: 16px; }
.error-state h2 { font-size: 20px; margin-bottom: 8px; }
.error-state p { color: #5a6470; margin-bottom: 24px; }

/* ─── TOAST ─────────────────────────────────────────────────── */
.toast-wrap {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 999;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  pointer-events: none;
}
.toast {
  padding: 10px 18px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 600;
  color: #fff;
  background: #1D2329;
  box-shadow: 0 4px 16px rgba(0,0,0,.2);
  opacity: 0;
  transform: translateY(8px);
  transition: opacity .22s, transform .22s;
  pointer-events: all;
}
.toast.show { opacity: 1; transform: translateY(0); }
.toast--success { background: #157A55; }
.toast--error   { background: #C41A1A; }


/* ═══════════════════════════════════════════════════════════════
   ADMIN PANEL
═══════════════════════════════════════════════════════════════ */

/* ─── ADMIN LOGIN OVERLAY ───────────────────────────────────── */
.admin-login {
  position: fixed;
  inset: 0;
  z-index: 999;
  background: #F7F6F2;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.admin-login__box {
  background: #ffffff;
  border-radius: 20px;
  padding: 40px;
  width: 100%;
  max-width: 380px;
  box-shadow: 0 8px 40px rgba(29,35,41,.10);
  text-align: center;
}
.admin-login__logo {
  height: 32px;
  margin-bottom: 24px;
}
.admin-login__box h1 { font-size: 22px; font-weight: 700; margin-bottom: 6px; }
.admin-login__box p  { color: #5a6470; font-size: 14px; margin-bottom: 24px; }
.admin-login__form { text-align: left; display: flex; flex-direction: column; gap: 12px; }
.admin-login__err {
  font-size: 13px;
  color: #C41A1A;
  text-align: center;
  display: none;
}
.admin-login__err.visible { display: block; }

/* ─── ADMIN LAYOUT ──────────────────────────────────────────── */
.admin-body { overflow: hidden; }

.admin-layout {
  display: grid;
  grid-template-columns: 340px 1fr;
  height: calc(100vh - 60px);
  overflow: hidden;
}

/* ─── SIDEBAR ───────────────────────────────────────────────── */
.admin-sidebar {
  display: flex;
  flex-direction: column;
  border-right: 1px solid #E8ECEB;
  background: #ffffff;
  overflow: hidden;
}

.admin-sidebar__top {
  padding: 16px;
  border-bottom: 1px solid #E8ECEB;
  flex-shrink: 0;
}

/* Stats row */
.admin-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  padding: 14px 16px;
  border-bottom: 1px solid #E8ECEB;
  flex-shrink: 0;
}
.admin-stat {
  text-align: center;
}
.admin-stat__val {
  font-size: 20px;
  font-weight: 800;
  color: #1D2329;
  line-height: 1;
}
.admin-stat__lbl {
  font-size: 10px;
  font-weight: 600;
  color: #9aa4ae;
  text-transform: uppercase;
  letter-spacing: .04em;
  margin-top: 3px;
}

/* Filter tabs */
.filter-tabs {
  display: flex;
  gap: 2px;
  padding: 10px 16px;
  border-bottom: 1px solid #E8ECEB;
  overflow-x: auto;
  flex-shrink: 0;
}
.filter-tabs::-webkit-scrollbar { display: none; }
.filter-tab {
  padding: 5px 12px;
  border-radius: 100px;
  border: none;
  background: transparent;
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  color: #5a6470;
  cursor: pointer;
  white-space: nowrap;
  transition: background .15s, color .15s;
}
.filter-tab:hover { background: #F0EFEA; }
.filter-tab.active { background: #1D2329; color: #fff; }

/* Search */
.admin-search {
  position: relative;
}
.admin-search input {
  width: 100%;
  padding: 9px 12px 9px 34px;
  border: 1.5px solid #E8ECEB;
  border-radius: 10px;
  font-family: inherit;
  font-size: 13px;
  color: #1D2329;
  background: #F7F6F2;
  outline: none;
  transition: border-color .18s;
}
.admin-search input:focus { border-color: #2D9C95; background: #fff; }
.admin-search__icon {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  color: #9aa4ae;
  pointer-events: none;
}

/* Orders list */
.orders-list {
  flex: 1;
  overflow-y: auto;
  padding: 8px;
}
.orders-list::-webkit-scrollbar { width: 4px; }
.orders-list::-webkit-scrollbar-thumb { background: #E8ECEB; border-radius: 4px; }

.order-card {
  padding: 14px;
  border-radius: 12px;
  cursor: pointer;
  transition: background .15s;
  border: 1.5px solid transparent;
  margin-bottom: 4px;
}
.order-card:hover { background: #F7F6F2; }
.order-card.active { background: #EDFAF9; border-color: #2D9C95; }

.order-card__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 6px;
}
.order-card__name {
  font-size: 14px;
  font-weight: 700;
  color: #1D2329;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.order-card__time {
  font-size: 11px;
  color: #9aa4ae;
  flex-shrink: 0;
}
.order-card__ref {
  font-size: 11px;
  font-weight: 600;
  color: #9aa4ae;
  margin-bottom: 6px;
  letter-spacing: .03em;
}
.order-card__pkg {
  font-size: 12px;
  color: #5a6470;
  margin-bottom: 8px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Dot indicator for needs-attention orders */
.order-card__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #F4A340;
  flex-shrink: 0;
}

.orders-empty {
  text-align: center;
  padding: 40px 16px;
  color: #9aa4ae;
  font-size: 13px;
}

/* ─── ORDER DETAIL PANEL ────────────────────────────────────── */
.admin-detail {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: #F7F6F2;
}

/* Empty state */
.admin-detail__empty {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: #9aa4ae;
  gap: 12px;
}
.admin-detail__empty-icon {
  width: 56px;
  height: 56px;
  background: #F0EFEA;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.admin-detail__empty p { font-size: 14px; }

/* Detail header */
.detail-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  background: #ffffff;
  border-bottom: 1px solid #E8ECEB;
  flex-shrink: 0;
  gap: 16px;
}
.detail-header__left { min-width: 0; }
.detail-header__name {
  font-size: 18px;
  font-weight: 700;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.detail-header__meta {
  font-size: 12px;
  color: #9aa4ae;
  margin-top: 2px;
}
.detail-header__right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

/* Scrollable content */
.detail-content {
  flex: 1;
  overflow-y: auto;
  padding: 20px 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.detail-content::-webkit-scrollbar { width: 4px; }
.detail-content::-webkit-scrollbar-thumb { background: #D0D4D8; border-radius: 4px; }

/* Top: info cards in a responsive horizontal grid */
.detail-info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 14px;
  align-items: start;
}

/* Bottom row: narrow actions + wide feed */
.detail-bottom-row {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

/* Feed column (right, wide) */
.detail-feed-col { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 16px; }

/* Action card column (left, narrow) */
.detail-actions-col { width: 260px; flex-shrink: 0; display: flex; flex-direction: column; gap: 14px; }

/* Order info card */
.info-card {
  background: #ffffff;
  border-radius: 14px;
  padding: 18px;
  box-shadow: 0 1px 6px rgba(29,35,41,.05);
}
.info-card__title {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: #9aa4ae;
  margin-bottom: 12px;
}
.info-row {
  display: flex;
  flex-direction: column;
  gap: 1px;
  padding: 6px 0;
  border-bottom: 1px solid #F0EFEA;
}
.info-row:last-child { border-bottom: none; }
.info-row__label { font-size: 11px; color: #9aa4ae; font-weight: 600; }
.info-row__val {
  font-size: 13px;
  color: #1D2329;
  font-weight: 500;
  word-break: break-word;
}
.info-row__val a { color: #2D9C95; text-decoration: none; }
.info-row__val a:hover { text-decoration: underline; }

/* Action card */
.action-card {
  background: #ffffff;
  border-radius: 14px;
  padding: 18px;
  box-shadow: 0 1px 6px rgba(29,35,41,.05);
}
.action-card__title {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: #9aa4ae;
  margin-bottom: 14px;
}
.action-card__btns {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* Action sub-panel (revealed on click) */
.action-panel {
  background: #F7F6F2;
  border-radius: 10px;
  padding: 14px;
  display: none;
  flex-direction: column;
  gap: 10px;
}
.action-panel.open { display: flex; }
.action-panel__title {
  font-size: 13px;
  font-weight: 700;
  color: #1D2329;
}
.action-panel__btns {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
  flex-wrap: wrap;
}

/* Brief details in admin */
.brief-section {
  background: #ffffff;
  border-radius: 14px;
  padding: 18px;
  box-shadow: 0 1px 6px rgba(29,35,41,.05);
}
.brief-section__title {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: #9aa4ae;
  margin-bottom: 12px;
}

/* ─── ADMIN FEED (inside detail panel) ─────────────────────── */
.admin-feed-wrap {
  background: #ffffff;
  border-radius: 14px;
  padding: 18px;
  box-shadow: 0 1px 6px rgba(29,35,41,.05);
}
.admin-feed-title {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: #9aa4ae;
  margin-bottom: 16px;
}

/* ─── RESPONSIVE ────────────────────────────────────────────── */
@media (max-width: 768px) {
  .admin-layout {
    grid-template-columns: 1fr;
    grid-template-rows: auto 1fr;
  }
  .admin-sidebar {
    height: auto;
    max-height: 45vh;
    border-right: none;
    border-bottom: 1px solid #E8ECEB;
  }
  .detail-info-grid { grid-template-columns: 1fr 1fr; }
  .detail-bottom-row { flex-direction: column; }
  .detail-actions-col { width: 100%; }

  .lookup-form { flex-direction: column; }
  .tracker__label { font-size: 9px; max-width: 60px; }
}

@media (max-width: 480px) {
  .dashboard { padding: 16px 14px 60px; }
  .order-hero { padding: 18px; }
  .action-zone { padding: 16px; }
  .feed-section { padding: 16px; }
  .detail-header { padding: 12px 16px; }
  .detail-content { padding: 14px 16px; }
}
