/* ==================== 赞助鸣谢页面样式 ==================== */

/* --- 全局动画定义 --- */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes fadeInUp {
    from { 
        opacity: 0; 
        transform: translateY(40px); 
    }
    to { 
        opacity: 1; 
        transform: translateY(0); 
    }
}

@keyframes shimmer {
    0% { transform: translateX(-100%) skewX(-20deg); }
    100% { transform: translateX(200%) skewX(-20deg); }
}

@keyframes slideDown {
    from {
        opacity: 0;
        max-height: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        max-height: 500px;
        transform: translateY(0);
    }
}

@keyframes slideUp {
    from {
        opacity: 1;
        max-height: 500px;
        transform: translateY(0);
    }
    to {
        opacity: 0;
        max-height: 0;
        transform: translateY(-10px);
    }
}

@keyframes sandstorm {
    from { transform: translateX(0); }
    to { transform: translateX(-50%); }
}

/* --- 页面背景特效 --- */
body::before,
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 200%;
    height: 100%;
    z-index: -1;
    background-image: repeating-radial-gradient(
        circle at center, 
        rgba(255, 215, 0, 0.15) 0, 
        rgba(255, 215, 0, 0.1) 1px, 
        transparent 2px, 
        transparent 100px
    );
    background-size: 2500px 2500px;
    animation-name: sandstorm;
    animation-timing-function: linear;
    animation-iteration-count: infinite;
}

body::before {
    opacity: 0.4;
    animation-duration: 15s;
}

body::after {
    opacity: 0.2;
    animation-duration: 25s;
    background-image: repeating-radial-gradient(
        circle at center, 
        rgba(200, 180, 140, 0.1) 0, 
        rgba(200, 180, 140, 0.08) 1px, 
        transparent 2px, 
        transparent 80px
    );
    background-size: 2000px 2000px;
}

/* --- 页面介绍与分隔符 --- */
.page-intro {
    max-width: 700px;
    margin: 0 auto 3rem auto;
    text-align: center;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.9);
}

.section-divider {
    width: 100px;
    height: 3px;
    background: var(--gold-primary);
    margin: 2.5rem auto;
    border-radius: 2px;
    opacity: 0.5;
}

/* --- 前三排行区域 --- */
.podium-section-wrapper {
    display: flex;
    justify-content: center;
    align-items: flex-end;
    gap: 1rem;
    min-height: 300px;
    padding-top: 60px;
    padding-bottom: 2rem;
}

/* --- 前三排行卡片基础样式 --- */
.podium-card {
    position: relative;
    width: 280px;
    padding: 2rem 1.5rem 1.5rem;
    border-radius: 16px;
    background: rgba(40, 35, 30, 0.6);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    text-align: center;
    transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
    overflow: hidden;
    animation: fadeInUp 0.8s backwards;
    cursor: pointer;
}

.podium-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 50%;
    height: 100%;
    background: linear-gradient(
        to right, 
        rgba(255,255,255,0) 0%, 
        rgba(255,255,255,0.15) 50%, 
        rgba(255,255,255,0) 100%
    );
    animation: shimmer 4s infinite linear;
    opacity: 0.8;
}

.podium-card .crown {
    position: absolute;
    top: 0px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 60px;
    line-height: 1;
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.5));
    transition: transform 0.4s ease;
}

.podium-card:hover .crown {
    transform: translateX(-50%) scale(1.1) rotate(-5deg);
}

.podium-card .name {
    margin-top: 2rem;
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text-primary);
}

.podium-card .amount {
    font-size: 2.2rem;
    font-weight: bold;
    margin: 0.5rem 0 1rem 0;
}

.podium-card .amount span {
    font-size: 1.2rem;
    margin-right: 5px;
}

.podium-card .details {
    font-size: 0.85rem;
    color: var(--text-secondary);
    opacity: 0.8;
}

/* 展开按钮样式 */
.expand-btn {
    margin-top: 0.5rem;
    padding: 0.3rem 1rem;
    background: rgba(255, 215, 0, 0.1);
    border: 1px solid var(--gold-primary);
    border-radius: 20px;
    color: var(--gold-primary);
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-block;
}

.expand-btn:hover {
    background: rgba(255, 215, 0, 0.2);
    transform: scale(1.05);
}

/* 详情表格样式 */
.details-table {
    margin-top: 1rem;
    width: 100%;
    border-collapse: collapse;
    background: rgba(20, 15, 10, 0.8);
    border-radius: 8px;
    overflow: hidden;
    animation: slideDown 0.4s ease;
    opacity: 0;
    max-height: 0;
    overflow: hidden;
    transition: all 0.4s ease;
}

.details-table.show {
    opacity: 1;
    max-height: 500px;
}

.details-table th,
.details-table td {
    padding: 0.5rem;
    text-align: left;
    border-bottom: 1px solid rgba(255, 215, 0, 0.2);
    font-size: 0.75rem;
}

.details-table th {
    background: rgba(255, 215, 0, 0.1);
    color: var(--gold-primary);
    font-weight: 600;
}

.details-table td {
    color: var(--text-secondary);
}

/* --- 冠军 (Rank 1) --- */
.podium-card.rank-1 {
    order: 2;
    width: 320px;
    transform: translateY(-30px);
    border: 3px solid var(--gold-primary);
    box-shadow: 0 0 25px var(--gold-primary), 0 10px 40px rgba(0,0,0,0.6);
    z-index: 10;
    animation-delay: 0.2s;
}

.podium-card.rank-1 .amount { 
    color: var(--gold-primary); 
}

.podium-card.rank-1:hover { 
    transform: translateY(-45px) scale(1.05); 
}

/* --- 亚军 (Rank 2) --- */
.podium-card.rank-2 {
    order: 1;
    border: 2px solid #C0C0C0;
    box-shadow: 0 0 15px rgba(192,192,192,0.5), 0 5px 20px rgba(0,0,0,0.4);
    animation-delay: 0s;
}

.podium-card.rank-2 .amount { 
    color: #EAEAEA; 
}

.podium-card.rank-2:hover { 
    transform: translateY(-15px) scale(1.03); 
}

/* --- 季军 (Rank 3) --- */
.podium-card.rank-3 {
    order: 3;
    border: 2px solid #CD7F32;
    box-shadow: 0 0 15px rgba(205,127,50,0.5), 0 5px 20px rgba(0,0,0,0.4);
    animation-delay: 0.4s;
}

.podium-card.rank-3 .amount { 
    color: #FFB06B; 
}

.podium-card.rank-3:hover { 
    transform: translateY(-15px) scale(1.03); 
}

/* --- 光荣骑士团列表 (Ranks 4+) --- */
.main-list-section {
    max-width: 800px;
    margin: 0 auto;
}

.list-item {
    display: flex;
    align-items: center;
    padding: 1rem 1.5rem;
    margin-bottom: 0.5rem;
    background: rgba(30, 25, 20, 0.8);
    border-radius: 8px;
    border-left: 4px solid var(--border-gold);
    transition: all 0.3s ease;
    opacity: 0;
    animation: fadeInUp 0.5s forwards;
    cursor: pointer;
    position: relative;
}

.list-item:hover {
    background: rgba(45, 40, 35, 0.9);
    border-left-color: var(--gold-primary);
    transform: translateX(10px);
}

.list-item .rank {
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--text-secondary);
    width: 50px;
    flex-shrink: 0;
}

.list-item .name {
    flex-grow: 1;
    font-size: 1.1rem;
    color: var(--text-primary);
    margin-right: 2rem;
}

.list-item .amount {
    font-weight: bold;
    color: var(--gold-secondary);
    min-width: 100px;
    text-align: right;
    flex-shrink: 0;
}

/* 列表项详情样式 */
.list-item-details {
    width: 100%;
    margin-top: 1rem;
    background: rgba(20, 15, 10, 0.9);
    border-radius: 8px;
    overflow: hidden;
    max-height: 0;
    opacity: 0;
    transition: all 0.4s ease;
}

.list-item-details.show {
    max-height: 400px;
    opacity: 1;
}

.list-item-wrapper {
    display: flex;
    flex-direction: column;
}

.list-item-content {
    display: flex;
    align-items: center;
    width: 100%;
}

/* 列表项详情表格样式 */
.list-item-details table {
    width: 100%;
    border-collapse: collapse;
    margin: 0;
}

.list-item-details th,
.list-item-details td {
    padding: 0.5rem;
    text-align: left;
    border-bottom: 1px solid rgba(255, 215, 0, 0.2);
    font-size: 0.75rem;
}

.list-item-details th {
    background: rgba(255, 215, 0, 0.1);
    color: var(--gold-primary);
    font-weight: 600;
}

.list-item-details td {
    color: var(--text-secondary);
}

/* --- 无赞助信息时的占位符样式 --- */
.no-sponsors-message {
    text-align: center;
    color: var(--text-secondary);
    padding: 4rem 2rem;
    font-size: 1.2rem;
    background: rgba(30, 25, 20, 0.8);
    border: 2px dashed var(--border-gold);
    border-radius: 12px;
    animation: fadeIn 1s;
}

/* 展开指示器 */
.expand-indicator {
    margin-left: 0.5rem;
    color: var(--gold-secondary);
    font-size: 0.8rem;
    transition: transform 0.3s ease;
    flex-shrink: 0;
}

.expand-indicator.expanded {
    transform: rotate(180deg);
}

/* --- 二维码区域样式 --- */
.qrcode-section {
    max-width: 800px;
    margin: 3rem auto;
    text-align: center;
    animation: fadeInUp 0.8s ease forwards;
}

.qrcode-container {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
    padding: 0 1rem;
}

.qrcode-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    background: rgba(40, 35, 30, 0.7);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 16px;
    padding: 1.5rem;
    min-width: 180px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 215, 0, 0.2);
    transition: all 0.3s ease;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.6s ease forwards;
}

.qrcode-box:nth-child(1) {
    animation-delay: 0.1s;
}

.qrcode-box:nth-child(2) {
    animation-delay: 0.3s;
}

.qrcode-box:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 30px rgba(255, 215, 0, 0.3),
                0 10px 40px rgba(0, 0, 0, 0.6);
    border-color: var(--gold-primary);
    opacity: 1;
}

.qrcode-title {
    font-size: 1rem;
    font-weight: bold;
    color: var(--gold-primary);
    margin-bottom: 0.8rem;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8);
}

.qrcode-image {
    width: 240px;
    height: 240px;
    border-radius: 12px;
    border: 1px solid rgba(255, 215, 0, 0.3);
    box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.5);
    transition: all 0.3s ease;
    object-fit: cover;
}

.qrcode-box:hover .qrcode-image {
    transform: scale(1.05);
}

/* 表格说明文字 */
.table-description {
    text-align: center;
    margin-top: 3rem;
}

.table-description a {
    color: var(--gold-secondary);
}

.table-description a:hover {
    color: var(--gold-primary);
    text-decoration: underline;
}

/* ==================== 响应式设计 ==================== */

@media (max-width: 768px) {
    .podium-section-wrapper {
        flex-direction: column;
        align-items: center;
        padding-top: 2rem;
        gap: 2rem;
    }

    .podium-card {
        width: 100% !important;
        max-width: 320px;
        transform: translateY(0) !important;
    }

    .podium-card.rank-1,
    .podium-card.rank-2,
    .podium-card.rank-3 {
        order: initial;
    }

    .podium-card:hover {
        transform: translateY(-10px) !important;
    }

    .list-item {
        flex-wrap: wrap;
        padding: 1rem;
    }

    .list-item .rank {
        width: auto;
        margin-right: 1rem;
    }

    .list-item .name {
        margin-right: auto;
    }

    .list-item .amount {
        width: 100%;
        text-align: left;
        margin-top: 0.5rem;
        padding-left: calc(1.2rem + 1rem);
    }

    .expand-indicator {
        position: absolute;
        right: 1rem;
        top: 1rem;
    }

    .qrcode-container {
        flex-direction: column;
        gap: 1.5rem;
    }

    .qrcode-box {
        width: 100%;
        max-width: 220px;
        margin: 0 auto;
    }

    .page-intro {
        padding: 0 1rem;
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .podium-card .name {
        font-size: 1.2rem;
    }

    .podium-card .amount {
        font-size: 1.8rem;
    }

    .list-item .rank {
        font-size: 1rem;
    }

    .list-item .name {
        font-size: 1rem;
    }

    .qrcode-image {
        width: 200px;
        height: 200px;
    }
}
