/* HitchPoint Dashboard Styles */

.rhd-dashboard-root {
  font-family: system-ui, sans-serif;
  color: #333;
}

.rhd-dashboard-root h2 {
  font-size: 1.875rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: #1f2937; /* text-gray-800 */
}

#rhd-update-success {
  padding: 0.5rem 1rem;
  border: 1px solid #16a34a;
  background-color: #dcfce7;
  border-radius: 4px;
}

#rhdSearchInput {
  border: 1px solid #d1d5db;
  border-radius: 6px;
  padding: 0.5rem 1rem;
  width: 100%;
  max-width: 24rem;
  margin-bottom: 2rem;
}

#rhdDashboardTable {
  border-collapse: collapse;
  width: 100%;
  font-size: 0.875rem;
  background-color: #ffffff;
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
  font-family: DM Sans;
}

#rhdDashboardTable th,
#rhdDashboardTable td {
  padding: 0.75rem;
  border-bottom: 1px solid #e5e7eb;
}

#rhdDashboardTable thead {
  background-color: #f3f4f6;
  font-weight: 600;
  color: #374151;
}

#rhdDashboardTable tr:hover {
  background-color: #e2eaf1; 
}

#rhdDashboardTable a {
  text-decoration: underline;
  filter: brightness(0) saturate(100%) invert(58%) sepia(86%) saturate(1927%) hue-rotate(111deg) brightness(101%) contrast(101%);
  transition: color 0.2s ease;
  padding: 0.25rem .25rem;
}

#rhdDashboardTable a:hover {
  filter: brightness(0) saturate(100%) invert(58%) sepia(86%) saturate(1927%) hue-rotate(111deg) brightness(101%) contrast(101%);
}

#rhdDashboardTable input[type="text"],
#rhdDashboardTable textarea {
  border: 1px solid #d1d5db;
  border-radius: 4px;
  padding: 0.5rem;
  width: 100%;
  font-size: 0.875rem;
}

#rhdDashboardTable label {
  display: block;
  margin-bottom: 0.75rem;
  font-size: 0.875rem;
  color: #374151;
}

#rhdDashboardTable textarea {
  min-height: 80px;
}

#rhdDashboardTable button {
  background: transparent !important;
  color: #00325B;
  padding: 0.25rem .25rem;
  border-radius: 4px;
  border: none;
  font-weight: 600;
  font-size: .8rem;
  /*margin-top: .25rem;*/
  cursor: pointer;
  transition: background-color 0.2s ease;
}

#rhdDashboardTable button:hover {
  background: transparent !important;
}

.bg-yellow-50 {
  background-color: #f9fafb;
}

.bg-gray-50 {
  background-color: #f9fafb;
}

.hidden {
  display: none;
}

.rhd-dashboard-cards-container {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.rhd-request-card {
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 1rem;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.rhd-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.rhd-card-name {
  font-size: 1.2rem;
  font-weight: bold;
  margin: 0;
}

.rhd-card-phone {
  font-size: 0.9rem;
  color: #555;
}

.rhd-card-body p {
  margin: 0.25rem 0;
}

/*.rhd-card-actions {
  display: flex;
  justify-content: flex-start;
  gap: 0.75rem;
  margin-top: 0.75rem;
}*/

.rhd-icon-button {
  background: #f5f5f5;
  border: none;
  padding: 0.5rem 0.75rem;
  border-radius: 4px;
  cursor: pointer;
  font-size: 0.9rem;
}

.rhd-icon-button:hover {
  background: #e0e0e0;
}

.rhd-hamburger {
  position: fixed;
  top: 1rem;
  left: 1rem;
  font-size: 2rem;
  font-weight: bold;
  color: #333;
  cursor: pointer;
  z-index: 1001;
}

.rhd-offcanvas {
  position: fixed;
  top: 0;
  left: -260px;
  width: 250px;
  height: 100%;
  background: #111;
  color: white;
  padding: 2rem 1rem;
  transition: left 0.3s ease-in-out;
  z-index: 1000;
  box-shadow: 4px 0 12px rgba(0,0,0,0.2);
}

.rhd-offcanvas.open {
  left: 0;
}

.rhd-offcanvas-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.rhd-offcanvas-list li {
  margin-bottom: 1.5rem;
}

.rhd-offcanvas-list a {
  color: white;
  text-decoration: none;
  font-size: 1.2rem;
}

.rhd-offcanvas-list a:hover {
  text-decoration: underline;
}

.rhd-close-btn {
  position: absolute;
  top: 1rem;
  right: 1rem;
  font-size: 2rem;
  font-weight: bold;
  cursor: pointer;
}


/* === List View Container === */
#rhd-delivery-list-view {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1rem 0;
}

/* === Single List Item === */
.rhd-list-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #fff;
  /*border: 1px solid #ddd;
  padding: 0.75rem 1rem;
  border-radius: 8px;
  box-shadow: 0 1px 2px rgba(0,0,0,0.05);*/
  transition: background 0.2s;
}
.rhd-list-item:hover {
  background: #f9f9f9;
}

/* === Left: Trash Icon === */
.rhd-list-item-left {
  display: flex;
  align-items: center;
  margin-right: 0.75rem;
}
.rhd-icon-btn {
  background: transparent;
  border: none;
  padding: 0.25rem;
  cursor: pointer;
}
.rhd-icon-btn img {
  width: 20px;
  height: 20px;
}

/* === Middle: Name + Meta === */
.rhd-list-item-content {
  flex: 1;
  display: flex;
  flex-direction: column;
}
.rhd-list-title {
  font-weight: 600;
  color: #00325B;
  font-size: 1rem;
  margin-bottom: 0.25rem;
}
.rhd-list-subtitle {
  font-size: 0.875rem;
  color: #444;
}
.rhd-list-submeta {
  font-size: 0.75rem;
  color: #777;
}

/* === Right: Archive + Toggle === */
.rhd-list-item-right {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* === Toggle Switch === */
.rhd-toggle-switch {
  position: relative;
  display: inline-block;
  width: 38px;
  height: 20px;
}
.rhd-toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}
.rhd-slider {
  position: absolute;
  top: 0; left: 0;
  right: 0; bottom: 0;
  background-color: #ccc;
  border-radius: 20px;
  transition: 0.3s;
}
.rhd-slider:before {
  content: "";
  position: absolute;
  height: 14px; width: 14px;
  left: 3px;
  top: 3px;
  background-color: white;
  border-radius: 50%;
  transition: 0.3s;
}
.rhd-toggle-switch input:checked + .rhd-slider {
  background-color: #4dff00;
}
.rhd-toggle-switch input:checked + .rhd-slider:before {
  transform: translateX(18px);
}

.rhd-card-actions {
  display: flex;
  gap: 0.5rem;
  padding-top: 0.5rem;
  justify-content: start;
}

.rhd-icon-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.3rem;
  cursor: pointer;
  transition: opacity 0.2s ease;
}

.rhd-icon-action img {
  width: 20px;
  height: 20px;
}

.rhd-icon-action:hover {
  opacity: 0.7;
}

.rhd-filter-dropdown {
  position: absolute;
  top: 100%;
  right: 0;
  background: #fff;
  border: 1px solid #ccc;
  padding: 0.5rem;
  z-index: 999;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}
.rhd-filter-option {
  display: inline-flex; /* Was 'flex' before, now inline-flex to keep natural flow */
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  font-size: 0.95rem;
  cursor: pointer;
  border-radius: 0.3rem;
  transition: background-color 0.2s ease;
  white-space: nowrap; /* Optional: prevents wrapping if text is short */
}

.rhd-filter-option:hover {
  background: #f0f0f0;
}

.rhd-filter-wrapper {
  position: relative;
  display: inline-block;
}

.rhd-filter-modal {
  position: absolute;
  top: 120%;
  right: -105%;
  z-index: 999;
  background: #fff;
  border: 1px solid #ccc;
  border-radius: 6px;
  padding: 10px 10px 10px 10px;
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
  display: flex;
  flex-direction: column;
  gap: 0px;
  min-width: 160px;
}

.rhd-filter-modal button {
  background: none;
  border: none;
  text-align: left;
  padding: 6px 10px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 14px;
  transition: background 0.2s ease;
}

.rhd-filter-modal button:hover {
  background-color: #f0f0f0;
}

.hidden {
  display: none !important;
}

.rhd-controls-icons-layout {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 1rem 0;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.rhd-controls-left,
.rhd-controls-center,
.rhd-controls-right {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.rhd-controls-center {
  justify-content: center;
  flex: 1;
}

.rhd-controls-left,
.rhd-controls-right {
  flex-shrink: 0;
}

.rhd-view-toggle {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 2rem; /* Optional space between groups */
  position: relative;
}

.rhd-toggle-group {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.rhd-toggle-group.center {
  justify-content: center;
  flex: 1;
}

.rhd-toggle-group.left {
  justify-content: flex-start;
}

.rhd-toggle-group.right {
  justify-content: flex-end;
}

.rhd-card-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 1rem;
  gap: 1rem;
}

.rhd-action-group {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.rhd-action-group.center {
  justify-content: center;
  flex: 1;
}

.rhd-action-group.left,
.rhd-action-group.right {
  flex-shrink: 0;
}

.rhd-filter-option:hover,
.rhd-filter-option:focus {
  background-color: #f0f0f0;
}

.rhd-filter-icon {
  width: 1.15rem;
  height: 1rem;
  display: inline-block;
  vertical-align: middle;
  flex-shrink: 0;
}
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.3rem;
  cursor: pointer;
  transition: opacity 0.2s ease;

.rhd-sort-menu {
    position: absolute;
    top: 120%;
    right: -179%;
    z-index: 999;
    background: #fff;
    border: 1px solid #ccc;
    border-radius: 6px;
    padding: 16px 12px 18px 17px;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
    display: flex;
    flex-direction: column;
    gap: 12px;
    min-width: 210px;
}

.rhd-sort-menu.hidden {
  display: none;
  z-index: 99; /* stays above cards */
}

/* ✨ Base Modal Styles 
.rhd-modal {
  position: absolute;
  top: 3.2rem;
  right: 0;
  z-index: 1000;
  background: white;
  border: 1px solid #ccc;
  border-radius: 0.5rem;
  padding: 0.75rem 1rem;
  min-width: 220px;
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.1);
  opacity: 0;
  transform: translateY(-10px);
  transition: opacity 0.2s ease, transform 0.2s ease;
  pointer-events: none;
}

/* 🔥 Show/Hide Transitions 
.rhd-modal.show {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.rhd-modal.hide {
  opacity: 0;
  transform: translateY(-10px);
  pointer-events: none;
}

/* 🙈 Display none backup for initial state 
.hidden {
  display: none !important;
}*/

/* 🪄 Optional: backdrop 
.rhd-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.3);
  z-index: 997;
  opacity: 0;
  transition: opacity 0.2s ease;
  pointer-events: none;
}*/


.rhd-backdrop.visible {
  opacity: 1;
  pointer-events: all;
}

/* Card Border Accents */
.rhd-request-card.rhd-status-active    { border: 1px solid #4dff00; }
.rhd-request-card.rhd-status-complete  { border: 1px solid #eb000c; }
.rhd-request-card.rhd-status-archived  { border: 1px solid #00fffb; }
.rhd-request-card.rhd-status-trashed   { border: 1px solid #95876f; }

/* Icon Filters */
.rhd-status-icon.rhd-status-active {
  filter: brightness(0) saturate(100%) invert(61%) sepia(88%) saturate(526%) hue-rotate(53deg) brightness(105%) contrast(118%);
}
.rhd-status-icon.rhd-status-complete {
  filter: brightness(0) saturate(100%) invert(17%) sepia(91%) saturate(6832%) hue-rotate(351deg) brightness(87%) contrast(113%);
}
.rhd-status-icon.rhd-status-archived {
  filter: brightness(0) saturate(100%) invert(74%) sepia(100%) saturate(715%) hue-rotate(120deg) brightness(103%) contrast(103%);
}
.rhd-status-icon.rhd-status-trashed {
  filter: brightness(0) saturate(100%) invert(54%) sepia(12%) saturate(643%) hue-rotate(359deg) brightness(98%) contrast(90%);
}

.rhd-status-icon img {
  filter: brightness(0) saturate(100%) invert(61%) sepia(88%) saturate(526%) hue-rotate(53deg) brightness(105%) contrast(118%);
}

/* ARCHIVE icon gets colored ONLY on archived cards */
.rhd-status-archived .rhd-archive-btn img {
  filter: brightness(0) saturate(100%) invert(74%) sepia(100%) saturate(715%) hue-rotate(120deg) brightness(103%) contrast(103%);
}

/* TRASH icon gets colored ONLY on trashed cards */
.rhd-status-trashed .rhd-trash-btn img {
  filter: brightness(0) saturate(100%) invert(54%) sepia(12%) saturate(643%) hue-rotate(359deg) brightness(98%) contrast(90%);
}

/* ❌ All other times — archive & trash = neutral gray */
.rhd-archive-btn img,
.rhd-trash-btn img {
  filter: brightness(0) saturate(100%) invert(50%) sepia(0%) saturate(0%) hue-rotate(0deg) brightness(90%) contrast(90%);
}


/* ARCHIVED */
.rhd-status-archived .rhd-archive-btn img {
  filter: brightness(0) saturate(100%) invert(74%) sepia(100%) saturate(715%) hue-rotate(120deg) brightness(103%) contrast(103%);
}

/* TRASHED */
.rhd-status-trashed .rhd-trash-btn img {
  filter: brightness(0) saturate(100%) invert(54%) sepia(12%) saturate(643%) hue-rotate(359deg) brightness(98%) contrast(90%);
}

/* Wrapper */
.rhd-toggle-switch {
  position: relative;
  display: inline-block;
  width: 42px;
  height: 24px;
}

/* Hide the actual checkbox */
.rhd-toggle-input {
  opacity: 0;
  width: 0;
  height: 0;
}

/* The slider track */
.rhd-slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  transition: background-color 0.3s;
  border-radius: 34px;
}

/* The circle thumb */
.rhd-slider::before {
  position: absolute;
  content: "";
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  transition: transform 0.3s;
  border-radius: 50%;
}

/* Toggle ON */
.rhd-toggle-input:checked + .rhd-slider {
  background-color: #4dff00; /* Active Green */
}

.rhd-toggle-input:checked + .rhd-slider::before {
  transform: translateX(18px);
}

/* Optional: Red when completed */
.rhd-toggle-switch[data-status="complete"] .rhd-slider {
  background-color: #eb000c !important;
}

.rhd-archive-icon {
      filter: brightness(0) saturate(100%) invert(74%) sepia(100%) saturate(715%) hue-rotate(120deg) brightness(103%) contrast(103%);
}

.rhd-active-icon {
  filter: brightness(0) saturate(100%) invert(61%) sepia(88%) saturate(526%) hue-rotate(53deg) brightness(105%) contrast(118%);
}

.rhd-trashed-icon {
  filter: brightness(0) saturate(100%) invert(54%) sepia(12%) saturate(643%) hue-rotate(359deg) brightness(98%) contrast(90%);
}

.rhd-completed-icon {
  filter: brightness(0) saturate(100%) invert(17%) sepia(91%) saturate(6832%) hue-rotate(351deg) brightness(87%) contrast(113%);
}

.rhd-toggle-wrapper {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.rhd-toggle-icon {
  width: 20px;
  height: 20px;
  opacity: 0.4;
  transition: opacity 0.2s, filter 0.2s;
}

/* ✅ ACTIVE state - Green Truck */
.rhd-status-active .rhd-icon-left {
  filter: brightness(0) saturate(100%) invert(61%) sepia(88%) saturate(526%) hue-rotate(53deg) brightness(105%) contrast(118%);
}

.rhd-status-active .rhd-icon-right {
  opacity: 1.0;
}

/* ✅ COMPLETE state - Red Check */
.rhd-status-complete .rhd-icon-left {
  opacity: 1.0;
}

.rhd-status-complete .rhd-icon-right {
  filter: brightness(0) saturate(100%) invert(61%) sepia(88%) saturate(526%) hue-rotate(53deg) brightness(105%) contrast(118%);
}

/* 🖼️ Toggle icon base style */
.rhd-toggle-icon {
  width: 20px;
  height: 20px;
  transition: filter 0.3s ease, opacity 0.3s ease;
}

/* Default: gray icons */
.rhd-toggle-wrapper .rhd-toggle-icon {
  filter: brightness(0) saturate(100%) invert(50%) sepia(0%) saturate(0%) hue-rotate(0deg) brightness(90%) contrast(90%);
}

/* Active = right side (truck green) */
.rhd-status-active .rhd-icon-right {
  filter: brightness(0) saturate(100%) invert(61%) sepia(88%) saturate(526%) hue-rotate(53deg) brightness(105%) contrast(118%);
}

/* Active = left side (check gray) — no change needed */

/* Complete = left side (check red) */
.rhd-status-complete .rhd-icon-left {
  filter: brightness(0) saturate(100%) invert(27%) sepia(98%) saturate(7481%) hue-rotate(357deg) brightness(98%) contrast(115%);
}

/* Complete = right side (truck gray) — no change needed */

.rhd-toggle-wrapper {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* 🛠 Default switch track style */
.rhd-toggle-switch .rhd-slider {
  background-color: #ccc;
  transition: background-color 0.3s ease;
}

/* ✅ Active = green track */
.rhd-status-active .rhd-toggle-switch .rhd-slider {
  background-color: #4dff00; /* Tailwind Emerald 400 */
}

/* 🟥 Complete = red track */
.rhd-status-complete .rhd-toggle-switch .rhd-slider {
  background-color: #f87171; /* Tailwind Red 400 */
}

.rhd-filter-btn img {
  width: 20px;
  height: 20px;
  transition: filter 0.3s ease, transform 0.2s ease;
  filter: brightness(0) saturate(100%) invert(50%) sepia(0%) hue-rotate(0deg) brightness(90%) contrast(90%); /* gray */
  opacity: 0.4;
}

.rhd-filter-btn.active img {
  opacity: 1.0;
  transform: scale(1.1);
}

.rhd-filter-btn.active[data-filter="active"] img {
  filter: brightness(0) saturate(100%) invert(61%) sepia(88%) saturate(526%) hue-rotate(53deg) brightness(105%) contrast(118%);
}

.rhd-filter-btn.active[data-filter="complete"] img {
  filter: brightness(0) saturate(100%) invert(17%) sepia(91%) saturate(6832%) hue-rotate(351deg) brightness(87%) contrast(113%);
}

.rhd-filter-btn.active[data-filter="archived"] img {
  filter: brightness(0) saturate(100%) invert(74%) sepia(100%) saturate(715%) hue-rotate(120deg) brightness(103%) contrast(103%);
}

.rhd-control-icons.center,
.rhd-control-icons.right {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.rhd-avatar-only {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
  box-shadow: 0 0 4px rgba(0, 0, 0, 0.15);
}

/* payment-confirmation.css */
.payment-confirm-container {
  max-width: 640px;
  margin: 2.5rem auto;
  background-color: #ffffff;
  padding: 2rem;
  border-radius: 1rem;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  animation: fadeInSlideUp 0.5s ease-out both;
}

.payment-confirm-container h1 {
  font-size: 1.75rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: #111827;
  text-align: center;
}

.payment-confirm-container .success {
  color: #059669;
  background: #ecfdf5;
  border: 1px solid #10b981;
  padding: 1rem;
  border-radius: 0.5rem;
  font-weight: 600;
  margin-top: 1.25rem;
  text-align: center;
}

.payment-confirm-container .error {
  color: #b91c1c;
  background: #fef2f2;
  border: 1px solid #ef4444;
  padding: 1rem;
  border-radius: 0.5rem;
  font-weight: 600;
  margin-top: 1.25rem;
  text-align: center;
}

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

.rhd-return-btn {
  display: inline-block;
  margin-top: 1.5rem;
  padding: 0.75rem 1.5rem;
  background-color: #548bc0;
  color: white;
  font-weight: 200;
  font-size: 18px;
  border-radius: 0.5rem;
  text-decoration: none;
  text-align: center;
  transition: background-color 0.2s ease;
}

.rhd-return-btn:hover {
  background-color: #548bc0;
}

.rhd-form-container {
  max-width: 600px;
  margin: 0 auto;
  padding: 20px;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 6px;
  box-shadow: 0 0 10px rgba(0,0,0,0.05);
}

.rhd-form-heading {
  font-size: 1.5rem;
  margin-bottom: 15px;
  border-bottom: 1px solid #ddd;
  padding-bottom: 5px;
  color: #333;
}

.rhd-form .rhd-field {
  margin-bottom: 15px;
}

.rhd-form label {
  display: block;
  font-weight: 500;
  margin-bottom: 5px;
  color: #444;
}

.rhd-form input[type="text"],
.rhd-form input[type="email"],
.rhd-form input[type="tel"],
.rhd-form input[type="number"],
.rhd-form input[type="password"] {
  width: 100%;
  padding: 8px;
  border: 1px solid #ccc;
  border-radius: 4px;
}

.rhd-form input[readonly] {
  background: #f9f9f9;
}

.rhd-form p {
  margin-bottom: 8px;
  font-weight: 500;
}

.rhd-form .rhd-required {
  color: red;
}

.rhd-address-container {
  border: 1px solid #ccc;
  padding: 8px;
  border-radius: 4px;
  background: #fafafa;
}

.rhd-btn {
  display: inline-block;
  padding: 10px 16px;
  border: none;
  border-radius: 4px;
  color: #fff;
  cursor: pointer;
  text-align: center;
}

.rhd-btn-blue {
  background: #0073e6;
}

.rhd-btn-blue:hover {
  background: #005bb5;
}

.rhd-btn-yellow {
  background: #f59e0b;
}

.rhd-btn-yellow:hover {
  background: #d97706;
}

.rhd-hidden {
  display: none;
}

.rhd-success {
  margin-top: 15px;
  color: green;
  font-weight: bold;
}

.rhd-delivery-form { max-width:800px; margin:2em auto; padding:.5em; background:#fff;  border-radius:8px; font-family: 'DM Sans'; font-size: 14px;}
.rhd-delivery-form h2 { margin-top:1.5em; border-bottom:2px solid #eee; padding-bottom:0.3em;   font-weight: 700; font-size: 1.25rem; color:#00325B; }
.rhd-delivery-form label, .rhd-delivery-form p { display:block; margin:0.8em 0 0.2em; color:#444;  }
.rhd-delivery-form input[type='text'], input[type='email'], input[type='tel'], input[type='number'], .rhd-delivery-form .rhd-address-container { width:100%; padding:0.6em; border:1px solid #ccc; border-radius:4px; box-sizing:border-box; }
.rhd-delivery-form input[readonly] { background:#f7f7f7; }
.rhd-delivery-form button { padding:0.7em 1.2em; border:none; border-radius:4px;  cursor:pointer; font-size:1em; }
#rhdGenerateQuote { background:#f90; color:#fff; }
.rhd-delivery-form button[type='submit'] { background:#00325B; color:#fff;     margin-top: .85rem;}
.conditional-group.hidden { display:none; }
/*
.autocomplete-dropdown {
  position: absolute;
  background: white;
  border: 1px solid #ccc;
  z-index: 1000;
  max-height: 200px;
  overflow-y: auto;
  list-style: none;
  padding: 0;
  margin: 0;
}

.autocomplete-dropdown li {
  padding: 8px;
  cursor: pointer;
}

.autocomplete-dropdown li:hover {
  background: #f0f0f0;
}
*/

.rhd-modal {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  display: none;
  align-items: flex-start;
  justify-content: center;
  z-index: 1000;
  overflow: auto; 

}

.rhd-modal.active {
  display: flex;
}

.modal-inner {
  background: #fff;
  padding: 2rem;
  margin-top: 5vh;
  margin-bottom: 5vh;
  max-width: 500px;
  width: 90%;
  border-radius: 8px;
  text-align: left;
  box-shadow: 0 0 20px rgba(0,0,0,0.3);
  display: flex;
  flex-direction: column;
  max-height: none;
  overflow: visible;
}

.modal-content {
  margin-bottom: 1rem;
font-family: 'DM Sans';
}

.modal-actions {
  display: inline;
  justify-content: center;
  gap: .5rem;
}

.rhd-btn {
  padding: 0.5rem 1rem;
  border: none;
  cursor: pointer;
  border-radius: 4px;
}

.rhd-btn-login {
  background: #00325B;
  color: #fff;
  width: 100%;
  margin-bottom: .75rem;
  border: 0px solid #00325B;
  margin-top: .75rem;
}

.rhd-btn-primary {
  background: #00325B;
  color: #fff;
  width: 100%;
  margin-bottom: .75rem;
  border: 0px solid #00325B;
}

.rhd-btn-primary:hover {
  background: #00325B;
  color: #fff;
  width: 100%;
  margin-bottom: .75rem;
}

.rhd-btn-secondary {
  background: #ccc;
}

.rhd-button-group {
  /*display: inline;
  flex-direction: column;
  gap: 10px;*/
  margin-top: 15px;
}

#rhdGenerateQuote {
  background: #00325B;
  color: #fff;
  font-weight: 700;
  padding: 10px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  width:100%;
  margin-top: 1.5rem;
}

.rhd-btn-secondary {
  background: #ddd;
  color: #333;
  padding: 8px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 0.9rem;
  width: 100%;
}

.rhd-modal-header {
  text-align: center;
  margin-bottom: 1rem;
}

.rhd-modal-logo {
  max-width: 160px;
  height: auto;
  display: inline-block;
}

.rhd-estimate-highlight {
  color: #00325B;         /* brand hex */
  font-weight: 700;
  font-size: 1.25rem;     /* Make it stand out without being obnoxious */
  display: inline-block;
  padding: 2px 6px;
  background: #f0f8ff;    /* Soft background highlight (optional) */
  border-radius: 4px;
}

#rhdSuccessModal .rhd-modal-icon {
  width: 68px;
  margin: 0 auto 1rem;
  display: block;
}

#rhdSuccessModal h2 {
  font-size: 28px;
  font-weight: 700;
  text-align: center;
}

#rhdSuccessModal p {
  font-size: 18px;
  text-align: center;
  margin-bottom: 1.5rem;
}

#rhdSuccessModal .rhd-btn-dark {
  background: #00325B;
  color: #fff;
  padding: 0.6rem 1.2rem;
  border-radius: 4px;
  text-align: center;
  display: inline-block;
  margin: 0 auto;
}
#rhdSuccessModal .modal-actions {
    display: flex;
    justify-content: center;
    margin-top: 20px;
}

.rhd-loader {
  margin-top: 1rem;
  text-align: center;
}

.spinner {
  width: 32px;
  height: 32px;
  border: 4px solid #ccc;
  border-top-color: #0073e6;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin: 10px auto 0;
}

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

.rhd-required::after {
  content: " *";
  color: red;
  font-weight: bold;
}

label.rhd-required {
    font-weight: 700;
}
p.rhd-required {
    font-weight: 700;
}

.rhd-crm-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 1rem;
  font-family: 'DM Sans', sans-serif;
}

.rhd-crm-table th,
.rhd-crm-table td {
  border: 1px solid #ccc;
  padding: 8px 10px;
  text-align: left;
  font-size: 0.95rem;
}

.rhd-crm-table th {
  background-color: #f5f5f5;
  font-weight: 600;
}

.rhd-btn-sm {
  padding: 4px 10px;
  font-size: 0.85rem;
  border-radius: 4px;
  cursor: not-allowed; /* Until enabled */
}

.rhd-crm-btn-primary {
  background-color: #00325B;
  color: #fff !important;
}

.rhd-crm-btn-primary:hover {
  background-color: #001f38;
}

.rhd-btn-secondary {
  background-color: #ddd;
  color: #333;
    margin-bottom: .75rem;
}

.rhd-btn-secondary:hover {
  background-color: #ccc;
}

.rhd-btn-danger {
    background-color: #fff;
    border: 1px solid #00325B;
    display: inline-flex;
    gap: .4rem;
    align-items: center;
    justify-content: center;
    color: #e63946;
    border-radius: 6px;
    padding: 0.5rem 4rem;
    font-weight: 600;
    margin-bottom: .75rem;
}

.rhd-btn-danger:hover {
  background-color: #e63946 !important;
  border: 1px solid #e63946 !important;
}

.rhd-task-wrapper {
  background: #f9f9f9;
  padding: 10px 15px;
  border-top: 1px solid #ddd;
  font-size: 0.9rem;
}

.rhd-task-list {
  list-style: disc;
  padding-left: 1rem;
  margin: 0;
}

#rhdTicketEditModal textarea {
  width: 100%;
  min-height: 100px;
  margin-bottom: 1rem;
}

#rhdTicketEditModal select,
#rhdTicketEditModal input {
  width: 100%;
  margin-bottom: 1rem;
  padding: 6px;
}

.rhd-ticket-view-content p {
  margin: 0.5rem 0;
  font-family: 'DM Sans', sans-serif;
}

.modal-actions {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-top: 1rem;
}

.rhd-org-builder {
  max-width: 800px;
  margin: auto;
  padding: 2rem;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 3px 8px rgba(0,0,0,0.1);
}

.rhd-org-section {
  margin-bottom: 2rem;
}

.rhd-org-section h2 {
  margin-bottom: 1rem;
  font-size: 1.5rem;
}

.rhd-org-section input,
.rhd-org-section select {
  width: 100%;
  margin-bottom: 0.75rem;
  padding: 0.5rem;
  border: 1px solid #ccc;
  border-radius: 4px;
}

.rhd-modal-content {
  position: relative;
  background: #fff;
  padding: 2rem;
  border-radius: 8px;
  box-shadow: 0 3px 10px rgba(0,0,0,0.2);
  z-index: 10000;
}

/* Compact table rows */
.rhd-org-table tbody tr {
  height: auto;
  padding: 0.25rem 0;
}

.rhd-org-table td {
  vertical-align: middle;
  padding: 6px 8px;
  font-size: 14px;
}

/* Edit / Save Buttons */
.rhd-org-table .rhd-edit-btn,
.rhd-org-table .rhd-save-btn {
  background: none;
  border: none;
  padding: 4px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.rhd-org-table .rhd-edit-btn img,
.rhd-org-table .rhd-save-btn img {
  width: 16px;
  height: 16px;
  opacity: 0.7;
  transition: opacity 0.2s ease;
}

/* Keep icons visible on hover (remove the fade) */
.rhd-org-table .rhd-edit-btn:hover img,
.rhd-org-table .rhd-save-btn:hover img {
  opacity: 1;
  filter: none;
}

/* Button baseline */
.rhd-org-table .rhd-edit-btn,
.rhd-org-table .rhd-save-btn {
  background: transparent !important;     /* defeat Elementor hover bg */
  border: 1px solid transparent;
  border-radius: 6px;
  padding: 4px;
  line-height: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition:
    border-color .15s ease,
    background-color .15s ease,
    box-shadow .15s ease,
    transform .05s ease;
}

/* Hover: 1px border, no fill */
.rhd-org-table .rhd-edit-btn:hover,
.rhd-org-table .rhd-save-btn:hover {
  background: transparent !important;
  border-color: #00325B;
  box-shadow: none;
}

/* Keyboard accessibility */
.rhd-org-table .rhd-edit-btn:focus-visible,
.rhd-org-table .rhd-save-btn:focus-visible {
  outline: 2px solid #00325B;
  outline-offset: 2px;
}


/* Make the icon click register on the button */
.rhd-action-btn img {
  pointer-events: none;
  width: 16px;
  height: 16px;
  display: block;
}

/* Utility */
.hidden { display: none !important; }

.rhd-add-btn {
  background: #00325B;
  color: #fff;
  margin-bottom: .75rem;
}

/* rhd-crm.css */
.rhd-search-wrapper {
  /*margin-bottom: 1.5rem;*/
  max-width: 400px;
}

.rhd-search-input {
  width: 100%;
  padding: 0.5rem 1rem;
  font-size: 1rem;
  border: 1px solid #ccc;
  border-radius: 6px;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.rhd-search-input:focus {
  border-color: #00325B;
  box-shadow: 0 0 0 2px rgba(0, 50, 91, 0.2);
}

/* Base style for all ticket rows */
.ticket-row {
  border: 6px solid;
  transition: border-color 0.2s ease;
}

/* Status color mappings */
.status-new {
  border-color: #FF6B6B; /* Red */
}

.status-approved {
  border-color: #5AD45A; /* Green */
}

.status-contacted {
  border-color: #F7B32B; /* Yellow/Amber */
}

.status-completed {
  border-color: #4ECDC4; /* Cyan / Teal */
}

.status-closed {
  border-color: #000000; /* black */
}

.status-scheduled {
  border-color: #006b35; /* drak green */
}

.rhd-inline-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem; /* ≈ 8px */
  flex-wrap: wrap; /* Optional: prevent overflow if viewport gets tight */
}

.rhd-inline-actions button,
.rhd-inline-actions a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  transition: opacity 0.15s ease-in-out;
}

.rhd-inline-actions img {
  width: 20px;
  height: 20px;
}

.rhd-inline-actions button:hover img,
.rhd-inline-actions a:hover img {
  opacity: 0.25;
}

.rhd-launch-create-ticket {
    filter: brightness(0) saturate(100%) invert(58%) sepia(86%) saturate(1927%) hue-rotate(111deg) brightness(101%) contrast(101%);
}

.rhd-start-row {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}
.rhd-geo-btn {
  white-space: nowrap;
  border-color: #2b6cb0;
  color: #2b6cb0;
}
.rhd-geo-btn:hover {
  background: #f0f6ff;
}

.rhd-filterbar {
  display: flex;
  gap: 12px;
  align-items: flex-end;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.rhd-filter-label { font-size: 0.9rem; margin-right: 6px; }
.rhd-filter-select {
  padding: 6px 10px;
  border: 1px solid #ccc;
  border-radius: 6px;
}

/* filter bar */
.rhd-filterbar { display:flex; gap:12px; align-items:center; flex-wrap:wrap; margin-bottom:12px; }
.rhd-icon-btn { display:inline-flex; align-items:center; justify-content:center; background:#fff; border:1px solid #ccc; border-radius:6px; padding:6px 8px; cursor:pointer; transition:opacity .15s; }
.rhd-icon-btn:hover { opacity:.8; }
.w-5 { width:20px; height:20px; }

/* modal */
.rhd-modal.hidden { display:none; }
/*.rhd-modal.active { display: block; }*/
.rhd-modal { position:fixed; inset:0; z-index:1000; }
.rhd-modal-backdrop { position:absolute; inset:0; background:rgba(0,0,0,.35); }
.rhd-modal-card { position:relative; background:#fff; width:100%; max-width:420px; margin:10vh auto; border-radius:10px; box-shadow:0 10px 30px rgba(0,0,0,.2); overflow:hidden; }
.rhd-modal-header { display:flex; justify-content:space-between; align-items:center; padding:12px 14px; border-bottom:1px solid #eee; }
.rhd-modal-footer { display:block; justify-content:space-between; align-items:center; padding:12px 14px; border-bottom:1px solid #eee; }
.rhd-modal-footer { border-top:1px solid #eee; border-bottom:none; }
.rhd-modal-body { padding:12px 14px; display:grid; grid-template-columns:1fr 1fr; gap:8px 12px; }
.rhd-check { display:flex; align-items:center; gap:8px; }



.rhd-modal { z-index: 9999; } /* ensure it sits above everything */

/* NEW: limit to icon action buttons only */
#rhdDashboardTable .rhd-inline-actions button {
  background: transparent !important;
  color: #00325B;
  padding: 0.25rem;
  border-radius: 4px;
  border: none;
  font-weight: 600;
  font-size: .8rem;
  cursor: pointer;
  transition: opacity .2s ease;
}
#rhdDashboardTable .rhd-inline-actions button:hover {
  background: transparent !important;
  opacity: .8;
}

/* Generic RHD buttons */
.rhd-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .4rem;
  padding: 8px 12px;
  border-radius: 6px;
  border: 1px solid #00325B;
  background: #fff;
  color: #00325B;
  font-weight: 600;
  cursor: pointer;
}
.rhd-btn:hover { background: #00325B; }

.rhd-btn-primary {
  background: #00325B;
  color: #fff;
  border-color: #00325B;
}
.rhd-btn-primary:hover { opacity: .9; }

/* Ensure edit-form submit isn’t overridden by table icon styles */
#rhdDashboardTable .rhd-edit-form .rhd-btn,
#rhdDashboardTable .rhd-edit-form .rhd-btn-primary {
  background: #00325B !important;
  color: #fff !important;
  border-color: #00325B !important;
  width: 100%;
  margin-top: .5rem;
}

input#rhdSubSearchInput {
    margin-bottom: 1rem;
}

.rhd-modal { position: fixed; inset: 0; z-index: 99999; }
.rhd-modal .rhd-modal-backdrop { position: fixed; inset: 0; }
.rhd-modal .rhd-modal-card { position: relative; z-index: 1; }

.rhd-map-wrap { display:grid; grid-template-columns: 2fr 1fr; gap:12px; margin-top:12px; }
.rhd-map      { width:100%; height:420px; border:1px solid #e2e8f0; border-radius:8px; }
.rhd-tt       { background:#fff; border:1px solid #e2e8f0; border-radius:8px; padding:10px; overflow:auto; }
.rhd-steps    { margin: 8px 0 0; padding-left: 1.25rem; max-height: 380px; overflow:auto; }
.rhd-tt-header{ display:flex; align-items:center; justify-content:space-between; gap:8px; }
.rhd-step-ind { font-weight:600; }

.rhd-normal { font-weight: 400 !important; }
.rhd-required::after { content: " *"; color: #dc2626; }

.rhd-alert{
  margin:10px 0;
  padding:10px 12px;
  border:1px solid #fdba74;
  background:#fff7ed;
  color:#9a3412;
  border-radius:8px;
}

.rhd-quote.rhd-oor { color:#dc2626; font-weight:700; } /* red $0.00 or >59 mi */

.rhd-badge-oor{
  display:inline-block; padding:2px 6px; border-radius:6px;
  background:#fee2e2; color:#b91c1c; border:1px solid #fecaca;
  font-weight:700; font-size:.85rem; letter-spacing:.02em;
}

/* ⚠️ do NOT use .rhd-modal here */
.rhd-upload-modal { 
  position: fixed; inset: 0;
  background: rgba(0,0,0,.45);
  display: none;                     /* hidden by default */
  align-items: center; justify-content: center;
  z-index: 1000;
}
.rhd-upload-modal.is-open { display: flex; }  /* visible when open */

.rhd-upload-modal .modal-inner{
  background:#fff; padding:16px; border-radius:10px;
  min-width:280px; max-width:520px;
  box-shadow:0 12px 28px rgba(0,0,0,.22);
}
.rhd-upload-list{ margin-top:8px; font-size:.92rem }
.rhd-up-item{ padding:6px 8px; border:1px solid #e5e7eb; border-radius:8px; margin-top:6px }

.rhd-linklike { background:none; border:0; padding:0; color:#0f172a; cursor:pointer; }
.rhd-linklike:hover { text-decoration:underline; }

.rhd-att-inline{
  margin-top:6px; padding:8px; background:#fff;
  border:1px solid #e5e7eb; border-radius:6px; max-width:340px;
}
.rhd-att-row{ display:flex; align-items:center; gap:8px; margin:4px 0; }
.rhd-att-thumb{ width:56px; height:56px; object-fit:cover; border-radius:4px; border:1px solid #e5e7eb; }

/* plan viewer basics (reuse your existing classes where possible) */
.rhd-kv{margin:8px 0 12px;color:#0f172a}
.rhd-mono{font-family:ui-monospace,SFMono-Regular,Menlo,monospace;background:#f8fafc;padding:8px;border-radius:6px;white-space:pre-wrap}
.rhd-copy{display:flex;gap:8px;flex-wrap:wrap;margin:8px 0}
.rhd-mapwrap.hidden{display:none}
.rhd-map{width:100%;height:360px;border-radius:8px;overflow:hidden;margin:8px 0}
.rhd-tt.hidden{display:none}
.rhd-tt-steps{margin:6px 0 0 18px}
.rhd-tt-step{cursor:pointer}

/* compact blue chip */
.fc .rhd-cal-chip-label{
  display:inline-block;
  padding:4px 8px;
  border-radius:4px;
  background:#00325B;
  color:#fff;
  font-size:12px;
  width:100%;
  line-height:1.4;
}
.fc-daygrid-event { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.rhd-badge { display:inline-block; min-width:1.25rem; padding:0 .35rem; border-radius:9999px; font-weight:600; font-size:.85em; }
.rhd-queue-list { list-style:none; padding:0; margin:0; }
.rhd-queue-item { display:flex; align-items:flex-start; gap:.5rem; padding:.4rem 0; border-bottom:1px solid #eee; }
.rhd-queue-item .meta { font-size:.85em; color:#666; }
.rhd-queue-item .actions { margin-left:auto; }

/* Modal shell */
.rhd-schedule-modal{position:fixed;inset:0;background:rgba(0,0,0,.45);display:none;align-items:center;justify-content:center;z-index:1000}
.rhd-schedule-modal.is-open{display:flex}
.rhd-schedule-modal .modal-inner{
  background:#fff;
  padding:16px;
  border-radius:10px;
  min-width:300px;
  max-width:720px;        /* a little wider helps */
  max-height:85vh;        /* 🔹 constrain height */
  overflow:auto;          /* 🔹 make inner scroll */
  box-shadow:0 12px 28px rgba(0,0,0,.22)
}

.rhd-list { margin: 6px 0 0 0; padding-left: 20px; }
.rhd-list li { margin: 2px 0; }

.rhd-pill {
  display:inline-block; margin-left:6px; padding:2px 6px;
  font-size:.75rem; line-height:1; border-radius:9999px;
  background:#fff7ed; color:#9a3412; border:1px solid #fdba74;
}
.rhd-pill.manual {
  background:#fff7ed; color:#9a3412; border-color:#fdba74;
}

/* Plan viewer numbered lists: no bullet dots */
.rhd-plan-modal .rhd-list {
  list-style: none;
  margin: 0;
  padding-left: 0;
}
.rhd-plan-modal .rhd-list li { padding-left: 0; }

.rhd-toggle {
    display: flex;
    gap: 8px;
}

#rhd-ticket-table th:nth-child(5),  /* City */
#rhd-ticket-table th:nth-child(6),  /* Store/Region */
#rhd-ticket-table td:nth-child(5),
#rhd-ticket-table td:nth-child(6) {
  width: 100px;
  max-width: 180px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rhd-delete-btn {
    border: 1px solid #00325B;
}

/* General dashboard wrapper */
.rhd-dashboard {
  margin: 20px 0;
  font-family: Arial, sans-serif;
}

/* Title */
.rhd-dashboard-title {
  font-size: 22px;
  font-weight: bold;
  margin-bottom: 10px;
}

/* Search bar */
.rhd-dashboard-search {
  border: 1px solid #ccc;
  border-radius: 4px;
  padding: 6px 10px;
  margin-bottom: 12px;
  width: 100%;
  max-width: 300px;
}

/* Table */
.rhd-dashboard-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.rhd-dashboard-table th,
.rhd-dashboard-table td {
  border: 1px solid #ccc;
  padding: 8px;
  text-align: left;
}

.rhd-dashboard-table thead {
  background: #f4f4f4;
}

.rhd-dashboard-table tr:hover {
  background: #fff8e1;
}

/* Detail + Edit rows */
.rhd-detail-box {
  background: #fafafa;
  padding: 10px;
  border-radius: 4px;
  border: 1px solid #eee;
}

.rhd-edit-row {
  background: #fffbe6;
}

/* Buttons */

.rhd-btn-link {
  background: none;
  border: none;
  padding: 0;
  margin: 0;
  color: #2563eb;
  cursor: pointer;
  text-decoration: underline;
  font-size: 14px;
}
