/* ===== 返回按鈕 ===== */
.back-bar {
    max-width: 1100px;
    margin: 16px auto 16px;
    padding: 0 20px;
}

.back-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 18px;
    background: rgba(255, 255, 255, 0.06);
    color: #b0a8b8;
    text-decoration: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s;
    border: 1px solid rgba(255, 255, 255, 0.04);
}

.back-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

/* ===== 主內容 ===== */
#main {
    max-width: 1100px;
    margin: 0 auto 40px;
    padding: 0 20px;
}

.game-title {
    font-weight: 400;
    margin: 0;
    font-size: 28px;
    color: #f0e0f4;
}

.game-title.english {
    font-style: italic;
    opacity: 0.4;
    font-weight: 300;
    font-size: 18px;
    margin-top: -2px;
}

/* ===== 頂部：幻燈片 + 資訊 ===== */
.game-header {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    margin: 16px 0 24px 0;
}

/* ===== 幻燈片 ===== */
.game-header .slideshow {
    flex: 2;
    min-width: 300px;
    aspect-ratio: 16 / 9;
    background: #221a2c;
    border-radius: 6px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.04);
    position: relative;
}

.game-header .slideshow .slide-container {
    width: 100%;
    height: 100%;
    position: relative;
}

.game-header .slideshow .slide-container .slide {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: none;
}

.game-header .slideshow .slide-container .slide.active {
    display: block;
}

.slideshow .slide-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: #fff;
    border: none;
    padding: 10px 14px;
    cursor: pointer;
    font-size: 18px;
    border-radius: 4px;
    transition: background 0.2s;
    z-index: 2;
}

.slideshow .slide-btn:hover {
    background: rgba(0, 0, 0, 0.8);
}

.slideshow .slide-btn.prev {
    left: 10px;
}

.slideshow .slide-btn.next {
    right: 10px;
}

.slideshow .dots {
    position: absolute;
    bottom: 12px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 2;
}

.slideshow .dots .dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    cursor: pointer;
    transition: background 0.2s;
    border: none;
}

.slideshow .dots .dot.active {
    background: #fff;
}

/* ===== 基本資訊區塊 ===== */
.game-header .game-info-side {
    flex: 1;
    min-width: 200px;
    max-width: 320px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* ===== 基本資訊 ===== */
.info-list {
    background: #221a2c;
    border: 1px solid rgba(255, 255, 255, 0.04);
    overflow: hidden;
}

.info-list .info-item {
    display: flex;
    justify-content: space-between;
    align-items: start;
    padding: 8px 14px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}

.info-list .info-item:last-child {
    border-bottom: none;
}

.info-list .info-item .label {
    font-size: 13px;
    color: #9c88a6;
    letter-spacing: 0.3px;
}

.info-list .info-item .value {
    font-size: 14px;
    font-weight: 300;
    max-width: 60%;
    color: #f0e0f4;
    text-align: right;
}

/* ===== 標籤（Steam風格） ===== */
.tag-section {
    background: #221a2c;
    border: 1px solid rgba(255, 255, 255, 0.04);
    padding: 12px 14px;
}

.tag-section .tag-label {
    font-size: 13px;
    color: #9c88a6;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}

.tag-section .tag-group {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.tag-section .tag-group .tag {
    padding: 2px 12px;
    background: rgba(255, 255, 255, 0.06);
    color: #b0a8b8;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 400;
    letter-spacing: 0.3px;
}

/* ===== 下部分兩欄 ===== */
.game-body {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    margin-top: 8px;
}

.game-body .left-col {
    flex: 2;
    min-width: 280px;
}

.game-body .right-col {
    flex: 1;
    min-width: 200px;
    max-width: 320px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* ===== 內容區塊 ===== */
.content-section {
    background: #221a2c;
    padding: 22px 24px;
    margin-bottom: 16px;
    border: 1px solid rgba(255, 255, 255, 0.04);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.3);
}

.content-section:last-child {
    margin-bottom: 0;
}

.content-section h3 {
    font-size: 17px;
    font-weight: 400;
    color: #f0e0f4;
    margin-bottom: 10px;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.content-section h3::after {
    content: '';
    flex: 1;
    height: 1px;
    background: rgba(255, 255, 255, 0.04);
}

.content-section p {
    font-size: 15px;
    font-weight: 300;
    line-height: 1.4;
    color: #c0b8c8;
    margin-bottom: 6px;
}

.content-section ul {
    padding-left: 18px;
    color: #c0b8c8;
    font-size: 14px;
    line-height: 1.8;
}

.content-section ul li {
    margin-bottom: 3px;
}

/* ===== 語言區塊（Steam風格） ===== */
.language-section {
    background: #221a2c;
    border: 1px solid rgba(255, 255, 255, 0.04);
    padding: 12px 14px;
}

.language-section .lang-label {
    font-size: 13px;
    color: #9c88a6;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}

.language-section .lang-group {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.language-section .lang-group .lang {
    padding: 2px 12px;
    background: rgba(255, 255, 255, 0.06);
    color: #b0a8b8;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 400;
    letter-spacing: 0.3px;
}

.language-section .lang-group .lang.full {
    background: rgba(50, 180, 120, 0.15);
    color: #70d0a0;
}


/* ===== 成就系統 ===== */
.achievement-wrapper {
    margin-bottom: 6px;
}

.achievement-item {
    display: block;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 4px;
    border: 1px solid rgba(255, 255, 255, 0.03);
    cursor: pointer;
    user-select: none;
    transition: all 0.3s ease;
    overflow: hidden;
}

.achievement-item:hover {
    background: rgba(255, 255, 255, 0.05);
}

.achievement-item .achievement-main {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 12px;
}

.achievement-item .icon {
    width: 36px;
    height: 36px;
    flex-shrink: 0;
}

.achievement-item .info {
    flex: 1;
}

.achievement-item .info .name {
    font-size: 14px;
    font-weight: 500;
    color: #f0e0f4;
}

.achievement-item .info .desc {
    font-size: 12px;
    color: #8a7a92;
}

/* ===== 環圈圖 ===== */
.achievement-stats {
    flex-shrink: 0;
    margin-left: 4px;
}

.progress-ring {
    position: relative;
    width: 36px;
    height: 36px;
}

.progress-ring svg {
    transform: rotate(-90deg);
    width: 36px;
    height: 36px;
}

.progress-ring .ring-bg {
    fill: none;
    stroke: rgba(255, 255, 255, 0.08);
    stroke-width: 3;
}

.progress-ring .ring-fg {
    fill: none;
    stroke: #70d0a0;
    stroke-width: 3;
    stroke-linecap: round;
    transition: stroke-dashoffset 0.6s ease;
}

.progress-ring .ring-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 9px;
    font-weight: 600;
    color: #c0b8c8;
    letter-spacing: 0.3px;
}

/* ===== 展開區域（在區塊內部） ===== */
.achievement-item .achievement-expand {
    display: flex;
    justify-content: center;
    align-items: center;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease, padding 0.35s ease, opacity 0.3s ease;
    opacity: 0;
}

.achievement-item.open .achievement-expand {
    display: flex;
    justify-content: center;
    align-items: center;
    max-height: 60px;
    padding: 5px 0;
    opacity: 1;
}

.achievement-item .achievement-expand .expand-text {
    font-size: 13px;
    color: #8a7a92;
    letter-spacing: 0.3px;
}

/* 展開時邊框微微發光 */
.achievement-item.open {
    border-color: rgba(112, 208, 160, 0.2);
    box-shadow: 0 0 20px rgba(112, 208, 160, 0.04);
}

/* ===== 注意事項 ===== */
.notice-box {
    background: rgba(200, 80, 50, 0.06);
    border-left: 3px solid #c0392b;
    padding: 12px 16px;
}

.notice-box h4 {
    font-size: 13px;
    font-weight: 600;
    color: #e08070;
    margin-bottom: 4px;
}

.notice-box p {
    font-size: 13px;
    color: #b0a0a8;
    margin-bottom: 4px;
    line-height: 1.3;
}

.notice-box ul {
    margin: 0;
    padding-left: 16px;
    font-size: 13px;
    color: #b0a0a8;
    line-height: 1.8;
}

.notice-box ul li {
    margin-bottom: 1px;
}

.notice-box .notice-footer {
    font-size: 12px;
    color: #8a7a82;
    margin-top: 6px;
    font-style: italic;
}

/* ===== 排行榜表格 ===== */
.ranking-table-wrap {
    overflow-x: auto;
    margin: 4px 0;
}

.ranking-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

.ranking-table thead th {
    background: rgba(255, 255, 255, 0.03);
    color: #b3a3bb;
    padding: 8px 12px;
    text-align: left;
    font-weight: 500;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.ranking-table tbody td {
    padding: 8px 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    color: #c0b8c8;
}

.ranking-table tbody tr:hover td {
    background: rgba(255, 255, 255, 0.02);
}


/* ===== 響應式 ===== */
@media screen and (max-width: 820px) {
    .game-header {
        flex-direction: column;
    }

    .game-header .slideshow {
        flex: 1;
        width: 100%;
        min-width: 0;
        aspect-ratio: 16 / 9;
    }

    .game-header .game-info-side {
        flex: 1;
        max-width: 100%;
        min-width: 0;
    }

    .game-body {
        flex-direction: column;
    }

    .game-body .left-col,
    .game-body .right-col {
        flex: 1;
        min-width: 0;
        max-width: 100%;
    }

    .game-title {
        font-size: 24px;
    }

    .content-section {
        padding: 18px 18px;
    }

    .info-list .info-item {
        padding: 8px 14px;
    }
}

@media screen and (max-width: 480px) {
    #main {
        padding: 0 12px;
    }

    .game-title {
        font-size: 20px;
    }

    .game-title.english {
        font-size: 15px;
    }

    .game-header .slideshow {
        aspect-ratio: 16 / 9;
    }

    .content-section {
        padding: 14px 14px;
    }

    .content-section h3 {
        font-size: 15px;
    }

    .content-section p {
        font-size: 14px;
    }

    .achievement-item {
        padding: 6px 10px;
    }

    .back-btn {
        font-size: 13px;
        padding: 6px 14px;
    }

    .info-list .info-item {
        padding: 6px 12px;
        flex-wrap: wrap;
    }

    .info-list .info-item .label {
        font-size: 12px;
    }

    .info-list .info-item .value {
        font-size: 13px;
    }

    .slideshow .slide-btn {
        padding: 6px 10px;
        font-size: 14px;
    }

    .slideshow .dots .dot {
        width: 8px;
        height: 8px;
    }
}

@media screen and (max-width: 360px) {
    .tag-section .tag-group .tag {
        font-size: 11px;
        padding: 1px 10px;
    }

    .language-section .lang-group .lang {
        font-size: 11px;
        padding: 1px 10px;
    }
}