* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px;
    color: #2c3e50;
}

.content {
    max-width: 800px;
    text-align: center;
    padding: 40px 20px;
}

h1 {
    font-size: 2.5rem;
    margin-bottom: 20px;
    color: #2c3e50;
}

p {
    font-size: 1.2rem;
    line-height: 1.6;
    margin-bottom: 30px;
}



/* 透明覆盖层 */
.overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0);
    z-index: 1000;
}

/* 涂鸦容器 - 透明背景 */
.doodle-container {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    background: transparent;
}

/* 工具栏 - 紧凑单行设计 */
.toolbar {
    background-color: rgba(0, 0, 0, 0);
    padding: 8px 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: nowrap;
    height: 60px;
}

.tool-group {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: nowrap;
    height: 100%;
}

.tool-btn {
    background: rgba(255, 255, 255, 0.7);
    border: 2px solid rgba(221, 221, 221, 0.5);
    border-radius: 6px;
	padding: 6px 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 5px;
    height: 40px;
    white-space: nowrap;
}

.tool-btn:hover {
    background: rgba(240, 240, 240, 0.9);
    transform: translateY(-1px);
}

.tool-btn.active {
    background: #3498db;
    color: white;
    border-color: #2980b9;
}

.color-picker-container {
    position: relative;
    display: flex;
    align-items: center;
    gap: 8px;
}

#color-picker {
    width: 30px;
    height: 30px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    padding: 0;
    background: transparent;
    opacity: 0;
    position: absolute;
    z-index: 1;
}

.color-preview {
    width: 30px;
    height: 30px;
    border-radius: 6px;
    border: 2px solid rgba(221, 221, 221, 0.5);
    background-color: #FF0000;
    cursor: pointer;
}

.line-width {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
}

.line-width input {
    width: 80px;
}

.canvas-container {
    flex: 1;
    overflow: hidden;
    position: relative;
}

#doodle-canvas {
    background-color: transparent;
    cursor: crosshair;
    display: block;
}

.close-btn {
    background: #e74c3c;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
    height: 40px;
}

.close-btn:hover {
    background: #c0392b;
}

.instructions {
    margin-top: 20px;
    color: #7f8c8d;
    text-align: center;
    max-width: 600px;
    line-height: 1.6;
    background: rgba(255, 255, 255, 0.7);
    padding: 15px;
    border-radius: 10px;
}

/* 响应式设计 */
@media (max-width: 1200px) {
    .tool-btn span {
        display: none;
    }
    
    .tool-btn {
        padding: 6px;
    }
    
    .line-width span:first-child {
        display: none;
    }
}

@media (max-width: 768px) {
    .toolbar {
        flex-direction: column;
        height: auto;
        padding: 10px;
    }
    
    .tool-group {
        width: 100%;
        justify-content: center;
        margin-bottom: 8px;
    }
    
    .tool-btn span {
        display: inline;
    }
    
    .line-width span:first-child {
        display: inline;
    }
}