.ticket-page {
    max-width: 1680px;
}

.ticket-order-page {
    max-width: min(1440px, calc(100vw - 32px));
}

.ticket-order-page .ticket-list-only {
    display: none;
}

.ticket-order-topbar {
    position: sticky;
    top: 0;
    z-index: 20;
    margin-bottom: 10px;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(8px);
}

.ticket-toolbar .ticket-keyword-input {
    width: 260px;
}

.ticket-date-input {
    width: 132px;
}

.ticket-stat-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    margin: 8px 0 12px;
    padding: 7px 10px;
    border: 1px solid #dbe3ef;
    background: #f8fafc;
    color: #374151;
    font-size: 14px;
}

.ticket-workbench {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: -4px 0 12px;
    padding: 7px 10px;
    border: 1px solid #e5e7eb;
    background: #fff;
    font-size: 14px;
}

.ticket-workbench button {
    border: 1px solid #d1d5db;
    background: #fff;
    padding: 5px 9px;
    cursor: pointer;
    white-space: nowrap;
    color: #4b5563;
    font: inherit;
}

.ticket-workbench button:hover {
    background: #f3f4f6;
}

.ticket-workbench b {
    color: #111827;
}

.ticket-home-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(240px, 1fr));
    gap: 12px;
    margin-top: 12px;
}

.ticket-home-status {
    display: flex;
    justify-content: flex-end;
    min-height: 22px;
    color: #64748b;
    font-size: 13px;
}

.ticket-home-kpis {
    display: grid;
    grid-template-columns: repeat(7, minmax(110px, 1fr));
    gap: 8px;
    margin: 8px 0 12px;
}

.ticket-home-kpis a {
    display: grid;
    gap: 5px;
    min-height: 64px;
    padding: 10px;
    border: 1px solid #dbe3ef;
    background: #f8fafc;
    color: #111827;
    text-decoration: none;
}

.ticket-home-kpis a:hover {
    border-color: #1d4ed8;
    background: #fff;
}

.ticket-home-kpis span {
    color: #475569;
    font-size: 13px;
}

.ticket-home-kpis b {
    font-size: 24px;
    line-height: 1;
}

.ticket-flow-strip {
    display: grid;
    grid-template-columns: repeat(7, minmax(120px, 1fr));
    gap: 8px;
    margin: 10px 0 14px;
}

.ticket-flow-strip a {
    display: grid;
    gap: 3px;
    min-height: 58px;
    padding: 10px;
    border: 1px solid #dbe3ef;
    background: #fff;
    color: #111827;
    text-decoration: none;
}

.ticket-flow-strip a:hover {
    border-color: #1d4ed8;
}

.ticket-flow-strip b {
    font-size: 15px;
}

.ticket-flow-strip span {
    color: #64748b;
    font-size: 13px;
}

.ticket-home-grid a {
    display: grid;
    gap: 8px;
    min-height: 96px;
    padding: 14px;
    border: 1px solid #dbe3ef;
    background: #fff;
    color: #111827;
    text-decoration: none;
}

.ticket-home-grid a:hover {
    background: #f8fafc;
    border-color: #93c5fd;
}

.ticket-home-grid b {
    font-size: 18px;
}

.ticket-home-grid span {
    color: #4b5563;
    line-height: 1.5;
}

.ticket-main-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 8px 0 12px;
    padding: 8px;
    border: 1px solid #e5e7eb;
    background: #fff;
}

.ticket-main-nav a {
    padding: 5px 9px;
    border: 1px solid #d1d5db;
    color: #1f2937;
    text-decoration: none;
    font-size: 14px;
}

.ticket-main-nav a:hover,
.ticket-main-nav a.is-active {
    background: #1f3a8a;
    border-color: #1f3a8a;
    color: #fff;
}

.ticket-nav-search {
    display: flex;
    gap: 6px;
    margin-left: auto;
}

.ticket-nav-search input {
    width: 180px;
    min-width: 0;
    height: 31px;
    box-sizing: border-box;
    border: 1px solid #d1d5db;
    padding: 4px 8px;
}

.ticket-nav-search button {
    height: 31px;
    border: 1px solid #1f3a8a;
    background: #1f3a8a;
    color: #fff;
    padding: 4px 10px;
    cursor: pointer;
}

.ticket-order-link,
.ticket-order-open,
.ticket-action-link {
    color: #1d4ed8;
    font-weight: 700;
    text-decoration: none;
}

.ticket-order-link:hover,
.ticket-order-open:hover,
.ticket-action-link:hover {
    text-decoration: underline;
}

.ticket-action-link {
    display: inline-block;
    border: 1px solid #bfdbfe;
    background: #eff6ff;
    padding: 3px 7px;
    color: #1d4ed8;
    font-size: 13px;
}

.ticket-action-link:hover {
    background: #dbeafe;
    text-decoration: none;
}

.ticket-order-open {
    display: inline;
    padding: 0;
    border: 0;
    background: transparent;
    cursor: pointer;
    font: inherit;
}

.ticket-stat-strip span {
    padding-right: 10px;
    border-right: 1px solid #dbe3ef;
    white-space: nowrap;
}

.ticket-stat-strip span:last-child {
    border-right: 0;
}

.ticket-stat-strip b {
    color: #111827;
}

.ticket-lab-grid {
    display: grid;
    grid-template-columns: minmax(420px, 1fr) minmax(360px, 0.8fr);
    gap: 14px;
    margin: 12px 0;
}

.ticket-parser-panel textarea {
    width: 100%;
    box-sizing: border-box;
    border: 0;
    border-top: 1px solid #e5e7eb;
    padding: 12px;
    resize: vertical;
    font-family: Menlo, Consolas, monospace;
    font-size: 13px;
    line-height: 1.5;
}

.ticket-parser-inline textarea {
    width: 100%;
    box-sizing: border-box;
    border: 0;
    border-top: 1px solid #e5e7eb;
    padding: 10px 12px;
    resize: vertical;
    font-family: Menlo, Consolas, monospace;
    font-size: 13px;
    line-height: 1.45;
}

.ticket-summary-preview {
    min-height: 190px;
    margin: 0;
    padding: 12px;
    border-top: 1px solid #e5e7eb;
    background: #f8fafc;
    white-space: pre-wrap;
    word-break: break-word;
    font-family: inherit;
    line-height: 1.7;
}

.ticket-parsed-pnr {
    border-top: 1px solid #e5e7eb;
    background: #f8fafc;
}

.ticket-parsed-pnr summary {
    cursor: pointer;
    padding: 9px 12px;
    color: #374151;
    font-weight: 700;
}

.ticket-parsed-pnr pre {
    max-height: 360px;
    margin: 0;
    overflow: auto;
    padding: 12px;
    border-top: 1px solid #e5e7eb;
    background: #fff;
    color: #111827;
    white-space: pre-wrap;
    word-break: break-word;
    font-family: Menlo, Consolas, monospace;
    font-size: 12px;
    line-height: 1.55;
}

.ticket-quality-panel {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding: 10px 12px;
    border-top: 1px solid #e5e7eb;
    background: #fff;
}

.ticket-quality-ok,
.ticket-quality-item {
    border: 1px solid #bbf7d0;
    background: #f0fdf4;
    color: #166534;
    padding: 4px 8px;
    font-size: 13px;
}

.ticket-quality-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border-color: #fde68a;
    background: #fffbeb;
    color: #92400e;
    cursor: pointer;
    font: inherit;
    font-size: 13px;
}

.ticket-quality-item b {
    color: #1d4ed8;
    font-size: 12px;
}

.ticket-quality-item.is-danger {
    border-color: #fecaca;
    background: #fef2f2;
    color: #991b1b;
}

.ticket-table {
    table-layout: auto;
}

.ticket-table th:nth-child(1),
.ticket-table td:nth-child(1) {
    width: 52px;
}

.ticket-table th:nth-child(2),
.ticket-table td:nth-child(2) {
    width: 150px;
    min-width: 150px;
}

.ticket-table th:nth-child(3),
.ticket-table td:nth-child(3) {
    width: 76px;
    min-width: 76px;
}

.ticket-table th:nth-child(4),
.ticket-table td:nth-child(4) {
    width: 86px;
    min-width: 86px;
}

.ticket-table th:nth-child(5),
.ticket-table td:nth-child(5) {
    min-width: 130px;
    white-space: pre-line;
    word-break: break-word;
}

.ticket-table th:nth-child(6),
.ticket-table td:nth-child(6) {
    width: 130px;
    min-width: 130px;
}

.ticket-table th:nth-child(7),
.ticket-table td:nth-child(7) {
    width: 130px;
    min-width: 130px;
}

.ticket-table th:nth-child(8),
.ticket-table td:nth-child(8),
.ticket-table th:nth-child(9),
.ticket-table td:nth-child(9),
.ticket-table th:nth-child(10),
.ticket-table td:nth-child(10) {
    width: 86px;
    min-width: 86px;
    text-align: right;
}

.ticket-table th:nth-child(11),
.ticket-table td:nth-child(11) {
    width: 92px;
    min-width: 92px;
    white-space: pre-line;
    font-size: 13px;
}

.ticket-table th:nth-child(12),
.ticket-table td:nth-child(12) {
    width: 92px;
    min-width: 92px;
}

.ticket-table th:nth-child(13),
.ticket-table td:nth-child(13) {
    width: 128px;
    min-width: 128px;
}

.ticket-table th:nth-child(14),
.ticket-table td:nth-child(14) {
    width: 128px;
    min-width: 128px;
}

.ticket-passenger-cell {
    line-height: 1.45;
}

.ticket-list-issues {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 5px;
}

.ticket-list-issue {
    border: 1px solid #fde68a;
    background: #fffbeb;
    color: #92400e;
    padding: 2px 5px;
    font-size: 12px;
    line-height: 1.3;
    cursor: pointer;
    font-family: inherit;
}

.ticket-list-issue.is-danger {
    border-color: #fecaca;
    background: #fef2f2;
    color: #991b1b;
}

button.ticket-list-issue:hover {
    text-decoration: underline;
}

.ticket-customer-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 4px;
    margin-bottom: 4px;
}

.ticket-customer-editor {
    margin-top: 12px;
}

.ticket-customer-form {
    display: grid;
    grid-template-columns: repeat(3, minmax(180px, 1fr));
    gap: 10px;
    padding: 12px;
}

.ticket-customer-form label {
    display: grid;
    gap: 5px;
    font-weight: 600;
}

.ticket-customer-form .wide-field {
    grid-column: 1 / -1;
}

.ticket-finance-cell {
    color: #374151;
    line-height: 1.45;
}

.ticket-finance-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 4px;
}

.ticket-finance-badge {
    border: 1px solid #bfdbfe;
    background: #eff6ff;
    color: #1d4ed8;
    padding: 2px 5px;
    font-size: 12px;
    line-height: 1.3;
    cursor: pointer;
    font-family: inherit;
}

.ticket-finance-badge.is-danger {
    border-color: #fecaca;
    background: #fef2f2;
    color: #991b1b;
}

button.ticket-finance-badge:hover {
    text-decoration: underline;
}

.ticket-action-overdue {
    color: #991b1b;
    font-weight: 700;
}

.ticket-action-today {
    color: #92400e;
    font-weight: 700;
}

.ticket-finance-table th,
.ticket-finance-table td,
.ticket-customer-table th,
.ticket-customer-table td {
    white-space: nowrap;
}

.ticket-finance-table th:nth-child(3),
.ticket-finance-table td:nth-child(3),
.ticket-finance-table th:nth-child(4),
.ticket-finance-table td:nth-child(4),
.ticket-customer-table th:nth-child(2),
.ticket-customer-table td:nth-child(2),
.ticket-customer-table th:nth-child(8),
.ticket-customer-table td:nth-child(8) {
    min-width: 150px;
}

.ticket-customer-table th:nth-child(4),
.ticket-customer-table td:nth-child(4),
.ticket-customer-table th:nth-child(9),
.ticket-customer-table td:nth-child(9) {
    min-width: 180px;
    white-space: normal;
}

.ticket-ops-table th:nth-child(4),
.ticket-ops-table td:nth-child(4),
.ticket-ops-table th:nth-child(5),
.ticket-ops-table td:nth-child(5) {
    min-width: 150px;
    white-space: pre-line;
}

.ticket-report-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(320px, 1fr));
    gap: 14px;
}

.ticket-report-grid-compact {
    margin: 10px 0 14px;
}

.ticket-report-list {
    padding: 10px 12px;
}

.ticket-report-row {
    display: grid;
    grid-template-columns: 90px 1fr 46px;
    gap: 8px;
    align-items: center;
    padding: 6px 0;
    border-bottom: 1px solid #edf2f7;
    font-size: 14px;
}

.ticket-report-row div {
    height: 8px;
    background: #e5e7eb;
    overflow: hidden;
}

.ticket-report-row i {
    display: block;
    height: 100%;
    background: #2563eb;
}

.ticket-report-row b {
    text-align: right;
}

.ticket-pipeline-board {
    display: grid;
    grid-template-columns: repeat(3, minmax(260px, 1fr));
    gap: 12px;
}

.ticket-pipeline-column {
    border: 1px solid #e5e7eb;
    background: #f8fafc;
}

.ticket-pipeline-column h2 {
    display: flex;
    justify-content: space-between;
    margin: 0;
    padding: 9px 10px;
    border-bottom: 1px solid #e5e7eb;
    font-size: 15px;
}

.ticket-pipeline-column > div {
    display: grid;
    gap: 8px;
    padding: 8px;
}

.ticket-pipeline-card {
    display: grid;
    gap: 4px;
    padding: 8px;
    border: 1px solid #dbe3ef;
    background: #fff;
    font-size: 13px;
}

.ticket-pipeline-card b {
    font-size: 14px;
}

.ticket-pipeline-card span,
.ticket-pipeline-card em {
    color: #4b5563;
    font-style: normal;
}

.ticket-pipeline-card small {
    justify-self: start;
    padding: 2px 6px;
    border: 1px solid #dbe3ef;
    background: #f8fafc;
    color: #374151;
    font-size: 12px;
}

.ticket-pipeline-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

.ticket-pipeline-badges i {
    border: 1px solid #fde68a;
    background: #fffbeb;
    color: #92400e;
    padding: 2px 5px;
    font-style: normal;
    font-size: 12px;
}

.ticket-setting-list {
    padding: 10px 12px;
}

.ticket-settings-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    margin: 8px 0 12px;
    padding: 8px;
    border: 1px solid #e5e7eb;
    background: #fff;
}

.ticket-settings-toolbar .ticket-settings-meta {
    margin-left: auto;
}

.ticket-setting-panel .admin-panel-head {
    cursor: pointer;
}

.ticket-setting-panel.is-collapsed > :not(.admin-panel-head) {
    display: none;
}

.ticket-setting-count {
    margin-left: auto;
    color: #64748b;
    font-size: 13px;
    white-space: nowrap;
}

.ticket-setting-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 7px 0;
    border-bottom: 1px solid #edf2f7;
}

.ticket-setting-row b {
    flex: 1;
}

.ticket-setting-row span {
    color: #6b7280;
}

.ticket-setting-row em {
    display: flex;
    gap: 4px;
    font-style: normal;
}

.ticket-setting-row button {
    padding: 2px 6px;
    font-size: 12px;
}

.ticket-setting-add-row {
    justify-content: flex-end;
    border-bottom: 0;
    padding-top: 10px;
}

.ticket-settings-editor {
    margin-top: 14px;
}

.ticket-settings-backup {
    margin-top: 14px;
}

.ticket-settings-import {
    display: grid;
    grid-template-columns: minmax(320px, 1fr) auto;
    gap: 10px;
    align-items: start;
    padding: 12px;
    border-top: 1px solid #e5e7eb;
}

.ticket-settings-import textarea {
    box-sizing: border-box;
    width: 100%;
    resize: vertical;
    font-family: Menlo, Consolas, monospace;
    font-size: 13px;
    line-height: 1.45;
}

.ticket-settings-history-table th:nth-child(4),
.ticket-settings-history-table td:nth-child(4) {
    min-width: 150px;
}

.ticket-settings-meta {
    padding: 0;
    border-top: 0;
    color: #4b5563;
    background: transparent;
    font-size: 13px;
}

.ticket-settings-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(260px, 1fr));
    gap: 12px;
    padding: 12px;
}

.ticket-settings-grid label {
    display: grid;
    gap: 6px;
    font-weight: 600;
}

.ticket-settings-grid textarea {
    width: 100%;
    box-sizing: border-box;
    resize: vertical;
    font-family: Menlo, Consolas, monospace;
    font-size: 13px;
    line-height: 1.45;
}

.ticket-supplier-table th:nth-child(1),
.ticket-supplier-table td:nth-child(1),
.ticket-supplier-table th:nth-child(7),
.ticket-supplier-table td:nth-child(7) {
    min-width: 150px;
}

.ticket-supplier-table th:nth-child(8),
.ticket-supplier-table td:nth-child(8) {
    min-width: 220px;
    white-space: normal;
}

.ticket-supplier-profile-panel {
    margin-bottom: 14px;
}

.ticket-supplier-profile-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(160px, 1fr));
    gap: 10px;
    padding: 12px;
    border-top: 1px solid #e5e7eb;
}

.ticket-supplier-profile-grid label {
    display: grid;
    gap: 5px;
    font-weight: 600;
}

.ticket-supplier-profile-grid input,
.ticket-supplier-profile-grid textarea {
    box-sizing: border-box;
    width: 100%;
}

.ticket-supplier-profile-grid .wide-field {
    grid-column: span 2;
}

.ticket-supplier-profile-table th:nth-child(1),
.ticket-supplier-profile-table td:nth-child(1),
.ticket-supplier-profile-table th:nth-child(6),
.ticket-supplier-profile-table td:nth-child(6) {
    min-width: 180px;
    white-space: normal;
}

.ticket-account-profile-panel {
    margin-bottom: 14px;
}

.ticket-account-profile-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(150px, 1fr));
    gap: 10px;
    padding: 12px;
    border-top: 1px solid #e5e7eb;
}

.ticket-account-profile-grid label {
    display: grid;
    gap: 5px;
    font-weight: 600;
}

.ticket-account-profile-grid input,
.ticket-account-profile-grid select,
.ticket-account-profile-grid textarea {
    box-sizing: border-box;
    width: 100%;
}

.ticket-account-profile-grid .wide-field {
    grid-column: span 2;
}

.ticket-account-table th:nth-child(1),
.ticket-account-table td:nth-child(1),
.ticket-account-table th:nth-child(7),
.ticket-account-table td:nth-child(7),
.ticket-account-table th:nth-child(8),
.ticket-account-table td:nth-child(8),
.ticket-account-profile-table th:nth-child(1),
.ticket-account-profile-table td:nth-child(1),
.ticket-account-profile-table th:nth-child(6),
.ticket-account-profile-table td:nth-child(6) {
    min-width: 170px;
    white-space: normal;
}

.ticket-account-table th:nth-child(2),
.ticket-account-table td:nth-child(2),
.ticket-account-table th:nth-child(3),
.ticket-account-table td:nth-child(3),
.ticket-account-table th:nth-child(4),
.ticket-account-table td:nth-child(4) {
    text-align: right;
    min-width: 90px;
}

.ticket-staff-table th:nth-child(1),
.ticket-staff-table td:nth-child(1),
.ticket-staff-table th:nth-child(10),
.ticket-staff-table td:nth-child(10) {
    min-width: 150px;
    white-space: normal;
}

.ticket-staff-table th:nth-child(3),
.ticket-staff-table td:nth-child(3),
.ticket-staff-table th:nth-child(4),
.ticket-staff-table td:nth-child(4),
.ticket-staff-table th:nth-child(5),
.ticket-staff-table td:nth-child(5),
.ticket-staff-table th:nth-child(6),
.ticket-staff-table td:nth-child(6),
.ticket-staff-table th:nth-child(7),
.ticket-staff-table td:nth-child(7) {
    text-align: right;
    min-width: 86px;
}

.ticket-reminder-table th:nth-child(4),
.ticket-reminder-table td:nth-child(4),
.ticket-refund-table th:nth-child(3),
.ticket-refund-table td:nth-child(3),
.ticket-refund-table th:nth-child(4),
.ticket-refund-table td:nth-child(4) {
    min-width: 150px;
    white-space: pre-line;
}

.ticket-reminder-table th:nth-child(7),
.ticket-reminder-table td:nth-child(7),
.ticket-refund-table th:nth-child(8),
.ticket-refund-table td:nth-child(8) {
    min-width: 240px;
    white-space: normal;
}

.ticket-search-table th:nth-child(4),
.ticket-search-table td:nth-child(4),
.ticket-search-table th:nth-child(5),
.ticket-search-table td:nth-child(5),
.ticket-health-table th:nth-child(4),
.ticket-health-table td:nth-child(4),
.ticket-health-table th:nth-child(5),
.ticket-health-table td:nth-child(5) {
    min-width: 150px;
    white-space: pre-line;
}

.ticket-search-table th:nth-child(3),
.ticket-search-table td:nth-child(3),
.ticket-health-table th:nth-child(3),
.ticket-health-table td:nth-child(3) {
    min-width: 120px;
}

.ticket-editor-panel {
    max-width: min(1440px, calc(100vw - 48px));
    margin: 14px auto 0;
}

.ticket-editor-panel.is-hidden {
    display: none;
}

.ticket-order-snapshot {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(240px, 0.42fr);
    gap: 10px;
    padding: 10px 12px;
    border-top: 1px solid #e5e7eb;
    background: #fbfdff;
}

.ticket-snapshot-main {
    display: grid;
    grid-template-columns: repeat(4, minmax(130px, 1fr));
    gap: 8px;
}

.ticket-snapshot-item,
.ticket-snapshot-next {
    min-width: 0;
    padding: 7px 9px;
    border: 1px solid #e5e7eb;
    background: #fff;
}

.ticket-snapshot-item b,
.ticket-snapshot-next b {
    display: block;
    margin-bottom: 3px;
    color: #64748b;
    font-size: 12px;
    font-weight: 600;
}

.ticket-snapshot-item em,
.ticket-snapshot-next span {
    display: block;
    overflow: hidden;
    color: #111827;
    font-style: normal;
    font-size: 13px;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ticket-snapshot-item.is-ok {
    border-color: #bbf7d0;
    background: #f0fdf4;
}

.ticket-snapshot-item.is-warn {
    border-color: #fde68a;
    background: #fffbeb;
}

.ticket-snapshot-item.is-danger {
    border-color: #fecaca;
    background: #fef2f2;
}

.ticket-snapshot-next {
    background: #f8fafc;
}

.ticket-editor-jumps {
    position: sticky;
    top: 46px;
    z-index: 12;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding: 8px 12px;
    border-top: 1px solid #e5e7eb;
    border-bottom: 1px solid #e5e7eb;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(8px);
}

.ticket-editor-jumps a {
    min-height: 28px;
    padding: 5px 10px;
    border: 1px solid #dbe3ef;
    background: #fff;
    color: #1f3a8a;
    font-size: 13px;
    font-weight: 700;
    text-decoration: none;
}

.ticket-editor-jumps a:hover {
    border-color: #1f3a8a;
    background: #eff6ff;
}

.ticket-status-flow {
    display: grid;
    grid-template-columns: repeat(9, minmax(72px, 1fr));
    gap: 6px;
    padding: 10px 12px;
    border-top: 1px solid #e5e7eb;
    background: #f8fafc;
}

.ticket-status-flow button {
    min-height: 34px;
    border: 1px solid #d1d5db;
    background: #fff;
    color: #374151;
    cursor: pointer;
    font: inherit;
    font-size: 13px;
}

.ticket-status-flow button.is-done {
    border-color: #bbf7d0;
    background: #f0fdf4;
    color: #166534;
}

.ticket-status-flow button.is-current {
    border-color: #1f3a8a;
    background: #1f3a8a;
    color: #fff;
    font-weight: 700;
}

.ticket-process-panel {
    display: grid;
    grid-template-columns: repeat(4, minmax(140px, 1fr));
    gap: 8px;
    padding: 10px 12px;
    border-top: 1px solid #e5e7eb;
    background: #fff;
}

.ticket-process-step {
    display: grid;
    gap: 4px;
    min-height: 52px;
    padding: 8px;
    border: 1px solid #e5e7eb;
    background: #f8fafc;
}

.ticket-process-step b {
    color: #111827;
    font-size: 14px;
}

.ticket-process-step span {
    color: #64748b;
    font-size: 12px;
}

.ticket-process-step.is-done {
    border-color: #bbf7d0;
    background: #f0fdf4;
}

.ticket-process-step.is-current {
    border-color: #f59e0b;
    background: #fffbeb;
}

.ticket-form-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(260px, 1fr));
    gap: 10px;
    padding: 10px 12px;
}

.ticket-form-block label {
    margin-bottom: 7px;
}

.ticket-order-tail {
    border-top: 1px solid #e5e7eb;
}

.ticket-summary-tail {
    border-bottom: 0;
}

.ticket-form-block {
    align-content: start;
    border: 1px solid #e5e7eb;
    background: #fff;
    padding: 12px;
}

.ticket-form-block h3 {
    grid-column: 1 / -1;
    margin: 0 0 10px;
    font-size: 16px;
}

.ticket-form-block textarea {
    min-height: 78px;
}

.ticket-block-title {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin: 0 0 10px;
}

.ticket-block-title h3 {
    margin: 0;
}

.ticket-profile-badge {
    align-self: center;
    border: 1px solid #dbeafe;
    background: #eff6ff;
    color: #1d4ed8;
    padding: 4px 7px;
    font-size: 12px;
}

.ticket-section {
    border-top: 1px solid #e5e7eb;
    overflow-x: auto;
}

.ticket-finance-records {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    border-top: 1px solid #e5e7eb;
}

.ticket-finance-records .ticket-section {
    min-width: 0;
    border-top: 0;
}

.ticket-finance-records .ticket-section + .ticket-section {
    border-left: 1px solid #e5e7eb;
}

.ticket-section-tight .admin-panel-head {
    padding-top: 7px;
    padding-bottom: 7px;
}

.ticket-row {
    display: grid;
    grid-template-columns: repeat(6, minmax(90px, 1fr)) auto;
    gap: 8px;
    align-items: center;
    padding: 8px 12px;
    border-top: 1px solid #f1f5f9;
}

.ticket-reservation-row {
    grid-template-columns: 86px 120px 92px 118px minmax(120px, 1fr) 86px 82px minmax(140px, 1fr) 74px 58px;
    padding-top: 5px;
    padding-bottom: 5px;
}

.ticket-reservation-row input,
.ticket-reservation-row select {
    height: 30px;
    padding: 3px 7px;
}

.ticket-reservation-row .secondary-button {
    min-height: 30px;
    padding: 3px 8px;
}

.ticket-segment-row {
    grid-template-columns: 70px 120px 70px 120px 90px 60px 150px 150px 70px auto;
    padding-top: 6px;
    padding-bottom: 6px;
}

.ticket-passenger-row {
    grid-template-columns: minmax(170px, 1.25fr) 58px 104px 98px minmax(180px, 1.25fr) 104px minmax(145px, 1.05fr) 78px 108px 82px auto;
}

.ticket-doc-status {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 30px;
    padding: 3px 8px;
    border: 1px solid #e5e7eb;
    border-radius: 999px;
    background: #f8fafc;
    color: #64748b;
    font-size: 12px;
    white-space: nowrap;
}

.ticket-doc-status.is-ok {
    border-color: #bbf7d0;
    background: #f0fdf4;
    color: #166534;
}

.ticket-doc-status.is-warn {
    border-color: #fde68a;
    background: #fffbeb;
    color: #92400e;
}

.ticket-doc-status.is-danger {
    border-color: #fecaca;
    background: #fef2f2;
    color: #991b1b;
}

.ticket-money-record-row {
    grid-template-columns: 116px 100px 130px 100px minmax(170px, 1fr) auto;
    padding-top: 6px;
    padding-bottom: 6px;
}

.ticket-events {
    padding: 8px 12px;
    background: #f8fafc;
}

.ticket-event-composer {
    display: grid;
    grid-template-columns: 110px minmax(220px, 1fr) auto;
    gap: 8px;
    padding: 10px 12px;
    border-top: 1px solid #f1f5f9;
}

.ticket-event-composer select,
.ticket-event-composer input {
    min-width: 0;
    height: 34px;
    box-sizing: border-box;
}

.ticket-event-line {
    display: grid;
    grid-template-columns: 150px 70px 1fr;
    gap: 8px;
    padding: 4px 0;
    border-bottom: 1px solid #edf2f7;
    font-size: 13px;
}

.ticket-event-line span {
    color: #6b7280;
}

.ticket-event-line b {
    color: #111827;
}

.ticket-event-line em {
    color: #374151;
    font-style: normal;
}

.ticket-event-empty {
    padding: 6px 0;
}

.ticket-row input,
.ticket-row select {
    min-width: 0;
    width: 100%;
    box-sizing: border-box;
}

.ticket-row .inline-check {
    white-space: nowrap;
}

.ticket-money-row {
    display: grid;
    grid-template-columns: repeat(4, minmax(150px, 1fr));
    gap: 12px;
    padding: 12px;
}

.ticket-money-row label {
    display: grid;
    gap: 5px;
    font-weight: 600;
}

.ticket-money-row input {
    height: 34px;
    padding: 4px 8px;
}

.ticket-finance-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(120px, 1fr));
    gap: 8px;
    padding: 0 12px 12px;
    font-size: 14px;
}

.ticket-finance-summary span {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    border: 1px solid #e5e7eb;
    background: #f8fafc;
    padding: 7px 9px;
}

.ticket-finance-summary b {
    color: #111827;
}

@media (max-width: 980px) {
    .ticket-lab-grid,
    .ticket-home-grid,
    .ticket-home-kpis,
    .ticket-flow-strip,
    .ticket-report-grid,
    .ticket-pipeline-board,
    .ticket-settings-grid,
    .ticket-form-grid,
    .ticket-status-flow,
    .ticket-process-panel,
    .ticket-order-snapshot,
    .ticket-snapshot-main,
    .ticket-row,
    .ticket-segment-row,
    .ticket-passenger-row,
    .ticket-money-record-row,
    .ticket-event-composer,
    .ticket-finance-records,
    .ticket-customer-form,
    .ticket-finance-summary,
    .ticket-money-row {
        grid-template-columns: 1fr;
    }

    .ticket-nav-search {
        width: 100%;
        margin-left: 0;
    }

    .ticket-nav-search input {
        flex: 1;
        width: auto;
    }
}
