/* PikLab calendar: existing brand tokens, no extra fonts or UI dependencies. */
.ch-calendar { scroll-margin-top:100px; }
/* Decorative per-day tones, shared by month chips and the day agenda. */
.ch-calendar [data-tone="0"] { --event-bg:#edf3f8; --event-hover:#e2ecf4; --event-accent:#7898b2; }
.ch-calendar [data-tone="1"] { --event-bg:#f2eef8; --event-hover:#e9e2f3; --event-accent:#9a86b4; }
.ch-calendar [data-tone="2"] { --event-bg:#fbf0e8; --event-hover:#f6e5d8; --event-accent:#bf9476; }
.ch-calendar [data-tone="3"] { --event-bg:#eef4eb; --event-hover:#e2eddc; --event-accent:#8ba37c; }
.ch-cal-heading { display:flex; align-items:center; justify-content:space-between; gap:20px; margin-bottom:28px; }
.ch-cal-heading h2 { font-size:clamp(1.9rem,4vw,3.1rem); margin:0; }
.ch-cal-heading-actions { display:flex; align-items:center; flex-wrap:wrap; gap:14px; }
.ch-cal-share-pill { display:inline-flex; align-items:center; justify-content:center; width:32px; height:32px; padding:0; border:1px solid var(--gray-200); border-radius:999px; color:var(--navy); }
.ch-cal-share-pill:hover { background:var(--gray-100); }
.ch-cal-share-pill:disabled { cursor:wait; opacity:.7; }
.ch-cal-share-fallback { display:block; max-width:260px; margin-top:8px; font-size:.72rem; color:var(--navy); }
.ch-cal-share-fallback input { display:block; width:100%; min-width:0; margin-top:6px; padding:8px; border:1px solid var(--gray-200); border-radius:6px; font:inherit; color:var(--navy); background:white; }
.ch-cal-all { display:inline-flex; gap:9px; align-items:center; min-height:44px; font-size:.88rem; font-weight:600; }
.ch-cal-all:hover { text-decoration:underline; text-underline-offset:5px; }
.ch-cal-shell { display:grid; grid-template-columns:minmax(0,1.95fr) minmax(280px,1fr); border:1px solid var(--gray-200); border-radius:var(--radius-lg); overflow:hidden; background:white; box-shadow:0 10px 36px rgba(15,26,46,.05); }
.ch-cal-main { min-width:0; padding:0 22px; }
.ch-cal-toolbar { display:flex; align-items:center; justify-content:space-between; gap:12px; min-height:84px; }
.ch-cal-toolbar h3 { margin:0; font-family:var(--font-display); font-size:clamp(1.1rem,2vw,1.5rem); letter-spacing:-.03em; }
.ch-cal-controls { display:flex; align-items:center; gap:3px; }
.ch-cal-controls button { display:inline-flex; align-items:center; justify-content:center; min-width:44px; min-height:44px; border-radius:999px; color:var(--navy); }
.ch-cal-controls button:hover { background:var(--gray-100); }
.ch-cal-controls .ch-cal-today { border:1px solid var(--gray-200); padding:0 15px; margin-right:7px; min-height:36px; font-size:.76rem; font-weight:600; }
.ch-cal-table { width:100%; border-collapse:separate; border-spacing:0; table-layout:fixed; }
.ch-cal-table th { color:var(--warm-gray); font-weight:500; font-size:.68rem; text-align:left; height:32px; padding-left:10px; }
.ch-cal-table abbr { text-decoration:none; }
.ch-cal-table td { height:82px; vertical-align:top; border-top:1px solid var(--gray-100); padding:3px 2px; }
.ch-cal-cell { min-height:76px; height:100%; border-radius:8px; padding:3px 5px 6px; }
.ch-cal-day { display:flex; flex-direction:column; width:100%; min-height:32px; text-align:left; border-radius:6px; padding:2px 1px; color:var(--navy); }
.ch-cal-day:hover { background:var(--gray-100); }
.ch-cal-day-top { display:flex; justify-content:space-between; align-items:center; width:100%; margin-bottom:4px; }
.ch-cal-number { display:inline-flex; align-items:center; justify-content:center; width:26px; height:26px; border-radius:50%; font-size:.78rem; font-weight:600; }
.ch-cal-number.is-today { box-shadow:inset 0 0 0 1px var(--navy); }
.ch-cal-table .is-selected .ch-cal-cell { background:#f3f6df; box-shadow:inset 0 0 0 1px #dce7a0; }
.ch-cal-table .is-selected .ch-cal-number { background:var(--green); box-shadow:none; color:var(--navy); }
.ch-cal-count { color:var(--warm-gray); font-size:.58rem; padding-right:2px; }
.ch-cal-table .is-outside .ch-cal-number { color:var(--gray-300); }
.ch-cal-table .is-outside .ch-cal-cell-events { opacity:.5; }
.ch-cal-table .is-past:not(.is-selected) .ch-cal-number { font-weight:400; color:var(--warm-gray); }
.ch-cal-cell-events { width:100%; min-width:0; display:grid; gap:4px; }
.ch-cal-cell-event { display:block; overflow:hidden; white-space:nowrap; text-overflow:ellipsis; font-size:.6rem; line-height:1.25; color:var(--navy); background:var(--event-bg); border-left:2px solid var(--event-accent); border-radius:4px; padding:3px 4px; }
.ch-cal-cell-event b { font-weight:600; }
.ch-cal-cell-event:hover { background:var(--event-hover); text-decoration:underline; }
.ch-cal-more { font-size:.59rem; color:var(--warm-gray); padding-left:6px; }
.ch-cal-dots { display:none; }
.ch-cal-footer { display:flex; align-items:center; justify-content:space-between; gap:12px; min-height:44px; color:var(--warm-gray); font-size:.65rem; border-top:1px solid var(--gray-100); }
.ch-cal-agenda { background:var(--off-white); border-left:1px solid var(--gray-200); display:flex; flex-direction:column; min-width:0; }
.ch-cal-agenda-head { display:flex; align-items:center; gap:16px; padding:28px 24px; border-bottom:1px solid var(--gray-200); }
.ch-cal-big-date { background:var(--navy); color:var(--green); font-family:var(--font-display); font-size:2.3rem; letter-spacing:-.06em; line-height:1; width:68px; height:78px; border-radius:var(--radius-md); display:flex; align-items:center; justify-content:center; flex:none; }
.ch-cal-agenda-eyebrow { font-family:var(--font-mono); font-size:.56rem; text-transform:uppercase; letter-spacing:.1em; color:var(--warm-gray); }
.ch-cal-agenda-head h3 { margin:4px 0 1px; font-family:var(--font-display); font-size:1.25rem; line-height:1.25; }
.ch-cal-agenda-month { color:var(--warm-gray); font-size:.75rem; }
.ch-cal-agenda-content { flex:1; min-height:230px; }
.ch-cal-event-list { list-style:none; margin:0; padding:18px 18px; max-height:425px; overflow-y:auto; overscroll-behavior-y:contain; }
.ch-cal-event + .ch-cal-event { margin-top:10px; }
.ch-cal-event { position:relative; background:var(--event-bg); border-left:3px solid var(--event-accent); border-radius:var(--radius-md); overflow:hidden; }
.ch-cal-event.is-shared { outline:2px solid var(--navy); outline-offset:2px; }
.ch-cal-shared-notice { margin:16px 18px 0; font-size:.8rem; line-height:1.5; color:var(--navy); }
.ch-cal-event a { display:flex; flex-direction:column; gap:10px; padding:18px 16px; color:var(--navy); }
.ch-cal-event a:hover { background:var(--event-hover); }
.ch-cal-event a:hover .ch-cal-event-title { text-decoration:underline; text-decoration-color:var(--green-dim); text-underline-offset:4px; }
.ch-cal-event-actions { position:absolute; top:7px; right:6px; }
.ch-cal-copy { display:inline-flex; align-items:center; justify-content:center; width:32px; height:32px; padding:0; border-radius:6px; color:var(--navy); }
.ch-cal-copy:hover { background:var(--event-hover); }
.ch-cal-copy:disabled { cursor:wait; opacity:.7; }
.ch-cal-copy-fallback { display:block; padding:0 16px 16px; font-size:.72rem; color:var(--navy); }
.ch-cal-copy-fallback input { display:block; width:100%; min-width:0; margin-top:6px; padding:8px; border:1px solid var(--event-accent); border-radius:6px; font:inherit; color:var(--navy); background:white; }
.ch-cal-event-time { padding-right:28px; font-size:.68rem; font-weight:600; color:#596273; }
.ch-cal-event-time > span { padding:0 3px; font-weight:400; }
.ch-cal-event-title { display:flex; justify-content:space-between; align-items:flex-start; gap:12px; font-family:var(--font-display); font-size:1.08rem; font-weight:600; line-height:1.3; overflow-wrap:anywhere; }
.ch-cal-event-title > span { flex:none; color:var(--warm-gray); }
.ch-cal-rating { font-size:.65rem; padding:4px 9px; border-radius:999px; align-self:flex-start; border:1px solid #dbe4b2; background:#f3f6df; }
.ch-cal-message { min-height:230px; padding:48px 24px; display:flex; align-items:center; justify-content:center; flex-direction:column; text-align:center; gap:10px; }
.ch-cal-message p { font-family:var(--font-display); font-size:1.1rem; font-weight:500; margin:0; }
.ch-cal-message > span, .ch-cal-message a { font-size:.8rem; color:var(--warm-gray); }
.ch-cal-message a { color:var(--navy); text-decoration:underline; text-decoration-color:var(--green-dim); text-underline-offset:4px; padding:10px 0; }
.ch-cal-retry { font-size:.72rem; min-height:44px; padding:0 14px; color:var(--warm-gray); border:1px solid var(--gray-200); border-radius:999px; }
.ch-cal-retry:hover { color:var(--navy); border-color:var(--navy); }
.ch-cal-agenda-foot { font-size:.7rem; color:var(--warm-gray); margin-top:auto; padding:17px 24px; border-top:1px solid var(--gray-200); }
.ch-cal-loading { height:22px; width:22px; border:2px solid var(--gray-200); border-top-color:var(--green-dim); border-radius:50%; animation:ch-cal-spin 1s linear infinite; }
@keyframes ch-cal-spin { to { transform:rotate(360deg); } }
.ch-calendar :is(a,button):focus-visible { outline:2px solid var(--navy); outline-offset:2px; }
.ch-cal-sr { position:absolute; width:1px; height:1px; padding:0; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0; }
@media(max-width:1050px) and (min-width:761px) {
  .ch-cal-main { padding:0 14px; }
  .ch-cal-agenda-head { padding:24px 18px; gap:12px; }
  .ch-cal-cell-event { font-size:.55rem; }
}
@media(max-width:760px) {
  .ch-cal-heading { flex-wrap:wrap; gap:12px; margin-bottom:22px; }
  .ch-cal-heading h2 { font-size:clamp(1.7rem,6vw,2.3rem); }
  .ch-cal-all { font-size:.75rem; }
  .ch-cal-shell { grid-template-columns:minmax(0,1fr); }
  .ch-cal-main { padding:0 14px; }
  .ch-cal-toolbar { min-height:76px; }
  .ch-cal-toolbar h3 { font-size:1.16rem; }
  .ch-cal-controls { gap:0; }
  .ch-cal-controls .ch-cal-today { padding:0 10px; margin-right:3px; }
  .ch-cal-table th { text-align:center; padding:0; font-size:.62rem; }
  .ch-cal-table td { height:53px; padding:2px 0; }
  .ch-cal-cell { min-height:49px; padding:0; }
  .ch-cal-day { min-height:49px; align-items:center; padding:3px 1px; }
  .ch-cal-day-top { justify-content:center; margin:0; }
  .ch-cal-number { width:27px; height:27px; font-size:.8rem; }
  .ch-cal-cell-events, .ch-cal-count { display:none; }
  .ch-cal-dots { display:flex; gap:3px; height:10px; align-items:center; }
  .ch-cal-dots i { width:4px; height:4px; border-radius:50%; background:var(--event-accent); }
  .ch-cal-agenda { border-left:0; border-top:1px solid var(--gray-200); }
  .ch-cal-agenda-head { padding:20px; gap:14px; }
  .ch-cal-big-date { width:54px; height:60px; font-size:1.9rem; }
  .ch-cal-agenda-content { min-height:140px; }
  .ch-cal-message { min-height:140px; padding:24px 20px; gap:7px; }
  .ch-cal-event-list { max-height:none; padding:16px; }
  .ch-cal-event a { padding:16px; }
  .ch-cal-agenda-foot { padding:14px 20px; }
}
@media(prefers-reduced-motion:reduce) { .ch-cal-loading { animation:none; } }
@media(max-width:420px) {
  .ch-cal-toolbar { flex-wrap:wrap; padding:14px 0; gap:8px; }
  .ch-cal-toolbar h3 { flex-basis:100%; }
  .ch-cal-controls { margin-left:auto; }
}

/* Weekly overview: all seven days and every event; selected-day agenda on mobile. */
.ch-cal-toolbar { min-height:0; margin-bottom:24px; flex-wrap:wrap; }
.ch-week-label { display:flex; align-items:baseline; gap:14px; flex-wrap:wrap; }
.ch-week-total { font-size:.75rem; color:var(--warm-gray); }
.ch-cal-controls .ch-cal-today { background:var(--green); border-color:var(--green); border-radius:8px; min-height:40px; }
.ch-cal-controls button { border-radius:8px; border:1px solid var(--gray-200); min-height:40px; }
.ch-week-shell { border:1px solid var(--gray-200); border-radius:16px; background:white; overflow:hidden; }
.ch-week-dates,.ch-week-grid { display:grid; grid-template-columns:repeat(7,minmax(0,1fr)); }
.ch-week-dates { border-bottom:1px solid var(--gray-200); }
.ch-week-dates .ch-cal-day { border-radius:0; padding:16px 13px; min-height:90px; border-right:1px solid var(--gray-100); gap:7px; position:relative; }
.ch-week-dates .ch-cal-day:last-child { border-right:0; }
.ch-week-dates .ch-cal-day[aria-pressed="true"] { background:#f2f5df; }
.ch-week-weekday { font-size:.66rem; color:var(--warm-gray); text-transform:uppercase; }
.ch-week-dates .ch-cal-number { width:34px; height:34px; font-family:var(--font-display); font-size:1.65rem; justify-content:flex-start; line-height:1; letter-spacing:-.04em; }
.ch-week-dates .ch-cal-number.is-today { background:var(--green); box-shadow:none; justify-content:center; font-size:1.4rem; }
.ch-week-dates .ch-cal-count { position:absolute; right:10px; bottom:23px; font-size:.6rem; }
.ch-week-day { min-width:0; border-right:1px solid var(--gray-100); }
.ch-week-day:last-child { border-right:0; }
.ch-week-cover { height:86px; background:var(--gray-100); overflow:hidden; }
.ch-week-cover:empty { background:repeating-linear-gradient(45deg,#f3f4ef,#f3f4ef 8px,#eff1ea 8px,#eff1ea 9px); }
.ch-week-cover img { width:100%; height:100%; object-fit:cover; display:block; }
.ch-week-mobile-heading { display:none; }
.ch-week-empty { padding:18px 13px; color:var(--warm-gray); font-size:.75rem; }
.ch-week-grid .ch-cal-event-list { padding:9px; max-height:none; overflow:visible; }
.ch-week-grid .ch-cal-event { border-radius:8px; min-height:90px; }
.ch-week-grid .ch-cal-event + .ch-cal-event { margin-top:8px; }
.ch-week-grid .ch-cal-event a { padding:12px 8px; gap:8px; min-height:90px; }
.ch-week-grid .ch-cal-event-title { font-family:var(--font-body); font-size:.75rem; font-weight:500; line-height:1.45; gap:0; }
.ch-week-grid .ch-cal-event-title > span { display:none; }
.ch-week-grid .ch-cal-event-time { font-size:.65rem; padding-right:20px; color:var(--navy); }
.ch-week-grid .ch-cal-event-actions { top:7px; right:3px; }
.ch-week-grid .ch-cal-copy { width:24px; height:26px; }
.ch-week-grid .ch-cal-copy svg { width:12px; height:12px; }
.ch-week-grid .ch-cal-copy-fallback { padding:0 8px 10px; font-size:.65rem; }
.ch-cal-footer { border-top:0; padding-top:10px; }
@media(max-width:1050px) and (min-width:761px) {
  .ch-week-dates .ch-cal-day { padding:14px 9px; }
  .ch-week-dates .ch-cal-count { position:static; font-size:.58rem; }
  .ch-week-grid .ch-cal-event-list { padding:5px; }
  .ch-week-grid .ch-cal-event a { padding:10px 6px; }
  .ch-week-grid .ch-cal-event-title { font-size:.7rem; }
  .ch-week-cover { height:65px; }
}
@media(max-width:760px) {
  .ch-cal-heading { gap:10px; }
  .ch-cal-heading-actions { gap:10px; }
  .ch-cal-all { font-size:.7rem; }
  .ch-cal-toolbar { padding:0; margin-bottom:18px; gap:16px; }
  .ch-week-label { gap:8px; }
  .ch-week-label h3 { flex-basis:auto; }
  .ch-cal-controls { width:100%; gap:6px; }
  .ch-cal-controls .ch-cal-today { margin-right:auto; padding:0 14px; }
  .ch-week-shell { background:transparent; border:0; overflow:visible; }
  .ch-week-dates { gap:4px; border:0; margin-bottom:24px; }
  .ch-week-dates .ch-cal-day { border:0; border-radius:10px; padding:10px 0; align-items:center; min-height:90px; }
  .ch-week-dates .ch-cal-day[aria-pressed="true"] { box-shadow:inset 0 0 0 1px #c9d986; }
  .ch-week-dates .ch-cal-number { font-size:1.25rem; justify-content:center; height:30px; }
  .ch-week-dates .ch-cal-count { position:static; display:block; padding:0; font-size:.54rem; }
  .ch-week-weekday { font-size:.65rem; text-transform:none; }
  .ch-week-grid { display:block; }
  .ch-week-day { display:none; border:0; }
  .ch-week-day.is-selected { display:block; }
  .ch-week-mobile-heading { display:block; font-family:var(--font-display); font-size:1.25rem; margin:0 0 16px; }
  .ch-week-cover { height:140px; border-radius:12px; margin-bottom:16px; }
  .ch-week-cover:empty { display:none; }
  .ch-week-grid .ch-cal-event-list { padding:0; }
  .ch-week-grid .ch-cal-event { min-height:0; }
  .ch-week-grid .ch-cal-event a { display:grid; grid-template-columns:74px minmax(0,1fr); gap:12px; padding:16px 36px 16px 14px; min-height:72px; }
  .ch-week-grid .ch-cal-event-time { padding-right:0; font-size:.72rem; }
  .ch-week-grid .ch-cal-event-title { font-size:.86rem; }
  .ch-week-grid .ch-cal-rating { grid-column:2; justify-self:start; }
  .ch-week-grid .ch-cal-event-actions { right:1px; top:9px; }
  .ch-week-grid .ch-cal-copy { width:32px; height:36px; }
  .ch-week-grid .ch-cal-copy svg { width:14px; height:14px; }
  .ch-cal-footer { align-items:flex-start; font-size:.62rem; }
}
