/* =====================================================
   NightHawk Elite — Resident App Styles (app.css)
   ===================================================== */

/* ---- Custom Properties ---- */
:root {
  --nh-red:             #d90000;
  --nh-red-dk:          #a80000;
  --nh-red-glow:        rgba(217, 0, 0, 0.22);
  --nh-bg:              #0a0a0a;
  --nh-surface:         #141414;
  --nh-surface-2:       #1d1d1d;
  --nh-surface-3:       #252525;
  --nh-border:          rgba(255, 255, 255, 0.07);
  --nh-border-md:       rgba(255, 255, 255, 0.12);
  --nh-border-lg:       rgba(255, 255, 255, 0.18);
  --nh-text:            #f0f0f0;
  --nh-text-sub:        rgba(240, 240, 240, 0.58);
  --nh-text-dim:        rgba(240, 240, 240, 0.32);
  --nh-green:           #00c337;
  --nh-day-inactive-bg: #2a2a2a;
  --nh-today-ring:      rgba(255, 255, 255, 0.85);
  --nh-amber:           #ffb300;
  --nh-radius:     14px;
  --nh-radius-sm:  10px;
  --nh-radius-lg:  20px;
  --nh-nav-h:      60px;
  --nh-bar-h:      68px;
  --nh-ease:       cubic-bezier(0.4, 0, 0.2, 1);
  --font:          'Poppins', sans-serif;
}

/* ---- Base ---- */
body {
  font-family: var(--font) !important;
  background: var(--nh-bg) !important;
  color: var(--nh-text);
  padding-bottom: 0 !important;
}
*, *::before, *::after { box-sizing: border-box; }
a { text-decoration: none; }
p { margin: 0; }

/* ---- Navbar ---- */
.navbar.fixed-top {
  background: rgba(8, 8, 8, 0.97) !important;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--nh-border-md);
  height: var(--nh-nav-h);
  min-height: var(--nh-nav-h);
}

/* =====================================================
   LOADING OVERLAY
   ===================================================== */
#app-loading {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 9999;
  align-items: center;
  justify-content: center;
}
#app-loading.show { display: flex; }

.loading-box {
  background: var(--nh-surface);
  border: 1px solid var(--nh-border-lg);
  border-radius: var(--nh-radius-lg);
  padding: 38px 50px;
  text-align: center;
}
.loading-box .spinner-border {
  width: 40px;
  height: 40px;
  border-width: 3px;
  color: var(--nh-red);
}
.loading-box .loading-text {
  font-size: 13.5px;
  color: var(--nh-text-sub);
  margin-top: 14px;
  font-family: var(--font);
}

/* =====================================================
   PROPERTY SELECTION SCREEN
   ===================================================== */
#select-property-form {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  background: var(--nh-bg) !important;
  padding: calc(var(--nh-nav-h) + 28px) 16px 48px;
  height: auto !important;
}

.ps-card {
  width: 100%;
  max-width: 460px;
  background: var(--nh-surface);
  border: 1px solid var(--nh-border-lg);
  border-radius: var(--nh-radius-lg);
  padding: 36px 32px 30px;
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.7);
}

.ps-logo {
  display: block;
  margin: 0 auto 24px;
  width: 140px;
}

.ps-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--nh-text);
  text-align: center;
  margin-bottom: 6px;
}

.ps-subtitle {
  font-size: 13px;
  color: var(--nh-text-sub);
  text-align: center;
  margin-bottom: 26px;
}

.ps-card .ps-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--nh-text-sub);
  display: block;
  margin-bottom: 7px;
}

.ps-card .form-check {
  margin-top: 16px;
  margin-bottom: 20px;
}

.ps-card .form-check-input {
  background-color: var(--nh-surface-3) !important;
  border-color: var(--nh-border-lg) !important;
  width: 16px;
  height: 16px;
  margin-top: 3px;
}

.ps-card .form-check-input:checked {
  background-color: var(--nh-red) !important;
  border-color: var(--nh-red) !important;
}

.ps-card .form-check-label {
  font-size: 12.5px;
  color: var(--nh-text-sub);
  padding-left: 4px;
}

.ps-card .form-check-label a {
  color: var(--nh-red);
  font-weight: 600;
}

.ps-card .form-check-label a:hover { text-decoration: underline; }

.btn-nh {
  display: block;
  width: 100%;
  background: var(--nh-red);
  color: #fff;
  border: none;
  border-radius: var(--nh-radius-sm);
  padding: 13px 20px;
  font-size: 15px;
  font-weight: 700;
  font-family: var(--font);
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: background 0.18s var(--nh-ease), transform 0.15s var(--nh-ease), box-shadow 0.18s var(--nh-ease);
}

.btn-nh:hover:not(:disabled) {
  background: var(--nh-red-dk);
  transform: translateY(-1px);
  box-shadow: 0 6px 22px var(--nh-red-glow);
}

.btn-nh:active:not(:disabled) { transform: translateY(0); }

.btn-nh:disabled {
  opacity: 0.42;
  cursor: not-allowed;
}

#property-select-form-error-div {
  display: none;
  margin-top: 12px;
  padding: 10px 14px;
  background: rgba(217, 0, 0, 0.1);
  border: 1px solid rgba(217, 0, 0, 0.3);
  border-radius: var(--nh-radius-sm);
}

#property-select-form-error-message {
  color: #ff7070 !important;
  font-size: 13px;
  margin: 0 !important;
  text-align: center;
}

/* =====================================================
   MAIN APP
   ===================================================== */
#main-resident-app {
  display: none;
  padding-bottom: calc(var(--nh-bar-h) + 16px);
  animation: appFadeIn 0.35s var(--nh-ease) both;
}

@keyframes appFadeIn {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ---- Property Header ---- */
.property-header {
  margin-top: var(--nh-nav-h);
  background: linear-gradient(118deg, #360000 0%, #b50000 60%, #ff2020 100%);
  padding: 11px 20px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.property-header::after {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    45deg, transparent, transparent 8px,
    rgba(255,255,255,0.018) 8px, rgba(255,255,255,0.018) 16px
  );
  pointer-events: none;
}

.ph-name {
  font-size: 13.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: #fff;
  line-height: 1.3;
}

.ph-address {
  font-size: 12px;
  color: rgba(255,255,255,0.72);
  margin-top: 2px;
}

/* ---- App Body ---- */
.app-body {
  max-width: 860px;
  margin: 0 auto;
  padding: 20px 14px;
}

@media (min-width: 768px) { .app-body { padding: 28px 24px; } }

.section-gap { margin-top: 24px; }

.section-label {
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--nh-text-dim);
  margin-bottom: 10px;
}

/* =====================================================
   STATUS CARD
   ===================================================== */
.status-card {
  background: var(--nh-surface);
  border: 1px solid var(--nh-border-md);
  border-radius: var(--nh-radius);
  padding: 18px 20px;
  transition: border-color 0.25s;
}

.status-card.state-active    { border-color: rgba(0, 195, 55, 0.38); }
.status-card.state-scheduled { border-color: rgba(255, 179, 0, 0.40); }
.status-card.state-inactive  { border-color: rgba(255, 64, 64, 0.35); }
/* Live crew run "Collection Complete" — fainter green than state-active:
   positive, but calm (nothing left for the resident to do). */
.status-card.state-complete  { border-color: rgba(0, 195, 55, 0.22); }

.sc-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
}

.sc-header i { font-size: 14px; color: var(--nh-text-dim); }

.sc-label {
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--nh-text-dim);
}

.sc-status-row {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 5px;
}

.status-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  flex-shrink: 0;
}

.dot-on {
  background: var(--nh-green);
  box-shadow: 0 0 0 3px rgba(0, 195, 55, 0.18);
  animation: dotPulse 2.2s ease-in-out infinite;
}

.dot-scheduled {
  background: #ffb300;
  box-shadow: 0 0 0 3px rgba(255, 179, 0, 0.18);
}

.dot-done { background: #9aa0a6; }

.dot-off { background: #ff4444; }

/* Live crew run "Collection Complete" — solid green, NO pulse (dot-on pulses
   while the crew is out; once done the dot goes still). */
.dot-complete {
  background: var(--nh-green);
  box-shadow: 0 0 0 3px rgba(0, 195, 55, 0.12);
}

@keyframes dotPulse {
  0%, 100% { box-shadow: 0 0 0 3px rgba(0, 195, 55, 0.18); }
  50%       { box-shadow: 0 0 0 6px rgba(0, 195, 55, 0.07); }
}

#status-message {
  font-size: 17px;
  font-weight: 700;
  color: var(--nh-text);
}

/* Theme-aware status colors (set as classes by applyStatusDisplay — inline
   colors failed contrast on the light theme). Light overrides further down. */
#status-message.status-running   { color: var(--nh-green); }
#status-message.status-scheduled { color: var(--nh-amber); }
#status-message.status-off       { color: #ff4444; }
#status-message.status-ended     { color: #9aa0a6; }

/* Live crew run (set by applyStatusDisplay from the property's liveRun field):
   "Crew On Site" reuses the running green; "Collection Complete" is a calmer
   green — positive without the "act now" urgency. Light overrides below. */
#status-message.status-liverun-active    { color: var(--nh-green); }
#status-message.status-liverun-completed { color: #58c47c; }

#status-message-1 {
  font-size: 13px;
  color: var(--nh-text-sub);
}

/* Countdown / next-pickup line ("Starts in 2h 15m", "Next pickup: Thursday
   at 7:00 PM"). Hidden by default; applyStatusDisplay shows it when it has
   something to say. */
#status-countdown {
  display: none;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--nh-text);
  margin-top: 6px;
}

/* =====================================================
   ANNOUNCEMENT BANNER (property notes)
   ===================================================== */
.notes-banner {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: var(--nh-surface);
  border: 1px solid rgba(255, 179, 0, 0.35);
  border-radius: var(--nh-radius);
  padding: 13px 16px 13px 19px;
  margin-bottom: 18px;
}

/* amber accent rail — same pattern as .rtp-card::before */
.notes-banner::before {
  content: "";
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: linear-gradient(#ffb300, #e08e00);
}

.nb-icon {
  flex-shrink: 0;
  margin-top: 2px;
  font-size: 15px;
  color: var(--nh-amber);
}

.nb-text {
  font-size: 13px;
  line-height: 1.55;
  color: var(--nh-text);
  overflow-wrap: anywhere;
}

/* =====================================================
   QUICK ACTION CARDS
   ===================================================== */
.qa-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

@media (min-width: 640px) { .qa-grid { grid-template-columns: repeat(4, 1fr); } }

.qa-card {
  display: block;
  background: var(--nh-surface);
  border: 1px solid var(--nh-border-md);
  border-radius: var(--nh-radius);
  padding: 16px 14px;
  cursor: pointer;
  text-decoration: none !important;
  transition: background 0.18s var(--nh-ease), border-color 0.18s var(--nh-ease),
              transform 0.18s var(--nh-ease), box-shadow 0.18s var(--nh-ease);
}

.qa-card:hover {
  background: var(--nh-surface-2);
  border-color: var(--nh-border-lg);
  transform: translateY(-2px);
  box-shadow: 0 8px 26px rgba(0, 0, 0, 0.5);
}

.qa-card:active { transform: translateY(0); }

.qa-card.qa-red {
  background: linear-gradient(140deg, #2b0000, #440000);
  border-color: rgba(217, 0, 0, 0.38);
}

.qa-card.qa-red:hover {
  background: linear-gradient(140deg, #3a0000, #580000);
  border-color: rgba(217, 0, 0, 0.65);
}

.qa-icon {
  font-size: 20px;
  margin-bottom: 10px;
  display: block;
}

.qa-card.qa-red .qa-icon    { color: #ff7a7a; }
.qa-card:not(.qa-red) .qa-icon { color: var(--nh-red); }

/* Red card always has a dark background — pin text to white in both themes */
.qa-card.qa-red .qa-title { color: rgba(255, 255, 255, 0.92); }
.qa-card.qa-red .qa-hint  { color: rgba(255, 255, 255, 0.50); }

.qa-title {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--nh-text);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 3px;
  line-height: 1.3;
}

.qa-hint {
  font-size: 11px;
  color: var(--nh-text-dim);
}

/* =====================================================
   WEEKLY SCHEDULE GRID
   ===================================================== */
.week-grid-note {
  font-size: 12px;
  color: var(--nh-text-dim);
  margin-bottom: 10px;
}

.week-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 5px;
}

.day-cell {
  position: relative;
  border-radius: 10px;
  padding: 10px 3px;
  text-align: center;
  /* background set by JS */
}

/* Today's cell — theme-aware ring (2px page-bg gap + 2px accent) plus a tiny
   "Today" pill so the marker doesn't rely on color alone. */
.day-cell.day-today {
  box-shadow: 0 0 0 2px var(--nh-bg), 0 0 0 4px var(--nh-today-ring);
}

.day-cell.day-today::after {
  content: "Today";
  position: absolute;
  left: 50%;
  bottom: -8px;
  transform: translateX(-50%);
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  line-height: 1;
  padding: 3px 6px;
  border-radius: 999px;
  background: #f0f0f0;
  color: #141414;
  white-space: nowrap;
  pointer-events: none;
}

.dc-name {
  font-size: 9.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 6px;
  background: none !important; /* override any inline bg from old code */
  line-height: 1;
}

.day-cell.day-inactive .dc-name { color: rgba(255,255,255,0.38); }

.dc-time {
  font-size: 10.5px;
  color: rgba(255, 255, 255, 0.88);
  line-height: 1.35;
  font-weight: 500;
}

.day-cell.day-inactive .dc-time { color: rgba(255,255,255,0.28); }

.dc-sep {
  font-size: 9px;
  color: rgba(255,255,255,0.38);
  line-height: 1;
  margin: 2px 0;
}

.day-cell.day-inactive .dc-sep { color: rgba(255,255,255,0.15); }

@media (max-width: 380px) {
  .day-cell { padding: 8px 1px; border-radius: 8px; }
  .dc-name  { font-size: 8.5px; }
  .dc-time  { font-size: 9.5px; }
}

/* =====================================================
   CONTACT CARDS
   ===================================================== */
.contact-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

@media (max-width: 460px) { .contact-row { grid-template-columns: 1fr; } }

.contact-card {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--nh-surface);
  border: 1px solid var(--nh-border-md);
  border-radius: var(--nh-radius);
  padding: 14px 16px;
  text-decoration: none !important;
  transition: background 0.18s, border-color 0.18s, transform 0.18s;
}

.contact-card:hover {
  background: var(--nh-surface-2);
  border-color: var(--nh-border-lg);
  transform: translateY(-1px);
}

.cc-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(217, 0, 0, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--nh-red);
  font-size: 15px;
  flex-shrink: 0;
}

.cc-label {
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--nh-text-dim);
  margin-bottom: 2px;
}

.cc-value {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--nh-text);
}

/* =====================================================
   REQUEST FORM
   ===================================================== */
.rf-card {
  background: var(--nh-surface);
  border: 1px solid var(--nh-border-md);
  border-radius: var(--nh-radius);
  padding: 24px;
}

@media (max-width: 480px) { .rf-card { padding: 16px; } }

.rf-heading {
  font-size: 19px;
  font-weight: 700;
  color: var(--nh-text);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 4px;
}

.rf-sub {
  font-size: 13px;
  color: var(--nh-text-sub);
  margin-bottom: 22px;
}

.app-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--nh-text-sub) !important;
  margin-bottom: 6px;
  display: block;
}

.app-input {
  display: block;
  width: 100%;
  background: var(--nh-surface-2) !important;
  border: 1px solid var(--nh-border-lg) !important;
  border-radius: var(--nh-radius-sm) !important;
  color: var(--nh-text) !important;
  padding: 11px 13px !important;
  font-size: 14px !important;
  font-family: var(--font) !important;
  transition: border-color 0.18s var(--nh-ease), box-shadow 0.18s var(--nh-ease);
}

.app-input::placeholder { color: var(--nh-text-dim) !important; }

.app-input:focus {
  border-color: var(--nh-red) !important;
  box-shadow: 0 0 0 3px var(--nh-red-glow) !important;
  outline: none !important;
  background: var(--nh-surface-3) !important;
}

.app-input[readonly] {
  opacity: 0.52;
  cursor: default;
}

.btn-rf {
  background: var(--nh-red);
  color: #fff;
  border: none;
  border-radius: var(--nh-radius-sm);
  padding: 13px 32px;
  font-size: 15px;
  font-weight: 700;
  font-family: var(--font);
  cursor: pointer;
  transition: background 0.18s, transform 0.18s, box-shadow 0.18s;
}

.btn-rf:hover {
  background: var(--nh-red-dk);
  transform: translateY(-1px);
  box-shadow: 0 6px 22px var(--nh-red-glow);
}

.btn-rf:active { transform: translateY(0); }

/* Inline error box (mirrors .rpm-error in the pickup modal) */
.rf-error {
  display: none;
  background: rgba(217, 0, 0, 0.12);
  border: 1px solid rgba(217, 0, 0, 0.35);
  color: #ff6b6b;
  font-size: 13px;
  border-radius: var(--nh-radius-sm);
  padding: 9px 12px;
  margin-bottom: 14px;
}
[data-theme="light"] .rf-error { color: #b00000; }

/* Small muted helper line under a field (contact requirement, etc.) */
.rf-field-hint {
  font-size: 12px;
  color: var(--nh-text-sub);
  line-height: 1.35;
  margin-top: 6px;
}

/* "Use the pickup button above" nudge — red accent, readable on both themes */
.rf-pickup-hint { color: var(--nh-red); font-weight: 600; }
[data-theme="light"] .rf-pickup-hint { color: #c40000; }

/* Live character counter under the description box */
.rf-char-count {
  font-size: 11.5px;
  color: var(--nh-text-dim);
  text-align: right;
  margin-top: 4px;
}

/* Success view (mirrors .rpm-success in the pickup modal) */
.rf-success      { text-align: center; padding: 26px 6px 10px; }
.rf-success-ic   { font-size: 46px; color: var(--nh-green); display: block; margin-bottom: 12px; }
.rf-success-msg  { font-size: 15px; font-weight: 600; color: var(--nh-text); margin: 0 0 6px; }
.rf-success-ref  { font-size: 12.5px; color: var(--nh-text-sub); margin: 0 0 18px; }
.rf-again-link {
  background: none;
  border: none;
  padding: 0;
  color: var(--nh-red);
  font-size: 13.5px;
  font-weight: 600;
  font-family: var(--font);
  text-decoration: underline;
  cursor: pointer;
}
[data-theme="light"] .rf-again-link { color: #c40000; }

/* =====================================================
   BOTTOM NAV BAR
   ===================================================== */
#app-footer-bar {
  display: none;
  position: fixed !important;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 1040;
  background: rgba(10, 10, 10, 0.97) !important;
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border-top: 1px solid var(--nh-border-lg) !important;
  height: var(--nh-bar-h) !important;
  padding: 0 !important;
}

.fnb-inner {
  display: flex;
  height: 100%;
  align-items: stretch;
}

.fnb-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  padding: 8px 4px;
  text-decoration: none !important;
  color: rgba(255, 255, 255, 0.36) !important;
  transition: color 0.18s, background 0.18s;
  cursor: pointer;
  border: none;
  background: transparent;
  font-family: var(--font);
  position: relative;
}

.fnb-item::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 20%;
  right: 20%;
  height: 2px;
  border-radius: 2px 2px 0 0;
  background: var(--nh-red);
  opacity: 0;
  transition: opacity 0.18s;
}

.fnb-item:hover,
.fnb-item:active {
  color: rgba(255, 255, 255, 0.82) !important;
  background: rgba(255, 255, 255, 0.04);
}

.fnb-item:hover::after { opacity: 1; }

.fnb-icon {
  font-size: 19px;
  transition: transform 0.18s;
}

.fnb-item:hover .fnb-icon { transform: translateY(-1px); }

.fnb-label {
  font-size: 9.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.fnb-support { color: rgba(255, 110, 110, 0.5) !important; }
.fnb-support:hover { color: #ff7a7a !important; }

/* =====================================================
   MODALS
   ===================================================== */
.modal-content {
  background: var(--nh-surface) !important;
  border: 1px solid var(--nh-border-lg) !important;
  border-radius: 20px !important;
  color: var(--nh-text) !important;
  overflow: hidden;
  box-shadow: 0 32px 90px rgba(0,0,0,0.8) !important;
}

.modal-header {
  background: linear-gradient(128deg, #1e0000 0%, #300000 100%) !important;
  border-bottom: 1px solid var(--nh-border-md) !important;
  padding: 18px 22px !important;
}

.modal-header-icon {
  font-size: 17px;
  color: var(--nh-red);
  margin-right: 9px;
}

.modal-title {
  font-size: 15.5px !important;
  font-weight: 700 !important;
  color: #fff !important;
  letter-spacing: 0.02em;
}

.btn-close {
  filter: invert(1) brightness(0.6) !important;
  opacity: 1 !important;
}

.modal-body {
  background: var(--nh-surface) !important;
  padding: 22px !important;
  overflow-y: auto;
  max-height: 72vh;
  scrollbar-width: thin;
  scrollbar-color: var(--nh-border-lg) transparent;
}

.modal-body::-webkit-scrollbar { width: 4px; }
.modal-body::-webkit-scrollbar-thumb { background: var(--nh-border-lg); border-radius: 4px; }

.modal-footer {
  background: rgba(0,0,0,0.22) !important;
  border-top: 1px solid var(--nh-border) !important;
  padding: 14px 22px !important;
}

.btn-modal-close {
  background: var(--nh-red) !important;
  color: #fff !important;
  border: none !important;
  border-radius: 8px !important;
  padding: 9px 22px !important;
  font-weight: 700 !important;
  font-size: 13.5px !important;
  font-family: var(--font) !important;
  cursor: pointer;
  transition: background 0.18s;
}

.btn-modal-close:hover { background: var(--nh-red-dk) !important; }

/* ---- Rule Cards ---- */
.rule-item {
  display: flex;
  gap: 13px;
  align-items: flex-start;
  background: var(--nh-surface-2);
  border: 1px solid var(--nh-border);
  border-radius: 12px;
  padding: 15px;
  margin-bottom: 9px;
}

.rule-num {
  min-width: 27px;
  height: 27px;
  border-radius: 50%;
  background: var(--nh-red);
  color: #fff;
  font-size: 11.5px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 1px;
}

.rule-title {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--nh-text);
  margin-bottom: 4px;
}

.rule-desc {
  font-size: 13px;
  color: var(--nh-text-sub);
  line-height: 1.55;
}

/* ---- Info box (why rules matter, weather, compactor) ---- */
.info-box {
  background: var(--nh-surface-2);
  border: 1px solid var(--nh-border);
  border-radius: 12px;
  padding: 18px;
  margin-top: 16px;
}

.info-box-heading {
  font-size: 14px;
  font-weight: 700;
  color: var(--nh-text);
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.info-box-heading i { color: var(--nh-red); font-size: 15px; }

.info-box p {
  font-size: 13px;
  color: var(--nh-text-sub);
  line-height: 1.6;
  margin-bottom: 8px;
}

.info-box p:last-child { margin-bottom: 0; }

.info-box ul {
  padding-left: 18px;
  margin-bottom: 8px;
}

.info-box li {
  font-size: 13px;
  color: var(--nh-text-sub);
  line-height: 1.6;
  margin-bottom: 3px;
}

/* ---- FAQ Accordion ---- */
.faq-item {
  background: var(--nh-surface-2);
  border: 1px solid var(--nh-border);
  border-radius: 12px;
  margin-bottom: 8px;
  overflow: hidden;
}

.faq-q {
  width: 100%;
  background: none;
  border: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 16px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--nh-text);
  cursor: pointer;
  font-family: var(--font);
  text-align: left;
  transition: background 0.15s;
}

.faq-q:hover { background: rgba(255,255,255,0.025); }

.faq-chevron {
  font-size: 11px;
  color: var(--nh-text-dim);
  transition: transform 0.22s var(--nh-ease);
  flex-shrink: 0;
  margin-left: 10px;
}

.faq-item.open .faq-chevron { transform: rotate(180deg); }

.faq-a {
  display: none;
  padding: 12px 16px 15px;
  font-size: 13px;
  color: var(--nh-text-sub);
  line-height: 1.62;
  border-top: 1px solid var(--nh-border);
}

.faq-item.open .faq-a { display: block; }

/* ---- Legal (ToS / Privacy) ---- */
.legal-heading {
  font-size: 19px;
  font-weight: 700;
  color: var(--nh-text);
  margin-bottom: 14px;
}

.legal-meta {
  font-size: 12px;
  color: var(--nh-text-dim);
  background: var(--nh-surface-2);
  border: 1px solid var(--nh-border);
  border-radius: 9px;
  padding: 10px 14px;
  margin-bottom: 20px;
  line-height: 1.65;
}

.legal-section {
  margin-bottom: 18px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--nh-border);
}

.legal-section:last-child {
  border-bottom: none;
  padding-bottom: 0;
  margin-bottom: 0;
}

.legal-section h3 {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--nh-text);
  margin-bottom: 8px;
}

.legal-section p {
  font-size: 13px;
  color: var(--nh-text-sub);
  line-height: 1.65;
  margin-bottom: 8px;
}

.legal-section p:last-child { margin-bottom: 0; }

.legal-section ul, .legal-section ol {
  padding-left: 18px;
  margin-top: 6px;
}

.legal-section li {
  font-size: 13px;
  color: var(--nh-text-sub);
  line-height: 1.6;
  margin-bottom: 4px;
}

.legal-contact-block {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--nh-surface-2);
  border: 1px solid var(--nh-border);
  border-radius: 10px;
  padding: 14px;
  margin-top: 10px;
}

.legal-contact-block img { width: 80px; opacity: 0.85; }

.legal-contact-block .lc-text {
  font-size: 13px;
  color: var(--nh-text-sub);
  line-height: 1.65;
}

/* =====================================================
   PICKUP SCHEDULE MODAL (redesigned)
   Sectioned body rendered by renderScheduleIntoModal:
   tonight hero → week list → tips → notes → holiday →
   CTAs. Theme-variable colors only; light overrides in
   the LIGHT THEME section below. Mobile-first: rows are
   44px+ tall and nothing scrolls horizontally.
   ===================================================== */
.sm-block { margin-top: 18px; }

/* --- 1. Tonight hero --- */
.sm-hero {
  background: var(--nh-surface-2);
  border: 1px solid var(--nh-border-md);
  border-radius: var(--nh-radius);
  padding: 15px 16px;
}
.sm-hero:empty { display: none; }

.sm-hero-row { display: flex; align-items: flex-start; gap: 10px; }

.sm-hero-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 5px;
  background: var(--nh-text-dim);
}

.sm-hero-title {
  font-size: 14.5px;
  font-weight: 700;
  color: var(--nh-text);
  line-height: 1.45;
}

.sm-hero-sub {
  margin: 7px 0 0 20px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--nh-text-sub);
}
.sm-hero-sub strong { color: var(--nh-text); }

.sm-hero-override {
  margin: 8px 0 0 20px;
  font-size: 12.5px;
  color: var(--nh-amber);
  line-height: 1.5;
}
.sm-hero-override i { font-size: 11px; margin-right: 4px; }

/* State accents — same palette + pulse as the status card */
.sm-hero--active,
.sm-hero--running { border-color: rgba(0, 195, 55, 0.38); }
.sm-hero--active .sm-hero-dot,
.sm-hero--running .sm-hero-dot {
  background: var(--nh-green);
  box-shadow: 0 0 0 3px rgba(0, 195, 55, 0.18);
  animation: dotPulse 2.2s ease-in-out infinite;
}
.sm-hero--complete { border-color: rgba(0, 195, 55, 0.22); }
.sm-hero--complete .sm-hero-dot {
  background: var(--nh-green);
  box-shadow: 0 0 0 3px rgba(0, 195, 55, 0.12);
}
.sm-hero--scheduled { border-color: rgba(255, 179, 0, 0.40); }
.sm-hero--scheduled .sm-hero-dot {
  background: var(--nh-amber);
  box-shadow: 0 0 0 3px rgba(255, 179, 0, 0.18);
}

/* --- 2. Week at a glance --- */
.sm-week-summary {
  font-size: 12.5px;
  color: var(--nh-text-sub);
  margin-bottom: 10px;
}
.sm-week-summary strong { color: var(--nh-text); }

.sm-week-list { display: flex; flex-direction: column; gap: 6px; }

.sm-day-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 46px;
  padding: 11px 14px;
  background: var(--nh-surface-2);
  border: 1px solid var(--nh-border);
  border-radius: var(--nh-radius-sm);
}

/* Today — same ring treatment as the week grid's .day-today */
.sm-day-row.is-today {
  box-shadow: 0 0 0 2px var(--nh-surface), 0 0 0 4px var(--nh-today-ring);
  border-color: transparent;
}

.sm-day-name {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 13.5px;
  font-weight: 700;
  color: var(--nh-text);
  flex-shrink: 0;
}

.sm-day-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  flex-shrink: 0;
  background: var(--nh-red);
}
.sm-day-row.is-off .sm-day-dot { background: var(--nh-day-inactive-bg); }

.sm-day-time {
  font-size: 12.5px;
  color: var(--nh-text-sub);
  text-align: right;
  line-height: 1.4;
  min-width: 0;
}
.sm-day-time strong { color: var(--nh-text); font-weight: 700; }

.sm-day-row.is-off .sm-day-name { color: var(--nh-text-dim); }
.sm-day-row.is-off .sm-day-time { color: var(--nh-text-dim); }

/* mirrors .day-cell.day-today::after (light override below) */
.sm-today-pill {
  font-size: 8px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  line-height: 1;
  padding: 3px 6px;
  border-radius: 999px;
  background: #f0f0f0;
  color: #141414;
}

.sm-week-note {
  font-size: 11.5px;
  color: var(--nh-text-dim);
  margin-top: 8px;
}

/* --- 3. Good-to-know checklist --- */
.sm-tips-card {
  background: var(--nh-surface-2);
  border: 1px solid var(--nh-border);
  border-radius: 12px;
  padding: 16px;
}

.sm-tips-heading {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13.5px;
  font-weight: 700;
  color: var(--nh-text);
  margin-bottom: 10px;
}
.sm-tips-heading i { color: var(--nh-red); font-size: 13px; }

.sm-tips-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.sm-tips-list li {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  font-size: 13px;
  color: var(--nh-text-sub);
  line-height: 1.5;
}
.sm-tips-list li i {
  color: var(--nh-green);
  font-size: 11px;
  margin-top: 4px;
  flex-shrink: 0;
}

.sm-tips-more {
  margin: 12px 0 0;
  padding-top: 11px;
  border-top: 1px solid var(--nh-border);
}

.sm-rules-link {
  font-size: 13px;
  font-weight: 600;
  color: var(--nh-red) !important;
}
.sm-rules-link i { font-size: 10px; margin-left: 3px; }
.sm-rules-link:hover { text-decoration: underline !important; }

/* --- 4. Property notes — reuses .notes-banner; drop its page margin here */
.schedule-modal .notes-banner { margin-bottom: 0; }

/* --- 5. Holiday note --- */
.sm-holiday {
  font-size: 12.5px;
  color: var(--nh-text-dim);
  line-height: 1.5;
}

/* --- 6. Smart CTAs --- */
.sm-ctas { display: flex; flex-direction: column; gap: 10px; }

.sm-cta-missed {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  width: 100%;
  min-height: 48px;
  background: var(--nh-red);
  color: #fff;
  border: none;
  border-radius: var(--nh-radius-sm);
  padding: 13px 16px;
  font-family: var(--font);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.18s, transform 0.18s;
}
.sm-cta-missed:hover  { background: var(--nh-red-dk); }
.sm-cta-missed:active { transform: translateY(1px); }

.sm-push-hint {
  font-size: 12.5px;
  color: var(--nh-text-sub);
  line-height: 1.5;
  text-align: center;
}

/* =====================================================
   UTILITY
   ===================================================== */
.hidden { display: none !important; }

/* =====================================================
   THEME TOGGLE BUTTON
   ===================================================== */
.theme-toggle-btn {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  border: 1px solid var(--nh-border-md);
  background: transparent;
  color: var(--nh-text-sub);
  font-size: 13px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.18s var(--nh-ease), border-color 0.18s var(--nh-ease), color 0.18s var(--nh-ease);
  flex-shrink: 0;
}

.theme-toggle-btn:hover {
  background: var(--nh-surface-2);
  border-color: var(--nh-border-lg);
  color: var(--nh-text);
}

/* Lightbulb — lit state (light theme) */
.bulb-lit { color: #ffd60a !important; }

/* =====================================================
   SETTINGS GEAR DROPDOWN
   ===================================================== */
.nh-settings-wrap { position: relative; }

.nh-settings-dropdown {
  display: none;
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  background: var(--nh-surface);
  border: 1px solid var(--nh-border-lg);
  border-radius: var(--nh-radius);
  padding: 6px;
  min-width: 192px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.38);
  z-index: 1200;
  animation: sdIn 0.15s var(--nh-ease) both;
}
.nh-settings-dropdown.open { display: block; }

@keyframes sdIn {
  from { opacity: 0; transform: translateY(-6px) scale(0.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.nh-sd-section {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--nh-text-dim);
  padding: 4px 10px 6px;
  margin: 0;
  user-select: none;
}

.nh-sd-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  background: none;
  border: none;
  border-radius: 8px;
  padding: 9px 12px;
  color: var(--nh-text);
  font-size: 13px;
  font-family: var(--font);
  cursor: pointer;
  text-align: left;
  transition: background 0.15s;
}
.nh-sd-item:hover { background: var(--nh-surface-2); }

/* ---- Pickup night reminders row (R4) ---- */
/* Two-line label + a small switch pill; theme colors come from the same
   custom properties as the rest of the dropdown, so both themes just work. */
.nh-push-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
  min-width: 0;
}

.nh-push-title {
  font-size: 13px;
  color: var(--nh-text);
}

.nh-push-sub {
  font-size: 11px;
  line-height: 1.35;
  color: var(--nh-text-dim);
}

.nh-push-switch {
  position: relative;
  width: 30px;
  height: 18px;
  border-radius: 999px;
  background: var(--nh-surface-3);
  border: 1px solid var(--nh-border-lg);
  flex-shrink: 0;
  transition: background 0.18s var(--nh-ease), border-color 0.18s var(--nh-ease);
}

.nh-push-switch::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--nh-text-sub);
  transition: transform 0.18s var(--nh-ease), background 0.18s var(--nh-ease);
}

.nh-push-switch.on {
  background: var(--nh-red);
  border-color: var(--nh-red);
}

.nh-push-switch.on::after {
  transform: translateX(12px);
  background: #fff;
}

.nh-push-switch.busy { opacity: 0.55; }

/* Transient status line under the row ("Reminders are off.", permission
   copy, …) — quiet, auto-hidden by resident-app.js after a few seconds. */
.nh-push-msg {
  font-size: 11px;
  line-height: 1.4;
  color: var(--nh-text-sub);
  padding: 2px 12px 6px;
  margin: 0;
}

[data-theme="light"] .nh-settings-dropdown {
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
}

/* =====================================================
   LIGHT THEME OVERRIDES
   ===================================================== */
[data-theme="light"] {
  --nh-bg:              #f2f2f4;
  --nh-surface:         #ffffff;
  --nh-surface-2:       #f0f0f2;
  --nh-surface-3:       #e6e6e9;
  --nh-border:          rgba(0, 0, 0, 0.06);
  --nh-border-md:       rgba(0, 0, 0, 0.11);
  --nh-border-lg:       rgba(0, 0, 0, 0.18);
  --nh-text:            #18181b;
  --nh-text-sub:        rgba(24, 24, 27, 0.62);
  --nh-text-dim:        rgba(24, 24, 27, 0.36);
  --nh-day-inactive-bg: #dddde0;
  --nh-today-ring:      rgba(24, 24, 27, 0.78);
}

/* Status message colors — darker variants that pass contrast on white */
[data-theme="light"] #status-message.status-running   { color: #00802a; }
[data-theme="light"] #status-message.status-scheduled { color: #8a5f00; }
[data-theme="light"] #status-message.status-off       { color: #c40000; }
[data-theme="light"] #status-message.status-ended     { color: #5f6368; }

/* Live crew run — darker greens that pass contrast on the white card */
[data-theme="light"] #status-message.status-liverun-active    { color: #00802a; }
[data-theme="light"] #status-message.status-liverun-completed { color: #1e7d43; }

/* Announcement banner — cream surface + darker amber accents on light */
[data-theme="light"] .notes-banner {
  background: #fffaf0;
  border-color: rgba(176, 122, 0, 0.38);
}
[data-theme="light"] .notes-banner::before { background: linear-gradient(#b07a00, #8a5f00); }
[data-theme="light"] .nb-icon { color: #8a5f00; }

/* "Today" pill — invert for the light background */
[data-theme="light"] .day-cell.day-today::after {
  background: #26262b;
  color: #ffffff;
}

/* Navbar */
[data-theme="light"] .navbar.fixed-top {
  background: rgba(255, 255, 255, 0.97) !important;
  border-bottom-color: rgba(0, 0, 0, 0.1);
}

/* Property select card — logo area */
[data-theme="light"] .ps-logo {
  background: var(--nh-surface-2);
  border-radius: 8px;
  padding: 6px 10px;
}

/* Modal body & footer (header stays dark red — brand identity) */
[data-theme="light"] .modal-content  { background: #ffffff !important; border-color: rgba(0,0,0,0.14) !important; }
[data-theme="light"] .modal-body     { background: #ffffff !important; }
[data-theme="light"] .modal-footer   { background: rgba(242, 242, 244, 0.85) !important; border-top-color: rgba(0,0,0,0.08) !important; }

/* btn-close — modal header is always dark, so keep it white in both themes */
/* (no override needed — the filter:invert rule already handles it globally) */

/* Loading box */
[data-theme="light"] .loading-box {
  background: #ffffff;
  border-color: rgba(0, 0, 0, 0.15);
}

/* Bottom nav */
[data-theme="light"] #app-footer-bar {
  background: rgba(255, 255, 255, 0.97) !important;
  border-top-color: rgba(0, 0, 0, 0.12) !important;
}

[data-theme="light"] .fnb-item           { color: rgba(0, 0, 0, 0.38) !important; }
[data-theme="light"] .fnb-item:hover     { color: rgba(0, 0, 0, 0.82) !important; background: rgba(0,0,0,0.04); }
[data-theme="light"] .fnb-item::after    { background: var(--nh-red); }
[data-theme="light"] .fnb-support        { color: rgba(170, 0, 0, 0.55) !important; }
[data-theme="light"] .fnb-support:hover  { color: var(--nh-red) !important; }

/* Day tiles — inactive text needs to be dark on the light gray bg */
[data-theme="light"] .day-cell.day-inactive .dc-name { color: rgba(0, 0, 0, 0.42); }
[data-theme="light"] .day-cell.day-inactive .dc-time { color: rgba(0, 0, 0, 0.28); }
[data-theme="light"] .day-cell.day-inactive .dc-sep  { color: rgba(0, 0, 0, 0.16); }

/* Pickup Schedule modal — darker accents that pass contrast on white */
[data-theme="light"] .sm-hero--scheduled .sm-hero-dot {
  background: #b07a00;
  box-shadow: 0 0 0 3px rgba(176, 122, 0, 0.16);
}
[data-theme="light"] .sm-hero-override { color: #8a5f00; }
[data-theme="light"] .sm-tips-list li i { color: #00802a; }
[data-theme="light"] .sm-rules-link { color: #c40000 !important; }
[data-theme="light"] .sm-today-pill {
  background: #26262b;
  color: #ffffff;
}

/* =====================================================
   Request Trash Pickup — card + modal
   ===================================================== */
.rtp-card {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  margin: 14px 0 0;
  padding: 15px 16px 15px 18px;
  text-align: left;
  position: relative;
  overflow: hidden;
  background: var(--nh-surface);
  border: 1px solid var(--nh-border-md);
  border-radius: var(--nh-radius);
  color: var(--nh-text);
  cursor: pointer;
  transition: transform 0.18s var(--nh-ease), border-color 0.18s var(--nh-ease), box-shadow 0.18s var(--nh-ease);
}
/* slim red accent rail */
.rtp-card::before {
  content: "";
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: linear-gradient(var(--nh-red), var(--nh-red-dk));
}
.rtp-card:hover  { transform: translateY(-2px); border-color: var(--nh-border-lg); box-shadow: 0 8px 24px rgba(0,0,0,0.42); }
.rtp-card:active { transform: translateY(0); }
.rtp-card.hidden { display: none !important; }
.rtp-ic {
  flex: 0 0 auto;
  width: 46px; height: 46px;
  display: grid; place-items: center;
  font-size: 19px;
  color: #fff;
  border-radius: 13px;
  background: linear-gradient(135deg, var(--nh-red), var(--nh-red-dk));
  box-shadow: 0 4px 14px var(--nh-red-glow);
}
.rtp-text  { display: flex; flex-direction: column; gap: 3px; flex: 1 1 auto; min-width: 0; }
.rtp-title { font-weight: 700; font-size: 15px; letter-spacing: 0.01em; line-height: 1.15; }
.rtp-sub   { font-size: 12.5px; color: var(--nh-text-sub); line-height: 1.3; }
.rtp-arrow { flex: 0 0 auto; color: var(--nh-text-dim); font-size: 13px; transition: transform 0.18s var(--nh-ease), color 0.18s var(--nh-ease); }
.rtp-card:hover .rtp-arrow { transform: translateX(3px); color: var(--nh-red); }

/* Disabled — outside today's service window */
.rtp-card.is-disabled {
  cursor: not-allowed;
  opacity: 0.6;
  box-shadow: none;
  transform: none;
  border-color: var(--nh-border);
}
.rtp-card.is-disabled::before     { background: var(--nh-text-dim); }
.rtp-card.is-disabled .rtp-ic     { background: var(--nh-day-inactive-bg); color: var(--nh-text-sub); box-shadow: none; }
.rtp-card.is-disabled:hover       { transform: none; box-shadow: none; border-color: var(--nh-border); }
.rtp-card.is-disabled:hover .rtp-arrow { transform: none; color: var(--nh-text-dim); }

/* Modal specifics (inherits the app's shared .modal-* styling) */
.rpm-title-ic { color: var(--nh-red); margin-right: 6px; }
.rpm-sub      { font-size: 13.5px; color: var(--nh-text-sub); margin: 0 0 14px; }
.rpm-field    { margin-bottom: 14px; }
.rpm-req      { color: var(--nh-red); }
.rpm-optional { color: var(--nh-text-dim); font-weight: 400; }
.rpm-error {
  display: none;
  background: rgba(217,0,0,0.12);
  border: 1px solid rgba(217,0,0,0.35);
  color: #ff6b6b;
  font-size: 13px;
  border-radius: var(--nh-radius-sm);
  padding: 9px 12px;
  margin-bottom: 12px;
}
.rpm-success      { text-align: center; padding: 18px 6px 8px; }
.rpm-success-ic   { font-size: 46px; color: var(--nh-green); display: block; margin-bottom: 12px; }
.rpm-success-msg  { font-size: 15px; font-weight: 600; color: var(--nh-text); margin: 0; }
.rpm-done-btn     { background: var(--nh-surface-2, #1e1e1e); }
[data-theme="light"] .rpm-error { color: #b00000; }

/* =====================================================
   Post-submit request tracking strip (R3)
   ===================================================== */
/* Slim status line under the request card: "Pickup requested at 8:14 PM ·
   Open" → "· Completed ✓". Surface variables flip it for the light theme. */
.req-track-strip {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-top: 10px;
  padding: 9px 13px;
  background: var(--nh-surface);
  border: 1px solid var(--nh-border-md);
  border-radius: var(--nh-radius-sm);
  font-size: 12.5px;
  color: var(--nh-text-sub);
}

.rts-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
  background: var(--nh-amber);
  box-shadow: 0 0 0 3px rgba(255, 179, 0, 0.16);
}

.req-track-strip.is-completed { color: var(--nh-text); }

.req-track-strip.is-completed .rts-dot {
  background: var(--nh-green);
  box-shadow: 0 0 0 3px rgba(0, 195, 55, 0.16);
}

/* =====================================================
   PWA install banner (R5)
   ===================================================== */
.install-banner {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--nh-surface);
  border: 1px solid var(--nh-border-md);
  border-radius: var(--nh-radius);
  padding: 12px 14px 12px 17px;
  margin-bottom: 18px;
}

/* red accent rail — same pattern as .rtp-card::before */
.install-banner::before {
  content: "";
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: linear-gradient(var(--nh-red), var(--nh-red-dk));
}

.ib-icon {
  flex-shrink: 0;
  font-size: 17px;
  color: var(--nh-red);
}

.ib-text {
  flex: 1 1 auto;
  font-size: 12.5px;
  line-height: 1.45;
  color: var(--nh-text-sub);
}

.ib-install {
  flex-shrink: 0;
  background: var(--nh-red);
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 8px 16px;
  font-size: 12.5px;
  font-weight: 700;
  font-family: var(--font);
  cursor: pointer;
  transition: background 0.18s;
}

.ib-install:hover { background: var(--nh-red-dk); }

.ib-dismiss {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  border-radius: 7px;
  color: var(--nh-text-dim);
  font-size: 13px;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.ib-dismiss:hover { background: var(--nh-surface-2); color: var(--nh-text); }

/* =====================================================
   Searchable property picker (R11)
   ===================================================== */
.ps-combobox { position: relative; }

.ps-combo-list {
  list-style: none;
  margin: 6px 0 0;
  padding: 6px;
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  z-index: 1100;
  background: var(--nh-surface);
  border: 1px solid var(--nh-border-lg);
  border-radius: var(--nh-radius-sm);
  max-height: 262px;
  overflow-y: auto;
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.5);
  scrollbar-width: thin;
  scrollbar-color: var(--nh-border-lg) transparent;
}

[data-theme="light"] .ps-combo-list { box-shadow: 0 18px 44px rgba(0, 0, 0, 0.14); }

.ps-combo-option {
  padding: 9px 11px;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.ps-combo-option:hover,
.ps-combo-option.active { background: var(--nh-surface-2); }

/* keyboard highlight gets a red rail so it reads even where hover also shows */
.ps-combo-option.active { box-shadow: inset 2px 0 0 var(--nh-red); }

.pso-name {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--nh-text);
  line-height: 1.3;
}

.pso-loc {
  font-size: 11.5px;
  color: var(--nh-text-dim);
  line-height: 1.3;
}

.ps-combo-empty {
  padding: 10px 11px;
  font-size: 12.5px;
  color: var(--nh-text-dim);
}

.ps-retry-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-top: 10px;
  background: var(--nh-surface-2);
  color: var(--nh-text);
  border: 1px solid var(--nh-border-lg);
  border-radius: var(--nh-radius-sm);
  padding: 8px 16px;
  font-size: 13px;
  font-weight: 600;
  font-family: var(--font);
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}

.ps-retry-btn:hover { background: var(--nh-surface-3); }
