@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700;800&display=swap');

:root {
    --ui-font-scale: 1;
    --accent: #25d366;
    --accent-strong: #16a34a;
    --accent-soft: rgba(37, 211, 102, 0.12);
    --page: #f4f7f5;
    --panel: rgba(255, 255, 255, 0.92);
    --panel-strong: rgba(255, 255, 255, 0.98);
    --panel-muted: #f7faf8;
    --line: #dde7e0;
    --text: #17212b;
    --text-soft: #4b5a68;
    --text-muted: #6b7280;
    --warning: #f59e0b;
    --shadow: 0 14px 40px rgba(15, 23, 42, 0.05);
}

* {
    box-sizing: border-box;
}

html {
    min-height: 100%;
    height: 100%;
    font-size: calc(16px * var(--ui-font-scale));
}

body {
    min-height: 100%;
    height: 100%;
}

body {
    margin: 0;
    background:
        radial-gradient(circle at top right, rgba(37, 211, 102, 0.12), transparent 28%),
        radial-gradient(circle at left center, rgba(22, 163, 74, 0.06), transparent 30%),
        linear-gradient(180deg, #ffffff 0%, var(--page) 100%);
    color: var(--text);
    font-family: 'Manrope', 'Segoe UI', sans-serif;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
}

body::before {
    content: '';
    position: fixed;
    inset: 0;
    pointer-events: none;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.14) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.14) 1px, transparent 1px);
    background-size: 72px 72px;
    mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.18), transparent 65%);
}

.app-shell {
    position: relative;
    z-index: 1;
    min-height: 100vh;
    height: 100vh;
    min-height: 100dvh;
    height: 100dvh;
    display: flex;
    flex-direction: column;
}

.app-topbar {
    position: sticky;
    top: 0;
    flex: 0 0 auto;
    z-index: 30;
    padding: 0.85rem 1.25rem;
    border-bottom: 1px solid rgba(221, 231, 224, 0.92);
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(18px);
}

.topbar-inner {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0.85rem 1rem;
    align-items: center;
}

.brand-block {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.brand-lockup {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    color: var(--text);
    text-decoration: none;
}

.brand-lockup strong {
    display: block;
    font-size: 1.08rem;
    letter-spacing: -0.03em;
}

.brand-mark {
    width: 12rem;
    height: 3.25rem;
    border-radius: 0.9rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    padding: 0.28rem 0.55rem;
    border: 1px solid #dde2ea;
    background: #eef0f3;
}

.brand-mark img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.brand-kicker,
.section-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.brand-kicker {
    color: var(--text-muted);
}

.section-tag {
    color: var(--accent-strong);
}

.brand-block p,
.card-copy {
    margin: 0;
    color: var(--text-soft);
    font-size: 0.9rem;
    line-height: 1.55;
}

.sidebar-nav {
    grid-column: 1 / -1;
    order: 3;
    width: 100%;
    min-width: 0;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.35rem;
    overflow: visible;
    padding: 0.18rem;
    scrollbar-width: thin;
}

.sidebar-dropdown {
    position: relative;
    flex: 0 0 auto;
}

.sidebar-link {
    width: auto;
    min-height: 2.55rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    flex: 0 0 auto;
    padding: 0.64rem 0.82rem;
    border: 1px solid transparent;
    border-radius: 0.85rem;
    background: transparent;
    color: var(--text-soft);
    text-decoration: none;
    font-size: 0.86rem;
    font-weight: 700;
    white-space: nowrap;
    transition: 180ms ease;
}

.sidebar-dropdown-toggle {
    border: 1px solid transparent;
    cursor: pointer;
}

.sidebar-link i {
    width: 1.1rem;
    color: inherit;
}

.sidebar-dropdown-toggle .dropdown-chevron {
    width: auto;
    margin-left: 0.1rem;
    font-size: 0.72rem;
    transition: transform 160ms ease;
}

.sidebar-link:hover,
.sidebar-link.is-active {
    color: var(--accent-strong);
    background: var(--accent-soft);
    border-color: rgba(22, 163, 74, 0.12);
    transform: translateY(-1px);
}

.sidebar-dropdown:hover .sidebar-dropdown-toggle,
.sidebar-dropdown:focus-within .sidebar-dropdown-toggle {
    color: var(--accent-strong);
    background: var(--accent-soft);
    border-color: rgba(22, 163, 74, 0.12);
}

.sidebar-dropdown:hover .dropdown-chevron,
.sidebar-dropdown:focus-within .dropdown-chevron {
    transform: rotate(180deg);
}

.sidebar-dropdown-menu {
    position: absolute;
    top: calc(100% + 0.45rem);
    left: 0;
    z-index: 70;
    min-width: 15.25rem;
    display: none;
    padding: 0.42rem;
    border: 1px solid rgba(221, 231, 224, 0.96);
    border-radius: 0.9rem;
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 18px 42px rgba(15, 23, 42, 0.12);
}

.sidebar-dropdown:hover .sidebar-dropdown-menu,
.sidebar-dropdown:focus-within .sidebar-dropdown-menu {
    display: grid;
    gap: 0.18rem;
}

.sidebar-dropdown-item {
    min-height: 2.35rem;
    display: flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.56rem 0.68rem;
    border-radius: 0.68rem;
    color: var(--text-soft);
    text-decoration: none;
    font-size: 0.86rem;
    font-weight: 750;
    white-space: nowrap;
    transition: 160ms ease;
}

.sidebar-dropdown-item i {
    width: 1rem;
}

.sidebar-dropdown-item:hover,
.sidebar-dropdown-item.is-active {
    color: var(--accent-strong);
    background: rgba(37, 211, 102, 0.12);
}

.sidebar-note {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 0.55rem;
    margin-top: 1.1rem;
    padding: 0.85rem 0.9rem;
    border: 1px solid rgba(22, 163, 74, 0.14);
    border-radius: 1rem;
    background: var(--panel-muted);
    color: var(--text-soft);
    font-size: 0.78rem;
    line-height: 1.45;
}

.user-panel {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto auto;
    gap: 0.62rem;
    align-items: center;
    width: 22rem;
    margin-top: 0;
    padding: 0.55rem 0.65rem;
    border: 1px solid rgba(221, 231, 224, 0.92);
    border-radius: 0.95rem;
    background: var(--panel-muted);
}

.user-avatar {
    width: 2.25rem;
    height: 2.25rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.8rem;
    background: var(--accent-soft);
    color: var(--accent-strong);
    font-weight: 800;
}

.user-avatar-button {
    border: 0;
    cursor: pointer;
    transition: 160ms ease;
}

.user-avatar-button::after {
    display: none;
}

.user-avatar-button:hover,
.user-avatar-button:focus-visible {
    background: var(--accent-strong);
    color: #fff;
    outline: none;
}

.user-menu .dropdown-menu {
    min-width: 11.5rem;
    padding: 0.35rem;
    border: 1px solid rgba(221, 231, 224, 0.96);
    border-radius: 0.7rem;
    box-shadow: 0 14px 28px rgba(15, 23, 42, 0.14);
}

.user-menu .dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    border-radius: 0.46rem;
    color: var(--text-soft);
    font-size: 0.84rem;
    font-weight: 750;
}

.user-menu .dropdown-item:hover,
.user-menu .dropdown-item:focus-visible {
    background: var(--accent-soft);
    color: var(--accent-strong);
}

.password-change-modal .modal-content {
    border: 1px solid rgba(221, 231, 224, 0.96);
    border-radius: 0.85rem;
    box-shadow: 0 22px 56px rgba(15, 23, 42, 0.2);
}

.password-change-modal .modal-header,
.password-change-modal .modal-footer {
    padding: 1rem 1.2rem;
}

.password-change-modal .modal-body {
    padding: 1.15rem 1.2rem;
}

.modal-kicker {
    margin: 0 0 0.12rem;
    color: var(--text-muted);
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
}

.user-panel strong,
.user-panel small {
    display: block;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.user-panel strong {
    font-size: 0.86rem;
}

.user-panel small {
    color: var(--text-muted);
    font-size: 0.72rem;
    font-weight: 700;
}

.font-zoom-controls {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.18rem;
    border: 1px solid rgba(221, 231, 224, 0.92);
    border-radius: 0.75rem;
    background: rgba(255, 255, 255, 0.72);
}

.zoom-button {
    width: 2.05rem;
    height: 2.05rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 0.58rem;
    background: transparent;
    color: var(--text-soft);
    font-size: 0.78rem;
    font-weight: 900;
    line-height: 1;
    transition: 160ms ease;
}

.zoom-button:hover:not(:disabled),
.zoom-button:focus-visible {
    color: var(--accent-strong);
    background: var(--accent-soft);
    outline: none;
}

.zoom-button:disabled {
    cursor: not-allowed;
    opacity: 0.42;
}

.font-zoom-value {
    min-width: 2.55rem;
    color: var(--text-muted);
    font-size: 0.72rem;
    font-weight: 800;
    text-align: center;
}

.status-dot {
    width: 0.62rem;
    height: 0.62rem;
    margin-top: 0.25rem;
    border-radius: 999px;
    background: var(--accent-strong);
    box-shadow: 0 0 0 0.22rem rgba(22, 163, 74, 0.12);
}

.app-content {
    min-width: 0;
    min-height: 0;
    flex: 1 1 auto;
    overflow: auto;
    padding: 1.25rem;
}

.app-content--fixed-list {
    --fixed-list-scroll-padding: 1.25rem;
    height: 0;
    display: block;
    overflow: auto;
    overscroll-behavior: contain;
}

.hero-panel,
.content-card,
.metric-card {
    border: 1px solid rgba(221, 231, 224, 0.92);
    border-radius: 1.5rem;
    background: var(--panel);
    backdrop-filter: blur(18px);
    box-shadow: var(--shadow);
}

.hero-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 1rem;
    align-items: center;
    padding: 1.35rem 1.5rem;
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(247, 250, 248, 0.92)),
        radial-gradient(circle at top right, rgba(37, 211, 102, 0.12), transparent 36%);
}

.hero-panel h1,
.content-card h2 {
    margin: 0.35rem 0 0.55rem;
    letter-spacing: -0.045em;
}

.hero-panel h1 {
    max-width: 18ch;
    font-size: clamp(1.55rem, 2.8vw, 2.25rem);
    line-height: 1.05;
}

.hero-panel p {
    max-width: 58rem;
    margin: 0;
    color: var(--text-soft);
    font-size: 0.94rem;
    line-height: 1.55;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 0.7rem;
}

.hero-actions .btn-lg {
    min-height: 2.75rem;
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    white-space: nowrap;
}

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

.metric-card {
    min-height: 8.1rem;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 0.85rem;
    align-items: start;
    padding: 1.05rem 1.1rem;
}

.metric-icon {
    width: 2.55rem;
    height: 2.55rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.9rem;
    background: var(--accent-soft);
    color: var(--accent-strong);
    font-size: 1.05rem;
}

.metric-card p,
.metric-card small {
    margin: 0;
    color: var(--text-soft);
}

.metric-card p {
    font-size: 0.82rem;
    font-weight: 700;
}

.metric-card strong {
    display: block;
    margin: 0.18rem 0;
    font-size: clamp(1.45rem, 2.4vw, 1.95rem);
    line-height: 1;
    letter-spacing: -0.04em;
}

.metric-card small {
    font-size: 0.78rem;
}

.dashboard-grid,
.report-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
}

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

.content-card {
    min-width: 0;
    padding: 1.25rem;
}

.crud-list-page {
    min-width: 0;
}

.app-content--fixed-list .hero-panel {
    flex: initial;
}

.app-content--fixed-list .crud-list-page {
    min-height: auto;
    display: block;
}

.crud-page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 0.85rem;
}

.crud-page-header h2 {
    margin: 0;
    color: var(--text);
    font-size: clamp(1.28rem, 1.8vw, 1.62rem);
    line-height: 1.12;
    letter-spacing: -0.035em;
}

.crud-page-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 0.55rem;
}

.crud-page-actions:empty {
    display: none;
}

.table-filter-bar {
    margin-top: 0.75rem;
    padding: 0;
}

.table-panel {
    min-width: 0;
    overflow: hidden;
    border: 1px solid rgba(221, 231, 224, 0.92);
    border-radius: 1rem;
    background: rgba(255, 255, 255, 0.88);
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.045);
}

.app-content--fixed-list .table-panel {
    width: max-content;
    min-width: 100%;
    min-height: auto;
    display: block;
    overflow: visible;
}

.app-content--fixed-list .column-filter-form {
    min-height: auto;
    display: block;
}

.app-content--fixed-list .table-responsive {
    min-height: auto;
    overflow: visible;
}

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

.content-card h2 {
    font-size: clamp(1.15rem, 1.7vw, 1.45rem);
}

.toolbar-search {
    min-width: min(100%, 320px);
    min-height: 2.75rem;
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.72rem 0.9rem;
    border: 1px solid var(--line);
    border-radius: 1rem;
    background: rgba(255, 255, 255, 0.92);
}

.toolbar-search input {
    min-width: 0;
    flex: 1;
    border: 0;
    outline: 0;
    background: transparent;
    color: var(--text);
    font-size: 0.9rem;
}

.toolbar-search i {
    color: var(--text-muted);
}

.app-table {
    --bs-table-bg: transparent;
    --bs-table-border-color: rgba(221, 231, 224, 0.9);
    margin-bottom: 0;
}

.app-table.is-column-resizable {
    table-layout: fixed;
    min-width: 1px;
}

.app-table thead th {
    position: relative;
    padding: 0.85rem 0.95rem;
    color: var(--text-muted);
    background: rgba(247, 250, 248, 0.98);
    font-size: 0.7rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.app-content--fixed-list .app-table thead th {
    position: sticky;
    top: calc(var(--fixed-list-scroll-padding) * -1);
    z-index: 5;
    box-shadow: inset 0 -1px rgba(221, 231, 224, 0.96);
}

.app-content--fixed-list .app-table thead tr.column-filter-row th {
    top: calc(2.72rem - var(--fixed-list-scroll-padding));
    z-index: 4;
}

.app-content--fixed-list .app-table thead tr.table-summary-row th {
    top: calc(5.78rem - var(--fixed-list-scroll-padding));
    z-index: 3;
}

.app-table.is-column-resizable thead th {
    user-select: none;
}

.column-filter-form {
    margin: 0;
}

.table-bulk-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.55rem;
    min-height: 2.5rem;
}

.table-bulk-selection {
    margin-right: auto;
    color: var(--text-muted);
    font-size: 0.8rem;
    font-weight: 700;
}

.load-selection-header,
.load-selection-cell {
    width: 44px;
    min-width: 44px;
    max-width: 44px;
    text-align: center;
}

.load-selection-control {
    width: 1rem;
    height: 1rem;
    accent-color: var(--accent-strong);
    cursor: pointer;
}

.column-sort-link {
    min-width: 0;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    color: inherit;
    text-decoration: none;
}

.column-sort-static {
    display: inline-flex;
    align-items: center;
    min-height: 1rem;
}

.sort-priority {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1rem;
    height: 1rem;
    padding: 0 0.2rem;
    border-radius: 999px;
    background: #3568ff;
    color: #ffffff;
    font-size: 0.58rem;
    font-weight: 800;
    line-height: 1;
}

.column-sort-link span {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
}

.column-sort-link i {
    flex: 0 0 auto;
    color: #94a3b8;
    font-size: 0.84rem;
    opacity: 0.72;
}

.column-sort-link:hover,
.column-sort-link.is-active {
    color: var(--accent-strong);
}

.column-sort-link.is-active i {
    color: var(--accent-strong);
    opacity: 1;
}

.app-table thead tr.column-filter-row th {
    padding: 0.45rem 0.55rem 0.62rem;
    background: rgba(250, 252, 251, 0.98);
    letter-spacing: 0;
    text-transform: none;
    overflow: visible;
}

.app-table thead tr.table-summary-row th {
    padding: 0.46rem 0.95rem;
    background: rgba(242, 247, 244, 0.98);
    color: #475569;
    font-size: 0.74rem;
    font-weight: 700;
    letter-spacing: 0;
    text-transform: none;
    box-shadow: inset 0 -1px rgba(203, 213, 225, 0.8);
}

.app-table thead tr.table-summary-row th.has-summary-value {
    color: #1e293b;
}

.summary-label {
    color: #64748b;
}

.summary-value {
    white-space: nowrap;
}

.column-filter-control {
    width: 100%;
    min-width: 2.9rem;
    height: 2.05rem;
    border: 1px solid rgba(203, 213, 225, 0.95);
    border-radius: 0.55rem;
    background: #ffffff;
    color: var(--text);
    font-size: 0.76rem;
    font-weight: 700;
    letter-spacing: 0;
    outline: 0;
    padding: 0.32rem 0.45rem;
    box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.03);
}

.column-filter-control::placeholder {
    color: #94a3b8;
    font-weight: 600;
}

.column-filter-control:focus {
    border-color: rgba(22, 163, 74, 0.58);
    box-shadow: 0 0 0 0.16rem rgba(37, 211, 102, 0.12);
}

.app-table .action-header-cell {
    height: 5.78rem;
    padding: 0.68rem 0.55rem;
    text-align: right;
    vertical-align: top;
    overflow: hidden;
    z-index: 6;
}

.actions-column-label {
    display: block;
    padding-right: 0.2rem;
}

.actions-column-toolbar {
    display: flex;
    justify-content: flex-end;
    gap: 0.32rem;
    margin-top: 0.5rem;
}

.actions-column-toolbar .icon-button {
    width: 2.05rem;
    height: 2.05rem;
    background: #ffffff;
}

.col-resize-handle {
    position: absolute;
    top: 0.45rem;
    right: 0;
    bottom: 0.45rem;
    width: 0.7rem;
    cursor: col-resize;
    border-right: 2px solid transparent;
    opacity: 0;
    transition: 160ms ease;
}

.app-table.is-column-resizable thead th:hover .col-resize-handle,
.col-resize-handle:hover,
.resizing-columns .col-resize-handle {
    border-right-color: rgba(22, 163, 74, 0.42);
    opacity: 1;
}

.resizing-columns,
.resizing-columns * {
    cursor: col-resize !important;
    user-select: none !important;
}

.app-table tbody td {
    padding: 0.5rem 0.72rem;
    color: var(--text-soft);
    font-size: 0.9rem;
    line-height: 1.35;
    vertical-align: middle;
    overflow: hidden;
    text-overflow: clip;
    white-space: nowrap;
    transition: background 160ms ease, box-shadow 160ms ease;
}

.app-table tbody td > strong,
.app-table tbody td > span:not(.status-badge):not(.freight-rate-availability-status):not(.launch-queue-placeholder) {
    display: inline;
    margin-top: 0;
    overflow: hidden;
    text-overflow: clip;
    white-space: nowrap;
}

.app-table tbody td > strong + span:not(.status-badge):not(.freight-rate-availability-status):not(.launch-queue-placeholder)::before {
    content: ' · ';
}

.app-table tbody td.editable-cell {
    cursor: cell;
}

.app-table tbody td.editable-cell:hover {
    background: rgba(37, 211, 102, 0.06);
    box-shadow: inset 0 0 0 1px rgba(22, 163, 74, 0.12);
}

.programming-status-cell,
.closure-advance-cell {
    padding: 0.2rem 0.4rem !important;
}

.programming-status-select,
.closure-advance-select {
    width: 100%;
    min-width: 0;
    height: 1.85rem;
    padding: 0.25rem 1.55rem 0.25rem 0.45rem;
    overflow: hidden;
    border: 1px solid transparent;
    border-radius: 0.25rem;
    background-color: transparent;
    color: var(--text);
    font: inherit;
    font-weight: 700;
    text-overflow: ellipsis;
    cursor: pointer;
}

.programming-status-select:hover,
.programming-status-select:focus,
.closure-advance-select:hover,
.closure-advance-select:focus {
    border-color: #b8c8c4;
    background-color: #fff;
    outline: none;
}

.programming-status-select.is-saving,
.closure-advance-select.is-saving {
    cursor: progress;
    opacity: 0.65;
}

.app-table tbody td.is-inline-editing {
    padding: 0.42rem 0.5rem;
    background: rgba(255, 255, 255, 0.98);
    box-shadow: inset 0 0 0 2px rgba(22, 163, 74, 0.28);
}

.app-table tbody .actions-cell .icon-button {
    width: 1.9rem;
    height: 1.9rem;
    border-radius: 0.6rem;
}

.app-table tbody .launch-checkbox-control,
.app-table tbody .launch-queue-placeholder {
    width: 1.9rem;
    height: 1.9rem;
}

.inline-edit-input {
    width: 100%;
    min-width: 8rem;
    height: 2.35rem;
    border: 1px solid rgba(22, 163, 74, 0.34);
    border-radius: 0.65rem;
    background: #ffffff;
    color: var(--text);
    font: inherit;
    font-size: 0.9rem;
    font-weight: 700;
    outline: 0;
    padding: 0.45rem 0.65rem;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.06);
}

.inline-edit-input:focus {
    border-color: var(--accent-strong);
    box-shadow: 0 0 0 0.2rem rgba(37, 211, 102, 0.14);
}

.app-table tbody td.is-inline-saving {
    background: rgba(245, 158, 11, 0.08);
    box-shadow: inset 0 0 0 1px rgba(245, 158, 11, 0.22);
}

.app-table tbody td.is-inline-saved {
    background: rgba(37, 211, 102, 0.1);
    box-shadow: inset 0 0 0 1px rgba(22, 163, 74, 0.24);
}

.app-table tbody td.is-inline-error {
    background: rgba(239, 68, 68, 0.08);
    box-shadow: inset 0 0 0 1px rgba(239, 68, 68, 0.24);
}

.app-table tbody td strong {
    display: block;
    color: var(--text);
    font-size: 0.94rem;
}

.app-table tbody td span {
    display: block;
    margin-top: 0.12rem;
    color: var(--text-muted);
    font-size: 0.78rem;
}

.inline-password-overlay {
    position: fixed;
    inset: 0;
    z-index: 1200;
    display: grid;
    place-items: center;
    padding: 1.5rem;
    background: rgba(15, 23, 42, 0.36);
    backdrop-filter: blur(2px);
}

.inline-password-dialog {
    width: min(100%, 420px);
    border: 1px solid rgba(203, 213, 225, 0.9);
    border-radius: 0.85rem;
    background: #ffffff;
    box-shadow: 0 22px 55px rgba(15, 23, 42, 0.22);
    padding: 1.25rem;
}

.inline-password-dialog h3 {
    margin: 0 0 0.35rem;
    color: var(--text);
    font-size: 1rem;
    font-weight: 800;
}

.inline-password-dialog p {
    margin: 0 0 1rem;
    color: var(--text-muted);
    font-size: 0.86rem;
    line-height: 1.45;
}

.inline-password-input {
    width: 100%;
    height: 2.75rem;
    border: 1px solid rgba(203, 213, 225, 0.95);
    border-radius: 0.65rem;
    padding: 0.55rem 0.75rem;
    font-size: 0.95rem;
    outline: 0;
}

.inline-password-input:focus {
    border-color: rgba(37, 99, 235, 0.7);
    box-shadow: 0 0 0 0.2rem rgba(37, 99, 235, 0.12);
}

.inline-password-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.6rem;
    margin-top: 1rem;
}

.launch-action-cell {
    text-align: center;
}

.launch-action-cell form {
    margin: 0;
}

.launch-checkbox-control {
    width: 2rem;
    height: 2rem;
    display: inline-grid;
    place-items: center;
    cursor: pointer;
    padding: 0;
    border: 0;
    background: transparent;
}

.launch-checkbox-control span {
    width: 1.15rem;
    height: 1.15rem;
    display: block;
    border: 2px solid rgba(22, 163, 74, 0.55);
    border-radius: 0.3rem;
    background: #ffffff;
    box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.04);
}

.launch-checkbox-control:hover span,
.launch-checkbox-control:focus-visible span {
    border-color: var(--accent-strong);
    box-shadow: 0 0 0 0.2rem rgba(37, 211, 102, 0.14);
}

.launch-checkbox-control.is-loading {
    cursor: wait;
    opacity: 0.68;
}

.launch-checkbox-control.is-loading span {
    border-color: var(--accent-strong);
    background:
        linear-gradient(135deg, transparent 0 44%, var(--accent-strong) 45% 55%, transparent 56% 100%),
        #ffffff;
}

.launch-queue-placeholder {
    width: 2rem;
    height: 2rem;
    display: inline-block;
}

.status-badge {
    width: fit-content;
    min-height: 1.9rem;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    padding: 0.28rem 0.7rem;
    border-radius: 999px;
    background: rgba(245, 158, 11, 0.16);
    color: #a15c00 !important;
    font-size: 0.76rem !important;
    font-weight: 800;
    white-space: nowrap;
}

.status-badge.is-success {
    background: rgba(22, 163, 74, 0.16);
    color: var(--accent-strong) !important;
}

.status-badge.is-muted {
    background: rgba(75, 90, 104, 0.12);
    color: var(--text-soft) !important;
}

.icon-button {
    width: 2.25rem;
    height: 2.25rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--line);
    border-radius: 0.8rem;
    background: var(--panel-muted);
    color: var(--text-soft);
}

.progress-stack {
    display: grid;
    gap: 0.95rem;
}

.progress-stack > div {
    display: grid;
    gap: 0.35rem;
}

.progress-stack span,
.progress-stack strong {
    font-size: 0.88rem;
}

.progress-stack span {
    color: var(--text-soft);
}

.progress-stack strong {
    color: var(--text);
}

.progress {
    height: 0.42rem;
    overflow: hidden;
    border-radius: 999px;
    background: rgba(75, 90, 104, 0.16);
}

.progress span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--accent-strong), var(--accent));
}

.status-chart {
    height: 0.82rem;
    display: flex;
    overflow: hidden;
    margin-top: 1.2rem;
    border-radius: 999px;
    background: rgba(75, 90, 104, 0.12);
}

.chart-segment {
    width: var(--value);
    min-width: 0.35rem;
    background: var(--warning);
}

.chart-segment.is-success {
    background: var(--accent-strong);
}

.chart-segment.is-muted {
    background: #8a98a6;
}

.filter-chips,
.copy-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
}

.crud-filters {
    display: grid;
    grid-template-columns: minmax(220px, 1fr) minmax(180px, 260px) auto;
    gap: 0.7rem;
    align-items: center;
}

.response-policy-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(320px, 520px);
    gap: 1rem;
    align-items: end;
    padding: 1rem;
    border: 1px solid rgba(16, 24, 40, 0.08);
    border-radius: 0.9rem;
    background: #f8fafc;
}

.response-policy-panel h3 {
    margin: 0.2rem 0 0.25rem;
    font-size: 1rem;
    color: var(--text-strong);
}

.response-policy-panel p {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.88rem;
}

.response-policy-form {
    display: flex;
    gap: 0.65rem;
    align-items: center;
}

.crud-form {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.9rem;
}

.crud-field {
    min-width: 0;
}

.crud-field.is-wide,
.crud-actions {
    grid-column: 1 / -1;
}

.field-hint {
    display: block;
    margin-top: 0.35rem;
    color: var(--text-muted);
    font-size: 0.78rem;
}

.crud-actions {
    display: inline-flex;
    gap: 0.45rem;
    align-items: center;
    justify-content: flex-end;
}

.app-table .actions-cell {
    display: table-cell;
    white-space: nowrap;
    text-align: right;
}

.app-table td.actions-cell > * {
    display: inline-flex;
    vertical-align: middle;
}

.app-table td.actions-cell > * + * {
    margin-left: 0.45rem;
}

.app-table .actions-cell form {
    display: inline-flex;
    margin: 0;
}

.detail-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.75rem;
}

.detail-item {
    padding: 0.9rem;
    border: 1px solid var(--line);
    border-radius: 1rem;
    background: var(--panel-muted);
}

.detail-item.is-wide {
    grid-column: 1 / -1;
}

.detail-item span {
    display: block;
    color: var(--text-muted);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.detail-item strong {
    display: block;
    margin-top: 0.25rem;
    color: var(--text);
    font-size: 0.92rem;
    line-height: 1.45;
    word-break: break-word;
}

.empty-cell {
    padding: 2rem 1rem !important;
    color: var(--text-muted) !important;
    text-align: center;
}

.filter-chips span {
    min-height: 2.25rem;
    display: inline-flex;
    align-items: center;
    padding: 0.35rem 0.75rem;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--panel-muted);
    color: var(--text-soft);
    font-size: 0.8rem;
    font-weight: 700;
}

.copy-tool textarea {
    border-color: var(--line);
    border-radius: 1rem;
    color: var(--text-soft);
    box-shadow: none;
    resize: vertical;
}

.copy-actions {
    margin-top: 0.9rem;
}

.programming-share-card {
    display: grid;
    gap: 1rem;
}

.programming-share-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
}

.programming-share-head h2 {
    margin: 0.2rem 0 0.35rem;
    color: var(--text-strong);
    font-size: 1.15rem;
}

.programming-share-head p {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.programming-share-preview {
    max-width: 52rem;
    border: 1px solid var(--line);
    border-radius: 0.45rem;
    background: #fff;
    overflow: hidden;
}

.programming-share-message {
    min-height: 17.5rem;
    margin: 0;
    padding: 1.15rem 1.25rem;
    overflow: auto;
    color: var(--text-strong);
    font-family: inherit;
    font-size: 0.95rem;
    line-height: 1.65;
    white-space: pre-wrap;
}

.programming-share-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-height: 4.25rem;
    padding: 0.75rem 1rem;
    border-top: 1px solid var(--line);
    background: var(--panel-muted);
}

.programming-share-feedback {
    color: var(--accent-strong);
    font-size: 0.85rem;
    font-weight: 700;
}

.programming-share-feedback.is-error {
    color: #b42318;
}

.report-card {
    display: grid;
    gap: 0.2rem;
    align-content: start;
}

.report-card .btn {
    width: fit-content;
    margin-top: 0.65rem;
}

.report-actions {
    display: inline-flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 0.55rem;
}

.btn {
    --bs-btn-font-weight: 700;
    --bs-btn-padding-y: 0.66rem;
    --bs-btn-padding-x: 1rem;
    --bs-btn-font-size: 0.9rem;
    --bs-btn-border-radius: 1rem;
}

.btn i {
    margin-right: 0.35rem;
}

.btn-primary {
    --bs-btn-bg: var(--accent-strong);
    --bs-btn-border-color: var(--accent-strong);
    --bs-btn-hover-bg: #13803c;
    --bs-btn-hover-border-color: #13803c;
    --bs-btn-active-bg: #13803c;
    --bs-btn-active-border-color: #13803c;
}

.btn-light {
    --bs-btn-bg: rgba(247, 250, 248, 0.96);
    --bs-btn-border-color: rgba(221, 231, 224, 0.96);
    --bs-btn-hover-bg: rgba(235, 242, 237, 0.96);
    --bs-btn-hover-border-color: rgba(221, 231, 224, 0.96);
    color: var(--text-soft);
}

.auth-page {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 1.25rem;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.22), transparent 34%),
        radial-gradient(circle at top center, rgba(37, 211, 102, 0.18), transparent 32%),
        linear-gradient(160deg, #6aa4b0 0%, #0f8f73 46%, #057333 100%);
}

.auth-card {
    width: min(100%, 410px);
    display: grid;
    gap: 1.05rem;
    padding: 2.45rem 2.45rem 2.3rem;
    border: 1px solid rgba(255, 255, 255, 0.78);
    border-radius: 0.35rem;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 24px 65px rgba(15, 23, 42, 0.18);
}

.auth-avatar {
    width: 6rem;
    height: 6rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    justify-self: center;
    border-radius: 999px;
    background:
        linear-gradient(180deg, rgba(23, 33, 43, 0.08), rgba(23, 33, 43, 0.14)),
        #e7ebea;
    color: #a0a6a8;
    font-size: 3.35rem;
}

.auth-brand {
    display: grid;
    justify-items: center;
    text-align: center;
    padding-bottom: 0.2rem;
}

.auth-brand h1 {
    margin: 0.15rem 0 0;
    color: var(--text);
    font-size: 1.35rem;
    line-height: 1.1;
    letter-spacing: 0;
}

.auth-form {
    display: grid;
    gap: 0.72rem;
}

.auth-field {
    position: relative;
}

.auth-field i {
    position: absolute;
    top: 50%;
    left: 0.95rem;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 0.98rem;
}

.auth-field .form-control {
    min-height: 3rem;
    padding-left: 2.65rem;
    border-color: #cfd7d4;
    border-radius: 0.28rem;
    color: var(--text);
    font-size: 0.92rem;
    box-shadow: none;
}

.auth-field .form-control:focus {
    border-color: var(--accent-strong);
    box-shadow: 0 0 0 0.2rem rgba(22, 163, 74, 0.12);
}

.auth-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
    margin: 0.15rem 0 0.25rem;
    color: var(--text-soft);
    font-size: 0.88rem;
}

.auth-options .form-check {
    min-height: auto;
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    margin: 0;
    padding-left: 0;
}

.auth-options .form-check-input {
    width: 0.95rem;
    height: 0.95rem;
    float: none;
    margin: 0;
    border-color: #b8c2bf;
}

.auth-options .form-check-input:checked {
    background-color: var(--accent-strong);
    border-color: var(--accent-strong);
}

.auth-options a {
    color: #3b8da0;
    font-weight: 700;
    text-decoration: none;
    white-space: nowrap;
}

.auth-options a:hover {
    color: var(--accent-strong);
}

.auth-form .btn-primary {
    min-height: 3rem;
    border-radius: 0.28rem;
}

.pagination-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding-top: 1rem;
    color: var(--text-soft);
    font-size: 0.86rem;
}

.pagination-actions {
    display: inline-flex;
    gap: 0.45rem;
}

@media (max-width: 1199.98px) {
    .topbar-inner {
        grid-template-columns: minmax(0, 1fr) auto;
    }

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

@media (max-width: 767.98px) {
    .app-topbar {
        padding: 0.7rem 0.8rem;
    }

    .topbar-inner {
        grid-template-columns: 1fr;
        gap: 0.65rem;
    }

    .brand-block {
        justify-content: center;
    }

    .brand-block p {
        display: none;
    }

    .brand-mark {
        width: min(13rem, 100%);
    }

    .sidebar-nav {
        justify-content: flex-start;
        margin-inline: -0.2rem;
        padding-bottom: 0.32rem;
        overflow: visible;
    }

    .sidebar-link {
        min-height: 2.45rem;
        padding: 0.58rem 0.72rem;
    }

    .user-panel {
        width: 100%;
    }

    .app-content {
        padding: 0.8rem;
    }

    .app-content--fixed-list {
        --fixed-list-scroll-padding: 0.8rem;
    }

    .hero-panel,
    .card-head,
    .crud-page-header {
        grid-template-columns: 1fr;
        flex-direction: column;
        align-items: stretch;
    }

    .hero-panel {
        padding: 1rem;
    }

    .hero-actions {
        justify-content: flex-start;
    }

    .metrics-grid,
    .dashboard-grid,
    .report-grid {
        grid-template-columns: 1fr;
    }

    .span-2 {
        grid-column: span 1;
    }

    .content-card,
    .metric-card {
        border-radius: 1.2rem;
        padding: 1rem;
    }

    .crud-filters,
    .crud-form,
    .response-policy-panel,
    .detail-grid {
        grid-template-columns: 1fr;
    }

    .crud-page-actions {
        justify-content: flex-start;
    }

    .response-policy-form {
        flex-direction: column;
        align-items: stretch;
    }
}
.inline-feedback {
    position: fixed;
    right: 20px;
    bottom: 20px;
    z-index: 1100;
    max-width: min(420px, calc(100vw - 40px));
    padding: 11px 14px;
    border: 1px solid #f0b6b6;
    border-radius: 6px;
    background: #fff7f7;
    color: #9a2828;
    box-shadow: 0 10px 26px rgba(38, 48, 72, 0.16);
    font-size: 13px;
    font-weight: 600;
    opacity: 0;
    pointer-events: none;
    transform: translateY(8px);
    transition: opacity 160ms ease, transform 160ms ease;
}

.inline-feedback.is-visible {
    opacity: 1;
    transform: translateY(0);
}
.available-load-cascade-form {
    margin: 0;
    width: 100%;
    min-width: 150px;
    border: 0;
    border-radius: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    padding: 4px 20px 4px 0;
    cursor: pointer;
}

.available-load-cascade-form:focus {
    outline: 2px solid rgba(53, 104, 255, 0.28);
    outline-offset: 2px;
}

.freight-rate-suggestion-input {
    width: 100%;
    min-width: 150px;
    border: 0;
    border-radius: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    padding: 4px 0;
}

.freight-rate-suggestion-input:focus {
    outline: 2px solid rgba(53, 104, 255, 0.28);
    outline-offset: 2px;
}

.column-multi-filter {
    position: relative;
    min-width: 132px;
}

.column-multi-filter-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
    width: 100%;
    text-align: left;
}

.column-multi-filter-panel {
    position: absolute;
    z-index: 30;
    top: calc(100% + 6px);
    left: 0;
    width: max-content;
    min-width: 190px;
    max-width: 280px;
    padding: 8px;
    border: 1px solid #d9e1ef;
    border-radius: 6px;
    background: #ffffff;
    box-shadow: 0 10px 24px rgba(28, 43, 74, 0.16);
}

.column-multi-filter-options {
    display: grid;
    gap: 4px;
    max-height: 220px;
    overflow-y: auto;
    padding: 2px;
}

.column-multi-filter-option {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 5px 6px;
    border-radius: 4px;
    color: #26334d;
    cursor: pointer;
    font-size: 12px;
    font-weight: 600;
}

.column-multi-filter-option:hover {
    background: #f2f6fd;
}

.column-multi-filter-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid #e8edf5;
}

.column-date-filter-panel {
    min-width: 278px;
    padding: 10px;
}

.column-date-filter-modes {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3px;
    padding: 3px;
    border-radius: 5px;
    background: #f0f4fa;
}

.column-date-filter-modes button {
    min-height: 28px;
    padding: 4px 6px;
    border: 0;
    border-radius: 4px;
    background: transparent;
    color: #64738f;
    font: inherit;
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
}

.column-date-filter-modes button.is-active {
    background: #ffffff;
    color: #2d61da;
    box-shadow: 0 1px 3px rgba(31, 58, 105, 0.14);
}

.column-date-filter-calendar {
    margin-top: 9px;
}

.column-calendar-navigation {
    display: grid;
    grid-template-columns: 30px 1fr 30px;
    align-items: center;
    gap: 6px;
    margin-bottom: 8px;
    text-align: center;
}

.column-calendar-navigation strong {
    color: #26334d;
    font-size: 12px;
    font-weight: 750;
}

.column-calendar-navigation .icon-button {
    width: 30px;
    height: 30px;
    min-width: 30px;
}

.column-calendar-weekdays,
.column-calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 3px;
}

.column-calendar-weekdays {
    margin-bottom: 3px;
}

.column-calendar-weekdays span {
    color: #8290aa;
    font-size: 10px;
    font-weight: 600;
    text-align: center;
}

.column-calendar-option {
    min-height: 30px;
    padding: 3px;
    border: 1px solid transparent;
    border-radius: 4px;
    background: transparent;
    color: #2b3852;
    font: inherit;
    font-size: 11px;
    font-weight: 650;
    cursor: pointer;
}

.column-calendar-option:hover,
.column-calendar-option:focus-visible {
    border-color: #b7cbfa;
    background: #edf3ff;
    outline: 0;
}

.column-calendar-option.is-covered {
    background: #f2f6ff;
    color: #4867ae;
}

.column-calendar-option.is-today {
    border-color: #8eacf7;
    background: #eaf1ff;
    color: #244fa9;
    box-shadow: inset 0 0 0 1px rgba(53, 104, 255, 0.12);
}

.column-calendar-option.is-selected {
    border-color: #3568ff;
    background: #3568ff;
    color: #ffffff;
}

.column-calendar-days .is-empty {
    min-height: 30px;
}

.column-calendar-months,
.column-calendar-years {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 5px;
}

.column-calendar-months .column-calendar-option,
.column-calendar-years .column-calendar-option {
    min-height: 34px;
}

.column-date-filter-panel .column-multi-filter-actions {
    justify-content: space-between;
}

.freight-rate-availability-cell {
    text-align: center;
}

.freight-rate-availability-status {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #1e9b64;
    font-size: 1rem;
}
