/* Asteria prototype, round 2 v7: a two-week schedule you can use with one thumb. A sliding day
   strip, filters by class, morning / noon / evening groups, and a spots ring on every class. */
.sched { background: var(--paper); padding-block: clamp(90px, 11vw, 150px); }
.sd-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 18px; }
.sd-head h2 { margin: 0; font-size: clamp(40px, 6vw, 96px); }
.sd-month { display: flex; align-items: center; gap: 12px; font-size: 15px; font-weight: 500; color: var(--taupe); }
.sd-arrows { display: inline-flex; gap: 6px; }
.sd-arrows button { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line); background: var(--sand); display: grid; place-items: center; transition: background 0.25s, transform 0.25s var(--ease); }
.sd-arrows button:hover { background: var(--linen); }
.sd-arrows button:active { transform: scale(0.94); }
.sd-arrows button:disabled { opacity: 0.35; cursor: default; transform: none; }
.sd-arrows svg, .sd-toast svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* The day strip: swipe on a phone, the dark pill slides to the day you pick. */
/* The wrapper clips sideways only in effect: the strip below it keeps 44px of room for the
   active day's shadow, and the negative bottom margin lets the filters sit over that room. */
.sd-strip-wrap { margin: 28px calc(var(--pad) * -1) -34px; overflow: hidden; }
/* Bottom padding leaves room for the active day's shadow (a scroller clips what overflows). */
.sd-strip { position: relative; display: flex; gap: 8px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 14px var(--pad) 44px; scrollbar-width: none; }
.sd-strip::-webkit-scrollbar { display: none; }
.sd-pill { position: absolute; top: 14px; left: 0; z-index: 2; overflow: hidden; width: 64px; height: 84px; border-radius: 999px 999px 20px 20px; background: var(--cocoa); box-shadow: 0 12px 26px rgba(47, 34, 27, 0.25); pointer-events: none; }
.sd-day { position: relative; z-index: 1; flex: none; scroll-snap-align: center; width: 64px; height: 84px; border-radius: 999px 999px 20px 20px; border: 1px solid var(--line); background: transparent; display: grid; align-content: center; justify-items: center; gap: 2px; font-size: 13px; color: var(--taupe); transition: color 0.35s var(--ease), border-color 0.35s; }
.sd-day b { font: 600 24px/1 var(--display); color: var(--cocoa); transition: color 0.35s; }
.sd-day .sd-dots { display: flex; gap: 3px; height: 4px; margin-top: 4px; }
.sd-day .sd-dots i { width: 4px; height: 4px; border-radius: 50%; background: var(--clay); opacity: 0.7; }
/* The light copy of the days inside the pill. */
.sd-pill-in { position: absolute; inset-block: 0; left: 0; width: 0; }
.sd-ghost { position: absolute; top: 0; width: 64px; height: 84px; border: 1px solid transparent; display: grid; align-content: center; justify-items: center; gap: 2px; font-size: 13px; color: var(--linen); }
.sd-ghost b { font: 600 24px/1 var(--display); color: var(--paper); }
.sd-ghost .sd-dots { display: flex; gap: 3px; height: 4px; margin-top: 4px; }
.sd-ghost .sd-dots i { width: 4px; height: 4px; border-radius: 50%; background: var(--sage); }
.sd-ghost.closed { opacity: 0.6; }
.sd-day.closed { opacity: 0.55; }
.sd-day .sd-star { position: absolute; top: -12px; color: var(--gold); font-size: 13px; animation: breathe 3s ease-in-out infinite; }
.sd-day .sd-week { position: absolute; bottom: -18px; font-size: 11px; color: var(--taupe); white-space: nowrap; }

.sd-filters { display: flex; gap: 8px; margin: 26px 0 8px; overflow-x: auto; scrollbar-width: none; padding-bottom: 4px; }
.sd-filters::-webkit-scrollbar { display: none; }
.sd-filters button { flex: none; min-height: 40px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line); background: transparent; font-size: 14px; color: var(--cocoa); transition: background 0.3s var(--ease), color 0.3s; }
.sd-filters [aria-pressed="true"] { background: var(--clay); border-color: var(--clay); color: var(--paper); }

/* Groups and classes. */
.sd-list { min-height: 360px; }
.sd-group h3 { display: flex; align-items: center; gap: 10px; margin: 26px 0 10px; font: 500 14px var(--body); letter-spacing: 0.16em; color: var(--taupe); }
.sd-group h3 svg { width: 18px; height: 18px; fill: none; stroke: var(--clay); stroke-width: 1.6; stroke-linecap: round; }
.sd-group h3::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.sd-class { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 18px; padding: 22px; margin-bottom: 10px; border-radius: 26px; background: var(--sand); border: 1px solid transparent; transition: border-color 0.3s, transform 0.35s var(--ease), box-shadow 0.35s; }
.sd-class:hover { border-color: var(--line); transform: translateY(-2px); box-shadow: 0 14px 30px rgba(47, 34, 27, 0.08); }
.sd-time { display: grid; justify-items: center; align-self: center; min-width: 100px; padding: 24px 16px 14px; border-radius: 999px 999px 18px 18px; background: var(--paper); }
.sd-time b { font: 600 22px/1 var(--display); font-variant-numeric: tabular-nums; direction: ltr; }
.sd-time span { font-size: 12px; color: var(--taupe); margin-top: 4px; }
.sd-info strong { display: block; font-size: 18px; font-weight: 600; }
.sd-who { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 4px; font-size: 14px; color: var(--taupe); }
.sd-who img { width: 24px; height: 24px; border-radius: 50%; object-fit: cover; }
.sd-lvl { padding: 2px 10px; border-radius: 999px; background: var(--paper); font-size: 12px; }
.sd-act { display: flex; align-items: center; gap: 12px; }
.sd-ring { position: relative; width: 46px; height: 46px; display: grid; place-items: center; font-size: 13px; font-weight: 600; font-variant-numeric: tabular-nums; }
.sd-ring svg { position: absolute; inset: 0; transform: rotate(-90deg); }
.sd-ring circle { fill: none; stroke-width: 3; }
.sd-ring .bg { stroke: var(--linen); }
.sd-ring .fg { stroke: var(--clay); stroke-linecap: round; }
.sd-ring.few .fg { stroke: var(--gold); }
.sd-ring.full .fg { stroke: var(--taupe); }
.sd-book { min-height: 44px; padding: 0 18px; border-radius: 999px; border: 0; background: var(--cocoa); color: var(--paper); font-size: 14px; font-weight: 500; white-space: nowrap; transition: transform 0.25s var(--ease), background 0.3s; }
.sd-book:active { transform: scale(0.95); }
.sd-book.wait { background: transparent; color: var(--cocoa); border: 1px solid var(--cocoa); }
.sd-book.done { background: var(--sage); color: var(--forest); }
.sd-empty { display: grid; justify-items: center; gap: 10px; padding: 50px 16px; text-align: center; color: var(--taupe); }
.sd-empty b { font: 600 26px var(--display); color: var(--cocoa); }
.sd-empty button { min-height: 44px; padding: 0 20px; border-radius: 999px; border: 1px solid var(--cocoa); background: transparent; }

.sd-toast { position: fixed; z-index: 50; inset-inline: 0; margin-inline: auto; width: max-content; max-width: calc(100vw - 32px); bottom: calc(96px + env(safe-area-inset-bottom, 0px)); display: flex; align-items: center; gap: 10px; padding: 12px 18px; border-radius: 999px; background: var(--forest); color: var(--cream); font-size: 15px; box-shadow: 0 18px 40px rgba(22, 36, 29, 0.35); }
.sd-toast svg { color: var(--sage); }

@media (max-width: 760px) {
  .sd-head h2 { font-size: 38px; }
  .sd-class { grid-template-columns: auto 1fr; gap: 14px; padding: 20px; }
  .sd-act { grid-column: 1 / -1; justify-content: space-between; }
  .sd-book { flex: 1; }
}
@media (prefers-reduced-motion: reduce) { .sd-day .sd-star { animation: none; } }
.sd-toast[hidden] {
  display: none;
}

/* On wide screens the classes sit in two columns, easier to scan. */
@media (min-width: 1000px) {
  .sd-group {
    display: grid;
    grid-template-columns: 1fr 1fr;
    column-gap: 14px;
  }
  .sd-group h3 {
    grid-column: 1 / -1;
  }
}
