/* bellhive99.com - shared styles for sign-in, the site bar, admin and account pages.
 * Layout follows HHB Project Exchange; colors are Bellhive honey. */
@import url('https://fonts.googleapis.com/css2?family=Barlow:wght@400;500;600;700&family=Barlow+Condensed:wght@600;700&display=swap');

:root {
  --bh-brand: #2a2216; --bh-brand-mid: #4a3b22; --bh-accent: #f2b134; --bh-accent-ink: #1a1406;
  --bh-bg: #f5f3ef; --bh-surface: #fff; --bh-surface2: #faf8f4;
  --bh-border: #e6e1d6; --bh-border2: #d3ccbd;
  --bh-text: #1e1a14; --bh-text2: #5f5747; --bh-text3: #948a77;
  --bh-red: #b9382b; --bh-red-bg: #fbeeec; --bh-green: #1e7e4a; --bh-green-bg: #eaf6ee;
  --bh-honey-bg: #fdf3dc;
  --bh-r: 8px; --bh-rl: 12px;
  --bh-font: 'Barlow', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --bh-display: 'Barlow Condensed', 'Arial Narrow', sans-serif;
}

/* ---------- base ---------- */
.bh-login *, .bh-loading *, .bh-bar *, .bh-overlay *, body.bh-page * { box-sizing: border-box; }

/* ---------- loading + login (full screen) ---------- */
.bh-loading, .bh-login { position: fixed; inset: 0; z-index: 900; display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 14px;
  background: radial-gradient(900px 420px at 50% -10%, rgba(242,177,52,.22), transparent 60%), var(--bh-brand); font-family: var(--bh-font); }
.bh-loading .bh-wordmark { color: #fff; }
.bh-spinner { width: 30px; height: 30px; border: 3px solid rgba(255,255,255,.2); border-top-color: var(--bh-accent); border-radius: 50%; animation: bh-spin .7s linear infinite; }
@keyframes bh-spin { to { transform: rotate(360deg); } }
.bh-loading-msg { color: rgba(255,255,255,.6); font-size: 13px; }
.bh-gone { display: none !important; }

.bh-login-box { background: #fff; border-radius: var(--bh-rl); padding: 34px 38px 26px; width: 380px; max-width: calc(100vw - 32px); box-shadow: 0 24px 80px rgba(0,0,0,.35); }
.bh-logo { text-align: center; margin-bottom: 22px; }
.bh-wordmark { font: 700 30px/1 var(--bh-display); letter-spacing: .5px; color: var(--bh-brand); }
.bh-wordmark b { color: var(--bh-accent); font-weight: 700; }
.bh-logo .sub { font-size: 11px; color: var(--bh-text3); margin-top: 4px; text-transform: uppercase; letter-spacing: .1em; }
.bh-logo .bar { width: 40px; height: 3px; background: var(--bh-accent); border-radius: 2px; margin: 12px auto 0; }
.bh-field { display: block; margin-bottom: 13px; }
.bh-field > span { display: block; font-size: 12px; font-weight: 600; color: var(--bh-text2); margin-bottom: 4px; }
.bh-field input, .bh-field select { width: 100%; font: 14px var(--bh-font); padding: 9px 11px; border: 1px solid var(--bh-border2); border-radius: var(--bh-r); color: var(--bh-text); background: #fff; outline: none; }
.bh-field input:focus, .bh-field select:focus { border-color: var(--bh-brand-mid); box-shadow: 0 0 0 3px rgba(242,177,52,.25); }
.bh-field input[readonly] { background: var(--bh-surface2); color: var(--bh-text2); }
.bh-login-btn { width: 100%; padding: 11px; background: var(--bh-brand); color: #fff; border: 0; border-radius: var(--bh-r); font: 600 15px var(--bh-font); cursor: pointer; margin-top: 4px; }
.bh-login-btn:hover { background: var(--bh-brand-mid); }
.bh-login-btn:disabled { opacity: .6; cursor: default; }
.bh-err { color: var(--bh-red); font-size: 13px; min-height: 18px; margin: 6px 0; text-align: center; }
.bh-forgot { text-align: center; margin-top: 12px; font-size: 13px; color: var(--bh-text3); }
.bh-forgot a, .bh-link { color: #9a6a10; cursor: pointer; text-decoration: none; }
.bh-forgot a:hover, .bh-link:hover { text-decoration: underline; }
/* "Not a member? Sign our Guest Book" on the sign-in screen */
.bh-guest-link { display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 16px; padding: 9px 12px; border: 1px dashed #e5c97f; border-radius: var(--bh-r);
  background: var(--bh-honey-bg); color: #6b4a07; font-size: 13px; text-decoration: none; transition: .15s; }
.bh-guest-link:hover { border-style: solid; border-color: var(--bh-accent); background: #fcebc0; }
.bh-guest-link b { color: #8a5a00; }
.bh-guest-link svg { width: 15px; height: 15px; flex: none; fill: none; stroke: #b8862a; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.bh-login-foot { text-align: center; margin-top: 16px; padding-top: 12px; border-top: 1px solid var(--bh-border); font-size: 11px; color: var(--bh-text3); letter-spacing: .04em; }

/* ---------- site bar (above the vintage frames) ---------- */
.bh-bar { height: 40px; background: var(--bh-brand); border-bottom: 2px solid var(--bh-accent); display: flex; align-items: center; gap: 12px; padding: 0 14px; font: 13px var(--bh-font); color: rgba(255,255,255,.85); }
.bh-bar .bh-wordmark { font-size: 21px; color: #fff; text-decoration: none; }
.bh-bar .spacer { flex: 1; }
.bh-av { width: 26px; height: 26px; border-radius: 50%; background: var(--bh-accent); color: var(--bh-accent-ink); display: inline-flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 700; }
.bh-rtag { font-size: 11px; padding: 1px 7px; border-radius: 20px; background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.22); }
.bh-bar-btn { background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.22); color: rgba(255,255,255,.9); border-radius: var(--bh-r); padding: 4px 10px; font: 12px var(--bh-font); cursor: pointer; text-decoration: none; white-space: nowrap; }
.bh-bar-btn:hover { background: rgba(255,255,255,.2); }
@media (max-width: 640px) { .bh-bar .bh-who-name, .bh-bar .bh-rtag { display: none; } }

/* ---------- buttons, badges ---------- */
.bh-btn { display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px; border-radius: var(--bh-r); border: 1px solid var(--bh-border2); background: #fff; color: var(--bh-text); font: 600 13px var(--bh-font); cursor: pointer; white-space: nowrap; }
.bh-btn:hover { border-color: var(--bh-text3); }
.bh-btn.primary { background: var(--bh-brand); border-color: var(--bh-brand); color: #fff; }
.bh-btn.primary:hover { background: var(--bh-brand-mid); }
.bh-btn.danger { color: var(--bh-red); }
.bh-btn.sm { padding: 4px 10px; font-size: 12px; }
.bh-btn:disabled { opacity: .55; cursor: default; }
.bh-ib { width: 30px; height: 30px; border-radius: 6px; border: 1px solid var(--bh-border); background: #fff; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; color: var(--bh-text2); }
.bh-ib:hover { border-color: var(--bh-text3); color: var(--bh-text); }
.bh-ib.red:hover { color: var(--bh-red); border-color: var(--bh-red); }
.bh-ib svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.bh-badge { display: inline-block; font-size: 11px; padding: 2px 8px; border-radius: 20px; font-weight: 600; }
.bh-badge.admin { background: var(--bh-honey-bg); color: #8a5a00; }
.bh-badge.member { background: #eef0f3; color: #4b5563; }
.bh-badge.on { background: var(--bh-green-bg); color: var(--bh-green); }
.bh-badge.off { background: var(--bh-red-bg); color: var(--bh-red); }

/* ---------- admin / account pages ---------- */
body.bh-page { margin: 0; background: var(--bh-bg); color: var(--bh-text); font: 14px/1.45 var(--bh-font); }
.bh-page-wrap { max-width: 980px; margin: 0 auto; padding: 22px 20px 50px; }
.bh-page-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.bh-page-head h1 { margin: 0; font: 700 30px var(--bh-display); letter-spacing: .3px; }
.bh-page-head .crumb { font-size: 11px; color: var(--bh-text3); text-transform: uppercase; letter-spacing: .1em; }
.bh-card { background: var(--bh-surface); border: 1px solid var(--bh-border); border-radius: var(--bh-rl); overflow: hidden; }
.bh-card-pad { padding: 18px 20px; }
.bh-card + .bh-card { margin-top: 14px; }
.bh-card h2 { margin: 0 0 12px; font: 700 20px var(--bh-display); letter-spacing: .3px; }
.bh-user-row { display: grid; grid-template-columns: 2.2fr 1fr 1fr 1.4fr 76px; gap: 12px; align-items: center; padding: 11px 16px; border-top: 1px solid var(--bh-border); }
.bh-user-row.header { border-top: 0; background: var(--bh-surface2); font-size: 11px; font-weight: 600; color: var(--bh-text3); text-transform: uppercase; letter-spacing: .06em; }
.bh-user-row .sortable { cursor: pointer; user-select: none; }
.bh-user-row .sortable:hover, .bh-user-row .sort-active { color: var(--bh-text); }
.bh-user-row .name { font-weight: 600; }
.bh-user-row .email { font-size: 12px; color: var(--bh-text3); }
.bh-user-row .when { font-size: 12px; color: var(--bh-text2); }
.bh-user-row .acts { display: flex; gap: 4px; justify-content: flex-end; }
.bh-you { font-size: 10px; font-weight: 600; color: #8a5a00; background: var(--bh-honey-bg); border-radius: 4px; padding: 0 5px; margin-left: 6px; vertical-align: 1px; }
@media (max-width: 720px) {
  .bh-user-row { grid-template-columns: 1fr auto; }
  .bh-user-row > :nth-child(2), .bh-user-row > :nth-child(3), .bh-user-row > :nth-child(4) { display: none; }
}
.bh-empty { padding: 28px; text-align: center; color: var(--bh-text3); }
.bh-alert { padding: 12px 14px; border-radius: var(--bh-r); background: var(--bh-red-bg); color: var(--bh-red); }
.bh-info { display: flex; gap: 8px; padding: 10px 12px; border-radius: var(--bh-r); background: var(--bh-honey-bg); color: #6b4a07; font-size: 13px; }
.bh-grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 12px; }
@media (max-width: 560px) { .bh-grid2 { grid-template-columns: 1fr; } }
.bh-section { background: var(--bh-surface2); border: 1px solid var(--bh-border); border-radius: var(--bh-r); padding: 12px 14px; font-size: 13px; color: var(--bh-text2); margin-top: 4px; }
.bh-section-title { font-weight: 600; color: var(--bh-text); margin-bottom: 8px; }
.bh-kv { display: grid; grid-template-columns: 140px 1fr; gap: 8px 14px; font-size: 14px; }
.bh-kv dt { color: var(--bh-text3); }
.bh-kv dd { margin: 0; }

/* ---------- modal ---------- */
.bh-overlay { position: fixed; inset: 0; background: rgba(20,16,10,.45); z-index: 950; display: flex; align-items: center; justify-content: center; padding: 16px; font-family: var(--bh-font); }
.bh-modal { background: #fff; border-radius: var(--bh-rl); width: 420px; max-width: 100%; max-height: calc(100vh - 32px); display: flex; flex-direction: column; box-shadow: 0 24px 80px rgba(0,0,0,.3); }
.bh-modal.wide { width: 560px; }
.bh-mhead { display: flex; align-items: center; justify-content: space-between; padding: 14px 18px; border-bottom: 1px solid var(--bh-border); font: 700 20px var(--bh-display); letter-spacing: .3px; color: var(--bh-text); }
.bh-x { border: 0; background: none; font-size: 22px; line-height: 1; cursor: pointer; color: var(--bh-text3); }
.bh-mbody { padding: 16px 18px 6px; overflow-y: auto; color: var(--bh-text); }
.bh-mfoot { display: flex; justify-content: flex-end; gap: 8px; padding: 12px 18px; border-top: 1px solid var(--bh-border); }
.bh-note { font-size: 13px; color: var(--bh-text2); margin: 0 0 14px; }
.bh-modal .bh-err { text-align: left; }

/* ---------- toast ---------- */
.bh-toast { position: fixed; left: 50%; bottom: 22px; transform: translate(-50%, 16px); background: var(--bh-brand); color: #fff; padding: 10px 16px; border-radius: 10px; font: 600 13px var(--bh-font); opacity: 0; transition: .25s; z-index: 990; max-width: 90vw; text-align: center; }
.bh-toast.ok { background: var(--bh-green); }
.bh-toast.error { background: var(--bh-red); }
.bh-toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- audit log ---------- */
.al-filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.al-select, .al-search { font: 13px var(--bh-font); padding: 7px 10px; border: 1px solid var(--bh-border2); border-radius: var(--bh-r); background: #fff; color: var(--bh-text); outline: none; }
.al-select:focus, .al-search:focus { border-color: var(--bh-brand-mid); box-shadow: 0 0 0 3px rgba(242,177,52,.25); }
.al-search { flex: 1; min-width: 180px; }
.al-count { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 8px; font-size: 12px; color: var(--bh-text3); margin: 0 2px 8px; }
.al-legend { display: flex; gap: 12px; flex-wrap: wrap; }
.al-legend span { display: inline-flex; align-items: center; gap: 5px; }
.al-card { padding: 0 16px; }
.al-day { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; color: var(--bh-text3); padding: 14px 0 6px; border-bottom: 1px solid var(--bh-border); }
.al-row { display: grid; grid-template-columns: 70px 12px 1fr auto; gap: 10px; align-items: baseline; padding: 9px 0; border-bottom: 1px solid var(--bh-border); font-size: 13px; cursor: pointer; }
.al-row:hover { background: var(--bh-surface2); }
.al-row:focus-visible { outline: 2px solid var(--bh-brand-mid); outline-offset: -2px; }
.al-row:last-child { border-bottom: 0; }
.al-time { color: var(--bh-text3); font-size: 12px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.al-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: #9aa3b0; }
.al-dot.k-access { background: #2a8fb5; }
.al-dot.k-create { background: var(--bh-green); }
.al-dot.k-update { background: #d39a1e; }
.al-dot.k-security { background: #7b4fc4; }
.al-dot.k-delete { background: var(--bh-red); }
.al-who { font-weight: 600; color: var(--bh-brand); }
.al-role { font-size: 11px; color: var(--bh-text3); }
.al-what { color: var(--bh-text2); }
.al-ref { color: var(--bh-text3); }
.al-mod { font-size: 11px; color: var(--bh-text3); background: var(--bh-surface2); border: 1px solid var(--bh-border); border-radius: 10px; padding: 0 7px; white-space: nowrap; }
.al-dot.k-view { background: #8fa2b8; }
.al-dot.k-visit { background: #c7cdd6; border: 1px solid #9aa3b0; }
.al-filters2 { margin-top: -4px; gap: 18px; }
.al-check { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--bh-text2); cursor: pointer; user-select: none; }
.al-check input { accent-color: var(--bh-brand-mid); width: 15px; height: 15px; margin: 0; }
.al-row { grid-template-columns: minmax(70px, max-content) 12px 1fr auto; }
.al-tags { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.al-src { font-size: 10.5px; border-radius: 10px; padding: 0 7px; border: 1px solid transparent; }
.al-src.s-browser { color: #5c6b7a; background: #eef2f6; border-color: #dbe2ea; }
.al-src.s-database { color: #22704a; background: #e7f5ec; border-color: #c9e8d4; }
.al-src.s-server { color: #6b44a8; background: #f1ebfb; border-color: #e0d4f5; }
.al-src.s-visit { color: #8a6a1e; background: var(--bh-honey-bg); border-color: #f0dfae; }
.al-count-badge { font-size: 11px; font-weight: 600; color: #8a5a00; background: var(--bh-honey-bg); border-radius: 10px; padding: 0 7px; }
.al-more { font-size: 12px; color: var(--bh-text3); font-style: italic; }
.al-caret { color: var(--bh-text3); font-size: 11px; width: 10px; text-align: center; }
.al-row.open { background: var(--bh-surface2); }
.al-kids { border-left: 2px solid var(--bh-border2); margin-left: 34px; padding-left: 10px; }
.al-child { font-size: 12.5px; }
.al-detail { background: var(--bh-surface2); border-bottom: 1px solid var(--bh-border); padding: 10px 14px 14px 92px; font-size: 12.5px; }
.al-facts { display: grid; grid-template-columns: max-content 1fr; gap: 3px 14px; margin: 0 0 10px; }
.al-facts dt { color: var(--bh-text3); }
.al-facts dd { margin: 0; color: var(--bh-text); word-break: break-word; }
.al-diff { border-collapse: collapse; width: 100%; max-width: 640px; background: #fff; border: 1px solid var(--bh-border); border-radius: var(--bh-r); overflow: hidden; }
.al-diff th { text-align: left; font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .05em; color: var(--bh-text3); background: var(--bh-surface2); padding: 6px 10px; border-bottom: 1px solid var(--bh-border); }
.al-diff td { padding: 6px 10px; border-bottom: 1px solid var(--bh-border); vertical-align: top; word-break: break-word; }
.al-diff tr:last-child td { border-bottom: 0; }
.al-diff td:first-child { color: var(--bh-text2); width: 30%; }
.al-old { color: #9b2c2c; text-decoration: line-through; text-decoration-color: rgba(155,44,44,.45); }
.al-new { color: #1f6b43; font-weight: 600; }
@media (max-width: 600px) {
  .al-row { grid-template-columns: 58px 10px 1fr; } .al-tags { display: none; }
  .al-detail { padding-left: 14px; } .al-kids { margin-left: 8px; }
}

/* ---------- site version (sign-in screen) ---------- */
.bh-login-ver { text-align: center; margin-top: 6px; font: 11px 'Consolas', 'Courier New', monospace; color: var(--bh-text3); letter-spacing: .02em; }

/* ---------- release notes ---------- */
.rn-card { overflow: visible; }
.rn-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 14px 20px; background: var(--bh-surface2); border-bottom: 1px solid var(--bh-border); border-radius: var(--bh-rl) var(--bh-rl) 0 0; position: sticky; top: 0; z-index: 10; }
.rn-title { font-size: 14px; font-weight: 600; }
.rn-sub { font-size: 11px; color: var(--bh-text3); margin-top: 2px; }
.rn-mono { font: 11px 'Consolas', 'Courier New', monospace; color: var(--bh-text3); white-space: nowrap; }
.rn-month-head { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 20px; background: var(--bh-surface2); border: 0; border-bottom: 1px solid var(--bh-border); cursor: pointer; font: 13px var(--bh-font); color: var(--bh-text); text-align: left; position: sticky; top: 55px; z-index: 9; }
.rn-month-head:hover { background: var(--bh-honey-bg); }
.rn-month:last-child:not(.open) .rn-month-head { border-bottom: 0; border-radius: 0 0 var(--bh-rl) var(--bh-rl); }
.rn-month-label { display: flex; align-items: center; gap: 10px; font-weight: 600; }
.rn-car { font-size: 12px; color: var(--bh-text3); width: 10px; }
.rn-count { font-size: 11px; color: var(--bh-text3); }
.rn-entry { padding: 16px 20px; border-bottom: 1px solid var(--bh-border); }
.rn-month:last-child .rn-entry:last-child { border-bottom: 0; }
.rn-entry-head { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.rn-ver { font: 600 13px 'Consolas', 'Courier New', monospace; color: #9a6a10; }
.rn-date { font-size: 11px; color: var(--bh-text3); }
.rn-items { font-size: 13px; color: var(--bh-text2); line-height: 1.75; padding-left: 18px; margin: 0; }
