#ae-ai-root {
    font-family: 'Montserrat', 'Segoe UI', Arial, sans-serif;
    max-width: 1200px;
    margin: 48px auto;
    padding: 32px 36px 32px 36px;
    border: none;
    display: flex;
    justify-content: center;
    align-items: flex-start;
}

.ae-ai-container {
    display: flex;
    width: 100%;
    gap: 48px;
}

.ae-ai-form-col {
    flex: 1 1 340px;
    background: #fff;
    border-radius: 18px;
    padding: 32px 30px 26px 30px;
    box-shadow: 0 2px 12px 0 #b7bad62b;
    display: flex;
    flex-direction: column;
    gap: 22px;
    min-width: 320px;
}

.ae-ai-preview-col {
    flex: 1 1 330px;
    background: #fff;
    border-radius: 18px;
    padding: 26px 22px 18px 22px;
    box-shadow: 0 2px 12px 0 #b7bad62b;
    min-width: 280px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.ae-ai-form-col h2 {
    font-size: 1.7em;
    font-weight: 800;
    margin-bottom: 10px;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.ae-ai-logo {
    font-size: 1.3em;
}

.ae-ai-label {
    font-weight: 500;
    display: flex;
    flex-direction: column;
    margin-bottom: 6px;
    font-size: 1.05em;
    color: #283a53;
    gap: 7px;
}

.ae-ai-form-col textarea,
.ae-ai-form-col select {
    padding: 13px 12px;
    font-size: 1.12em;
    margin-top: 4px;
    border-radius: 9px;
    border: 1.5px solid #e4e6ef;
    outline: none;
    background: #f7f9fc;
    margin-bottom: 4px;
    font-family: inherit;
    transition: border 0.2s;
}

.ae-ai-form-col textarea:focus,
.ae-ai-form-col select:focus {
    border: 1.5px solid #a2adce;
    background: #f4f6fa;
}

.ae-ai-form-col textarea {
    min-height: 72px;
    resize: vertical;
}

.ae-ai-form-col button {
    background: #1C1C1C;
    color: #fff;
    padding: 14px 36px;
    font-size: 1em;
    border: none;
    border-radius: 9px;
    margin-top: 10px;
    cursor: pointer;
    box-shadow: 0 1.5px 8px #b7bad626;
    margin-bottom: 4px;
    transition: background 0.3s, box-shadow 0.3s, opacity 0.2s;
    max-width: 400px;
    align-self: flex-start;
}

.ae-ai-form-col button:hover:not(:disabled) {
    background: #333;
    box-shadow: 0 2.5px 14px #b7bad62a;
}

.ae-ai-form-col button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    background: #999;
}

.ae-ai-image-preview {
    min-height: 320px;
    min-width: 240px;
    background: linear-gradient(120deg, #f3f5fc 80%, #e8e9f1 100%);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 12px 0 #b7bad62b;
    position: relative;
    width: 100%;
    margin-bottom: 10px;
}

.ae-ai-preview-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    color: #a0a1b8;
    font-size: 1.12em;
    gap: 8px;
}

.ae-ai-preview-icon {
    font-size: 2.4em;
}

.ae-ai-image-generated {
    max-width: 100%;
    max-height: 380px;
    border-radius: 12px;
    box-shadow: 0 1.5px 8px #b7bad62b;
}

.ae-ai-slider {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 4px;
    margin-top: 10px;
}

.ae-ai-slider-thumb {
    transition: transform 0.2s, box-shadow 0.2s;
}

.ae-ai-slider-thumb:hover {
    transform: scale(1.05);
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

.ae-ai-slider-thumb.selected {
    transform: scale(1.1);
    box-shadow: 0 2px 12px rgba(0,0,0,0.3);
}

.ae-generation-info {
    display: none;
    background: linear-gradient(145deg, #f7f7fb, #ffffff);
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.05);
    font-family: 'Poppins', sans-serif;
    color: #333;
    font-size: 15px;
    line-height: 1.6;
    margin-bottom: 20px;
    max-width: 90%;
    margin-inline: auto;
    text-align: center;
}

.disabled {
    background: #999 !important;
    cursor: not-allowed !important;
    opacity: 0.6 !important;
}

.disabled:hover {
    background: #999 !important;
}

#ae-confirmation {
    padding: 12px;
    border-radius: 8px;
    font-weight: 500;
    text-align: center;
    margin-top: 10px;
}

@media (min-width: 901px) {
    .flex, .ae-buttons {
        display: flex;
        justify-content: space-between;
        gap: 12px;
    }

    .flex > label {
        flex: 1;
        min-width: 0;
    }

    .ae-buttons {
        flex-direction: column;
        gap: 8px;
    }

    .ae-buttons button {
        width: 100%;
        max-width: none;
    }
}

.ae-ai-image-choice-wrapper {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
    max-width: 100%;
}

.ae-ai-imageChoice-item {
    cursor: pointer;
    width: 100px;
    text-align: center;
    border: 2px solid transparent;
    border-radius: 8px;
    overflow: hidden;
    transition: border 0.3s;
    flex-shrink: 0;
}

.ae-ai-imageChoice-item img {
    width: 100%;
    height: auto;
    display: block;
}

.ae-ai-imageChoice-item .label {
    font-size: 12px;
    padding: 5px 4px;
    background: #f9f9f9;
    color: #333;
}

.ae-ai-imageChoice-item.selected {
    border-color: #333;
    background: #eee;
}



/* --------- RESPONSIVE MOBILE ----------- */
@media (max-width: 900px) {
    #ae-ai-root {
        padding: 18px 3vw;
        max-width: 99vw;
    }

    .ae-ai-container {
        flex-direction: column;
        gap: 32px;
    }

    .ae-ai-form-col,
    .ae-ai-preview-col {
        min-width: 0;
        width: 100%;
        max-width: 100%;
        padding: 18px 6vw;
    }

    .ae-ai-image-preview {
        min-height: 210px;
        min-width: 100px;
        max-width: 100%;
    }

    .ae-buttons {
        flex-direction: column;
        gap: 12px;
    }

    .ae-buttons button {
        width: 100%;
        max-width: none;
    }
}

@media (max-width: 600px) {
    #ae-ai-root {
        padding: 7px 1vw;
        border-radius: 9px;
        margin: 0;
    }

    .ae-ai-container {
        gap: 12px;
    }

    .ae-ai-form-col,
    .ae-ai-preview-col {
        border-radius: 10px;
        padding: 13px 2vw;
        gap: 13px;
    }

    .ae-ai-form-col button {
        padding: 12px 2vw;
        font-size: 1em;
        width: 100%;
        max-width: 99vw;
    }

    .ae-ai-image-preview {
        min-height: 110px;
        min-width: 60px;
        border-radius: 8px;
    }

    .ae-ai-slider {
        justify-content: center;
    }
}