/* ==========================================================================
   BimmerManiacs — Cabeçalho comum a todas as páginas
   --------------------------------------------------------------------------
   Garante que o logótipo, o menu e os ícones ficam exatamente no mesmo sítio
   e com o mesmo tamanho em todas as páginas (referência: Comunidade).
   Tem de ser carregado DEPOIS dos estilos da página (último <link> do <head>).
   ========================================================================== */

/* Logótipo */
header .brand-logo { display: flex !important; align-items: center !important; gap: 10px !important; text-decoration: none !important; flex-shrink: 0; }
header .brand-stripes { display: flex !important; gap: 2.5px !important; transform: skewX(-20deg) !important; }
header .stripe { width: 5.5px !important; height: 22px !important; border-radius: 1px !important; }
header .stripe.blue { background: #0066b2 !important; }
header .stripe.dark { background: #151f6d !important; }
header .stripe.red  { background: #ce1226 !important; }
header .brand-text {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
  font-size: 22px !important; font-weight: 900 !important; letter-spacing: 2px !important;
  text-transform: uppercase !important; color: #fff !important; line-height: 1.5 !important; font-style: normal !important;
}
header .brand-text span { color: #0066b2 !important; font: inherit !important; letter-spacing: inherit !important; }

/* Menu */
header nav a {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
  font-size: 14px !important; font-weight: 600 !important; letter-spacing: 0 !important; text-transform: none !important;
}

@media (min-width: 768px) {
  header .header-container {
    max-width: 1480px !important; width: 100% !important; margin: 0 auto !important;
    padding: 0 40px !important; min-height: 75px !important; box-sizing: border-box !important;
    display: flex !important; flex-direction: row !important; align-items: center !important;
    justify-content: space-between !important; gap: 20px !important; position: relative !important;
  }
  header nav { display: flex !important; align-items: center !important; gap: 20px !important; margin: 0 !important; }
  header .header-right { margin-top: 0 !important; display: flex; align-items: center; gap: 10px !important; }
}

/* Páginas de membros (com ícones à direita): em ecrãs largos o menu fica sempre
   ao centro exato, seja qual for a largura do logótipo ou dos botões da direita.
   Páginas públicas (sem sessão: Início, Login, Registo): o menu fica à direita. */
@media (min-width: 1200px) {
  html.bm-logado header .header-container:has(.header-right) nav { position: absolute !important; left: 50% !important; transform: translateX(-50%) !important; }
}

/* Menu dos membros: no PC largo Comunidade · Artigos · Sobre · Contacto (bimmer-appbar.js);
   abaixo de 1280px fica Início · Artigos · Eventos · Marketplace */
header nav .bm-nav-pc { display: none !important; }
@media (min-width: 1280px) {
  header nav .bm-nav-mob { display: none !important; }
  header nav a.bm-nav-pc { display: inline-flex !important; }
  header nav span.bm-nav-pc { display: inline !important; }
  /* ordem no PC largo: Comunidade · Fórum · Marketplace · Artigos */
  header nav a.bm-nav-art { order: 9; }
}

/* Menu da comunidade à esquerda nas outras páginas da comunidade (bimmer-appbar.js) — só PC largo */
.bm-menu { display: none; }
@media (min-width: 1280px) {
  html.bm-logado body.com-menu { padding-left: var(--bm-pad-l, 284px) !important; padding-right: var(--bm-pad-r, 24px) !important; }
  html.bm-logado .bm-menu {
    display: block; position: fixed; top: 100px; left: var(--bm-menu-l, 20px); bottom: 16px; width: 260px; z-index: 50; overflow-y: auto; scrollbar-width: none;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  }
  .bm-menu::-webkit-scrollbar { display: none; }
  .bm-menu-eu { display: flex; align-items: center; gap: 12px; padding: 6px 8px; margin-bottom: 8px; border-radius: 8px; text-decoration: none !important; color: #fff !important; }
  .bm-menu-eu:hover, .bm-menu-eu.on { background: rgba(255,255,255,0.06); }
  .bm-menu-eu img { width: 38px; height: 38px; border-radius: 50%; object-fit: cover; flex-shrink: 0; border: 2px solid rgba(30,144,255,0.6); }
  .bm-menu-eu span { min-width: 0; display: flex; flex-direction: column; }
  .bm-menu-eu b { font-size: 14px; font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .bm-menu-eu small { font-size: 12px; color: #8b949e; }
  .bm-menu-grupo { display: flex; flex-direction: column; align-items: stretch; gap: 1px; margin: 0; padding: 0; }
  .bm-menu .bm-menu-item { position: relative; display: flex !important; align-items: center; justify-content: flex-start !important; gap: 12px; width: 100%; box-sizing: border-box; min-height: 44px; margin: 0 !important; padding: 6px 8px !important; border-radius: 6px; border: 0 !important; background: none; text-align: left !important; text-decoration: none !important; text-transform: none !important; letter-spacing: 0 !important; line-height: 1.3 !important; color: #d5d8de; font-size: 14px !important; font-weight: 700 !important; }
  .bm-menu-item:hover { background: rgba(255,255,255,0.05); color: #fff; }
  .bm-menu-item .ic { width: 34px; height: 34px; border-radius: 9px; display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; color: var(--c); background: color-mix(in srgb, var(--c) 16%, transparent); }
  .bm-menu-item .ic svg { width: 18px; height: 18px; }
  .bm-menu-item.on { background: rgba(255,255,255,0.07); color: #fff; }
  .bm-menu-item.on .ic { background: var(--c); color: #fff; }
  .bm-menu-item.on::before { content: ""; position: absolute; left: -6px; top: 8px; bottom: 8px; width: 3px; border-radius: 2px; background: var(--c); }
  .bm-menu-item .tx { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .bm-menu-tit { margin: 14px 0 4px; padding: 0 10px; font-size: 11px; font-weight: 800; letter-spacing: 1.6px; text-transform: uppercase; color: #8b949e; }
  .bm-menu .bm-menu-item.sec { min-height: 38px; padding: 6px 10px !important; font-size: 13.5px !important; font-weight: 600 !important; color: #b9bdc6; }
  .bm-menu-item.sec .ic { width: 22px; height: 22px; background: none; border-radius: 0; }
  .bm-seta { display: inline-flex; align-items: center; justify-content: center; width: 26px; height: 26px; margin-left: auto; flex-shrink: 0; border-radius: 6px; color: #8b949e; font-size: 18px; font-weight: 700; line-height: 1; transition: transform .2s, background .15s, color .15s; }
  .bm-seta:hover { background: rgba(255,255,255,0.08); color: #fff; }
  .bm-menu.g-feed .bm-seta[data-grupo="feed"], .bm-menu.g-oficina .bm-seta[data-grupo="oficina"] { transform: rotate(90deg); }
  .bm-menu:not(.g-feed) .bm-menu-filhos[data-g="feed"], .bm-menu:not(.g-oficina) .bm-menu-filhos[data-g="oficina"] { display: none; }
  .bm-ch { height: 16px; padding: 0 4px; border-radius: 3px; background: linear-gradient(135deg, #0066b2, #151f6d); color: #fff; font-style: italic; font-weight: 800; font-size: 10px; display: inline-flex; align-items: center; }
  .bm-menu-filhos { display: flex; flex-direction: column; gap: 1px; margin: 2px 0 6px 25px; padding-left: 8px; border-left: 1px solid rgba(255,255,255,0.09); }
  .bm-menu-filhos .bm-menu-item.on { background: rgba(255,255,255,0.07); color: #fff; }
  .bm-menu-filhos .bm-menu-item.on::before { left: -9px; }
  .bm-menu-filhos .bm-menu-item.on .ic { background: none; color: var(--c); }
  .bm-menu-sep { margin-top: 14px !important; padding-top: 14px !important; border-top: 1px solid rgba(255,255,255,0.07); }
  .bm-menu-tit.bm-menu-sep { margin-bottom: 8px; }
  .bm-menu-ativ { display: block; padding: 9px 10px; border-radius: 6px; text-decoration: none !important; color: #e1e3e8 !important; }
  .bm-menu-ativ:hover { background: rgba(255,255,255,0.05); }
  .bm-menu-ativ b { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; font-size: 13px; font-weight: 700; line-height: 1.35; }
  .bm-menu-ativ small { display: block; margin-top: 3px; font-size: 11.5px; color: #8b949e; }
  .bm-menu-ativ .nv { color: #4aa8ff; font-weight: 800; }
  .bm-menu-ativ.nova b::before { content: ""; display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: #1e90ff; margin-right: 6px; vertical-align: 2px; }
  .bm-menu-vazio a { color: #4aa8ff; font-weight: 700; text-decoration: none; }
  .bm-menu-ajuda { display: block; text-decoration: none !important; background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.06); border-left: 3px solid #ffb74d; border-radius: 6px; padding: 10px 12px; margin-bottom: 6px; color: #fff !important; }
  .bm-menu-ajuda:hover { background: rgba(255,255,255,0.06); }
  .bm-menu-ajuda b { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; font-size: 13px; font-weight: 700; line-height: 1.35; margin-bottom: 5px; }
  .bm-menu-ajuda small { font-size: 11.5px; color: #8b949e; display: flex; align-items: center; gap: 6px; }
  .bm-menu-ajuda .ch { height: 18px; padding: 0 6px; border-radius: 4px; background: linear-gradient(135deg, #0066b2, #151f6d); color: #fff; font-style: italic; font-weight: 800; font-size: 11.5px; display: inline-flex; align-items: center; }
  .bm-menu-link { display: block; padding: 4px 10px; font-size: 12px; font-weight: 800; color: #1e90ff !important; text-decoration: none !important; }
  .bm-menu-link:hover { text-decoration: underline !important; }
  .bm-menu-vazio { margin: 4px 0; padding: 0 10px; font-size: 12.5px; color: #8b949e; }
  .bm-menu-fix { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 6px; color: #b9bdc6 !important; font-size: 13px; font-weight: 600; text-decoration: none !important; }
  .bm-menu-fix:hover { background: rgba(255,255,255,0.05); color: #fff !important; }
  .bm-menu-fix i { width: 10px; height: 10px; border-radius: 3px; margin: 0 4px; flex-shrink: 0; }
  .bm-menu-item .nv { display: inline-flex; align-items: center; justify-content: center; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: #1e90ff; color: #fff; font-size: 11px; font-weight: 800; }
}

/* Foto de perfil (canto direito) */
header .user-profile-avatar-btn {
  width: 40px !important; height: 40px !important; border-radius: 50% !important; padding: 2px !important;
  border: 2px solid #1e90ff !important; box-sizing: border-box !important; overflow: hidden !important;
  display: flex !important; align-items: center !important; justify-content: center !important;
  background: rgba(255,255,255,0.05) !important; cursor: pointer; flex-shrink: 0;
}
header .user-profile-avatar-btn img { width: 100% !important; height: 100% !important; border-radius: 50% !important; object-fit: cover !important; }

/* Barra de baixo do telemóvel (Feed, Garagem, Chat, Perfil): só para membros */
html.bm-visitante .mobile-app-bar, html.bm-visitante .bm-appbar { display: none !important; }

/* ==========================================================================
   TELEMÓVEL (≤ 768px) — nada daqui se aplica ao PC
   ========================================================================== */
.bm-appbar { display: none; }
@media (max-width: 768px) {
  /* ---------- Barra de baixo (bimmer-appbar.js) ---------- */
  html.bm-logado .bm-appbar {
    display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 99999;
    height: calc(62px + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom);
    background: rgba(11, 13, 18, 0.88); backdrop-filter: blur(22px) saturate(170%); -webkit-backdrop-filter: blur(22px) saturate(170%);
    border-top: 1px solid rgba(255,255,255,0.08); box-shadow: 0 -10px 30px rgba(0,0,0,0.45);
  }
  .bm-appbar-item {
    position: relative; flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
    background: none; border: 0; padding: 0; margin: 0; cursor: pointer; color: #8b929e;
    font: 600 10.5px system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif; letter-spacing: .2px; -webkit-tap-highlight-color: transparent;
  }
  .bm-appbar-item svg { width: 24px; height: 24px; fill: currentColor; transition: transform .2s; }
  .bm-appbar-item:active svg { transform: scale(.9); }
  .bm-appbar-item.ativo { color: #1e90ff; }
  .bm-appbar-item.ativo::before { content: ""; position: absolute; top: 0; left: 30%; right: 30%; height: 3px; border-radius: 0 0 3px 3px;
    background: linear-gradient(90deg, #0066b2 0 33%, #151f6d 33% 66%, #ce1226 66%); }
  .bm-appbar-badge { position: absolute; top: 6px; left: calc(50% + 5px); min-width: 16px; height: 16px; padding: 0 4px; border-radius: 8px;
    background: #ce1226; color: #fff; font: 800 10px/16px system-ui, sans-serif; text-align: center; border: 2px solid #0b0d12; box-sizing: content-box; }
  .bm-appbar-badge[hidden] { display: none; }
  html.bm-logado.bm-com-appbar body { padding-bottom: calc(76px + env(safe-area-inset-bottom)) !important; }
  html.bm-com-appbar .mobile-app-bar { display: none !important; }
  /* o ecrã de mensagens fica por cima da barra */
  #bmMessenger { z-index: 100060; }

  /* ---------- Cabeçalho compacto: logótipo + ícones numa linha, menu por baixo ---------- */
  header .header-container {
    display: grid !important; grid-template-columns: minmax(0, 1fr) auto !important; grid-template-areas: "logo direita" "menu menu" !important;
    align-items: center !important; row-gap: 4px !important; column-gap: 10px !important;
    padding: 8px 14px 6px !important; min-height: 0 !important; width: 100% !important; max-width: 100% !important; box-sizing: border-box !important;
    flex-direction: unset !important;
  }
  header .brand-logo { grid-area: logo; justify-self: start !important; margin: 0 !important; }
  header .brand-text { font-size: 18px !important; letter-spacing: 1.5px !important; }
  header .stripe { height: 18px !important; width: 4.5px !important; }
  header nav { grid-area: menu; display: flex !important; justify-content: center !important; gap: 22px !important; margin: 0 !important;
    position: static !important; transform: none !important; flex-wrap: nowrap !important; overflow-x: auto; scrollbar-width: none; padding: 2px 0 4px !important; }
  header nav::-webkit-scrollbar { display: none; }
  header nav a { white-space: nowrap; font-size: 14px !important; padding: 4px 0 !important; }
  header .header-right { grid-area: direita; display: flex !important; align-items: center !important; gap: 8px !important; margin: 0 !important; justify-self: end; }
  html.bm-visitante header .header-container { grid-template-areas: "logo logo" "menu menu" !important; }
  html.bm-visitante header .brand-logo { justify-self: center !important; }
  html.bm-visitante header nav { flex-wrap: wrap !important; overflow: visible; gap: 6px 18px !important; }
  /* No telemóvel o chat abre-se na barra de baixo: o botão de mensagens do topo sai; o sino fica */
  html.bm-com-appbar header .header-messages-wrapper { display: none !important; }
  html.bm-logado header #notifWrapper { display: block !important; }
  header .user-profile-avatar-btn { width: 36px !important; height: 36px !important; }
}

/* ---------- Ícones do cabeçalho (Mensagens + Notificações) ---------- */
.header-chat-trigger, .icon-btn[onclick*="toggleNotificationPopup"] {
  width: 40px !important; height: 40px !important; border-radius: 50% !important; margin-left: 0 !important;
  background: #1d212b !important; border: 0 !important; box-shadow: none !important;
  color: #fff !important; display: flex; align-items: center; justify-content: center; position: relative; cursor: pointer;
  transform: none !important; transition: background 0.2s !important;
}
.header-chat-trigger:hover, .icon-btn[onclick*="toggleNotificationPopup"]:hover { background: #2b303c !important; }
.header-chat-trigger svg.hdr-ico, .icon-btn svg.hdr-ico {
  width: 20px !important; height: 20px !important; fill: currentColor !important; stroke: none !important; transition: none !important;
}
@media (max-width: 768px) {
  .header-chat-trigger, .icon-btn[onclick*="toggleNotificationPopup"] { width: 36px !important; height: 36px !important; }
}

/* ---------- Páginas abertas a todos (Notícias, Marketplace) ----------
   Têm os dois menus no HTML; a classe posta no <html> pelo bimmer-guard.js
   (antes de a página aparecer) decide qual se vê. Sem saltos ao carregar. */
html.bm-visitante header nav.so-membros,
html.bm-logado header nav.so-visitantes { display: none !important; }
html.bm-visitante header .header-right { display: none !important; }
html.bm-logado header #headerRightArea { display: flex !important; }
/* Botão "Registo / Login" igual em todas as páginas públicas */
header nav .nav-btn {
  background: #1e90ff !important; color: #fff !important; padding: 6px 14px !important; border-radius: 6px !important;
  font-size: 13px !important; font-weight: 700 !important; line-height: 1.5 !important; text-decoration: none !important;
  display: inline-flex !important; align-items: center !important; justify-content: center !important; border: none !important;
}
header nav .nav-btn:hover { background: #63a4ff !important; color: #fff !important; }

/* ==========================================================================
   LISTA / BARRA DE AMIGOS (componente amigos.js) — comum a todas as páginas
   ========================================================================== */
.rail-friend { display: flex; align-items: center; gap: 10px; width: 100%; padding: 7px 10px; border-radius: 8px; background: transparent; border: none; cursor: pointer; text-align: left; font-family: inherit; transition: background 0.2s; }
.rail-friend:hover { background: rgba(255,255,255,0.05); }
.rail-friend .av { position: relative; flex-shrink: 0; }
.rail-friend .av img { width: 34px; height: 34px; border-radius: 50%; object-fit: cover; }
.rail-friend .av i { position: absolute; right: -1px; bottom: -1px; width: 11px; height: 11px; border-radius: 50%; background: #4b5260; border: 2px solid #0b0d12; }
.rail-friend .av i.on { background: #00e676; }
.rail-friend .nm { min-width: 0; }
.rail-friend .nm b { display: block; color: #e6edf3; font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rail-friend .nm small { display: block; color: #9a9ea8; font-size: 11px; }
.rail-friend .nm small.on { color: #00e676; }
.rail-empty { font-size: 12px; color: #9a9ea8; padding: 4px 10px 8px; line-height: 1.5; }
.rail-empty a { color: #1e90ff; }
.friends-widget .widget-title small { font-size: 11px; color: #00e676; font-weight: 700; }
.friends-list { max-height: 330px; overflow-y: auto; margin: 0 -8px; scrollbar-width: thin; }
.friends-widget .rail-friend { padding: 7px 8px; }
.friends-foot { display: flex; gap: 8px; margin-top: 10px; padding-top: 10px; border-top: 1px solid rgba(255,255,255,0.06); }
.friends-foot a, .friends-foot button { flex: 1; text-align: center; text-decoration: none; }
.friends-search input { width: 100%; background: rgba(0,0,0,0.35); border: 1px solid rgba(255,255,255,0.1); border-radius: 8px; padding: 8px 12px; color: #fff; font-size: 12.5px; outline: none; margin-bottom: 8px; }
.friends-search input:focus { border-color: #1e90ff; }
.friends-sec { font-size: 10px; font-weight: 800; letter-spacing: 1.4px; text-transform: uppercase; color: #9a9ea8; padding: 10px 8px 4px; }
.amigos-barra { display: none; }
@media (min-width: 1400px) {
  html.bm-logado:not(.bm-amigos-recolhida) body.com-barra-amigos { padding-right: 274px; }
  html.bm-logado:not(.bm-amigos-recolhida) body.com-barra-amigos header { right: 250px !important; left: 0 !important; width: auto !important; }
  /* cabeçalho igual em todas as páginas com barra: logótipo à esquerda, ícones encostados à barra */
  html.bm-logado:not(.bm-amigos-recolhida) body.com-barra-amigos header .header-container {
    max-width: none !important; width: calc(min(1480px, 100% - 64px) + 80px) !important;
    margin: 0 -16px 0 auto !important;
  }
  html.bm-logado:not(.bm-amigos-recolhida) body.com-barra-amigos #bmChatDock { right: 266px; }
  html.bm-logado .amigos-barra {
    transition: transform .25s ease;
    display: flex; flex-direction: column; position: fixed; top: 0; right: 0; bottom: 0; width: 250px; z-index: 101;
    background: #0b0d12; border-left: 1px solid rgba(255,255,255,0.06);
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  }
  .amigos-barra .friends-widget {
    flex: 1; min-height: 0; display: flex; flex-direction: column; margin: 0 !important; padding: 0 !important;
    background: none !important; border: 0 !important; border-radius: 0 !important; box-shadow: none !important;
  }
  .amigos-barra .friends-widget .widget-title {
    height: 76px; flex-shrink: 0; margin: 0 !important; padding: 0 18px; box-sizing: border-box; background: #000;
    border-bottom: 1px solid #111; display: flex; align-items: center; justify-content: space-between;
    font-size: 11px; font-weight: 800; letter-spacing: 1.6px; text-transform: uppercase; color: #9a9ea8;
  }
  .amigos-barra .friends-widget .widget-title small { font-size: 11px; color: #00e676; font-weight: 700; letter-spacing: 0.4px; text-transform: none; }
  .amigos-barra .friends-search { padding: 14px 12px 4px; }
  .amigos-barra .friends-search input { box-sizing: border-box; margin-bottom: 4px; }
  .amigos-barra .friends-list { flex: 1; min-height: 0; max-height: none !important; overflow-y: auto; margin: 0 !important; padding: 0 6px 10px; }
  .amigos-barra .friends-foot { flex-shrink: 0; margin: 0; padding: 10px 12px; border-top: 1px solid rgba(255,255,255,0.06); display: flex; gap: 8px; }
  .amigos-barra .friends-foot .btn-secondary { flex: 1; text-align: center; text-decoration: none; background: none; border: 0; color: #9a9ea8; font: 700 12px system-ui, sans-serif; padding: 6px; cursor: pointer; }
  .amigos-barra .friends-foot .btn-secondary:hover { color: #fff; }
}

/* ==========================================================================
   Imagens dos cartões de artigos: quando a fotografia tem uma proporção muito
   diferente do cartão (panorâmica ou ao alto), aparece inteira, com um fundo
   desfocado dela própria (news-firebase.js → ajustarImagens)
   ========================================================================== */
.img-encaixe { position: relative; overflow: hidden; background: #000 var(--img-fundo) center / cover no-repeat; }
.img-encaixe::before { content: ""; position: absolute; inset: -20px; background: inherit; filter: blur(22px) brightness(.55); z-index: 0; }
.img-encaixe > img { position: relative; z-index: 1; object-fit: contain !important; transform: none !important; }

/* Recolher / mostrar a barra de amigos (só em ecrãs largos) */
.amigos-toggle { display: none; }
@media (min-width: 1400px) {
  html.bm-logado .amigos-toggle {
    display: flex; align-items: center; justify-content: center; gap: 6px;
    position: fixed; top: 92px; right: 250px; z-index: 102; height: 34px; padding: 0 10px 0 8px;
    background: #0b0d12; color: #9a9ea8; border: 1px solid rgba(255,255,255,0.08); border-right: 0;
    border-radius: 8px 0 0 8px; cursor: pointer; font: 700 12px system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
    transition: right .25s ease, color .2s, background .2s;
  }
  html.bm-logado .amigos-toggle:hover { color: #fff; background: #151922; }
  html.bm-logado .amigos-toggle svg { width: 16px; height: 16px; fill: currentColor; }
  html.bm-logado .amigos-toggle .seta { font-size: 15px; line-height: 1; }
  html.bm-logado .amigos-toggle .txt, html.bm-logado .amigos-toggle .cnt, html.bm-logado .amigos-toggle svg { display: none; }
  /* aberta: só uma seta estreita, cabe no espaço entre o conteúdo e a barra */
  html.bm-logado:not(.bm-amigos-recolhida) .amigos-toggle { width: 22px; padding: 0; }
  html.bm-logado.bm-amigos-recolhida .amigos-toggle svg { display: block; }
  html.bm-logado.bm-amigos-recolhida .amigos-barra { transform: translateX(100%); }
  /* barra recolhida: o cabeçalho aproveita o espaço que a barra libertou (cresce, não encolhe) */
  html.bm-logado.bm-amigos-recolhida body.com-barra-amigos header .header-container {
    max-width: none !important; width: calc(min(1730px, 100% - 80px) + 80px) !important; margin: 0 auto !important;
  }
  html.bm-logado.bm-amigos-recolhida .amigos-toggle { right: 0; }
  html.bm-logado.bm-amigos-recolhida .amigos-toggle .txt { display: inline; }
  html.bm-logado.bm-amigos-recolhida .amigos-toggle .cnt:not(:empty) { display: inline; color: #00e676; }
}
