/* ============================================================
   赞助打赏独立页面 - 样式表
   精确复刻 vxras.com/sponsor
   依赖 Zibll 主题 CSS 变量：
   --theme-color --focus-shadow-color --main-color --muted-color
   --main-bg-color --muted-bg-color --main-border-color --main-shadow
   ============================================================ */

/* ==================== 页面容器 ==================== */
.zib-sponsor-page {
    padding: 20px;
    position: relative;
    overflow: hidden;
    background: linear-gradient(180deg,
        rgba(255,255,255,0.01) 0%,
        var(--muted-bg-color, rgba(247,248,250,0.4)) 30%,
        var(--muted-bg-color, rgba(247,248,250,0.6)) 70%,
        rgba(255,255,255,0.01) 100%
    );
    border-radius: var(--main-radius, 8px);
    border: none !important;
    outline: none !important;
    box-shadow: none !important;
}

/* ==================== 外层容器边框精准剔除 ==================== */
/* 清除 Zibll/WordPress 父主题对 sponsor 页面外围 wrapper 的边框 */
body:has(.zib-sponsor-page) .wp-posts-content,
body:has(.zib-sponsor-page) .wp-block-post-content,
body:has(.zib-sponsor-page) .post-content,
body:has(.zib-sponsor-page) .entry-content,
body:has(.zib-sponsor-page) .single-content,
body:has(.zib-sponsor-page) .main-content,
body:has(.zib-sponsor-page) .site-main,
body:has(.zib-sponsor-page) #content,
body:has(.zib-sponsor-page) #primary,
body:has(.zib-sponsor-page) .content-area,
body:has(.zib-sponsor-page) .post-article,
body:has(.zib-sponsor-page) .post-inner,
body:has(.zib-sponsor-page) article.page,
body:has(.zib-sponsor-page) article.post,
body:has(.zib-sponsor-page) .main-wrap,
body:has(.zib-sponsor-page) .container-page,
body:has(.zib-sponsor-page) .page-wrapper {
    border: none !important;
    outline: none !important;
    box-shadow: none !important;
}
/* 连带清除这些外层容器的伪元素可能产生的视觉分割线 */
body:has(.zib-sponsor-page) .post-content::before,
body:has(.zib-sponsor-page) .post-content::after,
body:has(.zib-sponsor-page) .entry-content::before,
body:has(.zib-sponsor-page) .entry-content::after,
body:has(.zib-sponsor-page) .single-content::before,
body:has(.zib-sponsor-page) .single-content::after,
body:has(.zib-sponsor-page) article.page::before,
body:has(.zib-sponsor-page) article.page::after {
    display: none !important;
}

/* 全局边框复位 —— 覆盖 Zibll 父主题继承的边框样式 */
.zib-sponsor-page .sponsor-section,
.zib-sponsor-page .sponsor-summary,
.zib-sponsor-page .stats-card,
.zib-sponsor-page .sponsor-goal-left,
.zib-sponsor-page .sponsor-ranking-right,
.zib-sponsor-page .sponsor-messages,
.zib-sponsor-page .sponsor-header,
.zib-sponsor-page .goal-card,
.zib-sponsor-page .message-card,
.zib-sponsor-page .amount-card,
.zib-sponsor-page .pay-method-card,
.zib-sponsor-page .stat-box,
.zib-sponsor-page .sponsor-tabs,
.zib-sponsor-page .tab-item,
.zib-sponsor-page .tab-line,
.zib-sponsor-page .method-badge,
.zib-sponsor-page .completed-tag,
.zib-sponsor-page input:not([type="radio"]):not([type="checkbox"]),
.zib-sponsor-page textarea,
.zib-sponsor-page select,
.zib-sponsor-page .summary-header,
.zib-sponsor-page .summary-row,
.zib-sponsor-page .stats-header,
.zib-sponsor-page .goal-header,
.zib-sponsor-page .ranking-header,
.zib-sponsor-page .ranking-item,
.zib-sponsor-page .messages-header,
.zib-sponsor-page .message-content,
.zib-sponsor-page .message-header,
.zib-sponsor-page .gift-custom-preview,
.zib-sponsor-page .line-form,
.zib-sponsor-page .sponsor-submit-btn,
.zib-sponsor-page .avatar-img img,
.zib-sponsor-page .ranking-avatar img,
.zib-sponsor-page .message-avatar img {
    border: none;
    outline: none;
}

/* 背景光晕 */
.zib-sponsor-page::before {
    content: '';
    position: fixed;
    top: -100px;
    right: -100px;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(255,71,87,0.12) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
    z-index: 0;
}
.zib-sponsor-page::after {
    content: '';
    position: fixed;
    bottom: -150px;
    left: -150px;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(255,193,7,0.1) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
    z-index: 0;
}

/* ==================== 浮点装饰动画 ==================== */
.sponsor-decoration {
    position: fixed;
    pointer-events: none;
    z-index: 0;
}
.decoration-1 {
    top: 12%; left: 8%;
    width: 60px; height: 60px;
    border: 2px dashed rgba(255,71,87,0.18);
    border-radius: 50%;
    animation: float-1 8s ease-in-out infinite;
}
.decoration-2 {
    top: 28%; right: 6%;
    width: 50px; height: 50px;
    background: rgba(255,193,7,0.07);
    border-radius: 12px;
    transform: rotate(45deg);
    animation: float-2 6s ease-in-out infinite;
}
.decoration-3 {
    bottom: 18%; left: 6%;
    width: 35px; height: 35px;
    border: 2px solid rgba(255,71,87,0.12);
    border-radius: 8px;
    animation: float-3 10s ease-in-out infinite;
}
.decoration-4 {
    bottom: 32%; right: 8%;
    width: 80px; height: 2px;
    background: linear-gradient(90deg, transparent, rgba(255,71,87,0.15), transparent);
    animation: float-4 7s ease-in-out infinite;
}
.decoration-5 {
    top: 45%; left: 3%;
    width: 4px; height: 4px;
    background: rgba(255,71,87,0.2);
    border-radius: 50%;
    animation: pulse-1 4s ease-in-out infinite;
}
.decoration-6 {
    top: 55%; right: 4%;
    width: 6px; height: 6px;
    background: rgba(255,193,7,0.18);
    border-radius: 50%;
    animation: pulse-2 5s ease-in-out infinite;
}
.decoration-7 {
    bottom: 10%; left: 12%;
    width: 3px; height: 3px;
    background: rgba(255,71,87,0.15);
    border-radius: 50%;
    animation: pulse-1 3.5s ease-in-out infinite;
}
.decoration-8 {
    top: 65%; left: 18%;
    width: 5px; height: 5px;
    background: rgba(255,193,7,0.12);
    border-radius: 50%;
    animation: pulse-2 4.5s ease-in-out infinite;
}
.decoration-9 {
    top: 20%; right: 18%;
    width: 4px; height: 4px;
    background: rgba(255,71,87,0.16);
    border-radius: 50%;
    animation: pulse-1 4.2s ease-in-out infinite;
}
.decoration-10 {
    bottom: 25%; right: 16%;
    width: 6px; height: 6px;
    background: rgba(255,193,7,0.14);
    border-radius: 50%;
    animation: pulse-2 5.2s ease-in-out infinite;
}

@keyframes float-1 {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50%      { transform: translateY(-20px) rotate(10deg); }
}
@keyframes float-2 {
    0%, 100% { transform: rotate(45deg) translateY(0); }
    50%      { transform: rotate(55deg) translateY(-15px); }
}
@keyframes float-3 {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50%      { transform: translateY(20px) rotate(-10deg); }
}
@keyframes float-4 {
    0%, 100% { opacity: 0.3; transform: scaleX(1); }
    50%      { opacity: 0.8; transform: scaleX(1.5); }
}
@keyframes pulse-1 {
    0%, 100% { transform: scale(1); opacity: 0.3; }
    50%      { transform: scale(1.5); opacity: 0.6; }
}
@keyframes pulse-2 {
    0%, 100% { transform: scale(1); opacity: 0.25; }
    50%      { transform: scale(1.4); opacity: 0.55; }
}

/* ==================== Header ==================== */
.sponsor-header {
    padding: 5px 2px;
    position: relative;
    z-index: 1;
    text-align: center;
}
.sponsor-header .wiui-donate-cover {
    position: relative;
    width: 100%;
    border-radius: var(--main-radius);
    overflow: hidden;
    box-sizing: border-box;
}
.sponsor-header .wiui-donate-cover img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
    -webkit-user-drag: none;
}
.sponsor-title {
    font-size: 32px;
    margin-bottom: 12px;
    font-weight: bold;
    color: var(--main-color);
}
.sponsor-desc {
    font-size: 14px;
    line-height: 1.8;
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
    color: var(--muted-color);
}

/* ==================== Tab 切换 ==================== */
.sponsor-tabs {
    position: relative;
    display: flex;
    background: linear-gradient(145deg, var(--muted-bg-color), rgba(255,255,255,0.03));
    border-radius: 12px;
    padding: 4px;
    margin-bottom: 24px;
    overflow: hidden;
    box-shadow: inset 0 1px 3px rgba(0,0,0,0.02);
}
.tab-line {
    position: absolute;
    bottom: 4px;
    height: calc(100% - 8px);
    background: var(--main-bg-color);
    border-radius: 8px;
    transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: transform, width;
    box-shadow: var(--main-shadow);
    z-index: 0;
}
.tab-item {
    position: relative;
    z-index: 1;
    flex: 1;
    padding: 14px;
    text-align: center;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 14px;
    color: var(--main-color);
    transition: color 0.3s ease;
    transform: translateZ(0);
    -webkit-transform: translateZ(0);
}
.tab-item.active {
    color: var(--theme-color);
}
.tab-item:hover {
    color: var(--theme-color);
}

/* Tab 面板切换动画 */
.sponsor-tab-content {
    position: relative;
    min-height: 400px;
    padding-bottom: 40px;
}
.tab-panel {
    display: none;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: transform, opacity;
}
.tab-panel.active {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

/* ==================== 赞助表单布局 ==================== */
.sponsor-main {
    display: grid;
    grid-template-columns: 1fr 360px;
    gap: 30px;
}
@media (max-width: 992px) {
    .sponsor-main {
        grid-template-columns: 1fr;
    }
}

.sponsor-section {
    background: linear-gradient(145deg, rgba(255,255,255,0.04), var(--muted-bg-color), rgba(255,255,255,0.02));
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
    position: relative;
    z-index: 1;
    box-shadow: 0 1px 6px rgba(0,0,0,0.02), inset 0 1px 0 rgba(255,255,255,0.03);
}
.section-title {
    font-weight: 600;
    margin-bottom: 16px;
    font-size: 15px;
    color: var(--main-color);
}
.step-num {
    width: 24px;
    height: 24px;
    line-height: 24px;
    border-radius: 50%;
    background: var(--theme-color);
    color: #fff;
    font-size: 12px;
    text-align: center;
    margin-right: 10px;
    font-weight: bold;
}

/* ==================== 金额选择网格 ==================== */
.sponsor-amount-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}
@media (max-width: 576px) {
    .sponsor-amount-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.amount-card {
    position: relative;
    padding: 18px;
    border-radius: 10px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    background: var(--main-bg-color);
    transform: translateZ(0);
    will-change: transform, background;
    overflow: hidden;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}
.gift-corner-badge {
    position: absolute;
    top: 0;
    right: -8px;
    background: var(--theme-color);
    color: #fff;
    padding: 3px 10px;
    font-size: 10px;
    font-weight: 500;
    border-radius: 0 0 0 10px;
    display: flex;
    align-items: center;
    gap: 3px;
    z-index: 2;
}
.gift-corner-badge i {
    font-size: 11px;
}
.amount-card:hover {
    box-shadow: 0 4px 16px var(--focus-shadow-color);
    transform: translateY(-2px);
}
.amount-card.active {
    background: var(--main-bg-color);
    box-shadow: 0 0 0 2px var(--theme-color), 0 4px 16px var(--focus-shadow-color);
}
.amount-card.active .amount-icon {
    color: var(--theme-color);
}
.amount-icon {
    font-size: 35px;
    color: var(--muted-color);
    margin-bottom: 6px;
    transition: color 0.3s ease;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 6px;
}
.amount-icon svg.icon {
    width: 100%;
    height: 100%;
}
.amount-name {
    font-size: 12px;
    color: var(--muted-color);
    margin-bottom: 4px;
}
.amount-value {
    font-size: 16px;
    font-weight: bold;
    color: var(--main-color);
}
.amount-check {
    position: absolute;
    top: -8px;
    right: -8px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--theme-color);
    color: #fff;
    font-size: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: scale(0);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.amount-card.active .amount-check {
    opacity: 1;
    transform: scale(1);
}

/* 自定义金额 */
.custom-amount {
    background: var(--muted-bg-color);
}
.custom-amount:hover {
    box-shadow: 0 4px 16px var(--focus-shadow-color);
}
.custom-amount .amount-icon {
    color: var(--muted-color);
}
.custom-amount.active .amount-icon {
    color: var(--theme-color);
}
.amount-text {
    font-size: 14px;
    font-weight: 500;
    color: var(--main-color);
    margin-bottom: 4px;
}
.amount-sub {
    font-size: 12px;
    color: var(--muted-color);
}

.custom-input-box {
    margin-top: 12px;
}
.custom-amount-input {
    width: 100%;
    padding: 14px 16px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    text-align: center;
    background: var(--main-bg-color);
    color: var(--main-color);
    transition: box-shadow 0.3s ease;
    transform: translateZ(0);
    box-shadow: inset 0 1px 3px rgba(0,0,0,0.06);
}
.custom-amount-input:focus {
    outline: none;
    box-shadow: 0 0 0 2px var(--theme-color);
}
.custom-amount-input::placeholder {
    color: var(--muted-color);
}

/* ==================== 支付方式 ==================== */
.pay-methods {
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.pay-method-card {
    display: flex;
    align-items: center;
    padding: 18px;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    background: var(--main-bg-color);
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}
.pay-method-card:hover {
    box-shadow: 0 6px 20px var(--focus-shadow-color);
    transform: translateY(-2px);
}
.pay-method-card.active {
    box-shadow: 0 0 0 2px var(--theme-color), 0 6px 20px var(--focus-shadow-color);
}
.pay-method-card img {
    width: 48px;
    height: 48px;
    margin-right: 12px;
    border-radius: 8px;
}
.method-content {
    flex: 1;
}
.method-name {
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 4px;
    color: var(--main-color);
}
.method-badge {
    display: inline-block;
    padding: 2px 8px;
    background: var(--theme-color);
    color: #fff;
    font-size: 11px;
    border-radius: 4px;
    margin-left: 8px;
}
.method-desc {
    font-size: 12px;
    color: var(--muted-color);
}
.method-check {
    margin-left: auto;
    color: var(--theme-color);
    font-size: 18px;
    opacity: 0;
    transform: scale(0);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.pay-method-card.active .method-check {
    opacity: 1;
    transform: scale(1);
}

/* ==================== 赞助清单（右侧） ==================== */
.sponsor-summary {
    background: linear-gradient(160deg, var(--muted-bg-color), rgba(255,255,255,0.02), var(--muted-bg-color));
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 1px 8px rgba(0,0,0,0.03), inset 0 1px 0 rgba(255,255,255,0.04);
}
.sponsor-left {
    display: flex;
    flex-direction: column;
}
.sponsor-right {
    display: flex;
    flex-direction: column;
}
.summary-header {
    padding: 20px;
}
.summary-header h3 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 4px;
    color: var(--main-color);
}
.summary-content {
    padding: 20px;
}
.summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 16px;
}
.summary-row:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
}
.summary-row.total {
    margin-top: 8px;
}
.summary-row .label {
    font-size: 14px;
    color: var(--muted-color);
}
.summary-row .value {
    font-size: 14px;
    font-weight: 500;
    color: var(--main-color);
}
.total-value {
    font-size: 24px;
    color: var(--theme-color);
    font-weight: bold;
}

/* 表单输入（Zibll line-form 风格） */
.sponsor-summary .line-form {
    position: relative;
}
.sponsor-summary .line-form-input {
    width: 100%;
    padding: 12px 14px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    color: var(--main-color);
    background: var(--main-bg-color);
    transition: box-shadow 0.3s ease;
    outline: none;
    box-sizing: border-box;
    box-shadow: inset 0 1px 3px rgba(0,0,0,0.06);
}
.sponsor-summary .line-form-input:focus {
    box-shadow: 0 0 0 2px var(--theme-color);
}
.sponsor-summary .scale-placeholder {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 13px;
    color: var(--muted-color);
    pointer-events: none;
    transition: all 0.3s ease;
}
.sponsor-summary .line-form-input:focus ~ .scale-placeholder,
.sponsor-summary .line-form-input:not(:placeholder-shown) ~ .scale-placeholder {
    top: -8px;
    left: 10px;
    font-size: 11px;
    background: var(--main-bg-color);
    padding: 0 6px;
}

/* 提交按钮 */
.sponsor-submit-btn {
    width: 100%;
    padding: 14px;
    border: none;
    border-radius: 8px;
    background: var(--theme-color);
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.3s ease;
    margin-top: 20px;
}
.sponsor-submit-btn:hover {
    opacity: 0.9;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px var(--focus-shadow-color);
}
.sponsor-submit-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none !important;
    box-shadow: none !important;
}

/* ==================== 统计卡片 ==================== */
.stats-card {
    margin-bottom: 20px;
    padding: 28px;
    background: linear-gradient(145deg, rgba(255,255,255,0.04) 0%, rgba(255,255,255,0.01) 100%);
    border-radius: 16px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.02), inset 0 1px 0 rgba(255,255,255,0.03);
}
.stats-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
    padding-bottom: 16px;
}
.stats-icon {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    background: linear-gradient(135deg, var(--theme-color), rgba(255,71,87,0.6));
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 14px;
}
.stats-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--main-color);
}
.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}
@media (max-width: 768px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
}
.stat-box {
    text-align: center;
    padding: 18px 12px;
    background: rgba(255,255,255,0.01);
    border-radius: 12px;
    transition: all 0.3s ease;
}
.stat-box:hover {
    background: rgba(255,255,255,0.03);
    transform: translateY(-2px);
}
.stat-box.stat-primary {
    background: linear-gradient(145deg, rgba(255,71,87,0.08), rgba(255,71,87,0.03));
}
.stat-box.stat-primary .stat-num {
    color: var(--theme-color);
}
.stat-num {
    font-size: 26px;
    font-weight: 700;
    color: var(--main-color);
    line-height: 1;
    margin-bottom: 6px;
}
.stat-label {
    font-size: 12px;
    color: var(--muted-color);
    font-weight: 500;
    letter-spacing: 0.3px;
}

/* ==================== 榜单区域 ==================== */
.sponsor-ranking-main {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
}
@media (max-width: 992px) {
    .sponsor-ranking-main {
        grid-template-columns: 1fr;
    }
}

.sponsor-goal-left,
.sponsor-ranking-right {
    background: linear-gradient(160deg, rgba(255,255,255,0.04), var(--main-bg-color), rgba(255,255,255,0.02));
    border-radius: 12px;
    padding: 28px;
    position: relative;
    z-index: 1;
    box-shadow: 0 1px 8px rgba(0,0,0,0.03), inset 0 1px 0 rgba(255,255,255,0.04);
}
.goal-header,
.ranking-header {
    margin-bottom: 20px;
    padding-bottom: 16px;
}
.goal-header h3,
.ranking-header h3 {
    font-size: 16px;
    font-weight: 600;
    color: var(--main-color);
    margin-bottom: 6px;
}
.goal-header p,
.ranking-header p {
    font-size: 13px;
    color: var(--muted-color);
}
.goal-list,
.ranking-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* 目标卡片 */
.goal-card {
    background: linear-gradient(145deg, rgba(255,255,255,0.02), var(--muted-bg-color));
    border-radius: 12px;
    padding: 20px;
    transition: all 0.3s ease;
    transform: translateZ(0);
    box-shadow: 0 1px 4px rgba(0,0,0,0.03);
}
.goal-card:hover {
    box-shadow: 0 6px 20px var(--main-shadow);
    transform: translateY(-3px);
}
.goal-card.goal-completed {
    background: linear-gradient(145deg, rgba(76,175,80,0.08), rgba(76,175,80,0.03));
}
.goal-card.goal-completed:hover {
    box-shadow: 0 6px 20px rgba(76,175,80,0.15);
}
.goal-card.goal-completed .goal-amount .current,
.goal-card.goal-completed .goal-percentage {
    color: #4CAF50;
}
.goal-card.goal-completed .progress-fill {
    background: linear-gradient(90deg, #4CAF50, rgba(76,175,80,0.6), #4CAF50);
}
.goal-top-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
}
.goal-left {
    display: flex;
    align-items: center;
    flex: 1;
}
.goal-image {
    width: 100%;
    height: 100%;
    border-radius: 10px;
    object-fit: cover;
    display: block;
}
.goal-placeholder.goal-has-img {
    background: none;
}
.goal-placeholder {
    width: 52px;
    height: 52px;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--theme-color), rgba(255,71,87,0.7));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    color: #fff;
}
.goal-text {
    margin-left: 14px;
}
.goal-text h4 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 5px;
    color: var(--main-color);
    display: flex;
    align-items: center;
    gap: 8px;
}
.completed-tag {
    padding: 2px 8px;
    background: linear-gradient(135deg, #4CAF50, #388E3C);
    color: #fff;
    font-size: 11px;
    font-weight: 600;
    border-radius: 4px;
    box-shadow: 0 2px 4px rgba(76,175,80,0.3);
}
.goal-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 5px;
}
.goal-amount {
    text-align: right;
}
.goal-amount .current {
    font-size: 20px;
    font-weight: 700;
    color: var(--theme-color);
}
.goal-amount .divider {
    margin: 0 4px;
    color: var(--muted-color);
}
.goal-amount .target {
    font-size: 14px;
    color: var(--muted-color);
}
.goal-percentage {
    font-size: 24px;
    font-weight: 700;
    color: var(--theme-color);
    line-height: 1;
}
.goal-progress {
    margin-top: 12px;
}
.progress-bar {
    height: 8px;
    background: var(--body-bg-color);
    border-radius: 4px;
    overflow: hidden;
}
.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--theme-color), rgba(255,71,87,0.5), var(--theme-color));
    border-radius: 4px;
    transition: width 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    background-size: 200% 100%;
    animation: progress-shine 3s ease-in-out infinite;
}
@keyframes progress-shine {
    0%, 100% { background-position: 0 0; }
    50%      { background-position: 100% 0; }
}

/* 空状态 */
.empty-state {
    text-align: center;
    padding: 32px;
    color: var(--muted-color);
}
.empty-icon {
    font-size: 40px;
    margin-bottom: 12px;
    color: var(--muted-color);
}
.empty-state p:first-of-type {
    font-size: 15px;
    color: var(--main-color);
    margin-bottom: 6px;
}
.empty-state p:last-of-type {
    font-size: 13px;
    color: var(--muted-color);
}

/* 排行榜项 */
.ranking-item {
    display: flex;
    align-items: center;
    width: 90%;
    padding: 1px 0;
    transition: all 0.2s ease;
}
.ranking-item:hover {
    opacity: 0.85;
}
.ranking-avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    margin-right: 10px;
    overflow: hidden;
    flex-shrink: 0;
}
.ranking-avatar a {
    display: block;
    width: 100%;
    height: 100%;
    line-height: 0;
}
.ranking-avatar .avatar-img,
.ranking-avatar img.xuwbk-avatar-img,
.ranking-avatar img.avatar-img {
    display: block;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    overflow: hidden;
    object-fit: cover;
}
.ranking-avatar .avatar-img img,
.ranking-avatar img.avatar {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}
.ranking-avatar-placeholder {
    width: 100%;
    height: 100%;
    background: var(--muted-bg-color);
    color: var(--muted-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: bold;
    border-radius: 50%;
}
.ranking-info {
    flex: 1;
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 6px;
}
.ranking-name {
    font-size: 14px;
    font-weight: 500;
    color: var(--main-color);
}
.ranking-message {
    font-size: 12px;
    color: var(--muted-color);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 120px;
}
.ranking-amount {
    font-size: 14px;
    font-weight: 600;
    color: var(--theme-color);
    flex-shrink: 0;
    margin-left: auto;
}

/* ==================== 留言墙 ==================== */
.sponsor-messages {
    margin-top: 24px;
    background: linear-gradient(150deg, rgba(255,255,255,0.04), var(--main-bg-color), rgba(255,255,255,0.02));
    border-radius: 12px;
    padding: 28px;
    box-shadow: 0 1px 8px rgba(0,0,0,0.03), inset 0 1px 0 rgba(255,255,255,0.04);
}
.messages-header {
    margin-bottom: 20px;
    padding-bottom: 16px;
}
.messages-header h3 {
    font-size: 16px;
    font-weight: 600;
    color: var(--main-color);
    margin-bottom: 6px;
}
.messages-header p {
    font-size: 13px;
    color: var(--muted-color);
}
.messages-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}
@media (max-width: 992px) {
    .messages-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 576px) {
    .messages-grid {
        grid-template-columns: 1fr;
    }
}

.message-card {
    background: linear-gradient(145deg, rgba(255,255,255,0.02), var(--muted-bg-color));
    border-radius: 12px;
    padding: 18px;
    transition: all 0.3s ease;
    box-shadow: 0 1px 4px rgba(0,0,0,0.03);
}
.message-card:hover {
    box-shadow: 0 6px 16px var(--main-shadow);
    transform: translateY(-2px);
}
.message-header {
    display: flex;
    align-items: center;
    margin-bottom: 12px;
}
.message-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    overflow: hidden;
    margin-right: 10px;
    flex-shrink: 0;
}
.message-avatar img,
.message-avatar .avatar-img,
.message-avatar .xuwbk-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}
.message-avatar .avatar-placeholder {
    width: 100%;
    height: 100%;
    background: var(--theme-color);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: bold;
}
.message-info {
    flex: 1;
    min-width: 0;
}
.message-name {
    font-size: 13px;
    font-weight: 600;
    color: var(--main-color);
    display: block;
    margin-bottom: 2px;
}
.message-amount {
    font-size: 11px;
    color: var(--theme-color);
    font-weight: 600;
}
.message-date {
    font-size: 11px;
    color: var(--muted-color);
    flex-shrink: 0;
    margin-left: 8px;
}
.message-content {
    font-size: 13px;
    color: var(--main-color);
    line-height: 1.6;
    padding-top: 12px;
}

/* 赠品信息 */
.gift-info-row {
    color: var(--theme-color);
}
.gift-info-value {
    color: var(--theme-color);
}
.gift-custom-preview {
    margin-top: 12px;
    margin-left: 20px;
    margin-right: 20px;
    padding: 12px;
    background: linear-gradient(135deg, rgba(255,193,7,0.1), rgba(255,152,0,0.1));
    border-radius: 8px;
}
.gift-custom-box {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: var(--theme-color);
    font-weight: 600;
}
.gift-custom-box i {
    font-size: 18px;
    animation: gift-pulse 2s infinite;
}
@keyframes gift-pulse {
    0%, 100% { transform: scale(1); }
    50%      { transform: scale(1.2); }
}

/* ==================== 回馈详情区（四种类型独立展示） ==================== */
.gift-detail-section {
    margin: 16px 20px 0 20px;
    padding: 0;
    border-radius: 12px;
    background: linear-gradient(145deg, rgba(255,255,255,0.04), rgba(255,255,255,0.01));
    overflow: hidden;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,0.03);
}
.gift-detail-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 14px 16px 12px 16px;
    font-size: 13px;
    font-weight: 600;
    color: var(--main-color);
    background: linear-gradient(135deg, rgba(255,193,7,0.08), rgba(255,152,0,0.04));
    border-bottom: 1px solid rgba(255,255,255,0.04);
}
.gift-detail-header i {
    color: var(--theme-color);
    font-size: 14px;
}
.gift-detail-list {
    padding: 8px 0;
}
.gift-detail-item {
    display: flex;
    align-items: center;
    padding: 10px 16px;
    gap: 10px;
    font-size: 13px;
    color: var(--main-color);
    transition: background 0.2s ease;
}
.gift-detail-item:hover {
    background: rgba(255,255,255,0.02);
}
.gift-detail-icon {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    border-radius: 8px;
    flex-shrink: 0;
}
.gift-detail-item.gift-detail-physical .gift-detail-icon { background: rgba(255,152,0,0.12); }
.gift-detail-item.gift-detail-points .gift-detail-icon   { background: rgba(255,193,7,0.12); }
.gift-detail-item.gift-detail-vip .gift-detail-icon      { background: rgba(156,39,176,0.12); }
.gift-detail-item.gift-detail-balance .gift-detail-icon  { background: rgba(76,175,80,0.12); }
.gift-detail-label {
    flex: 1;
    color: var(--muted-color);
    font-size: 12px;
}
.gift-detail-value {
    font-weight: 600;
    color: var(--theme-color);
    font-size: 14px;
}
.gift-detail-item.gift-detail-physical .gift-detail-value { color: #FF9800; }
.gift-detail-item.gift-detail-points .gift-detail-value   { color: #FFC107; }
.gift-detail-item.gift-detail-vip .gift-detail-value      { color: #9C27B0; }
.gift-detail-item.gift-detail-balance .gift-detail-value  { color: #4CAF50; }

.gift-empty-preview {
    margin: 16px 20px 0 20px;
    padding: 14px;
    background: linear-gradient(145deg, rgba(255,255,255,0.02), rgba(255,255,255,0.005));
    border-radius: 8px;
    text-align: center;
}
.gift-empty-preview .gift-custom-box {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: var(--muted-color);
    font-weight: 500;
    font-size: 13px;
}
.gift-empty-preview .gift-custom-box i {
    font-size: 16px;
    animation: gift-pulse 2s infinite;
    color: var(--muted-color);
}

/* ==================== 小屏幕适配 ==================== */
@media (max-width: 768px) {
    .sponsor-header {
        padding: 30px 16px;
    }
    .sponsor-title {
        font-size: 24px;
    }
    .sponsor-description {
        font-size: 13px;
    }
    .sponsor-main {
        grid-template-columns: 1fr;
    }
    .sponsor-right {
        order: -1;
    }
    .stats-grid {
        grid-template-columns: 1fr;
    }
    .sponsor-ranking-main {
        grid-template-columns: 1fr;
    }
    .messages-grid {
        grid-template-columns: 1fr;
    }
}

/* ==================== 用户头像纯组件 ==================== */
.xuwbk-avatar-img {
    display: inline-block;
    vertical-align: middle;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    transition: opacity 0.3s ease;
}
.xuwbk-avatar-img.xuwbk-avatar-placeholder {
    opacity: 0.65;
    background: var(--muted-3-color, #e8eaed);
}
.xuwbk-avatar-wrap {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

/* 响应式 */
@media (max-width: 768px) {
    .xuwbk-avatar-img { 
        max-width: 100%; 
        height: auto; 
    }
}

/* ==================== 通用工具类 ==================== */
.flex { display: flex; }
.ac   { align-items: center; }
.mt10 { margin-top: 1px; }
.mt20 { margin-top: 20px; }
.mb6  { margin-bottom: 6px; }
.mb10 { margin-bottom: 10px; }
.mb20 { margin-bottom: 20px; }
.mb40 { margin-bottom: 40px; }
.muted-2-color { color: var(--muted-color); }
.text-center { text-align: center; }
.relative { position: relative; }

/* ==================== 旧版兼容样式 ==================== */
.xuwbk-donate-wrapper {
    max-width: 100%;
    margin: 0 auto;
}
