        :root {
            --primary-color: #ffcce6;
            --secondary-color: #ff99cc;
            --accent-color: #ff66b2;
            --text-color: #804d66;
            --light-color: #fff5f9;
            --shadow-color: rgba(255, 153, 204, 0.3);
        }
        
        * {
            box-sizing: border-box;
            margin: 0;
            padding: 0;
            font-family: 'Comic Sans MS', 'Arial Rounded MT Bold', sans-serif;
        }
        
        body {
            background-color: var(--primary-color);
            color: var(--text-color);
            line-height: 1.6;
            padding: 20px;
            display: flex;
            flex-direction: column;
            align-items: center;
            min-height: 100vh;
            background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="100" height="100" viewBox="0 0 100 100"><circle cx="50" cy="50" r="2" fill="%23ff99cc" opacity="0.3"/></svg>');
        }
        
        .header {
            text-align: center;
            margin-bottom: 20px;
        }
        
        h1 {
            color: var(--accent-color);
            text-shadow: 2px 2px 4px var(--shadow-color);
            font-size: 2.5rem;
        }
        
        .container {
            width: 100%;
            max-width: 1000px;
            background-color: var(--light-color);
            border-radius: 20px;
            padding: 20px;
            box-shadow: 0 10px 20px var(--shadow-color);
            position: relative;
        }
        
        .step {
            display: none;
            padding: 20px;
            animation: fadeIn 0.5s;
        }
        
        @keyframes fadeIn {
            from { opacity: 0; }
            to { opacity: 1; }
        }
        
        .step.active {
            display: block;
        }
        
        .btn {
            background-color: var(--secondary-color);
            color: white;
            border: none;
            padding: 12px 24px;
            font-size: 16px;
            border-radius: 50px;
            cursor: pointer;
            transition: all 0.3s;
            margin: 10px;
            box-shadow: 0 4px 8px var(--shadow-color);
        }
        
        .btn:hover {
            background-color: var(--accent-color);
            transform: translateY(-2px);
        }
        
        .btn-primary {
            background-color: var(--accent-color);
            font-weight: bold;
        }
        
        .btn-group {
            display: flex;
            justify-content: center;
            flex-wrap: wrap;
            margin: 20px 0;
        }
        
        .camera-container {
            position: relative;
            width: 100%;
            max-width: 640px;
            margin: 0 auto;
            overflow: hidden;
            border-radius: 10px;
            box-shadow: 0 5px 15px var(--shadow-color);
            aspect-ratio: 16/9;
        }
        
        #video {
            width: 100%;
            height: 100%;
            display: block;
            transform: scaleX(-1);
            object-fit: cover;
        }
        
        .preview-container {
            display: flex;
            flex-wrap: wrap;
            justify-content: center;
            gap: 10px;
            margin: 20px 0;
        }
        
        .photo-preview {
            width: 160px;
            height: 90px;
            border: 3px dashed var(--secondary-color);
            border-radius: 10px;
            display: flex;
            align-items: center;
            justify-content: center;
            color: var(--secondary-color);
            font-size: 24px;
            position: relative;
            overflow: hidden;
        }
        
        .photo-preview img {
            width: 100%;
            height: 100%;
            object-fit: cover;
        }
        
        .settings-group {
            background-color: white;
            padding: 15px;
            border-radius: 15px;
            margin: 20px 0;
            box-shadow: 0 3px 10px var(--shadow-color);
        }
        
        .settings-title {
            font-weight: bold;
            color: var(--accent-color);
            margin-bottom: 10px;
            font-size: 1.2rem;
        }
        
        .slider-container {
            margin: 15px 0;
        }
        
        .slider-container label {
            display: block;
            margin-bottom: 5px;
        }
        
        input[type="range"] {
            width: 100%;
            height: 10px;
            border-radius: 5px;
            background: var(--primary-color);
            outline: none;
            -webkit-appearance: none;
        }
        
        input[type="range"]::-webkit-slider-thumb {
            -webkit-appearance: none;
            width: 20px;
            height: 20px;
            border-radius: 50%;
            background: var(--accent-color);
            cursor: pointer;
        }
        
        .option-group {
            display: flex;
            flex-wrap: wrap;
            gap: 10px;
            margin: 15px 0;
        }
        
        .option-item {
            border: 2px solid var(--primary-color);
            border-radius: 10px;
            padding: 10px;
            cursor: pointer;
            transition: all 0.3s;
            text-align: center;
        }
        
        .option-item:hover, .option-item.selected {
            border-color: var(--accent-color);
            background-color: var(--primary-color);
        }
        
        .option-item img {
            width: 80px;
            height: 80px;
            object-fit: cover;
            border-radius: 5px;
            margin-bottom: 5px;
        }
        
        .frame-option {
            width: 100px;
            height: 100px;
            position: relative;
        }
        
        .frame-preview {
            width: 100%;
            height: 100%;
            border-radius: 5px;
            overflow: hidden;
            background-color: #eee;
        }
        
        .circle-frame {
            border-radius: 50%;
        }
        
        .heart-frame {
            clip-path: path('M50,15 C45,5 30,5 25,15 C15,30 35,55 50,65 C65,55 85,30 75,15 C70,5 55,5 50,15 Z');
            transform: scale(0.8);
        }
        
        .star-frame {
            clip-path: polygon(50% 0%, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%);
        }
        
        .color-option {
            width: 50px;
            height: 50px;
            border-radius: 50%;
            cursor: pointer;
            margin: 5px;
            transition: transform 0.2s;
        }
        
        .color-option:hover, .color-option.selected {
            transform: scale(1.2);
            box-shadow: 0 0 10px rgba(0,0,0,0.2);
        }
        
        #final-canvas-container {
            width: 100%;
            max-width: 500px;
            margin: 20px auto;
            border-radius: 10px;
            overflow: hidden;
            box-shadow: 0 5px 15px var(--shadow-color);
        }
        
        #final-canvas {
            width: 100%;
            height: auto;
            display: block;
        }
        
        .hidden {
            display: none !important;
        }
        
        .progress-bar {
            display: flex;
            justify-content: space-between;
            margin-bottom: 30px;
            position: relative;
            max-width: 600px;
            margin-left: auto;
            margin-right: auto;
        }
        
        .progress-bar::before {
            content: '';
            position: absolute;
            top: 50%;
            left: 0;
            right: 0;
            height: 3px;
            background-color: var(--primary-color);
            transform: translateY(-50%);
            z-index: 1;
        }
        
        .progress-step {
            width: 40px;
            height: 40px;
            border-radius: 50%;
            background-color: var(--primary-color);
            display: flex;
            align-items: center;
            justify-content: center;
            font-weight: bold;
            color: white;
            position: relative;
            z-index: 2;
        }
        
        .progress-step.active {
            background-color: var(--accent-color);
            transform: scale(1.2);
        }
        
        .progress-step.completed {
            background-color: var(--accent-color);
        }
        
        .loading-overlay {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background-color: rgba(255, 255, 255, 0.8);
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            z-index: 9999;
        }
        
        .loading-spinner {
            width: 60px;
            height: 60px;
            border: 8px solid var(--primary-color);
            border-radius: 50%;
            border-top-color: var(--accent-color);
            animation: spin 1s linear infinite;
        }
        
        @keyframes spin {
            0% { transform: rotate(0deg); }
            100% { transform: rotate(360deg); }
        }
        
        .loading-text {
            margin-top: 20px;
            font-size: 18px;
            color: var(--text-color);
        }
        
        @media (max-width: 768px) {
            .container {
                padding: 10px;
            }
            
            .btn {
                padding: 10px 15px;
                font-size: 14px;
            }
            
            .progress-step {
                width: 30px;
                height: 30px;
                font-size: 12px;
            }
            
            .photo-preview {
                width: 120px;
                height: 67.5px;
            }
            
            .camera-container {
                max-width: 100%;
            }
        }
        
        .countdown {
            position: absolute;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            font-size: 72px;
            color: white;
            text-shadow: 0 0 10px rgba(0,0,0,0.5);
            z-index: 1000;
        }
        
        .camera-selector {
            margin: 15px 0;
        }
        
        .camera-select {
            width: 100%;
            padding: 8px;
            border-radius: 5px;
            border: 2px solid var(--primary-color);
            background-color: white;
            color: var(--text-color);
            font-size: 16px;
        }
        
        .camera-select:focus {
            border-color: var(--accent-color);
            outline: none;
        }
        
        /* 相机设置样式 */
        .camera-settings {
            width: 100%;
            max-width: 640px;
            margin: 15px auto;
            background-color: white;
            padding: 15px;
            border-radius: 10px;
            box-shadow: 0 3px 10px var(--shadow-color);
        }