/* Stili condivisi dalle pagine di autenticazione. */
/* Parametrizzazione variabili per il colore del pulsante */
:root {
    --btn-color: #282d33; /* Colore predefinito per il pulsante */
    --btn-hover-color: #1e2226; /* Colore di hover per il pulsante */
}

/* Centra la pagina con lo sfondo */
body {
    background-image: url('../bg8.jpg') !important;
    background-size: 50%; /* Ridimensiona lo sfondo al 50% */
    background-position: center;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.form-container {
    background-color: rgba(245, 245, 245, 0.96); /* Bianco semi-trasparente */
    border-radius: 10px;
    padding: 30px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 400px;
    position: relative;
    z-index: 10;
}

.registration-container {
    max-width: 680px;
    margin: 24px 12px;
}

.registration-honeypot {
    position: absolute !important;
    left: -10000px !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
}

.auth-switch {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px 12px;
    margin-top: 22px;
    padding-top: 18px;
    border-top: 1px solid #d9dde1;
    color: #5c636a;
    font-size: 0.95rem;
}

.auth-switch-link {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 8px 14px;
    border: 1px solid #343a40;
    border-radius: 999px;
    color: #212529;
    background: #fff;
    font-weight: 700;
    text-decoration: none;
    transition: background-color 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.auth-switch-link:hover,
.auth-switch-link:focus-visible {
    color: #fff;
    background: #282d33;
    transform: translateY(-1px);
}

.auth-register-link {
    color: #5c636a;
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: underline;
    text-decoration-color: #adb5bd;
    text-underline-offset: 3px;
}

.auth-register-link:hover,
.auth-register-link:focus-visible {
    color: #212529;
    text-decoration-color: currentColor;
}

.auth-privacy-link {
    display: block;
    width: max-content;
    margin: 12px auto 0;
    color: #6c757d;
    font-size: 0.82rem;
    text-decoration: none;
}

.auth-privacy-link:hover,
.auth-privacy-link:focus-visible {
    color: #212529;
    text-decoration: underline;
}

.auth-help-link {
    margin: -2px 0 18px;
    text-align: right;
}

.auth-help-link a {
    color: #495057;
    font-size: 0.9rem;
    font-weight: 600;
    text-underline-offset: 3px;
}

.auth-help-link a:hover,
.auth-help-link a:focus-visible {
    color: #111;
}

.auth-description {
    color: #5c636a;
    font-size: 0.95rem;
    line-height: 1.55;
}

.auth-actions {
    display: grid;
    gap: 12px;
    margin-top: 22px;
}

.auth-actions .btn {
    width: 100%;
}

.privacy-policy-link {
    display: inline;
    margin: 0;
    color: #212529;
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.privacy-policy-link:hover,
.privacy-policy-link:focus-visible {
    color: #000;
    text-decoration-thickness: 2px;
}

.privacy-page {
    align-items: flex-start;
}

.privacy-container {
    max-width: 900px;
    margin: 32px 12px;
    line-height: 1.65;
}

.privacy-container h2 {
    margin-top: 1.8rem;
    font-size: 1.25rem;
}

.privacy-highlight {
    padding: 16px 18px;
    border-left: 4px solid #282d33;
    border-radius: 6px;
    background: #eef0f2;
}

/* Intestazione con logo e titolo */
.header {
    text-align: center;
    margin-bottom: 20px;
}

.header img {
    width: 100px; /* Raddoppiato la larghezza del logo da 50px a 100px */
    margin-bottom: 10px;
}

.header h1 {
    font-size: 1.5rem;
    font-weight: bold;
}

/* Estetica dei campi di input */
.form-group input {
    border-radius: 5px;
}

/* Pulsante di login personalizzato con variabile */
.btn-primary {
    width: 100%;
    padding: 10px;
    font-size: 1.1rem;
    border-radius: 5px;
    background-color: var(--btn-color); /* Colore personalizzato */
    border: none;
}
		.btn-primary:visited,
		.btn-primary:disabled,
		.btn-primary:focus,
		.btn-primary:active,
.btn-primary:hover {
    background-color: var(--btn-hover-color); /* Colore al passaggio del mouse */
    transform: scale(1.05); /* Ingrandisce leggermente il pulsante */
}

/* Aggiungi margine tra il form e il footer */
.modal-footer {
    padding: 0;
}

/* Modifica il colore dei messaggi di errore */
.alert-danger {
    background-color: #f8d7da;
    color: #721c24;
    font-weight: bold;
}

/* Icona visibilitÃ  password */
.password-icon {
    cursor: pointer;
    position: absolute;
    right: 15px;
    top: 70%;
    transform: translateY(-50%);
}

/* Loader */
#loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: none; /* Nascondi il loader inizialmente */
    justify-content: center;
    align-items: center;
    z-index: 9999; /* Assicurati che il loader stia sopra a tutto */
}
.loader-spinner {
    border: 8px solid #f3f3f3;
    border-top: 8px solid #3498db;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 2s linear infinite;
}
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Disabilita l'interazione con la pagina quando il loader Ã¨ visibile */
.overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.8);
    z-index: 9998;
    display: none;
}

/* Disabilitare l'effetto focus sul pulsante */
.btn:focus {
    outline: none;
}
