@charset "UTF-8";
/* ═══════════════════════════════════════════════════════════════
   FREIGHTS.css · AZURE AURORA PREMIUM
   Sistema visual del módulo de Fletes. Prefijo fr-*,
   alineado con bl-* (Facturación), qt-* (Cotizaciones),
   ia-* (Inventario) y dp-* (Despacho): firma aurora
   índigo→azul→violeta, sombras tintadas de azul, superficies
   tipo vidrio y acentos semánticos vívidos.

   Enlázalo una vez en el layout:
       <link rel="stylesheet" href="css/freights.css" />

   Segmentos:
   1. Variables              6. Tablas premium
   2. Página + Hero          7. Formularios
   3. Tabs                   8. Badges, alertas, chips
   4. Toolbar / filtros      9. Utilidades (layout, spacing)
   5. Botones               10. Scrollbars, animaciones, a11y
   ═══════════════════════════════════════════════════════════════ */

/* ── 1. Variables ───────────────────────────────────────────── */
:root {
    --fr-primary: #3b6cf6;
    --fr-primary-hover: #2453e0;
    --fr-primary-ink: #1d3fb0;
    --fr-primary-soft: #e8effe;
    --fr-primary-soft-2: #dbe7ff;
    --fr-accent: #8b5cf6;
    --fr-indigo: #6366f1;
    --fr-aurora: #153286;
    --fr-aurora-strong: linear-gradient(120deg, #4f46e5 0%, #2453e0 50%, #7c3aed 100%);
    --fr-sky: linear-gradient(135deg, #eaf1ff 0%, #e6e9ff 100%);
    --fr-success: #0ea371;
    --fr-success-soft: #e7fbf0;
    --fr-success-border: #a7f0cb;
    --fr-success-grad: linear-gradient(135deg, #10b981 0%, #059669 100%);
    --fr-warning: #e08a00;
    --fr-warning-soft: #fff6e2;
    --fr-warning-border: #fbd784;
    --fr-danger: #e11d48;
    --fr-danger-soft: #fdecf0;
    --fr-danger-border: #f9c0d1;
    --fr-danger-grad: linear-gradient(135deg, #fb7185 0%, #e11d48 100%);
    --fr-text: #263449;
    --fr-text-strong: #0d1b34;
    --fr-text-muted: #6b7a93;
    --fr-text-soft: #94a3b8;
    --fr-border: #e2e9f5;
    --fr-border-strong: #cdd8ec;
    --fr-bg: #f4f8ff;
    --fr-surface: #ffffff;
    --fr-radius-sm: 10px;
    --fr-radius: 15px;
    --fr-radius-lg: 22px;
    --fr-shadow-sm: 0 1px 2px rgba(29,63,176,.05), 0 2px 8px rgba(29,63,176,.04);
    --fr-shadow: 0 6px 16px rgba(29,63,176,.07), 0 14px 34px rgba(29,63,176,.06);
    --fr-shadow-lg: 0 12px 28px rgba(29,63,176,.10), 0 28px 60px rgba(29,63,176,.10);
    --fr-glow-primary: 0 10px 24px rgba(59,108,246,.35);
    --fr-glow-success: 0 10px 22px rgba(16,185,129,.30);
    --fr-glow-danger: 0 10px 22px rgba(225,29,72,.26);
    --fr-ring: 0 0 0 4px rgba(59,108,246,.16);
}

/* ── 2. Página + Hero ───────────────────────────────────────── */
.freight-module {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    color: var(--fr-text);
    font-family: 'Inter', system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    padding: 1.25rem 1.25rem 2.5rem;
    -webkit-font-smoothing: antialiased;
}

/* Hero premium — barra oscura aurora con vidrio interior */
.freight-hero {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    background: var(--fr-aurora);
    border: 1px solid rgba(255,255,255,.35);
    border-radius: var(--fr-radius);
    padding: 1.5rem 1.75rem;
    box-shadow: var(--fr-glow-primary), var(--fr-shadow);
    overflow: hidden;
    isolation: isolate;
    color: #fff;
    margin-bottom: 1.15rem;
}

    .freight-hero::before {
        content: "";
        position: absolute;
        inset: 0;
        background: radial-gradient(520px 220px at 8% -40%, rgba(255,255,255,.42), transparent 60%), radial-gradient(420px 260px at 100% 140%, rgba(255,255,255,.16), transparent 55%);
        pointer-events: none;
        z-index: -1;
    }

.freight-hero__info {
    display: flex;
    align-items: center;
    gap: 1.15rem;
}

.freight-hero__icon {
    width: 62px;
    height: 62px;
    border-radius: 18px;
    background: rgba(255,255,255,.16);
    border: 1px solid rgba(255,255,255,.35);
    backdrop-filter: blur(6px);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.5), 0 8px 20px rgba(13,27,52,.18);
    flex-shrink: 0;
    /*font-size: 28px;*/
}

.freight-hero__eyebrow {
    font-size: .68rem;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: rgba(255,255,255,.9);
    font-weight: 700;
}

.freight-hero__title {
    margin: .15rem 0 .2rem;
    font-size: 1.6rem;
    font-weight: 700;
    letter-spacing: -.02em;
    color: #fff;
    text-shadow: 0 1px 12px rgba(13,27,52,.18);
}

.freight-hero__subtitle {
    margin: 0;
    color: rgba(255,255,255,.88);
    font-size: .9rem;
}

.freight-hero__actions {
    display: flex;
    align-items: center;
    gap: .75rem;
}

/* ── 3. Tabs ────────────────────────────────────────────────── */
.freight-tabs {
    display: inline-flex;
    align-items: center;
    gap: .25rem;
    padding: .3rem;
    background: var(--fr-surface);
    border: 1px solid var(--fr-border-strong);
    border-radius: 999px;
    box-shadow: var(--fr-shadow-sm);
    list-style: none;
    margin: 0 0 1rem;
}

.freight-tabs--vertical {
    flex-direction: column;
    border-radius: var(--fr-radius);
    align-self: flex-start;
}

.freight-tabs__item {
    margin: 0;
    flex-shrink: 0;
}

.freight-tabs__link {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    border: none;
    border-radius: 999px;
    background: transparent;
    color: var(--fr-text-muted);
    font-family: inherit;
    font-size: .82rem;
    font-weight: 700;
    line-height: 1;
    padding: .55rem 1.15rem;
    cursor: pointer;
    white-space: nowrap;
    transition: all .18s ease;
    text-decoration: none;
}

    .freight-tabs__link:hover {
        background: var(--fr-primary-soft);
        color: var(--fr-primary-hover);
    }

.freight-tabs__link--active {
    background: var(--fr-aurora) !important;
    color: #fff !important;
    box-shadow: var(--fr-glow-primary);
}

/* Vertical pills */
.freight-tabs--pills .freight-tabs__link {
    justify-content: flex-end;
    border-radius: var(--fr-radius-sm);
    padding: .4rem .75rem;
}

.freight-tabs--pills .freight-tabs__link--active {
    background: var(--fr-primary-soft) !important;
    color: var(--fr-primary-ink) !important;
    border: 1px solid var(--fr-primary-soft-2);
    box-shadow: var(--fr-shadow-sm);
}

.freight-tab-content {
    padding: .75rem 0;
}

/* ── 4. Toolbar / Filtros ───────────────────────────────────── */
.freight-toolbar {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
    background: var(--fr-surface);
    border: 1px solid var(--fr-border);
    border-radius: var(--fr-radius);
    padding: .9rem 1.15rem;
    box-shadow: var(--fr-shadow);
    margin-bottom: 1rem;
}

.freight-count-chip {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    font-size: .78rem;
    font-weight: 700;
    color: var(--fr-primary-ink);
    background: var(--fr-primary-soft);
    border: 1px solid var(--fr-primary-soft-2);
    border-radius: 999px;
    padding: .4rem .95rem;
    white-space: nowrap;
}

/* ── 5. Botones ─────────────────────────────────────────────── */
.freight-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .4rem;
    padding: .55rem 1.1rem;
    border: 1px solid var(--fr-border-strong);
    border-radius: var(--fr-radius-sm);
    background: linear-gradient(180deg, #ffffff, #f7faff);
    color: var(--fr-text);
    font-weight: 700;
    font-size: .85rem;
    cursor: pointer;
    box-shadow: var(--fr-shadow-sm);
    font-family: inherit;
    transition: transform .14s ease, box-shadow .18s ease, background .18s ease, filter .18s ease, border-color .18s ease;
}

    .freight-btn:hover:not(:disabled) {
        transform: translateY(-1px);
        box-shadow: var(--fr-shadow);
        border-color: #9db9fb;
    }

    .freight-btn:active:not(:disabled) {
        transform: translateY(0) scale(.97);
    }

    .freight-btn:disabled {
        opacity: .5;
        cursor: not-allowed;
        transform: none !important;
        box-shadow: none !important;
        filter: grayscale(.2);
    }

.freight-btn--primary {
    background: var(--fr-aurora);
    border-color: transparent;
    color: #fff;
    box-shadow: var(--fr-glow-primary);
}

    .freight-btn--primary:hover:not(:disabled) {
        background: var(--fr-aurora-strong);
        border-color: transparent;
        box-shadow: 0 14px 30px rgba(59,108,246,.45);
    }

.freight-btn--success {
    background: var(--fr-success-grad);
    border-color: transparent;
    color: #fff;
    box-shadow: var(--fr-glow-success);
}

    .freight-btn--success:hover:not(:disabled) {
        filter: brightness(1.05);
        border-color: transparent;
    }

.freight-btn--warning {
    background: linear-gradient(135deg, #fbbf24 0%, var(--fr-warning) 100%);
    border-color: transparent;
    color: #fff;
    box-shadow: 0 6px 16px rgba(224,138,0,.2);
}

    .freight-btn--warning:hover:not(:disabled) {
        filter: brightness(1.05);
        border-color: transparent;
    }

.freight-btn--block {
    width: 100%;
}

/* Icon button (image-based) */
.freight-icon-btn {
    width: 34px;
    height: 34px;
    border-radius: var(--fr-radius-sm);
    border: 1px solid var(--fr-border-strong);
    background: #fff;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all .18s ease;
    box-shadow: var(--fr-shadow-sm);
    padding: 3px;
}

    .freight-icon-btn:hover {
        background: var(--fr-primary-soft);
        border-color: #9db9fb;
        transform: translateY(-2px);
        box-shadow: var(--fr-shadow);
    }

    .freight-icon-btn img {
        width: 100%;
        height: 100%;
        object-fit: contain;
    }

/* ── 6. Tablas premium ──────────────────────────────────────── */
.freight-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    font-size: .84rem;
    background: var(--fr-surface);
    border: 1px solid var(--fr-border);
    border-radius: var(--fr-radius);
    overflow: hidden;
    box-shadow: var(--fr-shadow-sm);
}

    .freight-table th,
    .freight-table td {
        padding: .55rem .85rem;
        border-bottom: 1px solid #eef2f9;
        vertical-align: middle;
    }

    .freight-table th {
        font-weight: 700;
        font-size: .66rem;
        text-transform: uppercase;
        letter-spacing: .05em;
        color: #47597a;
        background: linear-gradient(180deg, #f4f8ff, #eaf1ff);
        border-bottom: 2px solid var(--fr-border-strong);
    }

    .freight-table tr:last-child td {
        border-bottom: none;
    }

    .freight-table tbody tr {
        transition: background .15s ease;
    }

        .freight-table tbody tr:hover {
            background: #f6f9ff;
        }

.freight-table--borderless,
.freight-table--borderless th,
.freight-table--borderless td {
    border: none !important;
    box-shadow: none;
    background: transparent;
}

/* Row accent variants — gradient style */
.freight-table .row-primary {
    background: linear-gradient(180deg, #f4f8ff, #eaf1ff) !important;
}

.freight-table .row-success {
    background: linear-gradient(135deg, var(--fr-success-soft) 0%, #ecfdf5 100%) !important;
}

.freight-table .row-warning {
    background: linear-gradient(135deg, var(--fr-warning-soft) 0%, #fffbeb 100%) !important;
}

.freight-table .row-danger {
    background: linear-gradient(135deg, var(--fr-danger-soft) 0%, #fef2f2 100%) !important;
}

/* Sticky header/footer */
.freight-table .sticky-top {
    position: sticky;
    top: 0;
    z-index: 2;
    background: linear-gradient(180deg, #f4f8ff, #eaf1ff);
    box-shadow: 0 2px 4px rgba(29,63,176,.06);
}

.freight-table .sticky-bottom {
    position: sticky;
    bottom: 0;
    z-index: 2;
    background: var(--fr-surface);
    box-shadow: 0 -2px 4px rgba(29,63,176,.06);
}

/* Nested tables — remove card chrome */
.freight-table .freight-table {
    border: none;
    box-shadow: none;
    border-radius: 0;
}

/* ── 7. Formularios ─────────────────────────────────────────── */
.freight-input,
.freight-select {
    width: 100%;
    padding: .55rem .85rem;
    border: 1px solid var(--fr-border-strong);
    border-radius: var(--fr-radius-sm);
    background: var(--fr-bg);
    font-family: inherit;
    font-size: .88rem;
    color: var(--fr-text);
    outline: none;
    box-sizing: border-box;
    transition: border-color .15s ease, box-shadow .15s ease, background .15s ease;
}

    .freight-input:focus,
    .freight-select:focus {
        border-color: var(--fr-primary);
        background: #fff;
        box-shadow: var(--fr-ring);
    }

    .freight-input::placeholder {
        color: var(--fr-text-soft);
    }

.freight-select {
    cursor: pointer;
}

/* Checkbox / radio accents */
.freight-table input[type="checkbox"],
.freight-radio-group input[type="radio"] {
    accent-color: var(--fr-primary);
    width: 16px;
    height: 16px;
    cursor: pointer;
}

/* ── 8. Badges, alertas, chips ──────────────────────────────── */
.freight-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 22px;
    height: 22px;
    padding: 0 .5rem;
    font-size: .7rem;
    font-weight: 700;
    border-radius: 999px;
    background: var(--fr-success-grad);
    color: #fff;
    margin-left: .35rem;
    box-shadow: var(--fr-glow-success);
}

.freight-alert {
    display: flex;
    align-items: center;
    gap: .65rem;
    padding: .85rem 1.15rem;
    border-radius: var(--fr-radius);
    font-size: .85rem;
    box-shadow: var(--fr-shadow-sm);
    border-left: 4px solid transparent;
}

.freight-alert--warning {
    background: var(--fr-warning-soft);
    border-color: var(--fr-warning-border);
    border-left-color: var(--fr-warning);
    color: #92590a;
}

/* ── 9. Utilidades ──────────────────────────────────────────── */

/* Typography */
.freight-label {
    margin: 0;
    font-size: .82rem;
    /*color: var(--fr-text);*/
    display: inline-block;
    line-height: 1.5;
}

.freight-label--bold {
    font-weight: 700;
    color: var(--fr-text-strong);
}

.freight-label--light {
    font-weight: 300;
    font-size: 1.1rem;
    color: var(--fr-text-muted);
    letter-spacing: -.01em;
}

.freight-label--clickable {
    cursor: pointer;
    color: var(--fr-primary);
    transition: color .18s ease;
}

    .freight-label--clickable:hover {
        color: var(--fr-primary-hover);
        text-decoration: underline;
    }

/* Layout */
.freight-row {
    display: flex;
    flex-wrap: wrap;
    gap: .75rem;
    align-items: flex-start;
}

.freight-col {
    flex: 1 1 0;
    min-width: 0;
}

.freight-col--2 {
    flex: 0 0 16.66%;
    max-width: 16.66%;
}

.freight-col--3 {
    flex: 0 0 25%;
    max-width: 25%;
}

.freight-col--4 {
    flex: 0 0 33.33%;
    max-width: 33.33%;
}

.freight-col--5 {
    flex: 0 0 41.66%;
    max-width: 41.66%;
}

.freight-col--6 {
    flex: 0 0 50%;
    max-width: 50%;
}

.freight-col--8 {
    flex: 0 0 66.66%;
    max-width: 66.66%;
}

.freight-col--10 {
    flex: 0 0 83.33%;
    max-width: 83.33%;
}

.freight-col--12 {
    flex: 0 0 100%;
    max-width: 100%;
}

/* Spacing */
.freight-mt-1 {
    margin-top: .25rem;
}

.freight-mt-2 {
    margin-top: .5rem;
    margin-bottom: .9rem;
}

.freight-mt-3 {
    margin-top: 1rem;
}

.freight-mt-4 {
    margin-top: 1.5rem;
}

.freight-mb-2 {
    margin-bottom: .5rem;
}

.freight-mb-4 {
    margin-bottom: 1.5rem;
}

.freight-ms-2 {
    margin-left: .5rem;
}

.freight-ms-3 {
    margin-left: 1rem;
}

.freight-p-0 {
    padding: 0 !important;
}

.freight-p-1 {
    padding: .25rem;
}

.freight-py-3 {
    padding-top: 1rem;
    padding-bottom: 1rem;
}

/* Text alignment */
.freight-text-center {
    text-align: center;
}

.freight-text-end {
    text-align: right;
}

.freight-text-start {
    text-align: left;
}

/* Expand/collapse toggle */
.freight-toggle {
    font-size: .9rem;
    cursor: pointer;
    background: none;
    border: none;
    padding: 2px 6px;
    color: var(--fr-primary);
    border-radius: var(--fr-radius-sm);
    transition: background .18s ease, color .18s ease;
}

    .freight-toggle:hover {
        background: var(--fr-primary-soft);
        color: var(--fr-primary-hover);
    }

/* Radio group */
.freight-radio-group {
    display: flex;
    flex-direction: column;
    gap: .5rem;
}

    .freight-radio-group label,
    .freight-radio-group > div {
        display: inline-flex;
        align-items: center;
        gap: .45rem;
        font-size: .84rem;
        color: var(--fr-text);
        cursor: pointer;
        padding: .3rem .6rem;
        border-radius: var(--fr-radius-sm);
        transition: background .15s ease;
    }

        .freight-radio-group label:hover,
        .freight-radio-group > div:hover {
            background: var(--fr-primary-soft);
        }

/* Divider */
.freight-divider {
    border: none;
    border-top: 1px solid var(--fr-border);
    margin: 1rem 0;
}

/* ── 10. Scrollbars, animaciones, accesibilidad ─────────────── */
.freight-scroll {
    overflow-y: auto;
    overflow-x: hidden;
    scrollbar-width: thin;
    scrollbar-color: #bcd0fb transparent;
}

    .freight-scroll::-webkit-scrollbar {
        width: 8px;
        height: 8px;
    }

    .freight-scroll::-webkit-scrollbar-thumb {
        background: #bcd0fb;
        border-radius: 999px;
    }

.freight-scroll--main {
    max-height: calc(100vh - 200px);
}

.freight-scroll--stats {
    max-height: calc(100vh - 260px);
}

/* Loader */
.freight-loader {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    padding: 4rem 2rem;
    color: var(--fr-text-muted);
}

    .freight-loader img {
        width: 50%;
        max-width: 280px;
        opacity: .6;
        animation: frPulse 2s ease-in-out infinite;
    }

@keyframes frPulse {
    0%, 100% {
        opacity: .45;
        transform: scale(.98);
    }

    50% {
        opacity: .85;
        transform: scale(1);
    }
}

/* Fade-slide-in animation (matches biller) */
.freight-hero,
.freight-toolbar,
.freight-table,
.freight-tabs {
    animation: frFadeSlideIn .3s ease both;
}

@keyframes frFadeSlideIn {
    from {
        opacity: 0;
        transform: translateY(8px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Focus ring */
.freight-module :is(button, [role="button"], input, select, a):focus-visible {
    outline: 3px solid rgba(59,108,246,.6);
    outline-offset: 2px;
    border-radius: var(--fr-radius-sm);
}

/* Selection */
.freight-module ::selection {
    background: rgba(99,102,241,.25);
    color: var(--fr-text-strong);
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    .freight-module *, .freight-module *::before, .freight-module *::after {
        animation-duration: .01ms !important;
        transition-duration: .01ms !important;
    }
}

/* Responsive */
@media (max-width: 768px) {
    .freight-col--2, .freight-col--3, .freight-col--4,
    .freight-col--5, .freight-col--6, .freight-col--8,
    .freight-col--10 {
        flex: 0 0 100%;
        max-width: 100%;
    }

    .freight-tabs {
        flex-wrap: wrap;
        border-radius: var(--fr-radius);
    }

    .freight-module {
        padding: .75rem;
    }

    .freight-hero {
        padding: 1rem 1.15rem;
    }

    .freight-hero__title {
        font-size: 1.25rem;
    }
}

/* ═══════════════════════════════════════════════════════════════
   FREIGHTS · PREMIUM EXPERIENCE V2
   Capa visual 2026. Mantiene compatibilidad con el markup previo
   y agrega componentes específicos para Admin, Management y Stats.
   ═══════════════════════════════════════════════════════════════ */

:root {
    --fr-canvas: #f7f9fd;
    --fr-canvas-blue: #f0f5ff;
    --fr-navy: #0b1739;
    --fr-navy-2: #13285f;
    --fr-blue: #3b6cf6;
    --fr-violet: #7357f6;
    --fr-cyan: #43b8ff;
    --fr-green: #10a977;
    --fr-amber: #e69319;
    --fr-red: #dc3d62;
    --fr-line: #e6ebf4;
    --fr-line-strong: #d7dfec;
    --fr-ink: #18233b;
    --fr-muted: #71809a;
    --fr-soft: #97a3b7;
    --fr-white: #ffffff;
    --fr-card-radius: 18px;
    --fr-card-shadow: 0 1px 2px rgba(15,23,42,.03), 0 10px 26px rgba(40,69,128,.06);
    --fr-card-shadow-hover: 0 12px 30px rgba(40,69,128,.10), 0 2px 6px rgba(15,23,42,.04);
}

html {
    scrollbar-gutter: stable;
}

.freight-module {
    position: relative;
    padding: 1.4rem 1.55rem 3rem;
    color: var(--fr-ink);
}

    .freight-module::before {
        content: "";
        position: fixed;
        inset: 0;
        z-index: -2;
        pointer-events: none;
        background: radial-gradient(900px 420px at 8% 0%, rgba(59,108,246,.075), transparent 65%), radial-gradient(760px 420px at 94% 2%, rgba(115,87,246,.055), transparent 62%), linear-gradient(180deg, #fbfcff 0%, var(--fr-canvas) 44%, #f8faff 100%);
    }

/* ── Hero editorial ─────────────────────────────────────────── */
.freight-hero {
    min-height: 132px;
    padding: 1.55rem 1.7rem;
    border-radius: 22px;
    background: radial-gradient(520px 190px at 20% -30%, rgba(97,153,255,.52), transparent 64%), radial-gradient(460px 250px at 100% 110%, rgba(122,92,246,.44), transparent 67%), linear-gradient(118deg, #0d1d46 0%, #173884 48%, #4938aa 100%);
    border: 1px solid rgba(255,255,255,.24);
    box-shadow: 0 22px 48px rgba(32,59,133,.19);
    margin-bottom: 1rem;
}

    .freight-hero::after {
        content: "";
        position: absolute;
        width: 330px;
        height: 330px;
        right: -155px;
        top: -170px;
        border-radius: 50%;
        border: 55px solid rgba(255,255,255,.045);
        pointer-events: none;
    }

.freight-hero__info {
    gap: 1.05rem;
}

.freight-hero__icon {
    width: 58px;
    height: 58px;
    border-radius: 16px;
    font-size: 28px;
    background: rgba(255,255,255,.12);
    border: 1px solid rgba(255,255,255,.26);
    box-shadow: inset 0 1px rgba(255,255,255,.22), 0 8px 22px rgba(8,18,52,.18);
}

    .freight-hero__icon svg {
        width: 29px;
        height: 29px;
    }

.freight-hero__eyebrow {
    color: #b9ceff;
    letter-spacing: .13em;
    font-size: .66rem;
    font-weight: 800;
}

.freight-hero__title {
    margin-top: .2rem;
    font-size: clamp(1.5rem, 2vw, 1.95rem);
    font-weight: 760;
    letter-spacing: -.035em;
}

.freight-hero__subtitle {
    max-width: 670px;
    color: rgba(235,241,255,.79);
    font-size: .87rem;
}

.freight-hero__actions {
    gap: .55rem;
    align-self: center;
}

.freight-hero .freight-btn {
    min-height: 38px;
    padding: .53rem .88rem;
    border-color: rgba(255,255,255,.19);
    background: rgba(255,255,255,.10);
    color: #f7f9ff;
    box-shadow: none;
    backdrop-filter: blur(10px);
}

    .freight-hero .freight-btn:hover:not(:disabled) {
        background: rgba(255,255,255,.18);
        border-color: rgba(255,255,255,.34);
        box-shadow: none;
    }

.freight-hero .freight-btn--primary {
    color: #17306f;
    background: #fff;
    border-color: #fff;
}

.freight-btn svg,
.freight-tabs__link svg {
    width: 16px;
    height: 16px;
    flex: 0 0 auto;
}

/* ── Navigation shell ───────────────────────────────────────── */
.freight-nav-shell {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin: .9rem 0 1rem;
    padding: .45rem;
    background: rgba(255,255,255,.82);
    border: 1px solid var(--fr-line);
    border-radius: 17px;
    box-shadow: var(--fr-card-shadow);
    backdrop-filter: blur(14px);
}

    .freight-nav-shell .freight-tabs {
        width: 100%;
        margin: 0;
        padding: 0;
        gap: .25rem;
        border: 0;
        background: transparent;
        box-shadow: none;
        border-radius: 0;
    }

    .freight-nav-shell .freight-tabs__item {
        flex: 1 1 auto;
    }

    .freight-nav-shell .freight-tabs__link {
        width: 100%;
        min-height: 48px;
        justify-content: center;
        padding: .6rem .75rem;
        color: #64728b;
        border-radius: 12px;
        font-size: .78rem;
        position: relative;
    }

        .freight-nav-shell .freight-tabs__link:hover {
            background: #f3f6fc;
            color: #3157bd;
        }

    .freight-nav-shell .freight-tabs__link--active {
        background: linear-gradient(180deg, #eef3ff 0%, #e9f0ff 100%) !important;
        color: #21479f !important;
        border: 1px solid #d6e2ff;
        box-shadow: 0 4px 12px rgba(59,108,246,.10);
    }

        .freight-nav-shell .freight-tabs__link--active::after {
            content: "";
            position: absolute;
            height: 2px;
            left: 28%;
            right: 28%;
            bottom: 4px;
            border-radius: 99px;
            background: linear-gradient(90deg, var(--fr-blue), var(--fr-violet));
        }

    .freight-nav-shell .freight-tabs__link img {
        width: 18px !important;
        height: 18px;
        object-fit: contain;
        opacity: .82;
    }

.freight-tab-count {
    min-width: 24px;
    height: 21px;
    padding: 0 .42rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 99px;
    color: #52627c;
    background: #edf1f7;
    font-size: .68rem;
    font-weight: 800;
}

.freight-tabs__link--active .freight-tab-count {
    color: #234aab;
    background: #dce7ff;
}

.freight-tab-count--danger {
    color: #b72d4c;
    background: #fdebf0;
}

/* ── Cards / section architecture ───────────────────────────── */
.freight-card,
.freight-section-card {
    background: rgba(255,255,255,.96);
    border: 1px solid var(--fr-line);
    border-radius: var(--fr-card-radius);
    box-shadow: var(--fr-card-shadow);
}

.freight-section-card {
    overflow: hidden;
    margin-bottom: 1rem;
}

.freight-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 1.15rem;
    border-bottom: 1px solid #edf1f7;
    background: linear-gradient(180deg, #ffffff 0%, #fbfcff 100%);
}

.freight-section-heading {
    display: flex;
    align-items: center;
    gap: .75rem;
    min-width: 0;
}

.freight-section-icon {
    width: 35px;
    height: 35px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 11px;
    background: #edf3ff;
    color: #3563d9;
    flex: 0 0 auto;
}

    .freight-section-icon svg {
        width: 18px;
        height: 18px;
    }

.freight-section-title {
    margin: 0;
    color: #19263e;
    font-size: .93rem;
    font-weight: 780;
    letter-spacing: -.015em;
}

.freight-section-subtitle {
    margin: .12rem 0 0;
    color: var(--fr-muted);
    font-size: .72rem;
    line-height: 1.4;
}

.freight-section-body {
    padding: 1rem 1.15rem 1.15rem;
}

/* ── KPI cards ──────────────────────────────────────────────── */
.freight-kpi-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: .75rem;
    margin: 0 0 1rem;
}

.freight-kpi {
    position: relative;
    min-height: 86px;
    padding: .88rem .95rem;
    overflow: hidden;
    background: #fff;
    border: 1px solid var(--fr-line);
    border-radius: 15px;
    box-shadow: 0 4px 14px rgba(40,69,128,.045);
}

    .freight-kpi::after {
        content: "";
        position: absolute;
        right: -24px;
        bottom: -35px;
        width: 78px;
        height: 78px;
        border-radius: 50%;
        background: rgba(59,108,246,.045);
    }

.freight-kpi__top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .5rem;
}

.freight-kpi__icon {
    width: 31px;
    height: 31px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: #eff4ff;
    color: #4169d4;
}

    .freight-kpi__icon svg {
        width: 16px;
        height: 16px;
    }

.freight-kpi__label {
    color: #7d899e;
    font-size: .68rem;
    font-weight: 700;
}

.freight-kpi__value {
    margin-top: .45rem;
    color: #17233a;
    font-size: 1.2rem;
    font-weight: 800;
    letter-spacing: -.035em;
}

.freight-kpi--danger .freight-kpi__icon {
    color: #c33757;
    background: #fff0f3;
}

.freight-kpi--warning .freight-kpi__icon {
    color: #b86d05;
    background: #fff6e7;
}

.freight-kpi--success .freight-kpi__icon {
    color: #087d58;
    background: #eafaf4;
}

/* ── Tables: cleaner / SaaS density ─────────────────────────── */
.freight-table {
    border: 1px solid var(--fr-line);
    border-radius: 14px;
    box-shadow: none;
    background: #fff;
    font-size: .8rem;
}

    .freight-table th,
    .freight-table td {
        padding: .63rem .75rem;
        border-bottom-color: #edf1f7;
    }

    .freight-table th {
        color: #6d7b92;
        background: #f8faff;
        border-bottom: 1px solid #e7ecf5;
        font-size: .64rem;
        font-weight: 800;
        letter-spacing: .055em;
    }

    .freight-table tbody tr:hover {
        background: #f8faff;
    }

    .freight-table .row-primary,
    .freight-table .row-success,
    .freight-table .row-warning,
    .freight-table .row-danger {
        background: transparent !important;
    }

    .freight-table thead .row-primary th {
        background: #f2f6ff;
        color: #45609b;
    }

    .freight-table thead .row-success th {
        background: #f1fbf7;
        color: #39705e;
    }

    .freight-table thead .row-warning th {
        background: #fff9ed;
        color: #8d6a30;
    }

    .freight-table tbody .row-danger td {
        background: #fff6f8;
    }

    .freight-table tfoot td {
        background: #f8faff;
        border-top: 1px solid #e5ebf5;
        border-bottom: 0;
        font-weight: 700;
    }

    .freight-table .freight-table {
        border-radius: 0;
        background: #fbfcff;
    }

        .freight-table .freight-table th {
            background: #f7f9fd;
        }

.freight-toggle {
    width: 29px;
    height: 29px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: 1px solid #dce4f1;
    background: #fff;
    color: #5470b7;
    border-radius: 9px;
}

    .freight-toggle:hover {
        transform: translateY(-1px);
        background: #edf3ff;
        border-color: #bfd0f5;
    }

/* ── Inputs / buttons ───────────────────────────────────────── */
.freight-input,
.freight-select {
    min-height: 38px;
    padding: .5rem .7rem;
    border: 1px solid #dbe3ef;
    border-radius: 10px;
    background: #fbfcff;
    color: #26344d;
    font-size: .8rem;
}

    .freight-input:hover,
    .freight-select:hover {
        border-color: #c6d2e4;
    }

    .freight-input:focus,
    .freight-select:focus {
        border-color: #7b9df2;
        background: #fff;
        box-shadow: 0 0 0 3px rgba(59,108,246,.10);
    }

.freight-btn {
    min-height: 38px;
    padding: .52rem .88rem;
    border-radius: 10px;
    border-color: #dce4ef;
    font-size: .78rem;
    font-weight: 760;
    box-shadow: none;
}

    .freight-btn:hover:not(:disabled) {
        transform: translateY(-1px);
        box-shadow: 0 6px 14px rgba(36,68,135,.09);
    }

.freight-btn--primary {
    background: linear-gradient(135deg, #315fdc 0%, #5f54e8 100%);
    box-shadow: 0 7px 16px rgba(59,90,205,.18);
}

.freight-btn--success {
    background: linear-gradient(135deg, #129a70, #0a855f);
    box-shadow: 0 7px 16px rgba(11,135,97,.15);
}

.freight-btn--warning {
    background: linear-gradient(135deg, #e7a238, #d88917);
    box-shadow: 0 7px 16px rgba(216,137,23,.13);
}

.freight-icon-btn {
    width: 32px;
    height: 32px;
    padding: 5px;
    border: 1px solid #dfe6f0;
    border-radius: 9px;
    box-shadow: none;
}

    .freight-icon-btn:hover {
        transform: translateY(-1px);
        background: #f1f5ff;
        box-shadow: 0 5px 12px rgba(42,73,140,.08);
    }

/* ── Empty state ────────────────────────────────────────────── */
.freight-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 210px;
    padding: 2rem;
    text-align: center;
    color: var(--fr-muted);
}

.freight-empty__icon {
    width: 50px;
    height: 50px;
    display: grid;
    place-items: center;
    border-radius: 15px;
    color: #6179af;
    background: #f0f4fb;
    margin-bottom: .85rem;
}

    .freight-empty__icon svg {
        width: 24px;
        height: 24px;
    }

.freight-empty__title {
    color: #26334d;
    font-size: .9rem;
    font-weight: 780;
    margin-bottom: .25rem;
}

.freight-empty__text {
    font-size: .75rem;
    max-width: 420px;
}

/* ── FreightManagement ──────────────────────────────────────── */
.freight-management {
    padding: .15rem 0 1.2rem;
}

    .freight-management .freight-tabs--workflow {
        display: flex;
        width: fit-content;
        margin: 0 0 .85rem;
        padding: .3rem;
        border-radius: 13px;
        background: #eef2f8;
        border: 0;
        box-shadow: none;
    }

        .freight-management .freight-tabs--workflow .freight-tabs__link {
            min-height: 36px;
            border-radius: 9px;
            padding: .5rem .85rem;
        }

        .freight-management .freight-tabs--workflow .freight-tabs__link--active {
            background: #fff !important;
            color: #2d55b7 !important;
            box-shadow: 0 2px 7px rgba(43,67,117,.10);
        }

    .freight-management .freight-tabs--view-switch {
        display: flex;
        width: fit-content;
        margin: .85rem auto 1rem;
        padding: .25rem;
        border: 1px solid #e1e7f0;
        background: #fff;
        box-shadow: none;
        border-radius: 12px;
    }

        .freight-management .freight-tabs--view-switch .freight-tabs__link {
            min-width: 105px;
            justify-content: center;
            padding: .48rem .75rem;
            border-radius: 8px;
        }

.freight-filter-panel {
    position: relative;
    margin: 0 0 .75rem;
    padding: .85rem;
    background: #fff;
    border: 1px solid var(--fr-line);
    border-radius: 15px;
    box-shadow: var(--fr-card-shadow);
}

.freight-filter-panel__head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: .75rem;
    margin-bottom: .7rem;
}

.freight-filter-panel__title {
    display: flex;
    align-items: center;
    gap: .5rem;
    color: #2a3851;
    font-size: .76rem;
    font-weight: 800;
}

    .freight-filter-panel__title svg {
        width: 15px;
        height: 15px;
        color: #4c70c9;
    }

.freight-filter-grid {
    display: grid;
    grid-template-columns: repeat(12, minmax(0,1fr));
    gap: .65rem;
    align-items: end;
}

.freight-filter-field {
    grid-column: span 3;
    position: relative;
}

.freight-filter-field--date {
    grid-column: span 2;
}

.freight-filter-field--invoice {
    grid-column: span 2;
}

.freight-filter-actions {
    grid-column: span 1;
}

.freight-filter-label {
    display: block;
    margin: 0 0 .3rem .1rem;
    color: #77849a;
    font-size: .64rem;
    font-weight: 760;
}

.freight-filter-panel .freight-btn {
    width: 100%;
}

.freight-autocomplete {
    position: absolute;
    z-index: 30;
    left: 0;
    right: 0;
    top: calc(100% + 5px);
    max-height: 240px;
    overflow: auto;
    padding: .3rem;
    background: #fff;
    border: 1px solid #dfe6f1;
    border-radius: 11px;
    box-shadow: 0 14px 34px rgba(27,50,98,.16);
}

.freight-autocomplete__item {
    display: block;
    width: 100%;
    padding: .52rem .6rem;
    border-radius: 8px;
    color: #43516a;
    font-size: .76rem;
    cursor: pointer;
}

    .freight-autocomplete__item:hover {
        background: #f0f4ff;
        color: #3159ba;
    }

.freight-hierarchy {
    border: 1px solid var(--fr-line);
    border-radius: 16px;
    overflow: hidden;
    background: #fff;
    box-shadow: var(--fr-card-shadow);
}

    .freight-hierarchy > .freight-table {
        border: 0;
        border-radius: 0;
    }

    .freight-hierarchy .freight-table tbody > tr > td:first-child {
        padding-left: .65rem;
    }

    .freight-hierarchy .freight-table .freight-table {
        border-left: 3px solid #e2eaff;
    }

.freight-detail-editor {
    margin: .65rem;
    padding: 1rem;
    border: 1px solid #e4eaf3;
    border-radius: 14px;
    background: linear-gradient(180deg,#fbfcff,#f8faff);
}

    .freight-detail-editor .freight-divider {
        margin: .8rem 0;
    }

.freight-field-label {
    display: block;
    margin-bottom: .28rem;
    color: #748097;
    font-size: .64rem;
    font-weight: 760;
}

.freight-value-box {
    display: flex;
    min-height: 38px;
    align-items: center;
    padding: .5rem .7rem;
    border: 1px solid #e0e6f0;
    border-radius: 10px;
    background: #f4f7fc;
    color: #33425d;
    font-size: .8rem;
}

.freight-dispatch-card {
    overflow: hidden;
    margin-bottom: .9rem;
    border: 1px solid var(--fr-line);
    border-radius: 16px;
    background: #fff;
    box-shadow: var(--fr-card-shadow);
}

    .freight-dispatch-card > .freight-table {
        border: 0;
        border-radius: 0;
    }

.freight-dispatch-actions {
    display: flex;
    justify-content: flex-end;
    padding: .85rem 1rem;
    border-top: 1px solid var(--fr-line);
    background: #fbfcff;
}

/* ── Statistics dashboard ───────────────────────────────────── */
.freight-stats-hero {
    display: grid;
    grid-template-columns: minmax(0,1fr) auto;
    gap: 1rem;
    align-items: center;
    margin-bottom: .85rem;
    padding: 1.2rem 1.35rem;
    border-radius: 19px;
    color: #fff;
    background: radial-gradient(420px 180px at 10% -35%, rgba(93,157,255,.55), transparent 66%), radial-gradient(390px 210px at 100% 120%, rgba(139,92,246,.38), transparent 66%), linear-gradient(120deg,#10234f,#1b438d 55%,#523db0);
    box-shadow: 0 18px 40px rgba(33,66,139,.17);
}

.freight-stats-hero__top {
    display: flex;
    align-items: center;
    gap: .85rem;
}

.freight-stats-back {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border: 1px solid rgba(255,255,255,.2);
    border-radius: 11px;
    color: #fff;
    background: rgba(255,255,255,.09);
    cursor: pointer;
}

    .freight-stats-back:hover {
        background: rgba(255,255,255,.16);
    }

    .freight-stats-back svg {
        width: 17px;
        height: 17px;
    }

.freight-stats-hero__eyebrow {
    color: #bad0ff;
    font-size: .63rem;
    font-weight: 800;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.freight-stats-hero__title {
    margin: .12rem 0 0;
    font-size: 1.45rem;
    font-weight: 780;
    letter-spacing: -.03em;
}

.freight-stats-hero__metrics {
    display: flex;
    gap: .55rem;
}

.freight-stats-metric {
    min-width: 118px;
    padding: .65rem .8rem;
    border: 1px solid rgba(255,255,255,.16);
    border-radius: 12px;
    background: rgba(255,255,255,.09);
}

.freight-stats-metric__label {
    color: rgba(238,243,255,.72);
    font-size: .59rem;
    font-weight: 720;
}

.freight-stats-metric__value {
    margin-top: .18rem;
    color: #fff;
    font-size: .95rem;
    font-weight: 800;
    letter-spacing: -.02em;
}

.freight-month-strip {
    display: grid;
    grid-template-columns: repeat(12, minmax(88px,1fr));
    gap: .45rem;
    overflow-x: auto;
    margin-bottom: .85rem;
    padding: .15rem .05rem .45rem;
}

.freight-month-card {
    min-width: 88px;
    padding: .68rem .62rem;
    border: 1px solid var(--fr-line);
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 3px 10px rgba(46,72,124,.04);
}

.freight-month-card__month {
    color: #8a96a9;
    font-size: .59rem;
    font-weight: 760;
    text-transform: uppercase;
}

.freight-month-card__value {
    margin-top: .22rem;
    color: #273650;
    font-size: .72rem;
    font-weight: 780;
    white-space: nowrap;
}

.freight-month-card--active {
    border-color: #c9d8fb;
    background: #f2f6ff;
}

.freight-stats-layout {
    display: grid !important;
    grid-template-columns: 330px minmax(0, 1fr);
    gap: .85rem !important;
    align-items: start !important;
}

.freight-stats-sidebar,
.freight-stats-content {
    width: auto !important;
    min-width: 0;
}

.freight-stats-sidebar {
    position: sticky;
    top: .65rem;
}

.freight-stats-sidebar-card {
    overflow: hidden;
    margin-bottom: .75rem;
    border: 1px solid var(--fr-line);
    border-radius: 15px;
    background: #fff;
    box-shadow: var(--fr-card-shadow);
}

.freight-stats-sidebar-card__header {
    padding: .75rem .85rem;
    color: #2d3b54;
    font-size: .72rem;
    font-weight: 800;
    border-bottom: 1px solid #edf1f7;
    background: #fbfcff;
}

.freight-stats-date-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: .55rem;
    padding: .75rem;
}

    .freight-stats-date-grid .freight-btn {
        grid-column: 1 / -1;
    }

.freight-active-filter {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .5rem;
    padding: .45rem .55rem;
    margin: .35rem .7rem;
    border: 1px solid #e8edf5;
    border-radius: 9px;
    background: #fafbfe;
}

.freight-active-filter__text {
    min-width: 0;
    overflow: hidden;
    color: #526078;
    font-size: .7rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.freight-active-filter__remove {
    width: 24px;
    height: 24px;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    border: 0;
    border-radius: 7px;
    color: #a8455d;
    background: #fff0f3;
    cursor: pointer;
}

    .freight-active-filter__remove svg {
        width: 13px;
        height: 13px;
    }

.freight-stats-nav {
    display: flex !important;
    flex-direction: column;
    gap: .28rem !important;
    width: 100%;
    margin: 0;
    padding: .65rem !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    background: transparent !important;
}

    .freight-stats-nav .freight-tabs__item {
        width: 100%;
    }

    .freight-stats-nav .freight-tabs__link {
        width: 100%;
        justify-content: flex-start !important;
        min-height: 36px;
        padding: .48rem .58rem !important;
        border-radius: 9px !important;
        color: #67748a;
    }

    .freight-stats-nav .freight-tabs__link--active {
        background: #edf3ff !important;
        border: 1px solid #dbe6ff;
        color: #3159b6 !important;
        box-shadow: none;
    }

.freight-stat-mini-grid {
    display: grid;
    grid-template-columns: repeat(3,1fr);
    gap: .45rem;
    padding: .7rem;
}

.freight-stat-mini {
    padding: .55rem .45rem;
    text-align: center;
    border-radius: 9px;
    background: #f7f9fd;
}

.freight-stat-mini__value {
    color: #263750;
    font-size: .85rem;
    font-weight: 800;
}

.freight-stat-mini__label {
    margin-top: .12rem;
    color: #8994a7;
    font-size: .57rem;
    font-weight: 700;
}

.freight-stats-content-card {
    min-height: 520px;
    padding: .85rem;
    border: 1px solid var(--fr-line);
    border-radius: 16px;
    background: #fff;
    box-shadow: var(--fr-card-shadow);
}

.freight-stats-search {
    display: flex;
    align-items: center;
    gap: .55rem;
    margin-bottom: .7rem;
    padding: .35rem .45rem .35rem .7rem;
    border: 1px solid #e1e7f0;
    border-radius: 11px;
    background: #fafbfe;
}

    .freight-stats-search svg {
        width: 15px;
        height: 15px;
        color: #8895aa;
    }

    .freight-stats-search .freight-input {
        min-height: 32px;
        padding: .25rem;
        border: 0;
        background: transparent;
        box-shadow: none !important;
    }

.freight-stat-table tbody tr {
    cursor: pointer;
}

    .freight-stat-table tbody tr:hover td {
        background: #f4f7ff;
    }

.freight-stat-row td:first-child .freight-label {
    font-weight: 700;
    color: #34445f;
}

/* ── Scroll ─────────────────────────────────────────────────── */
.freight-scroll {
    scrollbar-color: #c8d2e4 transparent;
}

.freight-scroll--main {
    max-height: calc(100vh - 235px);
}

.freight-scroll--stats {
    max-height: calc(100vh - 245px);
    padding-right: .15rem;
}

.freight-scroll::-webkit-scrollbar {
    width: 7px;
    height: 7px;
}

.freight-scroll::-webkit-scrollbar-thumb {
    background: #c9d3e4;
    border: 2px solid transparent;
    background-clip: padding-box;
}

/* ── Motion ─────────────────────────────────────────────────── */
.freight-section-card,
.freight-filter-panel,
.freight-hierarchy,
.freight-stats-content-card,
.freight-kpi {
    animation: frPremiumEnter .28s ease both;
}

@keyframes frPremiumEnter {
    from {
        opacity: 0;
        transform: translateY(5px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ── Responsive ─────────────────────────────────────────────── */
@media (max-width: 1180px) {
    .freight-kpi-grid {
        grid-template-columns: repeat(2,minmax(0,1fr));
    }

    .freight-stats-layout {
        grid-template-columns: 285px minmax(0,1fr);
    }

    .freight-filter-field {
        grid-column: span 4;
    }

    .freight-filter-field--date,
    .freight-filter-field--invoice {
        grid-column: span 3;
    }

    .freight-filter-actions {
        grid-column: span 2;
    }
}

@media (max-width: 900px) {
    .freight-hero,
    .freight-stats-hero {
        grid-template-columns: 1fr;
    }

    .freight-hero__actions {
        width: 100%;
        flex-wrap: wrap;
    }

    .freight-nav-shell {
        overflow-x: auto;
    }

        .freight-nav-shell .freight-tabs {
            min-width: 760px;
        }

    .freight-stats-layout {
        grid-template-columns: 1fr;
    }

    .freight-stats-sidebar {
        position: static;
    }

    .freight-stats-hero__metrics {
        flex-wrap: wrap;
    }

    .freight-filter-field,
    .freight-filter-field--date,
    .freight-filter-field--invoice {
        grid-column: span 6;
    }

    .freight-filter-actions {
        grid-column: span 6;
    }
}

@media (max-width: 620px) {
    .freight-module {
        padding: .75rem .65rem 2rem;
    }

    .freight-hero {
        padding: 1.15rem;
        border-radius: 17px;
    }

    .freight-hero__icon {
        width: 48px;
        height: 48px;
        border-radius: 13px;
    }

    .freight-hero__actions .freight-btn {
        flex: 1 1 auto;
    }

    .freight-kpi-grid {
        grid-template-columns: 1fr;
    }

    .freight-filter-field,
    .freight-filter-field--date,
    .freight-filter-field--invoice,
    .freight-filter-actions {
        grid-column: 1 / -1;
    }

    .freight-stats-date-grid {
        grid-template-columns: 1fr;
    }

    .freight-stats-hero__metrics {
        display: grid;
        grid-template-columns: repeat(2,1fr);
    }

    .freight-stats-metric {
        min-width: 0;
    }

    .freight-stat-mini-grid {
        grid-template-columns: 1fr;
    }
}
