/* ========== pages.css ========== */
/* 此文件包含各个页面特有的样式，确保不与其他页面冲突 */

#dashboardPage .rich-box {
    /* 保持原样，已在 components.css 中定义 */
}

/* ===================== 基础设置开关行 ===================== */

#basicPage .plugin-ai-switch-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: 52px;
    padding: 0 14px;
    border-radius: 14px;
    border: 1px solid rgba(120, 150, 220, .25);
    background: rgba(7, 15, 28, .58);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .02);
    width: 260px;
    transition: border-color .18s ease, box-shadow .18s ease, background .18s ease;
}

#basicPage .plugin-ai-switch-row:hover {
    border-color: rgba(122, 166, 242, .40);
    background: rgba(9, 17, 31, .70);
}

#basicPage .plugin-ai-switch-label {
    flex: 1 1 auto;
    min-width: 0;
    font-size: 15px;
    font-weight: 700;
    color: #edf4ff;
    line-height: 1.35;
    white-space: nowrap;
}

#basicPage .plugin-ai-switch-row .switch {
    flex: 0 0 auto;
    margin-left: 12px;
}

/* ===================== 插件中心 ===================== */

.plugin-center-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 14px;
}

.plugin-center-title-row {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.plugin-center-title {
    font-size: 24px;
    font-weight: 900;
    color: #f2f7ff;
    letter-spacing: .4px;
}

.plugin-center-sub {
    font-size: 13px;
    color: #8ea5c9;
}

.plugin-card-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 14px;
    align-items: start;
}

.plugin-app-card {
    position: relative;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    min-height: 112px;
    padding: 16px 16px;
    border-radius: 16px;
    cursor: pointer;
    background:
        linear-gradient(180deg, rgba(24, 35, 58, .94) 0%, rgba(20, 29, 48, .96) 100%);
    border: 1px solid rgba(87, 114, 165, .26);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .04),
        0 10px 22px rgba(3, 8, 20, .20);
    transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.plugin-app-card:hover {
    transform: translateY(-2px);
    border-color: rgba(90, 140, 255, .42);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .05),
        0 14px 26px rgba(4, 10, 24, .28);
}

.plugin-app-card.disabled {
    cursor: default;
    opacity: .82;
}

.plugin-app-card.disabled:hover {
    transform: none;
    border-color: rgba(87, 114, 165, .26);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .04),
        0 10px 22px rgba(3, 8, 20, .20);
}

.plugin-app-card.active::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 16px;
    pointer-events: none;
    box-shadow: inset 0 0 0 1px rgba(70, 132, 255, .15);
}

.plugin-app-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    flex: 0 0 44px;
    border-radius: 12px;
    background: linear-gradient(180deg, #4a74c9 0%, #355ca9 100%);
    color: #eef5ff;
    font-size: 24px;
    font-weight: 900;
    box-shadow: 0 8px 18px rgba(29, 63, 128, .30);
    overflow: hidden;
}

.plugin-app-icon img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    border-radius: 12px;
}

.plugin-app-icon.placeholder {
    background: linear-gradient(180deg, rgba(70, 92, 135, .9) 0%, rgba(53, 72, 111, .92) 100%);
    font-size: 22px;
}

.plugin-app-main {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.plugin-app-name {
    font-size: 18px;
    line-height: 1.18;
    font-weight: 900;
    color: #f4f8ff;
    word-break: break-word;
}

.plugin-app-desc {
    font-size: 13px;
    line-height: 1.6;
    color: #aab9d6;
    word-break: break-word;
}

/* ===================== 插件详情页 ===================== */

.plugin-breadcrumbs {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
}

.plugin-breadcrumb-btn {
    appearance: none;
    border: 0;
    background: transparent;
    color: #dce8ff;
    font-size: 15px;
    font-weight: 800;
    cursor: pointer;
    padding: 0;
}

.plugin-breadcrumb-btn:hover {
    color: #6da7ff;
}

.plugin-breadcrumb-sep {
    color: #6384b8;
    font-weight: 700;
}

.plugin-breadcrumb-current {
    color: #4b86ff;
    font-size: 15px;
    font-weight: 900;
    letter-spacing: .12em;
    text-transform: uppercase;
}

/* ===================== HDHive 页面 ===================== */

.plugin-hdhive-oauth-page {
    width: 100%;
}

.plugin-hdhive-oauth-layout {
    display: grid;
    grid-template-columns: minmax(340px, .9fr) minmax(420px, 1.1fr);
    gap: 18px;
    align-items: stretch;
    width: 100%;
}

.plugin-hdhive-oauth-panel {
    position: relative;
    width: 100%;
    min-width: 0;
    padding: 20px 20px 18px;
    border-radius: 22px;
    background:
        radial-gradient(circle at 18% 0%, rgba(65, 138, 255, .12) 0%, transparent 30%),
        linear-gradient(180deg, rgba(18, 28, 50, .98) 0%, rgba(18, 27, 46, .98) 100%);
    border: 1px solid rgba(81, 106, 153, .30);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .045),
        0 18px 34px rgba(2, 7, 20, .26);
    overflow: hidden;
}

.plugin-hdhive-oauth-panel::before {
    content: "";
    position: absolute;
    left: 18px;
    right: 18px;
    top: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(93, 174, 255, .58), transparent);
    opacity: .68;
    pointer-events: none;
}

.plugin-hdhive-oauth-left {
    display: flex;
    flex-direction: column;
}

.plugin-hdhive-oauth-right {
    display: flex;
    flex-direction: column;
}

.plugin-hdhive-shell {
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 0;
    border-radius: 0;
    background: transparent;
    border: 0;
    box-shadow: none;
}

.plugin-hdhive-title {
    text-align: left;
    font-size: 21px;
    line-height: 1.2;
    font-weight: 900;
    color: #f7fbff;
    margin-bottom: 8px;
    letter-spacing: .2px;
}

.plugin-hdhive-oauth-note {
    margin-bottom: 16px;
    color: #9eb2d3;
    line-height: 1.7;
}

.plugin-hdhive-field-grid {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.plugin-hdhive-settings-grid {
    flex: 1 1 auto;
}

.plugin-hdhive-settings-grid .plugin-float-input[readonly] {
    color: #dbeaff;
    background: rgba(7, 15, 28, .42);
    border-color: rgba(120, 150, 220, .18);
    cursor: default;
}

.plugin-hdhive-actions {
    margin-top: 16px;
}

.plugin-hdhive-settings-actions,
.plugin-hdhive-oauth-actions {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 10px;
}

.plugin-hdhive-settings-actions button,
.plugin-hdhive-oauth-actions button {
    min-height: 42px;
    border-radius: 12px;
    font-weight: 900;
}

.plugin-hdhive-auth-box {
    display: flex;
    flex-direction: column;
    gap: 14px;
    min-width: 0;
}

.plugin-hdhive-auth-cards {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.plugin-hdhive-auth-card {
    position: relative;
    min-height: 118px;
    padding: 15px 15px 14px;
    border-radius: 18px;
    background:
        radial-gradient(circle at 100% 0%, rgba(66, 144, 255, .14) 0%, transparent 38%),
        linear-gradient(180deg, rgba(11, 23, 43, .78) 0%, rgba(8, 17, 33, .84) 100%);
    border: 1px solid rgba(108, 139, 198, .24);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .035),
        0 10px 22px rgba(2, 7, 20, .18);
    overflow: hidden;
}

.plugin-hdhive-auth-card::after {
    content: "";
    position: absolute;
    left: 14px;
    right: 14px;
    bottom: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(89, 185, 255, .30), transparent);
    opacity: .72;
}

.plugin-hdhive-auth-card-label {
    font-size: 12px;
    font-weight: 900;
    color: #8fa7cc;
    letter-spacing: .08em;
    text-transform: uppercase;
    margin-bottom: 12px;
}

.plugin-hdhive-auth-status {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 0 14px;
    border-radius: 999px;
    color: #eafff9;
    font-size: 15px;
    font-weight: 900;
    background: linear-gradient(90deg, rgba(19, 185, 155, .90) 0%, rgba(44, 206, 255, .88) 100%);
    border: 1px solid rgba(113, 255, 229, .24);
    box-shadow: 0 8px 18px rgba(24, 186, 201, .18);
}

.plugin-hdhive-auth-status.is-loading {
    color: #d8e7ff;
    background: linear-gradient(90deg, rgba(70, 94, 135, .78) 0%, rgba(55, 74, 110, .78) 100%);
    border-color: rgba(160, 184, 225, .18);
    box-shadow: none;
}

.plugin-hdhive-auth-status.is-unauthorized,
.plugin-hdhive-auth-status.is-expired {
    color: #fff0f0;
    background: linear-gradient(90deg, rgba(215, 75, 88, .95) 0%, rgba(255, 111, 91, .92) 100%);
    border-color: rgba(255, 141, 141, .24);
    box-shadow: 0 8px 18px rgba(204, 58, 74, .18);
}

.plugin-hdhive-token-days {
    display: flex;
    align-items: baseline;
    gap: 4px;
    min-height: 42px;
    color: #f7fbff;
    font-size: 32px;
    line-height: 1;
    font-weight: 950;
    letter-spacing: -.04em;
}

.plugin-hdhive-token-days::after {
    content: "";
}

.plugin-hdhive-token-days.good {
    color: #8fffe5;
}

.plugin-hdhive-token-days.warn {
    color: #ffd36e;
}

.plugin-hdhive-token-days.danger {
    color: #ff8f8f;
}

.plugin-hdhive-auth-card-sub {
    margin-top: 8px;
    font-size: 12px;
    line-height: 1.45;
    color: #8fa7cc;
}

.plugin-hdhive-notify-card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
}

.plugin-hdhive-toggle {
    position: relative;
    display: inline-flex;
    align-items: center;
    width: 62px;
    height: 34px;
    cursor: pointer;
    user-select: none;
}

.plugin-hdhive-toggle input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.plugin-hdhive-toggle-slider {
    position: absolute;
    inset: 0;
    border-radius: 999px;
    background: linear-gradient(180deg, rgba(72, 84, 110, .98) 0%, rgba(45, 55, 78, .98) 100%);
    border: 1px solid rgba(178, 197, 230, .16);
    box-shadow:
        inset 0 2px 7px rgba(0, 0, 0, .26),
        0 8px 16px rgba(2, 7, 20, .18);
    transition: background .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.plugin-hdhive-toggle-slider::before {
    content: "";
    position: absolute;
    width: 26px;
    height: 26px;
    left: 4px;
    top: 3px;
    border-radius: 999px;
    background: linear-gradient(180deg, #f5f9ff 0%, #cbd8ee 100%);
    box-shadow: 0 5px 12px rgba(0, 0, 0, .30);
    transition: transform .18s ease, background .18s ease;
}

.plugin-hdhive-toggle input:checked+.plugin-hdhive-toggle-slider {
    background: linear-gradient(90deg, #14c5a8 0%, #27c9ff 100%);
    border-color: rgba(107, 248, 233, .34);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .20),
        0 10px 20px rgba(23, 191, 203, .24);
}

.plugin-hdhive-toggle input:checked+.plugin-hdhive-toggle-slider::before {
    transform: translateX(27px);
    background: linear-gradient(180deg, #ffffff 0%, #eaf8ff 100%);
}

.plugin-hdhive-oauth-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    padding: 11px 13px;
    border-radius: 14px;
    border: 1px solid rgba(95, 137, 206, .22);
    background: rgba(7, 15, 28, .38);
    color: #91a7ca;
    font-size: 12px;
    line-height: 1.5;
}

.plugin-hdhive-oauth-meta b {
    color: #dce9ff;
    font-weight: 900;
}

.plugin-hdhive-oauth-meta-sep {
    color: rgba(145, 167, 202, .45);
}

.plugin-hdhive-notify-settings {
    margin-top: 2px;
    padding: 14px;
    border-radius: 18px;
    border: 1px solid rgba(95, 137, 206, .20);
    background: rgba(7, 15, 28, .35);
}

.plugin-hdhive-notify-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 12px;
}

.plugin-hdhive-notify-row>label {
    flex: 0 0 auto;
    color: #edf4ff;
    font-size: 14px;
    font-weight: 800;
    white-space: nowrap;
}

.plugin-hdhive-notify-select {
    max-width: 180px;
}

.plugin-hdhive-oauth-debug {
    border: 1px solid rgba(100, 148, 237, .22);
    background: rgba(20, 35, 60, .30);
    border-radius: 14px;
    padding: 12px 14px;
    line-height: 1.7;
    margin: 0;
}

.plugin-hdhive-logout-card {
    position: relative;
    border-color: rgba(255, 113, 113, .24);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .04),
        0 22px 50px rgba(0, 0, 0, .38),
        0 0 0 1px rgba(255, 80, 80, .08);
}

.plugin-hdhive-modal-close {
    position: absolute;
    top: 12px;
    right: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border: 0;
    border-radius: 12px;
    background: rgba(255, 255, 255, .06);
    color: #dce8ff;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
}

.plugin-hdhive-modal-close:hover {
    background: rgba(255, 255, 255, .10);
    color: #fff;
}

/* ===================== 115 页面 ===================== */

.plugin-115-shell {
    width: 100%;
    max-width: 460px;
    margin: 0;
    padding: 18px 18px 16px;
    border-radius: 20px;
    background:
        linear-gradient(180deg, rgba(18, 28, 50, .98) 0%, rgba(18, 27, 46, .98) 100%);
    border: 1px solid rgba(81, 106, 153, .28);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .04),
        0 16px 32px rgba(2, 7, 20, .24);
}

.plugin-115-title {
    text-align: center;
    font-size: 20px;
    font-weight: 900;
    color: #f7fbff;
    margin-bottom: 14px;
}

.plugin-115-form-row {
    display: flex;
    align-items: flex-end;
    gap: 8px;
    margin-bottom: 12px;
}

.plugin-115-select-wrap {
    flex: 1;
    min-width: 0;
}

/* ===================== AI辅助识别 页面 ===================== */

.plugin-ai-shell {
    width: 100%;
    max-width: 520px;
    margin: 0;
    padding: 18px 18px 16px;
    border-radius: 20px;
    background:
        linear-gradient(180deg, rgba(18, 28, 50, .98) 0%, rgba(18, 27, 46, .98) 100%);
    border: 1px solid rgba(81, 106, 153, .28);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .04),
        0 16px 32px rgba(2, 7, 20, .24);
}

.plugin-ai-title {
    text-align: center;
    font-size: 20px;
    font-weight: 900;
    color: #f7fbff;
    margin-bottom: 16px;
}

.plugin-ai-field-grid {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.plugin-ai-actions {
    margin-top: 16px;
}

.plugin-ai-switch-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: 52px;
    padding: 0 14px;
    border-radius: 14px;
    border: 1px solid rgba(120, 150, 220, .25);
    background: rgba(7, 15, 28, .58);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .02);
    width: 260px;
    transition: border-color .18s ease, box-shadow .18s ease, background .18s ease;
}

.plugin-ai-switch-row:hover {
    border-color: rgba(122, 166, 242, .40);
    background: rgba(9, 17, 31, .70);
}

.plugin-ai-switch-label {
    flex: 1 1 auto;
    min-width: 0;
    font-size: 15px;
    font-weight: 700;
    color: #edf4ff;
    line-height: 1.35;
    white-space: nowrap;
}

.plugin-ai-switch-row .switch {
    flex: 0 0 auto;
    margin-left: 12px;
}

/* ===================== 插件/网页端浮动标题输入框 ===================== */

.plugin-float-field,
.plugin-float-select-wrap {
    position: relative;
    width: 100%;
    min-width: 0;
}

.plugin-float-input,
.plugin-float-select-wrap select {
    width: 100%;
    height: 56px;
    padding: 0 16px;
    border-radius: 14px;
    border: 1px solid rgba(120, 150, 220, .25);
    background: rgba(7, 15, 28, .58);
    color: #f4f8ff;
    font-size: 16px;
    line-height: 56px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .02);
    transition:
        border-color .18s ease,
        box-shadow .18s ease,
        background .18s ease,
        color .18s ease;
}

.plugin-float-input::placeholder {
    color: transparent;
}

.plugin-float-input:hover,
.plugin-float-select-wrap select:hover {
    border-color: rgba(122, 166, 242, .40);
    background: rgba(9, 17, 31, .70);
}

.plugin-float-input:focus,
.plugin-float-select-wrap select:focus {
    border-color: rgba(96, 150, 255, .85);
    box-shadow: 0 0 0 3px rgba(79, 131, 255, .10), 0 0 18px rgba(79, 131, 255, .08);
    background: rgba(9, 17, 31, .78);
}

.plugin-float-label {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    max-width: calc(100% - 72px);
    padding: 0 2px;
    color: rgba(219, 232, 251, .72);
    font-size: 16px;
    font-weight: 600;
    line-height: 1;
    pointer-events: none;
    transition:
        top .18s ease,
        transform .18s ease,
        font-size .18s ease,
        color .18s ease,
        background-color .18s ease,
        opacity .18s ease;
    z-index: 2;
    white-space: nowrap;
}

.plugin-float-field:focus-within .plugin-float-label,
.plugin-float-field.has-value .plugin-float-label,
.plugin-float-input:not(:placeholder-shown)+.plugin-float-label {
    top: 0;
    transform: translateY(-50%);
    font-size: 12px;
    color: #73a8ff;
    background: #101a2b;
    opacity: 1;
}

.plugin-float-field:focus-within .plugin-float-label {
    color: #84b4ff;
}

/* 下拉框默认保持浮起，视觉与整站统一 */
.plugin-float-select-wrap .plugin-float-label {
    top: 0;
    transform: translateY(-50%);
    font-size: 12px;
    color: #97accd;
    background: #101a2b;
    opacity: 1;
}

.plugin-float-select-wrap:focus-within .plugin-float-label {
    color: #84b4ff;
}

.plugin-float-field-placeholder .plugin-float-input {
    color: rgba(237, 244, 255, .82);
}

.plugin-start-btn {
    height: 52px;
    min-width: 72px;
    padding: 0 16px;
    border: 0;
    border-radius: 10px;
    background: linear-gradient(180deg, #4b83ff 0%, #3d68d8 100%);
    color: #fff;
    font-size: 18px;
    font-weight: 900;
    cursor: pointer;
    box-shadow: 0 8px 14px rgba(43, 88, 191, .22);
}

.plugin-start-btn:disabled {
    opacity: .72;
    cursor: not-allowed;
}

.plugin-115-result-wrap {
    margin-top: 8px;
}

.plugin-115-qrcode-box {
    width: 100%;
    max-width: 248px;
    min-height: 248px;
    margin: 0 auto;
    padding: 8px;
    border-radius: 0;
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
}

#plugin115QrcodeImg {
    width: 100%;
    max-width: 232px;
    height: auto;
    display: block;
}

.plugin-115-qrcode-placeholder {
    text-align: center;
    font-size: 13px;
    color: #6c7480;
    line-height: 1.6;
    padding: 12px;
}

.plugin-115-status-text {
    margin-top: 14px;
    text-align: center;
    font-size: 17px;
    font-weight: 900;
    color: #d9e8ff;
    min-height: 28px;
}

.plugin-115-status-text.success-text {
    color: #9be065;
}

.plugin-115-status-text.warning-text {
    color: #b7ccff;
}

.plugin-115-status-text.error-text {
    color: #ff8d8d;
}

.plugin-115-success-actions {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    margin-top: 14px;
}

.plugin-115-copy-actions {
    display: flex;
    justify-content: center;
    gap: 10px;
}

.plugin-115-save-panel {
    display: flex;
    justify-content: center;
    align-items: flex-end;
    gap: 10px;
    flex-wrap: wrap;
}

.plugin-115-save-select-wrap {
    width: min(100%, 260px);
    min-width: 220px;
}

.plugin-115-save-btn {
    min-width: 96px;
    white-space: nowrap;
}

.plugin-115-save-status {
    min-height: 20px;
    text-align: center;
    font-size: 13px;
    font-weight: 700;
    color: rgba(219, 232, 251, .78);
    line-height: 1.45;
}

.plugin-115-save-status.success-text {
    color: #9be065;
}

.plugin-115-save-status.warning-text {
    color: #b7ccff;
}

.plugin-115-save-status.error-text {
    color: #ff8d8d;
}

.plugin-action-blue {
    min-width: 112px;
    height: 42px;
    border: 0;
    border-radius: 8px;
    background: linear-gradient(180deg, #4d85ff 0%, #3b67d8 100%);
    color: #fff;
    font-size: 15px;
    font-weight: 900;
    cursor: pointer;
    box-shadow: 0 8px 14px rgba(43, 88, 191, .20);
}

.plugin-action-blue:hover,
.plugin-start-btn:hover {
    filter: brightness(1.04);
}

/* ===================== 响应式 ===================== */

@media (max-width: 1600px) {
    .plugin-card-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

@media (max-width: 1280px) {
    .plugin-card-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 980px) {
    .content-scroll {
        /* 已在 layout.css 中定义，此处无需覆盖 */
    }

    #dashboardPage {
        position: relative;
        top: -18px;
    }

    .plugin-card-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .plugin-115-shell {
        max-width: 420px;
    }

    .plugin-ai-shell {
        max-width: 460px;
    }

    .plugin-hdhive-oauth-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 700px) {
    .plugin-card-grid {
        grid-template-columns: 1fr;
    }

    .plugin-app-card {
        min-height: 102px;
        padding: 14px 14px;
        border-radius: 14px;
    }

    .plugin-app-name {
        font-size: 17px;
    }

    .plugin-app-desc {
        font-size: 12px;
    }

    .plugin-115-shell,
    .plugin-ai-shell {
        max-width: 100%;
        padding: 16px 14px 14px;
        border-radius: 18px;
    }

    .plugin-hdhive-oauth-layout {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .plugin-hdhive-oauth-panel {
        padding: 16px 14px 14px;
        border-radius: 18px;
    }

    .plugin-hdhive-auth-cards {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .plugin-hdhive-auth-card {
        min-height: 104px;
        padding: 14px;
        border-radius: 16px;
    }

    .plugin-hdhive-token-days {
        font-size: 28px;
    }

    .plugin-hdhive-notify-row {
        align-items: flex-start;
        flex-direction: column;
    }

    .plugin-hdhive-notify-select {
        max-width: 100%;
    }

    .plugin-hdhive-settings-actions button,
    .plugin-hdhive-oauth-actions button {
        flex: 1 1 130px;
    }

    .plugin-115-title,
    .plugin-hdhive-title,
    .plugin-ai-title {
        font-size: 18px;
        margin-bottom: 14px;
    }

    .plugin-115-form-row {
        flex-direction: row;
        align-items: flex-end;
        gap: 8px;
    }

    .plugin-start-btn {
        min-width: 68px;
        padding: 0 14px;
        font-size: 17px;
    }

    .plugin-115-qrcode-box {
        max-width: 228px;
        min-height: 228px;
        padding: 8px;
    }

    #plugin115QrcodeImg {
        max-width: 212px;
    }

    .plugin-115-status-text {
        font-size: 16px;
    }

    .plugin-115-success-actions {
        gap: 10px;
    }

    .plugin-115-copy-actions {
        gap: 8px;
    }

    .plugin-115-save-panel {
        grid-template-columns: 1fr;
        padding: 10px;
    }

    .plugin-115-save-btn {
        width: 100%;
    }

    .plugin-action-blue {
        min-width: 104px;
        height: 40px;
        font-size: 14px;
    }

    #basicPage .plugin-ai-switch-row,
    .plugin-ai-switch-row {
        width: 100%;
        max-width: 260px;
        padding: 0 12px;
    }

    #basicPage .plugin-ai-switch-label,
    .plugin-ai-switch-label {
        font-size: 14px;
    }

    .plugin-float-input,
    .plugin-float-select-wrap select {
        font-size: 15px;
    }

    .plugin-float-label {
        font-size: 15px;
    }

    .plugin-float-field:focus-within .plugin-float-label,
    .plugin-float-field.has-value .plugin-float-label,
    .plugin-float-input:not(:placeholder-shown)+.plugin-float-label,
    .plugin-float-select-wrap .plugin-float-label {
        font-size: 12px;
    }
}

/* ===================== HDHive OAuth 视觉贴近目标图 v3 ===================== */
#pluginHDHivePage .page-shell {
    padding: 18px 18px 20px;
    background:
        radial-gradient(circle at 8% 0%, rgba(31, 117, 255, .10) 0%, transparent 34%),
        linear-gradient(180deg, rgba(7, 15, 29, .96) 0%, rgba(5, 12, 24, .98) 100%);
    border-color: rgba(65, 103, 166, .34);
}

#pluginHDHivePage .plugin-breadcrumbs {
    margin-bottom: 14px;
    padding-left: 8px;
}

#pluginHDHivePage .plugin-breadcrumb-btn,
#pluginHDHivePage .plugin-breadcrumb-current {
    font-size: 15px;
}

#pluginHDHivePage .plugin-hdhive-oauth-layout {
    grid-template-columns: minmax(300px, .72fr) minmax(620px, 1.28fr);
    gap: 14px;
    max-width: 1240px;
}

#pluginHDHivePage .plugin-hdhive-oauth-panel {
    padding: 22px 22px 18px;
    border-radius: 14px;
    background:
        radial-gradient(circle at 8% 0%, rgba(37, 111, 255, .13) 0%, transparent 34%),
        linear-gradient(180deg, rgba(13, 26, 46, .95) 0%, rgba(8, 19, 35, .97) 100%);
    border: 1px solid rgba(64, 101, 158, .38);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .045),
        0 14px 28px rgba(0, 7, 20, .22);
}

#pluginHDHivePage .plugin-hdhive-oauth-left {
    min-height: 600px;
}

#pluginHDHivePage .plugin-hdhive-oauth-right {
    min-height: 600px;
}

#pluginHDHivePage .plugin-hdhive-title {
    font-size: 21px;
    margin: 4px 0 14px;
    text-align: center;
    letter-spacing: -.02em;
}

#pluginHDHivePage .plugin-hdhive-oauth-right .plugin-hdhive-title {
    text-align: left;
    margin-bottom: 12px;
}

#pluginHDHivePage .plugin-hdhive-oauth-note {
    margin: 0 0 18px;
    font-size: 14px;
    line-height: 1.65;
    color: #b7c7e5;
}

#pluginHDHivePage .plugin-hdhive-field-grid,
#pluginHDHivePage .plugin-hdhive-settings-grid {
    gap: 14px;
}

#pluginHDHivePage .plugin-float-input,
#pluginHDHivePage .plugin-float-select-wrap select {
    height: 52px;
    line-height: 52px;
    border-radius: 12px;
    padding: 0 16px;
    background: rgba(3, 13, 25, .70);
    border-color: rgba(70, 113, 174, .34);
    font-size: 16px;
    font-weight: 750;
}

#pluginHDHivePage .plugin-float-label,
#pluginHDHivePage .plugin-float-field:focus-within .plugin-float-label,
#pluginHDHivePage .plugin-float-field.has-value .plugin-float-label,
#pluginHDHivePage .plugin-float-input:not(:placeholder-shown)+.plugin-float-label,
#pluginHDHivePage .plugin-float-select-wrap .plugin-float-label {
    color: #4097ff;
    background: #0b182d;
    font-weight: 850;
}

#pluginHDHivePage .plugin-hdhive-settings-actions {
    margin-top: auto;
    padding: 16px 16px 2px;
    margin-left: -22px;
    margin-right: -22px;
    border-top: 1px solid rgba(70, 113, 174, .18);
    background: rgba(10, 22, 40, .48);
}

#pluginHDHivePage .plugin-hdhive-settings-actions button,
#pluginHDHivePage .plugin-hdhive-oauth-actions button {
    min-height: 48px;
    height: 48px;
    padding: 0 18px;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 950;
}

#pluginHDHivePage .plugin-hdhive-settings-actions button {
    flex: 1 1 0;
    min-width: 0;
}

#pluginHDHivePage .plugin-hdhive-auth-box {
    gap: 16px;
}

#pluginHDHivePage .plugin-hdhive-auth-cards {
    grid-template-columns: minmax(180px, .78fr) repeat(2, minmax(240px, 1.11fr));
    gap: 18px;
    width: 100%;
}

#pluginHDHivePage .plugin-hdhive-auth-card {
    min-height: 164px;
    padding: 24px 18px 18px;
    border-radius: 12px;
    background:
        radial-gradient(circle at 82% 6%, rgba(41, 119, 255, .13) 0%, transparent 38%),
        linear-gradient(180deg, rgba(7, 21, 40, .76) 0%, rgba(6, 18, 34, .90) 100%);
    border-color: rgba(74, 119, 181, .38);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .035);
}

#pluginHDHivePage .plugin-hdhive-auth-card-label {
    margin-bottom: 20px;
    color: #d7e4fb;
    font-size: 14px;
    letter-spacing: 0;
    text-transform: none;
}

#pluginHDHivePage .plugin-hdhive-auth-status {
    min-height: auto;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    color: #2dde62;
    font-size: 25px;
    line-height: 1;
}

#pluginHDHivePage .plugin-hdhive-auth-status::before {
    content: "✓";
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 39px;
    height: 39px;
    margin-right: 12px;
    border-radius: 999px;
    border: 3px solid rgba(54, 211, 99, .9);
    color: #34e86a;
    font-size: 24px;
    font-weight: 950;
    box-shadow: 0 0 0 5px rgba(54, 211, 99, .08);
}

#pluginHDHivePage .plugin-hdhive-auth-status.is-loading,
#pluginHDHivePage .plugin-hdhive-auth-status.is-unauthorized,
#pluginHDHivePage .plugin-hdhive-auth-status.is-expired {
    background: transparent;
    border: 0;
    box-shadow: none;
}

#pluginHDHivePage .plugin-hdhive-auth-status.is-loading {
    color: #9fb2cf;
}

#pluginHDHivePage .plugin-hdhive-auth-status.is-loading::before {
    content: "…";
    border-color: rgba(159, 178, 207, .6);
    color: #b4c7e5;
}

#pluginHDHivePage .plugin-hdhive-auth-status.is-unauthorized,
#pluginHDHivePage .plugin-hdhive-auth-status.is-expired {
    color: #ff4a58;
}

#pluginHDHivePage .plugin-hdhive-auth-status.is-unauthorized::before,
#pluginHDHivePage .plugin-hdhive-auth-status.is-expired::before {
    content: "!";
    border-color: rgba(255, 73, 88, .9);
    color: #ff4a58;
    box-shadow: 0 0 0 5px rgba(255, 73, 88, .08);
}

#pluginHDHivePage .plugin-hdhive-token-days {
    min-height: 50px;
    font-size: 54px;
    letter-spacing: -.06em;
    color: #55e84f;
}

#pluginHDHivePage .plugin-hdhive-token-days span:last-child,
#pluginHDHivePage .plugin-hdhive-token-days .unit {
    font-size: 24px;
    letter-spacing: 0;
    margin-left: 6px;
}

#pluginHDHivePage .plugin-hdhive-token-days.warn {
    color: #ff920f;
}

#pluginHDHivePage .plugin-hdhive-token-days.danger {
    color: #ff4b5d;
}

#pluginHDHivePage .plugin-hdhive-auth-card-sub {
    margin-top: 12px;
    font-size: 14px;
    color: #b0c0de;
}

#pluginHDHivePage .plugin-hdhive-notify-card {
    align-items: stretch;
}

#pluginHDHivePage .plugin-hdhive-notify-card .plugin-hdhive-auth-card-label {
    margin-bottom: 16px;
}

#pluginHDHivePage .plugin-hdhive-toggle {
    width: 64px;
    height: 34px;
    margin: 1px 0 13px auto;
}

#pluginHDHivePage .plugin-hdhive-toggle-slider {
    background: linear-gradient(180deg,
            rgba(72, 84, 110, .98) 0%,
            rgba(45, 55, 78, .98) 100%);
    border-color: rgba(178, 197, 230, .16);
}

#pluginHDHivePage .plugin-hdhive-toggle input:checked+.plugin-hdhive-toggle-slider {
    background: linear-gradient(90deg, #185cff 0%, #2aa0ff 100%);
    border-color: rgba(86, 166, 255, .40);
}

#pluginHDHivePage .plugin-hdhive-toggle-slider::before {
    width: 28px;
    height: 28px;
    top: 2px;
    left: 3px;
}

#pluginHDHivePage .plugin-hdhive-toggle input:checked+.plugin-hdhive-toggle-slider::before {
    transform: translateX(29px);
}

#pluginHDHivePage .plugin-hdhive-oauth-meta {
    padding: 0 2px;
    border: 0;
    background: transparent;
    border-radius: 0;
    font-size: 15px;
    color: #a8b8d2;
    gap: 18px;
}

#pluginHDHivePage .plugin-hdhive-oauth-meta b,
#pluginHDHivePage .plugin-hdhive-oauth-meta code {
    color: #d7e4fb;
    font-size: 15px;
    font-weight: 900;
}

#pluginHDHivePage .plugin-hdhive-oauth-meta-sep {
    color: rgba(153, 177, 211, .50);
}

#pluginHDHivePage .plugin-hdhive-oauth-actions {
    gap: 18px;
}

#pluginHDHivePage .plugin-hdhive-oauth-actions button {
    min-width: 150px;
}

#pluginHDHivePage .plugin-hdhive-oauth-actions .danger,
#pluginHDHivePage button.danger {
    color: #ff3948;
    background: rgba(14, 22, 35, .72);
    border: 1px solid rgba(255, 57, 72, .82);
    box-shadow: none;
}

#pluginHDHivePage .plugin-hdhive-notify-settings {
    margin-top: 12px;
    padding: 20px 18px 18px;
    border-radius: 12px;
    background: rgba(7, 20, 37, .58);
    border-color: rgba(74, 119, 181, .36);
}

#pluginHDHivePage .plugin-hdhive-notify-settings .sub-card-title {
    font-size: 17px;
    margin-bottom: 10px;
}

#pluginHDHivePage .plugin-hdhive-notify-settings .group-note {
    font-size: 14px;
    line-height: 1.6;
    color: #aebdd9;
}

#pluginHDHivePage .plugin-hdhive-notify-row {
    justify-content: flex-start;
    gap: 16px;
    margin-top: 18px;
}

#pluginHDHivePage .plugin-hdhive-notify-row>label {
    font-size: 15px;
    color: #dce8ff;
}

#pluginHDHivePage .plugin-hdhive-notify-select {
    width: 128px;
    max-width: 128px;
}

#pluginHDHivePage .plugin-hdhive-notify-select select {
    height: 46px;
    line-height: 46px;
    border-radius: 10px;
    font-size: 15px;
}

#pluginHDHivePage .plugin-hdhive-oauth-debug {
    display: none;
}

#pluginHDHivePage .status-line {
    min-height: 20px;
    margin-top: 8px;
}

#pluginHDHivePage .plugin-hdhive-logout-card {
    width: min(604px, calc(100vw - 36px));
    padding: 30px 26px 26px 106px;
    border-radius: 16px;
    background:
        radial-gradient(circle at 8% 0%, rgba(42, 126, 255, .14) 0%, transparent 40%),
        linear-gradient(180deg, rgba(14, 30, 52, .98) 0%, rgba(9, 22, 40, .99) 100%);
    border-color: rgba(72, 117, 184, .42);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .05),
        0 24px 70px rgba(0, 0, 0, .55);
}

#pluginHDHivePage .plugin-hdhive-logout-card .confirm-accent {
    position: absolute;
    left: 28px;
    top: 28px;
    width: 58px;
    height: 58px;
    margin: 0;
    border-radius: 999px;
    border: 4px solid #ff4050;
    color: #ff4050;
    background: rgba(255, 64, 80, .06);
    font-size: 38px;
    line-height: 50px;
}

#pluginHDHivePage .plugin-hdhive-logout-card .modal-title {
    font-size: 24px;
    margin-bottom: 12px;
}

#pluginHDHivePage .plugin-hdhive-logout-card .modal-sub {
    font-size: 16px;
    line-height: 1.8;
    color: #d0dcf0;
}

#pluginHDHivePage .plugin-hdhive-logout-card .modal-actions {
    justify-content: flex-end;
    gap: 22px;
    margin-top: 26px;
}

#pluginHDHivePage .plugin-hdhive-logout-card .modal-actions button {
    min-width: 136px;
    height: 52px;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 950;
}

#pluginHDHivePage .plugin-hdhive-logout-card .modal-actions .danger {
    color: #fff;
    border: 0;
    background: linear-gradient(180deg, #ff3b4b 0%, #ed2436 100%);
    box-shadow: 0 12px 26px rgba(239, 36, 54, .30);
}

@media (max-width: 1280px) {
    #pluginHDHivePage .plugin-hdhive-oauth-layout {
        grid-template-columns: 320px minmax(0, 1fr);
    }

    #pluginHDHivePage .plugin-hdhive-auth-cards {
        gap: 12px;
    }

    #pluginHDHivePage .plugin-hdhive-token-days {
        font-size: 46px;
    }
}

@media (max-width: 1080px) {
    #pluginHDHivePage .plugin-hdhive-auth-cards {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    #pluginHDHivePage .plugin-hdhive-oauth-layout {
        grid-template-columns: 1fr;
    }

    #pluginHDHivePage .plugin-hdhive-oauth-left,
    #pluginHDHivePage .plugin-hdhive-oauth-right {
        min-height: auto;
    }
}

@media (max-width: 700px) {
    #pluginHDHivePage .page-shell {
        padding: 14px 12px 16px;
    }

    #pluginHDHivePage .plugin-hdhive-oauth-panel {
        padding: 16px 14px 14px;
    }

    #pluginHDHivePage .plugin-hdhive-auth-cards {
        grid-template-columns: 1fr;
    }

    #pluginHDHivePage .plugin-hdhive-auth-card {
        min-height: 120px;
        padding: 18px 16px 16px;
    }

    #pluginHDHivePage .plugin-hdhive-token-days {
        font-size: 42px;
    }

    #pluginHDHivePage .plugin-hdhive-oauth-actions {
        gap: 10px;
    }

    #pluginHDHivePage .plugin-hdhive-oauth-actions button,
    #pluginHDHivePage .plugin-hdhive-settings-actions button {
        flex: 1 1 130px;
        min-width: 0;
    }

    #pluginHDHivePage .plugin-hdhive-logout-card {
        padding: 86px 18px 20px;
    }

    #pluginHDHivePage .plugin-hdhive-logout-card .confirm-accent {
        left: 18px;
        top: 18px;
        width: 54px;
        height: 54px;
        line-height: 46px;
    }
}

/* ===================== HDHive OAuth 状态修正 v4 ===================== */
/* 修正未授权仍显示绿色对号；修正“已过期或未知”过大换行 */
#pluginHDHivePage .plugin-hdhive-auth-status.is-danger,
#pluginHDHivePage .plugin-hdhive-auth-status.is-unauthorized,
#pluginHDHivePage .plugin-hdhive-auth-status.is-expired {
    color: #ff4a58 !important;
}

#pluginHDHivePage .plugin-hdhive-auth-status.is-danger::before,
#pluginHDHivePage .plugin-hdhive-auth-status.is-unauthorized::before,
#pluginHDHivePage .plugin-hdhive-auth-status.is-expired::before {
    content: "!" !important;
    border-color: rgba(255, 73, 88, .9) !important;
    color: #ff4a58 !important;
    box-shadow: 0 0 0 5px rgba(255, 73, 88, .08) !important;
}

#pluginHDHivePage .plugin-hdhive-auth-status.is-warning {
    color: #ff920f !important;
}

#pluginHDHivePage .plugin-hdhive-auth-status.is-warning::before {
    content: "!" !important;
    border-color: rgba(255, 146, 15, .9) !important;
    color: #ff920f !important;
    box-shadow: 0 0 0 5px rgba(255, 146, 15, .08) !important;
}

#pluginHDHivePage .plugin-hdhive-token-days {
    display: flex !important;
    align-items: baseline !important;
    gap: 6px !important;
    min-height: 50px !important;
    white-space: nowrap !important;
    line-height: 1 !important;
}

#pluginHDHivePage .plugin-hdhive-token-days .token-main {
    font-size: 54px !important;
    font-weight: 950 !important;
    letter-spacing: -.06em !important;
}

#pluginHDHivePage .plugin-hdhive-token-days .token-unit {
    font-size: 24px !important;
    font-weight: 950 !important;
    letter-spacing: 0 !important;
}

#pluginHDHivePage .plugin-hdhive-token-days.unknown .token-main {
    font-size: 36px !important;
    letter-spacing: 0 !important;
}

#pluginHDHivePage .plugin-hdhive-token-days.unknown::after {
    content: "" !important;
}

/* ===================== HDHive OAuth 体验修正 v7 ===================== */
/* 未授权/未知状态减小字号，避免视觉过重 */
#pluginHDHivePage .plugin-hdhive-auth-status.is-unauthorized,
#pluginHDHivePage .plugin-hdhive-auth-status.is-expired,
#pluginHDHivePage .plugin-hdhive-auth-status.is-danger {
    font-size: 20px !important;
    font-weight: 900 !important;
}

#pluginHDHivePage .plugin-hdhive-auth-status.is-unauthorized::before,
#pluginHDHivePage .plugin-hdhive-auth-status.is-expired::before,
#pluginHDHivePage .plugin-hdhive-auth-status.is-danger::before {
    width: 32px !important;
    height: 32px !important;
    margin-right: 9px !important;
    border-width: 3px !important;
    font-size: 20px !important;
    box-shadow: 0 0 0 4px rgba(255, 73, 88, .07) !important;
}

#pluginHDHivePage .plugin-hdhive-token-days.unknown {
    min-height: 38px !important;
}

#pluginHDHivePage .plugin-hdhive-token-days.unknown .token-main {
    font-size: 28px !important;
    font-weight: 900 !important;
    letter-spacing: 0 !important;
}

#pluginHDHivePage .plugin-hdhive-logout-card .modal-sub {
    line-height: 1.65 !important;
}

#pluginHDHivePage #HDHIVE_LOGOUT_MODAL.is-info .plugin-hdhive-logout-card {
    border-color: rgba(77, 151, 255, .42) !important;
}

#pluginHDHivePage #HDHIVE_LOGOUT_MODAL.is-info .plugin-hdhive-logout-card .confirm-accent {
    border-color: #4c9cff !important;
    color: #4c9cff !important;
    background: rgba(76, 156, 255, .07) !important;
    font-size: 30px !important;
    font-style: normal !important;
}

#pluginHDHivePage #HDHIVE_LOGOUT_MODAL.is-info .plugin-hdhive-logout-card .modal-actions {
    justify-content: flex-end !important;
}

/* ===================== HDHive 产品化卡片与彩色按钮增强 ===================== */

#pluginHDHivePage .plugin-hdhive-card-title {
    display: flex;
    align-items: center;
    gap: 10px;
}

#pluginHDHivePage .plugin-hdhive-title-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    flex: 0 0 32px;
    border-radius: 10px;
    background:
        radial-gradient(circle at 30% 20%, rgba(255, 255, 255, .34) 0%, transparent 30%),
        linear-gradient(135deg, rgba(99, 102, 241, .95) 0%, rgba(14, 165, 233, .90) 100%);
    box-shadow: 0 10px 20px rgba(62, 99, 231, .24);
    font-size: 16px;
}

#pluginHDHivePage .plugin-hdhive-sub-title {
    margin-bottom: 8px;
    color: #f4f8ff;
    font-size: 16px;
    font-weight: 950;
}

#pluginHDHivePage .plugin-hdhive-signin-settings {
    margin-top: 18px;
    padding: 16px;
    border-radius: 18px;
    background:
        radial-gradient(circle at 0% 0%, rgba(34, 197, 94, .11) 0%, transparent 30%),
        linear-gradient(180deg, rgba(9, 24, 39, .72) 0%, rgba(7, 17, 32, .82) 100%);
    border: 1px solid rgba(76, 211, 194, .20);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .035),
        0 12px 24px rgba(2, 7, 20, .16);
}

#pluginHDHivePage .plugin-hdhive-checkin-grid {
    margin-top: 14px;
    gap: 14px;
}

#pluginHDHivePage .plugin-hdhive-checkin-switches {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
}

#pluginHDHivePage .plugin-hdhive-checkin-switches .plugin-ai-switch-row {
    width: 100%;
    min-height: 54px;
    border-color: rgba(100, 170, 220, .22);
    background:
        linear-gradient(180deg, rgba(8, 20, 37, .74) 0%, rgba(6, 15, 29, .80) 100%);
}

#pluginHDHivePage .plugin-hdhive-gambler-row {
    min-height: 68px !important;
}

#pluginHDHivePage .plugin-hdhive-gambler-note {
    margin: 4px 0 0;
    font-size: 12px;
    line-height: 1.45;
    color: #8ea5c9;
}

#pluginHDHivePage .plugin-action-btn {
    position: relative;
    min-height: 44px;
    padding: 0 18px;
    border: 0 !important;
    border-radius: 14px !important;
    color: #fff !important;
    font-size: 14px;
    font-weight: 950 !important;
    letter-spacing: .02em;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    cursor: pointer;
    transition:
        transform .16s ease,
        filter .16s ease,
        box-shadow .16s ease,
        opacity .16s ease;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .18),
        0 12px 22px rgba(2, 7, 20, .26);
    white-space: nowrap;
}

#pluginHDHivePage .plugin-action-btn:hover {
    transform: translateY(-1px);
    filter: brightness(1.06);
}

#pluginHDHivePage .plugin-action-btn:active {
    transform: translateY(0);
    filter: brightness(.98);
}

#pluginHDHivePage .plugin-action-btn:disabled {
    opacity: .65;
    cursor: not-allowed;
    transform: none;
    filter: none;
}

#pluginHDHivePage .plugin-action-save,
#pluginHDHivePage #savePluginHDHiveBtn {
    background: linear-gradient(135deg, #4f46e5 0%, #2563eb 52%, #06b6d4 100%) !important;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .18),
        0 12px 24px rgba(37, 99, 235, .28);
}

#pluginHDHivePage .plugin-action-auth {
    background: linear-gradient(135deg, #7c3aed 0%, #6366f1 48%, #3b82f6 100%) !important;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .20),
        0 12px 24px rgba(99, 102, 241, .30);
}

#pluginHDHivePage .plugin-action-refresh {
    background: linear-gradient(135deg, #22c55e 0%, #14b8a6 55%, #06b6d4 100%) !important;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .18),
        0 12px 24px rgba(20, 184, 166, .26);
}

#pluginHDHivePage .plugin-action-danger {
    background: linear-gradient(135deg, #ef4444 0%, #f97316 100%) !important;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .16),
        0 12px 24px rgba(239, 68, 68, .26);
}

#pluginHDHivePage .plugin-hdhive-oauth-actions {
    padding-top: 2px;
    gap: 10px;
}

#pluginHDHivePage .plugin-hdhive-auth-status.is-ok {
    color: #ecfff4;
    background: linear-gradient(90deg, rgba(34, 197, 94, .95) 0%, rgba(20, 184, 166, .92) 100%);
    border-color: rgba(134, 239, 172, .32);
    box-shadow: 0 10px 20px rgba(34, 197, 94, .20);
}

#pluginHDHivePage .plugin-hdhive-auth-status.is-danger,
#pluginHDHivePage .plugin-hdhive-auth-status.is-unauthorized,
#pluginHDHivePage .plugin-hdhive-auth-status.is-expired {
    color: #fff4f4;
    background: linear-gradient(90deg, rgba(239, 68, 68, .95) 0%, rgba(248, 113, 113, .90) 100%);
    border-color: rgba(252, 165, 165, .32);
    box-shadow: 0 10px 20px rgba(239, 68, 68, .20);
}

#pluginHDHivePage .plugin-hdhive-notify-settings {
    background:
        radial-gradient(circle at 0% 0%, rgba(250, 204, 21, .10) 0%, transparent 28%),
        linear-gradient(180deg, rgba(9, 21, 38, .68) 0%, rgba(7, 16, 30, .78) 100%);
    border-color: rgba(250, 204, 21, .18);
}

@media (max-width: 700px) {
    #pluginHDHivePage .plugin-action-btn {
        flex: 1 1 140px;
        min-height: 46px;
    }

    #pluginHDHivePage .plugin-hdhive-title-icon {
        width: 30px;
        height: 30px;
        flex-basis: 30px;
        font-size: 15px;
    }

    #pluginHDHivePage .plugin-hdhive-signin-settings {
        padding: 14px;
        border-radius: 16px;
    }
}

/* ===================== HDHive Hero 状态卡最终版：未授权/已授权双样式 ===================== */

/* 修复进入 HDHive 配置页整体下移，与左侧主菜单顶部对齐 */
#pluginHDHivePage .page-shell {
    padding-top: 14px !important;
}

#pluginHDHivePage .plugin-breadcrumbs {
    margin-top: 0 !important;
    margin-bottom: 12px !important;
    padding-top: 0 !important;
}

#pluginHDHivePage .plugin-hdhive-oauth-page,
#pluginHDHivePage .plugin-hdhive-oauth-layout {
    margin-top: 0 !important;
}

#pluginHDHivePage .plugin-hdhive-oauth-left,
#pluginHDHivePage .plugin-hdhive-oauth-right {
    min-height: 0 !important;
}

/* 左侧去掉 Userid/用户名后，整体更紧凑 */
#pluginHDHivePage .plugin-hdhive-settings-grid {
    gap: 14px !important;
}

/* Hero 主卡片：宽幅状态卡 */
#pluginHDHivePage .plugin-hdhive-auth-cards {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 14px !important;
}

#pluginHDHivePage .plugin-hdhive-auth-card:first-child {
    grid-column: 1 / -1 !important;
    position: relative !important;
    min-height: 160px !important;
    padding: 28px 300px 26px 128px !important;
    border-radius: 18px !important;
    overflow: hidden !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    border: 1px solid rgba(113, 166, 255, .38) !important;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .08),
        0 18px 38px rgba(2, 8, 24, .28) !important;
}

/* 未授权背景：蓝灰锁定态 */
#pluginHDHivePage.hdhive-unauthorized .plugin-hdhive-auth-card:first-child,
#pluginHDHivePage:not(.hdhive-authorized) .plugin-hdhive-auth-card:first-child {
    background:
        radial-gradient(circle at 86% 42%, rgba(58, 131, 255, .22) 0%, transparent 30%),
        radial-gradient(circle at 10% 30%, rgba(140, 181, 255, .15) 0%, transparent 32%),
        linear-gradient(135deg, rgba(32, 52, 83, .92) 0%, rgba(14, 31, 58, .94) 52%, rgba(8, 21, 41, .96) 100%) !important;
    border-color: rgba(123, 166, 234, .34) !important;
}

/* 已授权背景：绿色成功态 */
#pluginHDHivePage.hdhive-authorized .plugin-hdhive-auth-card:first-child {
    background:
        radial-gradient(circle at 84% 46%, rgba(16, 185, 129, .25) 0%, transparent 31%),
        radial-gradient(circle at 10% 30%, rgba(34, 197, 94, .20) 0%, transparent 34%),
        linear-gradient(135deg, rgba(0, 88, 68, .90) 0%, rgba(7, 50, 54, .92) 48%, rgba(5, 30, 38, .96) 100%) !important;
    border-color: rgba(16, 185, 129, .44) !important;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .08),
        0 18px 38px rgba(0, 120, 85, .20) !important;
}

/* 左侧圆形主图标 */
#pluginHDHivePage .plugin-hdhive-auth-card:first-child::before {
    content: "🔒";
    position: absolute;
    left: 30px;
    top: 50%;
    transform: translateY(-50%);
    width: 72px;
    height: 72px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background:
        radial-gradient(circle at 30% 20%, rgba(255, 255, 255, .20) 0%, transparent 34%),
        linear-gradient(135deg, rgba(90, 125, 185, .72) 0%, rgba(44, 70, 120, .80) 100%);
    border: 1px solid rgba(180, 210, 255, .22);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .12),
        0 14px 28px rgba(10, 22, 50, .30);
    font-size: 32px;
    z-index: 2;
}

#pluginHDHivePage.hdhive-authorized .plugin-hdhive-auth-card:first-child::before {
    content: "👤";
    background:
        radial-gradient(circle at 30% 20%, rgba(255, 255, 255, .20) 0%, transparent 34%),
        linear-gradient(135deg, rgba(16, 185, 129, .78) 0%, rgba(5, 150, 105, .82) 100%);
    border-color: rgba(134, 239, 172, .24);
}

/* 状态标签和主状态文字 */
#pluginHDHivePage .plugin-hdhive-auth-card:first-child .plugin-hdhive-auth-card-label {
    margin: 0 0 8px !important;
    font-size: 13px !important;
    color: #c7d8f4 !important;
    font-weight: 850 !important;
    letter-spacing: .02em !important;
    text-transform: none !important;
}

#pluginHDHivePage .plugin-hdhive-auth-status {
    width: fit-content !important;
    min-height: auto !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    font-size: 32px !important;
    line-height: 1.05 !important;
    font-weight: 950 !important;
    letter-spacing: -.04em !important;
}

#pluginHDHivePage .plugin-hdhive-auth-status.is-danger,
#pluginHDHivePage .plugin-hdhive-auth-status.is-unauthorized,
#pluginHDHivePage .plugin-hdhive-auth-status.is-expired {
    color: #f8fbff !important;
}

#pluginHDHivePage .plugin-hdhive-auth-status.is-ok {
    color: #30ff9a !important;
}

#pluginHDHivePage .plugin-hdhive-auth-status::before {
    content: none !important;
}

/* 状态说明：未授权显示，已授权隐藏 */
#pluginHDHivePage .plugin-hdhive-auth-card:first-child::after {
    content: "请先完成 OAuth 授权以使用所有功能。";
    position: static;
    display: block;
    height: auto;
    margin-top: 10px;
    background: none;
    opacity: 1;
    color: #c8d7f2;
    font-size: 14px;
    line-height: 1.55;
    font-weight: 650;
}

#pluginHDHivePage.hdhive-authorized .plugin-hdhive-auth-card:first-child::after {
    content: "" !important;
    display: none !important;
}

/* 中间用户信息区 */
#pluginHDHivePage .plugin-hdhive-hero-user {
    position: absolute;
    left: 52%;
    top: 50%;
    transform: translateY(-50%);
    width: 210px;
    padding-left: 28px;
    border-left: 1px solid rgba(168, 196, 240, .14);
    z-index: 3;
}

#pluginHDHivePage .plugin-hdhive-hero-user-row {
    display: grid;
    grid-template-columns: 26px 1fr;
    align-items: start;
    gap: 10px;
}

#pluginHDHivePage .plugin-hdhive-hero-user-icon {
    color: #17d7ff;
    font-size: 18px;
    line-height: 1.2;
    text-shadow: 0 0 12px rgba(23, 215, 255, .42);
}

#pluginHDHivePage.hdhive-authorized .plugin-hdhive-hero-user-icon {
    color: #20f3a2;
    text-shadow: 0 0 12px rgba(32, 243, 162, .42);
}

#pluginHDHivePage .plugin-hdhive-hero-user-label {
    color: #23c8ff;
    font-size: 13px;
    font-weight: 850;
    line-height: 1.25;
}

#pluginHDHivePage.hdhive-authorized .plugin-hdhive-hero-user-label {
    color: #29f3a8;
}

#pluginHDHivePage .plugin-hdhive-hero-user-value {
    margin-top: 6px;
    color: #f7fbff;
    font-size: 22px;
    font-weight: 950;
    line-height: 1.12;
}

#pluginHDHivePage .plugin-hdhive-hero-user-divider {
    height: 1px;
    margin: 16px 0;
    background: linear-gradient(90deg, rgba(122, 165, 235, .18), transparent);
}

/* 右侧插画 */
#pluginHDHivePage .plugin-hdhive-oauth-hero-art {
    position: absolute;
    right: 22px;
    top: 50%;
    transform: translateY(-50%);
    width: 245px;
    height: 138px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: .96;
    pointer-events: none;
    z-index: 2;
}

#pluginHDHivePage .plugin-hdhive-oauth-hero-art img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 18px 28px rgba(39, 106, 255, .26));
}

#pluginHDHivePage.hdhive-authorized .plugin-hdhive-oauth-hero-art img {
    filter: drop-shadow(0 18px 30px rgba(16, 185, 129, .28));
}

/* 左侧图标输入项：参考图风格 */
#pluginHDHivePage .plugin-float-field.with-left-icon::before {
    content: attr(data-icon);
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    width: 30px;
    height: 30px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    z-index: 3;
    font-size: 16px;
    background:
        radial-gradient(circle at 28% 18%, rgba(255, 255, 255, .22) 0%, transparent 34%),
        linear-gradient(135deg, rgba(59, 130, 246, .76) 0%, rgba(99, 102, 241, .62) 100%);
    border: 1px solid rgba(148, 180, 255, .20);
    box-shadow: 0 8px 16px rgba(20, 45, 100, .22);
    pointer-events: none;
}

#pluginHDHivePage .plugin-float-field.with-left-icon .plugin-float-input {
    padding-left: 58px !important;
}

#pluginHDHivePage .plugin-float-field.with-left-icon .plugin-float-label {
    left: 58px !important;
}

#pluginHDHivePage .plugin-float-field.with-left-icon:focus-within .plugin-float-label,
#pluginHDHivePage .plugin-float-field.with-left-icon.has-value .plugin-float-label,
#pluginHDHivePage .plugin-float-field.with-left-icon .plugin-float-input:not(:placeholder-shown)+.plugin-float-label {
    left: 18px !important;
}

/* 按钮区：图标恢复清晰，红底白色垃圾桶 */
#pluginHDHivePage .plugin-hdhive-oauth-actions {
    margin-top: 8px !important;
    padding: 14px 16px !important;
    gap: 24px !important;
    border-radius: 18px !important;
    background:
        radial-gradient(circle at 40% 0%, rgba(124, 58, 237, .16) 0%, transparent 34%),
        linear-gradient(180deg, rgba(8, 20, 38, .62) 0%, rgba(5, 14, 28, .72) 100%) !important;
    border: 1px solid rgba(92, 133, 205, .22) !important;
}

#pluginHDHivePage .plugin-action-btn {
    flex: 1 1 0 !important;
    min-height: 58px !important;
    border-radius: 16px !important;
    font-size: 18px !important;
    font-weight: 950 !important;
    gap: 12px !important;
}

#pluginHDHivePage #HDHIVE_OAUTH_AUTHORIZE_BTN,
#pluginHDHivePage #HDHIVE_OAUTH_FORCE_REFRESH_BTN,
#pluginHDHivePage #HDHIVE_OAUTH_LOGOUT_BTN {
    font-size: 0 !important;
}

#pluginHDHivePage #HDHIVE_OAUTH_AUTHORIZE_BTN::before {
    content: "🔒";
    font-size: 28px;
    line-height: 1;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, .25));
}

#pluginHDHivePage #HDHIVE_OAUTH_AUTHORIZE_BTN::after {
    content: "授权";
    font-size: 18px;
    font-weight: 950;
}

#pluginHDHivePage #HDHIVE_OAUTH_FORCE_REFRESH_BTN::before {
    content: "♻";
    width: 30px;
    height: 30px;
    display: inline-flex;
    align-items: center;
    justify-content: center;

    color: #fff;
    font-size: 24px;
    font-weight: 900;
    line-height: 1;

    text-shadow:
        0 2px 8px rgba(0, 0, 0, .42),
        0 0 1px rgba(255, 255, 255, .35);
}

#pluginHDHivePage #HDHIVE_OAUTH_FORCE_REFRESH_BTN::after {
    content: "刷新 Token";
    font-size: 18px;
    font-weight: 950;
}

#pluginHDHivePage #HDHIVE_OAUTH_LOGOUT_BTN::before {
    content: "";
    width: 28px;
    height: 28px;
    flex: 0 0 28px;
    display: inline-block;
    background: #fff;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, .25));
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 6h18'/%3E%3Cpath d='M8 6V4h8v2'/%3E%3Cpath d='M19 6l-1 15H6L5 6'/%3E%3Cpath d='M10 11v6'/%3E%3Cpath d='M14 11v6'/%3E%3C/svg%3E") center / contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 6h18'/%3E%3Cpath d='M8 6V4h8v2'/%3E%3Cpath d='M19 6l-1 15H6L5 6'/%3E%3Cpath d='M10 11v6'/%3E%3Cpath d='M14 11v6'/%3E%3C/svg%3E") center / contain no-repeat;
}

#pluginHDHivePage #HDHIVE_OAUTH_LOGOUT_BTN::after {
    content: "撤销";
    font-size: 18px;
    font-weight: 950;
}

/* Token 未授权时显示横线和等待授权 */
#pluginHDHivePage .plugin-hdhive-token-days.unknown,
#pluginHDHivePage .plugin-hdhive-token-days.danger.unknown {
    color: #e5eefc !important;
    font-size: 0 !important;
}

#pluginHDHivePage .plugin-hdhive-token-days.unknown .token-main,
#pluginHDHivePage .plugin-hdhive-token-days.unknown .token-unit {
    display: none !important;
}

#pluginHDHivePage .plugin-hdhive-token-days.unknown::before {
    content: "—";
    display: inline-block;
    font-size: 34px;
    color: #e8f0ff;
    line-height: 1;
}

#pluginHDHivePage .plugin-hdhive-auth-card:has(.plugin-hdhive-token-days.unknown) .plugin-hdhive-auth-card-sub {
    font-size: 0 !important;
}

#pluginHDHivePage .plugin-hdhive-auth-card:has(.plugin-hdhive-token-days.unknown) .plugin-hdhive-auth-card-sub::after {
    content: "等待 OAuth 授权";
    font-size: 13px;
    color: #b9c9e6;
}

/* 响应式 */
@media (max-width: 980px) {
    #pluginHDHivePage .plugin-hdhive-auth-card:first-child {
        padding-right: 220px !important;
    }

    #pluginHDHivePage .plugin-hdhive-oauth-hero-art {
        width: 190px;
    }

    #pluginHDHivePage .plugin-hdhive-hero-user {
        position: static;
        transform: none;
        width: auto;
        margin-top: 14px;
        padding-left: 0;
        border-left: 0;
    }
}

@media (max-width: 700px) {
    #pluginHDHivePage .plugin-hdhive-auth-cards {
        grid-template-columns: 1fr !important;
        gap: 12px !important;
    }

    #pluginHDHivePage .plugin-hdhive-auth-card:first-child {
        padding: 20px 16px !important;
        min-height: auto !important;
        display: grid !important;
        grid-template-columns: 86px minmax(0, 1fr) !important;
        column-gap: 14px !important;
        row-gap: 10px !important;
        align-items: center !important;
    }

    #pluginHDHivePage .plugin-hdhive-auth-card:first-child::before {
        position: static !important;
        transform: none !important;
        width: 58px !important;
        height: 58px !important;
        margin: 0 auto 10px !important;
        font-size: 26px !important;
        grid-column: 1 !important;
        grid-row: 1 !important;
    }

    #pluginHDHivePage .plugin-hdhive-auth-card:first-child .plugin-hdhive-auth-card-label,
    #pluginHDHivePage .plugin-hdhive-auth-status {
        grid-column: 1 !important;
        text-align: center !important;
        justify-self: center !important;
    }

    #pluginHDHivePage .plugin-hdhive-auth-status {
        font-size: 24px !important;
        line-height: 1.15 !important;
        white-space: nowrap !important;
    }

    #pluginHDHivePage .plugin-hdhive-auth-card:first-child::after {
        display: none !important;
        content: "" !important;
    }

    #pluginHDHivePage .plugin-hdhive-oauth-hero-art {
        display: none !important;
    }

    #pluginHDHivePage .plugin-hdhive-hero-user {
        position: static !important;
        transform: none !important;
        width: 100% !important;
        margin: 0 !important;
        padding-left: 14px !important;
        border-left: 1px solid rgba(168, 196, 240, .18) !important;
        grid-column: 2 !important;
        grid-row: 1 / span 3 !important;
    }

    #pluginHDHivePage .plugin-hdhive-hero-user-row {
        grid-template-columns: 24px minmax(0, 1fr) !important;
        gap: 8px !important;
    }

    #pluginHDHivePage .plugin-hdhive-hero-user-value {
        font-size: 17px !important;
        word-break: break-all !important;
    }

    #pluginHDHivePage .plugin-hdhive-hero-user-divider {
        margin: 12px 0 !important;
    }

    #pluginHDHivePage .plugin-hdhive-oauth-actions {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 10px !important;
        padding: 12px !important;
    }

    #pluginHDHivePage .plugin-action-btn {
        width: 100% !important;
        min-width: 0 !important;
        min-height: 48px !important;
        padding: 0 16px !important;
        flex: none !important;
        border-radius: 14px !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 10px !important;
    }

    #pluginHDHivePage #HDHIVE_OAUTH_AUTHORIZE_BTN::before,
    #pluginHDHivePage #HDHIVE_OAUTH_FORCE_REFRESH_BTN::before,
    #pluginHDHivePage #HDHIVE_OAUTH_LOGOUT_BTN::before {
        width: 24px !important;
        height: 24px !important;
        flex: 0 0 24px !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        font-size: 20px !important;
        line-height: 1 !important;
        margin: 0 !important;
    }

    #pluginHDHivePage #HDHIVE_OAUTH_AUTHORIZE_BTN,
    #pluginHDHivePage #HDHIVE_OAUTH_FORCE_REFRESH_BTN,
    #pluginHDHivePage #HDHIVE_OAUTH_LOGOUT_BTN {
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        text-align: center !important;
    }

    #pluginHDHivePage #HDHIVE_OAUTH_AUTHORIZE_BTN::before,
    #pluginHDHivePage #HDHIVE_OAUTH_FORCE_REFRESH_BTN::before,
    #pluginHDHivePage #HDHIVE_OAUTH_LOGOUT_BTN::before {
        margin-right: 8px !important;
        margin-left: 0 !important;
        vertical-align: middle !important;
    }

    #pluginHDHivePage #HDHIVE_OAUTH_AUTHORIZE_BTN::after,
    #pluginHDHivePage #HDHIVE_OAUTH_FORCE_REFRESH_BTN::after,
    #pluginHDHivePage #HDHIVE_OAUTH_LOGOUT_BTN::after {
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
    }

    #pluginHDHivePage #HDHIVE_OAUTH_AUTHORIZE_BTN::after,
    #pluginHDHivePage #HDHIVE_OAUTH_FORCE_REFRESH_BTN::after,
    #pluginHDHivePage #HDHIVE_OAUTH_LOGOUT_BTN::after {
        font-size: 15px !important;
        line-height: 1 !important;
        white-space: nowrap !important;
    }
}

/* ===================== HDHive OAuth 最小修正：隐藏授权状态前的红圈叹号 ===================== */
#pluginHDHivePage #HDHIVE_OAUTH_AUTH_STATUS::before,
#pluginHDHivePage #HDHIVE_OAUTH_AUTH_STATUS.is-danger::before,
#pluginHDHivePage #HDHIVE_OAUTH_AUTH_STATUS.is-unauthorized::before,
#pluginHDHivePage #HDHIVE_OAUTH_AUTH_STATUS.is-expired::before,
#pluginHDHivePage #HDHIVE_OAUTH_AUTH_STATUS.is-warning::before {
    content: none !important;
    display: none !important;
}

/* ===================== HDHive OAuth 手机端按钮对齐最终修正 ===================== */
/* 目标：手机端每行保持 [图标列] + [文字列]，三行图标左边严格对齐 */
@media (max-width: 700px) {
    #pluginHDHivePage .plugin-hdhive-oauth-actions {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 10px !important;
        padding: 12px !important;
    }

    #pluginHDHivePage #HDHIVE_OAUTH_AUTHORIZE_BTN,
    #pluginHDHivePage #HDHIVE_OAUTH_FORCE_REFRESH_BTN,
    #pluginHDHivePage #HDHIVE_OAUTH_LOGOUT_BTN {
        width: 100% !important;
        min-width: 0 !important;
        min-height: 48px !important;
        padding: 0 16px !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 8px !important;
        text-align: left !important;
        overflow: hidden !important;
    }

    #pluginHDHivePage #HDHIVE_OAUTH_AUTHORIZE_BTN::before,
    #pluginHDHivePage #HDHIVE_OAUTH_FORCE_REFRESH_BTN::before,
    #pluginHDHivePage #HDHIVE_OAUTH_LOGOUT_BTN::before {
        width: 32px !important;
        height: 32px !important;
        flex: 0 0 32px !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        margin: 0 !important;
        padding: 0 !important;
        line-height: 1 !important;
        font-size: 20px !important;
        text-align: center !important;
        transform: none !important;
    }

    #pluginHDHivePage #HDHIVE_OAUTH_FORCE_REFRESH_BTN::before {
        font-size: 22px !important;
    }

    #pluginHDHivePage #HDHIVE_OAUTH_LOGOUT_BTN::before {
        background-position: center !important;
        background-size: 24px 24px !important;
    }

    #pluginHDHivePage #HDHIVE_OAUTH_AUTHORIZE_BTN::after,
    #pluginHDHivePage #HDHIVE_OAUTH_FORCE_REFRESH_BTN::after,
    #pluginHDHivePage #HDHIVE_OAUTH_LOGOUT_BTN::after {
        width: 104px !important;
        flex: 0 0 104px !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: flex-start !important;
        margin: 0 !important;
        padding: 0 !important;
        font-size: 15px !important;
        line-height: 1 !important;
        white-space: nowrap !important;
        text-align: left !important;
    }
}

/* ===================== HDHive 设置输入框图标：MDI 风格 star-outline / speedometer ===================== */
#pluginHDHivePage .hdhive-setting-icon-field {
    position: relative !important;
}

#pluginHDHivePage .hdhive-setting-icon-field .plugin-float-input {
    padding-left: 62px !important;
}

#pluginHDHivePage .hdhive-setting-icon-field .plugin-float-label {
    left: 62px !important;
}

#pluginHDHivePage .hdhive-setting-icon-field:focus-within .plugin-float-label,
#pluginHDHivePage .hdhive-setting-icon-field.has-value .plugin-float-label,
#pluginHDHivePage .hdhive-setting-icon-field .plugin-float-input:not(:placeholder-shown)+.plugin-float-label {
    left: 18px !important;
}

#pluginHDHivePage .hdhive-setting-icon-field::before {
    content: "";
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    width: 28px;
    height: 28px;
    z-index: 3;
    pointer-events: none;
    opacity: .96;
    background: #8de3ff;
    filter:
        drop-shadow(0 1px 3px rgba(0, 0, 0, .30)) drop-shadow(0 0 8px rgba(90, 204, 255, .38));
}

/* 解锁积分上限：采用 mdi-star-outline 线稿风格 */
#pluginHDHivePage .hdhive-unlock-limit-field::before {
    background: #7fd3ff;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M12 15.4 8.24 17.67 9.24 13.39 5.92 10.5 10.3 10.13 12 6.1 13.71 10.13 18.09 10.5 14.77 13.39 15.77 17.67 12 15.4M12 17.27 18.18 21 16.54 13.97 22 9.24 14.81 8.63 12 2 9.19 8.63 2 9.24 7.45 13.97 5.82 21 12 17.27Z'/%3E%3C/svg%3E") center / contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M12 15.4 8.24 17.67 9.24 13.39 5.92 10.5 10.3 10.13 12 6.1 13.71 10.13 18.09 10.5 14.77 13.39 15.77 17.67 12 15.4M12 17.27 18.18 21 16.54 13.97 22 9.24 14.81 8.63 12 2 9.19 8.63 2 9.24 7.45 13.97 5.82 21 12 17.27Z'/%3E%3C/svg%3E") center / contain no-repeat;
    filter:
        drop-shadow(0 1px 3px rgba(0, 0, 0, .28)) drop-shadow(0 0 8px rgba(127, 211, 255, .42));
}

/* 解锁速率限制：采用 mdi-speedometer 风格 */
#pluginHDHivePage .hdhive-rate-limit-field::before {
    background: #38d6ff;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M12 16A3 3 0 0 1 9 13C9 11.88 9.61 10.9 10.5 10.39L20.21 4.77 14.68 14.35C14.16 15.33 13.14 16 12 16M12 3C13.81 3 15.5 3.5 16.97 4.32L15.87 6.22C14.73 5.44 13.39 5 12 5A9 9 0 0 0 3 14C3 16.32 3.88 18.45 5.32 20H18.68C20.12 18.45 21 16.32 21 14C21 12.4 20.59 10.89 19.86 9.57L21.76 8.47C22.54 10.1 23 12 23 14A11 11 0 0 1 20 21H4A11 11 0 0 1 1 14A11 11 0 0 1 12 3Z'/%3E%3C/svg%3E") center / contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M12 16A3 3 0 0 1 9 13C9 11.88 9.61 10.9 10.5 10.39L20.21 4.77 14.68 14.35C14.16 15.33 13.14 16 12 16M12 3C13.81 3 15.5 3.5 16.97 4.32L15.87 6.22C14.73 5.44 13.39 5 12 5A9 9 0 0 0 3 14C3 16.32 3.88 18.45 5.32 20H18.68C20.12 18.45 21 16.32 21 14C21 12.4 20.59 10.89 19.86 9.57L21.76 8.47C22.54 10.1 23 12 23 14A11 11 0 0 1 20 21H4A11 11 0 0 1 1 14A11 11 0 0 1 12 3Z'/%3E%3C/svg%3E") center / contain no-repeat;
    filter:
        drop-shadow(0 1px 3px rgba(0, 0, 0, .28)) drop-shadow(0 0 8px rgba(56, 214, 255, .45));
}

@media (max-width: 700px) {
    #pluginHDHivePage .hdhive-setting-icon-field .plugin-float-input {
        padding-left: 58px !important;
    }

    #pluginHDHivePage .hdhive-setting-icon-field .plugin-float-label {
        left: 58px !important;
    }

    #pluginHDHivePage .hdhive-setting-icon-field:focus-within .plugin-float-label,
    #pluginHDHivePage .hdhive-setting-icon-field.has-value .plugin-float-label,
    #pluginHDHivePage .hdhive-setting-icon-field .plugin-float-input:not(:placeholder-shown)+.plugin-float-label {
        left: 18px !important;
    }

    #pluginHDHivePage .hdhive-setting-icon-field::before {
        left: 16px;
        width: 26px;
        height: 26px;
    }
}

/* Hero 右侧插画右移 + 用户名区域加宽，避免长 ID/用户名遮挡 */
#pluginHDHivePage .plugin-hdhive-hero-user {
    left: 50% !important;
    width: 260px !important;
}

#pluginHDHivePage .plugin-hdhive-hero-user-value {
    font-size: 20px !important;
    word-break: break-all !important;
}

#pluginHDHivePage .plugin-hdhive-oauth-hero-art {
    right: -8px !important;
    width: 225px !important;
}

@media (max-width: 980px) {
    #pluginHDHivePage .plugin-hdhive-hero-user {
        width: auto !important;
    }

    #pluginHDHivePage .plugin-hdhive-oauth-hero-art {
        right: 6px !important;
        width: 185px !important;
    }
}

@media (max-width: 700px) {
    #pluginHDHivePage .hdhive-setting-icon-field .plugin-float-input {
        padding-left: 62px !important;
    }

    #pluginHDHivePage .hdhive-setting-icon-field .plugin-float-label {
        left: 62px !important;
    }

    #pluginHDHivePage .hdhive-setting-icon-field::before {
        left: 12px;
        width: 36px;
        height: 36px;
        border-radius: 13px;
    }

    #pluginHDHivePage .hdhive-setting-icon-field::after {
        left: 20px;
        width: 20px;
        height: 20px;
    }
}
/* ===================== HDHive 多账号授权中心 v1 ===================== */
#pluginHDHivePage .plugin-hdhive-account-center {
    min-height: 100%;
}

#pluginHDHivePage .plugin-hdhive-primary-account-wrap,
#pluginHDHivePage .plugin-hdhive-account-list-wrap {
    position: relative;
    padding: 14px;
    border-radius: 18px;
    border: 1px solid rgba(95, 137, 206, .22);
    background:
        radial-gradient(circle at 0% 0%, rgba(64, 147, 255, .10) 0%, transparent 34%),
        rgba(7, 15, 28, .34);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .035);
}

#pluginHDHivePage .plugin-hdhive-primary-account-wrap::before,
#pluginHDHivePage .plugin-hdhive-account-list-wrap::before {
    content: "";
    position: absolute;
    left: 16px;
    right: 16px;
    top: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(95, 186, 255, .42), transparent);
    opacity: .75;
    pointer-events: none;
}

#pluginHDHivePage .plugin-hdhive-account-section-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

#pluginHDHivePage .plugin-hdhive-account-section-title {
    font-size: 16px;
    line-height: 1.25;
    font-weight: 950;
    color: #f3f8ff;
}

#pluginHDHivePage .plugin-hdhive-account-section-sub {
    margin-top: 4px;
    font-size: 12px;
    line-height: 1.55;
    color: #8fa7cc;
}

#pluginHDHivePage .plugin-hdhive-primary-pill,
#pluginHDHivePage .plugin-hdhive-account-count {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 28px;
    padding: 0 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 950;
    white-space: nowrap;
}

#pluginHDHivePage .plugin-hdhive-primary-pill {
    color: #10231d;
    background: linear-gradient(90deg, #90ffe6 0%, #46dfff 100%);
    border: 1px solid rgba(148, 255, 235, .38);
    box-shadow: 0 8px 18px rgba(38, 210, 218, .16);
}

#pluginHDHivePage .plugin-hdhive-account-count {
    color: #d9e9ff;
    background: rgba(48, 74, 118, .62);
    border: 1px solid rgba(140, 175, 235, .20);
}

#pluginHDHivePage .plugin-hdhive-primary-cards {
    grid-template-columns: minmax(0, 1.25fr) minmax(0, .85fr);
}

#pluginHDHivePage .plugin-hdhive-primary-cards .plugin-hdhive-notify-card {
    min-height: 104px;
}

#pluginHDHivePage .plugin-hdhive-main-account-card {
    min-height: 180px;
    grid-row: span 2;
}

#pluginHDHivePage .plugin-hdhive-account-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

#pluginHDHivePage .plugin-hdhive-account-empty {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 78px;
    padding: 14px;
    border-radius: 16px;
    border: 1px dashed rgba(128, 165, 226, .28);
    background: rgba(8, 18, 35, .42);
}

#pluginHDHivePage .plugin-hdhive-account-empty-icon {
    flex: 0 0 38px;
    width: 38px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    color: #ecf7ff;
    font-size: 26px;
    font-weight: 800;
    background: linear-gradient(180deg, rgba(68, 132, 255, .90) 0%, rgba(49, 91, 206, .92) 100%);
    box-shadow: 0 8px 16px rgba(38, 87, 196, .20);
}


#pluginHDHivePage .plugin-hdhive-account-empty.is-clickable {
    cursor: pointer;
    transition: transform .18s ease, border-color .18s ease, background .18s ease, box-shadow .18s ease;
}

#pluginHDHivePage .plugin-hdhive-account-empty.is-clickable:hover {
    transform: translateY(-2px);
    border-color: rgba(86, 160, 255, .58);
    background:
        radial-gradient(circle at 12% 0%, rgba(64, 141, 255, .16) 0%, transparent 38%),
        rgba(9, 21, 42, .62);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .05),
        0 12px 24px rgba(2, 7, 20, .22),
        0 0 0 1px rgba(77, 143, 255, .08);
}

#pluginHDHivePage .plugin-hdhive-account-empty.is-clickable:hover .plugin-hdhive-account-empty-icon {
    transform: scale(1.05);
    box-shadow:
        0 10px 20px rgba(38, 87, 196, .28),
        0 0 18px rgba(91, 181, 255, .18);
}

#pluginHDHivePage .plugin-hdhive-account-empty.is-clickable:active {
    transform: translateY(0);
}

#pluginHDHivePage .plugin-hdhive-account-empty-icon {
    transition: transform .18s ease, box-shadow .18s ease;
}

#pluginHDHivePage .plugin-hdhive-account-empty-title {
    font-size: 14px;
    line-height: 1.35;
    font-weight: 950;
    color: #edf5ff;
}

#pluginHDHivePage .plugin-hdhive-account-empty-sub {
    margin-top: 3px;
    font-size: 12px;
    line-height: 1.55;
    color: #8fa7cc;
}

#pluginHDHivePage .plugin-hdhive-account-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    padding: 12px 12px;
    border-radius: 16px;
    border: 1px solid rgba(106, 143, 205, .22);
    background: rgba(8, 18, 35, .48);
}

#pluginHDHivePage .plugin-hdhive-account-item-main {
    min-width: 0;
}

#pluginHDHivePage .plugin-hdhive-account-item-name {
    color: #f4f8ff;
    font-size: 14px;
    font-weight: 950;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

#pluginHDHivePage .plugin-hdhive-account-item-meta {
    margin-top: 4px;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    color: #8fa7cc;
    font-size: 12px;
    line-height: 1.4;
}

#pluginHDHivePage .plugin-hdhive-account-item-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    flex-wrap: wrap;
}

#pluginHDHivePage .plugin-hdhive-account-mini-btn {
    min-height: 32px;
    padding: 0 10px;
    border-radius: 999px;
    border: 1px solid rgba(132, 170, 235, .22);
    background: rgba(45, 73, 125, .66);
    color: #eaf3ff;
    font-size: 12px;
    font-weight: 900;
    cursor: pointer;
}

#pluginHDHivePage .plugin-hdhive-account-mini-btn:hover {
    filter: brightness(1.06);
}

#pluginHDHivePage .plugin-hdhive-account-actions {
    justify-content: space-between;
}

#pluginHDHivePage .plugin-hdhive-account-actions .plugin-action-btn {
    flex: 0 1 auto;
}

@media (max-width: 1200px) {
    #pluginHDHivePage .plugin-hdhive-primary-cards {
        grid-template-columns: 1fr;
    }

    #pluginHDHivePage .plugin-hdhive-main-account-card {
        grid-row: auto;
    }
}

@media (max-width: 700px) {
    #pluginHDHivePage .plugin-hdhive-primary-account-wrap,
    #pluginHDHivePage .plugin-hdhive-account-list-wrap {
        padding: 12px;
        border-radius: 16px;
    }

    #pluginHDHivePage .plugin-hdhive-account-section-head {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    #pluginHDHivePage .plugin-hdhive-primary-pill,
    #pluginHDHivePage .plugin-hdhive-account-count {
        min-height: 26px;
    }

    #pluginHDHivePage .plugin-hdhive-main-account-card {
        min-height: 170px;
    }

    #pluginHDHivePage .plugin-hdhive-account-empty {
        align-items: flex-start;
        padding: 12px;
    }

    #pluginHDHivePage .plugin-hdhive-account-item {
        grid-template-columns: 1fr;
        align-items: stretch;
    }

    #pluginHDHivePage .plugin-hdhive-account-item-actions {
        justify-content: flex-start;
    }

    #pluginHDHivePage .plugin-hdhive-account-actions {
        justify-content: flex-start;
    }

    #pluginHDHivePage .plugin-hdhive-account-actions .plugin-action-btn,
    #pluginHDHivePage .plugin-hdhive-account-actions button {
        width: 100%;
    }
}


/* ===================== HDHive 多账号 UI 2.0：提醒左移 + 副账号卡片 + 弹窗 ===================== */
#pluginHDHivePage .plugin-hdhive-notify-settings-left {
    margin-top: 16px;
    margin-bottom: 2px;
}

#pluginHDHivePage .plugin-hdhive-notify-switch-row {
    padding: 10px 12px;
    border-radius: 14px;
    background: rgba(7, 15, 28, .38);
    border: 1px solid rgba(95, 137, 206, .18);
}

#pluginHDHivePage .plugin-hdhive-notify-hint-left {
    margin-top: 8px;
    margin-left: 2px;
}

#pluginHDHivePage .plugin-hdhive-primary-cards {
    grid-template-columns: minmax(0, 1.25fr) minmax(0, .85fr);
}

#pluginHDHivePage .plugin-hdhive-account-empty-note {
    padding: 4px 2px 0;
    color: #8fa7cc;
    font-size: 12px;
    font-weight: 800;
}

#pluginHDHivePage .plugin-hdhive-account-empty {
    cursor: pointer;
}

#pluginHDHivePage .plugin-hdhive-account-empty-title {
    font-size: 15px;
}

#pluginHDHivePage .plugin-hdhive-account-item {
    grid-template-columns: minmax(0, 1fr);
    align-items: stretch;
    gap: 12px;
    padding: 14px;
    border-color: rgba(106, 157, 235, .26);
    background:
        radial-gradient(circle at 0% 0%, rgba(65, 142, 255, .10) 0%, transparent 40%),
        rgba(8, 18, 35, .52);
}

#pluginHDHivePage .plugin-hdhive-account-item-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    min-width: 0;
}

#pluginHDHivePage .plugin-hdhive-account-mode-pill {
    flex: 0 0 auto;
    min-height: 26px;
    padding: 0 10px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 950;
    white-space: nowrap;
    border: 1px solid rgba(160, 190, 240, .18);
}

#pluginHDHivePage .plugin-hdhive-account-mode-pill.is-normal {
    color: #dff8ff;
    background: rgba(56, 125, 235, .34);
    border-color: rgba(110, 170, 255, .26);
}

#pluginHDHivePage .plugin-hdhive-account-mode-pill.is-gambler {
    color: #fff2d6;
    background: rgba(215, 143, 42, .28);
    border-color: rgba(255, 197, 97, .28);
}

#pluginHDHivePage .plugin-hdhive-account-mode-pill.is-off {
    color: #b9c7dd;
    background: rgba(72, 84, 110, .28);
    border-color: rgba(160, 180, 220, .14);
}

#pluginHDHivePage .plugin-hdhive-account-item-actions {
    justify-content: flex-start;
    padding-top: 2px;
}

#pluginHDHivePage .plugin-hdhive-account-switch {
    position: relative;
    display: inline-flex;
    align-items: center;
    width: 52px;
    height: 30px;
    cursor: pointer;
    user-select: none;
    flex: 0 0 auto;
}

#pluginHDHivePage .plugin-hdhive-account-switch input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

#pluginHDHivePage .plugin-hdhive-account-switch span {
    position: absolute;
    inset: 0;
    border-radius: 999px;
    background: linear-gradient(180deg, rgba(74, 84, 108, .98) 0%, rgba(45, 55, 78, .98) 100%);
    border: 1px solid rgba(178, 197, 230, .16);
    box-shadow: inset 0 2px 7px rgba(0, 0, 0, .26);
    transition: background .18s ease, border-color .18s ease, box-shadow .18s ease;
}

#pluginHDHivePage .plugin-hdhive-account-switch span::before {
    content: "";
    position: absolute;
    width: 22px;
    height: 22px;
    left: 4px;
    top: 3px;
    border-radius: 999px;
    background: linear-gradient(180deg, #f5f9ff 0%, #cbd8ee 100%);
    box-shadow: 0 5px 12px rgba(0, 0, 0, .30);
    transition: transform .18s ease, background .18s ease;
}

#pluginHDHivePage .plugin-hdhive-account-switch input:checked + span {
    background: linear-gradient(90deg, #18c99e 0%, #28d76f 100%);
    border-color: rgba(117, 255, 188, .34);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .18), 0 8px 18px rgba(28, 207, 126, .18);
}

#pluginHDHivePage .plugin-hdhive-account-switch input:checked + span::before {
    transform: translateX(22px);
    background: linear-gradient(180deg, #ffffff 0%, #ecfff6 100%);
}

#pluginHDHivePage .plugin-hdhive-signin-mode-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 18px 0 4px;
}

#pluginHDHivePage .plugin-hdhive-signin-mode-option {
    width: 100%;
    min-height: 48px;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 14px;
    border-radius: 14px;
    border: 1px solid rgba(120, 150, 220, .20);
    background: rgba(7, 15, 28, .42);
    color: #edf4ff;
    font-size: 14px;
    font-weight: 900;
    cursor: pointer;
    transition: border-color .18s ease, background .18s ease, transform .18s ease;
}

#pluginHDHivePage .plugin-hdhive-signin-mode-option:hover {
    transform: translateY(-1px);
    border-color: rgba(110, 170, 255, .42);
    background: rgba(10, 24, 48, .58);
}

#pluginHDHivePage .plugin-hdhive-signin-mode-option.active {
    border-color: rgba(116, 221, 255, .52);
    background: linear-gradient(90deg, rgba(35, 116, 220, .42) 0%, rgba(20, 186, 162, .22) 100%);
}

#pluginHDHivePage .plugin-hdhive-signin-radio {
    width: 18px;
    height: 18px;
    border-radius: 999px;
    border: 2px solid rgba(180, 205, 245, .52);
    box-shadow: inset 0 0 0 4px rgba(7, 15, 28, .72);
}

#pluginHDHivePage .plugin-hdhive-signin-mode-option.active .plugin-hdhive-signin-radio {
    border-color: #8fffe5;
    background: #8fffe5;
}

#pluginHDHivePage .plugin-hdhive-account-modal-card .modal-sub b {
    color: #f6fbff;
}

@media (max-width: 700px) {
    #pluginHDHivePage .plugin-hdhive-account-item-top {
        align-items: flex-start;
        flex-direction: column;
    }

    #pluginHDHivePage .plugin-hdhive-account-item-actions {
        gap: 8px;
    }
}


/* ===================== HDHive 多账号选择器 / 单账号详情 ===================== */

.plugin-hdhive-account-picker {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 14px;
    border-radius: 18px;
    border: 1px solid rgba(95, 137, 206, .22);
    background: rgba(7, 15, 28, .34);
    margin-bottom: 12px;
}

.plugin-hdhive-account-picker-title {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.plugin-hdhive-account-picker-title span {
    color: #eef6ff;
    font-size: 15px;
    font-weight: 900;
}

.plugin-hdhive-account-picker-title small {
    color: #8ea5c9;
    font-size: 12px;
    line-height: 1.5;
    text-align: right;
}

.plugin-hdhive-account-select-wrap {
    max-width: none;
}

.plugin-hdhive-account-select-wrap select {
    height: 52px;
    line-height: 52px;
    font-size: 15px;
    font-weight: 800;
}

.plugin-hdhive-account-detail-card {
    padding: 15px;
    border-radius: 18px;
    border: 1px solid rgba(108, 139, 198, .24);
    background:
        radial-gradient(circle at 100% 0%, rgba(66, 144, 255, .12) 0%, transparent 34%),
        linear-gradient(180deg, rgba(11, 23, 43, .70) 0%, rgba(8, 17, 33, .78) 100%);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .035),
        0 10px 22px rgba(2, 7, 20, .16);
    margin-bottom: 12px;
}

.plugin-hdhive-account-detail-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

.plugin-hdhive-account-detail-name {
    color: #f4f8ff;
    font-size: 18px;
    line-height: 1.2;
    font-weight: 950;
}

.plugin-hdhive-account-detail-sub {
    margin-top: 5px;
    color: #8fa7cc;
    font-size: 12px;
    line-height: 1.45;
    word-break: break-all;
}

.plugin-hdhive-account-detail-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin: 12px 0 14px;
}

.plugin-hdhive-account-detail-grid > div {
    min-width: 0;
    padding: 10px 12px;
    border-radius: 14px;
    border: 1px solid rgba(95, 137, 206, .18);
    background: rgba(7, 15, 28, .36);
}

.plugin-hdhive-account-detail-grid span {
    display: block;
    color: #8fa7cc;
    font-size: 11px;
    font-weight: 900;
    letter-spacing: .08em;
    text-transform: uppercase;
    margin-bottom: 6px;
}

.plugin-hdhive-account-detail-grid b {
    display: block;
    color: #eaf3ff;
    font-size: 13px;
    font-weight: 900;
    word-break: break-word;
}

.plugin-hdhive-account-detail-actions {
    justify-content: flex-start;
}

.plugin-hdhive-account-mini-btn.is-current,
.plugin-hdhive-account-mini-btn:disabled {
    opacity: .65;
    cursor: default;
    background: rgba(70, 94, 135, .35);
    color: #9eb2d3;
}

.plugin-hdhive-signin-time-field {
    margin-top: 14px;
    padding: 12px 14px;
    border-radius: 16px;
    border: 1px solid rgba(95, 137, 206, .20);
    background: rgba(7, 15, 28, .34);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.plugin-hdhive-signin-time-field label {
    color: #edf4ff;
    font-size: 14px;
    font-weight: 900;
    white-space: nowrap;
}

.plugin-hdhive-signin-time-field input {
    width: 128px;
    height: 40px;
    padding: 0 12px;
    border-radius: 12px;
    border: 1px solid rgba(120, 150, 220, .25);
    background: rgba(7, 15, 28, .58);
    color: #f4f8ff;
    font-size: 15px;
    font-weight: 900;
    outline: none;
}

.plugin-hdhive-signin-time-field input:focus {
    border-color: rgba(96, 150, 255, .85);
    box-shadow: 0 0 0 3px rgba(79, 131, 255, .10);
}

@media (max-width: 700px) {
    .plugin-hdhive-account-picker-title {
        flex-direction: column;
    }

    .plugin-hdhive-account-picker-title small {
        text-align: left;
    }

    .plugin-hdhive-account-detail-head,
    .plugin-hdhive-signin-time-field {
        flex-direction: column;
        align-items: stretch;
    }

    .plugin-hdhive-account-detail-grid {
        grid-template-columns: 1fr;
    }

    .plugin-hdhive-signin-time-field input {
        width: 100%;
    }
}


/* ===================== HDHive OAuth UI 3.0 精简布局 ===================== */
.plugin-hdhive-signin-settings {
    display: none !important;
}

.plugin-hdhive-notify-settings-left {
    margin-top: 18px;
}

.plugin-hdhive-settings-grid {
    flex: 0 0 auto;
}

.plugin-hdhive-oauth-left {
    justify-content: flex-start;
}

.plugin-hdhive-oauth-actions.plugin-hdhive-account-actions {
    display: none !important;
}

.plugin-hdhive-account-empty.is-clickable,
.plugin-hdhive-native-auth-link {
    text-decoration: none;
}

.plugin-hdhive-account-empty.is-clickable {
    cursor: pointer;
}

.plugin-hdhive-account-empty.is-clickable:hover {
    transform: translateY(-2px);
    border-color: rgba(99, 169, 255, .48);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .06),
        0 14px 28px rgba(5, 12, 30, .26),
        0 0 0 1px rgba(68, 144, 255, .10);
}

.plugin-hdhive-account-empty.is-clickable:active {
    transform: translateY(0);
}

.plugin-hdhive-account-detail-control-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 14px;
}

.plugin-hdhive-account-signin-switch-line {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    min-height: 36px;
    padding: 0 12px;
    border-radius: 999px;
    border: 1px solid rgba(112, 151, 210, .24);
    background: rgba(7, 15, 28, .36);
    color: #dceaff;
    font-size: 12px;
    font-weight: 900;
}


.plugin-hdhive-account-signin-next-line {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
    padding: 10px 12px;
    border-radius: 14px;
    border: 1px solid rgba(112, 151, 210, .18);
    background: rgba(9, 18, 34, .34);
    color: rgba(220, 234, 255, .86);
    font-size: 12px;
    font-weight: 800;
}

.plugin-hdhive-account-signin-next-line b {
    color: #ffffff;
    font-size: 13px;
    font-weight: 900;
}

.plugin-hdhive-signin-schedule-title {
    margin: 14px 0 8px;
    color: rgba(224, 238, 255, .86);
    font-size: 12px;
    font-weight: 900;
}

.plugin-hdhive-signin-time-field.hidden {
    display: none !important;
}

.plugin-hdhive-account-current-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 14px;
    padding-top: 13px;
    border-top: 1px solid rgba(112, 151, 210, .16);
}

.plugin-hdhive-current-action-btn {
    appearance: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 36px;
    padding: 0 14px;
    border-radius: 11px;
    border: 1px solid rgba(110, 156, 255, .24);
    background: linear-gradient(180deg, #4d85ff 0%, #3b67d8 100%);
    color: #fff;
    font-size: 13px;
    font-weight: 950;
    line-height: 1;
    cursor: pointer;
    text-decoration: none;
    box-shadow: 0 8px 14px rgba(43, 88, 191, .22);
    transition: transform .16s ease, filter .16s ease, box-shadow .16s ease, border-color .16s ease;
}

.plugin-hdhive-current-action-btn:hover {
    filter: brightness(1.05);
    transform: translateY(-1px);
    box-shadow: 0 10px 18px rgba(43, 88, 191, .28);
}

.plugin-hdhive-current-action-btn:active {
    transform: translateY(0);
}

.plugin-hdhive-current-action-btn.is-disabled {
    opacity: .62;
    cursor: not-allowed;
    filter: grayscale(.16);
}

.plugin-hdhive-current-action-danger {
    background: linear-gradient(180deg, #ff6b73 0%, #d94b57 100%);
    border-color: rgba(255, 128, 140, .30);
    box-shadow: 0 8px 14px rgba(191, 43, 66, .22);
}

.plugin-hdhive-current-action-refresh {
    background: linear-gradient(180deg, #47b4ff 0%, #3378e8 100%);
}

.plugin-hdhive-account-detail-actions .danger {
    display: none;
}

.plugin-hdhive-account-detail-card .plugin-hdhive-account-mini-btn {
    min-height: 36px;
    border-radius: 11px;
}

@media (max-width: 700px) {
    .plugin-hdhive-account-current-actions {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 8px;
    }

    .plugin-hdhive-current-action-btn {
        width: 100%;
        padding: 0 8px;
        font-size: 12px;
        min-height: 38px;
    }

    .plugin-hdhive-account-detail-control-row {
        gap: 8px;
    }

    .plugin-hdhive-account-signin-switch-line {
        width: 100%;
        justify-content: space-between;
    }
}


/* ===================== HDHive UI3：账号下拉驱动上方卡片 + Token 居中拉满 ===================== */
#pluginHDHivePage .plugin-hdhive-auth-card:nth-child(2),
#pluginHDHivePage .plugin-hdhive-auth-card:nth-child(3) {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

#pluginHDHivePage .plugin-hdhive-auth-card:nth-child(2) .plugin-hdhive-auth-card-label,
#pluginHDHivePage .plugin-hdhive-auth-card:nth-child(3) .plugin-hdhive-auth-card-label {
    width: 100%;
    text-align: center;
}

#pluginHDHivePage .plugin-hdhive-token-days {
    width: 100%;
    justify-content: center;
    align-items: baseline;
    text-align: center;
}

#pluginHDHivePage .plugin-hdhive-auth-card:nth-child(2) .plugin-hdhive-auth-card-sub,
#pluginHDHivePage .plugin-hdhive-auth-card:nth-child(3) .plugin-hdhive-auth-card-sub {
    width: 100%;
    text-align: center;
}

#pluginHDHivePage .plugin-hdhive-account-control-card {
    padding: 14px;
}

#pluginHDHivePage .plugin-hdhive-account-detail-grid {
    display: none !important;
}

#pluginHDHivePage .plugin-hdhive-account-detail-head {
    display: none !important;
}

#pluginHDHivePage .plugin-hdhive-account-detail-card.plugin-hdhive-account-control-card {
    margin-bottom: 0;
}

#pluginHDHivePage .plugin-hdhive-account-current-actions {
    margin-top: 12px;
}

@media (max-width: 980px) {
    #pluginHDHivePage .plugin-hdhive-oauth-layout {
        grid-template-columns: 1fr;
        max-width: none;
    }

    #pluginHDHivePage .plugin-hdhive-auth-cards {
        grid-template-columns: 1fr;
    }

    #pluginHDHivePage .plugin-hdhive-auth-card:nth-child(2),
    #pluginHDHivePage .plugin-hdhive-auth-card:nth-child(3) {
        align-items: stretch;
        text-align: left;
    }

    #pluginHDHivePage .plugin-hdhive-auth-card:nth-child(2) .plugin-hdhive-auth-card-label,
    #pluginHDHivePage .plugin-hdhive-auth-card:nth-child(3) .plugin-hdhive-auth-card-label,
    #pluginHDHivePage .plugin-hdhive-auth-card:nth-child(2) .plugin-hdhive-auth-card-sub,
    #pluginHDHivePage .plugin-hdhive-auth-card:nth-child(3) .plugin-hdhive-auth-card-sub {
        text-align: left;
    }

    #pluginHDHivePage .plugin-hdhive-token-days {
        justify-content: flex-start;
        text-align: left;
    }
}


/* ===================== HDHive UI3 Fix: 账号选择说明移除 + Token 两卡铺满 ===================== */
#pluginHDHivePage .plugin-hdhive-account-picker-title small {
    display: none !important;
}

#pluginHDHivePage .plugin-hdhive-auth-cards {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    width: 100% !important;
    max-width: none !important;
}

#pluginHDHivePage .plugin-hdhive-auth-card {
    width: 100% !important;
    min-width: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
}

#pluginHDHivePage .plugin-hdhive-token-days {
    width: 100% !important;
    justify-content: center !important;
    align-items: baseline !important;
    text-align: center !important;
}

#pluginHDHivePage .plugin-hdhive-auth-card-sub {
    width: 100% !important;
    text-align: center !important;
}

@media (max-width: 700px) {
    #pluginHDHivePage .plugin-hdhive-auth-cards {
        grid-template-columns: 1fr !important;
    }
}


/* ===================== HDHive UI3 Fix: 当前账号操作按钮三等分铺满 ===================== */
#pluginHDHivePage .plugin-hdhive-account-current-actions {
    width: 100% !important;
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 12px !important;
    align-items: stretch !important;
    justify-content: stretch !important;
    margin-top: 14px !important;
}

#pluginHDHivePage .plugin-hdhive-current-action-btn {
    width: 100% !important;
    min-width: 0 !important;
    height: 44px !important;
    min-height: 44px !important;
    padding: 0 12px !important;
    border-radius: 11px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    white-space: nowrap !important;
    box-sizing: border-box !important;
}

@media (max-width: 700px) {
    #pluginHDHivePage .plugin-hdhive-account-current-actions {
        grid-template-columns: 1fr !important;
        gap: 10px !important;
    }

    #pluginHDHivePage .plugin-hdhive-current-action-btn {
        height: 42px !important;
        min-height: 42px !important;
    }
}


/* ===================== HDHive UI3 Fix: 操作按钮颜色恢复 + 下拉添加账号 ===================== */
#pluginHDHivePage .plugin-hdhive-current-action-btn {
    color: #fff !important;
    border: 1px solid rgba(127, 174, 255, .28) !important;
    box-shadow: 0 8px 16px rgba(43, 88, 191, .18) !important;
}

#pluginHDHivePage .plugin-hdhive-current-action-auth {
    background: linear-gradient(180deg, #8c5cff 0%, #6544dc 100%) !important;
    border-color: rgba(181, 153, 255, .34) !important;
    box-shadow: 0 8px 16px rgba(112, 74, 220, .24) !important;
}

#pluginHDHivePage .plugin-hdhive-current-action-refresh {
    background: linear-gradient(180deg, #4d85ff 0%, #3b67d8 100%) !important;
}

#pluginHDHivePage .plugin-hdhive-current-action-danger {
    background: linear-gradient(180deg, #ff5f73 0%, #d83f55 100%) !important;
    border-color: rgba(255, 145, 160, .34) !important;
    box-shadow: 0 8px 16px rgba(216, 63, 85, .20) !important;
}

#pluginHDHivePage .plugin-hdhive-current-action-btn:hover {
    filter: brightness(1.06) !important;
    transform: translateY(-1px);
}

#pluginHDHivePage #HDHIVE_ACCOUNT_SELECT option[value="__add_account__"] {
    font-weight: 900;
}


/* ===================== HDHive UI3 Fix: 白色 SVG 图标 + 下拉切换刷新上方卡片 ===================== */
#pluginHDHivePage .plugin-hdhive-action-icon {
    width: 17px !important;
    height: 17px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    margin-right: 7px !important;
    flex: 0 0 auto !important;
}

#pluginHDHivePage .plugin-hdhive-action-icon svg {
    width: 17px !important;
    height: 17px !important;
    display: block !important;
}

#pluginHDHivePage .plugin-hdhive-action-icon svg path,
#pluginHDHivePage .plugin-hdhive-action-icon svg rect {
    fill: none !important;
    stroke: #ffffff !important;
    stroke-width: 2.2 !important;
    stroke-linecap: round !important;
    stroke-linejoin: round !important;
}

#pluginHDHivePage .plugin-hdhive-current-action-btn {
    color: #ffffff !important;
}

/* ===================== HDHive 签到时间控件恢复修正 ===================== */
/* 撤销白色覆盖图标方案，优先恢复点击区域和分钟完整显示 */
.plugin-hdhive-signin-time-field {
    position: relative !important;
}

.plugin-hdhive-signin-time-field::after {
    content: none !important;
    display: none !important;
    background-image: none !important;
    pointer-events: none !important;
}

.plugin-hdhive-signin-time-field input[type="time"],
.plugin-hdhive-signin-time-field input {
    padding-right: 16px !important;
    color-scheme: dark;
}

.plugin-hdhive-signin-time-field input[type="time"]::-webkit-calendar-picker-indicator,
.plugin-hdhive-signin-time-field input::-webkit-calendar-picker-indicator {
    opacity: 1 !important;
    cursor: pointer !important;
    pointer-events: auto !important;
}

