/* Più CAME – frontend (installatori) */

/* ------------------------------------------------------------------ */
/* Tokens                                                              */
/* ------------------------------------------------------------------ */

:root {
    /* CAME cyan: decorative accents only (white text on it is not readable). */
    --color-brand: #00b0ed;
    /* Darker cyans for text, buttons and backgrounds with white text (WCAG AA). */
    --color-brand-strong: #0079a8;
    --color-brand-deep: #005f85;
    --color-brand-soft: #e5f6fd;

    --color-ink: #1a1918;
    --color-text: #33302e;
    --color-muted: #6b6b6b;
    --color-border: #e3e6ea;
    --color-surface: #ffffff;
    --color-background: #f4f6f8;
    --color-error: #c62828;

    --font-sans: "Roboto", system-ui, -apple-system, "Segoe UI", "Helvetica Neue", Arial, sans-serif;

    --radius: 10px;
    --radius-small: 6px;
    --shadow: 0 1px 2px rgb(16 24 40 / 5%), 0 4px 16px rgb(16 24 40 / 6%);
    --shadow-hover: 0 2px 4px rgb(16 24 40 / 6%), 0 12px 28px rgb(16 24 40 / 10%);
    --container: 1200px;
}

/* ------------------------------------------------------------------ */
/* Base                                                                */
/* ------------------------------------------------------------------ */

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

html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    font-family: var(--font-sans);
    font-size: 16px;
    line-height: 1.55;
    color: var(--color-text);
    background: var(--color-background);
}

h1,
h2,
h3 {
    margin: 0 0 0.5em;
    font-weight: 500;
    line-height: 1.2;
    color: var(--color-ink);
}

h1 {
    font-size: clamp(1.6rem, 1.2rem + 1.6vw, 2.25rem);
}

h2 {
    font-size: 1.3rem;
}

p {
    margin: 0 0 1em;
}

a {
    color: var(--color-brand-strong);
}

a:hover {
    color: var(--color-brand-deep);
}

img,
svg {
    max-width: 100%;
}

:focus-visible {
    outline: 3px solid var(--color-brand);
    outline-offset: 2px;
}

.container {
    width: 100%;
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 16px;
}

.muted {
    color: var(--color-muted);
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
}

.skip-link {
    position: absolute;
    top: -100px;
    left: 16px;
    z-index: 100;
    padding: 8px 16px;
    color: #fff;
    background: var(--color-brand-deep);
    border-radius: var(--radius-small);
}

.skip-link:focus {
    top: 8px;
}

/* ------------------------------------------------------------------ */
/* Header                                                              */
/* ------------------------------------------------------------------ */

.site-header {
    position: relative;
    z-index: 10;
    background: var(--color-surface);
    box-shadow: 0 1px 0 var(--color-border);
}

.site-header__bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-height: 72px;
}

.site-header__brand {
    display: flex;
    align-items: center;
    gap: 16px;
    min-width: 0;
    text-decoration: none;
}

.site-header__brand img {
    display: block;
    flex-shrink: 0;
    width: 120px;
    height: auto;
}

.site-header__tagline {
    padding-left: 16px;
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--color-brand-strong);
    border-left: 1px solid var(--color-border);
    white-space: nowrap;
}

.site-header__tagline span {
    font-weight: 400;
    color: var(--color-muted);
}

.site-header__actions {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.site-header__actions form {
    margin: 0;
}

.user-menu {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}

.user-menu__avatar {
    display: grid;
    place-items: center;
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    font-weight: 500;
    color: #fff;
    background: var(--color-brand-strong);
    border-radius: 50%;
}

.user-menu__name {
    max-width: 220px;
    overflow: hidden;
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--color-ink);
    white-space: nowrap;
    text-overflow: ellipsis;
}

/* Account menu of small screens: the avatar opens "Modifica i tuoi dati" and "Esci" */

.account-menu {
    display: none;
    position: relative;
}

.account-menu__toggle {
    display: block;
    padding: 4px;
    list-style: none;
    border-radius: 50%;
    cursor: pointer;
}

.account-menu__toggle::-webkit-details-marker {
    display: none;
}

.account-menu__toggle:focus-visible {
    outline: 2px solid var(--color-brand-strong);
    outline-offset: 2px;
}

.account-menu[open] .account-menu__toggle .user-menu__avatar {
    background: var(--color-brand-deep);
    box-shadow: 0 0 0 3px var(--color-brand-soft);
}

.account-menu__panel {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    z-index: 30;
    width: max-content;
    min-width: 220px;
    max-width: calc(100vw - 32px);
    padding: 6px;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-hover);
}

.account-menu__name {
    margin: 0 0 4px;
    padding: 8px 12px 10px;
    overflow: hidden;
    font-size: 0.85rem;
    color: var(--color-muted);
    white-space: nowrap;
    text-overflow: ellipsis;
    border-bottom: 1px solid var(--color-border);
}

.account-menu__panel form {
    margin: 0;
}

.account-menu__item {
    display: block;
    width: 100%;
    padding: 12px;
    font: inherit;
    font-weight: 500;
    text-align: left;
    color: var(--color-ink);
    text-decoration: none;
    background: none;
    border: 0;
    border-radius: var(--radius-small);
    cursor: pointer;
}

.account-menu__item:hover,
.account-menu__item:focus-visible {
    color: var(--color-brand-deep);
    background: var(--color-brand-soft);
}

.account-menu__item.is-active {
    color: var(--color-brand-strong);
}

/* Mobile menu button */

.nav-toggle {
    display: none;
    width: 44px;
    height: 44px;
    padding: 0;
    color: var(--color-ink);
    background: none;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-small);
    cursor: pointer;
}

.nav-toggle__icon,
.nav-toggle__icon::before,
.nav-toggle__icon::after {
    display: block;
    width: 20px;
    height: 2px;
    margin: 0 auto;
    background: currentColor;
    border-radius: 2px;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.nav-toggle__icon {
    position: relative;
}

.nav-toggle__icon::before,
.nav-toggle__icon::after {
    content: "";
    position: absolute;
    left: 0;
}

.nav-toggle__icon::before {
    top: -6px;
}

.nav-toggle__icon::after {
    top: 6px;
}

.nav-toggle[aria-expanded="true"] .nav-toggle__icon {
    background: transparent;
}

.nav-toggle[aria-expanded="true"] .nav-toggle__icon::before {
    transform: translateY(6px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] .nav-toggle__icon::after {
    transform: translateY(-6px) rotate(-45deg);
}

/* ------------------------------------------------------------------ */
/* Main menu                                                           */
/* ------------------------------------------------------------------ */

.main-nav {
    border-top: 1px solid var(--color-border);
}

.main-nav__list {
    display: flex;
    margin: 0;
    padding: 0;
    list-style: none;
}

.main-nav__list > li {
    flex: 1 1 0;
    min-width: 0;
}

.main-nav__link {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 2px;
    height: 100%;
    padding: 14px 12px 16px;
    color: var(--color-ink);
    text-decoration: none;
    transition: background-color 0.15s ease;
}

.main-nav__link::after {
    content: "";
    position: absolute;
    right: 12px;
    bottom: 0;
    left: 12px;
    height: 3px;
    background: var(--color-brand);
    border-radius: 3px 3px 0 0;
    transform: scaleX(0);
    transition: transform 0.2s ease;
}

.main-nav__link:hover {
    color: var(--color-ink);
    background: var(--color-brand-soft);
}

.main-nav__link:hover::after,
.main-nav__link.is-active::after {
    transform: scaleX(1);
}

.main-nav__label {
    font-weight: 700;
    font-size: 0.95rem;
}

.main-nav__description {
    font-size: 0.78rem;
    color: var(--color-muted);
}

.main-nav__link.is-active .main-nav__label {
    color: var(--color-brand-strong);
}

/* ------------------------------------------------------------------ */
/* Page hero and layout                                                */
/* ------------------------------------------------------------------ */

.page-hero {
    padding: 40px 0 44px;
    color: #fff;
    background:
        radial-gradient(circle at 85% 0%, rgb(0 176 237 / 55%), transparent 55%),
        linear-gradient(120deg, var(--color-brand-strong), var(--color-brand-deep));
}

.page-hero h1 {
    margin-bottom: 0.3em;
    color: #fff;
}

.page-hero p {
    max-width: 720px;
    margin: 0;
    font-size: 1.05rem;
    color: rgb(255 255 255 / 92%);
}

.site-main {
    flex: 1;
    padding: 32px 0 56px;
}

.with-sidebar {
    display: grid;
    grid-template-columns: 300px minmax(0, 1fr);
    gap: 32px;
    align-items: start;
}

.section-title {
    margin-bottom: 16px;
}

/* ------------------------------------------------------------------ */
/* Section side menu                                                   */
/* ------------------------------------------------------------------ */

.section-menu {
    padding: 14px 12px;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
}

.section-menu__title {
    margin: 0;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--color-brand-strong);
}

/* The title opens and closes the menu (<details>); the arrow points down when closed, up when open. */
.section-menu__summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 4px 12px;
    list-style: none;
    cursor: pointer;
    border-radius: var(--radius-small);
}

.section-menu__summary::-webkit-details-marker {
    display: none;
}

.section-menu__summary::after {
    content: "";
    flex-shrink: 0;
    width: 8px;
    height: 8px;
    margin-top: -4px;
    border-right: 2px solid var(--color-brand-strong);
    border-bottom: 2px solid var(--color-brand-strong);
    transform: rotate(45deg);
    transition: transform 0.2s ease;
}

.section-menu__details[open] > .section-menu__summary {
    margin-bottom: 6px;
}

.section-menu__details[open] > .section-menu__summary::after {
    margin-top: 4px;
    transform: rotate(-135deg);
}

.section-menu__summary:hover {
    background: var(--color-brand-soft);
}

.section-menu__summary:focus-visible {
    outline: 2px solid var(--color-brand-strong);
    outline-offset: 2px;
}

.section-menu__list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.section-menu__link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 9px 12px;
    font-size: 0.95rem;
    color: var(--color-text);
    text-decoration: none;
    border-radius: var(--radius-small);
}

a.section-menu__link:hover {
    color: var(--color-ink);
    background: var(--color-brand-soft);
}

.section-menu__link.is-active {
    font-weight: 500;
    color: var(--color-brand-strong);
    background: var(--color-brand-soft);
}

.section-menu__link.is-disabled {
    color: var(--color-muted);
}

.section-menu__external {
    color: var(--color-brand-strong);
}

.badge {
    display: inline-block;
    flex-shrink: 0;
    padding: 2px 8px;
    font-size: 0.68rem;
    font-weight: 500;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: var(--color-muted);
    background: #eceff3;
    border-radius: 999px;
}

/* ------------------------------------------------------------------ */
/* Cards                                                               */
/* ------------------------------------------------------------------ */

.card {
    padding: 24px;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 20px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.card--link {
    display: flex;
    flex-direction: column;
    gap: 6px;
    height: 100%;
    color: var(--color-text);
    text-decoration: none;
    border-top: 4px solid var(--color-brand);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.card--link:hover {
    color: var(--color-text);
    box-shadow: var(--shadow-hover);
    transform: translateY(-2px);
}

.card__eyebrow {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--color-brand-strong);
}

.card__title {
    font-size: 1.3rem;
    font-weight: 500;
    color: var(--color-ink);
}

.card__text {
    font-size: 0.95rem;
    color: var(--color-muted);
}

.card__more {
    margin-top: auto;
    padding-top: 10px;
    font-weight: 500;
    color: var(--color-brand-strong);
}

.notice {
    margin-bottom: 20px;
}

.notice > :last-child {
    margin-bottom: 0;
}

/* ------------------------------------------------------------------ */
/* Forms and buttons                                                   */
/* ------------------------------------------------------------------ */

.form {
    display: flex;
    flex-direction: column;
    gap: 18px;
    margin-top: 20px;
}

.form__field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form__field label {
    font-weight: 500;
    font-size: 0.9rem;
    color: var(--color-ink);
}

.form__field input,
.form__field select,
.automations__brands input {
    width: 100%;
    min-height: 46px;
    padding: 10px 14px;
    font: inherit;
    color: var(--color-text);
    background: #fff;
    border: 1px solid #c9ced4;
    border-radius: var(--radius-small);
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.form__field select {
    padding-right: 36px;
    appearance: none;
    background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='none' stroke='%236b6b6b' stroke-width='2' d='m1 1 5 5 5-5'/%3E%3C/svg%3E") no-repeat right 14px center;
}

.form__field input[type="file"] {
    min-height: 0;
    padding: 8px;
}

.form__field input:focus,
.form__field select:focus,
.automations__brands input:focus {
    outline: none;
    border-color: var(--color-brand-strong);
    box-shadow: 0 0 0 3px rgb(0 176 237 / 25%);
}

.form__field input[aria-invalid="true"],
.form__field select[aria-invalid="true"] {
    border-color: var(--color-error);
}

.form__field select:disabled {
    background-color: var(--color-background);
}

.form__error {
    margin: 0;
    font-size: 0.85rem;
    color: var(--color-error);
}

.form__hint {
    margin: 0;
    font-size: 0.82rem;
    color: var(--color-muted);
}

.form__required {
    margin-left: 2px;
    color: var(--color-error);
}

.form__label {
    font-weight: 500;
    font-size: 0.9rem;
    color: var(--color-ink);
}

.form__static {
    margin: 0;
    padding: 11px 0;
    font-weight: 500;
}

.form__legend-note {
    margin: 0;
    font-size: 0.9rem;
    color: var(--color-muted);
}

.form__actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 16px 24px;
}

.form__actions p {
    margin: 0;
}

.form__field--checkbox {
    justify-content: flex-end;
}

/* Long forms split in sections (registration, profile) */

.form-page {
    max-width: 980px;
}

.form--sections {
    gap: 24px;
    margin-top: 0;
}

.form-section {
    min-width: 0;
    margin: 0;
    padding: 24px;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.form-section legend {
    float: left;
    width: 100%;
    margin-bottom: 18px;
    padding: 0;
    font-size: 1.2rem;
    font-weight: 500;
    color: var(--color-ink);
}

.form-section legend + * {
    clear: both;
}

.form-section__subtitle {
    margin: 24px 0 12px;
    font-size: 1rem;
    font-weight: 500;
    color: var(--color-brand-strong);
}

.form-section__intro {
    margin: 0 0 16px;
    font-size: 0.92rem;
    color: var(--color-muted);
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px 20px;
}

.form-grid + .form-grid {
    margin-top: 18px;
}

.form-grid__wide {
    grid-column: 1 / -1;
}

.form-grid--three {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

/* An activity and, below it, its detail ("Specifica") */
.activity-field {
    display: grid;
    align-content: start;
    gap: 12px;
}

.form-grid--address {
    grid-template-columns: minmax(0, 1fr) minmax(0, 3fr) minmax(0, 1fr);
}

.form-grid--phones {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.phone-field {
    display: grid;
    grid-template-columns: 110px minmax(0, 1fr);
    gap: 10px;
}

.is-hidden {
    display: none !important;
}

.choice {
    display: inline-flex;
    align-items: flex-start;
    gap: 10px;
    font-weight: 400;
    cursor: pointer;
}

.choice input {
    flex-shrink: 0;
    width: 18px;
    height: 18px;
    min-height: 0;
    margin: 2px 0 0;
    padding: 0;
    accent-color: var(--color-brand-strong);
}

.form__field .choice {
    font-weight: 400;
}

/* Treated automations: a type and up to three brands per row */

.automations {
    display: grid;
    gap: 8px;
}

.automations__row {
    display: grid;
    grid-template-columns: 210px minmax(0, 1fr);
    align-items: center;
    gap: 12px;
    padding: 8px 0;
    border-bottom: 1px solid var(--color-border);
}

.automations__row:last-child {
    border-bottom: 0;
}

.automations__brands {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
}

.automations__brands input {
    min-height: 40px;
    padding: 8px 12px;
    font-size: 0.92rem;
}

/* Privacy consents */

.consent {
    padding: 14px 0;
    border-top: 1px solid var(--color-border);
}

/* "Dichiaro di aver preso visione dell'informativa privacy": spaced from the line of the first consent. */
.consent-acknowledgement {
    margin-bottom: 16px;
}

.consent__choices {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 24px;
    margin-bottom: 6px;
    font-weight: 500;
}

.consent__text {
    margin: 0;
    font-size: 0.9rem;
    color: var(--color-muted);
}

/* Company logo */

.logo-field {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 20px 28px;
}

.logo-field__preview {
    margin: 0;
}

/* Half the maximum size of the stored logo (config/account_profile.php), with its proportions */
.logo-field__preview img {
    display: block;
    width: auto;
    max-width: min(100%, 345px);
    height: auto;
    max-height: 150px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-small);
}

.logo-field__preview figcaption {
    margin-top: 6px;
    font-size: 0.82rem;
    color: var(--color-muted);
}

.logo-field__inputs {
    display: grid;
    flex: 1 1 280px;
    gap: 12px;
}

/* Hidden field that only spam bots fill in */

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

/* Alerts */

.alert {
    margin-bottom: 20px;
    padding: 14px 18px;
    border: 1px solid;
    border-left-width: 4px;
    border-radius: var(--radius-small);
}

.alert p {
    margin: 0;
}

.alert p + p {
    margin-top: 8px;
}

.alert--success {
    color: #1e5631;
    background: #edf7ef;
    border-color: #2e7d32;
}

.alert--error {
    color: #7f1d1d;
    background: #fdecec;
    border-color: var(--color-error);
}

.alert--info {
    color: var(--color-brand-deep);
    background: var(--color-brand-soft);
    border-color: var(--color-brand-strong);
}

/* Registration benefits */

.benefits {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px 24px;
    margin: 0 0 24px;
    padding: 0;
    list-style: none;
}

.benefits li {
    position: relative;
    padding-left: 28px;
}

.benefits li::before {
    content: "✓";
    position: absolute;
    top: 1px;
    left: 0;
    display: grid;
    place-items: center;
    width: 20px;
    height: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    color: #fff;
    background: var(--color-brand-strong);
    border-radius: 50%;
}

/* Small pages with a single form (credentials recovery, new password) */

.auth-card {
    width: 100%;
    max-width: 460px;
    margin: 0 auto;
}

.auth-card__links {
    margin: 18px 0 0;
    font-size: 0.92rem;
    text-align: center;
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    padding: 10px 24px;
    font: inherit;
    font-weight: 500;
    color: #fff;
    text-decoration: none;
    background: var(--color-brand-strong);
    border: 1px solid var(--color-brand-strong);
    border-radius: var(--radius-small);
    cursor: pointer;
    transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.button:hover {
    color: #fff;
    background: var(--color-brand-deep);
    border-color: var(--color-brand-deep);
}

.button--outline {
    color: var(--color-brand-strong);
    background: transparent;
}

.button--outline:hover {
    color: var(--color-brand-deep);
    background: var(--color-brand-soft);
    border-color: var(--color-brand-deep);
}

.button--small {
    min-height: 36px;
    padding: 6px 16px;
    font-size: 0.9rem;
}

/* Confirmation window (public/js/confirm-dialog.js) */
.confirm-dialog {
    width: min(480px, calc(100vw - 32px));
    padding: 0;
    color: var(--color-text);
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-top: 4px solid var(--color-brand);
    border-radius: var(--radius);
    box-shadow: 0 16px 48px rgb(16 24 40 / 22%);
}

.confirm-dialog::backdrop {
    background: rgb(26 25 24 / 45%);
}

.confirm-dialog__content {
    padding: 28px;
}

.confirm-dialog__title {
    margin: 0;
    font-size: 1.2rem;
    font-weight: 500;
    line-height: 1.4;
    color: var(--color-ink);
    overflow-wrap: anywhere;
}

.confirm-dialog__text {
    margin: 12px 0 0;
    color: var(--color-muted);
    overflow-wrap: anywhere;
}

.confirm-dialog__actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 28px;
}

.confirm-dialog__danger,
.confirm-dialog__danger:hover {
    color: #fff;
}

.confirm-dialog__danger {
    background: var(--color-error);
    border-color: var(--color-error);
}

.confirm-dialog__danger:hover {
    background: #a51d1d;
    border-color: #a51d1d;
}

.confirm-dialog[open] {
    animation: confirm-dialog-in 0.15s ease-out;
}

@keyframes confirm-dialog-in {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
}

@media (max-width: 520px) {
    .confirm-dialog__content {
        padding: 22px 18px;
    }

    .confirm-dialog__actions .button {
        flex: 1 1 auto;
    }
}

.button--block {
    width: 100%;
}

.button--light {
    color: var(--color-brand-deep);
    background: #fff;
    border-color: #fff;
}

.button--light:hover {
    color: var(--color-brand-deep);
    background: var(--color-brand-soft);
    border-color: var(--color-brand-soft);
}

/* ------------------------------------------------------------------ */
/* Login page                                                          */
/* ------------------------------------------------------------------ */

.page-login .site-main {
    display: flex;
    align-items: center;
}

.login {
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    max-width: 980px;
    margin: 0 auto;
    overflow: hidden;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: 16px;
    box-shadow: var(--shadow-hover);
}

.login__intro {
    padding: 48px 44px;
    color: #fff;
    background:
        radial-gradient(circle at 100% 0%, rgb(0 176 237 / 60%), transparent 60%),
        linear-gradient(135deg, var(--color-brand-strong), var(--color-brand-deep));
}

.login__intro h1 {
    margin-bottom: 1em;
    font-size: clamp(1.5rem, 1.1rem + 1.4vw, 2.1rem);
    color: #fff;
}

.login__eyebrow {
    margin-bottom: 12px;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: rgb(255 255 255 / 85%);
}

.login__features {
    display: grid;
    gap: 12px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.login__features li {
    position: relative;
    padding-left: 30px;
}

.login__features li::before {
    content: "✓";
    position: absolute;
    top: 1px;
    left: 0;
    display: grid;
    place-items: center;
    width: 20px;
    height: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--color-brand-deep);
    background: #fff;
    border-radius: 50%;
}

.login__form {
    padding: 48px 44px;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

.login__register {
    margin-top: 32px;
    padding-top: 24px;
    border-top: 1px solid rgb(255 255 255 / 25%);
}

.login__register p {
    margin-bottom: 10px;
    font-weight: 500;
}

/* ------------------------------------------------------------------ */
/* Products and quotes                                                 */
/* ------------------------------------------------------------------ */

.section-menu + .section-menu {
    margin-top: 16px;
}

.back-link {
    margin: 0 0 16px;
}

.back-link a {
    font-weight: 500;
    text-decoration: none;
}

.search-box {
    margin-bottom: 24px;
}

.search-box__label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    font-size: 0.9rem;
    color: var(--color-ink);
}

.search-box__row {
    display: flex;
    gap: 10px;
}

.search-box__row input {
    flex: 1;
    min-width: 0;
    min-height: 46px;
    padding: 10px 14px;
    font: inherit;
    color: var(--color-text);
    background: #fff;
    border: 1px solid #c9ced4;
    border-radius: var(--radius-small);
}

.search-box__row input:focus {
    outline: none;
    border-color: var(--color-brand-strong);
    box-shadow: 0 0 0 3px rgb(0 176 237 / 25%);
}

.search-box__row input[aria-invalid="true"] {
    border-color: var(--color-error);
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.category {
    padding: 20px;
}

.category__title {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0 0 12px;
    padding-bottom: 12px;
    font-size: 1.05rem;
    font-weight: 500;
    border-bottom: 1px solid var(--color-border);
}

.category__title img {
    flex-shrink: 0;
    border-radius: var(--radius-small);
}

.category__series,
.file-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.category__series li + li,
.file-list li + li {
    margin-top: 6px;
}

.category__series a {
    text-decoration: none;
}

.category__series a:hover {
    text-decoration: underline;
}

.results-count {
    margin: 0 0 16px;
    color: var(--color-muted);
}

.series-intro,
.product-detail {
    display: flex;
    align-items: flex-start;
    gap: 24px;
    margin-bottom: 20px;
}

.series-intro__photo,
.product-detail__photo {
    flex-shrink: 0;
    max-width: 100%;
    height: auto;
}

.product-detail__code {
    margin: 0 0 6px;
    font-size: 1.3rem;
}

.rich-text {
    min-width: 0;
}

.rich-text > :first-child {
    margin-top: 0;
}

.rich-text > :last-child {
    margin-bottom: 0;
}

.rich-text img {
    max-width: 100%;
    height: auto;
}

.table-scroll {
    /* Containing block of the hidden labels (.visually-hidden, absolute) of the rows: otherwise those of a table
       wider than the screen stick out of the scroll box and the whole page scrolls sideways. */
    position: relative;
    margin-bottom: 20px;
    overflow-x: auto;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
}

.price-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.93rem;
}

.price-table caption {
    padding: 12px 16px;
    font-weight: 500;
    text-align: left;
    color: #fff;
    background: var(--color-brand-strong);
}

.price-table th,
.price-table td {
    padding: 10px 12px;
    text-align: left;
    vertical-align: middle;
    border-bottom: 1px solid var(--color-border);
}

.price-table thead th {
    font-size: 0.8rem;
    font-weight: 500;
    white-space: nowrap;
    color: var(--color-muted);
    background: var(--color-background);
}

.price-table tbody tr:last-child > * {
    border-bottom: 0;
}

.price-table tbody th {
    font-weight: 500;
}

.price-table__photo {
    width: 76px;
}

.price-table__photo img {
    display: block;
    /* A fixed size: with the max-width of every image, a table squeezed on a narrow screen would shrink them to nothing.
       The thumbnails of the series keep their proportions inside 60×60. */
    width: 60px;
    max-width: none;
    height: 60px;
    object-fit: contain;
}

.photo-placeholder {
    display: block;
    width: 60px;
    height: 60px;
    background: var(--color-background);
    border-radius: var(--radius-small);
}

.price-table__code {
    white-space: nowrap;
}

.price-table__code a {
    text-decoration: none;
}

.price-table__code a:hover {
    text-decoration: underline;
}

.price-table__price {
    text-align: right !important;
    white-space: nowrap;
}

.price-table__per {
    display: block;
    font-size: 0.8rem;
    color: var(--color-muted);
}

.price-table__quantity {
    white-space: nowrap;
}

.price-table__quantity input {
    width: 92px;
    min-height: 40px;
    padding: 6px 10px;
    font: inherit;
    color: var(--color-text);
    background: #fff;
    border: 1px solid #c9ced4;
    border-radius: var(--radius-small);
}

.price-table__quantity input:focus {
    outline: none;
    border-color: var(--color-brand-strong);
    box-shadow: 0 0 0 3px rgb(0 176 237 / 25%);
}

.price-table__quantity input[aria-invalid="true"] {
    border-color: var(--color-error);
}

.price-table__quantity .form__error {
    white-space: normal;
}

.price-table__unit {
    margin-left: 6px;
    font-size: 0.85rem;
    color: var(--color-muted);
}

.price-table__add {
    width: 1%;
    text-align: center !important;
}

/* Link at the end of a row (search results of series and FAQ boards) */
.price-table__link {
    width: 1%;
    text-align: right !important;
    white-space: nowrap;
}

.price-table__link a {
    font-weight: 500;
    text-decoration: none;
}

.price-table__link a:hover {
    text-decoration: underline;
}

.price-table__add input {
    width: 20px;
    height: 20px;
    accent-color: var(--color-brand-strong);
    cursor: pointer;
}

.price-form {
    margin-bottom: 24px;
}

.price-form__footer {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px 20px;
    padding: 16px 20px;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
}

.price-form__total,
.quote-subtotals p,
.quote-total p:first-child {
    margin: 0;
}

.price-form__total strong,
.quote-subtotals strong {
    margin-left: 6px;
    font-size: 1.15rem;
}

.price-form__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.documents__title {
    margin: 0 0 8px;
    font-size: 1.15rem;
}

.documents__subtitle {
    margin: 20px 0 8px;
    font-size: 1rem;
}

.documents p:last-child {
    margin-bottom: 0;
}

.add-code {
    margin-bottom: 24px;
}

.add-code .form__hint {
    margin-top: 4px;
}

.code-search {
    position: relative;
    display: flex;
    flex: 1;
    min-width: 0;
}

.suggestions {
    position: absolute;
    top: calc(100% + 4px);
    right: 0;
    left: 0;
    z-index: 20;
    max-height: 340px;
    margin: 0;
    padding: 4px;
    overflow-y: auto;
    list-style: none;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-small);
    box-shadow: var(--shadow-hover);
}

.suggestions[hidden] {
    display: none;
}

.suggestions__option {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 8px 12px;
    border-radius: var(--radius-small);
    cursor: pointer;
}

.suggestions__option:hover,
.suggestions__option[aria-selected="true"] {
    background: var(--color-brand-soft);
}

.suggestions__code {
    font-weight: 500;
    color: var(--color-ink);
}

.suggestions__description {
    font-size: 0.85rem;
    color: var(--color-muted);
}

.quote-form .table-scroll {
    margin-bottom: 16px;
}

.quote-subtotals {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px 24px;
}

.quote-discount {
    display: flex;
    align-items: center;
    gap: 8px;
}

.quote-discount label {
    font-weight: 500;
}

.quote-discount input {
    width: 80px;
    min-height: 40px;
    padding: 6px 10px;
    font: inherit;
    border: 1px solid #c9ced4;
    border-radius: var(--radius-small);
}

.quote-discount input[aria-invalid="true"] {
    border-color: var(--color-error);
}

.other-items {
    display: grid;
    gap: 12px;
    margin-bottom: 12px;
}

.other-items__row {
    display: grid;
    grid-template-columns: minmax(0, 3fr) minmax(0, 1fr);
    gap: 12px;
}

.other-items__row[hidden] {
    display: none;
}

.quote-total p:first-child strong {
    margin-left: 6px;
    font-size: 1.4rem;
    color: var(--color-ink);
}

.quote-total .muted {
    font-size: 0.88rem;
}

.quote-total .form__actions {
    margin-top: 16px;
}

.price-table__remove {
    width: 1%;
}

.link-button {
    padding: 0;
    font: inherit;
    font-size: 0.9rem;
    color: var(--color-error);
    text-decoration: underline;
    background: none;
    border: 0;
    cursor: pointer;
}

.button--danger {
    color: var(--color-error);
    border-color: var(--color-error);
}

.button--danger:hover {
    color: #fff;
    background: var(--color-error);
    border-color: var(--color-error);
}

.quote-actions {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-bottom: 24px;
}

.quote-actions h2 {
    margin-top: 0;
    font-size: 1.15rem;
}

.pagination {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 16px;
}

.pagination__item {
    min-width: 40px;
    padding: 8px 12px;
    text-align: center;
    text-decoration: none;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-small);
}

.pagination__item.is-current {
    font-weight: 500;
    color: #fff;
    background: var(--color-brand-strong);
    border-color: var(--color-brand-strong);
}

.pagination__item.is-disabled {
    color: var(--color-muted);
}

/* ------------------------------------------------------------------ */
/* Tabs (public/js/frontend.js)                                        */
/* ------------------------------------------------------------------ */

.tabs__list {
    display: flex;
    gap: 4px;
    margin-bottom: 20px;
    overflow-x: auto;
    overflow-y: hidden;
    border-bottom: 1px solid var(--color-border);
}

.tabs__tab {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: -1px;
    padding: 10px 16px;
    font-weight: 500;
    white-space: nowrap;
    color: var(--color-text);
    text-decoration: none;
    border-bottom: 3px solid transparent;
}

.tabs__tab:hover {
    color: var(--color-brand-strong);
}

.tabs__tab.is-active {
    color: var(--color-brand-strong);
    border-bottom-color: var(--color-brand);
}

.tabs__tab:focus-visible {
    outline: 2px solid var(--color-brand-strong);
    outline-offset: -2px;
}

.tabs__count {
    min-width: 26px;
    padding: 1px 8px;
    font-size: 0.78rem;
    text-align: center;
    color: var(--color-brand-deep);
    background: var(--color-brand-soft);
    border-radius: 999px;
}

.tabs__panel[hidden] {
    display: none;
}

/* With the tabs, the title of each panel is already on its tab. */
.tabs.is-enhanced .tabs__panel-title {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
}

/* ------------------------------------------------------------------ */
/* News and events                                                     */
/* ------------------------------------------------------------------ */

.page-intro {
    max-width: 860px;
    margin: 0 0 24px;
    font-size: 1.02rem;
}

.carousel {
    margin-bottom: 32px;
}

.carousel__slides {
    display: grid;
    gap: 2px;
    overflow: hidden;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.carousel__slide img {
    display: block;
    width: 100%;
    height: auto;
}

/* With JavaScript the banners are stacked in the same cell, so the box keeps the height of the tallest one,
   and they cross-fade: the hidden ones stay loaded and become invisible only at the end of the fade. */
.carousel.is-enhanced .carousel__slides {
    gap: 0;
}

.carousel.is-enhanced .carousel__slide {
    display: flex;
    align-items: center;
    grid-area: 1 / 1;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.8s ease, visibility 0s linear 0.8s;
}

.carousel.is-enhanced .carousel__slide > a {
    width: 100%;
}

.carousel.is-enhanced .carousel__slide.is-active {
    z-index: 1;
    opacity: 1;
    visibility: visible;
    transition: opacity 0.8s ease, visibility 0s;
}

@media (prefers-reduced-motion: reduce) {
    .carousel.is-enhanced .carousel__slide,
    .carousel.is-enhanced .carousel__slide.is-active {
        transition: none;
    }
}

/* Under the banners, centred */
.carousel__controls {
    display: flex;
    align-items: center;
    gap: 6px;
    width: fit-content;
    margin: 12px auto 0;
    padding: 4px;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: 999px;
    box-shadow: var(--shadow);
}

.carousel__controls[hidden] {
    display: none;
}

.carousel__button {
    min-width: 36px;
    min-height: 36px;
    padding: 0 10px;
    font: inherit;
    font-size: 0.85rem;
    line-height: 1;
    color: var(--color-ink);
    background: transparent;
    border: 0;
    border-radius: 999px;
    cursor: pointer;
}

.carousel__button span[aria-hidden="true"] {
    font-size: 1.4rem;
}

.carousel__button:hover,
.carousel__button:focus-visible {
    color: var(--color-brand-strong);
    background: var(--color-background);
}

.carousel__position {
    min-width: 40px;
    font-size: 0.85rem;
    text-align: center;
    color: var(--color-muted);
}

.news-section {
    margin-bottom: 36px;
}

.news-section__header {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: 8px 16px;
}

.news-section__header a {
    font-weight: 500;
    text-decoration: none;
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

/* One news per row on every screen, as on mobile (page "Comunicazioni") */
.news-grid--list {
    grid-template-columns: minmax(0, 1fr);
}

.news-card {
    display: grid;
    grid-template-columns: 96px minmax(0, 1fr);
    align-items: start;
    gap: 16px;
    padding: 20px;
}

.news-card__body:only-child {
    grid-column: 1 / -1;
}

.news-card__photo img {
    display: block;
    width: 96px;
    height: 96px;
    object-fit: cover;
    border-radius: var(--radius-small);
}

.news-card__date {
    margin: 0 0 4px;
    font-size: 0.8rem;
    font-weight: 500;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: var(--color-brand-strong);
}

.news-card__title {
    margin: 0 0 6px;
    font-size: 1.05rem;
    font-weight: 500;
    line-height: 1.35;
}

.news-card__title a {
    color: var(--color-ink);
    text-decoration: none;
}

.news-card__title a:hover {
    color: var(--color-brand-strong);
    text-decoration: underline;
}

.news-card__text {
    display: -webkit-box;
    margin: 0;
    overflow: hidden;
    font-size: 0.92rem;
    color: var(--color-muted);
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
}

.news-article {
    max-width: 860px;
}

.news-article__subtitle {
    margin: 28px 0 12px;
    font-size: 1.1rem;
}

.photo-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 12px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.photo-gallery figure {
    margin: 0;
}

.photo-gallery img {
    display: block;
    width: 100%;
    height: 140px;
    object-fit: cover;
    border-radius: var(--radius-small);
}

.photo-gallery figcaption {
    margin-top: 4px;
    font-size: 0.82rem;
    color: var(--color-muted);
}

/* ------------------------------------------------------------------ */
/* FAQ                                                                 */
/* ------------------------------------------------------------------ */

.board-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.board-list a {
    display: block;
    padding: 10px 14px;
    font-weight: 500;
    color: var(--color-ink);
    text-decoration: none;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-small);
}

.board-list a:hover {
    color: var(--color-brand-strong);
    border-color: var(--color-brand-strong);
}

.faq-list,
.faq-request {
    max-width: 860px;
    margin-bottom: 20px;
}

.faq-list__title {
    margin: 0 0 6px;
    font-size: 1.15rem;
}

/* Board the malfunctions belong to, above them */
.faq-list__header {
    margin-bottom: 18px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--color-border);
}

.faq-list__family {
    margin: 0 0 4px;
    font-size: 0.8rem;
    font-weight: 500;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: var(--color-brand-strong);
}

.faq-list__board {
    margin: 0;
    font-size: 1.6rem;
    font-weight: 500;
    line-height: 1.25;
    color: var(--color-ink);
}

.faq-item {
    border-top: 1px solid var(--color-border);
}

.faq-item summary {
    padding: 12px 0;
    font-weight: 500;
    color: var(--color-ink);
    cursor: pointer;
}

.faq-item summary:hover {
    color: var(--color-brand-strong);
}

.faq-item__checks {
    margin: 0 0 16px;
    padding-left: 24px;
}

.faq-item__checks li + li {
    margin-top: 6px;
}

.faq-request textarea {
    width: 100%;
    padding: 10px 14px;
    font: inherit;
    color: var(--color-text);
    background: #fff;
    border: 1px solid #c9ced4;
    border-radius: var(--radius-small);
    resize: vertical;
}

.faq-request textarea:focus {
    outline: none;
    border-color: var(--color-brand-strong);
    box-shadow: 0 0 0 3px rgb(0 176 237 / 25%);
}

.faq-request textarea[aria-invalid="true"] {
    border-color: var(--color-error);
}

/* ------------------------------------------------------------------ */
/* Contacts                                                            */
/* ------------------------------------------------------------------ */

.contacts {
    display: grid;
    gap: 20px;
}

.contacts__intro > :first-child {
    margin-top: 0;
}

.contacts__hotline {
    margin-top: 20px;
    padding: 16px 20px;
    background: var(--color-brand-soft);
    border-left: 4px solid var(--color-brand);
    border-radius: var(--radius-small);
}

.contacts__hotline p {
    margin: 0;
}

.contacts__hotline-label {
    font-weight: 500;
    color: var(--color-ink);
}

.contacts__hotline-number {
    display: inline-block;
    margin: 4px 0;
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--color-brand-deep);
    text-decoration: none;
}

.contacts__hotline-number:hover {
    text-decoration: underline;
}

/* Extensions to choose during the call: the key to press in a round badge. */
.contacts__extensions {
    display: grid;
    gap: 6px;
    margin: 8px 0 12px;
    padding: 0;
    list-style: none;
}

.contacts__extensions li {
    display: flex;
    align-items: center;
    gap: 10px;
}

.contacts__extension {
    display: inline-grid;
    flex: none;
    place-items: center;
    width: 26px;
    height: 26px;
    font-size: 0.85rem;
    font-weight: 700;
    color: #fff;
    background: var(--color-brand-strong);
    border-radius: 50%;
}

.contacts__offices {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 20px;
}

.contacts__office h2 {
    margin: 0 0 10px;
    font-size: 1.05rem;
    line-height: 1.4;
    color: var(--color-brand-strong);
}

.contacts__office address {
    font-style: normal;
    line-height: 1.6;
}

/* ------------------------------------------------------------------ */
/* Training                                                            */
/* ------------------------------------------------------------------ */

.training__banner {
    display: block;
    margin-top: 24px;
}

.training__banner img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: var(--radius-small);
}

/* ------------------------------------------------------------------ */
/* Downloads                                                           */
/* ------------------------------------------------------------------ */

.download-group {
    margin-bottom: 20px;
}

.download-group__title {
    margin: 0 0 12px;
    font-size: 1.15rem;
}

.download-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.download-list__item {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr) auto;
    align-items: center;
    gap: 14px;
    padding: 12px 0;
    border-top: 1px solid var(--color-border);
}

.download-list__type {
    padding: 4px 0;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-align: center;
    color: var(--color-brand-deep);
    background: var(--color-brand-soft);
    border-radius: var(--radius-small);
}

.download-list__body {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.download-list__name {
    font-weight: 500;
    overflow-wrap: anywhere;
}

.download-list__detail,
.download-list__size {
    font-size: 0.85rem;
    color: var(--color-muted);
}

.download-list__size {
    white-space: nowrap;
}

/* ------------------------------------------------------------------ */
/* Error pages                                                         */
/* ------------------------------------------------------------------ */

.error-page {
    max-width: 560px;
    margin: 24px auto 0;
    text-align: center;
}

.error-page__code {
    margin-bottom: 8px;
    font-size: 3.5rem;
    font-weight: 300;
    line-height: 1;
    color: var(--color-brand-strong);
}

/* ------------------------------------------------------------------ */
/* Footer                                                              */
/* ------------------------------------------------------------------ */

.site-footer {
    padding: 28px 0 32px;
    font-size: 0.9rem;
    color: #fff;
    background: var(--color-brand-deep);
    border-top: 4px solid var(--color-brand);
}

.site-footer a {
    color: #fff;
}

.site-footer__top {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding-bottom: 20px;
    margin-bottom: 20px;
    border-bottom: 1px solid rgb(255 255 255 / 20%);
}

.site-footer__toplink {
    font-weight: 500;
    text-decoration: none;
}

.site-footer__toplink:hover {
    text-decoration: underline;
}

.social-links {
    display: flex;
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.social-links a {
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    background: rgb(255 255 255 / 12%);
    border-radius: 50%;
    transition: background-color 0.15s ease;
}

.social-links a:hover {
    background: rgb(255 255 255 / 25%);
}

.site-footer__links {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 24px;
    margin: 0 0 12px;
    padding: 0;
    list-style: none;
}

.site-footer__links a {
    text-decoration: none;
}

.site-footer__links a:hover {
    text-decoration: underline;
}

.site-footer__copyright {
    margin: 0;
    font-size: 0.82rem;
    color: rgb(255 255 255 / 85%);
}

/* ------------------------------------------------------------------ */
/* Responsive                                                          */
/* ------------------------------------------------------------------ */

@media (max-width: 1080px) {
    .main-nav__description {
        display: none;
    }
}

@media (max-width: 960px) {
    .nav-toggle {
        display: block;
    }

    /* With the menu button, name and "Esci" give way to the account menu of the avatar. */
    .user-menu,
    .site-header__logout {
        display: none;
    }

    .account-menu {
        display: block;
    }

    .main-nav__list {
        flex-direction: column;
        padding: 8px 0 12px;
    }

    .main-nav__link {
        flex-direction: row;
        align-items: baseline;
        justify-content: space-between;
        padding: 12px;
        border-radius: var(--radius-small);
    }

    .main-nav__link::after {
        top: 10px;
        right: auto;
        bottom: 10px;
        left: 0;
        width: 3px;
        height: auto;
        border-radius: 0 3px 3px 0;
        transform: scaleY(0);
    }

    .main-nav__link:hover::after,
    .main-nav__link.is-active::after {
        transform: scaleY(1);
    }

    .main-nav__description {
        display: block;
        text-align: right;
    }

    /* Without JavaScript the menu stays open; with it, the button toggles it. */
    .has-js .main-nav {
        display: none;
    }

    .has-js .main-nav.is-open {
        display: block;
    }

    .with-sidebar {
        grid-template-columns: minmax(0, 1fr);
        gap: 24px;
    }

    /* The side menus start closed here: until frontend.js closes them, their content is hidden. */
    .has-js .section-menu__details:not([data-ready]) > :not(summary) {
        display: none;
    }

    .login {
        grid-template-columns: minmax(0, 1fr);
        max-width: 520px;
    }

    .login__intro,
    .login__form {
        padding: 32px 28px;
    }

    /* One column: the form comes first, the presentation and the registration link below it. */
    .login__form {
        order: -1;
    }

    .form-grid--three {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .form-grid--phones {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media (max-width: 720px) {
    .form-grid,
    .form-grid--three,
    .form-grid--address,
    .benefits {
        grid-template-columns: minmax(0, 1fr);
    }

    .automations__row {
        grid-template-columns: minmax(0, 1fr);
        gap: 8px;
    }

    .form-section {
        padding: 20px 16px;
    }

    .series-intro,
    .product-detail {
        flex-direction: column;
    }

    .other-items__row {
        grid-template-columns: minmax(0, 1fr);
        padding-bottom: 12px;
        border-bottom: 1px solid var(--color-border);
    }
}

@media (max-width: 720px) {
    .site-header__tagline span {
        display: none;
    }
}

@media (max-width: 520px) {
    .site-header__bar {
        min-height: 64px;
        gap: 10px;
    }

    .site-header__brand {
        gap: 10px;
    }

    .site-header__brand img {
        width: 96px;
    }

    .site-header__tagline {
        padding-left: 10px;
        font-size: 0.85rem;
    }

    .main-nav__description {
        display: none;
    }

    .page-hero {
        padding: 28px 0 32px;
    }

    .site-main {
        padding: 24px 0 40px;
    }

    .card,
    .login__intro,
    .login__form {
        padding: 22px 18px;
    }

    .page-login .site-main {
        padding-top: 16px;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        transition: none !important;
        scroll-behavior: auto !important;
    }

    .confirm-dialog[open] {
        animation: none;
    }
}
