/*
 * This is a manifest file that'll be compiled into application.css.
 *
 * With Propshaft, assets are served efficiently without preprocessing steps. You can still include
 * application-wide styles in this file, but keep in mind that CSS precedence will follow the standard
 * cascading order, meaning styles declared later in the document or manifest will override earlier ones,
 * depending on specificity.
 *
 * Consider organizing styles into separate files for maintainability.
 */

/* master_schedule.css is included via layout stylesheet_link_tag to avoid
  separate @import requests that may 404 when using Propshaft/digested assets */

/* Bulk export styles */
.bulk-export-panel {
  min-height: 200px;
  height: 200px;
  min-width: 100%;
  border: 1px solid #dee2e6;
  border-radius: 4px;
  overflow-y: auto;
}

.selected-panel {
  border: 2px dashed #dee2e6;
  background-color: #f8f9fa;
  padding: 10px;
  min-height: 200px;
  height: 200px;
  min-width: 100%;
}

.drag-handle {
  cursor: grab;
}

.drag-arrow {
  font-size: 2rem;
}

.bulk-export-panel .list-group-item {
  cursor: grab;
}

.bulk-export-panel .list-group-item.dragging {
  opacity: 0.5;
  background-color: #e9ecef;
}

/* For compact badges, keep a small gap and allow the slot to expand vertically */

:root { 
  --slot-action-h: 18px;
  --infobadge-single-h: 23px;
  --slot-single-h: 2.5rem;
  --slot-vert-pad: 0.35rem;
  --slot-row-gap: 0.15rem; /*
  --slot-base: 32px;
  --slot-gap: 4px; */
}

  /* Colour Definitions - using variables rather than CSS classes for better maintainability 
     These will be global to everything on the site found in .container fluid and its children 

    STANDARDIZED COLOR SCHEME
    Grey-tint system with consistent saturation (#6c5c9e baseline)
    All buttons: 0.5rem 1rem padding, 4px border-radius
    All badges: 0.35rem 0.65rem padding, 0.875rem font-size
    Replaces Bootstrap semantic classes (bg-primary, bg-success, etc.)
    ======================================== */

body {
  --pms-color-grey: #6c757d;
  --pms-color-grey-hover: #7c858e;
  --pms-color-dark-grey: #2b2b2b;
  --pms-color-dark-grey-hover: #3a3a3a;
  --pms-color-cyan: #5a7a8c;
  --pms-color-cyan-hover: #6a8a9c;
  --pms-color-blue: #5a7a9c;
  --pms-color-blue-hover: #6a8aac;
  --pms-color-purple: #6c5c9e;
  --pms-color-purple-hover: #7c6cae;
  --pms-color-green: #6c8c6c;
  --pms-color-green-hover: #7c9c7c;
  --pms-color-orange: #8c7c5a;

/* Autocomplete Results */
.autocomplete-results {
  background: white;
  border: 1px solid #dee2e6;
  border-radius: 0.375rem;
  box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
  max-height: 300px;
  overflow-y: auto;
  z-index: 1000;
}

.autocomplete-item {
  padding: 0.5rem 0.75rem;
  cursor: pointer;
  border-bottom: 1px solid #e9ecef;
  transition: background-color 0.15s ease-in-out;
}

.autocomplete-item:last-child {
  border-bottom: none;
}

.autocomplete-item:hover {
  background-color: #f8f9fa;
}

  --pms-color-orange-hover: #9c8c6a;
  --pms-color-yellow: #8c8c5a;
  --pms-color-yellow-hover: #9c9c6a;
  --pms-color-amber: #8c7030;
  --pms-color-amber-hover: #9c8040;
  --pms-color-light-grey: #858c91;
  --pms-color-light-grey-hover: #959ca1;
  --pms-color-blue-grey: #5b7fa6;
  --pms-color-blue-grey-hover: #4a6d92;
  --pms-color-red: #8c5a5a;
  --pms-color-red-hover: #9c6a6a;
  --pms-color-black: #000000;
  --pms-color-black-hover: #343a40;
  --pms-color-white: #ffffff;
  --pms-color-white-hover: #f8f9fa;
  --pms-color-off-white: #dee2e6;
  --pms-color-off-white-hover: #ced4da;
  --pms-color-unassigned: #6c757d;
  --pms-color-unassigned-hover: #5a6268;
  --pms-color-confirmed-blue: #cce5ff;
  --pms-color-confirmed-blue-hover: #b3d7ff;
  --pms-color-dark-blue: #004085;
  --pms-color-dark-blue-hover: #003366;
  --pms-color-bright-green: #28a745;
  --pms-color-bright-green-hover: #1f7f32;
  --pms-color-blue-semi-trans: rgba(13, 110, 253, 0.25);
  --pms-color-blue-semi-trans-hover: rgba(13, 110, 253, 0.35);
  --pms-color-light-green: #d4edda;
  --pms-color-light-green-hover: #c3e6cb;
  --pms-color-dark-green: #155724;
  --pms-color-dark-green-hover: #0e3e1a;
  --pms-color-lighter-green: #c3e6cb;
  --pms-color-lighter-green-hover: #b1d6bb;
  
}

/* Crossover dropdown positioning */

/* The crossover header card must sit above following siblings (sitting-number-bar etc.)
   Bootstrap .card has position:relative but no z-index, so later DOM siblings paint
   on top. An explicit z-index establishes the stacking context needed. */
.card[data-controller="crossover"] {
  position: relative !important;
  z-index: 9000 !important;
  overflow: visible !important;
}

.crossover-dropdown {
  top: 100%;
  left: 0;
  z-index: 99999 !important;
  min-width: 400px;
  -webkit-transform: translateZ(0);
  transform: translateZ(0);
}

/* Ensure crossover switch container has high z-index */
.sitting-header-meta .position-relative {
  z-index: 100000;
  position: relative;
}

.crossover-list {
  max-height: 200px;
  overflow-y: auto;
}

.crossover-list .list-group-item {
  pointer-events: auto;
  cursor: pointer;
}

/* Ensure the wrapper itself accepts pointer events and sits above overlays */
.crossover-dropdown,
.crossover-dropdown * {
  pointer-events: auto !important;
}
.crossover-list .list-group-item {
  position: relative;
  z-index: 100000;
}

/* Modal & contact modal styles (inlined to avoid a separate /assets request and 404 in dev) */
.modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);

  /* Raise modal z-index so it appears above any bootstrap-inserted backdrop. */
  z-index: 1050;
}

.modal.is-open { 
  display: block;
}

.modal .modal-dialog {
  max-width: 900px;
  margin: 3rem auto;
}

.modal .modal-content {
  background: #fff;
  padding: 1rem;
  border-radius: 4px;
  position: relative;
}

.contact-modal .modal-dialog {
  max-width: 95vw !important;
  margin: 2rem auto;
}

/* Ensure contact modals stack above other content without using inline styles */
.contact-modal-zindex {
  z-index: 1100;
}

.fieldset-box {
  border: 1px solid #dee2e6;
  padding: 0.75rem;
  border-radius: 4px;
}

/* Text colors now defined in STANDARDIZED COLOR SCHEME section below */
/* Removed overly broad .btn CSS - Bootstrap handles button styling */
.btn:disabled, .btn.disabled {
  opacity: 0.6;
  cursor: default;
}

/* Close button position for modals (move inline styles into CSS to satisfy CSP) */
.modal .close-btn {
  position: absolute;
  right: 8px;
  top: 8px;
  background: transparent;
  border: 0;
  font-size: 1.2rem;
  line-height: 1;
}

/* Contact modal new-fields hidden by default */
.new-contact-fields {
  display: none;
  margin-top: 8px;
}

.new-contact-fields.visible {
  display: block;
}

/* Duplicate vertical-text rule removed — the canonical .report-table-scroll th.vertical-text rule is defined later in this file */

/* Rotation helper for 90deg headers */
.report-table-scroll th.rotate-90,
.report-table-scroll th.rotate-90 > * {
  transform: rotate(90deg);
  transform-origin: center;
  /* display: inline-block; */
  white-space: nowrap;
  font-size: 0.65rem;
  /* height: 66px; */
}

.report-table-scroll table {
  table-layout: fixed;
}

/* Staff compensation tweaks */
.staff-compensation-table th,
.staff-compensation-table td {
  text-align: center;
}

.staff-compensation-table .standard-commission-col {
  width: 8rem;
  white-space: normal; /* allow break after <br> */
}

.staff-compensation-table .role-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  justify-content: center;
}
.staff-compensation-table .role-badges .pms-badge {
  flex: 0 0 50%;
}

/* Reduce overall table font and cell padding for report tables so many columns fit */
.report-table-scroll table th,
.report-table-scroll table td {
  font-size: 0.62rem;
  padding: 0.12rem 0.18rem;
  vertical-align: middle;
}

/* Column width helpers */
.report-table-scroll th.col-40 { width: 40px; text-align: center; }

.report-table-scroll th.col-location, .report-table-scroll td.col-location {
    text-align: center;
    width: 150px;
}

.report-table-scroll th.col-city, .report-table-scroll td.col-city {
    width: 100px;
    text-align: center;
}

/* Monetary column sizing: make the main money columns a consistent width and prevent wrapping */
.report-table-scroll th.col-portraits, .report-table-scroll td.col-portraits {
    text-align: center;
    width: 4rem; /* reduced from 5rem */
}

/* Generic dollar column sizing (applies to headers like GST/HST and the S&H header) */
.report-table-scroll th.col-dollar {
    width: 4rem;
    white-space: nowrap;
    text-align: center;
}

/* Explicit class for the trailing payment columns (Bal.COD..MC) */
.report-table-scroll th.col-money {
    width: 4rem; /* header centered */
    white-space: nowrap;
    text-align: center;
}
.report-table-scroll td.col-money, .report-table-scroll td.money {
    width: 4rem; /* cells right-aligned */
    white-space: nowrap;
    text-align: right;
}

/* S&H header should be centered despite being a dollar-width column */
.report-table-scroll th.col-dollar.col-sh {
    text-align: center;
}

/* Tax column helpers - allow halving when GST+PST appear */
.report-table-scroll th.col-tax, .report-table-scroll td.col-tax {
    width: 4rem;
    white-space: nowrap;
}
.report-table-scroll th.col-tax.half, .report-table-scroll td.col-tax.half {
    width: 2rem; /* half width when GST+PST are both present */
}

/* Ensure trailing payment columns (Bal.COD..MC) use the standard money width and prevent wrapping. */
.report-table-scroll tbody tr > td.text-end:nth-last-child(-n+6) {
    width: 4rem;
    white-space: nowrap;
    text-align: right;
}
.report-table-scroll thead tr > th.col-money {
    width: 4rem;
    white-space: nowrap;
    text-align: center;
}

/* Ensure trailing payment columns (Bal.COD..MC) use the standard money width and prevent wrapping.
   Use positional selector to cover td cells that may not have been updated with 'col-money'. */
.report-table-scroll tbody tr > td.text-end:nth-last-child(-n+6) {
    width: 4rem;
    white-space: nowrap;
    text-align: right;
}
.report-table-scroll thead tr > th.col-money {
    width: 4rem;
    white-space: nowrap;
    text-align: center;
}

/* Wider Name column for daily reports */
.report-table-scroll th.col-name, .report-table-scroll td.col-name {
    width: 10rem;
    text-align: left;
    padding-left: 0.4rem;
    vertical-align: top;
    vertical-align: middle;
}

/* Inner session table inside Name cell */
.report-table-scroll table.inner-sessions {
  border-collapse: collapse;
  width: 100%;
  border-top: none;
}
.report-table-scroll table.inner-sessions td.session-num {
  width: 30px;
  padding-right: 0.25rem;
  text-align: center;
  white-space: nowrap;
}
/* Only show an internal separator when there are multiple session rows */
.report-table-scroll table.inner-sessions tr:first-child td {
  border-top: none;
  padding-top: 0;
}
.report-table-scroll table.inner-sessions tr + tr td {
  border-top: 1px solid rgba(0,0,0,0.08);
  padding-top: 0.12rem;
}

/* Slightly larger Sitting # column */
.report-table-scroll th.col-sitting, .report-table-scroll td.col-sitting {
  width: 56px;
  text-align: center;
}
.report-table-scroll table.inner-sessions td.family-name {
  padding-left: 0.2rem;
  white-space: normal;
}

.report-table-scroll th.col-retouch, .report-table-scroll td.col-retouch { min-width: 80px; }
.report-table-scroll th.col-net, .report-table-scroll td.col-net { min-width: 100px; }
.report-table-scroll th.col-gst, .report-table-scroll td.col-gst { min-width: 70px; }
.report-table-scroll th.col-total, .report-table-scroll td.col-total { min-width: 100px; }

/* Center group headers */
.report-table-scroll th.group-header { text-align: center; }

/* Reduce cell contents wrapping for numeric cells while allowing long labels to break */
.report-table-scroll table td.text-end { white-space: nowrap; }

.report-table-scroll th.vertical-text {
    /* writing-mode: vertical-rl; */
    transform: rotate(90deg);
    transform-origin: center;
    white-space: nowrap;
    font-size: 0.55rem;
    padding: 0rem 0rem;
    vertical-align: middle;
    line-height: 1;
    text-align: center;
    background: transparent;
}

/* utility cell alignment */
td.count {
    text-align: center;
}

/* Totals label styling (now in Name column) */
.report-table-scroll td.totals-label {
    position: static;
    left: auto;
    z-index: auto;
    background: inherit;
    padding-left: 0.4rem;
    text-align: left;
    min-width: auto;
    width: auto;
    box-shadow: none;
    font-weight: 600;
}

/* Dollar column sizing: set header centered, body right-aligned (PDF override may change this) */
.report-table-scroll th.col-dollar {
    width: 5rem;
    white-space: nowrap;
    text-align: center;
}

/* on-screen report tables should centre their numeric values by default */
.report-table-scroll td.dollar,
.report-table-small td.dollar {
    width: 5rem;
    white-space: nowrap;
    text-align: center; /* override bootstrap right-align via !important rules below */
}

/* ensure all cells in report tables are centred; override explicit classes used for PDF */
.report-table-scroll td,
.report-table-small td,
.report-table-scroll th,
.report-table-small th {
    text-align: center;
}
.report-table-scroll td.text-end,
.report-table-scroll td.dollar,
.report-table-small td.text-end,
.report-table-small td.dollar,
.report-table-scroll th.text-end,
.report-table-small th.text-end {
    text-align: center !important;
}

/* S&H header should be centered despite being a dollar-width column */
.report-table-scroll th.col-dollar.col-sh {
    text-align: center;
}

tr.wk-rpt-hr2 {
    height: 3.5rem;
}


.search-results {
  margin-top: 0.5rem;
  max-height: 240px;
  overflow: auto;
}

.search-result-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.25rem 0;
  border-bottom: 1px solid #dee2e6;
}

.search-result-row span {
  flex: 1;
}

.search-result-row .btn {
  margin-left: 0.5rem;
}

/* Choose-slot page grid helpers */
.choose-slot-page {
  display: none;
}

.choose-slot-page.is-active {
  display: block;
}

/* Admin emulation role select width constraint */
.emulation-select {
  max-width: 300px;
}

/* Lock/Unlock button styling */
.btn-lock-toggle {
  height: 32px;
  border-radius: 6px;
  padding: 4px 12px;
  font-size: 0.875rem;
  line-height: 1.5;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.page-grid {
  display: grid;
  gap: 1rem;
  align-items: start;
}
/* CSP-safe column count helpers for .page-grid. Add classes grid-cols-N where N is 2..12. */
.page-grid.grid-cols-2 {
  grid-template-columns: repeat(2, 1fr);
}

.page-grid.grid-cols-3 {
  grid-template-columns: repeat(3, 1fr);
}

.page-grid.grid-cols-4 {
  grid-template-columns: repeat(4, 1fr);
}

.page-grid.grid-cols-5 {
  grid-template-columns: repeat(5, 1fr);
}

.page-grid.grid-cols-6 {
  grid-template-columns: repeat(6, 1fr);
}

.page-grid.grid-cols-7 {
  grid-template-columns: repeat(7, 1fr);
}

.page-grid.grid-cols-8 {
  grid-template-columns: repeat(8, 1fr);
}

.page-grid.grid-cols-9 {
  grid-template-columns: repeat(9, 1fr);
}

.page-grid.grid-cols-10 {
  grid-template-columns: repeat(10, 1fr);
}

.page-grid.grid-cols-11 {
  grid-template-columns: repeat(11, 1fr);
}

.page-grid.grid-cols-12 {
  grid-template-columns: repeat(12, 1fr);
}

.date-container {
  grid-column: span 2;
}

.date-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
}

.break-row {
  grid-column: 1 / span 2;
  padding: 0.25rem 0;
  text-align: center;
  font-weight: 600;
  background: #f8f9fa;
}

/* small margin helpers */
.mb-05 {
  margin-bottom: 0.5rem;
}

.mt-05 {
  margin-top: 0.5rem;
}

/* appointments_tooltips.css is loaded separately via layout to avoid browser @import 404 */

/* Legacy header styles - kept for backwards compatibility */
.main-header {
  padding: 8px;
  border-bottom: 1px solid #dee2e6;
}

.nav-margin {
  margin-left: 8px;
}

/* PMS Header Styles */
.pms-header {
  background-color: #f8f9fa;
  border-bottom: 2px solid #dee2e6;
}

.pms-title-bar {
  background-color: #343a40;
  color: #ffffff;
  padding: 12px 20px;
  text-align: center;
}

.pms-title {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 600;
}

/* Page-specific title helper */
.page-title {
  padding-left: 20px; /* align with other header spacing */
}

.pms-greeting {
  margin: 4px 0 0 0;
  font-size: 0.9rem;
  font-weight: 400;
  text-align: left;
  padding-left: 20px;
  opacity: 0.9;
}

.pms-nav {
  background-color: var(--pms-color-dark-grey);
  padding: 10px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #dee2e6;
}

.pms-nav:hover {
  background-color: var(--pms-color-dark-grey-hover);
}

.pms-nav-left,.pms-nav-right {
  display: flex;
  gap: 0;
  align-items: center;
}

.pms-nav-btn {
  padding: 8px 16px;
  background-color: #343a40;
  color: #ffffff;
  text-decoration: none;
  border: none;
  border-right: 1px solid #495057;
  cursor: pointer;
  font-size: 0.95rem;
  transition: background-color 0.2s;
  min-width: 140px;
  text-align: center;
}

.pms-nav-btn:first-child {
  border-top-left-radius: 4px;
  border-bottom-left-radius: 4px;
}

.pms-nav-left .pms-nav-btn:last-child, .pms-location-actions-left .pms-nav-btn:last-child {
  border-top-right-radius: 4px;
  border-bottom-right-radius: 4px;
  border-right: none;
}

.pms-nav-right .pms-nav-btn:first-child, .pms-location-actions-right .pms-nav-btn:first-child {
  border-top-left-radius: 4px;
  border-bottom-left-radius: 4px;
}

.pms-nav-right .pms-nav-btn:last-child, .pms-location-actions-right .pms-nav-btn:last-child {
  border-top-right-radius: 4px;
  border-bottom-right-radius: 4px;
  border-right: none;
}

.pms-nav-btn:hover:not(.pms-nav-disabled) {
  background-color: var(--pms-color-dark-grey-hover);
  color: #ffffff;
}

.pms-nav-btn:active:not(.pms-nav-disabled) {
  background-color: #23272b;
}

.pms-nav-disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Navbar spacer for visual separation between button groups */
.pms-nav-spacer {
  width: 20px;
}

/* Consultant Queue column widths and footer formatting */
.cqc1 { width: 13.25rem; }
.cqc2 { width: 14rem; }
.cqc3 { width: 8.571rem; }
/* Center only the Total header; right-align the column cells */
th.cqc3, .table thead th.cqc3, .table-sm thead th.cqc3 { text-align: center !important; }
td.cqc3 { text-align: right !important; }
.cqc4 { width: 10.187rem; }
.cqc5 { width: 11.572rem; }
.cqc6 { width: 11.572rem; }

.total-amt { text-align: right !important; }

tfoot.completed-sittings-table-footer tr td { border-style: none; }


/* Vertical align helper to avoid relying on Bootstrap utilities */
.pms-align-middle th,
.pms-align-middle td {
  vertical-align: middle;
}

/* Indentation helper */
.pms-indent {
  margin-left: 15px;
}

.pms-emulating-badge {
  background-color: #ff8c00;
  color: #fff;
  font-weight: bold;
  cursor: default;
  min-width: 240px;
  white-space: nowrap;
  margin-left: 10px;
}

.pms-emulating-badge:hover {
  background-color: #ff8c00;
  color: #fff;
}

/* Shipping table fixed layout for precise column control */
table.shipping-table-fixed {
  table-layout: fixed !important;
}

/* Shipping table column width classes */
table.shipping-table-fixed th.col-location-30,
table.shipping-table-fixed td.col-location-30 {
  width: 30%;
}

table.shipping-table-fixed th.col-sitting-15,
table.shipping-table-fixed td.col-sitting-15 {
  width: 15%;
}

table.shipping-table-fixed th.col-family-15,
table.shipping-table-fixed td.col-family-15 {
  width: 15%;
}

table.shipping-table-fixed th.col-town-code-15,
table.shipping-table-fixed td.col-town-code-15 {
  width: 15%;
}

table.shipping-table-fixed th.col-ship-to-25,
table.shipping-table-fixed td.col-ship-to-25 {
  width: 25%;
}

table.shipping-table-fixed th.col-actions-30,
table.shipping-table-fixed td.col-actions-30 {
  width: 30%;
}

/* Split Actions column classes */
table.shipping-table-fixed th.col-actions-15,
table.shipping-table-fixed td.col-actions-15 {
  width: 25% !important;
}

table.shipping-table-fixed th.col-actions-blank-15,
table.shipping-table-fixed td.col-actions-blank-15 {
  width: 5% !important;
  text-align: right !important;
}

/* Truck button minimum width to match View badge */
.pms-button.truck-button {
  min-width: 72px;
}

/* Shipping input fields to fill available width */
table.shipping-table-fixed input.shipping-input-full {
  width: 100% !important;
  height: 1.375rem !important;
  margin-bottom: 4px;
  font-size: 0.825em !important;
  box-sizing: border-box !important;
}

/* Clickable card header cursor */
.card-header-clickable {
  cursor: pointer;
}

/* ========================================
   BUTTONS
   ======================================== */

/* Base PMS Button - standardize sizing across variants */
/* Apply base sizing to pms-btn and all existing pms-*-btn classes so markup does not need changing */
.pms-btn {
  /* Use cyan button sizing as the canonical base */
  padding: 0.5rem 1rem; /* top/bottom 8px, left/right 16px */
  border-radius: 4px;
  border-width: 1px;
  border-style: solid;
  cursor: pointer;
  transition: background-color 0.2s;
  text-decoration: none;
  display: inline-block;
  line-height: 1.5;
  color: white !important;
}

/* Small variant for pms buttons */
.pms-btn.btn-sm {
  padding: 0.25rem 0.5rem; /* Bootstrap btn-sm sizing */
  font-size: 0.875rem;
  line-height: 1;
  vertical-align: middle;
}

/* Color variants only define colors and hover states
   Used to define the background and border colors for buttons and badges
*/
.pms-cyan-bg {
  background-color: var(--pms-color-cyan);
}

.pms-cyan-border {
  border-color: var(--pms-color-cyan);
}

.pms-cyan-bg:hover {
  background-color: var(--pms-color-cyan-hover);
}

.pms-cyan-border:hover {
  border-color: var(--pms-color-cyan-hover);
}

.pms-blue-bg {
  background-color: var(--pms-color-blue);
}

.pms-blue-border {
  border-color: var(--pms-color-blue);
}

.pms-blue-bg:hover {
  background-color: var(--pms-color-blue-hover);
}

.pms-blue-border:hover {
  border-color: var(--pms-color-blue-hover);
}

.pms-purple-bg {
  background-color: var(--pms-color-purple);
}

.pms-purple-border {
  border-color: var(--pms-color-purple);
}

.pms-purple-bg:hover {
  background-color: var(--pms-color-purple-hover);
}

.pms-purple-border:hover {
  border-color: var(--pms-color-purple-hover);
}

.pms-amber-bg {
  background-color: var(--pms-color-amber);
  color: #000;
}

.pms-amber-border {
  border-color: #ffa000;
}

.pms-amber-bg:hover {
  background-color: var(--pms-color-amber-hover);
}

.pms-amber-border:hover {
  border-color: #ffb300;
}

.pms-light-grey-bg {
  background-color: var(--pms-color-light-grey);
}

.pms-light-grey-border {
  border-color: var(--pms-color-light-grey);
}

.pms-light-grey-bg:hover {
  background-color: var(--pms-color-light-grey-hover);
}

.pms-light-grey-border:hover {
  border-color: var(--pms-color-light-grey-hover);
}

.pms-blue-grey-bg {
  background-color: var(--pms-color-blue-grey);
  color: #fff;
}

.pms-blue-grey-border {
  border-color: var(--pms-color-blue-grey);
}

.pms-blue-grey-bg:hover {
  background-color: var(--pms-color-blue-grey-hover);
}

.pms-blue-grey-border:hover {
  border-color: var(--pms-color-blue-grey-hover);
}

.pms-green-bg {
  background-color: var(--pms-color-green);
}

.card-header.pms-green-bg {
  background-color: var(--pms-color-green) !important;
}

.pms-green-border {
  border-color: var(--pms-color-green);
}

.pms-green-bg:hover {
  background-color: var(--pms-color-green-hover);
}

.pms-green-border:hover {
  border-color: var(--pms-color-green-hover);
}

.pms-orange-bg {
  background-color: var(--pms-color-orange);
}

.pms-orange-border {
  border-color: var(--pms-color-orange);
}

.pms-orange-bg:hover {
  background-color: var(--pms-color-orange-hover);
}

.pms-orange-border:hover {
  border-color: var(--pms-color-orange-hover);
}

.pms-yellow-bg {
  background-color: var(--pms-color-yellow);
}

.pms-yellow-border {
  border-color: var(--pms-color-yellow);
}

.pms-yellow-bg:hover {
  background-color: var(--pms-color-yellow-hover);
}

.pms-yellow-border:hover {
  border-color: var(--pms-color-yellow-hover);
}

.pms-red-bg {
  background-color: var(--pms-color-red);
}

.pms-red {
  color: var(--pms-color-red);
}

.pms-red-border {
  border-color: var(--pms-color-red);
}

.grand-total.pms-red {
  color: var(--pms-color-red);
}

.grand-total.pms-green {
  color: var(--pms-color-green);
}

.grand-total.text-bright-red {
  color: #ff0000;
}

.pms-red-bg:hover {
  background-color: var(--pms-color-red-hover);
}

.pms-red-border:hover {
  border-color: var(--pms-color-red-hover);
}

.pms-black-bg {
  background-color: var(--pms-color-black);
}

.pms-black-border {
  border-color: var(--pms-color-black);
}

.pms-black-bg:hover {
  background-color: var(--pms-color-black-hover);
}

.pms-black-border:hover {
  border-color: var(--pms-color-black-hover);
}

.pms-unassigned-bg {
  background-color: var(--pms-color-unassigned);
}

.pms-unassigned-border {
  border-color: var(--pms-color-unassigned);
}

.pms-unassigned-bg:hover {
  background-color: var(--pms-color-unassigned-hover);
}

.pms-unassigned-border:hover {
  border-color: var(--pms-color-unassigned-hover);
}

.pms-white-bg {
  background-color: var(--pms-color-white);
}

.pms-white-border {
  border-color: var(--pms-color-white);
}

.pms-white-bg:hover {
  background-color: var(--pms-color-white-hover);
}

.pms-white-border:hover {
  border-color: var(--pms-color-white-hover);
}

.pms-off-white-bg {
  background-color: var(--pms-color-off-white);
}

.pms-off-white-border {
  border-color: var(--pms-color-off-white);
}

.pms-off-white-bg:hover {
  background-color: var(--pms-color-off-white-hover);
}

.pms-off-white-border:hover {
  border-color: var(--pms-color-off-white-hover);
}

.pms-grey-bg {
  background-color: var(--pms-color-grey);
}

.card-header.pms-grey-bg {
  background-color: var(--pms-color-grey) !important;
}

.pms-grey-border {
  border-color: var(--pms-color-grey);
}

.pms-grey-bg:hover {
  background-color: var(--pms-color-grey-hover);
}

.pms-grey-border:hover {
  border-color: var(--pms-color-grey-hover);
}

.pms-dark-grey-bg {
  background-color: var(--pms-color-dark-grey);
}

.pms-dark-grey-border {
  border-color: var(--pms-color-dark-grey);
}

.pms-dark-grey-bg:hover {
  background-color: var(--pms-color-dark-grey-hover);
}

.pms-dark-grey-border:hover {
  border-color: var(--pms-color-dark-grey-hover);
}

.pms-light-red-bg {
  background-color: #ffe0e0;
  color: #777 !important;
  font-weight: bold;
}

.pms-light-red-border {
  border-color: #ffd0d0;
}

.pms-light-red-bg:hover {
  background-color: #ffd0d0;
}

.pms-light-red-border:hover {
  border-color: #ffc0c0;
}

.pms-light-amber-bg {
  background-color: #ffe0b3;
  color: #777 !important;
  font-weight: bold;
}

.pms-light-amber-border {
  border-color: #ffd699;
}

.pms-light-amber-bg:hover {
  background-color: #ffd699;
}

.pms-light-amber-border:hover {
  border-color: #ffcc66;
}



/* Reduce icon spacing inside the back button to keep it compact */
.pms-purple-btn .bi, .pms-btn .bi, .pms-button .bi {
  margin-right: 0.45rem;
  font-size: 0.95em;
}

/* Base PMS Button and Badge (single-class sizing) */
.pms-button {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  min-height: 41.186px; /* standardized height requested */
  padding: 8px 12px; /* proportioned padding */
  border: 0;
  margin: 0;
  border-radius: 4px;
  text-align: center;
  line-height: normal;
  font-size: 0.875rem;
  color: white !important;
  cursor: pointer;
  text-decoration: none;
  box-sizing: border-box;
  flex: 0 0 auto; /* prevent buttons expanding to fill flex containers */
  width: auto !important;
  white-space: nowrap; /* keep content on single line */
}

/* Full-width form wrapper for button_to — overrides pms-button's width:auto !important */
.pms-button-form {
  display: block;
  width: 100%;
}
.pms-button-form .pms-button {
  width: 100% !important;
}

/* Ensure form inputs and buttons get consistent inline-flex behaviour */
button.pms-button, input.pms-button, a.pms-button {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  box-sizing: border-box !important;
}

.pms-button:disabled,
.pms-button[disabled] {
  opacity: 0.45;
  cursor: not-allowed !important;
}

.pms-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  /* Compact badges: smaller height/padding per preference */
  min-height: 18px;
  min-width: 4.5rem;
  padding: 2px 4px !important;
  border-width: 0;
  border-style: none;
  margin: 0;
  border-radius: 4px;
  font-size: 0.75rem;
  color: white;
  box-sizing: border-box;
  align-items: center;
  vertical-align: text-bottom;
} 

.pms-badge-bold {
  font-weight: 700 !important;
}

.pms-badge-muted {
  background-color: #e9ecef;
  color: #6c757d;
}

.email-template-body {
  font-family: monospace;
  font-size: 0.875rem;
  resize: vertical;
}

.email-preview-body {
  font-size: 1rem;
  line-height: 1.6;
  color: #212529;
  padding: 1.5rem;
}

/* Bright, checked-in green used for 'Checked In' badges (brighter than pms-green) */
.pms-checked-in {
  background-color: var(--pms-color-bright-green);
  color: var(--pms-color-white);
}

.pms-checked-in:hover {
  background-color: var(--pms-color-bright-green-hover);
}

/* Grey-variants for badges (kept for backwards-compatible names like pms-grey-cyan, pms-grey-green etc.) */ /*
.pms-grey-cyan {
  background-color: #5a7a8c !important;
  color: white !important;
}

.pms-grey-green {
  background-color: #6c8c6c !important;
  color: white !important;
}

.pms-grey-orange {
  background-color: #8c7c5a !important;
  color: white !important;
}

.pms-grey-red {
  background-color: #8c5a5a !important;
  color: white !important;
}

/* Small hover darkening for grey-variant badges */ /*
.pms-grey-cyan:hover {
  background-color: #4f6f7c !important;
}

.pms-grey-green:hover {
  background-color: #5f7d5f !important;
}

.pms-grey-orange:hover {
  background-color: #7b6b49 !important;
}

.pms-grey-red:hover {
  background-color: #7b4b4b !important;
}*/

/* Navbar buttons */
.pms-navbar {
  background-color: var(--pms-color-dark-grey);
  color: white !important;
  border-radius: 0 !important;
  min-height: 41.186px;
  padding: 8px 12px !important;
  font-size: 1rem;
}
.pms-navbar:hover {
  background-color: var(--pms-color-dark-grey-hover);
}
/* Logout (red) keeps rounded corners */
.pms-navbar.pms-red {
  border-radius: 4px !important;
}
/* Legacy logout alias and padding */
.pms-logout, .pms-logout-btn {
  padding: 0.5rem 1rem !important;
}

/* Sitting actions layout */
.sitting-actions {
  display: inline-block;
}

.sitting-actions-top {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  justify-content: flex-end;
}

.sitting-actions-bottom {
  display: flex;
  gap: 0.75rem;
  justify-content: flex-end;
  margin-top: 6px;
  width: 100%;
}

.btn-group-right {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.sitting-actions .back-button {
  flex: 0 0 auto;
}

.instructions-text { 
  margin: .5rem 1rem 0;
  
  /* padding-left: 2rem; */
  /*font-size: 0. ninerem;*/
  color: #555;
}

/* Text color helpers removed: color-only classes should not set text colour so buttons remain white by default */

/* Crossover search sizing and layout under the location name */
.sitting-header-meta .fw-semibold {
  min-width: 220px;
  max-width: 42%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sitting-header-meta .ms-3 {
  /* Reduce minimum to avoid pushing action buttons onto a new line */
  min-width: 120px;
  max-width: 58%;
}
.sitting-header-meta .crossover-search {
  /* Constrain the search field so it sits inline under the location without forcing layout wrap */
  width: clamp(220px, 20vw, 320px);
  max-width: 100%;
}
.sitting-header-meta .crossover-list {
  min-width: 320px;
  width: 100%;
  box-sizing: border-box;
}
/*
/* Header color helpers (only affect text color, not background) */ /*
.pms-purple-header {
  color: #6c5c9e !important;
}

.pms-blue-header {
  color: #5a7a9c !important;
}

.pms-grey-green-header {
  color: #6c8c6c !important;
}

.pms-grey-cyan-header {
  color: #5a7a8c !important;
}

.pms-cyan-header {
  color: #5a7a8c !important;
}

.pms-green-header {
  color: #6c8c6c !important;
}

.pms-orange-header {
  color: #8c7c5a !important;
}

.pms-red-header {
  color: #8c5a5a !important;
}

/* Header color helpers (text-only) */ /*
.pms-cyan-header {
  color: #5a7a8c !important;
}

.pms-purple-header {
  color: #6c5c9e !important;
}

.pms-blue-header {
  color: #5a7a9c !important;
}

.pms-green-header {
  color: #6c8c6c !important;
}

.pms-orange-header {
  color: #8c7c5a !important;
}

.pms-red-header {
  color: #8c5a5a !important;
}

.pms-grey-green-header {
  color: #6c8c6c !important;
}

.pms-grey-cyan-header {
  color: #5a7a8c !important;
}

/* Form field width utilities for CSP compliance */ /*
.field-width-150 {
  width: 150px;
}

.field-width-120 {
  width: 120px;
}

.field-width-auto {
  width: auto;
}

/* Legacy badge helpers removed — use single-class approach: `.pms-badge` with a color-only class like `.pms-purple` */

/* pms-cyan handled by color variant above (keeps same color/hover only) */

/* Production open page: avoid default accordion blue background so sitting headers match project styling */
.production-open .accordion-button {
  background-color: transparent !important;
  box-shadow: none !important;
  color: inherit !important;
}

.production-open .accordion-header .pms-badge {
  vertical-align: middle;
}

/* pms-orange color variant (sizing handled by base selectors above) */ /*
.pms-orange-btn {
  background-color: #8c7c5a !important;
  border-color: #8c7c5a !important;
}
.pms-orange-btn:hover {
  background-color: #9c8c6a !important;
  border-color: #9c8c6a !important;
}

/* pms-red color variant (sizing handled by base selectors above) */ /*
.pms-red-btn {
  background-color: #8c5a5a !important;
  border-color: #8c5a5a !important;
}
.pms-red-btn:hover {
  background-color: #9c6a6a !important;
  border-color: #9c6a6a !important;
}
/* Crossover dropdown list styling (no reserved space) */
.crossover-list {
  max-height: 240px;
  overflow: auto;
  box-shadow: 0 6px 12px rgba(0,0,0,0.08);
  z-index: 1000;
}

.crossover-search {
  max-width: 420px;
}

/* Full-width sitting number bar */
/* Explicit stacking context so crossover card (z-index: 9000) wins */
.sitting-number-bar {
  position: relative;
  z-index: 1;
  background-color: #5a7a9c;
  color: white;
  padding: 12px 16px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Left text and right actions layout with flexbox */
.sitting-number-bar .sitting-number {
  flex: 1;
  min-width: 0;
}

/* Ensure status text uses the same color as the sitting number (not muted) */
.sitting-number .sitting-status {
  color: inherit !important;
  opacity: 1 !important;
}
.sitting-number-bar .sitting-actions {
  flex-shrink: 0;
  margin-left: 8px;
}

.sitting-number-bar.pms-purple-bg {
  background-color: var(--pms-color-purple);
}

.sitting-number-bar.pms-purple-bg:hover {
  background-color: var(--pms-color-purple);
}

.sitting-number-bar.pms-green-bg {
  background-color: var(--pms-color-green);
}

.sitting-number-bar.pms-green-bg:hover {
  background-color: var(--pms-color-green);
}

.sitting-number-bar.pms-orange-bg {
  background-color: var(--pms-color-orange);
}

.sitting-number-bar.pms-orange-bg:hover {
  background-color: var(--pms-color-orange);
}

.sitting-number-bar.pms-red-bg {
  background-color: var(--pms-color-red);
}

.sitting-number-bar.pms-red-bg:hover {
  background-color: var(--pms-color-red);
}

.sitting-number-bar.pms-grey-bg {
  background-color: #6c757d;
}

.sitting-number-bar.pms-grey-bg:hover {
  background-color: #6c757d;
}

.sitting-number {
  font-size: 1.25rem;
  font-weight: 600;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Ensure action badges stay inline */
.sitting-number-bar .sitting-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.sitting-number-bar .sitting-actions .pms-badge {
  white-space: nowrap;
}

.sitting-number-bar form {
  margin: 0;
  padding: 0;
}

.sitting-number-bar .pms-badge {
  line-height: 1;
}

/* Sitting header font sizing to match main text */
.sitting-header-date {
  font-size: 1.125rem; /* roughly matches h5/main text */
  font-weight: 600;
}

.sitting-header-meta {
  font-size: 1rem;
  color: #333;
}

/* Strong overrides to prevent descender clipping and ensure single-line layout */
.sitting-number-bar {
  overflow: visible !important;
}

.sitting-number {
  line-height: 1.4 !important;
  padding-bottom: 2px !important;
}

.sitting-number-bar .pms-badge {
  line-height: 1.25 !important;
}

/* Activity content collapsed state (avoid inline styles) */
.activity-content {
  transition: max-height 0.25s ease;
  overflow: hidden;
}
.activity-content.collapsed {
  max-height: 40px;
}

.pms-red-btn:hover {
  background-color: #9c6a6a !important;
  border-color: #9c6a6a !important;
  color: white !important;
}

/* Very Dark: Navbar/Action buttons */
.pms-dark-btn {
  background-color: #343a40 !important;
  border-color: #343a40 !important;
  color: white !important;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  border: 1px solid #343a40;
  cursor: pointer;
  transition: background-color 0.2s;
  text-decoration: none;
  display: inline-block;
  line-height: 1.5;
}

.pms-dark-btn:hover {
  background-color: #495057 !important;
  border-color: #495057 !important;
  color: white !important;
}

/* Legacy button class aliases (for backwards compatibility) */
.pms-grey-green-btn {
  background-color: #6c8c6c !important;
  border-color: #6c8c6c !important;
  color: white !important;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.2s;
  text-decoration: none;
  display: inline-block;
  line-height: 1.5;
}

.pms-grey-green-btn:hover {
  background-color: #7c9c7c !important;
  border-color: #7c9c7c !important;
  color: white !important;
}

.pms-grey-cyan-btn {
  background-color: #5a7a8c !important;
  border-color: #5a7a8c !important;
  color: white !important;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.2s;
  text-decoration: none;
  display: inline-block;
  line-height: 1.5;
}

.pms-grey-cyan-btn:hover {
  background-color: #6a8a9c !important;
  border-color: #6a8a9c !important;
  color: white !important;
}

.location-update-btn {
  background-color: #343a40;
  color: #ffffff;
  border: 1px solid #343a40;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.2s;
  text-decoration: none;
  display: inline-block;
  line-height: 1.5;
}

.location-update-btn:hover {
  background-color: #495057;
  color: #ffffff;
}

.location-cancel-btn {
  background-color: #6c757d;
  color: #ffffff !important;
  border: 1px solid #6c757d;
}

.location-cancel-btn:hover {
  background-color: #495057;
  border-color: #495057;
  color: #ffffff !important;
}

.pms-delete-btn {
  background-color: #8c5a5a;
  color: #ffffff;
  border: 1px solid #8c5a5a;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.2s;
  text-decoration: none;
  display: inline-block;
  line-height: 1.5;
}

.pms-delete-btn:hover {
  background-color: #9c6a6a;
  color: #ffffff;
}

.pms-logout-btn {
  background-color: #8c5a5a;
  border: 1px solid #8c5a5a;
  color: #ffffff;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.2s;
  box-shadow: none;
}

.pms-logout-btn:hover {
  background-color: #9c6a6a;
  border-color: #9c6a6a;
}

/* ========================================
   BADGES (Replaces Bootstrap semantic badges)
   ======================================== */

/* Consent / small circular indicator used in photographer view */
.consent-indicator {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
}

/* Highlighted text for spouse names and consent headings */
.session-spouse-name {
  font-size: 1.125rem;
  font-weight: 700;
}

.consent-heading {
  font-size: 1.125rem;
  font-weight: 700;
  display: inline-block;
  margin-right: 0.5rem;
}

/* Family heading styling */
.family-heading {
  font-weight: 700;
  font-size: 1.125rem;
}

/* subtle divider used between directory and roster sections */
.consent-divider {
  border-top: 1px solid #e9ecef;
  margin-top: 0.5rem;
  margin-bottom: 0.5rem;
}

/* Consent grid adjustments: make first column slightly narrower so the two columns are closer */
@media (min-width: 768px) {
  .consent-grid > .col-md-6:nth-child(odd) {
    flex: 0 0 30% !important;
    max-width: 30% !important;
  }
  .consent-grid > .col-md-6:nth-child(even) {
    flex: 0 0 70% !important;
    max-width: 70% !important;
  }
}
/* Grey-Purple: Photographer role, Incomplete todos, Back navigation context */
.pms-purple-badge {
  background-color: #6c5c9e !important;
  color: white !important;
  padding: 0.35rem 0.65rem;
  font-size: 0.875rem;
  border-radius: 4px;
}

/* Grey-Blue: Primary info, Session counts, Location counts (replaces bg-primary) */
.pms-blue-badge {
  background-color: #5a7a9c !important;
  color: white !important;
  padding: 0.25rem 0.5rem !important;
  font-size: 0.75rem !important;
  border-radius: 0.25rem !important;
  display: inline-block !important;
  text-align: center !important;
  white-space: nowrap !important;
  vertical-align: baseline !important;
  border: none !important;
  line-height: 1 !important;
  font-weight: 700 !important;
  min-width: 60px !important;
}

/* Grey-Green: Consultant role, Complete todos, Totals, Active status (replaces bg-success) */
.pms-green-badge {
  background-color: #6c8c6c !important;
  color: white !important;
  padding: 0.35rem 0.65rem;
  font-size: 0.875rem;
  border-radius: 4px;
}

/* Grey-Cyan: Info badges, Period types, Events (replaces bg-info) */
.pms-cyan-badge {
  background-color: #5a7a8c !important;
  color: white !important;
  padding: 0.25rem 0.5rem !important;
  font-size: 0.75rem !important;
  border-radius: 0.25rem !important;
  display: inline-block !important;
  text-align: center !important;
  white-space: nowrap !important;
  vertical-align: baseline !important;
  border: none !important;
  line-height: 1 !important;
  font-weight: 700 !important;
}

/* Grey: Standard neutral badges */ /*
.pms-grey-badge {
  background-color: #6c757d !important;
  color: white !important;
  padding: 0.25rem 0.5rem !important;
  font-size: 0.75rem !important;
  border-radius: 0.25rem !important;
  /*display: inline-block !important;*/ /*
  text-align: center !important;
  white-space: nowrap !important;
  vertical-align: baseline !important;
  border: none !important;
  line-height: 1 !important;
  font-weight: 700 !important;
} */

.appointment-info {
    width: 100%;
    padding: .25rem .25rem !important;
    vertical-align: middle;
    font-weight: 700; 
} 


/* Photo Schedule Table Rules */

.slots-columns {
    display: flex;
    flex-direction: column;
    gap: 0;
}

table.schedule-table {
    table-layout: fixed;
    border-collapse: separate;
    width: 100%;
    height: 100%;
    margin-bottom: 0;
}

.schedule-table-cell {
    vertical-align: top;
    padding: 0.25rem;
}

td.empty-offset {
    border: none;
    background: transparent;
}

table.slot-item-table {
    width: 100%;
    border-collapse: separate;
    border-style: solid;
    border-width: 1px;
    border-radius: 0.375rem;
    table-layout: fixed;
    height: 100%;
}

td.slot-item-table-left.slot-time {
    width: 10%;
    text-align: left;
    padding-left: 0.5rem;
    height: 100%;
}

td.slot-item-table-center {
    text-align: center;
}

table.appointment-info {
    display: table;
    margin: 0.25rem;
}

table.appointment-info td {
    flex-shrink: 0;
    text-align: left;
    width: 20%;
    padding: 0.25rem 0.5rem;
}

table.appointment-info .appt-count {
    text-align: center;
}

.appointment-info .appt-phone {
    text-align: right;
}

td.slot-item-table-right.slot-actions {
    width: 25%;
    text-align: right;
}

td.slot-item-table-left.slot-time.v-align-top {
    vertical-align: top;
    padding-top: 0.375rem;
}

.badge {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 0.25rem 0.5rem !important;
  border-radius: 0.25rem !important;
  font-weight: 700 !important;
  color: white !important;
}

/* Legacy background utilities mapped to PMS colors */
.bg-success {
  background-color: #6c8c6c !important;
}

.bg-primary {
  background-color: #5a7a9c !important;
}

.bg-info {
  background-color: #5a7a8c !important;
}

.bg-warning {
  background-color: #8c7c5a !important;
}

.bg-danger {
  background-color: #8c5a5a !important;
}

/* Light-opacity variants (used in schedule backgrounds) */
.bg-primary.bg-opacity-10 {
  background-color: rgba(90,122,156,0.10) !important;
}

.bg-success.bg-opacity-10 {
  background-color: rgba(108,140,108,0.10) !important;
}

.bg-warning.bg-opacity-10 {
  background-color: rgba(140,124,90,0.10) !important;
}

.bg-danger.bg-opacity-10 {
  background-color: rgba(140,90,90,0.10) !important;
}

.bg-info.bg-opacity-10 {
  background-color: rgba(90,122,140,0.10) !important;
}

.bg-secondary.bg-opacity-10 {
  background-color: rgba(108,108,108,0.06) !important;
}


/* Grey-Orange: Warning badges, Required items, Pending (replaces bg-warning) */
.pms-orange-badge {
  background-color: #8c7c5a !important;
  color: white !important;
  padding: 0.35rem 0.65rem;
  font-size: 0.875rem;
  border-radius: 4px;
}

/* Grey-Red: Danger badges, Unavailable, Error states (replaces bg-danger) */
.pms-red-badge {
  background-color: #8c5a5a !important;
  color: white !important;
  padding: 0.25rem 0.5rem !important;
  font-size: 0.75rem !important;
  border-radius: 0.25rem !important;
  display: inline-block !important;
  text-align: center !important;
  white-space: nowrap !important;
  vertical-align: baseline !important;
  border: none !important;
  line-height: 1 !important;
  font-weight: 700 !important;
  min-width: 60px !important;
}

/* Legacy badge aliases (for backwards compatibility) */
/* Legacy bg-grey-blue class removed - use pms-badge pms-blue instead */
.pms-grey-green-badge {
  background-color: #6c8c6c !important;
  color: white !important;
  padding: 0.35rem 0.65rem;
  font-size: 0.875rem;
  border-radius: 4px;
}

.pms-grey-orange-badge {
  background-color: #8c7c5a !important;
  color: white !important;
  padding: 0.35rem 0.65rem;
  font-size: 0.875rem;
  border-radius: 4px;
}

.pms-grey-red-badge {
  background-color: #8c5a5a !important;
  color: white !important;
  padding: 0.35rem 0.65rem;
  font-size: 0.875rem;
  border-radius: 4px;
}

/* ========================================
   TEXT COLORS (Replaces Bootstrap text utilities)
   ======================================== */

.pms-text-blue {
  color: var(--pms-color-blue) !important;
}

/* Notes offcanvas width */
.notes-offcanvas-wide {
  width: 650px !important;
}

.notes-history-scroll {
  max-height: 300px;
  overflow-y: auto;
}

.pms-text-green {
  color: var(--pms-color-dark-green) !important;
  text-decoration: none !important;
}

.pms-text-red {
  color: #8c5a5a !important;
}

.pms-text-orange {
  color: #8c7c5a !important;
}

.pms-text-cyan {
  color: #5a7a8c !important;
}

/* Town Code styling: white background with coloured text */
.town-code {
  background: #ffffff;
  border: 1px solid #dee2e6;
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  font-weight: 600;
  display: inline-block;
}

/* Override old Bootstrap text classes */
.text-success {
  color: #6c8c6c !important;
}

.text-danger {
  color: #8c5a5a !important;
}

.text-warning {
  color: #8c7c5a !important;
}

.text-info {
  color: #5a7a8c !important;
}

/* ========================================
   LIGHT BACKGROUNDS (Tints for hover/selected states)
   ======================================== */

.pms-bg-blue-light {
  background-color: #e7f1ff !important;
}

.pms-bg-green-light {
  background-color: #e8f5e9 !important;
}

.pms-bg-orange-light {
  background-color: #fff3cd !important;
}

/* Special Purpose Colors */
.pms-emulating-badge {
  background-color: #ff8c00 !important;
  color: white !important;
  padding: 0.35rem 0.65rem;
  font-size: 0.875rem;
  border-radius: 4px;
}

.current-time-indicator {
  background-color: #dc3545 !important;
}

/* Collapsible card header chevron rotation */
.cursor-pointer {
  cursor: pointer;
}

.card-header.collapsed .bi-chevron-down {
  transform: rotate(-90deg);
  transition: transform 0.2s ease;
}

.card-header:not(.collapsed) .bi-chevron-down {
  transform: rotate(0deg);
  transition: transform 0.2s ease;
}

/* Location notes nav tabs styling */
.location-notes-tabs .nav-link {
  color: #6c7a89;
  background-color: transparent;
  border: none;
  transition: color 0.2s;
}

.location-notes-tabs .nav-link:hover {
  color: #5a6775;
}

.card-header-tabs.location-notes-tabs .nav-link.active {
  color: #212529;
  background-color: #fff;
  border-bottom: 3px solid #343a40 !important;
  border-color: transparent transparent #343a40 transparent !important;
}

/* Location show page action buttons */
.pms-location-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 40px;
  margin-bottom: 40px;
  padding-top: 20px;
  border-top: 2px solid #dee2e6;
}

.pms-location-actions-left {
  display: flex;
  gap: 10px;
  align-items: center;
}

.pms-location-actions-right {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-left: auto;
}

.pms-delete-location-btn {
  font-size: 1rem;
}

/* Contact table sortable links */
.contact-table th a {
  color: #5a7a8c;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.contact-table th a:hover {
  color: #6a8a9c;
  text-decoration: none;
}

.contact-table .phone-link {
  color: #5a7a8c;
  text-decoration: none;
}

.contact-table .phone-link:hover {
  color: #6a8a9c;
  text-decoration: underline;
}

/* Ensure badges align properly in table cells */
.contact-table .badge {
  vertical-align: middle !important;
  line-height: 1.5;
}

/* Tax rate actions styling */
.tax-rate-actions {
  display: inline-flex;
  gap: 0.25rem;
  align-items: center;
  min-width: 200px;
}

.tax-rate-actions .badge {
  flex: 0 0 auto;
}

.pms-icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* Clickable badge styling */
.clickable-badge {
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  vertical-align: middle;
  line-height: 1;
}

/* Ensure all badges have consistent vertical alignment */
.badge,
a.badge,
span.badge,
button.badge,
input[type="submit"].badge,
form button.badge {
  display: inline-block !important;
  padding: 0.25rem 0.5rem !important;
  font-size: 0.75rem !important;
  font-weight: 700 !important;
  line-height: 1 !important;
  text-align: center !important;
  white-space: nowrap !important;
  vertical-align: baseline !important;
  border-radius: 0.25rem !important;
  border: none !important;
  cursor: pointer !important;
  height: auto !important;
  min-height: 0 !important;
  max-height: none !important;
}

/* Remove default button styling when button is styled as a badge */
button.badge,
input[type="submit"].badge,
form button.badge {
  background: none !important;
  font-family: inherit !important;
  margin: 0 !important;
  box-shadow: none !important;
}

button.badge:hover,
a.badge:hover,
span.badge:hover {
  opacity: 0.9;
  text-decoration: none !important;
}

/* Standard Bootstrap-like small buttons */
.btn-sm {
  padding: 0.25rem 0.5rem;
  font-size: 0.875rem;
  line-height: 1.5;
}

.clickable-slot {
  cursor: pointer;
  flex: 1;
}

.hidden-indicator {
  display: none;
}

.activity-content {
  overflow: hidden;
  position: relative;
}

.activity-content.collapsed {
  max-height: 40px;
}

.activity-content.collapsed::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 40px;
  background: linear-gradient(to bottom, transparent, white);
}

.show-more-btn {
  cursor: pointer;
  color: #6c757d;
  font-size: 0.875rem;
  margin-top: 0.5rem;
  text-decoration: none;
  display: inline-block;
}

.show-more-btn:hover {
  color: #495057;
  text-decoration: underline;
}

/* Text color */
.text-danger {
  color: red;
}

.text-success {
  color: green;
}

.text-muted {
  color: #666;
}

/* Margin and padding */
.mt-10 {
  margin-top: 10px;
}

.mt-14 {
  margin-top: 14px;
}

.mt-20 {
  margin-top: 20px;
}

.mt-30 {
  margin-top: 30px;
}

.m-10-0 {
  margin: 10px 0;
}

.mr-10 {
  margin-right: 10px;
}

/* Fieldset and border boxes */
.fieldset-box {
  margin: 20px 0;
  padding: 15px;
  border: 1px solid #ccc;
}

/* Dashboard-specific tweaks: make 4-up cards fill the row and appear wider */
.dashboard-grid .row {
  --bs-gutter-x: 1rem;
  --bs-gutter-y: 1rem;
  margin-bottom: 0;
}

/* Force the first row to be exactly four equal columns that fill the row */
.dashboard-grid .dashboard-first-row {
  display: flex;
  flex-wrap: wrap;
}

.dashboard-grid .dashboard-first-row .col-md-3 {
  display: flex;
  flex-direction: column;
}

/* Make all cards in the first row equal height */
.dashboard-grid .dashboard-first-row .border-box {
  flex: 1;
}

/* Shared card style for all dashboard cards */
.dashboard-grid .border-box {
  border: 1px solid #ddd;
  padding: 20px;
  border-radius: 6px;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.dashboard-grid .border-box h3 {
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
}

/* Locations card: gap between Manage Locations and Bulk Import/Export */
.dashboard-locations-actions {
  margin-top: 0.75rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.dashboard-locations-actions .dashboard-manage-btn {
  width: 100%;
}

/* Ensure small screens keep adequate spacing */
@media (max-width: 991px) {
  .dashboard-grid .row {
    --bs-gutter-x: 0.75rem;
    --bs-gutter-y: 0.75rem;
  }
}

/* Generic fallback for other border-box usages */
.border-box {
  border: 1px solid #ddd;
  padding: 15px;
  border-radius: 5px;
}

/* Display */
.d-block {
  display: block;
}

.d-flex {
  display: flex;
  gap: 12px;
  margin-top: 10px;
}

.d-none {
  display: none;
}

/* Timezone selector container sizing (CSP-safe; avoid inline styles) */
.tz-container {
  max-width: 480px;
}

/* Opacity */
.opacity-60 {
  opacity: 0.6;
}

.opacity-100 {
  opacity: 1;
}

/* Ensure bootstrap/backdrop elements sit below the modal dialog but above page content */
.modal-backdrop {
  z-index: 1040;
}

/* Utility to prevent body scroll when modal is open (CSP-safe) */
.no-scroll {
  overflow: hidden !important;
}

/* Flex */
.flex-1 {
  flex: 1;
}

.flex-2 {
  flex: 2;
}

/* Dashboard wrapper: use block layout so rows and floats behave predictably for 4-up layout */
.dashboard-grid {
  display: block;
  margin-top: 0;
}

/* Tooltip styles moved to appointments_tooltips.css */

.pms-booked {
  border-width: 2px;
  background:  var(--pms-color-light-green); /*  /* light green */  
  color: var(--pms-color-dark-green); /* #155724 dark green text for contrast */ 
  border-color: var(--pms-color-lighter-green);/* #c3e6cb; */
  cursor: default;
  opacity: 1;
}

.pms-open {
  background-color: transparent;
}

.pms-open.past {

  border-width: 0px;
}

.pms-booked.past {

  background-color: color-mix(in srgb, var(--pms-color-light-green) 85%, var(--bs-red) 15%); /* very light green tint for past booked slots */
}

.pms-booked.past:hover {

  background-color: color-mix(in srgb, var(--pms-color-light-green-hover) 85%, var(--bs-red) 15%); /* very light green tint for past booked slots */
}
.pms-booked:hover {
  border-color: var(--pms-color-lighter-green-hover); /* #b1dfbb; */
  background: var(--pms-color-light-green-hover); /* #d4edda; */
  color: var(--pms-color-dark-green-hover); /* #0f5132 */
}

/* Confirmed appointments get darker blue border */
.pms-confirmed.past {

  background-color: color-mix(in srgb, var(--pms-color-confirmed-blue) 80%,var(--bs-orange) 25%); /* very light blue tint for past confirmed slots */
}

.pms-confirmed.past:hover {

  background-color: color-mix(in srgb, var(--pms-color-confirmed-blue-hover) 80%,var(--bs-orange) 25%); /* very light blue tint for past confirmed slots */
}

.pms-confirmed {
  border-width: 2px;
  border-color: var(--pms-color-blue-semi-trans);
  background: var(--pms-color-confirmed-blue);
  color: var(--pms-color-dark-blue);
}

.pms-confirmed:hover {
  border-color: var(--pms-color-blue-semi-trans-hover);
  background: var(--pms-color-confirmed-blue-hover);
  color: var(--pms-color-dark-blue-hover);
}

.slot-item .slot-time {
  font-weight: 600;
  font-size: 0.96rem;
}

.slot-item.available:hover { box-shadow: 0 3px 8px rgba(11,81,50,0.06); }

.slot-break {
  grid-column: 1 / -1;
  background: var(--pms-color-grey);
  color: var(--pms-color-white);
  padding: 0.35rem 0.75rem;
  padding-left: 0.5rem;
  padding-right: 0.5rem;
  border-radius: 0.375rem;
  text-align: center;
  font-weight: 600;
  box-shadow: 0 1px 2px rgba(var(--pms-color-black),0.06);
  margin: 0.5rem 0;
  max-width: 100%;
  box-sizing: border-box;
}

.badge {
  font-weight: 700 !important;
}

.slot-item .slot-meta {
  opacity: 0.85;
}

@media (max-width: 576px) {
  .slots-grid { grid-template-columns: 1fr; }
}

*/
.slot-item-table > tbody > tr > td.slot-time { 
  /*width: 10%;
  padding-left: 0.5rem; */
  font-weight: 700; 
}

/* Booking date arrival/departure times */ 
.setup-teardown-time {
  color: #6c8c9f;
}

/* Appointment length indentation */
.appointment-length-indent {
  display: inline-block;
}

/* Booking dates table styling */
.booking-dates-table {
  margin-bottom: 0;
}

.booking-dates-table tbody tr {
  border-bottom: 1px solid #dee2e6;
}

.booking-dates-table tbody tr:hover {
  background-color: #f8f9fa;
}

.booking-dates-table td {
  padding: 0.75rem;
  vertical-align: top;
  border-top: none;
}

.booking-dates-table .buttons-cell {
  white-space: nowrap;
}

/* Booking History */
.booking-history-summary {
  font-size: 0.9rem;
}

.booking-history-table thead th {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: #6c757d;
  border-bottom: 2px solid #dee2e6;
}

.booking-history-table tbody tr:hover {
  background-color: #f8f9fa;
}

/* Main Menu Grid Styles */
.main-menu-title {
  text-align: center;
}

.main-menu-welcome-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 40px 20px 20px 20px;
}

.main-menu-welcome-bar > * {
  flex: 0 0 auto;
}

.main-menu-welcome-bar p {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

.main-menu-wrapper {
  max-width: 50vw;
  margin: 0 auto 40px auto;
  padding: 0 20px;
}

.main-menu-container {
  max-width: 100%;
  margin: 0;
}

.main-menu-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  row-gap: 20px;
  column-gap: 10px;
}

.main-menu-grid.wide-last-two {
  grid-template-columns: repeat(6, 1fr);
  column-gap: 10px;
}

.main-menu-grid.wide-last-two .menu-cell {
  grid-column: span 2;
}

.main-menu-grid.wide-last-two .menu-cell-wide {
  grid-column: 1 / -1;
}

.main-menu-grid.wide-last-two .menu-cell-half {
  grid-column: span 3;
}

.menu-cell {
  height: 100px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9em;
  text-decoration: none;
}

.menu-cell-wide {
  grid-column: 1 / -1;
  aspect-ratio: auto;
  height: 100px;
  font-size: 1em;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

.menu-cell-half {
  aspect-ratio: auto;
  height: 100px;
  font-size: 0.95em;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

.main-menu-footer {
  text-align: center;
  margin-top: 40px;
}

/* Login Page Styles */
.login-container {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 80vh;
  padding: 20px;
}

.login-box {
  width: 100%;
  max-width: 400px;
  padding: 40px;
  background-color: #fff;
  border: 1px solid #dee2e6;
  border-radius: 4px;
}

.login-title {
  text-align: center;
  margin-bottom: 30px;
  font-size: 1.8em;
  color: #343a40;
}

.login-subtitle {
  text-align: center;
  margin-top: -20px;
  margin-bottom: 24px;
  font-size: 0.95em;
  color: #6c757d;
}

.login-hint {
  margin: 4px 0 8px;
  font-size: 0.85em;
  color: #6c757d;
}

.login-links {
  margin-top: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.login-link {
  font-size: 0.9em;
  color: #0d6efd;
  text-decoration: none;
}

.login-link:hover {
  text-decoration: underline;
}

.login-field {
  margin-bottom: 20px;
}

.login-field label {
  display: block;
  margin-bottom: 8px;
  font-weight: 500;
  color: #495057;
}

.login-input {
  width: 100%;
  padding: 10px 12px;
  font-size: 1em;
  border: 1px solid #ced4da;
  border-radius: 4px;
  box-sizing: border-box;
}

.login-input:focus {
  outline: none;
  border-color: #80bdff;
  box-shadow: 0 0 0 0.2rem rgba(0,123,255,.25);
}

.password-field-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.password-input-with-toggle {
  padding-right: 45px;
}

.password-toggle-btn {
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 45px;
  background: none;
  border: none;
  cursor: pointer;
  color: #6c757d;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.2s ease;
}

.password-toggle-btn:hover {
  color: #495057;
}

.password-toggle-btn:focus {
  outline: none;
  color: #0066cc;
}

.password-toggle-btn i {
  font-size: 1.1rem;
}

.login-field-checkbox {
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.login-actions {
  margin-top: 30px;
  margin-bottom: 20px;
}

.login-actions .pms-nav-btn {
  width: 100%;
  padding: 12px;
  font-size: 1.1em;
}

/* Active status indicator - richer grey-blue */
.list-group-item.active {
  background-color: #3d5a7a !important;
  border-color: #3d5a7a !important;
  color: white !important;
}

.list-group-item.active:hover {
  background-color: #4d6a8a !important;
  border-color: #4d6a8a !important;
  color: white !important;
}

/* Cheque tracking checkbox styles */
.cheque-received-checkbox {
  width: 1.25em;
  height: 1.25em;
  cursor: pointer;
  border: 2px solid #6c757d;
}

.cheque-received-checkbox:checked {
  background-color: #198754;
  border-color: #198754;
}

.cheque-received-checkbox:disabled {
  opacity: 0.6;
  cursor: wait;
}

/* Cash tracking scroll container */
.cash-tracking-scroll {
  max-height: 400px;
  overflow-y: auto;
}

/* Footer spacer for all pages */
.footer-spacer {
  height: 100px;
  flex-shrink: 0;
}

/* Main footer styling */
.pms-footer {
  padding-top: 2rem;
  position: relative; /* ensure footer participates in normal flow */
  z-index: 0;          /* sit beneath page content */
  background-color: #fff; /* ensure it has an opaque background */
}

/* Ensure standard cards sit above the footer so their backgrounds are never overlaid */
.card {
  position: relative;
  z-index: 1;
}

/* Make body a column flex container so footer sits at bottom naturally */
html, body {
  height: 100%;
}
body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  background-color: #f8f9fa; /* page background to separate from footers/cards */
}

/* The main content area should expand to fill available space, pushing footer down */
.app-content {
  flex: 1 1 auto;
  width: 100%;
  padding-bottom: 1rem; /* give breathing room before footer */
}

/* Footer styling improvements */
.pms-footer {
  padding-top: 1rem;
  padding-bottom: 1rem;
  position: relative; /* ensure footer participates in normal flow */
  z-index: 0;          /* sit beneath page content */
  background-color: #ffffff; /* ensure it has an opaque background */
  border-top: 1px solid #e9ecef;
  width: 100%;
}

.pms-footer .container-fluid {
  text-align: left; /* match rest of the site */
  color: #6c757d;
  font-size: 0.9rem;
}


/* Session collapse styling */
.card-header[data-bs-toggle="collapse"] {
  transition: background-color 0.2s;
}

.card-header[data-bs-toggle="collapse"]:hover {
  background-color: rgba(0, 0, 0, 0.03);
}

.card-header h5[data-bs-toggle="collapse"]:hover {
  background-color: rgba(0, 0, 0, 0.03);
}

.card-header[data-bs-toggle="collapse"] .bi-chevron-down,
.card-header h5[data-bs-toggle="collapse"] .bi-chevron-down {
  transition: transform 0.3s ease;
  display: inline-block;
  transform: rotate(-90deg); /* Default collapsed state: point right */
}

.card-header[data-bs-toggle="collapse"]:not(.collapsed) .bi-chevron-down,
.card-header h5[data-bs-toggle="collapse"]:not(.collapsed) .bi-chevron-down {
  transform: rotate(0deg); /* Expanded state: point down */
}

.card-header[data-bs-toggle="collapse"].collapsed .bi-chevron-down,
.card-header h5[data-bs-toggle="collapse"].collapsed .bi-chevron-down {
  transform: rotate(-90deg); /* Collapsed state: point right */
}

/* Session header with directory selection form */
.session-header-with-directory {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: nowrap;
}

.session-header-with-directory .session-title {
  cursor: pointer;
  flex: 0 0 auto;
}

.session-header-with-directory .directory-controls {
  flex: 0 0 auto;
  margin: 0;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.session-header-with-directory .directory-controls span {
  white-space: nowrap;
  font-size: 0.875rem;
  margin: 0;
  padding: 0;
}

.session-header-with-directory .directory-controls input.directory-input {
  width: 60px;
  height: 30px;
  padding: 0.25rem 0.5rem;
  border: 1px solid #dee2e6;
  border-radius: 0.25rem;
  margin: 0;
}

.session-header-with-directory .directory-controls .pms-badge {
  margin: 0;
}

.session-header-with-directory .directory-controls form {
  margin: 0;
  padding: 0;
  display: inline;
}

/* Generic toggle icon styling for replaced +/- icons */
.toggle-icon {
  display: inline-block;
  transition: transform 0.15s ease-in-out;
  color: #6c757d;
  margin-right: 0.5rem;
  font-weight: 700;
}

/* Rotate class for chevrons */
.toggle-icon.rotate-90 {
  transform: rotate(90deg);
}

/* Ensure contrast on darker headers */
.card-header.text-white .toggle-icon,
.card-header.bg-secondary .toggle-icon,
.card-header.pms-purple-bg .toggle-icon {
  color: #ffffff !important;
}

/* Order form shipping input group */
.order-shipping-input {
  width: 150px;
  margin-left: auto;
}

/* Order form payment method input groups */
.order-payment-input {
  max-width: 120px;
}

/* Order form summary input groups (subtotal, retouch, shipping) - all same width */
.order-summary-input {
  width: 150px;
  margin-left: auto;
}

/* Order summary labels aligned right */
.order-summary-label {
  text-align: right;
  padding-right: 0.5rem;
}

/* Order receipt top right section */
.order-top-right-section {
  min-width: 300px;
}

.order-info-left-aligned {
  text-align: left;
}

/* Order receipt section scaling (80%) */
.order-section-scaled {
  transform: scale(0.8);
  transform-origin: top left;
}

.order-wrapper-compressed {
  margin-bottom: -1rem !important;
}

.order-header-scaled {
  transform: scale(0.8);
  transform-origin: top left;
  margin-bottom: -2rem;
}

/* Small form check labels */
.form-check-label-sm {
  font-size: 0.75rem;
}

/* Individual products grid layout */
.individual-products-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}

/* Retouch table column widths */
.retouch-table {
  table-layout: fixed;
  width: 100%;
}

.retouch-table td {
  vertical-align: middle;
}

.retouch-pose-col {
  width: 100px;
}

.retouch-acne-col {
  width: 200px;
}

.retouch-neck-col {
  width: 200px;
}

.retouch-facial-col {
  width: 200px;
}

.retouch-scars-col {
  width: 200px;
}

.retouch-teeth-col {
  width: 200px;
}

.retouch-remove-col {
  width: 100px;
}

/* Stands quantity input */
.stands-quantity-input {
  width: 100px;
}

/* Order action buttons - uniform width */
.order-action-button {
  min-width: 120px;
}

/* Clear form badge - match button width but keep badge height */
.clear-form-badge {
  min-width: 120px;
  padding: 2px 12px;
  font-size: 0.75rem;
}

/* Pose number input in header */
.pose-number-input {
  width: 100px;
}

/* Card type and quantity inputs */
.card-type-select {
  width: 150px;
}

.card-quantity-input {
  width: 100px;
}

/* Order form sections (replacing Bootstrap cards) */
.pms-section {
  margin-bottom: 1.5rem;
  border: 1px solid #dee2e6;
  border-radius: 0.375rem;
  background-color: #fff;
}

.pms-section-header {
  padding: 0.75rem 1rem;
  background-color: #f8f9fa;
  border-bottom: 1px solid #dee2e6;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.pms-section-header h5 {
  margin: 0;
  font-size: 1.125rem;
  font-weight: 500;
}

.pms-section-body {
  padding: 1rem;
}

.pms-table-responsive {
  overflow-x: auto;
}

/* Collapse functionality */
.pms-collapse {
  display: none;
  overflow: hidden;
}

.pms-collapse.show {
  display: block;
}

.pms-collapse-toggle {
  cursor: pointer;
  user-select: none;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.pms-collapse-toggle h5 {
  margin: 0;
  font-size: 1.125rem;
  font-weight: 500;
}

.pms-collapse-toggle i {
  transition: transform 0.2s ease;
  font-size: 1rem;
}

.pms-collapse-toggle.expanded i {
  transform: rotate(90deg);
}

/* Individual product table column widths */
.individual-product-table {
  border-collapse: collapse;
  table-layout: fixed;
  width: 100%;
}

.individual-product-table th,
.individual-product-table td {
  text-align: center;
  vertical-align: middle;
  border: 1px solid #dee2e6;
  padding: 0.25rem;
  width: 65px;
}

.individual-product-table th:first-child,
.individual-product-table td:first-child {
  width: 70px;
}

.individual-product-table th:nth-child(2),
.individual-product-table td:nth-child(2) {
  width: 60px;
}

.individual-product-table th:last-child,
.individual-product-table td:last-child {
  width: 50px;
}

.individual-product-table thead th {
  background-color: #f8f9fa;
  font-weight: 600;
}

.individual-product-table input[type="number"] {
  width: 100%;
  border: 1px solid #ced4da;
  padding: 0.25rem;
  border-radius: 0.25rem;
  text-align: center !important;
  -moz-appearance: textfield;
  appearance: textfield;
}

.individual-product-table input[type="number"]::-webkit-inner-spin-button,
.individual-product-table input[type="number"]::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.individual-product-table input[type="checkbox"] {
  width: auto;
}

.individual-product-table input[type="number"]:focus {
  outline: none;
  border-color: #86b7fe;
  box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

/* Directory Selection Table */
.directory-tables-container {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.directory-table-wrapper {
  flex: 0 0 calc(25% - 0.75rem);
  min-width: 250px;
}

.directory-photo-column {
  width: 80px;
  max-width: 80px;
}

.directory-photo-input {
  width: 60px;
}

.directory-name-column {
  width: auto;
}

/* Montage Visual Representation */
.montage-visual {
  margin: 1rem 0;
  padding: 1rem;
  border: 2px solid #dee2e6;
  border-radius: 4px;
  background-color: #f8f9fa;
}

.montage-237-layout {
  display: flex;
  gap: 1rem;
  align-items: center;
  justify-content: center;
  min-height: 200px;
}

.montage-photo {
  border: 2px solid #495057;
  background-color: white;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  position: relative;
}

.montage-photo-main {
  width: 180px;
  height: 180px;
  font-size: 2rem;
}

.montage-photos-side {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.montage-photo-top,
.montage-photo-bottom {
  width: 100px;
  height: 85px;
  font-size: 1.5rem;
}

.montage-photo .photo-label {
  position: absolute;
  top: 0.25rem;
  left: 0.25rem;
  font-size: 0.75rem;
  color: #6c757d;
  font-weight: 600;
}

.montage-photo .photo-number {
  font-weight: bold;
  color: #212529;
}

/* Montage Photo Input Fields */
.montage-photo-input-main {
  flex-shrink: 0;
  width: 100px;
}

.montage-photo-inputs-side {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  width: 50px;
}

/* Montage Form Table */
.montage-form-table {
  table-layout: fixed;
  width: 100%;
}

.montage-form-table td {
  vertical-align: top;
  padding: 0.5rem;
}

.montage-photo-table {
  border-collapse: collapse;
}

.montage-photo-table td {
  padding: 0.25rem;
}

.montage-photo-cell-main {
  width: 90px;
}

.montage-photo-cell-side {
  width: 30px;
  padding-bottom: 5px;
}

.montage-photo-label {
  display: block;
  font-size: 0.875rem;
  margin-bottom: 0.25rem;
}

/* Make main photo input for 245/255/265 */
.montage-main-input {
  height: 100px;
  width: 90px;
  text-align: center;
  font-size: 1rem;
  padding: 2px;
}

/* Make side photo inputs for 245/255/265 */
.montage-side-input {
  height: 45px;
  width: 30px;
  text-align: center;
  font-size: 0.875rem;
  padding: 2px;
}

/* Layout 237 - Larger main box, side boxes vertically offset */
.montage-main-input-237 {
  height: 90px;  /* 9 Inches (1 Pixel = 1 Inch) */
  width: 75px;   /* 7.5 Inches */
  text-align: center;
  font-size: 1rem;
  padding: 2px;
}

.montage-side-input-237 {
  height: 50px;
  width: 40px;
  text-align: center;
  font-size: 0.875rem;
  padding: 2px;
}

.montage-photo-cell-main-237 {
  width: 70px;
  vertical-align: top;
}

/* Montage code column - sized for longest option */
.montage-code-column {
  width: 300px;
  max-width: 300px;
}

/* Format column - sized for "Thin Laminate (T)" */
.montage-format-column {
  max-width: 175px;
}

/* Colour column - sized for "Black (BL)" / "Beige (BE)" */
.montage-colour-column {
  max-width: 130px;
}

/* Fixed width for layout column to prevent shifting */
.montage-layout-column {
  width: 230px;
  min-width: 230px;
  max-width: 230px;
}

/* Quantity column for montages */
.montage-quantity-column {
  max-width: 120px;
}

.montage-photo-cell-side-237 {
  width: 40px;
  vertical-align: top;
  padding-left: 10px;
}

/* Top photo positioned above main photo */
.montage-photo-table tr:first-child .montage-photo-cell-side-237 {
  position: relative;
  top: -8px;
}

/* Bottom photo positioned below main photo */
.montage-photo-table tr:last-child .montage-photo-cell-side-237 {
  position: relative;
  top: -8px;
}

/* Layout 238 - Three columns in one row */
.montage-input-238 {
  height: 70px;
  width: 50px;
  text-align: center;
  font-size: 1rem;
  padding: 2px;
}

.montage-photo-cell-238 {
  width: 50px;
  vertical-align: top;
  padding-left: 10px;
}

.montage-photo-cell-238:first-child {
  padding-left: 0;
}

/* Layout 239 - Three rows stacked vertically */
.montage-input-239 {
  height: 70px;
  width: 50px;
  text-align: center;
  font-size: 1rem;
  padding: 2px;
}

.montage-photo-cell-239 {
  width: 50px;
  vertical-align: top;
  padding-bottom: 10px;
}

.montage-photo-table tr:last-child .montage-photo-cell-239 {
  padding-bottom: 0;
}

/* Layout 242 - Three columns with wider center */
.montage-input-242-small {
  height: 70px;
  width: 50px;
  text-align: center;
  font-size: 1rem;
  padding: 2px;
}

.montage-input-242-large {
  height: 70px;
  width: 100px;
  text-align: center;
  font-size: 1rem;
  padding: 2px;
}

.montage-photo-cell-242-small {
  width: 50px;
  vertical-align: top;
  padding-left: 10px;
}

.montage-photo-cell-242-large {
  width: 100px;
  vertical-align: top;
  padding-left: 10px;
}

.montage-photo-cell-242-small:first-child {
  padding-left: 0;
}

/* Layout 246, 248, 249 - Top input spanning two columns, two bottom inputs */
.montage-input-246-top {
  height: 70px;
  width: 90px;
  margin-left: 5px;
  text-align: center;
  font-size: 1rem;
  padding: 2px;
}

.montage-input-246-bottom {
  height: 55px;
  width: 45px;
  text-align: center;
  font-size: 0.875rem;
  padding: 2px;
}

.montage-photo-cell-246-top {
  width: 90px;
  vertical-align: top;
  padding-bottom: 5px;
}

.montage-photo-cell-246-bottom {
  width: 45px;
  vertical-align: top;
  padding-left: 10px;
}

.montage-photo-cell-246-bottom:first-child {
  padding-left: 5px;
}

/* Compact Montage Cards for Order Summary */
.montage-compact-card {
  border: 1px solid #dee2e6;
  border-radius: 0.375rem;
  background-color: white;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
  display: flex;
  flex-direction: column;
  width: 300px;
  height: 320px;
}

.montage-compact-header {
  background-color: var(--pms-color-blue);
  color: white;
  padding: 0.5rem;
  font-size: 0.875rem;
  font-weight: 600;
  border-top-left-radius: 0.375rem;
  border-top-right-radius: 0.375rem;
  text-align: center;
}

.montage-compact-body {
  padding: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1;
}

/* Miniature montage cards for show page (80% scale) */
.montage-mini-card {
  border: 1px solid #dee2e6;
  border-radius: 0.375rem;
  background-color: white;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
  display: flex;
  flex-direction: column;
  width: 240px;
  height: 240px;
}

.montage-mini-header {
  background-color: var(--pms-color-blue);
  color: white;
  padding: 0.4rem;
  font-size: 0.85rem;
  font-weight: 600;
  border-top-left-radius: 0.375rem;
  border-top-right-radius: 0.375rem;
  text-align: center;
}

.montage-mini-body {
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1;
  overflow: hidden;
  position: relative;
}

.montage-mini-body > * {
  flex-shrink: 0;
  transform: scale(0.8);
  transform-origin: center center;
}

/* Fine-tune vertical positioning for 242 layout */
.montage-mini-body .montage-photo-table-242 {
  margin-top: -5px;
}

/* Collapsible section toggle */
.collapse-toggle {
  cursor: pointer;
}

/* Portrait Products, Accessories, and Retouching tables - override Bootstrap border-bottom and use very light transparent borders */
#portraits-collapse .table tbody td,
#accessories-collapse .table tbody td,
#retouching-collapse .table tbody td {
  border-bottom-width: 0 !important;
  border-top: 1px solid rgba(0, 0, 0, 0.08) !important;
}

/* Portrait Products pose grouping - slightly heavier border for pose separators */
#portraits-collapse .table tbody tr.pose-group-start td {
  border-top: 1.5px solid #6c757d !important;
}

/* Keep heavier border after table header */
#portraits-collapse .table thead + tbody tr.pose-group-start:first-child td,
#accessories-collapse .table thead + tbody tr:first-child td,
#retouching-collapse .table thead + tbody tr:first-child td {
  border-top: 2px solid #495057 !important;
}

/* Retouch work cards - equal height */
.retouch-cards-row {
  display: flex;
  flex-wrap: wrap;
}

.retouch-cards-row .col-md-6,
.retouch-cards-row .col-lg-4 {
  display: flex;
}

.retouch-cards-row .card {
  flex: 1;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.retouch-cards-row .card .card-body {
  flex: 1;
  display: flex;
  flex-direction: column;
}

/* Card header margin reset */
.card-header {
  margin-top: 0;
}

/* Confirmation action buttons */
.confirm-action-container {
  display: inline-block;
}

.confirm-action-confirm {
  margin-left: 0.25rem;
}

.confirm-action-hidden {
  display: none !important;
}

/* ============================================================
   Monthly Calendar View
   ============================================================ */

.text-pms-blue {
  color: var(--pms-color-blue, #5a7a9c);
}

/* Compact task counter card in daily view sidebar */
.daily-todo-card-compact .card-body {
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
}

.daily-todo-card-compact .display-4 {
  font-size: 2rem;
}

.monthly-day-number {
  color: var(--pms-color-blue, #5a7a9c);
  font-weight: 600;
  text-decoration: none;
}

.monthly-day-number:hover {
  color: var(--pms-color-blue-hover, #466585);
  text-decoration: underline;
}

/* ── Appointment email history log ── */
.appt-email-log {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}
.appt-email-log__item {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.78rem;
}
.appt-email-log__type {
  font-weight: 600;
  color: var(--pms-color-text, #333);
}
.appt-email-log__sent {
  color: var(--pms-color-text-muted, #666);
}
.appt-email-log__opened {
  color: #2d7a2d;
  font-weight: 500;
}
.appt-email-log__not-opened {
  color: var(--pms-color-text-muted, #999);
  font-style: italic;
}
.appt-email-log__none {
  color: var(--pms-color-text-muted, #999);
  font-size: 0.85rem;
}

/* Appointment slot: clicking the info badge links to admin show view */
.slot-appt-link {
  display: block;
  text-decoration: none;
  color: inherit;
}
.slot-appt-link:hover .appointment-info {
  outline: 2px solid var(--pms-color-blue, #0d6efd);
  outline-offset: 1px;
  cursor: pointer;
}

/* Appointment show page: activity log timeline */
.appt-activity-log {
  list-style: none;
  margin: 0;
  padding: 0;
}
.appt-activity-log__item {
  position: relative;
  padding: 0.5rem 0 0.75rem 1rem;
  border-left: 2px solid #dee2e6;
}
.appt-activity-log__item::before {
  content: "";
  position: absolute;
  left: -6px;
  top: 0.85rem;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #adb5bd;
}
.appt-activity-log__item--created::before  { background: var(--pms-color-blue); }
.appt-activity-log__item--updated::before  { background: var(--pms-color-purple); }
.appt-activity-log__item--email_sent::before   { background: var(--pms-color-orange); }
.appt-activity-log__item--email_opened::before { background: var(--pms-color-green); }

.appt-activity-log__time {
  font-size: 0.78rem;
  color: #6c757d;
  margin-bottom: 0.1rem;
}
.appt-activity-log__label {
  font-weight: 600;
  font-size: 0.92rem;
}
.appt-activity-log__detail {
  font-size: 0.82rem;
  color: #495057;
}
.appt-show-dl dt { font-weight: 600; }

/* MFA Backup Codes */
.backup-codes-grid {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.backup-codes-row {
  display: flex;
  gap: 1rem;
}
.backup-code {
  font-family: monospace;
  font-size: 1.1rem;
  font-weight: 600;
  background: #f0f0f0;
  border: 1px solid #ccc;
  border-radius: 4px;
  padding: 0.4rem 0.75rem;
  flex: 1;
  text-align: center;
  letter-spacing: 0.05em;
}

/* ============================================================
   Customer Service — Reconciliation
   ============================================================ */

.pms-text-purple {
  color: var(--pms-color-purple, #6c5c9e);
}

.reconciliation-action-bar {
  background: #fff;
  border-bottom: 1px solid #dee2e6;
  padding: 0.5rem 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 0.75rem;
}

.reconciliation-report-title {
  font-size: 0.95rem;
}

.reconciliation-progress {
  font-size: 0.85rem;
  color: var(--pms-color-grey, #6c757d);
  white-space: nowrap;
}

.reconciliation-resolved-note {
  font-size: 0.875rem;
  color: var(--pms-color-grey, #6c757d);
  margin-left: auto;
}

/* Floating notes panel */
.reconciliation-notes-float {
  display: none;
  position: fixed;
  bottom: var(--panel-bottom, 30px);
  left: var(--panel-left, 20px);
  top: var(--panel-top);
  width: 420px;
  height: 200px;
  z-index: 500;
  background: #fff;
  border: 1px solid #dee2e6;
  border-radius: 6px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
  flex-direction: column;
  min-width: 260px;
  min-height: 140px;
  resize: both;
  overflow: hidden;
}

.reconciliation-notes-float.reconciliation-notes-open {
  display: flex;
}

.reconciliation-notes-float-body {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  padding: 0.5rem;
}

.reconciliation-notes-textarea {
  flex: 1;
  width: 100%;
  height: 100%;
  resize: none;
  border: 1px solid #ced4da;
  border-radius: 4px;
  font-size: 0.875rem;
  padding: 0.4rem 0.5rem;
  font-family: inherit;
}

/* Floating settlement report panel */
.reconciliation-pdf-float {
  display: none;
  position: fixed;
  top: var(--panel-top, 80px);
  right: var(--panel-right, 20px);
  left: var(--panel-left);
  width: 560px;
  height: 700px;
  z-index: 500;
  background: #fff;
  border: 1px solid #dee2e6;
  border-radius: 6px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
  flex-direction: column;
  resize: both;
  overflow: hidden;
  min-width: 300px;
  min-height: 200px;
}

.reconciliation-pdf-float.reconciliation-pdf-open {
  display: flex;
}

.reconciliation-pdf-float-header {
  background: #f0f0f0;
  border-bottom: 1px solid #dee2e6;
  padding: 0.4rem 0.75rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: move;
  flex-shrink: 0;
  border-radius: 5px 5px 0 0;
  user-select: none;
  font-weight: 600;
  font-size: 0.875rem;
}

.reconciliation-pdf-float-body {
  flex: 1;
  min-height: 0;
  position: relative;
  overflow: hidden;
}

.reconciliation-pdf-float-embed {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}

.reconciliation-pdf-float-btn {
  pointer-events: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.reconciliation-pdf-float-btn .bi {
  margin-right: 0;
}

/* Checkbox column in the line items table */
.reconciliation-check-col {
  width: 32px;
  min-width: 32px;
  text-align: center;
  vertical-align: middle;
}

.reconciliation-checkbox {
  width: 16px;
  height: 16px;
  cursor: pointer;
}

/* Row highlight when checkbox is checked */
tr:has(.reconciliation-checkbox:checked) {
  background-color: var(--pms-color-light-green, #d4edda) !important;
}

/* Accounting Dashboard */
.accounting-dashboard-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

.accounting-dashboard-card .card-body {
  display: flex;
  flex-direction: column;
}

.accounting-card-action {
  margin-top: auto;
  padding-top: 0.75rem;
}

.accounting-card-action .location-update-btn {
  display: block;
  width: 100%;
  text-align: center;
  box-sizing: border-box;
}

.accounting-form-row {
  display: flex;
  gap: 0.5rem;
  align-items: flex-end;
  margin-top: 0.5rem;
}

.accounting-form-field {
  flex: 1;
}

/* Commission release row expand/collapse */
.commission-detail-hidden {
  display: none;
}

.commission-detail-visible {
  display: table-row;
}

.commission-expandable-row td {
  cursor: pointer;
}

.commission-expandable-row:hover {
  background-color: #f8f9fa;
}

/* Reconciliation date column alignment */
.reconciliation-date-cell {
  display: inline-flex;
  align-items: center;
  gap: 0;
}

.reconciliation-date-icon {
  display: inline-block;
  width: 1.25rem;
  text-align: center;
}

/* Todo location search dropdown */
.todo-location-dropdown {
  position: absolute;
  width: 100%;
  z-index: 1060;
  max-height: 200px;
  overflow-y: auto;
  box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

/* Expense Reports */
.expense-table {
  font-size: 0.85rem;
}

.expense-table th {
  white-space: nowrap;
}

.expense-item-row td {
  vertical-align: middle;
}

.expense-summary-card .form-control {
  font-size: 1.1rem;
  font-weight: 600;
}

.expense-receipt-thumb {
  display: inline-block;
}

.expense-report-form .card-header {
  background: #f8f9fa;
}

.expense-remove-row {
  font-size: 1.1rem;
}

/* Draggable location info panel */
.location-info-panel {
  position: fixed;
  z-index: 1055;
  left: var(--panel-left, 60px);
  top: var(--panel-top, 120px);
  width: 320px;
  max-height: 75vh;
  overflow-y: auto;
  background: #fff;
  border: 1px solid #ced4da;
  border-radius: 0.375rem;
  box-shadow: 0 0.5rem 1.5rem rgba(0, 0, 0, 0.25);
}

.location-info-panel.location-panel-hidden {
  display: none;
}

.location-panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0.75rem;
  background: #495057;
  color: #fff;
  border-radius: 0.375rem 0.375rem 0 0;
  cursor: move;
  user-select: none;
}

.draggable-header {
  cursor: move;
  user-select: none;
}

.modal-dialog {
  transform: translate(var(--drag-x, 0), var(--drag-y, 0));
}

.location-panel-header .location-panel-title {
  font-weight: 600;
  font-size: 0.9rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.location-panel-close {
  background: transparent;
  border: none;
  color: #fff;
  font-size: 1.25rem;
  line-height: 1;
  padding: 0 0 0 0.5rem;
  cursor: pointer;
  opacity: 0.75;
  flex-shrink: 0;
}

.location-panel-close:hover {
  opacity: 1;
}

.location-panel-body {
  padding: 0.75rem;
  font-size: 0.85rem;
}

.location-panel-body h6 {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #6c757d;
  margin-bottom: 0.25rem;
  margin-top: 0.75rem;
}

.location-panel-body h6:first-child {
  margin-top: 0;
}

.booking-date-input {
  width: 9rem !important;
}


/* ── Location Additional Contacts (lac) ─────────────────────────────────── */
.lac-search-wrapper { position: relative; }
.lac-results {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  z-index: 1000;
  background: #fff;
  border: 1px solid #dee2e6;
  border-radius: 0.375rem;
  max-height: 220px;
  overflow-y: auto;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}
.lac-result-item {
  padding: 0.4rem 0.75rem;
  cursor: pointer;
  font-size: 0.9rem;
}
.lac-result-item:hover { background: #f0f4ff; }
.lac-result-already { color: #6c757d; cursor: default; font-style: italic; }
.lac-result-empty { color: #6c757d; font-style: italic; cursor: default; }
.lac-contact-name { font-size: 0.9rem; }
.lac-job-title { max-width: 16em; }

/* Phone type select — narrow fixed width inside inline phone cell */
.contact-phone-type-select {
  width: 6.5rem !important;
  min-width: 6.5rem;
  flex-shrink: 0;
  padding-top: 0.25rem;
  padding-bottom: 0.25rem;
  font-size: 0.875rem;
  line-height: 1.5;
  height: calc(1.5em + 0.5rem + 2px);
}

/* Phone number input — fills remaining flex space beside the type select */
.contact-phone-field {
  flex: 1 1 0;
  min-width: 0;
}

/* Phone extension input — narrow fixed width */
.contact-phone-extension-field {
  width: 60px !important;
  min-width: 60px;
  flex-shrink: 0;
}

/* Action buttons (Clear / Remove) — sized to content, no wrap */
.location-contact-action-btn {
  flex-shrink: 0;
  white-space: nowrap;
}

/* Booking date table action buttons — uniform height; align form wrappers from button_to */
.booking-dates-table .buttons-cell .pms-button {
  height: 2rem;
  vertical-align: middle;
}
.booking-dates-table .buttons-cell form {
  display: inline-flex;
  vertical-align: middle;
  margin: 0;
}

/* ── Contract provision drag-drop builder ── */
.contract-provision-palette {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.contract-provision-tile {
  display: flex;
  flex-direction: column;
  padding: 8px 10px;
  border: 1.5px dashed #9b59b6;
  border-radius: 6px;
  background: #faf6ff;
  cursor: grab;
  user-select: none;
}

.contract-provision-tile:active {
  cursor: grabbing;
  background: #f0e6ff;
}

.contract-provision-tile-name {
  font-weight: 600;
  font-size: 0.85rem;
  color: #6c2a8a;
}

.contract-provision-tile-desc {
  font-size: 0.75rem;
}

.contract-provision-dropzone {
  min-height: 120px;
  border: 2px dashed #ced4da;
  border-radius: 6px;
  padding: 10px;
  background: #f8f9fa;
  transition: border-color 0.15s, background 0.15s;
}

.contract-provision-dropzone-active {
  border-color: #9b59b6;
  background: #f5eeff;
}

.contract-provision-dropped {
  padding: 6px 8px;
  border: 1px solid #dee2e6;
  border-radius: 5px;
  background: #fff;
  align-items: flex-start;
}

.contract-provision-dropped.contract-provision-dragging {
  opacity: 0.5;
}

.contract-provision-drag-handle {
  cursor: grab;
  color: #999;
  font-size: 1.1rem;
  line-height: 1.6;
  user-select: none;
  flex-shrink: 0;
}

.contract-provision-drag-handle:active {
  cursor: grabbing;
}

.contract-provision-label {
  font-size: 0.85rem;
  line-height: 1.6;
}

.contract-provision-number {
  width: 80px;
  display: inline-block;
  padding: 1px 4px;
  font-size: 0.85rem;
  border: 1px solid #adb5bd;
  border-radius: 3px;
  text-align: center;
}

.contract-provision-custom-text {
  font-size: 0.85rem;
  width: 100%;
}

.contract-provision-remove {
  flex-shrink: 0;
  align-self: flex-start;
}

.contract-min-sittings-group {
  width: 240px;
  max-width: 100%;
}

.contract-min-sittings-group .form-control {
  flex: 0 0 100px;
}

.contract-provision-dropzone-hint {
  pointer-events: none;
}

