/* Easy-Unlocker shared interface pieces.
   These belong to both themes - the theme switch, the support corner, the
   phone drawer, the in-page QR - so they live here and are always loaded.
   The light-mode colour layer is the separate eu-light.css, which is only
   fetched for people actually in light mode. */

/* Easy-Unlocker light mode.
   Dark stays the default; this layer only applies under .eu-light on <html>.
   Derived rule-for-rule from the dark rules (eu-custom.css plus the inline
   blocks the theme prints on the page), so every surface the dark theme
   paints has a light counterpart. Its own file, its own URL: a cached
   eu-custom.css cannot hold it back. */

/* ---------- the switch: a floating button that shares the corner with the
     scroll-to-top control, so it is reachable on a phone as well ---------- */
.eu-theme-fab{position:fixed;bottom:20px;left:20px;z-index:49;
  width:48px!important;height:48px!important;min-height:0!important;box-sizing:border-box;
  padding:0!important;border:0;border-radius:50%!important;
  display:flex;align-items:center;justify-content:center;line-height:0;
  background:linear-gradient(135deg,#19c8f5,#0090c0);color:#04121a;cursor:pointer;
  box-shadow:0 12px 28px -12px rgba(0,0,0,.95);-webkit-appearance:none;appearance:none;
  transition:opacity .3s ease,visibility .3s ease,transform .2s ease,background .2s ease}

.eu-theme-fab:hover{transform:translateY(-3px);
  background:linear-gradient(135deg,#fac90e,#e0a800)}

.eu-theme-fab:focus{outline:0}

.eu-theme-fab:focus-visible{outline:2px solid #fac90e;outline-offset:3px}

.eu-theme-fab svg{width:22px;height:22px;display:block}

.eu-theme-fab .eu-ic-moon{display:none}

.eu-theme-fab.eu-fab-hide{opacity:0;visibility:hidden;pointer-events:none}



/* ---------- the support corner ---------- *
 * Scoped under .eu-support so the generic class names inside it cannot collide
 * with the theme's own .items / .trigger. Not theme-scoped: it looks the same
 * in both modes apart from the depth of its shadows. */
.eu-support{position:fixed;right:20px;bottom:20px;z-index:49;
  width:56px;height:56px;display:block}

.eu-support.eu-support-raised{bottom:96px}

.eu-support .items{position:absolute;right:0;bottom:68px;
  display:flex;flex-direction:column;align-items:center;gap:12px;
  opacity:0;visibility:hidden;pointer-events:none;transform:translateY(12px) scale(.92);
  transition:opacity .22s ease,transform .22s ease,visibility .22s ease}

.eu-support:hover .items,
.eu-support:focus-within .items,
.eu-support.open .items{opacity:1;visibility:visible;pointer-events:auto;transform:none}

.eu-support .items a{width:52px;height:52px;border-radius:50%;flex:none;
  display:flex;align-items:center;justify-content:center;color:#fff!important;
  text-decoration:none!important;box-shadow:0 12px 26px -12px rgba(0,0,0,.85);
  transition:transform .18s ease,filter .18s ease}

.eu-support .items a:hover{transform:translateY(-3px);filter:brightness(1.07);color:#fff!important}

.eu-support .items a svg{width:26px;height:26px;display:block}

.eu-support .items .wa{background:#25d366}

.eu-support .items .tg{background:#229ed9}

.eu-support .trigger{width:56px!important;height:56px!important;min-height:0!important;
  box-sizing:border-box;flex:none;padding:0!important;border:0;border-radius:50%!important;
  display:flex;align-items:center;justify-content:center;cursor:pointer;line-height:0;
  color:#111823;background:linear-gradient(135deg,#fac90e,#e0a800);
  -webkit-appearance:none;appearance:none;
  box-shadow:0 14px 30px -12px rgba(0,0,0,.85);transition:transform .2s ease,filter .18s ease}

.eu-support:hover .trigger,.eu-support.open .trigger{transform:scale(1.06)}

.eu-support .trigger:focus{outline:0}

.eu-support .trigger:focus-visible{outline:2px solid #19c8f5;outline-offset:3px}

.eu-support .trigger svg{width:26px;height:26px;display:block}
@media (max-width:575px){
  .eu-support{right:14px;bottom:14px}
  .eu-support{width:52px;height:52px}
  .eu-support .trigger{width:52px!important;height:52px!important}
  .eu-support .items a{width:48px;height:48px}}
@media (max-width: 991.98px) {
  .modal-menu { padding: 0 !important; }

  .modal-menu .modal-dialog {
    position: fixed; top: 0; left: 0; bottom: 0;
    margin: 0 !important; width: min(340px, 86vw); max-width: none !important;
    height: 100%; height: 100dvh; pointer-events: auto;
    transform: translateX(-102%);
    transition: transform .32s cubic-bezier(.22, .9, .28, 1);
  }
  .modal-menu.show .modal-dialog { transform: none; }

  .modal-menu .modal-content {
    height: 100%; border: 0 !important; border-radius: 0 !important;
    box-shadow: 26px 0 70px -34px rgba(0, 0, 0, .95) !important;
    display: flex; flex-direction: column; overflow: hidden;
  }

  /* the top of the drawer stays put while the list scrolls under it */
  .modal-menu .modal-header {
    flex: none; position: sticky; top: 0; z-index: 3;
    padding: 14px 16px !important;
    border-bottom: 1px solid rgba(255, 255, 255, .07) !important;
  }
  .modal-menu .modal-body {
    flex: 1 1 auto; overflow-y: auto; -webkit-overflow-scrolling: touch;
    padding: 12px 12px 28px !important;
  }
  .modal-menu .modal-footer { flex: none; }

  /* rows read as one list, with room to be tapped */
  .modal-menu .nav-link,
  .modal-menu .dropdown-item {
    border-radius: 10px; padding: 13px 14px !important;
    font-size: 14.5px; line-height: 1.35; min-height: 46px;
    display: flex !important; align-items: center; gap: 11px;
  }
  .modal-menu .nav-item + .nav-item > .nav-link { margin-top: 2px; }
  .modal-menu .dropdown-menu {
    position: static !important; float: none !important; width: 100% !important;
    transform: none !important; margin: 2px 0 6px !important;
    border: 0 !important; box-shadow: none !important; background: transparent !important;
    padding: 0 0 0 10px !important;
  }
  .modal-menu .dropdown-header {
    font-family: ui-monospace, Consolas, monospace; font-size: 10.5px;
    letter-spacing: .16em; text-transform: uppercase; padding: 14px 14px 6px !important;
  }
  .modal-menu .dropdown-divider { margin: 8px 6px !important; }

  /* the chevron points where the row goes */
  .modal-menu .nav-link .fa-chevron-down,
  .modal-menu .dropdown-item .fa-chevron-down { margin-left: auto; opacity: .6; }

  .modal-backdrop.show { opacity: .55 !important; }}


/* the gap between the trigger and the icons would drop the hover, so it is
   bridged by an invisible strip that belongs to the menu */
.eu-support .items::after{content:"";position:absolute;left:-6px;right:-6px;
  bottom:-18px;height:20px;pointer-events:auto}

.eu-support.open .items,.eu-support:hover .items{pointer-events:auto}


/* the QR drawn in the page, and the fallback link when the encoder is blocked */
.eu-qr{display:flex;align-items:center;justify-content:center;padding:10px;
  background:#ffffff;border-radius:12px}

.eu-qr svg{display:block;width:220px;height:220px}

.eu-qr-link{display:inline-flex;align-items:center;justify-content:center;
  min-height:46px;padding:0 20px;border-radius:11px;font-weight:700;
  background:linear-gradient(135deg,#fac90e,#e0a800);color:#241a00!important;
  text-decoration:none!important}
