/* ===========================
   Base Styles
=========================== */

/* Base styles for the generator container */
.ai-x-generator-container {
    --main-bg-color: var(--container-bg-color, transparent);
    --button-bg-color: #000;
    --button-hover-bg-color: var(--generator-color, #be1e2d);
    --button-text-color: #fff;
    --input-border-color: #ccc;
    --input-focus-border-color: var(--generator-color, #be1e2d);
    --radio-bg-color: var(--generator-color, #be1e2d);
    --radio-hover-bg-color: #337ab7;
    --radio-selected-bg-color: #555;
    --error-box-color: #d9534f;
    --copy-button-bg-color: var(--generator-color, #be1e2d);
    --copy-button-text-color: #fff;
    --copy-button-hover-bg-color: #fff;
    --copy-button-hover-text-color: var(--generator-color, #be1e2d);
    --font-family: 'Arial', sans-serif;
    --result-box-border-color: #ddd;
    --result-box-min-height: 100px;
    --form-bg-color: var(--form-bg-color, transparent);
    --form-text-color: var(--form-text-color, #333333);
    --results-bg-color: var(--results-bg-color, #f9f9f9);
    --results-text-color: var(--results-text-color, #333333);
    --community-color: var(--generator-color, #be1e2d);
    --community-border: var(--generator-color, #be1e2d);
    --code-form-text-color: var(--code-form-text-color, #d4d4d4);

    border: 1px solid var(--result-box-border-color);
    border-radius: 10px;
    padding: 20px;
    background-color: var(--main-bg-color);
    font-family: var(--font-family);
    max-width: 100%;
    margin: 0 auto;
    box-sizing: border-box;
}

/* ===========================
   Form Styles
=========================== */

/* Form container */
.ai-x-generator-container .form-container {
    background-color: var(--form-bg-color);
    color: var(--form-text-color);
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
}

/* Labels */
.ai-x-generator-container label,
.ai-x-generator-container .form-container label {
    display: block;
    margin-bottom: 10px;
    font-weight: bold;
    font-size: 18px;
    color: var(--form-text-color);
}

.ai-x-generator-container label.optional {
    font-weight: bold;
    font-size: 18px;
    font-style: italic;
    color: var(--form-text-color);
}

.ai-x-generator-container label .optional-text {
    font-weight: normal;
    font-size: 90%;
    color: var(--form-text-color);
    opacity: 0.7;
}

/* Input fields */
.ai-x-generator-container input[type="text"],
.ai-x-generator-container textarea,
.ai-x-generator-container select {
    width: 100%;
    padding: 10px;
    margin-bottom: 15px;
    border: 1px solid var(--input-border-color);
    border-radius: 4px;
    font-size: 16px;
    box-sizing: border-box;
    background-color: #f9f9f9 !important;
    color: var(--form-text-color);
}

.ai-x-generator-container textarea
{
	min-height:150px;
}

.ai-x-generator-container input[type="text"]:focus,
.ai-x-generator-container textarea:focus,
.ai-x-generator-container select:focus {
    border-color: var(--input-focus-border-color);
    outline: none;
}

/* Checkbox Group */
.ai-x-generator-container .aixg-checkbox-group {
    margin-bottom: 20px;
}

.ai-x-generator-container .aixg-checkbox-options {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 10px;
    margin-top: 10px;
    margin-bottom: 10px;
}

.ai-x-generator-container .aixg-checkbox-option {
    position: relative;
    display: flex;
    align-items: center;
    margin: 0;
}

.ai-x-generator-container .aixg-checkbox-option input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.ai-x-generator-container .aixg-checkbox-option label {
    position: relative;
    padding: 10px 15px 10px 45px;
    background-color: var(--generator-color, #be1e2d);
    color: white !important;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
    margin: 0;
    font-weight: normal;
    display: block;
    box-sizing: border-box;
}

/* Checkbox Custom Icon */
.ai-x-generator-container .aixg-checkbox-option label::before {
    content: '';
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    background-color: white;
    border-radius: 3px;
    transition: all 0.3s ease;
}

/* Checkmark Icon */
.ai-x-generator-container .aixg-checkbox-option input[type="checkbox"]:checked + label::after {
    content: '✓';
    position: absolute;
    left: 19px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--generator-color, #be1e2d);
    font-size: 16px;
    font-weight: bold;
}

/* Hover and Focus States for Checkbox */
.ai-x-generator-container .aixg-checkbox-option label:hover {
    background-color: var(--radio-hover-bg-color, #337ab7);
}

.ai-x-generator-container .aixg-checkbox-option input[type="checkbox"]:focus + label {
    box-shadow: 0 0 0 2px rgba(190, 30, 45, 0.2);
}

.ai-x-generator-container .aixg-checkbox-option input[type="checkbox"]:checked + label {
    background-color: var(--radio-selected-bg-color);
}





/* Hover and focus states */
.aixg-slider-container input[type="range"]:hover,
.aixg-slider-container input[type="range"]:focus {
    opacity: 1;
}

/* Slider thumb */
.aixg-slider-container input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    background: var(--generator-color, #be1e2d);
    border-radius: 50%;
    cursor: pointer;
    border: 2px solid white;
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
    transition: all 0.2s ease;
    margin-top: -7px; /* Center the thumb on the track */
}
.aixg-slider-container input[type="range"]::-moz-range-thumb {
    width: 20px;
    height: 20px;
    background: var(--generator-color, #be1e2d);
    border-radius: 50%;
    cursor: pointer;
    border: 2px solid white;
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
    transition: all 0.2s ease;
}

/* Thumb hover and focus states */
.aixg-slider-container input[type="range"]::-webkit-slider-thumb:hover,
.aixg-slider-container input[type="range"]:focus::-webkit-slider-thumb {
    transform: scale(1.1);
    box-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.aixg-slider-container input[type="range"]::-moz-range-thumb:hover,
.aixg-slider-container input[type="range"]:focus::-moz-range-thumb {
    transform: scale(1.1);
    box-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

/* Track Styles for Webkit (Chrome, Safari, newer Edge) */
.aixg-slider-container input[type="range"]::-webkit-slider-runnable-track {
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: linear-gradient(to right, 
        var(--generator-color, #be1e2d) 0%, 
        var(--generator-color, #be1e2d) var(--slider-fill, 50%), 
        #e0e0e0 var(--slider-fill, 50%));
    cursor: pointer;
    transition: background 0.3s ease;
}

.aixg-slider-container input[type="range"]::-moz-range-track {
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: #e0e0e0;
    cursor: pointer;
}

/* Firefox Progress Fill */
.aixg-slider-container input[type="range"]::-moz-range-progress {
    height: 6px;
    border-radius: 3px;
    background: var(--generator-color, #be1e2d);
}

/* Checkbox Group Label */
.ai-x-generator-container .aixg-checkbox-group > label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    font-size: 18px;
    color: var(--form-text-color, #333333);
}

/* ===========================
   Button Styles
=========================== */

/* Generate Button */
.ai-x-generator-container .generate-button {
    background-color: var(--button-bg-color);
    color: var(--button-text-color);
    padding: 12px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    font-weight: bold;
    transition: background-color 0.3s ease;
    width: 100%;
}

.ai-x-generator-container .generate-button:hover {
    background-color: var(--button-hover-bg-color);
}

.ai-x-generator-container .generate-button:disabled,
.ai-x-generator-container .generate-button[disabled] {
    background-color: #D3D3D3; /* Default light gray */
    cursor: not-allowed;
    /* The JS will override this with the user setting if available */
}

/* Copy Button */
.ai-x-generator-container .copy-button {
    background-color: var(--copy-button-bg-color);
    color: var(--copy-button-text-color);
    border: none;
    padding: 12px 20px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    font-weight: bold;
    margin-top: 10px;
    transition: all 0.3s ease;
    width: 100%;
}

.ai-x-generator-container .copy-button:hover {
    background-color: var(--copy-button-hover-bg-color);
    color: var(--copy-button-hover-text-color);
}

/* Close Share Button */
.aixg-close-share {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
    border-radius: 16px;
    background: #f5f5f5;
    border: none;
    color: #666;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.aixg-close-share:hover {
    background: #ebebeb;
    color: #333;
}

.aixg-close-share:focus {
    box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.1);
}

/* ===========================
   Results Styles
=========================== */

/* Results Container */
.ai-x-generator-container .results-container {
    background-color: var(--results-bg-color);
    color: var(--results-text-color);
    border: 1px solid var(--result-box-border-color);
    border-radius: 4px;
    padding: 15px;
    margin-top: 20px;
    min-height: var(--result-box-min-height);
    word-wrap: break-word;
    font-size: 16px;
    line-height: 1.6;
    overflow-x: auto;
}

/* Line Container for Line-by-Line Copy Mode */
.ai-x-generator-container .line-container {
  display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid var(--result-box-border-color);
    position: relative;
}

.ai-x-generator-container .line-container:last-child {
    border-bottom: none;
}

.ai-x-generator-container .line-container p {
   margin: 0;
    flex-grow: 1;
    padding-left: 10px; /* Add consistent padding */
}

.ai-x-generator-container .line-container .line-number {
    color: var(--generator-color, #be1e2d);
    min-width: 30px; /* Fixed width for numbers */
    text-align: right;
    font-weight: bold;
    user-select: none; /* Prevent selection of line numbers */
}

.ai-x-generator-container .line-container .line-text {
    padding-left: 5px;
    line-height: 1.5;
    display: block;
    width: 100%;
}

/* Enhanced styles for list items in line-by-line mode */
.ai-x-generator-container .line-container .line-text ul,
.ai-x-generator-container .line-container .line-text ol {
    margin: 0;
    padding-left: 20px;
}

.ai-x-generator-container .line-container .line-text li {
    margin: 0;
    padding: 0;
}

/* Handle case where line is a direct list item */
.ai-x-generator-container .line-container .line-text > ul,
.ai-x-generator-container .line-container .line-text > ol {
    margin-left: -20px;
}

.ai-x-generator-container .line-container .line-button-wrapper {
    margin-left: 10px;
}



.ai-x-generator-container .line-container .copy-button {
    margin-top: 0;
    margin-left: 10px;
    width: auto;
    white-space: nowrap;
    padding: 6px 12px;
    font-size: 14px;
}

.ai-x-generator-container .line-containers-wrapper {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
}

/* ===========================
   Radio Button Styles
=========================== */

/* Hide default radio buttons */
.ai-x-generator-container .input-container input[type="radio"] {
    display: none;
}

/* Custom radio labels */
.ai-x-generator-container .input-container .radio-label {
    display: inline-block;
    padding: 10px 15px;
    background-color: var(--radio-bg-color);
    color: white !important;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    margin-right: 10px;
    margin-bottom: 10px;
}

.ai-x-generator-container .input-container .radio-label:hover {
    background-color: var(--radio-hover-bg-color);
}

.ai-x-generator-container .input-container input[type="radio"]:checked + .radio-label {
    background-color: var(--radio-selected-bg-color);
}

/* ===========================
   Error Styles
=========================== */

/* Error Box */
.ai-x-generator-container .error-box {
    background-color: #ffebee;
    border: 1px solid var(--error-box-color);
    color: var(--error-box-color);
    padding: 10px;
    border-radius: 4px;
    margin-top: 10px;
}

/* Form Validation */
.ai-x-generator-container input.error,
.ai-x-generator-container textarea.error,
.ai-x-generator-container select.error {
    border: 2px solid #ff0000;
}

.ai-x-generator-container .field-error-message {
    color: #dc3232;
    font-size: 12px;
    margin-top: 5px;
    padding: 3px 8px;
    background-color: rgba(220, 50, 50, 0.1);
    border-radius: 3px;
}

.ai-x-generator-container input.error + .field-error-message,
.ai-x-generator-container textarea.error + .field-error-message,
.ai-x-generator-container select.error + .field-error-message {
    display: block;
}

/* ===========================
   Honeypot Field Styles
=========================== */

/* Honeypot Field */
.ai-x-gen-hp-field {
    position: absolute !important;
    width: 0 !important;
    height: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

/* ===========================
   Community Styles
=========================== */

/* Community Byline */
.aixg-community-byline {
    margin-top: 20px;
    text-align: center;
    background-color: #f5f5f5;
    padding: 15px;
    border-radius: 5px;
    display: none;
}

.aixg-community-byline p {
    margin-bottom: 10px;
    font-size: 16px;
    color: #333;
    font-weight: bold;
}

/* Community Button */
.aixg-community-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 20px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    margin-top: 10px;
}

.aixg-community-button:hover {
    opacity: 0.9;
    text-decoration: none;
    border: 1px solid var(--community-border, #be1e2d);
    color: var(--community-color, #be1e2d);
}

.aixg-community-button-inline {
    background: none;
    border: none;
    padding: 4px;
    cursor: pointer;
    color: var(--generator-color, #4496D2);
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    border-radius: 4px;
}

.aixg-community-button-inline:hover {
    background-color: rgba(0, 0, 0, 0.05);
    opacity: 1;
}

.aixg-community-button-inline:active {
    transform: translateY(1px);
}

.aixg-icon-wrapper {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    margin-right: 8px;
}

.aixg-icon-wrapper svg {
    width: 100%;
    height: 100%;
    fill: currentColor;
}

.aixg-community-icon {
    width: 24px;
    height: 24px;
    margin-right: 8px;
    object-fit: contain;
}

/* ===========================
   Voting Container Styles
=========================== */

/* ===========================
   Mobile Responsive Adjustments for Voting Container
=========================== */

@media (max-width: 768px) {
    .aixg-voting-container {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }

    .aixg-voting-wrapper {
        flex-direction: column;
        align-items: center;
        gap: 15px;
    }

    .aixg-voting-section {
        flex: none;
        width: 100%;
        justify-content: center;
        text-align: center;
    }

    .aixg-vote-buttons {
        width: 100%;
        justify-content: center;
        gap: 10px;
    }

    .aixg-share-section {
        flex: none;
        width: 100%;
        justify-content: center;
        text-align: center;
		display: flex !important; /* Ensure visibility on mobile */
		visibility: visible !important;
    }

    .aixg-voting-text {
        font-size: 14px;
		white-space:wrap;
    }

    .aixg-share-text {
        font-size: 14px;
        margin-bottom: 8px;
    }

    .aixg-vote-button,
    .aixg-share-button-inline {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }

    .aixg-community-button {
        font-size: 14px;
        padding: 8px 16px;
    }
}

@media (max-width: 480px) {
    .aixg-voting-wrapper {
        flex-direction: column;
        gap: 10px;
    }

    .aixg-voting-section
    {
        flex: none;
        width: 100%;
        text-align: center;
    }
	
	 .aixg-share-section
	 
	 {
		 justify-content: center !important;
	 }

    .aixg-vote-buttons {
        flex-wrap: wrap;
        justify-content: center;
        gap: 8px;
    }

    .aixg-voting-text {
        font-size: 12px;
		white-space:wrap;
    }

    .aixg-share-text {
        font-size: 12px;
    }

    .aixg-vote-button,
    .aixg-share-button-inline {
        width: 36px;
        height: 36px;
        font-size: 14px;
    }

    .aixg-community-button {
        font-size: 12px;
        padding: 6px 12px;
    }
}



/* Voting Container */
.aixg-voting-container {
    display: flex;
    justify-content: center; /* Centers the wrapper */
    background-color: #f9fafc;
    border-radius: 8px;
    padding: 16px 20px;
    box-sizing: border-box;

}

.aixg-voting-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between; /* Space out Voting and Share sections */
    width: 100%;

    gap: 20px;
}




/* Voting Section */
.aixg-voting-section {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 3; /* Takes up 75% of the space */
}



/* Voting Text */
.aixg-voting-text {
    font-size: 16px;
    font-weight: 500;
    color: #333;
    margin: 0;
    white-space: nowrap;
}

/* Vote Buttons */
.aixg-vote-buttons {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Share Section */
.aixg-share-section {
    display: flex;
    align-items: center;
    justify-content: flex-end; /* Aligns content to the right */
    gap: 8px;
    flex: 1; /* Takes up 25% of the space */
}

.aixg-vote-thankyou {
    display: none;
    text-align: center;
    padding: 10px;
}
.aixg-voting-section .aixg-vote-buttons {
    display: flex;
    gap: 10px;
}

.aixg-voting-section,
.aixg-share-section {
    display: inline-flex; /* Treat these sections as inline-flex containers */
    align-items: center;  /* Align items vertically */
    gap: 10px;
}
.aixg-share-button-inline {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background-color: var(--copy-button-bg-color);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s ease;
    font-size: 20px;
}



.aixg-share-button-inline:hover {
    background-color: #337ab7;
}


/* Share Text */
.aixg-share-text {
    font-size: 14px;
    color: #333;
    margin: 0;
    margin-right: 5px;
    display: flex;
    align-items: center;
}


/* Vote Buttons */
.aixg-vote-button {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.3s ease;
    font-size: 20px;
}

.aixg-vote-button:hover {
    background-color: #e0e0e0;
    border-color: #bbb;
}

.aixg-vote-button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.aixg-vote-button .dashicons {
    margin: 0;
    font-size: 20px;
}

.aixg-vote-button.good {
    background-color: #4CAF50;
    color: #fff;
}

.aixg-vote-button.bad {
    background-color: #F44336;
    color: #fff;
}


.aixg-vote-button.good:hover {
    background-color: #4CAF50;
    color: #ffffff;
}

.aixg-vote-button.bad:hover {
    background-color: #F44336;
    color: #ffffff;
}

.aixg-thank-you {
 font-weight: bold !important;
  color: white;
  font-size: 16px;
  margin: 0 0 0 0;
  align-content: center;
  background: var(--copy-button-bg-color);
  border-radius: 5px;
  padding: 5px;
}

/* ===========================
   Slider Styles
=========================== */
/* Enhanced slider styles */
.aixg-slider-container {
    position: relative;
    width: 100%;
    padding: 35px 10px 45px;
    margin-bottom: 20px;
}

/* Floating value bubble */
.aixg-slider-value {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    background: var(--generator-color, #be1e2d);
    color: white;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 500;
    opacity: 0.9;
    transition: left 0.2s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    pointer-events: none;
    white-space: nowrap;
    z-index: 1;
}

.aixg-slider-value::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    transform: translateX(-50%);
    border-left: 6px solid transparent;
    border-right: 6px solid transparent;
    border-top: 6px solid var(--generator-color, #be1e2d);
}

/* Enhanced range input */
.aixg-slider-container input[type="range"] {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 6px;
    background: transparent; /* Remove default background */
    border-radius: 3px;
    outline: none;
    opacity: 0.9;
    transition: all 0.2s ease;
    margin: 10px 0;
}

/* Hover and focus states */
.aixg-slider-container input[type="range"]:hover,
.aixg-slider-container input[type="range"]:focus {
    opacity: 1;
}

/* Slider thumb */
.aixg-slider-container input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    background: var(--generator-color, #be1e2d);
    border-radius: 50%;
    cursor: pointer;
    border: 2px solid white;
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
    transition: all 0.2s ease;
    margin-top: -7px; /* Center the thumb on the track */
}
.aixg-slider-container input[type="range"]::-moz-range-thumb {
    width: 20px;
    height: 20px;
    background: var(--generator-color, #be1e2d);
    border-radius: 50%;
    cursor: pointer;
    border: 2px solid white;
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
    transition: all 0.2s ease;
}

/* Thumb hover and focus states */
.aixg-slider-container input[type="range"]::-webkit-slider-thumb:hover,
.aixg-slider-container input[type="range"]:focus::-webkit-slider-thumb {
    transform: scale(1.1);
    box-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.aixg-slider-container input[type="range"]::-moz-range-thumb:hover,
.aixg-slider-container input[type="range"]:focus::-moz-range-thumb {
    transform: scale(1.1);
    box-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

/* Track Styles for Webkit (Chrome, Safari, newer Edge) */
.aixg-slider-container input[type="range"]::-webkit-slider-runnable-track {
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: linear-gradient(to right, 
        var(--generator-color, #be1e2d) 0%, 
        var(--generator-color, #be1e2d) var(--slider-fill, 50%), 
        #e0e0e0 var(--slider-fill, 50%));
    cursor: pointer;
    transition: background 0.3s ease;
}

.aixg-slider-container input[type="range"]::-moz-range-track {
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: #e0e0e0;
    cursor: pointer;
}

/* Firefox Progress Fill */
.aixg-slider-container input[type="range"]::-moz-range-progress {
    height: 6px;
    border-radius: 3px;
    background: var(--generator-color, #be1e2d);
}

/* Labels container */
.aixg-slider-labels {
    display: flex;
    justify-content: space-between;
    margin-top: 8px;
    padding: 0 10px;
    position: absolute;
    bottom: 0;
    width: calc(100% - 20px);
}

/* Min/Max labels */
.aixg-slider-min-label,
.aixg-slider-max-label {
    font-size: 13px;
    font-weight: 500;
    padding: 4px 10px;
    border-radius: 12px;
    background: var(--generator-color, #be1e2d);
    color: white;
    opacity: 0.9;
    transition: opacity 0.2s ease;
    position: relative;
}

.aixg-slider-min-label:hover,
.aixg-slider-max-label:hover {
    opacity: 1;
}

/* Slider tick marks for key positions */
.aixg-slider-ticks {
    position: absolute;
    width: calc(100% - 20px);
    height: 20px;
    display: flex;
    justify-content: space-between;
    padding: 0 10px;
    pointer-events: none;
    bottom: 25px;
    left: 0;
}

.aixg-slider-tick {
    position: relative;
    width: 2px;
    height: 10px;
    background: #ccc;
}

.aixg-slider-tick.active {
    background: var(--generator-color, #be1e2d);
}


/* ===========================
   Dropdown Styles
=========================== */

/* Dropdown Wrapper */
.aixg-dropdown-wrapper {
    position: relative;
    width: 100%;
}

/* Other Input Container */
.aixg-other-input-container {
    margin-top: 10px;
    transition: all 0.3s ease;
    position: relative;
}

.aixg-other-input {
    width: 100%;
    min-height: 60px;
    padding: 8px;
    border: 1px solid var(--input-border-color);
    border-radius: 4px;
    resize: vertical;
    background-color: var(--form-bg-color);
    color: var(--form-text-color);
}

.aixg-other-input:focus {
    border-color: var(--input-focus-border-color);
    outline: none;
    box-shadow: 0 0 0 1px var(--input-focus-border-color);
}

/* ===========================
   Share Button and Popup Styles
=========================== */

/* Share Overlay */
.aixg-share-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(2px);
    z-index: 999999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.aixg-share-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Share Popup */
.aixg-share-popup {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.95);
    background: white;
    padding: 30px;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    z-index: 1000000;
    visibility: hidden;
    opacity: 0;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    width: 320px;
    max-width: calc(100vw - 40px);
}

.aixg-share-popup.active {
    visibility: visible;
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

.aixg-share-popup h3 {
    margin: 0 0 20px 0;
    font-size: 18px;
    color: #333;
    font-weight: 600;
}

/* Share Loading */
.aixg-share-loading {
    display: none;
    text-align: center;
    padding: 20px;
}

.aixg-spinner {
    display: inline-block;
    width: 30px;
    height: 30px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid var(--generator-color, #4496D2);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Share Options */
.aixg-share-options {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
}

.aixg-share-option .dashicons,
.aixg-share-option svg {
    margin-right: 12px;
    width: 20px;
    height: 20px;
}

.aixg-share-whatsapp {
    background: #25D366;
}

.aixg-share-facebook {
    background: #1877F2;
}

.aixg-share-x {
    background: #000000;
}

.aixg-share-copy {
    background: #6c757d;
}

.aixg-share-option {
    display: flex;
    align-items: center;
    padding: 12px;
    border-radius: 8px;
    color: white;
    cursor: pointer;
    font-size: 14px;
    border: none;
    text-align: left;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: all 0.2s ease;
}

.aixg-share-option:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.aixg-share-whatsapp:hover {
    background: #1ea952;
}

.aixg-share-facebook:hover {
    background: #1661c6;
}

.aixg-share-x:hover {
    background: #333;
}

.aixg-share-copy:hover {
    background: #5a6268;
}

.aixg-share-option:active {
    transform: translateY(0);
}

/* Close Share Button Refinements */
.aixg-close-share {
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
}

/* ===========================
   Community Styles for Code Mode
=========================== */

/* Dark Mode Compatibility for Code Mode */
.ai-x-generator-container.ai-x-generator-code .aixg-community-byline {
    background-color: var(--code-form-bg-color, #f5f5f5);
    color: var(--code-form-text-color, #000000);
}

.ai-x-generator-container.ai-x-generator-code .aixg-community-button {
    background-color: var(--community-button-bg-color, #25D366);
    color: var(--community-button-text-color, #ffffff);
}

.ai-x-generator-container.ai-x-generator-code .aixg-community-button:hover {
    background-color: transparent;
    border: 2px solid var(--community-button-bg-color, #25D366) !important;
    color: var(--community-button-bg-color, #25D366) !important;
}

/* ===========================
   Code Generator Specific Styles
=========================== */

/* Code Generator Container */
.ai-x-generator-container.ai-x-generator-code {
    --main-bg-color: var(--code-container-bg-color, transparent);
    --form-bg-color: var(--code-form-bg-color, transparent);
    --form-text-color: var(--code-form-text-color, #d4d4d4);
    --results-bg-color: var(--code-results-bg-color, #1e1e1e);
    --results-text-color: var(--code-results-text-color, #d4d4d4);
}

/* ===========================
   Share Menu Styles
=========================== */

/* Share Menu */
.aixg-share-menu {
    display: inline-block;
    margin-left: 10px;
}

/* ===========================
   Responsive Styles
=========================== */

/* General Responsive Adjustments */
@media (max-width: 768px) {
    .ai-x-generator-container input[type="text"],
    .ai-x-generator-container textarea,
    .ai-x-generator-container select,
    .ai-x-generator-container .generate-button {
        font-size: 14px;
    }

    .ai-x-generator-container .results-container {
        font-size: 14px;
    }

    .aixg-checkbox-options {
        flex-wrap: wrap;
        gap: 10px;
    }
}

@media (max-width: 480px) {
    /* Checkbox Options */
    .ai-x-generator-container .aixg-checkbox-options {
        display: flex;
        flex-direction: column;
        gap: 5px;
    }

    /* Voting Container */
  .aixg-voting-container {
        flex-direction: column;
        gap: 15px;
        text-align: center;
		padding-left:0px;
		padding-right:0px;
    }
	
	
	.aixg-voting-section {
        flex: none;
        width: 100%;
        justify-content: left;
    }
    .aixg-share-section
	{
		
	flex: none;
        width: 100%;
        justify-content: center;	
	}
	

/* Voting Section (75%) */
.aixg-voting-section {
        flex: none;
        width: 100%;
    }

    .aixg-vote-buttons {
        width: 100%;
        justify-content: center;
    }

    .aixg-share-section {
        flex: auto;
    width: 100%;
    border-top: 1px solid lightgray;
    padding-top: 20px;
    border-bottom: 1px solid lightgray;
    padding-bottom: 20px;
    }

    .aixg-voting-text {
        font-size: 14px;
    text-align: left;
    border-right: 1px solid lightgray;
	white-space: wrap !important;
    }

    .aixg-share-text {
        font-size: 14px;

   
    text-align: left;
    }

    .aixg-vote-button {
        font-size: 14px;
        padding: 6px 12px;
       
    }
	
	.aixg-vote-button,
.aixg-share-button-inline {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.3s ease;
    font-size: 20px;
}

    .aixg-vote-button .dashicons {
        font-size: 18px;
    }

    .aixg-community-button {
        padding: 8px 16px;
        font-size: 14px;
    }

    .aixg-community-icon,
    .aixg-icon-wrapper {
        width: 20px;
        height: 20px;
        margin-right: 6px;
    }

    .aixg-community-byline p {
        font-size: 14px;
    }

    /* Share Popup Adjustments */
    .aixg-share-popup {
        width: calc(100% - 32px);
        min-width: auto;
        max-width: calc(100% - 32px);
        padding: 20px;
        
    }

    .aixg-share-options {
        display: grid;
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .aixg-share-option {
        padding: 12px;
        border-radius: 8px;
        font-size: 14px;
    }
}

/* ===========================
   Accessibility Styles
=========================== */

/* Focus States for Accessibility */
.aixg-share-option:focus-visible,
.aixg-share-button:focus-visible,
.aixg-close-share:focus-visible {
    outline: 2px solid var(--generator-color, #4496D2);
    outline-offset: 2px;
}

/* ===========================
   Additional Styles
=========================== */

/* Fix for SVG icons in buttons */
.aixg-icon-wrapper svg path {
    fill: currentColor !important;
}

/* Button Hover State Refinements */
.aixg-community-button:hover {
    filter: brightness(1.1);
    transform: translateY(-1px);
}

.aixg-community-button:active {
    transform: translateY(0);
}

/* Dropdown with Other Option Styling */
.has-other-option-wrapper {
    background: #f8f8f8;
    padding: 8px;
    border-radius: 4px;
    margin: 10px 0;
}

.aixg-other-input.error {
    border-color: #dc3232;
}
/* ===========================
   Copy-All Output (Non-Code Mode)
=========================== */


.ai-x-generator-container ul {
    list-style-type: disc; /* Adds bullet points */
    margin: 10px 0;
    padding-left: 20px;
    color: var(--form-text-color, #333333); /* Inherits form text color */
}

.ai-x-generator-container li {
    margin-bottom: 5px;
    font-size: 16px;
    line-height: 1.5;
    color: var(--form-text-color, #333333); /* Inherits form text color */
}

.ai-x-generator-container li::marker {
    color: var(--generator-color, #be1e2d); /* Custom bullet color */
}


/* Non-code generator styling */
.ai-x-generator-container:not(.ai-x-generator-code) .results-container .line-number {
    position: absolute;
    left: 0;
    width: 1em;
    text-align: right;
    padding-right: 0.5em;
    color: var(--generator-color, #be1e2d); /* Use specified text color */
    user-select: none;
    border: none;
    background-color: var(--form-bg-color, #f9f9f9); /* Match form background */
    z-index: 1;
    position: sticky;
}
/* Update these CSS rules in shortcode.css */

/* Radio Group Container */
.aixg-radio-group {
    display: flex;
    flex-direction: column;
    margin-bottom: 20px;
}
/* Radio Group Label */
.aixg-radio-group-label {
    display: block;
    margin-bottom: 15px;
    font-weight: bold;
    font-size: 18px;
    width: 100%;
}
.aixg-radio-options {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 10px;
}

/* Radio Options */
.aixg-radio-option {
    display: inline-flex;
    align-items: center;
    margin: 0;
}

.aixg-radio-option input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.aixg-radio-option label {
    position: relative;
    padding: 10px 15px 10px 45px;
    background-color: var(--generator-color, #be1e2d);
    color: white !important;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
    margin: 0;
    font-weight: normal;
    display: inline-block;
    min-width: 120px;
    text-align: left;
}





/* Hover and Focus States */
.aixg-radio-option label:hover {
    background-color: var(--radio-hover-bg-color, #337ab7);
}

.aixg-radio-option input[type="radio"]:focus + label {
    box-shadow: 0 0 0 2px rgba(190, 30, 45, 0.2);
}

.aixg-radio-option input[type="radio"]:checked + label {
    background-color: var(--radio-selected-bg-color, #555);
}

/* Error State */
.aixg-radio-group.error {
    border-radius: 4px;
    padding: 10px;
    background-color: rgba(255, 0, 0, 0.05);
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .aixg-radio-group {
        gap: 8px;
    }
    
    .aixg-radio-option label {
        padding: 8px 12px 8px 40px;
        min-width: 100px;
        font-size: 14px;
    }
}

@media (max-width: 480px) {
    .aixg-radio-option {
        width: 100%;
    }
    
    .aixg-radio-option label {
        width: 100%;
        padding: 10px 10px 10px 35px;
    }
}

@media (max-width: 768px) {
    .ai-x-generator-container .line-container {
        flex-wrap: wrap;
    }
    
    .ai-x-generator-container .line-container p {
        width: calc(100% - 40px);
        padding-left: 5px;
    }
    
    .ai-x-generator-container .line-container .line-button-wrapper {
        width: 100%;
        margin-left: 35px;
        margin-top: 8px;
    }
    
    .ai-x-generator-container .line-container .copy-button {
        margin-left: 0;
    }
}
