      body {
        display: none;
      }
      :root {
        --bg-body: #f6f8fc;
        --bg-card: #ffffff;
        --bg-input: #fbfcfe;
        --bg-hover: #f2f6ff;
        --bg-tip: #f7f9fd;
        --text-main: #1f2430;
        --text-sub: #7a8296;
        --text-light: #9aa2b4;
        --border-main: #dfe6f2;
        --border-card: #e8edf6;
        --border-dashed: #dbe3f0;
        --primary: #4f6cf7;
        --primary-light: #eef2fa;
        --primary-gradient: linear-gradient(135deg, #5b8cff, #4f6cf7);
        --success: #12734a;
        --success-bg: #eefbf3;
        --success-border: #c9efda;
        --danger: #b32020;
        --danger-bg: #fff1f1;
        --danger-border: #ffd6d6;
        --warn: #9a5b06;
        --warn-bg: #fff8ec;
        --warn-border: #ffe1b8;
        --shadow: 0 12px 34px rgba(31, 36, 48, 0.07);
      }
      @media (prefers-color-scheme: dark) {
        :root {
          --bg-body: #0f1115;
          --bg-card: #1a1e27;
          --bg-input: #141821;
          --bg-hover: #252b38;
          --bg-tip: #1e232e;
          --text-main: #e2e8f0;
          --text-sub: #8892a0;
          --text-light: #5c667a;
          --border-main: #2a3141;
          --border-card: #2a3141;
          --border-dashed: #333c4f;
          --primary: #6b8cff;
          --primary-light: #2a3141;
          --primary-gradient: linear-gradient(135deg, #5b8cff, #4f6cf7);
          --success: #34d399;
          --success-bg: #064e3b;
          --success-border: #065f46;
          --danger: #f87171;
          --danger-bg: #7f1d1d;
          --danger-border: #991b1b;
          --warn: #fbbf24;
          --warn-bg: #78350f;
          --warn-border: #92400e;
          --shadow: 0 12px 34px rgba(0, 0, 0, 0.4);
        }
      }
      body.theme-light {
        --bg-body: #f6f8fc;
        --bg-card: #ffffff;
        --bg-input: #fbfcfe;
        --bg-hover: #f2f6ff;
        --bg-tip: #f7f9fd;
        --text-main: #1f2430;
        --text-sub: #7a8296;
        --text-light: #9aa2b4;
        --border-main: #dfe6f2;
        --border-card: #e8edf6;
        --border-dashed: #dbe3f0;
        --primary: #4f6cf7;
        --primary-light: #eef2fa;
        --success: #12734a;
        --success-bg: #eefbf3;
        --success-border: #c9efda;
        --danger: #b32020;
        --danger-bg: #fff1f1;
        --danger-border: #ffd6d6;
        --warn: #9a5b06;
        --warn-bg: #fff8ec;
        --warn-border: #ffe1b8;
        --shadow: 0 12px 34px rgba(31, 36, 48, 0.07);
      }
      body.theme-dark {
        --bg-body: #0f1115;
        --bg-card: #1a1e27;
        --bg-input: #141821;
        --bg-hover: #252b38;
        --bg-tip: #1e232e;
        --text-main: #e2e8f0;
        --text-sub: #8892a0;
        --text-light: #5c667a;
        --border-main: #2a3141;
        --border-card: #2a3141;
        --border-dashed: #333c4f;
        --primary: #6b8cff;
        --primary-light: #2a3141;
        --success: #34d399;
        --success-bg: #064e3b;
        --success-border: #065f46;
        --danger: #f87171;
        --danger-bg: #7f1d1d;
        --danger-border: #991b1b;
        --warn: #fbbf24;
        --warn-bg: #78350f;
        --warn-border: #92400e;
        --shadow: 0 12px 34px rgba(0, 0, 0, 0.4);
      }
      * {
        box-sizing: border-box;
      }
      html {
        -webkit-text-size-adjust: 100%;
      }
      body {
        margin: 0;
        padding: 36px 16px 56px;
        min-height: 100vh;
        font-family:
          -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
          "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
        color: var(--text-main);
        background: var(--bg-body);
        display: flex;
        flex-direction: column;
        justify-content: flex-start;
        align-items: center;
        transition:
          background-color 0.3s,
          color 0.3s;
      }
      body.modal-open {
        overflow: hidden;
      }
      .wrap {
        width: 100%;
        max-width: 720px;
      }
      .head {
        margin-bottom: 18px;
        padding: 0 4px;
        text-align: center;
        position: relative;
      }
      .head h1 {
        font-size: 24px;
        margin: 0 0 8px;
        letter-spacing: 1px;
        color: var(--text-main);
      }
      .sub {
        margin: 0;
        font-size: 14.5px;
        color: var(--text-sub);
        line-height: 1.6;
        letter-spacing: 0.5px;
      }
      .sub code,
      .hint code,
      .tip code {
        background: var(--primary-light);
        padding: 1px 6px;
        border-radius: 6px;
        font-size: 12.5px;
        font-family: ui-monospace, Menlo, Consolas, monospace;
        word-break: break-all;
      }

      /* 顶部左右开关 */
      .head-switches-left {
        position: absolute;
        top: 0;
        left: 0;
        background: var(--bg-card);
        border: 1px solid var(--border-card);
        border-radius: 20px;
        padding: 4px;
        display: flex;
        gap: 2px;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
      }
      .head-btn {
        background: none;
        border: none;
        padding: 4px 8px;
        border-radius: 16px;
        font-size: 11px;
        color: var(--text-sub);
        cursor: pointer;
        transition: 0.2s;
      }
      .head-btn.active {
        background: var(--primary-light);
        color: var(--primary);
        font-weight: 600;
      }

      .theme-switch {
        position: absolute;
        top: 0;
        right: 0;
        background: var(--bg-card);
        border: 1px solid var(--border-card);
        border-radius: 20px;
        padding: 4px;
        display: flex;
        gap: 2px;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
      }
      .theme-btn {
        background: none;
        border: none;
        padding: 4px 8px;
        border-radius: 16px;
        font-size: 11px;
        color: var(--text-sub);
        cursor: pointer;
        transition: 0.2s;
      }
      .theme-btn.active {
        background: var(--primary-light);
        color: var(--primary);
        font-weight: 600;
      }

      .card {
        background: var(--bg-card);
        border: 1px solid var(--border-card);
        border-radius: 18px;
        padding: 22px;
        box-shadow: var(--shadow);
        transition:
          background-color 0.3s,
          border-color 0.3s;
      }
      .tabs {
        display: flex;
        background: var(--primary-light);
        border-radius: 10px;
        padding: 4px;
        margin-bottom: 20px;
      }
      .tab {
        flex: 1;
        text-align: center;
        padding: 10px 0;
        font-size: 14px;
        font-weight: 600;
        color: var(--text-sub);
        border-radius: 8px;
        cursor: pointer;
        transition: 0.2s;
        user-select: none;
      }
      .tab.active {
        background: var(--bg-card);
        color: var(--primary);
        box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
      }
      .label {
        display: block;
        font-size: 13px;
        font-weight: 600;
        color: var(--text-main);
        margin-bottom: 8px;
      }
      .field {
        display: flex;
        gap: 10px;
        align-items: stretch;
      }
      .input-wrap {
        flex: 1;
        position: relative;
        display: flex;
      }
      .input-wrap .input {
        width: 100%;
      }

      .input {
        flex: 1;
        min-width: 0;
        height: 56px;
        padding: 0 15px;
        font-size: 16px;
        font-family: inherit;
        color: var(--text-main);
        border: 1px solid var(--border-main);
        border-radius: 12px;
        background: var(--bg-input);
        outline: none;
        transition: 0.18s;
        user-select: text !important;
        -webkit-user-select: text !important;
      }

      .input.has-clear {
        padding-left: 40px;
      }
      .input::placeholder {
        color: var(--text-light);
        font-size: 14px;
      }
      .input:focus {
        border-color: var(--primary);
        background: var(--bg-card);
        box-shadow: 0 0 0 4px rgba(91, 140, 255, 0.14);
      }
      .clear-btn {
        position: absolute;
        left: 12px;
        top: 50%;
        transform: translateY(-50%);
        width: 22px;
        height: 22px;
        border-radius: 50%;
        border: none;
        background: var(--border-main);
        color: var(--text-sub);
        font-size: 15px;
        line-height: 1;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: 0.2s;
        z-index: 10;
        padding: 0;
      }
      .clear-btn:hover {
        background: var(--border-card);
        color: var(--text-main);
      }
      .clear-btn.hidden {
        display: none !important;
      }
      .dropdown {
        position: absolute;
        top: calc(100% + 4px);
        left: 0;
        right: 0;
        background: var(--bg-card);
        border: 1px solid var(--border-card);
        border-radius: 12px;
        box-shadow: 0 8px 24px rgba(31, 36, 48, 0.15);
        z-index: 100;
        max-height: 240px;
        overflow-y: auto;
        display: flex;
        flex-direction: column;
        animation: fadeInDown 0.2s ease-out forwards;
      }
      @keyframes fadeInDown {
        from {
          opacity: 0;
          transform: translateY(-10px);
        }
        to {
          opacity: 1;
          transform: translateY(0);
        }
      }
      .dropdown.hidden {
        display: none !important;
      }
      .dropdown-item {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 10px 14px;
        border-bottom: 1px solid var(--border-card);
        cursor: pointer;
        transition: background 0.15s;
      }
      .dropdown-item:last-child {
        border-bottom: none;
      }
      .dropdown-item:hover {
        background: var(--bg-hover);
      }
      .item-content {
        flex: 1;
        color: var(--text-main);
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
        display: flex;
        flex-direction: column;
        justify-content: center;
      }
      .item-main {
        display: flex;
        align-items: center;
        font-size: 13.5px;
        margin-bottom: 2px;
      }
      .item-name {
        font-weight: 600;
        margin-right: 6px;
        max-width: 60%;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
      }
      .item-token {
        font-size: 12px;
        color: var(--text-sub);
        font-family: ui-monospace, Menlo, Consolas, monospace;
      }
      .item-exp {
        font-size: 11px;
        color: var(--text-light);
      }
      .del-btn {
        background: none;
        border: none;
        padding: 4px 8px;
        color: var(--danger);
        font-size: 16px;
        cursor: pointer;
        font-weight: 600;
        line-height: 1;
      }
      .del-btn:hover {
        background: var(--danger-bg);
        border-radius: 4px;
      }
      .btn {
        height: 56px;
        padding: 0 22px;
        border: 0;
        border-radius: 12px;
        cursor: pointer;
        color: #fff;
        font-size: 15px;
        font-weight: 600;
        font-family: inherit;
        white-space: nowrap;
        background: var(--primary-gradient);
        box-shadow: 0 6px 16px rgba(79, 108, 247, 0.28);
        transition: 0.18s;
      }
      .btn:hover:not(:disabled) {
        transform: translateY(-1px);
        box-shadow: 0 9px 20px rgba(79, 108, 247, 0.34);
      }
      .btn:active:not(:disabled) {
        transform: translateY(0);
        box-shadow: 0 4px 12px rgba(79, 108, 247, 0.28);
      }
      .btn:disabled {
        opacity: 0.62;
        cursor: not-allowed;
        box-shadow: none;
        transform: none;
      }
      .btn.ghost {
        background: var(--bg-card);
        color: var(--primary);
        border: 1px solid var(--border-card);
        box-shadow: none;
      }
      .btn.ghost:hover:not(:disabled) {
        background: var(--bg-hover);
        border-color: var(--primary);
        box-shadow: none;
      }
      .btn.ghost:active:not(:disabled) {
        box-shadow: none;
      }
      .actions {
        display: flex;
        gap: 10px;
        margin-top: 12px;
        flex-wrap: wrap;
      }
      .actions .btn {
        height: auto;
        min-height: 48px;
        padding: 10px 18px;
        font-size: 14px;
        line-height: 1.45;
        white-space: normal;
        flex: 1 1 auto;
      }
      .hint {
        margin: 10px 0 0;
        font-size: 12.5px;
        color: var(--text-light);
        line-height: 1.65;
      }
      .tip {
        margin-top: 12px;
        padding: 14px 16px;
        border-radius: 12px;
        background: var(--bg-tip);
        border: 1px dashed var(--border-dashed);
        font-size: 13px;
        color: var(--text-sub);
        line-height: 1.8;
      }
      .tip b {
        color: var(--text-main);
      }
      .result-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-bottom: 16px;
      }
      .result-title {
        font-size: 15px;
        font-weight: 600;
        color: var(--text-main);
        display: flex;
        align-items: center;
        gap: 6px;
      }
      .btn-text {
        background: none;
        border: none;
        cursor: pointer;
        padding: 0;
        color: var(--primary);
        font-size: 13px;
        font-weight: 600;
        display: flex;
        align-items: center;
        gap: 4px;
      }
      .btn-text:hover {
        text-decoration: underline;
      }
      .status {
        margin-top: 18px;
        padding: 12px 14px;
        border-radius: 12px;
        font-size: 13.5px;
        line-height: 1.7;
        white-space: pre-wrap;
        word-break: break-word;
        border: 1px solid transparent;
      }
      .status.info {
        background: var(--primary-light);
        border-color: var(--primary-light);
        color: var(--primary);
      }
      .status.ok {
        background: var(--success-bg);
        border-color: var(--success-border);
        color: var(--success);
      }
      .status.err {
        background: var(--danger-bg);
        border-color: var(--danger-border);
        color: var(--danger);
      }
      .status.warn {
        background: var(--warn-bg);
        border-color: var(--warn-border);
        color: var(--warn);
      }
      .result {
        margin-top: 20px;
      }
      .user-card {
        display: flex;
        gap: 14px;
        align-items: center;
        background: var(--bg-tip);
        border: 1px solid var(--border-card);
        border-radius: 14px;
        padding: 14px;
      }
      .avatar {
        width: 52px;
        height: 52px;
        border-radius: 50%;
        object-fit: cover;
        background: var(--border-main);
        flex: none;
      }
      .user-meta {
        min-width: 0;
      }
      .user-name {
        font-size: 15.5px;
        font-weight: 600;
        margin-bottom: 4px;
        color: var(--text-main);
      }
      .user-line {
        font-size: 13px;
        color: var(--text-sub);
        line-height: 1.7;
        word-break: break-all;
      }
      .token-status-line {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-top: 8px;
        padding: 0 4px;
        font-size: 12.5px;
        color: var(--text-sub);
      }
      .countdown-num {
        font-weight: 600;
        color: var(--primary);
        font-family: ui-monospace, Menlo, Consolas, monospace;
      }
      .token-status-line.expired .countdown-num {
        color: var(--danger);
      }
      .token-details {
        margin-top: 12px;
        border-top: 1px dashed var(--border-dashed);
        padding-top: 12px;
      }
      .token-summary {
        cursor: pointer;
        font-size: 12px;
        color: var(--text-light);
        outline: none;
        user-select: none;
        list-style: none;
        display: inline-flex;
        align-items: center;
      }
      .token-summary::-webkit-details-marker {
        display: none;
      }
      .token-summary::before {
        content: "▶";
        font-size: 10px;
        margin-right: 6px;
        transition: 0.2s;
      }
      .token-details[open] .token-summary::before {
        content: "▼";
      }
      .token-inner {
        margin-top: 8px;
      }
      .copy-btn {
        height: 24px;
        padding: 0 10px;
        border-radius: 6px;
        cursor: pointer;
        border: 1px solid var(--border-main);
        background: var(--bg-card);
        color: var(--primary);
        font-size: 11px;
        font-weight: 600;
        font-family: inherit;
        transition: 0.15s;
      }
      .copy-btn:hover {
        background: var(--bg-hover);
      }
      .copy-btn.copied {
        background: var(--success-bg);
        border-color: var(--success-border);
        color: var(--success);
      }
      .token-text {
        margin: 0;
        padding: 8px 10px;
        border-radius: 8px;
        background: var(--bg-input);
        border: 1px solid var(--border-card);
        color: var(--text-sub);
        font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
        font-size: 11px;
        line-height: 1.5;
        white-space: pre-wrap;
        word-break: break-all;
        user-select: text !important;
        -webkit-user-select: text !important;
      }
      .point-result {
        margin-top: 20px;
        padding: 16px;
        background: var(--bg-tip);
        border: 1px solid var(--border-card);
        border-radius: 14px;
      }
      .point-score {
        display: flex;
        gap: 12px;
        margin-bottom: 16px;
      }
      .score-box {
        flex: 1;
        background: var(--bg-card);
        border: 1px solid var(--border-card);
        border-radius: 10px;
        padding: 12px;
        text-align: center;
      }
      .score-num {
        font-size: 24px;
        font-weight: bold;
        color: var(--primary);
        line-height: 1.2;
      }
      .score-num .score-max {
        font-size: 15px;
        color: var(--text-light);
        font-weight: normal;
      }
      .score-label {
        font-size: 12px;
        color: var(--text-sub);
        margin-top: 4px;
      }
      .task-list-header {
        display: flex;
        justify-content: space-between;
        align-items: flex-end;
        margin-bottom: 10px;
      }
      .burst-btn {
        background: var(--danger-bg);
        color: var(--danger);
        border: 1px solid var(--danger-border);
        padding: 6px 12px;
        border-radius: 8px;
        font-size: 12.5px;
        font-weight: 600;
        cursor: pointer;
        transition: 0.15s;
      }
      .burst-btn:hover:not(:disabled) {
        filter: brightness(0.95);
      }
      .burst-btn:disabled {
        opacity: 0.6;
        cursor: not-allowed;
      }
      .task-list {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
      }
      @media (max-width: 360px) {
        .task-list {
          grid-template-columns: 1fr;
        }
      }
      .task-item {
        background: var(--bg-card);
        padding: 10px 12px;
        border: 1px solid var(--border-card);
        border-radius: 8px;
        font-size: 13px;
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        gap: 6px;
        transition: 0.2s;
      }
      .task-item.task-done {
        border-color: var(--success-border);
        background: var(--success-bg);
      }
      .task-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
      }
      .task-item.task-done .task-val {
        color: var(--success);
      }
      .task-val {
        color: var(--primary);
        font-weight: 600;
      }
      .task-rule {
        font-size: 11px;
        color: var(--text-light);
        line-height: 1.3;
        margin-bottom: 4px;
      }
      .task-comment-tip {
        font-size: 11px;
        color: var(--danger);
        margin-top: -2px;
      }
      .test-btn {
        background: var(--bg-card);
        border: 1px solid var(--border-main);
        color: var(--primary);
        padding: 4px 8px;
        border-radius: 6px;
        font-size: 11px;
        font-weight: 600;
        cursor: pointer;
        transition: 0.15s;
        display: flex;
        justify-content: center;
      }
      .test-btn:hover:not(:disabled) {
        background: var(--bg-hover);
        border-color: var(--primary);
      }
      .test-btn:disabled {
        opacity: 0.5;
        cursor: not-allowed;
      }
      .headline-actions {
        margin-top: 16px;
        padding-top: 16px;
        border-top: 1px dashed var(--border-dashed);
        display: flex;
        gap: 8px;
        flex-wrap: wrap;
      }
      .hl-btn {
        flex: 1 1 calc(50% - 4px);
        min-height: 38px;
        padding: 8px 10px;
        border-radius: 8px;
        font-size: 13px;
        font-weight: 600;
        cursor: pointer;
        transition: 0.15s;
        text-align: center;
        display: flex;
        align-items: center;
        justify-content: center;
      }
      .hl-btn.primary {
        background: var(--primary-light);
        color: var(--primary);
        border: 1px solid var(--primary-light);
      }
      .hl-btn.primary:hover:not(:disabled) {
        border-color: var(--primary);
      }
      .hl-btn.warning {
        background: var(--warn-bg);
        color: var(--warn);
        border: 1px solid var(--warn-border);
      }
      .hl-btn.warning:hover:not(:disabled) {
        border-color: var(--warn);
      }
      .hl-btn:disabled {
        opacity: 0.6;
        cursor: not-allowed;
      }

      /* 底部操作记录列表 */
      .records-title {
        width: 100%;
        margin: 20px 0 0;
        font-size: 13px;
        font-weight: 600;
        color: var(--text-sub);
        letter-spacing: 0.5px;
      }
      .records-panel {
        width: 100%;
        margin-top: 10px;
      }
      .record-group {
        background: var(--bg-card);
        border: 1px solid var(--border-card);
        border-radius: 14px;
        margin-bottom: 12px;
        overflow: hidden;
        box-shadow: var(--shadow);
        transition: 0.3s;
      }
      .record-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 12px 14px;
        cursor: pointer;
        user-select: none;
      }
      .record-title {
        font-size: 14px;
        font-weight: 600;
        color: var(--text-main);
      }
      .record-actions {
        display: flex;
        align-items: center;
        gap: 12px;
      }
      .record-arrow {
        font-size: 10px;
        color: var(--text-sub);
        transition: transform 0.2s;
      }
      .record-group.collapsed .record-arrow {
        transform: rotate(-90deg);
      }
      .record-group.collapsed .record-body {
        display: none;
      }
      .record-clear-btn {
        background: var(--bg-tip);
        color: var(--text-sub);
        border: 1px solid var(--border-main);
        padding: 4px 10px;
        border-radius: 6px;
        font-size: 11px;
        cursor: pointer;
        transition: 0.15s;
      }
      .record-clear-btn:hover {
        background: var(--danger-bg);
        color: var(--danger);
        border-color: var(--danger-border);
      }
      .record-body {
        border-top: 1px solid var(--border-card);
        max-height: 300px;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
      }

      .headline-item {
        display: flex;
        align-items: baseline;
        gap: 6px;
        padding: 9px 14px;
        font-size: 13px;
        color: var(--primary);
        text-decoration: none;
        line-height: 1.5;
        border-bottom: 1px dashed var(--border-dashed);
      }
      .headline-item:last-child {
        border-bottom: none;
      }
      .headline-item:active {
        background: var(--bg-hover);
      }
      .hl-title {
        flex: 1;
        word-break: break-all;
      }
      .hl-tags {
        display: flex;
        gap: 4px;
        flex-wrap: wrap;
        flex: none;
      }
      .hl-tag {
        font-size: 10px;
        padding: 1px 6px;
        border-radius: 6px;
        background: var(--bg-tip);
        color: var(--text-sub);
        white-space: nowrap;
      }
      .hl-tag-ok {
        background: var(--success-bg);
        color: var(--success);
      }
      .hl-tag-warn {
        background: var(--warn-bg);
        color: var(--warn);
      }
      .hl-tag-err {
        background: var(--danger-bg);
        color: var(--danger);
      }

      .overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.6);
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        z-index: 9999;
        touch-action: none;
      }
      .modal-content {
        background: var(--bg-card);
        border-radius: 16px;
        padding: 24px;
        width: 90%;
        max-width: 320px;
        box-shadow: 0 12px 34px rgba(0, 0, 0, 0.15);
      }
      .modal-content h3 {
        margin: 0 0 16px;
        font-size: 16px;
        text-align: center;
        color: var(--text-main);
      }
      .range-input-group {
        display: flex;
        gap: 10px;
        margin-bottom: 20px;
      }
      .range-input-group input {
        flex: 1;
        height: 40px;
        padding: 0 10px;
        border: 1px solid var(--border-main);
        border-radius: 8px;
        font-size: 16px;
        background: var(--bg-input);
        color: var(--text-main);
      }
      .range-input-group select {
        width: 80px;
        height: 40px;
        padding: 0 10px;
        border: 1px solid var(--border-main);
        border-radius: 8px;
        font-size: 15px;
        background: var(--bg-input);
        color: var(--text-main);
      }
      .modal-actions {
        display: flex;
        gap: 10px;
      }
      .modal-actions .btn {
        flex: 1;
        height: 40px;
        font-size: 14px;
      }
      .spinner {
        width: 40px;
        height: 40px;
        border: 4px solid rgba(255, 255, 255, 0.3);
        border-top-color: #fff;
        border-radius: 50%;
        animation: spin 1s linear infinite;
        margin-bottom: 12px;
      }
      @keyframes spin {
        to {
          transform: rotate(360deg);
        }
      }
      .loading-text {
        color: #fff;
        font-size: 15px;
        font-weight: 500;
      }
      .hidden {
        display: none !important;
      }

      /* 游戏层样式 */
      #gameOverlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        z-index: 1000;
        background: var(--bg-body);
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        transition: opacity 0.8s ease;
      }
      .game-tips {
        text-align: center;
        margin-bottom: 40px;
        pointer-events: none;
        transition: opacity 0.3s;
      }
      .game-tips h2 {
        font-size: 22px;
        color: var(--text-main);
        margin: 0 0 10px;
        letter-spacing: 1px;
      }
      .game-tips p {
        font-size: 14px;
        color: var(--text-sub);
        margin: 0;
      }
      .game-stage {
        position: relative;
        width: 280px;
        height: 280px;
        touch-action: none;
      }

      /* 甜品：可点击，居中于 stage，带抖动动画 */
      .dessert-svg {
        position: absolute;
        left: 50%;
        top: 50%;
        width: 100px;
        height: 100px;
        transform: translate(-50%, -50%);
        cursor: pointer;
        pointer-events: auto;
        -webkit-tap-highlight-color: transparent;
      }

      @keyframes dessertShake {
        0% {
          transform: translate(-50%, -50%) rotate(0deg) scale(1);
        }
        18% {
          transform: translate(-50%, -50%) rotate(-11deg) scale(1.09);
        }
        36% {
          transform: translate(-50%, -50%) rotate(9deg) scale(1.06);
        }
        54% {
          transform: translate(-50%, -50%) rotate(-6deg) scale(1.04);
        }
        72% {
          transform: translate(-50%, -50%) rotate(4deg) scale(1.02);
        }
        100% {
          transform: translate(-50%, -50%) rotate(0deg) scale(1);
        }
      }
      .dessert-svg.shake {
        animation: dessertShake 0.55s cubic-bezier(0.36, 0.07, 0.19, 0.97);
      }

      /* 吃豆人：fixed 定位，JS 通过 transform 控制位置与旋转 */
      .pacman-svg {
        position: fixed;
        left: 0;
        top: 0;
        width: 80px;
        height: 80px;
        cursor: grab;
        z-index: 10;
        transform-origin: center center;
        will-change: transform;
        touch-action: none;
      }
      .pacman-svg:active {
        cursor: grabbing;
      }
      .pacman-svg.pacman-jump {
        cursor: pointer;
        animation: pacmanJump 0.9s cubic-bezier(0.28, 0.6, 0.36, 1) infinite;
      }
      @keyframes pacmanJump {
        0%,
        100% {
          transform: rotate(0deg) scale(1) translateY(0);
        }
        45% {
          transform: rotate(0deg) scale(1.04) translateY(-30px);
        }
        65% {
          transform: rotate(0deg) scale(0.98) translateY(-22px);
        }
      }

      @keyframes fadeIn {
        from {
          opacity: 0;
          transform: translateY(20px);
        }
        to {
          opacity: 1;
          transform: translateY(0);
        }
      }
      .fade-in {
        animation: fadeIn 0.8s ease forwards;
      }

      @media (max-width: 560px) {
        body {
          padding: 24px 12px 44px;
        }
        .card {
          padding: 18px;
          border-radius: 16px;
        }
        .field {
          flex-direction: column;
        }
        .field .btn {
          width: 100%;
        }
        .actions {
          flex-direction: column;
        }
        .actions .btn {
          width: 100%;
          flex: none;
        }
        .hl-btn {
          flex: 1 1 100%;
        }
        .head h1 {
          font-size: 20px;
        }
        .theme-switch {
          transform: scale(0.9);
          transform-origin: top right;
        }
        .head-switches-left {
          transform: scale(0.9);
          transform-origin: top left;
        }
      }

      #authActionBox {
        margin-bottom: 12px;
      }
      #openAuthBtn {
        width: 100%;
      }
      .token-meta-row {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-bottom: 6px;
      }
      #expDateText {
        font-size: 11px;
        color: var(--text-light);
      }

      /* 新手引导 */
      body.guide-open {
        overflow: hidden;
      }
      /* 引导期间去掉 fade-in 的 transform 叠层，保证高亮元素能提到遮罩上方 */
      body.guide-open #mainContent {
        animation: none !important;
        transform: none !important;
      }
      .guide-overlay {
        position: fixed;
        inset: 0;
        z-index: 9000;
        background: rgba(0, 0, 0, 0.55);
        touch-action: none;
      }
      .guide-tip {
        position: fixed;
        left: 50%;
        bottom: 118px;
        transform: translateX(-50%);
        width: calc(100% - 36px);
        max-width: 360px;
        padding: 16px 18px;
        border-radius: 14px;
        background: #ffffff;
        color: #1f2430;
        font-size: 16px;
        line-height: 1.7;
        font-weight: 600;
        box-shadow: 0 10px 34px rgba(0, 0, 0, 0.28);
        z-index: 9002;
        pointer-events: none;
      }
      .guide-tip .guide-text {
        white-space: normal;
      }
      .guide-arrow {
        position: fixed;
        top: 14px;
        right: 30px;
        z-index: 9002;
        color: #ffffff;
        font-size: 68px;
        line-height: 1;
        text-shadow: 0 3px 14px rgba(0, 0, 0, 0.55);
        pointer-events: none;
        animation: guideArrow 1.2s ease-in-out infinite;
      }
      @keyframes guideArrow {
        0%,
        100% {
          transform: translate(0, 0);
        }
        50% {
          transform: translate(6px, -6px);
        }
      }
      .guide-actions {
        position: fixed;
        left: 0;
        right: 0;
        top: auto;
        bottom: calc(72px + env(safe-area-inset-bottom));
        transform: none;
        z-index: 9002;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
        padding: 0 16px;
        background: none;
        pointer-events: none;
      }
      .guide-actions .btn {
        flex: 1 1 0;
        width: auto;
        min-width: 0;
        pointer-events: auto;
      }
      .guide-actions .btn.ghost {
        background: rgba(255, 255, 255, 0.14);
        border-color: rgba(255, 255, 255, 0.45);
        color: #ffffff;
      }
      .guide-actions .btn.ghost:hover:not(:disabled) {
        background: rgba(255, 255, 255, 0.3);
        border-color: #ffffff;
        color: #ffffff;
        box-shadow: none;
      }
      .guide-actions .btn.guide-next {
        background: #07c160;
        border-color: transparent;
        color: #ffffff;
        font-weight: 700;
      }
      .guide-actions .btn.guide-next:hover:not(:disabled) {
        background: #06ad56;
        color: #ffffff;
        box-shadow: 0 9px 20px rgba(7, 193, 96, 0.35);
      }
      .guide-actions .btn:disabled {
        opacity: 0.35;
      }
      .guide-target {
        position: relative !important;
        z-index: 9001 !important;
        pointer-events: none !important;
        border-radius: 12px;
        animation: guideTargetPulse 1.5s ease-in-out infinite;
      }
      @keyframes guideTargetPulse {
        0%,
        100% {
          transform: scale(1);
          box-shadow: 0 0 0 3px #4f6cf7, 0 0 0 9px rgba(79, 108, 247, 0.35),
            0 0 24px rgba(79, 108, 247, 0.55);
        }
        50% {
          transform: scale(1.03);
          box-shadow: 0 0 0 5px #4f6cf7, 0 0 0 16px rgba(79, 108, 247, 0.18),
            0 0 34px rgba(79, 108, 247, 0.75);
        }
      }
      .app-toast {
        position: fixed;
        left: 50%;
        top: 50%;
        bottom: auto;
        z-index: 9100;
        max-width: 76vw;
        padding: 10px 18px;
        border-radius: 999px;
        background: rgba(0, 0, 0, 0.82);
        color: #ffffff;
        font-size: 14px;
        font-weight: 600;
        line-height: 1.4;
        text-align: center;
        pointer-events: none;
        opacity: 0;
        transform: translate(-50%, calc(-50% + 10px));
        transition: opacity 0.22s ease, transform 0.22s ease;
      }
      .app-toast.show {
        opacity: 1;
        transform: translate(-50%, -50%);
      }