/**
 * 打赏插件样式 - 简化版
 * 尽可能使用子比主题自带的样式类和变量
 */

/* 打赏页面渐变背景 */
.zanzhu-page {
    position: relative;
}

.zanzhu-page::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 450px;
    background-image: linear-gradient(180deg, var(--zanzhu-theme, var(--theme-color)) 0%, transparent 100%);
    z-index: 0;
    pointer-events: none;
}

/* 固定导航栏适配 */
body.nav-fixed.zanzhu-page-body {
    padding-top: 70px !important;
}

/* 页面头部 */
.zanzhu-header {
    position: relative;
    text-align: center;
    padding: 60px 20px 100px;
    margin-bottom: -80px;
    z-index: 1;
}

.zanzhu-header-content {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.zanzhu-title {
    font-size: 28px;
    color: #fff;
    font-weight: 700;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    word-break: break-word;
    max-width: 100%;
}

.zanzhu-header-img {
    width: 180px;
    max-width: 100%;
    margin-top: 15px;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.1));
    display: block;
}

/* 二维码区域 */
.zanzhu-qrcode {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin: 0 auto 30px;
    flex-wrap: wrap;
    position: relative;
    z-index: 1;
}

.zanzhu-qrcode::after {
    content: "REWARDS";
    position: absolute;
    top: 40%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 100px;
    font-weight: 700;
    color: transparent;
    -webkit-text-stroke: 3px #c28b00;
    opacity: 0.08;
    z-index: -1;
    pointer-events: none;
    letter-spacing: 8px;
}

.zanzhu-qrcode-item {
    text-align: center;
}

.zanzhu-qrcode-item img {
    border-radius: var(--main-radius);
    padding: 8px;
    border: 1px solid var(--main-border-color);
    background: var(--main-bg-color);
    transition: transform 0.3s ease;
}

.zanzhu-qrcode-item img:hover {
    transform: translateY(-5px);
}

.zanzhu-qrcode-text {
    margin-top: 10px;
    color: var(--muted-color);
    font-size: 14px;
}

/* 控制区域 - 使用子比主题样式 */
.zanzhu-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    max-width: 800px;
    margin: 0 auto 20px;
    position: relative;
    z-index: 1;
}

.zanzhu-sort-select {
    padding: 8px 12px;
    border: 1px solid var(--main-border-color);
    background: var(--main-bg-color);
    color: var(--main-color);
    border-radius: var(--main-radius);
    cursor: pointer;
}

.zanzhu-sort-select:hover {
    border-color: var(--zanzhu-theme, var(--theme-color));
}

.zanzhu-controls-tips {
    color: var(--muted-color);
    font-size: 18px;
}

/* 赞助列表 - 使用子比主题box样式 */
.zanzhu-reward-list {
    max-width: 800px;
    margin: 0 auto;
    padding: 16px;
    background: var(--main-bg-color);
    border-radius: var(--main-radius);
    
    position: relative;
    z-index: 1;
}

/* 表格样式 */
.zanzhu-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    border-radius: var(--main-radius);
    overflow: hidden;
}

.zanzhu-table thead {
    background: var(--muted-bg-color);
}

.zanzhu-table th {
    padding: 12px 15px;
    text-align: left;
    font-weight: 500;
    color: var(--muted-color);
    font-size: 14px;
}

.zanzhu-table th:first-child {
    border-top-left-radius: var(--main-radius);
}

.zanzhu-table th:last-child {
    border-top-right-radius: var(--main-radius);
}

.zanzhu-table th.zanzhu-th-amount,
.zanzhu-table th.zanzhu-th-date {
    text-align: center;
    width: 100px;
}

.zanzhu-table td {
    padding: 14px 15px;
    font-size: 14px;
    color: var(--main-color);
    border-bottom: 1px solid var(--main-border-color);
}

.zanzhu-row:last-child td {
    border-bottom: none;
}

.zanzhu-td-name {
    font-weight: 500;
}

.zanzhu-td-name a {
    color: inherit;
    text-decoration: none;
    pointer-events: none;
}

.zanzhu-td-amount,
.zanzhu-td-date {
    text-align: center;
}

.zanzhu-td-date {
    color: var(--muted-color);
}

/* 高亮行 - 根据金额区间 */
.zanzhu-highlight-50 {
    background-color: var(--zanzhu-highlight-50);
}

.zanzhu-highlight-100 {
    background-color: var(--zanzhu-highlight-100);
}

.zanzhu-highlight-100-plus {
    background-color: var(--zanzhu-highlight-100-plus);
}

/* 可点击行样式 - 简化版 */
.zanzhu-row-clickable {
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.zanzhu-row-clickable:hover {
    background-color: var(--muted-bg-color);
}

/* 分页 - 使用子比主题按钮样式 */
.zanzhu-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin-top: 20px;
}

.zanzhu-pagination button {
    padding: 6px 16px;
    background: var(--main-bg-color);
    color: var(--main-color);
    border: 1px solid var(--main-border-color);
    border-radius: var(--main-radius);
    cursor: pointer;
    transition: all 0.3s ease;
}

.zanzhu-pagination button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.zanzhu-pagination button:hover:not(:disabled) {
    border-color: var(--zanzhu-theme, var(--theme-color));
    color: var(--zanzhu-theme, var(--theme-color));
}

/* 底部提示 */
.zanzhu-btm-tips {
    max-width: 800px;
    margin: 20px auto;
    text-align: center;
    font-size: 14px;
    color: var(--muted-color);
    background: var(--main-bg-color);
    border: 1px solid var(--main-border-color);
    border-radius: var(--main-radius);
    padding: 12px;
}

.zanzhu-btm-tips-text {
    display: block;
    margin: 4px 0;
}

/* 小工具样式 */
.mb20:has(.zanzhu-widget-new) {
    background: var(--main-bg-color);
    padding: 15px;
    box-shadow: 0 0 10px var(--main-shadow);
    border-radius: var(--main-radius);
}

.zanzhu-widget-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--main-border-color);
}

.zanzhu-widget-title-wrap i {
    color: var(--zanzhu-theme, var(--theme-color));
    margin-right: 6px;
}

.zanzhu-widget-title {
    font-weight: 600;
    font-size: 15px;
}

.zanzhu-widget-link {
    color: var(--muted-color);
    font-size: 13px;
    text-decoration: none;
}

.zanzhu-widget-link:hover {
    color: var(--zanzhu-theme, var(--theme-color));
}

/* 特色赞助者 */
.zanzhu-featured {
    display: flex;
    gap: 12px;
    padding: 12px;
    background: var(--muted-bg-color);
    border-radius: var(--main-radius);
    margin-bottom: 12px;
}

.zanzhu-featured-link {
    text-decoration: none;
    transition: all 0.3s ease;
}

.zanzhu-featured-link:hover {
    background: var(--zanzhu-theme, var(--theme-color));
}

.zanzhu-featured-link:hover .zanzhu-featured-name,
.zanzhu-featured-link:hover .zanzhu-featured-message {
    color: #fff;
}

.zanzhu-featured-link:hover .zanzhu-featured-avatar {
    transform: scale(0.9);
    border-color: #fff;
}

.zanzhu-featured-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: 600;
    font-size: 18px;
    flex-shrink: 0;
    transition: all 0.3s ease;
    border: 3px solid transparent;
}

.zanzhu-featured-info {
    flex: 1;
    min-width: 0;
}

.zanzhu-featured-name {
    font-weight: 600;
    font-size: 15px;
    color: var(--main-color);
    margin-bottom: 4px;
    transition: color 0.3s ease;
}

.zanzhu-featured-message {
    font-size: 13px;
    color: var(--muted-color);
    line-height: 1.5;
    word-break: break-word;
    transition: color 0.3s ease;
}

/* 简单列表 */
.zanzhu-list-simple {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.zanzhu-simple-item {
    padding: 4px 10px;
    background: var(--muted-bg-color);
    border-radius: 4px;
    font-size: 13px;
    color: var(--main-color);
    text-decoration: none;
    transition: all 0.2s ease;
}

.zanzhu-simple-item:hover {
    background: var(--zanzhu-theme, var(--theme-color));
    color: #fff;
}

/* 响应式 */
@media (max-width: 768px) {
    .zanzhu-header {
        padding: 40px 15px 80px;
    }
    
    .zanzhu-title {
        font-size: 20px;
        line-height: 1.4;
    }
    
    .zanzhu-header-img {
        width: 120px;
    }
    
    .zanzhu-qrcode {
        gap: 20px;
    }
    
    .zanzhu-qrcode-item img {
        width: 120px;
        height: 120px;
    }
    
    .zanzhu-qrcode::after {
        font-size: 60px;
    }
    
    .zanzhu-controls {
        flex-direction: column;
        align-items: stretch;
    }
    
    .zanzhu-table th,
    .zanzhu-table td {
        padding: 10px 8px;
        font-size: 13px;
    }
}
