/* =========================
   STILE GENERALE
========================= */
body {
    font-family: Arial, sans-serif;
    text-align: center;
    background-color: #f0f8ff;
    margin: 0;
    padding: 0;
}

/* HEADER */
.logo-container {
    display: flex;
    align-items: center; /* center items vertically */
    height: 60px; /* set height for container */
    background-color: #10475C;
}

.logo-image {
    width: 60px; /* set width for logo */
    height: 60px; /* set height for logo */
}

.logo-text {
    flex-basis: calc(100% - 60px);
    text-align: center;
    color: #F0F0C9;
}
#operazione-container {
    font-size: 30px;
    margin: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

#input-container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
    font-size: 20px;
}

input {
    font-size: 20px;
    width: 100px;
    text-align: center;
    padding: 4px;
}

button {
    font-size: 18px;
    padding: 6px 12px;
    margin: 8px;
    cursor: pointer;
}

/* =========================
   GRIGLIA E CERCHI
========================= */
.grid {
    margin: 20px auto;
    width: 420px;       /* larghezza fissa per PC */
    display: flex;
    flex-direction: column;
    align-items: center;
}

.row {
    display: flex;
    justify-content: center;
    margin: 4px 0;
}

.circle {
    width: 42px;          /* diametro fisso su PC */
    height: 42px;
    aspect-ratio: 1 / 1;  /* cerchio perfetto */
    border-radius: 50%;
    border: 2px solid #999;
    margin: 3px;
    background-color: white;
    flex-shrink: 0;
    box-sizing: border-box;
}

.filled {
    background-color: #2b7cff;
    cursor: pointer;
}

.gap {
    margin-right: 12px; /* gap tra 5+5 */
}

.selected {
    outline: 4px solid orange; /* pedina selezionata */
}

/* =========================
   SEPARATORE TRA ADDENDI
========================= */
.separator {
    width: 100%;
    height: 16px;          /* spazio verticale */
    margin: 8px 0;
}

/* =========================
   FEEDBACK
========================= */
#feedback {
    font-size: 22px;
    font-weight: bold;
    margin-top: 10px;
}

/* =========================
   MODAL INFO
========================= */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
}

.modal-content {
    background-color: white;
    margin: 10% auto;
    padding: 20px;
    width: 350px;
    border-radius: 10px;
    text-align: left;
}

.close {
    float: right;
    font-size: 24px;
    cursor: pointer;
}

/* =========================
   BOTTONE INFO “i” SVG
========================= */
.info-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    transition: transform 0.2s ease;
}

.info-btn:hover {
    transform: scale(1.15) rotate(5deg);
}

.info-btn:active {
    transform: scale(0.95);
}

/* =========================
   MOBILE & TABLET
========================= */
@media (max-width: 768px) {

    body {
        padding: 10px;
    }

    #operazione-container {
        font-size: 24px;
        flex-wrap: wrap;
    }

    .grid {
        width: 95%;       /* adatta la griglia allo schermo */
        max-width: none;  /* niente limite su mobile */
    }

    .circle {
        width: 32px;      /* diametro più piccolo su smartphone */
        height: 32px;
        margin: 2px;
    }

    .gap {
        margin-right: 8px; /* gap ridotto su mobile */
    }

    input {
        font-size: 22px;
        width: 120px;
    }

    button {
        font-size: 20px;
        padding: 10px 14px;
    }

    .modal-content {
        width: 90%;
        margin: 20% auto;
    }
}

