/* 基础样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Microsoft YaHei', Arial, sans-serif;
    background: linear-gradient(135deg, #8b0000 0%, #a52a2a 100%);
    color: #ffffff;
    min-height: 100vh;
    padding: 20px;
    line-height: 1.6;
    position: relative;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
    position: relative;
    z-index: 1;
}

/* 标题样式 */
.header {
    text-align: center;
    margin-bottom: 30px;
    padding: 20px;
    background: rgba(139, 0, 0, 0.9);
    border-radius: 15px;
    border: 3px solid #FFD700;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.7);
}

.header h1 {
    color: #FFD700;
    font-size: 2.2rem;
    margin-bottom: 10px;
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.3);
    letter-spacing: 1px;
}

/* 管理员面板 */
.admin-panel {
    margin-top: 20px;
    padding: 15px;
    background: rgba(255, 69, 0, 0.9);
    border: 2px solid #FF4500;
    border-radius: 10px;
}

.admin-header {
    text-align: center;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
}

.admin-header h3 {
    color: #FFD700;
    margin-bottom: 5px;
}

.admin-note {
    color: #FFFFFF;
    font-size: 0.9rem;
    opacity: 0.9;
}

.admin-controls {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
    margin-bottom: 15px;
}

.btn-admin {
    padding: 12px 20px;
    background: linear-gradient(to bottom, #8B0000, #5a0000);
    color: white;
    border: 2px solid #FF4500;
    border-radius: 8px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-admin:hover {
    background: linear-gradient(to bottom, #a00000, #6a0000);
    box-shadow: 0 0 10px rgba(255, 69, 0, 0.5);
    transform: translateY(-2px);
}

.admin-message {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 5px;
    padding: 10px;
    color: #FFD700;
    font-size: 0.9rem;
    text-align: center;
    word-break: break-all;
}

.admin-info {
    margin-top: 15px;
    padding: 10px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 5px;
    font-size: 0.9rem;
}

.admin-info p {
    margin: 5px 0;
    color: #FFFFFF;
}

.admin-info code {
    background: rgba(0, 0, 0, 0.3);
    padding: 2px 6px;
    border-radius: 3px;
    color: #FFD700;
    word-break: break-all;
}

/* 游戏容器 */
.game-container {
    margin-bottom: 30px;
}

/* 刮刮卡九宫格 */
.scratch-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(3, 1fr);
    gap: 10px;
    width: 100%;
    max-width: 500px;
    height: 500px;
    margin: 0 auto 30px;
    padding: 10px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 10px;
    border: 2px solid #FFD700;
}

.scratch-cell {
    position: relative;
    border: 2px solid #8B7355;
    border-radius: 8px;
    overflow: hidden;
    cursor: crosshair;
    background: #FFFFFF;
    width: 100%;
    height: 100%;
}

.scratch-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
}

.cell-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1;
    padding: 10px;
    text-align: center;
}

.prize-text {
    color: #000000;
    font-weight: bold;
    font-size: 12px;
    word-break: break-word;
    line-height: 1.2;
}

.cell-number {
    position: absolute;
    top: 5px;
    left: 5px;
    background: rgba(139, 0, 0, 0.8);
    color: #FFD700;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: bold;
    z-index: 3;
    border: 1px solid #FFD700;
}

/* 状态消息样式 */
.status-message {
    background: rgba(0, 0, 0, 0.7);
    border: 2px solid #FFD700;
    border-radius: 8px;
    padding: 15px;
    margin: 20px auto;
    max-width: 500px;
    text-align: center;
    color: #FFD700;
    font-size: 1rem;
    display: none;
}

.status-message.visible {
    display: block;
}

.status-message.warning {
    border-color: #FF4500;
    color: #FF4500;
}

.status-message.success {
    border-color: #32CD32;
    color: #32CD32;
}

/* 信息区域 */
.info-section {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.warning-box, .prize-box {
    background: rgba(139, 0, 0, 0.8);
    border-radius: 10px;
    padding: 20px;
    border: 2px solid #8b0000;
}

.warning-box h3, .prize-box h3 {
    color: #FFD700;
    margin-bottom: 15px;
    font-size: 1.2rem;
}

.warning-box p {
    color: #FFFFFF;
    line-height: 1.6;
}

.prize-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.prize-item {
    padding: 12px 15px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 5px;
    font-weight: bold;
    border-left: 4px solid;
}

.first-prize { border-left-color: #FFD700; }
.first-prize .prize-name { color: #FFD700; }
.second-prize { border-left-color: #C0C0C0; }
.second-prize .prize-name { color: #C0C0C0; }
.third-prize { border-left-color: #87CEEB; }
.third-prize .prize-name { color: #87CEEB; }
.participate-prize { border-left-color: #90EE90; }
.participate-prize .prize-name { color: #90EE90; }
