/* Stili specifici per il generatore di password/username */

/* Contenitore principale del generatore */
.ii-generator-container {
    background-color: #ffffff;
    border-radius: 1.5rem; /* Bordi più arrotondati */
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1); /* Ombra più pronunciata */
    padding: 2.5rem; /* Padding aumentato */
    max-width: 900px; /* Aumentato per ospitare il layout a due colonne */
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 1.5rem; /* Spazio tra gli elementi */
    margin: 2rem auto; /* Aggiunto margine per centrare e distanziare le card */
}

.ii-generator-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem; /* Spazio tra le colonne */
}

@media (min-width: 768px) {
    .ii-generator-grid {
        grid-template-columns: 1fr 1fr; /* Due colonne su schermi medi e grandi */
    }
}

.ii-generator-h1 {
    font-size: 2rem; /* Ridotto da 2.25rem (text-3xl) a 2rem */
    font-weight: 700; /* font-bold */
    text-align: center;
    margin-bottom: 1.5rem; /* mb-6 */
    color: #FA6803;
}

.ii-generator-flex-col-gap-4 {
    display: flex;
    flex-direction: column;
    gap: 1rem; /* gap-4 */
}

.ii-generator-slider-container {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 1.25rem; /* Adjusted for consistency */
}

.ii-generator-label {
    font-size: 1rem; /* Ridotto da 1.125rem (text-lg) a 1rem */
    font-weight: 600; /* font-semibold */
    color: #4b5563; /* text-gray-700 */
}

.ii-generator-range-input {
    width: 100%;
    height: 0.5rem; /* h-2 */
    background-color: #e5e7eb; /* bg-gray-200 */
    border-radius: 0.5rem; /* rounded-lg */
    -webkit-appearance: none; /* remove default webkit styles */
    appearance: none;
    cursor: pointer;
}

/* Track styles for range input */
.ii-generator-range-input::-webkit-slider-runnable-track {
    background: #e5e7eb;
    border-radius: 0.5rem;
    height: 0.5rem;
}

.ii-generator-range-input::-moz-range-track {
    background: #e5e7eb;
    border-radius: 0.5rem;
    height: 0.5rem;
}

/* Thumb styles for range input */
.ii-generator-range-input::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 1.25rem; /* Adjust thumb size */
    height: 1.25rem; /* Adjust thumb size */
    background: #FA6803; /* Thumb color */
    border-radius: 50%;
    margin-top: -0.375rem; /* Adjust to center vertically on the track */
    box-shadow: 0 0 0 4px rgba(250, 104, 3, 0.2); /* Focus ring effect */
    transition: background-color 0.2s ease-in-out;
}

.ii-generator-range-input::-moz-range-thumb {
    width: 1.25rem;
    height: 1.25rem;
    background: #FA6803;
    border-radius: 50%;
    box-shadow: 0 0 0 4px rgba(250, 104, 3, 0.2);
    transition: background-color 0.2s ease-in-out;
}

.ii-generator-range-input:focus::-webkit-slider-thumb {
    outline: none; /* Remove focus outline */
    background-color: #e05e00; /* Darker on focus */
}
.ii-generator-range-input:focus::-moz-range-thumb {
    outline: none; /* Remove focus outline */
    background-color: #e05e00; /* Darker on focus */
}


.ii-generator-security-wrapper,
.ii-generator-username-strength-wrapper {
    display: flex;
    align-items: center;
    margin-top: 0.625rem; /* margin-top: 10px; */
}

.ii-generator-security-label,
.ii-generator-username-strength-label {
    font-size: 0.875rem; /* text-sm */
    font-weight: 600;
    color: #4b5563; /* text-gray-700 */
}

.ii-generator-security-text,
.ii-generator-username-strength-text {
    font-size: 0.875rem; /* text-sm */
    font-weight: 600;
    margin-left: 0.25rem; /* ml-1 */
    transition: color 0.3s ease-in-out;
}

.ii-generator-security-indicator {
    width: 0.9375rem; /* 15px */
    height: 0.9375rem; /* 15px */
    border-radius: 50%;
    background-color: #cbd5e1; /* bg-gray-300 */
    transition: background-color 0.3s ease-in-out;
    margin-left: 0.5rem; /* ml-2 */
    flex-shrink: 0;
}

/* Colori dell'indicatore di sicurezza */
.ii-generator-security-indicator.red { background-color: #dc2626; } /* Pericolosa */
.ii-generator-security-text.red { color: #dc2626; }
.ii-generator-security-indicator.orange { background-color: #f97316; } /* Poco sicura */
.ii-generator-security-text.orange { color: #f97316; }
.ii-generator-security-indicator.yellow { background-color: #eab308; } /* Media */
.ii-generator-security-text.yellow { color: #eab308; }
.ii-generator-security-indicator.green { background-color: #22c55e; } /* Sicura */
.ii-generator-security-text.green { color: #22c55e; }
.ii-generator-security-indicator.emerald { background-color: #059669; } /* Eccellente */
.ii-generator-security-text.emerald { color: #059669; }


.ii-generator-checkbox-group {
    display: grid;
    grid-template-columns: 1fr; /* Colonna singola per mobile */
    gap: 1rem;
}

@media (min-width: 768px) {
    .ii-generator-checkbox-group {
        grid-template-columns: 1fr 1fr; /* Due colonne su schermi medi e grandi */
    }
}

.ii-generator-checkbox-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.ii-generator-checkbox-input {
    width: 1.25rem; /* w-5 */
    height: 1.25rem; /* h-5 */
    color: #2563eb; /* text-blue-600 */
    background-color: #f9fafb; /* bg-gray-50 */
    border-color: #d1d5db; /* border-gray-300 */
    border-radius: 0.25rem; /* rounded */
    /* Aggiungi stili per il focus se necessario */
    box-shadow: none; /* Rimuovi potenziali box-shadow di temi o Bootstrap */
}

.ii-generator-flex-center-gap-4 {
    display: flex;
    flex-direction: column; /* Colonna per mobile */
    align-items: center;
    gap: 1rem; /* Spazio tra gli elementi */
    width: 100%; /* Assicura che occupi tutta la larghezza disponibile */
}

@media (min-width: 768px) {
    .ii-generator-flex-center-gap-4 {
        flex-direction: row; /* Riga per desktop */
        justify-content: space-between; /* Spazia gli elementi */
    }
}

.ii-generator-button {
    background-color: #FA6803; /* Arancio richiesto */
    color: white;
    padding: 0.75rem 1.25rem; /* Ridotto da 1rem 1.5rem */
    border-radius: 0.75rem;
    font-size: 1rem; /* Ridotto da 1.125rem a 1rem */
    font-weight: 700;
    cursor: pointer;
    transition: background-color 0.2s ease-in-out;
    width: 100%; /* Default a piena larghezza su mobile */
    max-width: 200px; /* Limita la larghezza del pulsante su desktop */
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem; /* Ridotto da 0.75rem */
    border: none; /* Rimuovi bordi che potrebbero arrivare da Bootstrap */
}

.ii-generator-button:hover,
.ii-generator-button:active {
    background-color: #2098C1; /* Azzurro richiesto per hover/active */
}


@media (min-width: 768px) {
    .ii-generator-button {
        width: auto; /* Larghezza automatica su desktop */
    }
}

.ii-generator-display-box {
    background-color: #e2e8f0; /* Sfondo per la password/username */
    padding: 0.75rem 1rem; /* Ridotto da 1rem */
    border-radius: 0.75rem;
    font-size: 1rem; /* Ridotto da 1.25rem a 1rem */
    font-weight: 600;
    text-align: center;
    word-break: break-all;
    display: flex;
    align-items: center; /* Allinea verticalmente gli elementi interni */
    justify-content: space-between;
    flex-grow: 1; /* Permette al box di espandersi */
    color: #1f2937; /* text-gray-900 */
    min-height: 48px; /* Assicura un'altezza minima per l'allineamento */
}

.ii-generator-copy-button {
    background-color: #2098C1; /* Colore richiesto */
    color: white;
    padding: 0.2rem 0.4rem; /* Reso ancora più piccolo */
    border-radius: 0.4rem; /* Arrotondamento leggermente ridotto */
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s ease-in-out;
    margin-left: 0.75rem; /* Ridotto da 1rem */
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center; /* Centra icona e testo nel pulsante */
    gap: 0.15rem; /* Spazio ridotto per icona e testo */
    font-size: 0.75rem; /* Testo ancora più piccolo */
    border: none; /* Rimuovi bordi che potrebbero arrivare da Bootstrap */
    height: 30px; /* Altezza fissa per coerenza */
    line-height: 1; /* Rimuovi spazio extra per il testo */
}

.ii-generator-copy-button svg {
    width: 0.875rem; /* w-3.5 */
    height: 0.875rem; /* h-3.5 */
}

.ii-generator-copy-button:hover {
    background-color: #1a7fa3; /* Scuro al hover */
}

/* Messaggi temporanei */
.ii-generator-message-box {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: #FA6803;
    color: white;
    padding: 0.625rem 1.25rem; /* 10px 20px */
    border-radius: 0.5rem; /* 8px */
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
    z-index: 1000;
    font-size: 1rem;
}

.ii-generator-message-box.show {
    opacity: 1;
}

/* Tailwind CSS reset adjustments */
.ii-generator-checkbox-input:checked {
    background-color: currentColor; /* Use the text-blue-600 color for checked state */
    border-color: transparent;
}