/* Humidibee Login FX — scoped effects. Existing login layout stays yours. */
.hb-login-fx { position: relative; }
.hb-login-fx .hb-login-panel { position: relative; isolation: isolate; }
.hb-login-fx .hb-login-panel::before,
.hb-login-fx .hb-login-panel::after { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; z-index: 50; opacity: 0; }
.hb-login-fx .hb-login-panel::before {
  background:
    radial-gradient(ellipse at 6% 16%, rgba(255,255,255,.96), transparent 38%),
    radial-gradient(ellipse at 90% 78%, rgba(210,244,255,.93), transparent 42%),
    repeating-linear-gradient(125deg, transparent 0 14px, rgba(255,255,255,.21) 15px 17px, transparent 18px 28px),
    linear-gradient(160deg, rgba(151,224,249,.66), rgba(212,245,255,.77) 53%, rgba(102,184,229,.72));
  transform-origin: center top;
  transform: scaleY(.02);
  mix-blend-mode: screen;
}
.hb-login-fx .hb-login-panel::after {
  box-shadow: inset 0 0 11px 4px rgba(244,254,255,.9), inset 0 0 41px 14px rgba(65,161,219,.55), inset 0 0 90px rgba(229,253,255,.5);
  border: 2px solid rgba(238,253,255,.94);
}
.hb-login-fx .hb-login-panel.hb-is-freezing::before,
.hb-login-fx .hb-login-panel.hb-is-cracking::before { opacity: 1; transform: scaleY(1); transition: transform .61s cubic-bezier(.11,.82,.16,1), opacity .1s; }
.hb-login-fx .hb-login-panel.hb-is-freezing::after,
.hb-login-fx .hb-login-panel.hb-is-cracking::after { opacity: 1; transition: opacity .25s; }
.hb-login-fx .hb-login-panel.hb-is-freezing { animation: hb-freeze-shiver .63s ease-in-out both; }
.hb-login-fx .hb-login-panel.hb-is-cracking { animation: hb-snap .26s ease-in-out both; }
.hb-login-fx .hb-login-panel.hb-is-frozen-static::before { opacity: 1; transform: scaleY(1); }
.hb-login-fx .hb-login-panel.hb-is-frozen-static::after { opacity: 1; }
.hb-login-fx .hb-login-panel.hb-is-vanished { visibility: hidden !important; }
.hb-login-fx .hb-login-panel.hb-is-returning { animation: hb-reappear .58s cubic-bezier(.18,.9,.31,1.2) both; }
.hb-crack-overlay { position:absolute; inset:0; z-index:52; pointer-events:none; opacity:0; overflow:hidden; border-radius:inherit; }
.hb-crack-overlay svg { display:block; width:100%; height:100%; filter: drop-shadow(0 0 2px #fff) drop-shadow(0 0 4px #f8ffff); }
.hb-crack-overlay path { stroke:rgba(30,119,168,.97); stroke-width:1.35; fill:none; stroke-linecap:round; stroke-linejoin:round; vector-effect:non-scaling-stroke; }
.hb-login-fx .hb-login-panel.hb-is-cracking .hb-crack-overlay { animation: hb-crack-flash .28s ease-out both; }
.hb-login-fx .hb-login-panel.hb-is-frozen-static .hb-crack-overlay { opacity:1; }
.hb-shatter-stage { position:fixed; margin:0; padding:0; overflow:visible; pointer-events:none; z-index:99999; }
.hb-ice-shard { position:absolute; overflow:hidden; transform-origin:center center; will-change:transform,opacity; animation: hb-shard-fall var(--hb-duration, 900ms) cubic-bezier(.14,.52,.37,1) var(--hb-delay,0ms) both; filter:drop-shadow(0 3px 3px rgba(26,89,123,.3)); }
.hb-ice-shard > .hb-login-panel { position:absolute !important; margin:0 !important; max-width:none !important; min-width:0 !important; box-sizing:border-box !important; pointer-events:none !important; animation:none !important; transform:none !important; }
@keyframes hb-freeze-shiver { 0%,20%,44%,67%,100%{transform:translateX(0)} 13%,56%{transform:translateX(-2px)} 30%,75%{transform:translateX(2px)} }
@keyframes hb-snap { 0%,100%{transform:translateX(0)} 20%,60%{transform:translateX(-6px)} 40%,80%{transform:translateX(5px)} }
@keyframes hb-crack-flash { from{opacity:0;transform:scale(1.02)} 35%{opacity:1} to{opacity:1;transform:scale(1)} }
@keyframes hb-shard-fall { 0%{opacity:1;transform:translate3d(0,0,0) rotate(0) scale(1)} 22%{opacity:1} 100%{opacity:0;transform:translate3d(var(--hb-x),var(--hb-y),0) rotate(var(--hb-angle)) scale(.66)} }
@keyframes hb-reappear { 0%{opacity:0;transform:translateY(-26px) scale(.88)} 65%{opacity:1;transform:translateY(6px) scale(1.02)} 100%{opacity:1;transform:translateY(0) scale(1)} }
/* The message remains clear even with JavaScript disabled. */
.hb-login-fx [data-hb-error][hidden],
.hb-login-fx [data-hb-intro][hidden] { display:none !important; }
@media (prefers-reduced-motion:reduce) {
 .hb-login-fx .hb-login-panel, .hb-login-fx .hb-login-panel::before, .hb-login-fx .hb-login-panel::after,
 .hb-login-fx .hb-login-panel.hb-is-returning { animation:none !important; transition:none !important; }
 .hb-shatter-stage { display:none !important; }
}

/* Login-only comedy messages; no changes to the shared Humidibee styles. */
.hb-login-fx .hb-login-warning,
.hb-login-fx .hb-login-error-fx {
  border-radius: 12px;
  padding: 15px 17px;
  margin: 18px 0;
  line-height: 1.5;
}
.hb-login-fx .hb-login-warning {
  border: 1px solid #c6d7e8;
  background: #eff7ff;
  color: #21445d;
}
.hb-login-fx .hb-login-error-fx {
  border: 1px solid #c8d9e8;
  background: #ecf7fe;
  color: #19445d;
}
.hb-login-fx .hb-login-warning strong,
.hb-login-fx .hb-login-error-fx strong {display:block; font-size: .94rem; letter-spacing: .02em;}
.hb-login-fx .hb-login-warning p,
.hb-login-fx .hb-login-error-fx p {margin: 9px 0; color: inherit; line-height: 1.45;}
.hb-login-fx .hb-login-warning small,
.hb-login-fx .hb-login-error-fx small {display: block; font-size: .79rem; opacity: .79;}
.hb-login-fx .hb-auth-error[data-hb-credential-error][hidden] {display:none !important;}

/* Login-card footprint only (v4). Restore every font size to the site's
   normal typography; do not scale the logo, header, page text or links.
   Registration uses the unchanged shared accounts.css rules. */
.hb-login-fx.hb-auth {
  min-height: 0;
  padding: 14px 20px 16px;
}
.hb-login-fx .hb-login-panel {
  width: min(100%, 460px);
  padding: clamp(19px, 3vw, 27px);
  border-radius: 20px;
}
.hb-login-fx .hb-login-panel h1 {
  margin: 8px 0 9px;
}
.hb-login-fx .hb-login-panel > .eyebrow + h1 + p {
  margin-bottom: 8px;
  line-height: 1.5;
}
.hb-login-fx .hb-login-warning,
.hb-login-fx .hb-login-error-fx {
  padding: 11px 13px;
  margin: 10px 0;
  line-height: 1.4;
}
.hb-login-fx .hb-login-warning p,
.hb-login-fx .hb-login-error-fx p {
  margin: 5px 0;
  line-height: 1.4;
}
.hb-login-fx .hb-login-panel form {
  gap: 10px;
  margin: 10px 0;
}
.hb-login-fx .hb-login-panel label {
  gap: 5px;
}
.hb-login-fx .hb-login-panel input:not([type=hidden]):not([type=checkbox]) {
  padding-top: 10px;
  padding-bottom: 10px;
}
.hb-login-fx .hb-login-panel .button {
  padding-top: 11px;
  padding-bottom: 11px;
}
.hb-login-fx .hb-login-panel .hb-auth-toggle {
  margin-bottom: 7px;
}
.hb-login-fx .hb-login-panel .hb-auth-note {
  margin-top: 7px;
  margin-bottom: 0;
}
@media (max-width: 550px) {
  .hb-login-fx .hb-login-panel { padding: 18px; }
}

/* v5: Login page only — place the footer at the viewport bottom when content
   is short. On tall content and small phones, let it flow naturally below the
   page (never position:fixed, never cover the form). */
@supports selector(body:has(.hb-login-fx)) {
  body:has(> main > .hb-login-fx) {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    min-height: 100dvh;
  }
  body:has(> main > .hb-login-fx) > .site-header,
  body:has(> main > .hb-login-fx) > .footer { flex: 0 0 auto; }
  body:has(> main > .hb-login-fx) > main {
    display: flex;
    flex: 1 0 auto;
    flex-direction: column;
  }
  body:has(> main > .hb-login-fx) > main > .hb-login-fx {
    flex: 1 0 auto;
    width: 100%;
  }
}
