/* HouseMatch Immobili — stili delle pagine annunci.
   Tutti i colori sono variabili: il tema può ridefinirle su .hm senza toccare il plugin.
   Contrasti verificati WCAG AA (testo su bianco ≥ 4.5:1, bianco sul primario ≥ 4.5:1). */
.hm, .hm-splash {
  --hm-primary: #0d4694;
  --hm-primary-hover: #0a3672;
  --hm-text: #1d2433;
  --hm-muted: #5a6375;
  --hm-border: #d9dee7;
  --hm-surface: #f5f7fa;
  --hm-bg: #ffffff;
  --hm-accent: #1f7a3f;
  --hm-radius: 10px;
  --hm-gap: 1.25rem;
  color: var(--hm-text);
  background: var(--hm-bg);
  line-height: 1.55;
}
.hm *, .hm *::before, .hm *::after { box-sizing: border-box; }
.hm-wrap { max-width: 1200px; margin: 0 auto; padding: 1.5rem 1rem 3rem; }
.hm-h1 { font-size: clamp(1.5rem, 2.6vw, 2.2rem); line-height: 1.2; margin: .25rem 0 .5rem; }
.hm-h2 { font-size: 1.25rem; margin: 0 0 .75rem; }
.hm-muted { color: var(--hm-muted); font-size: .92rem; margin: 0; }
.hm-eyebrow { text-transform: uppercase; letter-spacing: .06em; font-size: .8rem; color: var(--hm-muted); margin: 0; }
.hm-link { color: var(--hm-primary); }
/* Link dentro il testo sempre sottolineati: il tema toglie la sottolineatura e il solo colore non basta (WCAG 1.4.1) */
.hm-check a, .hm-prose a, .hm-tour__links a, .hm-breadcrumb a, .hm-notice a, .hm-link { text-decoration: underline; text-underline-offset: 2px; }
.hm a:focus-visible, .hm button:focus-visible, .hm input:focus-visible, .hm select:focus-visible, .hm textarea:focus-visible {
  outline: 3px solid var(--hm-primary); outline-offset: 2px;
}

/* Pulsanti */
.hm-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .4rem;
  background: var(--hm-primary); color: #fff; border: 2px solid var(--hm-primary);
  border-radius: var(--hm-radius); padding: .65rem 1.1rem; font-weight: 600; font-size: 1rem;
  cursor: pointer; text-decoration: none; min-height: 44px;
}
.hm-btn:hover { background: var(--hm-primary-hover); border-color: var(--hm-primary-hover); color: #fff; }
.hm-btn--ghost { background: transparent; color: var(--hm-primary); }
.hm-btn--ghost:hover { background: var(--hm-surface); color: var(--hm-primary-hover); }
.hm-btn--block { width: 100%; }
.hm-btn[disabled] { opacity: .6; cursor: progress; }

/* Filtri */
.hm-filters {
  display: grid; gap: .75rem 1rem; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  background: var(--hm-surface); border: 1px solid var(--hm-border); border-radius: var(--hm-radius);
  padding: 1rem; margin: 1rem 0 1.5rem;
}
.hm-filters__actions { display: flex; align-items: end; gap: 1rem; }
.hm-filters__toggle { display: none; }
.hm-filters__count { display: inline-grid; place-items: center; min-width: 1.4em; height: 1.4em; padding: 0 .3em; border-radius: 999px;
  background: var(--hm-accent, #1f7a3f); color: #fff; font-size: .8rem; }
@media (max-width: 767px) {
  /* Filtri compatti: in vista contratto e prezzo massimo, il resto dietro «Filtri» */
  .hm-filters { grid-template-columns: 1fr 1fr; gap: .6rem; padding: .8rem; }
  .hm-filters .hm-field--more { display: none; }
  .hm-filters.is-open .hm-field--more { display: flex; }
  .hm-filters.is-open .hm-filters__tour { display: flex; grid-column: 1 / -1; }
  .hm-filters__actions { grid-column: 1 / -1; display: grid; grid-template-columns: 1fr 1fr; gap: .6rem; align-items: center; }
  .hm-filters__actions .hm-link { grid-column: 1 / -1; justify-self: center; }
  .hm-filters__toggle { display: inline-flex; justify-content: center; align-items: center; gap: .4rem; }
  .hm-filters__actions .hm-btn { width: 100%; min-height: 48px; }
  /* senza contratto in vista (pagine Vendita / Affitto) il prezzo prende tutta la riga */
  .hm-filters--fixed:not(.is-open) .hm-field--pmax { grid-column: 1 / -1; }
}
.hm-field { display: flex; flex-direction: column; gap: .3rem; }
.hm-field label { font-weight: 600; font-size: .9rem; }
.hm-field input, .hm-field select, .hm-field textarea {
  width: 100%; border: 1px solid #8c94a3; border-radius: 8px; padding: .55rem .65rem;
  font: inherit; color: var(--hm-text); background: #fff; min-height: 44px;
}

/* Griglia e card */
.hm-grid { display: grid; gap: var(--hm-gap); grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.hm-card { border: 1px solid var(--hm-border); border-radius: var(--hm-radius); overflow: hidden; background: #fff; transition: box-shadow .15s, transform .15s; }
.hm-card:hover { box-shadow: 0 6px 20px rgba(13, 70, 148, .12); transform: translateY(-2px); }
.hm-card__link { color: inherit; text-decoration: none; display: block; height: 100%; }
.hm-card__media { position: relative; aspect-ratio: 4 / 3; background: var(--hm-surface); overflow: hidden; }
.hm-card__img { width: 100%; height: 100%; object-fit: cover; display: block; }
/* foto verticali o temi che forzano height:auto: l'immagine riempie sempre il riquadro 4:3 */
.hm-card__media > img.hm-card__img { position: absolute; inset: 0; width: 100% !important; height: 100% !important; max-width: none; }
.hm-card__img--empty { background: linear-gradient(135deg, #e6ebf2, #f5f7fa); }
.hm-badge { position: absolute; top: .6rem; left: .6rem; background: var(--hm-accent); color: #fff; font-size: .8rem; font-weight: 700; padding: .25rem .6rem; border-radius: 999px; }
.hm-card__body { padding: .9rem 1rem 1.1rem; }
.hm-card__price { font-size: 1.25rem; font-weight: 700; color: var(--hm-primary); margin: 0 0 .25rem; }
.hm-card__title { font-size: 1rem; margin: 0 0 .35rem; line-height: 1.35; }
.hm-card__place, .hm-card__facts, .hm-card__energy { margin: 0; font-size: .9rem; color: var(--hm-muted); }
.hm-pagination { margin-top: 2rem; display: flex; gap: .5rem; flex-wrap: wrap; }
.hm-pagination .page-numbers { padding: .45rem .8rem; border: 1px solid var(--hm-border); border-radius: 8px; text-decoration: none; color: var(--hm-primary); }
.hm-pagination .current { background: var(--hm-primary); color: #fff; border-color: var(--hm-primary); }
.hm-empty { padding: 2rem; background: var(--hm-surface); border-radius: var(--hm-radius); }

/* Scheda */
.hm-breadcrumb { font-size: .9rem; color: var(--hm-muted); display: flex; gap: .4rem; flex-wrap: wrap; margin-bottom: .5rem; }
.hm-breadcrumb a { color: var(--hm-primary); }
.hm-notice { background: #fff4e5; border: 1px solid #f0b46a; border-radius: var(--hm-radius); padding: .8rem 1rem; margin: .5rem 0 1rem; display: flex; gap: 1rem; flex-wrap: wrap; }
.hm-single__place { color: var(--hm-muted); margin: 0 0 1rem; }
.hm-gallery__track { list-style: none; margin: 0; padding: 0; display: grid; grid-auto-flow: column; grid-auto-columns: minmax(80%, 1fr); gap: .5rem; overflow-x: auto; scroll-snap-type: x mandatory; border-radius: var(--hm-radius); }
@media (min-width: 900px) { .hm-gallery__track { grid-auto-columns: calc(50% - .25rem); } }
.hm-gallery__item { scroll-snap-align: start; aspect-ratio: 4 / 3; }
.hm-gallery__open { all: unset; cursor: zoom-in; display: block; width: 100%; height: 100%; }
.hm-gallery__open img { width: 100%; height: 100%; object-fit: cover; display: block; border-radius: 6px; }
.hm-gallery__count { margin-top: .4rem; }
.hm-lightbox { border: 0; padding: 0; background: #000; max-width: 100vw; max-height: 100vh; width: 100vw; height: 100vh; }
.hm-lightbox::backdrop { background: rgba(0, 0, 0, .9); }
.hm-lightbox__img { width: 100%; height: 100%; object-fit: contain; }
.hm-lightbox button { position: absolute; background: rgba(0, 0, 0, .55); color: #fff; border: 0; font-size: 2rem; width: 52px; height: 52px; border-radius: 50%; cursor: pointer; }
.hm-lightbox__close { top: 1rem; right: 1rem; }
.hm-lightbox__prev { left: 1rem; top: 50%; transform: translateY(-50%); }
.hm-lightbox__next { right: 1rem; top: 50%; transform: translateY(-50%); }
.hm-single__layout { display: grid; gap: 2rem; margin-top: 1.5rem; }
@media (min-width: 1024px) { .hm-single__layout { grid-template-columns: minmax(0, 2fr) minmax(300px, 1fr); } .hm-single__aside { position: sticky; top: 1.5rem; align-self: start; } }
.hm-price { font-size: 2rem; font-weight: 800; color: var(--hm-primary); margin: 0; }
.hm-facts { font-size: 1.05rem; margin: .25rem 0 1rem; }
.hm-section { margin-top: 2rem; }
.hm-dl { margin: 0; display: grid; gap: .5rem; }
.hm-dl > div { display: flex; gap: .75rem; justify-content: space-between; border-bottom: 1px solid var(--hm-border); padding: .45rem 0; }
.hm-dl dt { color: var(--hm-muted); }
.hm-dl dd { margin: 0; font-weight: 600; text-align: right; }
.hm-dl--grid { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); column-gap: 2rem; }
.hm-energy { display: inline-block; padding: .1rem .55rem; border-radius: 4px; background: var(--hm-surface); border: 1px solid var(--hm-border); margin-right: .4rem; }
.hm-prose { font-size: 1.04rem; max-width: 70ch; }
.hm-prose p { margin: 0 0 1rem; }
.hm-prose strong { font-weight: 700; color: var(--hm-text); }
.hm-prose__list { margin: -.25rem 0 1.1rem; padding-left: 1.25rem; display: grid; gap: .3rem; }
.hm-prose__list li::marker { color: var(--hm-primary); }
.hm-prose__cta { border-left: 3px solid var(--hm-primary); padding: .4rem 0 .4rem .9rem; color: var(--hm-muted); margin-top: 1.25rem; }
.hm-floorplan { max-width: 100%; height: auto; border: 1px solid var(--hm-border); border-radius: var(--hm-radius); background: #fff; }
.hm-embed { border: 1px dashed var(--hm-border); border-radius: var(--hm-radius); padding: 1.25rem; display: grid; gap: .5rem; justify-items: start; }
.hm-embed iframe { width: 100%; aspect-ratio: 16 / 9; border: 0; border-radius: var(--hm-radius); }
.hm-embed.is-loaded { padding: 0; border: 0; }
.hm-contact { background: var(--hm-surface); border: 1px solid var(--hm-border); border-radius: var(--hm-radius); padding: 1.25rem; }
.hm-contact__quick { display: flex; gap: .5rem; flex-wrap: wrap; margin: 0 0 1rem; }

/* Tour 3D in apertura della scheda */
.hm-tour { margin: .5rem 0 1.25rem; }
.hm-tour__stage { position: relative; aspect-ratio: 16 / 9; border-radius: var(--hm-radius); overflow: hidden; background: #111; }
@media (max-width: 640px) { .hm-tour__stage { aspect-ratio: 4 / 3; } }
.hm-tour__poster { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: brightness(.62); }
.hm-tour__play {
  position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .5rem;
  background: transparent; border: 0; color: #fff; cursor: pointer; text-align: center; padding: 1rem; font: inherit;
}
.hm-tour__icon {
  display: grid; place-items: center; width: 84px; height: 84px; border-radius: 50%; padding-left: .25rem;
  background: var(--hm-primary); color: #fff; box-shadow: 0 0 0 10px rgba(255, 255, 255, .22); transition: transform .2s;
}
.hm-tour__play:hover .hm-tour__icon, .hm-tour__play:focus-visible .hm-tour__icon { transform: scale(1.08); }
.hm-tour__play:focus-visible { outline: 3px solid #fff; outline-offset: -6px; }
.hm-tour__cta { font-size: clamp(1.3rem, 3vw, 2rem); font-weight: 800; text-shadow: 0 2px 8px rgba(0, 0, 0, .5); }
.hm-tour__sub { font-size: 1rem; text-shadow: 0 1px 6px rgba(0, 0, 0, .6); }
.hm-tour__stage.is-loaded { background: #000; }
.hm-tour__stage iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; aspect-ratio: auto; border-radius: 0; }
.hm-tour__links { display: flex; gap: 1rem; flex-wrap: wrap; align-items: baseline; margin: .5rem 0 0; font-size: .9rem; }
.hm-tour__links a { color: var(--hm-primary); font-weight: 600; }
.hm-badge--offer { background: #8a4b00; }
.hm-badge--closed { background: #8f1d1d; }
.hm-card--sold .hm-card__img, .hm-card--rented .hm-card__img { filter: grayscale(.35); }
.hm-notice--closed { background: #fdecec; border-color: #e3a0a0; }
.hm-notice span { flex-basis: 100%; }
.hm-badge--tour { left: auto; right: .6rem; background: rgba(0, 0, 0, .72); }
.hm-filters__tour { align-self: end; padding-bottom: .6rem; }
@media (prefers-reduced-motion: reduce) { .hm-tour__icon { transition: none; } }

/* Ricerca rapida (home) e «vedi tutti» */
.hm-quick { display: grid; gap: .75rem; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); align-items: end;
  background: rgba(255, 255, 255, .96); border: 1px solid var(--hm-border); border-radius: var(--hm-radius); padding: 1rem; }
.hm-quick__go .hm-btn { width: 100%; }
/* Larghezza propria: alcuni contenitori (es. sezioni Elementor «larghe quanto il contenuto»)
   si restringono sul contenuto e una griglia fluida finirebbe larga zero. */
.hm-quick { width: min(1100px, calc(100vw - 2rem)); margin-inline: auto; }
.hm-more { text-align: center; margin: 1.5rem 0 0; }
.hm-swipe-hint { display: none; }

/* ── Telefono prima di tutto ─────────────────────────────────────────────── */
@media (max-width: 767px) {
  /* File di annunci da scorrere col dito, con la card successiva che si intravede */
  .hm-grid--scroll { grid-auto-flow: column; grid-template-columns: none; grid-auto-columns: 84%; overflow-x: auto;
    scroll-snap-type: x mandatory; overscroll-behavior-x: contain; padding-bottom: .5rem; scrollbar-width: none; }
  .hm-grid--scroll::-webkit-scrollbar { display: none; }
  .hm-grid--scroll > * { scroll-snap-align: start; }
  .hm-swipe-hint { display: block; text-align: right; font-size: .85rem; color: var(--hm-muted, #5b6470); margin: .25rem 0 0; }
  /* Ricerca rapida su due colonne: «Cerco» e il pulsante a tutta larghezza */
  .hm-quick { grid-template-columns: 1fr 1fr; gap: .5rem .6rem; padding: .9rem; }
  .hm-quick > .hm-field:first-child, .hm-quick__go { grid-column: 1 / -1; }
}

/* Barra contatti fissa in basso nella scheda, solo su schermi stretti */
.hm-stickybar { display: none; }
.hm-single__headline { display: flex; flex-wrap: wrap; align-items: baseline; gap: .25rem .75rem; margin: .35rem 0 .5rem; }
.hm-single__headprice { font-size: 1.5rem; color: var(--hm-accent); }
.hm-single__headfacts { color: var(--hm-muted); }
@media (max-width: 767px) {
  /* Percorso: su telefono basta «‹ Immobili», il titolo è subito sotto */
  .hm-breadcrumb [aria-current], .hm-breadcrumb span[aria-hidden] { display: none; }
  .hm-breadcrumb a::before { content: "‹ "; }
}
@media (max-width: 1023px) {
  .hm-stickybar { display: flex; gap: .5rem; position: fixed; left: 0; right: 0; bottom: 0; z-index: 9990;
    padding: .6rem .75rem calc(.6rem + env(safe-area-inset-bottom)); background: #fff; border-top: 1px solid var(--hm-border);
    box-shadow: 0 -4px 16px rgba(0, 0, 0, .08); transition: transform .2s ease; }
  .hm-stickybar.is-hidden { transform: translateY(110%); }
  .hm-stickybar__btn { flex: 1 1 0; display: inline-flex; align-items: center; justify-content: center; gap: .35rem; min-height: 44px;
    border: 1px solid var(--hm-accent); border-radius: var(--hm-radius); color: var(--hm-accent); font-weight: 700; text-decoration: none; font-size: .95rem; }
  .hm-stickybar__btn--main { flex: 1.6 1 0; background: var(--hm-accent); color: #fff; }
  .hm-single { padding-bottom: 76px; }
  /* Il pulsante «preferenze cookie» del banner (WebToffee, CookieYes) sale sopra la barra */
  body:has(.hm-stickybar) .wcc-btn-revisit-wrapper,
  body:has(.hm-stickybar) .cky-btn-revisit-wrapper { bottom: calc(84px + env(safe-area-inset-bottom)) !important; }
}
@media (prefers-reduced-motion: reduce) { .hm-stickybar { transition: none; } }
.hm-search .hm-filters { margin-top: .5rem; }

/* Condivisione */
.hm-share { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; margin: .25rem 0 1.25rem; }
.hm-share__label { font-weight: 600; font-size: .9rem; color: var(--hm-muted); margin-right: .25rem; }
.hm-share__btn {
  display: inline-flex; align-items: center; gap: .4rem; min-height: 40px; padding: .4rem .8rem;
  border: 1px solid var(--hm-border); border-radius: 999px; background: #fff; color: var(--hm-text);
  font: inherit; font-size: .9rem; font-weight: 600; text-decoration: none; cursor: pointer;
}
.hm-share__btn:hover { border-color: var(--hm-primary); color: var(--hm-primary); }
.hm-share__btn--whatsapp svg { color: #1a7f45; }
.hm-share__btn--facebook svg { color: #1659c7; }
.hm-share__btn--telegram svg { color: #1c7fb5; }
.hm-share__btn--email svg { color: var(--hm-primary); }
.hm-share__status { font-size: .85rem; color: var(--hm-accent); }
@media (max-width: 480px) { .hm-share__btn span { display: none; } .hm-share__btn { padding: .5rem; min-width: 44px; justify-content: center; } .hm-share__native span { display: inline; } }

/* Modulo */
.hm-form { display: grid; gap: .8rem; }
/* Modulo generico: fondo proprio, perché può stare sopra immagini o colori del tema */
.hm-form--generic { background: #fff; color: var(--hm-text); border-radius: var(--hm-radius); padding: 1.25rem; box-shadow: 0 4px 18px rgba(0, 0, 0, .08); }
.hm-form__row { display: grid; gap: .8rem; grid-template-columns: 1fr 1fr; }
@media (max-width: 480px) { .hm-form__row { grid-template-columns: 1fr; } }
.hm-check { display: flex; gap: .55rem; align-items: flex-start; font-size: .9rem; }
.hm-check input { width: 20px; height: 20px; margin-top: .15rem; flex: none; }
.hm-hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.hm-form__error { color: #a3141a; font-weight: 600; margin: 0; }
.hm-form__ok { color: var(--hm-accent); font-weight: 700; margin: 0; }
.hm-form__note { font-size: .82rem; }

@media (prefers-reduced-motion: reduce) {
  .hm-card { transition: none; }
  .hm-card:hover { transform: none; }
  .hm-gallery__track { scroll-behavior: auto; }
}

/* ── Apertura a tutto schermo su telefono ([housematch_splash]) ─────────── */
.hm-splash { display: none; }
@media (max-width: 767px) {
  .hm-splash-on .hm-splash { display: flex; position: fixed; inset: 0; z-index: 99980; flex-direction: column;
    justify-content: flex-end; background: #0f2a1a center / cover no-repeat; color: #fff; overflow: hidden;
    transition: transform .6s cubic-bezier(.7, 0, .3, 1), opacity .6s ease; }
  .hm-splash.is-leaving { transform: translateY(-100%); opacity: .6; }
  .hm-splash-on .hm-splash--top { justify-content: flex-start; }
  .hm-splash--top .hm-splash__content { padding-top: calc(4.5rem + env(safe-area-inset-top)); }
  .hm-splash--top .hm-splash__veil { background: linear-gradient(0deg, rgba(0,0,0,.05) 35%, rgba(0,0,0,.65) 100%); }
  .hm-splash__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
  .hm-splash__veil { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,.05) 35%, rgba(0,0,0,.65) 100%); }
  .hm-splash__content { position: relative; padding: 0 1.5rem calc(2.25rem + env(safe-area-inset-bottom)); }
  .hm-splash__title { font-size: 2.1rem; font-weight: 800; line-height: 1.1; margin: 0 0 .5rem; letter-spacing: -.01em;
    text-shadow: 0 2px 12px rgba(0,0,0,.35); }
  .hm-splash__sub { font-size: 1.1rem; line-height: 1.4; margin: 0 0 1.25rem; text-shadow: 0 1px 8px rgba(0,0,0,.4); }
  .hm-splash__go { display: inline-flex; align-items: center; gap: .5rem; min-height: 48px; padding: 0 1.4rem; border: 0;
    border-radius: 999px; background: #fff; color: var(--hm-accent, #1f7a3f); font-weight: 800; font-size: 1.05rem; cursor: pointer; }
  .hm-splash__skip { position: absolute; top: calc(.75rem + env(safe-area-inset-top)); right: .75rem; min-height: 44px; min-width: 44px;
    padding: 0 .9rem; border: 1px solid rgba(255,255,255,.6); border-radius: 999px; background: rgba(0,0,0,.25); color: #fff; font-weight: 700; }
  .hm-splash__go:focus-visible, .hm-splash__skip:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }
  /* Barra del tempo: quando finisce, l'apertura si chiude */
  .hm-splash__bar { position: absolute; left: 0; bottom: 0; height: 3px; width: 100%; background: rgba(255,255,255,.85);
    transform-origin: left; animation: hm-splash-bar var(--hm-splash-ms, 6s) linear forwards; }
}
@keyframes hm-splash-bar { from { transform: scaleX(0); } to { transform: scaleX(1); } }

/* ── Notifiche delle nuove offerte ([housematch_avvisi]) ─────────────────── */
.hm-avvisi { margin: 1.5rem 0; padding: 1.1rem 1.25rem; border: 1px solid var(--hm-border); border-radius: var(--hm-radius);
  background: linear-gradient(180deg, #f6faf7, #fff); }
.hm-avvisi[hidden] { display: none; }
.hm-avvisi__head { display: flex; gap: .75rem; align-items: flex-start; margin-bottom: .75rem; }
.hm-avvisi__head .hm-h2 { margin: 0 0 .2rem; font-size: 1.15rem; }
.hm-avvisi__bell { font-size: 1.6rem; line-height: 1; }
.hm-avvisi__form { display: grid; gap: .6rem; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); align-items: end; }
.hm-avvisi__go .hm-btn { width: 100%; min-height: 56px; font-size: 1.1rem; font-weight: 800; }
.hm-avvisi__actions { display: flex; gap: .75rem; align-items: center; flex-wrap: wrap; margin: .5rem 0 0; }
.hm-avvisi__ios ol { margin: .25rem 0 0 1.25rem; padding: 0; }
.hm-avvisi__msg:empty { display: none; }
.hm-avvisi__msg { margin: .6rem 0 0; font-weight: 600; }
.hm-avvisi__legal { margin: .75rem 0 0; font-size: .82rem; }
.hm-single__aside .hm-avvisi__form { grid-template-columns: 1fr 1fr; }
.hm-single__aside .hm-avvisi__form > .hm-field:first-child, .hm-single__aside .hm-avvisi__go { grid-column: 1 / -1; }
@media (max-width: 767px) {
  .hm-avvisi__form { grid-template-columns: 1fr 1fr; }
  .hm-avvisi__form > .hm-field:first-child, .hm-avvisi__go { grid-column: 1 / -1; }
}

/* Pulsante fisso che porta al riquadro degli avvisi */
.hm-bell { position: fixed; left: .75rem; right: .75rem; bottom: calc(.75rem + env(safe-area-inset-bottom)); z-index: 99960;
  display: flex; align-items: center; gap: .75rem; min-height: 64px; padding: .55rem 1.1rem .55rem .8rem; border: 0; border-radius: 18px;
  background: var(--hm-accent, #1f7a3f); color: #fff; text-align: left; box-shadow: 0 8px 24px rgba(0,0,0,.25); cursor: pointer; }
.hm-bell__icon { flex: none; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: rgba(255,255,255,.18); font-size: 1.45rem; }
.hm-bell__text { display: flex; flex-direction: column; line-height: 1.2; }
.hm-bell__text strong { font-size: 1.05rem; font-weight: 800; }
.hm-bell__text small { font-size: .85rem; opacity: .9; margin-top: .15rem; }
.hm-bell[hidden] { display: none; }
.hm-bell:focus-visible { outline: 3px solid #1a1a1a; outline-offset: 3px; }
body:has(.hm-stickybar) .hm-bell { bottom: calc(84px + env(safe-area-inset-bottom)); }
/* lascia libero l'angolo dell'icona delle preferenze cookie */
body:has(.wcc-btn-revisit-wrapper) .hm-bell, body:has(.cky-btn-revisit-wrapper) .hm-bell { right: 4.5rem; }
body:has(.hm-install:not([hidden])) .hm-bell { display: none; }
.hm-avvisi.is-highlight { box-shadow: 0 0 0 4px var(--hm-accent, #1f7a3f); transition: box-shadow .3s ease; }
@media (min-width: 1024px) { .hm-bell { display: none; } }

/* ── Invito a installare l'app ─────────────────────────────────────────── */
.hm-install { position: fixed; left: .75rem; right: .75rem; bottom: calc(.75rem + env(safe-area-inset-bottom)); z-index: 99970;
  display: flex; gap: .75rem; align-items: center; padding: .8rem .9rem; border-radius: 14px; background: #fff; color: #1a1a1a;
  box-shadow: 0 8px 30px rgba(0,0,0,.18); border: 1px solid var(--hm-border, #e3e6ea); font-size: .95rem; }
.hm-install[hidden] { display: none; }
.hm-install img { width: 44px; height: 44px; border-radius: 10px; flex: none; }
.hm-install__text { flex: 1; line-height: 1.3; }
.hm-install__text strong { display: block; }
.hm-install__go { min-height: 44px; padding: 0 1rem; border: 0; border-radius: 999px; background: var(--hm-accent, #1f7a3f); color: #fff; font-weight: 700; }
.hm-install__no { min-height: 44px; min-width: 44px; border: 0; background: none; color: #555; font-size: 1.3rem; }
body:has(.hm-stickybar) .hm-install { bottom: calc(84px + env(safe-area-inset-bottom)); }
@media (min-width: 1024px) { .hm-install { left: auto; width: 380px; } }

/* Il tema mette le iniziali maiuscole a ogni parola nei titoli: nel plugin no */
.hm h1, .hm h2, .hm h3, .hm .hm-h1, .hm .hm-h2 { text-transform: none; }

/* ── «Scarica l'app»: riquadro (home, scheda) e fascia prima del piè di pagina ── */
.hm-app { display: flex; align-items: center; gap: .9rem; margin: 1.25rem 0; padding: 1rem 1.1rem; border-radius: 16px;
  background: #fff; border: 1px solid var(--hm-border, #e3e6ea); box-shadow: 0 4px 16px rgba(0,0,0,.06); color: #1a1a1a; }
.hm-app[hidden], .hm-app [hidden] { display: none; }
.hm-app__icon { flex: none; width: 56px; height: 56px; border-radius: 14px; }
.hm-app__text { flex: 1; display: flex; flex-direction: column; gap: .2rem; line-height: 1.35; font-size: .95rem; }
.hm-app__text strong { font-size: 1.08rem; }
.hm-app__go { flex: none; white-space: nowrap; }
.hm-app--band { margin: 0; border-radius: 0; border: 0; border-top: 1px solid var(--hm-border, #e3e6ea); box-shadow: none;
  justify-content: center; padding: 1.1rem max(1rem, calc((100% - 1140px) / 2)); background: var(--hm-surface, #f3f6f4); }
.hm-app--band .hm-app__text { flex: 0 1 640px; }
@media (max-width: 599px) {
  .hm-app { flex-wrap: wrap; }
  .hm-app__text { flex-basis: calc(100% - 72px); }
  .hm-app__go { width: 100%; }
}

/* ── Credito nel piè di pagina: marchio HouseMatch come da brand kit (simbolo ufficiale, wordmark Space Grotesk) ── */
@font-face { font-family: 'HM Space Grotesk'; font-weight: 500; font-display: swap; src: url('fonts/space-grotesk-latin-500.woff2') format('woff2'); }
@font-face { font-family: 'HM Space Grotesk'; font-weight: 700; font-display: swap; src: url('fonts/space-grotesk-latin-700.woff2') format('woff2'); }
.hm-credit { display: inline; }
.hm-credit a { color: inherit; text-decoration: none; }
.hm-credit a:hover, .hm-credit a:focus-visible { text-decoration: underline; }
.hm-credit__hm { display: inline-flex; align-items: center; gap: .4rem; vertical-align: middle; white-space: nowrap; }
.hm-credit__hm img { width: 26px; height: auto; padding: 3px; box-sizing: content-box; }
.hm-credit__word { font-family: 'HM Space Grotesk', sans-serif; letter-spacing: -0.02em; font-size: 1.05em; }
.hm-credit__word b { font-weight: 500; color: #fff; }
.hm-credit__word i { font-style: normal; font-weight: 700; color: #7FA8FF; }
.hm-app__hint { font-weight: 600; color: var(--hm-accent, #1f7a3f); }
.hm-app__icon { border-radius: 14px !important; }
