:root {
    --teal: #087f78;
    --teal-dark: #08635f;
    --teal-soft: #e7f6f3;
    --navy: #18252f;
    --muted: #74828e;
    --border: #e7ecef;
    --bg: #f5f7f8;
    --white: #fff;
    --shadow: 0 2px 9px rgba(24, 51, 61, .045)
}

* {
    box-sizing: border-box
}

html,
body {
    margin: 0;
    min-height: 100%;
    font-family: 'DM Sans', sans-serif;
    color: var(--navy);
    background: var(--bg);
}

button,
input {
    font: inherit
}

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

.app-shell {
    display: flex;
    min-height: 100vh
}

.sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    width: 248px;
    background: #fff;
    border-right: 1px solid var(--border);
    padding: 25px 16px 20px;
    display: flex;
    flex-direction: column;
    z-index: 20;
    overflow-y: auto;
    overflow-x: hidden;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: #c9d7d9 transparent
}

.sidebar::-webkit-scrollbar {
    width: 6px
}

.sidebar::-webkit-scrollbar-track {
    background: transparent
}

.sidebar::-webkit-scrollbar-thumb {
    background: #c9d7d9;
    border-radius: 999px
}

.sidebar .side-nav {
    flex: 0 0 auto
}

.sidebar .sidebar-help {
    margin-top: 24px;
    flex: 0 0 auto
}

.brand {
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 0 10px 24px
}

.brand-mark {
    width: 39px;
    height: 39px;
    border-radius: 11px;
    display: grid;
    place-items: center;
    background: var(--teal);
    color: #fff;
    font-size: 20px;
    box-shadow: 0 5px 12px rgba(8, 127, 120, .25)
}

.brand>span:last-child {
    display: flex;
    flex-direction: column
}

.brand strong {
    font: 800 19px/21px Manrope
}

.brand small {
    font-size: 10px;
    color: #84919a;
    letter-spacing: .3px
}

.side-nav {
    display: flex;
    flex-direction: column;
    gap: 3px
}

.nav-label {
    font-size: 10px;
    font-weight: 700;
    color: #a2abb1;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin: 17px 11px 6px
}

.nav-link {
    min-height: 41px;
    padding: 10px 12px;
    display: flex;
    align-items: center;
    gap: 12px;
    border-radius: 8px;
    color: #56646e;
    font-size: 13px;
    font-weight: 500
}

.nav-link i {
    font-size: 16px;
    width: 18px
}

.nav-link:hover,
.nav-link.active {
    background: var(--teal-soft);
    color: var(--teal);
    font-weight: 700
}

.nav-badge {
    margin-left: auto;
    color: #fff;
    background: var(--teal);
    border-radius: 20px;
    min-width: 20px;
    padding: 1px 6px;
    text-align: center;
    font-size: 10px
}

.nav-badge.amber {
    background: #ed9a29
}

.sidebar-help {
    margin-top: auto;
    padding: 14px;
    border-radius: 10px;
    background: #f1f8f7;
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--teal)
}

.sidebar-help>i {
    font-size: 20px
}

.sidebar-help div {
    display: flex;
    flex-direction: column
}

.sidebar-help strong {
    font-size: 11px
}

.sidebar-help small {
    font-size: 9px;
    color: #7c8d90
}

.app-main {
    margin-left: 248px;
    min-width: 0;
    flex: 1;
    display: flex;
    flex-direction: column
}

.topbar {
    height: 73px;
    padding: 0 31px;
    background: #fff;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 10
}

.topbar-title {
    display: flex;
    flex-direction: column
}

.topbar-title strong {
    font: 700 15px Manrope
}

.topbar-title span {
    font-size: 10px;
    color: #8a959d;
    margin-top: 2px
}

.topbar-actions {
    display: flex;
    align-items: center;
    gap: 10px
}

.icon-button,
.more {
    border: 0;
    background: transparent;
    color: #64747e;
    font-size: 17px;
    padding: 7px;
    position: relative;
    cursor: pointer
}

.icon-button b {
    position: absolute;
    width: 6px;
    height: 6px;
    background: #e95c5c;
    border-radius: 50%;
    right: 5px;
    top: 5px;
    border: 1px solid #fff
}

.topbar-separator {
    width: 1px;
    height: 26px;
    background: var(--border);
    margin: 0 4px
}

.avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #d8eeea;
    color: var(--teal);
    display: grid;
    place-items: center;
    font-size: 11px;
    font-weight: 800
}

.user-meta {
    display: flex;
    flex-direction: column;
    min-width: 110px
}

.user-meta strong {
    font-size: 11px
}

.user-meta span {
    font-size: 9px;
    color: #8c979e
}

.user-chevron {
    font-size: 11px;
    color: #89959c
}

.menu-button {
    display: none
}

.page-content {
    padding: 31px;
    flex: 1;
    max-width: 1530px;
    width: 100%;
    margin: 0 auto
}

.welcome-row,
.page-heading {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px
}

.eyebrow {
    font-size: 9px;
    letter-spacing: 1.4px;
    color: var(--teal);
    font-weight: 800
}

.welcome-row h1,
.page-heading h1 {
    font: 800 25px Manrope;
    margin: 5px 0 3px
}

.welcome-row p,
.page-heading p {
    font-size: 12px;
    color: var(--muted);
    margin: 0
}

.btn-primary,
.btn-outline {
    border: 0;
    border-radius: 8px;
    padding: 10px 16px;
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px
}

.btn-primary {
    color: #fff;
    background: var(--teal);
    box-shadow: 0 4px 10px rgba(8, 127, 120, .18)
}

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

.btn-outline {
    background: #fff;
    border: 1px solid var(--border);
    color: #5d6972
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-bottom: 19px
}

.stat-card {
    background: #fff;
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
    border-radius: 11px;
    padding: 18px;
    display: flex;
    gap: 14px;
    align-items: flex-start;
    position: relative;
    overflow: hidden
}

.stat-card:after {
    content: "";
    position: absolute;
    width: 55px;
    height: 55px;
    border-radius: 50%;
    right: -22px;
    top: -23px;
    background: currentColor;
    opacity: .06
}

.stat-icon {
    width: 41px;
    height: 41px;
    border-radius: 9px;
    display: grid;
    place-items: center;
    font-size: 18px
}

.stat-card>div:last-child {
    display: flex;
    flex-direction: column
}

.stat-card span {
    font-size: 10px;
    color: #75838c
}

.stat-card strong {
    font: 800 25px Manrope;
    margin: 3px 0
}

.stat-card small {
    font-size: 9px;
    color: #98a1a7
}

.stat-card small b {
    color: #33a271
}

.teal {
    color: #07827b
}

.teal .stat-icon {
    background: #e1f5f1
}

.amber {
    color: #d58a21
}

.amber .stat-icon {
    background: #fff1db
}

.blue {
    color: #387bd5
}

.blue .stat-icon {
    background: #e9f1fc
}

.green {
    color: #31a36c
}

.green .stat-icon {
    background: #e6f7ee
}

.dashboard-grid {
    display: grid;
    grid-template-columns: minmax(0, 2.1fr) minmax(270px, .9fr);
    gap: 18px
}

.panel {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 11px;
    box-shadow: var(--shadow)
}

.panel-head {
    padding: 17px 19px 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid #edf0f2
}

.panel-head h3 {
    font: 700 13px Manrope;
    margin: 0 0 3px
}

.panel-head p {
    font-size: 9px;
    color: #909ba2;
    margin: 0
}

.panel-head a {
    font-size: 10px;
    font-weight: 700;
    color: var(--teal)
}

.table-wrap {
    overflow: auto
}

table {
    width: 100%;
    border-collapse: collapse;
    white-space: nowrap
}

th {
    text-align: left;
    background: #fafbfb;
    color: #88949c;
    font-size: 8px;
    text-transform: uppercase;
    letter-spacing: .55px;
    padding: 10px 14px;
    border-bottom: 1px solid #edf0f2
}

td {
    font-size: 10px;
    color: #53616a;
    padding: 11px 14px;
    border-bottom: 1px solid #eff2f3
}

tbody tr:last-child td {
    border-bottom: 0
}

tbody tr:hover {
    background: #fbfdfd
}

.queue-no {
    color: var(--teal);
    font-size: 11px
}

.patient-cell {
    display: flex;
    flex-direction: column
}

.patient-cell strong {
    font-size: 10px;
    color: #283943
}

.patient-cell span {
    font-size: 8px;
    color: #9aa3a8
}

.status {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 8px;
    font-weight: 700
}

.status i {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: currentColor
}

.status.warning {
    color: #b8791e;
    background: #fff4df
}

.status.primary {
    color: #377bcf;
    background: #eaf2fd
}

.status.purple {
    color: #8461c5;
    background: #f0ebfa
}

.status.success {
    color: #2e9964;
    background: #e8f7ef
}

.status.muted {
    color: #7b878e;
    background: #eef1f2
}

.side-stack {
    display: flex;
    flex-direction: column;
    gap: 18px
}

.quick-grid {
    padding: 14px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 9px
}

.quick-grid a {
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 13px 7px;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 5px;
    font-size: 9px;
    font-weight: 600;
    color: #57666e
}

.quick-grid i {
    font-size: 19px;
    color: var(--teal)
}

.quick-grid a:hover {
    background: var(--teal-soft);
    border-color: #c9e8e2
}

.alerts>a {
    display: flex;
    align-items: center;
    padding: 11px 15px;
    gap: 10px;
    border-bottom: 1px solid #eff2f3
}

.alerts>a:last-child {
    border: 0
}

.alerts>a>i {
    margin-left: auto;
    font-size: 10px;
    color: #a3abb0
}

.alert-icon,
.circle {
    width: 33px;
    height: 33px;
    border-radius: 8px;
    display: grid;
    place-items: center
}

.alert-icon.red {
    background: #fceaea;
    color: #d95c5c
}

.alert-icon.amber {
    background: #fff1dc;
    color: #d89027
}

.alerts a div {
    display: flex;
    flex-direction: column
}

.alerts a strong {
    font-size: 9px
}

.alerts a small {
    font-size: 8px;
    color: #929da3
}

.bottom-stats {
    margin-top: 18px;
    display: grid;
    grid-template-columns: 1fr 1fr 2fr;
    gap: 18px
}

.bottom-stats article {
    border: 1px solid var(--border);
    background: #fff;
    border-radius: 10px;
    padding: 14px 17px;
    display: flex;
    align-items: center;
    gap: 11px
}

.circle {
    border-radius: 50%;
    font-size: 15px
}

.circle.purple {
    color: #8b65c7;
    background: #f0ebf8
}

.circle.blue {
    color: #3c81d5;
    background: #eaf2fd
}

.circle.green {
    color: #2c9a65;
    background: #e7f7ef
}

.bottom-stats div {
    display: flex;
    flex-direction: column
}

.bottom-stats span {
    font-size: 9px;
    color: #849098
}

.bottom-stats strong {
    font: 700 16px Manrope;
    margin-top: 2px
}

.trend {
    margin-left: auto !important;
    color: #319b68 !important;
    background: #e8f7ef;
    padding: 5px 7px;
    border-radius: 12px
}

footer {
    padding: 18px 31px;
    border-top: 1px solid var(--border);
    font-size: 9px;
    color: #9ba4a9
}

footer span {
    float: right
}

.page-heading {
    margin-bottom: 20px
}

.filter-bar {
    display: flex;
    gap: 9px;
    margin-bottom: 15px
}

.search {
    position: relative;
    flex: 1;
    max-width: 470px
}

.search i,
.input-icon>i:first-child {
    position: absolute;
    left: 13px;
    top: 50%;
    transform: translateY(-50%);
    color: #98a2a8
}

.search input {
    width: 100%;
    height: 37px;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 0 12px 0 37px;
    background: #fff;
    font-size: 10px;
    outline: none
}

.module-panel .panel-head {
    padding: 16px 19px
}

.module-panel td,
.module-panel th {
    padding: 14px 17px
}

.table-action {
    border: 0;
    background: var(--teal-soft);
    color: var(--teal);
    border-radius: 6px;
    padding: 6px 9px;
    font-size: 9px;
    font-weight: 700
}

.pagination {
    padding: 13px 17px;
    border-top: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: #8b969d;
    font-size: 9px
}

.pagination button {
    width: 27px;
    height: 27px;
    border: 1px solid var(--border);
    background: #fff;
    color: #68767e;
    font-size: 9px
}

.pagination button.current {
    background: var(--teal);
    color: #fff;
    border-color: var(--teal)
}

.login-body {
    background: #fff
}

.login-shell {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 1.05fr .95fr
}

.login-hero {
    background: linear-gradient(145deg, #075f5b, #09877e);
    padding: 42px 7vw;
    position: relative;
    overflow: hidden;
    color: #fff;
    display: flex;
    flex-direction: column
}

.login-hero:after,
.login-hero:before {
    content: "";
    position: absolute;
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: 50%
}

.login-hero:before {
    width: 560px;
    height: 560px;
    right: -270px;
    top: -210px
}

.login-hero:after {
    width: 380px;
    height: 380px;
    left: -180px;
    bottom: -220px
}

.brand.light {
    padding: 0;
    color: #fff;
    z-index: 1
}

.brand.light .brand-mark {
    background: #fff;
    color: var(--teal)
}

.brand.light small {
    color: rgba(255, 255, 255, .65)
}

.hero-copy {
    margin: auto 0;
    max-width: 510px;
    z-index: 1
}

.hero-copy .eyebrow {
    color: #bce2dd;
    background: rgba(255, 255, 255, .1);
    padding: 7px 10px;
    border-radius: 20px
}

.hero-copy h1 {
    font: 800 49px/1.14 Manrope;
    margin: 22px 0 18px;
    letter-spacing: -1.5px
}

.hero-copy h1 em {
    color: #8fddd4;
    font-style: normal
}

.hero-copy p {
    font-size: 14px;
    line-height: 1.7;
    color: rgba(255, 255, 255, .74);
    max-width: 430px
}

.hero-foot {
    display: flex;
    gap: 27px;
    font-size: 10px;
    color: rgba(255, 255, 255, .7);
    z-index: 1
}

.hero-foot i {
    color: #8edbd2;
    margin-right: 5px
}

.login-panel {
    display: grid;
    place-items: center;
    padding: 50px
}

.login-card {
    width: 100%;
    max-width: 385px
}

.login-kicker {
    color: var(--teal);
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 1.3px
}

.login-card h2 {
    font: 800 28px Manrope;
    margin: 8px 0 5px
}

.login-card>p {
    color: #829098;
    font-size: 12px;
    margin: 0 0 30px
}

.login-card label {
    display: block;
    font-size: 10px;
    font-weight: 700;
    margin: 15px 0 7px
}

.input-icon {
    position: relative
}

.input-icon input {
    width: 100%;
    height: 45px;
    border: 1px solid #dfe6e9;
    border-radius: 8px;
    padding: 0 42px 0 38px;
    outline: none;
    font-size: 11px
}

.input-icon input:focus {
    border-color: var(--teal);
    box-shadow: 0 0 0 3px var(--teal-soft)
}

.input-icon .eye {
    position: absolute;
    right: 13px;
    top: 14px;
    color: #909ca3
}

.form-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 15px 0 19px;
    font-size: 10px
}

.form-row .check {
    display: flex;
    align-items: center;
    gap: 7px;
    margin: 0;
    color: #65737c;
    font-weight: 500
}

.form-row a {
    color: var(--teal);
    font-weight: 700
}

.btn-block {
    width: 100%;
    height: 45px;
    justify-content: center
}

.login-note {
    display: block;
    text-align: center;
    color: #98a1a7;
    margin-top: 22px;
    font-size: 9px
}

.mobile-brand {
    display: none
}

@media(max-width:1000px) {
    .sidebar {
        transform: translateX(-100%);
        transition: .2s
    }

    .sidebar.open {
        transform: translateX(0);
        box-shadow: 10px 0 40px rgba(0, 0, 0, .12)
    }

    .app-main {
        margin-left: 0
    }

    .menu-button {
        display: block
    }

    .topbar {
        justify-content: flex-start;
        gap: 12px
    }

    .topbar-actions {
        margin-left: auto
    }

    .stats-grid {
        grid-template-columns: 1fr 1fr
    }

    .dashboard-grid {
        grid-template-columns: 1fr
    }

    .side-stack {
        display: grid;
        grid-template-columns: 1fr 1fr
    }

    .login-hero {
        padding: 35px
    }

    .hero-copy h1 {
        font-size: 39px
    }
}

@media(max-width:700px) {
    .page-content {
        padding: 20px 14px
    }

    .topbar {
        padding: 0 14px
    }

    .user-meta,
    .user-chevron {
        display: none
    }

    .welcome-row,
    .page-heading {
        align-items: flex-start;
        gap: 15px
    }

    .welcome-row h1,
    .page-heading h1 {
        font-size: 21px
    }

    .stats-grid {
        grid-template-columns: 1fr
    }

    .side-stack,
    .bottom-stats {
        grid-template-columns: 1fr
    }

    .bottom-stats {
        display: grid
    }

    .filter-bar {
        flex-wrap: wrap
    }

    .search {
        max-width: none;
        flex-basis: 100%
    }

    .login-shell {
        display: block
    }

    .login-hero {
        display: none
    }

    .login-panel {
        min-height: 100vh;
        padding: 30px 22px
    }

    .mobile-brand {
        display: flex;
        align-items: center;
        gap: 10px;
        margin-bottom: 45px
    }

    .login-card h2 {
        font-size: 25px
    }
}

html,
body {
    font-size: 14px
}

.page-content td,
.page-content th,
.page-content input,
.page-content select,
.page-content textarea,
.page-content button,
.page-content p,
.nav-link {
    font-size: 14px
}

.custom-medical-form input,
.custom-medical-form select,
.custom-medical-form textarea {
    padding: 8px;
    border: 1px solid #ccd6da;
    border-radius: 4px;
    max-width: 100%
}

.custom-medical-form label {
    display: block;
    margin: 8px 0
}

.toast-notification {
    position: fixed;
    top: 85px;
    right: 20px;
    z-index: 1000;
    background: #e7f6f3;
    border: 1px solid #087f78;
    padding: 16px;
    border-radius: 8px;
    box-shadow: 0 5px 20px #0002;
    max-width: 90vw
}

.toast-notification button {
    border: 0;
    background: transparent;
    margin-left: 15px
}

.patient-summary-card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 24px 28px;
    margin-bottom: 18px;
    box-shadow: var(--shadow);
}

.patient-summary-name {
    font: 700 22px Manrope;
    color: var(--navy);
}

.patient-summary-meta {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px dashed #d9e1e3;
    color: #596970;
    font-size: 16px;
}

.patient-summary-visit {
    margin-top: 8px;
    color: var(--muted);
    font-size: 13px;
}

.soap-card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow);
}

.soap-card-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 24px 28px 14px;
}

.soap-card-heading h2 {
    margin: 0;
    font: 800 23px Manrope;
    letter-spacing: .04em;
}

.soap-card-heading span {
    color: var(--teal);
    background: var(--teal-soft);
    border-radius: 999px;
    padding: 6px 11px;
    font-size: 12px;
    font-weight: 700;
}

.soap-row {
    min-height: 92px;
    padding: 20px 28px;
    display: flex;
    align-items: center;
    gap: 14px;
    border-top: 1px solid #edf0f2;
}

.soap-row-label {
    color: #59636a;
    font-size: 18px;
}

.soap-row-value {
    flex: 1;
    color: #273940;
    font-size: 14px;
    white-space: pre-wrap;
}

.soap-action {
    margin-left: auto;
    border: 1px solid #d8e0e2;
    border-radius: 999px;
    padding: 8px 18px;
    background: #fff;
    color: #29343a;
    font-size: 14px;
    cursor: pointer;
    white-space: nowrap;
}

.soap-action:hover {
    border-color: var(--teal);
    color: var(--teal);
    background: var(--teal-soft);
}

.soap-action-edit {
    color: #168ea4;
}

.soap-done {
    display: grid;
    place-items: center;
    width: 24px;
    height: 24px;
    border-radius: 6px;
    background: #55d2b1;
    color: #fff;
    font-size: 14px;
}

.soap-row-diagnosis {
    min-height: 100px;
}

.soap-row-diagnosis>div {
    flex: 1;
}

.soap-row-label span {
    color: #8b969b;
    font-size: 13px;
}

.soap-row-help {
    margin-top: 4px;
    color: #a1aaae;
    font-size: 13px;
    line-height: 1.45;
}

.soap-editor {
    display: none;
    padding: 24px 28px;
    border-top: 1px solid #edf0f2;
    background: #fbfdfd;
}

.soap-editor.is-visible {
    display: block;
}

.soap-editor-title {
    margin-bottom: 14px;
    font: 700 16px Manrope;
}

.soap-history {
    border-top: 1px solid #edf0f2;
    padding: 18px 28px;
    color: #68767c;
}

.soap-history summary {
    cursor: pointer;
    font-weight: 700;
}

.soap-history article {
    margin-top: 15px;
    padding: 14px;
    border-radius: 8px;
    background: #f7f9f9;
}

.soap-history article p {
    margin: 7px 0 0;
    white-space: pre-wrap;
}

.soap-accordion {
    border-top: 1px solid #edf0f2;
}

.soap-accordion summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    padding: 18px 28px;
    cursor: pointer;
    list-style: none;
}

.soap-accordion summary::-webkit-details-marker {
    display: none;
}

.soap-accordion summary::after {
    content: '›';
    color: #8c999e;
    font-size: 25px;
    transform: rotate(90deg);
    transition: transform .2s;
}

.soap-accordion[open] summary::after {
    transform: rotate(-90deg);
}

.soap-accordion-title {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.soap-accordion-title strong {
    color: #273940;
    font-size: 16px;
}

.soap-accordion-title small {
    color: #8c999e;
    font-size: 12px;
}

.soap-accordion-status {
    color: #29966f;
    background: #e8f7ef;
    border-radius: 999px;
    padding: 6px 10px;
    font-size: 12px;
    white-space: nowrap;
}

.soap-accordion-body {
    padding: 0 28px 20px;
}

.soap-content-block {
    padding: 13px 0;
    border-top: 1px dashed #e2e8e9;
}

.soap-content-block span {
    color: #637279;
    font-size: 13px;
    font-weight: 700;
}

.soap-content-block p {
    margin: 5px 0 0;
    color: #273940;
    white-space: pre-wrap;
    line-height: 1.55;
}

.soap-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 30px;
    color: #8e9ba0;
    text-align: center;
}

.soap-empty i {
    color: #b8c7ca;
    font-size: 30px;
}

.soap-empty strong {
    color: #607077;
}

.soap-add-button {
    width: calc(100% - 56px);
    margin: 18px 28px 24px;
    padding: 12px 16px;
    border: 1px dashed #9ccfc9;
    border-radius: 9px;
    background: var(--teal-soft);
    color: var(--teal);
    font-weight: 700;
    cursor: pointer;
}

.soap-add-button:hover {
    background: #d4eee9;
}

@media (max-width: 700px) {
    .patient-summary-card {
        padding: 20px;
    }

    .patient-summary-name {
        font-size: 19px;
    }

    .patient-summary-meta {
        font-size: 14px;
    }

    .soap-card-heading,
    .soap-row,
    .soap-editor {
        padding-left: 20px;
        padding-right: 20px;
    }

    .soap-row {
        min-height: 82px;
    }

    .soap-row-label {
        font-size: 16px;
    }

    .soap-row-value {
        max-width: 100%;
    }

    .soap-row-diagnosis {
        align-items: flex-start;
    }

    .soap-action {
        padding: 7px 13px;
        font-size: 13px;
    }

    .soap-accordion summary,
    .soap-accordion-body {
        padding-left: 20px;
        padding-right: 20px;
    }

    .soap-add-button {
        width: calc(100% - 40px);
        margin-left: 20px;
        margin-right: 20px;
    }
}

.access-denied-page {
    min-height: calc(100vh - 170px);
    display: grid;
    place-items: center;
    padding: 24px;
}

.access-denied-card {
    width: min(100%, 560px);
    padding: 42px 40px;
    text-align: center;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 18px;
    box-shadow: 0 12px 35px rgba(24, 51, 61, .08);
}

.access-denied-icon {
    width: 72px;
    height: 72px;
    margin: 0 auto 22px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: #b8791e;
    background: #fff4df;
    font-size: 31px;
}

.access-denied-card h1 {
    margin: 12px 0;
    font: 800 26px/1.25 Manrope;
}

.access-denied-card p {
    margin: 0 auto 26px;
    max-width: 430px;
    color: var(--muted);
    line-height: 1.65;
}

.access-denied-actions {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
}

.access-denied-card small {
    display: block;
    margin-top: 24px;
    color: #9aa5aa;
}

/* Bootstrap form controls and Select2 stay aligned at every breakpoint. */
.page-content .card form .form-label,
.page-content .card form>label,
.page-content .card form .form-check-label {
    display: block;
    width: 100%;
    color: var(--navy);
    font-size: 14px;
    font-weight: 600;
}

.page-content .form-control,
.page-content .form-select,
.page-content .select2-container .select2-selection--single {
    min-height: 42px;
    border-color: var(--border);
    border-radius: 8px;
}

.page-content textarea.form-control {
    min-height: 110px;
    resize: vertical;
}

.select2-container {
    width: 100% !important;
}

.select2-container--bootstrap-5 .select2-selection--single {
    display: flex;
    align-items: center;
    padding: 0 12px;
}

.select2-container--bootstrap-5 .select2-selection--single .select2-selection__arrow {
    top: 8px;
    right: 8px;
}

.select2-container--bootstrap-5 .select2-dropdown {
    border-color: var(--border);
    box-shadow: 0 8px 24px rgba(24, 51, 61, .12);
}

.custom-medical-form .row {
    margin-left: 0;
    margin-right: 0;
}

@media (max-width: 700px) {
    .page-content {
        padding: 20px 14px;
    }

    .page-heading {
        flex-wrap: wrap;
    }

    .page-heading> :last-child {
        width: 100%;
    }

    .page-heading .btn-primary,
    .page-heading .btn-outline {
        width: 100%;
        justify-content: center;
    }

    .page-content .card form {
        padding: 18px !important;
    }

    .table-wrap {
        margin-left: -1px;
        margin-right: -1px;
    }
}

/* Master Rekam Medis: editor template dengan panel pratinjau langsung. */
.mrm-stats {
    margin-bottom: 19px
}

.mrm-actions {
    display: flex;
    align-items: center;
    gap: 9px
}

.mrm-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr);
    gap: 18px;
    align-items: start;
    margin-bottom: 19px
}

.mrm-editor form {
    padding: 19px 20px 22px
}

.mrm-editor .mrm-label {
    display: block;
    width: 100%;
    margin: 0 0 6px;
    color: var(--navy);
    font-size: 13px;
    font-weight: 700
}

.mrm-label-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin: 0 0 6px
}

.mrm-label-row .mrm-help {
    margin: 0
}

.mrm-help {
    display: block;
    color: #8b969d;
    font-size: 12px;
    line-height: 1.5
}

.mrm-help-link {
    color: var(--teal);
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap
}

.mrm-counter {
    color: #9aa5aa;
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap
}

.mrm-code {
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 12.5px;
    line-height: 1.6;
    min-height: 360px;
    background: #fbfdfd
}

.mrm-guide {
    border: 1px dashed #dbe4e6;
    border-radius: 10px;
    padding: 13px 16px;
    background: #fbfdfd;
    color: #5b6a72;
    font-size: 13px
}

.mrm-guide summary {
    cursor: pointer;
    color: var(--teal);
    font-weight: 700
}

.mrm-guide ul {
    margin: 10px 0 0;
    padding-left: 18px
}

.mrm-guide li {
    margin: 5px 0;
    line-height: 1.6
}

.mrm-guide code {
    background: #e9f4f2;
    color: var(--teal-dark);
    border-radius: 4px;
    padding: 1px 5px;
    font-size: 12px
}

.mrm-samples {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 13px
}

.mrm-sample {
    border: 1px dashed #bcd6d3;
    border-radius: 8px;
    background: #fff;
    color: var(--teal);
    padding: 8px 12px;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer
}

.mrm-sample:hover {
    background: var(--teal-soft);
    border-color: var(--teal)
}

.mrm-submit {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    padding-top: 4px
}

.mrm-muted {
    color: #9aa5aa
}

.mrm-list .is-current td {
    background: #f4fbf9
}

/* Panel pratinjau. */
.mrm-preview {
    position: sticky;
    top: 92px
}

.mrm-preview-tools {
    display: flex;
    align-items: center;
    gap: 8px
}

.mrm-mode {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border-radius: 999px;
    padding: 5px 11px;
    background: var(--teal-soft);
    color: var(--teal);
    font-size: 11px;
    font-weight: 700;
    white-space: nowrap
}

.mrm-mode.live {
    background: #fff4df;
    color: #b8791e
}

.mrm-preview-body {
    padding: 17px 19px 19px
}

.mrm-preview-stage {
    border: 1px solid var(--border);
    border-radius: 10px;
    background: #fff;
    padding: 18px;
    min-height: 280px;
    max-height: 620px;
    overflow: auto
}

.mrm-preview-frame {
    width: 100%;
    height: 520px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: #fff;
    vertical-align: top
}

.mrm-preview-alert {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 13px
}

.mrm-empty {
    padding: 34px 20px;
    border: 1px dashed #dfe6e8;
    border-radius: 10px;
    text-align: center;
    color: #93a0a6;
    font-size: 13px
}

.mrm-empty i {
    display: block;
    margin-bottom: 10px;
    color: #c3ced3;
    font-size: 30px
}

.mrm-empty strong {
    display: block;
    margin-bottom: 6px;
    color: #6d7c84;
    font-size: 14px
}

.mrm-preview-note {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin: 14px 0 0;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.6
}

.mrm-preview-note i {
    margin-top: 1px;
    color: var(--teal)
}

.mrm-filter {
    padding: 16px 19px 0;
    margin-bottom: 14px
}

.mrm-filter-status {
    max-width: 210px
}

.mrm-empty-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    padding: 26px 10px;
    color: #93a0a6
}

.mrm-empty-row i {
    font-size: 20px
}

/* Form hasil render template: rapi di pratinjau master maupun halaman rawat jalan. */
.custom-medical-form {
    border: 0;
    margin: 0;
    padding: 0;
    min-width: 0
}

.custom-medical-form fieldset {
    border: 1px solid var(--border);
    border-radius: 10px;
    background: #fff;
    padding: 16px 18px 4px;
    margin: 0 0 16px
}

.custom-medical-form fieldset:last-child {
    margin-bottom: 0
}

.custom-medical-form legend {
    width: auto;
    max-width: 100%;
    margin: 0;
    padding: 0 8px;
    color: var(--teal-dark);
    font: 700 13px Manrope
}

.custom-medical-form label {
    display: block;
    margin: 0 0 14px;
    color: var(--navy);
    font-size: 13px;
    font-weight: 600;
    line-height: 1.5
}

.custom-medical-form input[type="text"],
.custom-medical-form input[type="number"],
.custom-medical-form input[type="date"],
.custom-medical-form input[type="time"],
.custom-medical-form select,
.custom-medical-form textarea {
    display: block;
    width: 100%;
    margin-top: 6px;
    min-height: 40px;
    padding: 8px 10px;
    border: 1px solid #ccd6da;
    border-radius: 8px;
    background: #fff;
    color: #273940;
    font-size: 13px
}

.custom-medical-form input[type="checkbox"],
.custom-medical-form input[type="radio"] {
    width: 16px;
    height: 16px;
    min-height: 0;
    margin: 0 7px 0 0;
    padding: 0;
    vertical-align: -2px;
    accent-color: var(--teal)
}

.custom-medical-form textarea {
    min-height: 84px;
    resize: vertical
}

.custom-medical-form input:focus,
.custom-medical-form select:focus,
.custom-medical-form textarea:focus {
    outline: none;
    border-color: var(--teal);
    box-shadow: 0 0 0 3px rgba(8, 127, 120, .12)
}

.custom-medical-form table {
    width: 100%;
    margin: 0 0 16px;
    border: 1px solid var(--border);
    border-radius: 10px;
    border-collapse: separate;
    border-spacing: 0;
    overflow: hidden;
    white-space: normal
}

.custom-medical-form th {
    padding: 11px 14px;
    background: #f6fafa;
    color: #5c6a72;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0;
    text-transform: none;
    border-bottom: 1px solid var(--border)
}

.custom-medical-form td {
    padding: 11px 14px;
    color: #273940;
    font-size: 13px;
    border-bottom: 1px solid #eff2f3
}

.custom-medical-form tbody tr:last-child td {
    border-bottom: 0
}

.custom-medical-form td input[type="text"],
.custom-medical-form td input[type="number"] {
    margin-top: 0;
    min-height: 36px
}

.custom-medical-form p {
    margin: 0 0 12px
}

.custom-medical-form .row {
    margin-left: 0;
    margin-right: 0
}

@media (max-width: 1000px) {
    .mrm-layout {
        grid-template-columns: 1fr
    }

    .mrm-preview {
        position: static
    }
}

@media (max-width: 700px) {
    .mrm-actions {
        width: 100%
    }

    .mrm-actions .btn-primary,
    .mrm-actions .btn-outline {
        justify-content: center
    }

    .mrm-label-row {
        flex-wrap: wrap
    }

    .mrm-preview-frame {
        height: 420px
    }

    .mrm-filter {
        flex-wrap: wrap
    }

    .mrm-filter-status {
        max-width: none;
        flex-basis: 100%
    }
}

/* Pendaftaran pasien: alur dua langkah yang ringkas. */
.reg-heading-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px
}

.reg-chip {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: #fff;
    padding: 8px 14px;
    color: #5d6972;
    font-size: 12px;
    font-weight: 700
}

.reg-chip i {
    color: var(--teal)
}

.reg-chip-soft {
    border-color: transparent;
    background: var(--teal-soft);
    color: var(--teal);
    padding: 6px 12px;
    font-size: 11px
}

.reg-alert {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    font-size: 13px
}

.reg-toolbar {
    margin-bottom: 19px
}

.reg-toolbar-body {
    display: grid;
    grid-template-columns: minmax(160px, .6fr) minmax(200px, .9fr) auto;
    gap: 13px;
    align-items: end;
    padding: 17px 19px 19px
}

.reg-field {
    min-width: 0
}

.reg-field .search {
    max-width: none
}

.reg-field .search input {
    height: 42px;
    font-size: 14px
}

.reg-field-buttons {
    display: flex;
    align-items: center;
    gap: 9px
}

.reg-field-buttons .btn-primary,
.reg-field-buttons .btn-outline {
    padding: 11px 16px;
    white-space: nowrap
}

.reg-label {
    display: block;
    margin-bottom: 7px;
    color: var(--navy);
    font-size: 13px;
    font-weight: 700
}

.reg-hint {
    display: block;
    margin: 8px 0 0;
    color: #8b969d;
    font-size: 12px;
    line-height: 1.6
}

.reg-hint i {
    color: var(--teal)
}

.reg-flow .col-xl-5,
.reg-flow .col-xl-7 {
    display: flex
}

.registration-layout.step-3-full>.col-xl-4 {
    display: none;
}

.registration-layout.step-3-full>.reg-flow-column {
    width: 100%;
    flex: 0 0 100%;
}

.registration-layout.step-3-full .reg-flow>.row>.col-lg-7 {
    width: 100%;
    flex: 0 0 100%;
}

.reg-step {
    display: flex;
    flex-direction: column;
    width: 100%
}

.reg-step-head {
    display: flex;
    align-items: flex-start;
    gap: 13px;
    padding: 17px 19px;
    border-bottom: 1px solid #edf0f2
}

.reg-step-head>div {
    flex: 1;
    min-width: 0
}

.reg-step-head h3 {
    margin: 0 0 3px;
    font: 700 14px Manrope
}

.reg-step-head p {
    margin: 0;
    color: #909ba2;
    font-size: 12px
}

.reg-step-no {
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    width: 28px;
    height: 28px;
    border-radius: 8px;
    background: var(--teal-soft);
    color: var(--teal);
    font: 800 13px Manrope
}

.reg-step-body {
    flex: 1;
    padding: 19px 19px 13px
}

.reg-step-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 13px;
    padding: 15px 19px 19px;
    border-top: 1px solid #edf0f2
}

.reg-step-foot .reg-hint {
    flex: 1;
    min-width: 200px;
    margin: 0
}

.reg-or {
    position: relative;
    margin: 18px 0 16px;
    border-top: 1px dashed #dfe6e8;
    text-align: center
}

.reg-or span {
    position: relative;
    top: -9px;
    padding: 0 10px;
    background: #fff;
    color: #a5aeb3;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .6px;
    text-transform: uppercase
}

.reg-new-patient {
    border: 1px dashed #dbe4e6;
    border-radius: 10px;
    background: #fbfdfd
}

.reg-new-patient[open] {
    border-style: solid;
    border-color: #cfe3e1;
    background: #f7fcfb
}

.reg-new-patient>summary {
    padding: 13px 15px;
    cursor: pointer;
    color: var(--teal-dark);
    font-size: 13px;
    font-weight: 700
}

.reg-new-patient>summary i {
    margin-right: 6px
}

.reg-new-patient>summary span {
    margin-left: 6px;
    color: #9aa5aa;
    font-size: 11px;
    font-weight: 500
}

.reg-new-body {
    padding: 0 15px 15px
}

.reg-check {
    display: flex;
    align-items: center;
    gap: 9px;
    margin-bottom: 15px;
    color: var(--navy);
    font-size: 13px;
    font-weight: 600
}

.reg-check .form-check-input {
    flex: 0 0 auto;
    width: 17px;
    height: 17px;
    margin: 0
}

.reg-schedule-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
    gap: 12px
}

.reg-schedule {
    display: flex;
    align-items: flex-start;
    gap: 11px;
    margin: 0;
    padding: 14px 15px;
    border: 1px solid var(--border);
    border-radius: 11px;
    background: #fff;
    cursor: pointer;
    transition: border-color .15s ease, background .15s ease
}

.reg-schedule:hover {
    border-color: #bcd6d3;
    background: #fbfdfd
}

.reg-schedule input[type="radio"] {
    flex: 0 0 auto;
    width: 16px;
    height: 16px;
    margin: 3px 0 0;
    accent-color: var(--teal)
}

.reg-schedule-main {
    display: flex;
    flex-direction: column;
    flex: 1;
    gap: 5px;
    min-width: 0
}

.reg-schedule-main strong {
    color: var(--navy);
    font: 700 14px Manrope
}

.reg-schedule-time,
.reg-schedule-quota {
    color: #7b878e;
    font-size: 12px;
    line-height: 1.5
}

.reg-schedule-time i {
    margin-right: 4px;
    color: var(--teal)
}

.reg-schedule-bar {
    display: block;
    height: 6px;
    border-radius: 999px;
    background: #eef2f3;
    overflow: hidden
}

.reg-schedule-bar>span {
    display: block;
    width: var(--used, 0%);
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, #087f78, #55d2b1)
}

.reg-schedule-state {
    flex: 0 0 auto;
    align-self: flex-start;
    padding: 4px 10px;
    border-radius: 999px;
    background: var(--teal-soft);
    color: var(--teal);
    font-size: 11px;
    font-weight: 700;
    white-space: nowrap
}

.reg-schedule:has(input:checked) {
    border-color: var(--teal);
    background: var(--teal-soft);
    box-shadow: 0 0 0 3px rgba(8, 127, 120, .1)
}

.reg-schedule.is-full {
    background: #f7f9f9;
    cursor: not-allowed
}

.reg-schedule.is-full .reg-schedule-state {
    background: #eef1f2;
    color: #7b878e
}

.reg-schedule.is-full strong,
.reg-schedule.is-full .reg-schedule-time,
.reg-schedule.is-full .reg-schedule-quota {
    color: #9aa5aa
}

.reg-schedule.is-full .reg-schedule-bar>span {
    background: #d5dde0
}

.reg-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 7px;
    margin-bottom: 13px;
    padding: 36px 20px;
    border: 1px dashed #dfe6e8;
    border-radius: 11px;
    background: #fbfdfd;
    text-align: center;
    color: #93a0a6;
    font-size: 13px
}

.reg-empty i {
    color: #c3ced3;
    font-size: 28px
}

.reg-empty strong {
    color: #6d7c84;
    font-size: 14px
}

.reg-empty span {
    max-width: 430px;
    line-height: 1.6
}

.reg-list .reg-name {
    display: block;
    color: #283943;
    font-weight: 600
}

.reg-list .reg-sub {
    display: block;
    margin-top: 3px;
    color: #9aa3a8;
    font-size: 12px
}

.reg-empty-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    padding: 26px 10px;
    color: #93a0a6
}

.reg-empty-row i {
    font-size: 20px
}

@media (max-width: 1200px) {
    .reg-toolbar-body {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr)
    }

    .reg-field-action .reg-label {
        display: none
    }
}

@media (max-width: 700px) {
    .reg-heading-meta {
        width: 100%
    }

    .reg-toolbar-body {
        grid-template-columns: 1fr
    }

    .reg-field-buttons .btn-primary,
    .reg-field-buttons .btn-outline {
        flex: 1;
        justify-content: center
    }

    .reg-step-head,
    .reg-step-body,
    .reg-step-foot {
        padding-left: 15px;
        padding-right: 15px
    }

    .reg-step-foot .btn-primary {
        width: 100%;
        justify-content: center
    }
}

/* Pendaftaran pasien: langkah berurutan, hasil pencarian, dan ringkasan pasien. */
.reg-steps {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin: 0 0 19px;
    padding: 0;
    list-style: none
}

.reg-steps-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    border: 1px solid var(--border);
    border-radius: 11px;
    background: #fff;
    box-shadow: var(--shadow)
}

.reg-steps-item.is-current {
    border-color: var(--teal);
    background: var(--teal-soft)
}

.reg-steps-dot {
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #f0f3f4;
    color: #7b878e;
    font: 800 13px Manrope
}

.reg-steps-item.is-current .reg-steps-dot {
    background: var(--teal);
    color: #fff
}

.reg-steps-item.is-done .reg-steps-dot {
    background: #e2f4ef;
    color: #2e9964
}

.reg-steps-text {
    display: flex;
    flex-direction: column;
    min-width: 0
}

.reg-steps-text strong {
    color: var(--navy);
    font: 700 13px Manrope
}

.reg-steps-text small {
    margin-top: 3px;
    color: #93a0a6;
    font-size: 11px;
    line-height: 1.4
}

.reg-steps-item.is-pending .reg-steps-text strong {
    color: #96a1a7
}

.reg-search {
    display: flex;
    align-items: center;
    gap: 9px;
    margin-bottom: 4px
}

.reg-search .search {
    flex: 1;
    max-width: none
}

.reg-search .btn-primary {
    flex: 0 0 auto;
    padding: 11px 16px;
    white-space: nowrap
}

.reg-results {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 430px;
    overflow: auto;
    padding-right: 2px
}

.reg-result {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 11px;
    padding: 12px 14px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: #fff;
    transition: border-color .15s ease, background .15s ease
}

.reg-result:hover {
    border-color: var(--teal);
    background: #f6fcfb
}

.reg-result-main {
    display: flex;
    flex-direction: column;
    min-width: 0
}

.reg-result-main strong {
    color: var(--navy);
    font-size: 14px
}

.reg-result-main small {
    margin-top: 3px;
    color: #93a0a6;
    font-size: 12px
}

.reg-result-go {
    display: inline-flex;
    align-items: center;
    flex: 0 0 auto;
    gap: 5px;
    color: var(--teal);
    font-size: 12px;
    font-weight: 700
}

.reg-selected {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 15px;
    border: 1px solid #cfe3e1;
    border-radius: 11px;
    background: #f4fbf9
}

.reg-selected-icon {
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: #fff;
    color: var(--teal);
    font-size: 18px
}

.reg-selected-text {
    display: flex;
    flex-direction: column;
    min-width: 0
}

.reg-selected-text strong {
    color: var(--navy);
    font: 700 15px Manrope
}

.reg-selected-text small {
    margin-top: 4px;
    color: #7b878e;
    font-size: 12px;
    line-height: 1.5
}

.reg-selected-change {
    margin-top: 12px;
    padding: 9px 14px
}

.reg-hint-center {
    text-align: center
}

.reg-link {
    color: var(--teal);
    font-weight: 700
}

.reg-data {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin: 0
}

.reg-data>div {
    padding: 11px 13px;
    border: 1px solid var(--border);
    border-radius: 9px;
    background: #fbfdfd
}

.reg-data dt {
    color: #93a0a6;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .4px;
    text-transform: uppercase
}

.reg-data dd {
    margin: 5px 0 0;
    color: var(--navy);
    font-size: 13px;
    font-weight: 600;
    word-break: break-word
}

@media (max-width: 1200px) {
    .reg-steps {
        grid-template-columns: 1fr
    }
}

@media (max-width: 700px) {
    .reg-search {
        flex-wrap: wrap
    }

    .reg-search .btn-primary {
        width: 100%;
        justify-content: center
    }

    .reg-data {
        grid-template-columns: 1fr
    }
}

@keyframes regFade {
    from {
        opacity: 0;
        transform: translateY(4px);
    }

    to {
        opacity: 1;
        transform: none;
    }
}

.reg-spin {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #7b878e;
    font-size: 13px;
    padding: 14px 4px;
}


.registration-wizard {
    width: 100%;
    max-width: 100%;
}

.registration-wizard .reg-step {
    width: 100%;
    max-width: 100%;
}

.registration-wizard .wizard-hidden {
    display: none !important;
}

.registration-wizard .panel {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(15, 23, 42, .04);
}

.reg-step-head {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 20px 24px;
    border-bottom: 1px solid #e5e7eb;
    background: #fff;
}

.reg-step-no {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    border-radius: 50%;
    background: var(--teal-dark);
    color: #fff;
    font-size: 16px;
    font-weight: 700;
}

.reg-step-head h3 {
    margin: 0 0 3px;
    font-size: 18px;
    font-weight: 700;
    color: #212529;
}

.reg-step-head p {
    margin: 0;
    font-size: 13px;
    color: #6c757d;
}

.reg-step-body {
    padding: 24px;
}

.reg-step-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 18px 24px;
    border-top: 1px solid #e5e7eb;
}

.wizard-navigation {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 18px 24px;
    border-top: 1px solid #e5e7eb;
    background: #fafafa;
}

.wizard-navigation.only-next {
    justify-content: flex-end;
}

.wizard-navigation.only-prev {
    justify-content: flex-start;
}

.btn-primary,
.btn-outline {
    min-height: 42px;
    padding: 9px 18px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: .15s ease;
}

.btn-primary {
    border: 1px solid var(--teal-dark);
    background: var(--teal-dark);
    color: #fff;
}

.btn-primary:hover {
    background: #0b5ed7;
    border-color: #0a58ca;
    color: #fff;
}

.btn-primary:disabled {
    opacity: .55;
    cursor: not-allowed;
}

.btn-outline {
    border: 1px solid #ced4da;
    background: #fff;
    color: #495057;
}

.btn-outline:hover {
    background: #f8f9fa;
    color: #212529;
}

.reg-search {
    display: flex;
    align-items: center;
    gap: 12px;
}

.reg-search .search {
    position: relative;
    flex: 1;
}

.reg-search .search>i {
    position: absolute;
    top: 50%;
    left: 14px;
    transform: translateY(-50%);
    color: #adb5bd;
}

.reg-search .search input {
    width: 100%;
    height: 44px;
    padding: 8px 14px 8px 42px;
    border: 1px solid #ced4da;
    border-radius: 8px;
    outline: none;
}

.reg-search .search input:focus {
    border-color: #86b7fe;
    box-shadow: 0 0 0 .2rem rgba(13, 110, 253, .12);
}

.reg-results {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-top: 16px;
}

.reg-result {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    width: 100%;
    padding: 15px 16px;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    background: #fff;
    color: inherit;
    text-decoration: none;
    text-align: left;
    cursor: pointer;
}

.reg-result:hover {
    border-color: #86b7fe;
    background: #f8fbff;
}

.reg-result-main {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.reg-result-main strong {
    color: #212529;
    font-size: 14px;
}

.reg-result-main small {
    color: #6c757d;
    font-size: 12px;
}

.reg-result-go {
    flex: 0 0 auto;
    font-size: 13px;
    font-weight: 600;
    color: var(--teal-dark);
}

.reg-selected {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px;
    border: 1px solid #dbeafe;
    border-radius: 10px;
    background: #f8fbff;
}

.reg-selected-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    border-radius: 50%;
    background: #e7f1ff;
    color: var(--teal-dark);
    font-size: 19px;
}

.reg-selected-text {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.reg-selected-text strong {
    color: #212529;
}

.reg-selected-text small {
    color: #6c757d;
}

.reg-selected-change {
    display: inline-flex;
    margin-top: 12px;
}

.reg-data {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0;
    margin: 0;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    overflow: hidden;
}

.reg-data>div {
    padding: 15px 18px;
    border-right: 1px solid #e5e7eb;
    border-bottom: 1px solid #e5e7eb;
}

.reg-data>div:nth-child(3n) {
    border-right: 0;
}

.reg-data dt {
    margin-bottom: 4px;
    font-size: 12px;
    font-weight: 500;
    color: #6c757d;
}

.reg-data dd {
    margin: 0;
    font-size: 14px;
    font-weight: 600;
    color: #212529;
}

.reg-label {
    display: block;
    margin-bottom: 6px;
    font-size: 13px;
    font-weight: 600;
    color: #495057;
}

.reg-hint {
    margin: 12px 0 0;
    color: #6c757d;
    font-size: 12px;
}

.reg-hint-center {
    text-align: center;
}

.reg-link {
    color: var(--teal-dark);
    text-decoration: none;
}

.reg-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 180px;
    padding: 30px;
    text-align: center;
    color: #6c757d;
}

.reg-empty>i {
    margin-bottom: 10px;
    font-size: 34px;
    color: #adb5bd;
}

.reg-empty strong {
    margin-bottom: 4px;
    color: #343a40;
}

.reg-empty span {
    max-width: 550px;
    font-size: 13px;
}

.reg-empty .btn-primary {
    margin-top: 16px;
}

.reg-check {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
}

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

.reg-schedule {
    position: relative;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    background: #fff;
    cursor: pointer;
}

.reg-schedule:hover {
    border-color: #86b7fe;
    background: #f8fbff;
}

.reg-schedule:has(input:checked) {
    border-color: var(--teal-dark);
    background: #f5f9ff;
    box-shadow: 0 0 0 1px var(--teal-dark);
}

.reg-schedule.is-full {
    opacity: .65;
    cursor: not-allowed;
}

.reg-schedule>input {
    flex: 0 0 auto;
}

.reg-schedule-main {
    display: flex;
    flex: 1;
    flex-direction: column;
    gap: 5px;
    min-width: 0;
}

.reg-schedule-main strong {
    color: #212529;
}

.reg-schedule-time,
.reg-schedule-quota {
    color: #6c757d;
    font-size: 12px;
}

.reg-schedule-state {
    flex: 0 0 auto;
    padding: 5px 9px;
    border-radius: 20px;
    background: #e8f5e9;
    color: #198754;
    font-size: 11px;
    font-weight: 700;
}

.reg-schedule.is-full .reg-schedule-state {
    background: #f8d7da;
    color: #842029;
}

.reg-schedule-bar {
    display: block;
    width: 100%;
    height: 5px;
    overflow: hidden;
    border-radius: 5px;
    background: #e9ecef;
}

.reg-schedule-bar>span {
    display: block;
    width: var(--used);
    height: 100%;
    background: var(--teal-dark);
}

.reg-alert {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.reg-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 10px;
    border: 1px solid #e5e7eb;
    border-radius: 20px;
    background: #fff;
    color: #495057;
    font-size: 12px;
    white-space: nowrap;
}

.reg-chip-soft {
    background: #eef6ff;
    border-color: #dbeafe;
    color: var(--teal-dark);
}

.reg-heading-meta {
    display: flex;
    align-items: center;
    gap: 8px;
}

@media (max-width: 991.98px) {

    .reg-results,
    .reg-schedule-grid,
    .reg-data {
        grid-template-columns: 1fr;
    }

    .reg-data>div {
        border-right: 0;
    }
}

@media (max-width: 767.98px) {

    .reg-step-head,
    .reg-step-body,
    .wizard-navigation,
    .reg-step-foot {
        padding-left: 16px;
        padding-right: 16px;
    }

    .reg-search {
        flex-direction: column;
        align-items: stretch;
    }

    .wizard-navigation {
        flex-wrap: wrap;
    }

    .wizard-navigation .btn-primary,
    .wizard-navigation .btn-outline {
        flex: 1;
    }

    .reg-step-foot {
        flex-direction: column;
        align-items: stretch;
    }

    .reg-step-foot .btn-primary {
        width: 100%;
    }
}

/* Modul Kasir: Antrean pembayaran dan settlement kasir */
.cashier-heading-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.cashier-stats {
    margin-bottom: 20px;
}

.cashier-panel {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.cashier-tag {
    color: var(--teal);
    background: var(--teal-soft);
    border-radius: 999px;
    padding: 4px 12px;
    font-size: 11px;
    font-weight: 700;
}

.cashier-list {
    display: flex;
    flex-direction: column;
}

.cashier-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 18px 24px;
    border-top: 1px solid #edf0f2;
    transition: background .15s ease;
}

.cashier-item:hover {
    background: #fbfdfd;
}

.cashier-queue {
    flex: 0 0 85px;
    display: flex;
    flex-direction: column;
}

.cashier-queue small {
    font-size: 10px;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: .5px;
}

.cashier-queue strong {
    font: 800 18px/1.2 Manrope;
    color: var(--teal);
}

.cashier-who {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.cashier-who strong {
    font: 700 15px Manrope;
    color: var(--navy);
}

.cashier-who span {
    font-size: 12px;
    color: var(--muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.cashier-due {
    flex: 0 0 170px;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
    text-align: right;
}

.cashier-due small {
    font-size: 10px;
    color: var(--muted);
    text-transform: uppercase;
}

.cashier-due strong {
    font: 800 16px Manrope;
    color: var(--navy);
}

.cashier-open {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 9px 18px;
    white-space: nowrap;
}

.cashier-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 48px 20px;
    color: var(--muted);
    text-align: center;
}

.cashier-empty i {
    font-size: 32px;
    color: #a4b2b6;
}

.cashier-empty strong {
    color: var(--navy);
    font: 700 15px Manrope;
}

.cashier-empty span {
    font-size: 13px;
}

/* Detail & Settlement Kasir */
.cashier-patient {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 12px;
    box-shadow: var(--shadow);
    padding: 20px 24px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.cashier-patient h2 {
    margin: 4px 0 6px;
    font: 800 20px Manrope;
    color: var(--navy);
}

.cashier-patient p {
    margin: 0;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.5;
}

.cashier-patient-side {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 8px;
    text-align: right;
    flex-shrink: 0;
}

.cashier-patient-side small {
    color: #9aa3a8;
    font-size: 12px;
}

.cashier-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(320px, 0.95fr);
    gap: 20px;
    align-items: start;
}

.cashier-items {
    width: 100%;
}

.cashier-items th.is-number,
.cashier-items td.is-number {
    text-align: right;
}

.cashier-items tfoot th {
    background: #f8fbfa;
    color: var(--navy);
    font: 800 14px Manrope;
    padding: 14px;
    border-top: 2px solid #dfe6e8;
}

.cashier-pay-head {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 24px 20px;
    background: #fbfdfd;
    border-bottom: 1px solid #edf0f2;
    text-align: center;
}

.cashier-pay-head span {
    font-size: 12px;
    color: var(--muted);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .5px;
}

.cashier-pay-head strong {
    font: 800 28px/1.2 Manrope;
    color: var(--teal);
    margin: 6px 0 2px;
}

.cashier-pay-head small {
    font-size: 12px;
    color: #438e70;
    font-weight: 600;
}

.cashier-form {
    padding: 22px 24px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.cashier-methods {
    border: 0;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.cashier-methods legend {
    font-size: 13px;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: 8px;
    float: none;
    width: auto;
}

.cashier-methods input[type="radio"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.cashier-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 16px;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: #fff;
    color: #495057;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all .15s ease;
    user-select: none;
}

.cashier-chip:hover {
    border-color: var(--teal);
    color: var(--teal);
    background: var(--teal-soft);
}

.cashier-methods input[type="radio"]:checked + .cashier-chip {
    border-color: var(--teal);
    background: var(--teal);
    color: #fff;
    box-shadow: 0 2px 6px rgba(8, 127, 120, .25);
}

.cashier-form .form-label {
    margin: 0;
    font-size: 13px;
    font-weight: 700;
    color: var(--navy);
}

.cashier-form .form-control {
    font: 700 18px Manrope;
    color: var(--navy);
}

.cashier-quick {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.cashier-quick .cashier-chip {
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 500;
    border-style: dashed;
    background: #fafafa;
}

.cashier-quick .cashier-chip:hover {
    border-style: solid;
    background: var(--teal-soft);
}

.cashier-hint {
    margin: 0;
    padding: 10px 14px;
    border-radius: 8px;
    background: #f1f8f7;
    color: var(--teal-dark);
    font-size: 13px;
}

.cashier-hint strong {
    font-weight: 700;
}

.cashier-hint.is-short {
    background: #fff4df;
    color: #9a6519;
}

.cashier-hint.is-done {
    margin: 0 24px 24px;
    background: #e8f7ef;
    color: #21794e;
    display: flex;
    align-items: center;
    gap: 8px;
}

.cashier-submit {
    width: 100%;
    justify-content: center;
    gap: 8px;
    font-weight: 700;
    padding: 12px;
    font-size: 15px;
}

.cashier-receipt {
    padding: 20px 24px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.cashier-receipt p {
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 13px;
    color: var(--muted);
    padding-bottom: 8px;
    border-bottom: 1px dashed #edf0f2;
}

.cashier-receipt p:last-child {
    border-bottom: 0;
    padding-bottom: 0;
}

.cashier-receipt p strong {
    color: var(--navy);
    font-weight: 700;
}

/* Responsiveness for Cashier Module */
@media (max-width: 991.98px) {
    .cashier-layout {
        grid-template-columns: 1fr;
    }

    .cashier-patient {
        flex-direction: column;
        align-items: flex-start;
    }

    .cashier-patient-side {
        align-items: flex-start;
        text-align: left;
    }
}

@media (max-width: 767.98px) {
    .cashier-heading-actions {
        width: 100%;
    }

    .cashier-heading-actions .btn-primary,
    .cashier-heading-actions .btn-outline {
        flex: 1;
        justify-content: center;
    }

    .cashier-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
        padding: 16px;
    }

    .cashier-queue {
        flex-direction: row;
        align-items: baseline;
        gap: 6px;
    }

    .cashier-due {
        align-items: flex-start;
        text-align: left;
        flex: 0 0 auto;
        width: 100%;
    }

    .cashier-open {
        width: 100%;
        justify-content: center;
    }

    .cashier-form {
        padding: 18px 16px;
    }

    .cashier-receipt {
        padding: 18px 16px;
    }
}


