/* Dashboard-only responsive fixes. Keep the sidebar motion aligned with page direction. */
.dashboard-main,
.dashboard-main-body {
    box-sizing: border-box;
    min-width: 0;
    max-width: 100%;
}

.dashboard-main {
    flex-wrap: nowrap;
    margin-inline-start: 20rem;
    margin-left: 0;
}

body.twin-collapsed .dashboard-main {
    margin-inline-start: 4.5rem;
    margin-left: 0;
}

.dashboard-main-body > *,
.dashboard-main-body :is(.grid, .flex) > * {
    min-width: 0;
}

.dashboard-main-body :where(input, select, textarea, button, img, svg, video, iframe, canvas, .select2-container) {
    box-sizing: border-box;
    max-width: 100%;
}

.dashboard-main-body :where(p, h1, h2, h3, h4, h5, h6, label, a, li, td, th, dd, dt) {
    overflow-wrap: anywhere;
}

.dashboard-main-body :where(.overflow-x-auto, .table-responsive) {
    max-width: 100%;
    overscroll-behavior-inline: contain;
}

.twin-sidebar {
    box-sizing: border-box;
    inline-size: min(20rem, 100%);
    max-inline-size: 100%;
}

.twin-panel {
    min-inline-size: 0;
}

.navbar-header,
.navbar-header > div,
.dashboard-header-title,
.dashboard-header-actions,
.dashboard-header-actions > * {
    box-sizing: border-box;
    min-width: 0;
    max-width: 100%;
}

.dashboard-header-title > span,
.dashboard-user-name {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dashboard-header-actions {
    flex-wrap: wrap;
}

.organization-switcher {
    min-width: 0;
    max-width: 100%;
}

.organization-switcher form,
.organization-switcher select {
    min-width: 0;
    max-width: 100%;
}

.notification-bell-menu {
    inset-inline-end: 0;
}

.d-footer,
.d-footer > div {
    box-sizing: border-box;
    min-width: 0;
    max-width: 100%;
}

.d-footer > div {
    flex-wrap: wrap;
}

.twin-backdrop {
    max-width: 100vw;
}

.dashboard-main-body .lab-credit-form,
.dashboard-main-body .lab-credit-form > *,
.dashboard-main-body .lab-credit-reject-form > * {
    min-width: 0;
    max-width: 100%;
}

.dashboard-main-body .lab-credit-reject-form {
    align-items: stretch;
}

.dashboard-main-body .lab-credit-reject-form label {
    flex-basis: 100%;
}

.dashboard-main-body .lab-credit-reject-form button {
    min-height: 2.75rem;
}

.quota-summary {
    min-width: 0;
}

.quota-summary__title {
    margin: 0;
    font-size: 1rem;
    line-height: 1.5rem;
    font-weight: 600;
}

.lab-dashboard-shell {
    width: 100%;
    max-width: 80rem;
    margin-inline: auto;
    padding: 1rem;
}

.lab-dashboard-header {
    align-items: stretch;
}

.lab-dashboard-button,
.lab-order-action {
    min-height: 2.75rem;
}

.lab-dashboard-action {
    min-height: 5rem;
}

.lab-dashboard-empty {
    width: 100%;
    max-width: 48rem;
}

.lab-order-code {
    overflow-wrap: anywhere;
}

.lab-orders-mobile {
    display: block;
}

.lab-orders-desktop {
    display: none;
}

@media (min-width: 768px) {
    .lab-orders-mobile {
        display: none;
    }

    .lab-orders-desktop {
        display: block;
    }
}

@media (min-width: 640px) {
    .lab-dashboard-shell {
        padding: 1.5rem;
    }

    .lab-dashboard-header {
        align-items: center;
        justify-content: space-between;
    }

    .lab-dashboard-empty {
        text-align: right;
    }
}

@media (max-width: 1199px) {
    .navbar-header {
        height: auto;
        min-height: 4.5rem;
        box-sizing: border-box;
        padding-top: 4.5rem;
        padding-bottom: 1rem;
    }

    .dashboard-main,
    body.twin-collapsed .dashboard-main {
        width: auto;
        margin-inline-start: 0;
        margin-left: 0;
    }

    html[dir="rtl"] .twin-sidebar {
        inset-inline-start: 0;
        transform: translateX(100%);
        inline-size: min(20rem, 100%);
        max-width: 100%;
    }

    html[dir="rtl"] .twin-sidebar.is-open {
        transform: translateX(0);
    }

    html[dir="ltr"] .twin-sidebar {
        inset-inline-start: 0;
        transform: translateX(-100%);
        inline-size: min(20rem, 100%);
        max-width: 100%;
    }

    html[dir="ltr"] .twin-sidebar.is-open {
        transform: translateX(0);
    }

    html[dir="rtl"] .twin-mobile-toggle {
        right: 16px;
        left: auto;
    }

    html[dir="ltr"] .twin-mobile-toggle {
        left: 16px;
        right: auto;
    }

    html[dir="rtl"] .dashboard-main,
    html[dir="rtl"] body.twin-collapsed .dashboard-main,
    html[dir="ltr"] .dashboard-main,
    html[dir="ltr"] body.twin-collapsed .dashboard-main {
        margin-inline-start: 0;
        margin-left: 0;
    }
}

@media (max-width: 767.98px) {
    .dashboard-main-body {
        padding: .75rem;
    }

    .navbar-header > div {
        flex-wrap: wrap;
        gap: .75rem;
    }

    .dashboard-header-title {
        flex: 1 1 100%;
        justify-content: flex-start;
    }

    .dashboard-header-actions {
        flex: 1 1 100%;
        justify-content: flex-start;
        gap: .5rem;
    }

    .organization-switcher {
        flex: 1 1 100%;
    }

    .organization-switcher form {
        flex-wrap: wrap;
    }

    .dashboard-user-name {
        max-width: min(12rem, calc(100vw - 9rem));
    }

    .dashboard-main-body .lab-credit-form {
        grid-template-columns: minmax(0, 1fr);
    }

    .dashboard-main-body .lab-credit-form > * {
        grid-column: 1 / -1;
    }
}

@media (max-width: 359.98px) {
    .dashboard-main-body {
        padding: .5rem;
    }

    .dashboard-header-actions {
        column-gap: .375rem;
    }
}

.lab-order-page{max-width:68rem;margin:0 auto;padding:1.25rem;color:#172033}.lab-order-intro,.lab-order-section__title,.lab-order-summary dl>div{display:flex;align-items:center;justify-content:space-between;gap:1rem}.lab-order-intro{margin-bottom:1.25rem}.lab-order-intro h1{font-size:1.75rem;font-weight:700;margin:.15rem 0}.lab-order-intro p,.lab-order-intro span,.lab-order-section__title p,.lab-field-hint{color:#687386;font-size:.875rem}.lab-order-intro a,.lab-tooth-clear{color:#2563eb}.lab-order-form{display:grid;gap:1rem}.lab-order-section,.lab-order-summary{background:#fff;border:1px solid #e2e8f0;border-radius:1rem;padding:1.25rem;box-shadow:0 4px 16px #0f172a08}.lab-order-section__title{justify-content:flex-start;margin-bottom:1.15rem}.lab-order-section__title>span{display:grid;place-items:center;width:2.25rem;height:2.25rem;border-radius:50%;background:#eff6ff;color:#2563eb;font-weight:700}.lab-order-section h2,.lab-order-summary h2{font-size:1.1rem;font-weight:700;margin:0}.lab-order-label{display:block;font-weight:600;margin:.75rem 0 .4rem}.lab-order-label span{color:#64748b;font-size:.8rem;font-weight:400}.lab-order-input{box-sizing:border-box;width:100%;border:1px solid #cbd5e1;border-radius:.75rem;background:#fff;padding:.75rem .9rem;color:inherit}.lab-order-input:focus,.lab-tooth:focus-visible{outline:3px solid #93c5fd;outline-offset:2px;border-color:#2563eb}.lab-order-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:1rem}.lab-order-errors{border-radius:.75rem;background:#fef2f2;color:#991b1b;padding:1rem}.lab-schema-note{border-right:3px solid #f59e0b;background:#fffbeb;padding:.65rem .8rem;color:#854d0e;font-size:.85rem}.lab-required{color:#dc2626;font-size:.78rem}.lab-order-summary{background:linear-gradient(135deg,#f8fbff,#f0f7ff)}.lab-order-summary>div:first-child p{color:#64748b;font-size:.85rem}.lab-order-summary dl{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.65rem 1.5rem;margin:1rem 0 0}.lab-order-summary dl>div{border-bottom:1px solid #dbeafe;padding:.55rem 0}.lab-order-summary dt{color:#64748b}.lab-order-summary dd{margin:0;font-weight:600;text-align:left}.lab-order-summary dl>div:nth-last-child(-n+2) dd{color:#1d4ed8}.lab-order-actions{display:flex;align-items:center;gap:1rem;flex-wrap:wrap}.lab-order-actions span{font-size:.85rem;color:#64748b}.lab-order-submit{border:0;border-radius:.8rem;background:#2563eb;color:white;padding:.85rem 1.25rem;font-weight:700;cursor:pointer}.lab-order-submit:disabled{opacity:.55;cursor:not-allowed}.lab-sender-fields[hidden],.lab-service-field[hidden]{display:none!important}.lab-tooth-selector{margin-top:1.25rem;border:1px solid #e2e8f0;border-radius:1rem;padding:1rem}.lab-tooth-selector__head{display:flex;justify-content:space-between;align-items:center;gap:1rem}.lab-tooth-selector__head h3{font-weight:700;margin:0}.lab-tooth-selector__head p{font-size:.83rem;color:#64748b;margin:.3rem 0}.lab-tooth-clear{background:none;border:0;cursor:pointer}.lab-tooth-quadrants{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.75rem;margin-top:1rem}.lab-tooth-quadrant{min-width:0;border:1px solid #e2e8f0;border-radius:.8rem;padding:.65rem}.lab-tooth-quadrant legend{font-size:.82rem;font-weight:600;color:#475569;padding:0 .3rem}.lab-tooth-row{display:flex;justify-content:center;gap:.25rem}.lab-tooth{position:relative;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:.05rem;min-width:2.35rem;min-height:3.2rem;border:1px solid #cbd5e1;border-radius:.65rem;background:#fff;color:#334155;cursor:pointer;padding:.2rem}.lab-tooth svg{width:1.35rem;height:1.8rem;fill:#e2e8f0;stroke:#64748b;stroke-width:1.2}.lab-tooth span{font-size:.7rem;font-weight:700}.lab-tooth[aria-pressed=true]{background:#dbeafe;border-color:#2563eb;color:#1d4ed8;box-shadow:inset 0 0 0 1px #2563eb}.lab-tooth[aria-pressed=true] svg{fill:#60a5fa;stroke:#1d4ed8}.lab-tooth-selected{margin-top:.8rem}.lab-tooth-selected strong{font-size:.85rem}.lab-tooth-selected [data-tooth-chips]{display:flex;gap:.35rem;flex-wrap:wrap;margin-top:.4rem}.lab-tooth-chip{border:1px solid #bfdbfe;border-radius:999px;background:#eff6ff;color:#1d4ed8;padding:.25rem .65rem;cursor:pointer}.lab-tooth-fallback[hidden]{display:none}.lab-tooth-fallback>div{display:flex;flex-wrap:wrap;gap:.4rem}.lab-tooth-fallback label{padding:.35rem;border:1px solid #ddd;border-radius:.4rem}
@media(max-width:700px){.lab-order-page{padding:.75rem}.lab-order-section,.lab-order-summary{padding:1rem}.lab-order-grid,.lab-order-summary dl{grid-template-columns:1fr}.lab-tooth-quadrants{grid-template-columns:1fr}.lab-tooth-row{justify-content:space-between;gap:.15rem}.lab-tooth{flex:1;min-width:0;min-height:3rem}.lab-tooth-selector__head{align-items:flex-start}.lab-order-intro{align-items:flex-start}}
.lab-order-intro a.lab-order-submit{color:#fff;text-decoration:none}

.lab-order-page--form{box-sizing:border-box;width:100%;max-width:none;min-width:0;margin:0;padding:0;text-align:right}
.lab-order-page--form .lab-order-form,.lab-order-page--form .lab-order-section,.lab-order-page--form .lab-order-summary{width:100%;min-width:0;box-sizing:border-box}
.lab-order-page--form .lab-order-grid>*{min-width:0}
.lab-order-page--form .form-group{min-width:0;margin:0}
.lab-order-page--form label,.lab-order-page--form .help-block,.lab-order-page--form .lab-order-errors{text-align:right}
.lab-order-page--form .form-group>label{display:block;margin-bottom:.5rem}
.lab-order-page--form .selection,.lab-order-page--form .select2-selection{display:block;width:100%}
.lab-order-page--form .lab-service-field-setting>span.lab-order-input{display:block}
.lab-order-page--form [hidden]{display:none!important}
.lab-order-page--form .lab-order-sender-hint:empty{display:none}

.lab-tooth-submit-input{display:none}
.lab-tooth svg,.lab-tooth svg *{pointer-events:none}
.lab-order-section .cke{width:100%!important;border:1px solid #cbd5e1;border-radius:.75rem;overflow:hidden}.lab-order-section .cke_top,.lab-order-section .cke_bottom{background:#f8fafc}
.lab-date-picker-field{position:relative}.lab-date-picker-field .form-group{margin:0}.lab-date-picker-field input{padding-left:3.25rem}.lab-date-picker-button{position:absolute;left:.45rem;bottom:.45rem;display:grid;place-items:center;width:2.5rem;height:2.5rem;border:0;border-radius:.55rem;background:#eff6ff;color:#1d4ed8;cursor:pointer}.lab-date-picker-button:hover,.lab-date-picker-button:focus-visible{background:#dbeafe;outline:2px solid #93c5fd}


.lab-order-sender-type{width:100%;min-width:0;margin-bottom:.75rem}.lab-order-sender-type .lab-order-label{margin-top:0}.lab-sender-fields--grid:not([hidden]){display:grid;grid-template-columns:repeat(2,minmax(0,1fr));align-items:start;gap:.75rem 1rem}.lab-order-sender-control{min-width:0}.lab-order-sender-control .lab-order-label{margin-top:0}.lab-order-sender-hint{grid-column:1/-1;margin:0;min-width:0}.lab-sender-fields--grid .form-group{margin:0}@media(max-width:700px){.lab-sender-fields--grid:not([hidden]){grid-template-columns:1fr}}

