:root {
    --ink: #1e293b;
    --muted: #64748b;
    --line: #e2e8f0;
    --paper: #ffffff;
    --soft: #f8fafc;
    --bg: #f1f5f9;
    --green-primary: #00833e;
    --green-dark: #005c2a;
    --blue-primary: #0074d9;
    --blue-dark: #004fa3;
    --amber-primary: #f39c12;
    --amber-dark: #d67d00;
    --purple-primary: #9b59b6;
    --purple-dark: #7d3c98;
    --danger: #ef4444;
    --shadow-sm: 0 2px 8px rgba(0,0,0,.06);
    --shadow-md: 0 8px 24px rgba(0,0,0,.10);
    --shadow-lg: 0 16px 40px rgba(0,0,0,.14);
}

*, *::before, *::after {
    box-sizing: border-box;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    -webkit-touch-callout: none;
}
input, textarea {
    -webkit-user-select: text;
    -moz-user-select: text;
    -ms-user-select: text;
    user-select: text;
}
body {
    position: relative;
    margin: 0;
    min-height: 100vh;
    font-family: 'Poppins', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: var(--ink);
    background:
        linear-gradient(180deg, rgba(248,251,255,.70) 0%, rgba(237,244,247,.66) 48%, rgba(246,247,251,.78) 100%),
        url("../img/rsmh_bg.jpg") center / cover fixed no-repeat;
    overflow-x: hidden;
}
body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: -1;
    background: linear-gradient(180deg, rgba(255,255,255,.30), rgba(241,245,249,.85));
}
a { color: inherit; text-decoration: none; }

.topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    width: 100%;
    margin: 0;
    padding: 12px 28px;
    border-radius: 0;
    background: linear-gradient(135deg, var(--green-primary) 0%, var(--green-dark) 100%);
    box-shadow: var(--shadow-md);
}
.brand {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
}
.brand img {
    width: 48px;
    height: 48px;
    object-fit: contain;
    padding: 4px;
    border-radius: 12px;
    background: #ffffff;
    box-shadow: 0 4px 12px rgba(0,0,0,.15);
}
.brand strong, .brand small, .clock strong, .clock small { display: block; }
.brand strong { font-size: 19px; font-weight: 700; color: #ffffff; letter-spacing: .3px; }
.brand small { font-size: 13px; color: rgba(255, 255, 255, .88); font-weight: 400; }
.clock { text-align: right; color: #ffffff; }
.clock strong { font-size: 22px; font-weight: 700; color: #ffffff; }
.clock small { font-size: 13px; color: rgba(255, 255, 255, .85); }

.page {
    width: min(1200px, calc(100% - 32px));
    margin: 20px auto 30px;
}
.home-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 20px;
    padding: 18px 24px;
    border-radius: 16px;
    background: rgba(255, 255, 255, .92);
    border: 1px solid rgba(226, 232, 240, .80);
    box-shadow: var(--shadow-sm);
    backdrop-filter: blur(12px);
}
.home-head span {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    border-radius: 20px;
    color: var(--green-primary);
    background: #e8f5ee;
    font-size: 13px;
    font-weight: 600;
}
.home-head h1 {
    margin: 6px 0 0;
    font-size: 24px;
    font-weight: 700;
    color: var(--ink);
}
.home-head small {
    color: var(--muted);
    font-size: 14px;
    font-weight: 400;
}

.home-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}
.menu-tile {
    position: relative;
    min-height: 155px;
    padding: 22px 24px;
    border-radius: 16px;
    color: #ffffff;
    text-align: left;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    align-items: stretch !important;
    box-shadow: var(--shadow-md);
    overflow: hidden;
    isolation: isolate;
    transition: transform .25s cubic-bezier(.4,0,.2,1), box-shadow .25s cubic-bezier(.4,0,.2,1);
    border: 1px solid rgba(255, 255, 255, .20);
}
.home-grid.grid-6 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}
.menu-tile.rose { background: linear-gradient(135deg, #e11d48, #be123c); }
.menu-tile.cyan { background: linear-gradient(135deg, #0284c7, #0369a1); }
.menu-tile.green { background: linear-gradient(135deg, var(--green-primary), var(--green-dark)); }
.menu-tile.blue { background: linear-gradient(135deg, var(--blue-primary), var(--blue-dark)); }
.menu-tile.orange { background: linear-gradient(135deg, #ea580c, #c2410c); }
.menu-tile.amber { background: linear-gradient(135deg, var(--amber-primary), var(--amber-dark)); }
.menu-tile.purple { background: linear-gradient(135deg, var(--purple-primary), var(--purple-dark)); }

.antrian-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
    margin-top: 24px;
}
.antrian-card {
    position: relative;
    padding: 28px 24px;
    border-radius: 16px;
    color: #fff;
    cursor: pointer;
    text-align: center;
    box-shadow: var(--shadow-md);
    transition: transform .25s ease, box-shadow .25s ease;
}
.antrian-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}
.antrian-card.blue { background: linear-gradient(135deg, #0074d9, #004fa3); }
.antrian-card.green { background: linear-gradient(135deg, #00833e, #005c2a); }
.antrian-card.amber { background: linear-gradient(135deg, #f39c12, #d67d00); }
.antrian-badge {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: rgba(255,255,255,.25);
    display: grid;
    place-items: center;
    font-size: 18px;
    font-weight: 800;
}
.antrian-icon {
    margin: 0 auto 12px;
    display: grid;
    place-items: center;
}
.antrian-card strong {
    display: block;
    font-size: 20px;
    font-weight: 700;
}
.antrian-card small {
    display: block;
    font-size: 14px;
    opacity: 0.9;
    margin-top: 4px;
}
.ticket-result-box {
    margin-top: 30px;
    padding: 24px;
    background: #ffffff;
    border-radius: 16px;
    border: 2px dashed #00833e;
    max-width: 450px;
    margin-left: auto;
    margin-right: auto;
    text-align: center;
    box-shadow: var(--shadow-md);
}
.ticket-header { margin-bottom: 16px; }
.ticket-header strong { display: block; font-size: 18px; color: var(--green-primary); }
.ticket-header span { font-size: 13px; color: var(--muted); }
.ticket-body p { font-size: 14px; font-weight: 600; color: var(--muted); margin: 0; }
.ticket-body h2 { font-size: 54px; font-weight: 900; color: var(--ink); margin: 10px 0; }
.ticket-body span { font-size: 13px; color: var(--muted); }
.ticket-footer { margin-top: 16px; padding-top: 12px; border-top: 1px solid #e2e8f0; }
.ticket-actions { margin-top: 20px; display: flex; gap: 12px; justify-content: center; }

.menu-tile:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.tile-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.tile-icon {
    width: 52px;
    height: 52px;
    display: inline-grid;
    place-items: center;
    color: #ffffff;
    border-radius: 14px;
    background: rgba(255, 255, 255, .18);
    backdrop-filter: blur(6px);
    border: 1px solid rgba(255, 255, 255, .30);
    transition: transform .25s ease;
}
.tile-icon-img {
    background: rgba(255, 255, 255, .95);
    padding: 6px;
}
.tile-logo-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}
.menu-tile:hover .tile-icon {
    transform: scale(1.06);
    background: rgba(255, 255, 255, .26);
}
.tile-badge {
    font-size: 12px;
    font-weight: 500;
    padding: 4px 10px;
    border-radius: 20px;
    background: rgba(255, 255, 255, .20);
    backdrop-filter: blur(4px);
    letter-spacing: .2px;
}

.tile-content {
    margin-top: 14px;
}
.menu-tile strong {
    display: block;
    font-size: 21px;
    font-weight: 700;
    line-height: 1.25;
    letter-spacing: .1px;
}
.menu-tile small {
    display: block;
    font-size: 13px;
    font-weight: 400;
    color: rgba(255, 255, 255, .88);
    margin-top: 4px;
}

.summary-strip {
    margin-top: 20px;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}
.summary-strip div {
    position: relative;
    padding: 18px 24px;
    border-radius: 16px;
    background: rgba(255, 255, 255, .92);
    border: 1px solid rgba(226, 232, 240, .80);
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: center;
    gap: 16px;
}
.summary-strip b {
    font-size: 32px;
    font-weight: 800;
    color: var(--green-primary);
    line-height: 1;
}
.summary-strip span {
    font-size: 14px;
    font-weight: 600;
    color: var(--ink);
}
    overflow: hidden;
    padding: 22px 24px;
    background:
        linear-gradient(180deg, rgba(255,255,255,.96), rgba(248,251,255,.90));
    border: 1px solid rgba(255, 255, 255, .82);
    border-radius: 8px;
    box-shadow: 0 16px 34px rgba(23, 32, 51, .09);
    transition: transform .2s ease, box-shadow .2s ease;
}
.summary-strip div::after {
    content: "";
    position: absolute;
    right: 0;
    top: 0;
    width: 10px;
    height: 100%;
    background: linear-gradient(180deg, #0d6efd, #198754);
}
.summary-strip div:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 32px rgba(23, 32, 51, .10);
}
.summary-strip b {
    display: block;
    font-size: 32px;
    color: var(--green);
}
.summary-strip span { color: var(--muted); }

.work-surface {
    background:
        linear-gradient(180deg, rgba(255,255,255,.93), rgba(255,255,255,.84));
    border: 1px solid rgba(255,255,255,.72);
    border-radius: 8px;
    padding: 28px;
    box-shadow: 0 26px 70px rgba(23, 32, 51, .16);
    backdrop-filter: blur(14px);
}
.work-surface.wide { padding-bottom: 34px; }
.surface-head { margin-bottom: 12px; }
.surface-head.compact-head { margin-bottom: 12px; }
.surface-head h1 {
    margin: 0;
    font-size: 24px;
}
.surface-head p {
    margin: 0;
    color: var(--muted);
    font-size: 15px;
}
.back {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    height: 40px;
    padding: 0 16px;
    border: 2px solid var(--green-primary) !important;
    border-radius: 20px;
    color: var(--green-dark) !important;
    background: #e8f5ee !important;
    font-weight: 700;
    font-size: 15px;
    text-decoration: none;
    box-shadow: 0 2px 6px rgba(0, 131, 62, 0.12);
    transition: all .2s ease;
}
.back .ui-icon {
    width: 20px !important;
    height: 20px !important;
    padding: 0 !important;
    border-radius: 0 !important;
    color: var(--green-primary) !important;
    stroke: var(--green-primary) !important;
    background: transparent !important;
    box-shadow: none !important;
}
.back:hover {
    color: #ffffff !important;
    background: var(--green-primary) !important;
    border-color: var(--green-primary) !important;
    transform: translateX(-3px);
}
.back:hover .ui-icon {
    color: #ffffff !important;
    stroke: #ffffff !important;
}
.search-row {
    display: grid;
    grid-template-columns: 1fr 180px;
    gap: 12px;
}
.search-row.double {
    grid-template-columns: 1fr 1fr 180px;
}
input, select, button {
    font: inherit;
}
input, select {
    width: 100%;
    min-height: 62px;
    border: 1px solid rgba(160, 174, 192, .48);
    border-radius: 8px;
    padding: 0 18px;
    font-size: 20px;
    background:
        linear-gradient(180deg, rgba(255,255,255,.96), rgba(248,251,255,.90));
    color: var(--ink);
    outline: none;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.80), 0 8px 20px rgba(23,32,51,.045);
    transition: border-color .18s ease, box-shadow .18s ease, background .18s ease, transform .18s ease;
}
input:focus, select:focus {
    border-color: rgba(13, 110, 253, .74);
    box-shadow:
        0 0 0 4px rgba(13, 110, 253, .14),
        0 14px 28px rgba(13, 110, 253, .08);
    background: #fff;
    transform: translateY(-1px);
}
button {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    border: 0;
    border-radius: 8px;
    min-height: 62px;
    padding: 0 22px;
    color: #fff;
    background:
        linear-gradient(180deg, rgba(255,255,255,.16), rgba(255,255,255,0)),
        linear-gradient(135deg, #18a96f 0%, #16885a 48%, #0b6b49 100%);
    font-weight: 700;
    cursor: pointer;
    box-shadow:
        0 16px 32px rgba(25, 135, 84, .25),
        inset 0 1px 0 rgba(255,255,255,.28);
    overflow: hidden;
    transition: transform .18s ease, box-shadow .18s ease, filter .18s ease, background .18s ease;
}
button::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(110deg, transparent 0 34%, rgba(255,255,255,.22) 46%, transparent 58% 100%);
    transform: translateX(-120%);
    transition: transform .45s ease;
}
.ui-icon {
    width: 22px;
    height: 22px;
    flex: 0 0 auto;
    fill: none;
    stroke: currentColor;
    stroke-width: 2.2;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.tile-svg {
    width: 38px;
    height: 38px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.9;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.icon-button span {
    min-width: 0;
}
button:hover {
    transform: translateY(-2px);
    box-shadow:
        0 22px 42px rgba(25, 135, 84, .32),
        inset 0 1px 0 rgba(255,255,255,.34);
    filter: brightness(1.02);
}
button:hover::after { transform: translateX(120%); }
button:active {
    transform: translateY(0);
}
.search-row button {
    min-width: 160px;
    letter-spacing: .1px;
}
.search-row button .ui-icon {
    width: 24px;
    height: 24px;
    padding: 4px;
    border-radius: 8px;
    background: rgba(255,255,255,.16);
}
.result-panel {
    margin-top: 22px;
    border-top: 1px solid rgba(13, 110, 253, .13);
    padding-top: 24px;
}
.frista-panel {
    margin-top: 18px;
    padding: 20px;
    border: 1px solid rgba(13, 110, 253, .22);
    border-radius: 8px;
    background:
        linear-gradient(180deg, rgba(255,255,255,.86), rgba(238,244,255,.96)),
        #eef4ff;
    box-shadow: 0 14px 32px rgba(13, 110, 253, .10);
}
.frista-panel h2 {
    margin: 0 0 6px;
    font-size: 25px;
}
.frista-panel p {
    margin: 0 0 14px;
    color: var(--muted);
    font-size: 16px;
}
.frista-actions {
    display: grid;
    grid-template-columns: minmax(240px, .9fr) minmax(280px, 1.1fr);
    gap: 12px;
}
.secondary-action {
    color: var(--blue-dark);
    background: #fff;
    border: 1px solid rgba(13, 110, 253, .32);
    box-shadow: 0 10px 22px rgba(13, 110, 253, .08);
}
.secondary-action:hover {
    border-color: rgba(13, 110, 253, .58);
    box-shadow: 0 16px 30px rgba(13, 110, 253, .16);
}
.secondary-action.is-loading {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    color: #fff;
    background: var(--blue-dark);
    border-color: var(--blue-dark);
    cursor: wait;
    opacity: .9;
}
.btn-spinner {
    width: 18px;
    height: 18px;
    border: 3px solid rgba(255, 255, 255, .45);
    border-top-color: #fff;
    border-radius: 50%;
    flex: 0 0 auto;
    animation: spin .75s linear infinite;
}
@keyframes spin {
    to { transform: rotate(360deg); }
}
.hidden { display: none !important; }
.patient-title {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: flex-start;
    margin-bottom: 18px;
    padding: 2px 2px 0;
}
.patient-title strong {
    font-size: 30px;
    letter-spacing: .2px;
}
.patient-title span {
    min-height: 34px;
    padding: 7px 12px;
    border: 1px solid rgba(13, 110, 253, .14);
    border-radius: 8px;
    color: #0a58ca;
    background: rgba(238, 244, 255, .82);
    font-size: 18px;
    font-weight: 700;
}
.info-grid, .form-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}
.form-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}
.info-grid div {
    position: relative;
    min-height: 88px;
    padding: 16px;
    border: 1px solid rgba(160, 174, 192, .42);
    border-radius: 8px;
    background:
        linear-gradient(180deg, rgba(255,255,255,.90), rgba(247,250,255,.82));
    box-shadow:
        0 10px 24px rgba(23, 32, 51, .055),
        inset 0 1px 0 rgba(255,255,255,.80);
    overflow: hidden;
    transition: transform .18s ease, border-color .18s ease, background .18s ease, box-shadow .18s ease;
}
.info-grid div::before {
    content: "";
    position: absolute;
    left: 0;
    top: 14px;
    bottom: 14px;
    width: 4px;
    border-radius: 0 8px 8px 0;
    background: linear-gradient(180deg, #0d6efd, #198754);
    opacity: .72;
}
.info-grid div:hover {
    transform: translateY(-2px);
    border-color: rgba(13, 110, 253, .30);
    background:
        linear-gradient(180deg, rgba(255,255,255,.98), rgba(247,250,255,.94));
    box-shadow:
        0 16px 32px rgba(23, 32, 51, .10),
        inset 0 1px 0 rgba(255,255,255,.90);
}
.info-grid small, label {
    display: block;
    color: var(--muted);
}
.info-grid b {
    display: block;
    margin-top: 8px;
    font-size: 18px;
    word-break: break-word;
}
label {
    font-weight: 700;
}
label select { margin-top: 8px; }
.primary-wide {
    width: 100%;
    margin-top: 18px;
    font-size: 20px;
    min-height: 64px;
    background:
        linear-gradient(180deg, rgba(255,255,255,.15), rgba(255,255,255,0)),
        linear-gradient(135deg, #149968 0%, #0f7d53 50%, #075b40 100%);
    box-shadow:
        0 18px 36px rgba(25, 135, 84, .28),
        inset 0 1px 0 rgba(255,255,255,.26);
}
.schedule-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}
.doctor-card {
    display: flex;
    gap: 14px;
    padding: 14px;
    border: 1px solid rgba(208, 215, 226, .84);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 10px 22px rgba(23, 32, 51, .06);
    transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.doctor-card:hover {
    transform: translateY(-4px);
    border-color: #b8c3d2;
    box-shadow: 0 18px 36px rgba(23, 32, 51, .12);
}
.doctor-card img {
    width: 86px;
    height: 108px;
    object-fit: cover;
    object-position: center top;
    border-radius: 8px;
    background: #e2e8f0;
}
.doctor-card strong, .doctor-card span, .doctor-card small {
    display: block;
}
.doctor-card strong { font-size: 18px; line-height: 1.25; }
.doctor-card span {
    width: fit-content;
    color: var(--green-dark);
    margin: 8px 0;
    padding: 5px 9px;
    border-radius: 999px;
    background: #e9f7ef;
    font-size: 13px;
    font-weight: 800;
}
.doctor-card small {
    width: fit-content;
    color: var(--slate);
    padding: 5px 9px;
    border-radius: 999px;
    background: #eef4ff;
    font-weight: 700;
}
.empty-state {
    grid-column: 1 / -1;
    padding: 28px;
    text-align: center;
    color: var(--muted);
    border: 1px dashed var(--line);
    border-radius: 8px;
}
.toast {
    position: fixed;
    left: 50%;
    bottom: 28px;
    transform: translateX(-50%) translateY(20px);
    min-width: 360px;
    max-width: 680px;
    width: min(90%, 680px);
    background: #0f172a;
    color: #ffffff;
    border-radius: 14px;
    box-shadow: 0 20px 45px rgba(15, 23, 42, 0.45);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    transition: opacity .3s ease, transform .3s ease, visibility .3s ease;
    z-index: 2000;
}
.toast.show {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}
.toast.error {
    background: #991b1b;
    border: 1px solid #f87171;
}
.toast-body {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 14px 18px;
}
.toast-msg {
    font-size: 15px;
    font-weight: 600;
    line-height: 1.5;
    color: #ffffff;
    flex: 1;
    word-break: break-word;
}
.toast-close {
    background: rgba(255, 255, 255, 0.2);
    color: #ffffff;
    border: none;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    min-height: 28px !important;
    max-height: 28px !important;
    display: grid;
    place-items: center;
    padding: 0 !important;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    flex-shrink: 0;
    transition: background .2s ease;
}
.toast-close:hover {
    background: rgba(255, 255, 255, 0.38);
}
.toast-progress {
    width: 100%;
    height: 5px;
    background: rgba(255, 255, 255, 0.22);
}
.toast-bar {
    height: 100%;
    width: 100%;
    background: #22c55e;
}
.toast.error .toast-bar {
    background: #facc15;
}
.busy {
    position: fixed;
    inset: 0;
    background: rgba(255, 255, 255, 0.88);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 9999999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}
.busy.show {
    opacity: 1;
    pointer-events: auto;
}
.busy b {
    margin-top: 14px;
    font-size: 14px;
    font-weight: 700;
    color: var(--ink);
    letter-spacing: 0.3px;
}

@media (max-width: 860px) {
    .topbar, .patient-title, .home-head { flex-direction: column; align-items: flex-start; }
    .clock { text-align: left; }
    .home-grid, .summary-strip, .search-row, .info-grid, .form-grid, .schedule-grid {
        grid-template-columns: 1fr;
    }
    .frista-actions {
        grid-template-columns: 1fr;
    }
    .search-row.double {
        grid-template-columns: 1fr;
    }
    .menu-tile { min-height: 190px; }
    .menu-tile strong { font-size: 28px; }
    .home-head h1 { font-size: 26px; }
    .topbar, .page {
        width: min(100% - 24px, 1220px);
    }
}

/* ======================== SPLIT PANEL & NUMPAD ======================== */
.form-split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    align-items: start;
}
.form-panel {
    display: flex;
    flex-direction: column;
    gap: 16px;
}
.form-panel.left-panel {
    border-right: 1px solid rgba(226, 232, 240, 0.8);
    padding-right: 24px;
}
@media (max-width: 860px) {
    .form-split { grid-template-columns: 1fr; }
    .form-panel.left-panel { border-right: none; padding-right: 0; }
}

.input-display-wrap {
    position: relative;
    width: 100%;
}
.input-display {
    width: 100%;
    min-height: 56px;
    padding: 0 48px 0 18px;
    font-size: 20px;
    font-weight: 700;
    color: var(--ink);
    background: #ffffff;
    border: 2px solid var(--line);
    border-radius: 12px;
    outline: none;
    letter-spacing: 1px;
}
.input-display:focus {
    border-color: var(--green-primary);
    box-shadow: 0 0 0 3px rgba(0, 131, 62, .15);
}
.btn-icon-clear {
    position: absolute !important;
    right: 14px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    width: 28px !important;
    height: 28px !important;
    min-width: 28px !important;
    max-width: 28px !important;
    min-height: 28px !important;
    max-height: 28px !important;
    border-radius: 50% !important;
    background: #e2e8f0 !important;
    color: #475569 !important;
    border: none !important;
    padding: 0 !important;
    margin: 0 !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    line-height: 28px !important;
    text-align: center !important;
    cursor: pointer !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    box-shadow: none !important;
    transition: background .2s ease, color .2s ease !important;
    z-index: 10 !important;
}
.btn-icon-clear:hover {
    background: #ef4444 !important;
    color: #ffffff !important;
}

.numpad {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-top: 12px;
}
.numpad-btn {
    height: 58px;
    font-size: 22px;
    font-weight: 700;
    color: var(--ink);
    background: #ffffff;
    border: 2px solid #cbd5e1;
    border-radius: 12px;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0,0,0,.04);
    transition: background .18s ease, transform .12s ease;
}
.numpad-btn:hover {
    background: #f1f5f9;
    border-color: var(--green-primary);
}
.numpad-btn:active {
    transform: scale(0.96);
}
.numpad-btn.btn-clear-pad {
    background: #fee2e2;
    color: #dc2626;
    border-color: #fca5a5;
}
.numpad-btn.btn-del-pad {
    background: #fef3c7;
    color: #d97706;
    border-color: #fde68a;
}

.btn-submit-search {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    min-height: 54px;
    margin-top: 12px;
    padding: 0 20px;
    font-size: 16px;
    font-weight: 700;
    color: #ffffff;
    background: linear-gradient(135deg, var(--green-primary), var(--green-dark));
    border: none;
    border-radius: 12px;
    cursor: pointer;
    box-shadow: var(--shadow-md);
    transition: transform .2s ease;
}
.btn-submit-search:hover {
    transform: translateY(-2px);
}

.pasien-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 320px;
    padding: 30px;
    border: 2px dashed #cbd5e1;
    border-radius: 16px;
    text-align: center;
    color: var(--muted);
}
.pasien-empty-state .empty-icon {
    font-size: 48px;
    margin-bottom: 12px;
}
.pasien-info-box {
    background: #ffffff;
    border-radius: 16px;
    border: 2px solid #e2e8f0;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    display: flex;
    flex-direction: column;
    padding: 0;
}
.pasien-info-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: linear-gradient(135deg, #e8f5ee, #d4eddf);
    border-bottom: 1px solid #b8dcc5;
}
.pasien-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #ffffff;
    display: grid;
    place-items: center;
    font-size: 20px;
    box-shadow: var(--shadow-sm);
    flex-shrink: 0;
}
.pasien-info-main {
    flex: 1;
}
.pasien-nama {
    font-size: 15px;
    font-weight: 700;
    color: var(--ink);
    margin: 0 0 2px 0;
    line-height: 1.3;
}
.pasien-badge {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    background: var(--green-primary);
    color: #ffffff;
    text-transform: uppercase;
    letter-spacing: .5px;
}

.info-table {
    width: 100%;
    border-collapse: collapse;
}
.info-table td {
    padding: 7px 16px;
    font-size: 13px;
    border-bottom: 1px solid #f1f5f9;
}
.info-table td:first-child {
    color: var(--muted);
    font-weight: 500;
    width: 38%;
}
.info-table td:last-child {
    color: var(--ink);
    font-weight: 600;
}

.pendaftaran-form-inputs {
    padding: 12px 18px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    background: #fafafa;
    border-top: 1px solid #f1f5f9;
    border-bottom: 1px solid #f1f5f9;
}
.form-group-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.form-group-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 11.5px;
    font-weight: 800;
    color: #0369a1 !important;
    background: #f0f9ff;
    padding: 4px 10px;
    border-radius: 7px;
    border-left: 4px solid #0284c7;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.form-select-kiosk {
    width: 100%;
    height: 54px;
    padding: 0 16px;
    font-size: 16px;
    font-weight: 600;
    color: var(--ink);
    background-color: #ffffff;
    border: 2px solid #cbd5e1;
    border-radius: 12px;
    outline: none;
    cursor: pointer;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.form-select-kiosk:focus {
    border-color: var(--green-primary);
    box-shadow: 0 0 0 3px rgba(0, 131, 62, 0.15);
}

.btn-full {
    width: calc(100% - 36px);
    margin: 10px 18px 16px;
}

/* ======================== CONFIRMATION MODAL ======================== */
.modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 1000;
    background: rgba(15, 23, 42, 0.65);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    transition: opacity .25s ease;
}
.modal-overlay.hidden {
    display: none !important;
}
.modal-card {
    background: #ffffff;
    border-radius: 20px;
    box-shadow: 0 25px 60px rgba(0,0,0,0.30);
    max-width: 520px;
    width: 100%;
    overflow: hidden;
    animation: modalPop .25s ease-out;
}
.modal-card.wide-modal {
    max-width: 1440px !important;
    width: 95vw !important;
}
@keyframes modalPop {
    from { opacity: 0; transform: scale(0.92) translateY(10px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}
.modal-header {
    background: linear-gradient(135deg, var(--green-primary), var(--green-dark));
    color: #ffffff;
    padding: 24px 28px;
    text-align: center;
}
.modal-icon {
    font-size: 36px;
    display: block;
    margin-bottom: 8px;
}
.modal-header h3 {
    margin: 0 0 4px 0;
    font-size: 22px;
    font-weight: 700;
}
.modal-header p {
    margin: 0;
    font-size: 14px;
    color: rgba(255,255,255,0.88);
}
.modal-body {
    padding: 24px 28px;
}
.modal-table {
    width: 100%;
    border-collapse: collapse;
}
.modal-table td {
    padding: 10px 0;
    font-size: 15px;
    border-bottom: 1px dashed #e2e8f0;
}
.modal-table td:first-child {
    color: var(--muted);
    width: 38%;
    font-weight: 500;
}
.modal-table td:last-child {
    color: var(--ink);
    font-weight: 600;
}
.modal-table tr:last-child td {
    border-bottom: none;
}
.modal-actions {
    padding: 16px 28px 28px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.btn-confirm-yes {
    width: 100%;
    min-height: 52px;
    font-size: 16px;
    font-weight: 700;
    border-radius: 12px;
}
.error-field {
    border-color: #ef4444 !important;
    background-color: #fef2f2 !important;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.25) !important;
    border-radius: 12px;
    padding: 6px;
}

.dokter-radio-grid {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 2px;
    max-height: 240px;
    overflow-y: auto;
    padding-right: 4px;
    scroll-behavior: smooth;
}
.dokter-radio-grid::-webkit-scrollbar {
    width: 5px;
}
.dokter-radio-grid::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 4px;
}
.dokter-radio-grid::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}
.dokter-radio-grid::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}
.dokter-radio-card {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 7px 12px;
    border-radius: 10px;
    background: #ffffff;
    border: 2px solid #cbd5e1;
    cursor: pointer;
    transition: all .2s ease;
    flex-shrink: 0;
}
.dokter-radio-card:hover {
    border-color: var(--green-primary);
    background: #f8fafc;
}
.dokter-radio-card:has(input:checked),
.dokter-radio-card.active {
    border-color: var(--green-primary);
    background: #e8f5ee;
    box-shadow: 0 3px 8px rgba(0, 131, 62, 0.12);
}
.dokter-radio-card input[type="radio"] {
    width: 18px;
    height: 18px;
    accent-color: var(--green-primary);
    cursor: pointer;
    margin: 0;
}
.dokter-radio-img {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #e2e8f0;
    background: #f8fafc;
    flex-shrink: 0;
}
.dokter-radio-body {
    display: flex;
    flex-direction: column;
    gap: 1px;
}
.dokter-radio-body strong {
    font-size: 13.5px;
    font-weight: 700;
    color: var(--ink);
    line-height: 1.3;
}
.dokter-radio-body small {
    font-size: 12px;
    color: var(--muted);
}
.empty-dokter-hint {
    font-size: 14px;
    color: var(--muted);
    font-style: italic;
    margin: 4px 0;
}

.btn-confirm-no {
    width: 100%;
    min-height: 48px;
    font-size: 15px;
    font-weight: 700 !important;
    border-radius: 12px;
    color: #334155 !important;
    background: #ffffff !important;
    border: 2px solid #cbd5e1 !important;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
    cursor: pointer;
    transition: all .2s ease;
}
.btn-confirm-no:hover {
    background: #f1f5f9 !important;
    color: #0f172a !important;
    border-color: #94a3b8 !important;
}

.bayar-radio-group {
    display: flex;
    gap: 8px;
    width: 100%;
    margin-top: 2px;
}
.bayar-radio-pill {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 6px 12px;
    min-height: 36px;
    border-radius: 9px;
    background: #ffffff;
    border: 2px solid #cbd5e1;
    cursor: pointer;
    font-size: 13px;
    font-weight: 700;
    color: #475569;
    user-select: none;
    transition: all .18s ease;
}
.bayar-radio-pill input[type="radio"] {
    display: none !important;
}
.bayar-radio-pill .check-icon {
    display: inline-block;
    font-size: 12px;
    font-weight: 900;
    opacity: 0;
    transform: scale(0.5);
    transition: opacity .18s ease, transform .18s ease;
}
.bayar-radio-pill:hover {
    border-color: var(--green-primary);
    background: #f8fafc;
    color: var(--ink);
}
.bayar-radio-pill:has(input:checked),
.bayar-radio-pill.active {
    border-color: #00833e !important;
    background: #dcfce7 !important;
    color: #005c2a !important;
    box-shadow: 0 2px 6px rgba(0, 131, 62, 0.20);
}
.bayar-radio-pill:has(input:checked) .check-icon,
.bayar-radio-pill.active .check-icon {
    opacity: 1;
    transform: scale(1);
    color: #00833e;
}

.btn-select-kiosk-trigger {
    width: 100%;
    min-height: 44px;
    padding: 0 14px;
    font-size: 14px;
    font-weight: 700;
    color: #64748b;
    background: #ffffff;
    border: 2px solid #cbd5e1;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0,0,0,0.04);
    transition: all .2s ease;
}
.btn-select-kiosk-trigger:hover {
    border-color: var(--green-primary);
    background: #f8fafc;
}
.btn-select-kiosk-trigger.has-value {
    border-color: var(--green-primary);
    background: #e8f5ee;
    color: var(--green-dark);
}
.trigger-arrow {
    font-size: 13px;
    color: #64748b;
}

.wide-modal {
    max-width: 900px !important;
    width: min(94%, 900px) !important;
}
.scrollable-grid-body {
    max-height: none !important;
    overflow-y: visible !important;
    padding: 16px 20px;
}
.poli-touch-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}
@media (max-width: 768px) {
    .poli-touch-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 480px) {
    .poli-touch-grid {
        grid-template-columns: 1fr;
    }
}
.poli-grid-card {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 12px;
    background: #ffffff;
    border: 2px solid #cbd5e1;
    cursor: pointer;
    text-align: left;
    box-shadow: 0 2px 6px rgba(0,0,0,0.03);
    transition: all .18s ease;
}
.poli-grid-card:not(.disabled):hover,
.poli-grid-card:not(.disabled):active {
    border-color: var(--green-primary);
    background: #e8f5ee;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 131, 62, 0.15);
}
.poli-grid-card.disabled {
    background: #f1f5f9 !important;
    border-color: #cbd5e1 !important;
    cursor: not-allowed !important;
    opacity: 0.65;
    box-shadow: none !important;
    transform: none !important;
}
.poli-card-icon {
    font-size: 20px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #e8f5ee;
    display: grid;
    place-items: center;
    flex-shrink: 0;
}
.poli-card-icon.disabled {
    background: #e2e8f0 !important;
    color: #94a3b8 !important;
    font-size: 18px;
}
.poli-card-info {
    display: flex;
    flex-direction: column;
    gap: 1px;
}
.poli-card-name {
    font-size: 13.5px;
    font-weight: 700;
    color: var(--ink);
    line-height: 1.25;
}
.text-muted {
    color: #64748b !important;
}
.poli-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 6px;
    margin-top: 3px;
    width: fit-content;
}
.poli-badge.badge-active {
    background: #dcfce7;
    color: #005c2a;
    border: 1px solid #86efac;
}
.poli-badge.badge-off {
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #fca5a5;
}

.btn-cancel-red {
    width: 100%;
    min-height: 48px;
    font-size: 15px;
    font-weight: 700 !important;
    border-radius: 12px;
    color: #ffffff !important;
    background: #dc2626 !important;
    border: none !important;
    box-shadow: 0 4px 12px rgba(220, 38, 38, 0.25);
    cursor: pointer;
    transition: all .2s ease;
}
.btn-cancel-red:hover {
    background: #b91c1c !important;
}

.compact-header {
    padding: 20px 24px 14px !important;
}
.compact-header h3 {
    margin: 0 0 4px 0 !important;
}

/* ======================== JADWAL DOKTER MODAL ======================== */
.jadwal-modal-card {
    max-width: 1100px !important;
    width: min(97%, 1100px) !important;
    max-height: 92vh;
    display: flex;
    flex-direction: column;
}
.jadwal-modal-header {
    background: linear-gradient(135deg, var(--green-primary) 0%, var(--green-dark) 100%);
    padding: 10px 20px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}
.jadwal-modal-header h3 { font-size: 16px; margin: 0; font-weight: 700; color: #fff; }
.jadwal-modal-header p  { font-size: 12px; margin: 0; opacity: .90; color: #fff; white-space: nowrap; }
.jadwal-modal-body {
    flex: 1;
    overflow-y: visible;
    padding: 14px 18px 16px;
    background: #f4f6fb;
}

/* CSS Grid 3-column — headers + rows sejajar per baris */
.jadwal-poli-groups {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    align-items: start;
}
.jadwal-poli-group {
    background: #ffffff;
    border-radius: 12px;
    border: 1.5px solid #e2e8f0;
    overflow: hidden;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
    display: flex;
    flex-direction: column;
}
.jadwal-poli-label {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px 8px 14px;
    background: #ffffff;
    border-bottom: 1.5px solid #d1fae5;
    border-left: 4px solid var(--green-primary);
    font-size: 12.5px;
    font-weight: 800;
    color: var(--green-dark);
    letter-spacing: .2px;
}
.jadwal-poli-count {
    font-size: 10.5px;
    font-weight: 700;
    background: #7c3aed;
    color: #ffffff;
    padding: 2px 8px;
    border-radius: 20px;
    flex-shrink: 0;
}
.jadwal-poli-doctors {
    display: flex;
    flex-direction: column;
}
.jadwal-dokter-card {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border-bottom: 1.5px solid #d1fae5;
    background: #ffffff;
    border-left: 3px solid transparent;
    transition: background .15s ease, border-left-color .15s;
}
.jadwal-dokter-card:nth-child(even) {
    background: #f0fdf8;
}
.jadwal-dokter-card:last-child { border-bottom: none; }
.jadwal-dokter-card:hover {
    background: #dcfce7;
    border-left-color: var(--green-primary);
}
.jadwal-dokter-foto {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    object-fit: cover;
    object-position: top center;
    border: 2px solid #b8dcc5;
    background: #f0faf4;
    flex-shrink: 0;
}
.jadwal-dokter-info {
    display: flex;
    flex-direction: column;
    gap: 1px;
    min-width: 0;
}
.jadwal-dokter-info strong {
    font-size: 12px;
    font-weight: 700;
    color: var(--ink);
    line-height: 1.3;
}
.jadwal-dokter-info small {
    font-size: 11px;
    color: var(--green-primary);
    font-weight: 600;
}

/* ======================== JADWAL MODAL SPLIT LAYOUT ======================== */
.jadwal-modal-content {
    display: flex;
    flex: 1;
    overflow: hidden;
    position: relative;
}
.jadwal-modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 14px 18px 16px;
    background: #f4f6fb;
    transition: flex .35s cubic-bezier(.4,0,.2,1);
    min-width: 0;
}
.jadwal-modal-body::-webkit-scrollbar { width: 5px; }
.jadwal-modal-body::-webkit-scrollbar-track { background: #f1f5f9; }
.jadwal-modal-body::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 4px; }

/* Detail panel — hidden by default, slides in from right INSIDE modal */
.jadwal-detail-panel {
    width: 0;
    overflow: hidden;
    background: #ffffff;
    border-left: 0px solid #e2e8f0;
    transition: width .35s cubic-bezier(.4,0,.2,1), border-left-width .35s;
    display: flex;
    flex-direction: column;
    align-items: center;
    flex-shrink: 0;
    position: relative;
}
.jadwal-detail-panel.open {
    width: 280px;
    border-left-width: 2px;
    overflow-y: auto;
    padding: 20px 16px 16px;
}
.jadwal-detail-panel::-webkit-scrollbar { width: 4px; }
.jadwal-detail-panel::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 4px; }

/* Loket Ticket Slide Panel — slides up/down smoothly inside modal */
.loket-ticket-slide-panel {
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    transition: max-height 0.45s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.35s ease, margin-top 0.35s ease, padding 0.35s ease;
    margin-top: 0;
    padding: 0 20px;
}
.loket-ticket-slide-panel.open {
    max-height: 480px;
    opacity: 1;
    margin-top: 16px;
    padding: 20px;
}

.antrian-card-tile.active-selected {
    border-width: 3px !important;
    border-color: #2563eb !important;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.25), 0 8px 24px rgba(0, 0, 0, 0.15) !important;
    transform: translateY(-2px) scale(1.02);
}

.jadwal-detail-close {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 32px;
    height: 32px;
    min-width: 32px;
    min-height: 32px;
    border-radius: 50%;
    background: #ef4444;
    border: none;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    padding: 0;
    box-shadow: 0 2px 8px rgba(239,68,68,0.35);
    transition: background .15s, transform .15s;
    flex-shrink: 0;
}
.jadwal-detail-close:hover {
    background: #dc2626;
    transform: scale(1.1);
}

.jadwal-detail-foto-wrap {
    margin: 32px 0 12px;
    flex-shrink: 0;
}
.jadwal-detail-foto {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
    object-position: top center;
    border: 3px solid var(--green-primary);
    box-shadow: 0 4px 16px rgba(0,131,62,.2);
    background: #f0faf4;
}
.jadwal-detail-nama {
    font-size: 13.5px;
    font-weight: 800;
    color: var(--ink);
    text-align: center;
    line-height: 1.4;
    padding: 0 4px;
    flex-shrink: 0;
}
.jadwal-detail-poli {
    font-size: 11.5px;
    font-weight: 600;
    color: var(--green-primary);
    text-align: center;
    margin: 4px 0 14px;
    flex-shrink: 0;
}
.jadwal-detail-jadwal-title {
    width: 100%;
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .8px;
    color: #94a3b8;
    margin-bottom: 8px;
    flex-shrink: 0;
}
.jadwal-detail-rows {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 6px;
    flex-shrink: 0;
}
.jadwal-detail-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 7px 10px;
    border-radius: 8px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
}
.jadwal-detail-row.today {
    background: #e8f5ee;
    border-color: #b8dcc5;
}
.jadwal-hari-badge {
    font-size: 11.5px;
    font-weight: 700;
    color: var(--ink);
    min-width: 52px;
}
.jadwal-detail-row.today .jadwal-hari-badge {
    color: var(--green-dark);
}
.jadwal-jam {
    font-size: 11px;
    font-weight: 600;
    color: #64748b;
    white-space: nowrap;
}
.jadwal-detail-row.today .jadwal-jam {
    color: var(--green-primary);
}
.jadwal-hari-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #cbd5e1;
    flex-shrink: 0;
}
.jadwal-detail-row.today .jadwal-hari-dot {
    background: var(--green-primary);
}

/* Highlight doctor card when active */
.jadwal-dokter-card.selected {
    background: #e8f5ee !important;
    border-left: 3px solid var(--green-primary);
}

/* Fixed Centered Modal Backdrop Overlay */
.modal-backdrop {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    background: rgba(15, 23, 42, 0.65) !important;
    backdrop-filter: blur(4px) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    z-index: 99999 !important;
}

.modal-backdrop.hidden {
    display: none !important;
}

.modal-card {
    background: #ffffff !important;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.3) !important;
    animation: modalPop 0.2s cubic-bezier(0.16, 1, 0.3, 1) !important;
    border-radius: 16px !important;
}

@keyframes modalPop {
    from { opacity: 0; transform: scale(0.92) translateY(12px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}

/* Touchscreen Numeric Keypad Buttons */
.keypad-btn {
    height: 52px !important;
    border-radius: 12px !important;
    border: 1px solid #cbd5e1 !important;
    background: #ffffff !important;
    color: var(--ink) !important;
    font-size: 20px !important;
    font-weight: 700 !important;
    cursor: pointer !important;
    box-shadow: 0 2px 4px rgba(0,0,0,0.04) !important;
    transition: all 0.12s ease !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    user-select: none !important;
}

.keypad-btn:hover {
    background: #f1f5f9 !important;
    border-color: #0284c7 !important;
}

.keypad-btn:active {
    transform: scale(0.94) !important;
    background: #e2e8f0 !important;
}

/* PIN Keypad Buttons */
.pin-key-btn {
    height: 48px !important;
    border-radius: 12px !important;
    border: 1px solid #cbd5e1 !important;
    background: #ffffff !important;
    color: var(--ink) !important;
    font-size: 18px !important;
    font-weight: 700 !important;
    cursor: pointer !important;
    box-shadow: 0 2px 4px rgba(0,0,0,0.04) !important;
    transition: all 0.12s ease !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    user-select: none !important;
}

.pin-key-btn:hover {
    background: #f0fdf4 !important;
    border-color: #b8dcc5 !important;
}

.pin-key-btn:active {
    transform: scale(0.94) !important;
    background: #e2e8f0 !important;
}

/* Active Poliklinik Selected Card Highlight */
.poli-grid-card.active-selected {
    background: #dcfce7 !important;
    border-color: #16a34a !important;
    box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.4), 0 4px 12px rgba(22, 163, 74, 0.2) !important;
    transform: scale(1.03) !important;
}

/* ==================== GLOBAL PAGE LOADER WITH LOGO ==================== */
.page-loader-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(255, 255, 255, 0.88);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    z-index: 9999999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.page-loader-overlay.show {
    opacity: 1;
    pointer-events: auto;
}

.page-loader-box {
    position: relative;
    width: 110px;
    height: 110px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.page-loader-spinner {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 4px solid transparent;
    border-top-color: var(--green-primary);
    border-right-color: #0284c7;
    border-bottom-color: #e11d48;
    border-left-color: #ea580c;
    animation: spinLoaderRing 1.1s linear infinite;
    box-shadow: 0 0 20px rgba(0, 131, 62, 0.25);
}

.page-loader-logo {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #ffffff;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
    animation: pulseLoaderLogo 1.6s ease-in-out infinite alternate;
}

@keyframes spinLoaderRing {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes pulseLoaderLogo {
    0% { transform: scale(0.94); }
    100% { transform: scale(1.04); }
}

