.logistics-board-shell {
    width: min(100%, 1472px);
    max-width: 1472px;
    margin: 0 auto;
    padding: 0.35rem 0 1.35rem;
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.logistics-detail-shell {
    width: min(100%, 1320px);
    max-width: 1320px;
    margin: 0 auto;
    padding: 0.35rem clamp(1rem, 3vw, 2.4rem) 1.35rem;
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.logistics-board-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.logistics-board-filters {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    flex: 1 1 auto;
    min-width: 0;
    width: 100%;
}

.logistics-board-search {
    max-width: 560px;
}

.logistics-board-list {
    width: 100%;
    display: block;
    gap: 0;
}

.logistics-table-shell {
    margin-top: 0;
    overflow-x: hidden;
}

.logistics-table {
    table-layout: fixed;
}

.logistics-col-status {
    width: 11%;
}

.logistics-col-order {
    width: 25%;
}

.logistics-col-party {
    width: 28%;
}

.logistics-col-movement {
    width: 24%;
}

.logistics-col-actions {
    width: 12%;
}

.logistics-table .shipment-cell,
.logistics-table .supplier-cell,
.logistics-table .inspector-cell,
.logistics-table .date-cell,
.logistics-table .deadline-cell {
    min-width: 0;
}

.logistics-table .qc-compact-line span {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.logistics-table .logistics-status-badge {
    min-height: 0;
    padding: 0.34rem 0.72rem;
    font-size: 0.76rem;
    text-transform: none;
}

.logistics-table-actions-cell {
    white-space: nowrap;
}

.logistics-table-actions {
    justify-content: flex-end;
    gap: 0.28rem;
    flex-wrap: nowrap;
}

.logistics-table-action {
    width: 34px;
    min-width: 34px;
    height: 32px;
    min-height: 32px;
    padding: 0;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.logistics-board-cta:disabled {
    cursor: not-allowed;
    opacity: 0.58;
    box-shadow: none;
}

.logistics-rollout-note,
.logistics-readonly-note,
.logistics-empty-copy {
    margin: 0;
    color: #64748b;
    font-size: 0.92rem;
    line-height: 1.5;
}

.logistics-row-shell {
    width: 100%;
}

.logistics-row {
    grid-template-columns: 58px minmax(0, 1fr) auto;
    min-height: 98px;
    padding: 1rem 1rem;
    border: 1px solid rgba(203, 213, 225, 0.72);
    border-radius: 8px;
    box-shadow: none;
}

.logistics-row-icon--draft,
.logistics-row-icon--booked {
    background: linear-gradient(145deg, rgba(232, 244, 241, 0.96) 0%, rgba(244, 248, 246, 0.98) 100%);
    color: #526760;
}

.logistics-row-icon--moving {
    background: linear-gradient(145deg, rgba(219, 234, 254, 0.96) 0%, rgba(239, 246, 255, 0.98) 100%);
    color: #2563eb;
}

.logistics-row-icon--delivered {
    background: linear-gradient(145deg, rgba(187, 247, 208, 0.95) 0%, rgba(240, 253, 244, 0.98) 100%);
    color: #15803d;
}

.logistics-row-icon--exception {
    background: linear-gradient(145deg, rgba(254, 226, 226, 0.96) 0%, rgba(255, 247, 237, 0.98) 100%);
    color: #dc2626;
}

.logistics-row-icon--cancelled {
    background: linear-gradient(145deg, rgba(226, 232, 240, 0.96) 0%, rgba(248, 250, 252, 0.98) 100%);
    color: #475569;
}

.logistics-row-subgrid {
    display: grid;
    grid-template-columns: minmax(130px, 0.8fr) minmax(150px, 1fr) minmax(190px, 1fr);
    gap: 0.55rem 0.9rem;
    margin-top: 0.55rem;
    color: #64748b;
    font-size: 0.86rem;
}

.logistics-row-subgrid span {
    display: inline-flex;
    align-items: center;
    gap: 0.42rem;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.logistics-row-subgrid i {
    color: #245e4a;
    font-size: 0.8rem;
}

.logistics-row-action {
    gap: 0.7rem;
    justify-content: flex-end;
    min-width: 0;
}

.logistics-status-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 30px;
    padding: 0.32rem 0.78rem;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0;
    white-space: nowrap;
}

.logistics-status-badge--draft {
    background: #eef2f7;
    color: #475569;
}

.logistics-status-badge--booked {
    background: #e0f2fe;
    color: #0369a1;
}

.logistics-status-badge--moving {
    background: #dbeafe;
    color: #1d4ed8;
}

.logistics-status-badge--delivered {
    background: #dcfce7;
    color: #166534;
}

.logistics-status-badge--exception {
    background: #fee2e2;
    color: #b91c1c;
}

.logistics-status-badge--cancelled {
    background: #e2e8f0;
    color: #334155;
}

.logistics-share-btn {
    color: #245e4a;
}

.logistics-detail-hero {
    display: grid;
    grid-template-columns: minmax(0, 1.45fr) minmax(320px, 0.85fr);
    align-items: stretch;
    gap: 1.65rem;
    padding: clamp(1.25rem, 2.4vw, 1.85rem);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid rgba(203, 213, 225, 0.78);
    border-top: 4px solid #7dd3fc;
    box-shadow: none;
}

.logistics-detail-hero-main {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.logistics-back-btn {
    align-self: flex-start;
    margin-bottom: 1rem;
    padding: 0.48rem 0.9rem;
}

.logistics-detail-hero-main h2 {
    margin: 0.35rem 0 0.45rem;
    color: #151c19;
    font-size: clamp(1.65rem, 2.2vw, 2.15rem);
    line-height: 1.15;
}

.logistics-detail-hero-main p {
    margin: 0.18rem 0;
    color: #53647d;
    font-size: 0.96rem;
    line-height: 1.45;
}

.logistics-detail-owner {
    margin-top: 0.9rem !important;
    color: #8a95aa !important;
    font-size: 0.88rem !important;
}

.logistics-detail-meta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(203, 213, 225, 0.9);
}

.logistics-data-pill,
.logistics-access-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    min-height: 34px;
    padding: 0.42rem 0.78rem;
    border: 1px solid rgba(203, 213, 225, 0.92);
    border-radius: 999px;
    background: #f8fafc;
    color: #334155;
    font-size: 0.85rem;
    font-weight: 700;
    white-space: nowrap;
}

.logistics-access-pill i {
    color: #1d4ed8;
}

.logistics-data-pill i {
    color: #2563eb;
}

.logistics-access-pill {
    background: #eff6ff;
    border-color: #bfdbfe;
    color: #1d4ed8;
}

.logistics-detail-hero-side {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    justify-content: flex-start;
    gap: 1rem;
    padding-left: 1.4rem;
    border-left: 1px solid rgba(203, 213, 225, 0.9);
}

.logistics-detail-hero-toolbar {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.65rem;
    flex-wrap: wrap;
}

.logistics-collab-btn {
    padding: 0.48rem 0.9rem;
}

.logistics-detail-hero-side > .logistics-status-badge {
    align-self: flex-end;
}

.logistics-shipment-card {
    width: 100%;
    padding: 1rem;
    border: 1px solid rgba(125, 211, 252, 0.62);
    border-top: 4px solid #7dd3fc;
    border-radius: 8px;
    background: #f0f9ff;
}

.logistics-shipment-card div {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    align-items: center;
}

.logistics-shipment-card span {
    display: inline-flex;
    align-items: center;
    gap: 0.42rem;
    color: #0369a1;
    font-size: 0.82rem;
    font-weight: 800;
}

.logistics-shipment-card strong {
    color: #075985;
    font-size: 0.86rem;
    text-transform: uppercase;
}

.logistics-shipment-card p {
    margin: 0.7rem 0 0;
    color: #334155;
    font-size: 0.92rem;
    line-height: 1.5;
}

.logistics-audit-card,
.logistics-evidence-panel {
    padding: 1.45rem 1.5rem;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid rgba(203, 213, 225, 0.78);
    box-shadow: none;
}

.logistics-audit-card h3,
.logistics-evidence-header h3 {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0;
    color: #0f172a;
    font-size: 1.05rem;
}

.logistics-audit-container {
    margin-top: 1.2rem;
    padding: 0.9rem 0 0.1rem;
    overflow-x: auto;
}

.logistics-audit-horizontal {
    flex-wrap: nowrap;
    min-width: 760px;
}

.logistics-audit-horizontal .audit-trail-item {
    min-width: 120px;
}

.logistics-audit-horizontal .audit-trail-item strong {
    text-transform: none;
    letter-spacing: 0;
    font-size: 0.78rem;
}

.logistics-detail-work-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(360px, 0.85fr);
    align-items: stretch;
    gap: 1.25rem;
}

.logistics-detail-work-grid .logistics-detail-form {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-content: start;
}

.logistics-evidence-panel {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.logistics-evidence-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid rgba(203, 213, 225, 0.8);
}

.logistics-evidence-header p {
    margin: 0.35rem 0 0;
    color: #64748b;
    font-size: 0.9rem;
    line-height: 1.45;
}

.logistics-evidence-actions {
    display: flex;
    justify-content: flex-end;
    flex: 0 0 auto;
}

.logistics-evidence-grid {
    gap: 0.85rem;
}

.logistics-evidence-file-card {
    cursor: pointer;
}

.logistics-detail-form,
.logistics-form {
    display: grid;
    gap: 1rem;
}

.logistics-detail-form {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    padding: 1.45rem 1.5rem;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid rgba(203, 213, 225, 0.78);
    box-shadow: none;
}

.logistics-detail-form-header {
    grid-column: 1 / -1;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid rgba(203, 213, 225, 0.8);
}

.logistics-detail-form-header h3 {
    margin: 0;
    color: #0f172a;
    font-size: 1.05rem;
}

.logistics-detail-form-header p {
    margin: 0.35rem 0 0;
    color: #64748b;
    font-size: 0.9rem;
    line-height: 1.45;
}

.logistics-form .form-group,
.logistics-detail-form .form-group {
    display: grid;
    gap: 0.45rem;
}

.logistics-form .form-group span,
.logistics-detail-form .form-group span {
    color: #334155;
    font-size: 0.82rem;
    font-weight: 800;
}

.logistics-form input,
.logistics-form select,
.logistics-detail-form input,
.logistics-detail-form select,
.logistics-collaborator-row select,
.logistics-invite-create select {
    width: 100%;
    min-height: 44px;
    border: 1px solid rgba(148, 163, 184, 0.45);
    border-radius: 6px;
    background: #ffffff;
    color: #1f2937;
    padding: 0.65rem 0.8rem;
    font-size: 0.94rem;
}

.logistics-detail-form input,
.logistics-detail-form select {
    min-height: 46px;
}

.logistics-detail-form input:disabled,
.logistics-detail-form select:disabled {
    background: #f8fafc;
    color: #64748b;
}

.logistics-detail-meta,
.logistics-form-actions {
    grid-column: 1 / -1;
}

.logistics-detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem 0.9rem;
    color: #64748b;
    font-size: 0.88rem;
}

.logistics-form-actions {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.logistics-detail-form-actions {
    margin-top: 0.2rem;
}

.logistics-modal-content,
.logistics-collaborator-modal-content {
    max-width: 720px;
}

.logistics-collaborator-modal-content {
    display: grid;
    gap: 1.1rem;
}

.logistics-collaborator-section {
    display: grid;
    gap: 0.75rem;
}

.logistics-collaborator-section h3 {
    margin: 0;
    color: #0f172a;
    font-size: 1rem;
}

.logistics-collaborator-row,
.logistics-invite-row,
.logistics-invite-create {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 150px auto;
    align-items: center;
    gap: 0.75rem;
    padding: 0.85rem;
    border: 1px solid rgba(203, 213, 225, 0.75);
    border-radius: 8px;
    background: #f8fafc;
}

.logistics-collaborator-row strong,
.logistics-collaborator-row span {
    display: block;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.logistics-collaborator-row span {
    margin-top: 0.16rem;
    color: #64748b;
    font-size: 0.84rem;
}

.logistics-invite-row {
    grid-template-columns: 120px minmax(0, 1fr) auto;
}

.logistics-invite-row code {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #334155;
    font-size: 0.82rem;
}

.logistics-danger-btn {
    color: #dc2626;
    border-color: #fecaca;
}

body.workspace-shell-active .dashboard-sidebar.dashboard-topbar #btn-dash-logistics.active {
    background: #dbeafe !important;
    color: #111111 !important;
}

body.workspace-shell-active .logistics-board-shell {
    width: min(100%, 1472px);
    max-width: 1472px;
}

body.workspace-shell-active .logistics-detail-shell {
    width: min(100%, 1320px);
    max-width: 1320px;
}

body.workspace-shell-active .logistics-board-toolbar,
body.workspace-shell-active .logistics-board-list,
body.workspace-shell-active .logistics-detail-hero,
body.workspace-shell-active .logistics-audit-card,
body.workspace-shell-active .logistics-detail-work-grid,
body.workspace-shell-active .logistics-detail-form {
    width: 100%;
}

body.workspace-shell-active .logistics-row {
    grid-template-columns: 48px minmax(0, 1fr) auto !important;
}

body.workspace-shell-active .logistics-row-icon {
    width: 48px;
    height: 48px;
}

@media (max-width: 1160px) {
    .logistics-detail-work-grid {
        grid-template-columns: 1fr;
    }

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

    .logistics-row-subgrid {
        grid-template-columns: repeat(2, minmax(150px, 1fr));
    }
}

@media (max-width: 860px) {
    .logistics-table-shell {
        overflow-x: auto;
    }

    body.workspace-shell-active .logistics-table-shell {
        overflow-x: auto !important;
    }

    .logistics-table {
        min-width: 760px;
    }

    .logistics-board-filters,
    .logistics-detail-hero,
    .logistics-detail-form-header,
    .logistics-evidence-header {
        align-items: stretch;
        flex-direction: column;
    }

    .logistics-detail-hero {
        display: flex;
    }

    .logistics-detail-hero-side {
        align-items: stretch;
        padding-left: 0;
        padding-top: 1rem;
        border-left: none;
        border-top: 1px solid rgba(203, 213, 225, 0.9);
    }

    .logistics-detail-hero-toolbar {
        justify-content: flex-start;
    }

    .logistics-row {
        grid-template-columns: 48px minmax(0, 1fr);
    }

    body.workspace-shell-active .logistics-row {
        grid-template-columns: 48px minmax(0, 1fr) !important;
    }

    .logistics-row-subgrid {
        grid-template-columns: 1fr;
    }

    .logistics-row-action {
        grid-column: 1 / -1;
        justify-content: flex-start;
        flex-wrap: wrap;
        min-width: 0;
    }

    .logistics-detail-form {
        grid-template-columns: 1fr;
    }

    .logistics-detail-work-grid .logistics-detail-form {
        grid-template-columns: 1fr;
    }

    .logistics-evidence-actions {
        justify-content: flex-start;
    }

    .logistics-collaborator-row,
    .logistics-invite-row,
    .logistics-invite-create {
        grid-template-columns: 1fr;
    }

    .logistics-form-actions {
        justify-content: stretch;
    }

    .logistics-form-actions > * {
        width: 100%;
        justify-content: center;
    }
}
