:root {
    --verde-col: #070;
    --oro-col: #cda70e;
    --oro-col-hover: #a0820b;
    --colore-grigio-chiaro: #eee;
    --colore-ombra: rgba(0, 0, 0, 0.1);
    --colore-testogrigio: #555;
}

@media screen and (max-width: 600px) {
    .fotoProfilo {
        border-radius: 0 !important;
        margin: 0 -20px;
    }

    .infoUtente, .app-grid {
        padding: 0 !important;
    }

    .app-grid, .tabContenuti .col-12 {
        margin: 0 !important;
        padding: 0;
    }

    #stelleUser {
        font-size: 30px !important;
    }

    .labelTab {
        display: none;
    }

    .iconTab {
        /* transform: scale(2); */
    }
}

.fotoProfilo {
    border-radius: 10px;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
}

.fotoProfilo img {
    width: 100%;
    height: auto;
    object-fit: cover;
}

.infoUtente p {
    color: var(--colore-testogrigio);
}

.boxContributo {
    padding: 5px;
    border-radius: 10px;
    box-shadow: 0 0 30px #ddd;
    margin: 15px 0;
}

.boxContributo h3 {
    background: var(--colore-grigio-chiaro);
    margin: -5px -5px 10px;
    padding: 5px;
    color: var(--colore-testogrigio);
}

.contributiutente {
    background: var(--verde-col);
    padding: 10px 0 0 5px;
}

.contributiutente .nav-item {
    margin-right: 5px;
}

.contributiutente .nav-link {
    color: #fff;
    border: 1px solid #fff;
}

.contributiutente .nav-link:hover {
    color: #000;
    background: #fff;
}

.contributiutente .nav-link.active {
    color: #000;
}

.contributo {
    margin-bottom: 5px;
}

.contributo .col-2,
.contributo .col-md-1 {
    background: var(--colore-grigio-chiaro);
    font-size: 20px;
    text-align: center;
}

span.badge.badge-primary.badge-pill[data-count="0"] {
    display: none;
}

.flag-list {
    list-style-type: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.flag-item {
    display: flex;
    align-items: center;
    padding: 10px;
    background-color: #f9f9f9;
    border-radius: 5px;
    box-shadow: 0 2px 4px var(--colore-ombra);
    border: 1px solid #ddd;
    transition: background-color .3s ease;
}

.flag-icon {
    width: 40px;
    height: 30px;
    border: 2px solid #ccc;
    border-radius: 3px;
    margin-right: 10px;
}

.flag-label {
    font-size: 16px;
    font-weight: 600;
    color: #333;
}

.active-count {
    background-color: #b7950c;
}

.inactive-count {
    background-color: var(--colore-grigio-chiaro);
    color: rgb(128, 128, 128);
}

span.inactive-count {
    background-color: white;
}

.active-count,
.filtertab,
.inactive-count {
    cursor: pointer;
}

.app-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
    gap: 5px;
    margin: 5px;
    padding: 5px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px var(--colore-ombra);
}

.app-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 2px;
    border-radius: 8px;
    transition: background .3s, transform .3s;
    cursor: pointer;
    color: #444;
}

.app-item:hover {
    background: #e8f0fe;
    transform: scale(1.05);
}

.app-icon {
    font-size: 40px;
    margin-bottom: 5px;
}

.app-label {
    font-size: 14px;
}

.group-title {
    text-align: left;
    font-size: 20px;
    margin: 10px 0;
    color: #333;
    font-weight: 700;
    margin-left: 10px;
}

.results-container {
    min-height: 400px;
}

.user {
    display: flex;
    align-items: center;
    padding: 10px;
    border-bottom: 1px solid #eee;
}

.user:last-child {
    border-bottom: none;
}

.user img {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    margin-right: 15px;
}

.user-info {
    display: flex;
    flex-direction: column;
    flex: 1;
}

.user-nickname {
    font-weight: 700;
    color: #333;
}

.user-score {
    color: #777;
}

.profile-button {
    color: #fff;
    border: none;
    border-radius: 5px;
    padding: 8px 12px;
    cursor: pointer;
    margin-left: 10px;
}

#stelleUser {
    font-size: 70px;
}

.strength-bar {
    height: 8px;
    width: 100%;
    background-color: #ddd;
    border-radius: 5px;
    margin-bottom: 10px;
}

.strength-bar span {
    display: block;
    height: 100%;
    width: 0%;
    border-radius: 5px;
    transition: width 0.3s ease;
}

.password-rules {
    list-style: none;
    padding: 0;
    margin: 10px 0;
    color: #999;
    font-size: 14px;
}

.password-rules li {
    margin-bottom: 5px;
}

.valid-rule {
    color: #9acd32;
    /* Verde intermedio */
}

.invalid-rule {
    color: #ff0000;
    /* Rosso per regole non valide */
}

.strength-1 {
    background-color: #ff0000;
}

/* Rosso per Debole */
.strength-2 {
    background-color: #ffa500;
}

/* Arancione per Accettabile */
.strength-3 {
    background-color: #8fbc8f;
}

/* Verde intermedio per Buona */
.strength-4 {
    background-color: #008000;
}

/* Verde scuro per Forte */
.strength-5 {
    background-color: #006400;
}

.strength-text {
    font-size: 14px;
    margin-top: 10px;
    color: #666;
    text-align: center;
}