/* Present mode (present.js) + scheduled report panel (schedule-ui.js). Brand colors arrive as --pr-* variables. */
html.pr-open, html.pr-open body { overflow: hidden; }
.pr { position: fixed; inset: 0; z-index: 9000; background: var(--pr-paper); color: var(--pr-ink); font-family: var(--pr-body), system-ui, sans-serif; height: 100vh; height: 100dvh; overflow: hidden; touch-action: pan-y; user-select: none; -webkit-user-select: none; }
.pr-bar { position: absolute; left: 0; right: 0; top: 0; height: 5px; background: color-mix(in srgb, var(--pr-ink) 10%, transparent); z-index: 3; }
.pr-bar i { display: block; height: 100%; width: 0; background: var(--pr-accent); transition: width .45s cubic-bezier(.2, .8, .2, 1); }
.pr-stage { position: absolute; inset: 5px 0 64px; }
.pr-slide { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; padding: 2vh 3vw; transition: opacity .45s ease, transform .55s cubic-bezier(.2, .8, .2, 1); }
.pr-slide.from-r { opacity: 0; transform: translateX(6vw); }
.pr-slide.from-l { opacity: 0; transform: translateX(-6vw); }
.pr-slide.out { opacity: 0; transform: scale(.97); pointer-events: none; }
.pr-chart { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; }
.pr-chart svg { width: auto; height: auto; max-width: 100%; max-height: 100%; display: block; border-radius: 6px; }
.pr-hit { position: absolute; top: 5px; bottom: 64px; width: 18%; z-index: 2; cursor: pointer; }
.pr-hit-l { left: 0; cursor: w-resize; }
.pr-hit-r { right: 0; cursor: e-resize; }

/* chart entrance (same keyframes as story.js) */
.pr-chart.go path.sp-line { animation: pr-draw 1.4s ease forwards; }
.pr-chart.go[data-type=column] rect[data-tip], .pr-chart.go[data-type=stacked] rect[data-tip], .pr-chart.go[data-type=grouped] rect[data-tip], .pr-chart.go[data-type=combo] rect[data-tip], .pr-chart.go[data-type=waterfall] rect[data-tip] { transform-box: fill-box; transform-origin: 50% 100%; animation: pr-growY .9s cubic-bezier(.2, .8, .2, 1) both; }
.pr-chart.go[data-type=bar] rect[data-tip], .pr-chart.go[data-type=lollipop] line, .pr-chart.go[data-type=kpi] rect[data-tip] { transform-box: fill-box; transform-origin: 0 50%; animation: pr-growX .9s cubic-bezier(.2, .8, .2, 1) both; }
.pr-chart.go[data-type=donut] path[data-tip], .pr-chart.go[data-type=map] path[data-tip], .pr-chart.go[data-type=radial] path[data-tip], .pr-chart.go[data-type=treemap] rect[data-tip], .pr-chart.go[data-type=heatmap] rect[data-tip], .pr-chart.go circle[data-tip], .pr-chart.go[data-type=lollipop] circle { animation: pr-pop .7s ease both; }
.pr-chart.go [data-tip]:nth-of-type(2n) { animation-delay: .08s; } .pr-chart.go [data-tip]:nth-of-type(3n) { animation-delay: .16s; } .pr-chart.go [data-tip]:nth-of-type(5n) { animation-delay: .24s; }
@keyframes pr-draw { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
@keyframes pr-growY { from { transform: scaleY(0); } to { transform: scaleY(1); } }
@keyframes pr-growX { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@keyframes pr-pop { from { opacity: 0; transform: scale(.6); } to { opacity: 1; transform: none; } }
@keyframes pr-rise { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }

/* title slide */
.pr-cover { max-width: 1000px; width: 100%; padding: 0 4vw; }
.pr-cover > * { opacity: 0; }
.pr-cover.go > * { animation: pr-rise .8s cubic-bezier(.2, .8, .2, 1) both; }
.pr-cover.go > :nth-child(2) { animation-delay: .1s; } .pr-cover.go > :nth-child(3) { animation-delay: .2s; } .pr-cover.go > :nth-child(4) { animation-delay: .4s; }
.pr-cover h1 { font-family: var(--pr-head), Georgia, serif; font-size: clamp(36px, 7vw, 92px); line-height: 1.04; margin: 18px 0 16px; letter-spacing: -.02em; color: var(--pr-ink); }
.pr-cover h1::after { content: ""; display: block; width: 84px; height: 6px; margin-top: 24px; border-radius: 3px; background: var(--pr-accent); }
.pr-eye { font-size: 14px; letter-spacing: .16em; text-transform: uppercase; font-weight: 700; opacity: .75; display: flex; align-items: center; gap: 10px; margin: 0; }
.pr-eye i { width: 10px; height: 10px; border-radius: 50%; background: var(--pr-accent); }
.pr-logo { max-height: 56px; max-width: 240px; display: block; }
.pr-sub { font-size: clamp(16px, 2vw, 22px); opacity: .7; margin: 0; }
.pr-hint { margin-top: 40px; font-size: 13px; letter-spacing: .12em; text-transform: uppercase; opacity: .5; }

/* controls */
.pr-ui { position: absolute; left: 0; right: 0; bottom: 0; height: 64px; display: flex; align-items: center; justify-content: center; gap: 10px; z-index: 4; padding: 0 12px; }
.pr-btn { font: 600 15px/1 var(--pr-body), system-ui, sans-serif; color: var(--pr-ink); background: color-mix(in srgb, var(--pr-ink) 8%, transparent); border: 0; border-radius: 999px; min-width: 44px; height: 44px; padding: 0 14px; cursor: pointer; }
.pr-btn:hover:not([disabled]) { background: color-mix(in srgb, var(--pr-ink) 16%, transparent); }
.pr-btn[disabled] { opacity: .3; cursor: default; }
.pr-btn:focus-visible { outline: 3px solid var(--pr-accent); outline-offset: 2px; }
.pr-btn[aria-pressed=true] { background: var(--pr-accent); color: var(--pr-paper); }
.pr-txt { font-size: 13px; }
.pr-count { font: 700 14px/1 var(--pr-body), system-ui, sans-serif; letter-spacing: .08em; min-width: 64px; text-align: center; font-variant-numeric: tabular-nums; }
.pr-notes { position: absolute; left: 50%; bottom: 72px; transform: translate(-50%, 16px); width: min(760px, calc(100% - 24px)); background: var(--pr-ink); color: var(--pr-paper); border-radius: 14px; padding: 14px 18px; z-index: 5; opacity: 0; pointer-events: none; transition: opacity .25s, transform .25s; box-shadow: 0 12px 40px rgba(0, 0, 0, .25); }
.pr-notes b { font-size: 11px; letter-spacing: .14em; text-transform: uppercase; opacity: .7; }
.pr-notes p { margin: 6px 0 0; font-size: 16px; line-height: 1.5; user-select: text; -webkit-user-select: text; }
.pr.notes-on .pr-notes { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
@media (max-width: 600px) {
  .pr-stage { inset: 5px 0 60px; } .pr-ui { height: 60px; gap: 6px; } .pr-hit { bottom: 60px; }
  .pr-slide { padding: 8px; } .pr-txt { padding: 0 10px; } .pr-notes { bottom: 66px; } .pr-notes p { font-size: 15px; }
}
@media (prefers-reduced-motion: reduce) {
  .pr-slide, .pr-bar i { transition: opacity .2s; transform: none !important; }
  .pr-chart.go *, .pr-cover.go > * { animation: none !important; opacity: 1; }
}

/* ---------- 📬 scheduled report panel ---------- */
.sched { margin-top: 16px; }
.sched h4 { display: flex; align-items: center; gap: 6px; }
.sched-test { background: #FFF2C2; color: #6B5000; border-radius: 8px; padding: 8px 10px; font-size: 12.5px; font-weight: 600; margin: 0 0 10px; }
.sched-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 8px 0; }
.sched-grid label, .sched-f { display: grid; gap: 4px; font-size: 12px; font-weight: 600; }
.sched-f { margin: 8px 0; }
.sched select, .sched input, .sched textarea { width: 100%; box-sizing: border-box; font: inherit; font-weight: 400; font-size: 13px; padding: 7px 8px; border-radius: 8px; border: 1px solid var(--line, #d9d4ca); background: #fff; color: inherit; }
.sched textarea { resize: vertical; min-height: 54px; }
.sched-row { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.sched-status { font-size: 12.5px; margin: 10px 0 0; padding: 8px 10px; border-radius: 8px; background: rgba(0, 0, 0, .04); line-height: 1.45; }
.sched-status.ok b { color: #1D7A46; } .sched-status.bad b { color: #B3261E; }
.sched-hist { margin: 6px 0 0; padding: 0; list-style: none; font-size: 12px; opacity: .8; }
.sched-hist li { padding: 2px 0; }
.sched-modal { position: fixed; inset: 0; z-index: 8000; background: rgba(23, 20, 15, .55); display: grid; place-items: center; padding: 16px; }
.sched-modal > div { background: #fff; border-radius: 14px; width: min(700px, 100%); height: min(88vh, 1000px); display: flex; flex-direction: column; overflow: hidden; }
.sched-modal header { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 14px; border-bottom: 1px solid #eee; font-size: 13px; }
.sched-modal iframe { flex: 1; border: 0; width: 100%; background: #EFECE6; }
