:root {
    --ink: #173127;
    --muted: #678074;
    --green: #6b8e8e;
    --green-dark: #326b4d;
    --line: rgba(52, 101, 73, .16);
    --glass: rgba(255, 255, 255, .54);
}

* { box-sizing: border-box; }

html, body { margin: 0; height: 100%; min-height: 100%; }

body {
    min-height: 100svh;
    height: 100%;
    overflow: hidden;
    color: var(--ink);
    font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "PingFang SC", "Microsoft YaHei", sans-serif;
    background: #fff;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -2;
    background:
        radial-gradient(circle at 75% 28%, rgba(255,255,255,.88), transparent 38%),
        linear-gradient(135deg, #f8fcf6 0%, #edf7eb 50%, #dfefdf 100%);
    opacity: 1;
}

body::after {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    opacity: .17;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.16'/%3E%3C/svg%3E");
    mix-blend-mode: soft-light;
}

button, input { font: inherit; }
button { -webkit-tap-highlight-color: transparent; }

.auth-page {
    height: 100svh;
    display: flex;
    flex-direction: row;
}

.auth-column {
    z-index: 3;
    flex: 0 0 46%;
    min-width: 420px;
    display: grid;
    place-items: center;
    padding: clamp(24px, 5vw, 76px);
}

.auth-card {
    width: min(100%, 446px);
    max-height: calc(100svh - 42px);
    overflow: auto;
    padding: clamp(27px, 4vw, 43px);
    border: 1px solid rgba(255,255,255,.82);
    border-radius: 14px;
    background:
        linear-gradient(145deg, rgba(255,255,255,.72), rgba(255,255,255,.33)),
        var(--glass);
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    opacity: 1;
    scrollbar-width: thin;
}

.brand-block { display: flex; align-items: baseline; gap: 12px; margin-bottom: 26px; }
.brand { font: italic 36px/1 Georgia, serif; color: #6b8e8e; letter-spacing: -.02em; }
.brand-block p { margin: 0; color: #73887b; font-size: 12px; letter-spacing: .08em; }
.view-heading span, .policy-sheet header span { color: #779383; font-size: 10px; letter-spacing: .18em; }
.view-heading h1 { margin: 6px 0 5px; font-size: clamp(25px, 3vw, 31px); font-weight: 620; letter-spacing: -.035em; }
.view-heading p { margin: 0 0 21px; color: var(--muted); font-size: 13px; line-height: 1.7; }

.auth-view { display: none; }
.auth-view.active { display: block; animation: view-in .38s ease; }
@keyframes view-in { from { opacity: 0; transform: translateX(10px); } to { opacity: 1; transform: none; } }

label:not(.agreement-check) { display: block; margin: 14px 0 7px; color: #3d5e4b; font-size: 12px; font-weight: 600; }
.field {
    width: 100%;
    min-height: 46px;
    padding: 12px 14px;
    border: 1px solid var(--line);
    border-radius: 13px;
    outline: none;
    color: var(--ink);
    background: rgba(255,255,255,.58);
    box-shadow: inset 0 1px rgba(255,255,255,.7);
    transition: border-color .25s, box-shadow .25s, background .25s;
}
.field:focus { border-color: rgba(73, 143, 101, .6); background: rgba(255,255,255,.82); box-shadow: 0 0 0 4px rgba(107,142,142,.11); }
.field.invalid { border-color: rgba(182,72,72,.58); box-shadow: 0 0 0 4px rgba(182,72,72,.08); }
.field.valid { border-color: rgba(76,175,80,.6); box-shadow: 0 0 0 4px rgba(76,175,80,.08); }
.field-hint { margin: 5px 0 0; font-size: 11px; line-height: 1.5; color: #8a9a90; min-height: 16px; }
.field-hint.error { color: #c26161; }
.field-hint.success { color: #5a9a6d; }
.contact-input-wrapper { position: relative; }
.email-suffix-dropdown {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid rgba(52, 101, 73, .16);
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(42, 80, 57, .12);
    z-index: 10;
    overflow: hidden;
}
.suffix-option {
    padding: 10px 14px;
    font-size: 13px;
    color: #3d5e4b;
    cursor: pointer;
    transition: background .15s;
}
.suffix-option:hover { background: rgba(107,142,142,.08); }
.sms-upstream-notice {
    display: flex;
    gap: 12px;
    margin: 12px 0;
    padding: 14px;
    border-radius: 12px;
    background: rgba(226, 242, 228, .6);
    border: 1px solid rgba(76, 175, 80, .15);
}
.sms-upstream-notice .notice-icon {
    flex: 0 0 24px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: linear-gradient(135deg, #7d9e9e, #5a7a7a);
    color: #fff;
    font-size: 14px;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    font-style: italic;
    font-family: Georgia, serif;
}
.sms-upstream-notice .notice-content { flex: 1; }
.sms-upstream-notice .notice-title { margin: 0 0 4px; font-size: 12px; font-weight: 600; color: #2e5f42; }
.sms-upstream-notice .notice-desc { margin: 0 0 4px; font-size: 11px; color: #4a6b57; line-height: 1.6; }
.sms-upstream-notice .notice-tip { margin: 0; font-size: 10px; color: #7a8f81; }
.sms-upstream-notice .notice-highlight { color: #6b8e8e; font-weight: 600; }
.password-field { position: relative; }
.password-field .field { padding-right: 58px; }
.peek { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); border: 0; background: transparent; color: #5f8a70; font-size: 11px; cursor: pointer; }
.forgot-link { display: block; margin: 10px 0 0 auto; }

.primary-button, .secondary-button {
    border: 1px solid rgba(255,255,255,.75);
    border-radius: 10px;
    cursor: pointer;
    transition: transform .2s, box-shadow .2s, opacity .2s;
}
.primary-button {
    width: 100%;
    min-height: 47px;
    margin-top: 20px;
    color: #fff;
    background: linear-gradient(135deg, #7d9e9e, #5a7a7a);
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
    font-weight: 650;
}
.primary-button:not(:disabled):hover { transform: translateY(-2px); box-shadow: 0 14px 28px rgba(107,142,142,.25); }
.primary-button:disabled { opacity: .4; cursor: not-allowed; box-shadow: none; }
.secondary-button { flex: 0 0 110px; min-height: 46px; padding: 0 10px; color: #5a7a7a; background: rgba(255,255,255,.54); font-size: 12px; }
.secondary-button:disabled { opacity: .5; cursor: not-allowed; }
.text-link, .policy-link { border: 0; padding: 0; color: #6b8e8e; background: transparent; cursor: pointer; font-size: 12px; }
.text-link:hover, .policy-link:hover { text-decoration: underline; }
.switch-line { margin: 18px 0 0; text-align: center; color: #74847b; font-size: 12px; }
.form-message { min-height: 18px; margin: 12px 0 -5px; text-align: center; color: #ae4f4f; font-size: 12px; }
.form-message.success { color: #397a50; }
.form-message.dev-code { padding: 9px; border-radius: 10px; color: #376d4b; background: rgba(226,242,228,.8); }
.code-row { display: flex; gap: 8px; }
.code-field { letter-spacing: .16em; }
.strength { display: flex; align-items: center; gap: 4px; height: 18px; margin-top: 5px; }
.strength i { width: 30px; height: 3px; border-radius: 5px; background: rgba(50,95,69,.13); }
.strength span { margin-left: 5px; color: #809087; font-size: 10px; }
.strength[data-level="1"] i:first-child { background: #c97865; }
.strength[data-level="2"] i:nth-child(-n+2) { background: #c2a452; }
.strength[data-level="3"] i { background: #5a9a6d; }
.strength[data-level="4"] i { background: #4caf50; }
.agreement-check { display: flex; align-items: flex-start; gap: 8px; margin-top: 15px; color: #65776d; font-size: 11px; line-height: 1.7; cursor: pointer; }
.agreement-check input { width: 16px; height: 16px; margin: 2px 0 0; accent-color: #4f8d68; }
.policy-link { font-size: inherit; }
.reset-progress { display: flex; gap: 6px; margin: 4px 0 18px; }
.reset-progress i { flex: 1; height: 3px; border-radius: 5px; background: rgba(67,112,81,.15); }
.reset-progress i.active { background: #639b73; }
.resend-line { display: flex; justify-content: space-between; margin-top: 9px; color: #809087; font-size: 11px; }
.hidden { display: none !important; }

.tree-column { position: relative; flex: 1; overflow: hidden; background: transparent; pointer-events: none; }
.tree-photo {
    position: absolute;
    z-index: 0;
    max-width: none;
    opacity: 0;
    pointer-events: none;
}
#treeCanvas { position: relative; z-index: 1; display: block; width: 100%; height: 100svh; pointer-events: none; }
.tree-copy {
    position: absolute;
    z-index: 2;
    top: 7%;
    right: 8%;
    text-align: right;
    color: rgba(44,80,57,.58);
    pointer-events: none;
    opacity: 0;
    transition: opacity 1.2s ease 1.6s;
}
body.life .tree-copy { opacity: 1; }
.tree-copy small { font-size: 9px; letter-spacing: .18em; display: block; }
.tree-copy p { margin: 8px 0 0; font: italic clamp(16px, 1.6vw,23px)/1.6 Georgia, serif; }
.tree-copy-en { display: block; margin-top: 6px; font-size: clamp(9px, 0.9vw, 12px); letter-spacing: .04em; color: rgba(44,80,57,.42); font-style: italic; }
.tree-hint { position: absolute; z-index: 2; right: 8%; bottom: 5%; color: rgba(56,86,67,.55); font-size: 10px; letter-spacing: .08em; opacity: 0; transition: opacity .8s 3s; pointer-events: none; }
body.life .tree-hint { opacity: 1; }

/* ====== 短信验证区域（注册表单内） ====== */
.sms-verify-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 12px 0;
    padding: 14px 16px;
    border-radius: 14px;
    background: rgba(226, 242, 228, .6);
    border: 1px solid rgba(76, 175, 80, .18);
}
.sms-verify-label {
    font-size: 13px;
    font-weight: 600;
    color: #2e5f42;
}
.sms-start-btn {
    flex: 0 0 auto;
    min-height: 36px;
    padding: 0 18px;
    font-size: 12px;
}
.sms-verify-status {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 10px 0 8px;
    padding: 14px;
    border-radius: 14px;
    background: rgba(255, 248, 225, .6);
    border: 1px solid rgba(255, 193, 7, .25);
}
.sms-status-icon {
    flex: 0 0 32px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255, 193, 7, .15);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
}
.sms-status-text { flex: 1; }
.sms-status-title { margin: 0 0 2px; font-size: 12px; font-weight: 600; color: #5a4a1a; }
.sms-status-desc { margin: 0; font-size: 11px; color: #8a7a4a; }
.sms-recheck-btn {
    flex: 0 0 auto;
    min-height: 34px;
    padding: 0 14px;
    font-size: 11px;
    background: rgba(76, 175, 80, .12);
    color: #6b8e8e;
    border: 1px solid rgba(76, 175, 80, .2);
    border-radius: 10px;
    cursor: pointer;
    transition: background .2s;
}
.sms-recheck-btn:hover { background: rgba(76, 175, 80, .2); }
.sms-recheck-btn:disabled { opacity: .4; cursor: not-allowed; }
.sms-verify-status.verified {
    background: rgba(226, 242, 228, .8);
    border-color: rgba(76, 175, 80, .3);
}
.sms-verify-status.verified .sms-status-icon {
    background: rgba(76, 175, 80, .15);
}

/* ====== 短信验证弹窗 ====== */
.sms-modal {
    position: fixed;
    inset: 0;
    z-index: 30;
    display: grid;
    place-items: center;
    padding: clamp(12px, 3vw, 36px);
    background: rgba(22, 46, 33, .28);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}
.sms-modal[hidden] { display: none; }
.sms-modal-sheet {
    width: min(420px, 100%);
    border: 1px solid rgba(255, 255, 255, .82);
    border-radius: 14px;
    background: rgba(248, 252, 247, .95);
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
    animation: modal-in .3s ease;
    overflow: hidden;
}
.sms-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px 16px;
    border-bottom: 1px solid rgba(54, 91, 67, .11);
}
.sms-modal-header h2 { margin: 0; font-size: 18px; font-weight: 620; color: var(--ink); }
.sms-modal-close {
    width: 32px;
    height: 32px;
    border: 1px solid rgba(54, 91, 67, .12);
    border-radius: 50%;
    color: #4a6e58;
    background: rgba(255, 255, 255, .66);
    cursor: pointer;
    font-size: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .2s;
}
.sms-modal-close:hover { background: rgba(255, 255, 255, .9); }
.sms-modal-body { padding: 20px 24px 24px; }

.sms-modal-step {
    display: flex;
    gap: 14px;
    margin-bottom: 18px;
}
.sms-step-num {
    flex: 0 0 28px;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: linear-gradient(135deg, #7d9e9e, #5a7a7a);
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}
.sms-step-content { flex: 1; }
.sms-step-title { margin: 0 0 2px; font-size: 13px; font-weight: 600; color: var(--ink); }
.sms-step-desc { margin: 0 0 8px; font-size: 11px; color: #8a9a90; }

.sms-copy-row {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    border-radius: 10px;
    background: rgba(235, 245, 237, .8);
    border: 1px solid rgba(76, 175, 80, .15);
}
.sms-copy-text {
    flex: 1;
    font-size: 13px;
    font-weight: 600;
    color: #2e5f42;
    font-family: "SF Mono", "Menlo", "Consolas", monospace;
    word-break: break-all;
}
.sms-copy-btn {
    flex: 0 0 auto;
    padding: 6px 14px;
    border: 1px solid rgba(76, 175, 80, .25);
    border-radius: 8px;
    background: #fff;
    color: #6b8e8e;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    transition: all .2s;
}
.sms-copy-btn:hover { background: rgba(76, 175, 80, .08); }
.sms-copy-btn.copied { background: #6b8e8e; color: #fff; border-color: #6b8e8e; }

.sms-countdown-bar {
    margin: 20px 0 14px;
}
.sms-countdown-track {
    width: 100%;
    height: 4px;
    border-radius: 4px;
    background: rgba(54, 91, 67, .1);
    overflow: hidden;
}
.sms-countdown-fill {
    height: 100%;
    width: 100%;
    border-radius: 4px;
    background: linear-gradient(90deg, #7d9e9e, #5a7a7a);
    transition: width 1s linear;
}
.sms-countdown-label {
    display: block;
    margin-top: 6px;
    font-size: 10px;
    color: #8a9a90;
    text-align: center;
}

.sms-recheck-primary {
    margin-top: 0;
}
.sms-recheck-primary:disabled { opacity: .4; cursor: not-allowed; }
.sms-modal-hint {
    margin: 10px 0 0;
    text-align: center;
    font-size: 11px;
    min-height: 16px;
    color: #ae4f4f;
}
.sms-modal-hint.success { color: #397a50; }

/* ====== 短信验证选择面板（移动端） ====== */
.sms-mobile-panel {
    position: fixed;
    inset: 0;
    z-index: 30;
    display: grid;
    place-items: center;
    padding: clamp(12px, 3vw, 36px);
    background: rgba(22, 46, 33, .28);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}
.sms-mobile-panel[hidden] { display: none; }
.sms-mobile-sheet {
    width: min(380px, 100%);
    border: 1px solid rgba(255, 255, 255, .82);
    border-radius: 14px;
    background: rgba(248, 252, 247, .95);
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
    animation: modal-in .3s ease;
    overflow: hidden;
}
.sms-mobile-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px 16px;
    border-bottom: 1px solid rgba(54, 91, 67, .11);
}
.sms-mobile-header h2 { margin: 0; font-size: 18px; font-weight: 620; color: var(--ink); }
.sms-mobile-body { padding: 28px 24px 24px; text-align: center; }
.sms-mobile-icon {
    width: 56px;
    height: 56px;
    margin: 0 auto 14px;
    border-radius: 50%;
    background: linear-gradient(135deg, #7d9e9e, #5a7a7a);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
}
.sms-mobile-title { margin: 0 0 6px; font-size: 17px; font-weight: 620; color: var(--ink); }
.sms-mobile-desc { margin: 0 0 18px; font-size: 12px; color: #8a9a90; line-height: 1.6; }
.sms-mobile-tip { margin: 10px 0 0; font-size: 10px; color: #aab7ae; }
.sms-mobile-body .sms-copy-row { text-align: left; }

.policy-modal {
    position: fixed;
    inset: 0;
    z-index: 20;
    display: grid;
    place-items: center;
    padding: clamp(12px, 3vw, 36px);
    background: rgba(22,46,33,.28);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}
.policy-modal[hidden] { display: none; }
.policy-sheet {
    width: min(860px, 100%);
    height: min(88svh, 820px);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,.82);
    border-radius: 14px;
    background: rgba(248,252,247,.9);
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
    animation: modal-in .3s ease;
}
@keyframes modal-in { from { opacity: 0; transform: translateY(14px) scale(.985); } }
.policy-sheet header { display: flex; align-items: center; justify-content: space-between; padding: 22px 27px 17px; border-bottom: 1px solid rgba(54,91,67,.11); }
.policy-sheet h2 { margin: 4px 0 0; font-size: 21px; }
.modal-close { width: 36px; height: 36px; border: 1px solid rgba(54,91,67,.12); border-radius: 50%; color: #4a6e58; background: rgba(255,255,255,.66); cursor: pointer; font-size: 23px; }
.policy-content { overflow-y: auto; padding: 22px 28px 34px; color: #455d4d; font-size: 13px; line-height: 1.9; }
.policy-content h3 { margin: 23px 0 6px; color: #294b37; font-size: 15px; }
.policy-content p { margin: 7px 0; }
.policy-updated { color: #819087; font-size: 11px; }
.policy-note { margin-top: 25px !important; padding: 14px; border-radius: 12px; background: rgba(222,237,222,.65); }

@media (max-width: 760px) {
    body { overflow: auto; }
    .auth-page { display: flex; min-height: 100svh; flex-direction: column-reverse; }
    .tree-column { flex: 0 0 45svh; min-height: 320px; }
    #treeCanvas { height: 100%; }
    .auth-column { flex: 1; padding: 0 15px 22px; }
    .auth-card { width: 100%; max-height: none; padding: 24px; border-radius: 14px; }
    .tree-copy { top: 10%; right: 6%; }
    .tree-hint { display: none; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; transition-duration: .01ms !important; transition-delay: 0ms !important; }
}

/* ====== 树叶微动动画（入场动画完成后激活） ====== */
@keyframes leaf-sway {
    0%, 100% { transform: translateX(0) rotate(0deg); }
    25% { transform: translateX(0.3px) rotate(0.04deg); }
    50% { transform: translateX(0) rotate(0.07deg); }
    75% { transform: translateX(-0.3px) rotate(0.04deg); }
}

body.life #treeCanvas {
    animation: leaf-sway 800s ease-in-out infinite;
}

/* 全局隐藏滚动条但保留滚动功能 */
.auth-card::-webkit-scrollbar {
    display: none;
}

/* ====== 人机验证组件（ALTCHA 开源 PoW 方案） ====== */
.captcha-container {
    margin: 4px 0 2px;
}

/* ALTCHA widget 主题适配 —— 与页面月白/苔绿风格统一 */
altcha-widget {
    --altcha-color-primary: #6b8e8e;
    --altcha-color-base: rgba(255, 255, 255, 0.55);
    --altcha-color-border: rgba(107, 142, 142, 0.22);
    --altcha-color-border-focus: #6b8e8e;
    --altcha-color-text: #3a4a4a;
    --altcha-color-error-text: #b85450;
    --altcha-color-footer-bg: transparent;
    --altcha-border-width: 1px;
    --altcha-border-radius: 14px;
    --altcha-max-width: 100%;
    width: 100%;
    margin: 0;
}

/* widget 内部 main 容器 */
altcha-widget::part(main) {
    border-radius: 14px;
}

/* 复选框 / 验证按钮 */
altcha-widget::part(checkbox) {
    border-color: rgba(107, 142, 142, 0.3);
}
altcha-widget::part(checkbox):focus {
    box-shadow: 0 0 0 3px rgba(107, 142, 142, 0.18);
}

/* PoW 计算中的加载圈 */
altcha-widget::part(spinner) {
    border-top-color: #6b8e8e;
}

/* 验证通过的对勾 */
altcha-widget::part(verifying) {
    color: #6b8e8e;
}

/* 错误 / 过期提示 */
altcha-widget::part(error) {
    color: #b85450;
}

.captcha-msg {
    min-height: 16px;
    font-size: 12.5px;
}
.captcha-msg.success {
    color: #2f7d5b;
}

/* === 微信扫码登录(底部一行 + 弹窗) === */
.auth-divider {
    display: flex;
    align-items: center;
    gap: 14px;
    margin: 22px 0 14px;
    color: #819087;
    font-size: 11.5px;
    letter-spacing: 0.04em;
}
.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(54,91,67,.18), transparent);
}
.auth-divider span {
    white-space: nowrap;
}

.wechat-entry {
    display: flex;
    justify-content: center;
}
.wechat-btn {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    padding: 11px 22px 11px 18px;
    border: 1px solid rgba(54,91,67,.18);
    border-radius: 999px;
    background: rgba(255,255,255,.78);
    color: #365b43;
    font-size: 13.5px;
    font-weight: 500;
    cursor: pointer;
    transition: transform .18s ease, box-shadow .18s ease, background .18s ease, border-color .18s ease;
    box-shadow: 0 1px 3px rgba(0,0,0,.04);
}
.wechat-btn:hover {
    transform: translateY(-1px);
    background: rgba(255,255,255,.95);
    border-color: rgba(7,193,96,.45);
    color: #07c160;
    box-shadow: 0 6px 18px rgba(7,193,96,.12);
}
.wechat-btn:active { transform: translateY(0); }
.wechat-btn:focus-visible {
    outline: 2px solid rgba(7,193,96,.45);
    outline-offset: 2px;
}
.wechat-icon {
    width: 18px;
    height: 18px;
    color: #07c160;
    flex-shrink: 0;
}

/* === 微信扫码弹窗(与 policy-modal 玻璃风一致) === */
.wechat-modal {
    position: fixed;
    inset: 0;
    z-index: 30;
    display: grid;
    place-items: center;
    padding: clamp(12px, 3vw, 36px);
    background: rgba(22,46,33,.32);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    animation: modal-in .25s ease;
}
.wechat-modal[hidden] { display: none; }
.wechat-modal-mask {
    position: absolute;
    inset: 0;
    z-index: 0;
}
.wechat-modal-card {
    position: relative;
    z-index: 1;
    width: min(360px, 100%);
    padding: 24px 26px 26px;
    border: 1px solid rgba(255,255,255,.82);
    border-radius: 18px;
    background: rgba(248,252,247,.95);
    box-shadow: 0 12px 40px rgba(0,0,0,.18);
    text-align: center;
    color: #365b43;
}
.wechat-modal-card header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 0 0 18px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(54,91,67,.11);
    text-align: left;
}
.wechat-modal-card header > div { display: flex; flex-direction: column; gap: 2px; }
.wechat-modal-card header span {
    font-size: 10.5px;
    letter-spacing: 0.18em;
    color: #819087;
}
.wechat-modal-card h2 {
    margin: 0;
    font-size: 17px;
    color: #294b37;
}
.wechat-modal-body { display: flex; flex-direction: column; align-items: center; gap: 14px; }
.wechat-qrcode {
    width: 220px;
    height: 220px;
    padding: 10px;
    border-radius: 12px;
    background: #fff;
    box-shadow: inset 0 0 0 1px rgba(54,91,67,.08);
    display: flex;
    align-items: center;
    justify-content: center;
}
.wechat-qrcode img,
.wechat-qrcode canvas { display: block; }
.wechat-modal-tip {
    margin: 4px 0 0;
    font-size: 13px;
    color: #455d4d;
}
.wechat-modal-status {
    margin: 0;
    font-size: 11.5px;
    color: #819087;
    min-height: 16px;
}
.wechat-status-err { color: #ae4f4f; }

@media (max-width: 760px) {
    .wechat-modal-card { width: min(340px, 100%); padding: 20px 18px 22px; }
    .wechat-qrcode { width: 200px; height: 200px; }
}

