* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    width: 100vw;
    height: 100vh;
    overflow: hidden;
    background: #ffffff;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: #1a202c;
}

#canvas {
    width: 100vw;
    height: 90vh;
    display: block;
    background: #ffffff;
    border: 1px solid #e2e8f0;
}

.control {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    gap: 16px;
    background: #ffffff;
    border-top: 1px solid #e2e8f0;
}
.control-left, .control-right {
    display: flex;
    align-items: center;
    gap: 16px;
}
.color-readout {
    font-family: system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
    font-size: 14px;
}

.play-button, .upload-button, .record-button {
    padding: 12px 24px;
    background: #cee0ff;
    color: black;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.2s ease;
}

.play-button:hover, .upload-button:hover, .record-button:hover {
    background: #dce7ff;
    transform: translateY(-1px);
}

.play-button:active, .upload-button:active, .record-button:active {
    transform: translateY(0);
    background: #b8d4ff;
}

.record-button.recording {
    background: #ff6b6b;
    color: white;
    animation: pulse 1s infinite;
}

.record-button.recording:hover {
    background: #ff5252;
}

@keyframes pulse {
    0% { opacity: 1; }
    50% { opacity: 0.7; }
    100% { opacity: 1; }
}

.upload-wrapper {
    position: relative;
    display: inline-block;
}

.upload-input {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
    z-index: 10;
}

.file-name {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    font-size: 14px;
    color: #64748b;
    font-weight: 500;
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.color-readout {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    font-size: 14px;
    color: #64748b;
    font-weight: 500;
}

#colorPicker {
    width: 40px;
    height: 40px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    cursor: pointer;
    transition: transform 0.2s ease;
}

#colorPicker:hover {
    transform: scale(1.05);
}
.dragover #canvas {
    outline: 2px dashed #3b82f6;
    outline-offset: -2px;
}

#word-circle {
    display: none;
    align-items: center;
    gap: 8px;
}
#word-circle.show {
    display: flex;
}
#word-circle label {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    font-size: 14px;
    color: #64748b;
    font-weight: 500;
}
#word-circle-input {
    padding: 8px 12px;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    font-size: 14px;
    background: #ffffff;
    color: #1a202c;
    width: 120px;
}
#word-circle-input:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.1);
}

#options {
    padding: 8px 12px;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    font-size: 14px;
    background: #ffffff;
    color: #1a202c;
    cursor: pointer;
}
#options:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.1);
}