/* =================== RESET & BASE =================== */
* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

:root {
  --primary: #00549B;          /* Kutchina brand blue */
  --primary-dark: #003D74;     /* Deeper brand blue */
  --primary-light: #E3F0FA;    /* Light blue tint */
  --accent: #ED1C24;           /* Kutchina brand red (i dot) */
  --accent-light: #FCE4E5;     /* Light red tint */
  --bg: #F7F8FA;
  --white: #FFFFFF;
  --text: #1A1A1A;
  --text-light: #6B7280;
  --text-muted: #9CA3AF;
  --border: #E5E7EB;
  --shadow-sm: 0 2px 6px rgba(0,0,0,.05);
  --shadow: 0 4px 16px rgba(0,0,0,.08);
  --shadow-lg: 0 8px 28px rgba(0,0,0,.12);
  --radius: 14px;
  --radius-sm: 10px;
  --radius-lg: 20px;
}

html, body {
  font-family: 'Poppins', -apple-system, BlinkMacSystemFont, sans-serif;
  background: #E5E7EB;
  color: var(--text);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* =================== PHONE FRAME =================== */
body {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.screen {
  display: none;
  width: 100%;
  max-width: 440px;
  min-height: 100vh;
  background: var(--bg);
  position: relative;
  overflow: hidden;
  box-shadow: 0 0 60px rgba(0,0,0,.15);
}

@media (min-width: 768px) {
  body { padding: 20px; }
  .screen {
    min-height: 90vh;
    max-height: 920px;
    border-radius: 28px;
    border: 8px solid #1a1a1a;
  }
}

.screen.active { display: block; animation: fadeIn .4s ease; }

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

/* =================== LOGIN SCREEN =================== */
#loginScreen {
  background: #F7F8FA;
  min-height: 100vh;
  display: none;
  position: relative;
  overflow: hidden;
}
#loginScreen.active { display: block; }

.login-bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  opacity: .35;
}
.blob-1 { width: 300px; height: 300px; background: #00549B; top: -120px; right: -100px; opacity:.15; }
.blob-2 { width: 250px; height: 250px; background: #ED1C24; bottom: 10%; left: -80px; opacity:.10; }
.blob-3 { width: 200px; height: 200px; background: #00549B; top: 40%; right: -50px; opacity:.10; }

.login-container {
  position: relative;
  z-index: 2;
  padding: 40px 24px 24px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.logo-wrap {
  text-align: center;
  margin-bottom: 32px;
  animation: slideDown .8s ease;
  background: #fff;
  border-radius: 20px;
  padding: 24px 16px;
  box-shadow: 0 4px 20px rgba(0,84,155,.08);
}
@keyframes slideDown {
  from { opacity: 0; transform: translateY(-20px); }
  to { opacity: 1; transform: translateY(0); }
}

.logo-mark {
  width: 100%;
  max-width: 280px;
  margin: 0 auto;
  animation: pulse 2.5s ease-in-out infinite;
  display: flex;
  align-items: center;
  justify-content: center;
}
@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.03); }
}
.brand-logo-img {
  width: 100%;
  height: auto;
  max-width: 280px;
  aspect-ratio: 4813 / 1162;
  display: block;
  object-fit: contain;
}

.login-card {
  background: #fff;
  border-radius: 20px;
  padding: 26px 22px;
  box-shadow: 0 4px 20px rgba(0,84,155,.08);
  border-top: 4px solid var(--primary);
  animation: slideUp .7s ease .2s backwards;
}
@keyframes slideUp {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}

.login-title {
  font-size: 22px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 4px;
}
.login-sub {
  font-size: 13px;
  color: var(--text-light);
  margin-bottom: 22px;
}

.login-form { display: flex; flex-direction: column; gap: 14px; }

.input-group {
  position: relative;
  display: flex;
  align-items: center;
  background: #F3F4F6;
  border: 2px solid transparent;
  border-radius: 12px;
  padding: 0 14px;
  height: 52px;
  transition: all .2s;
}
.input-group:focus-within {
  background: #fff;
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(0,84,155,.1);
}
.input-icon {
  display: flex;
  align-items: center;
  color: var(--text-light);
  margin-right: 10px;
}
.input-icon svg { width: 20px; height: 20px; }
.input-group input {
  flex: 1;
  border: none;
  background: none;
  outline: none;
  font-size: 15px;
  color: var(--text);
  font-family: inherit;
}
.input-group input::placeholder { color: var(--text-muted); }
.toggle-pass {
  display: flex;
  color: var(--text-light);
  cursor: pointer;
  padding: 4px;
}
.toggle-pass svg { width: 20px; height: 20px; }

.form-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  margin-top: 2px;
}
.remember { display: flex; align-items: center; gap: 6px; color: var(--text-light); cursor: pointer; }
.remember input { accent-color: var(--primary); width: 16px; height: 16px; }
.forgot { color: var(--primary); text-decoration: none; font-weight: 500; }

.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  border: none;
  border-radius: 12px;
  height: 52px;
  font-size: 16px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 8px 20px rgba(0,84,155,.35);
  transition: all .2s;
  margin-top: 6px;
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 28px rgba(0,84,155,.45); }
.btn-primary:active { transform: translateY(0); }
.btn-primary svg { width: 18px; height: 18px; }

.divider {
  text-align: center;
  position: relative;
  margin: 18px 0 14px;
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 500;
}
.divider::before, .divider::after {
  content: '';
  position: absolute;
  top: 50%;
  width: 38%;
  height: 1px;
  background: var(--border);
}
.divider::before { left: 0; }
.divider::after { right: 0; }

.sso-row { display: flex; flex-direction: column; gap: 10px; }
.sso-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  height: 50px;
  border-radius: 10px;
  border: 1.5px solid var(--border);
  background: #fff;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  font-family: inherit;
  transition: all .2s;
}
.sso-btn:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow);
  border-color: var(--primary);
  background: var(--primary-light);
}
.sso-btn:active { transform: translateY(0); }
.sso-btn svg { flex-shrink: 0; }
.sso-btn.sso-microsoft {
  background: #2F2F2F;
  border-color: #2F2F2F;
  color: #fff;
  font-size: 14px;
  font-weight: 500;
}
.sso-btn.sso-microsoft:hover {
  background: #1A1A1A;
  border-color: #1A1A1A;
  color: #fff;
  box-shadow: 0 8px 20px rgba(0,0,0,.2);
}

.sso-info {
  text-align: center;
  font-size: 11px;
  color: var(--text-light);
  margin-top: 10px;
  line-height: 1.5;
}

.signup-text {
  text-align: center;
  font-size: 13px;
  color: var(--text-light);
  margin-top: 18px;
}
.link { color: var(--primary); font-weight: 600; text-decoration: none; }

.login-footer {
  text-align: center;
  font-size: 11px;
  color: rgba(255,255,255,.7);
  margin-top: 20px;
  line-height: 1.6;
}
.login-footer a { color: #fff; text-decoration: underline; font-weight: 500; }


/* =================== HOME SCREEN =================== */
.app-bar {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  padding: 16px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #fff;
  position: sticky;
  top: 0;
  z-index: 10;
  box-shadow: 0 4px 16px rgba(0,84,155,.25);
}

.bar-left { display: flex; align-items: center; gap: 12px; }
.app-logo {
  background: #fff;
  border-radius: 6px;
  padding: 3px 6px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  box-shadow: 0 2px 6px rgba(0,0,0,.15);
}
.app-logo-img {
  height: 26px;
  width: auto;
  aspect-ratio: 4813 / 1162;
  display: block;
  object-fit: contain;
}
.bar-titles h1 { font-size: 16px; font-weight: 700; letter-spacing: 1.5px; }
.bar-titles p { font-size: 12px; opacity: .9; }
.wave { display: inline-block; animation: wave 1.5s ease-in-out infinite; }
@keyframes wave {
  0%, 100% { transform: rotate(0); }
  25% { transform: rotate(15deg); }
  75% { transform: rotate(-10deg); }
}

.bar-right { display: flex; align-items: center; gap: 8px; position: relative; }
.icon-btn {
  position: relative;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255,255,255,.18);
  border: none;
  color: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all .2s;
}
.icon-btn:hover { background: rgba(255,255,255,.28); }
.icon-btn svg { width: 20px; height: 20px; }
.badge {
  position: absolute;
  top: 4px;
  right: 4px;
  background: var(--accent);
  color: #1a1a1a;
  font-size: 9px;
  font-weight: 700;
  min-width: 16px;
  height: 16px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  border: 2px solid var(--primary);
}
.avatar-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--primary-dark);
  border: 2px solid #fff;
  font-weight: 700;
  font-size: 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Search */
.search-wrap {
  padding: 14px 18px 8px;
  background: var(--white);
}
.search-bar {
  display: flex;
  align-items: center;
  background: #F3F4F6;
  border-radius: 12px;
  padding: 0 14px;
  height: 46px;
  border: 1.5px solid transparent;
  transition: all .2s;
}
.search-bar:focus-within {
  background: #fff;
  border-color: var(--primary);
}
.search-bar svg { width: 18px; height: 18px; color: var(--text-light); }
.search-bar input {
  flex: 1;
  border: none;
  background: none;
  outline: none;
  font-size: 14px;
  font-family: inherit;
  padding: 0 10px;
  color: var(--text);
}
.mic-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--primary);
  display: flex;
  padding: 4px;
}
.mic-btn svg { width: 18px; height: 18px; }

/* Content */
.content {
  padding: 0 18px 20px;
  overflow-y: auto;
  max-height: calc(100vh - 200px);
  scroll-behavior: smooth;
}
@media (min-width: 768px) {
  .content { max-height: calc(90vh - 200px); }
}

/* Hero Section */
.hero-section { margin: 16px 0 22px; }
.hero-slider {
  display: flex;
  gap: 14px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  padding-bottom: 6px;
}
.hero-slider::-webkit-scrollbar { display: none; }
.hero-card {
  flex: 0 0 100%;
  min-width: 100%;
  background: linear-gradient(135deg, #00549B, #1976D2);
  border-radius: 18px;
  padding: 22px;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  scroll-snap-align: start;
  box-shadow: 0 8px 24px rgba(0,84,155,.3);
  position: relative;
  overflow: hidden;
}
.hero-card::before {
  content: '';
  position: absolute;
  top: -40px;
  right: -40px;
  width: 140px;
  height: 140px;
  background: rgba(255,255,255,.1);
  border-radius: 50%;
}
.hero-card::after {
  content: '';
  position: absolute;
  bottom: -60px;
  left: -30px;
  width: 100px;
  height: 100px;
  background: rgba(255,255,255,.08);
  border-radius: 50%;
}
.hero-2 { background: linear-gradient(135deg, #FF8C00, #FFB800); box-shadow: 0 8px 24px rgba(255,140,0,.3); }
.hero-text { z-index: 1; flex: 1; }
.hero-tag {
  display: inline-block;
  background: rgba(255,255,255,.25);
  padding: 4px 10px;
  border-radius: 12px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1px;
  margin-bottom: 10px;
}
.hero-text h3 { font-size: 20px; font-weight: 700; margin-bottom: 4px; line-height: 1.2; }
.hero-text p { font-size: 12px; opacity: .9; margin-bottom: 14px; }
.hero-btn {
  background: #fff;
  color: var(--primary);
  border: none;
  padding: 8px 18px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
}
.hero-2 .hero-btn { color: #FF8C00; }
.hero-illust { z-index: 1; flex-shrink: 0; }
.hero-illust svg { width: 90px; height: 90px; }

.hero-dots { display: flex; justify-content: center; gap: 6px; margin-top: 10px; }
.dot {
  width: 6px;
  height: 6px;
  background: #D1D5DB;
  border-radius: 3px;
  transition: all .2s;
}
.dot.active { width: 22px; background: var(--primary); }

/* Stats Row */
.stats-row {
  background: #fff;
  border-radius: 16px;
  padding: 18px 12px;
  display: flex;
  align-items: center;
  justify-content: space-around;
  margin-bottom: 22px;
  box-shadow: var(--shadow-sm);
}
.stat { text-align: center; flex: 1; }
.stat-num {
  font-size: 22px;
  font-weight: 700;
  color: var(--primary);
  line-height: 1;
  margin-bottom: 4px;
}
.stat-label { font-size: 11px; color: var(--text-light); }
.stat-divider { width: 1px; height: 30px; background: var(--border); }

/* Section */
.section { margin-bottom: 24px; }
.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.section-title { font-size: 18px; font-weight: 700; color: var(--text); }
.section-action { font-size: 12px; color: var(--primary); font-weight: 600; cursor: pointer; }

/* Menu Grid */
.menu-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.menu-card {
  background: #fff;
  border-radius: 14px;
  padding: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  transition: all .2s;
  text-decoration: none;
  color: var(--text);
  position: relative;
  border: 1.5px solid transparent;
  box-shadow: var(--shadow-sm);
}
.menu-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
  border-color: var(--primary-light);
}
.menu-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.menu-icon svg { width: 22px; height: 22px; }

.icon-blue { background: #E3F2FD; color: #1976D2; }
.icon-red { background: var(--accent-light); color: var(--accent); }
.icon-orange { background: #FFF3E0; color: #F57C00; }
.icon-purple { background: #F3E5F5; color: #7B1FA2; }
.icon-green { background: #E8F5E9; color: #388E3C; }
.icon-teal { background: #E0F2F1; color: #00796B; }
.icon-pink { background: #FCE4EC; color: #C2185B; }
.icon-indigo { background: #E8EAF6; color: #303F9F; }
.icon-cyan { background: #E0F7FA; color: #0097A7; }
.icon-yellow { background: #FFF8E1; color: #F9A825; }

.menu-text { flex: 1; min-width: 0; }
.menu-text h4 { font-size: 13px; font-weight: 600; margin-bottom: 2px; line-height: 1.2; }
.menu-text p { font-size: 10px; color: var(--text-light); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.menu-arrow {
  font-size: 22px;
  color: var(--text-muted);
  font-weight: 300;
}
.menu-badge {
  position: absolute;
  top: 8px;
  right: 32px;
  background: var(--accent);
  color: var(--primary-dark);
  font-size: 9px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 8px;
}

/* Product Scroll */
.product-scroll {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  scrollbar-width: none;
  padding-bottom: 4px;
  margin: 0 -18px;
  padding: 0 18px 4px;
}
.product-scroll::-webkit-scrollbar { display: none; }
.product-card {
  flex: 0 0 160px;
  background: #fff;
  border-radius: 14px;
  padding: 10px;
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  transition: all .2s;
}
.product-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.product-img {
  width: 100%;
  height: 110px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  margin-bottom: 8px;
  overflow: hidden;
}
.product-img svg { width: 70%; height: 70%; }
.product-tag {
  position: absolute;
  top: 6px;
  left: 6px;
  background: var(--primary);
  color: #fff;
  font-size: 9px;
  font-weight: 700;
  padding: 3px 6px;
  border-radius: 6px;
}
.product-card h4 { font-size: 12px; font-weight: 600; margin-bottom: 4px; line-height: 1.3; }
.product-price { font-size: 13px; font-weight: 700; color: var(--text); margin-bottom: 4px; }
.product-price .strike { font-size: 10px; color: var(--text-muted); text-decoration: line-through; font-weight: 400; margin-left: 4px; }
.product-rating { font-size: 10px; color: var(--text-light); }

/* Promo Banner */
.promo-banner {
  background: linear-gradient(135deg, #1A1A1A, #2D2D2D);
  border-radius: 16px;
  padding: 18px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #fff;
  position: relative;
  overflow: hidden;
}
.promo-banner::before {
  content: '';
  position: absolute;
  top: -30px;
  right: 30%;
  width: 100px;
  height: 100px;
  background: rgba(0,84,155,.3);
  border-radius: 50%;
  filter: blur(30px);
}
.promo-content { z-index: 1; }
.promo-content h3 { font-size: 16px; font-weight: 700; margin-bottom: 4px; }
.promo-content p { font-size: 11px; opacity: .8; margin-bottom: 10px; }
.promo-btn {
  background: var(--accent);
  color: #1a1a1a;
  border: none;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
}
.promo-illust { z-index: 1; }
.promo-illust svg { width: 70px; height: 70px; }

/* Bottom Nav */
.bottom-nav {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding: 8px 0 12px;
  border-top: 1px solid var(--border);
  box-shadow: 0 -4px 16px rgba(0,0,0,.05);
  z-index: 5;
}
.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  text-decoration: none;
  color: var(--text-muted);
  font-size: 10px;
  font-weight: 500;
  flex: 1;
  cursor: pointer;
  padding: 4px 0;
  transition: all .2s;
}
.nav-item svg { width: 22px; height: 22px; }
.nav-item.active { color: var(--primary); }
.nav-item.active svg { stroke: var(--primary); }

.nav-item.center-action {
  position: relative;
  margin-top: -16px;
}
.center-circle {
  width: 52px;
  height: 52px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  box-shadow: 0 6px 16px rgba(0,84,155,.4);
  margin-bottom: 2px;
  transition: all .2s;
}
.center-circle svg { width: 24px; height: 24px; }
.nav-item.center-action { color: var(--text); font-weight: 600; }


/* =================== DETAIL SCREEN =================== */
.detail-bar {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  padding: 16px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #fff;
  position: sticky;
  top: 0;
  z-index: 10;
}
.back-btn {
  background: rgba(255,255,255,.18);
  border: none;
  color: #fff;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all .2s;
}
.back-btn:hover { background: rgba(255,255,255,.28); }
.back-btn svg { width: 20px; height: 20px; }
.detail-title { font-size: 18px; font-weight: 600; flex: 1; text-align: center; }

/* Detail Content */
.detail-empty {
  text-align: center;
  padding: 60px 24px;
  color: var(--text-light);
}
.detail-empty svg { width: 80px; height: 80px; opacity: .4; margin-bottom: 16px; }
.detail-empty h3 { color: var(--text); margin-bottom: 8px; font-size: 18px; }
.detail-empty p { font-size: 13px; line-height: 1.5; }

/* Generic list items for detail screens */
.list-card {
  background: #fff;
  border-radius: 12px;
  padding: 14px;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: var(--shadow-sm);
  transition: all .2s;
  cursor: pointer;
}
.list-card:hover { box-shadow: var(--shadow); transform: translateY(-1px); }
.list-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: var(--primary-light);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.list-icon svg { width: 22px; height: 22px; }
.list-body { flex: 1; min-width: 0; }
.list-body h4 { font-size: 14px; font-weight: 600; margin-bottom: 2px; }
.list-body p { font-size: 12px; color: var(--text-light); }
.status-pill {
  font-size: 10px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 8px;
  text-transform: uppercase;
}
.status-active { background: #E8F5E9; color: #2E7D32; }
.status-pending { background: #FFF3E0; color: #EF6C00; }
.status-done { background: #E3F2FD; color: #1565C0; }

/* Tracking timeline */
.tracking-card {
  background: #fff;
  border-radius: 14px;
  padding: 18px;
  margin-bottom: 16px;
  box-shadow: var(--shadow-sm);
}
.tracking-head { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 14px; }
.tracking-head h4 { font-size: 15px; font-weight: 600; }
.tracking-head p { font-size: 11px; color: var(--text-light); }
.tracking-id { font-size: 11px; color: var(--text-muted); margin-top: 4px; }

.timeline { position: relative; padding-left: 24px; }
.timeline::before {
  content: '';
  position: absolute;
  left: 8px;
  top: 6px;
  bottom: 6px;
  width: 2px;
  background: var(--border);
}
.tl-item { position: relative; padding-bottom: 18px; }
.tl-item:last-child { padding-bottom: 0; }
.tl-item::before {
  content: '';
  position: absolute;
  left: -21px;
  top: 4px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #fff;
  border: 3px solid var(--border);
}
.tl-item.done::before { background: var(--primary); border-color: var(--primary); box-shadow: 0 0 0 4px rgba(0,84,155,.15); }
.tl-item.current::before { background: var(--accent); border-color: var(--accent); box-shadow: 0 0 0 4px rgba(255,184,0,.25); animation: pulse2 1.5s infinite; }
@keyframes pulse2 {
  0%, 100% { box-shadow: 0 0 0 4px rgba(255,184,0,.25); }
  50% { box-shadow: 0 0 0 8px rgba(255,184,0,.1); }
}
.tl-item h5 { font-size: 13px; font-weight: 600; margin-bottom: 2px; }
.tl-item p { font-size: 11px; color: var(--text-light); }
.tl-item.current h5 { color: var(--primary); }

/* Form */
.form-card {
  background: #fff;
  border-radius: 14px;
  padding: 18px;
  margin-bottom: 16px;
  box-shadow: var(--shadow-sm);
}
.form-card h3 { font-size: 15px; font-weight: 600; margin-bottom: 12px; }
.form-group { margin-bottom: 14px; }
.form-group label { display: block; font-size: 12px; font-weight: 500; color: var(--text); margin-bottom: 6px; }
.form-control {
  width: 100%;
  border: 1.5px solid var(--border);
  background: #fff;
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 13px;
  font-family: inherit;
  outline: none;
  transition: all .2s;
}
.form-control:focus { border-color: var(--primary); }
textarea.form-control { min-height: 80px; resize: vertical; }
select.form-control { cursor: pointer; }

/* Product card detail */
.product-row {
  background: #fff;
  border-radius: 12px;
  padding: 12px;
  display: flex;
  gap: 12px;
  margin-bottom: 12px;
  box-shadow: var(--shadow-sm);
  align-items: center;
}
.product-row .p-img {
  width: 70px;
  height: 70px;
  border-radius: 10px;
  background: linear-gradient(135deg,#FFE4E4,#FFC0C0);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.product-row .p-img svg { width: 50%; height: 50%; }
.product-row .p-info { flex: 1; }
.product-row .p-info h4 { font-size: 14px; font-weight: 600; margin-bottom: 2px; }
.product-row .p-info .p-id { font-size: 11px; color: var(--text-muted); margin-bottom: 4px; }
.product-row .p-info .p-status { font-size: 11px; color: #2E7D32; font-weight: 600; }

/* =================== CHATBOT SCREEN =================== */
.chat-header { display: flex; align-items: center; gap: 10px; flex: 1; }
.bot-avatar {
  width: 40px;
  height: 40px;
  background: rgba(255,255,255,.2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}
.bot-avatar svg { width: 22px; height: 22px; color: #fff; }
.chat-status { font-size: 10px; opacity: .9; }

.chat-body {
  flex: 1;
  overflow-y: auto;
  padding: 20px 16px;
  background: var(--bg);
  max-height: calc(100vh - 180px);
  scroll-behavior: smooth;
}
@media (min-width: 768px) {
  .chat-body { max-height: calc(90vh - 180px); }
}

.chat-msg { margin-bottom: 12px; display: flex; }
.chat-msg.bot { justify-content: flex-start; }
.chat-msg.user { justify-content: flex-end; }
.bubble {
  max-width: 75%;
  padding: 10px 14px;
  border-radius: 16px;
  font-size: 14px;
  line-height: 1.4;
  word-wrap: break-word;
}
.chat-msg.bot .bubble {
  background: #fff;
  color: var(--text);
  border-bottom-left-radius: 4px;
  box-shadow: var(--shadow-sm);
}
.chat-msg.user .bubble {
  background: var(--primary);
  color: #fff;
  border-bottom-right-radius: 4px;
}

.quick-replies {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 12px 0 0 0;
  padding: 0 0 0 0;
}
.quick-btn {
  background: #fff;
  border: 1.5px solid var(--primary);
  color: var(--primary);
  padding: 8px 14px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  font-family: inherit;
  transition: all .2s;
}
.quick-btn:hover { background: var(--primary); color: #fff; }

.chat-input {
  background: #fff;
  padding: 12px 14px;
  display: flex;
  align-items: center;
  gap: 8px;
  border-top: 1px solid var(--border);
  position: sticky;
  bottom: 0;
}
.attach-btn, .send-btn {
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  padding: 6px;
  color: var(--text-light);
}
.attach-btn svg, .send-btn svg { width: 20px; height: 20px; }
.send-btn { color: var(--primary); background: var(--primary-light); border-radius: 50%; width: 40px; height: 40px; }
.send-btn svg { width: 18px; height: 18px; }
.chat-input input {
  flex: 1;
  border: none;
  background: #F3F4F6;
  border-radius: 20px;
  padding: 10px 14px;
  outline: none;
  font-size: 14px;
  font-family: inherit;
}

/* Scrollbar */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(0,0,0,.2); border-radius: 3px; }


/* =================== DASHBOARD ADDITIONS =================== */

/* Greeting Strip */
.greeting-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(135deg, #00549B 0%, #003D74 100%);
  margin: 0 16px 16px;
  padding: 18px 20px;
  border-radius: 18px;
  color: #fff;
  position: relative;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0, 84, 155, 0.25);
}
.greeting-strip::after {
  content: '';
  position: absolute;
  right: -40px;
  top: -40px;
  width: 160px;
  height: 160px;
  background: radial-gradient(circle, rgba(237,28,36,0.18) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}
.greet-text { position: relative; z-index: 1; }
.greet-hi { font-size: 18px; font-weight: 700; letter-spacing: -0.2px; }
.greet-sub { font-size: 12px; opacity: 0.85; margin-top: 2px; font-weight: 400; }
.greet-avatar {
  position: relative;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #ED1C24, #B8102A);
  border-radius: 50%;
  color: #fff;
  font-weight: 700;
  font-size: 16px;
  letter-spacing: 0.5px;
  flex-shrink: 0;
}
.greet-ring {
  position: absolute;
  inset: -4px;
  border: 2px solid rgba(255,255,255,0.4);
  border-radius: 50%;
  animation: ringPulse 2s infinite;
}
@keyframes ringPulse {
  0% { transform: scale(1); opacity: 0.6; }
  100% { transform: scale(1.25); opacity: 0; }
}

/* KPI Grid */
.kpi-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  padding: 0 16px;
  margin-bottom: 16px;
}
.kpi-card {
  background: #fff;
  border-radius: 14px;
  padding: 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  position: relative;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
  border: 1px solid rgba(0,0,0,0.04);
  transition: transform .2s, box-shadow .2s;
}
.kpi-card:active { transform: scale(0.97); }
.kpi-card:hover { box-shadow: 0 4px 16px rgba(0,0,0,0.08); }
.kpi-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.kpi-icon svg { width: 22px; height: 22px; stroke-width: 2; }
.kpi-blue .kpi-icon { background: #E3F2FD; color: #1976D2; }
.kpi-green .kpi-icon { background: #E8F5E9; color: #2E7D32; }
.kpi-amber .kpi-icon { background: #FFF3E0; color: #F57C00; }
.kpi-purple .kpi-icon { background: #F3E5F5; color: #7B1FA2; }
.kpi-info { flex: 1; min-width: 0; }
.kpi-num { font-size: 22px; font-weight: 700; color: #1A1A1A; line-height: 1.1; }
.kpi-unit { font-size: 13px; font-weight: 500; color: #6B7280; margin-left: 1px; }
.kpi-label { font-size: 11px; color: #6B7280; font-weight: 500; margin-top: 2px; }
.kpi-trend {
  position: absolute;
  top: 10px;
  right: 10px;
  font-size: 9px;
  font-weight: 600;
  padding: 3px 6px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  gap: 3px;
}
.kpi-trend.up { background: #E8F5E9; color: #2E7D32; }
.kpi-trend.live { background: #FFEBEE; color: #ED1C24; padding: 3px 7px; }
.live-dot {
  width: 6px;
  height: 6px;
  background: #ED1C24;
  border-radius: 50%;
  animation: liveBlink 1.2s infinite;
}
@keyframes liveBlink {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.8); }
}

/* Active Service Banner */
.active-service-card {
  margin: 0 16px 16px;
  background: linear-gradient(135deg, #FFF5F5 0%, #FFE8E8 100%);
  border: 1px solid #FCD3D3;
  border-radius: 16px;
  padding: 14px 16px;
  cursor: pointer;
  position: relative;
  transition: transform .2s;
}
.active-service-card:active { transform: scale(0.99); }
.as-left { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.as-pulse {
  position: relative;
  width: 44px;
  height: 44px;
  background: #fff;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ED1C24;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(237,28,36,0.15);
}
.as-pulse svg { width: 22px; height: 22px; }
.pulse-ring {
  position: absolute;
  inset: 0;
  border: 2px solid #ED1C24;
  border-radius: 12px;
  animation: pulseRing 1.8s infinite;
}
@keyframes pulseRing {
  0% { transform: scale(1); opacity: 0.8; }
  100% { transform: scale(1.5); opacity: 0; }
}
.as-info { flex: 1; min-width: 0; }
.as-tag {
  display: inline-block;
  background: #ED1C24;
  color: #fff;
  font-size: 9px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 6px;
  letter-spacing: 0.5px;
  margin-bottom: 4px;
  text-transform: uppercase;
}
.as-info h4 { font-size: 14px; font-weight: 600; color: #1A1A1A; line-height: 1.3; }
.as-info p { font-size: 11px; color: #6B7280; margin-top: 2px; }
.as-progress { display: flex; align-items: center; gap: 10px; }
.as-progress-bar {
  flex: 1;
  height: 6px;
  background: #fff;
  border-radius: 3px;
  overflow: hidden;
  border: 1px solid #F5C2C2;
}
.as-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #ED1C24, #FF6B6B);
  border-radius: 3px;
  transition: width .4s ease;
}
.as-progress-text { font-size: 11px; font-weight: 600; color: #ED1C24; min-width: 28px; text-align: right; }

/* Quick Actions */
.quick-actions {
  display: flex;
  gap: 10px;
  padding: 0 16px;
  margin-bottom: 18px;
  overflow-x: auto;
  scrollbar-width: none;
}
.quick-actions::-webkit-scrollbar { display: none; }
.qa-item {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  text-align: center;
  cursor: pointer;
  padding: 6px 4px;
  border-radius: 12px;
  transition: transform .2s;
}
.qa-item:active { transform: scale(0.92); }
.qa-icon {
  width: 52px;
  height: 52px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  position: relative;
}
.qa-icon svg { width: 24px; height: 24px; }
.qa-orange { background: linear-gradient(135deg, #FF8A65, #F57C00); }
.qa-teal { background: linear-gradient(135deg, #4DB6AC, #00897B); }
.qa-purple { background: linear-gradient(135deg, #BA68C8, #7B1FA2); }
.qa-green { background: linear-gradient(135deg, #66BB6A, #2E7D32); }
.qa-pink { background: linear-gradient(135deg, #F06292, #C2185B); }
.qa-item span {
  font-size: 10px;
  color: #4B5563;
  font-weight: 500;
  line-height: 1.2;
}

/* Chart Card */
.chart-card {
  margin: 0 16px 18px;
  background: #fff;
  border-radius: 16px;
  padding: 16px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
  border: 1px solid rgba(0,0,0,0.04);
}
.chart-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 16px;
}
.chart-title { font-size: 15px; font-weight: 700; color: #1A1A1A; }
.chart-sub { font-size: 11px; color: #6B7280; margin-top: 2px; }
.chart-legend { display: flex; align-items: center; gap: 5px; font-size: 10px; color: #6B7280; font-weight: 500; }
.legend-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #00549B;
}
.legend-dot.completed { background: #00549B; }
.chart-bars {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  height: 100px;
  gap: 6px;
  padding: 0 4px;
  margin-bottom: 14px;
}
.bar-col {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  height: 100%;
  position: relative;
}
.bar-fill {
  width: 100%;
  max-width: 32px;
  background: linear-gradient(180deg, #4DA3DB 0%, #00549B 100%);
  border-radius: 6px 6px 0 0;
  position: relative;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 4px;
  min-height: 8px;
  transition: all .3s;
}
.bar-fill.active {
  background: linear-gradient(180deg, #FF6B6B 0%, #ED1C24 100%);
  box-shadow: 0 0 0 3px rgba(237,28,36,0.08);
}
.bar-val {
  font-size: 9px;
  font-weight: 700;
  color: #fff;
  line-height: 1;
}
.bar-label {
  font-size: 10px;
  color: #6B7280;
  font-weight: 500;
  margin-top: 6px;
}
.chart-summary {
  display: flex;
  align-items: center;
  background: #F7F8FA;
  border-radius: 10px;
  padding: 10px 6px;
}
.cs-item { flex: 1; text-align: center; }
.cs-num { font-size: 16px; font-weight: 700; color: #1A1A1A; line-height: 1.1; }
.cs-unit { font-size: 11px; color: #6B7280; font-weight: 500; }
.cs-label { font-size: 10px; color: #6B7280; margin-top: 2px; font-weight: 500; }
.cs-divider {
  width: 1px;
  height: 28px;
  background: #E5E7EB;
}

/* My Products Carousel */
.my-products-scroll {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  padding: 0 16px 4px;
  scrollbar-width: none;
  margin: 0 -16px;
  padding-left: 16px;
  padding-right: 16px;
}
.my-products-scroll::-webkit-scrollbar { display: none; }
.mp-card {
  min-width: 145px;
  background: #fff;
  border-radius: 14px;
  padding: 10px;
  border: 1px solid rgba(0,0,0,0.05);
  box-shadow: 0 2px 6px rgba(0,0,0,0.04);
  flex-shrink: 0;
  cursor: pointer;
  transition: transform .2s;
}
.mp-card:active { transform: scale(0.97); }
.mp-img {
  width: 100%;
  aspect-ratio: 1.2 / 1;
  border-radius: 10px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 8px;
  overflow: hidden;
}
.mp-img svg { width: 70%; height: 70%; }
.mp-status {
  position: absolute;
  top: 6px;
  right: 6px;
  background: rgba(46,125,50,0.95);
  color: #fff;
  font-size: 9px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 8px;
}
.mp-card h4 { font-size: 12px; font-weight: 600; color: #1A1A1A; line-height: 1.3; margin-bottom: 2px; }
.mp-model { font-size: 10px; color: #6B7280; margin-bottom: 8px; }
.mp-warranty { display: flex; align-items: center; gap: 6px; }
.mp-warranty-bar {
  flex: 1;
  height: 4px;
  background: #E5E7EB;
  border-radius: 2px;
  overflow: hidden;
}
.mp-warranty-fill {
  height: 100%;
  background: linear-gradient(90deg, #43A047, #66BB6A);
  border-radius: 2px;
}
.mp-warranty span { font-size: 9px; color: #6B7280; white-space: nowrap; font-weight: 500; }

/* Appointment Cards */
.appt-card {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #fff;
  border-radius: 14px;
  padding: 12px 14px;
  margin-bottom: 10px;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0,0,0,0.04);
  border: 1px solid rgba(0,0,0,0.04);
  transition: transform .2s;
}
.appt-card:active { transform: scale(0.99); }
.appt-date {
  background: linear-gradient(135deg, #E3F2FD, #BBDEFB);
  color: #1976D2;
  border-radius: 10px;
  padding: 8px 10px;
  text-align: center;
  min-width: 60px;
  flex-shrink: 0;
}
.appt-date.appt-future {
  background: #F7F8FA;
  color: #6B7280;
}
.appt-day { font-size: 9px; font-weight: 700; letter-spacing: 0.5px; }
.appt-time { font-size: 12px; font-weight: 600; margin-top: 2px; }
.appt-divider {
  width: 1px;
  align-self: stretch;
  background: #E5E7EB;
}
.appt-info { flex: 1; min-width: 0; }
.appt-info h4 { font-size: 13px; font-weight: 600; color: #1A1A1A; line-height: 1.3; }
.appt-info p { font-size: 11px; color: #6B7280; margin-top: 2px; }
.appt-status { font-size: 10px; font-weight: 600; margin-top: 4px; display: inline-block; }
.appt-status.status-active { color: #2E7D32; }
.appt-status.status-pending { color: #F57C00; }
.appt-card .menu-arrow {
  color: #9CA3AF;
  font-size: 22px;
  font-weight: 300;
  flex-shrink: 0;
}

/* Activity List */
.activity-list {
  background: #fff;
  border-radius: 14px;
  padding: 6px 0;
  box-shadow: 0 2px 6px rgba(0,0,0,0.04);
  border: 1px solid rgba(0,0,0,0.04);
}
.activity-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  position: relative;
}
.activity-item:not(:last-child)::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 38px;
  right: 14px;
  height: 1px;
  background: #F3F4F6;
}
.activity-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  flex-shrink: 0;
  box-shadow: 0 0 0 4px rgba(0,0,0,0.03);
}
.activity-content { flex: 1; min-width: 0; }
.activity-content h4 { font-size: 12px; font-weight: 600; color: #1A1A1A; }
.activity-content p { font-size: 11px; color: #6B7280; margin-top: 1px; }
.activity-time { font-size: 10px; color: #9CA3AF; font-weight: 500; flex-shrink: 0; }

/* Announcements */
.announce-card {
  border-radius: 14px;
  padding: 14px 16px;
  margin-bottom: 10px;
  position: relative;
  overflow: hidden;
}
.announce-tag {
  display: inline-block;
  color: #fff;
  font-size: 9px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 6px;
  letter-spacing: 0.5px;
  margin-bottom: 8px;
  text-transform: uppercase;
}
.announce-card h4 { font-size: 14px; font-weight: 700; color: #1A1A1A; line-height: 1.3; }
.announce-card p { font-size: 11px; color: #4B5563; margin-top: 4px; line-height: 1.4; }
.announce-btn {
  background: none;
  border: none;
  font-size: 12px;
  font-weight: 600;
  margin-top: 8px;
  cursor: pointer;
  font-family: inherit;
  padding: 0;
}

/* KPI scrolling fix for very small screens */
@media (max-width: 340px) {
  .kpi-num { font-size: 19px; }
  .kpi-label { font-size: 10px; }
}

