:root {
    color-scheme: light;
    --privato-blu: #007bff;
    --privato-sfondo: #f4f7fc;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    min-height: 100%;
    background: var(--privato-sfondo);
    -webkit-text-size-adjust: 100%;
}

body {
    min-height: 100vh;
    min-height: 100dvh;
    overscroll-behavior-y: none;
}

button,
input,
select,
textarea {
    font-family: inherit;
}

button,
a,
input,
select,
textarea {
    -webkit-tap-highlight-color: transparent;
}

@media (max-width: 700px) {
    body {
        margin: 0;
        padding: 0 0 env(safe-area-inset-bottom, 0);
        background: var(--privato-sfondo);
    }

    .gap-wrap,
    .wrap {
        width: 100%;
        max-width: none;
        margin: 0;
        padding: max(12px, env(safe-area-inset-top, 0)) 10px 24px;
    }

    .gap-logo,
    .logo {
        position: sticky;
        top: 0;
        z-index: 20;
        margin: -12px -10px 12px;
        padding: calc(10px + env(safe-area-inset-top, 0)) 12px 8px;
        background: rgba(244, 247, 252, .96);
        border-bottom: 1px solid #dce4ed;
        backdrop-filter: blur(8px);
        -webkit-backdrop-filter: blur(8px);
    }

    .gap-logo img,
    .logo img {
        width: 142px;
        max-height: 45px;
        object-fit: contain;
        margin: 0;
    }

    fieldset.gap-card,
    fieldset.card {
        width: 100%;
        min-width: 0;
        margin: 0;
        padding: 15px 12px 18px !important;
        border: 1px solid #c9d4df;
        border-radius: 8px;
        box-shadow: 0 2px 9px rgba(31, 60, 88, .08);
    }

    fieldset.gap-card > legend,
    fieldset.card > legend {
        max-width: calc(100vw - 52px);
        padding: 0 8px;
        font-size: 17px;
        line-height: 1.25;
        white-space: normal;
    }

    .form-group,
    .grid > div {
        min-width: 0;
    }

    .grid,
    .discipline {
        display: grid;
        grid-template-columns: minmax(0, 1fr) !important;
        gap: 13px !important;
    }

    .box {
        margin: 14px 0 !important;
        padding: 14px 11px !important;
        border-radius: 7px !important;
    }

    .box h2 {
        font-size: 17px !important;
        line-height: 1.25;
    }

    input:not([type="checkbox"]):not([type="radio"]),
    select,
    textarea {
        display: block;
        width: 100% !important;
        max-width: none !important;
        min-height: 48px;
        padding: 11px 10px !important;
        font-size: 16px !important;
        line-height: 1.25;
        border-radius: 5px !important;
    }

    textarea {
        min-height: 84px;
    }

    .check {
        min-height: 44px;
        padding: 7px 3px;
        align-items: flex-start !important;
        line-height: 1.35;
    }

    .check input {
        flex: 0 0 auto;
        width: 22px !important;
        height: 22px;
        margin: 0 4px 0 0 !important;
    }

    .btn-primary,
    .submit,
    .cerca-cf {
        min-height: 48px;
        font-size: 16px !important;
        border-radius: 6px !important;
        touch-action: manipulation;
    }

    .submit {
        position: sticky;
        bottom: max(8px, env(safe-area-inset-bottom, 0));
        z-index: 15;
        display: block;
        width: 100%;
        margin-top: 14px;
        box-shadow: 0 4px 14px rgba(0, 80, 170, .28);
    }

    .cerca-cf {
        width: 100%;
        margin-top: 8px !important;
    }

    .gap-evento {
        min-height: 62px;
        padding: 14px !important;
        font-size: 16px;
        line-height: 1.25;
        touch-action: manipulation;
    }

    .gap-msg,
    .msg {
        font-size: 14px;
        line-height: 1.4;
    }

    .account {
        text-align: center !important;
        overflow-wrap: anywhere;
    }

    .evento {
        line-height: 1.45;
    }
}
