/**
 * Nexsend Portal Styles
 *
 * Customer-facing portal UI. Designed to feel like a standalone app,
 * not a WordPress site. Clean, professional, Nexsend-branded.
 */

/* ─── Variables ──────────────────────────────────────────────────────── */
:root {
    --ns-primary: #3D338C;
    --ns-primary-hover: #322A75;
    --ns-primary-light: #ECEBF3;
    --ns-primary-violet: #873EFF;
    --ns-amber: #EDA62B;
    --ns-amber-hover: #C9890F;
    --ns-amber-light: #FFE0AB;
    --ns-cream: #F7EDDB;
    --ns-ink: #2F3536;
    --ns-danger: #C7384B;
    --ns-danger-hover: #A12B3B;
    --ns-danger-light: #FBE7EA;
    --ns-success: #1F8A5B;
    --ns-success-light: #E3F4EC;
    --ns-warning: #B57608;
    --ns-warning-light: #FDF1DC;
    --ns-info: #2A57DB;
    --ns-info-light: #E5EBFC;
    --ns-gray-50: #FAF9FC;
    --ns-gray-100: #F4F3F8;
    --ns-gray-200: #E4E2EE;
    --ns-gray-300: #D1D5DB;
    --ns-gray-400: #9CA3AF;
    --ns-gray-500: #7B8082;
    --ns-gray-600: #4A5152;
    --ns-gray-700: #374151;
    --ns-gray-800: #2F3536;
    --ns-gray-900: #221C52;
    --ns-radius: 10px;
    --ns-radius-lg: 14px;
    --ns-radius-xl: 20px;
    --ns-shadow-sm: 0 1px 2px rgba(26, 24, 48, 0.06);
    --ns-shadow: 0 2px 8px rgba(26, 24, 48, 0.08);
    --ns-shadow-md: 0 4px 16px rgba(26, 24, 48, 0.1);
    --ns-shadow-lg: 0 12px 40px rgba(26, 24, 48, 0.16);
    --ns-font: 'Mulish', system-ui, -apple-system, 'Segoe UI', sans-serif;
    --ns-font-mono: 'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, monospace;
}

/* ─── Base ───────────────────────────────────────────────────────────── */
.nexsend-portal {
    padding-top: 200px;
    padding-bottom: 200px;
}

.nexsend-portal {
    font-family: var(--ns-font);
    color: var(--ns-gray-800);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

.nexsend-portal *,
.nexsend-portal *::before,
.nexsend-portal *::after {
    box-sizing: border-box;
}

/*
 * The theme defaults text inputs to white-on-transparent for forms placed on
 * dark marketing sections. Portal screens use light surfaces, so establish a
 * higher-specificity palette at the portal boundary instead of changing that
 * intentional theme default. Keep control geometry in the component rules.
 */
body.nexsend-portal-page .nexsend-portal :where(
    input:not([type]),
    input[type="text"],
    input[type="url"],
    input[type="email"],
    input[type="tel"],
    input[type="number"],
    input[type="password"],
    input[type="search"],
    input[type="date"],
    input[type="datetime-local"],
    input[type="time"],
    input[type="month"],
    input[type="week"],
    textarea,
    select,
    option
),
body.nexsend-portal-page .nexsend-auth :where(
    input:not([type]),
    input[type="text"],
    input[type="url"],
    input[type="email"],
    input[type="tel"],
    input[type="number"],
    input[type="password"],
    input[type="search"],
    input[type="date"],
    input[type="datetime-local"],
    input[type="time"],
    input[type="month"],
    input[type="week"],
    textarea,
    select,
    option
),
body.nexsend-portal-page .ns-cmdk :where(
    input:not([type]),
    input[type="text"],
    input[type="search"],
    textarea
) {
    color: var(--ns-gray-900);
    -webkit-text-fill-color: var(--ns-gray-900);
    caret-color: var(--ns-gray-900);
}

body.nexsend-portal-page .nexsend-portal :where(
    input:not([type]),
    input[type="text"],
    input[type="url"],
    input[type="email"],
    input[type="tel"],
    input[type="number"],
    input[type="password"],
    input[type="search"],
    input[type="date"],
    input[type="datetime-local"],
    input[type="time"],
    input[type="month"],
    input[type="week"],
    textarea,
    select
),
body.nexsend-portal-page .nexsend-auth :where(
    input:not([type]),
    input[type="text"],
    input[type="url"],
    input[type="email"],
    input[type="tel"],
    input[type="number"],
    input[type="password"],
    input[type="search"],
    input[type="date"],
    input[type="datetime-local"],
    input[type="time"],
    input[type="month"],
    input[type="week"],
    textarea,
    select
) {
    background-color: #fff;
    border-color: var(--ns-gray-200);
}

body.nexsend-portal-page .nexsend-portal :where(input, textarea)::placeholder,
body.nexsend-portal-page .nexsend-auth :where(input, textarea)::placeholder,
body.nexsend-portal-page .ns-cmdk :where(input, textarea)::placeholder {
    color: var(--ns-gray-500);
    -webkit-text-fill-color: var(--ns-gray-500);
    opacity: 1;
}

body.nexsend-portal-page .nexsend-portal :where(
    input:not([type]),
    input[type="text"],
    input[type="url"],
    input[type="email"],
    input[type="tel"],
    input[type="number"],
    input[type="password"],
    input[type="search"],
    input[type="date"],
    input[type="datetime-local"],
    input[type="time"],
    input[type="month"],
    input[type="week"],
    textarea,
    select
):disabled,
body.nexsend-portal-page .nexsend-auth :where(
    input:not([type]),
    input[type="text"],
    input[type="url"],
    input[type="email"],
    input[type="tel"],
    input[type="number"],
    input[type="password"],
    input[type="search"],
    input[type="date"],
    input[type="datetime-local"],
    input[type="time"],
    input[type="month"],
    input[type="week"],
    textarea,
    select
):disabled,
body.nexsend-portal-page .ns-cmdk :where(
    input:not([type]),
    input[type="text"],
    input[type="search"],
    textarea
):disabled {
    color: var(--ns-gray-500);
    -webkit-text-fill-color: var(--ns-gray-500);
    opacity: 1;
}

body.nexsend-portal-page .nexsend-portal input:-webkit-autofill,
body.nexsend-portal-page .nexsend-auth input:-webkit-autofill,
body.nexsend-portal-page .ns-cmdk input:-webkit-autofill {
    -webkit-text-fill-color: var(--ns-gray-900);
    caret-color: var(--ns-gray-900);
    -webkit-box-shadow: 0 0 0 1000px #fff inset;
}

.nexsend-portal h1 {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 0 1.5rem;
    color: var(--ns-gray-900);
}

.nexsend-portal h2 {
    font-size: 1.125rem;
    font-weight: 600;
    margin: 0 0 1rem;
    color: var(--ns-gray-800);
}

.nexsend-portal__content {
    max-width: 1100px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
}

.nexsend-portal__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.nexsend-portal__header h1 {
    margin: 0;
}

.nexsend-portal__section {
    margin-top: 2.5rem;
}

.nexsend-portal__intro {
    color: var(--ns-gray-500);
    margin-bottom: 1.5rem;
}

.nexsend-portal__actions {
    margin: 1.5rem 0;
}

.nexsend-portal__pending {
    text-align: center;
    padding: 4rem 2rem;
}

.nexsend-empty {
    color: var(--ns-gray-400);
    font-style: italic;
    padding: 2rem 0;
}

/* ─── Stats cards ────────────────────────────────────────────────────── */
.nexsend-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.nexsend-stats__card {
    background: #fff;
    border: 1px solid var(--ns-gray-200);
    border-radius: var(--ns-radius);
    padding: 1.25rem;
    text-align: center;
    box-shadow: var(--ns-shadow);
}

.nexsend-stats__card--highlight {
    border-color: var(--ns-primary);
    background: var(--ns-primary-light);
}

.nexsend-stats__number {
    display: block;
    font-size: 2rem;
    font-weight: 700;
    color: var(--ns-gray-900);
}

.nexsend-stats__card--highlight .nexsend-stats__number {
    color: var(--ns-primary);
}

.nexsend-stats__label {
    display: block;
    font-size: 0.8125rem;
    color: var(--ns-gray-500);
    margin-top: 0.25rem;
}

/* ─── Table ──────────────────────────────────────────────────────────── */
.nexsend-table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    border: 1px solid var(--ns-gray-200);
    border-radius: var(--ns-radius);
    overflow: hidden;
    font-size: 0.875rem;
}

.nexsend-table thead {
    background: var(--ns-gray-50);
}

.nexsend-table th {
    text-align: left;
    padding: 0.75rem 1rem;
    font-weight: 600;
    color: var(--ns-gray-600);
    font-size: 0.8125rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    border-bottom: 1px solid var(--ns-gray-200);
}

.nexsend-table td {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--ns-gray-100);
    color: var(--ns-gray-700);
}

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

.nexsend-table tbody tr:hover {
    background: var(--ns-gray-50);
}

.nexsend-table tfoot th {
    text-align: left;
    border-top: 2px solid var(--ns-gray-200);
}

.nexsend-table--summary {
    max-width: 500px;
}

.nexsend-table--summary th {
    width: 40%;
    text-transform: none;
    letter-spacing: normal;
}

.nexsend-table code {
    font-size: 0.8125rem;
    background: var(--ns-gray-100);
    padding: 0.125rem 0.375rem;
    border-radius: 4px;
}

/* ─── Badges ─────────────────────────────────────────────────────────── */
.nexsend-badge {
    display: inline-block;
    padding: 0.125rem 0.5rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.nexsend-badge--pending,
.nexsend-badge--draft { background: var(--ns-warning-light); color: #92400e; }
.nexsend-badge--processing,
.nexsend-badge--created,
.nexsend-badge--sent { background: var(--ns-primary-light); color: var(--ns-primary); }
.nexsend-badge--shipped,
.nexsend-badge--in_transit,
.nexsend-badge--label_printed { background: var(--ns-info-light); color: var(--ns-info); }
.nexsend-badge--delivered,
.nexsend-badge--paid,
.nexsend-badge--active { background: var(--ns-success-light); color: #166534; }
.nexsend-badge--cancelled,
.nexsend-badge--failed,
.nexsend-badge--returned,
.nexsend-badge--overdue { background: #fecaca; color: #991b1b; }
.nexsend-badge--package { background: var(--ns-gray-100); color: var(--ns-gray-700); }

/* ─── Buttons ────────────────────────────────────────────────────────── */
.nexsend-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border: 1px solid var(--ns-gray-300);
    border-radius: 6px;
    background: #fff;
    color: var(--ns-gray-700);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    transition: background-color 0.15s, border-color 0.15s;
    font-family: var(--ns-font);
    line-height: 1.5;
}

.nexsend-btn:hover {
    background: var(--ns-gray-50);
    border-color: var(--ns-gray-400);
}

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

.nexsend-btn--primary:hover {
    background: var(--ns-primary-hover);
    border-color: var(--ns-primary-hover);
}

.nexsend-btn--danger {
    color: var(--ns-danger);
    border-color: var(--ns-danger);
}

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

.nexsend-btn--outline {
    background: transparent;
    border-color: var(--ns-gray-300);
    color: var(--ns-gray-700);
}

.nexsend-btn--outline:hover {
    background: var(--ns-gray-50);
    border-color: var(--ns-gray-400);
}

.nexsend-btn--small {
    padding: 0.25rem 0.625rem;
    font-size: 0.8125rem;
}

.nexsend-btn--large {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
}

.nexsend-btn--full {
    width: 100%;
}

.nexsend-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.nexsend-btn--secondary {
    background: #fff;
    border-color: var(--ns-gray-200);
    color: var(--ns-gray-800);
}
.nexsend-btn--secondary:hover {
    background: var(--ns-gray-100);
    border-color: var(--ns-gray-300);
}

.nexsend-btn--ghost {
    background: transparent;
    border-color: transparent;
    color: var(--ns-gray-600);
}
.nexsend-btn--ghost:hover {
    background: var(--ns-gray-100);
    color: var(--ns-gray-900);
}

.nexsend-btn--amber {
    background: var(--ns-amber);
    border-color: var(--ns-amber);
    color: #fff;
}
.nexsend-btn--amber:hover {
    background: var(--ns-amber-hover);
    border-color: var(--ns-amber-hover);
}

.nexsend-btn--sm {
    padding: 6px 10px;
    font-size: 0.75rem;
}

/* Match the design's pill-shaped italic-Mulish button when inside the
   portal app shell. */
body.nexsend-portal-app .nexsend-btn {
    border-radius: 999px;
    font-style: italic;
    font-weight: 700;
    font-size: 13px;
    padding: 9px 16px;
}
body.nexsend-portal-app .nexsend-btn--sm {
    padding: 6px 12px;
    font-size: 12px;
}

/* ─── Forms ──────────────────────────────────────────────────────────── */
.nexsend-form__row {
    margin-bottom: 1rem;
}

.nexsend-form__row label {
    display: block;
    font-weight: 500;
    margin-bottom: 0.375rem;
    font-size: 0.875rem;
    color: var(--ns-gray-700);
}

.nexsend-portal .nexsend-form__row input[type="text"],
.nexsend-portal .nexsend-form__row input[type="email"],
.nexsend-portal .nexsend-form__row input[type="password"],
.nexsend-form__input {
    display: block !important;
    width: 100% !important;
    height: auto !important;
    padding: 0.5rem 0.75rem !important;
    border: 1px solid #d1d5db !important;
    border-radius: 6px !important;
    font-size: 0.875rem !important;
    font-family: var(--ns-font) !important;
    line-height: 1.5 !important;
    color: #1f2937 !important;
    background-color: #fff !important;
    box-shadow: none !important;
    transition: border-color 0.15s;
    box-sizing: border-box !important;
    margin: 0 !important;
    opacity: 1 !important;
}

.nexsend-portal .nexsend-form__row input:focus,
.nexsend-form__input:focus {
    outline: none !important;
    border-color: #3D338C !important;
    box-shadow: 0 0 0 3px rgba(61, 51, 140, 0.18) !important;
}

.nexsend-portal .nexsend-form__row select {
    display: block !important;
    width: 100% !important;
    height: auto !important;
    padding: 0.5rem 0.75rem !important;
    border: 1px solid #d1d5db !important;
    border-radius: 6px !important;
    font-size: 0.875rem !important;
    font-family: var(--ns-font) !important;
    line-height: 1.5 !important;
    color: #1f2937 !important;
    background-color: #fff !important;
    -webkit-appearance: menulist !important;
    -moz-appearance: menulist !important;
    appearance: menulist !important;
    cursor: pointer;
    box-shadow: none !important;
    transition: border-color 0.15s;
    box-sizing: border-box !important;
    margin: 0 !important;
    opacity: 1 !important;
}

.nexsend-portal .nexsend-form__row select:focus {
    outline: none !important;
    border-color: #3D338C !important;
    box-shadow: 0 0 0 3px rgba(61, 51, 140, 0.18) !important;
}

.nexsend-form__row small {
    display: block;
    margin-top: 0.25rem;
    font-size: 0.75rem;
    color: var(--ns-gray-400);
}

.nexsend-form__row--half {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.nexsend-form__row--inline {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nexsend-form__checkbox {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 400;
    cursor: pointer;
}

.nexsend-form__checkbox input[type="checkbox"] {
    width: auto;
}

.nexsend-form--inline {
    display: flex;
    gap: 0.75rem;
    align-items: flex-end;
}

.nexsend-form--inline .nexsend-form__input {
    flex: 1;
}

.nexsend-form__message {
    padding: 0.75rem 1rem;
    border-radius: 6px;
    margin-bottom: 1rem;
    font-size: 0.875rem;
}

.nexsend-form__message--success {
    background: var(--ns-success-light);
    color: #166534;
    border: 1px solid #bbf7d0;
}

.nexsend-form__message--error {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

/* ─── Filters ────────────────────────────────────────────────────────── */
.nexsend-filters {
    display: flex;
    gap: 0.25rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.nexsend-filters__item {
    padding: 0.375rem 0.75rem;
    border-radius: 6px;
    font-size: 0.8125rem;
    text-decoration: none;
    color: var(--ns-gray-600);
    background: var(--ns-gray-100);
    transition: background-color 0.15s, color 0.15s;
}

.nexsend-filters__item:hover {
    background: var(--ns-gray-200);
    color: var(--ns-gray-800);
}

.nexsend-filters__item--active {
    background: var(--ns-primary);
    color: #fff;
}

.nexsend-filters__item--active:hover {
    background: var(--ns-primary-hover);
    color: #fff;
}

/* ─── Pagination ─────────────────────────────────────────────────────── */
.nexsend-pagination {
    display: flex;
    gap: 0.25rem;
    margin-top: 1.5rem;
    justify-content: center;
}

.nexsend-pagination__page {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    border-radius: 6px;
    font-size: 0.8125rem;
    text-decoration: none;
    color: var(--ns-gray-600);
    background: var(--ns-gray-100);
}

.nexsend-pagination__page:hover {
    background: var(--ns-gray-200);
}

.nexsend-pagination__page--active {
    background: var(--ns-primary);
    color: #fff;
}

/* ─── Login ──────────────────────────────────────────────────────────── */
.nexsend-login {
    display: flex;
    justify-content: center;
    padding: 200px 1.5rem;
    font-family: var(--ns-font);
    min-height: 60vh;
    align-items: flex-start;
    color: #1f2937 !important;
}

.nexsend-login__card {
    width: 100%;
    max-width: 440px;
    background: #fff;
    border: 1px solid var(--ns-gray-200);
    border-radius: 12px;
    padding: 2.5rem;
    box-shadow: var(--ns-shadow-md);
}

.nexsend-login label,
.nexsend-login .nexsend-form__checkbox {
    color: #374151 !important;
}

.nexsend-login input[type="email"],
.nexsend-login input[type="password"],
.nexsend-login input[type="text"] {
    display: block !important;
    width: 100% !important;
    height: auto !important;
    padding: 0.5rem 0.75rem !important;
    font-size: 0.875rem !important;
    font-family: var(--ns-font) !important;
    line-height: 1.5 !important;
    color: #1f2937 !important;
    background-color: #fff !important;
    border: 1px solid #d1d5db !important;
    border-radius: 6px !important;
    box-shadow: none !important;
    box-sizing: border-box !important;
    margin: 0 !important;
    opacity: 1 !important;
}

.nexsend-login input:focus {
    outline: none !important;
    border-color: #3D338C !important;
    box-shadow: 0 0 0 3px rgba(61, 51, 140, 0.18) !important;
}

.nexsend-login__card h2 {
    text-align: center;
    margin-bottom: 0.5rem;
    font-size: 1.375rem;
    font-weight: 700;
    color: var(--ns-gray-900);
}

.nexsend-login__register {
    text-align: center;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--ns-gray-100);
    font-size: 0.875rem;
    color: var(--ns-gray-500);
}

.nexsend-login__register a {
    color: var(--ns-primary);
    font-weight: 500;
}

.nexsend-link {
    color: var(--ns-primary);
    text-decoration: none;
    font-size: 0.8125rem;
}

.nexsend-link:hover {
    text-decoration: underline;
}

/* ─── Shipment creation ──────────────────────────────────────────────── */
.nexsend-shipment-step {
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--ns-gray-200);
}

.nexsend-shipment-step:last-of-type {
    border-bottom: none;
}

.nexsend-order-select {
    display: grid;
    gap: 0.5rem;
}

.nexsend-order-card {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    border: 2px solid var(--ns-gray-200);
    border-radius: var(--ns-radius);
    cursor: pointer;
    transition: border-color 0.15s;
}

.nexsend-order-card:hover {
    border-color: var(--ns-gray-300);
}

.nexsend-order-card--selected {
    border-color: var(--ns-primary);
    background: var(--ns-primary-light);
}

.nexsend-order-card input[type="radio"] {
    accent-color: var(--ns-primary);
}

.nexsend-order-card__content {
    display: flex;
    gap: 1rem;
    align-items: center;
    flex: 1;
    font-size: 0.875rem;
}

.nexsend-package-select {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 0.75rem;
}

.nexsend-package-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 1rem;
    border: 2px solid var(--ns-gray-200);
    border-radius: var(--ns-radius);
    cursor: pointer;
    transition: border-color 0.15s;
}

.nexsend-package-card:hover {
    border-color: var(--ns-gray-300);
}

.nexsend-package-card--selected {
    border-color: var(--ns-primary);
    background: var(--ns-primary-light);
}

.nexsend-package-card input[type="radio"] {
    display: none;
}

.nexsend-package-card__content {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.nexsend-package-card__content strong {
    font-size: 0.8125rem;
}

.nexsend-package-card__type {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--ns-primary);
}

.nexsend-package-card__price {
    font-size: 1rem;
    font-weight: 600;
    color: var(--ns-gray-900);
}

.nexsend-package-card__base {
    font-size: 0.75rem;
    color: var(--ns-gray-400);
    text-decoration: line-through;
}

.nexsend-shipment-summary {
    margin-bottom: 1rem;
}

.nexsend-shipment-result {
    text-align: center;
    padding: 2rem;
    background: var(--ns-success-light);
    border: 1px solid #bbf7d0;
    border-radius: var(--ns-radius);
}

.nexsend-shipment-result h2 {
    color: #166534;
    margin-bottom: 1rem;
}

.nexsend-shipment-result__info {
    margin-bottom: 1.5rem;
}

.nexsend-shipment-result__actions {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* ─── API Keys ───────────────────────────────────────────────────────── */
.nexsend-api-generate {
    margin-bottom: 1.5rem;
}

.nexsend-api-new-key {
    margin-bottom: 1.5rem;
}

/* ─── Register form ──────────────────────────────────────────────────── */
.nexsend-register {
    display: flex;
    justify-content: center;
    padding: 200px 1.5rem;
    font-family: var(--ns-font);
    min-height: 60vh;
    align-items: flex-start;
    color: #1f2937 !important;
}

.nexsend-register__card {
    width: 100%;
    max-width: 560px;
    background: #fff;
    border: 1px solid var(--ns-gray-200);
    border-radius: 12px;
    padding: 2.5rem;
    box-shadow: var(--ns-shadow-md);
}

.nexsend-register label {
    color: #374151 !important;
}

.nexsend-register small {
    color: #9ca3af !important;
}

.nexsend-register .nexsend-form__section h3 {
    color: #9ca3af !important;
}

.nexsend-register input[type="email"],
.nexsend-register input[type="password"],
.nexsend-register input[type="text"] {
    display: block !important;
    width: 100% !important;
    height: auto !important;
    padding: 0.5rem 0.75rem !important;
    font-size: 0.875rem !important;
    font-family: var(--ns-font) !important;
    line-height: 1.5 !important;
    color: #1f2937 !important;
    background-color: #fff !important;
    border: 1px solid #d1d5db !important;
    border-radius: 6px !important;
    box-shadow: none !important;
    box-sizing: border-box !important;
    margin: 0 !important;
    opacity: 1 !important;
}

.nexsend-register input:focus {
    outline: none !important;
    border-color: #3D338C !important;
    box-shadow: 0 0 0 3px rgba(61, 51, 140, 0.18) !important;
}

.nexsend-register__card h2 {
    text-align: center;
    margin-bottom: 0.25rem;
    font-size: 1.375rem;
    font-weight: 700;
    color: var(--ns-gray-900);
}

.nexsend-register__intro {
    text-align: center;
    color: var(--ns-gray-500);
    font-size: 0.9375rem;
    margin-bottom: 2rem;
}

.nexsend-register__login {
    text-align: center;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--ns-gray-100);
    font-size: 0.875rem;
    color: var(--ns-gray-500);
}

.nexsend-register__login a {
    color: var(--ns-primary);
    font-weight: 500;
}

.nexsend-form__section {
    margin-bottom: 1.5rem;
}

.nexsend-form__section h3 {
    font-size: 0.8125rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--ns-gray-400);
    margin-bottom: 0.75rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--ns-gray-100);
}

/* ─── Batch action bar ───────────────────────────────────────────────── */
.nexsend-batch-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    padding: 1rem 2rem;
    background: var(--ns-gray-900);
    color: #fff;
    font-size: 0.9375rem;
    box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.15);
    z-index: 100;
}

.nexsend-batch-bar__count {
    color: var(--ns-gray-300);
}

.nexsend-table__check {
    width: 40px;
    text-align: center;
}

.nexsend-table__check input[type="checkbox"] {
    accent-color: var(--ns-primary);
    width: 16px;
    height: 16px;
    cursor: pointer;
}

/* ─── Modal ──────────────────────────────────────────────────────────── */
.nexsend-modal {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 200;
    font-family: var(--ns-font);
}

.nexsend-modal__overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
}

.nexsend-modal__content {
    position: relative;
    width: 90%;
    max-width: 600px;
    max-height: 80vh;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    display: flex;
    flex-direction: column;
}

.nexsend-modal__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--ns-gray-200);
}

.nexsend-modal__header h2 {
    margin: 0;
    font-size: 1.125rem;
    font-weight: 600;
}

.nexsend-modal__close {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--ns-gray-400);
    padding: 0;
    line-height: 1;
}

.nexsend-modal__close:hover {
    color: var(--ns-gray-700);
}

.nexsend-modal__body {
    padding: 1.5rem;
    overflow-y: auto;
    flex: 1;
}

.nexsend-modal__footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--ns-gray-200);
}

.nexsend-table--compact {
    font-size: 0.875rem;
}

.nexsend-table--compact td,
.nexsend-table--compact th {
    padding: 0.5rem 0.75rem;
}

/* ─── Progress bar ───────────────────────────────────────────────────── */
.nexsend-batch-progress {
    text-align: center;
    padding: 1rem 0;
}

.nexsend-progress-bar {
    width: 100%;
    height: 6px;
    background: var(--ns-gray-200);
    border-radius: 3px;
    margin: 1rem 0;
    overflow: hidden;
}

.nexsend-progress-bar__fill {
    height: 100%;
    background: var(--ns-primary);
    border-radius: 3px;
    width: 100%;
    animation: nexsend-progress 1.5s ease-in-out infinite;
}

@keyframes nexsend-progress {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.nexsend-batch-progress__status {
    color: var(--ns-gray-500);
    font-size: 0.875rem;
}

/* ─── Batch results ──────────────────────────────────────────────────── */
.nexsend-batch-results {
    font-size: 0.9375rem;
}

/* ─── Detail Pages ───────────────────────────────────────────────────── */
.nexsend-back-link {
    display: inline-block;
    margin-bottom: 1rem;
    color: var(--ns-gray-500);
    text-decoration: none;
    font-size: 0.875rem;
}

.nexsend-back-link:hover {
    color: var(--ns-primary);
}

.nexsend-detail__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.nexsend-detail__header h1 {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin: 0;
}

.nexsend-detail__header h1 .nexsend-badge {
    font-size: 0.75rem;
}

.nexsend-detail__actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nexsend-select--small {
    padding: 0.375rem 0.5rem;
    font-size: 0.875rem;
    border: 1px solid #d1d5db;
    border-radius: 0.375rem;
    background: #fff;
}

.nexsend-detail__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.nexsend-detail__card {
    background: #fff;
    border: 1px solid var(--ns-gray-200);
    border-radius: 8px;
    padding: 1.5rem;
}

.nexsend-detail__card h3 {
    margin: 0 0 1rem;
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--ns-gray-500);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.nexsend-detail__dl {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 0.5rem 1rem;
    margin: 0;
    font-size: 0.9375rem;
}

.nexsend-detail__dl dt {
    color: var(--ns-gray-500);
    font-weight: 500;
}

.nexsend-detail__dl dd {
    margin: 0;
    color: var(--ns-gray-900);
}

.nexsend-detail__section {
    margin-bottom: 2rem;
}

.nexsend-detail__section h2 {
    font-size: 1.125rem;
    margin: 0 0 1rem;
}

/* ─── Header Actions ─────────────────────────────────────────────────── */
.nexsend-portal__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.nexsend-archive-notice {
    color: var(--ns-gray-500);
    font-size: 0.875rem;
    font-style: italic;
    margin: 0 0 1rem;
}

/* ─── Create Shipment Form ───────────────────────────────────────────── */
.nexsend-form__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-bottom: 1.5rem;
}

.nexsend-form__section {
    margin-bottom: 1.5rem;
}

.nexsend-form__section h3 {
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--ns-gray-200);
}

.nexsend-form__field {
    margin-bottom: 0.75rem;
}

.nexsend-form__field label {
    display: block;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--ns-gray-600);
    margin-bottom: 0.25rem;
}

.nexsend-portal .nexsend-form__field input[type="text"],
.nexsend-portal .nexsend-form__field input[type="email"],
.nexsend-portal .nexsend-form__field input[type="tel"],
.nexsend-portal .nexsend-form__field input[type="password"],
.nexsend-portal .nexsend-form__field input[type="number"],
.nexsend-portal .nexsend-form__field input:not([type]),
.nexsend-portal .nexsend-form__field select,
.nexsend-portal .nexsend-form__field textarea {
    display: block !important;
    width: 100% !important;
    height: auto !important;
    padding: 0.5rem 0.625rem !important;
    font-size: 0.875rem !important;
    font-family: var(--ns-font) !important;
    line-height: 1.5 !important;
    color: #1f2937 !important;
    background-color: #fff !important;
    border: 1px solid #d1d5db !important;
    border-radius: 0.375rem !important;
    box-shadow: none !important;
    transition: border-color 0.15s;
    box-sizing: border-box !important;
    margin: 0 !important;
    opacity: 1 !important;
}

.nexsend-portal .nexsend-form__field select {
    -webkit-appearance: menulist !important;
    -moz-appearance: menulist !important;
    appearance: menulist !important;
    cursor: pointer;
    padding-right: 2rem !important;
}

.nexsend-portal .nexsend-form__field input:focus,
.nexsend-portal .nexsend-form__field select:focus,
.nexsend-portal .nexsend-form__field textarea:focus {
    outline: none !important;
    border-color: #3D338C !important;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1) !important;
}

/*
 * Create-shipment form rows are 2-col grids of `.nexsend-form__field`
 * cells. Originally this rule was unscoped, which made *every*
 * `.nexsend-form__row` a 2-col grid — including the login form, where
 * label + input then ended up side-by-side. Restrict via `:has()` so
 * only rows that actually contain a `.nexsend-form__field` child take
 * the grid; plain rows (login, register, generic) stay block-flow.
 */
.nexsend-form__row:has(> .nexsend-form__field) {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}

.nexsend-form__field--wide {
    grid-column: span 1;
}

.nexsend-form__field--narrow {
    grid-column: span 1;
}

.nexsend-form__row:has(> .nexsend-form__field--wide):has(> .nexsend-form__field--narrow) {
    grid-template-columns: 2fr 1fr;
}

.nexsend-form__actions {
    padding-top: 1rem;
    border-top: 1px solid var(--ns-gray-200);
}

.nexsend-result {
    padding: 1.5rem;
    border-radius: 0.5rem;
    margin-top: 1rem;
}

.nexsend-result--success {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
}

.nexsend-result--success h3 {
    color: #166534;
    margin: 0 0 1rem;
}

.nexsend-result--error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #991b1b;
}

.nexsend-result__actions {
    margin-top: 1rem;
    display: flex;
    gap: 0.5rem;
}

/* ─── Responsive ─────────────────────────────────────────────────────── */
@media (max-width: 768px) {
    .nexsend-form__row--half {
        grid-template-columns: 1fr;
    }

    .nexsend-package-select {
        grid-template-columns: repeat(2, 1fr);
    }

    .nexsend-form--inline {
        flex-direction: column;
        align-items: stretch;
    }

    .nexsend-order-card__content {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.25rem;
    }

    .nexsend-detail__grid,
    .nexsend-form__grid {
        grid-template-columns: 1fr;
    }

    .nexsend-detail__header {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* ─── Portal-page chrome cleanup (Phase 3) ────────────────────────────── */
/* When customer is logged in viewing /portal*, hide the marketing footer
   that bleeds in from the theme. Login/register keep the marketing footer
   so visitors still get the conversion chrome. */
body.nexsend-portal-app .footer,
body.nexsend-portal-app footer.footer { display: none; }

/* Tighten the page so the content area sits closer to the top, matching
   the dashboard density in the design. */
body.nexsend-portal-app main,
body.nexsend-portal-app .nexsend-portal {
    background: var(--ns-gray-50);
    min-height: calc(100vh - 80px);
}
body.nexsend-portal-app .nexsend-portal__content {
    padding-top: 1.5rem;
    padding-bottom: 4rem;
}

/* Stats: left-aligned label-on-top, matching design `.stat` */
body.nexsend-portal-app .nexsend-stats__card {
    text-align: left;
    padding: 1.25rem 1.25rem 1rem;
    border-radius: var(--ns-radius-lg);
    border-color: var(--ns-gray-200);
    box-shadow: var(--ns-shadow-sm);
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
    transition: border-color .15s, box-shadow .15s;
}
body.nexsend-portal-app .nexsend-stats__card:hover {
    border-color: var(--ns-primary-light);
    box-shadow: var(--ns-shadow);
}
body.nexsend-portal-app .nexsend-stats__label {
    margin-top: 0;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--ns-gray-500);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
body.nexsend-portal-app .nexsend-stats__number {
    font-family: var(--ns-font);
    font-style: italic;
    font-size: 2rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.05;
    color: var(--ns-gray-900);
}
body.nexsend-portal-app .nexsend-stats__card--highlight {
    background: var(--ns-primary);
    border-color: var(--ns-primary);
}
body.nexsend-portal-app .nexsend-stats__card--highlight .nexsend-stats__label { color: rgba(255,255,255,0.75); }
body.nexsend-portal-app .nexsend-stats__card--highlight .nexsend-stats__number { color: #fff; }

/* Italic Mulish display headings to mirror the design wordmark */
body.nexsend-portal-app .nexsend-portal__title,
body.nexsend-portal-app .nexsend-portal__content > h1,
body.nexsend-portal-app .nexsend-portal__content > h2 {
    font-family: var(--ns-font);
    font-style: italic;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--ns-gray-900);
}

/* Filter chip pill cluster — match design's pill toolbar */
body.nexsend-portal-app .nexsend-filters {
    background: var(--ns-gray-100);
    padding: 4px;
    border-radius: 999px;
    width: fit-content;
    gap: 2px;
}
body.nexsend-portal-app .nexsend-filters__item {
    border-radius: 999px;
    padding: 0.4rem 0.85rem;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--ns-gray-600);
    background: transparent;
    border: none;
}
body.nexsend-portal-app .nexsend-filters__item:hover { color: var(--ns-gray-900); }
body.nexsend-portal-app .nexsend-filters__item--active {
    background: var(--ns-primary);
    color: #fff;
    box-shadow: var(--ns-shadow-sm);
}

/* Public portal pages (login/register): drop the cards into the design's
   2-col split-screen vibe — purple gradient hero left, form right. */
body.nexsend-portal-public main { background: var(--ns-gray-50); }
body.nexsend-portal-public .nexsend-login,
body.nexsend-portal-public .nexsend-register {
    max-width: 1080px;
    margin: 2rem auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    background: #fff;
    border-radius: var(--ns-radius-xl);
    overflow: hidden;
    box-shadow: var(--ns-shadow);
}
body.nexsend-portal-public .nexsend-login::before,
body.nexsend-portal-public .nexsend-register::before {
    content: '';
    background: linear-gradient(135deg, var(--ns-primary) 0%, var(--ns-gray-900) 100%);
    min-height: 480px;
}
body.nexsend-portal-public .nexsend-login__card,
body.nexsend-portal-public .nexsend-register__card {
    box-shadow: none;
    border: none;
    margin: 0;
    padding: 3rem 2.5rem;
    max-width: none;
}

@media (max-width: 800px) {
    body.nexsend-portal-public .nexsend-login,
    body.nexsend-portal-public .nexsend-register { grid-template-columns: 1fr; }
    body.nexsend-portal-public .nexsend-login::before,
    body.nexsend-portal-public .nexsend-register::before { display: none; }
}

/*
 * Auth-shell takeover. The legacy block above ships its own 2-column
 * split-screen with a purple `::before` panel on the left. The new
 * auth-shell (`.nexsend-auth`) already provides the brand panel, so when
 * `.nexsend-login` / `.nexsend-register` render *inside* it we have to
 * neutralise the legacy grid (otherwise we get the ghost purple square
 * + form pinned far-right that the screenshot shows).
 */
body.nexsend-portal-public .nexsend-auth__panel .nexsend-login,
body.nexsend-portal-public .nexsend-auth__panel .nexsend-register {
    display: block;
    max-width: none;
    margin: 0;
    background: transparent;
    border-radius: 0;
    box-shadow: none;
    overflow: visible;
}
body.nexsend-portal-public .nexsend-auth__panel .nexsend-login::before,
body.nexsend-portal-public .nexsend-auth__panel .nexsend-register::before {
    content: none;
}

/* ─── Sidebar shell (Phase 3) ───────────────────────────────────────────
   Mirrors `docs/nexsend/design/project/styles.css:60-159`. Hides the
   theme header on portal-app pages and lays out the sidebar + main
   two-column shell. */

body.nexsend-portal-app header.header,
body.nexsend-portal-app .header,
body.nexsend-portal-app header[role="banner"] { display: none !important; }

body.nexsend-portal-app .wrapper { padding: 0; margin: 0; max-width: none; }
/* Theme's outer <main class="block"> needs full-bleed treatment so the
   shell can occupy the full viewport, otherwise it pins content to
   ~1100px even on 4K monitors. */
body.nexsend-portal-app main {
    padding: 0;
    max-width: none !important;
    width: 100%;
}
body.nexsend-portal-app main.block,
body.nexsend-portal-app .block { padding: 0; max-width: none !important; }
body.nexsend-portal-app main .nexsend-portal { padding: 0; max-width: none; }
body.nexsend-portal-app main .nexsend-portal__content { padding: 0; max-width: none; }

.nexsend-shell {
    display: grid;
    grid-template-columns: 248px 1fr;
    min-height: 100vh;
    background: var(--ns-gray-50);
}

.nexsend-shell__sidebar {
    background: #fff;
    border-right: 1px solid var(--ns-gray-200);
    padding: 18px 14px 16px;
    display: flex;
    flex-direction: column;
    position: sticky;
    top: 0;
    height: 100vh;
    z-index: 30;
}

.nexsend-shell__brand {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px 8px 18px;
    font-family: var(--ns-font);
    font-style: italic;
    font-weight: 800;
    font-size: 22px;
    letter-spacing: -0.01em;
    color: var(--ns-primary);
}
.nexsend-shell__brand-mark { display: grid; place-items: center; }
.nexsend-shell__brand-text em { font-style: italic; color: var(--ns-amber); font-weight: 800; }

.nexsend-shell__nav {
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex: 1;
}

.nexsend-shell__nav-section {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--ns-gray-500);
    padding: 14px 12px 6px;
    font-weight: 600;
}

.nexsend-shell__nav-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 12px;
    border-radius: 8px;
    text-decoration: none;
    color: var(--ns-gray-700);
    font-weight: 500;
    font-size: 14px;
    transition: background .12s, color .12s;
}
.nexsend-shell__nav-link:hover { background: var(--ns-gray-100); color: var(--ns-gray-900); }
.nexsend-shell__nav-link.is-active {
    background: var(--ns-primary-light);
    color: var(--ns-primary);
    font-weight: 600;
}

.nexsend-shell__nav-icon {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    display: inline-block;
    background: currentColor;
    -webkit-mask-position: center;
            mask-position: center;
    -webkit-mask-repeat: no-repeat;
            mask-repeat: no-repeat;
    -webkit-mask-size: contain;
            mask-size: contain;
}
.nexsend-shell__nav-icon[data-icon="dashboard"] { -webkit-mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='3' width='7' height='9'/%3E%3Crect x='14' y='3' width='7' height='5'/%3E%3Crect x='14' y='12' width='7' height='9'/%3E%3Crect x='3' y='16' width='7' height='5'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='3' width='7' height='9'/%3E%3Crect x='14' y='3' width='7' height='5'/%3E%3Crect x='14' y='12' width='7' height='9'/%3E%3Crect x='3' y='16' width='7' height='5'/%3E%3C/svg%3E"); }
.nexsend-shell__nav-icon[data-icon="truck"]     { -webkit-mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='1' y='6' width='15' height='10'/%3E%3Cpath d='M16 9h4l3 4v3h-7'/%3E%3Ccircle cx='5.5' cy='18.5' r='2.5'/%3E%3Ccircle cx='18.5' cy='18.5' r='2.5'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='1' y='6' width='15' height='10'/%3E%3Cpath d='M16 9h4l3 4v3h-7'/%3E%3Ccircle cx='5.5' cy='18.5' r='2.5'/%3E%3Ccircle cx='18.5' cy='18.5' r='2.5'/%3E%3C/svg%3E"); }
.nexsend-shell__nav-icon[data-icon="upload"],
.ns-cmdk__row-icon[data-icon="upload"] { -webkit-mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4'/%3E%3Cpolyline points='17 8 12 3 7 8'/%3E%3Cline x1='12' y1='3' x2='12' y2='15'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4'/%3E%3Cpolyline points='17 8 12 3 7 8'/%3E%3Cline x1='12' y1='3' x2='12' y2='15'/%3E%3C/svg%3E"); }
.nexsend-shell__nav-icon[data-icon="package"]   { -webkit-mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 16V8a2 2 0 0 0-1-1.7l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.7l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16Z'/%3E%3Cpath d='m3.3 7 8.7 5 8.7-5'/%3E%3Cpath d='M12 22V12'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 16V8a2 2 0 0 0-1-1.7l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.7l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16Z'/%3E%3Cpath d='m3.3 7 8.7 5 8.7-5'/%3E%3Cpath d='M12 22V12'/%3E%3C/svg%3E"); }
.nexsend-shell__nav-icon[data-icon="plus"]      { -webkit-mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cline x1='12' y1='5' x2='12' y2='19'/%3E%3Cline x1='5' y1='12' x2='19' y2='12'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cline x1='12' y1='5' x2='12' y2='19'/%3E%3Cline x1='5' y1='12' x2='19' y2='12'/%3E%3C/svg%3E"); }
.nexsend-shell__nav-icon[data-icon="receipt"]   { -webkit-mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 2v20l3-2 3 2 3-2 3 2 3-2 3 2V2l-3 2-3-2-3 2-3-2-3 2-3-2Z'/%3E%3Cpath d='M8 8h8M8 12h8M8 16h6'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 2v20l3-2 3 2 3-2 3 2 3-2 3 2V2l-3 2-3-2-3 2-3-2-3 2-3-2Z'/%3E%3Cpath d='M8 8h8M8 12h8M8 16h6'/%3E%3C/svg%3E"); }
.nexsend-shell__nav-icon[data-icon="book"]      { -webkit-mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 19.5A2.5 2.5 0 0 1 6.5 17H20'/%3E%3Cpath d='M6.5 2H20v20H6.5A2.5 2.5 0 0 1 4 19.5v-15A2.5 2.5 0 0 1 6.5 2z'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 19.5A2.5 2.5 0 0 1 6.5 17H20'/%3E%3Cpath d='M6.5 2H20v20H6.5A2.5 2.5 0 0 1 4 19.5v-15A2.5 2.5 0 0 1 6.5 2z'/%3E%3C/svg%3E"); }
.nexsend-shell__nav-icon[data-icon="settings"]  { -webkit-mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3Cpath d='M19.4 15a1.65 1.65 0 0 0 .33 1.82l.06.06a2 2 0 1 1-2.83 2.83l-.06-.06a1.65 1.65 0 0 0-1.82-.33 1.65 1.65 0 0 0-1 1.51V21a2 2 0 1 1-4 0v-.09a1.65 1.65 0 0 0-1-1.51 1.65 1.65 0 0 0-1.82.33l-.06.06a2 2 0 1 1-2.83-2.83l.06-.06a1.65 1.65 0 0 0 .33-1.82 1.65 1.65 0 0 0-1.51-1H3a2 2 0 0 1 0-4h.09a1.65 1.65 0 0 0 1.51-1 1.65 1.65 0 0 0-.33-1.82l-.06-.06a2 2 0 1 1 2.83-2.83l.06.06a1.65 1.65 0 0 0 1.82.33h0a1.65 1.65 0 0 0 1-1.51V3a2 2 0 1 1 4 0v.09a1.65 1.65 0 0 0 1 1.51h0a1.65 1.65 0 0 0 1.82-.33l.06-.06a2 2 0 1 1 2.83 2.83l-.06.06a1.65 1.65 0 0 0-.33 1.82v0a1.65 1.65 0 0 0 1.51 1H21a2 2 0 1 1 0 4h-.09a1.65 1.65 0 0 0-1.51 1z'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3Cpath d='M19.4 15c.6 1.2.4 2.6-.5 3.5l-.5.5c-.9.9-2.3 1.1-3.5.5-1.2-.6-2-1.8-2-3.1V16c0-1.3-.8-2.5-2-3.1-1.2-.6-2.6-.4-3.5.5l-.5.5c-.9.9-2.3 1.1-3.5.5C2.4 13.8 1.6 12 2.5 10.5l.5-.5c.9-.9 1.1-2.3.5-3.5C2.9 5.3 1.7 4.5 0.4 4.5'/%3E%3C/svg%3E"); }

.nexsend-shell__user {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px;
    border-top: 1px solid var(--ns-gray-200);
    margin-top: 8px;
}
.nexsend-shell__avatar {
    width: 34px;
    height: 34px;
    border-radius: 8px;
    background: var(--ns-primary);
    color: #fff;
    display: grid;
    place-items: center;
    font-weight: 700;
    font-size: 13px;
    flex-shrink: 0;
}
.nexsend-shell__user-meta {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
    min-width: 0;
    flex: 1;
}
.nexsend-shell__user-name {
    font-weight: 600;
    font-size: 13px;
    color: var(--ns-gray-900);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.nexsend-shell__user-sub { color: var(--ns-gray-500); font-size: 12px; }
.nexsend-shell__logout {
    color: var(--ns-gray-500);
    text-decoration: none;
    width: 28px;
    height: 28px;
    display: grid;
    place-items: center;
    border-radius: 6px;
}
.nexsend-shell__logout:hover { background: var(--ns-gray-100); color: var(--ns-gray-900); }

/* Specificity boost — the theme's `body.nexsend-portal-app main` rule
   is 0,1,1 and would otherwise win over a single class selector. */
body.nexsend-portal-app main.nexsend-shell__main,
.nexsend-shell__body > main.nexsend-shell__main {
    min-width: 0;
    width: 100%;
    /* Symmetric padding that keeps inner content max 1400px wide on
       large screens and falls back to 32px on narrower viewports.
       max() ensures we never go below 32px even when the grid column
       is narrower than 1400px. */
    padding: 28px max(32px, calc((100% - 1400px) / 2)) 80px;
}

/* Logo links back to the marketing site. */
.nexsend-shell__brand-link {
    display: flex;
    align-items: center;
    gap: 8px;
    color: inherit;
    text-decoration: none;
}
.nexsend-shell__brand-link:focus-visible { outline: 2px solid var(--ns-primary); outline-offset: 4px; border-radius: 6px; }

/* Sidebar count badges: neutral for open shipments, amber for pending orders. */
.nexsend-shell__nav-label { flex: 1; min-width: 0; }
.nexsend-shell__nav-badge {
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    border-radius: 999px;
    background: var(--ns-gray-100);
    color: var(--ns-gray-600);
    font-size: 11px;
    font-weight: 700;
    line-height: 20px;
    text-align: center;
    font-variant-numeric: tabular-nums;
}
.nexsend-shell__nav-link.is-active .nexsend-shell__nav-badge { background: #fff; color: var(--ns-primary); }
.nexsend-shell__nav-badge--amber,
.nexsend-shell__nav-link.is-active .nexsend-shell__nav-badge--amber { background: var(--ns-amber); color: #fff; }

/* Content column: sticky top bar above the page. */
.nexsend-shell__body {
    min-width: 0;
    display: flex;
    flex-direction: column;
}
.nexsend-shell__topbar {
    position: sticky;
    top: 0;
    z-index: 25;
    display: flex;
    align-items: center;
    gap: 12px;
    height: 56px;
    padding: 0 max(32px, calc((100% - 1400px) / 2));
    background: rgba(255, 255, 255, 0.92);
    -webkit-backdrop-filter: saturate(180%) blur(8px);
    backdrop-filter: saturate(180%) blur(8px);
    border-bottom: 1px solid var(--ns-gray-200);
}
.nexsend-shell__crumb {
    flex: 1;
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    white-space: nowrap;
    overflow: hidden;
}
.nexsend-shell__crumb a { color: var(--ns-gray-500); text-decoration: none; }
.nexsend-shell__crumb a:hover { color: var(--ns-gray-900); }
.nexsend-shell__crumb-sep { color: var(--ns-gray-300); }
.nexsend-shell__crumb-current { font-weight: 700; color: var(--ns-gray-900); overflow: hidden; text-overflow: ellipsis; }

.nexsend-shell__search {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    width: 300px;
    height: 36px;
    padding: 0 8px 0 12px;
    border: 1px solid var(--ns-gray-200);
    border-radius: 8px;
    background: var(--ns-gray-50);
    color: var(--ns-gray-500);
    font: inherit;
    font-size: 13px;
    cursor: pointer;
    transition: border-color 0.15s, background-color 0.15s;
}
.nexsend-shell__search:hover { border-color: var(--ns-gray-300); background: #fff; }
.nexsend-shell__search:focus-visible { outline: 2px solid var(--ns-primary); outline-offset: 2px; }
.nexsend-shell__search-label { flex: 1; text-align: left; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nexsend-shell__search-kbd {
    padding: 1px 6px;
    border: 1px solid var(--ns-gray-200);
    border-radius: 4px;
    background: #fff;
    font-family: var(--ns-font-mono);
    font-size: 11px;
    color: var(--ns-gray-500);
}

.nexsend-shell__menu-btn,
.nexsend-shell__drawer-close,
.nexsend-shell__bell {
    display: inline-grid;
    place-items: center;
    width: 36px;
    height: 36px;
    padding: 0;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: var(--ns-gray-600);
    cursor: pointer;
}
.nexsend-shell__menu-btn:hover,
.nexsend-shell__drawer-close:hover,
.nexsend-shell__bell:hover,
.nexsend-shell__bell[aria-expanded="true"] { background: var(--ns-gray-100); color: var(--ns-gray-900); }
.nexsend-shell__menu-btn,
.nexsend-shell__drawer-close { display: none; }

.nexsend-shell__bell-wrap { position: relative; }
.nexsend-shell__bell { position: relative; }
.nexsend-shell__bell-count {
    position: absolute;
    top: 3px;
    right: 2px;
    min-width: 16px;
    height: 16px;
    padding: 0 4px;
    border-radius: 999px;
    background: var(--ns-danger);
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    line-height: 16px;
    text-align: center;
    box-shadow: 0 0 0 2px #fff;
}
.nexsend-shell__bell-panel {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    width: 320px;
    max-width: calc(100vw - 32px);
    background: #fff;
    border: 1px solid var(--ns-gray-200);
    border-radius: var(--ns-radius);
    box-shadow: var(--ns-shadow-md);
    overflow: hidden;
    z-index: 40;
}
.nexsend-shell__bell-panel[hidden] { display: none; }
.nexsend-shell__bell-head {
    padding: 12px 14px;
    border-bottom: 1px solid var(--ns-gray-100);
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--ns-gray-500);
}
.nexsend-shell__bell-empty { margin: 0; padding: 16px 14px; font-size: 13px; color: var(--ns-gray-500); }
.nexsend-shell__bell-list { list-style: none; margin: 0; padding: 4px; max-height: 360px; overflow-y: auto; }
.nexsend-shell__bell-item {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    padding: 10px;
    border-radius: 8px;
    color: inherit;
    text-decoration: none;
}
.nexsend-shell__bell-item:hover { background: var(--ns-gray-50); }
.nexsend-shell__bell-dot { width: 8px; height: 8px; margin-top: 5px; border-radius: 50%; flex-shrink: 0; background: var(--ns-danger); }
.nexsend-shell__bell-item--warn .nexsend-shell__bell-dot { background: var(--ns-amber); }
.nexsend-shell__bell-text { display: flex; flex-direction: column; min-width: 0; line-height: 1.3; }
.nexsend-shell__bell-title { font-size: 13px; font-weight: 600; color: var(--ns-gray-900); }
.nexsend-shell__bell-sub { font-size: 12px; color: var(--ns-gray-500); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.nexsend-shell__scrim[hidden] { display: none; }

/* Phones and narrow tablets: the sidebar becomes an off-canvas drawer. */
@media (max-width: 900px) {
    .nexsend-shell { grid-template-columns: 1fr; }
    .nexsend-shell__sidebar {
        position: fixed;
        top: 0;
        bottom: 0;
        left: 0;
        width: min(300px, 86vw);
        height: auto;
        z-index: 70;
        overflow-y: auto;
        transform: translateX(-100%);
        visibility: hidden;
        transition: transform 0.22s ease, visibility 0s linear 0.22s;
        box-shadow: var(--ns-shadow-lg);
    }
    .nexsend-shell.is-drawer-open .nexsend-shell__sidebar {
        transform: translateX(0);
        visibility: visible;
        transition: transform 0.22s ease;
    }
    .nexsend-shell__brand { justify-content: space-between; }
    .nexsend-shell__drawer-close,
    .nexsend-shell__menu-btn { display: inline-grid; }
    .nexsend-shell__scrim {
        position: fixed;
        inset: 0;
        z-index: 65;
        background: rgba(26, 24, 48, 0.4);
    }
    .nexsend-shell__topbar { padding: 0 16px; gap: 8px; }
    .nexsend-shell__search { width: auto; }
}
@media (max-width: 600px) {
    body.nexsend-portal-app main.nexsend-shell__main { padding: 20px 16px 64px; }
    .nexsend-shell__search { width: 36px; padding: 0; justify-content: center; }
    .nexsend-shell__search-label,
    .nexsend-shell__search-kbd { display: none; }
    body.nexsend-portal-app .nexsend-filters { width: auto; border-radius: 16px; }
}
@media (prefers-reduced-motion: reduce) {
    .nexsend-shell__sidebar { transition: none !important; }
}

/* ─── Dashboard redesign (Phase 5a) ─────────────────────────────────────
   Mirrors `docs/nexsend/design/project/page-dashboard.jsx`. */

.nexsend-page-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 22px;
    flex-wrap: wrap;
}
.nexsend-page-header h1 {
    font-family: var(--ns-font);
    font-style: italic;
    font-size: 28px;
    font-weight: 800;
    letter-spacing: -0.02em;
    margin: 0 0 4px;
    color: var(--ns-gray-900);
}
.nexsend-page-header__sub {
    color: var(--ns-gray-500);
    font-size: 13px;
}
.nexsend-page-header__actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.nexsend-banner {
    background: linear-gradient(120deg, var(--ns-primary) 0%, var(--ns-primary-hover) 100%);
    color: #fff;
    padding: 14px 18px;
    border-radius: var(--ns-radius-lg);
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 18px;
    box-shadow: var(--ns-shadow);
}
.nexsend-banner__icon {
    background: rgba(255,255,255,0.18);
    border-radius: 8px;
    width: 36px; height: 36px;
    display: grid; place-items: center;
    flex-shrink: 0;
    font-size: 18px;
}
.nexsend-banner__body { flex: 1; line-height: 1.4; }
.nexsend-banner__body strong { font-weight: 700; }
.nexsend-banner__body p { margin: 2px 0 0; font-size: 13px; opacity: 0.9; }
.nexsend-banner__cta {
    background: #fff;
    color: var(--ns-primary);
    border: none;
    border-radius: 8px;
    padding: 8px 14px;
    font-weight: 600;
    font-size: 13px;
    text-decoration: none;
    transition: background .12s;
}
.nexsend-banner__cta:hover { background: var(--ns-primary-light); }

body.nexsend-portal-app .nexsend-stats--four {
    grid-template-columns: repeat(4, 1fr);
}
@media (max-width: 1100px) {
    body.nexsend-portal-app .nexsend-stats--four {
        grid-template-columns: repeat(2, 1fr);
    }
}

body.nexsend-portal-app .nexsend-stats__card--accent {
    background: var(--ns-primary);
    border-color: var(--ns-primary);
    color: #fff;
}
body.nexsend-portal-app .nexsend-stats__card--accent .nexsend-stats__label { color: rgba(255,255,255,0.78); }
body.nexsend-portal-app .nexsend-stats__card--accent .nexsend-stats__number { color: #fff; }
body.nexsend-portal-app .nexsend-stats__card--accent .nexsend-stats__delta { color: rgba(255,255,255,0.85); }

.nexsend-stats__delta {
    font-size: 12px;
    font-weight: 600;
    color: var(--ns-gray-500);
}
.nexsend-stats__delta--up   { color: var(--ns-success); }
.nexsend-stats__delta--down { color: var(--ns-danger); }
.nexsend-stats__delta--neutral { color: var(--ns-gray-500); }

.nexsend-grid { display: grid; gap: 16px; }
.nexsend-grid--2-1 { grid-template-columns: 2fr 1fr; }
@media (max-width: 1100px) { .nexsend-grid--2-1 { grid-template-columns: 1fr; } }

.nexsend-stack { display: flex; flex-direction: column; gap: 16px; }

.nexsend-card {
    background: #fff;
    border: 1px solid var(--ns-gray-200);
    border-radius: var(--ns-radius-lg);
    overflow: hidden;
}
.nexsend-card__header {
    padding: 14px 18px;
    border-bottom: 1px solid var(--ns-gray-200);
    display: flex;
    align-items: center;
    gap: 12px;
}
.nexsend-card__title {
    font-family: var(--ns-font);
    font-style: italic;
    font-weight: 800;
    font-size: 16px;
    flex: 1;
    margin: 0;
    letter-spacing: -0.01em;
    color: var(--ns-gray-900);
}
.nexsend-card__body { padding: 16px 18px; }
.nexsend-card__body--list { padding: 8px; }

.nexsend-table-wrap { overflow-x: auto; }
.nexsend-cell-strong { font-weight: 700; color: var(--ns-gray-900); font-size: 13px; }
.nexsend-cell-sub    { color: var(--ns-gray-500); font-size: 11px; }
.nexsend-mono        { font-family: var(--ns-font-mono); font-size: 12px; color: var(--ns-gray-700); }
.text-right          { text-align: right; }

/* Replace the badge style for page-table contexts with the design's
   pill+dot variant. */
body.nexsend-portal-app .nexsend-badge {
    display: inline-flex;
    align-items: center;
    padding: 3px 9px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.02em;
    white-space: nowrap;
    gap: 5px;
    text-transform: none;
}
body.nexsend-portal-app .nexsend-badge::before {
    content: '';
    width: 6px; height: 6px;
    border-radius: 50%;
    background: currentColor;
    opacity: 0.85;
}
body.nexsend-portal-app .nexsend-badge--package::before,
body.nexsend-portal-app .nexsend-pkg-tag::before { display: none; }

body.nexsend-portal-app .nexsend-badge--created,
body.nexsend-portal-app .nexsend-badge--label_printed { background: var(--ns-primary-light); color: var(--ns-primary); }
body.nexsend-portal-app .nexsend-badge--in_transit    { background: var(--ns-info-light); color: var(--ns-info); }
body.nexsend-portal-app .nexsend-badge--delivered     { background: var(--ns-success-light); color: var(--ns-success); }
body.nexsend-portal-app .nexsend-badge--failed,
body.nexsend-portal-app .nexsend-badge--returned      { background: var(--ns-danger-light); color: var(--ns-danger); }
body.nexsend-portal-app .nexsend-badge--warn          { background: var(--ns-warning-light); color: var(--ns-warning); }
body.nexsend-portal-app .nexsend-badge--warn::before  { display: inline-block; }

/* Package tag chip (uppercase mono on cream). */
body.nexsend-portal-app .nexsend-pkg-tag,
body.nexsend-portal-app .nexsend-badge--package {
    display: inline-grid;
    place-items: center;
    width: 30px; height: 22px;
    border-radius: 6px;
    background: var(--ns-cream);
    color: var(--ns-gray-800);
    font-weight: 700;
    font-size: 11px;
    font-family: var(--ns-font-mono);
}
body.nexsend-portal-app .nexsend-pkg-tag--bp { background: var(--ns-info-light); color: var(--ns-info); }
body.nexsend-portal-app .nexsend-pkg-tag--m  { background: var(--ns-warning-light); color: var(--ns-warning); }

/* "Te verwerken" queue list rows. */
.nexsend-queue-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 8px;
    text-decoration: none;
    color: inherit;
    transition: background .12s;
}
.nexsend-queue-item:hover { background: var(--ns-gray-100); }
.nexsend-queue-item__icon {
    width: 32px; height: 32px;
    border-radius: 8px;
    background: var(--ns-warning-light);
    color: var(--ns-warning);
    display: grid; place-items: center;
    flex-shrink: 0;
    font-size: 14px;
}
.nexsend-queue-item__avatar {
    width: 32px; height: 32px;
    border-radius: 50%;
    background: var(--ns-primary-light);
    color: var(--ns-primary);
    display: grid; place-items: center;
    flex-shrink: 0;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.02em;
}
.nexsend-queue-item__body { flex: 1; min-width: 0; }
.nexsend-queue-item__chev { color: var(--ns-gray-400); font-size: 18px; }

/* Sparkline. */
.nexsend-volume {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}
.nexsend-volume__total {
    font-family: var(--ns-font);
    font-weight: 800;
    font-size: 22px;
    letter-spacing: -0.02em;
    color: var(--ns-gray-900);
}
.nexsend-volume__total span {
    font-size: 13px;
    font-weight: 500;
    color: var(--ns-gray-500);
    margin-left: 4px;
}

.nexsend-spark {
    display: flex;
    align-items: flex-end;
    gap: 3px;
    height: 60px;
}
.nexsend-spark__bar {
    flex: 1;
    background: var(--ns-primary-light);
    border-radius: 3px 3px 0 0;
    min-height: 4px;
    transition: background .15s;
}
.nexsend-spark__bar.is-last { background: var(--ns-primary); }
.nexsend-spark__legend {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: var(--ns-gray-500);
    margin-top: 6px;
}

/* Section-level dashboard-only typography reset so the existing
   `.nexsend-portal h1` (left-aligned, italic Mulish) doesn't collide
   with the new `.nexsend-page-header h1`. */
body.nexsend-portal-app .nexsend-dashboard .nexsend-portal__content > h1 { display: none; }

/* ─── Wizard (Phase 5d) ─────────────────────────────────────────────── */

.nexsend-page-header__crumb {
    color: var(--ns-gray-500);
    font-size: 13px;
    margin-bottom: 4px;
}
.nexsend-page-header__crumb a { color: var(--ns-gray-500); text-decoration: none; }
.nexsend-page-header__crumb a:hover { color: var(--ns-gray-700); }

.nexsend-steps {
    list-style: none;
    margin: 0 0 24px;
    padding: 0;
    display: flex;
    gap: 4px;
}
.nexsend-steps__item {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
    padding: 10px 14px;
    border-radius: 10px;
    background: var(--ns-gray-100);
    font-size: 13px;
    font-weight: 600;
    color: var(--ns-gray-500);
    transition: background .15s, color .15s;
}
.nexsend-steps__item.is-active { background: var(--ns-primary-light); color: var(--ns-primary); }
.nexsend-steps__item.is-done   { color: var(--ns-success); }
.nexsend-steps__num {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: #fff;
    display: grid;
    place-items: center;
    font-size: 11px;
    border: 1px solid currentColor;
    flex-shrink: 0;
}
.nexsend-steps__item.is-done .nexsend-steps__num {
    background: var(--ns-success);
    color: #fff;
    border-color: var(--ns-success);
}

.nexsend-wizard__step h3 {
    font-family: var(--ns-font);
    font-style: italic;
    font-weight: 800;
    font-size: 16px;
    margin: 0 0 14px;
    letter-spacing: -0.01em;
    color: var(--ns-gray-900);
}
.nexsend-wizard__step + .nexsend-wizard__step { margin-top: 20px; }
.nexsend-divider {
    border: none;
    border-top: 1px solid var(--ns-gray-200);
    margin: 20px 0;
}
.nexsend-req { color: var(--ns-danger); }

.nexsend-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 12px;
}
.nexsend-field label {
    font-size: 12px;
    font-weight: 600;
    color: var(--ns-gray-700);
    display: flex;
    gap: 4px;
    align-items: center;
}
.nexsend-field input,
.nexsend-field select,
.nexsend-field textarea {
    border: 1px solid var(--ns-gray-200);
    border-radius: 8px;
    padding: 9px 12px;
    font-size: 13px;
    background: #fff;
    outline: none;
    transition: border-color .12s, box-shadow .12s;
    color: var(--ns-gray-900);
    font-family: var(--ns-font);
}
.nexsend-field input:focus,
.nexsend-field select:focus,
.nexsend-field textarea:focus {
    border-color: var(--ns-primary);
    box-shadow: 0 0 0 3px var(--ns-primary-light);
}
.nexsend-field input.has-error { border-color: var(--ns-danger); }
.nexsend-field input:disabled {
    background: var(--ns-gray-100);
    color: var(--ns-gray-500);
    cursor: not-allowed;
}

.nexsend-field-row {
    display: grid;
    gap: 12px;
    grid-template-columns: 1fr 1fr;
    margin-bottom: 12px;
}
.nexsend-field-row .nexsend-field { margin-bottom: 0; }
.nexsend-field-row--street { grid-template-columns: 2fr 80px 80px; }
.nexsend-field-row--3 { grid-template-columns: 1fr 1.2fr 1fr; }

.nexsend-pkg-options {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.nexsend-pkg-option {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 14px;
    border: 2px solid var(--ns-gray-200);
    border-radius: 12px;
    cursor: pointer;
    background: #fff;
    transition: border-color .12s, background .12s;
}
.nexsend-pkg-option:hover { border-color: var(--ns-primary-light); }
.nexsend-pkg-option:has(input:checked) {
    border-color: var(--ns-primary);
    background: var(--ns-primary-light);
}
.nexsend-pkg-option input { margin: 0; accent-color: var(--ns-primary); }
.nexsend-pkg-option__body {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 0;
}
.nexsend-pkg-option__price {
    font-family: var(--ns-font-mono);
    font-weight: 700;
    font-size: 14px;
    color: var(--ns-gray-900);
}

.nexsend-toggle-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    border: 1px solid var(--ns-gray-200);
    border-radius: 10px;
    margin-bottom: 8px;
    background: #fff;
    cursor: pointer;
}
.nexsend-toggle-row__body {
    display: flex;
    flex-direction: column;
    flex: 1;
}
.nexsend-toggle-row__extra {
    color: var(--ns-gray-500);
    font-size: 13px;
}

.nexsend-summary-block {
    background: var(--ns-gray-100);
    padding: 14px 16px;
    border-radius: 10px;
    margin-bottom: 12px;
}
.nexsend-summary-block__label {
    font-size: 11px;
    font-weight: 600;
    color: var(--ns-gray-500);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 4px;
}
.nexsend-summary-banner {
    background: var(--ns-warning-light);
    color: var(--ns-warning);
    padding: 12px 14px;
    border-radius: 10px;
    font-size: 13px;
    line-height: 1.4;
    margin-top: 4px;
}
.nexsend-summary-banner strong { color: var(--ns-gray-900); }

.nexsend-card__footer {
    padding: 12px 18px;
    border-top: 1px solid var(--ns-gray-200);
    display: flex;
    align-items: center;
    gap: 8px;
    background: #fff;
    border-radius: 0 0 var(--ns-radius-lg) var(--ns-radius-lg);
}

/* The HTML5 `hidden` attribute is overridden by `display: inline-flex`
   on `.nexsend-btn` — restore the spec'd behaviour with !important. */
[hidden] { display: none !important; }

.nexsend-summary-card { position: sticky; top: 20px; align-self: start; }

.nexsend-dl {
    display: grid;
    grid-template-columns: 130px 1fr;
    gap: 8px 12px;
    font-size: 13px;
    margin: 0;
}
.nexsend-dl dt { color: var(--ns-gray-500); font-weight: 500; }
.nexsend-dl dd { margin: 0; color: var(--ns-gray-900); font-weight: 500; text-align: right; }
.nexsend-num  { font-family: var(--ns-font-mono); font-variant-numeric: tabular-nums; }

.nexsend-summary-total {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    padding-top: 4px;
}

/* ─── Slide-over (Phase 5b) ─────────────────────────────────────────── */

.ns-slideover {
    position: fixed;
    inset: 0;
    z-index: 100;
    pointer-events: none;
}
.ns-slideover[hidden] { display: none \!important; }
.ns-slideover .ns-slideover__scrim {
    position: absolute;
    inset: 0;
    background: rgba(26, 24, 48, 0.4);
    opacity: 0;
    transition: opacity 0.2s ease;
    pointer-events: auto;
}
.ns-slideover.is-open .ns-slideover__scrim { opacity: 1; }

.ns-slideover__panel {
    position: absolute;
    top: 0;
    right: 0;
    height: 100vh;
    width: 540px;
    max-width: 90vw;
    background: #fff;
    box-shadow: var(--ns-shadow-lg);
    display: flex;
    flex-direction: column;
    transform: translateX(40px);
    opacity: 0;
    transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.25s ease;
    pointer-events: auto;
    overflow: hidden;
}
.ns-slideover.is-open .ns-slideover__panel {
    transform: translateX(0);
    opacity: 1;
}

.ns-slideover__header {
    padding: 18px 24px;
    border-bottom: 1px solid var(--ns-gray-200);
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}
.ns-slideover__title {
    font-size: 16px;
    font-weight: 700;
    margin: 0;
    flex: 1;
    color: var(--ns-gray-900);
}
.ns-slideover__close {
    border: none;
    background: transparent;
    font-size: 18px;
    color: var(--ns-gray-500);
    cursor: pointer;
    width: 32px;
    height: 32px;
    border-radius: 6px;
    display: grid;
    place-items: center;
}
.ns-slideover__close:hover {
    background: var(--ns-gray-100);
    color: var(--ns-gray-900);
}

.ns-slideover__body {
    flex: 1;
    padding: 20px 24px;
    overflow-y: auto;
}
.ns-slideover__section + .ns-slideover__section {
    margin-top: 22px;
}
.ns-slideover__section-title {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--ns-gray-500);
    margin: 0 0 12px;
}
.ns-slideover__chip-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
}
.ns-slideover__address {
    background: var(--ns-gray-100);
    padding: 14px;
    border-radius: 10px;
}
.ns-slideover__address > div + div { margin-top: 2px; font-size: 13px; color: var(--ns-gray-700); }
.ns-slideover__address > div:first-child { margin-bottom: 4px; }

.ns-slideover__footer {
    padding: 14px 24px;
    border-top: 1px solid var(--ns-gray-200);
    background: var(--ns-gray-100);
    display: flex;
    gap: 8px;
    justify-content: flex-end;
    flex-shrink: 0;
}

/* Timeline */
.ns-timeline {
    list-style: none;
    margin: 0;
    padding: 0 0 0 28px;
    position: relative;
}
.ns-timeline::before {
    content: '';
    position: absolute;
    left: 9px;
    top: 6px;
    bottom: 6px;
    width: 2px;
    background: var(--ns-gray-200);
}
.ns-timeline__item {
    position: relative;
    padding: 8px 0 14px;
}
.ns-timeline__item::before {
    content: '';
    position: absolute;
    left: -23px;
    top: 12px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #fff;
    border: 2px solid var(--ns-gray-200);
}
.ns-timeline__item.is-done::before {
    background: var(--ns-success);
    border-color: var(--ns-success);
}
.ns-timeline__item.is-active::before {
    background: var(--ns-primary);
    border-color: var(--ns-primary);
    box-shadow: 0 0 0 4px var(--ns-primary-light);
}
.ns-timeline__title {
    font-weight: 600;
    font-size: 13px;
    color: var(--ns-gray-900);
}
.ns-timeline__item.is-pending .ns-timeline__title { color: var(--ns-gray-500); }
.ns-timeline__meta {
    font-size: 12px;
    color: var(--ns-gray-500);
    margin-top: 2px;
}

/* Make table rows visibly clickable */
body.nexsend-portal-app .nexsend-table tbody tr.nexsend-table__row {
    cursor: pointer;
    transition: background 0.1s;
}
body.nexsend-portal-app .nexsend-table tbody tr.nexsend-table__row:hover {
    background: var(--ns-gray-100);
}

@media (max-width: 600px) {
    .ns-slideover__panel { width: 100vw; }
}

/* --------------------------------------------------------------------- */
/* Phase 5e — Billing tier list + invoice document                        */
/* --------------------------------------------------------------------- */

body.nexsend-portal-app .nexsend-tier-list {
    list-style: none;
    margin: 12px 0 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
body.nexsend-portal-app .nexsend-tier-list__row {
    display: grid;
    grid-template-columns: 1fr auto auto;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    border: 1px solid var(--ns-gray-200);
    border-radius: 12px;
    background: #fff;
}
body.nexsend-portal-app .nexsend-tier-list__row.is-current {
    border-color: var(--ns-primary);
    background: var(--ns-primary-light);
}
body.nexsend-portal-app .nexsend-tier-list__name {
    font-weight: 600;
    font-size: 14px;
    color: var(--ns-gray-900);
}
body.nexsend-portal-app .nexsend-tier-list__price {
    font-variant-numeric: tabular-nums;
    font-size: 13px;
    color: var(--ns-gray-700);
}

body.nexsend-portal-app .nexsend-invoice {
    background: #fff;
    border: 1px solid var(--ns-gray-200);
    border-radius: 20px;
    padding: 40px 44px;
    box-shadow: 0 1px 2px rgba(31, 36, 50, 0.04);
    max-width: 920px;
    margin: 0 auto;
}
body.nexsend-portal-app .nexsend-invoice__head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 24px;
    border-bottom: 1px solid var(--ns-gray-200);
    padding-bottom: 24px;
    margin-bottom: 24px;
}
body.nexsend-portal-app .nexsend-invoice__brand {
    font-family: var(--ns-font-display, "Mulish"), sans-serif;
    font-style: italic;
    font-weight: 800;
    font-size: 28px;
    color: var(--ns-primary);
    letter-spacing: -0.5px;
}
body.nexsend-portal-app .nexsend-invoice__brand-sub {
    font-size: 13px;
    color: var(--ns-gray-500);
    margin-top: 2px;
}
body.nexsend-portal-app .nexsend-invoice__meta {
    text-align: right;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 8px;
}
body.nexsend-portal-app .nexsend-invoice__nr {
    font-family: var(--ns-font-mono, "JetBrains Mono"), monospace;
    font-weight: 600;
    font-size: 16px;
    color: var(--ns-gray-900);
}
body.nexsend-portal-app .nexsend-invoice__parties {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    padding-bottom: 28px;
    border-bottom: 1px solid var(--ns-gray-200);
    font-size: 13px;
    line-height: 1.55;
}
body.nexsend-portal-app .nexsend-invoice__label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: var(--ns-gray-500);
    font-weight: 600;
    margin-bottom: 6px;
}
body.nexsend-portal-app .nexsend-invoice__lines {
    width: 100%;
    margin: 24px 0;
    border-collapse: collapse;
}
body.nexsend-portal-app .nexsend-invoice__lines th,
body.nexsend-portal-app .nexsend-invoice__lines td {
    padding: 12px 8px;
    text-align: left;
    border-bottom: 1px solid var(--ns-gray-100);
    font-size: 13px;
}
body.nexsend-portal-app .nexsend-invoice__lines th {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: var(--ns-gray-500);
    font-weight: 600;
    border-bottom: 1px solid var(--ns-gray-200);
}
body.nexsend-portal-app .nexsend-invoice__lines .text-right { text-align: right; }
body.nexsend-portal-app .nexsend-invoice__totals {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 8px 32px;
    margin: 0 0 0 auto;
    width: fit-content;
    min-width: 280px;
    padding: 16px 0 0;
    border-top: 2px solid var(--ns-gray-900);
    font-size: 14px;
}
body.nexsend-portal-app .nexsend-invoice__totals dt { margin: 0; color: var(--ns-gray-700); }
body.nexsend-portal-app .nexsend-invoice__totals dd { margin: 0; text-align: right; }
body.nexsend-portal-app .nexsend-invoice__foot {
    margin-top: 28px;
    padding-top: 20px;
    border-top: 1px solid var(--ns-gray-100);
}

@media print {
    body.nexsend-portal-app .nexsend-no-print,
    body.nexsend-portal-app .nexsend-shell__sidebar,
    body.nexsend-portal-app .nexsend-shell__topbar,
    body.nexsend-portal-app .nexsend-page-header { display: none !important; }
    body.nexsend-portal-app .nexsend-shell__main { padding: 0 !important; }
    body.nexsend-portal-app .nexsend-invoice {
        border: none;
        box-shadow: none;
        padding: 0;
        max-width: 100%;
    }
}

/* --------------------------------------------------------------------- */
/* Phase 5f — Address book                                                */
/* --------------------------------------------------------------------- */

body.nexsend-portal-app .nexsend-form-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px 16px;
}
body.nexsend-portal-app .nexsend-form-grid label {
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: 13px;
    color: var(--ns-gray-700);
}
body.nexsend-portal-app .nexsend-form-grid label > span {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--ns-gray-500);
    font-weight: 600;
}
body.nexsend-portal-app .nexsend-form-grid input[type="text"],
body.nexsend-portal-app .nexsend-form-grid input[type="email"],
body.nexsend-portal-app .nexsend-form-grid input[type="tel"],
body.nexsend-portal-app .nexsend-form-grid select {
    width: 100%;
    padding: 9px 12px;
    border: 1px solid var(--ns-gray-200);
    border-radius: 10px;
    font-size: 13px;
    background: #fff;
    transition: border-color 0.1s, box-shadow 0.1s;
}
body.nexsend-portal-app .nexsend-form-grid input:focus,
body.nexsend-portal-app .nexsend-form-grid select:focus {
    outline: none;
    border-color: var(--ns-primary);
    box-shadow: 0 0 0 3px var(--ns-primary-light);
}
body.nexsend-portal-app .nexsend-form-grid__col-2 { grid-column: span 2; }
body.nexsend-portal-app .nexsend-form-grid__inline {
    flex-direction: row;
    align-items: center;
    gap: 8px;
}
body.nexsend-portal-app .nexsend-form-grid__inline > span {
    text-transform: none;
    letter-spacing: 0;
    color: var(--ns-gray-700);
    font-weight: 400;
    font-size: 13px;
}
body.nexsend-portal-app .ns-slideover__footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 16px 24px;
    border-top: 1px solid var(--ns-gray-200);
}
body.nexsend-portal-app .ns-slideover__error {
    margin-top: 12px;
    padding: 10px 12px;
    border-radius: 8px;
    background: #fef2f2;
    color: #b91c1c;
    font-size: 13px;
}
body.nexsend-portal-app .nexsend-banner--info {
    background: var(--ns-primary-light);
    color: var(--ns-primary);
    border: 1px solid var(--ns-primary);
    border-radius: 12px;
    padding: 10px 14px;
    margin-bottom: 16px;
    font-size: 13px;
    font-weight: 500;
}

/* --------------------------------------------------------------------- */
/* Phase 4 — Command palette (⌘K)                                         */
/* --------------------------------------------------------------------- */

.ns-cmdk {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding-top: 14vh;
    pointer-events: none;
}
.ns-cmdk[hidden] { display: none !important; }
.ns-cmdk__scrim {
    position: absolute;
    inset: 0;
    background: rgba(26, 24, 48, 0.5);
    backdrop-filter: blur(2px);
    opacity: 0;
    transition: opacity 0.18s ease;
    pointer-events: auto;
}
.ns-cmdk.is-open .ns-cmdk__scrim { opacity: 1; }
.ns-cmdk__panel {
    position: relative;
    width: 100%;
    max-width: 600px;
    margin: 0 16px;
    background: #fff;
    border: 1px solid var(--ns-gray-200);
    border-radius: 14px;
    box-shadow: 0 24px 60px rgba(31, 36, 50, 0.25);
    overflow: hidden;
    transform: translateY(-8px) scale(0.98);
    opacity: 0;
    transition: transform 0.18s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.18s ease;
    pointer-events: auto;
}
.ns-cmdk.is-open .ns-cmdk__panel {
    transform: translateY(0) scale(1);
    opacity: 1;
}
.ns-cmdk__header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 16px;
    border-bottom: 1px solid var(--ns-gray-100);
}
.ns-cmdk__icon {
    color: var(--ns-gray-500);
    display: inline-flex;
}
.ns-cmdk__input {
    flex: 1;
    border: none;
    outline: none;
    background: transparent;
    font-size: 15px;
    color: var(--ns-gray-900);
    font-family: inherit;
}
.ns-cmdk__input::placeholder { color: var(--ns-gray-500); }
.ns-cmdk__esc,
.ns-cmdk__footer kbd,
.ns-cmdk__row-shortcut {
    font-family: var(--ns-font-mono, monospace);
    font-size: 11px;
    background: var(--ns-gray-100);
    color: var(--ns-gray-700);
    border: 1px solid var(--ns-gray-200);
    border-radius: 4px;
    padding: 1px 6px;
    line-height: 1.4;
}
.ns-cmdk__results {
    max-height: 360px;
    overflow-y: auto;
    padding: 6px;
}
.ns-cmdk__group-label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: var(--ns-gray-500);
    font-weight: 600;
    padding: 10px 10px 4px;
}
.ns-cmdk__row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 10px;
    border-radius: 8px;
    text-decoration: none;
    color: var(--ns-gray-900);
    font-size: 14px;
    cursor: pointer;
}
.ns-cmdk__row.is-active {
    background: var(--ns-primary-light);
    color: var(--ns-primary);
}
.ns-cmdk__row-icon {
    width: 18px;
    height: 18px;
    background: currentColor;
    -webkit-mask-size: 18px 18px;
    mask-size: 18px 18px;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-position: center;
    mask-position: center;
    flex-shrink: 0;
    opacity: 0.75;
}
.ns-cmdk__row.is-active .ns-cmdk__row-icon { opacity: 1; }
/* Re-use the same data-icon mask URLs as the sidebar nav. */
.ns-cmdk__row-icon[data-icon="dashboard"] { -webkit-mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='3' width='7' height='9'/%3E%3Crect x='14' y='3' width='7' height='5'/%3E%3Crect x='14' y='12' width='7' height='9'/%3E%3Crect x='3' y='16' width='7' height='5'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='3' width='7' height='9'/%3E%3Crect x='14' y='3' width='7' height='5'/%3E%3Crect x='14' y='12' width='7' height='9'/%3E%3Crect x='3' y='16' width='7' height='5'/%3E%3C/svg%3E"); }
.ns-cmdk__row-icon[data-icon="truck"]     { -webkit-mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='1' y='6' width='15' height='10'/%3E%3Cpath d='M16 9h4l3 4v3h-7'/%3E%3Ccircle cx='5.5' cy='18.5' r='2.5'/%3E%3Ccircle cx='18.5' cy='18.5' r='2.5'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='1' y='6' width='15' height='10'/%3E%3Cpath d='M16 9h4l3 4v3h-7'/%3E%3Ccircle cx='5.5' cy='18.5' r='2.5'/%3E%3Ccircle cx='18.5' cy='18.5' r='2.5'/%3E%3C/svg%3E"); }
.ns-cmdk__row-icon[data-icon="package"]   { -webkit-mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 16V8a2 2 0 0 0-1-1.7l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.7l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16Z'/%3E%3Cpath d='m3.3 7 8.7 5 8.7-5'/%3E%3Cpath d='M12 22V12'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 16V8a2 2 0 0 0-1-1.7l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.7l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16Z'/%3E%3Cpath d='m3.3 7 8.7 5 8.7-5'/%3E%3Cpath d='M12 22V12'/%3E%3C/svg%3E"); }
.ns-cmdk__row-icon[data-icon="plus"]      { -webkit-mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cline x1='12' y1='5' x2='12' y2='19'/%3E%3Cline x1='5' y1='12' x2='19' y2='12'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cline x1='12' y1='5' x2='12' y2='19'/%3E%3Cline x1='5' y1='12' x2='19' y2='12'/%3E%3C/svg%3E"); }
.ns-cmdk__row-icon[data-icon="receipt"]   { -webkit-mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 2v20l3-2 3 2 3-2 3 2 3-2 3 2V2l-3 2-3-2-3 2-3-2-3 2-3-2Z'/%3E%3Cpath d='M8 8h8M8 12h8M8 16h6'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 2v20l3-2 3 2 3-2 3 2 3-2 3 2V2l-3 2-3-2-3 2-3-2-3 2-3-2Z'/%3E%3Cpath d='M8 8h8M8 12h8M8 16h6'/%3E%3C/svg%3E"); }
.ns-cmdk__row-icon[data-icon="settings"]  { -webkit-mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3Cpath d='M19.4 15a1.65 1.65 0 0 0 .33 1.82l.06.06a2 2 0 1 1-2.83 2.83l-.06-.06a1.65 1.65 0 0 0-1.82-.33 1.65 1.65 0 0 0-1 1.51V21a2 2 0 1 1-4 0v-.09a1.65 1.65 0 0 0-1-1.51 1.65 1.65 0 0 0-1.82.33l-.06.06a2 2 0 1 1-2.83-2.83l.06-.06a1.65 1.65 0 0 0 .33-1.82 1.65 1.65 0 0 0-1.51-1H3a2 2 0 0 1 0-4h.09a1.65 1.65 0 0 0 1.51-1 1.65 1.65 0 0 0-.33-1.82l-.06-.06a2 2 0 1 1 2.83-2.83l.06.06a1.65 1.65 0 0 0 1.82.33h0a1.65 1.65 0 0 0 1-1.51V3a2 2 0 1 1 4 0v.09a1.65 1.65 0 0 0 1 1.51h0a1.65 1.65 0 0 0 1.82-.33l.06-.06a2 2 0 1 1 2.83 2.83l-.06.06a1.65 1.65 0 0 0-.33 1.82v0a1.65 1.65 0 0 0 1.51 1H21a2 2 0 1 1 0 4h-.09a1.65 1.65 0 0 0-1.51 1z'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3Cpath d='M19.4 15c.6 1.2.4 2.6-.5 3.5l-.5.5c-.9.9-2.3 1.1-3.5.5-1.2-.6-2-1.8-2-3.1V16c0-1.3-.8-2.5-2-3.1-1.2-.6-2.6-.4-3.5.5l-.5.5c-.9.9-2.3 1.1-3.5.5C2.4 13.8 1.6 12 2.5 10.5l.5-.5c.9-.9 1.1-2.3.5-3.5C2.9 5.3 1.7 4.5 0.4 4.5'/%3E%3C/svg%3E"); }
.ns-cmdk__row-icon[data-icon="book"]      { -webkit-mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 19.5A2.5 2.5 0 0 1 6.5 17H20'/%3E%3Cpath d='M6.5 2H20v20H6.5A2.5 2.5 0 0 1 4 19.5v-15A2.5 2.5 0 0 1 6.5 2z'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 19.5A2.5 2.5 0 0 1 6.5 17H20'/%3E%3Cpath d='M6.5 2H20v20H6.5A2.5 2.5 0 0 1 4 19.5v-15A2.5 2.5 0 0 1 6.5 2z'/%3E%3C/svg%3E"); }
.ns-cmdk__row-label { flex: 1; }
.ns-cmdk__empty {
    padding: 32px 16px;
    text-align: center;
    color: var(--ns-gray-500);
    font-size: 13px;
}
.ns-cmdk__footer {
    display: flex;
    gap: 16px;
    padding: 10px 16px;
    border-top: 1px solid var(--ns-gray-100);
    background: var(--ns-gray-100);
    font-size: 11px;
    color: var(--ns-gray-700);
}
.ns-cmdk__footer kbd {
    margin-right: 2px;
    background: #fff;
}

/* --------------------------------------------------------------------- */
/* Phase 5g — Settings landing                                            */
/* --------------------------------------------------------------------- */

body.nexsend-portal-app .nexsend-settings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 14px;
    margin-top: 4px;
}
body.nexsend-portal-app .nexsend-settings-card {
    display: grid;
    grid-template-columns: 38px 1fr;
    grid-template-rows: auto auto;
    gap: 4px 14px;
    align-items: start;
    padding: 16px 18px;
    border: 1px solid var(--ns-gray-200);
    border-radius: 14px;
    background: #fff;
    text-decoration: none;
    color: var(--ns-gray-900);
    transition: border-color 0.1s, box-shadow 0.1s, transform 0.1s;
}
body.nexsend-portal-app .nexsend-settings-card:hover {
    border-color: var(--ns-primary);
    box-shadow: 0 4px 18px rgba(61, 51, 140, 0.08);
}
body.nexsend-portal-app .nexsend-settings-card.is-soon {
    opacity: 0.85;
}
body.nexsend-portal-app .nexsend-settings-card__icon {
    grid-row: 1 / span 2;
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: var(--ns-primary-light);
    color: var(--ns-primary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    position: relative;
}
body.nexsend-portal-app .nexsend-settings-card__icon::before {
    content: "";
    width: 20px;
    height: 20px;
    background: currentColor;
    -webkit-mask-size: 20px 20px;
    mask-size: 20px 20px;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-position: center;
    mask-position: center;
}
body.nexsend-portal-app .nexsend-settings-card__icon[data-icon="building"]::before { -webkit-mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='4' y='2' width='16' height='20' rx='1'/%3E%3Cpath d='M9 22v-4h6v4'/%3E%3Cpath d='M8 6h.01M16 6h.01M12 6h.01M12 10h.01M12 14h.01M16 10h.01M16 14h.01M8 10h.01M8 14h.01'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='4' y='2' width='16' height='20' rx='1'/%3E%3Cpath d='M9 22v-4h6v4'/%3E%3Cpath d='M8 6h.01M16 6h.01M12 6h.01M12 10h.01M12 14h.01M16 10h.01M16 14h.01M8 10h.01M8 14h.01'/%3E%3C/svg%3E"); }
body.nexsend-portal-app .nexsend-settings-card__icon[data-icon="send"]::before     { -webkit-mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cline x1='22' y1='2' x2='11' y2='13'/%3E%3Cpolygon points='22 2 15 22 11 13 2 9 22 2'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cline x1='22' y1='2' x2='11' y2='13'/%3E%3Cpolygon points='22 2 15 22 11 13 2 9 22 2'/%3E%3C/svg%3E"); }
body.nexsend-portal-app .nexsend-settings-card__icon[data-icon="plug"]::before     { -webkit-mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 2v6'/%3E%3Cpath d='M15 2v6'/%3E%3Cpath d='M6 8h12v4a6 6 0 0 1-12 0z'/%3E%3Cpath d='M12 18v4'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 2v6'/%3E%3Cpath d='M15 2v6'/%3E%3Cpath d='M6 8h12v4a6 6 0 0 1-12 0z'/%3E%3Cpath d='M12 18v4'/%3E%3C/svg%3E"); }
body.nexsend-portal-app .nexsend-settings-card__icon[data-icon="book"]::before     { -webkit-mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 19.5A2.5 2.5 0 0 1 6.5 17H20'/%3E%3Cpath d='M6.5 2H20v20H6.5A2.5 2.5 0 0 1 4 19.5v-15A2.5 2.5 0 0 1 6.5 2z'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 19.5A2.5 2.5 0 0 1 6.5 17H20'/%3E%3Cpath d='M6.5 2H20v20H6.5A2.5 2.5 0 0 1 4 19.5v-15A2.5 2.5 0 0 1 6.5 2z'/%3E%3C/svg%3E"); }
body.nexsend-portal-app .nexsend-settings-card__icon[data-icon="receipt"]::before  { -webkit-mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 2v20l3-2 3 2 3-2 3 2 3-2 3 2V2l-3 2-3-2-3 2-3-2-3 2-3-2Z'/%3E%3Cpath d='M8 8h8M8 12h8M8 16h6'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 2v20l3-2 3 2 3-2 3 2 3-2 3 2V2l-3 2-3-2-3 2-3-2-3 2-3-2Z'/%3E%3Cpath d='M8 8h8M8 12h8M8 16h6'/%3E%3C/svg%3E"); }
body.nexsend-portal-app .nexsend-settings-card__icon[data-icon="bell"]::before     { -webkit-mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M18 8a6 6 0 0 0-12 0c0 7-3 9-3 9h18s-3-2-3-9'/%3E%3Cpath d='M13.73 21a2 2 0 0 1-3.46 0'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M18 8a6 6 0 0 0-12 0c0 7-3 9-3 9h18s-3-2-3-9'/%3E%3Cpath d='M13.73 21a2 2 0 0 1-3.46 0'/%3E%3C/svg%3E"); }
body.nexsend-portal-app .nexsend-settings-card__icon[data-icon="lock"]::before     { -webkit-mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='11' width='18' height='11' rx='2' ry='2'/%3E%3Cpath d='M7 11V7a5 5 0 0 1 10 0v4'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='11' width='18' height='11' rx='2' ry='2'/%3E%3Cpath d='M7 11V7a5 5 0 0 1 10 0v4'/%3E%3C/svg%3E"); }
body.nexsend-portal-app .nexsend-settings-card__icon[data-icon="help"]::before     { -webkit-mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpath d='M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3'/%3E%3Cline x1='12' y1='17' x2='12.01' y2='17'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpath d='M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3'/%3E%3Cline x1='12' y1='17' x2='12.01' y2='17'/%3E%3C/svg%3E"); }
body.nexsend-portal-app .nexsend-settings-card__title {
    font-weight: 600;
    font-size: 14px;
    color: var(--ns-gray-900);
    display: flex;
    align-items: center;
    gap: 8px;
}
body.nexsend-portal-app .nexsend-settings-card__desc {
    font-size: 13px;
    color: var(--ns-gray-500);
    line-height: 1.45;
    margin-top: 2px;
}
body.nexsend-portal-app .nexsend-settings-card__cta {
    grid-column: 2;
    margin-top: 8px;
    font-size: 12px;
    font-weight: 600;
    color: var(--ns-primary);
}

body.nexsend-portal-app .nexsend-deflist {
    display: grid;
    grid-template-columns: 140px 1fr;
    gap: 6px 16px;
    margin: 0;
    font-size: 13px;
}
body.nexsend-portal-app .nexsend-deflist dt {
    color: var(--ns-gray-500);
    font-weight: 500;
}
body.nexsend-portal-app .nexsend-deflist dd {
    margin: 0;
    color: var(--ns-gray-900);
    font-weight: 500;
}

/* --------------------------------------------------------------------- */
/* Phase 3 — Auth shell (login + register)                                */
/* --------------------------------------------------------------------- */

.nexsend-auth {
    display: grid;
    grid-template-columns: minmax(320px, 1fr) minmax(420px, 1fr);
    min-height: 100vh;
    background: #fff;
}
.nexsend-auth__brand {
    background: linear-gradient(160deg, var(--ns-primary, #3D338C) 0%, #1F1965 100%);
    color: #fff;
    padding: 56px 48px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
}
.nexsend-auth__brand::after {
    content: "";
    position: absolute;
    right: -120px;
    bottom: -120px;
    width: 380px;
    height: 380px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(237, 166, 43, 0.18) 0%, rgba(237, 166, 43, 0) 70%);
}
.nexsend-auth__brand-logo {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: #fff;
    font-family: "Mulish", sans-serif;
    font-style: italic;
    font-weight: 800;
    font-size: 28px;
    letter-spacing: -0.5px;
    position: relative;
    z-index: 2;
}
.nexsend-auth__brand-text { color: #fff; }
.nexsend-auth__brand-text em {
    color: var(--ns-amber, #EDA62B);
    font-style: italic;
}
.nexsend-auth__brand-copy {
    position: relative;
    z-index: 2;
    max-width: 460px;
}
.nexsend-auth__brand-copy h2 {
    font-family: "Mulish", sans-serif;
    font-weight: 700;
    font-size: 36px;
    line-height: 1.15;
    color: #fff;
    margin: 0 0 18px;
}
.nexsend-auth__brand-copy p {
    font-size: 15px;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.78);
    margin: 0 0 24px;
}
.nexsend-auth__brand-bullets {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.nexsend-auth__brand-bullets li {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.92);
    padding-left: 28px;
    position: relative;
}
.nexsend-auth__brand-bullets li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 4px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--ns-amber, #EDA62B);
    -webkit-mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E");
    -webkit-mask-size: 12px 12px;
    mask-size: 12px 12px;
    -webkit-mask-position: center;
    mask-position: center;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    background-color: var(--ns-amber, #EDA62B);
    background-image: none;
    box-shadow: inset 0 0 0 99px var(--ns-amber, #EDA62B);
}
.nexsend-auth__brand-foot {
    position: relative;
    z-index: 2;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.6);
    letter-spacing: 0.4px;
}
.nexsend-auth__panel {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 48px 32px;
    width: 100%;
}
.nexsend-auth__panel .nexsend-login,
.nexsend-auth__panel .nexsend-register {
    width: 100%;
    max-width: 520px;
}
.nexsend-auth__panel .nexsend-login__card,
.nexsend-auth__panel .nexsend-register__card {
    background: #fff;
    border: 1px solid var(--ns-gray-200);
    border-radius: 18px;
    padding: 44px 44px 36px;
    box-shadow: 0 12px 36px rgba(31, 36, 50, 0.06);
}
.nexsend-auth__panel h2 {
    font-family: "Mulish", sans-serif;
    font-weight: 700;
    font-size: 28px;
    color: var(--ns-gray-900);
    margin: 0 0 4px;
}
.nexsend-auth__panel .nexsend-login input[type="email"],
.nexsend-auth__panel .nexsend-login input[type="password"],
.nexsend-auth__panel .nexsend-login input[type="text"],
.nexsend-auth__panel .nexsend-register input[type="email"],
.nexsend-auth__panel .nexsend-register input[type="password"],
.nexsend-auth__panel .nexsend-register input[type="text"] {
    padding: 0.85rem 1rem !important;
    font-size: 1rem !important;
    border-radius: 10px !important;
}
.nexsend-auth__panel .nexsend-login label,
.nexsend-auth__panel .nexsend-register label {
    font-size: 0.95rem;
}
.nexsend-auth__sub {
    color: var(--ns-gray-500);
    font-size: 14px;
    margin: 0 0 22px;
}

@media (max-width: 920px) {
    .nexsend-auth { grid-template-columns: 1fr; }
    .nexsend-auth__brand {
        padding: 32px 28px;
        min-height: auto;
    }
    .nexsend-auth__brand-copy { max-width: 100%; }
    .nexsend-auth__brand-copy h2 { font-size: 24px; }
    .nexsend-auth__brand-bullets { display: none; }
    .nexsend-auth__brand-foot { display: none; }
    .nexsend-auth__panel { padding: 32px 16px; }
}

/* --------------------------------------------------------------------- */
/* Tier picker (registration form Step 1)                                 */
/* --------------------------------------------------------------------- */

.nexsend-tier-picker__hint {
    color: var(--ns-gray-500);
    font-size: 13px;
    margin: -4px 0 12px;
}
.nexsend-tier-picker {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
}
.nexsend-tier-card {
    display: block;
    padding: 14px 16px;
    background: #fff;
    border: 2px solid var(--ns-gray-200);
    border-radius: 12px;
    cursor: pointer;
    transition: border-color 0.15s, background 0.15s;
}
.nexsend-tier-card:hover {
    border-color: var(--ns-primary);
}
.nexsend-tier-card.is-selected {
    border-color: var(--ns-primary);
    background: var(--ns-cream, #F7EDDB);
}
.nexsend-tier-card input[type="radio"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}
.nexsend-tier-card__head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 4px;
}
.nexsend-tier-card__name {
    font-family: "Mulish", sans-serif;
    font-weight: 800;
    font-style: italic;
    font-size: 18px;
    color: var(--ns-primary);
}
.nexsend-tier-card__fee {
    font-weight: 700;
    font-size: 14px;
    color: var(--ns-gray-900);
}
.nexsend-tier-card__tagline {
    display: block;
    font-size: 13px;
    color: var(--ns-gray-700);
    line-height: 1.4;
    margin-bottom: 6px;
}
.nexsend-tier-card__highlight {
    display: inline-block;
    font-size: 12px;
    font-weight: 700;
    color: var(--ns-amber, #EDA62B);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

/* --------------------------------------------------------------------- */
/* Portal polish — chip counts, row actions, dashboard rows, address picker */
/* --------------------------------------------------------------------- */

.nexsend-filters__item { display: inline-flex; align-items: center; }
.nexsend-filters__count {
    margin-left: 6px;
    min-width: 18px;
    height: 18px;
    padding: 0 6px;
    border-radius: 999px;
    background: #fff;
    color: var(--ns-gray-600);
    font-size: 11px;
    font-weight: 600;
    line-height: 18px;
    text-align: center;
    font-variant-numeric: tabular-nums;
}
.nexsend-filters__item--active .nexsend-filters__count { background: rgba(255, 255, 255, 0.22); color: #fff; }

.nexsend-pagination { align-items: center; flex-wrap: wrap; }
.nexsend-pagination__range {
    margin-right: auto;
    font-size: 13px;
    color: var(--ns-gray-500);
    font-variant-numeric: tabular-nums;
}

.nexsend-quick-label__error {
    max-width: 220px;
    margin-top: 4px;
    font-size: 12px;
    line-height: 1.35;
    color: var(--ns-danger);
    white-space: normal;
}
.nexsend-quick-label__error[hidden] { display: none; }

.nexsend-table__row--link { cursor: pointer; }
.nexsend-table__row--link:hover td { background: var(--ns-gray-50); }
.nexsend-table__row--link td:first-child a { color: inherit; text-decoration: none; }
.nexsend-table__row--link td:first-child a:hover,
.nexsend-table__row--link td:first-child a:focus-visible { color: var(--ns-primary); text-decoration: underline; }

.nexsend-wizard__section-head {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}
.nexsend-wizard__section-head h3 { margin-bottom: 0; }
.nexsend-ab-picker {
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    z-index: 50;
    width: 360px;
    max-width: 100%;
    background: #fff;
    border: 1px solid var(--ns-gray-200);
    border-radius: 8px;
    box-shadow: var(--ns-shadow-md);
    overflow: hidden;
}
.nexsend-ab-picker[hidden] { display: none; }
.nexsend-ab-picker__search {
    display: block;
    width: 100%;
    box-sizing: border-box;
    padding: 10px 12px;
    border: 0;
    border-bottom: 1px solid var(--ns-gray-200);
    font: inherit;
    font-size: 14px;
    outline: none;
}
.nexsend-ab-picker__list { max-height: 320px; overflow-y: auto; padding: 4px; margin: 0; list-style: none; }
.nexsend-ab-picker__item {
    display: flex;
    flex-direction: column;
    gap: 2px;
    width: 100%;
    padding: 8px 10px;
    border: 0;
    border-radius: 6px;
    background: transparent;
    font: inherit;
    font-size: 13px;
    text-align: left;
    color: var(--ns-gray-900);
    cursor: pointer;
}
.nexsend-ab-picker__item:hover,
.nexsend-ab-picker__item.is-active { background: var(--ns-gray-100); }
.nexsend-ab-picker__empty { margin: 0; padding: 12px; font-size: 13px; color: var(--ns-gray-500); }
.nexsend-ab-picker__empty[hidden] { display: none; }

/* Wide list tables scroll inside their card instead of widening the page,
   so the top bar and drawer stay put on phones and narrow tablets. */
body.nexsend-portal-app .nexsend-table-wrap { max-width: 100%; -webkit-overflow-scrolling: touch; }
body.nexsend-portal-app .nexsend-table-wrap > #nexsend-orders-table,
body.nexsend-portal-app .nexsend-table-wrap > #nexsend-shipments-table { min-width: 720px; }
@media (max-width: 600px) {
    .nexsend-steps { overflow-x: auto; scrollbar-width: none; }
    .nexsend-steps::-webkit-scrollbar { display: none; }
    .nexsend-steps__item { flex: 0 0 auto; }
}

/* Deselecteer sits on the dark batch bar: light text instead of the ghost default. */
body.nexsend-portal-app .nexsend-batch-bar .nexsend-btn--ghost {
    color: #fff;
    background: transparent;
    border-color: rgba(255, 255, 255, 0.35);
    opacity: 0.9;
}
body.nexsend-portal-app .nexsend-batch-bar .nexsend-btn--ghost:hover {
    background: rgba(255, 255, 255, 0.12);
    opacity: 1;
}

/* Row actions stay on one line; the table scrolls inside its wrapper instead. */
#nexsend-orders-table td:last-child,
#nexsend-shipments-table td:last-child { white-space: nowrap; }
#nexsend-orders-table td:last-child .nexsend-quick-label__error { white-space: normal; }

#nexsend-tier-dialog { max-width: 480px; width: calc(100% - 48px); padding: 24px; border: 0; border-radius: 16px; color: #29243d; }
#nexsend-tier-dialog::backdrop { background: rgba(25,20,40,.45); }
#nexsend-tier-error { color: #b42318; }

body.nexsend-portal-app .nexsend-invoice__table-wrap { max-width:100%; overflow-x:auto; }
body.nexsend-portal-app .nexsend-invoice__postcharges p { font-size:14px; line-height:1.6; }
@media screen and (max-width: 640px) {
    body.nexsend-portal-app .nexsend-invoice { padding:20px; }
    body.nexsend-portal-app .nexsend-invoice__parties { grid-template-columns:minmax(0,1fr); gap:16px; }
    body.nexsend-portal-app .nexsend-invoice__totals { min-width:0; width:100%; gap:8px 16px; }
    body.nexsend-portal-app .nexsend-invoice__head { flex-wrap:wrap; }
    body.nexsend-portal-app .nexsend-invoice__lines { min-width:440px; }
    body.nexsend-portal-app .nexsend-invoice__postcharges { min-width:0; }
}
@media print { body.nexsend-portal-app .nexsend-invoice__table-wrap { overflow:visible; } }
