/* 全局变量 */
:root {
    --bg-primary: #0a0a0a;
    --bg-secondary: #1a1a1a;
    --text-primary: #ffffff;
    --text-secondary: #b0b0b0;
    --accent-color: #007AFF;
    --glass-bg: rgba(255, 255, 255, 0.08);
    --glass-border: rgba(255, 255, 255, 0.1);
    --shadow-color: rgba(0, 0, 0, 0.3);
}

/* 重置样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
}

/* 背景动画 */
.background-animation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.gradient-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.4;
    animation: float 20s infinite ease-in-out;
}

.orb-1 {
    width: 400px;
    height: 400px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    top: -200px;
    left: -200px;
    animation-delay: 0s;
}

.orb-2 {
    width: 300px;
    height: 300px;
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    top: 50%;
    right: -150px;
    animation-delay: -7s;
}

.orb-3 {
    width: 350px;
    height: 350px;
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    bottom: -175px;
    left: 50%;
    animation-delay: -14s;
}

@keyframes float {
    0%, 100% {
        transform: translate(0, 0) scale(1);
    }
    33% {
        transform: translate(30px, -30px) scale(1.1);
    }
    66% {
        transform: translate(-20px, 20px) scale(0.9);
    }
}

/* 容器样式 - 居中布局 */
.container {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    width: 100%;
    min-height: 100vh;
}

/* 主卡片样式 */
.main-card {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 40px;
    box-shadow: 0 8px 32px var(--shadow-color);
    width: 450px;
    min-height: 600px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    transition: all 0.3s ease;
}

/* 实时时钟卡片 */
.clock-card {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 30px;
    box-shadow: 0 8px 32px var(--shadow-color);
    width: 300px;
    text-align: center;
    margin-bottom: 20px;
}

/* 实时时间显示 */
.real-time-display {
    font-size: 2.5rem;
    font-weight: 200;
    font-family: 'Inter', monospace;
    letter-spacing: 2px;
    margin-bottom: 10px;
}

.real-date-display {
    font-size: 1rem;
    color: var(--text-secondary);
    font-weight: 300;
}

/* 部分样式 */
.section {
    display: none;
    text-align: center;
}

.section.active {
    display: block;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 时钟样式 - 已移除，使用实时时钟卡片 */

/* 计时器设置 */
.timer-setup {
    margin-top: 40px;
}

.setup-header {
    font-size: 1.3rem;
    font-weight: 500;
    margin-bottom: 30px;
    color: var(--text-primary);
}

.time-selector {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-bottom: 30px;
}

.time-btn {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    color: var(--text-primary);
    padding: 12px 16px;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1rem;
    font-weight: 500;
}

.time-btn:hover {
    background: var(--accent-color);
    transform: translateY(-2px);
}

.time-display-value {
    font-size: 2rem;
    font-weight: 300;
    min-width: 80px;
}

.unit {
    font-size: 1rem;
    color: var(--text-secondary);
    margin-left: 5px;
}

/* 播放内容选择器 */
.music-selector {
    margin-bottom: 30px;
}

.selector-label {
    font-size: 1rem;
    color: var(--text-secondary);
    margin-bottom: 10px;
}

.music-dropdown {
    width: 100%;
    padding: 12px 16px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    color: var(--text-primary);
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.music-dropdown:hover {
    border-color: var(--accent-color);
}

.music-dropdown:focus {
    outline: none;
    border-color: var(--accent-color);
}

/* 按钮样式 */
.primary-btn {
    width: 100%;
    padding: 16px 32px;
    background: var(--accent-color);
    border: none;
    border-radius: 16px;
    color: white;
    font-size: 1.1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.primary-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 122, 255, 0.3);
}

.primary-btn:active {
    transform: translateY(0);
}

.btn-icon {
    font-size: 1.2rem;
}

/* 倒计时样式 */
.countdown-container {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.progress-ring {
    position: relative;
    margin-bottom: 40px;
}

.progress-ring-svg {
    transform: rotate(-90deg);
}

.progress-ring-bg {
    fill: none;
    stroke: var(--glass-bg);
    stroke-width: 8;
}

.progress-ring-fill {
    fill: none;
    stroke: var(--accent-color);
    stroke-width: 8;
    stroke-linecap: round;
    stroke-dasharray: 754;
    stroke-dashoffset: 754;
    transition: stroke-dashoffset 1s ease;
}

.countdown-display {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
}

#countdown-time {
    font-size: 3rem;
    font-weight: 200;
    font-family: 'Inter', monospace;
    letter-spacing: 2px;
}

.countdown-label {
    font-size: 1rem;
    color: var(--text-secondary);
    margin-top: 5px;
}

/* 计时器控制 */
.timer-controls {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
}

.control-btn {
    padding: 12px 24px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    color: var(--text-primary);
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1rem;
}

.control-btn:hover {
    background: var(--accent-color);
    transform: translateY(-2px);
}

/* 正在播放信息 */
.now-playing {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 15px;
    background: var(--glass-bg);
    border-radius: 12px;
    margin-top: 20px;
}

.music-icon {
    font-size: 1.2rem;
}

#now-playing-text {
    color: var(--text-secondary);
    font-size: 1rem;
}

/* 完成状态 */
.complete-animation {
    margin-bottom: 40px;
}

.checkmark {
    font-size: 4rem;
    color: var(--accent-color);
    margin-bottom: 20px;
}

.complete-message {
    font-size: 2rem;
    font-weight: 500;
    margin-bottom: 10px;
}

.complete-subtitle {
    font-size: 1.2rem;
    color: var(--text-secondary);
}

/* 视频播放器样式 - 左侧布局 */
.video-player-card {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 30px;
    box-shadow: 0 8px 32px var(--shadow-color);
    width: 450px;
    min-height: 500px;
    display: flex;
    flex-direction: column;
    transition: all 0.3s ease;
}

.video-player-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.video-player-title {
    font-size: 1.3rem;
    font-weight: 500;
    color: var(--text-primary);
}

.video-container {
    margin-bottom: 20px;
    border-radius: 16px;
    overflow: hidden;
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.video-container iframe {
    width: 100%;
    height: 300px;
    border: none;
    border-radius: 12px;
}

.video-controls {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 20px;
}

.video-controls .control-btn {
    padding: 10px 20px;
    font-size: 1.2rem;
}

/* 响应式设计 */
@media (max-width: 1024px) {
    .container {
        flex-direction: column;
        align-items: center;
    }
    
    .main-card,
    .video-player-card {
        width: 100%;
        max-width: 400px;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    .main-card,
    .video-player-card {
        max-width: 350px;
        padding: 25px 20px;
    }
    
    .time-display {
        font-size: 2.5rem;
    }
    
    .countdown-display {
        width: 250px;
        height: 250px;
    }
    
    #countdown-time {
        font-size: 2.5rem;
    }
    
    .real-time-display {
        font-size: 2rem;
    }
}

@media (max-width: 480px) {
    .time-display {
        font-size: 2rem;
    }
    
    .time-selector {
        gap: 10px;
    }
    
    .time-btn {
        padding: 10px 12px;
        font-size: 0.9rem;
    }
    
    .time-display-value {
        font-size: 1.5rem;
    }
}