:root {
  color-scheme: light;
  --bg: #f4f6f5;
  --surface: #ffffff;
  --surface-muted: #eef3f1;
  --border: #d7dfdc;
  --text: #17211d;
  --muted: #66736e;
  --primary: #0f766e;
  --primary-dark: #115e59;
  --warning: #b7791f;
  --danger: #b42318;
  --success: #147a44;
  --shadow: 0 12px 32px rgba(20, 32, 28, 0.08);
}

* {
  box-sizing: border-box;
}

body {
  min-width: 320px;
  margin: 0;
  color: var(--text);
  background: var(--bg);
  font-family: Arial, Helvetica, sans-serif;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

[hidden] {
  display: none !important;
}

.role-hidden {
  display: none !important;
}

.lang-toggle {
  position: fixed;
  top: 14px;
  right: 14px;
  z-index: 30;
  min-height: 34px;
  padding: 6px 12px;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  box-shadow: var(--shadow);
}

.lang-toggle:hover {
  background: var(--surface-muted);
}

.toast-container {
  position: fixed;
  top: 60px;
  right: 14px;
  z-index: 40;
  display: grid;
  gap: 8px;
  max-width: min(360px, calc(100vw - 28px));
}

.toast {
  padding: 12px 14px;
  color: #10221d;
  background: #eafaf3;
  border: 1px solid #9fdcc0;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 700;
  box-shadow: var(--shadow);
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.toast-hide {
  opacity: 0;
  transform: translateY(-6px);
}

.nav-badge {
  display: inline-flex;
  min-width: 18px;
  height: 18px;
  margin-left: 8px;
  padding: 0 5px;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: #ef4444;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
}

.password-form {
  display: grid;
  gap: 14px;
  max-width: 420px;
}

.login-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    linear-gradient(135deg, rgba(15, 118, 110, 0.14), rgba(244, 246, 245, 0.72)),
    var(--bg);
}

.login-panel {
  width: min(420px, 100%);
  display: grid;
  gap: 18px;
  padding: 28px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.login-panel h1,
.topbar h2,
.form-section-title h3,
.list-title {
  margin: 0;
  letter-spacing: 0;
}

.login-panel h1 {
  font-size: 29.4px;
  line-height: 1.15;
  text-align: center;
}

.eyebrow {
  margin: 0 0 6px;
  color: var(--primary-dark);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}

label {
  display: grid;
  gap: 7px;
  color: #28352f;
  font-size: 14px;
  font-weight: 700;
}

input,
select,
textarea {
  width: 100%;
  min-height: 42px;
  padding: 10px 12px;
  color: var(--text);
  background: #fff;
  border: 1px solid #cbd6d2;
  border-radius: 6px;
  outline: none;
}

textarea {
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(15, 118, 110, 0.14);
}

.primary-action,
.secondary-action,
.nav-button,
.segmented-control button,
.table-action {
  min-height: 40px;
  border: 1px solid transparent;
  border-radius: 6px;
  font-weight: 700;
}

.primary-action {
  color: #fff;
  background: var(--primary);
}

.primary-action:hover {
  background: var(--primary-dark);
}

.secondary-action {
  color: var(--text);
  background: var(--surface);
  border-color: var(--border);
}

.form-error,
.global-message {
  margin: 0;
  padding: 10px 12px;
  border-radius: 6px;
  font-size: 14px;
}

.form-error,
.global-message.error {
  color: #7a271a;
  background: #fff0ed;
  border: 1px solid #f4b5ac;
}

.global-message.success {
  color: #0f5132;
  background: #e8f6ee;
  border: 1px solid #a6d7b9;
}

.app-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 252px minmax(0, 1fr);
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 22px;
  padding: 20px;
  background: #18231f;
  color: #f7faf8;
}

.brand-block {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
}

.brand-block strong {
  font-size: 18px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: block;
}

.brand-mark {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  background: #d7efe9;
  color: #113c37;
  border-radius: 8px;
  font-weight: 800;
}

.brand-block small,
.session-pill small,
.form-section-title p {
  color: var(--muted);
}

.brand-block small {
  display: block;
  margin-top: 3px;
  color: #b9c7c2;
}

.nav-stack {
  display: grid;
  align-content: start;
  gap: 8px;
}

.nav-button {
  width: 100%;
  padding: 10px 12px;
  color: #dbe7e3;
  text-align: left;
  background: transparent;
}

.nav-button:hover,
.nav-button.active {
  color: #10201c;
  background: #d7efe9;
}

.workspace {
  min-width: 0;
  padding: 22px;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.topbar h2 {
  font-size: 26px;
}

.session-pill {
  display: grid;
  gap: 2px;
  min-width: 190px;
  padding: 10px 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.session-pill span {
  font-weight: 800;
}

.view-pane {
  display: grid;
  gap: 16px;
}

.metrics-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.metrics-grid article,
.form-grid,
.transfer-section,
.hotel-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: 0 6px 18px rgba(20, 32, 28, 0.04);
}

.metrics-grid article {
  display: grid;
  gap: 8px;
  padding: 16px;
}

.metrics-grid span {
  color: var(--muted);
  font-size: 13px;
}

.metrics-grid strong {
  font-size: 28px;
}

.toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: space-between;
  align-items: center;
}

.toolbar-search-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  flex: 1 1 auto;
}

.toolbar-search {
  flex: 1 1 260px;
  max-width: 380px;
}

.hotel-filter {
  flex: 0 1 240px;
  min-width: 190px;
}

.segmented-control {
  display: inline-grid;
  grid-auto-flow: column;
  padding: 3px;
  background: var(--surface-muted);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.segmented-control button {
  padding: 8px 12px;
  color: #43514b;
  background: transparent;
}

.segmented-control button.active {
  color: var(--text);
  background: var(--surface);
  border-color: var(--border);
}

.filter-control {
  grid-template-columns: repeat(9, auto);
}

.toolbar-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  flex: 1 1 100%;
}

.toolbar-filters #exportCsvButton {
  margin-left: auto;
}

.filter-date {
  width: 172px;
}

.table-stack {
  display: grid;
  gap: 16px;
}

.payment-toolbar {
  display: flex;
  align-items: end;
  flex-wrap: wrap;
  gap: 12px;
  padding: 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.payment-toolbar label {
  min-width: 160px;
}

.payments-stack {
  display: grid;
  gap: 16px;
}

.payment-shell {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
}

.payment-shell.single-column {
  grid-template-columns: 1fr;
}

.payment-hotel-nav {
  position: sticky;
  top: 16px;
  display: grid;
  gap: 8px;
  padding: 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.payment-hotel-nav > strong {
  font-size: 15px;
}

.payment-hotel-nav button {
  display: grid;
  gap: 3px;
  min-height: 48px;
  padding: 9px 10px;
  color: var(--text);
  background: #f8faf9;
  border: 1px solid var(--border);
  border-radius: 6px;
  text-align: left;
}

.payment-hotel-nav button.active {
  background: #dff3ef;
  border-color: #72b8af;
}

.payment-hotel-nav span {
  color: var(--muted);
  font-size: 12px;
}

.payment-detail-pane {
  display: grid;
  gap: 12px;
  min-width: 0;
}

.payment-overview {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.payment-overview article,
.payment-hotel-card,
.payment-grand-total {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: 0 6px 18px rgba(20, 32, 28, 0.04);
}

.payment-overview article {
  display: grid;
  gap: 7px;
  padding: 14px;
}

.payment-overview span,
.payment-grand-total span,
.payment-grand-total small {
  color: var(--muted);
  font-size: 13px;
}

.payment-overview strong,
.payment-grand-total strong {
  font-size: 22px;
}

.payment-selected-counts {
  display: flex;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 8px 14px;
  padding: 8px 12px;
  background: #f8faf9;
  border: 1px solid var(--border);
  border-radius: 8px;
}

.payment-selected-counts span {
  color: #34423c;
  font-size: 13px;
  white-space: nowrap;
}

.payment-hotel-card {
  display: grid;
  gap: 14px;
  padding: 16px;
}

.payment-hotel-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.payment-hotel-header h3 {
  margin: 0 0 4px;
  font-size: 18px;
}

.payment-hotel-header span {
  color: var(--muted);
  font-size: 13px;
}

.payment-counts {
  display: flex;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 8px 14px;
}

.payment-counts span {
  color: #34423c;
  white-space: nowrap;
}

.payment-rates-form {
  display: grid;
  gap: 12px;
  padding: 12px;
  background: #f8faf9;
  border: 1px solid var(--border);
  border-radius: 8px;
}

.rate-matrix-wrap {
  overflow-x: auto;
}

.rate-matrix {
  width: 100%;
  border-collapse: collapse;
}

.rate-matrix th,
.rate-matrix td {
  padding: 4px 6px;
  text-align: left;
}

.rate-matrix thead th {
  font-size: 12px;
  color: var(--muted);
  font-weight: 700;
  white-space: nowrap;
}

.rate-matrix tbody th {
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
  padding-right: 10px;
}

.rate-matrix th:first-child {
  position: sticky;
  left: 0;
  background: #f8faf9;
}

.rate-matrix input {
  min-height: 36px;
  min-width: 90px;
}

.payment-form-title {
  display: grid;
  gap: 4px;
}

.payment-form-title span {
  color: var(--muted);
  font-size: 12px;
}

.payment-rates-form .primary-action {
  justify-self: start;
  min-height: 42px;
  padding-inline: 12px;
}

.payment-totals-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  padding: 10px 12px;
  background: #f5f8f7;
  border-radius: 6px;
}

.payment-columns {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.payment-transfer-group {
  min-width: 0;
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
}

.payment-group-header {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  background: #f8faf9;
  border-bottom: 1px solid var(--border);
}

.payment-group-header h4 {
  margin: 0;
}

.payment-group-header span,
.payment-empty {
  color: var(--muted);
  font-size: 13px;
}

.payment-empty {
  padding: 14px 12px;
}

.payment-transfer-list {
  display: grid;
}

.payment-transfer-item {
  display: grid;
  grid-template-columns: 1.3fr 1fr minmax(150px, 0.9fr) minmax(130px, 0.8fr);
  gap: 10px;
  padding: 11px 12px;
  border-bottom: 1px solid #e6ece9;
}

.payment-transfer-item:last-child {
  border-bottom: 0;
}

.payment-transfer-item > div {
  display: grid;
  align-content: start;
  gap: 4px;
  min-width: 0;
}

.payment-transfer-item span {
  color: var(--muted);
  font-size: 12px;
}

.payment-transfer-item .payment-code {
  width: fit-content;
  padding: 2px 7px;
  color: #0f5f58;
  font-weight: 800;
  background: #dff3ef;
  border: 1px solid #72b8af;
  border-radius: 999px;
}

.payment-amount strong {
  color: var(--text);
}

.address-payment-control {
  display: grid;
  gap: 6px;
}

.address-payment-control .secondary-action {
  min-height: 32px;
  padding: 5px 8px;
  font-size: 12px;
}

.payment-status-select {
  min-height: 34px;
}

.payment-status-pill {
  display: inline-flex;
  width: fit-content;
  padding: 5px 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.payment-status-pill.pending {
  color: #68430a;
  background: #fff4cf;
}

.payment-status-pill.paid {
  color: #0f5132;
  background: #dff3e8;
}

.payment-grand-total {
  display: grid;
  gap: 6px;
  padding: 16px;
}

.transfer-section {
  min-width: 0;
  overflow: hidden;
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
}

.section-header h3 {
  margin: 0;
  font-size: 17px;
}

.section-title-group {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 14px;
  min-width: 0;
}

.toggle-cancelled-btn {
  min-height: 28px;
  padding: 0 10px;
  font-size: 12px;
  border-radius: 999px;
}

.route-summary {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  color: var(--muted);
  font-size: 12px;
}

.route-summary-item {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
}

.route-summary-item::before {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  content: "";
}

.arrival-summary::before {
  background: #60a5fa;
}

.departure-summary::before {
  background: #4ade80;
}

.route-summary-item strong {
  color: var(--text);
}

.count-pill {
  padding: 4px 8px;
  color: #49564f;
  background: var(--surface-muted);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}

.table-scroll {
  overflow-x: auto;
}

table {
  width: 100%;
  min-width: 1260px;
  border-collapse: collapse;
}

th,
td {
  padding: 12px 14px;
  border-bottom: 1px solid #e6ece9;
  text-align: left;
  vertical-align: top;
  font-size: 14px;
}

th {
  color: #51605a;
  background: #f8faf9;
  font-size: 12px;
  text-transform: uppercase;
}

.sortable-header {
  cursor: pointer;
  user-select: none;
  white-space: nowrap;
}

.sortable-header:hover {
  color: var(--primary-dark);
  background: #eef3f1;
}

.sortable-header.active-sort {
  color: var(--primary-dark);
  font-weight: 800;
}

.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 14px 16px;
  border-top: 1px solid #e6ece9;
}

.pagination-status {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.pagination .secondary-action {
  min-height: 34px;
  padding: 6px 14px;
}

.pagination .secondary-action:disabled {
  cursor: default;
  opacity: 0.5;
}

.strong-cell {
  font-weight: 800;
}

.muted-line {
  display: -webkit-box;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  overflow: hidden;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
}

.primary-line {
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
}

.notes-cell {
  min-width: 180px;
  max-width: 280px;
}

.wrap-cell {
  min-width: 160px;
  max-width: 260px;
  overflow-wrap: anywhere;
}

.note-line {
  display: -webkit-box;
  color: #34423c;
  font-size: 12px;
  line-height: 1.45;
  overflow-wrap: anywhere;
  overflow: hidden;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
}

.note-line + .note-line {
  margin-top: 6px;
}

.admin-note-line {
  color: #68430a;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.status-new {
  color: #10213b;
  background: #60a5fa;
  border-color: #3b82f6;
}

.status-confirmed {
  color: #3f2b00;
  background: #fbbf24;
  border-color: #d99b00;
}

.status-completed {
  color: #0c3b20;
  background: #4ade80;
  border-color: #22c55e;
}

.status-cancelled {
  color: #501313;
  background: #f87171;
  border-color: #ef4444;
}

.status-no_show {
  color: #2f1859;
  background: #a78bfa;
  border-color: #8b5cf6;
}

.status-select {
  min-width: 132px;
  min-height: 34px;
  padding: 6px 8px;
  font-weight: 800;
}

.status-row-new {
  background: #eff6ff;
}

.status-row-confirmed {
  background: #fffbeb;
}

.status-row-completed {
  background: #f0fdf4;
}

.status-row-cancelled {
  background: #fff1f2;
}

.status-row-no_show {
  background: #f5f3ff;
}

.status-row-new > td:first-child {
  box-shadow: inset 5px 0 0 #60a5fa;
}

.status-row-confirmed > td:first-child {
  box-shadow: inset 5px 0 0 #fbbf24;
}

.status-row-completed > td:first-child {
  box-shadow: inset 5px 0 0 #4ade80;
}

.status-row-cancelled > td:first-child {
  box-shadow: inset 5px 0 0 #f87171;
}

.status-row-no_show > td:first-child {
  box-shadow: inset 5px 0 0 #a78bfa;
}

.table-action {
  min-height: 34px;
  padding: 6px 12px;
  color: #0b4d47;
  background: #dff3ef;
  border-color: #8ccfc5;
}

.table-action:hover {
  background: #c8eae4;
}

.table-actions {
  display: flex;
  gap: 7px;
  min-width: 190px;
}

.table-actions .table-action {
  white-space: nowrap;
}

.assign-action {
  color: #174ea6;
  background: #e7f0fc;
  border-color: #a9c7ee;
}

.assign-action:hover {
  background: #d7e7fa;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(10, 19, 16, 0.48);
}

.transfer-modal {
  width: min(760px, 100%);
  max-height: min(720px, calc(100vh - 36px));
  overflow: auto;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: 0 22px 60px rgba(10, 19, 16, 0.24);
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px;
  border-bottom: 1px solid var(--border);
}

.modal-header h3 {
  margin: 0;
  font-size: 20px;
}

.modal-header .secondary-action {
  min-height: 34px;
  padding: 6px 10px;
}

.modal-content {
  display: grid;
  gap: 14px;
  padding: 16px;
}

.modal-reference-line {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 12px;
}

.modal-reference {
  min-width: 0;
  color: var(--primary-dark);
  font-weight: 800;
  overflow-wrap: anywhere;
}

.modal-route-label {
  grid-column: 2;
  padding: 6px 10px;
  color: #174ea6;
  background: #e7f0fc;
  border: 1px solid #a9c7ee;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 800;
  text-align: center;
}

.detail-list {
  display: grid;
  gap: 10px;
  margin: 0;
}

.detail-list div {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid #e6ece9;
}

.detail-list dt {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.detail-list dd {
  margin: 0;
  font-weight: 700;
  overflow-wrap: anywhere;
}

.modal-passengers {
  display: grid;
  gap: 10px;
  padding: 12px;
  background: #f8faf9;
  border: 1px solid var(--border);
  border-radius: 6px;
}

.modal-notes {
  display: grid;
  gap: 10px;
  padding: 12px;
  background: #fffdf5;
  border: 1px solid #e5d8a9;
  border-radius: 6px;
}

.modal-note-list {
  display: grid;
  gap: 8px;
}

.modal-note-row {
  display: grid;
  grid-template-columns: 130px minmax(0, 1fr);
  gap: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid #eee4c3;
}

.modal-note-row:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.modal-note-row span {
  color: #74663a;
  font-size: 12px;
  font-weight: 800;
}

.modal-note-row p,
.empty-note {
  margin: 0;
  color: #3d3828;
  font-size: 13px;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.empty-note {
  color: var(--muted);
}

.modal-passengers-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.copy-action {
  min-height: 30px;
  padding: 5px 9px;
  color: #0b4d47;
  background: #fff;
  border: 1px solid #b8cbc5;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 700;
}

.copy-action:hover,
.copy-action.copied {
  background: #dff3ef;
  border-color: #8ccfc5;
}

.passenger-name-list {
  display: grid;
  gap: 6px;
}

.passenger-name-list span {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-bottom: 6px;
  color: #34423c;
  border-bottom: 1px solid #e2e9e6;
  overflow-wrap: anywhere;
}

.passenger-passport-tag {
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}

.passenger-name-list span:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.no-show-row {
  background: #f5f3ff;
}

.no-show-flag {
  display: inline-flex;
  margin-top: 7px;
  padding: 3px 7px;
  color: #2f1859;
  background: #a78bfa;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
}

.operation-form {
  display: grid;
  gap: 14px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.operation-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.operation-heading h4 {
  margin: 0;
  font-size: 17px;
}

.operation-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.operation-grid .wide {
  grid-column: 1 / -1;
}

.operation-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.operation-footer span {
  color: var(--muted);
  font-size: 12px;
}

.operation-footer .primary-action {
  min-width: 180px;
  padding: 9px 14px;
}

.operation-footer .primary-action:disabled {
  cursor: wait;
  opacity: 0.65;
}

.operation-message {
  margin: 0;
  padding: 9px 11px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 700;
}

.operation-message.success {
  color: #0f5132;
  background: #e8f6ee;
  border: 1px solid #a6d7b9;
}

.operation-message.error {
  color: #7a271a;
  background: #fff0ed;
  border: 1px solid #f4b5ac;
}

.control-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding-top: 4px;
}

.control-actions button {
  min-width: 130px;
  padding: 9px 14px;
}

.assignment-choice {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  padding: 3px;
  background: var(--surface-muted);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.assignment-choice button {
  min-height: 40px;
  color: #43514b;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 6px;
  font-weight: 700;
}

.assignment-choice button.active {
  color: var(--text);
  background: var(--surface);
  border-color: var(--border);
}

.field-hint {
  color: var(--muted);
  font-size: 12px;
  font-weight: 400;
}

.empty-state {
  padding: 24px 16px;
  color: var(--muted);
  background: var(--surface);
  border: 1px dashed #c9d5d1;
  border-radius: 8px;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  padding: 18px;
}

.wizard-step {
  display: contents;
}

.choice-group {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.choice-group legend {
  grid-column: 1 / -1;
  margin-bottom: 2px;
  color: #28352f;
  font-size: 14px;
  font-weight: 800;
}

.choice-card {
  min-height: 46px;
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  background: #f8faf9;
  border: 1px solid #cbd6d2;
  border-radius: 6px;
  font-weight: 800;
}

.choice-card:has(input:checked) {
  color: #0b4d47;
  background: #dff3ef;
  border-color: #72b8af;
}

.choice-card input {
  width: 16px;
  min-height: 16px;
  margin: 0;
}

.info-field {
  min-height: 42px;
  display: grid;
  gap: 5px;
  padding: 10px 12px;
  background: #f8faf9;
  border: 1px solid var(--border);
  border-radius: 6px;
}

.info-field span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.info-field strong {
  font-size: 15px;
}

.passenger-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.passenger-row {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.passenger-row label {
  flex: none;
  max-width: 50%;
  min-width: 160px;
}

.passenger-row .passenger-passport-field {
  min-width: 160px;
  max-width: 240px;
}

.passenger-passport-field.is-hidden {
  display: none;
}

.passenger-step-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.small-action {
  min-height: 32px;
  padding: 0 12px;
  font-size: 13px;
}

.passport-toggle-row {
  display: flex;
}

.passport-toggle-row .small-action {
  margin-top: -6px;
}

.split-actions {
  justify-content: space-between;
}

.compact-form {
  align-content: start;
}

.wide,
.form-section-title {
  grid-column: 1 / -1;
}

.form-section-title {
  display: grid;
  gap: 5px;
}

.form-section-title h3 {
  font-size: 20px;
}

.form-section-title p {
  margin: 0;
  font-size: 14px;
}

.form-actions {
  display: flex;
  justify-content: flex-end;
}

.form-actions .primary-action {
  min-width: 160px;
}

.split-layout {
  display: grid;
  grid-template-columns: minmax(320px, 0.88fr) minmax(360px, 1.12fr);
  gap: 16px;
  align-items: start;
}

.list-title {
  margin-bottom: 12px;
  font-size: 18px;
}

.hotel-list {
  display: grid;
  gap: 10px;
}

.driver-list {
  display: grid;
  gap: 10px;
}

.driver-card {
  display: grid;
  gap: 8px;
  padding: 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.driver-card-main,
.driver-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.entity-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.entity-card-header .driver-card-main {
  flex: 1;
}

.entity-actions {
  display: flex;
  gap: 7px;
  flex-shrink: 0;
}

.entity-action {
  min-height: 32px;
  padding: 5px 9px;
  color: #0b4d47;
  background: #e7f4f1;
  border-color: #a8d4cd;
  font-size: 12px;
  font-weight: 800;
}

.entity-action:hover {
  background: #d5ebe7;
}

.danger-action {
  color: #8a1c1c;
  background: #fff0f0;
  border-color: #f2b7b7;
}

.danger-action:hover {
  background: #ffe1e1;
}

.driver-card-main span {
  color: var(--primary-dark);
  font-weight: 800;
}

.driver-meta {
  color: var(--muted);
  font-size: 13px;
}

.hotel-card {
  display: grid;
  gap: 8px;
  padding: 14px;
}

.hotel-card strong {
  font-size: 16px;
}

.hotel-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  color: var(--muted);
  font-size: 13px;
}

@media (max-width: 920px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
    height: auto;
    grid-template-rows: auto auto auto;
  }

  .nav-stack {
    grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
  }

  .nav-button {
    text-align: center;
  }

  .topbar {
    align-items: stretch;
    flex-direction: column;
  }

  .session-pill {
    min-width: 0;
  }

  .payment-shell {
    grid-template-columns: 1fr;
  }

  .payment-hotel-nav {
    position: static;
    grid-template-columns: repeat(3, minmax(150px, 1fr));
    overflow-x: auto;
  }

  .payment-hotel-nav > strong {
    grid-column: 1 / -1;
  }

  .payment-columns,
  .form-grid,
  .choice-group,
  .passenger-list,
  .split-layout {
    grid-template-columns: 1fr;
  }

  .metrics-grid,
  .payment-overview {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .payment-hotel-header {
    align-items: stretch;
    flex-direction: column;
  }

  .payment-counts {
    justify-content: flex-start;
  }

  .payment-transfer-item {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .filter-control {
    width: 100%;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    grid-auto-flow: row;
  }
}

@media (max-width: 560px) {
  .workspace,
  .sidebar,
  .login-shell {
    padding: 14px;
  }

  .login-panel,
  .form-grid {
    padding: 16px;
  }

  .metrics-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .payment-toolbar,
  .payment-transfer-item {
    grid-template-columns: 1fr;
  }

  .payment-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .payment-hotel-nav {
    grid-template-columns: 1fr;
  }

  .payment-toolbar label,
  .payment-toolbar button {
    width: 100%;
  }

  .nav-stack {
    grid-template-columns: 1fr;
  }

  .segmented-control {
    width: 100%;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-auto-flow: row;
  }

  .section-header {
    align-items: flex-start;
  }

  .modal-note-row {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .filter-control {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .filter-date {
    width: 100%;
  }

  .toolbar-search {
    max-width: none;
  }

  .hotel-filter {
    flex-basis: 100%;
    width: 100%;
  }

  .toolbar-filters #exportCsvButton {
    margin-left: 0;
    width: 100%;
  }

  .detail-list div {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .modal-reference-line {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .modal-route-label {
    grid-column: 2;
  }

  .operation-grid {
    grid-template-columns: 1fr;
  }

  .operation-grid .wide {
    grid-column: auto;
  }

  .operation-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .operation-footer .primary-action {
    width: 100%;
  }

  .control-actions {
    flex-direction: column-reverse;
  }

  .control-actions button {
    width: 100%;
  }

  .driver-card-main,
  .driver-meta {
    align-items: flex-start;
    flex-direction: column;
  }

  .entity-card-header {
    align-items: stretch;
    flex-direction: column;
  }

  .entity-actions {
    width: 100%;
  }

  .entity-action {
    flex: 1;
  }
}
