:root {
    --electric-orange: #FF6B35;
    --hot-pink: #FF006E;
    --lemon-yellow: #FFBE0B;
    --deep-purple: #7209B7;
    --sky-blue: #4CC9F0;
    --lime-green: #06FFA5;
    --dark-bg: #1A0B2E;
    --card-bg: #16213E;
    --shadow-color: rgba(255, 107, 53, 0.4);
}

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

body {
    font-family: 'Righteous', cursive;
    background: linear-gradient(135deg,
        var(--dark-bg) 0%,
        #2D1B69 25%,
        #3D2C8D 50%,
        #2D1B69 75%,
        var(--dark-bg) 100%);
    background-size: 400% 400%;
    animation: gradientShift 15s ease infinite;
    min-height: 100vh;
    color: #fff;
    overflow-x: hidden;
    position: relative;
}

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

.noise-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
    opacity: 0.05;
    pointer-events: none;
    z-index: 1;
    animation: noiseMove 8s steps(10) infinite;
}

@keyframes noiseMove {
    0%, 100% { transform: translate(0, 0); }
    10% { transform: translate(-5%, -5%); }
    20% { transform: translate(-10%, 5%); }
    30% { transform: translate(5%, -10%); }
    40% { transform: translate(-5%, 5%); }
    50% { transform: translate(-10%, -5%); }
    60% { transform: translate(10%, 0%); }
    70% { transform: translate(0%, 10%); }
    80% { transform: translate(-10%, 0%); }
    90% { transform: translate(5%, 5%); }
}

.container {
    max-width: 900px;
    margin: 0 auto;
    padding: 3rem 2rem;
    position: relative;
    z-index: 2;
}

/* Header Styling */
.header {
    text-align: center;
    margin-bottom: 4rem;
    position: relative;
}

.header-decoration {
    position: absolute;
    top: -40px;
    left: 50%;
    transform: translateX(-50%);
    width: 300px;
    height: 80px;
    background: linear-gradient(90deg,
        transparent 0%,
        var(--electric-orange) 15%,
        var(--hot-pink) 30%,
        var(--lemon-yellow) 45%,
        var(--lime-green) 60%,
        var(--sky-blue) 75%,
        transparent 100%);
    border-radius: 50%;
    filter: blur(40px);
    opacity: 0.6;
    animation: decorationPulse 3s ease-in-out infinite;
}

@keyframes decorationPulse {
    0%, 100% { transform: translateX(-50%) scale(1); opacity: 0.6; }
    50% { transform: translateX(-50%) scale(1.2); opacity: 0.8; }
}

.title {
    font-family: 'Bungee Shade', cursive;
    font-size: clamp(4rem, 15vw, 9rem);
    letter-spacing: 0.1em;
    margin: 0;
    background: linear-gradient(135deg,
        var(--electric-orange),
        var(--hot-pink),
        var(--lemon-yellow),
        var(--lime-green));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 0 30px rgba(255, 107, 53, 0.6));
    animation: titleFloat 6s ease-in-out infinite;
    text-shadow:
        4px 4px 0 rgba(114, 9, 183, 0.4),
        8px 8px 0 rgba(255, 0, 110, 0.3);
    -webkit-text-stroke: 2px rgba(255, 190, 11, 0.3);
}

@keyframes titleFloat {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    25% { transform: translateY(-10px) rotate(-1deg); }
    75% { transform: translateY(-5px) rotate(1deg); }
}

.subtitle {
    font-size: 1.5rem;
    color: var(--lemon-yellow);
    text-transform: uppercase;
    letter-spacing: 0.3em;
    margin-top: 1rem;
    font-weight: 400;
    text-shadow:
        0 0 10px rgba(255, 190, 11, 0.8),
        0 0 20px rgba(255, 190, 11, 0.4);
    animation: subtitleGlow 2s ease-in-out infinite alternate;
}

@keyframes subtitleGlow {
    from {
        text-shadow:
            0 0 10px rgba(255, 190, 11, 0.8),
            0 0 20px rgba(255, 190, 11, 0.4);
    }
    to {
        text-shadow:
            0 0 20px rgba(255, 190, 11, 1),
            0 0 40px rgba(255, 190, 11, 0.6),
            0 0 60px rgba(255, 190, 11, 0.3);
    }
}

/* Form Container */
.form-container {
    background: linear-gradient(135deg,
        rgba(22, 33, 62, 0.9),
        rgba(45, 27, 105, 0.9));
    border: 4px solid var(--electric-orange);
    border-radius: 30px;
    padding: 3rem;
    box-shadow:
        0 20px 60px rgba(0, 0, 0, 0.5),
        inset 0 -2px 40px rgba(255, 107, 53, 0.1),
        0 0 0 8px rgba(255, 107, 53, 0.2);
    position: relative;
    overflow: hidden;
}

.form-container::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: repeating-linear-gradient(
        45deg,
        transparent,
        transparent 10px,
        rgba(255, 107, 53, 0.03) 10px,
        rgba(255, 107, 53, 0.03) 20px
    );
    animation: stripesMove 20s linear infinite;
    pointer-events: none;
}

@keyframes stripesMove {
    0% { transform: translate(0, 0); }
    100% { transform: translate(50px, 50px); }
}

/* Animation */
@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-in {
    animation: slideInUp 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) backwards;
}

/* Form Elements */
.form-group {
    margin-bottom: 2rem;
    position: relative;
    z-index: 1;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.form-group--half {
    margin-bottom: 0;
}

.label {
    display: block;
    font-size: 1.1rem;
    color: var(--lemon-yellow);
    text-transform: uppercase;
    letter-spacing: 0.15em;
    margin-bottom: 0.75rem;
    text-shadow: 0 2px 10px rgba(255, 190, 11, 0.5);
    font-weight: 400;
}

.input,
.select,
.textarea {
    width: 100%;
    padding: 1rem 1.25rem;
    font-size: 1.05rem;
    font-family: 'DM Mono', monospace;
    background: rgba(26, 11, 46, 0.6);
    border: 3px solid var(--sky-blue);
    border-radius: 15px;
    color: #fff;
    outline: none;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow:
        0 4px 15px rgba(0, 0, 0, 0.3),
        inset 0 2px 8px rgba(0, 0, 0, 0.4);
}

.input:focus,
.select:focus,
.textarea:focus {
    border-color: var(--hot-pink);
    background: rgba(26, 11, 46, 0.8);
    box-shadow:
        0 8px 25px rgba(255, 0, 110, 0.4),
        inset 0 2px 8px rgba(0, 0, 0, 0.4),
        0 0 0 4px rgba(255, 0, 110, 0.2);
    transform: translateY(-2px) scale(1.01);
}

.input:hover,
.select:hover,
.textarea:hover {
    border-color: var(--lime-green);
    transform: translateY(-1px);
}

.textarea {
    resize: vertical;
    min-height: 200px;
    line-height: 1.6;
}

.select {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg width='20' height='12' viewBox='0 0 20 12' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1L10 10L19 1' stroke='%2306FFA5' stroke-width='3' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1.25rem center;
    padding-right: 3rem;
}

.select option {
    background: rgba(26, 11, 46, 0.95);
    color: #fff;
    padding: 1rem;
    font-family: 'DM Mono', monospace;
    border-radius: 0;
}

.select option:hover,
.select option:checked {
    background: linear-gradient(135deg,
        rgba(255, 107, 53, 0.3),
        rgba(255, 0, 110, 0.3));
    color: var(--lemon-yellow);
}

/* Ensure fontFamily select gets the same styling */
#fontFamily {
    width: 100%;
    padding: 1rem 1.25rem;
    font-size: 1.05rem;
    font-family: 'DM Mono', monospace;
    background: rgba(26, 11, 46, 0.6);
    border: 3px solid var(--sky-blue);
    border-radius: 15px;
    color: #fff;
    outline: none;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow:
        0 4px 15px rgba(0, 0, 0, 0.3),
        inset 0 2px 8px rgba(0, 0, 0, 0.4);
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg width='20' height='12' viewBox='0 0 20 12' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1L10 10L19 1' stroke='%2306FFA5' stroke-width='3' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1.25rem center;
    padding-right: 3rem;
}

#fontFamily:focus {
    border-color: var(--hot-pink);
    background: rgba(26, 11, 46, 0.8);
    box-shadow:
        0 8px 25px rgba(255, 0, 110, 0.4),
        inset 0 2px 8px rgba(0, 0, 0, 0.4),
        0 0 0 4px rgba(255, 0, 110, 0.2);
    transform: translateY(-2px) scale(1.01);
}

#fontFamily:hover {
    border-color: var(--lime-green);
    transform: translateY(-1px);
}

.hint {
    margin-top: 0.5rem;
    font-size: 0.9rem;
    color: var(--sky-blue);
    font-family: 'DM Mono', monospace;
    opacity: 0.8;
}

.error {
    margin-top: 0.5rem;
    font-size: 0.95rem;
    color: var(--hot-pink);
    font-weight: 500;
    text-shadow: 0 0 10px rgba(255, 0, 110, 0.6);
}

/* Custom Checkbox */
.checkbox-container {
    display: flex;
    align-items: center;
    cursor: pointer;
    user-select: none;
    padding: 1rem;
    border-radius: 12px;
    transition: background 0.3s;
    position: relative;
}

.checkbox-container:hover {
    background: rgba(255, 107, 53, 0.1);
}

.checkbox-container input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.checkmark {
    width: 32px;
    height: 32px;
    background: rgba(26, 11, 46, 0.6);
    border: 3px solid var(--sky-blue);
    border-radius: 8px;
    position: relative;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    flex-shrink: 0;
}

.checkbox-container:hover .checkmark {
    border-color: var(--lime-green);
    transform: scale(1.05);
}

.checkbox-container input:checked ~ .checkmark {
    background: var(--lime-green);
    border-color: var(--lime-green);
    box-shadow: 0 0 20px rgba(6, 255, 165, 0.6);
}

.checkbox-container input:checked ~ .checkmark::after {
    content: '';
    position: absolute;
    left: 9px;
    top: 4px;
    width: 8px;
    height: 14px;
    border: solid var(--dark-bg);
    border-width: 0 3px 3px 0;
    transform: rotate(45deg);
}

.checkbox-label {
    margin-left: 1rem;
    font-size: 1.05rem;
    color: #fff;
}

/* Generate Button */
.generate-btn {
    width: 100%;
    padding: 1.75rem 2rem;
    font-size: 1.5rem;
    font-family: 'Righteous', cursive;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    background: linear-gradient(135deg,
        var(--electric-orange),
        var(--hot-pink),
        var(--deep-purple));
    border: none;
    border-radius: 20px;
    color: #fff;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    box-shadow:
        0 10px 30px rgba(255, 107, 53, 0.5),
        0 0 0 4px rgba(255, 107, 53, 0.3),
        inset 0 -4px 0 rgba(0, 0, 0, 0.2);
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.generate-btn:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow:
        0 15px 40px rgba(255, 107, 53, 0.7),
        0 0 0 6px rgba(255, 107, 53, 0.4),
        inset 0 -4px 0 rgba(0, 0, 0, 0.2);
}

.generate-btn:active {
    transform: translateY(-1px) scale(0.98);
}

.btn-text {
    position: relative;
    z-index: 2;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.btn-shine {
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.3),
        transparent
    );
    transition: left 0.5s;
}

.generate-btn:hover .btn-shine {
    left: 100%;
}

/* Responsive */
@media (max-width: 768px) {
    .container {
        padding: 2rem 1.5rem;
    }

    .title {
        font-size: 5rem;
    }

    .subtitle {
        font-size: 1rem;
        letter-spacing: 0.2em;
    }

    .form-container {
        padding: 2rem;
        border-width: 3px;
    }

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

    .form-group--half {
        margin-bottom: 0;
    }

    .generate-btn {
        font-size: 1.25rem;
        padding: 1.5rem 1.5rem;
    }
}

@media (max-width: 480px) {
    .title {
        font-size: 3.5rem;
        letter-spacing: 0.05em;
    }

    .subtitle {
        font-size: 0.85rem;
    }

    .form-container {
        padding: 1.5rem;
    }

    .label {
        font-size: 1rem;
    }

    .input,
    .select,
    .textarea {
        padding: 0.875rem 1rem;
        font-size: 1rem;
    }
}
