.description-form-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 1200;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.description-form-overlay.visible {
    opacity: 1;
}

.description-creator-form {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.9);
    width: 90%;
    max-width: 650px;
    background: var(--dark);
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 5px 30px rgba(0, 0, 0, 0.5);
    z-index: 1300;
    opacity: 0;
    transition: all 0.3s ease;
}

.description-creator-form.visible {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

.description-creator-form h4 {
    color: var(--secondary);
    margin-top: 0;
    text-align: center;
    margin-bottom: 20px;
    font-size: 1.4rem;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--light);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border-radius: 8px;
    border: 1px solid var(--card-border);
    background: rgba(0, 0, 0, 0.2);
    color: var(--light);
    font-size: 1rem;
    transition: border 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--secondary);
    outline: none;
}

.form-group textarea.error {
    border-color: #ff3e3e;
    animation: shake 0.5s;
}

.example-description {
    background: rgba(15, 12, 41, 0.6);
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 20px;
}

.example-title {
    margin: 0 0 8px 0;
    color: var(--secondary);
    font-weight: bold;
    font-size: 0.9rem;
}

.example-text {
    margin: 0;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
    font-style: italic;
}

.form-actions {
    display: flex;
    justify-content: space-between;
    gap: 15px;
    margin-top: 20px;
}

.generate-from-desc-btn, .cancel-desc-btn {
    flex: 1;
    padding: 12px;
    border-radius: 50px;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.95rem;
}

.generate-from-desc-btn {
    background: linear-gradient(to right, var(--secondary), #ff5e62);
    color: white;
}

.cancel-desc-btn {
    background: rgba(255, 255, 255, 0.2);
    color: var(--light);
}

.generate-from-desc-btn:hover, .cancel-desc-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.description-creator-btn {
    background: linear-gradient(to right, #9d4edd, #ff5e62);
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 50px;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: block;
    margin: 15px auto 0;
    box-shadow: 0 4px 15px rgba(157, 78, 221, 0.4);
}

.description-creator-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 94, 98, 0.6);
}

.description-creator-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Mobile optimization */
@media (max-width: 768px) {
    .description-creator-form {
        width: 95%;
        padding: 20px;
    }
}

/* Loading animation */
.description-character-loading {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 10;
    border-radius: 15px;
}

.description-character-loading .loading-spinner {
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top: 4px solid var(--secondary);
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
    margin-bottom: 15px;
}

.description-character-loading p {
    color: white;
    font-size: 1.1rem;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}