/* One quiet card; detailed charts stay behind the native disclosure. */
.home-review{--hrv-ink:var(--accent,#de7786);--hrv-text:var(--shell-text,#303644);--hrv-muted:var(--shell-muted,#737a87);--hrv-line:var(--shell-line,#e6e5e3);--hrv-soft:var(--shell-soft,#f4f3f1);grid-column:1/-1;box-sizing:border-box;width:100%;min-width:0;padding:14px 16px;margin:0 0 12px;color:var(--hrv-text);font-family:var(--home-font,Pretendard,sans-serif);text-align:left;border:1px solid var(--hrv-line);border-radius:var(--shell-radius,16px);background:var(--shell-surface,#fffefd);box-shadow:var(--shell-shadow,0 4px 20px rgb(34 42 56 / 5%))}
:is(.home-review,.home-routine-history) *{box-sizing:border-box}
:is(.home-review,.home-routine-history) button,:is(.home-review,.home-routine-history) select{font-family:inherit;-webkit-tap-highlight-color:transparent}
:is(.home-review,.home-routine-history) button{cursor:pointer}
:is(.home-review,.home-routine-history) :is(button,select,summary):focus-visible{outline:2px solid var(--hrv-ink);outline-offset:3px;border-radius:4px}
:is(.home-review,.home-routine-history) svg{display:block;width:18px;height:18px;flex:none}
:is(.home-review,.home-routine-history) .hrv-summary{list-style:none;display:grid;grid-template-rows:auto auto auto;gap:8px;min-height:108px;padding:0;cursor:pointer;touch-action:manipulation}
:is(.home-review,.home-routine-history) .hrv-summary::-webkit-details-marker{display:none}
.hrv-heading{display:flex;align-items:center;gap:10px;min-height:20px}
.hrv-title{font-size:15px;font-weight:550;letter-spacing:-.025em}
.hrv-heading-rule{height:1px;flex:1;background:var(--hrv-line)}
.hrv-disclosure{display:flex;align-items:center;gap:4px;font-size:10px;color:var(--hrv-muted);white-space:nowrap}
.hrv-disclosure svg{width:15px;height:15px}
.hrv-open-label,.home-review[open] .hrv-closed-label{display:none}
.home-review[open] .hrv-open-label{display:inline}
.home-review[open] .hrv-disclosure svg{transform:rotate(180deg)}
.hrv-overview{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;min-width:0}
.hrv-execution{display:flex;flex-direction:column;gap:4px;min-width:0}
.hrv-execution+.hrv-execution{padding-left:16px;border-left:1px solid var(--hrv-line)}
.hrv-execution>span{font-size:11px;line-height:1.2;color:var(--hrv-muted)}
.hrv-execution>strong{display:flex;align-items:baseline;gap:2px;font-size:34px;line-height:1.05;letter-spacing:-.055em;font-weight:550;font-variant-numeric:tabular-nums;color:var(--hrv-text);white-space:nowrap}
.hrv-execution>strong small{font-size:10px;letter-spacing:0;font-weight:400;color:var(--hrv-muted);margin-right:3px}
.hrv-summary-stats{display:flex;align-items:baseline;gap:16px;font-size:10px;line-height:1.3;color:var(--hrv-muted);white-space:nowrap}
.hrv-summary-stats>span{display:flex;gap:5px;min-width:0}
.hrv-summary-stats b{font-weight:450;color:var(--hrv-text)}
.hrv-expanded{padding:12px 0 2px}
.hrv-tabs{display:flex;gap:4px;border-bottom:1px solid var(--hrv-line);margin-bottom:14px}
:is(.home-review,.home-routine-history) .hrv-tabs button{flex:1;min-height:38px;padding:6px 8px;margin:0 0 -1px;border:0;border-bottom:2px solid transparent;border-radius:0;background:transparent;font-size:12px;font-weight:450;color:var(--hrv-muted)}
:is(.home-review,.home-routine-history) .hrv-tabs button[aria-selected="true"]{border-bottom-color:var(--hrv-ink);color:var(--hrv-text);font-weight:600}
.hrv-panel{min-width:0}
.hrv-load-status,:is(.home-review,.home-routine-history) .hrv-load-retry{display:block;margin:0 0 12px;padding:0;border:0;background:transparent;color:var(--hrv-muted);font-size:10px;line-height:1.5;text-align:left}
:is(.home-review,.home-routine-history) .hrv-load-retry{min-height:32px;text-decoration:underline;text-underline-offset:3px}
.hrv-panel-heading{display:flex;align-items:center;justify-content:space-between;gap:10px;margin:0 0 12px;font-size:11px;color:var(--hrv-muted);font-variant-numeric:tabular-nums}
.hrv-panel-heading b{color:var(--hrv-text);font-weight:500}
.hrv-chart-key{display:flex;align-items:center;gap:4px;font-size:10px}
.hrv-chart-key i{width:8px;height:8px;border-radius:2px;display:block;background:var(--hrv-line)}
.hrv-chart-key i.is-actual{margin-left:7px;background:var(--hrv-ink)}
.hrv-week-chart{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:5px;min-width:0}
:is(.home-review,.home-routine-history) .hrv-week-day{display:flex;flex-direction:column;align-items:stretch;gap:6px;min-width:0;border:0;border-radius:3px;padding:3px 0 5px;background:transparent;color:var(--hrv-text);font-size:10px}
.hrv-week-value{min-height:14px;color:var(--hrv-muted);font-size:9px;line-height:1.35;overflow-wrap:anywhere;font-variant-numeric:tabular-nums}
.hrv-bars{height:95px;display:flex;align-items:flex-end;justify-content:center;gap:3px;border-bottom:1px solid var(--hrv-line)}
.hrv-bars>i{display:block;width:25%;max-width:20px;border-radius:3px 3px 0 0;min-height:0;background:var(--hrv-line)}
.hrv-bars>.hrv-actual-bar{background:var(--hrv-ink)}
.is-unknown .hrv-bars{background:repeating-linear-gradient(135deg,transparent 0 5px,color-mix(in srgb,var(--hrv-line) 60%,transparent) 5px 6px)}
.hrv-week-label{display:flex;align-items:baseline;justify-content:center;gap:3px;color:var(--hrv-muted)}
.hrv-week-label small{font-size:9px}
.hrv-week-day.is-today .hrv-week-label{color:var(--hrv-ink);font-weight:600}
.hrv-week-day.is-future .hrv-week-label{opacity:.5}
.hrv-note{margin:12px 0 0;font-size:10px;line-height:1.55;color:var(--hrv-muted);word-break:keep-all}
.hrv-trends{margin-top:18px;padding-top:14px;border-top:1px solid var(--hrv-line)}
.hrv-small-chart{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:5px;min-width:0}
.hrv-trend-chart{grid-template-columns:repeat(12,minmax(0,1fr));gap:4px}
.hrv-small-day{display:flex;flex-direction:column;min-width:0;gap:5px;text-align:center}
.hrv-small-track{display:flex;align-items:flex-end;justify-content:center;height:48px;border-bottom:1px solid var(--hrv-line)}
.hrv-small-track>i{display:block;width:62%;max-width:24px;min-height:0;border-radius:2px 2px 0 0;background:color-mix(in srgb,var(--hrv-ink) 65%,var(--hrv-soft))}
.hrv-trend-chart .hrv-small-track{height:54px}
.hrv-small-label{display:block;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;font-size:9px;color:var(--hrv-muted);line-height:1.3}
.hrv-small-label.is-muted{visibility:hidden}
.hrv-small-day.is-unknown .hrv-small-track{background:repeating-linear-gradient(135deg,transparent 0 5px,var(--hrv-line) 5px 6px)}
.hrv-fold{margin:14px 0 0;border-top:1px solid var(--hrv-line)}
:is(.home-review,.home-routine-history) .hrv-fold>summary{display:flex;align-items:center;justify-content:space-between;gap:12px;min-height:44px;padding:6px 0;font-size:11px;font-weight:450;list-style:none;color:var(--hrv-text);cursor:pointer;touch-action:manipulation}
:is(.home-review,.home-routine-history) .hrv-fold>summary::-webkit-details-marker{display:none}
:is(.home-review,.home-routine-history) .hrv-fold>summary>svg{width:14px;height:14px;color:var(--hrv-muted)}
:is(.home-review,.home-routine-history) .hrv-fold[open]>summary>svg{transform:rotate(180deg)}
.hrv-fold-body{padding:4px 0 6px;min-width:0}
.hrv-panel-heading>small{font-size:9px;font-weight:400;color:var(--hrv-muted)}
.hrv-hour-heading{margin-top:20px;margin-bottom:8px}
.hrv-hour-strip{display:grid;grid-template-columns:repeat(24,minmax(0,1fr));gap:2px}
.hrv-hour{height:16px;border-radius:2px;background:color-mix(in srgb,var(--hrv-ink) var(--hrv-strength),var(--hrv-soft))}
.hrv-hour.is-unknown{background:repeating-linear-gradient(135deg,var(--hrv-soft) 0 2px,var(--hrv-line) 2px 3px)}
.hrv-hour-labels{display:flex;justify-content:space-between;margin-top:5px;font-size:8px;color:var(--hrv-muted)}
.hrv-month-totals{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;margin:0 0 16px}
.hrv-month-totals>span{display:flex;flex-direction:column;gap:5px;font-size:10px;color:var(--hrv-muted)}
.hrv-month-totals b{font-size:15px;line-height:1.3;font-weight:500;color:var(--hrv-text);overflow-wrap:anywhere;font-variant-numeric:tabular-nums}
.hrv-month-totals b>small{font-size:9px;font-weight:400;color:var(--hrv-muted)}
.hrv-subjects{display:grid;gap:13px}
.hrv-subjects>.hrv-note{margin:0}
.hrv-subject{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:5px 12px;align-items:baseline}
.hrv-subject-title{display:flex;align-items:baseline;gap:6px;min-width:0;overflow-wrap:anywhere;font-size:11px;color:var(--hrv-text)}
.hrv-subject-title>small{font-size:8px;white-space:nowrap;color:var(--hrv-muted)}
.hrv-subject-time{font-size:10px;color:var(--hrv-muted);font-variant-numeric:tabular-nums}
.hrv-subject-track{grid-column:1/-1;display:block;height:4px;border-radius:1px;background:var(--hrv-soft)}
.hrv-subject-track>i{display:block;height:100%;border-radius:1px;background:var(--hrv-subject-color,var(--hrv-ink))}
.hrv-task-result{display:flex;justify-content:space-between;align-items:center;flex-wrap:wrap;gap:12px;margin-top:18px;padding-top:14px;border-top:1px solid var(--hrv-line);font-size:10px;color:var(--hrv-muted)}
.hrv-task-result>span>b{margin-left:5px;color:var(--hrv-text);font-size:14px;font-weight:500}
.hrv-marks{display:flex;gap:14px}
.hrv-marks>span{display:flex;align-items:center;gap:3px}
.hrv-marks>span>svg{width:13px;height:13px;color:var(--hrv-muted)}
.hrv-marks b{font-size:11px;font-weight:450;color:var(--hrv-text)}
.hrv-milestones{display:flex;gap:7px 18px;flex-wrap:wrap;margin-top:10px;padding-top:12px;border-top:1px solid var(--hrv-line)}
.hrv-milestones>span{display:flex;gap:7px;min-width:0;max-width:100%;font-size:10px;color:var(--hrv-muted)}
.hrv-milestones>span>span{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}
.hrv-milestones b{flex:none;color:var(--hrv-text);font-weight:500}
.hrv-month-calendar{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:4px;min-width:0}
.hrv-calendar-weekday{text-align:center;font-size:10px;color:var(--hrv-muted);padding:0 0 4px}
:is(.home-review,.home-routine-history) .hrv-calendar-day{position:relative;display:flex;flex-direction:column;align-items:flex-start;justify-content:space-between;gap:3px;min-width:0;min-height:44px;border:0;border-radius:4px;padding:5px;background:var(--hrv-soft);color:var(--hrv-text);text-align:left}
.hrv-calendar-day>span{font-size:11px;line-height:1}
.hrv-calendar-day>small{font-size:8px;line-height:1.2;color:var(--hrv-muted);overflow-wrap:anywhere}
:is(.home-review,.home-routine-history) .hrv-calendar-day.is-today{outline:1.5px solid var(--hrv-ink);outline-offset:-1.5px}
:is(.home-review,.home-routine-history) .hrv-calendar-day.is-future{background:transparent;color:var(--hrv-muted);opacity:.6}
:is(.home-review,.home-routine-history) .level-1{background:color-mix(in srgb,var(--hrv-ink) 14%,var(--hrv-soft))}
:is(.home-review,.home-routine-history) .level-2{background:color-mix(in srgb,var(--hrv-ink) 28%,var(--hrv-soft))}
:is(.home-review,.home-routine-history) .level-3{background:color-mix(in srgb,var(--hrv-ink) 44%,var(--hrv-soft))}
:is(.home-review,.home-routine-history) .level-4{background:color-mix(in srgb,var(--hrv-ink) 62%,var(--hrv-soft))}
.hrv-legend{display:flex;align-items:center;justify-content:flex-end;gap:4px;flex-wrap:wrap;margin-top:9px;font-size:9px;color:var(--hrv-muted)}
.hrv-legend>i{display:block;width:8px;height:8px;border-radius:1px;background:var(--hrv-soft)}
:is(.home-review,.home-routine-history) :is(.hrv-calendar-day,.hrv-legend>i,.hrv-heat-day).is-unknown{background:repeating-linear-gradient(135deg,var(--hrv-soft) 0 2px,var(--hrv-line) 2px 3px)}
.hrv-routine-records{display:grid;gap:16px;min-width:0}
.hrv-routine-record{min-width:0}
.hrv-routine-record+.hrv-routine-record{padding-top:14px;border-top:1px solid var(--hrv-line)}
.hrv-routine-heading{display:flex;align-items:center;gap:6px;min-width:0;margin:0 0 9px}
.hrv-routine-heading h3{margin:0;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:13px;font-weight:500;line-height:1.4;color:var(--hrv-text)}
.home-routine-history .hrv-routine-icon{display:grid;place-items:center;width:32px;height:32px;min-height:32px;padding:0;border:0;border-radius:50%;background:transparent;color:var(--hrv-ink);flex:none;touch-action:manipulation}
.home-routine-history .hrv-routine-icon svg{width:20px;height:20px}
.hrv-routine-totals{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;margin:0 0 10px}
.hrv-routine-totals>span{display:flex;flex-direction:column;gap:3px;color:var(--hrv-muted);font-size:9px}
.home-routine-history .hrv-routine-totals b{font-size:14px;line-height:1.2;font-weight:500;color:var(--hrv-text);font-variant-numeric:tabular-nums;white-space:nowrap}
.hrv-year-range{font-size:10px;margin-bottom:8px}
.hrv-heatmap{display:grid;grid-template-rows:repeat(7,minmax(0,1fr));grid-template-columns:repeat(53,minmax(0,1fr));grid-auto-flow:column;gap:2px;width:100%;max-width:740px;min-width:0}
:is(.home-review,.home-routine-history) .hrv-heat-day,.hrv-heat-pad{display:block;width:100%;min-width:0;min-height:0;aspect-ratio:1;max-height:12px;margin:0;padding:0;border:0;border-radius:1px;background:var(--hrv-soft)}
:is(.home-review,.home-routine-history) .hrv-heat-day:is(.is-done,.is-partial){background:color-mix(in srgb,var(--hrv-routine-color,var(--hrv-ink)) var(--hrv-strength),var(--hrv-soft))}
:is(.home-review,.home-routine-history) .hrv-heat-day.is-off,.hrv-legend>i.is-off{background:transparent;box-shadow:inset 0 0 0 1px var(--hrv-line)}
:is(.home-review,.home-routine-history) .hrv-heat-pad{visibility:hidden}
.hrv-legend>i.is-done{background:var(--hrv-ink)}
.hrv-legend>i.is-partial{background:color-mix(in srgb,var(--hrv-ink) 45%,var(--hrv-soft))}
:is(.home-review,.home-routine-history) .hrv-heat-day:focus-visible{outline-offset:1px;position:relative;z-index:1}
.hrv-empty{margin:0;padding:16px 0;color:var(--hrv-muted);font-size:12px;line-height:1.6}
@media(max-width:359px){.hrv-execution>strong{font-size:29px}.hrv-execution+.hrv-execution{padding-left:10px}.hrv-overview{gap:10px}.hrv-summary-stats{gap:10px;font-size:9px}.hrv-heatmap{gap:1px}.hrv-routine-totals b{font-size:18px}:is(.home-review,.home-routine-history) .hrv-calendar-day{padding:4px 3px}.hrv-calendar-day>small{font-size:7px}.hrv-month-totals b{font-size:13px}.hrv-hour-strip{gap:1px}}
@media(prefers-reduced-motion:reduce){:is(.home-review,.home-routine-history) *{scroll-behavior:auto}}
html body #calView>.st>.home-review{padding:14px 16px;margin:0 0 12px;border:1px solid var(--hrv-line);border-radius:16px;background:var(--shell-surface,#fffefd)}

/* Routine history shares the existing card rather than adding another card. */
.home-routine-history{--hrv-ink:var(--accent,#de7786);--hrv-text:var(--shell-text,#303644);--hrv-muted:var(--shell-muted,#737a87);--hrv-line:var(--shell-line,#e6e5e3);--hrv-soft:var(--shell-soft,#f4f3f1);min-width:0;padding-top:7px;color:var(--hrv-text);font-family:var(--home-font,Pretendard,sans-serif);text-align:left}
.hrv-routine-panel{min-width:0}
/* Every weekday keeps the same value, bar and date rows. */
.home-review .hrv-week-day{display:grid;grid-template-rows:16px 78px 18px;align-content:start;gap:5px}
.hrv-week-value{height:16px;min-height:16px;display:flex;align-items:center;justify-content:center;white-space:nowrap;overflow-wrap:normal;font-size:9px}
.hrv-bars{height:78px}
.hrv-week-label{align-self:center}
.hrv-trends{margin-top:14px;padding-top:12px}
.hrv-trend-chart .hrv-small-track{height:42px}
/* Compact month cells keep dates readable while using less vertical space. */
.hrv-panel .hrv-month-totals{gap:8px;margin-bottom:10px}
.hrv-panel .hrv-month-totals>span{gap:3px}
.hrv-panel .hrv-month-totals b{font-size:13px;line-height:1.2}
.hrv-panel .hrv-month-calendar{gap:3px}
.home-review .hrv-calendar-day{height:34px;min-height:34px;padding:4px}
.hrv-calendar-day>span{font-size:10px}
.hrv-calendar-day>small{font-size:7px;line-height:1;white-space:nowrap;overflow-wrap:normal}
.hrv-panel .hrv-calendar-weekday{font-size:9px;padding-bottom:2px}
.hrv-panel .hrv-panel-heading{margin-bottom:10px}
.hrv-panel .hrv-fold{margin-top:10px}
.home-review .hrv-fold>summary{min-height:38px;padding:5px 0}
.hrv-panel .hrv-legend{margin-top:7px;font-size:8px}

/* 10/14 루틴 1년 기록: 아이콘·이름·숫자를 한 줄에, 표는 그 아래 — 여러 루틴이 한눈에 */
.home-routine-history .hrv-routine-records{gap:10px}
.home-routine-history .hrv-routine-record{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;column-gap:10px}
.home-routine-history .hrv-routine-record+.hrv-routine-record{padding-top:10px}
.home-routine-history .hrv-routine-heading{margin:0}
.home-routine-history .hrv-routine-totals{display:flex;justify-content:flex-end;gap:10px;margin:0}
.home-routine-history .hrv-routine-totals>span{flex-direction:row;align-items:baseline;gap:3px;font-size:10px;white-space:nowrap}
.home-routine-history .hrv-routine-totals b{font-size:13px}
.home-routine-history .hrv-heatmap{grid-column:1/-1;margin-top:6px}
