.overlay { position: fixed; inset: 0; z-index: 20; background: var(--color-overlay); display: flex; align-items: flex-end; justify-content: center; padding: 0; }
.overlay.center { align-items: center; padding: var(--space-16); }
.sheet { width: 100%; max-width: 520px; max-height: 94vh; overflow-y: auto; background: var(--color-surface); border-radius: var(--radius-card) var(--radius-card) 0 0; padding: var(--space-24) var(--space-16) var(--space-16); box-shadow: var(--shadow-card); }
.overlay.center .sheet { border-radius: var(--radius-card); max-width: 400px; }
@media (min-width: 640px) { .overlay { align-items: center; padding: var(--space-16); } .sheet { border-radius: var(--radius-card); padding: var(--space-24); } }
.sheet-head { display: flex; align-items: center; justify-content: space-between; gap: var(--space-12); margin-bottom: var(--space-16); }
.sheet-head h2 { margin: 0; font-weight: 700; font-size: 24px; line-height: 1.3; }
.confirm p { margin: 0 0 var(--space-16); color: var(--color-text-muted); }
.confirm h2 { margin: 0 0 var(--space-8); font-weight: 700; font-size: 24px; line-height: 1.3; }
/* new numbers for a track (RateChange) */
.sheet.confirm .rc-name, .sheet.confirm .rc-note { display: block; }
.sheet.confirm .rc-name { margin-top: var(--space-8); font-weight: 700; }
.sheet.confirm .rc-note { margin-top: var(--space-12); }

/* the "שימו לב" part of a save popup (FitCheck) */
.sheet.confirm .fit { display: block; margin-top: var(--space-12); padding: 12px 14px; border-radius: 18px; background: var(--surface-1); text-align: start; font-size: 13.5px; line-height: 1.5; }
.fit-title { display: block; margin-bottom: var(--space-4); font-size: 14px; color: var(--date-label); }
.fit-text strong { color: var(--text-primary); }
.fit .bd-form { margin-top: 10px; }
.fit .bd-ledger { display: block; }
.fit .bd-fl { min-height: 48px; }
.fit-state { display: block; margin-top: var(--space-8); font-weight: 700; }
.fit-state.ok { color: var(--accent-mint); }
.fit-state.neg { color: var(--color-error); }
.sheet.confirm #cf-yes:disabled { opacity: .4; cursor: default; }

/* "?" next to a page title, and the explanation popup it opens (GoalsHelp) */
.title-help { display: flex; align-items: center; gap: 10px; min-width: 0; }
.help-btn { width: 26px; height: 26px; flex: none; padding: 0; border: 0; border-radius: 50%; background: var(--accent-gold); color: #17222e; font: inherit; font-size: 15px; font-weight: 700; line-height: 1; cursor: pointer; }
@media (min-width: 640px) { .sheet.help { max-width: 720px; } }
.gh-tabs { display: flex; gap: 4px; padding: 4px; margin-bottom: var(--space-12); border-radius: 14px; background: var(--bg-app); }
.gh-tabs button { flex: 1; min-height: 40px; border: 0; border-radius: 11px; background: none; color: var(--color-text-muted); font: inherit; font-weight: 600; cursor: pointer; }
.gh-tabs button[aria-selected="true"] { background: #7ee3c8; color: #0f2b22; }
.gh-panel { margin-bottom: var(--space-12); }
.gh-frame { position: relative; margin: 0 auto var(--space-12); direction: ltr; }
.gh-copy { position: absolute; top: 0; left: 0; transform-origin: top left; direction: rtl; pointer-events: none; }
.gh-n { display: inline-grid; place-items: center; flex: none; width: 20px; height: 20px; border-radius: 50%; background: var(--accent-gold); color: #17222e; font-size: 12px; font-weight: 700; line-height: 1; }
.gh-mark { position: absolute; z-index: 2; margin: -10px 0 0 -10px; box-shadow: 0 2px 6px rgba(0, 0, 0, 0.55); }
.gh-list { list-style: none; margin: 0; padding: 0; }
.gh-list li { display: flex; align-items: flex-start; gap: 9px; padding: 5px 0; font-size: 14px; line-height: 1.45; }
.gh-example { margin: 0 0 var(--space-12); text-align: center; }
.gh-example figcaption { margin-bottom: var(--space-8); font-size: 13px; color: var(--color-text-muted); }
.gh-example figcaption b { color: var(--accent-gold); }
.gh-example img { display: block; margin: 0 auto; max-width: 100%; max-height: 42vh; border-radius: 12px; }
