        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
        }

        body {
            font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Inter', sans-serif;
            background: #0a0e27;
            color: #ffffff;
            min-height: 100vh;
            display: flex;
            align-items: center;
            justify-content: center;
            padding: 20px;
            position: relative;
            overflow-x: hidden;
        }


        /* Animated background orbs */
        .bg-orb {
            position: fixed;
            border-radius: 50%;
            filter: blur(60px);
            pointer-events: none;
            z-index: -1;
            opacity: 0.3;
        }

        .bg-orb-1 {
            width: 400px;
            height: 400px;
            background: radial-gradient(circle, rgba(100, 255, 218, 0.4), transparent);
            top: -200px;
            left: -200px;
            animation: orbFloat1 20s ease-in-out infinite;
        }

        .bg-orb-2 {
            width: 350px;
            height: 350px;
            background: radial-gradient(circle, rgba(68, 138, 255, 0.4), transparent);
            bottom: -150px;
            right: -150px;
            animation: orbFloat2 25s ease-in-out infinite;
        }

        .bg-orb-3 {
            width: 300px;
            height: 300px;
            background: radial-gradient(circle, rgba(100, 255, 218, 0.3), transparent);
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            animation: orbFloat3 30s ease-in-out infinite;
        }

        @keyframes orbFloat1 {
            0%, 100% {
                transform: translate(0, 0) scale(1);
            }
            33% {
                transform: translate(100px, 150px) scale(1.2);
            }
            66% {
                transform: translate(-50px, 200px) scale(0.8);
            }
        }

        @keyframes orbFloat2 {
            0%, 100% {
                transform: translate(0, 0) scale(1);
            }
            33% {
                transform: translate(-150px, -100px) scale(1.1);
            }
            66% {
                transform: translate(100px, -200px) scale(0.9);
            }
        }

        @keyframes orbFloat3 {
            0%, 100% {
                transform: translate(-50%, -50%) scale(1) rotate(0deg);
            }
            50% {
                transform: translate(-50%, -50%) scale(1.3) rotate(180deg);
            }
        }


        .container {
            background: transparent;
            border: none;
            border-radius: 24px;
            padding: 32px;
            width: 100%;
            max-width: 1200px;
            position: relative;
            animation: fadeInUp 0.6s ease-out;
            overflow: visible;
        }

        @keyframes fadeInUp {
            from {
                opacity: 0;
                transform: translateY(20px);
            }
            to {
                opacity: 1;
                transform: translateY(0);
            }
        }


        /* Music decorations on background */
        .music-decoration {
            position: fixed;
            pointer-events: none;
            z-index: 0;
            opacity: 0.2;
        }

        .music-note {
            font-size: 2.5rem;
            animation: floatNote 8s ease-in-out infinite;
            color: rgba(100, 255, 218, 0.35);
            user-select: none;
        }

        /* Top edge notes - evenly spread */
        .music-note:nth-child(1) {
            top: 3%;
            left: 3%;
            animation-delay: 0s;
            font-size: 2rem;
        }

        .music-note:nth-child(2) {
            top: 3%;
            left: 12%;
            animation-delay: 0.8s;
            font-size: 2.2rem;
        }

        .music-note:nth-child(3) {
            top: 3%;
            left: 21%;
            animation-delay: 1.6s;
            font-size: 1.8rem;
        }

        .music-note:nth-child(4) {
            top: 3%;
            left: 79%;
            animation-delay: 2.4s;
            font-size: 2.3rem;
        }

        .music-note:nth-child(5) {
            top: 3%;
            left: 88%;
            animation-delay: 3.2s;
            font-size: 1.9rem;
        }

        .music-note:nth-child(6) {
            top: 3%;
            right: 3%;
            animation-delay: 0.4s;
            font-size: 2.1rem;
        }

        /* Right edge notes - evenly spread */
        .music-note:nth-child(7) {
            top: 8%;
            right: 2%;
            animation-delay: 1.2s;
            font-size: 1.7rem;
        }

        .music-note:nth-child(8) {
            top: 25%;
            right: 2%;
            animation-delay: 2s;
            font-size: 2.4rem;
        }

        .music-note:nth-child(9) {
            top: 42%;
            right: 2%;
            animation-delay: 2.8s;
            font-size: 2rem;
        }

        .music-note:nth-child(10) {
            top: 75%;
            right: 2%;
            animation-delay: 0.6s;
            font-size: 1.8rem;
        }

        .music-note:nth-child(11) {
            top: 92%;
            right: 2%;
            animation-delay: 1.4s;
            font-size: 2.2rem;
        }

        /* Bottom edge notes - evenly spread */
        .music-note:nth-child(12) {
            bottom: 3%;
            right: 3%;
            animation-delay: 2.2s;
            font-size: 1.9rem;
        }

        .music-note:nth-child(13) {
            bottom: 3%;
            right: 12%;
            animation-delay: 3s;
            font-size: 2rem;
        }

        .music-note:nth-child(14) {
            bottom: 3%;
            right: 21%;
            animation-delay: 0.2s;
            font-size: 1.8rem;
        }

        .music-note:nth-child(15) {
            bottom: 3%;
            right: 79%;
            animation-delay: 1s;
            font-size: 2.1rem;
        }

        .music-note:nth-child(16) {
            bottom: 3%;
            right: 88%;
            animation-delay: 1.8s;
            font-size: 2.3rem;
        }

        .music-note:nth-child(17) {
            bottom: 3%;
            left: 3%;
            animation-delay: 2.6s;
            font-size: 1.9rem;
        }

        /* Left edge notes - evenly spread */
        .music-note:nth-child(18) {
            top: 8%;
            left: 2%;
            animation-delay: 3.4s;
            font-size: 2.3rem;
        }

        .music-note:nth-child(19) {
            top: 25%;
            left: 2%;
            animation-delay: 0.3s;
            font-size: 1.9rem;
        }

        .music-note:nth-child(20) {
            top: 42%;
            left: 2%;
            animation-delay: 1.1s;
            font-size: 2rem;
        }

        .music-note:nth-child(21) {
            top: 75%;
            left: 2%;
            animation-delay: 1.9s;
            font-size: 1.8rem;
        }

        @keyframes floatNote {
            0%, 100% {
                transform: translateY(0) translateX(0) rotate(0deg);
                opacity: 0.25;
            }
            25% {
                transform: translateY(-40px) translateX(20px) rotate(10deg);
                opacity: 0.4;
            }
            50% {
                transform: translateY(-60px) translateX(-15px) rotate(-10deg);
                opacity: 0.5;
            }
            75% {
                transform: translateY(-30px) translateX(10px) rotate(5deg);
                opacity: 0.35;
            }
        }

        /* Heartbeat animation for music notes during generation */
        body.generating .music-note {
            animation: floatNote 8s ease-in-out infinite, noteHeartbeat 1.2s ease-in-out infinite;
        }

        @keyframes noteHeartbeat {
            0%, 100% {
                filter: brightness(1) drop-shadow(0 0 0px rgba(100, 255, 218, 0));
            }
            25% {
                filter: brightness(1.6) drop-shadow(0 0 10px rgba(100, 255, 218, 0.8));
            }
            50% {
                filter: brightness(1) drop-shadow(0 0 0px rgba(100, 255, 218, 0));
            }
            75% {
                filter: brightness(1.4) drop-shadow(0 0 8px rgba(100, 255, 218, 0.5));
            }
        }

        .sound-wave {
            position: fixed;
            width: 50px;
            height: 30px;
            opacity: 0.15;
        }

        .sound-wave::before,
        .sound-wave::after {
            content: '';
            position: absolute;
            width: 5px;
            background: linear-gradient(to top, rgba(100, 255, 218, 0.6), rgba(68, 138, 255, 0.6));
            border-radius: 3px;
            animation: wavePulse 2s ease-in-out infinite;
        }

        .sound-wave::before {
            left: 0;
            height: 100%;
            animation-delay: 0s;
        }

        .sound-wave::after {
            right: 0;
            height: 80%;
            animation-delay: 0.5s;
        }

        .sound-wave-1 {
            top: 20%;
            left: 5%;
        }

        .sound-wave-2 {
            bottom: 25%;
            right: 5%;
        }

        @keyframes wavePulse {
            0%, 100% {
                transform: scaleY(0.4);
                opacity: 0.15;
            }
            50% {
                transform: scaleY(1);
                opacity: 0.4;
            }
        }

        .header {
            text-align: center;
            margin-bottom: 16px;
            position: relative;
            z-index: 1;
        }

        .header h1 {
            font-size: 2.5rem;
            font-weight: 800;
            margin-bottom: 6px;
            background: linear-gradient(135deg, #64ffda 0%, #448aff 50%, #64ffda 100%);
            background-size: 200% 200%;
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
            background-clip: text;
            animation: gradientFlow 3s ease infinite;
            letter-spacing: -0.02em;
        }

        @keyframes gradientFlow {
            0%, 100% { background-position: 0% 50%; }
            50% { background-position: 100% 50%; }
        }

        .header p {
            color: rgba(255, 255, 255, 0.6);
            font-size: 1rem;
            font-weight: 400;
            letter-spacing: 0.01em;
        }

        .form-sections-grid {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 12px;
            margin-bottom: 12px;
            position: relative;
            overflow: visible;
        }

        .form-section {
            margin-bottom: 12px;
            padding: 14px;
            background: rgba(255, 255, 255, 0.03);
            border: 1px solid rgba(255, 255, 255, 0.06);
            border-radius: 16px;
            transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
            position: relative;
            overflow: visible;
            z-index: 1; /* Lower than dropdown container */
        }
        
        /* When a dropdown is open in a form-section, boost the section's z-index */
        .form-section:has(.custom-select-dropdown.open) {
            z-index: 99996 !important; /* High enough to be above other sections */
            overflow: visible !important; /* Ensure dropdown isn't clipped */
            position: relative; /* Ensure stacking context */
        }
        
        /* All other form sections should be below sections with open dropdowns */
        .form-section:not(:has(.custom-select-dropdown.open)) {
            z-index: 1 !important;
        }
        
        /* Ensure ALL inputs are always below any open dropdown */
        .form-input,
        .form-select.hidden-select,
        textarea {
            z-index: 1 !important;
            position: relative;
        }
        
        /* Prevent backdrop effects from overlapping when dropdown is open */
        .form-section:has(.custom-select-dropdown.open)::before {
            z-index: -1; /* Keep backdrop effect behind content */
            pointer-events: none; /* Don't interfere with dropdown clicks */
        }
        
        /* Ensure other form sections stay below when one has an open dropdown */
        .form-section:not(:has(.custom-select-dropdown.open)) {
            z-index: 1;
        }

        .form-section::before {
            content: '';
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: radial-gradient(circle at var(--mouse-x, 50%) var(--mouse-y, 50%), rgba(100, 255, 218, 0.08) 0%, transparent 70%);
            opacity: 0;
            transition: opacity 0.8s ease, background 0.3s ease;
            pointer-events: none;
            border-radius: 16px;
        }

        .form-section:hover::before {
            opacity: 1;
        }

        .form-section.full-width {
            grid-column: 1 / -1;
        }

        .form-section:hover {
            background: rgba(255, 255, 255, 0.05);
            border-color: rgba(100, 255, 218, 0.2);
            transform: translateY(-2px);
            box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2), 0 0 20px rgba(100, 255, 218, 0.1);
        }

        .section-header {
            margin-bottom: 10px;
            padding-bottom: 6px;
            border-bottom: 1px solid rgba(255, 255, 255, 0.08);
            transition: all 0.3s ease;
        }

        .form-section:hover .section-header {
            border-bottom-color: rgba(100, 255, 218, 0.2);
        }

        .section-header h2 {
            font-size: 1rem;
            font-weight: 700;
            color: rgba(255, 255, 255, 0.95);
            margin: 0;
            letter-spacing: 0.02em;
            display: flex;
            align-items: center;
            gap: 8px;
            transition: all 0.3s ease;
        }

        .form-section:hover .section-header h2 {
            color: rgba(255, 255, 255, 1);
        }

        .section-subtitle {
            font-size: 0.85rem;
            font-weight: 500;
            color: rgba(255, 255, 255, 0.5);
            margin-left: 4px;
        }

        .mode-toggle-wrapper {
            display: flex;
            justify-content: center;
            margin-bottom: 32px;
            position: relative;
        }

        .mode-toggle {
            display: inline-flex;
            background: transparent;
            border: none;
            padding: 0;
            position: relative;
            gap: 0;
        }

        .mode-btn {
            padding: 12px 32px;
            border: none;
            background: transparent;
            color: rgba(255, 255, 255, 0.5);
            cursor: pointer;
            transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
            font-weight: 600;
            font-size: 0.95rem;
            position: relative;
            z-index: 1;
            border-bottom: 2px solid transparent;
            margin: 0 4px;
        }

        .mode-btn:hover {
            color: rgba(255, 255, 255, 0.9);
        }

        .mode-btn.active {
            color: #64ffda;
            border-bottom-color: #64ffda;
            background: transparent;
            box-shadow: none;
            transform: none;
        }

        .mode-btn.active::after {
            content: '';
            position: absolute;
            bottom: -2px;
            left: 0;
            right: 0;
            height: 2px;
            background: #64ffda;
            opacity: 1;
            transition: opacity 0.3s ease;
        }

        .form-group {
            margin-bottom: 12px;
            position: relative;
            z-index: 1; /* Lower than dropdown container */
        }
        
        /* Ensure form elements (inputs, labels) have lower z-index than open dropdowns */
        .form-group label,
        .form-group .form-input,
        .form-group .form-select,
        .form-group textarea {
            position: relative;
            z-index: 1; /* Always below dropdowns */
        }
        
        /* Force all inputs to be below any open dropdown, even in other sections */
        .form-input,
        .form-select,
        textarea {
            z-index: 1 !important; /* Always below dropdowns */
        }

        .form-section .form-group:last-child {
            margin-bottom: 0;
        }

        .form-group label {
            display: block;
            margin-bottom: 4px;
            font-weight: 600;
            color: rgba(255, 255, 255, 0.95);
            font-size: 0.9rem;
            letter-spacing: 0.01em;
        }

        .form-group .example {
            font-size: 0.8rem;
            color: rgba(255, 255, 255, 0.5);
            margin-bottom: 6px;
            font-weight: 400;
        }

        .form-input {
            width: 100%;
            padding: 12px 16px;
            background: rgba(255, 255, 255, 0.12);
            border: 1px solid rgba(255, 255, 255, 0.2);
            border-radius: 14px;
            color: #ffffff;
            font-size: 0.95rem;
            transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
            font-family: inherit;
            position: relative;
            z-index: 1 !important; /* Always below dropdowns - use !important to override any other rules */
        }
        
        /* When a form-section has an open dropdown, ensure inputs stay below */
        .form-section:has(.custom-select-dropdown.open) .form-group label,
        .form-section:has(.custom-select-dropdown.open) .form-group .form-input,
        .form-section:has(.custom-select-dropdown.open) .form-group .form-select,
        .form-section:has(.custom-select-dropdown.open) .form-group textarea {
            z-index: 1 !important; /* Stay below dropdown */
        }
        
        /* Ensure inputs in other sections also stay below any open dropdown */
        .form-section:not(:has(.custom-select-dropdown.open)) .form-input,
        .form-section:not(:has(.custom-select-dropdown.open)) .form-select {
            z-index: 1 !important; /* Always below any open dropdown */
        }
        
        /* In other sections (without open dropdown), keep normal z-index */
        .form-section:not(:has(.custom-select-dropdown.open)) .form-group label,
        .form-section:not(:has(.custom-select-dropdown.open)) .form-group .form-input,
        .form-section:not(:has(.custom-select-dropdown.open)) .form-group .form-select,
        .form-section:not(:has(.custom-select-dropdown.open)) .form-group textarea {
            z-index: 1;
        }

        .form-select {
            width: 100%;
            padding: 12px 16px;
            background: rgba(255, 255, 255, 0.12);
            border: 1px solid rgba(255, 255, 255, 0.2);
            border-radius: 14px;
            color: #ffffff;
            font-size: 0.95rem;
            font-family: inherit;
        }

        .form-input:hover {
            background: rgba(255, 255, 255, 0.16);
            border-color: rgba(100, 255, 218, 0.4);
            transform: translateY(-1px);
            box-shadow: 0 2px 8px rgba(100, 255, 218, 0.15);
        }

        .form-select:hover {
            background: rgba(255, 255, 255, 0.16);
            border-color: rgba(100, 255, 218, 0.4);
            transform: translateY(-1px);
            box-shadow: 0 2px 8px rgba(100, 255, 218, 0.15);
        }

        .form-input:focus,
        .form-select:focus {
            outline: none;
            background: rgba(255, 255, 255, 0.18);
            border-color: #64ffda;
            box-shadow: 
                0 0 0 4px rgba(100, 255, 218, 0.15),
                0 4px 16px rgba(100, 255, 218, 0.2),
                0 0 24px rgba(100, 255, 218, 0.1);
            transform: translateY(-2px) scale(1.01);
        }

        .form-input::placeholder {
            color: rgba(255, 255, 255, 0.4);
        }

        .form-select {
            cursor: pointer;
            appearance: none;
            background-image: url("data:image/svg+xml,%3Csvg width='14' height='14' viewBox='0 0 14 14' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M3.5 5.25L7 8.75L10.5 5.25' stroke='%2364ffda' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
            background-repeat: no-repeat;
            background-position: right 18px center;
            padding-right: 48px;
        }

        /* Custom Dropdown - Proper z-index layering */
        .custom-select-container {
            position: relative;
            z-index: 1; /* Base z-index when closed */
        }
        
        /* Within a form-group, give different base z-index to multiple dropdowns */
        .form-group:nth-of-type(1) .custom-select-container {
            z-index: 10;
        }
        
        .form-group:nth-of-type(2) .custom-select-container {
            z-index: 20;
        }
        
        .form-group:nth-of-type(3) .custom-select-container {
            z-index: 30;
        }
        
        .form-group:nth-of-type(4) .custom-select-container {
            z-index: 40;
        }
        
        /* Style dropdown should always appear in front of other dropdowns - using class selector for reliability */
        .custom-select-container.select-style,
        .custom-select-container:has(#style) {
            z-index: 10050 !important; /* Higher than other dropdowns */
        }
        
        /* When style dropdown is open, ensure it's on top */
        .custom-select-container.select-style:has(.custom-select-trigger.open),
        .custom-select-container:has(#style):has(.custom-select-trigger.open) {
            z-index: 10050 !important;
        }
        
        .custom-select-container.select-style .custom-select-dropdown.open,
        .custom-select-container:has(#style) .custom-select-dropdown.open {
            z-index: 10052 !important; /* Higher than style trigger */
        }
        
        /* Fallback: target by form-group containing style select */
        .form-group:has(#style) .custom-select-container.select-style,
        .form-group:has(#style) .custom-select-container {
            z-index: 10050 !important;
        }
        
        .form-group:has(#style) .custom-select-container.select-style:has(.custom-select-trigger.open),
        .form-group:has(#style) .custom-select-container:has(.custom-select-trigger.open) {
            z-index: 10050 !important;
        }
        
        .form-group:has(#style) .custom-select-container.select-style .custom-select-dropdown.open,
        .form-group:has(#style) .custom-select-dropdown.open {
            z-index: 10052 !important;
        }
        
        /* Preset dropdown should always be below style dropdown - using class selector for reliability */
        .custom-select-container.select-preset,
        .custom-select-container:has(#preset) {
            z-index: 10040 !important; /* Lower than style (10050) */
        }
        
        .custom-select-container.select-preset:has(.custom-select-trigger.open),
        .custom-select-container:has(#preset):has(.custom-select-trigger.open) {
            z-index: 10040 !important; /* Lower than style when open */
        }
        
        .custom-select-container.select-preset .custom-select-dropdown.open,
        .custom-select-container:has(#preset) .custom-select-dropdown.open {
            z-index: 10042 !important; /* Lower than style dropdown (10052) */
        }
        
        .form-group:has(#preset) .custom-select-container.select-preset,
        .form-group:has(#preset) .custom-select-container {
            z-index: 10040 !important;
        }
        
        .form-group:has(#preset) .custom-select-container.select-preset:has(.custom-select-trigger.open),
        .form-group:has(#preset) .custom-select-container:has(.custom-select-trigger.open) {
            z-index: 10040 !important;
        }
        
        .form-group:has(#preset) .custom-select-container.select-preset .custom-select-dropdown.open,
        .form-group:has(#preset) .custom-select-dropdown.open {
            z-index: 10042 !important;
        }

        /* When dropdown is open, boost z-index to appear above everything (but style and preset have their own rules) */
        .custom-select-container:has(.custom-select-trigger.open):not(:has(#style)):not(:has(#preset)) {
            z-index: 10000 !important;
        }
        
        /* Ensure the container itself gets high z-index when dropdown is open (but not style/preset which have specific rules) */
        .custom-select-container:not(:has(#style)):not(:has(#preset)) .custom-select-dropdown.open {
            z-index: 10002 !important; /* Higher than triggers and form elements */
        }
        
        /* Make sure open dropdown appears above all other elements - use very high z-index */
        .custom-select-dropdown.open {
            z-index: 99999 !important; /* Extremely high to be above everything */
            position: absolute !important; /* Ensure absolute positioning */
        }
        
        /* Ensure dropdown container with open dropdown is above everything */
        .custom-select-container:has(.custom-select-dropdown.open) {
            z-index: 99998 !important; /* Just below the dropdown itself */
        }
        
        /* Ensure form-group containing open dropdown is also elevated */
        .form-group:has(.custom-select-dropdown.open) {
            z-index: 99997 !important;
        }
        
        /* Override: Preset dropdown should always be below style dropdown - MUST come after general rule */
        .custom-select-container.select-preset .custom-select-dropdown.open,
        .custom-select-container:has(#preset) .custom-select-dropdown.open {
            z-index: 10042 !important; /* Lower than style dropdown (10052) */
        }
        
        .form-group:has(#preset) .custom-select-container.select-preset .custom-select-dropdown.open,
        .form-group:has(#preset) .custom-select-dropdown.open {
            z-index: 10042 !important;
        }
        
        /* Override: Style dropdown should always appear in front - MUST come last to override everything */
        .custom-select-container.select-style .custom-select-dropdown.open,
        .custom-select-container:has(#style) .custom-select-dropdown.open {
            z-index: 10052 !important; /* Higher than preset (10042) and general (10002) */
        }
        
        .form-group:has(#style) .custom-select-container.select-style .custom-select-dropdown.open,
        .form-group:has(#style) .custom-select-dropdown.open {
            z-index: 10052 !important;
        }

        .custom-select-trigger {
            width: 100%;
            padding: 10px 14px;
            background: rgba(255, 255, 255, 0.1);
            border: 1px solid rgba(255, 255, 255, 0.15);
            border-radius: 12px;
            color: #ffffff;
            font-size: 0.9rem;
            cursor: pointer;
            display: flex;
            justify-content: space-between;
            align-items: center;
            transition: all 0.3s ease;
            position: relative;
            z-index: 10001 !important; /* Triggers always above dropdowns below them */
        }

        .custom-select-trigger:hover {
            background: rgba(255, 255, 255, 0.12);
            border-color: rgba(100, 255, 218, 0.3);
            box-shadow: 0 1px 6px rgba(100, 255, 218, 0.1);
        }

        .custom-select-trigger.open {
            background: rgba(255, 255, 255, 0.14);
            border-color: #64ffda;
            box-shadow: 0 0 0 3px rgba(100, 255, 218, 0.1), 0 3px 12px rgba(100, 255, 218, 0.15);
        }

        .custom-select-trigger .selected-value {
            flex: 1;
        }

        .custom-select-trigger .selected-value.placeholder {
            color: rgba(255, 255, 255, 0.45);
        }

        .custom-select-trigger .arrow {
            width: 12px;
            height: 12px;
            transition: transform 0.3s ease;
            margin-left: 10px;
        }

        .custom-select-trigger.open .arrow {
            transform: rotate(180deg);
        }

        .custom-select-dropdown {
            position: absolute;
            top: calc(100% + 6px);
            left: 0;
            right: 0;
            background: #0a0e27;
            border: 1px solid rgba(100, 255, 218, 0.2);
            border-radius: 12px;
            box-shadow: 0 6px 24px rgba(0, 0, 0, 0.5), 0 0 30px rgba(0, 0, 0, 0.3);
            max-height: 280px;
            overflow-y: auto;
            overflow-x: hidden;
            z-index: 1;
            opacity: 0;
            visibility: hidden;
            transform: translateY(-8px);
            transition: transform 0.3s ease, visibility 0.3s ease, opacity 0.3s ease;
            pointer-events: none; /* Prevent interaction when closed */
        }
        
        .custom-select-dropdown.open {
            opacity: 1;
            visibility: visible;
            transform: translateY(0);
            pointer-events: auto; /* Allow interaction when open */
            z-index: 10002 !important; /* Higher than triggers and form elements */
        }

        .custom-select-option {
            padding: 12px 14px;
            color: rgba(255, 255, 255, 0.85);
            font-size: 0.9rem;
            cursor: pointer;
            transition: background 0.2s ease, color 0.2s ease;
            border-bottom: 1px solid rgba(255, 255, 255, 0.04);
            background: #0a0e27;
        }

        .custom-select-option:last-child {
            border-bottom: none;
        }

        .custom-select-option:hover {
            background: #1e293b;
            color: #64ffda;
        }

        .custom-select-option.selected {
            background: #1e293b;
            color: #64ffda;
            font-weight: 500;
        }

        /* Custom scrollbar - sleeker */
        .custom-select-dropdown::-webkit-scrollbar {
            width: 6px;
        }

        .custom-select-dropdown::-webkit-scrollbar-track {
            background: rgba(255, 255, 255, 0.04);
            border-radius: 3px;
        }

        .custom-select-dropdown::-webkit-scrollbar-thumb {
            background: #64748b;
            border-radius: 3px;
        }

        .custom-select-dropdown::-webkit-scrollbar-thumb:hover {
            background: #94a3b8;
        }

        /* Hide native select but keep it for form submission */
        .form-select.hidden-select {
            position: absolute;
            opacity: 0;
            pointer-events: none;
            height: 0;
            width: 0;
        }

        textarea.form-input {
            resize: vertical;
            min-height: 70px;
            line-height: 1.5;
        }

        .form-row {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 10px;
        }

        .form-row.three-columns {
            grid-template-columns: 1fr 1fr 1fr;
        }

        @media (max-width: 1024px) {
            .form-sections-grid {
                grid-template-columns: 1fr;
            }

            .form-row.three-columns {
                grid-template-columns: 1fr;
            }
        }

        @media (max-width: 768px) {
            .container {
                max-width: 100%;
            }

            .form-row {
                grid-template-columns: 1fr;
            }

            .section-item .form-row {
                grid-template-columns: 1fr;
            }
        }

        @media (max-width: 640px) {
            .container {
                padding: 32px 24px;
                border-radius: 20px;
            }

            .header h1 {
                font-size: 2.25rem;
            }

            .header {
                margin-bottom: 36px;
            }

            .form-section {
                padding: 20px 16px;
                margin-bottom: 24px;
            }

            .section-header h2 {
                font-size: 1rem;
            }

            body {
                padding: 12px;
            }

            .section-item .form-row {
                grid-template-columns: 1fr !important;
            }
        }

        .optional-tag {
            background: rgba(100, 255, 218, 0.15);
            color: #64ffda;
            padding: 3px 10px;
            border-radius: 8px;
            font-size: 0.75rem;
            margin-left: 8px;
            font-weight: 500;
            border: 1px solid rgba(100, 255, 218, 0.2);
        }

        .create-btn {
            width: 100%;
            padding: 14px;
            background: linear-gradient(135deg, #64ffda 0%, #448aff 100%);
            color: #0a0e27;
            border: none;
            border-radius: 14px;
            font-size: 1rem;
            font-weight: 700;
            cursor: pointer;
            transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
            margin-top: 32px;
            text-transform: uppercase;
            letter-spacing: 0.05em;
            position: relative;
            overflow: hidden;
            box-shadow: 0 4px 16px rgba(100, 255, 218, 0.3);
        }

        .create-btn::before {
            content: '';
            position: absolute;
            top: 0;
            left: -100%;
            width: 100%;
            height: 100%;
            background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
            transition: left 0.6s ease;
        }

        .create-btn:hover::before {
            left: 100%;
        }

        .create-btn:hover {
            transform: translateY(-4px) scale(1.02);
            box-shadow: 
                0 8px 32px rgba(100, 255, 218, 0.5),
                0 0 40px rgba(68, 138, 255, 0.3);
            background: linear-gradient(135deg, #70ffdf 0%, #4d9aff 100%);
        }

        .create-btn:active {
            transform: translateY(-2px) scale(1.01);
            transition: all 0.15s ease;
        }

        .create-btn:disabled {
            opacity: 0.5;
            cursor: not-allowed;
            transform: none;
            box-shadow: none;
        }

        .create-btn:disabled::before {
            display: none;
        }

        .status {
            margin-top: 24px;
            margin-bottom: 24px;
            padding: 0;
            border-radius: 0;
            font-weight: 500;
            text-align: center;
            display: none;
            animation: slideIn 0.3s ease-out;
            border: none;
            backdrop-filter: none;
            position: relative;
            overflow: visible;
            background: transparent;
        }

        @keyframes slideIn {
            from {
                opacity: 0;
                transform: translateY(-10px);
            }
            to {
                opacity: 1;
                transform: translateY(0);
            }
        }

        .status.success {
            background: transparent;
            border: none;
            color: #4ade80;
        }

        .status.success a {
            color: #64ffda;
            text-decoration: none;
            font-weight: 600;
            border-bottom: 1px solid #64ffda;
            transition: all 0.2s ease;
        }

        .status.success a:hover {
            color: #448aff;
            border-color: #448aff;
        }

        .status.error {
            background: transparent;
            border: none;
            color: #f87171;
        }

        .status.loading {
            background: transparent;
            border: none;
            color: #fbbf24;
        }


        /* Audio player */
        .audio-player-container {
            margin-top: 24px;
            margin-bottom: 32px;
            padding: 20px;
            background: rgba(255, 255, 255, 0.05);
            border: 1px solid rgba(100, 255, 218, 0.2);
            border-radius: 16px;
            display: none;
            animation: slideIn 0.3s ease-out;
        }

        .audio-player-container.active {
            display: block;
        }

        .audio-player-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 16px;
        }

        .audio-player-title {
            font-weight: 600;
            color: rgba(255, 255, 255, 0.95);
            font-size: 1rem;
        }

        .audio-player-close {
            background: transparent;
            border: none;
            color: rgba(255, 255, 255, 0.6);
            font-size: 1.5rem;
            cursor: pointer;
            padding: 0;
            width: 24px;
            height: 24px;
            display: flex;
            align-items: center;
            justify-content: center;
            border-radius: 4px;
            transition: all 0.2s ease;
        }

        .audio-player-close:hover {
            color: rgba(255, 255, 255, 0.9);
            background: rgba(255, 255, 255, 0.1);
        }

        .audio-player {
            width: 100%;
            height: 50px;
            border-radius: 12px;
            background: rgba(255, 255, 255, 0.08);
        }

        .audio-player audio {
            width: 100%;
            height: 100%;
            outline: none;
            pointer-events: auto !important;
            cursor: pointer;
        }
        
        .audio-player audio:disabled {
            opacity: 0.5;
            cursor: not-allowed;
        }

        .audio-player audio::-webkit-media-controls-panel {
            background-color: rgba(15, 23, 42, 0.8);
        }

        .audio-player audio::-webkit-media-controls-play-button {
            background-color: #64ffda;
            border-radius: 50%;
        }

        .advanced-options {
            display: none;
            animation: fadeIn 0.4s ease-out;
        }

        .advanced-options.active {
            display: block;
        }

        @keyframes fadeIn {
            from {
                opacity: 0;
            }
            to {
                opacity: 1;
            }
        }

        @keyframes pulse {
            0%, 100% { 
                opacity: 1; 
            }
            50% { 
                opacity: 0.6; 
            }
        }

        .loading {
            animation: pulse 1.5s ease-in-out infinite;
        }

        /* Mode content wrapper */
        .mode-content-wrapper {
            position: relative;
        }

        #basic-mode,
        #advanced-mode {
            width: 100%;
            display: none;
        }

        #advanced-mode.active {
            display: flex;
            flex-direction: column;
        }

        /* Composition Mode Styles */
        .section-result {
            transition: opacity 0.2s, transform 0.2s;
        }
        
        .section-result.dragging {
            opacity: 0.5;
            transform: scale(0.98);
        }
        
        .section-result:hover {
            background: rgba(255,255,255,0.08) !important;
        }
        
        .section-item {
            background: rgba(255, 255, 255, 0.03);
            border: 1px solid rgba(255, 255, 255, 0.1);
            border-radius: 12px;
            padding: 20px;
            margin-bottom: 20px;
            position: relative;
        }
        
        .section-item .form-row {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 20px;
            margin-bottom: 0;
        }

        @media (max-width: 768px) {
            .section-item .form-row {
                grid-template-columns: 1fr !important;
            }
        }
        
        .section-item .form-column {
            display: flex;
            flex-direction: column;
            gap: 16px;
        }
        
        
        .section-item .form-group {
            margin-bottom: 0;
            display: flex;
            flex-direction: column;
        }
        
        /* Ensure all form-selects in sections have consistent styling */
        .section-item .form-select,
        .section-item .custom-select-container {
            width: 100%;
        }
        
        /* Ensure custom select triggers match input field height */
        .section-item .custom-select-trigger {
            min-height: 44px; /* Match form-input height */
            display: flex;
            align-items: center;
        }

        .section-header-row {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 16px;
            gap: 10px;
        }
        
        .section-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 20px;
        }

        .section-header-row h3 {
            font-size: 18px;
            font-weight: 600;
            color: #64ffda;
            margin: 0;
        }

        .btn-add-section,
        .btn-remove-section {
            background: rgba(100, 255, 218, 0.1);
            border: 1px solid rgba(100, 255, 218, 0.3);
            color: #64ffda;
            padding: 8px 16px;
            border-radius: 8px;
            cursor: pointer;
            font-size: 14px;
            font-weight: 500;
            transition: all 0.3s ease;
        }

        .btn-add-section:hover {
            background: rgba(100, 255, 218, 0.2);
            border-color: rgba(100, 255, 218, 0.5);
        }

        .btn-duplicate-section {
            background: rgba(100, 255, 218, 0.1);
            border: 1px solid rgba(100, 255, 218, 0.3);
            color: #64ffda;
            padding: 8px 16px;
            border-radius: 8px;
            cursor: pointer;
            font-size: 14px;
            font-weight: 500;
            transition: all 0.3s ease;
        }
        
        .btn-duplicate-section:hover {
            background: rgba(100, 255, 218, 0.2);
            border-color: rgba(100, 255, 218, 0.5);
        }
        
        .btn-remove-section {
            background: rgba(255, 82, 82, 0.1);
            border-color: rgba(255, 82, 82, 0.3);
            color: #ff5252;
            padding: 4px 12px;
            font-size: 20px;
            line-height: 1;
        }

        .btn-remove-section:hover {
            background: rgba(255, 82, 82, 0.2);
            border-color: rgba(255, 82, 82, 0.5);
        }

        .optional {
            color: rgba(255, 255, 255, 0.5);
            font-size: 0.85em;
            font-weight: normal;
        }

        #sectionsContainer {
            margin-top: 16px;
        }

