:root {
    --ink: #17202a;
    --muted: #6b7280;
    --line: #dce3ea;
    --panel: #ffffff;
    --wash: #f4f7fb;
    --primary: #0d9488;
    --primary-dark: #0f766e;
    --dark: #273449;
    --amber: #f59e0b;
    --danger: #dc2626;
    --success: #15803d;
    --radius: 8px;
    --shadow: 0 18px 45px rgba(31, 41, 55, .12);
}

* {
    box-sizing: border-box;
}

body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    margin: 0;
    color: var(--ink);
    background: var(--wash);
    font-family: "Segoe UI", Arial, sans-serif;
    line-height: 1.5;
}

a {
    color: inherit;
    text-decoration: none;
}

.app-header {
    position: sticky;
    top: 0;
    z-index: 30;
    background: rgba(255, 255, 255, .98);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(18px);
    box-shadow: 0 14px 38px rgba(31, 41, 55, .08);
}

.nav-shell,
.page-shell,
.app-footer {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
}

.nav-shell {
    min-height: 76px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 22px;
}

.brand {
    display: inline-flex;
    align-items: center;
    flex: 0 0 auto;
    min-width: 230px;
}

.brand-logo {
    display: block;
    width: clamp(190px, 18vw, 244px);
    height: auto;
}

.brand-mark {
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    color: #fff;
    background: linear-gradient(135deg, var(--primary), #2563eb);
    border-radius: 9px;
    font-weight: 800;
    font-size: 13px;
    box-shadow: 0 10px 22px rgba(13, 148, 136, .24);
}

.brand small {
    display: block;
    color: var(--muted);
    font-size: 11px;
}

.brand strong {
    font-size: 15px;
}

.nav-area {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex: 1;
    gap: 16px;
    min-width: 0;
}

.mobile-nav-head {
    display: none;
}

.nav-links {
    display: flex;
    align-items: center;
    flex-wrap: nowrap;
    justify-content: flex-end;
    gap: 2px;
    padding: 5px;
    background: #f8fafc;
    border: 1px solid #edf2f7;
    border-radius: 999px;
}

.nav-links a,
.nav-group-toggle {
    position: relative;
    min-height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 13px;
    border-radius: 999px;
    color: #243247;
    background: transparent;
    border: 0;
    cursor: pointer;
    font-family: inherit;
    font-size: 14px;
    font-weight: 750;
    transition: color .18s ease, background .18s ease, transform .18s ease;
}

.nav-links a::after,
.nav-group-toggle::after {
    position: absolute;
    right: 14px;
    bottom: 6px;
    left: 14px;
    height: 2px;
    content: "";
    background: linear-gradient(90deg, var(--primary), #2563eb);
    border-radius: 999px;
    transform: scaleX(0);
    transform-origin: center;
    transition: transform .18s ease;
}

.nav-links a:hover,
.nav-links a:focus,
.nav-group:hover > .nav-group-toggle,
.nav-group.is-open > .nav-group-toggle,
.nav-group-toggle:focus {
    background: #fff;
    color: var(--primary-dark);
    transform: translateY(-1px);
}

.nav-links a:hover::after,
.nav-links a:focus::after,
.nav-group:hover > .nav-group-toggle::after,
.nav-group.is-open > .nav-group-toggle::after,
.nav-group-toggle:focus::after {
    transform: scaleX(1);
}

.nav-group {
    position: relative;
}

.nav-group-toggle {
    padding-right: 28px;
}

.nav-group-toggle::before {
    position: absolute;
    top: 50%;
    right: 12px;
    width: 7px;
    height: 7px;
    content: "";
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: translateY(-65%) rotate(45deg);
    transition: transform .18s ease;
}

.nav-group.is-open > .nav-group-toggle::before,
.nav-group:hover > .nav-group-toggle::before {
    transform: translateY(-35%) rotate(225deg);
}

.nav-submenu {
    position: absolute;
    top: calc(100% + 12px);
    left: 50%;
    z-index: 50;
    min-width: 210px;
    display: grid;
    gap: 6px;
    padding: 10px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 12px;
    box-shadow: 0 22px 48px rgba(31, 41, 55, .16);
    opacity: 0;
    pointer-events: none;
    transform: translateX(-50%) translateY(8px);
    transition: opacity .18s ease, transform .18s ease;
}

.nav-submenu::before {
    position: absolute;
    top: -8px;
    left: 50%;
    width: 14px;
    height: 14px;
    content: "";
    background: #fff;
    border-top: 1px solid var(--line);
    border-left: 1px solid var(--line);
    transform: translateX(-50%) rotate(45deg);
}

.nav-group:hover > .nav-submenu,
.nav-group:focus-within > .nav-submenu,
.nav-group.is-open > .nav-submenu {
    opacity: 1;
    pointer-events: auto;
    transform: translateX(-50%) translateY(0);
}

.nav-submenu a {
    min-height: 40px;
    justify-content: flex-start;
    padding: 10px 12px;
    color: var(--dark);
    border-radius: 8px;
    white-space: nowrap;
}

.nav-submenu a::after {
    content: none;
}

.nav-submenu a:hover,
.nav-submenu a:focus {
    color: var(--primary-dark);
    background: #e8f7f5;
    transform: none;
}

.account-menu {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

.account-menu > a,
.account-menu > .nav-group > .nav-group-toggle {
    min-height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 34px 8px 14px;
    border-radius: 999px;
    color: var(--primary-dark);
    background: #e8f7f5;
    border: 1px solid #bdece5;
    font-size: 12px;
    font-weight: 800;
    transition: background .18s ease, color .18s ease, transform .18s ease;
}

.account-menu > .nav-group > .nav-group-toggle::after {
    content: none;
}

.account-menu > .nav-group > .nav-group-toggle::before {
    right: 15px;
    z-index: 1;
}

.nav-menu-label {
    display: block;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.account-menu > a:hover,
.account-menu > a:focus,
.account-menu > .nav-group:hover > .nav-group-toggle,
.account-menu > .nav-group.is-open > .nav-group-toggle,
.account-menu > .nav-group > .nav-group-toggle:focus {
    background: var(--primary);
    color: #fff;
    transform: translateY(-1px);
}

.account-menu > .logout-link {
    color: #fff;
    background: linear-gradient(135deg, #ef4444, #991b1b);
    border-color: transparent;
}

.account-menu .nav-submenu {
    right: 0;
    left: auto;
    transform: translateY(8px);
}

.account-menu .nav-submenu::before {
    right: 24px;
    left: auto;
    transform: rotate(45deg);
}

.account-menu .nav-group:hover > .nav-submenu,
.account-menu .nav-group:focus-within > .nav-submenu,
.account-menu .nav-group.is-open > .nav-submenu {
    transform: translateY(0);
}

.account-menu .nav-submenu a {
    width: 100%;
    justify-content: flex-start;
    color: var(--dark);
    background: transparent;
    border: 0;
    border-radius: 8px;
    font-size: 13px;
}

.account-menu .nav-submenu a:hover,
.account-menu .nav-submenu a:focus {
    color: var(--primary-dark);
    background: #e8f7f5;
    transform: none;
}

.account-menu .nav-submenu .logout-link {
    color: #991b1b;
    background: #fee2e2;
}

.user-account-menu .nav-submenu {
    min-width: 260px;
}

.user-menu-toggle {
    min-width: 118px;
    max-width: 180px;
}

.user-menu-detail {
    display: grid;
    gap: 2px;
    padding: 10px 12px;
    color: var(--dark);
    background: #f8fafc;
    border: 1px solid #edf2f7;
    border-radius: 8px;
}

.user-menu-detail span {
    color: var(--muted);
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
}

.user-menu-detail strong {
    color: var(--ink);
    font-size: 13px;
    overflow-wrap: anywhere;
}

.user-chip {
    display: grid;
    gap: 1px;
    max-width: 190px;
    min-height: 42px;
    padding: 7px 12px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: linear-gradient(180deg, #ffffff, #f7fbfc);
    box-shadow: 0 8px 20px rgba(31, 41, 55, .06);
    line-height: 1.15;
}

.user-chip strong {
    font-size: 12px;
    color: var(--ink);
}

.user-chip small {
    overflow: hidden;
    color: var(--muted);
    font-size: 10px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.nav-toggle {
    position: relative;
    z-index: 45;
    display: none;
    width: 44px;
    height: 44px;
    border: 1px solid var(--line);
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 12px 24px rgba(31, 41, 55, .08);
}

.nav-toggle span {
    display: block;
    width: 19px;
    height: 2px;
    margin: 3px auto;
    background: var(--dark);
    border-radius: 999px;
    transition: transform .18s ease, opacity .18s ease;
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
    transform: translateY(5px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
    opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
    transform: translateY(-5px) rotate(-45deg);
}

.nav-backdrop {
    display: none;
}

.page-shell {
    flex: 1 0 auto;
    padding: 32px 0 44px;
}

.app-footer {
    flex-shrink: 0;
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 26px 0;
    color: var(--muted);
    font-size: 14px;
}

.footer-credit {
    margin-left: auto;
    text-align: right;
}

.hero-band {
    min-height: 360px;
    display: grid;
    grid-template-columns: 1.4fr .8fr;
    align-items: center;
    gap: 28px;
    padding: 44px;
    color: #fff;
    background:
        linear-gradient(115deg, rgba(23, 32, 42, .94), rgba(13, 148, 136, .84)),
        url("https://images.unsplash.com/photo-1586528116311-ad8dd3c8310d?auto=format&fit=crop&w=1500&q=80") center/cover;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.eyebrow {
    margin: 0 0 8px;
    color: var(--primary);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.hero-band .eyebrow {
    color: #9ff4ea;
}

h1,
h2 {
    margin: 0;
    line-height: 1.12;
}

.hero-band h1 {
    max-width: 760px;
    font-size: clamp(34px, 6vw, 62px);
}

.hero-copy {
    max-width: 640px;
    margin: 18px 0 0;
    color: rgba(255, 255, 255, .86);
    font-size: 18px;
}

.hero-actions,
.form-actions,
.heading-actions,
.card-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 24px;
}

.hero-panel {
    padding: 28px;
    background: rgba(255, 255, 255, .14);
    border: 1px solid rgba(255, 255, 255, .26);
    border-radius: var(--radius);
    backdrop-filter: blur(12px);
}

.hero-panel span,
.hero-panel small {
    display: block;
    color: rgba(255, 255, 255, .78);
}

.hero-panel strong {
    display: block;
    margin: 8px 0;
    font-size: 42px;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 10px 16px;
    border: 1px solid transparent;
    border-radius: 7px;
    cursor: pointer;
    font-weight: 750;
    font-family: inherit;
}

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

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

.btn-ghost {
    color: var(--dark);
    background: #fff;
    border-color: var(--line);
}

.hero-band .btn-ghost {
    color: #fff;
    background: rgba(255, 255, 255, .13);
    border-color: rgba(255, 255, 255, .32);
}

.btn-dark {
    color: #fff;
    background: var(--dark);
}

.btn-danger {
    color: #fff;
    background: var(--danger);
}

.metric-grid,
.content-grid,
.detail-layout,
.supplier-grid {
    display: grid;
    gap: 18px;
    margin-top: 22px;
}

.metric-grid {
    grid-template-columns: repeat(6, 1fr);
}

.content-grid,
.detail-layout {
    grid-template-columns: minmax(0, 1.25fr) minmax(320px, .75fr);
}

.supplier-grid {
    grid-template-columns: repeat(3, 1fr);
}

.metric-card,
.panel,
.supplier-card,
.form-panel,
.detail-card {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: 0 10px 28px rgba(31, 41, 55, .07);
}

.metric-card {
    padding: 22px;
}

.metric-card span,
.metric-card small {
    display: block;
    color: var(--muted);
}

.metric-card strong {
    display: block;
    margin: 8px 0 2px;
    font-size: clamp(24px, 2.4vw, 34px);
}

.metric-card.warning {
    border-color: rgba(245, 158, 11, .45);
    background: #fff8eb;
}

.panel,
.form-panel,
.detail-card {
    padding: 24px;
}

.panel-header,
.page-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}

.page-heading {
    margin-bottom: 18px;
}

.page-heading h1 {
    font-size: 34px;
}

.text-link {
    color: var(--primary-dark);
    font-weight: 750;
}

.table-wrap {
    width: 100%;
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th,
td {
    padding: 14px 12px;
    text-align: left;
    border-bottom: 1px solid var(--line);
    vertical-align: middle;
}

th {
    color: var(--muted);
    font-size: 12px;
    text-transform: uppercase;
}

.status-pill {
    display: inline-flex;
    align-items: center;
    min-height: 24px;
    padding: 3px 9px;
    border-radius: 999px;
    color: var(--primary-dark);
    background: #dff8f3;
    font-size: 12px;
    font-weight: 800;
}

.status-pill.danger {
    color: #991b1b;
    background: #fee2e2;
}

.status-pill.success {
    color: var(--success);
    background: #dcfce7;
}

.stack-list {
    display: grid;
    gap: 10px;
    margin-top: 18px;
}

.stack-row,
.supplier-tile {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #fbfdff;
}

.stack-row small,
.stack-row em,
.supplier-tile span,
.supplier-tile small {
    display: block;
    color: var(--muted);
    font-style: normal;
}

.supplier-strip {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 12px;
    margin-top: 18px;
}

.supplier-tile {
    align-items: flex-start;
    flex-direction: column;
}

.toolbar {
    display: flex;
    gap: 12px;
    margin: 0 0 18px;
}

.list-summary {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    margin: 0 0 18px;
    color: var(--muted);
    font-size: 14px;
    font-weight: 750;
}

.pagination-bar {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 24px;
}

.page-link {
    min-width: 38px;
    min-height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--dark);
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 7px;
    font-weight: 800;
}

.page-link:hover,
.page-link.is-active {
    color: #fff;
    background: var(--primary);
    border-color: var(--primary);
}

input,
select,
textarea {
    width: 100%;
    min-height: 42px;
    padding: 10px 12px;
    color: var(--ink);
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 7px;
    font: inherit;
}

textarea {
    resize: vertical;
}

.toolbar input {
    flex: 1;
}

.toolbar select {
    max-width: 190px;
}

.actions {
    white-space: nowrap;
}

.actions a {
    margin-left: 10px;
    color: var(--primary-dark);
    font-weight: 750;
}

.supplier-card {
    display: flex;
    min-height: 300px;
    padding: 22px;
    flex-direction: column;
    justify-content: space-between;
}

.supplier-logo-box,
.supplier-detail-logo,
.supplier-logo-preview {
    display: flex;
    align-items: center;
}

.supplier-logo-box {
    width: 72px;
    height: 72px;
    justify-content: center;
    margin-bottom: 16px;
    overflow: hidden;
    color: #fff;
    background: linear-gradient(135deg, var(--primary), #2563eb);
    border-radius: 12px;
    box-shadow: 0 14px 28px rgba(31, 41, 55, .12);
}

.supplier-logo-box img,
.supplier-detail-logo img,
.supplier-logo-preview img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #fff;
}

.supplier-logo-box span,
.supplier-detail-logo span {
    font-size: 28px;
    font-weight: 850;
}

.supplier-detail-logo {
    width: 96px;
    height: 96px;
    justify-content: center;
    margin-bottom: 18px;
    overflow: hidden;
    color: #fff;
    background: linear-gradient(135deg, var(--primary), #2563eb);
    border-radius: 14px;
}

.supplier-logo-preview {
    gap: 12px;
    padding: 10px;
    background: #f8fafc;
    border: 1px solid var(--line);
    border-radius: 8px;
}

.supplier-logo-preview img {
    width: 64px;
    height: 64px;
    border-radius: 8px;
}

.supplier-logo-preview small,
.field-note {
    color: var(--muted);
    font-size: 13px;
    font-weight: 650;
}

.supplier-card h2 {
    font-size: 22px;
}

.supplier-card p {
    color: var(--muted);
}

dl {
    display: grid;
    grid-template-columns: 120px minmax(0, 1fr);
    gap: 10px 14px;
    margin: 20px 0 0;
}

dt {
    color: var(--muted);
    font-weight: 700;
}

dd {
    margin: 0;
    overflow-wrap: anywhere;
}

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

label {
    display: grid;
    gap: 7px;
    color: var(--dark);
    font-weight: 750;
}

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

.helper-note {
    margin-top: 16px;
    padding: 12px 14px;
    color: var(--dark);
    background: #eef8ff;
    border: 1px solid #cfe9ff;
    border-radius: 7px;
    font-size: 14px;
}

.validation-summary {
    margin-bottom: 16px;
    color: var(--danger);
    font-weight: 700;
}

.alert-success {
    margin-bottom: 18px;
    padding: 14px 16px;
    color: var(--success);
    background: #dcfce7;
    border: 1px solid #bbf7d0;
    border-radius: 7px;
    font-weight: 750;
}

.empty-state {
    margin: 18px 0 0;
    color: var(--muted);
}

.muted-cell {
    max-width: 360px;
    color: var(--muted);
    font-size: 13px;
    overflow-wrap: anywhere;
}

.detail-card.accent {
    background: linear-gradient(180deg, #ffffff, #effaf8);
}

.danger-panel {
    border-color: #fecaca;
    background: #fff7f7;
}

.login-shell {
    min-height: calc(100vh - 210px);
    display: grid;
    place-items: center;
    padding: 24px 0;
}

.login-panel {
    width: min(100%, 460px);
    padding: 30px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.login-brand {
    display: flex;
    gap: 16px;
    align-items: flex-start;
    margin-bottom: 24px;
}

.login-brand h1 {
    font-size: 30px;
}

.login-brand p:last-child {
    margin: 8px 0 0;
    color: var(--muted);
}

.login-form {
    display: grid;
    gap: 16px;
}

.check-row {
    display: flex;
    grid-template-columns: none;
    align-items: center;
    gap: 10px;
    color: var(--muted);
    font-weight: 650;
}

.check-row input {
    width: 18px;
    min-height: 18px;
}

.login-button {
    width: 100%;
}

@media (max-width: 1080px) {
    body.nav-open {
        overflow: hidden;
    }

    .nav-shell {
        min-height: 72px;
    }

    .brand {
        min-width: 0;
    }

    .brand-logo {
        width: clamp(184px, 42vw, 230px);
    }

    .nav-toggle {
        display: grid;
        place-items: center;
        flex: 0 0 auto;
        z-index: 80;
    }

    .nav-area {
        position: fixed;
        top: 0;
        right: 0;
        bottom: 0;
        z-index: 60;
        width: min(420px, 100vw);
        height: 100vh;
        height: 100dvh;
        display: flex;
        align-items: stretch;
        justify-content: flex-start;
        flex-direction: column;
        gap: 14px;
        padding: 82px 18px 24px;
        overflow-y: auto;
        background: #fff;
        border-left: 1px solid var(--line);
        box-shadow: -24px 0 52px rgba(31, 41, 55, .18);
        transform: translateX(105%);
        transition: transform .22s ease;
    }

    .mobile-nav-head {
        display: grid;
        gap: 2px;
        padding: 0 4px 12px;
        border-bottom: 1px solid var(--line);
    }

    .mobile-nav-head strong {
        color: var(--ink);
        font-size: 18px;
    }

    .mobile-nav-head small {
        color: var(--muted);
        font-weight: 700;
    }

    .nav-area.is-open {
        transform: translateX(0);
    }

    .nav-links,
    .account-menu {
        align-items: stretch;
        flex-direction: column;
        justify-content: flex-start;
        width: 100%;
        gap: 8px;
    }

    .nav-links {
        padding: 0;
        background: transparent;
        border: 0;
        border-radius: 0;
    }

    .nav-links a,
    .nav-group,
    .nav-group-toggle,
    .account-menu > a,
    .account-menu > .nav-group > .nav-group-toggle,
    .user-chip {
        min-height: 46px;
        max-width: none;
        width: 100%;
        justify-content: flex-start;
        border-radius: 10px;
    }

    .nav-links a,
    .nav-group-toggle,
    .account-menu > .nav-group > .nav-group-toggle {
        padding: 12px 40px 12px 14px;
        background: #f8fafc;
        border: 1px solid #edf2f7;
        color: #243247;
    }

    .nav-links a::after,
    .nav-group-toggle::after {
        right: auto;
        bottom: 10px;
        left: 14px;
        width: 34px;
    }

    .nav-group-toggle::before {
        right: 16px;
    }

    .nav-submenu,
    .account-menu .nav-submenu {
        position: static;
        min-width: 0;
        max-height: 0;
        display: grid;
        gap: 7px;
        margin-top: 0;
        padding: 0 0 0 12px;
        overflow: hidden;
        background: transparent;
        border: 0;
        border-left: 2px solid #d9f1ee;
        border-radius: 0;
        box-shadow: none;
        opacity: 1;
        pointer-events: auto;
        transform: none;
        transition: max-height .22s ease, margin-top .22s ease;
    }

    .nav-submenu::before,
    .account-menu .nav-submenu::before {
        content: none;
    }

    .nav-group.is-open > .nav-submenu,
    .account-menu .nav-group.is-open > .nav-submenu {
        max-height: 240px;
        margin-top: 8px;
        transform: none;
    }

    .nav-submenu a,
    .account-menu .nav-submenu a {
        min-height: 42px;
        padding: 10px 12px;
        color: var(--dark);
        background: #fff;
        border: 1px solid #edf2f7;
        border-radius: 9px;
        white-space: normal;
    }

    .account-menu .nav-submenu .logout-link {
        color: #991b1b;
        background: #fee2e2;
        border-color: #fecaca;
    }

    .user-account-menu .nav-submenu {
        min-width: 0;
    }

    .user-menu-toggle {
        max-width: none;
    }

    .account-menu {
        padding-top: 18px;
        border-top: 1px solid var(--line);
    }

    .nav-backdrop {
        position: fixed;
        inset: 0;
        z-index: 35;
        display: block;
        pointer-events: none;
        background: rgba(15, 23, 42, .42);
        opacity: 0;
        transition: opacity .22s ease;
    }

    body.nav-open .nav-backdrop {
        pointer-events: auto;
        opacity: 1;
    }
}

@media (max-width: 920px) {
    .hero-band,
    .content-grid,
    .detail-layout {
        grid-template-columns: 1fr;
    }

    .metric-grid,
    .supplier-grid,
    .supplier-strip {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 680px) {
    .nav-shell,
    .page-shell,
    .app-footer {
        width: min(100% - 20px, 1180px);
    }

    .nav-shell {
        min-height: 68px;
        padding: 8px 0;
    }

    .brand-logo {
        width: min(168px, 62vw);
    }

    .nav-toggle {
        width: 42px;
        height: 42px;
    }

    .nav-area {
        width: 100vw;
        padding-right: 16px;
        padding-left: 16px;
    }

    .hero-band {
        padding: 28px;
    }

    .hero-band h1 {
        font-size: 34px;
    }

    .metric-grid,
    .supplier-grid,
    .supplier-strip,
    .form-grid {
        grid-template-columns: 1fr;
    }

    .toolbar,
    .list-summary,
    .page-heading,
    .panel-header,
    .app-footer {
        align-items: stretch;
        flex-direction: column;
    }

    .footer-credit {
        margin-left: 0;
        text-align: left;
    }

    .toolbar select {
        max-width: none;
    }

    dl {
        grid-template-columns: 1fr;
    }
}
