html, body {
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
    min-height: 100%;
}

@font-face {
    font-family: "DXIcons";
    src: local("DevExtreme Generic Icons"),
         local("devextreme_generic_icons"),
         url("css/devexpress-icons/dxicons.woff2") format("woff2"),
         url("css/devexpress-icons/dxicons.woff") format("woff");
    font-weight: 400;
    font-style: normal;
}

:root {
    --portal-brand: #bd0f0f;
    --portal-brand-rgb: 189, 15, 15;
    --portal-button-bg: var(--portal-brand);
    --portal-button-border: var(--portal-brand);
    --portal-button-hover-bg: #990c0c;
    --portal-button-hover-border: #8a0b0b;
    --portal-button-active-bg: #790909;
    --portal-button-active-border: #680808;
    --portal-button-focus-rgb: var(--portal-brand-rgb);
    --bs-primary: var(--portal-button-bg);
    --bs-primary-rgb: var(--portal-button-focus-rgb);
    --portal-text: #212529;
    --portal-heading: #111827;
    --portal-muted: #6c757d;
    --portal-muted-strong: #495057;
    --portal-surface: #fff;
    --portal-surface-subtle: #f8f9fa;
    --portal-surface-raised: #fff;
    --portal-border: #dee2e6;
    --portal-border-soft: rgba(33, 37, 41, 0.12);
    --portal-accent: #2f6f5e;
    --portal-accent-soft: rgba(47, 111, 94, 0.08);
    --portal-focus: #258cfb;
    /* RO palette stays the same in light and dark mode. */
    --portal-ro-status-gray: #6B7280;
    --portal-ro-status-amber: #D18B00;
    --portal-ro-status-blue: #3976B8;
    --portal-ro-status-red: #E21936;
    --portal-ro-status-green: #39845A;
    --portal-radius: 8px;
    --portal-radius-sm: 6px;
    --portal-shadow: 0 0.25rem 0.75rem rgba(0, 0, 0, 0.04);
    --portal-shadow-strong: 0 0.5rem 1.4rem rgba(0, 0, 0, 0.18);
}

.portal-dx-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.25rem;
    height: 1.25rem;
    margin-right: 0.75rem;
    flex: 0 0 auto;
    color: currentColor;
    font-size: 1.25rem;
    line-height: 1;
    text-rendering: auto;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.portal-dx-icon.dx-icon::before {
    display: block;
    font-family: "DXIcons", sans-serif;
    font-size: inherit;
    font-style: normal;
    font-weight: 400;
    line-height: 1;
}

.dx-icon-attach::before {
    content: "\f151";
}

.dx-icon-car::before {
    content: "\f01b";
}

.dx-icon-chat::before {
    content: "\f17e";
}

.dx-icon-check::before {
    content: "\f005";
}

.dx-icon-checkmarkcircle::before {
    content: "\f183";
}

.dx-icon-chevrondown::before {
    content: "\f016";
}

.dx-icon-chevronright::before {
    content: "\f010";
}

.dx-icon-clipboardtasklist::before {
    content: "\f184";
}

.dx-icon-clock::before {
    content: "\f01d";
}

.dx-icon-close::before {
    content: "\f00a";
}

.dx-icon-doc::before {
    content: "\f021";
}

.dx-icon-file::before {
    content: "\f021";
}

.dx-icon-group::before {
    content: "\f02e";
}

.dx-icon-home::before {
    content: "\f030";
}

.dx-icon-map::before {
    content: "\f035";
}

.dx-icon-navigation_home_32x32white::before,
.dx-icon-iconbuilder_shopping_delivery_svg_32x32::before,
.dx-icon-businessobjects_bo_list_svg_dark_32x32::before,
.dx-icon-xaf_action_bell_svg_32x32::before,
.dx-icon-businessobjects_bo_user_svg_white_32x32::before,
.dx-icon-iconbuilder_actions_options_svg_32x32::before,
.dx-icon-wrench::before,
.dx-icon-wrench-solid::before,
.dx-icon-verified-user::before {
    content: "";
    width: 1em;
    height: 1em;
    background-color: currentColor;
    -webkit-mask-position: center;
    mask-position: center;
    -webkit-mask-size: contain;
    mask-size: contain;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
}

.dx-icon-navigation_home_32x32white::before {
    -webkit-mask-image: url("images/navigation_home_32x32gray.png");
    mask-image: url("images/navigation_home_32x32gray.png");
}

.dx-icon-iconbuilder_shopping_delivery_svg_32x32::before {
    -webkit-mask-image: url("images/iconbuilder_shopping_delivery.svg");
    mask-image: url("images/iconbuilder_shopping_delivery.svg");
}

.dx-icon-businessobjects_bo_list_svg_dark_32x32::before {
    -webkit-mask-image: url("images/businessobjects_bo_list_svg_dark_32x32.svg");
    mask-image: url("images/businessobjects_bo_list_svg_dark_32x32.svg");
}

.dx-icon-xaf_action_bell_svg_32x32::before {
    -webkit-mask-image: url("images/xaf_action_bell_svg_32x32.svg");
    mask-image: url("images/xaf_action_bell_svg_32x32.svg");
}

.dx-icon-businessobjects_bo_user_svg_white_32x32::before {
    -webkit-mask-image: url("images/businessobjects_bo_user_svg_white_32x32.svg");
    mask-image: url("images/businessobjects_bo_user_svg_white_32x32.svg");
}

.dx-icon-iconbuilder_actions_options_svg_32x32::before,
.dx-icon-wrench::before {
    -webkit-mask-image: url("images/wrench.svg");
    mask-image: url("images/wrench.svg");
}

.dx-icon-wrench-solid::before {
    -webkit-mask-image: url("images/wrench-solid.svg");
    mask-image: url("images/wrench-solid.svg");
}

.dx-icon-verified-user::before {
    -webkit-mask-image: url("images/pending-actions.svg");
    mask-image: url("images/pending-actions.svg");
}

.dx-icon-preferences::before {
    content: "\f03b";
}

.dx-icon-textdocument::before {
    content: "\f147";
}

.dx-icon-toolbox::before {
    content: "\f007";
}

.portal-dark {
    --portal-button-bg: #8f0b0b;
    --portal-button-border: #8f0b0b;
    --portal-button-hover-bg: #760909;
    --portal-button-hover-border: #680808;
    --portal-button-active-bg: #5c0707;
    --portal-button-active-border: #500606;
    --portal-button-focus-rgb: 143, 11, 11;
    --bs-primary: var(--portal-button-bg);
    --bs-primary-rgb: var(--portal-button-focus-rgb);
    --portal-text: #e7edf2;
    --portal-heading: #f8fafc;
    --portal-muted: #aeb8c2;
    --portal-muted-strong: #cbd5df;
    --portal-surface: #171d22;
    --portal-surface-subtle: #11171c;
    --portal-surface-raised: #1b2228;
    --portal-border: #2d3841;
    --portal-border-soft: #33404a;
    --portal-accent: #5bb99e;
    --portal-accent-soft: rgba(22, 101, 52, 0.22);
    --portal-focus: #7c9bd6;
    --portal-shadow: 0 0.5rem 1.4rem rgba(0, 0, 0, 0.24);
    --portal-shadow-strong: 0 1.25rem 3rem rgba(0, 0, 0, 0.34);
}

a, .btn-link {
    color: #006bb7;
}

.btn-primary,
.btn-outline-primary {
    --bs-btn-color: #fff;
    --bs-btn-bg: var(--portal-button-bg);
    --bs-btn-border-color: var(--portal-button-border);
    --bs-btn-hover-color: #fff;
    --bs-btn-hover-bg: var(--portal-button-hover-bg);
    --bs-btn-hover-border-color: var(--portal-button-hover-border);
    --bs-btn-focus-shadow-rgb: var(--portal-button-focus-rgb);
    --bs-btn-active-color: #fff;
    --bs-btn-active-bg: var(--portal-button-active-bg);
    --bs-btn-active-border-color: var(--portal-button-active-border);
    --bs-btn-disabled-color: #fff;
    --bs-btn-disabled-bg: var(--portal-button-bg);
    --bs-btn-disabled-border-color: var(--portal-button-border);
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem var(--portal-surface), 0 0 0 0.25rem var(--portal-focus);
}

.content {
    padding-top: 1.1rem;
}

h1:focus {
    outline: none;
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid #e50000;
}

.validation-message {
    color: #e50000;
}

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4NyAyNjcuNTM5IDUzLjYyODMgMjkwLjE4NSA5Mi4xODMxIDI5MC41NDUgOTIuNzk1IDI5MC42NTYgOTIuOTk2QzI5MC44NzcgOTMuNTEzIDI5MSA5NC4wODE1IDI5MSA5NC42NzgyIDI5MSA5Ny4wNjUxIDI4OS4wMzggOTkgMjg2LjYxNyA5OUwyNDAuMzgzIDk5QzIzNy45NjMgOTkgMjM2IDk3LjA2NTEgMjM2IDk0LjY3ODIgMjM2IDk0LjM3OTkgMjM2LjAzMSA5NC4wODg2IDIzNi4wODkgOTMuODA3MkwyMzYuMzM4IDkzLjAxNjIgMjM2Ljg1OCA5Mi4xMzE0IDI1OS40NzMgNTMuNjI5NCAyNTkuOTYxIDUyLjc5ODUgMjYwLjQwNyA1Mi4yNjU4QzI2MS4yIDUxLjQ4MzcgMjYyLjI5NiA1MSAyNjMuNTA2IDUxWk0yNjMuNTg2IDY2LjAxODNDMjYwLjczNyA2Ni4wMTgzIDI1OS4zMTMgNjcuMTI0NSAyNTkuMzEzIDY5LjMzNyAyNTkuMzEzIDY5LjYxMDIgMjU5LjMzMiA2OS44NjA4IDI1OS4zNzEgNzAuMDg4N0wyNjEuNzk1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

    .blazor-error-boundary::after {
        content: "An error has occurred."
    }

.darker-border-checkbox.form-check-input {
    border-color: #929292;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}

.portal-page {
    max-width: 1200px;
}

.portal-card {
    background-color: var(--portal-surface);
    border: 1px solid var(--portal-border);
    border-radius: var(--portal-radius);
    padding: 1.5rem;
    box-shadow: var(--portal-shadow);
}

.portal-hero-card {
    background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
}

.portal-card-title {
    color: color-mix(in srgb, var(--portal-heading) 88%, var(--portal-muted));
    font-size: 1.4rem;
    font-weight: 600;
    margin: 0;
}

.portal-section-title {
    font-size: 1.2rem;
    margin: 0;
}

.portal-header-account-selector {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.portal-header-account-change {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
    min-height: 2.35rem;
    max-width: 24rem;
    padding: 0.38rem 0.7rem 0.38rem 0.85rem;
    border: 1px solid color-mix(in srgb, var(--portal-brand) 30%, var(--portal-border));
    border-radius: var(--portal-radius-sm);
    background: var(--portal-surface);
    color: var(--portal-header-text);
    cursor: pointer;
    font: inherit;
    font-size: 0.86rem;
    line-height: 1.2;
    text-decoration: none;
    white-space: nowrap;
}

.portal-header-account-change .portal-header-account {
    align-items: flex-start;
    text-align: left;
}

.portal-header-account-change .portal-header-account-change-icon {
    width: 1.2rem;
    height: 1.2rem;
    margin-right: 0;
    font-size: 1.2rem;
}

.portal-header-account-change:hover,
.portal-header-account-change:focus-visible {
    border-color: color-mix(in srgb, var(--portal-brand) 55%, var(--portal-border));
    color: var(--portal-header-title);
    text-decoration: none;
}

.portal-eyebrow {
    display: none;
    color: var(--portal-muted);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    margin-bottom: 0.5rem;
    text-transform: uppercase;
}

.portal-eyebrow.mt-4 + .portal-card-title {
    margin-top: 1.5rem;
}

.portal-detail-grid,
.portal-metric-grid,
.portal-link-grid {
    display: grid;
    gap: 1rem;
}

.portal-detail-grid {
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    padding-left: .75rem;
}

.portal-metric-grid {
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.portal-link-grid {
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.portal-metric-card,
.portal-link-card {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    padding: 1rem;
    border: 1px solid var(--portal-border);
    border-radius: var(--portal-radius);
    color: inherit;
    text-decoration: none;
    background-color: var(--portal-surface);
}

.portal-metric-card:hover,
.portal-link-card:hover {
    border-color: color-mix(in srgb, var(--portal-focus) 45%, var(--portal-border));
    text-decoration: none;
}

.portal-metric-label {
    color: var(--portal-muted);
    font-size: 0.9rem;
    font-weight: 600;
}

.portal-metric-value {
    font-size: 2rem;
    font-weight: 700;
    line-height: 1;
}

.portal-metric-value--compact {
    font-size: 1.25rem;
    line-height: 1.2;
}

.portal-metric-note {
    color: var(--portal-muted);
    font-size: 0.9rem;
}

.portal-kv {
    display: grid;
    grid-template-columns: minmax(110px, 150px) 1fr;
    gap: 0.75rem 1rem;
}

.portal-kv > div:nth-child(odd) {
    color: var(--portal-muted);
    font-weight: 600;
}

.portal-my-inland-page {
    --portal-my-inland-card-gap: 0.9rem;
    --portal-my-inland-card-overlap: 2rem;
    --portal-my-inland-fade-midpoint: 1.35rem;
    --portal-my-inland-fade-endpoint: 0.5rem;
    display: grid;
    gap: 0;
}

.portal-my-inland-page .portal-card {
    padding: 1.15rem;
}

.portal-my-inland-page .portal-card-title {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    font-size: 1.2rem;
    line-height: 1.2;
}

.portal-my-inland-hero {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    padding: 0 !important;
    border: 0;
    background: var(--portal-main-bg, #fff);
    box-shadow: none;
}

.portal-my-inland-hero::after {
    position: absolute;
    z-index: 1;
    right: 0;
    bottom: 0;
    left: 0;
    height: var(--portal-my-inland-card-overlap);
    background: linear-gradient(
        to bottom,
        transparent 0,
        color-mix(in srgb, var(--portal-main-bg, #fff) 34%, transparent) 42%,
        var(--portal-main-bg, #fff) 100%
    );
    content: "";
    pointer-events: none;
}

.portal-my-inland-header {
    position: absolute;
    z-index: 2;
    inset: 0;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1rem;
    padding: clamp(1.25rem, 3vw, 2.25rem) clamp(1.25rem, 3.5vw, 2.75rem) 3.75rem;
    background: linear-gradient(
        to bottom,
        transparent 56%,
        rgba(0, 0, 0, 0.09) 69%,
        rgba(0, 0, 0, 0.26) 87%,
        transparent 100%
    );
}

.portal-my-inland-heading {
    min-width: 0;
}

.portal-my-inland-header .portal-eyebrow {
    color: rgba(255, 255, 255, 0.82);
    text-shadow:
        0 0.04rem 0.1rem rgba(0, 0, 0, 0.83),
        0 0.08rem 0.24rem rgba(0, 0, 0, 0.68);
}

.portal-my-inland-header .portal-my-inland-website-link {
    flex: 0 1 auto;
    text-align: right;
    white-space: nowrap;
}

.portal-my-inland-title {
    overflow: hidden;
    color: #fff;
    filter:
        drop-shadow(0 0.04rem 0.12rem rgba(0, 0, 0, 0.86))
        drop-shadow(0 0.1rem 0.28rem rgba(0, 0, 0, 0.74));
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 700;
    line-height: 1.1;
    margin: 0;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.portal-dark .portal-my-inland-title {
    color: #fff;
}

.portal-my-inland-hero--without-photo {
    background: var(--portal-surface);
    border: 1px solid var(--portal-border);
}

.portal-my-inland-hero--without-photo::after {
    display: none;
}

.portal-my-inland-hero--without-photo .portal-my-inland-header {
    position: relative;
    min-height: 10rem;
    background: none;
    padding-bottom: 4rem;
}

.portal-my-inland-hero--without-photo .portal-eyebrow {
    color: var(--portal-muted);
    text-shadow: none;
}

.portal-my-inland-hero--without-photo .portal-my-inland-title {
    color: var(--portal-header-title);
    filter: none;
    text-shadow: none;
}

.portal-my-inland-hero--without-photo .portal-my-inland-website-link,
.portal-my-inland-hero--without-photo .portal-my-inland-website-link:hover,
.portal-my-inland-hero--without-photo .portal-my-inland-website-link:focus {
    color: var(--portal-button-bg);
    filter: none;
    text-shadow: none;
}

.portal-my-inland-grid {
    position: relative;
    z-index: 1;
    isolation: isolate;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    align-items: stretch;
    gap: var(--portal-my-inland-card-gap);
    margin: calc(-1 * var(--portal-my-inland-card-overlap)) var(--portal-my-inland-card-gap) 0;
}

.portal-my-inland-grid > .portal-card {
    position: relative;
    z-index: 1;
    display: flex;
    min-width: 0;
    flex-direction: column;
    border-color: var(--portal-border-soft);
    box-shadow: 0 0.65rem 1.6rem rgba(0, 0, 0, 0.11);
}

.portal-store-photo-tail {
    position: absolute;
    z-index: 0;
    top: 0;
    right: calc(-1 * var(--portal-my-inland-card-gap));
    left: calc(-1 * var(--portal-my-inland-card-gap));
    height: 52%;
    overflow: hidden;
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.3) 0,
        rgba(0, 0, 0, 0.14) 52%,
        transparent 100%
    );
    pointer-events: none;
    -webkit-mask-image: linear-gradient(
        to bottom,
        transparent 0,
        rgba(0, 0, 0, 0.35) 8%,
        rgba(0, 0, 0, 0.8) 16%,
        #000 22%,
        rgba(0, 0, 0, 0.62) 58%,
        transparent 100%
    );
    mask-image: linear-gradient(
        to bottom,
        transparent 0,
        rgba(0, 0, 0, 0.35) 8%,
        rgba(0, 0, 0, 0.8) 16%,
        #000 22%,
        rgba(0, 0, 0, 0.62) 58%,
        transparent 100%
    );
}

.portal-store-photo-tail img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center bottom;
    filter: blur(0.8rem) saturate(0.82);
    opacity: 0.78;
    transform: scale(1.04, -1.08);
    transform-origin: center;
}

.portal-my-inland-card-icon {
    display: block;
    width: 1.5rem;
    height: 1.5rem;
    flex: 0 0 auto;
    color: var(--portal-brand);
    fill: currentColor;
}

.portal-store-hours-sections {
    display: grid;
    gap: 0;
    margin-top: 0.8rem;
}

.portal-store-hours-card {
    container-type: inline-size;
}

.portal-store-hours-section + .portal-store-hours-section {
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid var(--portal-border-soft);
}

.portal-store-hours-heading {
    margin: 0 0 0.4rem;
    color: var(--portal-heading);
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    text-transform: uppercase;
}

.portal-store-hours-list {
    display: grid;
    gap: 0.35rem;
    font-size: 0.875rem;
}

.portal-store-hours-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) max-content;
    align-items: baseline;
    gap: 0.55rem;
}

.portal-store-hours-days {
    overflow: hidden;
    color: var(--portal-muted);
    font-weight: 600;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.portal-store-hours-days-compact {
    display: none;
}

@container (max-width: 18rem) {
    .portal-store-hours-days-full {
        display: none;
    }

    .portal-store-hours-days-compact {
        display: inline;
    }
}

.portal-store-hours-value {
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.portal-store-hours-note,
.portal-store-hours-unavailable {
    margin-top: 0.8rem;
    color: var(--portal-muted);
    font-size: 0.9rem;
}

.portal-my-inland-address {
    display: grid;
    gap: 0.5rem;
    margin-top: 0.9rem;
    font-size: 0.9rem;
}

.portal-my-inland-address > div {
    overflow-wrap: anywhere;
}

.portal-store-photo-banner {
    width: 100%;
    height: clamp(24rem, 52dvh, 36rem);
    overflow: hidden;
    background: var(--portal-main-bg, #fff);
}

.portal-store-photo-banner img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    -webkit-mask-image: linear-gradient(
        to bottom,
        #000 0 calc(100% - var(--portal-my-inland-card-overlap)),
        rgba(0, 0, 0, 0.72) calc(100% - var(--portal-my-inland-fade-midpoint)),
        rgba(0, 0, 0, 0.24) calc(100% - var(--portal-my-inland-fade-endpoint)),
        transparent 100%
    );
    mask-image: linear-gradient(
        to bottom,
        #000 0 calc(100% - var(--portal-my-inland-card-overlap)),
        rgba(0, 0, 0, 0.72) calc(100% - var(--portal-my-inland-fade-midpoint)),
        rgba(0, 0, 0, 0.24) calc(100% - var(--portal-my-inland-fade-endpoint)),
        transparent 100%
    );
}

.portal-my-inland-actions {
    margin-top: auto;
    padding-top: 1rem;
    border-top: 1px solid var(--portal-border);
}

.portal-my-inland-direction-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.55rem;
    padding: 0.3rem 0.65rem;
    border: 1px solid var(--portal-button-border);
    border-radius: 0.375rem;
    background: var(--portal-button-bg);
    color: #fff;
    font-weight: 600;
    line-height: 1.5;
    text-decoration: none;
    transition: background-color 0.15s ease-in-out, border-color 0.15s ease-in-out;
    white-space: nowrap;
}

.portal-my-inland-direction-button:hover,
.portal-my-inland-direction-button:focus-visible {
    border-color: var(--portal-button-hover-border);
    background: var(--portal-button-hover-bg);
    color: #fff;
    text-decoration: none;
}

.portal-my-inland-website-link {
    overflow: hidden;
    color: #fff;
    filter:
        drop-shadow(0 0.04rem 0.1rem rgba(0, 0, 0, 0.85))
        drop-shadow(0 0.08rem 0.24rem rgba(0, 0, 0, 0.7));
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    text-overflow: ellipsis;
}

.portal-my-inland-website-link:hover,
.portal-my-inland-website-link:focus {
    color: #fff;
    text-decoration: underline;
}

.portal-store-contact-list {
    display: grid;
    gap: 0;
    margin-top: 0.55rem;
    font-size: 0.875rem;
}

.portal-store-manager-list {
    margin-top: 0.55rem;
}

.portal-store-manager-list .portal-store-contact-value {
    white-space: nowrap;
}

.portal-store-contact-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) max-content;
    align-items: start;
    gap: 0.65rem;
    padding: 0.65rem 0;
    border-bottom: 1px solid var(--portal-border-soft);
}

.portal-store-contact-row:last-child {
    border-bottom: 0;
}

.portal-store-contact-label {
    min-width: 0;
    color: var(--portal-muted);
    font-weight: 600;
    overflow-wrap: break-word;
}

.portal-store-contact-value {
    min-width: 0;
    text-align: right;
}

.portal-store-contact-phone {
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

@media (max-height: 53.125rem) and (min-width: 641px) {
    .portal-my-inland-page .portal-card {
        padding: clamp(0.5rem, 1.25dvh, 0.75rem);
    }

    .portal-my-inland-page .portal-card-title {
        font-size: 1.1rem;
    }

    .portal-store-photo-banner {
        max-height: clamp(14rem, calc(100vh - 21rem), 24.75rem);
        max-height: clamp(14rem, calc(100dvh - 21rem), 24.75rem);
    }

    .portal-my-inland-address,
    .portal-store-hours-list,
    .portal-store-contact-list {
        font-size: 0.9rem;
    }
}

@media (max-width: 1360px) and (min-width: 761px) {
    .portal-my-inland-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .portal-store-photo-tail {
        height: min(26%, 9rem);
    }
}

@media (max-width: 760px) {
    .portal-my-inland-page {
        --portal-my-inland-card-overlap: 1rem;
        --portal-my-inland-fade-midpoint: 0.65rem;
        --portal-my-inland-fade-endpoint: 0.25rem;
    }

    .portal-my-inland-header {
        justify-content: flex-end;
        align-items: flex-start;
        flex-direction: column;
        padding-bottom: 2.25rem;
    }

    .portal-my-inland-header .portal-my-inland-website-link {
        text-align: left;
    }

    .portal-my-inland-grid {
        grid-template-columns: 1fr;
        margin-right: var(--portal-my-inland-card-gap);
        margin-left: var(--portal-my-inland-card-gap);
    }

    .portal-store-photo-banner {
        height: clamp(18rem, 48dvh, 26rem);
    }

    .portal-store-photo-tail {
        height: min(13%, 7.5rem);
    }
}

.portal-preference-list {
    display: grid;
    gap: 0.85rem;
}

.portal-preference-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem;
    border: 1px solid var(--portal-border);
    border-radius: var(--portal-radius-sm);
    background-color: var(--portal-surface);
}

.portal-preference-copy {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    min-width: 0;
}

.portal-preference-title {
    color: var(--portal-heading);
    font-weight: 700;
}

.portal-preference-copy span {
    color: var(--portal-muted);
    overflow-wrap: anywhere;
}

.portal-preference-switch {
    flex: 0 0 auto;
    margin: 0;
    min-height: 0;
}

.portal-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.portal-account-select-grid {
    display: grid;
    gap: 1rem;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.portal-account-select-card {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    min-height: 7rem;
    padding: 1rem;
    border: 1px solid var(--portal-border);
    border-radius: var(--portal-radius);
    background: var(--portal-surface);
    color: inherit;
    text-align: left;
}

.portal-account-select-card:hover,
.portal-account-select-card:focus-visible,
.portal-account-select-card--selected {
    border-color: var(--portal-button-border);
    box-shadow: 0 0 0 0.15rem rgba(var(--portal-button-focus-rgb), 0.12);
}

.portal-account-select-card span {
    color: var(--portal-muted);
}

.portal-account-select-card small {
    color: var(--portal-muted-strong);
    font-weight: 600;
}

.portal-account-select-notifications {
    display: flex;
    align-self: flex-end;
    gap: 0.4rem;
    margin-top: auto;
}

.portal-account-select-notification {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    min-width: 1.85rem;
    height: 1.85rem;
    padding: 0 0.45rem;
    border-radius: 999px;
    background: var(--portal-brand);
    color: #fff;
    font-size: 0.78rem;
    font-weight: 700;
    line-height: 1;
}

.portal-account-select-notification .portal-account-select-notification-icon {
    width: 0.95rem;
    height: 0.95rem;
    margin-right: 0;
    font-size: 0.95rem;
}

.portal-account-select-card .portal-account-select-notification,
.portal-account-select-card .portal-account-select-notification span {
    color: #fff;
}

.portal-image-strip {
    display: grid;
    gap: 0.75rem;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
}

.portal-image-placeholder {
    min-height: 140px;
    border: 1px dashed #c6ccd3;
    border-radius: var(--portal-radius);
    background-color: var(--portal-surface-subtle);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 0.4rem;
    padding: 1rem;
    text-align: center;
    color: var(--portal-muted-strong);
}

.portal-vehicle-thumbnail {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    overflow: hidden;
    border: 1px solid #cfd6dd;
    border-radius: var(--portal-radius-sm);
    background: #f1f3f5;
    color: #495057;
    font-size: 0.72rem;
    font-weight: 700;
    line-height: 1;
    text-transform: uppercase;
}

.portal-vehicle-thumbnail--small {
    width: 48px;
    height: 48px;
}

.portal-vehicle-thumbnail--large {
    width: 112px;
    height: 84px;
}

.portal-vehicle-thumbnail img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.portal-vehicle-thumbnail img:not([src]),
.portal-vehicle-thumbnail img[src=""] {
    visibility: hidden;
}

.portal-vehicle-thumbnail .portal-vehicle-thumbnail-placeholder-icon {
    width: auto;
    height: auto;
    margin: 0;
    color: inherit;
    font-size: 1.2rem;
}

.portal-vehicle-thumbnail--large .portal-vehicle-thumbnail-placeholder-icon {
    font-size: 2rem;
}

.portal-vehicle-list-thumbnail .portal-vehicle-thumbnail-placeholder-icon {
    color: var(--portal-muted);
    font-size: 2rem;
}

.portal-vehicle-list-thumbnail .portal-vehicle-thumbnail-placeholder-icon::before {
    -webkit-mask: url("images/itp-truck-icon-vector.svg") center / 155% no-repeat;
    mask: url("images/itp-truck-icon-vector.svg") center / 155% no-repeat;
    transform: translateY(1px);
}

.portal-repair-list-thumbnail .portal-vehicle-thumbnail-placeholder-icon::before {
    -webkit-mask: url("images/wrench-solid.svg") center / contain no-repeat;
    mask: url("images/wrench-solid.svg") center / contain no-repeat;
    transform: scaleX(-1);
}

.portal-repair-list-thumbnail .portal-vehicle-thumbnail-placeholder-icon {
    width: 1.8rem;
    height: 1.8rem;
    font-size: 1.8rem;
}

body:not(.portal-dark) .portal-vehicle-list-thumbnail .portal-vehicle-thumbnail-placeholder-icon,
body:not(.portal-dark) .portal-repair-list-thumbnail--active .portal-vehicle-thumbnail-placeholder-icon {
    color: var(--portal-brand);
}

.portal-vehicle-thumbnail.is-loading {
    background: #e9ecef;
}

.portal-status-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.45rem 0.75rem;
    border-radius: 999px;
    font-size: 0.9rem;
    font-weight: 700;
}

.portal-status-pill--warning {
    background-color: #fff3cd;
    color: #8a5c00;
}

.portal-status-pill--success {
    background-color: #d1e7dd;
    color: #0f5132;
}

.portal-status-pill--danger {
    background-color: #f8d7da;
    color: #842029;
}

.portal-status-pill--info {
    background-color: #e2eafc;
    color: #234ea5;
}

.portal-status-pill--secondary {
    background-color: #e9ecef;
    color: #495057;
}

.portal-user-deactivated {
    color: #7a838c;
    opacity: 0.68;
}

.portal-user-status-control {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.portal-user-gear-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.75rem;
    height: 1.75rem;
    border: 0;
    background: transparent;
    color: var(--portal-muted-strong);
    font-size: 1.35rem;
    font-weight: 900;
    line-height: 1;
    padding: 0;
}

.portal-user-gear-button:not(:disabled):hover,
.portal-user-gear-button:not(:disabled):focus-visible {
    color: var(--portal-heading);
    box-shadow: 0 0 0 0.15rem rgba(37, 140, 251, 0.16);
}

.portal-user-confirm {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.portal-thread {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.portal-message {
    border: 1px solid var(--portal-border);
    border-radius: var(--portal-radius);
    padding: 1rem 1.1rem;
    max-width: min(52rem, 100%);
    box-shadow: 0 0.2rem 0.7rem rgba(0, 0, 0, 0.04);
}

.portal-message--customer {
    align-self: flex-end;
    background-color: #edf4ff;
    border-color: #bfd5ff;
}

.portal-message--itp {
    align-self: flex-start;
    background-color: #fff;
}

.portal-message-meta {
    color: var(--portal-muted);
    font-size: 0.85rem;
    margin-bottom: 0.35rem;
}

.portal-chip-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.9rem;
}

.portal-chip {
    background-color: color-mix(in srgb, var(--portal-surface-subtle) 85%, var(--portal-border));
    border-radius: 999px;
    color: var(--portal-muted-strong);
    font-size: 0.8rem;
    padding: 0.3rem 0.65rem;
}

.portal-messaging-screen {
    --portal-thread-list-surface: color-mix(in srgb, var(--portal-surface-subtle) 97%, var(--portal-text));
    display: grid;
    grid-template-columns: minmax(260px, 340px) minmax(0, 1fr);
    gap: 1rem;
    height: var(--portal-messaging-screen-height, calc(100dvh - 7rem));
    min-height: 420px;
    max-height: var(--portal-messaging-screen-height, calc(100dvh - 7rem));
    overflow: visible;
    color: var(--portal-text);
    font-size: 0.9rem;
}

.portal-conversation-pane,
.portal-thread-pane {
    min-width: 0;
    min-height: 0;
    border: 1px solid var(--portal-border);
    border-radius: var(--portal-radius);
    background: var(--portal-surface);
    box-shadow: 0 0.4rem 1.1rem rgba(15, 23, 42, 0.08);
}

.portal-conversation-pane {
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.portal-conversation-header,
.portal-thread-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem;
    border-bottom: 1px solid var(--portal-border-soft);
}

.portal-thread-header {
    container-type: inline-size;
}

.portal-thread-header-with-thumbnail {
    --portal-thread-leading-offset: 4rem;
    padding-block: 0.5rem;
}

.portal-thread-header:not(.portal-thread-header-with-thumbnail) {
    --portal-thread-leading-offset: 0rem;
    padding-block: 0.75rem;
}

.portal-conversation-title,
.portal-thread-title {
    min-width: 0;
}

.portal-thread-title {
    flex: 1 1 auto;
}

.portal-thread-title-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    align-items: baseline;
    column-gap: 1rem;
    width: calc(100% + var(--portal-thread-leading-offset));
    margin-left: calc(0rem - var(--portal-thread-leading-offset));
    min-width: 0;
}

.portal-thread-subtitle {
    min-width: 0;
    overflow: hidden;
    padding-left: var(--portal-thread-leading-offset);
    text-overflow: ellipsis;
    white-space: nowrap;
}

.portal-thread-type {
    grid-column: 2;
    justify-self: center;
    white-space: nowrap;
    text-align: center;
}

.portal-thread-heading-row {
    grid-template-columns: minmax(10rem, 1fr) minmax(0, auto) minmax(10rem, 1fr);
    align-items: center;
}

.portal-thread-heading-row h2 {
    min-width: 0;
    padding-left: var(--portal-thread-leading-offset);
    overflow-wrap: anywhere;
}

.portal-thread-vehicle {
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
}

.portal-thread-header > .portal-view-messages {
    flex-shrink: 0;
    white-space: nowrap;
}

@container (max-width: 30rem) {
    .portal-thread-heading-row {
        grid-template-columns: minmax(0, 1fr);
        row-gap: 0.2rem;
    }

    .portal-thread-heading-row .portal-thread-vehicle {
        grid-column: 1 / -1;
        grid-row: 2;
    }
}

.portal-conversation-title h2,
.portal-thread-title h2,
.portal-empty-thread h3 {
    margin: 0;
    font-size: 1rem;
    line-height: 1.3;
    font-weight: 700;
}

.portal-conversation-title span,
.portal-thread-title span,
.portal-compose-hint {
    color: var(--portal-muted);
    font-size: 0.8rem;
}

.portal-message-search {
    width: auto;
    margin: 0.75rem 1rem;
    font-size: 0.85rem;
}

.portal-conversation-top-card {
    display: grid;
    flex: 0 0 auto;
    gap: 0.7rem;
    margin: 0;
    padding: 0.75rem;
    border: 0;
    border-bottom: 1px solid var(--portal-border);
    border-radius: 0;
    background: color-mix(in srgb, var(--portal-surface-subtle) 88%, var(--portal-border));
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.82),
        inset 0 -0.2rem 0.7rem rgba(15, 23, 42, 0.045),
        0 0.25rem 0.65rem rgba(15, 23, 42, 0.08);
}

.portal-conversation-top-card .portal-message-search,
.portal-conversation-top-card .portal-conversation-tabs {
    width: 100%;
    margin: 0;
}

.portal-conversation-tabs {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.2rem;
    margin: 0 1rem 0.75rem;
    padding: 0.2rem;
    border: 1px solid var(--portal-border-soft);
    border-radius: calc(var(--portal-radius) - 0.15rem);
    background: var(--portal-surface-subtle);
}

.portal-conversation-tab {
    min-width: 0;
    padding: 0.45rem 0.65rem;
    border: 1px solid transparent;
    border-radius: calc(var(--portal-radius) - 0.3rem);
    background: transparent;
    color: var(--portal-muted-strong);
    font-size: 0.8rem;
    font-weight: 600;
}

.portal-conversation-tab:hover {
    color: var(--portal-text);
}

.portal-conversation-tab:focus-visible {
    outline: 2px solid rgba(var(--portal-brand-rgb), 0.35);
    outline-offset: 2px;
}

.portal-conversation-tab-active {
    border-color: var(--portal-border-soft);
    background: var(--portal-surface);
    color: var(--portal-brand);
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.08);
}

.portal-conversation-list {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    flex: 1 1 auto;
    min-height: 0;
    padding: 0.8rem 1rem 1rem;
    background: var(--portal-thread-list-surface);
    overflow-y: auto;
    overscroll-behavior: contain;
}

.portal-general-conversation-slot {
    display: grid;
    gap: 0.5rem;
}

.portal-general-conversation-slot .portal-conversation-item {
    border-color: var(--portal-border-soft);
}

.portal-general-conversation-slot .portal-conversation-item-active {
    border-color: var(--portal-brand);
}

.portal-conversation-item {
    --portal-thread-selection-width: 10.9512px;
    --portal-thread-stretch-distance: 14.23656px;
    position: relative;
    display: grid;
    flex: 0 0 auto;
    grid-template-columns: 42px minmax(0, 1fr) auto;
    align-items: center;
    gap: 0.75rem;
    width: calc(100% - var(--portal-thread-stretch-distance));
    /* min-height: 76px; */
    margin: 0;
    overflow: hidden;
    padding: 0.8rem 0.75rem;
    border: 1px solid var(--portal-border-soft);
    border-radius: var(--portal-radius);
    background: var(--portal-thread-list-surface);
    color: inherit;
    text-align: left;
    transition:
        width 160ms ease,
        padding-left 160ms ease,
        border-color 160ms ease,
        box-shadow 160ms ease;
}

.portal-conversation-item:focus-visible {
    outline: 2px solid rgba(var(--portal-brand-rgb), 0.35);
    outline-offset: 2px;
}

.portal-conversation-item-active {
    width: 100%;
    padding-left: calc(0.75rem + var(--portal-thread-selection-width));
    border-color: var(--portal-brand);
    background: var(--portal-surface-raised);
    box-shadow: 0.45rem 0 0.65rem -0.35rem rgba(15, 23, 42, 0.18);
}

.portal-conversation-item::before {
    position: absolute;
    top: -1px;
    bottom: -1px;
    left: -1px;
    width: var(--portal-thread-selection-width);
    border-radius: var(--portal-radius) 0 0 var(--portal-radius);
    background: var(--portal-brand);
    transform: translateX(-100%);
    transition: transform 160ms ease;
    content: "";
}

.portal-conversation-item-active::before {
    transform: translateX(0);
}

@media (prefers-reduced-motion: reduce) {
    .portal-conversation-item,
    .portal-conversation-item::before {
        transition: none;
    }
}

.portal-conversation-avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: #e3e6ea;
    color: var(--portal-brand);
    box-shadow: none;
    font-size: 0.9rem;
    font-weight: 700;
}

.portal-conversation-avatar .portal-dx-icon {
    width: 1.1rem;
    height: 1.1rem;
    margin: 0;
    overflow: visible;
    font-size: 1.1rem;
}

.portal-conversation-avatar-repair-order .portal-dx-icon {
    width: 1.4rem;
    height: 1.4rem;
    font-size: 1.4rem;
    transform: scaleX(-1);
}

.portal-conversation-avatar-chat-icon {
    display: block;
    width: 1.35rem;
    height: 1.35rem;
    flex: 0 0 auto;
    transform: translateY(-1px);
}

.portal-conversation-pane-archived .portal-conversation-avatar {
    color: #6b7280;
}

.portal-conversation-content {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    min-width: 0;
}

.portal-conversation-row {
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
    min-width: 0;
}

.portal-conversation-name,
.portal-conversation-preview {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.portal-conversation-name {
    flex: 1 1 auto;
    font-weight: 700;
}

.portal-ro-vehicle-detail {
    display: block;
    color: var(--portal-muted);
    font-size: 0.85rem;
    line-height: 1.35;
    overflow-wrap: anywhere;
}

.portal-conversation-time {
    flex: 0 0 auto;
    color: var(--portal-muted);
    font-size: 0.72rem;
}

.portal-conversation-preview {
    color: var(--portal-muted-strong);
    display: -webkit-box;
    overflow: hidden;
    font-size: 0.8rem;
    line-height: 1.35;
    white-space: normal;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.portal-unread-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    height: 24px;
    padding: 0 0.4rem;
    border-radius: 999px;
    background: var(--portal-brand);
    color: #fff;
    font-size: 0.78rem;
    font-weight: 700;
}

.portal-thread-pane {
    display: grid;
    grid-template-rows: auto minmax(0, 1fr) auto;
    overflow: hidden;
}

.portal-thread-header-main {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    flex: 1 1 auto;
    gap: 1rem;
    min-width: 0;
}

.portal-recipient-picker-row {
    display: grid;
    grid-template-columns: auto minmax(130px, 0.4fr) minmax(220px, 1fr);
    align-items: center;
    gap: 0.5rem;
}

.portal-recipient-picker-label {
    color: #495057;
    font-size: 0.85rem;
    font-weight: 700;
}

.portal-recipient-picker-type,
.portal-recipient-picker-recipient {
    min-width: 0;
}

.portal-message-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    min-height: 0;
    padding: 1.25rem;
    overflow-y: auto;
    overscroll-behavior: contain;
    background-color: #f7f9fc;
    background-image:
        radial-gradient(ellipse 88% 72% at -8% -12%, rgba(255, 255, 255, 0.98) 0 42%, rgba(255, 255, 255, 0.82) 46%, rgba(207, 217, 231, 0.28) 51%, rgba(230, 236, 244, 0.14) 56%, transparent 62%),
        radial-gradient(ellipse 72% 58% at 24% 3%, rgba(255, 255, 255, 0.58) 0 35%, rgba(255, 255, 255, 0.16) 42%, transparent 52%),
        radial-gradient(ellipse 112% 78% at 108% 108%, transparent 0 31%, rgba(255, 255, 255, 0.16) 34%, rgba(255, 255, 255, 0.72) 38%, rgba(202, 214, 230, 0.32) 44%, rgba(229, 235, 243, 0.12) 49%, transparent 55%),
        radial-gradient(ellipse 124% 88% at 108% 110%, transparent 0 46%, rgba(255, 255, 255, 0.72) 51%, rgba(205, 216, 230, 0.25) 57%, rgba(242, 245, 249, 0.18) 61%, transparent 67%),
        radial-gradient(ellipse 82% 58% at 72% 48%, rgba(255, 255, 255, 0.42), rgba(232, 237, 244, 0.1) 48%, transparent 70%),
        linear-gradient(158deg, rgba(255, 255, 255, 0.4) 8%, transparent 38%, rgba(205, 216, 230, 0.08) 58%, rgba(255, 255, 255, 0.3) 82%),
        url("/images/valve-body-chat-background-optimized.webp");
    background-position: center bottom;
    background-size: cover;
    background-repeat: no-repeat;
    background-blend-mode: soft-light, soft-light, soft-light, soft-light, soft-light, soft-light, normal;
}

.portal-message-list:not(.portal-new-message-list)::before {
    content: "";
    margin-top: auto;
}

.portal-new-message-list {
    align-items: center;
    justify-content: center;
}

.portal-new-message-placeholder,
.portal-empty-list,
.portal-empty-thread {
    color: var(--portal-muted);
}

.portal-empty-list {
    padding: 1rem;
    text-align: center;
}

.portal-empty-thread {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    height: 100%;
    min-height: 320px;
}

.portal-empty-thread-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 50%;
    background: var(--portal-brand);
    color: #fff;
    font-size: 1rem;
    font-weight: 700;
}

.portal-message-row {
    display: flex;
}

.portal-message-row-mine {
    justify-content: flex-end;
}

.portal-message-bubble {
    max-width: min(72%, 680px);
    border: 1px solid var(--portal-border-soft);
    border-radius: var(--portal-radius);
    padding: 0.9rem 1rem;
    background: var(--portal-surface-raised);
    font-size: 0.85rem;
}

.portal-message-row-mine .portal-message-bubble {
    border-color: rgba(35, 78, 165, 0.25);
    background: #edf4ff;
}

.portal-message-row-target .portal-message-bubble {
    border-color: var(--portal-border-soft);
    box-shadow: none;
}

.portal-bubble-meta {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.35rem;
    color: var(--portal-muted);
    font-size: 0.72rem;
}

.portal-bubble-meta span {
    font-weight: 700;
    color: var(--portal-heading);
}

.portal-message-bubble p {
    margin: 0;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

.portal-message-body {
    line-height: 1.45;
    overflow-wrap: anywhere;
}

.portal-message-body p,
.portal-message-body ul,
.portal-message-body ol {
    margin: 0;
}

.portal-message-body p,
.portal-message-body li {
    white-space: pre-wrap;
}

.portal-message-body ul,
.portal-message-body ol {
    padding-inline-start: 1.5em;
}

.portal-message-body > :not(:first-child) {
    margin-top: .5rem;
}

.portal-message-body li + li {
    margin-top: .15rem;
}

.portal-message-ro-link {
    font-weight: 700;
}

.portal-ro-verification {
    display: grid;
    gap: .75rem;
    border: 1px solid var(--portal-border-soft);
    border-radius: var(--portal-radius);
    padding: 0.75rem;
    background: color-mix(in srgb, var(--portal-surface-raised) 94%, var(--portal-surface-subtle));
}

.portal-message-row-target .portal-ro-verification {
    border-color: rgba(var(--portal-brand-rgb), 0.65);
    box-shadow: 0 0 0 3px rgba(var(--portal-brand-rgb), 0.14);
}

.portal-ro-verification-kicker {
    color: var(--portal-brand);
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: 0;
    text-transform: uppercase;
}

.portal-ro-verification-title {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.portal-ro-verification-header {
    display: flex;
    align-items: flex-start;
    gap: .75rem;
}

.portal-ro-verification-header-content {
    display: grid;
    flex: 1 1 auto;
    gap: .55rem;
    min-width: 0;
}

.portal-ro-verification-title strong,
.portal-ro-verification-ro-link {
    color: var(--portal-heading);
    font-size: 1rem;
    font-weight: 700;
}

.portal-ro-verification-status {
    overflow-wrap: anywhere;
    border: 1px solid #fecaca;
    border-radius: 999px;
    color: #991b1b;
    font-size: .75rem;
    font-weight: 700;
    padding: .2rem .55rem;
}

.portal-ro-verification-status--approved {
    border-color: #bbf7d0;
    color: #166534;
}

.portal-ro-verification-status--denied {
    border-color: #fecaca;
    color: #991b1b;
}

.portal-ro-verification-status--pending {
    border-color: #fde68a;
    color: #92400e;
}

.portal-ro-verification dl {
    display: grid;
    gap: .55rem;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin: 0;
}

.portal-ro-verification dt {
    color: var(--portal-muted);
    font-size: .72rem;
    font-weight: 600;
    margin: 0 0 .15rem;
}

.portal-ro-verification dd {
    color: var(--portal-heading);
    font-size: .9rem;
    font-weight: 700;
    margin: 0;
}

.portal-ro-verification p {
    border-left: 3px solid var(--portal-brand);
    color: var(--portal-muted-strong);
    margin: 0;
    padding-left: .65rem;
}

.portal-ro-verification-actions {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
}

.portal-ro-verification-details {
    margin-left: auto;
}

.portal-approval-confirmation {
    display: grid;
    grid-template-rows: 1fr;
    margin-bottom: var(--portal-approval-confirmation-gap, .75rem);
    animation: portal-approval-confirmation-expand 180ms ease, portal-approval-confirmation-enter 180ms ease;
}

.portal-approval-confirmation > p {
    min-height: 0;
    overflow: hidden;
    margin: 0;
    padding: 0;
    border: 0;
}

.portal-approval-confirmation-button {
    animation: portal-approval-confirmation-enter 180ms ease;
}

@keyframes portal-approval-confirmation-expand {
    from {
        grid-template-rows: 0fr;
        margin-bottom: 0;
    }
    to {
        grid-template-rows: 1fr;
        margin-bottom: var(--portal-approval-confirmation-gap, .75rem);
    }
}

@keyframes portal-approval-confirmation-enter {
    from { opacity: 0; transform: translateY(.25rem); }
    to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
    .portal-approval-confirmation,
    .portal-approval-confirmation-button {
        animation: none;
    }
}

.portal-ro-verification-message {
    color: var(--portal-muted);
    font-size: .82rem;
}

.portal-message-attachments {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(132px, 220px));
    gap: .55rem;
    margin-top: .65rem;
}

.portal-message-attachment-image {
    min-width: 0;
    margin: 0;
}

.portal-message-attachment-open {
    display: block;
    width: 100%;
    padding: 0;
    border: 0;
    background: transparent;
    color: inherit;
    cursor: pointer;
}

.portal-message-attachment-open:focus-visible {
    outline: 2px solid var(--portal-focus);
    outline-offset: 2px;
    border-radius: var(--portal-radius-sm);
}

.portal-message-attachment-image img,
.portal-message-attachment-placeholder {
    display: block;
    width: 100%;
    aspect-ratio: 4 / 3;
    border: 1px solid var(--portal-border-soft);
    border-radius: var(--portal-radius-sm);
    background: var(--portal-surface-subtle);
}

.portal-message-attachment-image img {
    object-fit: cover;
}

.portal-message-attachment-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: .75rem;
    color: var(--portal-muted);
    font-size: .82rem;
    text-align: center;
}

.portal-message-attachment-image figcaption {
    margin-top: .25rem;
    color: var(--portal-muted);
    font-size: .78rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.portal-message-image-gallery {
    display: grid;
    gap: .85rem;
    padding: .25rem;
}

.portal-message-image-gallery:focus-visible {
    outline: 2px solid var(--portal-focus);
    outline-offset: 2px;
}

.portal-message-image-gallery-stage {
    position: relative;
    display: grid;
    min-height: min(62vh, 620px);
    place-items: center;
    overflow: hidden;
    border: 1px solid var(--portal-border-soft);
    border-radius: var(--portal-radius);
    background: var(--portal-surface-subtle);
}

.portal-message-image-gallery-stage > img {
    display: block;
    width: 100%;
    height: min(62vh, 620px);
    max-width: 100%;
    max-height: min(62vh, 620px);
    object-fit: contain;
}

.portal-message-image-gallery-nav {
    position: absolute;
    top: 50%;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    border: 1px solid var(--portal-border-soft);
    border-radius: 999px;
    background: rgba(255, 255, 255, .92);
    color: var(--portal-muted-strong);
    font-size: 2rem;
    line-height: 1;
    transform: translateY(-50%);
}

.portal-message-image-gallery-nav:hover,
.portal-message-image-gallery-nav:focus-visible {
    background: var(--portal-surface);
    color: var(--portal-brand);
    outline: none;
}

.portal-message-image-gallery-nav-previous {
    left: .75rem;
}

.portal-message-image-gallery-nav-next {
    right: .75rem;
}

.portal-message-image-gallery-thumbnails {
    display: flex;
    gap: .6rem;
    max-width: 100%;
    overflow-x: auto;
    padding: .1rem;
}

.portal-message-image-gallery-thumbnail {
    display: flex;
    flex: 0 0 96px;
    min-width: 0;
    flex-direction: column;
    gap: .35rem;
    padding: .35rem;
    border: 1px solid var(--portal-border-soft);
    border-radius: var(--portal-radius-sm);
    background: var(--portal-surface);
    color: inherit;
    text-align: left;
}

.portal-message-image-gallery-thumbnail.is-selected {
    border-color: var(--portal-brand);
    box-shadow: inset 0 0 0 1px var(--portal-brand);
}

.portal-message-image-gallery-thumbnail:focus-visible {
    outline: 2px solid var(--portal-focus);
    outline-offset: 2px;
}

.portal-message-image-gallery-thumbnail img {
    display: block;
    width: 100%;
    aspect-ratio: 4 / 3;
    border-radius: var(--portal-radius-sm);
    object-fit: cover;
}

.portal-message-image-gallery-thumbnail span,
.portal-message-image-gallery-meta span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.portal-message-image-gallery-thumbnail span {
    color: var(--portal-muted);
    font-size: .78rem;
    font-weight: 700;
}

.portal-message-image-gallery-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .75rem;
    color: var(--portal-muted);
    font-size: .85rem;
}

.portal-message-image-gallery-filename {
    min-width: 0;
    font-weight: 700;
}

body.portal-dark .portal-message-image-gallery-popup,
body.portal-dark .portal-message-image-gallery-popup .dxbl-popup,
body.portal-dark .portal-message-image-gallery-popup .dxbl-popup-root,
body.portal-dark .portal-message-image-gallery-popup .dxbl-modal,
body.portal-dark .portal-message-image-gallery-popup .dxbl-modal-content,
body.portal-dark .portal-message-image-gallery-popup.dxbl-modal > .dxbl-modal-root > .dxbl-popup > .dxbl-modal-content {
    background: #11171c !important;
    color: #d1d5db !important;
    border-color: #2d3841 !important;
}

body.portal-dark .portal-message-image-gallery-popup .dxbl-popup-header,
body.portal-dark .portal-message-image-gallery-popup .dxbl-modal-header {
    background: #11171c !important;
    color: #f8fafc !important;
    border-color: #2d3841 !important;
}

body.portal-dark .portal-message-image-gallery-popup .dxbl-popup-body,
body.portal-dark .portal-message-image-gallery-popup .dxbl-modal-body {
    background: #11171c !important;
    color: #d1d5db !important;
    padding: 0.75rem !important;
}

body.portal-dark .portal-message-image-gallery-popup .dxbl-popup-close,
body.portal-dark .portal-message-image-gallery-popup .dxbl-btn {
    color: #e7edf2 !important;
}

.portal-message-link {
    margin-top: 0.75rem;
}

.portal-compose-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 0.5rem 0.75rem;
    border-top: 1px solid var(--portal-border-soft);
    padding: 0.75rem 1rem;
    background: var(--portal-surface);
}

.portal-compose-input {
    grid-column: 1 / -1;
    width: 100%;
    height: 3.75rem;
    min-height: 3.75rem;
    padding: 0.5rem 0.65rem;
    resize: none;
    font-size: 0.82rem;
    line-height: 1.35;
}

.portal-compose-panel-archived .portal-compose-input:disabled,
.portal-compose-panel-archived .portal-compose-actions .dxbl-btn {
    border-color: var(--portal-border-soft) !important;
    background: var(--portal-thread-list-surface) !important;
    background-image: none !important;
    color: var(--portal-muted-strong) !important;
    opacity: 1;
}

.portal-compose-attachment {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0.5rem;
    min-width: 0;
    margin-top: 0;
    color: var(--portal-muted);
    font-size: 0.8rem;
}

.portal-compose-attachment-input {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    clip-path: inset(50%);
}

.portal-compose-attachment-button {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    border: 1px solid var(--portal-border-soft);
    border-radius: var(--portal-radius-sm);
    padding: 0.25rem 0.5rem;
    background: var(--portal-surface);
    color: var(--portal-muted-strong);
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
}

.portal-compose-attachment-button .portal-dx-icon {
    width: 0.85rem;
    height: 0.85rem;
    font-size: 0.85rem;
    margin-right: 0;
}

.portal-compose-attachment-button:hover,
.portal-compose-attachment-button:focus {
    border-color: rgba(var(--portal-brand-rgb), 0.35);
    background: rgba(var(--portal-brand-rgb), 0.06);
    outline: none;
}

.portal-compose-attachment-button.is-disabled {
    cursor: not-allowed;
    opacity: 0.6;
    pointer-events: none;
}

.portal-compose-attachment-name,
.portal-compose-attachment-status {
    min-width: 0;
    color: var(--portal-accent);
    font-size: 0.78rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.portal-compose-attachment-previews {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(80px, 104px));
    gap: 0.5rem;
    margin-bottom: 0;
}

.portal-compose-attachment-preview {
    position: relative;
    min-width: 0;
    margin: 0;
}

.portal-compose-attachment-preview img {
    display: block;
    width: 100%;
    aspect-ratio: 4 / 3;
    border: 1px solid var(--portal-border-soft);
    border-radius: var(--portal-radius-sm);
    background: var(--portal-surface-subtle);
    object-fit: cover;
}

.portal-compose-attachment-preview figcaption {
    margin-top: 0.25rem;
    color: var(--portal-muted);
    font-size: 0.75rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.portal-compose-attachment-remove {
    position: absolute;
    top: 0.25rem;
    right: 0.25rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border: 1px solid var(--portal-border-soft);
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.94);
    color: var(--portal-muted-strong);
    font-size: 0.75rem;
}

.portal-compose-attachment-remove .portal-dx-icon {
    width: 0.8rem;
    height: 0.8rem;
    font-size: 0.8rem;
    margin-right: 0;
}

.portal-compose-attachment-remove:hover,
.portal-compose-attachment-remove:focus {
    border-color: rgba(var(--portal-brand-rgb), 0.45);
    color: var(--portal-brand);
    outline: none;
}

.portal-compose-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.6rem;
    margin-top: 0;
}

.portal-compose-actions .dxbl-btn {
    min-height: 1.9rem;
    padding: 0.25rem 0.65rem;
    font-size: 0.8rem;
}
.portal-dark .portal-compose-attachment-button {
    border-color: #474747;
    background: #1d1d1d;
    color: #e0e0e0;
}

.portal-dark .portal-compose-attachment-button:hover,
.portal-dark .portal-compose-attachment-button:focus {
    border-color: rgba(248, 113, 113, 0.45);
    background: rgba(185, 28, 28, 0.22);
}

.portal-dark .portal-compose-attachment-name,
.portal-dark .portal-compose-attachment-status {
    color: #bbf7d0;
}

.portal-dark .portal-compose-attachment-preview img {
    border-color: #384653;
    background-color: #27313a;
}

.portal-dark .portal-compose-attachment-remove {
    border-color: #475569;
    background: rgba(15, 23, 42, 0.92);
    color: #e2e8f0;
}

.portal-dark .portal-compose-attachment-preview figcaption {
    color: #cbd5e1;
}

.portal-map-placeholder {
    min-height: 220px;
    border: 1px dashed #c6ccd3;
    border-radius: var(--portal-radius);
    background: linear-gradient(180deg, #f8fafc 0%, #eef2f7 100%);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    padding: 1.5rem;
    text-align: center;
}

.portal-simple-list {
    padding-left: 1.2rem;
}

.portal-ro-history-list {
    display: grid;
    gap: 1rem;
}

.portal-ro-history-group {
    border: 1px solid var(--portal-border);
    border-radius: var(--portal-radius);
    overflow: hidden;
    background: var(--portal-surface);
}

.portal-ro-history-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.85rem 1rem;
    border-bottom: 1px solid var(--portal-border);
    background: var(--portal-surface-subtle);
}

.portal-ro-history-header.is-expandable {
    cursor: pointer;
    transition: background-color 120ms ease;
}

.portal-ro-history-header.is-expandable:hover,
.portal-ro-history-header.is-expandable:focus-within {
    background: color-mix(in srgb, var(--portal-surface-subtle) 92%, var(--portal-muted));
}

.portal-ro-history-heading {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-width: 0;
}

.portal-ro-history-heading > div {
    min-width: 0;
}

.portal-ro-history-header h2 {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 700;
}

.portal-ro-history-title {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.portal-ro-history-created-date {
    display: block;
    margin-top: 0.2rem;
    color: var(--portal-muted);
    font-size: 0.82rem;
}

.portal-ro-history-heading .portal-ro-vehicle-detail {
    margin-top: 0.2rem;
}

.portal-ro-status-badge {
    --status-color: var(--portal-ro-status-gray);
    padding: 0.25rem 0.55rem;
    border: 1px solid var(--status-border, var(--status-color));
    background: var(--status-color);
    color: var(--status-text, #fff);
    font-size: 0.85rem;
    line-height: 1.2;
    vertical-align: middle;
    white-space: nowrap;
    box-shadow: none;
    text-shadow: none;
}

.portal-ro-status-badge--detail {
    padding: 0.35rem 0.7rem;
    font-size: 0.9rem;
}

/* Match Home's current-status palette and flat fill in both themes. */
.portal-ro-status-badge--working {
    --status-color: var(--portal-ro-status-blue);
}

.portal-ro-status-badge--ready {
    --status-color: var(--portal-ro-status-green);
}

.portal-ro-status-badge--waiting {
    --status-color: var(--portal-ro-status-amber);
}

.portal-ro-status-badge--needs-approval {
    --status-color: var(--portal-ro-status-red);
}

.portal-ro-status-badge--pending {
    --status-color: #fff;
    --status-text: #000;
    --status-border: #000;
}

.portal-ro-status-badge--picked-up,
.portal-ro-status-badge--finalized {
    --status-color: var(--portal-ro-status-gray);
}

.portal-ro-history-link {
    color: inherit;
    text-decoration: none;
}

.portal-ro-history-link:hover,
.portal-ro-history-link:focus {
    color: #006bb7;
    text-decoration: underline;
}

.portal-ro-history-header span:not(.portal-ro-status-badge) {
    color: var(--portal-muted);
}

.portal-ro-history-header span:not(.portal-ro-status-badge, .portal-vehicle-thumbnail-placeholder-icon) {
    font-size: 0.85rem;
}

.portal-ro-history-actions,
.portal-ro-detail-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 0.5rem;
}

.portal-ro-detail-actions {
    justify-content: flex-start;
}

.portal-ro-history-toggle-actions {
    align-items: center;
    flex-wrap: nowrap;
    margin-left: auto;
}

.portal-view-messages-icon {
    width: 1em;
    height: 1em;
    margin: 0 0.125rem 0 -0.125rem;
    color: inherit !important;
    font-size: 1em;
    vertical-align: -0.125em;
}

.portal-view-messages-icon.dx-icon::before {
    color: inherit !important;
    font-weight: 400;
    -webkit-text-stroke: 0.1px currentColor;
}

body.portal-dark .portal-view-messages {
    --bs-btn-color: var(--portal-header-text);
    --bs-btn-border-color: var(--portal-header-text);
    --bs-btn-hover-color: var(--portal-surface);
    --bs-btn-hover-bg: var(--portal-header-text);
    --bs-btn-hover-border-color: var(--portal-header-text);
    --bs-btn-focus-shadow-rgb: 174, 184, 194;
    --bs-btn-active-color: var(--portal-surface);
    --bs-btn-active-bg: var(--portal-header-text);
    --bs-btn-active-border-color: var(--portal-header-text);
    --bs-btn-disabled-color: var(--portal-header-text);
    --bs-btn-disabled-bg: transparent;
    --bs-btn-disabled-border-color: var(--portal-header-text);
}

.portal-ro-pending-approval-notification,
.portal-ro-history-header .portal-ro-pending-approval-notification span {
    color: #fff;
}

.portal-ro-pending-approval-notification {
    flex: 0 0 auto;
}

.portal-ro-history-caret,
.portal-ro-history-caret-spacer {
    width: 2rem;
    height: 2rem;
    flex: 0 0 auto;
}

.portal-ro-history-caret {
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: var(--portal-muted-strong);
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.portal-ro-history-caret:hover,
.portal-ro-history-caret:focus-visible {
    background: var(--portal-surface);
    color: var(--portal-text);
}

.portal-ro-history-caret:focus-visible {
    outline: 2px solid var(--portal-focus);
    outline-offset: 2px;
}

.portal-ro-history-caret span {
    width: 0.55rem;
    height: 0.55rem;
    border: solid currentColor;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
    transition: transform 120ms ease;
}

.portal-ro-history-header.is-expanded .portal-ro-history-caret span {
    transform: rotate(-135deg);
}

.portal-card.portal-ro-detail-card,
.portal-card.portal-vehicle-detail-card {
    padding-top: 0.9rem;
}

.portal-ro-detail-info-strip {
    display: grid;
    grid-template-columns:
        minmax(6.5rem, 0.8fr)
        minmax(6.5rem, 0.8fr)
        minmax(7.5rem, 0.9fr)
        minmax(8rem, 1.2fr)
        minmax(5rem, 0.6fr)
        minmax(7.5rem, 0.9fr)
        minmax(7rem, 0.8fr)
        minmax(10rem, 1.15fr);
    align-items: stretch;
}

.portal-ro-detail-info-item {
    display: flex;
    min-width: 0;
    flex-direction: column;
    justify-content: center;
    gap: 0.25rem;
    padding: 0.15rem 1rem;
    border-left: 1px solid var(--portal-border-soft);
}

.portal-ro-detail-info-item:first-child {
    border-left: 0;
    padding-left: 0;
}

.portal-ro-detail-info-item > span {
    color: var(--portal-muted);
    font-size: 0.78rem;
    font-weight: 500;
}

.portal-ro-detail-info-item > strong {
    overflow-wrap: anywhere;
    color: var(--portal-heading);
    font-size: 0.9rem;
    line-height: 1.25;
}

.portal-ro-detail-info-item--activity > strong {
    white-space: nowrap;
}

.portal-ro-detail-info-strip > .portal-ro-detail-info-item--full {
    grid-column: 1 / -1;
    margin-top: 0.55rem;
    padding-left: 0;
    padding-top: 0.65rem;
    border-top: 1px solid var(--portal-border-soft);
    border-left: 0;
}

.portal-ro-approval-group {
    margin-top: 0.75rem;
}

.portal-ro-approval-header {
    border-bottom: 0;
    background: var(--portal-surface);
}

.portal-ro-approval-header.is-expanded {
    border-bottom: 1px solid var(--portal-border);
}

.portal-ro-approval-header h3 {
    margin: 0;
    font-size: 1rem;
    font-weight: 700;
}

.portal-ro-approval-table-wrap {
    min-width: 0;
    margin: 0;
}

.portal-ro-approval-table {
    width: 100%;
    table-layout: auto;
}

.vehicle-detail-summary {
    display: grid;
    gap: 0.9rem;
}

.portal-detail-back {
    justify-self: start;
}

.portal-detail-back::before {
    content: "\2039";
    margin-right: 0.35rem;
    font-size: 1.15em;
    line-height: 0;
}

.vehicle-detail-info-strip {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: start;
    gap: 0.9rem;
    padding: 1rem 0.9rem;
    border: 1px solid var(--portal-border);
    border-radius: var(--portal-radius);
    background: var(--portal-surface);
    box-shadow: var(--portal-shadow);
}

.vehicle-detail-visual {
    display: grid;
    grid-template-columns: 4.25rem;
    justify-items: center;
    gap: 1rem;
}

.vehicle-detail-truck-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 4.25rem;
    height: 4.25rem;
    color: var(--portal-brand);
}

.vehicle-detail-truck-icon > span {
    width: 4.25rem;
    height: 4.25rem;
    background-color: currentColor;
    -webkit-mask: url("images/itp-truck-icon-vector.svg") center / 155% no-repeat;
    mask: url("images/itp-truck-icon-vector.svg") center / 155% no-repeat;
}

.portal-ro-detail-wrench-icon > span {
    -webkit-mask: url("images/wrench-solid.svg") center / contain no-repeat;
    mask: url("images/wrench-solid.svg") center / contain no-repeat;
    transform: scaleX(-1);
}

.vehicle-detail-info-content {
    display: grid;
    min-width: 0;
    gap: 1.75rem;
}

.vehicle-detail-info-heading {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.portal-ro-detail-heading .portal-view-messages {
    margin-left: auto;
    flex: 0 0 auto;
}

.vehicle-detail-info-heading > .portal-card-title {
    font-size: 1.65rem;
    line-height: 1.2;
    margin: 0;
}

.vehicle-detail-info-items {
    display: grid;
    grid-template-columns:
        minmax(7rem, 0.85fr)
        minmax(12rem, 1.45fr)
        minmax(5rem, 0.6fr)
        minmax(6rem, 0.7fr)
        minmax(10rem, 1.25fr)
        minmax(8rem, 1fr);
    align-items: stretch;
}

.vehicle-detail-info-item {
    display: flex;
    min-width: 0;
    flex-direction: column;
    justify-content: center;
    gap: 0.25rem;
    padding: 0.15rem 1rem;
    border-left: 1px solid var(--portal-border-soft);
}

.vehicle-detail-info-item:first-child {
    border-left: 0;
    padding-left: 0;
}

.vehicle-detail-info-item > span {
    color: var(--portal-muted);
    font-size: 0.78rem;
    font-weight: 500;
}

.vehicle-detail-info-item > strong {
    overflow-wrap: anywhere;
    color: var(--portal-heading);
    font-size: 0.9rem;
    line-height: 1.25;
}

.portal-dark .vehicle-detail-truck-icon {
    color: var(--portal-muted);
}

.portal-ro-empty-message {
    margin: 0.35rem 0 0;
    line-height: 1.45;
}

.portal-ro-photo-strip {
    margin-top: 1rem !important;
    padding-top: 0.85rem;
}

.portal-ro-photo-strip > .portal-ro-empty-message {
    max-width: 42rem;
}

.portal-repair-search {
    position: relative;
    margin-bottom: 1rem;
}

.portal-repair-search .form-control {
    padding: 0.6rem 2.6rem;
    font-size: 0.9rem;
}

.portal-repair-search .form-control::-webkit-search-cancel-button {
    -webkit-appearance: none;
}

.portal-repair-search-icon {
    position: absolute;
    top: 50%;
    left: 0.85rem;
    width: 1rem;
    height: 1rem;
    transform: translateY(-50%);
    color: var(--portal-muted);
    pointer-events: none;
}

.portal-repair-search-clear {
    position: absolute;
    inset: 0.25rem 0.25rem 0.25rem auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    padding: 0;
    border: 0;
    border-radius: var(--portal-radius-sm);
    background: transparent;
    color: var(--portal-muted);
}

.portal-repair-search-clear .portal-dx-icon {
    margin: 0;
    font-size: 1rem;
}

.portal-repair-search-clear:hover {
    background: var(--portal-surface-subtle);
    color: var(--portal-heading);
}

.portal-repair-search-clear:focus-visible {
    outline: 2px solid var(--portal-focus);
    outline-offset: 1px;
}

.portal-ro-filter-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
    border-bottom: 1px solid var(--bs-border-color);
}

.portal-ro-filter-tab {
    border: 0;
    border-bottom: 2px solid transparent;
    background: transparent;
    color: var(--bs-secondary-color);
    padding: 0.65rem 0.75rem;
    font: inherit;
    font-weight: 600;
}

.portal-ro-filter-tab:hover,
.portal-ro-filter-tab:focus {
    color: var(--bs-primary);
}

.portal-ro-filter-tab.is-active {
    border-bottom-color: var(--bs-primary);
    color: var(--bs-primary);
}

.portal-ro-history-table th,
.portal-ro-history-table td {
    padding: 0.75rem 1rem;
    vertical-align: middle;
}

.portal-ro-history-table:not(.portal-pending-approval-table) :is(th, td):nth-child(-n + 4) {
    white-space: nowrap;
}

.portal-ro-history-table .portal-ro-requested-at {
    min-width: 12rem;
    white-space: nowrap;
}

.portal-ro-history-table .portal-approval-note-text {
    display: -webkit-box;
    overflow: hidden;
    overflow-wrap: anywhere;
    white-space: normal;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    line-clamp: 3;
}

.portal-vehicle-list-header {
    border-bottom: 0;
}

.portal-vehicle-list-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem 2rem;
    padding: 0 1rem 0.85rem;
}

.portal-vehicle-list-meta span {
    display: inline-flex;
    gap: 0.5rem;
    min-width: max-content;
}

.portal-vehicle-list-meta strong {
    color: #6c757d;
}

.vehicle-photo-type-strip {
    display: grid;
    gap: 0.85rem;
}

.vehicle-detail-photo-strip {
    padding: 0.85rem 0.85rem 0.55rem;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    background: #fff;
    box-shadow: var(--portal-shadow);
}

.vehicle-photo-type-strip-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 1rem;
}

.vehicle-photo-type-strip-header span {
    color: #6c757d;
    font-weight: 700;
}

.vehicle-photo-type-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 0.75rem;
}

.vehicle-photo-type-option {
    display: grid;
    grid-template-columns: 64px minmax(0, 1fr);
    grid-template-areas:
        "thumb copy"
        "thumb code";
    gap: 0.35rem 0.65rem;
    min-height: 82px;
    padding: 0.65rem;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    background: #fff;
    color: inherit;
    text-align: left;
}

.vehicle-photo-type-option:hover,
.vehicle-photo-type-option:focus-visible,
.vehicle-photo-type-option.is-selected {
    border-color: var(--portal-button-border);
    box-shadow: 0 0 0 0.15rem rgba(var(--portal-button-focus-rgb), 0.12);
    outline: none;
}

.vehicle-photo-type-thumb {
    grid-area: thumb;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    overflow: hidden;
    border: 1px solid #cfd6dd;
    border-radius: 6px;
    background: #f1f3f5;
    color: #495057;
    font-size: 0.72rem;
    font-weight: 700;
    text-align: center;
}

.vehicle-photo-type-thumb img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.vehicle-photo-type-copy {
    grid-area: copy;
    display: grid;
    gap: 0.15rem;
    min-width: 0;
}

.vehicle-photo-type-copy strong,
.vehicle-photo-type-copy span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.vehicle-photo-type-copy span,
.vehicle-photo-type-code {
    color: #6c757d;
    font-size: 0.82rem;
}

.vehicle-photo-type-code {
    grid-area: code;
    align-self: end;
    font-weight: 700;
}

.vehicle-ro-photo-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(120px, 1fr));
    gap: 0.75rem;
}

.vehicle-ro-photo-layout {
    position: relative;
    display: grid;
    gap: 0.75rem;
}

.vehicle-ro-photo-scroll {
    position: relative;
    min-width: 0;
    overflow: hidden;
}

.vehicle-ro-photo-selector {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto auto;
    align-items: center;
    gap: 0.5rem;
    min-height: 0;
}

.vehicle-ro-photo-selector::after {
    position: absolute;
    right: 0;
    bottom: -0.375rem;
    left: 0;
    border-bottom: 1px solid var(--portal-border-soft);
    content: "";
    pointer-events: none;
}

.vehicle-ro-photo-selector-list {
    display: flex;
    gap: 0.6rem;
    min-width: 0;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    margin: -0.25rem 0 -0.9rem;
    padding: 0.6rem 1.25rem 1.25rem;
    scroll-padding-inline: 1.25rem;
    scroll-behavior: smooth;
    scroll-snap-type: x proximity;
    scrollbar-width: thin;
}

.vehicle-ro-photo-selector-list::-webkit-scrollbar {
    height: 0.35rem;
}

.vehicle-ro-photo-selector-list::-webkit-scrollbar-thumb {
    border-radius: 999px;
    background: var(--portal-border);
}

.vehicle-ro-photo-selector-item {
    display: grid;
    gap: 0.1rem;
    flex: 0 0 auto;
    min-width: 7.5rem;
    max-width: 11rem;
    padding: 0.55rem 0.75rem;
    border: 1px solid var(--portal-border-soft);
    border-radius: 0.35rem;
    background: var(--portal-surface-raised);
    color: var(--portal-muted-strong);
    cursor: pointer;
    font: inherit;
    text-align: left;
    scroll-snap-align: nearest;
    box-shadow: 0 0.2rem 0.5rem rgba(0, 0, 0, 0.06);
    transition: border-color 150ms ease, background-color 150ms ease, box-shadow 150ms ease, color 150ms ease, transform 150ms ease;
}

.vehicle-ro-photo-selector-item span,
.vehicle-ro-photo-selector-item small {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.vehicle-ro-photo-selector-item span {
    color: inherit;
    font-size: 0.86rem;
    font-weight: 800;
}

.vehicle-ro-photo-selector-item small {
    color: var(--portal-muted);
    font-size: 0.72rem;
    font-weight: 700;
}

.vehicle-ro-photo-selector-item:hover,
.vehicle-ro-photo-selector-item:focus-visible {
    border-color: rgba(var(--portal-brand-rgb), 0.55);
    background: var(--portal-surface-subtle);
    color: var(--portal-heading);
    box-shadow: 0 0 0 2px rgba(var(--portal-brand-rgb), 0.12), 0 0.45rem 1rem rgba(0, 0, 0, 0.1);
    transform: translateY(-1px);
    outline: none;
}

.vehicle-ro-photo-selector-item.is-selected {
    border-color: var(--portal-brand);
    background: var(--portal-brand);
    color: #fff;
    box-shadow: 0 0 0 2px rgba(var(--portal-brand-rgb), 0.18), 0 0.45rem 1rem rgba(var(--portal-brand-rgb), 0.22);
}

.vehicle-ro-photo-selector-item.is-selected small {
    color: rgba(255, 255, 255, 0.82);
}

.vehicle-ro-photo-selector-nav {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    border: 1px solid var(--portal-border);
    border-radius: 0.35rem;
    background: var(--portal-surface);
    color: var(--portal-text);
}

.vehicle-ro-photo-selector-nav:hover:not(:disabled),
.vehicle-ro-photo-selector-nav:focus-visible:not(:disabled) {
    border-color: var(--portal-brand);
    background: var(--portal-surface-subtle);
    outline: none;
}

.vehicle-ro-photo-selector-nav:disabled {
    cursor: default;
    opacity: 0.45;
}

.vehicle-ro-photo-selector-nav svg {
    width: 1rem;
    height: 1rem;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 2;
}

.vehicle-ro-photo-selector-position {
    color: var(--portal-muted-strong);
    font-size: 0.78rem;
    font-weight: 800;
    white-space: nowrap;
}

@media (prefers-reduced-motion: reduce) {
    .vehicle-ro-photo-selector-list {
        scroll-behavior: auto;
    }

    .vehicle-ro-photo-section.is-transition-source .vehicle-ro-photo-section-content,
    .vehicle-ro-photo-section.is-transition-target .vehicle-ro-photo-section-content {
        animation: none;
    }
}

.vehicle-ro-carousel {
    display: grid;
    gap: 0.75rem;
}

.vehicle-ro-photo-carousel {
    width: 100%;
}

.vehicle-ro-photo-carousel .dxbl-carousel-arrow-button {
    top: auto !important;
    bottom: 0.35rem;
}

.vehicle-ro-photo-carousel .dxbl-carousel-arrow-button.dxbl-left-arrow {
    left: 0;
}

.vehicle-ro-photo-carousel .dxbl-carousel-arrow-button.dxbl-right-arrow {
    right: 0;
}

.vehicle-ro-photo-fixed-arrow {
    position: absolute;
    bottom: 0.55rem;
    z-index: 3;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    padding: 0.375rem;
    border: 0;
    border-radius: 0.25rem;
    background: var(--portal-surface);
    color: var(--portal-text);
    cursor: pointer;
    opacity: 0.8;
}

.vehicle-ro-photo-fixed-arrow.is-left {
    left: 0.85rem;
}

.vehicle-ro-photo-fixed-arrow.is-right {
    right: 0.85rem;
}

.vehicle-ro-photo-fixed-arrow:hover,
.vehicle-ro-photo-fixed-arrow:focus-visible {
    color: var(--portal-brand);
    opacity: 1;
    outline: none;
}

.vehicle-ro-photo-fixed-arrow svg {
    width: 1.25rem;
    height: 1.25rem;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 2;
}

.dxbl-carousel .dxbl-carousel-substrate-button {
    width: 3%;
}

.vehicle-ro-carousel-controls {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.75rem;
}

.vehicle-ro-carousel-controls span {
    color: #6c757d;
    font-size: 0.85rem;
    font-weight: 700;
    min-width: 4rem;
    text-align: center;
}

.vehicle-ro-photo-section {
    display: grid;
    gap: 0.75rem;
    padding: 0.85rem 0.85rem 0.5rem;
    border-radius: 8px;
    background: #fff;
    box-shadow: var(--portal-shadow);
}

.vehicle-ro-photo-section.is-transition-source {
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
}

.vehicle-ro-photo-section.is-transition-target {
    position: relative;
    z-index: 1;
    border-color: transparent !important;
    background: transparent !important;
    box-shadow: none;
}

.vehicle-ro-photo-section-content {
    display: grid;
    gap: 0.75rem;
}

.vehicle-ro-photo-section.is-transition-next.is-transition-source .vehicle-ro-photo-section-content {
    animation: vehicle-ro-content-exit-up 220ms ease both;
}

.vehicle-ro-photo-section.is-transition-next.is-transition-target .vehicle-ro-photo-section-content {
    animation: vehicle-ro-content-enter-up 220ms ease both;
}

.vehicle-ro-photo-section.is-transition-previous.is-transition-source .vehicle-ro-photo-section-content {
    animation: vehicle-ro-content-exit-down 220ms ease both;
}

.vehicle-ro-photo-section.is-transition-previous.is-transition-target .vehicle-ro-photo-section-content {
    animation: vehicle-ro-content-enter-down 220ms ease both;
}

@keyframes vehicle-ro-content-exit-up {
    to { transform: translateY(-100%); }
}

@keyframes vehicle-ro-content-enter-up {
    from { transform: translateY(100%); }
}

@keyframes vehicle-ro-content-exit-down {
    to { transform: translateY(100%); }
}

@keyframes vehicle-ro-content-enter-down {
    from { transform: translateY(-100%); }
}

.vehicle-ro-photo-section-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 1rem;
}

.vehicle-ro-photo-section-header h3 {
    margin: 0;
    font-size: 1rem;
}

.vehicle-ro-photo-section-header span {
    color: #6c757d;
    font-size: 0.85rem;
    font-weight: 700;
}

.vehicle-ro-photo-card {
    display: grid;
    gap: 0.45rem;
    min-width: 0;
    margin: 0;
}

.vehicle-ro-photo-button {
    display: block;
    width: 100%;
    aspect-ratio: 4 / 3;
    padding: 0;
    border: 0;
    border-radius: 6px;
    background: transparent;
    overflow: hidden;
}

.vehicle-ro-photo-card img {
    display: block;
    width: 100%;
    height: 100%;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    background: #f8f9fa;
    object-fit: cover;
}

.vehicle-ro-photo-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    aspect-ratio: 4 / 3;
    border: 1px dashed #c6ccd3;
    border-radius: 6px;
    background: #f8f9fa;
    color: #6c757d;
    font-size: 0.78rem;
    font-weight: 700;
    text-align: center;
}

.vehicle-ro-photo-card figcaption {
    display: grid;
    gap: 0.1rem;
    min-width: 0;
    padding-bottom: 1.33rem;
}

.vehicle-ro-photo-card figcaption strong,
.vehicle-ro-photo-card figcaption span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.vehicle-ro-photo-card figcaption span {
    color: #6c757d;
    font-size: 0.82rem;
}

.vehicle-ro-photo-card:not(.has-photo) {
    opacity: 0.72;
}

.vehicle-photo-detail-popup,
.vehicle-photo-detail-popup .dxbl-popup,
.vehicle-photo-detail-popup .dxbl-popup-root,
.vehicle-photo-detail-popup .dxbl-modal,
.vehicle-photo-detail-popup .modal-content {
    background: #fff !important;
    color: #212529 !important;
    border-color: #dee2e6 !important;
}

.vehicle-photo-detail-popup .dxbl-popup-header,
.vehicle-photo-detail-popup .dxbl-modal-header,
.vehicle-photo-detail-popup .modal-header {
    background: #f8f9fa !important;
    color: #212529 !important;
    border-color: #dee2e6 !important;
}

.vehicle-photo-detail-popup .dxbl-popup-body,
.vehicle-photo-detail-popup .dxbl-modal-body,
.vehicle-photo-detail-popup .modal-body {
    background: #fff !important;
    color: #212529 !important;
    padding: 0 !important;
}

.vehicle-photo-detail-popup .dxbl-popup-close,
.vehicle-photo-detail-popup .dxbl-btn,
.vehicle-photo-detail-popup button {
    color: #495057 !important;
}

.vehicle-photo-detail {
    min-height: min(76vh, 720px);
    background: #fff;
}

.vehicle-photo-detail-carousel,
.vehicle-photo-detail-carousel .dxbl-carousel,
.vehicle-photo-detail-carousel .dxbl-carousel-container,
.vehicle-photo-detail-carousel .dxbl-carousel-items,
.vehicle-photo-detail-carousel .dxbl-carousel-item {
    height: min(76vh, 720px) !important;
    min-height: min(76vh, 720px);
    background: #fff !important;
    color: #212529 !important;
}

.vehicle-photo-detail-stage {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: calc(min(76vh, 720px) - 3rem);
    min-height: 320px;
    padding: 1rem;
    background: #fff;
}

.vehicle-photo-detail-image {
    display: block;
    width: 100%;
    height: 100%;
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.vehicle-photo-detail-meta {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 3rem;
    padding: 0.5rem 1rem 0.85rem;
    background: #fff;
    color: #495057;
    text-align: center;
}

.vehicle-photo-detail-meta strong {
    color: #212529;
}

.vehicle-photo-detail-carousel .dxbl-carousel-nav-button,
.vehicle-photo-detail-carousel .dxbl-carousel-btn,
.vehicle-photo-detail-carousel .dxbl-carousel-indicator,
.vehicle-photo-detail-carousel .dxbl-carousel-indicators button {
    color: #495057 !important;
}

body.portal-dark .vehicle-photo-detail-popup,
body.portal-dark .vehicle-photo-detail-popup .dxbl-popup,
body.portal-dark .vehicle-photo-detail-popup .dxbl-popup-root,
body.portal-dark .vehicle-photo-detail-popup .dxbl-modal,
body.portal-dark .vehicle-photo-detail-popup .modal-content {
    background: #0f1418 !important;
    color: #e7edf2 !important;
    border-color: #2d3841 !important;
}

body.portal-dark .vehicle-photo-detail-popup .dxbl-popup-header,
body.portal-dark .vehicle-photo-detail-popup .dxbl-modal-header,
body.portal-dark .vehicle-photo-detail-popup .modal-header {
    background: #11171c !important;
    color: #f8fafc !important;
    border-color: #2d3841 !important;
}

body.portal-dark .vehicle-photo-detail-popup .dxbl-popup-body,
body.portal-dark .vehicle-photo-detail-popup .dxbl-modal-body,
body.portal-dark .vehicle-photo-detail-popup .modal-body {
    background: #0f1418 !important;
    color: #e7edf2 !important;
}

body.portal-dark .vehicle-photo-detail-popup .dxbl-popup-close,
body.portal-dark .vehicle-photo-detail-popup .dxbl-btn,
body.portal-dark .vehicle-photo-detail-popup button {
    color: #e7edf2 !important;
}

body.portal-dark .vehicle-photo-detail,
body.portal-dark .vehicle-photo-detail-stage,
body.portal-dark .vehicle-photo-detail-meta,
body.portal-dark .vehicle-photo-detail-carousel,
body.portal-dark .vehicle-photo-detail-carousel .dxbl-carousel,
body.portal-dark .vehicle-photo-detail-carousel .dxbl-carousel-container,
body.portal-dark .vehicle-photo-detail-carousel .dxbl-carousel-items,
body.portal-dark .vehicle-photo-detail-carousel .dxbl-carousel-item {
    background: #0f1418 !important;
    color: #e7edf2 !important;
}

body.portal-dark .vehicle-photo-detail-meta {
    color: #cbd5df;
}

body.portal-dark .vehicle-photo-detail-meta strong {
    color: #f8fafc;
}

body.portal-dark .vehicle-photo-detail-carousel .dxbl-carousel-nav-button,
body.portal-dark .vehicle-photo-detail-carousel .dxbl-carousel-btn,
body.portal-dark .vehicle-photo-detail-carousel .dxbl-carousel-indicator,
body.portal-dark .vehicle-photo-detail-carousel .dxbl-carousel-indicators button {
    color: #e7edf2 !important;
}

.portal-document-page {
    max-width: 1180px;
    --portal-document-sticky-top: 0;
    --portal-document-anchor-offset: 1rem;
}

.portal-document-layout {
    display: grid;
    grid-template-columns: minmax(8rem, 12rem) minmax(0, 1fr);
    gap: 1rem;
    align-items: start;
}

.portal-document-timeline {
    position: sticky;
    top: calc(var(--portal-document-sticky-top) + 1rem);
    display: grid;
    gap: 0.35rem;
    max-height: calc(100dvh - 8rem);
    overflow-y: auto;
    padding-right: 0.25rem;
}

.portal-document-timeline a {
    display: block;
    border-left: 3px solid var(--portal-border);
    padding: 0.35rem 0.6rem;
    color: var(--portal-muted-strong);
    font-size: 0.85rem;
    font-weight: 700;
    text-decoration: none;
}

.portal-document-timeline a:hover,
.portal-document-timeline a:focus {
    border-left-color: var(--portal-brand);
    color: var(--portal-heading);
    background: var(--portal-surface-subtle);
    outline: none;
}

.portal-document-list {
    display: grid;
    gap: 1rem;
    min-width: 0;
}

.portal-document-month {
    min-width: 0;
    scroll-margin-top: var(--portal-document-anchor-offset);
}

.portal-document-month-header {
    position: sticky;
    top: var(--portal-document-sticky-top);
    z-index: 1;
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.7rem 0.85rem;
    border: 1px solid var(--portal-border);
    border-radius: var(--portal-radius) var(--portal-radius) 0 0;
    background: var(--portal-surface-subtle);
}

.portal-document-month-header h2 {
    margin: 0;
    font-size: 1rem;
}

.portal-document-month-header span {
    color: var(--portal-muted);
    font-size: 0.85rem;
    font-weight: 700;
}

.portal-document-items {
    display: grid;
    border: 1px solid var(--portal-border);
    border-top: 0;
    border-radius: 0 0 var(--portal-radius) var(--portal-radius);
    overflow: hidden;
}

.portal-document-items-standalone {
    border: 1px solid var(--portal-border);
    border-radius: var(--portal-radius);
    box-shadow: none;
}

.portal-document-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 0.75rem;
    padding: 0.6rem 0.75rem;
    background: var(--portal-surface);
}

.portal-document-item + .portal-document-item {
    border-top: 1px solid var(--portal-border);
}

.portal-document-open {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr) auto;
    align-items: center;
    gap: 0.75rem;
    min-width: 0;
    width: 100%;
    border: 0;
    background: transparent;
    color: inherit;
    text-align: left;
}

.portal-document-open:not(:disabled):hover,
.portal-document-open:not(:disabled):focus-visible {
    outline: none;
}

.portal-document-open:not(:disabled):hover .portal-document-main strong,
.portal-document-open:not(:disabled):focus-visible .portal-document-main strong {
    color: #006bb7;
    text-decoration: underline;
}

.portal-document-open:disabled {
    cursor: not-allowed;
    opacity: 0.72;
}

.portal-document-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: var(--portal-radius-sm);
    background: var(--portal-brand);
    color: #fff;
    font-size: 0.72rem;
    font-weight: 800;
}

.portal-document-main,
.portal-document-meta {
    display: grid;
    gap: 0.2rem;
    min-width: 0;
}

.portal-document-main strong,
.portal-document-main span,
.portal-document-meta span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.portal-document-main strong {
    font-size: 0.98rem;
}

.portal-document-main span,
.portal-document-meta {
    color: var(--portal-muted);
    font-size: 0.84rem;
}

.portal-document-meta {
    display: grid;
    grid-template-columns: 5.5rem 5.25rem;
    align-items: center;
    justify-content: flex-end;
    column-gap: 3rem;
    text-align: right;
}

.portal-document-amount {
    color: inherit;
    display: block;
    font-size: 0.98rem;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    text-align: left;
    white-space: nowrap;
}

.portal-document-meta-details {
    display: grid;
    gap: 0.2rem;
    min-width: 0;
}

.portal-document-download {
    white-space: nowrap;
}

.portal-pending-approval-table {
    table-layout: auto;
}

.portal-pending-approval-notes {
    overflow-wrap: anywhere;
}

.portal-pending-approval-review {
    text-align: center;
    white-space: nowrap;
}

.portal-pending-approval-row > td {
    border-top-color: rgba(var(--portal-brand-rgb), 0.4);
    border-bottom-color: rgba(var(--portal-brand-rgb), 0.4);
    background-color: rgba(var(--portal-brand-rgb), 0.055);
}

.portal-pending-approval-row > td:first-child {
    box-shadow: inset 3px 0 0 var(--portal-brand);
}

.portal-auth-shell {
    position: relative;
    isolation: isolate;
    overflow-x: hidden;
    min-height: 100vh;
    background:
        radial-gradient(ellipse 50% 32% at 50% 0%, #36404a 0%, #161c22 54%, #090d11 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: clamp(4.5rem, 9vh, 7rem) clamp(1.5rem, 5vw, 5rem);
}

.portal-auth-shell.portal-account-deletion {
    padding-block: 1.5rem;
}

.portal-auth-shell::before {
    position: fixed;
    z-index: 1;
    inset: 0;
    background:
        radial-gradient(ellipse 58% 42% at 50% -8%, rgba(255, 255, 255, 0.16) 0%, rgba(10, 14, 18, 0.23) 48%, transparent 74%),
        linear-gradient(180deg, rgba(4, 8, 12, 0.61) 0%, rgba(4, 8, 12, 0.73) 58%, rgba(3, 6, 9, 0.83) 100%);
    content: "";
    pointer-events: none;
}

.portal-auth-background {
    position: fixed;
    z-index: 0;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.portal-auth-motion-toggle {
    position: absolute;
    z-index: 3;
    top: 1rem;
    right: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 999px;
    background: rgba(5, 9, 13, 0.44);
    color: rgba(255, 255, 255, 0.82);
    padding: 0.4rem 0.72rem;
    font-size: 0.76rem;
    font-weight: 600;
    backdrop-filter: blur(8px);
    transition: background-color 160ms ease, color 160ms ease;
}

.portal-auth-motion-toggle:hover,
.portal-auth-motion-toggle:focus-visible {
    background: rgba(5, 9, 13, 0.78);
    color: #fff;
}

.portal-auth-motion-toggle:focus-visible {
    outline: 2px solid #fff;
    outline-offset: 3px;
}

.portal-auth-motion-toggle[hidden] {
    display: none;
}

.portal-auth-card {
    position: relative;
    z-index: 2;
    width: min(100%, 1120px);
    display: grid;
    grid-template-columns: minmax(250px, 0.82fr) minmax(340px, 1fr);
    align-items: center;
    gap: clamp(4rem, 10vw, 9rem);
}

@media (prefers-reduced-motion: reduce) {
    .portal-auth-background,
    .portal-auth-motion-toggle {
        display: none;
    }
}

.portal-auth-brand {
    color: #fff;
    display: grid;
    justify-items: start;
    gap: clamp(1.75rem, 4vh, 2.75rem);
    padding-bottom: 1.5rem;
}

.portal-auth-logo {
    width: min(100%, clamp(20rem, 32vw, 26rem));
    height: auto;
    margin-bottom: -2rem;
    object-fit: contain;
}

.portal-auth-brand h1 {
    display: grid;
    gap: 0.12rem;
    margin: 0;
    border-left: 4px solid #ed1b36;
    padding-left: 1rem;
    color: rgba(255, 255, 255, 0.94);
    font-size: clamp(1.25rem, 2vw, 1.55rem);
    font-weight: 400;
    line-height: 1.15;
    letter-spacing: -0.015em;
}

.portal-auth-panel {
    width: min(100%, 500px);
    justify-self: end;
    display: flex;
    flex-direction: column;
    gap: 1.35rem;
    color: #fff;
    transition: opacity 120ms ease;
}

.portal-auth-panel.is-navigating {
    opacity: 0.55;
    pointer-events: none;
}

@media (min-width: 861px) {
    .portal-auth-card {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 0;
    }

    .portal-auth-brand {
        justify-self: center;
    }

    .portal-auth-panel {
        grid-column: 3;
        justify-self: center;
    }

    .portal-account-deletion .portal-auth-panel {
        grid-column: 2 / -1;
    }
}

@media (prefers-reduced-motion: reduce) {
    .portal-auth-panel,
    .portal-auth-tab-indicator {
        transition: none;
    }
}

.portal-auth-tabs {
    position: relative;
    display: flex;
    align-items: flex-end;
    gap: clamp(1.5rem, 4vw, 2.5rem);
    min-height: 3.2rem;
}

.portal-auth-tab {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.35rem 0 0.8rem;
    text-decoration: none;
    color: rgba(255, 255, 255, 0.62);
    font-size: clamp(1.25rem, 2vw, 1.5rem);
    font-weight: 400;
    line-height: 1;
    letter-spacing: -0.015em;
    transition: color 180ms ease;
}

.portal-auth-tab:hover {
    color: #fff;
}

.portal-auth-tab.is-active {
    color: #fff;
}

.portal-auth-tab.is-active::after {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 3.25rem;
    height: 3px;
    border-radius: 999px;
    background: #ed1b36;
    content: "";
}

.portal-auth-tabs.is-enhanced .portal-auth-tab.is-active::after {
    display: none;
}

.portal-auth-tab-indicator {
    position: absolute;
    bottom: 0;
    left: 0;
    display: none;
    width: 3.25rem;
    height: 3px;
    border-radius: 999px;
    background: #ed1b36;
    pointer-events: none;
    transform: translateX(0);
    transition: transform 240ms cubic-bezier(0.22, 1, 0.36, 1);
}

.portal-auth-tabs.is-enhanced .portal-auth-tab-indicator {
    display: block;
}

.portal-auth-tab:focus-visible {
    border-radius: 2px;
    outline: 2px solid #fff;
    outline-offset: 4px;
}

.portal-auth-content {
    display: flex;
    flex-direction: column;
    gap: 1.35rem;
}

.portal-account-deletion .portal-auth-content {
    gap: 1rem;
}

.portal-auth-panel h2 {
    margin: 0;
    color: #fff;
    font-size: 1.35rem;
    font-weight: 500;
    line-height: 1.25;
}

.portal-auth-panel p {
    margin: 0;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.5;
}

.portal-auth-form {
    display: grid;
    gap: 1.15rem;
}

.portal-auth-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.15rem 1rem;
}

.portal-auth-field {
    display: grid;
    gap: 0.48rem;
}

.portal-auth-field--full {
    grid-column: 1 / -1;
}

.portal-auth-field label {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.88rem;
    font-weight: 500;
}

.portal-auth-field input {
    min-height: 4.25rem;
    border: 1px solid rgba(255, 255, 255, 0.48);
    border-radius: 8px;
    background-color: rgba(8, 12, 16, 0.18);
    color: #fff;
    padding: 1rem 1.15rem;
    font-size: 1rem;
    box-shadow: none;
    backdrop-filter: blur(5px);
    transition: background-color 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
}

.portal-auth-field input:hover {
    border-color: rgba(255, 255, 255, 0.72);
}

.portal-auth-field input:focus {
    border-color: #fff;
    background-color: rgba(8, 12, 16, 0.42);
    color: #fff;
    box-shadow: 0 0 0 0.2rem rgba(237, 27, 54, 0.24);
}

.portal-auth-field input::placeholder {
    color: rgba(255, 255, 255, 0.48);
}

.portal-auth-field input[type="email"] {
    padding-right: 3.25rem;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-opacity='.78' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='5' width='18' height='14' rx='2'/%3E%3Cpath d='m3 7 9 6 9-6'/%3E%3C/svg%3E");
    background-position: right 1.1rem center;
    background-repeat: no-repeat;
    background-size: 1.25rem;
}

.portal-auth-field input[type="password"] {
    padding-right: 3.25rem;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-opacity='.78' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='5' y='10' width='14' height='11' rx='2'/%3E%3Cpath d='M8 10V7a4 4 0 0 1 8 0v3'/%3E%3Cpath d='M12 14v3'/%3E%3C/svg%3E");
    background-position: right 1.1rem center;
    background-repeat: no-repeat;
    background-size: 1.25rem;
}

.portal-auth-field small {
    color: rgba(255, 255, 255, 0.62);
    font-size: 0.82rem;
}

.portal-auth-forgot-link {
    display: flex;
    justify-content: flex-end;
}

.portal-auth-field small a,
.portal-auth-field small a.link-secondary {
    border-bottom: 1px solid rgba(237, 27, 54, 0.78);
    color: rgba(255, 255, 255, 0.74);
    text-decoration: none;
    transition: color 160ms ease, border-color 160ms ease;
}

.portal-auth-field small a:hover,
.portal-auth-field small a:focus-visible {
    border-color: #ed1b36;
    color: #fff;
}

.portal-auth-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem;
    margin-top: 0.15rem;
}

.portal-auth-actions .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 4.15rem;
    border-radius: 8px;
    padding: 0.9rem 1.35rem;
    font-weight: 600;
    transition: background-color 100ms ease, border-color 100ms ease;
}

.portal-auth-actions .btn-danger {
    flex: 1 1 14rem;
    justify-content: space-between;
    border-color: #ed1b36;
    background: #d71934;
    box-shadow: none;
}

.portal-auth-actions .btn-danger::after {
    margin-left: 1.5rem;
    content: "\2192";
    font-size: 1.6rem;
    font-weight: 300;
    line-height: 0;
}

.portal-auth-actions .btn-danger:hover {
    border-color: #d71934;
    background: #c5162f;
}

.portal-auth-actions .btn-danger:focus,
.portal-auth-actions .btn-danger:active:focus {
    outline: none;
    box-shadow: none;
}

.portal-auth-actions .btn-danger:active,
.portal-auth-actions .btn-danger.is-loading,
.portal-auth-actions .btn-danger.is-loading:hover {
    border-color: #981023;
    background: #981023;
    box-shadow: none;
}

.portal-auth-actions .btn-danger:focus-visible {
    outline: 2px solid rgba(255, 255, 255, 0.9);
    outline-offset: 3px;
    box-shadow: none;
}

.portal-auth-actions .btn-danger.is-loading {
    cursor: wait;
    opacity: 1;
}

.portal-auth-actions .btn-danger.is-loading::after {
    width: 1.15rem;
    height: 1.15rem;
    border: 2px solid rgba(255, 255, 255, 0.42);
    border-top-color: #fff;
    border-radius: 50%;
    content: "";
    animation: portal-auth-button-spin 700ms linear infinite;
}

@keyframes portal-auth-button-spin {
    to {
        transform: rotate(360deg);
    }
}

.portal-auth-actions .btn-outline-secondary {
    border-color: rgba(255, 255, 255, 0.48);
    background: rgba(8, 12, 16, 0.18);
    color: rgba(255, 255, 255, 0.88);
}

.portal-auth-actions .btn-outline-secondary:hover {
    border-color: #fff;
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
}

.portal-auth-note {
    background: rgba(91, 64, 19, 0.62);
    border: 1px solid rgba(240, 201, 125, 0.46);
    color: #ffe0a6;
    border-radius: var(--portal-radius);
    padding: 0.9rem 1rem;
}

.portal-auth-panel .alert {
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    color: #fff;
    backdrop-filter: blur(8px);
}

.portal-auth-panel .alert-danger {
    background: rgba(116, 11, 27, 0.76);
}

.portal-auth-panel .alert-success {
    background: rgba(26, 92, 64, 0.76);
}

.portal-dark .content,
.portal-dark .portal-page {
    color: var(--portal-text);
}

.portal-dark a:not(.btn):not(.portal-link-card):not(.portal-metric-card) {
    color: var(--portal-muted);
}

.portal-dark a.portal-my-inland-website-link:not(.btn):not(.portal-link-card):not(.portal-metric-card),
.portal-dark a.portal-my-inland-website-link:not(.btn):not(.portal-link-card):not(.portal-metric-card):hover,
.portal-dark a.portal-my-inland-website-link:not(.btn):not(.portal-link-card):not(.portal-metric-card):focus {
    color: #fff;
}

.portal-dark .text-muted {
    color: #aeb8c2 !important;
}

.portal-dark .portal-card,
.portal-dark .portal-metric-card,
.portal-dark .portal-link-card,
.portal-dark .portal-conversation-pane,
.portal-dark .portal-thread-pane {
    background-color: var(--portal-surface);
    border-color: var(--portal-border);
    color: var(--portal-text);
    box-shadow: var(--portal-shadow);
}

.portal-dark .portal-account-select-card {
    background-color: var(--portal-surface);
    border-color: var(--portal-border);
    color: var(--portal-text);
}

.portal-dark .portal-account-select-card:hover,
.portal-dark .portal-account-select-card:focus-visible,
.portal-dark .portal-account-select-card--selected {
    border-color: var(--portal-button-border);
    box-shadow: 0 0 0 0.15rem rgba(var(--portal-button-focus-rgb), 0.18);
}

.portal-dark .portal-account-select-card span,
.portal-dark .portal-account-select-card small {
    color: var(--portal-muted);
}

.portal-dark .portal-account-select-card .portal-account-select-notification,
.portal-dark .portal-account-select-card .portal-account-select-notification span {
    color: #fff;
}

.portal-dark .portal-hero-card {
    background: linear-gradient(180deg, #1b2228 0%, #141a1f 100%);
}

.portal-dark .portal-metric-card:hover,
.portal-dark .portal-link-card:hover {
    border-color: var(--portal-focus);
    background-color: #1d252c;
}

.portal-dark .portal-eyebrow,
.portal-dark .portal-metric-label,
.portal-dark .portal-metric-note,
.portal-dark .portal-kv > div:nth-child(odd),
.portal-dark .portal-conversation-title span,
.portal-dark .portal-thread-title span,
.portal-dark .portal-compose-hint,
.portal-dark .portal-conversation-time,
.portal-dark .portal-conversation-preview,
.portal-dark .portal-new-message-placeholder,
.portal-dark .portal-empty-list,
.portal-dark .portal-empty-thread,
.portal-dark .portal-recipient-picker-label {
    color: #aeb8c2;
}

.portal-dark .portal-image-placeholder,
.portal-dark .portal-map-placeholder {
    border-color: #3a4650;
    background: #11171c;
    color: #cbd5df;
}

.portal-dark .portal-vehicle-thumbnail {
    border-color: #384653;
    background: #27313a;
    color: #cbd5e1;
}

.portal-dark .portal-vehicle-thumbnail.is-loading {
    background: #202a33;
}

.portal-dark .portal-status-pill--warning {
    background-color: #4a3412;
    color: #ffe0a6;
}

.portal-dark .portal-status-pill--success {
    background-color: #123d2a;
    color: #b9f4d7;
}

.portal-dark .portal-status-pill--danger {
    background-color: #4a1820;
    color: #ffc0c9;
}

.portal-dark .portal-status-pill--info {
    background-color: #203754;
    color: #c7dcff;
}

.portal-dark .portal-status-pill--secondary {
    background-color: #27313a;
    color: #cbd5df;
}

.portal-dark .portal-user-deactivated {
    color: #a8b0b8;
}

.portal-dark .portal-user-gear-button {
    background: transparent;
    color: #cbd5df;
}

.portal-dark .portal-user-gear-button:not(:disabled):hover,
.portal-dark .portal-user-gear-button:not(:disabled):focus-visible {
    color: #f8fafc;
}

.portal-dark .portal-message,
.portal-dark .portal-message--itp,
.portal-dark .portal-message-bubble {
    background-color: var(--portal-surface-raised);
    border-color: var(--portal-border-soft);
}

.portal-dark .portal-message--customer,
.portal-dark .portal-message-row-mine .portal-message-bubble {
    background-color: #192c45;
    border-color: #3d5d87;
}

.portal-dark .portal-message-row-target .portal-message-bubble {
    border-color: var(--portal-border-soft);
    box-shadow: none;
}

.portal-dark .portal-message-meta,
.portal-dark .portal-bubble-meta {
    color: #aeb8c2;
}

.portal-dark .portal-bubble-meta span {
    color: #eef3f7;
}

.portal-dark .portal-ro-verification-kicker {
    color: #fca5a5;
}

.portal-dark .portal-ro-verification-title strong,
.portal-dark .portal-ro-verification-ro-link,
.portal-dark .portal-ro-verification dd {
    color: #f8fafc;
}

.portal-dark .portal-ro-verification-status {
    border-color: rgba(252, 165, 165, .45);
    color: #fecaca;
}

.portal-dark .portal-ro-verification-status--approved {
    border-color: rgba(74, 222, 128, .45);
    color: #bbf7d0;
}

.portal-dark .portal-ro-verification-status--pending {
    border-color: rgba(251, 191, 36, .45);
    color: #fde68a;
}

.portal-dark .portal-message-row-target .portal-ro-verification {
    border-color: rgba(255, 107, 107, 0.72);
    box-shadow: 0 0 0 3px rgba(255, 107, 107, 0.16);
}

.portal-dark .portal-ro-verification dt,
.portal-dark .portal-ro-verification p,
.portal-dark .portal-ro-verification-message {
    color: #cbd5e1;
}

.portal-dark .portal-chip {
    background-color: #27313a;
    color: #d2dce5;
}

.portal-dark .portal-message-attachment-image img,
.portal-dark .portal-message-attachment-placeholder {
    border-color: #384653;
    background-color: #27313a;
}

.portal-dark .portal-message-attachment-placeholder,
.portal-dark .portal-message-attachment-image figcaption {
    color: #cbd5e1;
}

.portal-dark .portal-message-image-gallery-stage {
    border-color: #384653;
    background-color: #11171c;
}

.portal-dark .portal-message-image-gallery-nav {
    border-color: #384653;
    background: rgba(23, 29, 34, .94);
    color: #e7edf2;
}

.portal-dark .portal-message-image-gallery-nav:hover,
.portal-dark .portal-message-image-gallery-nav:focus-visible {
    background: #24313a;
    color: #f2f6f9;
}

.portal-dark .portal-message-image-gallery-thumbnail {
    border-color: #384653;
    background: #171d22;
}

.portal-dark .portal-message-image-gallery-thumbnail.is-selected {
    border-color: #f87171;
    box-shadow: inset 0 0 0 1px #f87171;
}

.portal-dark .portal-message-image-gallery-thumbnail span,
.portal-dark .portal-message-image-gallery-meta {
    color: #cbd5e1;
}

.portal-dark .portal-conversation-header,
.portal-dark .portal-thread-header,
.portal-dark .portal-compose-panel {
    border-color: var(--portal-border);
    background-color: var(--portal-surface);
}


.portal-dark .portal-conversation-item:focus-visible {
    outline-color: rgba(248, 113, 113, 0.55);
}

.portal-dark .portal-conversation-top-card {
    border-bottom-color: var(--portal-border);
    background: color-mix(in srgb, var(--portal-surface-subtle) 82%, var(--portal-border));
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.04),
        inset 0 -0.2rem 0.7rem rgba(0, 0, 0, 0.28),
        0 0.3rem 0.8rem rgba(0, 0, 0, 0.24);
}

.portal-dark .portal-general-conversation-slot .portal-conversation-item {
    border-color: var(--portal-border-soft);
}

.portal-dark .portal-general-conversation-slot .portal-conversation-item-active {
    border-color: var(--portal-header-text);
}

.portal-dark .portal-conversation-avatar {
    background: #39434c;
    color: var(--portal-header-text);
    box-shadow: none;
}

.portal-dark .portal-conversation-pane-archived .portal-conversation-avatar {
    color: #9ca3af;
}

.portal-dark .portal-conversation-tabs {
    border-color: var(--portal-border);
    background: #11171c;
}

.portal-dark .portal-conversation-tab {
    color: var(--portal-muted);
}

.portal-dark .portal-conversation-tab:hover {
    color: var(--portal-text);
}

.portal-dark .portal-conversation-tab:focus-visible {
    outline-color: rgba(248, 113, 113, 0.55);
}

.portal-dark .portal-conversation-tab-active {
    border-color: rgba(248, 113, 113, 0.34);
    background: rgba(185, 28, 28, 0.18);
    color: #fecaca;
    box-shadow: none;
}

.portal-dark .portal-conversation-item-active {
    border-color: var(--portal-header-text);
    background: var(--portal-surface-raised);
    box-shadow: 0.5rem 0 0.75rem -0.4rem rgba(0, 0, 0, 0.38);
}

.portal-dark .portal-conversation-item::before {
    background: var(--portal-header-text);
}

.portal-dark .portal-message-list {
    background-color: var(--portal-surface);
    background-image: url("/images/valve-body-chat-background-optimized.webp");
    background-position: center bottom;
    background-size: cover;
    background-repeat: no-repeat;
    background-blend-mode: color-burn;
    box-shadow: inset 0 0 0 1px var(--portal-surface);
}

.portal-dark .portal-data-grid,
.portal-dark .portal-data-grid .dxbl-grid,
.portal-dark .portal-data-grid .dxbl-grid-table,
.portal-dark .portal-data-grid table {
    --dxbl-grid-bg: #171d22;
    --dxbl-grid-color: #e7edf2;
    --dxbl-grid-border-color: #2d3841;
    --dxbl-grid-header-bg: #11171c;
    --dxbl-grid-header-color: #e7edf2;
    --dxbl-grid-row-hover-bg: #1f2932;
    background-color: #171d22 !important;
    color: #e7edf2 !important;
    border-color: #2d3841 !important;
}

.portal-dark .portal-data-grid .dxbl-grid-header-row,
.portal-dark .portal-data-grid .dxbl-grid-header,
.portal-dark .portal-data-grid thead,
.portal-dark .portal-data-grid th {
    background-color: #11171c !important;
    color: #e7edf2 !important;
    border-color: #2d3841 !important;
}

.portal-dark .portal-data-grid .dxbl-grid-table > tbody > tr,
.portal-dark .portal-data-grid tbody tr {
    background-color: #171d22 !important;
    color: #e7edf2 !important;
}

.portal-dark .portal-data-grid .dxbl-grid-table > tbody > tr:hover,
.portal-dark .portal-data-grid tbody tr:hover {
    background-color: #1f2932 !important;
}

.portal-dark .portal-data-grid .dxbl-grid-table > tbody > tr > td,
.portal-dark .portal-data-grid .dxbl-grid-table > thead > tr > th,
.portal-dark .portal-data-grid td,
.portal-dark .portal-data-grid th {
    border-color: #2d3841 !important;
    color: inherit !important;
}

.portal-dark .portal-data-grid .dxbl-grid-empty-data,
.portal-dark .portal-data-grid .dxbl-grid-search-box,
.portal-dark .portal-data-grid .dxbl-grid-group-panel,
.portal-dark .portal-data-grid .dxbl-grid-filter-row,
.portal-dark .portal-data-grid .dxbl-grid-footer,
.portal-dark .portal-data-grid .dxbl-grid-pager,
.portal-dark .portal-data-grid .dxbl-pager {
    background-color: #171d22 !important;
    color: #cbd5df !important;
    border-color: #2d3841 !important;
}

.portal-dark .portal-data-grid .dxbl-btn,
.portal-dark .portal-data-grid .dxbl-pager .dxbl-btn,
.portal-dark .portal-data-grid button:not(.btn) {
    background-color: #1b2228 !important;
    border-color: #3a4650 !important;
    color: #e7edf2 !important;
}

.portal-dark .portal-data-grid .dxbl-btn:hover,
.portal-dark .portal-data-grid .dxbl-pager .dxbl-btn:hover,
.portal-dark .portal-data-grid button:not(.btn):hover {
    background-color: #24313a !important;
    border-color: #526777 !important;
}

.portal-dark .portal-data-grid .btn-outline-primary {
    background-color: var(--portal-button-bg);
    border-color: var(--portal-button-border);
    color: #fff;
}

.portal-dark .portal-data-grid .btn-outline-primary:hover {
    background-color: var(--portal-button-bg);
    border-color: var(--portal-button-border);
    color: #fff;
}

.portal-dark .portal-ro-history-group {
    background: var(--portal-surface);
    border-color: var(--portal-border);
}

.portal-dark .portal-ro-history-header {
    background: var(--portal-surface-subtle);
    border-color: var(--portal-border);
}

.portal-dark .portal-ro-filter-tabs {
    border-bottom-color: var(--portal-border);
}

.portal-dark .portal-ro-filter-tab {
    color: var(--portal-muted);
}

.portal-dark .portal-ro-filter-tab:hover,
.portal-dark .portal-ro-filter-tab:focus {
    color: var(--portal-muted-strong);
}

.portal-dark .portal-ro-filter-tab.is-active {
    border-bottom-color: var(--portal-muted-strong);
    color: var(--portal-text);
}

.portal-dark .portal-card-title,
.portal-dark a.portal-ro-history-link:not(.btn):not(.portal-link-card):not(.portal-metric-card) {
    color: var(--portal-text);
}

.portal-dark .portal-ro-history-header span:not(.portal-ro-status-badge) {
    color: #aeb8c2;
}

.portal-dark .portal-vehicle-list-meta strong {
    color: #aeb8c2;
}

.portal-dark .vehicle-photo-type-strip-header span,
.portal-dark .vehicle-photo-type-copy span,
.portal-dark .vehicle-photo-type-code {
    color: #aeb8c2;
}

.portal-dark .vehicle-photo-type-option {
    background: #171d22;
    border-color: #2d3841;
}

.portal-dark .vehicle-detail-photo-strip {
    background: #171d22;
    border-color: #2d3841;
}

.portal-dark .vehicle-ro-photo-selector-item.is-selected {
    background: darkred;
    box-shadow: 0px 0px 4px 1px red, 0 0.45rem 1rem rgba(var(--portal-brand-rgb), 0.22);
}

.portal-dark .vehicle-photo-type-option:hover,
.portal-dark .vehicle-photo-type-option:focus-visible,
.portal-dark .vehicle-photo-type-option.is-selected {
    border-color: var(--portal-button-border);
    background: #1d252c;
}

.portal-dark .vehicle-photo-type-thumb {
    border-color: #384653;
    background: #27313a;
    color: #cbd5e1;
}

.portal-dark .vehicle-ro-photo-card img {
    border-color: #384653;
    background: #27313a;
}

.portal-dark .vehicle-ro-photo-section {
    background: #171d22;
    border-color: #2d3841;
}

.portal-dark .vehicle-ro-photo-carousel,
.portal-dark .vehicle-ro-photo-carousel .dxbl-carousel,
.portal-dark .vehicle-ro-photo-carousel .dxbl-carousel-container,
.portal-dark .vehicle-ro-photo-carousel .dxbl-carousel-item {
    background: #171d22;
    color: #e7edf2;
}

.portal-dark .vehicle-ro-photo-carousel .dxbl-carousel-arrow-button {
    background: var(--portal-brand);
    color: #e7edf2;
}

.portal-dark .vehicle-ro-photo-fixed-arrow {
    background: var(--portal-brand);
    color: #e7edf2;
}

.portal-dark .vehicle-ro-photo-carousel .dxbl-carousel-arrow-button:hover,
.portal-dark .vehicle-ro-photo-carousel .dxbl-carousel-arrow-button:focus,
.portal-dark .vehicle-ro-photo-fixed-arrow:hover,
.portal-dark .vehicle-ro-photo-fixed-arrow:focus-visible {
    background: #24313a;
    border-color: #526777;
    color: #f2f6f9;
}

.portal-dark .vehicle-ro-photo-carousel .dxbl-carousel-indicator,
.portal-dark .vehicle-ro-photo-carousel .dxbl-carousel-indicators button {
    background-color: #526777;
}

.portal-dark .vehicle-ro-photo-carousel .dxbl-carousel-indicator-active,
.portal-dark .vehicle-ro-photo-carousel .dxbl-carousel-indicators button.active {
    background-color: #c7dcff;
}

.portal-dark .vehicle-ro-photo-section-header span {
    color: #aeb8c2;
}

.portal-dark .vehicle-ro-carousel-controls span {
    color: #aeb8c2;
}

.portal-dark .vehicle-ro-photo-placeholder {
    border-color: #384653;
    background: #27313a;
    color: #aeb8c2;
}

.portal-dark .vehicle-ro-photo-card figcaption span {
    color: #aeb8c2;
}

.portal-dark .portal-ro-history-link:hover,
.portal-dark .portal-ro-history-link:focus {
    color: #c7dcff;
}

.portal-dark .portal-document-month-header span,
.portal-dark .portal-document-main span,
.portal-dark .portal-document-meta,
.portal-dark .portal-document-timeline a {
    color: #aeb8c2;
}

.portal-dark .portal-document-month-header,
.portal-dark .portal-document-timeline a:hover,
.portal-dark .portal-document-timeline a:focus {
    background: var(--portal-surface-subtle);
    border-color: var(--portal-border);
}

.portal-dark .portal-document-items,
.portal-dark .portal-document-item + .portal-document-item {
    border-color: var(--portal-border);
}

.portal-dark .portal-document-item {
    background: var(--portal-surface);
}

.portal-dark .portal-document-icon {
    background: #8f1729;
}

.portal-dark .portal-document-open:not(:disabled):hover .portal-document-main strong,
.portal-dark .portal-document-open:not(:disabled):focus-visible .portal-document-main strong {
    color: #c7dcff;
}

.portal-dark .table {
    --bs-table-bg: #171d22;
    --bs-table-color: #e7edf2;
    --bs-table-border-color: #2d3841;
    --bs-table-striped-bg: #1b2228;
    --bs-table-striped-color: #e7edf2;
    --bs-table-hover-bg: #1f2932;
    --bs-table-hover-color: #f2f6f9;
    color: #e7edf2;
    border-color: #2d3841;
}

.portal-dark .form-control,
.portal-dark .form-select,
.portal-dark textarea,
.portal-dark input {
    background-color: #10161b;
    border-color: #3a4650;
    color: #e7edf2;
}

.portal-dark .form-control::placeholder,
.portal-dark textarea::placeholder,
.portal-dark input::placeholder {
    color: #87939f;
}

.portal-dark .form-control:focus,
.portal-dark .form-select:focus,
.portal-dark textarea:focus,
.portal-dark input:focus {
    background-color: #121a20;
    border-color: #7c9bd6;
    color: #f2f6f9;
    box-shadow: 0 0 0 0.2rem rgba(124, 155, 214, 0.24);
}

.portal-dark .portal-auth-shell {
    background:
        radial-gradient(circle at top right, rgba(205, 31, 56, 0.16), transparent 28%),
        linear-gradient(180deg, #12161b 0%, #0f1418 48%, #101418 100%);
}

.portal-dark .portal-auth-card {
    background: var(--portal-surface);
    border-color: var(--portal-border);
    box-shadow: var(--portal-shadow-strong);
}

.portal-dark .portal-auth-brand {
    background: linear-gradient(180deg, #8f1729 0%, #4b2230 55%, #1f313f 100%);
}

.portal-dark .portal-auth-tabs {
    background: #2a2025;
}

.portal-dark .portal-auth-tab {
    color: #f0c6cf;
}

.portal-dark .portal-auth-tab.is-active {
    background: #3a2029;
    color: #ffe8ed;
    box-shadow: 0 0.35rem 0.85rem rgba(0, 0, 0, 0.25);
}

.portal-dark .portal-auth-panel h2,
.portal-dark .portal-auth-field label {
    color: #f4d8df;
}

.portal-dark .portal-auth-panel p,
.portal-dark .portal-auth-field small {
    color: #c8b6bc;
}

.portal-dark .portal-auth-field input {
    background: #10161b;
    border-color: #3a4650;
    color: #e7edf2;
}

.portal-dark .portal-auth-note {
    background: #3b2a14;
    border-color: #6d5228;
    color: #ffe0a6;
}

@media (min-width: 641px) {
    .portal-document-page {
        --portal-document-sticky-top: 3.75rem;
        --portal-document-anchor-offset: 4.75rem;
    }
}

@media (min-width: 641px) and (max-width: 1279px) {
    .portal-ro-detail-info-strip {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        row-gap: 0.65rem;
    }

    .portal-ro-detail-info-item:nth-child(3n+1) {
        border-left: 0;
    }

    .portal-ro-detail-info-item:nth-child(n+4):not(.portal-ro-detail-info-item--full) {
        padding-top: 0.65rem;
        border-top: 1px solid var(--portal-border-soft);
    }

    .vehicle-detail-info-items {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        row-gap: 0.9rem;
    }

    .vehicle-detail-info-item:nth-child(5) {
        border-left: 0;
    }

    .vehicle-detail-info-item:nth-child(n+5) {
        padding-top: 0.9rem;
        border-top: 1px solid var(--portal-border-soft);
    }
}

@media (min-width: 641px) and (max-width: 1024px) {
    .portal-page {
        max-width: 100%;
    }

    .portal-card {
        padding: 1.25rem;
    }

    .portal-detail-grid {
        grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    }

    .portal-metric-grid,
    .portal-link-grid {
        grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
    }

    .portal-account-select-grid {
        grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    }

    .portal-ro-history-header,
    .portal-document-month-header {
        gap: 0.75rem;
    }

    .portal-document-layout {
        grid-template-columns: minmax(9rem, 0.32fr) minmax(0, 1fr);
    }

    .portal-message-bubble {
        max-width: 82%;
    }
}

@media (max-width: 860px) {
    .vehicle-ro-photo-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .portal-messaging-screen {
        grid-template-columns: 1fr;
        grid-template-rows: minmax(150px, 34%) minmax(0, 1fr);
    }

    .portal-recipient-picker-row {
        grid-template-columns: auto minmax(120px, 1fr);
    }

    .portal-recipient-picker-recipient {
        grid-column: 2 / -1;
    }

    .portal-auth-card {
        width: min(100%, 560px);
        grid-template-columns: 1fr;
        gap: clamp(2.5rem, 7vh, 4rem);
    }

    .portal-auth-brand {
        grid-template-columns: auto minmax(0, 1fr);
        align-items: end;
        gap: 1.25rem;
        padding: 0;
    }

    .portal-auth-logo {
        width: clamp(11rem, 32vw, 18rem);
        margin-bottom: -1.35rem;
    }

    .portal-auth-brand h1 {
        font-size: clamp(1.02rem, 3.5vw, 1.25rem);
    }

    .portal-auth-panel {
        width: 100%;
        justify-self: stretch;
        padding: 0;
    }
}

@media (max-width: 640.98px) {
    .portal-auth-shell {
        align-items: flex-start;
        padding: 4.5rem 1.25rem 2.5rem;
    }

    .portal-auth-card {
        gap: 2.5rem;
    }

    .portal-auth-tabs {
        gap: 1.5rem;
    }

    .portal-auth-field input,
    .portal-auth-actions .btn {
        min-height: 3.9rem;
    }

    .vehicle-ro-photo-selector {
        grid-template-columns: auto minmax(0, 1fr) auto;
    }

    .vehicle-ro-photo-selector-position {
        grid-column: 1 / -1;
        justify-self: center;
    }

    .vehicle-ro-photo-selector-item {
        min-width: 6.75rem;
        padding: 0.4rem 0.55rem;
    }

    .vehicle-ro-photo-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .content {
        padding-top: 0.75rem;
    }

    .portal-page {
        max-width: 100%;
    }

    .portal-card-title {
        font-size: 1.18rem;
        line-height: 1.25;
    }

    .portal-section-title {
        font-size: 1.05rem;
        line-height: 1.25;
    }

    .portal-detail-grid,
    .portal-metric-grid,
    .portal-link-grid,
    .portal-account-select-grid,
    .portal-image-strip {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }

    .portal-metric-card,
    .portal-link-card,
    .portal-account-select-card {
        padding: 0.85rem;
    }

    .portal-metric-value {
        font-size: 1.65rem;
    }

    .portal-metric-value--compact {
        font-size: 1.08rem;
    }

    .portal-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .portal-user-confirm {
        align-items: stretch;
        flex-direction: column;
    }

    .portal-actions .btn,
    .portal-ro-verification-actions .btn,
    .portal-auth-actions .btn {
        width: 100%;
    }

    .portal-header-account-selector {
        align-items: flex-end;
        flex-direction: column;
        gap: 0.35rem;
    }

    .portal-header-account-change {
        width: 100%;
        font-size: 0.82rem;
        padding: 0.32rem 0.55rem 0.32rem 0.65rem;
    }

    .portal-messaging-screen {
        gap: 0.5rem;
    }

    .portal-conversation-pane,
    .portal-thread-pane {
        border-radius: 0;
    }

    .portal-conversation-header,
    .portal-thread-header,
    .portal-compose-panel {
        padding: 0.75rem;
    }

    .portal-thread-header-with-thumbnail {
        padding-block: 0.3125rem;
    }

    .portal-thread-header:not(.portal-thread-header-with-thumbnail) {
        padding-block: 0.5625rem;
    }

    .portal-message-search {
        margin-right: 0.75rem;
        margin-left: 0.75rem;
    }

    .portal-conversation-tabs {
        margin-right: 0.75rem;
        margin-left: 0.75rem;
    }

    .portal-recipient-picker-row {
        grid-template-columns: 1fr;
    }

    .portal-recipient-picker-recipient {
        grid-column: auto;
    }

    .portal-message-list {
        padding: 0.75rem;
    }

    .portal-conversation-item {
        grid-template-columns: 38px minmax(0, 1fr) auto;
        gap: 0.55rem;
        min-height: 68px;
    }

    .portal-conversation-avatar {
        width: 38px;
        height: 38px;
    }

    .portal-vehicle-thumbnail--large {
        width: 88px;
        height: 66px;
    }

    .portal-message-bubble {
        max-width: 92%;
    }

    .portal-bubble-meta,
    .portal-ro-verification-title,
    .portal-ro-verification-header {
        align-items: flex-start;
        flex-direction: column;
        gap: 0.45rem;
    }

    .portal-ro-verification dl,
    .portal-message-attachments,
    .portal-compose-attachment-previews {
        grid-template-columns: 1fr;
    }

    .portal-compose-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .portal-card {
        padding: 0.9rem;
    }

    .vehicle-detail-info-strip {
        gap: 0.8rem;
        padding: 0.8rem;
    }

    .vehicle-detail-truck-icon {
        width: 3.5rem;
        height: 3.5rem;
    }

    .vehicle-detail-visual {
        grid-template-columns: 3.5rem;
        gap: 0.8rem;
    }

    .vehicle-detail-truck-icon > span {
        width: 3.5rem;
        height: 3.5rem;
    }

    .vehicle-detail-info-heading > .portal-card-title {
        font-size: 1.5rem;
    }

    .vehicle-detail-info-items {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .vehicle-detail-info-item {
        padding: 0.7rem 0.8rem;
    }

    .vehicle-detail-info-item:nth-child(odd) {
        border-left: 0;
    }

    .vehicle-detail-info-item:nth-child(n+3) {
        border-top: 1px solid var(--portal-border-soft);
    }

    .portal-ro-history-list {
        gap: 0.75rem;
    }

    .portal-ro-history-header {
        padding: 0.75rem;
    }

    .portal-document-layout {
        grid-template-columns: 1fr;
    }

    .portal-document-month-header,
    .portal-ro-history-header {
        align-items: stretch;
        flex-direction: column;
    }

    .portal-ro-detail-info-strip {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        row-gap: 0;
    }

    .portal-ro-detail-info-item {
        padding: 0.7rem 0.8rem;
    }

    .portal-ro-detail-info-item:nth-child(odd) {
        border-left: 0;
    }

    .portal-ro-detail-info-item:nth-child(n+3):not(.portal-ro-detail-info-item--full) {
        border-top: 1px solid var(--portal-border-soft);
    }

    .portal-ro-detail-info-item--full {
        margin-top: 0;
    }

    .portal-ro-photo-strip {
        margin-top: 0.85rem !important;
        padding-top: 0.75rem;
    }

    .portal-ro-history-actions,
    .portal-ro-detail-actions {
        justify-content: flex-start;
        width: 100%;
    }

    .portal-ro-approval-header {
        align-items: center;
        flex-direction: row;
        gap: 0.75rem;
    }

    .portal-ro-approval-header .portal-ro-history-toggle-actions {
        width: auto;
    }

    .portal-ro-history-toggle-actions {
        justify-content: flex-end;
    }

    .portal-ro-history-actions .btn {
        width: 100%;
    }

    .portal-ro-history-toggle-actions .btn {
        flex: 1 1 auto;
        width: auto;
    }

    .portal-ro-history-table th,
    .portal-ro-history-table td,
    .portal-pending-approval-table th,
    .portal-pending-approval-table td {
        white-space: normal;
    }

    .portal-ro-history-table .portal-ro-requested-at {
        white-space: nowrap;
    }

    .portal-ro-approval-table colgroup,
    .portal-ro-approval-table thead {
        display: none;
    }

    .portal-ro-approval-table,
    .portal-ro-approval-table tbody,
    .portal-ro-approval-table tr,
    .portal-ro-approval-table td {
        display: block;
        width: 100%;
    }

    .portal-ro-approval-table tbody {
        display: grid;
        gap: 0.65rem;
        padding: 0.65rem;
    }

    .portal-ro-approval-table tr {
        padding: 0.65rem;
        border: 1px solid var(--portal-border-soft);
        border-radius: var(--portal-radius-sm);
        background: var(--portal-surface);
    }

    .portal-ro-approval-table td {
        display: grid;
        grid-template-columns: 7rem minmax(0, 1fr);
        align-items: baseline;
        gap: 0.5rem;
        padding: 0.2rem 0;
        border: 0;
        background: transparent;
        box-shadow: none;
    }

    .portal-ro-approval-table td::before {
        color: var(--portal-muted);
        content: attr(data-label);
        font-size: 0.78rem;
        font-weight: 700;
    }

    .portal-pending-approval-table {
        table-layout: auto;
    }

    .portal-pending-approval-table colgroup,
    .portal-pending-approval-table thead {
        display: none;
    }

    .portal-pending-approval-table,
    .portal-pending-approval-table tbody,
    .portal-pending-approval-table tr,
    .portal-pending-approval-table td {
        display: block;
        width: 100%;
    }

    .portal-pending-approval-table tbody {
        display: grid;
        gap: 0.65rem;
    }

    .portal-pending-approval-table tr {
        border: 1px solid var(--portal-border-soft);
        border-radius: var(--portal-radius-sm);
        padding: 0.65rem;
        background: var(--portal-surface);
    }

    .portal-pending-approval-table tr.portal-pending-approval-row {
        border-color: rgba(var(--portal-brand-rgb), 0.6);
        background: rgba(var(--portal-brand-rgb), 0.055);
        box-shadow:
            inset 3px 0 0 var(--portal-brand),
            0 0 0 2px rgba(var(--portal-brand-rgb), 0.1);
    }

    .portal-pending-approval-table td {
        display: grid;
        grid-template-columns: 6.5rem minmax(0, 1fr);
        align-items: baseline;
        gap: 0.5rem;
        border: 0;
        padding: 0.2rem 0;
    }

    .portal-pending-approval-table td::before {
        color: var(--portal-muted);
        font-size: 0.78rem;
        font-weight: 700;
    }

    .portal-pending-approval-table td:nth-child(1)::before {
        content: "Amount";
    }

    .portal-pending-approval-table td:nth-child(2)::before {
        content: "Requested";
    }

    .portal-pending-approval-table td:nth-child(3)::before {
        content: "Status";
    }

    .portal-pending-approval-table td:nth-child(4)::before {
        content: "Notes";
    }

    .portal-pending-approval-table td:nth-child(5)::before {
        content: "Review";
    }

    .portal-pending-approval-review {
        text-align: center;
        white-space: normal;
    }

    .portal-pending-approval-review .btn {
        width: 100%;
    }

    .portal-document-timeline {
        position: static;
        display: flex;
        overflow-x: auto;
        max-height: none;
        padding-bottom: 0.35rem;
    }

    .portal-document-timeline a {
        flex: 0 0 auto;
        border-left: 0;
        border-bottom: 3px solid #dee2e6;
    }

    .portal-document-item {
        grid-template-columns: 1fr;
        align-items: stretch;
    }

    .portal-document-open {
        grid-template-columns: 42px minmax(0, 1fr);
    }

    .portal-document-meta {
        grid-column: 2;
        justify-items: start;
        text-align: left;
    }

    .portal-document-download {
        justify-self: start;
    }

    .portal-kv {
        display: grid;
        grid-template-columns: 1fr;
        gap: 0.35rem;
    }

    .portal-auth-grid {
        grid-template-columns: 1fr;
    }

    .portal-compose-attachment {
        align-items: stretch;
        flex-direction: column;
    }

    .portal-compose-attachment-button {
        justify-content: center;
    }

    .portal-compose-attachment-name,
    .portal-compose-attachment-status,
    .portal-compose-attachment-preview figcaption {
        white-space: normal;
    }
}

/* Role restrictions stay visible and neutral in both light and dark themes. */
.portal-role-disabled,
.portal-compose-panel-read-only :is(.portal-compose-input, .portal-compose-attachment-button, .portal-compose-attachment .dxbl-btn, .portal-compose-actions .dxbl-btn) {
    background: var(--portal-surface-subtle) !important;
    border-color: var(--portal-border) !important;
    color: var(--portal-muted-strong) !important;
    box-shadow: none !important;
    cursor: not-allowed;
    opacity: 1;
}

.portal-role-hint {
    margin: .75rem 0 0;
    color: var(--portal-muted-strong);
    font-size: .875rem;
}
