/* HandCalc — account control (site.js navRight): person icon + "Sign in" when signed out; avatar with a green
   "signed in" dot when signed in, opening the account menu (account, subscription, delete, sign out).
   Shared by the site header (#hc-nav-user, assets/site.css adds the header-only rules) and the calculator top bar
   (.hc-tool-acct, rules at the end). Site pages load this file BEFORE site.css, calculator pages after tool-overrides.css. */
.hc-acct-host .hc-acct-wrap { position: relative; display: inline-flex; }
.hc-acct-host .hc-acct { display: inline-flex !important; align-items: center; gap: 8px; height: 42px; padding: 0 14px 0 4px; margin: 0;
  border: 1px solid #cfe0f3; border-radius: 999px; background: #fff; color: #0f2f57; font: 600 13.5px/1 var(--font-ui);
  white-space: nowrap; text-decoration: none; cursor: pointer; box-shadow: 0 2px 8px rgba(16, 60, 110, .06);
  transition: border-color 150ms, background 150ms, box-shadow 150ms; }
.hc-acct-host .hc-acct:hover { border-color: #8dbaf0; background: #f5f9ff; color: #0b5fcf; box-shadow: 0 4px 14px rgba(16, 90, 190, .12); }
.hc-acct-host .hc-acct:focus-visible { outline: 3px solid rgba(13, 113, 237, .35); outline-offset: 2px; }
.hc-acct-host .hc-acct-in { padding-right: 10px; }
.hc-acct-host .hc-acct-out { border-color: #a9c9f0; }
.hc-acct-host .hc-acct-ico { width: 32px; height: 32px; border-radius: 50%; background: #e6f0fd; color: #0d6fe8; display: grid; place-items: center; flex: none; }
.hc-acct-host .hc-acct-ico svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.hc-acct-host .hc-acct-label { max-width: 140px; overflow: hidden; text-overflow: ellipsis; }
.hc-acct-host .hc-avatar { position: relative; width: 32px; height: 32px; border-radius: 50%; flex: none; display: grid; place-items: center;
  background: linear-gradient(145deg, #3a97f4, #0b63da); color: #fff; font: 700 13px/1 var(--font-ui); letter-spacing: 0; }
.hc-acct-host .hc-avatar-lg { width: 44px; height: 44px; font-size: 16px; }
.hc-acct-host .hc-dot { position: absolute; right: -1px; bottom: -1px; width: 11px; height: 11px; border-radius: 50%; background: #1fbf6a; border: 2px solid #fff; }
.hc-acct-host .hc-avatar-lg .hc-dot { width: 13px; height: 13px; }
.hc-acct-host .hc-acct-pro { padding: 3px 7px; border-radius: 6px; background: #fff1cf; color: #8a5a00; font: 800 10.5px/1.2 var(--font-ui); letter-spacing: .05em; }
.hc-acct-host .hc-acct-caret { width: 16px; height: 16px; flex: none; fill: none; stroke: #5d7ea5; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; transition: transform 150ms; }
.hc-acct-host .hc-acct[aria-expanded="true"] .hc-acct-caret { transform: rotate(180deg); }
.hc-acct-host .hc-acct-menu { position: absolute; top: calc(100% + 8px); right: 0; z-index: 120; width: 290px; max-width: calc(100vw - 24px);
  padding: 8px; background: #fff; border: 1px solid #dce7f3; border-radius: 14px; box-shadow: 0 18px 44px rgba(16, 43, 86, .18); color: #153a67; text-align: start; }
.hc-acct-host .hc-acct-menu[hidden] { display: none !important; }
html[dir="rtl"] .hc-acct-host .hc-acct-menu { right: auto; left: 0; }
.hc-acct-host .hc-acct-head { display: flex; align-items: center; gap: 12px; padding: 8px 8px 12px; }
.hc-acct-host .hc-acct-who { min-width: 0; }
.hc-acct-host .hc-acct-name { font: 700 14.5px/1.25 var(--font-ui); color: #0b2850; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hc-acct-host .hc-acct-email { font-size: 12px; line-height: 1.35; color: #6580a2; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hc-acct-host .hc-acct-state { display: flex; align-items: center; gap: 6px; margin-top: 5px; color: #12804a; font-size: 12px; font-weight: 600; }
.hc-acct-host .hc-acct-state .hc-dot { position: static; width: 9px; height: 9px; border: 0; box-shadow: 0 0 0 3px rgba(31, 191, 106, .18); }
.hc-acct-host .hc-acct-plan { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 0 2px 6px; padding: 9px 10px;
  border-radius: 10px; background: #f3f7fc; color: #486889; font-size: 12.5px; font-weight: 600; }
.hc-acct-host .hc-acct-free { color: #0b2850; font-weight: 700; }
.hc-acct-host .hc-acct-item { display: flex !important; align-items: center; gap: 10px; width: 100%; margin: 0; padding: 10px; border: 0; border-radius: 9px;
  background: none; color: #153a67; font: 600 13.5px/1.25 var(--font-ui); text-align: start; text-decoration: none; cursor: pointer; }
.hc-acct-host .hc-acct-item:hover, .hc-acct-host .hc-acct-item:focus-visible { background: #eef5fe; color: #0b6ce1; outline: none; }
.hc-acct-host .hc-acct-item svg { width: 18px; height: 18px; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.hc-acct-host .hc-acct-danger { color: #a8321f; }
.hc-acct-host .hc-acct-danger:hover, .hc-acct-host .hc-acct-danger:focus-visible { background: #fdf1ef; color: #b42318; }
.hc-acct-host .hc-acct-sep { height: 1px; margin: 6px 4px; background: #e8eef6; }

/* ---------- Calculator pages: top right of the tool bar, icon / avatar only ---------- */
.topbar { position: relative; }
.topbar .hc-tool-acct { display: inline-flex; flex: none; align-items: center; }
.topbar .hc-acct { height: 40px; padding: 0 4px; gap: 4px; }
.topbar .hc-acct-label, .topbar .hc-acct-in > .hc-acct-pro, .topbar .hc-acct-caret { display: none; }
/* tablet and phone: the tools wrap under the title, so the account control moves to the corner of the bar */
@media (max-width: 980px) {
  .topbar .hc-tool-acct { position: absolute; top: 0; right: 0; }
  html[dir="rtl"] .topbar .hc-tool-acct { right: auto; left: 0; }
  .topbar-left { padding-inline-end: 52px; }
}
@media (max-width: 640px) {
  .topbar .hc-tool-acct { top: -4px; }
  .topbar .hc-acct { height: 38px; }
  .topbar-left { padding-inline-end: 0; }   /* brand row on its own line, the title starts below the control */
}
