/* game6.css - 詩陣侵略 (Poetry Invaders) */

.game6-overlay {
    position: fixed;
    top: 0;
    left: 0;
    margin: 0;
    background: radial-gradient(circle at center, hsl(210, 30%, 25%) 0%, hsl(0, 0%, 5%) 100%);
    color: hsl(40, 50%, 80%);
    font-family: 'Noto Serif TC', serif;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    z-index: 1000;
}

.game6-header {
    padding: 2px 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(0, 0, 0, 0.4);
    z-index: 10;
    width: 100%;
    height: 50px;
}

.game6-score-board {
    color: hsl(50, 70%, 60%);
    font-size: 24px;
    font-weight: bold;
    padding-left: 50px;
}

/*控制按鈕*/
.game6-controls {
    display: flex;
    gap: 10px;
}

/*控制按鈕*/
.game6-controls .nav-btn {
    padding: 0px 10px;
    background: hsl(0, 60%, 25%);
    border: 0.6px solid hsla(40, 100%, 80%, 0.3);
    color: hsl(45, 80%, 70%);
    border-radius: 12px;
    font-size: 20px;
    cursor: pointer;
}

.game6-controls .nav-btn:hover {
    background: hsl(0, 60%, 50%);
    color: hsl(45, 80%, 90%);
}

.game6-controls .nav-btn:disabled {
    background: hsl(0, 0%, 50%);
    color: hsl(45, 0%, 90%);
}

/* 紅心與詩句進度列所在區塊（含頭部，佔畫面頂部約 10% 區域） */
.game6-sub-header {
    display: flex;
    justify-content: center;
    align-items: center;
    /* 垂直居中 */
    background: rgba(0, 0, 0, 0.4);
    z-index: 9;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    width: 100%;
    height: 40px;
}

.game6-hearts {
    display: flex;
    gap: 2px;
    justify-content: center;
    flex-wrap: wrap;
}

.game6-hearts .heart {
    color: hsl(4, 90%, 60%);
    font-size: 32px;
}

.game6-hearts .empty {
    opacity: 0.8;
}

.game6-area {
    flex: 1;
    position: relative;
    width: 100%;
    /* 中部 75% 戰鬥區 */
    display: flex;
    flex-direction: column;
}

/* 難度標籤 */
.game6-difficulty-tag {
    padding: 2px 6px;
    border-radius: 6px;
    font-size: 20px;
    color: hsl(45, 30%, 85%);
    border: 0.6px solid hsla(40, 100%, 80%, 0.1);
    z-index: 100;
    cursor: pointer;
    transition: all 0.2s;
}

.game6-difficulty-tag[data-level="小學"] {
    background: linear-gradient(135deg, hsl(100, 40%, 40%) 0%, hsl(120, 40%, 30%) 100%);
}

.game6-difficulty-tag[data-level="中學"] {
    background: linear-gradient(135deg, hsl(210, 40%, 50%) 0%, hsl(230, 40%, 40%) 100%);
}

.game6-difficulty-tag[data-level="高中"] {
    background: linear-gradient(135deg, hsl(0, 50%, 50%) 0%, hsl(0, 50%, 35%) 100%);
}

.game6-difficulty-tag[data-level="大學"] {
    background: linear-gradient(135deg, hsl(290, 50%, 50%) 0%, hsl(270, 50%, 35%) 100%);
}

.game6-difficulty-tag[data-level="研究所"] {
    background: linear-gradient(135deg, hsl(50, 80%, 50%) 0%, hsl(40, 80%, 35%) 100%);
}

.game6-difficulty-tag:hover {
    box-shadow: 0 0px 8px rgba(255, 255, 255, 0.9);
    filter: brightness(1.5);
}

/*收集詩句的欄位*/
.game6-progress-strip {
    min-height: 60px;
    height: 60px;
    background: rgba(0, 0, 0, 0.4);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2px 20px;
    font-size: auto;
    line-height: 1.0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    gap: 6px;
}

/*收集詩句的欄位*/
.game6-poem-row {
    display: flex;
    justify-content: center;
    gap: 4px;
}

/*未收集的字*/
.game6-poem-char {
    margin-right: 4px;
    opacity: 0.6;
}

/*已收集的字*/
.game6-poem-char.collected {
    opacity: 1;
    color: gold;
    text-shadow: 0 0 2px gold;
}

/*戰鬥區*/
#game6-canvas {
    width: 100%;
    height: 680px;
    background: transparent;
    cursor: crosshair;
    touch-action: none;
}

/*底部說明區*/
.game6-footer {
    height: 30px;
    background: rgba(255, 255, 255, 0.05);
    display: flex;
    justify-content: center;
    align-items: center;
    border-top: 0px solid hsla(0, 0%, 100%, 0.1);
}

.game6-drag-hint {
    font-size: 16px;
    opacity: 0.6;
}

/*計時器*/
#game6-timer-ring {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 5;
}

#game6-timer-path {
    fill: none;
    stroke: hsl(0, 50%, 22%);
    /* 初始暗紅色（由 JS 插值到鮮紅）*/
    stroke-width: 6;
    stroke-dasharray: 10000;
    /* 預設隱藏：JS 初始化前不顯示框線，避免閃爍 */
    stroke-dashoffset: 10000;
    /* 預設隱藏：offset=dasharray → 完全不可見 */
    /*transition: stroke-dashoffset 0.1s linear, stroke 0.4s ease;*/
}

/* .game6-message Styles Removed - Using Unified GameMessage Component */

/* 寶箱/特殊效果動畫 */
@keyframes chest-appear {
    0% {
        transform: scale(0) rotate(-10deg);
        opacity: 0;
    }

    70% {
        transform: scale(1.2) rotate(5deg);
        opacity: 1;
    }

    100% {
        transform: scale(1) rotate(0deg);
        opacity: 1;
    }
}

.powerup-chest {
    animation: chest-appear 0.5s ease-out forwards;
}

.hidden {
    display: none !important;
}