* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body,
html {
    height: 100%;
    width: 100%;
    font-family: 'Segoe UI', 'PingFang SC', sans-serif;
    color: #ffffff;
    overflow: hidden;
}

body {
    background-color: #1a1a2e;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

/* 背景与遮罩 */
#bg-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

.bg-media {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 1.5s ease-in-out;
}

.bg-media.active {
    opacity: 1;
}

.background-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.45);
    z-index: 1;
}

/* 居中容器 */
.container {
    position: relative;
    z-index: 2;
    text-align: center;
    /* background: rgba(255, 255, 255, 0.08); */
    /* backdrop-filter: blur(20px); */
    /* -webkit-backdrop-filter: blur(20px); */
    padding: 60px 40px;
    /* border-radius: 24px; */
    /* border: 1px solid rgba(255, 255, 255, 0.15); */
    width: 90%;
    max-width: 850px;
    /* box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5); */
    margin: auto;
}

h1#event-name {
    font-size: 2.8rem;
    margin-bottom: 10px;
    letter-spacing: 1px;
}

p#event-description {
    font-size: 1.2rem;
    margin-bottom: 40px;
    opacity: 0.9;
}

/* 倒计时方块 */
.countdown-wrapper {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 40px;
    flex-wrap: wrap;
}

.time-box {
    background: rgba(0, 0, 0, 0.3);
    padding: 20px;
    border-radius: 16px;
    min-width: 120px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    flex: 1;
}

.time-box span:first-child {
    font-size: 3.5rem;
    font-weight: bold;
    display: block;
}

.label {
    font-size: 1rem;
    color: #ccc;
    text-transform: uppercase;
    margin-top: 5px;
}

/* 时间显示 */
.current-time-wrapper {
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    padding-top: 20px;
    font-size: 1.1rem;
    line-height: 1.8;
}

.target-time-text {
    color: #ffcc80;
}

/* UI 悬浮按钮 (全屏、菜单、声音) */
.ui-element {
    position: absolute;
    z-index: 10;
    width: 45px;
    height: 45px;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(10px);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    transition: 0.3s;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.ui-element:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}

.ui-element.hidden {
    opacity: 0;
    pointer-events: none;
    transform: scale(0.8);
}

.ui-element svg {
    width: 22px;
    height: 22px;
    color: white;
}

/* 按钮位置 */
#menu-btn {
    top: 20px;
    left: 20px;
}

#fullscreen-btn {
    bottom: 20px;
    left: 20px;
}

#audio-btn {
    bottom: 20px;
    right: 20px;
}

/* 新增的声音按钮位置 */

/* 侧边栏与分类样式 */
#sidebar {
    position: absolute;
    top: 0;
    left: -320px;
    width: 300px;
    height: 100%;
    background: rgba(15, 15, 25, 0.9);
    backdrop-filter: blur(25px);
    z-index: 20;
    padding: 40px 20px;
    transition: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border-right: 1px solid rgba(255, 255, 255, 0.1);
    overflow-y: auto;
}

#sidebar.open {
    left: 0;
}

#sidebar h2 {
    margin-bottom: 10px;
}

/* 分类标题 */
.category-title {
    font-size: 1.1rem;
    color: #b0bec5;
    margin: 20px 0 10px;
    padding-bottom: 5px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    font-weight: bold;
}

/* 侧边栏活动卡片 */
.event-item {
    padding: 12px;
    border-radius: 10px;
    margin-bottom: 10px;
    cursor: pointer;
    background: rgba(255, 255, 255, 0.05);
    transition: 0.2s;
}

.event-item:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateX(5px);
}

.event-item.active {
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.event-item h3 {
    font-size: 1rem;
    margin-bottom: 8px;
}

/* 状态标签 (开始/结束) */
.event-time-info {
    font-size: 0.85rem;
    color: #cfd8dc;
    display: flex;
    align-items: center;
}

.badge {
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.75rem;
    margin-right: 8px;
    font-weight: bold;
}

.badge.start {
    background: #4caf50;
    color: white;
}

.badge.end {
    background: #e53935;
    color: white;
}

@media (max-width: 768px) {
    .container {
        padding: 40px 20px;
        width: 95%;
    }

    h1#event-name {
        font-size: 1.8rem;
    }

    .time-box {
        min-width: 80px;
        padding: 10px;
        flex: 1 1 40%;
    }

    .time-box span:first-child {
        font-size: 2.2rem;
    }
}