/*
 * YASTRAV UI stability layer.
 *
 * The desktop application has a fixed navigation rail.  Responsive decisions in
 * feature styles must therefore account for the usable application canvas, not
 * just the browser viewport.  This file is loaded last so feature work cannot
 * accidentally re-introduce cramped split panes or mixed light/dark surfaces.
 */

.app-frame,
.app-content,
.app-content > *,
.booking-workspace-grid,
.service-editor,
.operations-form {
    min-width: 0;
}

.booking-financial-snapshot-notice {
    align-items: center;
    background: linear-gradient(135deg, rgba(255, 248, 225, .96), rgba(244, 250, 255, .96));
    border: 1px solid #e3c875;
    border-radius: 14px;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.9), 0 8px 22px rgba(20, 54, 80, .08);
    display: grid;
    gap: 12px;
    grid-template-columns: auto 1fr auto;
    margin: 0 0 14px;
    padding: 13px 15px;
}

.booking-next-finance-step {
    display:grid;
    grid-template-columns:48px minmax(0,1fr) auto;
    gap:16px;
    align-items:center;
    margin:0 0 14px;
    padding:17px 19px;
    border:1px solid rgba(8,133,126,.34);
    border-radius:15px;
    background:linear-gradient(145deg,#f9fffe,#e9f7f5);
    box-shadow:inset 0 1px #fff,0 7px 18px rgba(8,71,76,.08);
}
.booking-next-finance-step[hidden]{display:none!important}
.booking-next-finance-icon{display:grid;width:46px;height:46px;place-items:center;border-radius:13px;background:linear-gradient(145deg,#18a49c,#08717a);color:#fff;font-size:22px;box-shadow:inset 0 1px rgba(255,255,255,.38),0 5px 12px rgba(7,89,91,.2)}
.booking-next-finance-step strong{display:block;margin:3px 0 4px;color:#153b54;font-size:1rem}.booking-next-finance-step p{max-width:660px;margin:0;color:#617988;font-size:.75rem;line-height:1.5}.booking-prepare-invoice-form{display:flex;align-items:end;gap:10px}.booking-prepare-invoice-form label>span{display:block;margin-bottom:5px;color:#315469;font-size:.68rem;font-weight:800}.booking-prepare-invoice-form input{min-width:145px}
html[data-theme="dark"] .booking-next-finance-step{border-color:rgba(37,181,170,.32);background:linear-gradient(145deg,#10363c,#092b36)}html[data-theme="dark"] .booking-next-finance-step strong{color:#e0eff5}
@media(max-width:900px){.booking-next-finance-step{grid-template-columns:44px 1fr}.booking-prepare-invoice-form{grid-column:1/-1;display:grid;grid-template-columns:1fr auto}.booking-prepare-invoice-form input{width:100%}}
@media(max-width:560px){.booking-next-finance-step{grid-template-columns:1fr}.booking-next-finance-icon{display:none}.booking-prepare-invoice-form{grid-template-columns:1fr}.booking-prepare-invoice-form .button{width:100%;justify-content:center}}

.booking-financial-snapshot-notice p {
    color: #3d596e;
    margin: 3px 0 0;
}

.booking-financial-snapshot-notice strong {
    color: #173e52;
}

.booking-invoice-notice-copy {
    min-width: 0;
}

.booking-invoice-snapshot-metrics {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: 10px;
}

.booking-invoice-snapshot-metrics span {
    background: rgba(255, 255, 255, .7);
    border: 1px solid rgba(126, 160, 177, .42);
    border-radius: 9px;
    display: grid;
    gap: 1px;
    min-width: 112px;
    padding: 7px 10px;
}

.booking-invoice-snapshot-metrics small {
    color: #69808f;
    font-size: 8px;
    font-weight: 850;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.booking-invoice-snapshot-metrics b {
    color: #173e52;
    font-size: 10px;
}

html[data-theme="dark"] .booking-invoice-snapshot-metrics span {
    background: rgba(12, 30, 42, .7);
    border-color: #39515e;
}

html[data-theme="dark"] .booking-invoice-snapshot-metrics b {
    color: #e0edf3;
}

.account-transfer-workbench {
    border: 1px solid #a9c8d2;
    border-top: 4px solid #0d918a;
    margin-bottom: 16px;
    overflow: hidden;
    padding: 0;
}

.account-transfer-heading {
    align-items: center;
    background: radial-gradient(circle at 100% 0, rgba(20, 165, 158, .2), transparent 38%), linear-gradient(145deg, #0a344e, #075d6c);
    color: #fff;
    display: flex;
    gap: 18px;
    justify-content: space-between;
    padding: 18px 21px;
}

.account-transfer-heading h2 {
    color: #fff;
    margin: 3px 0;
}

.account-transfer-heading p {
    color: #cce1e7;
    margin: 0;
    max-width: 820px;
}

.account-transfer-links {
    display: grid;
    flex: 0 0 auto;
    gap: 6px;
}

.account-transfer-links a {
    border: 1px solid rgba(255, 255, 255, .25);
    border-radius: 8px;
    color: #e4fbfa;
    font-size: 9px;
    font-weight: 850;
    padding: 7px 9px;
    text-align: center;
    text-decoration: none;
}

#account-transfer-form {
    padding: 16px 20px 18px;
}

.account-transfer-type {
    display: grid;
    gap: 10px;
    grid-template-columns: 1fr 1fr;
    margin-bottom: 13px;
}

.account-transfer-type label {
    align-items: center;
    background: linear-gradient(145deg, #fff, #edf4f6);
    border: 2px solid #ccdae0;
    border-radius: 13px;
    cursor: pointer;
    display: grid;
    gap: 11px;
    grid-template-columns: 42px 1fr;
    padding: 11px 13px;
    position: relative;
}

.account-transfer-type input {
    opacity: 0;
    position: absolute;
}

.account-transfer-type label:has(input:checked) {
    background: linear-gradient(145deg, #f4fffd, #ddf4f0);
    border-color: #15968e;
    box-shadow: 0 6px 14px rgba(11, 128, 120, .12);
}

.account-transfer-type-icon {
    align-items: center;
    background: linear-gradient(145deg, #23a7a0, #08716e);
    border-radius: 10px;
    box-shadow: inset 0 1px rgba(255,255,255,.45), 0 4px 9px rgba(8,113,110,.2);
    color: #fff;
    display: flex;
    font-size: 11px;
    font-weight: 950;
    height: 39px;
    justify-content: center;
    width: 39px;
}

.account-transfer-type strong,
.account-transfer-type small {
    display: block;
}

.account-transfer-type strong {
    color: #173e55;
}

.account-transfer-type small {
    color: #6b818f;
    margin-top: 2px;
}

.account-transfer-fields {
    display: grid;
    gap: 10px;
    grid-template-columns: minmax(210px, 1.25fr) minmax(210px, 1.25fr) minmax(180px, .85fr) 145px 170px;
}

.account-transfer-fields label {
    color: #315064;
    display: grid;
    font-size: 10px;
    font-weight: 850;
    gap: 5px;
    min-width: 0;
}

.account-transfer-fields [hidden] {
    display: none !important;
}

.account-transfer-fields label > small {
    color: #778b96;
    font-size: 8px;
    font-weight: 500;
}

.account-transfer-fields input,
.account-transfer-fields select {
    height: 42px;
    width: 100%;
}

.account-transfer-narration {
    grid-column: span 2;
}

.account-transfer-amount {
    display: grid;
    grid-template-columns: 68px 1fr;
}

.account-transfer-amount select {
    border-radius: 9px 0 0 9px;
    font-weight: 900;
}

.account-transfer-amount input {
    border-left: 0;
    border-radius: 0 9px 9px 0;
    font-weight: 850;
}

.account-transfer-preview {
    align-items: center;
    background: linear-gradient(145deg, #eff9f7, #e4f1f2);
    border: 1px solid #b4d6d2;
    border-radius: 12px;
    display: grid;
    gap: 10px;
    grid-template-columns: minmax(170px, 1fr) auto minmax(170px, 1fr) minmax(260px, 1.4fr);
    margin-top: 13px;
    padding: 11px 13px;
}

.account-transfer-preview small,
.account-transfer-preview strong {
    display: block;
}

.account-transfer-preview small {
    color: #0b8179;
    font-size: 8px;
    font-weight: 900;
    text-transform: uppercase;
}

.account-transfer-preview strong {
    color: #21495c;
    font-size: 11px;
    margin-top: 2px;
}

.account-transfer-preview i {
    color: #15938b;
    font-size: 20px;
    font-style: normal;
}

.account-transfer-preview p {
    color: #5f7885;
    font-size: 9px;
    margin: 0;
}

.account-transfer-actions {
    align-items: center;
    display: flex;
    gap: 9px;
    justify-content: flex-end;
    margin-top: 12px;
}

.account-transfer-feedback {
    border-radius: 9px;
    flex: 1;
    font-size: 10px;
    font-weight: 800;
    padding: 9px 11px;
}

.account-transfer-feedback.is-success {
    background: #e4f7ef;
    border: 1px solid #9bcfba;
    color: #176849;
}

.account-transfer-feedback.is-error {
    background: #fff0ef;
    border: 1px solid #dfaaa6;
    color: #963f39;
}

html[data-theme="dark"] .account-transfer-type label,
html[data-theme="dark"] .account-transfer-preview {
    background: linear-gradient(145deg, #142938, #0e1d2a);
    border-color: #304959;
}

html[data-theme="dark"] .account-transfer-type label:has(input:checked) {
    background: linear-gradient(145deg, #153b3b, #102c31);
    border-color: #2d8982;
}

html[data-theme="dark"] .account-transfer-type strong,
html[data-theme="dark"] .account-transfer-preview strong,
html[data-theme="dark"] .account-transfer-fields label {
    color: #e0ecf3;
}

@media (max-width: 1180px) {
    .account-transfer-fields {
        grid-template-columns: 1fr 1fr 1fr;
    }

    .account-transfer-narration {
        grid-column: span 2;
    }

    .account-transfer-preview {
        grid-template-columns: 1fr auto 1fr;
    }

    .account-transfer-preview p {
        grid-column: 1 / -1;
    }
}

@media (max-width: 720px) {
    .account-transfer-heading {
        align-items: stretch;
        flex-direction: column;
    }

    .account-transfer-type,
    .account-transfer-fields,
    .account-transfer-preview {
        grid-template-columns: 1fr;
    }

    .account-transfer-narration {
        grid-column: auto;
    }

    .account-transfer-preview i {
        transform: rotate(90deg);
    }

    .account-transfer-preview p {
        grid-column: auto;
    }

    .account-transfer-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .account-transfer-actions .button,
    .account-transfer-feedback {
        box-sizing: border-box;
        text-align: center;
        width: 100%;
    }
}

.booking-financial-snapshot-icon {
    align-items: center;
    background: linear-gradient(145deg, #1c9a96, #087271);
    border-radius: 10px;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.35), 0 4px 10px rgba(7, 92, 96, .18);
    color: #fff;
    display: inline-flex;
    font-size: 18px;
    height: 38px;
    justify-content: center;
    width: 38px;
}

@media (max-width: 720px) {
    .booking-financial-snapshot-notice {
        grid-template-columns: auto 1fr;
    }

    .booking-financial-snapshot-notice .button {
        grid-column: 1 / -1;
        justify-self: stretch;
        text-align: center;
    }

    .booking-invoice-snapshot-metrics {
        display: grid;
        grid-template-columns: 1fr 1fr;
    }
}

.form-section-heading h2,
.form-section-heading h3 {
    margin: 0;
    color: #153b5a;
    font-size: 17px;
    line-height: 1.25;
}

/* Booking operations: keep the itinerary useful without starving the editor. */
.booking-workspace-grid {
    grid-template-columns: minmax(250px, 275px) minmax(0, 1fr);
}

.service-rail {
    width: 100%;
}

.service-editor .form-section {
    overflow: visible;
}

.erp-field-grid .span-2 {
    grid-column: span 2;
}

.erp-field-grid .span-3 {
    grid-column: 1 / -1;
}

.line-scope-strip {
    display: grid;
    grid-template-columns: 38px minmax(0, 1fr);
    align-items: center;
    gap: 11px;
    padding: 11px 24px;
    color: #31566e;
    background: linear-gradient(145deg, #eff8fa, #e5f1f4);
    border-bottom: 1px solid #c8dae2;
}

.line-scope-icon {
    display: grid;
    width: 36px;
    height: 32px;
    place-items: center;
    color: #fff;
    background: linear-gradient(145deg, #149f99, #08706f);
    border-radius: 9px;
    box-shadow: inset 0 1px rgba(255, 255, 255, .38), 0 4px 9px rgba(8, 112, 111, .18);
    font-size: 12px;
    font-weight: 900;
}

.line-scope-strip strong,
.line-scope-strip small,
.line-scope-note strong,
.line-scope-note span {
    display: block;
}

.line-scope-strip strong {
    color: #17445a;
    font-size: 12px;
}

.line-scope-strip small {
    margin-top: 2px;
    color: #667f8e;
    font-size: 10px;
}

.line-scope-note {
    padding: 11px 13px;
    color: #2f6170;
    background: linear-gradient(145deg, #f4fafc, #e9f2f5);
    border: 1px dashed #a8c4d1;
    border-radius: 10px;
}

.line-scope-note strong {
    color: #17465c;
    font-size: 11px;
}

.line-scope-note span {
    margin-top: 3px;
    font-size: 10px;
    line-height: 1.4;
}

.bulk-apply-option {
    position: relative;
    display: grid !important;
    grid-template-columns: 24px minmax(0, 1fr);
    align-items: center;
    gap: 10px !important;
    min-height: 64px;
    padding: 11px 13px;
    color: #31576d !important;
    background: linear-gradient(145deg, #f6fafc, #e8f1f5);
    border: 1px solid #b8ced9;
    border-radius: 10px;
    cursor: pointer;
    transition: border-color .15s ease, background .15s ease, box-shadow .15s ease;
}

.bulk-apply-option:hover {
    border-color: #53a59f;
    box-shadow: 0 4px 12px rgba(8, 105, 101, .09);
}

.bulk-apply-option > input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.bulk-check {
    position: relative;
    display: block !important;
    width: 23px;
    height: 23px;
    background: #fff;
    border: 2px solid #91aebd;
    border-radius: 7px;
    box-shadow: inset 0 1px 2px rgba(8, 36, 62, .08);
}

.bulk-check::after {
    position: absolute;
    top: 3px;
    left: 6px;
    width: 6px;
    height: 11px;
    content: "";
    border: solid #fff;
    border-width: 0 2px 2px 0;
    opacity: 0;
    transform: rotate(45deg);
}

.bulk-apply-option > input:checked + .bulk-check {
    background: linear-gradient(145deg, #13a59a, #08746f);
    border-color: #08746f;
}

.bulk-apply-option > input:checked + .bulk-check::after {
    opacity: 1;
}

.bulk-apply-option:has(input:checked) {
    color: #205a56 !important;
    background: linear-gradient(145deg, #f2fffc, #ddf2ed);
    border-color: #40a99d;
    box-shadow: inset 0 0 0 1px rgba(15, 143, 132, .10), 0 5px 13px rgba(8, 105, 101, .10);
}

.bulk-apply-option strong,
.bulk-apply-option small {
    display: block;
}

.bulk-apply-option strong {
    color: #17475b;
    font-size: 11px;
    line-height: 1.35;
}

.bulk-apply-option small {
    margin-top: 3px;
    color: #6b8290;
    font-size: 9.5px;
    font-weight: 500;
    line-height: 1.4;
}

.pricing-basis-selector {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    min-width: 0;
    padding: 0;
    margin: 0;
    border: 0;
}

.pricing-basis-selector legend {
    grid-column: 1 / -1;
    margin: 0 0 1px;
    padding: 0;
    color: #3d566c;
    font-size: 12px;
    font-weight: 800;
}

.erp-field-grid .pricing-basis-card {
    position: relative;
    display: grid;
    grid-template-columns: 18px minmax(0, 1fr);
    align-items: center;
    gap: 9px;
    min-height: 72px;
    padding: 10px 11px;
    color: #31566c;
    background: linear-gradient(145deg, #fff, #edf3f6);
    border: 1px solid #bfd0da;
    border-radius: 10px;
    cursor: pointer;
}

.pricing-basis-card input {
    width: 17px !important;
    height: 17px;
    min-height: 17px !important;
    margin: 0;
    accent-color: #087b76;
}

.pricing-basis-card strong,
.pricing-basis-card small {
    display: block;
}

.pricing-basis-card strong {
    color: #173e58;
    font-size: 11px;
}

.pricing-basis-card small {
    margin-top: 3px;
    color: #6b8190;
    font-size: 9px;
    font-weight: 500;
    line-height: 1.35;
}

.pricing-basis-card:has(input:checked) {
    background: linear-gradient(145deg, #f2fffc, #ddf2ed);
    border-color: #35a69a;
    box-shadow: inset 0 0 0 1px rgba(12, 134, 123, .10), 0 4px 11px rgba(8, 105, 101, .08);
}

[data-quantity-field].is-total input {
    color: #547183;
    background: #e9f0f3;
    cursor: not-allowed;
}

.commercial-calculation {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1px;
    overflow: hidden;
    background: #c5d5de;
    border: 1px solid #b9ccd7;
    border-radius: 11px;
    box-shadow: 0 4px 12px rgba(8, 43, 69, .07);
}

.commercial-calculation > div {
    min-width: 0;
    padding: 12px 14px;
    background: linear-gradient(145deg, #fff, #f0f5f7);
}

.commercial-calculation .margin-result {
    background: linear-gradient(145deg, #f2fffb, #dff1ed);
}

.commercial-calculation small,
.commercial-calculation strong,
.commercial-calculation span {
    display: block;
}

.commercial-calculation small {
    color: #667f8e;
    font-size: 8.5px;
    font-weight: 900;
    letter-spacing: .05em;
    text-transform: uppercase;
}

.commercial-calculation strong {
    margin-top: 4px;
    overflow: hidden;
    color: #123d59;
    font-size: 17px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.commercial-calculation span {
    margin-top: 3px;
    color: #6c8290;
    font-size: 9px;
    line-height: 1.35;
}

.commercial-calculation strong.is-negative {
    color: #ad333c;
}

.flight-segment {
    grid-template-columns:
        minmax(90px, .75fr)
        minmax(150px, 1.2fr)
        minmax(90px, .72fr)
        repeat(2, minmax(140px, 1.1fr));
    align-items: end;
}

.flight-segment label:nth-of-type(n) {
    grid-row: auto;
}

.flight-segment label,
.flight-segment .select2-container {
    min-width: 0;
}

.flight-segment input,
.flight-segment select,
.flight-segment .select2-selection__rendered {
    overflow: hidden;
    text-overflow: ellipsis;
}

/* A 1500px viewport leaves about 1140px after the application rail/padding. */
@media (max-width: 1500px) {
    .booking-workspace-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .service-rail {
        position: static;
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 9px;
        max-height: none;
        overflow: visible;
    }

    .service-rail > .section-title-row,
    .service-rail > .service-add-bar {
        grid-column: 1 / -1;
    }

    .service-rail .service-card {
        margin: 0;
    }

    .accounting-grid,
    .governance-grid,
    .governance-period-grid,
    .customer-edit-layout {
        grid-template-columns: minmax(0, 1fr);
    }

    .coa-panel {
        position: static;
        max-height: 560px;
    }
}

@media (max-width: 1200px) {
    .flight-segment {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .commercial-grid,
    .air-ticket-header,
    .hotel-stay-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .booking-command-bar {
        align-items: flex-start;
        flex-direction: column;
    }

    .booking-command-metrics {
        display: grid;
        width: 100%;
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .booking-command-metrics article {
        min-width: 0;
    }
}

@media (max-width: 820px) {
    .service-rail {
        grid-template-columns: minmax(0, 1fr);
    }

    .flight-segment {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .booking-context-strip {
        grid-template-columns: minmax(0, 1fr);
    }

    .traveler-cards article {
        min-width: min(235px, calc(100vw - 76px));
    }

    .commercial-calculation {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media (max-width: 620px) {
    .booking-command-bar,
    .service-editor-header,
    .form-section,
    .sticky-editor-actions {
        padding-right: 16px;
        padding-left: 16px;
    }

    .booking-command-metrics,
    .flight-segment,
    .commercial-grid,
    .air-ticket-header,
    .hotel-stay-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .erp-field-grid label.span-2,
    .hotel-stay-grid label.span-2,
    .erp-field-grid .span-2,
    .erp-field-grid .span-3 {
        grid-column: auto;
    }

    .pricing-basis-selector {
        grid-template-columns: minmax(0, 1fr);
    }

    .pricing-basis-selector legend {
        grid-column: auto;
    }

    .segment-toolbar {
        align-items: stretch;
        flex-direction: column;
    }

    .segment-toolbar .button {
        width: 100%;
    }
}

/* Complete appearance coverage for feature surfaces added after Theme.css. */
html[data-theme="dark"] .booking-command-bar,
html[data-theme="dark"] .booking-command-metrics article,
html[data-theme="dark"] .booking-context-strip article,
html[data-theme="dark"] .traveler-roster,
html[data-theme="dark"] .traveler-cards article,
html[data-theme="dark"] .service-rail,
html[data-theme="dark"] .service-editor,
html[data-theme="dark"] .hrm-metric-grid article,
html[data-theme="dark"] .hrm-staff-list > article,
html[data-theme="dark"] .hrm-identity-strip article,
html[data-theme="dark"] .supplier-metrics article,
html[data-theme="dark"] .supplier-record-card,
html[data-theme="dark"] .supplier-identity-strip article,
html[data-theme="dark"] .accounting-command-bar,
html[data-theme="dark"] .accounting-metrics article,
html[data-theme="dark"] .customer-directory-metrics article,
html[data-theme="dark"] .customer-record-card {
    color: #dce8f2;
    background: radial-gradient(circle at 100% 0, rgba(18, 152, 149, .10), transparent 34%), linear-gradient(145deg, #142838, #0d1d2b);
    border-color: #2c4556;
    box-shadow: inset 0 1px rgba(255, 255, 255, .04), 0 6px 16px rgba(0, 0, 0, .22);
}

html[data-theme="dark"] .commercial-panel,
html[data-theme="dark"] .typed-panel,
html[data-theme="dark"] .notes-panel,
html[data-theme="dark"] .flight-segment,
html[data-theme="dark"] .service-add-bar,
html[data-theme="dark"] .pnr-provider-note,
html[data-theme="dark"] .erp-field-grid .workbench-switch,
html[data-theme="dark"] .hrm-search,
html[data-theme="dark"] .hrm-consultant-toggle,
html[data-theme="dark"] .voucher-type-card,
html[data-theme="dark"] .voucher-line,
html[data-theme="dark"] .voucher-control-strip,
html[data-theme="dark"] .voucher-control-strip > div,
html[data-theme="dark"] .coa-row,
html[data-theme="dark"] .coa-editor-simple,
html[data-theme="dark"] .fiscal-period-card,
html[data-theme="dark"] .opening-balance-card,
html[data-theme="dark"] .bill-line,
html[data-theme="dark"] .capability-grid label,
html[data-theme="dark"] .customer-lifecycle-card,
html[data-theme="dark"] .customer-balance-panel,
html[data-theme="dark"] .customer-overview-metrics article,
html[data-theme="dark"] .customer-receivable-position,
html[data-theme="dark"] .customer-recent-activity,
html[data-theme="dark"] .customer-currency-list article,
html[data-theme="dark"] .customer-overview-empty,
html[data-theme="dark"] .customer-automation-editor,
html[data-theme="dark"] .customer-automation-grid > label,
html[data-theme="dark"] .automation-master-toggle,
html[data-theme="dark"] .customer-permission-builder,
html[data-theme="dark"] .customer-permission-switch,
html[data-theme="dark"] .customer-default-branch-note {
    color: #b9ced9;
    background: linear-gradient(145deg, #102333, #0b1a27);
    border-color: #2c4557;
    box-shadow: inset 0 1px rgba(255, 255, 255, .035);
}

html[data-theme="dark"] .coa-modal-close {
    color: #c8d9e3;
    background: linear-gradient(#173143, #102534);
    border-color: #365264;
}

html[data-theme="dark"] .sticky-editor-actions {
    background: rgba(11, 26, 39, .96);
    border-color: #2c4557;
    box-shadow: 0 -5px 16px rgba(0, 0, 0, .30);
}

html[data-theme="dark"] .form-section {
    border-color: #263e50;
}

html[data-theme="dark"] .form-section-heading h2,
html[data-theme="dark"] .form-section-heading h3,
html[data-theme="dark"] .booking-command-bar h1,
html[data-theme="dark"] .booking-command-metrics strong,
html[data-theme="dark"] .booking-context-strip strong,
html[data-theme="dark"] .traveler-roster h2,
html[data-theme="dark"] .traveler-cards strong,
html[data-theme="dark"] .service-card-copy strong,
html[data-theme="dark"] .service-card-money strong,
html[data-theme="dark"] .workbench-switch strong,
html[data-theme="dark"] .hrm-metric-grid strong,
html[data-theme="dark"] .hrm-staff-list article > span strong,
html[data-theme="dark"] .hrm-identity-strip strong,
html[data-theme="dark"] .hrm-consultant-toggle strong,
html[data-theme="dark"] .supplier-metrics strong,
html[data-theme="dark"] .supplier-copy strong,
html[data-theme="dark"] .supplier-balance strong,
html[data-theme="dark"] .supplier-identity-strip strong,
html[data-theme="dark"] .accounting-command-bar h1,
html[data-theme="dark"] .accounting-metrics strong,
html[data-theme="dark"] .voucher-type-card strong,
html[data-theme="dark"] .voucher-control-strip strong,
html[data-theme="dark"] .coa-row strong,
html[data-theme="dark"] .customer-directory-metrics strong,
html[data-theme="dark"] .customer-record-copy strong,
html[data-theme="dark"] .customer-record-balance strong,
html[data-theme="dark"] .customer-balance-panel strong,
html[data-theme="dark"] .customer-overview-heading h2,
html[data-theme="dark"] .customer-overview-metrics strong,
html[data-theme="dark"] .customer-receivable-position h3,
html[data-theme="dark"] .customer-recent-activity h3,
html[data-theme="dark"] .customer-currency-list b,
html[data-theme="dark"] .customer-recent-activity a strong,
html[data-theme="dark"] .customer-recent-activity a b,
html[data-theme="dark"] .customer-overview-empty strong,
html[data-theme="dark"] .customer-automation-grid strong,
html[data-theme="dark"] .customer-permission-switch strong {
    color: #e4eef5;
}

html[data-theme="dark"] .booking-command-bar p,
html[data-theme="dark"] .booking-command-metrics small,
html[data-theme="dark"] .booking-context-strip small,
html[data-theme="dark"] .traveler-cards small,
html[data-theme="dark"] .service-card-copy small,
html[data-theme="dark"] .service-card-copy span,
html[data-theme="dark"] .form-section-heading p,
html[data-theme="dark"] .sticky-editor-actions span,
html[data-theme="dark"] .workbench-switch small,
html[data-theme="dark"] .hrm-metric-grid small,
html[data-theme="dark"] .hrm-staff-list article > span small,
html[data-theme="dark"] .hrm-staff-list article > span em,
html[data-theme="dark"] .hrm-identity-strip small,
html[data-theme="dark"] .hrm-consultant-toggle small,
html[data-theme="dark"] .supplier-metrics small,
html[data-theme="dark"] .supplier-copy small,
html[data-theme="dark"] .supplier-copy em,
html[data-theme="dark"] .supplier-copy span,
html[data-theme="dark"] .supplier-balance small,
html[data-theme="dark"] .supplier-identity-strip small,
html[data-theme="dark"] .accounting-command-bar p,
html[data-theme="dark"] .accounting-metrics small,
html[data-theme="dark"] .voucher-type-card small,
html[data-theme="dark"] .voucher-control-strip small,
html[data-theme="dark"] .coa-row small,
html[data-theme="dark"] .coa-row span,
html[data-theme="dark"] .customer-directory-metrics small,
html[data-theme="dark"] .customer-record-copy small,
html[data-theme="dark"] .customer-record-copy span,
html[data-theme="dark"] .customer-record-balance small,
html[data-theme="dark"] .customer-balance-panel small,
html[data-theme="dark"] .customer-balance-panel span,
html[data-theme="dark"] .customer-overview-heading p,
html[data-theme="dark"] .customer-overview-metrics small,
html[data-theme="dark"] .customer-overview-metrics em,
html[data-theme="dark"] .customer-receivable-position p,
html[data-theme="dark"] .customer-recent-activity p,
html[data-theme="dark"] .customer-currency-list small,
html[data-theme="dark"] .customer-recent-activity a small,
html[data-theme="dark"] .customer-recent-activity a em,
html[data-theme="dark"] .customer-automation-grid small,
html[data-theme="dark"] .customer-permission-switch small {
    color: #8da4b4;
}

html[data-theme="dark"] .customer-overview-heading,
html[data-theme="dark"] .customer-recent-activity > a {
    border-color: #2d4857;
}

html[data-theme="dark"] .customer-receivable-position > header > a,
html[data-theme="dark"] .customer-recent-activity > a > i {
    color: #73d2c8;
    background: #112c35;
    border-color: #365965;
}

html[data-theme="dark"] .flight-segment label,
html[data-theme="dark"] .erp-field-grid label,
html[data-theme="dark"] .commercial-grid label small,
html[data-theme="dark"] .hotel-stay-grid label small {
    color: #a9bdcb;
}

html[data-theme="dark"] .select2-container--default .select2-selection--single,
html[data-theme="dark"] .select2-dropdown,
html[data-theme="dark"] .select2-search--dropdown,
html[data-theme="dark"] .select2-search--dropdown .select2-search__field {
    color: #dce8f2;
    background: #0b1927;
    border-color: #30485b;
}

html[data-theme="dark"] .select2-container--default .select2-selection--single .select2-selection__rendered,
html[data-theme="dark"] .select2-results__option {
    color: #dce8f2;
}

html[data-theme="dark"] .select2-container--default .select2-results__option[aria-selected="true"] {
    background: #18354a;
}

html[data-theme="dark"] .line-scope-strip,
html[data-theme="dark"] .line-scope-note,
html[data-theme="dark"] .bulk-apply-option,
html[data-theme="dark"] .pricing-basis-card,
html[data-theme="dark"] .commercial-calculation > div {
    color: #b9ced9;
    background: linear-gradient(145deg, #102333, #0b1a27);
    border-color: #2c4557;
    box-shadow: inset 0 1px rgba(255, 255, 255, .035);
}

html[data-theme="dark"] .commercial-calculation {
    background: #2c4557;
    border-color: #2c4557;
}

html[data-theme="dark"] .line-scope-strip strong,
html[data-theme="dark"] .line-scope-note strong,
html[data-theme="dark"] .bulk-apply-option strong,
html[data-theme="dark"] .pricing-basis-selector legend,
html[data-theme="dark"] .pricing-basis-card strong,
html[data-theme="dark"] .commercial-calculation strong {
    color: #e4eef5;
}

html[data-theme="dark"] .line-scope-strip small,
html[data-theme="dark"] .bulk-apply-option small,
html[data-theme="dark"] .pricing-basis-card small,
html[data-theme="dark"] .commercial-calculation small,
html[data-theme="dark"] .commercial-calculation span {
    color: #8da4b4;
}

html[data-theme="dark"] .bulk-apply-option:has(input:checked),
html[data-theme="dark"] .pricing-basis-card:has(input:checked) {
    background: linear-gradient(145deg, #123333, #0e292c);
    border-color: #2d7772;
}
