/* ======================================================================
   SERVICE INFO PLATFORM — DESIGN SYSTEM (LIGHT THEME, BANGLA-FIRST)
   ====================================================================== */

:root {
  /* Background & surface */
  --app-bg: #f4f6f9;
  --app-surface: #ffffff;
  --app-surface-elevated: #ffffff;

  /* Primary (teal scale) */
  --primary-50: #e6f7f7;
  --primary-100: #b3eeec;
  --primary-500: #0EB7B2;
  --primary-600: #0A9A96;

  /* Text */
  --text-primary: #0f172a;
  --text-secondary: #64748b;

  /* Border */
  --border: #e2e8f0;

  /* Shadow */
  --shadow-soft: 0 10px 30px rgba(2, 6, 23, 0.06);
  --shadow-header: 0 2px 12px rgba(2, 6, 23, 0.06);

  /* Radius */
  --radius-sm: 12px;
  --radius-md: 16px;
  --radius-lg: 20px;
  --radius-xl: 24px;

  /* Spacing */
  --space-page: 20px;
  --space-page-lg: 24px;
  --space-section: 32px;
  --space-card: 16px;
  --space-card-lg: 20px;

  /* Header */
  --header-height: 68px;
  --header-bg: #ffffff;
  --header-border: 1px solid var(--border);

  /* Bottom nav */
  --nav-height: 76px;
  --nav-margin: 16px;
  --nav-radius: 24px;
  --nav-shadow: 0 10px 30px rgba(2, 6, 23, 0.08);
  --safe-bottom: env(safe-area-inset-bottom, 0px);

  /* Motion */
  --motion-fast: 120ms;
  --motion-normal: 180ms;
  --motion-slow: 220ms;
}

/* Typography — Bangla-first */
body {
  font-family: "Noto Sans Bengali", "Noto Sans", system-ui, sans-serif;
  background: var(--app-bg);
  color: var(--text-primary);
  margin: 0;
  padding: 0;
  -webkit-font-smoothing: antialiased;
  line-height: 1.5;
}

.app-meta { font-size: 12px; color: var(--text-secondary); line-height: 1.45; }
.app-label { font-size: 14px; color: var(--text-secondary); line-height: 1.5; }
.app-body { font-size: 16px; color: var(--text-primary); line-height: 1.55; }
.app-card-title { font-size: 18px; font-weight: 600; color: var(--text-primary); line-height: 1.4; }
.app-section-title { font-size: 20px; font-weight: 600; color: var(--text-primary); line-height: 1.35; }
@media (min-width: 480px) {
  .app-section-title { font-size: 22px; }
}

/* ========== APP LAYOUT ========== */
.app-viewport {
  min-height: 100vh;
  position: relative;
  padding-bottom: calc(var(--nav-height) + var(--nav-margin) * 2 + 56px + var(--safe-bottom));
}
.app-content {
  padding-left: var(--space-page);
  padding-right: var(--space-page);
}
@media (min-width: 480px) {
  .app-content { padding-left: var(--space-page-lg); padding-right: var(--space-page-lg); }
}

/* ========== APP HEADER ========== */
.app-header {
  height: var(--header-height);
  min-height: var(--header-height);
  background: var(--header-bg);
  border-bottom: var(--header-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--space-page);
  position: sticky;
  top: 0;
  z-index: 1000;
  transition: box-shadow var(--motion-normal) ease;
}
.app-header.scrolled { box-shadow: var(--shadow-header); }

.app-header-left,
.app-header-right {
  display: flex;
  align-items: center;
  min-width: 44px;
  min-height: 44px;
}
.app-header-left { justify-content: flex-start; }
.app-header-right { justify-content: flex-end; }

.app-header-btn {
  width: 44px;
  height: 44px;
  border: none;
  background: transparent;
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  text-decoration: none;
  transition: transform var(--motion-fast) ease, background var(--motion-fast) ease;
  -webkit-tap-highlight-color: transparent;
}
.app-header-btn:active { transform: scale(0.96); }
.app-header-btn:hover { background: var(--app-bg); }

.app-header-title {
  flex: 1;
  text-align: center;
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.app-header-title img { height: 28px; max-width: 140px; object-fit: contain; }

.notification-wrap { position: relative; }
.notification-badge {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 10px;
  height: 10px;
  background: #ef4444;
  border-radius: 50%;
  border: 2px solid var(--header-bg);
  animation: badge-pulse 2s ease-in-out infinite;
}
@keyframes badge-pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.85; transform: scale(1.1); }
}

/* ========== FLOATING BOTTOM NAV ========== */
.app-bottom-nav-wrap {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 0 var(--nav-margin) calc(var(--nav-margin) + var(--safe-bottom));
  z-index: 1000;
  pointer-events: none;
}
.app-bottom-nav {
  pointer-events: auto;
  height: var(--nav-height);
  max-width: 480px;
  margin: 0 auto;
  background: var(--app-surface);
  border-radius: var(--nav-radius);
  box-shadow: var(--nav-shadow);
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding: 0 8px;
}

.app-nav-item {
  position: relative;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 8px 4px;
  text-decoration: none;
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 500;
  border: none;
  background: none;
  cursor: pointer;
  transition: color var(--motion-fast) ease, transform var(--motion-fast) ease;
  -webkit-tap-highlight-color: transparent;
  min-height: 56px;
}
.app-nav-item i, .app-nav-item svg { font-size: 22px; }
.app-nav-item:active { transform: scale(0.96); }
.app-nav-item.active { color: var(--primary-500); }
.app-nav-item.active .app-nav-dot { opacity: 1; }
.app-nav-dot {
  position: absolute;
  top: 6px;
  left: 50%;
  transform: translateX(-50%);
  width: 4px;
  height: 4px;
  border-radius: 2px;
  background: var(--primary-500);
  opacity: 0;
  transition: opacity var(--motion-fast) ease;
}

.app-nav-center-wrap {
  position: relative;
  flex: 0 0 auto;
  margin-top: -28px;
}
.app-nav-center-btn {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--primary-500);
  color: #fff;
  border: 4px solid var(--app-bg);
  box-shadow: 0 4px 16px rgba(14, 183, 178, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  transition: transform var(--motion-fast) ease, box-shadow var(--motion-fast) ease;
  -webkit-tap-highlight-color: transparent;
  animation: nav-center-idle 3s ease-in-out infinite;
}
.app-nav-center-btn i, .app-nav-center-btn svg { font-size: 24px; }
.app-nav-center-btn:active { transform: scale(0.92); }
@keyframes nav-center-idle {
  0%, 100% { box-shadow: 0 4px 16px rgba(14, 183, 178, 0.4); }
  50% { box-shadow: 0 6px 20px rgba(14, 183, 178, 0.35); }
}

/* Footer copyright strip above nav */
/* Footer copyright: floating pill above bottom nav (matches nav style), centered */
.app-footer-strip {
  position: fixed;
  bottom: calc(var(--nav-height) + var(--nav-margin) * 2 + var(--safe-bottom));
  left: 50%;
  transform: translateX(-50%);
  width: calc(100% - var(--nav-margin) * 2);
  max-width: 480px;
  padding: 10px 16px;
  text-align: center;
  font-size: 11px;
  color: var(--text-secondary);
  line-height: 1.45;
  z-index: 999;
  background: var(--app-surface);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-soft);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  flex-wrap: wrap;
  box-sizing: border-box;
}
.app-footer-strip a {
  color: var(--primary-500);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.15s ease;
}
.app-footer-strip a:hover { color: var(--primary-600); }
.app-footer-strip .app-footer-sep {
  color: var(--border);
  font-weight: 300;
  user-select: none;
}

/* ========== HERO BANNER ========== */
.app-hero {
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  overflow: hidden;
  position: relative;
  margin: 0 calc(-1 * var(--space-page));
  margin-bottom: var(--space-section);
}
.app-hero img { width: 100%; height: 160px; object-fit: cover; display: block; }
.app-hero-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: var(--space-card);
  background: linear-gradient(to top, rgba(0,0,0,0.4), transparent);
}

/* ========== SEARCH FIELD ========== */
.app-search-wrap {
  position: sticky;
  top: var(--header-height);
  z-index: 100;
  background: var(--app-bg);
  padding: 12px 0;
  margin: 0 calc(-1 * var(--space-page));
  padding-left: var(--space-page);
  padding-right: var(--space-page);
}
.app-search-inner {
  display: flex;
  align-items: center;
  background: var(--app-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  gap: 10px;
}
.app-search-inner:focus-within { border-color: var(--primary-500); box-shadow: 0 0 0 3px var(--primary-50); }
.app-search-inner i { color: var(--text-secondary); font-size: 18px; flex-shrink: 0; }
.app-search-inner input {
  flex: 1;
  border: none;
  outline: none;
  font-size: 16px;
  color: var(--text-primary);
  background: transparent;
}
.app-search-inner input::placeholder { color: var(--text-secondary); }
.app-search-clear {
  width: 36px;
  height: 36px;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  border-radius: var(--radius-sm);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background var(--motion-fast), color var(--motion-fast);
}
.app-search-clear:active { transform: scale(0.96); }

/* ========== NOTICE STRIP ========== */
.app-notice-card {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--app-surface);
  border-radius: var(--radius-md);
  padding: 14px var(--space-card);
  margin-bottom: var(--space-section);
  box-shadow: var(--shadow-soft);
  border: 1px solid var(--border);
  text-decoration: none;
  color: var(--text-primary);
  transition: transform var(--motion-fast) ease, box-shadow var(--motion-fast) ease;
}
.app-notice-card:active { transform: scale(0.99); }
.app-notice-chip {
  flex-shrink: 0;
  background: var(--primary-500);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
}
.app-notice-text {
  flex: 1;
  font-size: 14px;
  color: var(--text-primary);
  line-height: 1.45;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Notice marquee: scrolling text */
.app-notice-marquee .app-notice-marquee-wrap {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  position: relative;
}
.app-notice-marquee .app-notice-marquee-wrap::after {
  content: '';
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 24px;
  background: linear-gradient(to left, var(--app-surface), transparent);
  pointer-events: none;
  z-index: 1;
}
.app-notice-marquee .app-notice-marquee-content {
  display: inline-block;
  white-space: nowrap;
  font-size: 14px;
  color: var(--text-primary);
  line-height: 1.45;
  padding-right: 40px;
  animation: app-notice-scroll 35s linear infinite;
}
.app-notice-marquee:hover .app-notice-marquee-content {
  animation-play-state: paused;
}
.app-notice-marquee .app-notice-sep {
  opacity: 0.6;
  margin: 0 6px;
}
.app-notice-marquee .app-notice-arrow {
  flex-shrink: 0;
  color: var(--text-secondary);
}
@keyframes app-notice-scroll {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* ========== CATEGORY CARD ========== */
.app-category-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-bottom: var(--space-section);
}
@media (min-width: 480px) {
  .app-category-grid { grid-template-columns: repeat(3, 1fr); }
}

.app-category-card {
  background: var(--app-surface);
  border-radius: var(--radius-md);
  padding: var(--space-card);
  text-align: center;
  text-decoration: none;
  color: var(--text-primary);
  box-shadow: var(--shadow-soft);
  border: 1px solid var(--border);
  transition: transform var(--motion-fast) ease, box-shadow var(--motion-fast) ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-height: 120px;
}
.app-category-card:active { transform: scale(0.96); }
.app-category-icon-wrap {
  width: 56px;
  height: 56px;
  border-radius: var(--radius-md);
  background: var(--primary-50);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 10px;
}
.app-category-icon-wrap img { width: 40px; height: 40px; object-fit: contain; }
.app-category-title {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
  line-height: 1.35;
  display: block;
}

/* Stagger reveal */
.app-stagger > * {
  opacity: 0;
  animation: stagger-in var(--motion-slow) ease forwards;
}
.app-stagger > *:nth-child(1) { animation-delay: 0ms; }
.app-stagger > *:nth-child(2) { animation-delay: 40ms; }
.app-stagger > *:nth-child(3) { animation-delay: 80ms; }
.app-stagger > *:nth-child(4) { animation-delay: 120ms; }
.app-stagger > *:nth-child(5) { animation-delay: 160ms; }
.app-stagger > *:nth-child(6) { animation-delay: 200ms; }
.app-stagger > *:nth-child(7) { animation-delay: 240ms; }
.app-stagger > *:nth-child(8) { animation-delay: 280ms; }
.app-stagger > *:nth-child(9) { animation-delay: 320ms; }
.app-stagger > *:nth-child(n+10) { animation-delay: 360ms; }
@keyframes stagger-in {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ========== SERVICE LIST CARD ========== */
.app-service-card {
  background: var(--app-surface);
  border-radius: var(--radius-md);
  padding: var(--space-card-lg);
  margin-bottom: 16px;
  box-shadow: var(--shadow-soft);
  border: 1px solid var(--border);
  transition: transform var(--motion-fast) ease, box-shadow var(--motion-fast) ease;
}
.app-service-card:active { transform: scale(0.99); }

.app-service-card-inner { display: flex; align-items: flex-start; gap: 16px; margin-bottom: 16px; }
.app-service-avatar {
  width: 70px;
  height: 70px;
  border-radius: var(--radius-md);
  object-fit: cover;
  background: var(--app-bg);
  flex-shrink: 0;
}
.app-service-details { flex: 1; min-width: 0; }
.app-service-name { font-size: 17px; font-weight: 600; color: var(--text-primary); margin: 0 0 4px 0; line-height: 1.35; }
.app-service-subtitle { font-size: 14px; color: var(--text-secondary); margin: 0 0 6px 0; line-height: 1.45; }
.app-service-meta { font-size: 14px; color: var(--text-primary); margin: 0; line-height: 1.5; }
.app-service-meta i { color: var(--text-secondary); margin-right: 6px; width: 18px; text-align: center; }
.app-service-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.app-btn-call {
  flex: 1;
  min-width: 120px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 16px;
  background: var(--primary-500);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition: transform var(--motion-fast) ease, background var(--motion-fast) ease;
}
.app-btn-call:active { transform: scale(0.98); }
.app-btn-call:hover { background: var(--primary-600); color: #fff; }
.app-btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 16px;
  background: transparent;
  color: var(--primary-500);
  border: 2px solid var(--primary-500);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition: transform var(--motion-fast) ease, background var(--motion-fast) ease, color var(--motion-fast) ease;
}
.app-btn-outline:active { transform: scale(0.98); }
.app-btn-outline:hover { background: var(--primary-500); color: #fff; }

/* ========== PAGE TOP (BACK + TITLE) ========== */
.app-page-top {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  margin-bottom: var(--space-section);
}
.app-back-btn {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  background: var(--app-bg);
  border: 1px solid var(--border);
  color: var(--text-primary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  flex-shrink: 0;
  transition: transform var(--motion-fast) ease, background var(--motion-fast) ease;
}
.app-back-btn:active { transform: scale(0.96); }
.app-page-title { font-size: 18px; font-weight: 600; color: var(--text-primary); margin: 0 0 2px 0; }
.app-breadcrumb { font-size: 12px; color: var(--text-secondary); }
.app-breadcrumb a { color: var(--text-secondary); text-decoration: none; }

/* ========== FLOATING ACTION BUTTON ========== */
.app-fab {
  position: fixed;
  bottom: calc(var(--nav-height) + var(--nav-margin) + 60px + var(--safe-bottom));
  right: var(--space-page);
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--primary-500);
  color: #fff;
  border: none;
  box-shadow: var(--shadow-soft);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  cursor: pointer;
  z-index: 1001;
  text-decoration: none;
  transition: transform var(--motion-fast) ease, box-shadow var(--motion-fast) ease;
  -webkit-tap-highlight-color: transparent;
}
.app-fab:active { transform: scale(0.92); }
.app-fab:hover { box-shadow: 0 12px 28px rgba(14, 183, 178, 0.25); }

/* Install / PWA FAB */
.app-fab-install {
  bottom: calc(var(--nav-height) + var(--nav-margin) + 60px + var(--safe-bottom));
  animation: fab-pulse 2s ease-in-out infinite;
}
@keyframes fab-pulse {
  0%, 100% { box-shadow: var(--shadow-soft); }
  50% { box-shadow: 0 10px 28px rgba(14, 183, 178, 0.2); }
}

/* ========== SECTION CONTAINER ========== */
.app-section { margin-bottom: var(--space-section); }
.app-section-title-wrap { margin-bottom: 16px; }

/* ========== UTILITIES ========== */
.app-tap-scale:active { transform: scale(0.96); }
.app-no-results {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-secondary);
}
.app-no-results i { font-size: 48px; color: var(--border); margin-bottom: 12px; display: block; }
.service-item.hidden { display: none !important; }

/* Filter pills (services page) */
.app-filter-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; justify-content: center; min-height: 40px; }
.app-filter-btn {
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--app-surface);
  color: var(--text-primary);
  font-size: 14px;
  cursor: pointer;
  transition: background var(--motion-fast), color var(--motion-fast), border-color var(--motion-fast);
}
.app-filter-btn.active { background: var(--primary-500); color: #fff; border-color: var(--primary-500); }

/* PC view: centered column */
@media (min-width: 769px) {
  .app-viewport {
    max-width: 428px;
    margin: 0 auto;
    box-shadow: 0 0 0 1px rgba(0,0,0,0.06);
    background: var(--app-bg);
  }
  .app-bottom-nav-wrap { left: 50%; right: auto; transform: translateX(-50%); width: 428px; max-width: 428px; padding-left: var(--nav-margin); padding-right: var(--nav-margin); }
  .app-footer-strip { width: calc(428px - var(--nav-margin) * 2); }
  .app-fab, .app-fab-install { right: calc(50% - 214px + var(--space-page)); }
  .add-service-fab { right: calc(50% - 214px + 20px) !important; }
}
