:root {
  --primary: #2563eb;
  --bg-main: #f1f5f9;
  --border-color: #cbd5e1;
  --text-main: #0f172a;
  --text-muted: #64748b;
  --font-family: "Inter", sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: var(--font-family);
}

body {
  background-color: var(--bg-main);
  color: var(--text-main);
  overflow-x: hidden;
}

/* Navbar / Ribbon */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 16px;
  background: #ffffff;
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.nav-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.nav-title {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.3px;
  color: #1e293b;
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Save status indicator */
.save-indicator {
  font-size: 11px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 4px;
  background: #e2e8f0;
  color: #475569;
}
.save-indicator.saving {
  background: #fef3c7;
  color: #b45309;
}
.save-indicator.saved {
  background: #dcfce7;
  color: #15803d;
}
.save-indicator.error {
  background: #fee2e2;
  color: #b91c1c;
}

/* Buttons */
.btn {
  padding: 6px 14px;
  font-size: 12px;
  font-weight: 600;
  border-radius: 4px;
  cursor: pointer;
  border: 1px solid transparent;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}
.btn-primary {
  background: var(--primary);
  color: white;
}
.btn-primary:hover {
  background: #1d4ed8;
}
.btn-success {
  background: #10b981;
  color: white;
}
.btn-success:hover {
  background: #059669;
}
.btn-secondary {
  background: #e2e8f0;
  color: #1e293b;
}
.btn-secondary:hover {
  background: #cbd5e1;
}
.btn-outline {
  background: transparent;
  border-color: var(--border-color);
  color: #334155;
}
.btn-outline:hover {
  background: #f1f5f9;
}

/* Search Group */
.search-group {
  display: flex;
  align-items: center;
  gap: 4px;
}
.search-group select {
  padding: 6px 8px;
  border: 1px solid var(--border-color);
  border-radius: 4px;
  font-size: 12px;
  background: white;
  outline: none;
}
.search-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}
.search-input-wrapper input {
  padding: 6px 10px 6px 26px;
  border: 1px solid var(--border-color);
  border-radius: 4px;
  font-size: 12px;
  outline: none;
  width: 170px;
}
.search-icon {
  position: absolute;
  left: 7px;
  font-size: 11px;
  opacity: 0.6;
}

/* Full Width Table Layout with Crisp Colors */
.main-wrapper {
  padding: 10px 14px;
  width: 100%;
  height: calc(100vh - 55px);
  display: flex;
  flex-direction: column;
}
.table-responsive {
  flex: 1;
  height: 100%;
  overflow-x: auto;
  overflow-y: auto;
  background: white;
  border: 1px solid var(--border-color);
  border-radius: 6px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
}
table {
  width: max-content;
  min-width: 100%;
  border-collapse: collapse;
  font-size: 12px;
  white-space: nowrap;
}
th {
  position: sticky;
  top: 0;
  background: #0f172a;
  color: #ffffff;
  font-weight: 600;
  padding: 8px 14px;
  text-align: center;
  border-right: 1px solid #1e293b;
  user-select: none;
  cursor: context-menu;
  z-index: 10;
  width: fit-content;
  white-space: nowrap;
}

/* Month column width & compact center alignment */
th[data-col="month_year"],
td.col-month-cell {
  width: 95px !important;
  min-width: 90px !important;
  max-width: 105px !important;
  text-align: center !important;
}

.month-picker-trigger {
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  background: transparent;
  width: 100%;
}
td {
  padding: 6px 12px;
  border-bottom: 1px solid #e2e8f0;
  border-right: 1px solid #e2e8f0;
  vertical-align: middle;
  background: #ffffff;
  color: #0f172a;
  width: fit-content;
  white-space: nowrap;
  outline: none;
}
td[contenteditable="true"] {
  cursor: text;
}
td[contenteditable="true"]:focus {
  background: #ffffff !important;
  box-shadow: inset 0 0 0 2px var(--primary);
}
tr:nth-child(even) td {
  background: #f8fafc;
}
tr:hover td {
  background: #f1f5f9;
}
.col-sn {
  text-align: center;
  background: #090d16;
  position: sticky;
  left: 0;
  z-index: 15;
}
td.col-sn-cell {
  text-align: center;
  font-weight: 700;
  color: #475569;
  background: #f1f5f9;
  cursor: context-menu;
  position: sticky;
  left: 0;
  z-index: 5;
}

/* Inputs inside Table */
.cell-input,
.cell-select {
  width: 100%;
  border: 1px solid transparent;
  background: transparent;
  padding: 4px 6px;
  font-size: 12px;
  outline: none;
  font-family: inherit;
  border-radius: 3px;
  color: #0f172a;
}
.cell-input:focus,
.cell-select:focus {
  border-color: var(--primary);
  background: white;
}
.cell-input[readonly] {
  cursor: default;
}
.editable-active .cell-input,
.editable-active .cell-select {
  border-color: #e2e8f0;
  background: #ffffff;
}

/* Context Menu */
.context-menu {
  position: absolute;
  display: none;
  flex-direction: column;
  background: white;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  z-index: 2000;
  min-width: 170px;
  padding: 4px 0;
}
.context-menu button {
  padding: 8px 14px;
  border: none;
  background: transparent;
  text-align: left;
  font-size: 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
}
.context-menu button:hover {
  background: #f1f5f9;
}
.text-danger {
  color: #dc2626 !important;
}

/* Filter Popup */
#filterPopup {
  position: absolute;
  display: none;
  flex-direction: column;
  background: white;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.18);
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  width: 250px;
  padding: 10px;
  z-index: 2500;
}
.filter-sort-actions {
  display: flex;
  gap: 6px;
  margin: 6px 0;
}
.btn-sort {
  flex: 1;
  padding: 4px 6px;
  font-size: 11px;
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  border-radius: 4px;
  cursor: pointer;
}
.btn-sort:hover {
  background: #e2e8f0;
}
.filter-search {
  width: 100%;
  padding: 5px 8px;
  border: 1px solid #cbd5e1;
  border-radius: 4px;
  font-size: 12px;
  margin-bottom: 6px;
  outline: none;
}
.filter-list {
  max-height: 260px;
  overflow-y: auto;
  border: 1px solid #f1f5f9;
  padding: 4px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.filter-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  padding: 2px 4px;
}

/* Month-Year Picker Popover */
.month-picker-popover {
  position: absolute;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.18);
  width: 220px;
  padding: 10px;
  z-index: 4500;
}
.myp-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
  border-bottom: 1px solid #f1f5f9;
  padding-bottom: 6px;
}
.myp-year-text {
  font-weight: 700;
  font-size: 13px;
  color: #1e293b;
}
.myp-nav-btn {
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 4px;
  cursor: pointer;
  padding: 3px 8px;
  font-size: 11px;
  color: #334155;
}
.myp-nav-btn:hover {
  background: #e2e8f0;
}
.myp-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
}
.myp-month-btn {
  padding: 6px 0;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 600;
  color: #1e293b;
  cursor: pointer;
  text-align: center;
}
.myp-month-btn:hover {
  background: #2563eb;
  color: #ffffff;
  border-color: #2563eb;
}
.month-picker-trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  background: transparent;
  width: 100%;
}

/* Modals & 5-Column Grid */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.65);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 3000;
}
.modal-box {
  background: white;
  padding: 22px;
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
  width: 100%;
}
.modal-super-wide {
  max-width: 1180px;
  max-height: 90vh;
  overflow-y: auto;
}
.modal-header-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}
.modal-header-bar h3 {
  font-size: 16px;
  color: #0f172a;
}
.modal-close-icon {
  background: transparent;
  border: none;
  font-size: 18px;
  cursor: pointer;
  color: #64748b;
}
.modal-sub-text {
  font-size: 12px;
  color: #64748b;
  margin-bottom: 18px;
}
.form-row-5 {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
  margin-bottom: 14px;
}
.form-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.form-field label {
  font-size: 11px;
  font-weight: 600;
  color: #475569;
}
.modal-input {
  width: 100%;
  padding: 7px 10px;
  border: 1px solid #cbd5e1;
  border-radius: 4px;
  outline: none;
  font-size: 12px;
}
.modal-input:focus {
  border-color: var(--primary);
}
.readonly-bg {
  background: #f1f5f9;
  color: #475569;
}
.uppercase-text {
  text-transform: uppercase;
  font-weight: 600;
}
.modal-actions-bar {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 15px;
  padding-top: 14px;
  border-top: 1px solid #e2e8f0;
}

/* Upload Progress Bar */
.progress-wrapper {
  margin-top: 10px;
  margin-bottom: 10px;
}
.progress-bar-bg {
  width: 100%;
  height: 8px;
  background: #e2e8f0;
  border-radius: 4px;
  overflow: hidden;
}
.progress-bar-fill {
  width: 0%;
  height: 100%;
  background: #2563eb;
  transition: width 0.2s ease-in-out;
}
.progress-text {
  font-size: 11px;
  font-weight: 600;
  color: #2563eb;
  margin-top: 4px;
  display: block;
}

/* Row attachment button styling */
.btn-attachment {
  border: 1px solid #cbd5e1;
  background: #f8fafc;
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 11px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  text-decoration: none;
  color: #1e293b;
}
.btn-attachment:hover {
  background: #e2e8f0;
}
.btn-attachment.has-file {
  background: #eff6ff;
  border-color: #93c5fd;
  color: #1d4ed8;
  font-weight: 600;
}

/* Floating Toast */
.bottom-toast {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: #1e293b;
  color: white;
  padding: 8px 16px;
  font-size: 12px;
  border-radius: 4px;
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none;
  z-index: 4000;
}
.bottom-toast.show {
  opacity: 1;
}
/* Duplicate Row Highlighting */
tr.row-duplicate {
  background-color: #fee2e2 !important; /* Soft Red Tint */
}

tr.row-duplicate:hover {
  background-color: #fecaca !important;
}

tr.row-duplicate td.col-sn-cell {
  background-color: #fca5a5 !important;
  color: #7f1d1d !important;
  font-weight: 700;
}

#filterList .tree-row {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 3px 4px;
  font-size: 12px;
  font-weight: 600;
  color: #0f172a;
}
#filterList .tree-row label {
  cursor: pointer;
  margin: 0;
}
#filterList .tree-toggle {
  width: 14px;
  font-size: 10px;
  color: #475569;
  cursor: pointer;
  user-select: none;
  text-align: center;
}
#filterList .tree-children {
  padding-left: 18px;
}
#filterList .tree-leaf {
  font-weight: 400;
}

/* =========================================================
   GLASSMORPHISM SECURITY LOGIN MODAL
   ========================================================= */
.glass-login-overlay {
  background:
    radial-gradient(
      circle at 20% 22%,
      rgba(56, 189, 248, 0.25),
      transparent 45%
    ),
    radial-gradient(
      circle at 80% 78%,
      rgba(124, 58, 237, 0.22),
      transparent 45%
    ),
    rgba(9, 17, 34, 0.8);
  backdrop-filter: blur(14px) saturate(150%);
  -webkit-backdrop-filter: blur(14px) saturate(150%);
  padding: 16px;
}

.glass-login-box {
  position: relative;
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.14) 0%,
    rgba(255, 255, 255, 0.05) 100%
  );
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-top-color: rgba(255, 255, 255, 0.45);
  border-left-color: rgba(255, 255, 255, 0.34);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  padding: 34px 28px;
  border-radius: 20px;
  width: 100%;
  max-width: 365px;
  text-align: center;
  color: #f8fafc;
  box-shadow:
    0 25px 50px -12px rgba(0, 0, 0, 0.65),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.corner-bio-btn {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.28);
  color: #ffffff;
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
  transition: all 0.2s ease;
}

.corner-bio-btn:hover {
  background: rgba(56, 189, 248, 0.32);
  border-color: #38bdf8;
  transform: scale(1.08);
}

.glass-login-badge {
  display: inline-block;
  padding: 4px 12px;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 1.3px;
  text-transform: uppercase;
  color: #7dd3fc;
  background: rgba(56, 189, 248, 0.14);
  border: 1px solid rgba(56, 189, 248, 0.34);
  border-radius: 999px;
  margin-bottom: 12px;
}

.glass-login-box h3 {
  margin: 0 0 6px;
  font-size: 21px;
  font-weight: 700;
  color: #ffffff;
}

.glass-login-box p {
  margin: 0 0 18px;
  font-size: 12.5px;
  color: #cbd5e1;
}

.glass-login-input {
  width: 100%;
  padding: 12px 14px;
  margin-bottom: 14px;
  background: rgba(15, 23, 42, 0.58);
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 12px;
  color: #ffffff;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 2px;
  text-align: center;
  outline: none;
  transition: all 0.2s ease;
}

.glass-login-input::placeholder {
  color: rgba(148, 163, 184, 0.85);
  letter-spacing: 0.5px;
  font-weight: 400;
}

.glass-login-input:focus {
  border-color: #38bdf8;
  background: rgba(15, 23, 42, 0.8);
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.22);
}

.glass-login-btn {
  width: 100%;
  justify-content: center;
  padding: 11px 16px;
  border-radius: 12px;
  font-size: 13.5px;
  font-weight: 700;
  color: #ffffff;
  background: linear-gradient(135deg, #38bdf8, #2563eb);
  box-shadow: 0 8px 22px rgba(37, 99, 235, 0.38);
  transition: all 0.2s ease;
}

.glass-login-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 26px rgba(56, 189, 248, 0.45);
}

/* =========================================================
   DARK MODE THEME
   ========================================================= */
body.dark-mode {
  --bg-main: #0b1329;
  --border-color: #233554;
  --text-main: #f1f5f9;
  --text-muted: #94a3b8;
  background-color: #0b1329;
  color: #f1f5f9;
}

body.dark-mode .navbar {
  background: #0f172a;
  border-bottom-color: #233554;
}

body.dark-mode .nav-title {
  color: #f8fafc;
}

body.dark-mode .save-indicator {
  background: #1e293b;
  color: #cbd5e1;
}

body.dark-mode .btn-secondary {
  background: #1e293b;
  color: #f1f5f9;
}

body.dark-mode .btn-secondary:hover {
  background: #334155;
}

body.dark-mode .btn-outline {
  border-color: #334155;
  color: #e2e8f0;
}

body.dark-mode .btn-outline:hover {
  background: #1e293b;
}

body.dark-mode .search-group select,
body.dark-mode .search-input-wrapper input {
  background: #131f37;
  border-color: #233554;
  color: #f8fafc;
}

body.dark-mode .table-responsive {
  background: #131f37;
  border-color: #233554;
}

body.dark-mode th {
  background: #080d1a;
  border-right-color: #1e293b;
}

body.dark-mode td {
  background: #131f37;
  color: #e2e8f0;
  border-bottom-color: #1e293b;
  border-right-color: #1e293b;
}

body.dark-mode tr:nth-child(even) td {
  background: #0f192e;
}

body.dark-mode tr:hover td {
  background: #1b2a4a;
}

body.dark-mode td[contenteditable="true"]:focus {
  background: #1e293b !important;
  color: #ffffff !important;
}

body.dark-mode td.col-sn-cell {
  background: #0d1628;
  color: #94a3b8;
}

body.dark-mode .cell-input,
body.dark-mode .cell-select {
  background: #0f172a;
  border-color: #334155;
  color: #f8fafc;
}

body.dark-mode input[type="date"].cell-input {
  color-scheme: dark;
}

body.dark-mode .cell-select option {
  background: #0f172a;
  color: #f8fafc;
}

body.dark-mode.editable-active .cell-input,
body.dark-mode.editable-active .cell-select {
  background: #0f172a;
  border-color: #334155;
  color: #f8fafc;
}

body.dark-mode .cell-input:focus,
body.dark-mode .cell-select:focus {
  background: #1e293b;
  border-color: #38bdf8;
  color: #ffffff;
  box-shadow: 0 0 0 2px rgba(56, 189, 248, 0.2);
}

body.dark-mode .modal-box,
body.dark-mode #filterPopup,
body.dark-mode .context-menu,
body.dark-mode .month-picker-popover {
  background: #131f37;
  border-color: #233554;
  color: #f1f5f9;
}

body.dark-mode .modal-header-bar h3,
body.dark-mode #filterPopupTitle,
body.dark-mode .myp-year-text,
body.dark-mode #filterList .tree-row {
  color: #f8fafc;
}

body.dark-mode .modal-sub-text,
body.dark-mode .form-field label {
  color: #94a3b8;
}

body.dark-mode .modal-input,
body.dark-mode .filter-search {
  background: #0b1329;
  border-color: #233554;
  color: #f8fafc;
}

body.dark-mode .readonly-bg {
  background: #1e293b;
  color: #94a3b8;
}

body.dark-mode .modal-actions-bar {
  border-top-color: #233554;
}

body.dark-mode .context-menu button {
  color: #e2e8f0;
}

body.dark-mode .context-menu button:hover,
body.dark-mode .btn-sort:hover {
  background: #1e293b;
}

body.dark-mode .btn-sort,
body.dark-mode .myp-nav-btn,
body.dark-mode .myp-month-btn {
  background: #0b1329;
  border-color: #233554;
  color: #e2e8f0;
}

body.dark-mode .filter-list {
  border-color: #233554;
}

body.dark-mode .btn-attachment {
  background: #1e293b;
  border-color: #334155;
  color: #e2e8f0;
}

body.dark-mode .btn-attachment.has-file {
  background: rgba(37, 99, 235, 0.22);
  border-color: rgba(59, 130, 246, 0.5);
  color: #93c5fd;
}

body.dark-mode tr.row-duplicate td {
  background-color: rgba(220, 38, 38, 0.22) !important;
}

body.dark-mode tr.row-duplicate td.col-sn-cell {
  background-color: rgba(220, 38, 38, 0.45) !important;
  color: #fecaca !important;
}

/* =========================================================
   MOBILE 3-BAR HAMBURGER RIBBON MENU & COMPACT HEADER
   ========================================================= */
.title-mobile {
  display: none;
}

.mobile-header-actions {
  display: none;
  align-items: center;
  gap: 8px;
}

.mobile-quick-search-bar {
  display: none;
}

.mobile-menu-btn {
  display: none;
  align-items: center;
  justify-content: center;
  width: 35px;
  height: 35px;
  font-size: 17px;
  font-weight: 700;
  line-height: 1;
  background: #f1f5f9;
  color: #0f172a;
  border: 1px solid #cbd5e1;
  border-radius: 7px;
  cursor: pointer;
  flex-shrink: 0;
  transition: all 0.2s ease;
}

.mobile-menu-btn:hover {
  background: #e2e8f0;
}

body.dark-mode .mobile-menu-btn {
  background: #1e293b;
  color: #f8fafc;
  border-color: #334155;
}

body.dark-mode .mobile-menu-btn:hover {
  background: #334155;
}

@media (max-width: 900px) {
  .navbar {
    flex-wrap: wrap;
    padding: 8px 12px;
  }

  .title-desktop {
    display: none;
  }

  .title-mobile {
    display: inline;
    font-size: 16px;
    font-weight: 800;
    letter-spacing: 0.4px;
  }

  /* Compact Status Dot instead of '✓ Ready' text */
  .save-indicator {
    width: 10px;
    height: 10px;
    padding: 0;
    border-radius: 50%;
    font-size: 0;
    color: transparent;
    overflow: hidden;
    background: #10b981;
    box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.22);
    flex-shrink: 0;
  }

  .save-indicator.saving {
    background: #f59e0b;
    box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.25);
  }

  .save-indicator.saved {
    background: #10b981;
    box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.25);
  }

  .save-indicator.error {
    background: #ef4444;
    box-shadow: 0 0 0 2px rgba(239, 68, 68, 0.25);
  }

  .mobile-header-actions {
    display: inline-flex;
  }

  .mobile-menu-btn {
    display: inline-flex;
  }

  .mobile-quick-search-bar.open {
    display: flex;
    align-items: center;
    gap: 6px;
    width: 100%;
    margin-top: 8px;
    padding: 6px 8px;
    background: #f8fafc;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
  }

  .mobile-quick-search-bar select {
    padding: 6px 6px;
    font-size: 12px;
    border: 1px solid #cbd5e1;
    border-radius: 5px;
    background: #ffffff;
    color: #0f172a;
    outline: none;
  }

  .mobile-quick-search-bar input {
    flex: 1;
    min-width: 0;
    padding: 6px 9px;
    font-size: 12.5px;
    border: 1px solid #cbd5e1;
    border-radius: 5px;
    background: #ffffff;
    color: #0f172a;
    outline: none;
  }

  .mobile-quick-search-bar button {
    background: transparent;
    border: none;
    color: #64748b;
    font-size: 15px;
    font-weight: 700;
    padding: 4px 6px;
    cursor: pointer;
  }

  body.dark-mode .mobile-quick-search-bar.open {
    background: #131f37;
    border-color: #233554;
  }

  body.dark-mode .mobile-quick-search-bar select,
  body.dark-mode .mobile-quick-search-bar input {
    background: #0b1329;
    border-color: #233554;
    color: #f8fafc;
  }

  /* Hide duplicate search inside 3-bar drawer on mobile since header search is active */
  .nav-right .search-group {
    display: none;
  }

  .nav-right {
    display: none;
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    margin-top: 10px;
    padding: 12px;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.16);
  }

  .nav-right.mobile-open {
    display: flex;
  }

  body.dark-mode .nav-right {
    background: #131f37;
    border-color: #233554;
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.55);
  }

  .nav-right .search-group {
    width: 100%;
    display: flex;
    gap: 6px;
  }

  .nav-right .search-group select {
    width: 36%;
    height: 36px;
  }

  .nav-right .search-input-wrapper {
    flex: 1;
  }

  .nav-right .search-input-wrapper input {
    width: 100%;
    height: 36px;
  }

  .nav-right .btn {
    width: 100%;
    justify-content: center;
    padding: 9px 12px;
    font-size: 13px;
  }
}
