/* 난이도와 제한 시간 2열 배치 */
.mode-time-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 1.4rem;
    margin: 0;
}

.mode-section,
.time-section,
.sound-section {
    background: var(--surface-muted);
    border: var(--pixel-border);
    border-radius: var(--radius-md);
    padding: 1rem;
    box-shadow: 0.2rem 0.2rem 0 var(--border-strong);
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    max-width: 100%;
    overflow: visible;
    min-height: 11.8rem;
    height: auto;
    max-height: none;
}

.mode-section h2,
.time-section h2,
.sound-section h2 {
    font-size: 1.4rem;
    margin: 0;
    min-height: 3.7rem;
    text-align: left;
    color: var(--text-light);
    font-family: var(--font-display);
    text-shadow: none;
    display: flex;
    align-items: center;
    border-bottom: 0.3rem solid var(--primary);
    padding-bottom: 0.5rem;
}

.mode-section .mode-selector {
    display: flex;
    flex-direction: row;
    gap: 0.6rem;
    margin: 0;
    justify-content: center;
    align-items: center;
    flex: 1;
}

.time-section {
    justify-content: flex-start;
}

.time-section #time-setter-wrapper {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    margin: 0;
    height: 100%;
}

.time-section #time-setter-wrapper h2 {
    margin-bottom: 0;
}

.time-section #time-setter-wrapper .time-setter {
    margin-top: 0;
    flex: 1;
}

.time-section #time-setter-wrapper.hidden {
    display: none;
}

.mode-time-grid .time-setter {
    margin: 0 !important;
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 0.9rem !important;
    flex-wrap: nowrap !important;
}

.sound-section #sound-toggle-container {
    flex: 1;
    padding: 0;
}

/* 반응형: 작은 화면에서는 세로 배치 */
@media (max-width: 768px) {
    .mode-time-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .mode-section .mode-selector {
        flex-direction: row;
        gap: 0.8rem;
    }

    .mode-btn-group .mode-btn {
        min-width: 60px;
        max-width: 80px;
        font-size: 1rem;
        padding: 0.4rem 0.6rem;
    }

    .mode-btn-group::before {
        border-radius: 0;
    }

    .mode-section,
    .time-section,
    .sound-section {
        padding: 0.4rem 0.6rem;
        height: auto;
        min-height: 60px;
        max-height: none;
    }

    .mode-time-grid .time-control-btn {
        font-size: 1.4rem;
        padding: 0.4rem 0.6rem;
    }

    .mode-time-grid #time-setting-display {
        font-size: 1.6rem;
    }
}

#start-game-btn {
    background: var(--primary-strong);
    color: var(--text-light);
    padding: 1.5rem 3.5rem;
    margin-top: 1.2rem;
    margin-bottom: 0;
    font-size: 2.6rem;
    font-weight: 900;
    text-shadow: none; /* 평면 디자인 - 텍스트 그림자 제거 */
    border: var(--pixel-border);
    width: 100%;
    justify-self: center;
    box-shadow: 0.45rem 0.45rem 0 var(--border-strong);
    position: relative;
    overflow: visible;
    animation: none; /* 애니메이션 제거 */
    z-index: 10;
    border-radius: var(--radius-md);
    transition: none;
}

#start-game-btn::before {
    display: none; /* ::before 제거 */
}

#start-game-btn:hover {
    background: var(--primary);
    transform: translate(-0.1rem, -0.1rem);
    box-shadow: 0.55rem 0.55rem 0 var(--border-strong);
    animation: none;
}

#start-game-btn:active {
    transform: translate(0.5rem, 0.5rem);
    box-shadow: 0.2rem 0.2rem 0 var(--border-strong);
}

/* pulse-start-btn 애니메이션 제거 */
@keyframes gradient-shift {
    /* 제거됨 */
}

@keyframes shine {
    /* 제거됨 */
}

#hard-core-description {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 0;
    margin: 0;
    flex: 1;
    min-height: 0; /* 부모 높이에 맞춤 */
    height: 100%; /* 부모의 전체 높이 사용 */
}

#hard-core-description.hidden {
    display: none;
}

#hard-core-description h2 {
    font-size: 2rem;
    margin: 0 0 1rem 0;
    text-align: center;
    color: var(--text-dark);
    font-family: var(--font-display);
    text-shadow: 2px 2px 0px rgba(0, 0, 0, 0.3);
}

#hard-core-description p {
    margin: 0;
    padding: 0;
    font-size: 1.5rem;
    font-family: var(--font-display);
    color: var(--text-dark);
    text-align: center;
    line-height: 1.8;
    /* flex 컨테이너의 중앙 정렬을 위해 */
    align-self: center;
}
