/* ============================================
   MC Quiz - 基于Mizuki博客风格的主样式文件
   ============================================ */

/* CSS 变量 - 参照博客设计，全局主题色应用 */
:root {
    /* 主题色相关 - 通过JS动态修改 --hue */
    --hue: 175;
    --primary: oklch(0.60 0.16 var(--hue));
    --primary-light: oklch(0.70 0.13 var(--hue));
    --primary-dark: oklch(0.50 0.17 var(--hue));
    
    /* 页面背景 - 跟随主题色但更明显 */
    --page-bg: oklch(0.95 0.012 var(--hue));
    --page-bg-secondary: oklch(0.92 0.015 var(--hue));
    
    /* 卡片背景 */
    --card-bg: oklch(1 0 0 / 0.85);
    --card-bg-solid: oklch(1 0 0);
    
    /* 按钮背景 */
    --btn-regular-bg: oklch(0.93 0.012 var(--hue));
    --btn-regular-bg-hover: oklch(0.88 0.018 var(--hue));
    --btn-regular-bg-active: oklch(0.83 0.025 var(--hue));
    --btn-plain-bg-hover: oklch(0.93 0.015 var(--hue));
    --btn-plain-bg-active: oklch(0.88 0.025 var(--hue));
    
    /* 内容颜色 */
    --btn-content: oklch(0.35 0.06 var(--hue));
    --text-primary: oklch(0.22 0.03 var(--hue));
    --text-secondary: oklch(0.45 0.025 var(--hue));
    --text-tertiary: oklch(0.60 0.02 var(--hue));
    
    /* 边框和分隔线 */
    --line-divider: oklch(0.88 0.012 var(--hue));
    
    /* 圆角 */
    --radius-small: 0.25rem;
    --radius-medium: 0.375rem;
    --radius-large: 0.625rem;
    
    /* 过渡动画 */
    --transition-duration: 150ms;
    --transition-easing: cubic-bezier(0.25, 0.46, 0.45, 0.94);
    
    /* 导航栏高度 */
    --navbar-height: 3.5rem;
}

/* 暗色模式 */
:root.dark {
    --primary: oklch(0.65 0.16 var(--hue));
    --primary-light: oklch(0.72 0.14 var(--hue));
    --primary-dark: oklch(0.55 0.17 var(--hue));
    
    /* 背景真的变黑 */
    --page-bg: oklch(0.12 0.02 var(--hue));
    --page-bg-secondary: oklch(0.10 0.018 var(--hue));
    
    --card-bg: oklch(0.15 0.015 var(--hue) / 0.9);
    --card-bg-solid: oklch(0.15 0.015 var(--hue));
    
    --btn-regular-bg: oklch(0.20 0.02 var(--hue));
    --btn-regular-bg-hover: oklch(0.25 0.022 var(--hue));
    --btn-regular-bg-active: oklch(0.30 0.025 var(--hue));
    --btn-plain-bg-hover: oklch(0.22 0.02 var(--hue));
    --btn-plain-bg-active: oklch(0.28 0.024 var(--hue));
    
    --btn-content: oklch(0.88 0.01 var(--hue));
    --text-primary: oklch(0.95 0.008 var(--hue));
    --text-secondary: oklch(0.78 0.01 var(--hue));
    --text-tertiary: oklch(0.60 0.01 var(--hue));
    --line-divider: oklch(0.30 0.015 var(--hue));
}

/* 基础重置 */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    scrollbar-gutter: stable;
}

body {
    font-family: 'Noto Sans SC', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--page-bg);
    color: var(--text-primary);
    line-height: 1.6;
    transition: background-color var(--transition-duration) var(--transition-easing),
                color var(--transition-duration) var(--transition-easing);
    min-height: 100vh;
    overflow-x: hidden;
}

/* ============================================
   背景光晕效果 - 轻量版
   ============================================ */
.bg-glow {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.bg-glow::before {
    content: '';
    position: absolute;
    top: -20%;
    right: -10%;
    width: 60%;
    height: 50%;
    background: radial-gradient(ellipse, oklch(from var(--primary) l c h / 0.08) 0%, transparent 70%);
    filter: blur(60px);
}

.bg-glow::after {
    content: '';
    position: absolute;
    bottom: 10%;
    left: -15%;
    width: 50%;
    height: 40%;
    background: radial-gradient(ellipse, oklch(from var(--primary) l c h / 0.06) 0%, transparent 70%);
    filter: blur(80px);
}

/* ============================================
   随机喵文字样式
   ============================================ */
#nya-container {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    z-index: 1;
    overflow: hidden;
}

.nya-text {
    position: absolute;
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--primary);
    opacity: 0;
    animation: nya-fade 4s ease-in-out forwards;
    text-shadow: 0 0 20px oklch(from var(--primary) l c h / 0.3);
}

@keyframes nya-fade {
    0% {
        opacity: 0;
        transform: translateY(10px) scale(0.9);
    }
    20% {
        opacity: 0.6;
        transform: translateY(0) scale(1);
    }
    80% {
        opacity: 0.6;
        transform: translateY(-5px) scale(1);
    }
    100% {
        opacity: 0;
        transform: translateY(-15px) scale(0.95);
    }
}

/* ============================================
   导航栏 - 参照博客Navbar.astro + 小椭圆底部
   ============================================ */
#navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    height: var(--navbar-height);
    background: var(--card-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--line-divider);
    transition: background-color var(--transition-duration) var(--transition-easing);
    /* 小椭圆底部效果 */
    border-radius: 0 0 1.25rem 1.25rem;
}

#navbar.scrolled {
    background: var(--card-bg);
    box-shadow: 0 2px 12px oklch(from var(--primary) l c h / 0.1);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.25rem;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav-left {
    display: flex;
    align-items: center;
}

.nav-title {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    text-decoration: none;
    color: var(--text-primary);
    font-weight: 700;
    font-size: 1rem;
    transition: color var(--transition-duration) var(--transition-easing);
}

.nav-title:hover {
    color: var(--primary);
}

.nav-title-text {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 0.125rem;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.375rem 0.625rem;
    border-radius: var(--radius-medium);
    cursor: pointer;
    color: var(--text-secondary);
    transition: all var(--transition-duration) var(--transition-easing);
    position: relative;
    user-select: none;
}

.nav-item:hover {
    background: var(--btn-plain-bg-hover);
    color: var(--primary);
}

.nav-icon {
    font-size: 1.125rem;
}

.nav-label {
    font-size: 0.8125rem;
    font-weight: 500;
}

@media (max-width: 640px) {
    .nav-label {
        display: none;
    }
    
    .nav-title-text {
        font-size: 0.9375rem;
    }
}

/* ============================================
   浮动面板 - 参照博客float-panel样式
   ============================================ */
.float-panel {
    position: absolute;
    top: calc(100% + 0.375rem);
    right: 0;
    min-width: 11rem;
    background: var(--card-bg-solid);
    border-radius: var(--radius-large);
    box-shadow: 0 4px 24px oklch(from var(--primary) l c h / 0.15);
    border: 1px solid var(--line-divider);
    padding: 0.625rem;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: all var(--transition-duration) var(--transition-easing);
    z-index: 110;
}

.float-panel.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.panel-content {
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
}

.panel-title {
    font-weight: 700;
    font-size: 0.8125rem;
    color: var(--text-primary);
    padding: 0.25rem 0.5rem;
    margin-bottom: 0.25rem;
    position: relative;
    padding-left: 0.625rem;
}

.panel-title::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 0.8125rem;
    background: var(--primary);
    border-radius: 2px;
}

/* 调色板选项 */
.color-options {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
}

.color-btn {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    padding: 0.5rem 0.625rem;
    border: none;
    background: transparent;
    border-radius: var(--radius-medium);
    cursor: pointer;
    transition: all var(--transition-duration) var(--transition-easing);
    color: var(--text-secondary);
    font-size: 0.8125rem;
}

.color-btn:hover {
    background: var(--btn-plain-bg-hover);
    color: var(--text-primary);
}

.color-btn.active {
    background: var(--primary);
    color: white;
}

.color-btn.active:hover {
    background: var(--primary-dark);
    color: white;
}

.color-preview {
    width: 1.375rem;
    height: 1.375rem;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.4);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

.color-name {
    font-weight: 500;
}

/* 语言选项 */
.lang-options {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
}

.lang-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 0.625rem;
    border: none;
    background: transparent;
    border-radius: var(--radius-medium);
    cursor: pointer;
    transition: all var(--transition-duration) var(--transition-easing);
    color: var(--text-secondary);
    font-size: 0.8125rem;
}

.lang-btn:hover {
    background: var(--btn-plain-bg-hover);
    color: var(--text-primary);
}

.lang-btn.active {
    background: var(--primary);
    color: white;
}

.lang-btn.active:hover {
    background: var(--primary-dark);
    color: white;
}

.lang-name {
    font-weight: 500;
}

/* 主题选项 */
.theme-options {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
}

.theme-btn {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    padding: 0.5rem 0.625rem;
    border: none;
    background: transparent;
    border-radius: var(--radius-medium);
    cursor: pointer;
    transition: all var(--transition-duration) var(--transition-easing);
    color: var(--text-secondary);
    font-size: 0.8125rem;
}

.theme-btn:hover {
    background: var(--btn-plain-bg-hover);
    color: var(--text-primary);
}

.theme-btn.active {
    background: var(--primary);
    color: white;
}

.theme-btn.active:hover {
    background: var(--primary-dark);
    color: white;
}

.theme-icon {
    font-size: 1.125rem;
}

.theme-name {
    font-weight: 500;
}

/* ============================================
   Hero 区域 - 博客Banner风格
   ============================================ */
.hero-section {
    position: relative;
    height: 50vh;
    min-height: 280px;
    max-height: 480px;
    margin-top: 30px;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background-image: url('../assets/bg.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.hero-bg::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.15) 0%,
        rgba(0, 0, 0, 0.35) 50%,
        rgba(0, 0, 0, 0.55) 100%
    );
}

/* 波浪效果 - 速度加快、高度降低 */
.waves {
    position: absolute;
    bottom: -1px;
    left: 0;
    right: 0;
    height: 8vh;
    max-height: 5rem;
    min-height: 2rem;
    width: 100%;
}

.waves-svg {
    width: 100%;
    height: 100%;
    transform: translateZ(0);
    backface-visibility: hidden;
}

.wave-layer {
    fill: var(--page-bg);
    transition: fill var(--transition-duration) var(--transition-easing);
}

.wave-1 {
    opacity: 0.25;
    animation: wave-move 5s ease-in-out infinite;
    animation-delay: -2s;
}

.wave-2 {
    opacity: 0.5;
    animation: wave-move 7s ease-in-out infinite;
    animation-delay: -3s;
}

.wave-3 {
    opacity: 0.75;
    animation: wave-move 9s ease-in-out infinite;
    animation-delay: -4s;
}

.wave-4 {
    opacity: 1;
    animation: wave-move 12s ease-in-out infinite;
    animation-delay: -5s;
}

@keyframes wave-move {
    0%, 100% {
        transform: translateX(0);
    }
    50% {
        transform: translateX(-40px);
    }
}

/* 电脑端波浪幅度更大 */
@media (min-width: 641px) {
    @keyframes wave-move {
        0%, 100% {
            transform: translateX(0);
        }
        50% {
            transform: translateX(-60px);
        }
    }
}

/* ============================================
   主内容区域
   ============================================ */
.main-content {
    position: relative;
    z-index: 2;
    min-height: calc(40vh + 50px);
    padding: 1.5rem 1rem 3rem;
    background: transparent;
}

.content-wrapper {
    max-width: 680px;
    margin: 0 auto;
}

/* 底部装饰渐变条 */
.bottom-decoration {
    margin-top: 3rem;
    height: 6px;
    border-radius: 3px;
    background: linear-gradient(
        90deg,
        transparent 0%,
        var(--primary-light) 20%,
        var(--primary) 50%,
        var(--primary-light) 80%,
        transparent 100%
    );
    opacity: 0.6;
}

/* ============================================
   答题卡片 - 博客文章卡片风格，优化圆角
   ============================================ */
.quiz-card {
    background: var(--card-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: var(--radius-large);
    overflow: hidden;
    transition: background-color var(--transition-duration) var(--transition-easing);
    border: 1px solid var(--line-divider);
    box-shadow: 0 4px 24px oklch(from var(--primary) l c h / 0.08);
}

:root.dark .quiz-card {
    background: var(--card-bg);
    border-color: var(--line-divider);
    box-shadow: 0 4px 24px oklch(0 0 0 / 0.3);
}

/* 开始界面 */
.quiz-start {
    padding: 2rem 1.75rem 1.75rem;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    gap: 1.25rem;
    padding-left: 2.5rem;
    position: relative;
}

.quiz-start::before {
    content: '';
    position: absolute;
    left: 0.875rem;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 50%;
    background: var(--primary);
    border-radius: 2px;
}

.quiz-title h1 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.375rem;
    line-height: 1.3;
}

.quiz-subtitle {
    color: var(--text-secondary);
    font-size: 0.9375rem;
}

.start-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 1.25rem;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: var(--radius-medium);
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-duration) var(--transition-easing);
}

.start-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
}

.start-btn:active {
    transform: translateY(0);
}

.btn-icon {
    font-size: 1rem;
}

/* 答题游戏界面 */
.quiz-game {
    padding: 1.75rem 1.75rem 2rem;
    padding-left: 2.5rem;
    position: relative;
}

.quiz-game::before {
    content: '';
    position: absolute;
    left: 0.875rem;
    top: 2rem;
    width: 3px;
    height: calc(100% - 4rem);
    background: var(--primary);
    border-radius: 2px;
}

/* 进度条 */
.progress-bar {
    margin-bottom: 1.25rem;
}

.progress-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.375rem;
}

.progress-text {
    font-size: 0.8125rem;
    color: var(--text-secondary);
}

.progress-percent {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--primary);
}

.progress-track {
    height: 4px;
    background: var(--btn-regular-bg);
    border-radius: 2px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: var(--primary);
    border-radius: 2px;
    transition: width 0.3s ease;
    width: 0%;
}

/* 题目容器 */
.question-container {
    margin-bottom: 1.25rem;
}

/* 题目图片 */
.question-image-container {
    margin-bottom: 1rem;
    border-radius: var(--radius-medium);
    overflow: hidden;
    max-height: 200px;
}

.question-image-container.hidden {
    display: none;
}

.question-image {
    width: 100%;
    height: auto;
    object-fit: cover;
    display: block;
}

.question-number {
    font-size: 0.6875rem;
    font-weight: 600;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.375rem;
}

.question-text {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.6;
}

/* 选项容器 */
.options-container {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 1.25rem;
}

.option-btn {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 0.875rem;
    background: var(--btn-regular-bg);
    border: 1px solid var(--line-divider);
    border-radius: var(--radius-medium);
    cursor: pointer;
    transition: all var(--transition-duration) var(--transition-easing);
    text-align: left;
    font-size: 0.875rem;
    color: var(--text-primary);
}

.option-btn:hover {
    border-color: var(--primary);
    background: oklch(from var(--primary) l c h / 0.06);
}

.option-btn.selected {
    border-color: var(--primary);
    background: oklch(from var(--primary) l c h / 0.1);
}

.option-btn.correct {
    border-color: oklch(0.65 0.15 145);
    background: oklch(0.65 0.15 145 / 0.1);
}

.option-btn.incorrect {
    border-color: oklch(0.60 0.18 25);
    background: oklch(0.60 0.18 25 / 0.1);
}

.option-marker {
    width: 1.5rem;
    height: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--card-bg-solid);
    border-radius: var(--radius-small);
    font-weight: 600;
    font-size: 0.75rem;
    color: var(--text-secondary);
    transition: all var(--transition-duration) var(--transition-easing);
    flex-shrink: 0;
    border: 1px solid var(--line-divider);
}

.option-btn.selected .option-marker {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.option-btn.correct .option-marker {
    background: oklch(0.65 0.15 145);
    color: white;
    border-color: oklch(0.65 0.15 145);
}

.option-btn.incorrect .option-marker {
    background: oklch(0.60 0.18 25);
    color: white;
    border-color: oklch(0.60 0.18 25);
}

.option-text {
    flex: 1;
}

/* 操作按钮 */
.quiz-actions {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.action-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.5rem 0.875rem;
    background: var(--btn-regular-bg);
    border: 1px solid var(--line-divider);
    border-radius: var(--radius-medium);
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--btn-content);
    cursor: pointer;
    transition: all var(--transition-duration) var(--transition-easing);
}

.action-btn:hover:not(:disabled) {
    background: var(--btn-regular-bg-hover);
    border-color: var(--primary);
}

.action-btn:active:not(:disabled) {
    background: var(--btn-regular-bg-active);
    transform: scale(0.98);
}

.action-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.action-btn.primary {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.action-btn.primary:hover:not(:disabled) {
    background: var(--primary-dark);
}

.submit-btn {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.submit-btn:hover:not(:disabled) {
    background: var(--primary-dark);
}

/* 结果界面 */
.quiz-result {
    padding: 1.75rem 1.75rem 2rem;
    padding-left: 2.5rem;
    position: relative;
}

.quiz-result::before {
    content: '';
    position: absolute;
    left: 0.875rem;
    top: 1.75rem;
    width: 3px;
    height: calc(100% - 3.5rem);
    background: var(--primary);
    border-radius: 2px;
}

.result-header {
    margin-bottom: 1rem;
}

.result-icon {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 0.375rem;
}

.result-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
}

.result-score {
    display: flex;
    justify-content: center;
    align-items: baseline;
    gap: 0.25rem;
    margin-bottom: 0.375rem;
}

.score-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary);
    line-height: 1;
}

.score-divider {
    font-size: 1.5rem;
    color: var(--text-tertiary);
}

.score-total {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-secondary);
}

.result-text {
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-bottom: 0.875rem;
}

.result-message {
    font-size: 0.875rem;
    color: var(--text-primary);
    padding: 0.625rem 1rem;
    background: oklch(from var(--primary) l c h / 0.1);
    border-radius: var(--radius-medium);
    margin-bottom: 1rem;
}

.restart-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 1.25rem;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: var(--radius-medium);
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-duration) var(--transition-easing);
}

.restart-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
}

/* 工具类 */
.hidden {
    display: none !important;
}

/* ============================================
   响应式设计
   ============================================ */
@media (max-width: 640px) {
    .nav-container {
        padding: 0 0.875rem;
    }
    
    .hero-section {
        height: 35vh;
        min-height: 220px;
    }
    
    .main-content {
        padding: 1rem 0.75rem 2.5rem;
    }
    
    .quiz-start,
    .quiz-game,
    .quiz-result {
        padding: 1.25rem 1rem 1.5rem;
        padding-left: 2rem;
    }
    
    .quiz-start::before,
    .quiz-game::before,
    .quiz-result::before {
        left: 0.625rem;
    }
    
    .quiz-title h1 {
        font-size: 1.25rem;
    }
    
    .question-text {
        font-size: 0.9375rem;
    }
    
    .option-btn {
        padding: 0.625rem 0.75rem;
    }
    
    .float-panel {
        position: fixed;
        left: 0.75rem;
        right: 0.75rem;
        top: calc(var(--navbar-height) + 0.375rem);
    }
}

/* ============================================
   动画效果
   ============================================ */
@keyframes fade-in-up {
    from {
        opacity: 0;
        transform: translateY(1rem);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fade-in-up 0.3s ease-out forwards;
}

/* 主题切换过渡 */
.is-theme-transitioning .float-panel,
.is-theme-transitioning .float-panel * {
    transition: background-color 0ms !important;
}
/* ============================================ */
/* 新增样式 - 波浪/背景调整 + 按钮动画 */
/* ============================================ */

/* Hero区域往下调 */
.hero-section {
    position: relative;
    height: 35vh;
    min-height: 220px;
    max-height: 380px;
    margin-top: 20px;
}

/* 波浪效果调低 */
.waves {
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 80px;
}

.waves-svg {
    display: block;
    width: 100%;
    height: 100%;
}

.wave-layer {
    fill: var(--page-bg);
    transform-origin: center bottom;
}

/* 背景图淡入淡出 */
.hero-bg {
    transition: opacity 0.5s ease-in-out;
}

.hero-bg.fading {
    opacity: 0.3;
}

/* 导航栏椭圆底部 */
#navbar {
    border-radius: 0 0 24px 24px;
}

/* 按钮丝滑动画 */
.action-btn, .option-btn, .start-btn, .confirm-btn, .restart-btn {
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.action-btn:hover:not(:disabled), .option-btn:hover, .start-btn:hover, .confirm-btn:hover, .restart-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.action-btn:active:not(:disabled), .option-btn:active, .start-btn:active, .confirm-btn:active, .restart-btn:active {
    transform: translateY(0);
}

/* 答题卡片 - 博客卡片风格 */
.quiz-card.card-base {
    border-radius: 24px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* 名称输入框样式 */
.name-input-container {
    display: flex;
    gap: 12px;
    max-width: 420px;
    margin: 0 auto;
    flex-wrap: wrap;
}

.name-input {
    flex: 1;
    min-width: 180px;
    padding: 14px 18px;
    font-size: 15px;
    border: 2px solid oklch(0.9 0.01 var(--hue));
    border-radius: 12px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    transition: all 0.2s ease;
}

.name-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px oklch(0.65 0.12 var(--hue) / 0.15);
}

/* 顶部信息栏 */
.quiz-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 24px;
    background: oklch(0.70 0.08 var(--hue) / 0.25);
    border-bottom: 1px solid oklch(0.55 0.08 var(--hue) / 0.1);
    border-radius: 24px 24px 0 0;
}

.player-info {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
}

.header-icon {
    font-size: 20px;
    color: var(--primary);
}

#current-question-num {
    color: var(--primary);
    font-weight: 600;
}


/* 背景图淡入淡出样式 */
.hero-bg {
    transition: opacity 0.5s ease-in-out;
}
.hero-bg.fading {
    opacity: 0.3;
}
