/* Edeal Homes: existing blue, Roboto stack and 9px corners. No remote assets. */
#ehmb-bar,
#ehmb-bar *,
#ehmb-spacer { box-sizing: border-box; }

#ehmb-bar,
#ehmb-spacer { display: none; }
#ehmb-bar[hidden],
#ehmb-spacer[hidden] { display: none !important; }

@media (max-width: 767px) {
  #ehmb-bar {
    --ehmb-accent: #0878be;
    --ehmb-on-accent: #ffffff;
    position: fixed;
    z-index: 9990;
    inset: auto 12px var(--ehmb-dock-offset, calc(12px + env(safe-area-inset-bottom, 0px)));
    display: block;
    width: calc(100% - 24px);
    max-width: 600px;
    margin: 0 auto;
    padding: 8px;
    border: 1px solid #dfe7ed;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.97);
    box-shadow: 0 8px 24px rgba(29, 49, 66, 0.16);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    color: #273744;
    font-family: Roboto, Arial, sans-serif;
    font-size: 14px;
    line-height: 1.2;
    isolation: isolate;
  }
  #ehmb-bar .ehmb-inner {
    display: grid;
    grid-template-columns: minmax(0, 1.3fr) minmax(124px, 1fr);
    gap: 8px;
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
    padding: 0;
  }
  #ehmb-bar .ehmb-action {
    display: flex;
    min-width: 0;
    min-height: 48px;
    align-items: center;
    justify-content: center;
    gap: 7px;
    margin: 0;
    padding: 9px 10px;
    border: 1px solid transparent;
    border-radius: 9px;
    font: inherit;
    font-weight: 600;
    letter-spacing: 0;
    line-height: 1.2;
    text-align: center;
    text-decoration: none;
    text-transform: none;
    overflow-wrap: anywhere;
    -webkit-tap-highlight-color: transparent;
    transition: background-color 120ms ease, filter 120ms ease;
  }
  #ehmb-bar .ehmb-primary {
    color: var(--ehmb-on-accent);
    background: var(--ehmb-accent);
  }
  #ehmb-bar .ehmb-primary:hover { filter: brightness(0.94); }
  #ehmb-bar .ehmb-whatsapp {
    color: #176038;
    background: #f4faf6;
    border-color: #bcd6c7;
  }
  #ehmb-bar .ehmb-whatsapp:hover { background: #e8f3ec; }
  #ehmb-bar .ehmb-whatsapp span { white-space: nowrap; overflow-wrap: normal; }
  #ehmb-bar .ehmb-whatsapp svg { display: block; width: 20px; height: 20px; flex: 0 0 20px; }
  #ehmb-bar a:focus-visible { outline: 3px solid #163e63; outline-offset: 2px; }
  #ehmb-spacer {
    display: block;
    width: 100%;
    height: calc(var(--ehmb-bar-height, 66px) + var(--ehmb-dock-offset, calc(12px + env(safe-area-inset-bottom, 0px))) + 8px);
    flex: 0 0 auto;
    margin: 0;
    padding: 0;
    border: 0;
    pointer-events: none;
  }
  /* Trustindex is never moved or restyled: the floating bar docks above it. */
  body.ehmb-visible .ehmb-raised-consent {
    margin-bottom: calc(var(--ehmb-original-gap, 0px) + var(--ehmb-bar-height, 66px) + var(--ehmb-dock-offset, calc(12px + env(safe-area-inset-bottom, 0px))) + 8px) !important;
  }
  /* Transitional protection; does not deactivate Joinchat or affect desktop. */
  body.ehmb-mobile .joinchat { display: none !important; }
}

@media (prefers-reduced-motion: reduce) {
  #ehmb-bar .ehmb-action { transition: none; }
}

@media print {
  #ehmb-bar, #ehmb-spacer { display: none !important; }
  .ehmb-raised-consent { margin-bottom: var(--ehmb-original-gap, 0px) !important; }
}
