        :root {
            --bg: #f3f6fb;
            --panel: #ffffff;
            --panel-soft: rgba(255, 255, 255, 0.78);
            --text: #18212f;
            --muted: #64748b;
            --line: #e5eaf2;
            --brand: #0b5fff;
            --brand-dark: #0847c7;
            --brand-soft: #e9f1ff;
            --danger: #c62828;
            --success: #0f9d58;
            --shadow: 0 12px 30px rgba(16, 24, 40, 0.08);
        }

        * { box-sizing: border-box; }

        body {
            margin: 0;
            min-height: 100vh;
            background:
                radial-gradient(circle at top left, rgba(11, 95, 255, 0.14), transparent 35%),
                radial-gradient(circle at top right, rgba(15, 157, 88, 0.08), transparent 28%),
                var(--bg);
            color: var(--text);
            font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
        }

        body.login-page {
            background: #003600;
            color: #F5E6D3;
        }

        button, input, select {
            font: inherit;
        }

        input[type="checkbox"] {
            width: 20px;
            height: 20px;
            margin: 0;
            accent-color: var(--brand);
            cursor: pointer;
            vertical-align: middle;
        }

        button {
            border: 0;
            cursor: pointer;
        }

        .page {
            width: 100%;
            max-width: 1040px;
            margin: 0 auto;
            padding: 20px 14px 36px;
        }

        .card {
            background: var(--panel);
            border: 1px solid var(--line);
            border-radius: 18px;
            padding: 18px;
            box-shadow: var(--shadow);
        }

        .confirm-mask {
            position: fixed;
            inset: 0;
            z-index: 6000;
            display: grid;
            place-items: center;
            padding: 20px;
            background: rgba(15, 23, 42, 0.42);
        }

        .confirm-panel {
            width: min(420px, 100%);
            border-radius: 18px;
            border: 1px solid var(--line);
            background: #fff;
            padding: 20px;
            box-shadow: 0 24px 60px rgba(15, 23, 42, 0.26);
        }

        .confirm-message {
            margin: 12px 0 0;
            color: var(--muted);
            line-height: 1.7;
        }

        .confirm-actions {
            display: flex;
            justify-content: flex-end;
            gap: 10px;
            margin-top: 18px;
        }

        .panel {
            background: var(--panel-soft);
            backdrop-filter: blur(10px);
        }

        .status {
            color: var(--muted);
            font-size: 14px;
        }

        .status.error {
            color: var(--danger);
        }

        .status.success {
            color: var(--success);
        }

        .btn {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            gap: 8px;
            min-height: 44px;
            padding: 0 18px;
            border-radius: 12px;
            text-decoration: none;
            font-size: 15px;
            font-weight: 600;
        }

        .btn-primary {
            background: var(--brand);
            color: #fff;
        }

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

        .btn-secondary {
            background: var(--brand-soft);
            color: var(--brand);
        }

        .btn-ghost {
            background: transparent;
            color: var(--muted);
            border: 1px solid var(--line);
        }

        .btn-danger {
            background: #fff1f1;
            color: var(--danger);
        }

        .top-actions {
            display: flex;
            align-items: center;
            gap: 10px;
            margin-top: 14px;
            flex-wrap: wrap;
        }

        .publish-action-row {
            display: flex;
            align-items: center;
            gap: 10px;
            flex-wrap: wrap;
        }

        .schedule-control {
            display: flex;
            align-items: center;
            gap: 8px;
            flex-wrap: wrap;
        }

        .schedule-control input {
            width: 260px;
            min-height: 38px;
            border: 1px solid var(--line);
            border-radius: 8px;
            padding: 0 10px;
            color: var(--text);
            background: #fff;
        }

        #scheduledPublishPicker .ant-picker {
            width: 260px;
            min-height: 38px;
            border-radius: 8px;
        }

        #scheduledPublishPicker .ant-picker-input > input {
            min-height: 28px;
            border: 0;
            padding: 0;
        }

        .login-card {
            max-width: 480px;
            margin: 40px auto 0;
        }

        body.login-page .login-card {
            background: #003600;
            border-color: rgba(245, 230, 211, 0.38);
            box-shadow: none;
        }

        body.login-page .section-desc,
        body.login-page .status,
        body.login-page .btn-ghost {
            color: #F5E6D3;
        }

        body.login-page .field input {
            background: #003600;
            border-color: rgba(245, 230, 211, 0.5);
            color: #F5E6D3;
        }

        body.login-page .field input::placeholder {
            color: rgba(245, 230, 211, 0.62);
        }

        body.login-page .btn-primary {
            background: #F5E6D3;
            color: #003600;
        }

        body.login-page .btn-primary:hover {
            background: #ffffff;
        }

        body.login-page .btn-ghost {
            border-color: rgba(245, 230, 211, 0.5);
        }

        body.login-page .hospital-item {
            background: #fff;
            color: var(--text);
        }

        body.login-page .hospital-meta {
            color: var(--muted);
        }

        body.login-page .hospital-item .btn-primary {
            background: var(--brand);
            color: #fff;
        }

        body.login-page .hospital-item .btn-primary:hover {
            background: var(--brand-dark);
        }

        .section-title {
            margin: 0 0 8px;
            font-size: 22px;
        }

        .section-desc {
            margin: 0 0 18px;
            color: var(--muted);
            line-height: 1.7;
            font-size: 14px;
        }

        .field {
            display: flex;
            flex-direction: column;
            gap: 8px;
            margin-bottom: 14px;
        }

        .field label {
            font-size: 14px;
            font-weight: 600;
        }

        .field input {
            height: 48px;
            padding: 0 14px;
            border-radius: 12px;
            border: 1px solid var(--line);
            background: #fff;
            color: var(--text);
        }

        .hospital-list {
            display: grid;
            gap: 10px;
            margin-top: 14px;
        }

        .hospital-item {
            display: flex;
            justify-content: space-between;
            align-items: center;
            gap: 12px;
            padding: 14px 16px;
            border: 1px solid var(--line);
            border-radius: 14px;
            background: #fff;
        }

        .hospital-name {
            font-weight: 600;
        }

        .hospital-meta {
            margin-top: 4px;
            font-size: 12px;
            color: var(--muted);
        }

        .hidden {
            display: none !important;
        }

        .home-header {
            display: flex;
            gap: 14px;
            align-items: center;
            justify-content: space-between;
            flex-wrap: wrap;
        }

        .home-title {
            margin: 0;
            font-size: 24px;
        }

        .home-subtitle {
            margin-top: 6px;
            color: var(--muted);
            font-size: 14px;
        }

        .menu-row {
            display: flex;
            gap: 10px;
            flex-wrap: wrap;
        }

        .toolbar-row {
            display: flex;
            justify-content: space-between;
            gap: 12px;
            align-items: center;
            flex-wrap: wrap;
        }

        .main-toolbar-card {
            position: relative;
            z-index: 3000;
            overflow: visible;
        }

        .menu-pill {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            min-height: 42px;
            padding: 0 18px;
            border-radius: 999px;
            background: var(--brand);
            color: #fff;
            border: 1px solid var(--brand);
            font-weight: 700;
            line-height: 1;
        }

        .menu-pill.is-muted {
            background: #fff;
            color: var(--brand);
        }

        .publish-menu-wrap {
            position: relative;
            z-index: 3100;
        }

        .create-menu {
            position: absolute;
            top: calc(100% + 10px);
            right: 0;
            z-index: 3101;
            width: 190px;
            padding: 8px;
            border: 1px solid var(--line);
            border-radius: 14px;
            background: #fff;
            box-shadow: 0 18px 38px rgba(15, 23, 42, 0.16);
        }

        .create-menu button {
            display: flex;
            align-items: center;
            gap: 12px;
            width: 100%;
            min-height: 46px;
            padding: 0 12px;
            border-radius: 10px;
            background: transparent;
            color: var(--text);
            font-size: 15px;
            font-weight: 650;
            text-align: left;
        }

        .create-menu button:hover {
            background: #f4f7fb;
        }

        .create-menu__icon {
            width: 28px;
            color: var(--muted);
            font-size: 18px;
            text-align: center;
        }

        .list-shell {
            display: grid;
            gap: 14px;
            margin-top: 14px;
        }

        .news-card {
            display: grid;
            grid-template-columns: 64px minmax(0, 1fr) 180px;
            gap: 16px;
            align-items: start;
            padding: 18px;
            border: 1px solid var(--line);
            border-radius: 18px;
            background: #fff;
            box-shadow: var(--shadow);
            cursor: pointer;
        }

        .avatar {
            width: 64px;
            height: 64px;
            border-radius: 50%;
            object-fit: cover;
            border: 1px solid var(--line);
            background: linear-gradient(135deg, #eef4ff, #f7fbff);
        }

        .news-author {
            font-size: 14px;
            color: var(--muted);
            margin-bottom: 8px;
        }

        .news-title {
            margin: 0 0 8px;
            font-size: 18px;
            line-height: 1.5;
        }

        .news-desc {
            margin: 0;
            color: var(--muted);
            font-size: 14px;
            line-height: 1.7;
            display: -webkit-box;
            -webkit-box-orient: vertical;
            -webkit-line-clamp: 3;
            overflow: hidden;
        }

        .news-stats {
            display: flex;
            gap: 18px;
            margin-top: 14px;
            color: var(--muted);
            font-size: 13px;
            flex-wrap: wrap;
        }

        .thumb {
            width: 180px;
            height: 120px;
            object-fit: cover;
            border-radius: 12px;
            border: 1px solid var(--line);
            background: linear-gradient(135deg, #eef4ff, #f9fbff);
        }

        .thumb.video-thumb {
            display: flex;
            align-items: center;
            justify-content: center;
            color: var(--brand);
            font-size: 30px;
            font-weight: 800;
        }

        .thumb.video-frame {
            background: #111827;
        }

        .pdf-thumb-wrap {
            width: 180px;
            height: 120px;
            border-radius: 12px;
            border: 1px solid var(--line);
            overflow: hidden;
            background: #f8fafc;
        }

        .pdf-thumb-wrap iframe {
            width: 180px;
            height: 120px;
            border: 0;
            pointer-events: none;
            background: #fff;
        }

        .video-thumb-wrap {
            position: relative;
            width: 180px;
            height: 120px;
            border-radius: 12px;
            overflow: hidden;
            border: 1px solid var(--line);
            background: #111827;
        }

        .video-thumb-wrap video {
            width: 100%;
            height: 100%;
            object-fit: cover;
            display: block;
        }

        .video-thumb-wrap::after {
            content: "▶";
            position: absolute;
            inset: 0;
            display: grid;
            place-items: center;
            color: var(--brand);
            font-size: 28px;
            font-weight: 800;
            pointer-events: none;
            text-shadow: 0 1px 8px rgba(0, 0, 0, 0.35);
        }

        .detail-shell {
            display: none;
            margin-top: 14px;
        }

        .publish-shell {
            display: none;
            margin-top: 14px;
        }

        .payment-shell {
            display: none;
            margin-top: 14px;
        }

        .detail-topbar {
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 10px;
            margin-bottom: 14px;
            flex-wrap: wrap;
        }

        .publish-topbar {
            padding-left: 18px;
        }

        .preview-topbar {
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 12px;
            margin-bottom: 14px;
        }

        .publish-preview-panel {
            width: min(720px, calc(100vw - 32px));
            max-height: 82vh;
            overflow: auto;
        }

        .publish-preview-body {
            display: grid;
            gap: 14px;
            color: var(--text);
        }

        .publish-preview-body h1 {
            margin: 0;
            font-size: 24px;
            line-height: 1.35;
        }

        .publish-preview-meta {
            color: var(--muted);
            font-size: 13px;
        }

        .publish-preview-cover,
        .publish-preview-video {
            width: 100%;
            max-height: 360px;
            border-radius: 8px;
            object-fit: cover;
            background: var(--bg);
        }

        .publish-preview-content {
            line-height: 1.75;
            word-break: break-word;
        }

        .title {
            margin: 0;
            font-size: 24px;
            line-height: 1.35;
        }

        .meta {
            display: flex;
            flex-wrap: wrap;
            gap: 8px 12px;
            margin-top: 10px;
            color: var(--muted);
            font-size: 13px;
        }

        .detail-stats {
            display: flex;
            flex-wrap: wrap;
            gap: 12px;
            margin-top: 14px;
            color: var(--muted);
            font-size: 13px;
        }

        .cover {
            width: 100%;
            border-radius: 12px;
            margin-top: 14px;
            display: none;
            border: 1px solid var(--line);
        }

        .content {
            margin-top: 16px;
            line-height: 1.75;
            font-size: 16px;
            word-break: break-word;
        }

        .form-grid {
            display: grid;
            gap: 16px;
        }

        .field textarea, .field select {
            min-height: 48px;
            padding: 12px 14px;
            border-radius: 12px;
            border: 1px solid var(--line);
            background: #fff;
            color: var(--text);
            resize: vertical;
        }

        .field textarea.rich {
            min-height: 240px;
        }

        .editor-wrap {
            border: 1px solid var(--line);
            border-radius: 12px;
            overflow: hidden;
            background: #fff;
        }

        .editor-toolbar {
            display: flex;
            align-items: center;
            gap: 6px;
            flex-wrap: wrap;
            padding: 8px 10px;
            border-bottom: 1px solid var(--line);
            background: #f7f8fa;
        }

        .editor-btn {
            min-width: 34px;
            height: 34px;
            padding: 0 8px;
            border-radius: 7px;
            background: transparent;
            color: #424855;
            font-size: 16px;
            font-weight: 650;
            line-height: 34px;
            text-align: center;
        }

        .editor-btn[data-editor-action="insertUnorderedList"],
        .editor-btn[data-editor-action="insertOrderedList"],
        .editor-btn[data-editor-action="blockquote"],
        .editor-btn[data-editor-action="insertHorizontalRule"],
        .editor-btn[data-editor-action="codeBlock"],
        .editor-btn[data-editor-action="table"],
        .editor-btn[data-editor-action="emoji"],
        .editor-btn[data-editor-action="justifyLeft"],
        .editor-btn[data-editor-action="justifyCenter"],
        .editor-btn[data-editor-action="justifyRight"],
        .editor-btn[data-editor-action="justifyFull"],
        .editor-btn[data-editor-action="outdent"],
        .editor-btn[data-editor-action="indent"] {
            font-size: 17px;
        }

        .editor-btn:hover,
        .editor-select:hover,
        .editor-color:hover {
            background: #eef2f7;
        }

        .editor-btn.is-disabled {
            color: #b8c0cc;
            cursor: not-allowed;
            opacity: 0.58;
        }

        .editor-btn.is-disabled:hover {
            background: transparent;
        }

        .editor-btn:disabled,
        .editor-select:disabled {
            color: #b8c0cc;
            cursor: not-allowed;
        }

        .editor-btn.is-active {
            background: #e6efff;
            color: var(--brand);
        }

        .editor-select {
            height: 34px;
            border: 0;
            border-radius: 7px;
            background: transparent;
            color: #424855;
            padding: 0 8px;
            outline: none;
            font-weight: 600;
        }

        #editorFontSizeSelect {
            width: 58px;
            padding: 0 4px;
        }

        .editor-color {
            position: relative;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            width: 34px;
            height: 34px;
            border-radius: 7px;
            color: #424855;
            font-weight: 700;
        }

        .editor-color input {
            position: absolute;
            inset: 0;
            width: 100%;
            height: 100%;
            opacity: 0;
            cursor: pointer;
        }

        .editor-tooltip {
            position: fixed;
            z-index: 5000;
            display: none;
            max-width: 180px;
            padding: 6px 8px;
            border-radius: 7px;
            background: #18212f;
            color: #fff;
            font-size: 12px;
            line-height: 1.2;
            white-space: nowrap;
            pointer-events: none;
            box-shadow: 0 8px 18px rgba(15, 23, 42, 0.18);
        }

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

        .editor-divider {
            width: 1px;
            height: 24px;
            margin: 0 2px;
            background: #dce3ed;
        }

        .editor {
            min-height: 260px;
            padding: 14px;
            outline: none;
            line-height: 1.8;
            font-size: 16px;
        }

        .editor:empty::before {
            content: attr(data-placeholder);
            color: #98a2b3;
        }

        .editor img {
            max-width: 100%;
            height: auto;
            border-radius: 8px;
            margin: 8px 0;
        }

        .editor ul, .editor ol {
            padding-left: 24px;
        }

        .editor blockquote {
            margin: 14px 0;
            padding: 10px 14px;
            border-left: 4px solid var(--brand);
            background: #f5f8ff;
            color: #475569;
        }

        .editor pre {
            padding: 12px;
            border-radius: 8px;
            background: #111827;
            color: #f8fafc;
            overflow-x: auto;
        }

        .editor table {
            width: 100%;
            border-collapse: collapse;
            margin: 14px 0;
        }

        .editor td {
            min-width: 72px;
            border: 1px solid var(--line);
            padding: 8px 10px;
        }

        .inline-row {
            display: flex;
            gap: 16px;
            flex-wrap: wrap;
            align-items: center;
        }

        .check-row {
            display: inline-flex;
            gap: 8px;
            align-items: center;
            color: var(--muted);
            font-size: 14px;
        }

        .cover-preview {
            width: 280px;
            max-width: 100%;
            height: 160px;
            object-fit: cover;
            border-radius: 12px;
            border: 1px solid var(--line);
            display: none;
            background: #fff;
        }

        .video-preview {
            display: none;
            width: min(100%, 420px);
            max-height: 240px;
            border-radius: 12px;
            border: 1px solid var(--line);
            background: #111827;
        }

        .pdf-preview-shell {
            width: min(100%, 680px);
            border: 1px solid var(--line);
            border-radius: 12px;
            overflow: hidden;
            background: #fff;
        }

        .pdf-preview-head {
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 12px;
            padding: 10px 12px;
            background: #f7f9fc;
            color: var(--text);
            font-size: 14px;
            font-weight: 650;
        }

        .pdf-preview {
            display: block;
            width: 100%;
            height: 420px;
            border: 0;
            background: #f8fafc;
        }

        .content img, .content video {
            max-width: 100%;
            height: auto;
            border-radius: 8px;
        }

        .empty {
            text-align: center;
            color: var(--muted);
            padding: 48px 20px;
        }

        .payment-panel {
            display: grid;
            gap: 16px;
        }

        .payment-note {
            color: var(--muted);
            font-size: 14px;
            line-height: 1.7;
            margin: 0;
        }

        .qr-shell {
            display: none;
            gap: 12px;
            justify-items: center;
            padding: 18px;
            border: 1px dashed var(--line);
            border-radius: 16px;
            background: #fcfdff;
        }

        .qr-shell img {
            width: 240px;
            height: 240px;
            border-radius: 16px;
            border: 1px solid var(--line);
            background: #fff;
            padding: 10px;
        }

        .mono {
            font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
            font-size: 13px;
            line-height: 1.6;
            word-break: break-all;
        }

        @media (max-width: 760px) {
            .home-header, .detail-topbar {
                align-items: flex-start;
                flex-direction: column;
            }

            .news-card {
                grid-template-columns: 56px minmax(0, 1fr);
            }

            .thumb {
                width: 100%;
                height: 180px;
                grid-column: 1 / -1;
            }

        }
