/* AEDP Course Master — same family as the facilitation hub (Newsreader + Public Sans, deep teal) */
:root {
  --ink: oklch(0.28 0.03 192);
  --ink-2: oklch(0.44 0.02 192);
  --muted: oklch(0.55 0.02 192);
  --line: oklch(0.90 0.012 192);
  --bg: oklch(0.985 0.006 85);
  --card: #fff;
  --brand: oklch(0.38 0.05 192);
  --brand-h: oklch(0.46 0.08 192);
  --gap: oklch(0.55 0.15 35);
  --c-es1: oklch(0.62 0.09 165);
  --c-immersion: oklch(0.58 0.11 290);
  --c-asm: oklch(0.65 0.12 75);
  --c-seminar: oklch(0.62 0.13 30);
  --c-talks: oklch(0.58 0.09 240);
  --c-team: oklch(0.58 0.12 350);
  --c-other: oklch(0.62 0.02 192);
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body { font-family: "Public Sans", system-ui, sans-serif; color: var(--ink); background: var(--bg); -webkit-font-smoothing: antialiased; font-size: 15.5px; line-height: 1.5; }
a { color: var(--brand-h); }
h1, h2 { font-family: Newsreader, Georgia, serif; font-weight: 500; letter-spacing: -0.01em; }
h1 { font-size: clamp(28px, 4vw, 38px); line-height: 1.12; margin: 0 0 6px; }
h2 { font-size: 23px; margin: 30px 0 10px; }
.lede { color: var(--ink-2); margin: 0 0 18px; font-size: 16px; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
main.wide { max-width: 1180px; margin: 0 auto; padding: 30px 24px 70px; }
main.narrow { max-width: 820px; margin: 0 auto; padding: 30px 24px 70px; }

/* header */
.top { background: oklch(0.975 0.008 192); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
.top-in { max-width: 1180px; margin: 0 auto; padding: 12px 24px; display: flex; align-items: center; gap: 22px; flex-wrap: wrap; }
.brand { display: flex; flex-direction: column; text-decoration: none; color: var(--ink); margin-right: auto; }
.brand .nm { font-family: Newsreader, serif; font-size: 20px; font-weight: 500; line-height: 1.1; }
.brand .sb { font-size: 10.5px; letter-spacing: 0.13em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.top nav { display: flex; gap: 4px; }
.top nav a { text-decoration: none; color: var(--ink-2); padding: 7px 12px; border-radius: 99px; font-weight: 600; font-size: 14.5px; }
.top nav a:hover { background: oklch(0.94 0.015 192); }
.top nav a[aria-current] { background: var(--brand); color: #fff; }
.me { display: flex; align-items: center; gap: 12px; font-size: 14px; }
.me a { color: var(--ink-2); }
.me form { margin: 0; }
.linkish { background: none; border: 0; color: var(--ink-2); text-decoration: underline; cursor: pointer; font: inherit; padding: 0; }

/* buttons, forms */
.btn { display: inline-flex; align-items: center; gap: 6px; padding: 10px 18px; border-radius: 99px; border: 1px solid var(--line); background: #fff; color: var(--ink); font: 600 14.5px "Public Sans", sans-serif; cursor: pointer; text-decoration: none; white-space: nowrap; }
.btn:hover { border-color: var(--brand-h); }
.btn.primary { background: var(--brand); border-color: var(--brand); color: #fff; }
.btn.primary:hover { background: var(--brand-h); }
.btn.small { padding: 7px 13px; font-size: 13.5px; }
.btn.ghost { background: transparent; }
.btn.link-danger { border: 0; background: none; color: var(--gap); padding-left: 0; }
.btn:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, a:focus-visible { outline: 2px solid var(--brand-h); outline-offset: 2px; }
label { display: flex; flex-direction: column; gap: 6px; font-size: 12px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
label.inline { flex-direction: row; align-items: center; gap: 7px; text-transform: none; letter-spacing: 0; font-size: 14px; font-weight: 500; color: var(--ink-2); }
input, select, textarea { font: 400 15.5px "Public Sans", sans-serif; color: var(--ink); background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; width: 100%; text-transform: none; letter-spacing: 0; }
label.inline input { width: auto; }
textarea { resize: vertical; }
.hint { font-size: 12.5px; font-weight: 400; text-transform: none; letter-spacing: 0; color: var(--muted); }
.stack { display: flex; flex-direction: column; gap: 16px; max-width: 420px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 18px; }
.msg { padding: 12px 15px; border-radius: 12px; margin: 0 0 18px; font-size: 14.5px; }
.msg.err { background: oklch(0.96 0.03 25 / 0.6); border: 1px solid oklch(0.86 0.04 25); color: oklch(0.42 0.13 25); }
.msg.info { background: oklch(0.95 0.025 192); border: 1px solid var(--line); color: var(--ink-2); }
.toast { position: fixed; top: 74px; left: 50%; transform: translateX(-50%); background: var(--brand); color: #fff; padding: 9px 18px; border-radius: 99px; font-weight: 600; z-index: 30; animation: fade 3s forwards; }
@keyframes fade { 0%, 70% { opacity: 1; } 100% { opacity: 0; visibility: hidden; } }

/* filters */
.filters { display: flex; gap: 9px; flex-wrap: wrap; align-items: center; padding: 12px 0 18px; border-bottom: 1px solid var(--line); margin-bottom: 8px; }
.filters input[type=search] { flex: 1 1 150px; min-width: 150px; width: auto; border-radius: 99px; padding: 9px 15px; }
select { appearance: none; -webkit-appearance: none; padding-right: 38px; cursor: pointer;
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%23476b69' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right 14px center; }
.filters select { width: auto; border-radius: 99px; padding: 9px 40px 9px 16px; background-position: right 16px center; }
.filters input[type=date] { width: auto; padding: 7px 10px; }
.filters .clear { font-size: 14px; }
.filters .spacer { flex: 1 0 100%; height: 0; }
.filters .spacer + .btn { margin-left: auto; }

/* categories & statuses */
.cat { display: inline-block; font-size: 11px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; padding: 3px 9px; border-radius: 99px; color: #fff; background: var(--c-other); }
.cat-es1 { --c: var(--c-es1); } .cat-immersion { --c: var(--c-immersion); } .cat-asm { --c: var(--c-asm); }
.cat-seminar { --c: var(--c-seminar); } .cat-talks-series { --c: var(--c-talks); } .cat-team { --c: var(--c-team); } .cat-other { --c: var(--c-other); }
.cat[class*=cat-] { background: var(--c); }
.status { font-size: 11px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; padding: 2px 8px; border-radius: 99px; border: 1px dashed currentColor; color: var(--ink-2); }
.status.st-cancelled { color: var(--gap); border-style: solid; }
.status.st-moved { color: oklch(0.50 0.10 70); }
.gap { color: var(--gap); font-weight: 600; }
.struck { text-decoration: line-through; text-decoration-thickness: 2px; color: var(--muted); }

/* upcoming list */
.list-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; }
.month { position: sticky; top: 64px; background: var(--bg); padding: 10px 0 8px; margin: 22px 0 6px; z-index: 5; font-size: 22px; }
.cards { display: flex; flex-direction: column; gap: 10px; }
.card { display: grid; grid-template-columns: 190px 1fr; gap: 18px; background: var(--card); border: 1px solid var(--line); border-left: 5px solid var(--c, var(--c-other)); border-radius: 14px; padding: 15px 18px; text-decoration: none; color: var(--ink); transition: border-color .15s, box-shadow .15s; }
.card:hover { box-shadow: 0 2px 10px oklch(0.3 0.04 192 / 0.08); border-color: oklch(0.8 0.03 192); border-left-color: var(--c); }
.card-when .d { display: block; font-weight: 700; font-size: 15px; }
.card-when .t { display: block; color: var(--muted); font-size: 13.5px; margin-top: 2px; }
.card-tags { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; font-size: 13px; margin-bottom: 4px; }
.card-title { font-family: Newsreader, serif; font-size: 19px; line-height: 1.25; }
.card-meta { display: flex; gap: 10px 14px; flex-wrap: wrap; align-items: center; font-size: 13.5px; color: var(--ink-2); margin-top: 6px; }
.card-meta .lbl { font-size: 10.5px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; margin-right: 6px; }
.card-meta .pres { color: var(--ink); font-weight: 600; }
.card-meta .pres .lbl { color: var(--muted); }
.card-meta .fac { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 4px; }
.card-meta .fac .lbl { color: var(--muted); }
.card.st-tentative, .card.st-moved { opacity: 0.62; border-style: dashed; border-left-style: solid; }
.card.st-cancelled { opacity: 0.55; }
.card.st-cancelled .card-title { text-decoration: line-through; }
.empty { padding: 50px 0; text-align: center; color: var(--muted); }

/* calendar */
.cal-head { display: flex; align-items: center; gap: 14px; }
.cal-head h1 { margin: 0; min-width: 9em; text-align: center; }
.today-link { font-size: 14px; margin-left: 6px; }
.cal { margin-top: 6px; }
.cal-dow { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; font-size: 11.5px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); padding: 6px 2px; }
.cal-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.cal-day { background: #fff; border: 1px solid var(--line); border-radius: 10px; min-height: 118px; padding: 6px; display: flex; flex-direction: column; gap: 4px; }
.cal-day.out { background: transparent; border-style: dashed; opacity: 0.55; }
.cal-day.today { border-color: var(--brand-h); box-shadow: inset 0 0 0 1px var(--brand-h); }
.cal-num { display: flex; justify-content: space-between; font-size: 13px; font-weight: 700; color: var(--ink-2); }
.cal-add { text-decoration: none; color: var(--muted); font-weight: 400; opacity: 0; padding: 0 4px; border-radius: 6px; }
.cal-day:hover .cal-add { opacity: 1; }
.cal-add:hover { background: oklch(0.94 0.015 192); color: var(--ink); }
.cal-note { font-size: 11px; color: var(--muted); font-style: italic; line-height: 1.25; }
.chip { display: flex; flex-direction: column; text-decoration: none; color: var(--ink); background: color-mix(in oklch, var(--c) 13%, white); border-left: 3px solid var(--c); border-radius: 6px; padding: 4px 6px; font-size: 12px; line-height: 1.25; }
.chip:hover { background: color-mix(in oklch, var(--c) 22%, white); }
.chip-t { font-weight: 600; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.chip-m, .chip-f { color: var(--ink-2); font-size: 11px; }
.chip-f.gap { color: var(--gap); }
.chip.st-tentative, .chip.st-moved { opacity: 0.55; border-left-style: dashed; }
.chip.st-cancelled { opacity: 0.5; text-decoration: line-through; }
.legend { display: flex; flex-wrap: wrap; gap: 8px 18px; font-size: 13px; color: var(--ink-2); margin-top: 22px; align-items: center; }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend .sw { width: 12px; height: 12px; border-radius: 3px; background: var(--c); display: inline-block; }
.legend .st-tentative-sw { background: transparent; border: 1.5px dashed var(--ink-2); }
.legend .sep { width: 1px; height: 14px; background: var(--line); }

/* course page */
.back { display: inline-block; font-size: 14px; margin-bottom: 14px; text-decoration: none; }
.eyebrow { display: flex; gap: 9px; align-items: center; flex-wrap: wrap; font-size: 14px; margin-bottom: 8px; }
.when { font-size: 17px; color: var(--ink-2); margin: 0 0 16px; }
.actions { display: flex; gap: 10px; margin-bottom: 20px; }
.facts { display: grid; grid-template-columns: 1fr 1fr; gap: 0 24px; margin: 0; background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 6px 20px; }
.facts div { padding: 10px 0; border-bottom: 1px solid oklch(0.95 0.008 192); }
.facts dt { font-size: 11.5px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.facts dd { margin: 2px 0 0; }
.days { list-style: none; padding: 0; margin: 0; background: #fff; border: 1px solid var(--line); border-radius: 14px; }
.days li { display: grid; grid-template-columns: 170px 1fr; gap: 4px 16px; padding: 10px 18px; border-bottom: 1px solid oklch(0.95 0.008 192); }
.days li:last-child { border-bottom: 0; }
.days .d { font-weight: 600; }
.days .n { grid-column: 2; font-size: 13.5px; color: var(--muted); }
.notes { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 14px 18px; margin: 0; }
.hist { margin-top: 30px; }
.hist summary { cursor: pointer; color: var(--ink-2); font-size: 14px; }
.history { list-style: none; padding: 0; margin: 12px 0 0; display: flex; flex-direction: column; gap: 10px; }
.history > li { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; font-size: 14px; }
.h-ch { margin: 6px 0 0; padding-left: 18px; color: var(--ink-2); font-size: 13.5px; }
.h-ch s { color: var(--muted); }
.h-f { font-weight: 600; }

/* edit form */
.edit fieldset { border: 1px solid var(--line); background: #fff; border-radius: 16px; padding: 16px 20px 20px; margin: 0 0 16px; display: grid; grid-template-columns: 1fr 1fr; gap: 14px 18px; }
.edit legend { font-family: Newsreader, serif; font-size: 20px; padding: 0 6px; margin-left: -6px; color: var(--ink); }
.edit .wide { grid-column: 1 / -1; }
.sessions { display: flex; flex-direction: column; gap: 8px; }
.sess-head, .sess-row { display: grid; grid-template-columns: 170px 1fr 1fr 32px; gap: 8px; align-items: center; }
.sess-head span { font-size: 11.5px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
.sess-row .x { border: 0; background: none; font-size: 22px; color: var(--muted); cursor: pointer; border-radius: 8px; }
.sess-row .x:hover { color: var(--gap); background: oklch(0.96 0.02 25); }
.sess-tools { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; font-size: 14px; color: var(--ink-2); }
.sess-tools input[type=date] { width: auto; padding: 6px 8px; }
.form-actions { display: flex; gap: 10px; align-items: center; grid-column: 1 / -1; }
.danger { margin-top: 26px; padding-top: 16px; border-top: 1px solid var(--line); }

/* people */
.share { display: flex; gap: 8px; margin: 8px 0 10px; }
.share input { font-size: 13px; }
.users { width: 100%; border-collapse: collapse; background: #fff; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; font-size: 14px; }
.users th, .users td { text-align: left; padding: 9px 12px; border-bottom: 1px solid oklch(0.95 0.008 192); }
.users th { font-size: 11.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.users form { margin: 0; }

@media (max-width: 760px) {
  .top-in { gap: 10px; }
  .top nav { order: 3; width: 100%; overflow-x: auto; }
  .card { grid-template-columns: 1fr; gap: 6px; }
  .facts, .grid2, .edit fieldset { grid-template-columns: 1fr; }
  .days li { grid-template-columns: 1fr; }
  .days .n { grid-column: 1; }
  .sess-head { display: none; }
  .sess-row { grid-template-columns: 1fr 32px; }
  .sess-row input[name="s_fac[]"], .sess-row input[name="s_note[]"] { grid-column: 1; }
  .cal-grid, .cal-dow { gap: 3px; }
  .cal-day { min-height: 70px; padding: 3px; }
  .chip-m, .chip-f, .cal-note { display: none; }
  .chip { font-size: 10.5px; padding: 2px 4px; }
  .month { top: 104px; }
  .filters .spacer { display: none; }
}
@media print {
  .top, .filters, .actions, .btn, .legend, .cal-add, .hist, .danger { display: none !important; }
  body { background: #fff; font-size: 12px; }
  main.wide, main.narrow { max-width: none; padding: 0; }
  .card { break-inside: avoid; box-shadow: none; }
  .month { position: static; }
  .cal-day { min-height: 90px; }
}
.my-days { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 2px 8px; margin-top: 7px; padding: 4px 12px; border-radius: 10px; background: var(--brand); color: #fff; font-size: 13.5px; font-weight: 600; }
.my-days .lbl { font-size: 10.5px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; opacity: .8; }
.my-days.need { background: var(--gap); }
.subscribe { margin: 4px 0 14px; padding: 10px 14px; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.subscribe summary { cursor: pointer; font-weight: 600; color: var(--brand); }
.subscribe p { margin: 8px 0; }
.sub-btns { display: flex; flex-wrap: wrap; gap: 8px; }
.month-pick select { width: auto; border-radius: 99px; padding: 7px 36px 7px 14px; background-position: right 14px center; font-size: 14px; }
.cal-head { flex-wrap: wrap; }
.cal-agenda { display: none; }
.ag-day { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; margin-bottom: 10px; display: flex; flex-direction: column; gap: 6px; }
.ag-day.today { border-color: var(--brand-h); }
.ag-day h3 { margin: 0; font-size: 15px; font-family: "Public Sans", sans-serif; }
.ag-day .chip { font-size: 13.5px; padding: 6px 9px; }
.ag-day .chip-m, .ag-day .chip-f, .ag-day .cal-note { display: block; font-size: 12.5px; }
@media (max-width: 760px) {
  .cal { display: none; }
  .cal-agenda { display: block; }
  .cal-head h1 { min-width: 0; font-size: 22px; }
}
@media print { .subscribe, .month-pick, .cal-agenda { display: none !important; } .cal { display: block !important; } }
/* Facilitator name tags: one colour per person, matching the hub */
.fp { display: inline-block; padding: 1px 8px; border-radius: 99px; background: oklch(0.92 0.06 var(--h)); color: oklch(0.36 0.11 var(--h)); border: 1px solid oklch(0.84 0.08 var(--h)); font-weight: 600; font-size: 12.5px; line-height: 1.45; white-space: nowrap; }
.chip-f .fp { font-size: 10.5px; padding: 0 6px; margin-top: 2px; }
.chip-f { display: flex; flex-wrap: wrap; gap: 3px; align-items: center; }
.ag-day .chip-f { display: flex; }
.ag-day .chip-f .fp { font-size: 12px; }
.days .f { display: flex; flex-wrap: wrap; gap: 5px; }
