/* ===========================================================================
   Lifehaki: Birthday hub (/birthdays).
   Loaded only when bodyClass contains `lh-birthdays` (templates/layout.php).
   Rules are scoped under `.bh-scope` (the hub root, and the birthday banner /
   frame roots on /title, /character, /staff, which link this same sheet);
   class prefix `bh-*` (`bd-*` is the blog).
   =========================================================================== */

body.lh-birthdays, .bh-scope {
    --bh-paper: #f5f5f9;
    --bh-white: #fff;
    --bh-ink: #15171c;
    --bh-ink-2: #20242b;
    --bh-body: #4d535e;
    --bh-faint: #767d89;
    --bh-line: #e3e3ea;
    --bh-line-2: #ececf1;
    --bh-line-3: #d2d3dc;
    --bh-red: #ca2128;
    --bh-red-dark: #a81a20;
    --bh-gold: #fdc949;
    --bh-gold-soft: #fff6dc;
    --bh-gold-ink: #8a6410;
    --bh-green: #2f8f5b;
    --bh-display: 'Fraunces', Georgia, serif;
    --bh-text: 'Urbanist', system-ui, sans-serif;
    --bh-cond: 'Barlow Condensed', 'Arial Narrow', sans-serif;
    --bh-mono: 'DM Mono', ui-monospace, monospace;
    --bh-ease: cubic-bezier(.16, 1, .3, 1);
    --bh-max: 1320px;
    color: var(--bh-ink-2);
    font-family: var(--bh-text);
}
body.lh-birthdays { background: var(--bh-paper); }
html:has(> body.lh-birthdays), body.lh-birthdays, body.lh-birthdays main { overflow-x: clip; }
body.lh-birthdays main { padding: 0; max-width: none; }
body.lh-birthdays ::selection { background: var(--bh-gold); color: var(--bh-ink); }
body.lh-birthdays [hidden], .bh-scope [hidden] { display: none !important; }

.bh-scope .bh-wrap { max-width: var(--bh-max); margin: 0 auto; padding-left: 40px; padding-right: 40px; }
.bh-scope .bh-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.bh-scope .bh-kicker { font-family: var(--bh-cond); font-weight: 600; font-size: 13px; letter-spacing: .14em; text-transform: uppercase; color: var(--bh-red); }
.bh-scope .bh-kicker-gold { color: var(--bh-gold-ink); }
.bh-scope .bh-mono { font-family: var(--bh-mono); font-size: 12px; color: var(--bh-faint); }
.bh-scope .bh-gold { color: var(--bh-gold-ink); }
.bh-scope .bh-mt { display: block; margin-top: 14px; }
.bh-scope .bh-small { font-size: 12.5px; color: var(--bh-faint); margin: 12px 0 0; }
.bh-scope .bh-small a { color: var(--bh-red); }

@keyframes bh-pulse { 0% { box-shadow: 0 0 0 0 rgba(47,143,91,.55); } 70% { box-shadow: 0 0 0 7px rgba(47,143,91,0); } 100% { box-shadow: 0 0 0 0 rgba(47,143,91,0); } }
@keyframes bh-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* ---------------------------------------------------------------- hero */
.bh-scope .bh-hero { position: relative; background: var(--bh-ink); overflow: hidden; }
.bh-scope .bh-hero::before, .bh-scope .bh-hero::after {
    content: ''; position: absolute; border-radius: 50%; pointer-events: none;
}
.bh-scope .bh-hero::before { top: -180px; right: -120px; width: 620px; height: 620px; background: radial-gradient(circle, rgba(253,201,73,.22), transparent 70%); }
.bh-scope .bh-hero::after { bottom: -220px; left: -160px; width: 640px; height: 640px; background: radial-gradient(circle, rgba(202,33,40,.2), transparent 70%); }
.bh-scope .bh-hero-grid { position: relative; z-index: 1; padding-top: 52px; padding-bottom: 56px; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 460px), 1fr)); gap: 40px; align-items: center; }
.bh-scope .bh-live { display: flex; align-items: center; gap: 11px; margin: 0 0 16px; }
.bh-scope .bh-live .bh-kicker { color: var(--bh-gold); font-size: 14px; }
.bh-scope .bh-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--bh-green); animation: bh-pulse 2.2s infinite; flex: none; }
.bh-scope .bh-h1 { font-family: var(--bh-display); font-weight: 900; font-size: clamp(40px, 5vw, 64px); line-height: .98; letter-spacing: -.02em; color: #fff; margin: 0 0 18px; text-wrap: pretty; }
.bh-scope .bh-h1 em, .bh-scope .bh-faq-h em { color: var(--bh-gold); font-style: italic; }
.bh-scope .bh-lede { font-size: 18px; line-height: 1.5; color: rgba(255,255,255,.82); margin: 0 0 28px; max-width: 520px; }
.bh-scope .bh-stats { display: flex; flex-wrap: wrap; gap: 12px; }
.bh-scope .bh-stat { display: flex; flex-direction: column; gap: 2px; padding: 14px 18px; border-radius: 14px; background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.12); }
.bh-scope .bh-stat b { font-family: var(--bh-display); font-weight: 900; font-size: 28px; color: #fff; line-height: 1; }
.bh-scope .bh-stat b.is-gold { color: var(--bh-gold); }
.bh-scope .bh-stat span { font-family: var(--bh-cond); font-weight: 600; font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: rgba(255,255,255,.7); }

.bh-scope .bh-feat { background: #fff; border-radius: 24px; box-shadow: 0 30px 70px rgba(0,0,0,.45), 0 0 0 1px rgba(255,255,255,.08); overflow: hidden; display: grid; grid-template-columns: 200px minmax(0, 1fr); padding: 10px; }
.bh-scope .bh-feat-img { position: relative; display: block; min-height: 300px; border-radius: 16px; overflow: hidden; background: linear-gradient(155deg, var(--bh-gold), var(--bh-red)); }
.bh-scope .bh-feat-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.bh-scope .bh-feat-ini { position: absolute; inset: 0; display: grid; place-items: center; color: #fff; font-weight: 800; font-size: 56px; }
.bh-scope .bh-feat-tag { position: absolute; top: 12px; left: 12px; padding: 4px 10px; border-radius: 999px; background: var(--bh-gold); color: var(--bh-ink); font-family: var(--bh-mono); font-size: 12px; }
.bh-scope .bh-feat-body { padding: 20px; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.bh-scope .bh-feat-name { font-family: var(--bh-display); font-weight: 900; font-size: 30px; line-height: 1; letter-spacing: -.02em; color: var(--bh-ink); margin: 0; }
.bh-scope .bh-feat-name a { color: inherit; text-decoration: none; }
.bh-scope .bh-feat-name a:hover { color: var(--bh-red); }
.bh-scope .bh-feat-sub { font-size: 14px; font-weight: 600; color: var(--bh-body); }
.bh-scope .bh-feat-count { display: flex; align-items: center; gap: 8px; font-family: var(--bh-mono); font-size: 13px; color: var(--bh-ink); }
.bh-scope .bh-feat-count svg { color: var(--bh-red); }
.bh-scope .bh-ticker { flex: 1; min-height: 64px; padding: 10px 12px; border-radius: 12px; background: var(--bh-paper); border: 1px solid var(--bh-line); overflow: hidden; }
.bh-scope .bh-tick { margin: 0; font-size: 14px; font-weight: 600; color: var(--bh-ink); line-height: 1.35; animation: bh-in .3s var(--bh-ease); overflow-wrap: anywhere; }
.bh-scope .bh-tick span { display: block; font-family: var(--bh-mono); font-size: 12px; font-weight: 400; color: var(--bh-faint); }

/* ------------------------------------------------------- icon buttons */
.bh-scope .bh-acts { display: flex; gap: 8px; justify-content: center; }
.bh-scope .bh-feat .bh-acts { justify-content: flex-start; }
.bh-scope .bh-ic { display: inline-flex; align-items: center; justify-content: center; width: 42px; height: 42px; border-radius: 999px; border: 0; background: var(--bh-line-2); color: #a0a5b0; cursor: default; transition: transform 120ms var(--bh-ease), background 120ms; text-decoration: none; }
.bh-scope .bh-ic-red { background: var(--bh-red); color: #fffdf8; cursor: pointer; box-shadow: 0 5px 14px rgba(202,33,40,.28); }
.bh-scope .bh-ic-red:hover { background: var(--bh-red-dark); color: #fffdf8; }
.bh-scope .bh-ic.is-wished { border: 1.5px solid var(--bh-gold); background: var(--bh-gold-soft); color: var(--bh-gold-ink); }
.bh-scope .bh-ic-line { border: 1.5px solid var(--bh-line-3); background: #fff; color: var(--bh-ink-2); cursor: pointer; }
.bh-scope .bh-ic-line:hover { background: var(--bh-line-2); }
.bh-scope .bh-ic:not(:disabled):active { transform: scale(.9); }
.bh-scope .bh-round { display: inline-flex; align-items: center; justify-content: center; width: 38px; height: 38px; border-radius: 999px; border: 1.5px solid var(--bh-line-3); background: #fff; color: var(--bh-ink-2); cursor: pointer; }
.bh-scope .bh-round:hover { background: var(--bh-line-2); }

.bh-scope .bh-btn { display: inline-flex; align-items: center; justify-content: center; height: 42px; padding: 0 20px; border-radius: 999px; border: 0; font-family: var(--bh-text); font-weight: 800; font-size: 14px; cursor: pointer; text-decoration: none; transition: transform 120ms, background 120ms; }
.bh-scope .bh-btn-red { background: var(--bh-red); color: #fffdf8; box-shadow: 0 6px 18px rgba(202,33,40,.3); }
.bh-scope .bh-btn-red:hover { background: var(--bh-red-dark); color: #fffdf8; }
.bh-scope .bh-btn-red:disabled { background: var(--bh-line-2); color: #a0a5b0; box-shadow: none; cursor: default; }
.bh-scope .bh-btn-ghost { background: transparent; color: var(--bh-body); }
.bh-scope .bh-btn-ghost:hover { background: var(--bh-line-2); }

/* -------------------------------------------------------- segmented */
.bh-scope .bh-seg { display: flex; align-items: center; background: var(--bh-line-2); border-radius: 999px; padding: 3px; max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.bh-scope .bh-seg button { flex: none; height: 34px; padding: 0 15px; border-radius: 999px; border: 0; background: transparent; color: var(--bh-body); font-family: var(--bh-text); font-size: 14px; font-weight: 700; cursor: pointer; transition: background 120ms, color 120ms; }
.bh-scope .bh-seg button[aria-pressed="true"] { background: var(--bh-ink); color: #fff; }
.bh-scope .bh-seg-sm button { height: 30px; padding: 0 12px; font-size: 13px; }

/* ---------------------------------------------------------- calendar */
.bh-scope .bh-cal { padding-top: 36px; padding-bottom: 8px; }
.bh-scope .bh-cal-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 16px; }
.bh-scope .bh-cal-nav { display: flex; align-items: center; gap: 10px; margin-top: 4px; }
.bh-scope .bh-cal-title { font-family: var(--bh-display); font-weight: 900; font-size: 32px; letter-spacing: -.02em; color: var(--bh-ink); margin: 0; min-width: 250px; text-align: center; }
.bh-scope .bh-cal-tools { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.bh-scope .bh-search { position: relative; }
.bh-scope .bh-search-box { display: flex; align-items: center; gap: 8px; height: 40px; width: 260px; padding: 0 14px; border-radius: 999px; border: 1.5px solid var(--bh-line-3); background: #fff; color: var(--bh-faint); }
.bh-scope .bh-search-box:focus-within { border-color: var(--bh-ink); }
.bh-scope .bh-search-box input { flex: 1; min-width: 0; border: 0; outline: none; background: transparent; font-family: var(--bh-text); font-size: 14px; font-weight: 600; color: var(--bh-ink); }
.bh-scope .bh-search-clear { border: 0; background: none; color: var(--bh-faint); cursor: pointer; padding: 4px; display: inline-flex; }
.bh-scope .bh-search-list { position: absolute; z-index: 20; top: calc(100% + 6px); left: 0; right: 0; margin: 0; padding: 6px; list-style: none; background: #fff; border: 1px solid var(--bh-line); border-radius: 14px; box-shadow: 0 14px 34px rgba(21,23,40,.16); max-height: 320px; overflow: auto; }
.bh-scope .bh-search-list li { display: flex; align-items: center; gap: 10px; padding: 7px 8px; border-radius: 10px; cursor: pointer; font-size: 14px; font-weight: 600; color: var(--bh-ink); }
.bh-scope .bh-search-list li[aria-selected="true"], .bh-scope .bh-search-list li:hover { background: var(--bh-line-2); }
.bh-scope .bh-search-list img { width: 28px; height: 40px; object-fit: cover; border-radius: 4px; flex: none; }
.bh-scope .bh-cal-summary { font-size: 14px; font-weight: 600; color: var(--bh-body); margin: 0 0 12px; }
.bh-scope .bh-week, .bh-scope .bh-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 8px; }
.bh-scope .bh-week { margin-bottom: 8px; }
.bh-scope .bh-week span { font-family: var(--bh-cond); font-weight: 600; font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--bh-faint); padding-left: 4px; }
.bh-scope .bh-grid.is-loading { opacity: .55; transition: opacity .2s; }
.bh-scope .bh-cell { display: flex; flex-direction: column; justify-content: space-between; align-items: flex-start; gap: 10px; min-height: 108px; padding: 10px; border-radius: 14px; text-align: left; cursor: pointer; font-family: var(--bh-text); background: #fff; border: 1px solid var(--bh-line); box-shadow: 0 2px 10px rgba(21,23,40,.05); transition: transform 160ms var(--bh-ease), box-shadow 160ms; }
.bh-scope .bh-cell:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(21,23,40,.12); }
.bh-scope .bh-cell.is-pad { visibility: hidden; }
.bh-scope .bh-cell.is-today { border: 2px solid var(--bh-red); }
.bh-scope .bh-cell.is-empty { opacity: .45; }
.bh-scope .bh-cell.is-sel { background: var(--bh-ink); border: 2px solid var(--bh-ink); box-shadow: 0 10px 24px rgba(21,23,40,.25); }
.bh-scope .bh-cell-top { display: flex; align-items: baseline; justify-content: space-between; gap: 6px; width: 100%; }
.bh-scope .bh-cell-num { font-family: var(--bh-display); font-weight: 900; font-size: 20px; line-height: 1; color: var(--bh-ink); }
.bh-scope .bh-cell-n { font-family: var(--bh-mono); font-size: 11px; color: var(--bh-faint); }
.bh-scope .bh-cell.is-today .bh-cell-n { color: var(--bh-red); }
.bh-scope .bh-cell.is-sel .bh-cell-num { color: #fff; }
.bh-scope .bh-cell.is-sel .bh-cell-n { color: var(--bh-gold); }
.bh-scope .bh-cell-avs { display: flex; align-items: center; }
.bh-scope .bh-av-xs, .bh-scope .bh-av-more { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; border-radius: 999px; border: 2px solid #fff; overflow: hidden; background: linear-gradient(155deg, var(--bh-gold), var(--bh-red)); color: #fff; font-weight: 800; font-size: 10px; box-shadow: 0 1px 3px rgba(21,23,40,.15); }
.bh-scope .bh-av-xs + .bh-av-xs, .bh-scope .bh-av-xs + .bh-av-more { margin-left: -9px; }
.bh-scope .bh-av-xs img { width: 100%; height: 100%; object-fit: cover; }
.bh-scope .bh-av-more { width: auto; min-width: 30px; padding: 0 6px; background: var(--bh-line-2); color: var(--bh-ink); font-family: var(--bh-mono); font-size: 11px; font-weight: 400; box-shadow: none; }
.bh-scope .bh-cell.is-sel .bh-av-xs, .bh-scope .bh-cell.is-sel .bh-av-more { border-color: var(--bh-ink); }
.bh-scope .bh-cell.is-sel .bh-av-more { background: var(--bh-gold); }

/* --------------------------------------------------- day list + rail */
.bh-scope .bh-body { padding-top: 28px; padding-bottom: 24px; display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 32px; align-items: start; }
.bh-scope .bh-day { min-width: 0; display: flex; flex-direction: column; gap: 18px; scroll-margin-top: calc(var(--mn-offset, 64px) + 16px); }
.bh-scope .bh-day-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.bh-scope .bh-day-page { display: inline-block; margin-top: 6px; font-weight: 600; color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.bh-scope .bh-day-page[hidden] { display: none; }
.bh-scope .bh-day-title { font-family: var(--bh-display); font-weight: 900; font-size: 32px; letter-spacing: -.02em; color: var(--bh-ink); margin: 4px 0 0; }
.bh-scope .bh-people { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 30px 16px; padding-top: 6px; }
.bh-scope .bh-people.is-loading { opacity: .55; }
.bh-scope .bh-person { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 3px; min-width: 0; animation: bh-in .3s var(--bh-ease); }
.bh-scope .bh-av-wrap { position: relative; margin-bottom: 10px; }
.bh-scope .bh-frame { display: flex; align-items: center; justify-content: center; width: 112px; height: 112px; border-radius: 999px; padding: 5px; background: var(--bh-line); text-decoration: none; }
/* The Sparkle frame (the one the owner picked from the design's six). */
.bh-scope .bh-frame.is-live { background: repeating-conic-gradient(from var(--r, 0deg), #fdc949 0 4deg, #fff 4deg 14deg); box-shadow: 0 6px 18px rgba(253,201,73,.45); }
.bh-scope .bh-av { display: inline-flex; align-items: center; justify-content: center; width: 100%; height: 100%; border-radius: 999px; border: 3px solid #fff; overflow: hidden; background: linear-gradient(155deg, var(--bh-gold), var(--bh-red)); color: #fff; font-weight: 800; font-size: 34px; letter-spacing: -.02em; }
.bh-scope .bh-av img { width: 100%; height: 100%; object-fit: cover; }
.bh-scope a.bh-frame:hover .bh-av { filter: brightness(1.05); }
.bh-scope .bh-fav { position: absolute; top: 0; right: 0; display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 999px; border: 2px solid var(--bh-paper); background: #fff; color: var(--bh-faint); cursor: pointer; box-shadow: 0 2px 8px rgba(21,23,40,.12); transition: transform 120ms var(--bh-ease); }
.bh-scope .bh-fav:hover { transform: scale(1.08); }
.bh-scope .bh-fav[aria-pressed="true"], .bh-scope .bh-fav-sm[aria-pressed="true"] { color: var(--bh-red); }
.bh-scope .bh-fav[aria-pressed="true"] svg, .bh-scope .bh-fav-sm[aria-pressed="true"] svg { fill: currentColor; }
.bh-scope .bh-name { font-family: var(--bh-display); font-weight: 700; font-size: 17px; line-height: 1.15; color: var(--bh-ink); margin: 0; text-wrap: pretty; }
.bh-scope .bh-name a { color: inherit; text-decoration: none; }
.bh-scope .bh-name a:hover { color: var(--bh-red); }
.bh-scope .bh-sub { max-width: 100%; font-size: 13px; font-weight: 600; color: var(--bh-faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bh-scope .bh-count { font-family: var(--bh-mono); font-size: 12px; color: var(--bh-body); }
.bh-scope .bh-person .bh-acts { margin-top: 8px; }
.bh-scope .bh-person .bh-ic { width: 40px; height: 40px; }
.bh-scope .bh-empty { font-size: 15px; color: var(--bh-faint); margin: 8px 0; }

.bh-scope .bh-rail { position: sticky; top: calc(var(--mn-offset, 64px) + 24px); display: flex; flex-direction: column; gap: 18px; }
.bh-scope .bh-card { background: #fff; border: 1px solid var(--bh-line); border-radius: 20px; box-shadow: 0 2px 14px rgba(21,23,40,.06); padding: 20px; }
.bh-scope .bh-card-ink { border: 2px solid var(--bh-ink); border-radius: 14px; box-shadow: 4px 4px 0 var(--bh-ink); }
.bh-scope .bh-card-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.bh-scope .bh-card-copy { font-size: 14px; color: var(--bh-body); line-height: 1.5; margin: 8px 0 14px; }
.bh-scope .bh-streak { display: inline-flex; align-items: center; gap: 5px; font-family: var(--bh-mono); font-size: 13px; color: var(--bh-red); }
.bh-scope .bh-streak svg { fill: currentColor; }
.bh-scope .bh-xp-today { display: flex; align-items: baseline; gap: 8px; margin: 10px 0 0; font-size: 14px; font-weight: 600; color: var(--bh-faint); }
.bh-scope .bh-xp-today b { font-family: var(--bh-display); font-weight: 900; font-size: 30px; color: var(--bh-ink); line-height: 1; }
.bh-scope .bh-bar { margin: 14px 0 6px; height: 8px; border-radius: 999px; background: var(--bh-line-2); overflow: hidden; }
.bh-scope .bh-bar i { display: block; height: 100%; background: var(--bh-red); border-radius: 999px; transition: width .4s var(--bh-ease); }
.bh-scope .bh-quests { list-style: none; margin: 10px 0 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.bh-scope .bh-quests li { display: flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 600; color: var(--bh-ink-2); }
.bh-scope .bh-quests li > span:nth-child(2) { flex: 1; }
.bh-scope .bh-check { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 20px; height: 20px; border-radius: 999px; background: #fff; border: 1.5px solid var(--bh-line-3); color: transparent; }
.bh-scope .bh-quests li.is-done .bh-check { background: var(--bh-green); border-color: var(--bh-green); color: #fff; }
.bh-scope .bh-rules { margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--bh-line); display: grid; grid-template-columns: 1fr 1fr; gap: 8px 12px; font-size: 13px; color: var(--bh-body); }
.bh-scope .bh-rules b { font-family: var(--bh-mono); font-weight: 500; color: var(--bh-ink); }
.bh-scope .bh-twin-pick { display: flex; gap: 8px; margin: 12px 0; }
.bh-scope .bh-twin-pick select { flex: 1; height: 40px; padding: 0 12px; border-radius: 14px; border: 1.5px solid var(--bh-line-3); background: #fff; font-family: var(--bh-text); font-size: 14px; font-weight: 600; color: var(--bh-ink); }
.bh-scope .bh-twin-pick select + label + select { flex: 0 0 84px; font-family: var(--bh-mono); }
.bh-scope .bh-twin-text { font-size: 14px; line-height: 1.45; color: var(--bh-ink-2); margin: 0 0 10px; }
.bh-scope .bh-twin-text b { font-family: var(--bh-display); font-weight: 900; font-size: 18px; }
.bh-scope .bh-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.bh-scope .bh-chip { display: inline-flex; align-items: center; gap: 7px; padding: 3px 11px 3px 3px; border-radius: 999px; background: var(--bh-paper); border: 1px solid var(--bh-line); font-size: 13px; font-weight: 700; color: var(--bh-ink); text-decoration: none; }
.bh-scope a.bh-chip:hover { border-color: var(--bh-ink); }
.bh-scope .bh-av-chip { display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 24px; border-radius: 999px; overflow: hidden; background: linear-gradient(155deg, var(--bh-gold), var(--bh-red)); color: #fff; font-size: 9px; font-weight: 800; }
.bh-scope .bh-av-chip img { width: 100%; height: 100%; object-fit: cover; }
.bh-scope .bh-wishers { list-style: none; margin: 14px 0 0; padding: 0; display: flex; flex-direction: column; gap: 11px; }
.bh-scope .bh-wishers li { display: flex; align-items: center; gap: 11px; font-size: 14px; font-weight: 700; }
.bh-scope .bh-wishers a { flex: 1; color: var(--bh-ink); text-decoration: none; }
.bh-scope .bh-wishers a:hover { color: var(--bh-red); }
.bh-scope .bh-rank { flex: none; min-width: 30px; text-align: center; padding: 3px 7px; border-radius: 999px; background: var(--bh-gold); color: var(--bh-ink); font-family: var(--bh-mono); font-size: 13px; font-weight: 400; }

/* --------------------------------------------------------- coming up */
.bh-scope .bh-up { padding-top: 28px; padding-bottom: 20px; }
.bh-scope .bh-rule-head { display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; margin-bottom: 18px; padding-bottom: 11px; border-bottom: 2px solid var(--bh-ink); }
.bh-scope .bh-rule-head h2 { font-family: var(--bh-display); font-weight: 900; font-size: 26px; letter-spacing: -.02em; color: var(--bh-ink); margin: 0; }
.bh-scope .bh-rule-head span { font-size: 14px; color: var(--bh-faint); }
.bh-scope .bh-up-row { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 14px; }
.bh-scope .bh-up-card { display: flex; align-items: center; gap: 12px; padding: 12px; background: #fff; border: 1px solid var(--bh-line); border-radius: 16px; box-shadow: 0 2px 14px rgba(21,23,40,.06); }
.bh-scope .bh-av-md { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 52px; height: 52px; border-radius: 999px; overflow: hidden; background: linear-gradient(155deg, var(--bh-gold), var(--bh-red)); color: #fff; font-weight: 800; font-size: 18px; text-decoration: none; }
.bh-scope .bh-av-md img { width: 100%; height: 100%; object-fit: cover; }
.bh-scope .bh-up-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.bh-scope .bh-up-name { font-size: 15px; font-weight: 800; color: var(--bh-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-decoration: none; }
.bh-scope a.bh-up-name:hover { color: var(--bh-red); }
.bh-scope .bh-up-sub { font-size: 13px; color: var(--bh-faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bh-scope .bh-up-when { font-family: var(--bh-mono); font-size: 12px; color: var(--bh-red); }
.bh-scope .bh-fav-sm { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 38px; height: 38px; border-radius: 999px; border: 1.5px solid var(--bh-line-3); background: #fff; color: var(--bh-body); cursor: pointer; }
.bh-scope .bh-fav-sm[aria-pressed="true"] { border-color: var(--bh-red); }

/* --------------------------------------------------------------- FAQ */
.bh-scope .bh-faq { padding-top: 40px; padding-bottom: 72px; display: grid; grid-template-columns: minmax(0, 340px) minmax(0, 1fr); gap: 48px; align-items: start; }
.bh-scope .bh-faq-side { position: sticky; top: calc(var(--mn-offset, 64px) + 24px); }
.bh-scope .bh-faq-h { font-family: var(--bh-display); font-weight: 900; font-size: 40px; line-height: 1; letter-spacing: -.02em; color: var(--bh-ink); margin: 8px 0 12px; }
.bh-scope .bh-faq-side p { font-size: 16px; line-height: 1.5; color: var(--bh-body); margin: 0; }
.bh-scope .bh-faq-list { border-top: 1px solid var(--bh-line); }
.bh-scope .bh-qa { border-bottom: 1px solid var(--bh-line); }
.bh-scope .bh-qa summary { list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 20px 4px; cursor: pointer; font-size: 17px; font-weight: 700; color: var(--bh-ink); }
.bh-scope .bh-qa summary::-webkit-details-marker { display: none; }
.bh-scope .bh-qa summary:hover { color: var(--bh-red); }
.bh-scope .bh-qa summary i { position: relative; flex: none; width: 32px; height: 32px; border-radius: 999px; background: var(--bh-line-2); transition: transform .2s var(--bh-ease), background .12s; }
.bh-scope .bh-qa summary i::before, .bh-scope .bh-qa summary i::after { content: ''; position: absolute; left: 50%; top: 50%; width: 14px; height: 2.4px; margin: -1.2px 0 0 -7px; border-radius: 2px; background: var(--bh-ink-2); }
.bh-scope .bh-qa summary i::after { transform: rotate(90deg); }
.bh-scope .bh-qa[open] summary i { transform: rotate(45deg); background: var(--bh-red); }
.bh-scope .bh-qa[open] summary i::before, .bh-scope .bh-qa[open] summary i::after { background: #fff; }
.bh-scope .bh-qa p { font-size: 16px; line-height: 1.6; color: var(--bh-body); margin: 0; padding: 0 56px 22px 4px; }

/* ------------------------------------------------------ dialog/toast */
.bh-scope .bh-dialog { width: min(520px, calc(100% - 32px)); padding: 0; border: 2px solid var(--bh-ink); border-radius: 14px; box-shadow: 6px 6px 0 var(--bh-red); background: #fff; color: var(--bh-ink-2); }
.bh-scope .bh-dialog::backdrop { background: rgba(21,23,28,.45); backdrop-filter: blur(3px); }
.bh-scope .bh-dlg-body { padding: 24px; }
.bh-scope .bh-dlg-title { font-family: var(--bh-display); font-weight: 900; font-size: 28px; letter-spacing: -.02em; color: var(--bh-ink); margin: 6px 0 4px; }
.bh-scope .bh-dlg-sub { font-size: 14px; color: var(--bh-faint); margin: 0 0 16px; }
.bh-scope .bh-presets { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.bh-scope .bh-presets button { padding: 7px 12px; border-radius: 999px; border: 1px solid var(--bh-line); background: var(--bh-paper); font-family: var(--bh-text); font-size: 13px; font-weight: 700; color: var(--bh-ink-2); cursor: pointer; }
.bh-scope .bh-presets button:hover { background: var(--bh-line-2); }
.bh-scope .bh-dialog textarea { width: 100%; min-height: 96px; padding: 12px 14px; border-radius: 14px; border: 1.5px solid var(--bh-line-3); font-family: var(--bh-text); font-size: 16px; color: var(--bh-ink); resize: vertical; outline: none; box-sizing: border-box; }
.bh-scope .bh-dialog textarea:focus { border-color: var(--bh-ink); }
.bh-scope .bh-dlg-foot { display: flex; align-items: center; justify-content: flex-end; gap: 10px; margin-top: 14px; flex-wrap: wrap; }
.bh-scope .bh-dlg-foot .bh-mono { margin-right: auto; }
.bh-scope .bh-dlg-err { font-size: 13px; font-weight: 600; color: var(--bh-red); }
.bh-scope .bh-toast { position: fixed; left: 50%; bottom: 28px; z-index: 60; transform: translateX(-50%); display: flex; align-items: center; gap: 12px; padding: 10px 18px 10px 10px; border-radius: 999px; background: var(--bh-ink); box-shadow: 4px 4px 0 var(--bh-gold); color: #fff; font-size: 14px; font-weight: 700; animation: bh-in .3s var(--bh-ease); max-width: calc(100% - 32px); }
.bh-scope .bh-toast b { padding: 5px 12px; border-radius: 999px; background: var(--bh-gold); color: var(--bh-ink); font-family: var(--bh-mono); font-weight: 400; white-space: nowrap; }

@media (prefers-reduced-motion: reduce) {
    .bh-scope *, .bh-scope *::before { animation: none !important; transition: none !important; }
}

/* ------------------------------------------------------------ tablet */
@media (max-width: 1080px) {
    .bh-scope .bh-body { grid-template-columns: 1fr; }
    .bh-scope .bh-rail { position: static; display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
    .bh-scope .bh-faq { grid-template-columns: 1fr; gap: 18px; }
    .bh-scope .bh-faq-side { position: static; }
}

/* ------------------------------------------------------------- phone */
@media (max-width: 640px) {
    .bh-scope .bh-wrap { padding-left: 16px; padding-right: 16px; }
    .bh-scope .bh-hero-grid { padding-top: 28px; padding-bottom: 28px; gap: 24px; }
    .bh-scope .bh-live .bh-kicker { font-size: 12px; }
    .bh-scope .bh-lede { font-size: 16px; margin-bottom: 20px; }
    .bh-scope .bh-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
    .bh-scope .bh-stat { padding: 12px; }
    .bh-scope .bh-stat b { font-size: 24px; }
    .bh-scope .bh-stat span { font-size: 11px; letter-spacing: .12em; }
    .bh-scope .bh-feat { grid-template-columns: 1fr; padding: 8px; }
    .bh-scope .bh-feat-img { min-height: 190px; }
    .bh-scope .bh-feat-body { padding: 14px 10px 10px; gap: 8px; }
    .bh-scope .bh-feat-name { font-size: 26px; }
    .bh-scope .bh-cal { padding: 24px 12px 8px; }
    .bh-scope .bh-cal-head { flex-direction: column; align-items: stretch; padding: 0 4px; }
    .bh-scope .bh-cal-nav { justify-content: space-between; }
    .bh-scope .bh-cal-title { font-size: 26px; min-width: 0; }
    .bh-scope .bh-round { width: 44px; height: 44px; }
    .bh-scope .bh-cal-tools { flex-direction: column; align-items: stretch; }
    .bh-scope .bh-cal-tools > .bh-seg:first-child { align-self: flex-start; }
    .bh-scope .bh-search-box { width: auto; height: 44px; }
    .bh-scope .bh-search-box input { font-size: 16px; }
    .bh-scope .bh-seg-sm { align-self: flex-start; }
    .bh-scope .bh-week, .bh-scope .bh-grid { gap: 4px; }
    .bh-scope .bh-week span { text-align: center; padding: 0; font-size: 11px; letter-spacing: .08em; }
    .bh-scope .bh-week span { font-size: 0; }
    .bh-scope .bh-week span::first-letter { font-size: 11px; }
    .bh-scope .bh-cell { min-height: 58px; padding: 6px 2px; align-items: center; gap: 4px; border-radius: 12px; text-align: center; }
    .bh-scope .bh-cell-top { justify-content: center; }
    .bh-scope .bh-cell-num { font-size: 16px; }
    .bh-scope .bh-cell-n, .bh-scope .bh-av-more { display: none; }
    .bh-scope .bh-av-xs { width: 18px; height: 18px; border-width: 1.5px; font-size: 0; }
    .bh-scope .bh-av-xs:nth-child(n+3) { display: none; }
    .bh-scope .bh-av-xs + .bh-av-xs { margin-left: -6px; }
    .bh-scope .bh-body { padding: 24px 16px 8px; gap: 28px; }
    .bh-scope .bh-day-title { font-size: 24px; }
    .bh-scope .bh-people { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px 8px; }
    .bh-scope .bh-frame { width: 84px; height: 84px; padding: 4px; }
    .bh-scope .bh-av { font-size: 26px; }
    .bh-scope .bh-fav { top: -4px; right: -6px; width: 30px; height: 30px; }
    .bh-scope .bh-name { font-size: 15px; }
    .bh-scope .bh-person .bh-acts { gap: 6px; }
    .bh-scope .bh-person .bh-ic { width: 44px; height: 44px; }
    .bh-scope .bh-twin-pick select { height: 44px; font-size: 16px; }
    .bh-scope .bh-up-row { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; margin: 0 -16px; padding: 0 16px 8px; }
    .bh-scope .bh-up-card { flex: 0 0 78%; scroll-snap-align: start; }
    .bh-scope .bh-faq { padding-top: 32px; padding-bottom: 40px; }
    .bh-scope .bh-faq-h { font-size: 30px; }
    .bh-scope .bh-qa summary { padding: 16px 2px; font-size: 16px; }
    .bh-scope .bh-qa p { padding: 0 8px 18px 2px; font-size: 15px; }
    .bh-scope .bh-dialog { width: 100%; max-width: 100%; margin: auto 0 0; border-radius: 24px 24px 0 0; border: 0; box-shadow: 0 -20px 50px rgba(21,23,40,.25); }
}

/* 44px thumb targets (the site's pointer:coarse rule, kept local to this page). */
@media (pointer: coarse) {
    html .bh-scope .bh-seg button { min-height: 44px; }
    html .bh-scope .bh-fav, html .bh-scope .bh-fav-sm { min-width: 44px; min-height: 44px; }
    html .bh-scope .bh-ic, html .bh-scope .bh-round { min-width: 44px; min-height: 44px; }
}

/* ===================================================================
   Birthday moments outside the hub (same sheet, linked once by
   templates/partials/birthday_assets.php).
   =================================================================== */

/* /title/{slug} — one slim strip atop Overview ---------------------- */
.bh-scope.bh-strip { display: flex; align-items: center; gap: 12px; margin: 0 0 22px; padding: 8px 8px 8px 12px; min-height: 52px; background: #fff; border: 1px solid var(--bh-line); border-radius: 14px; box-shadow: inset 3px 0 0 var(--bh-gold), 0 1px 3px rgba(21,23,40,.05); }
.bh-scope .bh-strip-faces { display: flex; flex: none; }
.bh-scope .bh-strip-face { display: inline-flex; width: 36px; height: 36px; border-radius: 50%; box-shadow: none; padding: 3px !important; }
.bh-scope .bh-strip-face + .bh-strip-face { margin-left: -10px; }
.bh-scope .bh-strip-face img, .bh-scope .bh-strip-face > span { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; border: 2px solid #fff; box-sizing: border-box; }
.bh-scope .bh-strip-face > span { display: flex; align-items: center; justify-content: center; background: linear-gradient(155deg, var(--bh-gold), var(--bh-red)); color: #fff; font-size: 10px; font-weight: 800; }
.bh-scope .bh-strip-txt { flex: 1; min-width: 0; margin: 0; font-size: 15px; font-weight: 600; line-height: 1.35; color: var(--bh-ink-2); }
.bh-scope .bh-strip-name { font-weight: 800; color: var(--bh-ink); }
.bh-scope a.bh-strip-name, .bh-scope .bh-strip-more { color: var(--bh-red); text-decoration: none; font-weight: 800; }
.bh-scope .bh-strip-more { white-space: nowrap; }
.bh-scope a.bh-strip-name:hover, .bh-scope .bh-strip-more:hover { text-decoration: underline; }
.bh-scope .bh-strip-n { margin-left: 6px; font-family: var(--bh-mono); font-size: 12px; font-weight: 400; color: var(--bh-faint); white-space: nowrap; }
.bh-scope .bh-strip-wish { flex: none; display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 14px; border-radius: 999px; border: 0; background: var(--bh-red); color: #fffdf8; font-family: var(--bh-text); font-weight: 800; font-size: 13px; cursor: pointer; text-decoration: none; white-space: nowrap; transition: background 120ms, transform 120ms var(--bh-ease); }
.bh-scope .bh-strip-wish:hover { background: var(--bh-red-dark); color: #fffdf8; }
.bh-scope .bh-strip-wish:active { transform: scale(.96); }
.bh-scope .bh-strip-wish.is-wished { background: var(--bh-gold-soft); color: var(--bh-gold-ink); cursor: default; }

/* /character + /staff — the portrait is the surface ----------------
   Sparkle frame around it, a speech bubble from its corner, a wish bar
   sitting on its bottom edge. Nothing below it, so the hero never moves. */
.bh-portrait-frame { position: relative; padding: 7px; border-radius: 20px; background: repeating-conic-gradient(from var(--r, 0deg), #fdc949 0 4deg, #fff 4deg 14deg); box-shadow: 0 8px 26px rgba(253,201,73,.5); margin-bottom: 18px; }
.bh-portrait-frame > div:first-of-type { border-radius: 14px !important; }

.bh-scope .bh-bubble { position: absolute; z-index: 4; top: -18px; right: -30px; width: max-content; max-width: 220px; padding: 9px 13px; background: #fff; color: var(--bh-ink); border: 2px solid var(--bh-ink); border-radius: 16px 16px 16px 4px; box-shadow: 3px 3px 0 var(--bh-red); transform: rotate(3deg); transform-origin: 0 100%; animation: bh-pop .5s var(--bh-ease) .3s both; }
.bh-scope .bh-bubble::after { content: ''; position: absolute; left: 10px; bottom: -9px; width: 14px; height: 14px; background: #fff; border-right: 2px solid var(--bh-ink); border-bottom: 2px solid var(--bh-ink); transform: rotate(45deg) skew(12deg, 12deg); }
.bh-scope .bh-bubble-line { display: none; margin: 0; font-family: var(--bh-display); font-style: italic; font-weight: 700; font-size: 15px; line-height: 1.25; overflow-wrap: anywhere; }
.bh-scope .bh-bubble-line:first-child { white-space: nowrap; }
.bh-scope .bh-bubble-line.is-on { display: block; animation: bh-in .3s var(--bh-ease); }
.bh-scope .bh-bubble-line.is-wish { font-family: var(--bh-text); font-style: normal; font-weight: 600; font-size: 13.5px; padding-right: 14px; position: relative; }
.bh-scope .bh-bubble-by { display: block; font-family: var(--bh-mono); font-size: 11px; font-weight: 400; color: var(--bh-faint); }
.bh-scope .bh-bubble-x { position: absolute; top: -2px; right: -4px; border: 0; background: none; color: var(--bh-faint); font-size: 16px; line-height: 1; cursor: pointer; padding: 2px; }
@keyframes bh-pop { from { opacity: 0; transform: rotate(3deg) scale(.6); } to { opacity: 1; transform: rotate(3deg) scale(1); } }

.bh-scope .bh-wishbar { position: absolute; z-index: 4; left: 50%; bottom: -21px; transform: translateX(-50%); display: flex; align-items: center; gap: 6px; padding: 4px 5px 4px 4px; background: var(--bh-ink); border: 2px solid var(--bh-gold); border-radius: 999px; box-shadow: 0 10px 24px rgba(0,0,0,.45); white-space: nowrap; }
.bh-scope .bh-wb-wish { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 13px; border-radius: 999px; border: 0; background: var(--bh-red); color: #fffdf8; font-family: var(--bh-text); font-weight: 800; font-size: 13px; cursor: pointer; text-decoration: none; transition: background 120ms, transform 120ms var(--bh-ease); }
.bh-scope .bh-wb-wish:hover { background: var(--bh-red-dark); color: #fffdf8; }
.bh-scope .bh-wb-wish:active { transform: scale(.95); }
.bh-scope .bh-wb-wish.is-wished { background: var(--bh-gold); color: var(--bh-ink); cursor: default; }
.bh-scope .bh-wb-n { padding: 0 4px; font-family: var(--bh-mono); font-size: 12px; color: rgba(255,255,255,.82); }
.bh-scope .bh-wb-ic { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 50%; border: 1.5px solid rgba(255,255,255,.25); background: transparent; color: #fff; cursor: pointer; }
.bh-scope .bh-wb-ic:hover { border-color: var(--bh-gold); color: var(--bh-gold); }
.bh-scope .bh-wb-ic[aria-pressed="true"] { color: var(--bh-red); border-color: var(--bh-red); background: #fff; }
.bh-scope .bh-wb-ic[aria-pressed="true"] svg { fill: currentColor; }

@media (max-width: 640px) {
    /* Phone strip: faces · text · the hub's round cake button (icon only). */
    .bh-scope.bh-strip { gap: 10px; padding: 8px 8px 8px 10px; }
    .bh-scope .bh-strip-face { width: 46px; height: 46px; }
    .bh-scope .bh-strip-face + .bh-strip-face { margin-left: -16px; }
    .bh-scope .bh-strip-txt { font-size: 14px; }
    .bh-scope .bh-strip-n { display: block; margin: 2px 0 0; }
    .bh-scope .bh-strip-wish { width: 44px; height: 44px; padding: 0; justify-content: center; border-radius: 50%; box-shadow: 0 5px 14px rgba(202,33,40,.28); }
    .bh-scope .bh-strip-wish svg { width: 18px; height: 18px; }
    .bh-scope .bh-strip-wish [data-lbl] { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
    .bh-scope .bh-strip-wish.is-wished { box-shadow: none; border: 1.5px solid var(--bh-gold); }
    /* Bubble: centred above the portrait, with room reserved so it never reaches the header. */
    .bh-portrait-frame { margin-top: 44px; }
    .bh-scope .bh-bubble { right: auto; left: 50%; top: -40px; max-width: calc(100vw - 32px); transform: translateX(-50%) rotate(-2deg); animation: none; }
    .bh-scope .bh-bubble-line { font-size: 13.5px; }
}
@media (pointer: coarse) {
    html .bh-scope .bh-strip-wish, html .bh-scope .bh-wb-wish { min-height: 44px; }
    html .bh-scope .bh-wb-ic { min-width: 44px; min-height: 44px; }
}
