/* Main container styling */
.ai-domain-generator-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 40px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    color: #333;
    background-color: #ffffff;
    border-radius: 20px;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.08);
}

/* Step styling */
.ai-domain-generator-step {
    display: none;
    padding: 40px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.04);
    margin-bottom: 30px;
    transition: all 0.4s ease;
    animation-duration: 0.5s;
    animation-fill-mode: both;
}

.ai-domain-generator-step.active {
    display: block;
    animation-name: fadeInStep;
}

@keyframes fadeInStep {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.ai-domain-generator-step h2 {
    margin-top: 0;
    color: #1a1a1a;
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 2px solid #f0f0f0;
    position: relative;
}

.ai-domain-generator-step h2:after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 60px;
    height: 2px;
    background: linear-gradient(90deg, #4d90fe, #6aa8ff);
}

.step-description {
    font-size: 18px;
    margin-bottom: 35px;
    color: #555;
    line-height: 1.6;
}

/* Form styling */
.form-group {
    margin-bottom: 35px;
}

.form-group label {
    display: block;
    margin-bottom: 12px;
    font-weight: 600;
    color: #333;
    font-size: 18px;
}

.form-control {
    width: 100%;
    padding: 16px 20px;
    border: 2px solid #e8e8e8;
    border-radius: 12px;
    font-size: 16px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.02);
    color: #444;
}

.form-control:focus {
    outline: none;
    border-color: #4d90fe;
    box-shadow: 0 0 0 4px rgba(77, 144, 254, 0.15);
}

textarea.form-control {
    min-height: 150px;
    resize: vertical;
    line-height: 1.6;
}

/* Keywords input with button */
.keywords-form-group {
    margin-bottom: 0;
}

.keywords-input-container {
    display: flex;
    gap: 15px;
    align-items: center; /* Ensure vertical alignment */
}

.keywords-input-container .form-control {
    flex: 1;
    font-size: 18px;
}

.keywords-input-container .button {
    align-self: stretch;
    margin: 0;
    height: auto; /* Ensure button takes full height */
}

/* Two columns layout for options */
.options-container {
    display: flex;
    gap: 30px;
    margin-bottom: 30px;
}

.options-column {
    flex: 1;
}

/* Radio options */
.radio-options {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 15px;
}

.radio-options label {
    font-weight: normal;
    display: flex;
    align-items: center;
    padding: 14px 20px;
    background: #f9f9f9;
    border-radius: 12px;
    transition: all 0.25s ease;
    cursor: pointer;
    border: 2px solid #f0f0f0;
    margin-bottom: 0;
}

.radio-options label:hover {
    background: #f2f2f2;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04);
}

.radio-options input {
    margin-right: 12px;
    accent-color: #4d90fe;
    width: 18px;
    height: 18px;
}

.radio-options label:has(input:checked) {
    background-color: #eef5ff;
    border-color: #4d90fe;
    box-shadow: 0 4px 15px rgba(77, 144, 254, 0.15);
}

.radio-options input:checked + span {
    color: #4d90fe;
    font-weight: 600;
}

/* Remove the background from the extensions group */
.domain-extensions-group {
    background: transparent;
    padding: 0;
    box-shadow: none;
    margin-top: 0;
}

/* Domain extension styling */
.domain-extensions-container {
    margin-top: 10px;
}

.extension-options {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.extension-options label {
    font-weight: normal;
    display: flex;
    align-items: center;
    background: #fff;
    padding: 10px 18px;
    border-radius: 30px;
    border: 2px solid #e8e8e8;
    transition: all 0.2s ease;
    cursor: pointer;
    margin-bottom: 0;
}

.extension-options label:hover {
    background: #f8f8f8;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.04);
}

.extension-options input {
    margin-right: 8px;
    accent-color: #4d90fe;
    width: 18px;
    height: 18px;
}

.extension-options label:has(input:checked) {
    background-color: #eef5ff;
    border-color: #4d90fe;
    box-shadow: 0 3px 10px rgba(77, 144, 254, 0.15);
}

.extension-options input:checked + span {
    color: #4d90fe;
    font-weight: 600;
}

/* Name style card styling */
.name-style-options {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
    margin-top: 20px;
}

.name-style-option {
    position: relative;
}

.name-style-option input[type="radio"] {
    position: absolute;
    opacity: 0;
}

.name-style-card {
    padding: 25px;
    background: #f9f9f9;
    border: 2px solid #e8e8e8;
    border-radius: 16px;
    transition: all 0.3s ease;
    height: 100%;
    cursor: pointer;
    display: flex;
    gap: 15px;
}

.name-style-card:hover {
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.06);
    transform: translateY(-3px);
}

.name-style-option input[type="radio"]:checked + label .name-style-card {
    border-color: #4d90fe;
    background-color: #eef5ff;
    box-shadow: 0 8px 25px rgba(77, 144, 254, 0.15);
}

.name-style-icon {
    width: 40px;
    height: 40px;
    background-color: #4d90fe;
    border-radius: 10px;
    flex-shrink: 0;
}

.name-style-content {
    flex-grow: 1;
}

.name-style-card h3 {
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 18px;
    color: #222;
    font-weight: 600;
}

.name-style-card p {
    margin: 0;
    color: #666;
    font-size: 14px;
    line-height: 1.5;
}

/* Style icons */
.auto-icon { background-color: #4d90fe; }
.all-icon { background-color: #6d5dfc; }
.brandable-icon { background-color: #10b981; }
.evocative-icon { background-color: #f59e0b; }
.phrase-icon { background-color: #8b5cf6; }
.compound-icon { background-color: #ec4899; }
.alternate-icon { background-color: #14b8a6; }
.non-english-icon { background-color: #ef4444; }
.real-words-icon { background-color: #3b82f6; }

/* Button styling */
.form-actions {
    margin-top: 40px;
    display: flex;
    gap: 20px;
}

/* First step: Keep the Generate button to the right of the input */
.step-1 .form-actions {
    justify-content: flex-end;
}

/* Other steps: Center all navigation buttons */
.form-actions.centered-actions {
    justify-content: center;
}

.button {
    padding: 14px 26px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    text-align: center;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 120px;
}

.button-primary {
    background: linear-gradient(135deg, #4d90fe, #3a7be8);
    color: white;
    box-shadow: 0 5px 15px rgba(77, 144, 254, 0.25);
}

.button-primary:hover {
    background: linear-gradient(135deg, #3a7be8, #2a6dd6);
    box-shadow: 0 8px 20px rgba(77, 144, 254, 0.35);
    transform: translateY(-2px);
}

.button:not(.button-primary) {
    background-color: #f5f5f5;
    color: #333;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
}

.button:not(.button-primary):hover {
    background-color: #e8e8e8;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    transform: translateY(-2px);
}

.generate-btn {
    font-size: 18px;
    border-radius: 12px;
    padding: 0 30px;
}

/* Results header with top actions */
.results-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 35px;
}

.top-actions {
    display: flex;
    gap: 15px;
}

/* Loading container with spinner */
.loading-container {
    text-align: center;
    padding: 80px 0;
}

.spinner-container {
    display: inline-block;
    position: relative;
    width: 120px;
    height: 120px;
}

.spinner {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 8px solid rgba(0, 0, 0, 0.1);
    border-radius: 50%;
    border-top-color: #4d90fe;
    animation: spin 1s ease-in-out infinite;
}

.small-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid rgba(0, 0, 0, 0.1);
    border-radius: 50%;
    border-top-color: #4d90fe;
    animation: spin 1s ease-in-out infinite;
    margin: 0 auto 15px;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.spinner-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 24px;
    font-weight: 700;
    color: #4d90fe;
}

.loading-container p {
    margin-top: 25px;
    font-size: 18px;
    color: #666;
    font-weight: 500;
}

/* Results count */
.results-count {
    background: #f5f5f5;
    padding: 10px 15px;
    border-radius: 10px;
    font-weight: 600;
    margin-bottom: 20px;
    color: #444;
    display: inline-block;
}

/* Results styling */
.domain-results-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 25px;
    margin-top: 40px;
}

.domain-result-card {
    padding: 25px;
    background: #fff;
    border: 1px solid #e8e8e8;
    border-radius: 16px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.04);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: all 0.3s ease;
}

.domain-result-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.08);
}

.domain-result-card.premium {
    border-color: #f59e0b;
    background: linear-gradient(to bottom right, #fffbeb, #fff);
    box-shadow: 0 8px 20px rgba(245, 158, 11, 0.15);
}

.domain-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
}

.domain-card-header h3 {
    margin: 0;
    font-size: 20px;
    word-break: break-word;
    color: #1a1a1a;
    font-weight: 700;
    line-height: 1.4;
}

.premium-tag {
    background: linear-gradient(135deg, #f59e0b, #f97316);
    color: white;
    padding: 5px 10px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 3px 8px rgba(245, 158, 11, 0.25);
}

.check-domain-button {
    width: 100%;
    padding: 12px;
    text-align: center;
    border-radius: 30px;
    background-color: #f8f8f8;
    border: none;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s ease;
    color: #333;
}

.check-domain-button:hover {
    background: linear-gradient(135deg, #eef5ff, #e5edff);
    color: #4d90fe;
    box-shadow: 0 4px 12px rgba(77, 144, 254, 0.15);
}

/* Modal styling */
.domain-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.6);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease;
    backdrop-filter: blur(5px);
}

.domain-modal.active {
    opacity: 1;
    visibility: visible;
}

.domain-modal-content {
    position: relative;
    background-color: #fff;
    margin: 8% auto;
    padding: 35px;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
    width: 90%;
    max-width: 650px;
    transform: translateY(-30px);
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.domain-modal.active .domain-modal-content {
    transform: translateY(0);
    opacity: 1;
}

.domain-modal-close {
    position: absolute;
    top: 20px;
    right: 25px;
    font-size: 28px;
    font-weight: bold;
    color: #aaa;
    cursor: pointer;
    transition: all 0.2s ease;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.domain-modal-close:hover {
    color: #333;
    background: #f5f5f5;
    transform: rotate(90deg);
}

.domain-modal-title {
    margin-top: 0;
    margin-bottom: 30px;
    font-size: 24px;
    font-weight: 700;
    color: #1a1a1a;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.domain-check-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 50px 0;
    width: 100%;
}

.domain-check-loading p {
    margin-top: 15px;
    margin-bottom: 0;
    color: #666;
    font-size: 16px;
    text-align: center;
    width: 100%;
}

.domain-check-results {
    display: none;
    max-height: 400px;
    overflow-y: auto;
    border-radius: 12px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.04);
    border: 1px solid #eee;
}

.domain-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid #eee;
    transition: all 0.2s ease;
}

.domain-item:hover {
    background-color: #fafafa;
}

.domain-item:last-child {
    border-bottom: none;
}

.domain-name {
    font-weight: 600;
    font-size: 18px;
    color: #333;
}

.domain-status {
    display: flex;
    align-items: center;
    gap: 15px;
    font-weight: 600;
    font-size: 16px;
}

.domain-status.available {
    color: #10b981;
}

.domain-status.not-available {
    color: #ef4444;
}

.domain-status.premium {
    color: #f59e0b;
}

.get-domain-button {
    padding: 10px 18px;
    border-radius: 30px;
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    border: none;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.2s ease;
    box-shadow: 0 3px 8px rgba(16, 185, 129, 0.2);
}

.get-domain-button:hover {
    background: linear-gradient(135deg, #059669, #047857);
    box-shadow: 0 5px 15px rgba(16, 185, 129, 0.3);
    transform: translateY(-2px);
}

.bottom-actions {
    margin-top: 50px;
}

/* Error message */
.error-message {
    background-color: #fee2e2;
    border-left: 4px solid #ef4444;
    color: #b91c1c;
    padding: 18px 20px;
    margin-bottom: 25px;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 500;
    animation: fadeInError 0.3s ease;
    box-shadow: 0 5px 15px rgba(239, 68, 68, 0.1);
}

@keyframes fadeInError {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Progress steps indicator */
.progress-steps {
    display: flex;
    justify-content: space-between;
    margin-bottom: 50px;
    position: relative;
    padding: 0 30px;
}

.progress-steps::before {
    content: '';
    position: absolute;
    top: 25px;
    left: 15px;
    right: 15px;
    height: 5px;
    background-color: #e8e8e8;
    z-index: 1;
    border-radius: 3px;
}

.progress-step {
    position: relative;
    z-index: 2;
    text-align: center;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #f5f5f5, #fff);
    color: #666;
    border-radius: 50%;
    font-weight: 700;
    font-size: 18px;
    transition: all 0.4s ease;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    border: 3px solid #e8e8e8;
}

.progress-step.active {
    background: linear-gradient(135deg, #4d90fe, #3a7be8);
    color: white;
    box-shadow: 0 5px 15px rgba(77, 144, 254, 0.3);
    transform: scale(1.15);
    border-color: #fff;
}

.progress-step.completed {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.25);
    border-color: #fff;
}

/* Responsive adjustments */
@media (max-width: 991px) {
    .ai-domain-generator-container {
        padding: 30px 20px;
        border-radius: 15px;
    }
    
    .ai-domain-generator-step {
        padding: 30px;
    }
    
    .options-container {
        flex-direction: column;
        gap: 20px;
    }
}

@media (max-width: 768px) {
    .ai-domain-generator-step {
        padding: 25px;
    }
    
    .ai-domain-generator-step h2 {
        font-size: 26px;
    }
    
    .name-style-options {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    }
    
    .domain-results-container {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 20px;
    }
    
    .results-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .top-actions {
        margin-top: 20px;
        width: 100%;
    }
    
    .top-actions button {
        flex: 1;
    }
    
    .domain-modal-content {
        width: 95%;
        margin: 20% auto;
        padding: 25px;
    }
    
    .keywords-input-container {
        flex-direction: column;
        align-items: stretch;
    }
    
    .keywords-input-container .button {
        margin-top: 15px;
    }
    
    .progress-step {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
}

@media (max-width: 576px) {
    .name-style-options {
        grid-template-columns: 1fr;
    }
    
    .domain-results-container {
        grid-template-columns: 1fr;
    }
    
    .form-actions:not(.centered-actions) {
        flex-direction: column;
    }
    
    .form-actions button {
        width: 100%;
    }
    
    .extension-options {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    
    .extension-options label {
        margin: 0;
        padding: 10px 15px;
        font-size: 14px;
    }
    
    .progress-steps {
        padding: 0 10px;
    }
    
    .progress-step {
        width: 36px;
        height: 36px;
        font-size: 14px;
        border-width: 2px;
    }
    
    .progress-steps::before {
        top: 17px;
        height: 4px;
    }
}