html, body, #root { height: 100%; margin: 0; padding: 0; overflow: hidden; background-color: #f8fafc; }
        .custom-scrollbar::-webkit-scrollbar { width: 4px; height: 6px; }
        .custom-scrollbar::-webkit-scrollbar-track { background: transparent; }
        .custom-scrollbar::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 4px; }
        .custom-scrollbar::-webkit-scrollbar-thumb:hover { background: #94a3b8; }
        
        .table-container { height: 100%; overflow: auto; -webkit-overflow-scrolling: touch; }
        .table-container::-webkit-scrollbar { height: 8px; width: 8px; }
        .table-container::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 4px; }
        .history-scroll::-webkit-scrollbar { width: 5px; }
        .history-scroll::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 4px; }
        .schedule-table thead { position: sticky; top: 0; z-index: 20; }
        th { background-clip: padding-box; }
        .auth-bg { background: linear-gradient(135deg, #0f766e 0%, #3730a3 100%); }
        .gmhs-hospital-logo {
            display: block;
            height: auto;
            object-fit: contain;
        }
        .gmhs-auth-brand-logo {
            width: min(100%, 270px);
            max-height: 45px;
        }
        .gmhs-sidebar-brand-full {
            width: min(100%, 172px);
            max-height: 34px;
        }
        .gmhs-sidebar-brand-mark {
            position: relative;
            width: 38px;
            height: 38px;
            flex: 0 0 38px;
            overflow: hidden;
            border-radius: 10px;
            background: #fff;
            box-shadow: inset 0 0 0 1px rgba(2, 134, 111, .14);
        }
        .gmhs-sidebar-brand-mark img {
            position: absolute;
            top: 3px;
            left: 2px;
            width: auto;
            max-width: none;
            height: 32px;
        }


        :root {
            --gmhs-primary: #0866ff;
            --gmhs-primary-strong: #0b4fce;
            --gmhs-accent: #0f9f8f;
            --gmhs-success: #00a884;
            --gmhs-warning: #f59e0b;
            --gmhs-danger: #ef4444;
            --gmhs-surface: rgba(255, 255, 255, 0.96);
            --gmhs-canvas: #f0f2f5;
            --gmhs-border: #dfe3ea;
            --gmhs-text: #111827;
            --gmhs-muted: #606770;
            --gmhs-radius: 8px;
            --gmhs-shadow: 0 1px 2px rgba(15, 23, 42, 0.08), 0 8px 24px rgba(15, 23, 42, 0.05);
            --gmhs-shadow-hover: 0 2px 6px rgba(15, 23, 42, 0.10), 0 12px 28px rgba(15, 23, 42, 0.08);
        }

        * { box-sizing: border-box; }
        body {
            color: var(--gmhs-text);
            font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
            text-rendering: optimizeLegibility;
            -webkit-font-smoothing: antialiased;
        }
        button, input, select, textarea { font: inherit; }
        button, [role="button"], a { touch-action: manipulation; }
        button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
            outline: 3px solid rgba(20, 184, 166, 0.28) !important;
            outline-offset: 2px;
        }
        .gmhs-shell {
            background:
                radial-gradient(circle at 8% 0%, rgba(20, 184, 166, 0.08), transparent 25rem),
                radial-gradient(circle at 100% 0%, rgba(59, 130, 246, 0.08), transparent 32rem),
                var(--gmhs-canvas);
        }
        .gmhs-sidebar {
            background:
                linear-gradient(180deg, rgba(255,255,255,0.98) 0%, rgba(244,248,255,0.98) 55%, rgba(236,253,249,0.98) 100%),
                radial-gradient(circle at 10% 0%, rgba(8,102,255,0.12), transparent 16rem);
            color: #0f172a !important;
            border-right: 1px solid rgba(203,213,225,0.95);
            box-shadow: 8px 0 28px rgba(15, 23, 42, 0.12);
        }
        .gmhs-sidebar > div:first-child {
            background: rgba(255,255,255,0.7);
            border-bottom-color: #dbe7f5 !important;
            backdrop-filter: blur(14px);
            -webkit-backdrop-filter: blur(14px);
        }
        .gmhs-sidebar .text-green-400 {
            color: #02866f !important;
            text-shadow: none;
        }
        .gmhs-sidebar nav a {
            color: #475569 !important;
        }
        .gmhs-sidebar nav a:hover {
            background: rgba(8,102,255,0.08) !important;
            color: #0f3f82 !important;
            box-shadow: inset 0 0 0 1px rgba(8,102,255,0.08);
        }
        .gmhs-sidebar button {
            color: #475569 !important;
        }
        .gmhs-sidebar button:hover {
            color: var(--gmhs-primary) !important;
            background: rgba(8,102,255,0.08) !important;
        }
        .gmhs-sidebar .bg-emerald-400\/15,
        .gmhs-sidebar [class*="bg-emerald-400/15"] {
            background: #e8fbf6 !important;
            color: #0f9f8f !important;
            box-shadow: inset 0 0 0 1px #b9f2e5;
        }
        .gmhs-header {
            position: sticky;
            top: 0;
            background: rgba(255,255,255,0.94) !important;
            backdrop-filter: blur(16px) saturate(150%);
            -webkit-backdrop-filter: blur(16px) saturate(150%);
            border-color: rgba(223,227,234,0.95) !important;
            box-shadow: 0 1px 2px rgba(15,23,42,0.08) !important;
        }
        .gmhs-main { background: transparent !important; }
        .gmhs-content { scrollbar-gutter: stable; }
        .gmhs-main .bg-white.rounded-xl,
        .gmhs-main .bg-white.rounded-lg {
            border-color: var(--gmhs-border);
            box-shadow: var(--gmhs-shadow);
        }
        .gmhs-main .rounded-xl { border-radius: var(--gmhs-radius) !important; }
        .gmhs-main .bg-white.rounded-xl { border-radius: var(--gmhs-radius) !important; }
        .gmhs-main .bg-white.rounded-lg { border-radius: 7px !important; }
        .gmhs-main .bg-white.rounded-xl:hover,
        .gmhs-main .bg-white.rounded-lg:hover { box-shadow: var(--gmhs-shadow-hover); }
        .gmhs-sidebar nav a {
            border-left-width: 0 !important;
            border-radius: var(--gmhs-radius) !important;
        }
        .gmhs-sidebar nav a[aria-label] {
            margin-top: 2px;
            margin-bottom: 2px;
        }
        .gmhs-sidebar nav a.bg-white\/15,
        .gmhs-sidebar nav a[class*="bg-white/15"] {
            background: linear-gradient(135deg, #0866ff 0%, #0f9f8f 100%) !important;
            color: #fff !important;
            box-shadow: 0 10px 22px rgba(8, 102, 255, 0.22), inset 0 0 0 1px rgba(255,255,255,0.24) !important;
        }
        .gmhs-sidebar nav a.bg-white\/15 i,
        .gmhs-sidebar nav a[class*="bg-white/15"] i {
            color: #fff !important;
        }
        .gmhs-main table {
            background: #fff;
            border-radius: var(--gmhs-radius);
        }
        .gmhs-main table tbody tr { transition: background-color .12s ease, box-shadow .12s ease; }
        .gmhs-main table tbody tr:hover {
            background-color: #f7fbff !important;
            box-shadow: inset 3px 0 0 var(--gmhs-primary);
        }
        .gmhs-main table th {
            color: #334155;
            letter-spacing: .02em;
        }
        .gmhs-main button,
        .gmhs-main a[role="button"] {
            transition: background-color .12s ease, border-color .12s ease, color .12s ease, box-shadow .12s ease, transform .12s ease;
        }
        .gmhs-main button:active,
        .gmhs-sidebar a:active { transform: translateY(1px); }
        .gmhs-main input:not([type="checkbox"]):not([type="radio"]),
        .gmhs-main select,
        .gmhs-main textarea {
            border-radius: var(--gmhs-radius) !important;
            border-color: var(--gmhs-border) !important;
            background-color: #fff;
            box-shadow: inset 0 1px 1px rgba(15, 23, 42, 0.04);
        }
        .gmhs-main input:not([type="checkbox"]):not([type="radio"]):focus,
        .gmhs-main select:focus,
        .gmhs-main textarea:focus {
            border-color: var(--gmhs-primary) !important;
            box-shadow: 0 0 0 3px rgba(8, 102, 255, 0.13) !important;
            background-color: #fff;
        }
        .gmhs-main label {
            color: #374151;
        }
        .gmhs-modal-panel {
            border-radius: var(--gmhs-radius) !important;
            box-shadow: 0 24px 64px rgba(15, 23, 42, 0.26) !important;
        }
        .gmhs-main [class*="rounded-2xl"] {
            border-radius: var(--gmhs-radius) !important;
        }
        .gmhs-content article,
        .gmhs-content .gmhs-normal-notes [class*="bg-white"],
        .gmhs-content .gmhs-important-notes [class*="bg-white"],
        .gmhs-content .gmhs-surgery-board [class*="bg-white"] {
            content-visibility: auto;
            contain-intrinsic-size: 96px;
        }
        .gmhs-surgery-board-body {
            min-height: 0;
            overflow: auto;
            background: #f8fafc;
        }
        .gmhs-surgery-board-overview {
            flex: 0 0 auto;
            width: 100%;
            min-height: 0;
            max-height: min(38dvh, 22rem);
            overflow: hidden;
        }
        .gmhs-surgery-work-date {
            position: sticky;
            left: 0;
            z-index: 4;
            width: max-content;
            min-width: 100%;
            padding: .22rem .35rem;
            border-bottom: 1px solid #cbd5e1;
            background: #fff;
            color: #334155;
            font-size: .48rem;
            font-weight: 800;
            white-space: nowrap;
        }
        .gmhs-surgery-grid {
            display: grid;
            width: 100%;
            min-width: 100%;
            align-items: stretch;
            background: #fff;
        }
        .gmhs-surgery-grid-corner,
        .gmhs-surgery-column-header {
            position: sticky;
            top: 0;
            z-index: 3;
            min-height: 1.55rem;
            padding: .22rem .28rem;
            border-right: 1px solid #94a3b8;
            border-bottom: 1px solid #64748b;
            background: #f1f5f9;
            color: #0f172a;
            font-size: .43rem;
            font-weight: 900;
            line-height: 1.05;
        }
        .gmhs-surgery-grid-corner {
            left: 0;
            z-index: 5;
            display: grid;
            place-items: center;
            text-align: center;
        }
        .gmhs-surgery-column-header {
            text-align: center;
        }
        .gmhs-surgery-shift-label {
            position: sticky;
            left: 0;
            z-index: 2;
            display: flex;
            align-items: center;
            justify-content: center;
            min-height: 4.25rem;
            padding: .25rem .1rem;
            border-right: 1px solid #64748b;
            border-bottom: 1px solid #64748b;
            background: #1e4f9a;
            color: #fff;
            font-size: .4rem;
            font-weight: 900;
            line-height: 1.05;
            text-align: center;
            writing-mode: vertical-rl;
            transform: rotate(180deg);
        }
        .gmhs-surgery-column-cell {
            min-height: 4.25rem;
            padding: .12rem;
            border-right: 1px solid #94a3b8;
            border-bottom: 1px solid #64748b;
            background: #fff;
        }
        .gmhs-surgery-case-card {
            margin-bottom: .12rem;
            padding: .15rem .18rem;
            border: 1px solid;
            border-radius: .12rem;
            font-size: .4rem;
            line-height: 1.04;
            overflow: hidden;
        }
        .gmhs-surgery-case-card:last-child {
            margin-bottom: 0;
        }
        .gmhs-surgery-patient {
            overflow: hidden;
            font-weight: 900;
            text-overflow: ellipsis;
            white-space: nowrap;
        }
        .gmhs-surgery-case-time {
            margin-top: .08rem;
            font-weight: 900;
        }
        .gmhs-surgery-procedure,
        .gmhs-surgery-surgeon {
            margin-top: .08rem;
            display: -webkit-box;
            -webkit-box-orient: vertical;
            -webkit-line-clamp: 3;
            overflow: hidden;
        }
        .gmhs-surgery-surgeon {
            font-weight: 800;
            -webkit-line-clamp: 2;
        }
        @media (min-width: 768px) {
            .gmhs-dashboard-right {
                min-height: 0 !important;
                overflow: hidden !important;
            }
            .gmhs-dashboard-right .gmhs-important-notes,
            .gmhs-dashboard-right .gmhs-normal-notes {
                min-height: 8.25rem !important;
                max-height: none !important;
                overflow: hidden !important;
            }
            .gmhs-dashboard-right .gmhs-important-notes {
                flex: var(--gmhs-pinned-note-flex, 1) 1 0 !important;
            }
            .gmhs-dashboard-right .gmhs-normal-notes {
                flex: var(--gmhs-normal-note-flex, 1) 1 0 !important;
            }
            /* Lưu ý ghim ngắn chỉ chiếm đúng chiều cao nội dung; nhiều lưu ý sẽ cuộn trong giới hạn. */
            .gmhs-dashboard-right.gmhs-has-pinned-notes .gmhs-important-notes {
                flex: 0 1 auto !important;
                min-height: 0 !important;
                max-height: min(38dvh, 19rem) !important;
            }
            .gmhs-dashboard-right.gmhs-has-pinned-notes .gmhs-normal-notes {
                flex: 1 1 0 !important;
                min-height: 8.25rem !important;
            }
            .gmhs-dashboard-right.gmhs-no-pinned-notes .gmhs-important-notes,
            .gmhs-dashboard-right.gmhs-no-normal-notes .gmhs-normal-notes {
                flex: 0 0 auto !important;
                min-height: 3.75rem !important;
            }
            .gmhs-dashboard-right.gmhs-no-pinned-notes .gmhs-important-notes > div:last-child,
            .gmhs-dashboard-right.gmhs-no-normal-notes .gmhs-normal-notes > div:last-child {
                padding-top: .45rem !important;
                padding-bottom: .45rem !important;
            }
            .gmhs-dashboard-right .gmhs-important-notes > div:last-child,
            .gmhs-dashboard-right .gmhs-normal-notes > div:last-child {
                min-height: 0 !important;
                overflow-y: auto !important;
            }
            .gmhs-surgery-board-overview.gmhs-no-surgery-data {
                max-height: 4.25rem !important;
            }
        }
        @media (max-width: 767px) {
            .gmhs-dashboard-right .gmhs-important-notes,
            .gmhs-dashboard-right .gmhs-normal-notes {
                max-height: none !important;
            }
        }
        .gmhs-alert-panel {
            border-radius: var(--gmhs-radius) !important;
            box-shadow: 0 18px 45px rgba(15, 23, 42, 0.22) !important;
        }
        .gmhs-toast {
            max-width: min(92vw, 360px);
            pointer-events: none;
        }
        .gmhs-toast > div {
            border-radius: var(--gmhs-radius) !important;
            box-shadow: 0 10px 24px rgba(15, 23, 42, 0.18) !important;
            pointer-events: auto;
        }
        .gmhs-toast-message {
            max-width: 17rem;
            overflow: hidden;
            text-overflow: ellipsis;
            white-space: nowrap;
        }
        .gmhs-toast-close {
            width: 1.6rem;
            height: 1.6rem;
            min-width: 1.6rem;
            min-height: 1.6rem;
        }
        .schedule-table { border-collapse: separate; border-spacing: 0; }
        .schedule-table th, .schedule-table td {
            vertical-align: middle;
            border-color: #e5e7eb !important;
        }
        .schedule-table th {
            background-color: #eef7f6 !important;
            box-shadow: inset 0 -1px 0 #d1e7e3;
        }
        .schedule-table tbody td {
            background-clip: padding-box;
            line-height: 1.18;
        }
        .schedule-table tbody tr:nth-child(2n) td:not(:first-child):not(:nth-child(2)) {
            background-color: rgba(248, 250, 252, 0.58);
        }
        .schedule-table tbody tr:hover td {
            background-color: #f0f7ff !important;
        }
        .schedule-toolbar { scrollbar-width: thin; }
        .schedule-toolbar {
            box-shadow: 0 1px 2px rgba(15, 23, 42, 0.08) !important;
            border-color: var(--gmhs-border) !important;
        }
        .gmhs-main.schedule-view .gmhs-header {
            padding-top: .35rem !important;
            padding-bottom: .35rem !important;
            min-height: 42px;
        }
        .gmhs-main.schedule-view .gmhs-header-title { gap: .45rem !important; }
        .gmhs-main.schedule-view .gmhs-header h1 {
            font-size: .92rem !important;
            line-height: 1 !important;
        }
        .gmhs-main.schedule-view .gmhs-alert-button,
        .gmhs-main.schedule-view .gmhs-logout-button {
            min-width: 30px !important;
            min-height: 30px !important;
            width: 30px !important;
            height: 30px !important;
        }
        .gmhs-main.schedule-view .gmhs-alert-button .gmhs-alert-bell { font-size: .78rem !important; }
        .gmhs-main.schedule-view .gmhs-alert-badge {
            top: -.25rem !important;
            right: -.25rem !important;
            min-width: 16px !important;
            height: 16px !important;
            line-height: 16px !important;
            font-size: 8px !important;
        }
        .gmhs-schedule-tabs {
            padding-top: .35rem !important;
            padding-bottom: .35rem !important;
        }
        .gmhs-schedule-tabs > div {
            padding: .2rem !important;
            border-radius: .55rem !important;
        }
        .gmhs-schedule-tabs button {
            padding: .35rem .95rem !important;
            font-size: .78rem !important;
            line-height: 1.05 !important;
            border-radius: .45rem !important;
        }
        .schedule-toolbar {
            padding: .25rem .35rem !important;
            gap: .35rem !important;
            border-radius: .5rem .5rem 0 0 !important;
        }
        .schedule-toolbar > div { gap: .35rem !important; }
        .schedule-toolbar button {
            padding-top: .25rem !important;
            padding-bottom: .25rem !important;
            line-height: 1.05 !important;
        }
        .schedule-toolbar > div:first-child > div {
            min-width: 92px !important;
            font-size: 10px !important;
            line-height: 1 !important;
        }
        .safe-bottom { padding-bottom: max(0.75rem, env(safe-area-inset-bottom)); }

        @keyframes gmhsBellPulse {
            0%, 100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.48); }
            45% { transform: scale(1.08); box-shadow: 0 0 0 7px rgba(239, 68, 68, 0); }
        }
        @keyframes gmhsBellSwing {
            0%, 100% { transform: rotate(0deg); }
            20% { transform: rotate(13deg); }
            40% { transform: rotate(-11deg); }
            60% { transform: rotate(7deg); }
            80% { transform: rotate(-4deg); }
        }
        .gmhs-alert-unread { animation: gmhsBellPulse 1.35s ease-in-out infinite; }
        .gmhs-alert-unread .gmhs-alert-bell { transform-origin: 50% 8%; animation: gmhsBellSwing 1.35s ease-in-out infinite; }
        .gmhs-alert-panel { box-shadow: 0 22px 55px rgba(15, 23, 42, 0.22); }

        @media (min-width: 1024px) {
            .gmhs-sidebar { transition: width .25s ease, transform .3s ease; }
            .gmhs-main { width: auto !important; min-width: 0; transition: margin-left .25s ease; }
            .gmhs-main.sidebar-expanded { margin-left: 15rem; }
            .gmhs-main.sidebar-collapsed { margin-left: 4.5rem; }
            .gmhs-main.sidebar-hidden { margin-left: 0; }
        }

        @media (max-width: 767px) {
            .gmhs-header { padding-left: .65rem !important; padding-right: .65rem !important; }
            .gmhs-content { padding: .45rem !important; }
            .schedule-table { min-width: 980px; table-layout: fixed; }
            .schedule-table thead tr:first-child > th:first-child,
            .schedule-table td:first-child {
                position: sticky;
                left: 0;
                z-index: 12;
                width: 42px !important;
                min-width: 42px !important;
                max-width: 42px !important;
                box-shadow: 1px 0 0 #dbe4ee;
            }
            .schedule-table thead tr:first-child > th:nth-child(2),
            .schedule-table td:nth-child(2) {
                position: sticky;
                left: 42px;
                z-index: 11;
                width: 48px !important;
                min-width: 48px !important;
                max-width: 48px !important;
                box-shadow: 1px 0 0 #dbe4ee;
            }
            .schedule-table thead tr:first-child > th:first-child,
            .schedule-table thead tr:first-child > th:nth-child(2) { z-index: 30; }
            .schedule-table tbody td:first-child,
            .schedule-table tbody td:nth-child(2) { background: inherit; }
            .gmhs-modal-panel { max-height: calc(100dvh - 1rem) !important; border-radius: var(--gmhs-radius) !important; }
        }


        /* Compact department information card on phones */
        @media (max-width: 767px) {
            .gmhs-dept-info {
                padding: .4rem .45rem !important;
                gap: .35rem !important;
                border-radius: .75rem !important;
            }
            .gmhs-dept-title-row { align-items: center !important; }
            .gmhs-dept-title h2 {
                font-size: .78rem !important;
                line-height: 1.05 !important;
                letter-spacing: .02em !important;
            }
            .gmhs-dept-date {
                margin-top: .12rem !important;
                font-size: .58rem !important;
                line-height: 1 !important;
            }
            .gmhs-dept-clock {
                padding: .22rem .42rem !important;
                gap: .25rem !important;
                border-radius: .45rem !important;
            }
            .gmhs-shift-card {
                display: grid !important;
                grid-template-columns: auto minmax(0, 1fr) !important;
                align-items: start !important;
                gap: .22rem !important;
                padding: .25rem !important;
                border-radius: .5rem !important;
            }
            .gmhs-shift-title {
                padding: .2rem .3rem !important;
                font-size: .52rem !important;
                line-height: 1 !important;
                border-radius: .38rem !important;
            }
            .gmhs-shift-grid {
                grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
                gap: 0 !important;
                align-items: center !important;
            }
            .gmhs-shift-group {
                display: flex !important;
                align-items: center !important;
                gap: .22rem !important;
                min-width: 0 !important;
                padding: 0 .28rem !important;
                border-left: 1px solid #e5e7eb;
            }
            .gmhs-shift-group:first-child { border-left: 0; }
            .gmhs-shift-label {
                display: inline-flex !important;
                align-items: center !important;
                align-self: center !important;
                margin: 0 !important;
                padding-top: 0 !important;
                font-size: .48rem !important;
                line-height: 1 !important;
                flex: 0 0 auto !important;
            }
            .gmhs-shift-names {
                flex: 1 1 auto !important;
                gap: .16rem !important;
                align-items: center !important;
                min-width: 0 !important;
            }
            .gmhs-shift-chip {
                padding: .11rem .27rem !important;
                font-size: .57rem !important;
                line-height: 1.05 !important;
                border-radius: .32rem !important;
            }
            .gmhs-shift-empty {
                font-size: .52rem !important;
                line-height: 1 !important;
            }
        }

        @media (prefers-reduced-motion: reduce) {
            *, *::before, *::after {
                animation-duration: 0.01ms !important;
                animation-iteration-count: 1 !important;
                transition-duration: 0.01ms !important;
                scroll-behavior: auto !important;
            }
        }


        /* Mobile stability & responsive refinements */
        .gmhs-shell { height: 100vh; min-height: 0; }
        .gmhs-main, .gmhs-content { min-width: 0; min-height: 0; }
        .gmhs-header-title, .gmhs-header-search, .gmhs-header-actions { min-width: 0; }
        .gmhs-alert-panel { overscroll-behavior: contain; }
        .gmhs-alert-panel p, .gmhs-alert-panel span { overflow-wrap: anywhere; }
        @supports (height: 100dvh) {
            html, body, #root, .gmhs-shell { height: 100dvh; }
        }

        @media (max-width: 767px) {
            .gmhs-sidebar { width: min(86vw, 18rem) !important; }
            .gmhs-header {
                display: grid !important;
                grid-template-columns: minmax(0, 1fr) auto;
                align-items: center;
                gap: .4rem !important;
                padding-top: .45rem !important;
                padding-bottom: .45rem !important;
            }
            .gmhs-header-title { grid-column: 1; }
            .gmhs-header-actions { grid-column: 2; gap: .35rem !important; }
            .gmhs-header-search {
                grid-column: 1 / -1;
                width: 100%;
                max-width: none !important;
                min-width: 0 !important;
                padding-left: 0 !important;
                padding-right: 0 !important;
            }
            .gmhs-alert-panel {
                position: fixed !important;
                top: 4.2rem !important;
                left: .5rem !important;
                right: .5rem !important;
                width: auto !important;
                max-width: none !important;
                max-height: calc(100dvh - 4.8rem);
                border-radius: var(--gmhs-radius) !important;
            }
            .gmhs-alert-panel > div:last-child { max-height: calc(100dvh - 10rem) !important; }
            .gmhs-schedule-tabs { justify-content: flex-start !important; padding-left: .5rem; padding-right: .5rem; }
            .gmhs-schedule-tabs > div { min-width: max-content; }
            .gmhs-content { -webkit-overflow-scrolling: touch; }
        }

        @media (max-width: 420px) {
            .gmhs-create-label { display: none; }
            .gmhs-header-actions button { flex-shrink: 0; }
            .gmhs-toast { left: .5rem; right: .5rem; top: .45rem; max-width: none; }
            .gmhs-toast > div { padding: .48rem .62rem !important; gap: .42rem !important; }
            .gmhs-toast i { font-size: .95rem !important; }
            .gmhs-toast-message { max-width: calc(100vw - 5.5rem); font-size: .78rem !important; line-height: 1.2 !important; }
        }


        /* Final mobile/web stability */
        .gmhs-local-warning {
            min-height: 100dvh;
            display: flex;
            align-items: center;
            justify-content: center;
            padding: max(1rem, env(safe-area-inset-top)) 1rem max(1rem, env(safe-area-inset-bottom));
            background: linear-gradient(135deg, #0f766e 0%, #1e3a8a 100%);
        }
        .gmhs-local-warning-card {
            width: min(100%, 430px);
            background: rgba(255,255,255,.98);
            border: 1px solid rgba(255,255,255,.7);
            border-radius: var(--gmhs-radius);
            padding: 1.25rem;
            box-shadow: 0 24px 60px rgba(2, 6, 23, .28);
        }
        .gmhs-local-warning-card a,
        .gmhs-local-warning-card button { min-height: 44px; }
        .auth-bg { min-height: 100dvh; padding-top: max(.5rem, env(safe-area-inset-top)); padding-bottom: max(.5rem, env(safe-area-inset-bottom)); }
        @media (max-width: 480px) {
            .auth-bg > div { max-width: calc(100vw - 1rem) !important; border-radius: var(--gmhs-radius) !important; }
            .auth-bg input { font-size: 16px !important; min-height: 46px; }
            .auth-bg button[type="submit"] { min-height: 48px; }
        }


        /* Compact, bright department information bar */
        .gmhs-dept-info {
            display: grid !important;
            grid-template-columns: auto minmax(0, 1fr);
            grid-template-rows: auto auto;
            align-items: center !important;
            column-gap: .7rem !important;
            row-gap: .2rem !important;
            padding: .5rem .8rem !important;
            overflow: hidden !important;
            border: 1px solid #d9eafe !important;
            background: linear-gradient(180deg, #ffffff 0%, #f7fbff 100%) !important;
            box-shadow: 0 10px 24px rgba(59, 130, 246, 0.08) !important;
        }
        .gmhs-dept-title-row {
            grid-column: 1;
            grid-row: 1 / span 2;
            display: flex !important;
            flex-wrap: wrap !important;
            align-items: center !important;
            justify-content: flex-start !important;
            gap: .22rem .34rem !important;
            width: max-content !important;
            min-width: 0;
            padding: 0 !important;
        }
        .gmhs-dept-title-row .gmhs-dept-title {
            display: contents !important;
        }
        .gmhs-dept-title-row .gmhs-dept-title h2 {
            order: 1;
            margin: 0 !important;
            min-width: 0;
            font-size: .86rem !important;
            line-height: 1.05 !important;
            letter-spacing: .01em !important;
            color: #1e3a8a !important;
            white-space: nowrap;
        }
        .gmhs-dept-title-row > .gmhs-dept-clock {
            order: 2;
            display: inline-flex !important;
            align-items: center !important;
            min-height: 0;
            white-space: nowrap;
            padding: .16rem .52rem !important;
            border-radius: .72rem !important;
            border: 1px solid #bfdbfe !important;
            background: #f0f9ff !important;
            color: #1d4ed8 !important;
            box-shadow: 0 1px 2px rgba(37, 99, 235, 0.05);
        }
        .gmhs-dept-title-row > .gmhs-dept-clock span {
            font-size: .8rem !important;
            line-height: 1 !important;
            letter-spacing: .03em !important;
        }
        .gmhs-dept-title-row .gmhs-dept-date {
            order: 2;
            margin-top: 0 !important;
            display: inline-flex !important;
            align-items: center !important;
            gap: .28rem !important;
            padding: .18rem .48rem !important;
            border-radius: 999px !important;
            border: 1px solid #bae6fd !important;
            background: #ecfeff !important;
            color: #0f766e !important;
            white-space: nowrap;
            font-size: .76rem !important;
            line-height: 1 !important;
            box-shadow: 0 1px 2px rgba(8, 145, 178, 0.06);
        }
        .gmhs-daily-clock {
            display: inline-flex !important;
            align-items: center !important;
            gap: .28rem !important;
            padding: .18rem .52rem !important;
            border-radius: .55rem !important;
            border: 1px solid #bae6fd !important;
            background: #ecfeff !important;
            color: #0f766e !important;
            font-size: .72rem !important;
            line-height: 1 !important;
            font-weight: 800 !important;
            white-space: nowrap !important;
        }
        .gmhs-daily-date-chip {
            display: none !important;
        }
        .gmhs-assignment-display-tile {
            content-visibility: auto;
            contain-intrinsic-size: 3.25rem;
        }
        .gmhs-shift-host {
            grid-column: 2;
            grid-row: 1 / span 2;
            flex: unset !important;
            width: 100% !important;
            min-width: 0;
            overflow-x: auto !important;
            overflow-y: hidden !important;
            scrollbar-width: none;
            -webkit-overflow-scrolling: touch;
            align-self: center;
        }
        .gmhs-shift-host::-webkit-scrollbar { display: none; }
        .gmhs-shift-card {
            display: flex !important;
            flex-wrap: nowrap !important;
            align-items: center !important;
            width: max-content !important;
            min-width: 100%;
            overflow: visible !important;
            gap: .38rem !important;
            padding: 0 !important;
            background: transparent !important;
            border: 0 !important;
            box-shadow: none !important;
            color: #1e3a8a !important;
        }
        .gmhs-shift-section {
            display: flex;
            flex: 0 0 auto;
            align-items: center;
            gap: .28rem;
            min-width: max-content;
            max-width: none;
        }
        .gmhs-shift-section-duty,
        .gmhs-shift-section-reinforcement {
            flex-grow: 0 !important;
        }
        .gmhs-shift-title {
            background: linear-gradient(180deg, #ecfeff 0%, #dbeafe 100%) !important;
            border: 1px solid #bfdbfe !important;
            color: #1e40af !important;
            box-shadow: 0 1px 2px rgba(59, 130, 246, 0.05);
        }
        .gmhs-reinforcement-title {
            background: linear-gradient(180deg, #fff7ed 0%, #fef3c7 100%) !important;
            border: 1px solid #fcd34d !important;
            color: #b45309 !important;
            box-shadow: 0 1px 2px rgba(245, 158, 11, 0.05);
        }
        .gmhs-shift-groups,
        .gmhs-shift-grid,
        .gmhs-reinforcement-grid {
            display: flex !important;
            flex: 0 0 auto !important;
            flex-wrap: nowrap !important;
            align-items: center;
            width: auto !important;
            max-width: none !important;
            min-width: 0;
            grid-template-columns: none !important;
            gap: .08rem !important;
        }
        .gmhs-shift-group {
            display: flex !important;
            flex: 0 0 auto !important;
            align-items: center !important;
            gap: .24rem !important;
            min-width: max-content !important;
            max-width: none;
            padding: .08rem .42rem !important;
            border-left: 1px solid #e2e8f0;
        }
        .gmhs-shift-group:first-child {
            border-left: 0;
            padding-left: 0 !important;
        }
        .gmhs-shift-label {
            flex: 0 0 auto !important;
            margin: 0 !important;
            color: #64748b !important;
            white-space: nowrap !important;
            font-size: .74rem !important;
        }
        .gmhs-shift-names {
            display: flex !important;
            flex: 0 0 auto !important;
            flex-wrap: nowrap !important;
            align-items: center !important;
            gap: .2rem !important;
            min-width: max-content;
            white-space: nowrap;
            overflow: visible !important;
        }
        .gmhs-shift-chip {
            flex: 0 0 auto;
            max-width: none !important;
            white-space: nowrap !important;
            overflow-wrap: normal !important;
            word-break: normal !important;
            padding: .14rem .42rem !important;
            border-radius: .55rem !important;
            border-color: #c7d2fe !important;
            background: linear-gradient(180deg, #f8fbff 0%, #eef6ff 100%) !important;
            color: #1e3a8a !important;
            box-shadow: 0 1px 1px rgba(30, 64, 175, 0.04);
            font-size: .74rem !important;
            line-height: 1.05 !important;
        }
        .gmhs-shift-names-compact .gmhs-shift-chip {
            padding-left: .34rem !important;
            padding-right: .34rem !important;
            font-size: .7rem !important;
        }
        .gmhs-shift-names-dense .gmhs-shift-chip {
            padding-left: .28rem !important;
            padding-right: .28rem !important;
            font-size: .66rem !important;
        }
        .gmhs-shift-empty {
            color: #94a3b8 !important;
        }
        @media (max-width: 1199px) {
            .gmhs-dept-info {
                grid-template-columns: 1fr !important;
                grid-template-rows: auto auto auto !important;
                row-gap: .32rem !important;
                padding: .48rem .62rem !important;
            }
            .gmhs-dept-title-row {
                grid-column: 1;
                grid-row: 1 / span 2;
                width: 100% !important;
            }
            .gmhs-shift-host {
                grid-column: 1;
                grid-row: 3;
                width: 100% !important;
            }
        }
        @media (max-width: 767px) {
            .gmhs-dept-title-row {
                gap: .18rem .24rem !important;
                width: 100% !important;
            }
            .gmhs-dept-title-row .gmhs-dept-title h2 {
                font-size: .74rem !important;
            }
            .gmhs-dept-title-row .gmhs-dept-date {
                font-size: .62rem !important;
                padding: .12rem .34rem !important;
            }
            .gmhs-dept-title-row > .gmhs-dept-clock {
                padding: .12rem .36rem !important;
            }
            .gmhs-dept-title-row > .gmhs-dept-clock span {
                font-size: .68rem !important;
            }
            .gmhs-shift-card {
                min-width: 0 !important;
                width: 100% !important;
            }
            .gmhs-shift-title,
            .gmhs-reinforcement-title {
                font-size: .64rem !important;
                padding: .16rem .42rem !important;
            }
            .gmhs-shift-label {
                font-size: .62rem !important;
                min-width: 2.8rem;
            }
            .gmhs-shift-chip {
                font-size: .62rem !important;
                padding: .12rem .3rem !important;
            }
        }

        @media print {
            .print\:hidden { display: none !important; }
            .print\:block { display: block !important; }
            .print\:bg-white { background-color: white !important; }
            .print\:overflow-visible { overflow: visible !important; }
            .print\:shadow-none { box-shadow: none !important; }
            .print\:border-none { border: none !important; }
            .print\:rounded-none { border-radius: 0 !important; }
            .print\:w-auto { width: auto !important; }
            .print\:static { position: static !important; }
            .print\:text-xs { font-size: 0.75rem !important; }
            .print\:space-y-6 > * + * { margin-top: 1.5rem !important; }
            .print\:p-0 { padding: 0 !important; }
        }


        /* Phones: show the full duty/reinforcement teams inside the screen width with no horizontal swipe. */
        @media (max-width: 767px) {
            .gmhs-dept-info {
                padding: .44rem .5rem !important;
            }
            .gmhs-shift-host {
                width: 100% !important;
                overflow: visible !important;
            }
            .gmhs-shift-card {
                align-items: stretch !important;
                gap: .26rem !important;
                width: 100% !important;
                min-width: 0 !important;
                flex-wrap: wrap !important;
            }
            .gmhs-shift-section {
                flex: 1 1 100% !important;
                min-width: 0 !important;
                max-width: 100% !important;
                align-items: flex-start;
                flex-wrap: wrap !important;
                gap: .18rem .24rem !important;
            }
            .gmhs-shift-groups,
            .gmhs-shift-grid,
            .gmhs-reinforcement-grid {
                display: flex !important;
                flex-wrap: wrap !important;
                width: 100% !important;
                max-width: 100% !important;
                min-width: 0 !important;
                overflow: visible !important;
                gap: .12rem 0 !important;
            }
            .gmhs-shift-group {
                flex: 1 1 100% !important;
                min-width: 0 !important;
                max-width: 100% !important;
                padding: .08rem 0 !important;
                border-left: 0 !important;
                border-top: 1px solid #e2e8f0 !important;
                gap: .22rem !important;
            }
            .gmhs-shift-group:first-child {
                border-top: 0 !important;
            }
            .gmhs-shift-names {
                flex: 1 1 auto !important;
                min-width: 0 !important;
                max-width: 100% !important;
                display: flex !important;
                flex-wrap: wrap !important;
                white-space: normal !important;
                overflow: visible !important;
                gap: .14rem !important;
            }
            .gmhs-shift-chip {
                max-width: 100% !important;
                padding: .1rem .26rem !important;
                font-size: .58rem !important;
                line-height: 1.05 !important;
            }
            .gmhs-shift-empty {
                white-space: normal !important;
            }
        }

        /* Phones: two-column duty/reinforcement board and one-line daily header. */
        @media (max-width: 767px) {
            .gmhs-assignment-display-grid {
                grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
            }
            .gmhs-assignment-display-tile {
                min-height: 3.35rem !important;
            }
            .gmhs-shift-card {
                display: grid !important;
                grid-template-columns: minmax(0, 1.55fr) minmax(6rem, .85fr) !important;
                align-items: stretch !important;
                gap: .32rem !important;
                flex-wrap: nowrap !important;
            }
            .gmhs-shift-section {
                display: flex !important;
                flex-direction: column !important;
                flex: initial !important;
                min-width: 0 !important;
                max-width: 100% !important;
                gap: .18rem !important;
                padding: .28rem !important;
                border: 1px solid #e2e8f0 !important;
                border-radius: .45rem !important;
                background: rgba(255,255,255,.82) !important;
            }
            .gmhs-shift-section-duty { grid-column: 1; }
            .gmhs-shift-section-reinforcement { grid-column: 2; }
            .gmhs-shift-title,
            .gmhs-reinforcement-title {
                width: max-content !important;
                max-width: 100% !important;
                font-size: .58rem !important;
                padding: .12rem .32rem !important;
                line-height: 1 !important;
            }
            .gmhs-shift-groups,
            .gmhs-shift-grid,
            .gmhs-reinforcement-grid {
                display: flex !important;
                flex-direction: column !important;
                flex-wrap: nowrap !important;
                gap: .1rem !important;
                width: 100% !important;
            }
            .gmhs-shift-group {
                display: grid !important;
                grid-template-columns: 2.25rem minmax(0, 1fr) !important;
                align-items: start !important;
                flex: 0 0 auto !important;
                width: 100% !important;
                min-width: 0 !important;
                max-width: 100% !important;
                padding: .11rem 0 0 !important;
                border-left: 0 !important;
                border-top: 1px solid #e2e8f0 !important;
                gap: .12rem !important;
            }
            .gmhs-shift-group:first-child {
                border-top: 0 !important;
                padding-top: 0 !important;
            }
            .gmhs-shift-label {
                min-width: 0 !important;
                padding-top: .14rem !important;
                font-size: .55rem !important;
                line-height: 1 !important;
            }
            .gmhs-shift-names {
                display: flex !important;
                flex-wrap: wrap !important;
                gap: .1rem !important;
                min-width: 0 !important;
                max-width: 100% !important;
                white-space: normal !important;
            }
            .gmhs-shift-chip {
                max-width: 100% !important;
                padding: .08rem .22rem !important;
                font-size: .55rem !important;
                line-height: 1.05 !important;
                border-radius: .32rem !important;
            }
            .gmhs-shift-empty {
                font-size: .55rem !important;
                line-height: 1.05 !important;
            }
            .gmhs-daily-header {
                display: flex !important;
                flex-direction: row !important;
                align-items: center !important;
                justify-content: space-between !important;
                gap: .35rem !important;
                padding: .38rem .45rem !important;
            }
            .gmhs-daily-title-row {
                flex: 0 0 auto !important;
                min-width: 0 !important;
            }
            .gmhs-daily-title-row h3 {
                font-size: .68rem !important;
                gap: .28rem !important;
            }
            .gmhs-daily-clock {
                padding: .14rem .34rem !important;
                font-size: .6rem !important;
                gap: .18rem !important;
            }
            .gmhs-daily-controls {
                flex: 1 1 auto !important;
                justify-content: flex-end !important;
                flex-wrap: nowrap !important;
                gap: .28rem !important;
                min-width: 0 !important;
            }
            .gmhs-daily-nav-button {
                min-width: 1.65rem !important;
                min-height: 1.65rem !important;
                width: 1.65rem !important;
                height: 1.65rem !important;
            }
            .gmhs-daily-date-input {
                min-width: 6.35rem !important;
                width: 6.35rem !important;
                height: 1.65rem !important;
                font-size: .62rem !important;
                padding-left: .32rem !important;
                padding-right: .32rem !important;
            }
            .gmhs-daily-today-button {
                display: none !important;
            }
            .gmhs-daily-edit-button {
                height: 1.65rem !important;
                padding-left: .45rem !important;
                padding-right: .45rem !important;
                white-space: nowrap !important;
            }
        }

        @media (max-width: 360px) {
            .gmhs-assignment-display-grid {
                grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
                gap: .3rem !important;
                padding: .3rem !important;
            }
            .gmhs-shift-card {
                grid-template-columns: minmax(0, 1.45fr) minmax(5.6rem, .8fr) !important;
                gap: .24rem !important;
            }
            .gmhs-shift-section {
                padding: .22rem !important;
            }
            .gmhs-shift-group {
                grid-template-columns: 2rem minmax(0, 1fr) !important;
            }
            .gmhs-shift-chip {
                font-size: .52rem !important;
                padding: .07rem .18rem !important;
            }
            .gmhs-daily-date-input {
                width: 5.9rem !important;
                min-width: 5.9rem !important;
            }
        }

        /* Mobile dashboard density: uniform duty names, collision-free date bar and
           compact two-column assignment rows. Desktop/tablet layout stays unchanged. */
        @media (max-width: 767px) {
            .gmhs-shift-names .gmhs-shift-chip,
            .gmhs-shift-names-compact .gmhs-shift-chip,
            .gmhs-shift-names-dense .gmhs-shift-chip {
                padding: .08rem .22rem !important;
                font-size: .56rem !important;
                line-height: 1.05 !important;
            }
            .gmhs-daily-header {
                display: grid !important;
                grid-template-columns: minmax(4.65rem, auto) minmax(0, 1fr) !important;
                align-items: center !important;
                gap: .2rem !important;
                padding: .28rem .34rem !important;
                overflow: hidden !important;
            }
            .gmhs-daily-title-row {
                min-width: 0 !important;
                overflow: hidden !important;
            }
            .gmhs-daily-title-row h3 {
                min-width: 0 !important;
                max-width: 100% !important;
                overflow: hidden !important;
                text-overflow: ellipsis !important;
                white-space: nowrap !important;
                font-size: .62rem !important;
            }
            .gmhs-daily-clock {
                display: none !important;
            }
            .gmhs-daily-controls {
                display: flex !important;
                min-width: 0 !important;
                gap: .16rem !important;
                overflow: hidden !important;
            }
            .gmhs-daily-nav-button {
                flex: 0 0 1.5rem !important;
                width: 1.5rem !important;
                min-width: 1.5rem !important;
                height: 1.5rem !important;
                min-height: 1.5rem !important;
            }
            .gmhs-daily-date-input {
                flex: 1 1 5.7rem !important;
                width: auto !important;
                min-width: 5.7rem !important;
                max-width: 7.2rem !important;
                height: 1.5rem !important;
                padding-inline: .25rem !important;
                font-size: .58rem !important;
            }
            .gmhs-daily-edit-button {
                flex: 0 0 1.7rem !important;
                width: 1.7rem !important;
                height: 1.5rem !important;
                padding: 0 !important;
                overflow: hidden !important;
                font-size: 0 !important;
            }
            .gmhs-daily-edit-button i {
                margin: 0 !important;
                font-size: .62rem !important;
            }
            .gmhs-assignment-display-grid {
                grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
                gap: .26rem !important;
                padding: .3rem !important;
            }
            .gmhs-assignment-display-tile {
                flex-direction: row !important;
                align-items: stretch !important;
                min-height: 0 !important;
                height: 2.45rem !important;
                border-radius: .38rem !important;
            }
            .gmhs-assignment-room {
                flex: 0 0 36% !important;
                width: 36% !important;
                min-width: 0 !important;
                min-height: 0 !important;
                padding: .12rem .24rem !important;
                border-right: 1px solid #e5e7eb !important;
                border-bottom: 0 !important;
            }
            .gmhs-assignment-room-label,
            .gmhs-assignment-person-label {
                display: -webkit-box !important;
                -webkit-box-orient: vertical !important;
                -webkit-line-clamp: 2 !important;
                overflow: hidden !important;
            }
            .gmhs-assignment-room-label {
                font-size: .52rem !important;
                line-height: 1.05 !important;
            }
            .gmhs-assignment-person {
                flex: 1 1 auto !important;
                min-width: 0 !important;
                min-height: 0 !important;
                padding: .12rem .25rem !important;
                justify-content: flex-end !important;
            }
            .gmhs-assignment-person-label {
                width: 100% !important;
                font-size: .63rem !important;
                line-height: 1.05 !important;
                text-align: right !important;
            }
            .gmhs-no-pinned-notes .gmhs-important-notes {
                flex: 0 0 auto !important;
                min-height: 0 !important;
                max-height: 3.25rem !important;
            }
            .gmhs-no-pinned-notes .gmhs-important-notes > div:first-child {
                min-height: 1.55rem !important;
                padding: .22rem .5rem !important;
            }
            .gmhs-no-pinned-notes .gmhs-important-notes > div:last-child {
                flex: 0 0 auto !important;
                min-height: 0 !important;
                padding: .12rem .4rem !important;
                overflow: hidden !important;
            }
            .gmhs-no-pinned-notes .gmhs-important-notes > div:last-child > div {
                padding-block: 0 !important;
                font-size: .58rem !important;
                line-height: 1 !important;
            }
        }

        @media (max-width: 360px) {
            .gmhs-daily-header {
                grid-template-columns: minmax(4.2rem, auto) minmax(0, 1fr) !important;
            }
            .gmhs-daily-title-row h3 {
                font-size: .58rem !important;
            }
            .gmhs-daily-date-input {
                min-width: 5.25rem !important;
            }
            .gmhs-assignment-room-label {
                font-size: .49rem !important;
            }
            .gmhs-assignment-person-label {
                font-size: .59rem !important;
            }
        }

        /* Mobile dashboard order: important notices first, department board right below. */
        @media (max-width: 767px) {
            .gmhs-dashboard-root {
                display: flex !important;
                flex-direction: column !important;
            }
            .gmhs-dashboard-grid {
                display: contents !important;
            }
            .gmhs-dashboard-right {
                display: contents !important;
            }
            .gmhs-important-notes {
                order: -30;
                width: 100%;
            }
            .gmhs-surgery-board {
                order: -25;
                width: 100%;
                max-height: 18rem;
                overflow: hidden;
            }
            .gmhs-surgery-board.gmhs-no-surgery-data {
                max-height: 4rem;
            }
            .gmhs-surgery-board-body {
                min-height: 0;
                overflow-y: auto;
            }
            .gmhs-dept-info {
                order: -20;
                width: 100%;
            }
            .gmhs-dashboard-left {
                order: -10;
                width: 100%;
            }
            .gmhs-normal-notes {
                order: 10;
                width: 100%;
            }
        }

        /* Mobile single-scroll fix for Bảng thông báo */
        @media (max-width: 767px) {
            .gmhs-main {
                overflow: hidden !important;
            }
            .gmhs-content {
                overflow-y: auto !important;
                overflow-x: hidden !important;
                -webkit-overflow-scrolling: touch;
                overscroll-behavior-y: contain;
                touch-action: pan-y;
                scrollbar-gutter: auto;
            }
            .gmhs-content > div {
                min-width: 0;
            }
        }

        /* Desktop bulletin: keep the page title, duty team and actions on one compact row. */
        @media (min-width: 1024px) {
            .gmhs-main.bulletin-view .gmhs-header {
                flex-wrap: nowrap !important;
                min-height: 42px;
                padding-top: .22rem !important;
                padding-bottom: .22rem !important;
                gap: .35rem !important;
            }
            .gmhs-main.bulletin-view .gmhs-header-title,
            .gmhs-main.bulletin-view .gmhs-header-actions {
                flex: 0 0 auto;
            }
            .gmhs-main.bulletin-view .gmhs-create-button {
                min-height: 26px;
                padding: .24rem .48rem !important;
                border-radius: .45rem !important;
                font-size: .64rem !important;
                line-height: 1 !important;
            }
            .gmhs-main.bulletin-view .gmhs-create-button i {
                font-size: .68rem !important;
                margin-right: .3rem !important;
            }
            .gmhs-main.bulletin-view .gmhs-header-actions {
                gap: .25rem !important;
            }
            .gmhs-main.bulletin-view .gmhs-alert-button,
            .gmhs-main.bulletin-view .gmhs-password-button,
            .gmhs-main.bulletin-view .gmhs-logout-button {
                min-width: 28px !important;
                min-height: 28px !important;
                width: 28px !important;
                height: 28px !important;
                margin-left: 0 !important;
            }
            .gmhs-main.bulletin-view .gmhs-user-summary {
                max-width: 76px;
                padding-left: .4rem !important;
            }
            .gmhs-main.bulletin-view .gmhs-user-summary span {
                display: block;
                max-width: 70px;
                overflow: hidden;
                text-overflow: ellipsis;
                white-space: nowrap;
            }
            .gmhs-header-duty-slot {
                align-items: center;
                justify-content: center;
                align-self: stretch;
                margin: 0 .35rem;
                overflow: hidden;
            }
            .gmhs-header-duty-slot .gmhs-dept-info {
                display: block !important;
                width: 100% !important;
                min-width: 0;
                padding: 0 !important;
                border: 0 !important;
                border-radius: 0 !important;
                background: transparent !important;
                box-shadow: none !important;
                overflow: hidden !important;
            }
            .gmhs-header-duty-slot .gmhs-shift-host {
                display: block !important;
                width: 100% !important;
                overflow-x: auto !important;
                overflow-y: hidden !important;
            }
            .gmhs-header-duty-slot .gmhs-shift-card {
                width: max-content !important;
                min-width: 100% !important;
                min-height: 30px;
                padding: .1rem .2rem !important;
            }
            .gmhs-header-duty-slot .gmhs-shift-section {
                flex-wrap: nowrap !important;
            }
            .gmhs-dept-info-inline {
                display: none !important;
            }
            .gmhs-main.bulletin-view .gmhs-content {
                overflow-y: auto !important;
                overflow-x: hidden !important;
            }
            .gmhs-main.bulletin-view .gmhs-dashboard-root {
                height: auto !important;
                min-height: 100%;
            }
            .gmhs-main.bulletin-view .gmhs-dashboard-grid {
                flex: 0 0 auto !important;
                height: auto !important;
                overflow: visible !important;
                align-items: flex-start !important;
            }
            .gmhs-main.bulletin-view .gmhs-dashboard-left {
                height: auto !important;
                min-height: 0 !important;
            }
            .gmhs-main.bulletin-view .gmhs-daily-board {
                height: auto !important;
                min-height: 0 !important;
                overflow: visible !important;
            }
            .gmhs-main.bulletin-view .gmhs-daily-body {
                flex: 0 0 auto !important;
                min-height: 0 !important;
                overflow-y: visible !important;
                overflow-x: hidden !important;
            }
            .gmhs-main.bulletin-view .gmhs-assignment-display-grid {
                grid-template-columns: repeat(auto-fill, minmax(8.5rem, 1fr)) !important;
                gap: .32rem !important;
                padding: .4rem !important;
                align-items: stretch;
            }
            .gmhs-main.bulletin-view .gmhs-assignment-display-tile {
                flex-direction: row !important;
                align-items: stretch !important;
                min-height: 2.55rem !important;
                height: auto !important;
                border-radius: .42rem !important;
            }
            .gmhs-main.bulletin-view .gmhs-assignment-display-tile.gmhs-tile-code-blue {
                grid-column: span 2 !important;
            }
            .gmhs-main.bulletin-view .gmhs-assignment-room {
                flex: 0 0 38% !important;
                width: 38% !important;
                min-width: 0 !important;
                padding: .2rem .32rem !important;
                border-right: 1px solid #e5e7eb !important;
                border-bottom: 0 !important;
            }
            .gmhs-main.bulletin-view .gmhs-assignment-display-tile.gmhs-tile-code-blue .gmhs-assignment-room {
                flex: 0 0 auto !important;
                min-width: 4.8rem !important;
                width: auto !important;
            }
            .gmhs-main.bulletin-view .gmhs-assignment-display-tile.gmhs-tile-code-blue .gmhs-assignment-person {
                flex: 1 1 auto !important;
                width: auto !important;
            }
            .gmhs-main.bulletin-view .gmhs-assignment-room-label {
                width: 100%;
                font-size: .61rem !important;
                line-height: 1.08 !important;
                overflow-wrap: anywhere;
            }
            .gmhs-main.bulletin-view .gmhs-assignment-person {
                min-width: 0 !important;
                min-height: 0 !important;
                padding: .2rem .32rem !important;
                justify-content: flex-end !important;
            }
            .gmhs-main.bulletin-view .gmhs-assignment-person-label {
                width: 100%;
                font-size: clamp(.64rem, .7vw, .78rem) !important;
                line-height: 1.08 !important;
                text-align: right !important;
                overflow-wrap: anywhere;
                white-space: normal !important;
            }
            .gmhs-main.bulletin-view .gmhs-dashboard-right {
                position: sticky;
                top: .5rem;
                align-self: flex-start !important;
                height: calc(100dvh - 5.5rem) !important;
                max-height: calc(100dvh - 5.5rem);
            }
        }

        /* Bulletin priority: one shared scrollbar for the whole notice column.
           Each section keeps its natural height, so all pinned notices appear before
           the normal feed without nested section scrollbars. */
        .gmhs-main.bulletin-view .gmhs-dashboard-right {
            height: auto !important;
            max-height: none !important;
            overflow: visible !important;
        }
        .gmhs-main.bulletin-view .gmhs-dashboard-right .gmhs-important-notes,
        .gmhs-main.bulletin-view .gmhs-dashboard-right.gmhs-has-pinned-notes .gmhs-important-notes {
            flex: 0 0 auto !important;
            height: auto !important;
            min-height: 0 !important;
            max-height: none !important;
            overflow: visible !important;
        }
        .gmhs-main.bulletin-view .gmhs-dashboard-right .gmhs-important-notes > div:last-child {
            flex: 0 0 auto !important;
            height: auto !important;
            max-height: none !important;
            overflow: visible !important;
        }
        @media (min-width: 768px) {
            .gmhs-main.bulletin-view .gmhs-dashboard-right {
                height: calc(100dvh - 5.5rem) !important;
                max-height: calc(100dvh - 5.5rem) !important;
                overflow-x: hidden !important;
                overflow-y: auto !important;
                overscroll-behavior: contain;
                scrollbar-gutter: stable;
            }
            .gmhs-main.bulletin-view .gmhs-dashboard-right .gmhs-normal-notes {
                flex: 0 0 auto !important;
                height: auto !important;
                min-height: 0 !important;
                max-height: none !important;
                overflow: visible !important;
            }
            .gmhs-main.bulletin-view .gmhs-dashboard-right .gmhs-normal-notes > div:last-child {
                flex: 0 0 auto !important;
                height: auto !important;
                max-height: none !important;
                overflow: visible !important;
            }
        }

        /* FIX 2026-06-27: Mobile schedule can scroll to the real bottom of the duty table.
           Keep the page fixed, let only the schedule table area scroll, and reserve bottom safe space
           so the last rows are not hidden by Android/Chrome navigation bars. */
        @media (max-width: 767px) {
            .gmhs-main.schedule-view {
                height: 100dvh !important;
                max-height: 100dvh !important;
                overflow: hidden !important;
            }
            .gmhs-main.schedule-view .gmhs-content {
                flex: 1 1 auto !important;
                min-height: 0 !important;
                height: auto !important;
                overflow: hidden !important;
                padding-bottom: max(.5rem, env(safe-area-inset-bottom)) !important;
            }
            .gmhs-main.schedule-view .gmhs-content > div {
                height: 100% !important;
                min-height: 0 !important;
            }
            .gmhs-main.schedule-view .table-container {
                flex: 1 1 auto !important;
                min-height: 0 !important;
                height: auto !important;
                max-height: none !important;
                overflow: auto !important;
                padding-bottom: max(5.5rem, env(safe-area-inset-bottom)) !important;
                scroll-padding-bottom: max(5.5rem, env(safe-area-inset-bottom)) !important;
                overscroll-behavior: contain;
                -webkit-overflow-scrolling: touch;
            }
            .gmhs-main.schedule-view .schedule-table {
                margin-bottom: max(5.5rem, env(safe-area-inset-bottom)) !important;
            }
        }

    
