:root {
  color-scheme: dark;
  --bg: #070807;
  --bg-low: #25261f;
  --panel: #101110;
  --panel-2: #161714;
  --panel-3: #20211c;
  --ink: #f4f1e9;
  --muted: #a7a79c;
  --quiet: #77786f;
  --line: rgba(244, 241, 233, 0.12);
  --line-strong: rgba(244, 241, 233, 0.2);
  --accent: #c7c0a5;
  --accent-soft: rgba(199, 192, 165, 0.14);
  --warning: #e8b36f;
  --warning-soft: rgba(232, 179, 111, 0.15);
  --aa: #aab4c8;
  --na: #b7a9c4;
  --now: #b9c3a7;
  --shadow: 0 22px 70px rgba(0, 0, 0, 0.34);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    linear-gradient(180deg, var(--bg) 0%, #0a0b0a 58%, var(--bg-low) 100%);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: 0;
}

button,
input {
  font: inherit;
}

.app-shell {
  width: min(820px, calc(100% - 28px));
  margin: 0 auto;
  padding: 34px 0 48px;
}

.topbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
}

.eyebrow {
  margin: 0 0 7px;
  color: var(--accent);
  font-size: 0.82rem;
  font-weight: 650;
}

h1 {
  margin: 0;
  color: #fffdf7;
  font-size: clamp(2.25rem, 5vw, 3.7rem);
  line-height: 0.95;
  font-weight: 780;
}

.topbar-actions,
.date-strip {
  display: flex;
  align-items: center;
  gap: 8px;
}

.icon-button {
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
  color: var(--ink);
  cursor: pointer;
  transition: background 140ms ease, border-color 140ms ease, color 140ms ease;
}

.icon-button:hover {
  border-color: var(--line-strong);
  background: rgba(255, 255, 255, 0.075);
}

.icon-button.primary {
  border-color: rgba(199, 192, 165, 0.42);
  background: var(--accent);
  color: #11120f;
}

.icon-button svg {
  width: 19px;
  height: 19px;
}

.control-band {
  display: grid;
  grid-template-columns: auto auto 1fr;
  gap: 10px;
  align-items: center;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(16, 17, 16, 0.92);
  box-shadow: var(--shadow);
}

.date-field {
  display: grid;
  gap: 3px;
}

.date-field span {
  color: var(--quiet);
  font-size: 0.7rem;
  font-weight: 720;
  text-transform: uppercase;
}

.date-field input {
  min-width: 160px;
  height: 44px;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #090a09;
  color: var(--ink);
  color-scheme: dark;
}

.segmented {
  display: inline-grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(54px, auto);
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #090a09;
}

.segmented.wide {
  justify-self: stretch;
}

.segment {
  min-height: 36px;
  padding: 0 12px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  white-space: nowrap;
  font-weight: 680;
  transition: background 140ms ease, color 140ms ease;
}

.segment:hover {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.055);
}

.segment.active {
  background: var(--panel-3);
  color: var(--ink);
}

.freshness {
  margin: 14px 0 16px;
  color: var(--quiet);
  font-size: 0.84rem;
  font-weight: 620;
}

.meeting-list {
  display: grid;
  gap: 13px;
}

.time-group {
  display: grid;
  gap: 10px;
}

.time-heading {
  position: sticky;
  top: 0;
  z-index: 1;
  display: flex;
  align-items: center;
  padding: 11px 0 2px;
  background: transparent;
  color: var(--quiet);
  font-size: 0.72rem;
  font-weight: 780;
  text-transform: uppercase;
}

.meeting-card {
  display: grid;
  grid-template-columns: 98px 1fr auto;
  gap: 14px;
  padding: 15px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(16, 17, 16, 0.94);
  box-shadow: 0 12px 34px rgba(0, 0, 0, 0.24);
}

.meeting-card.current {
  border-color: rgba(185, 195, 167, 0.42);
  background: linear-gradient(90deg, rgba(185, 195, 167, 0.12), rgba(16, 17, 16, 0.98) 48%);
}

.meeting-time {
  color: #fffdf7;
  font-size: 1.15rem;
  font-weight: 780;
  line-height: 1.05;
}

.meeting-end {
  display: block;
  margin-top: 6px;
  color: var(--quiet);
  font-size: 0.78rem;
  font-weight: 620;
  line-height: 1.25;
}

.meeting-main {
  min-width: 0;
}

.meeting-title-row {
  display: flex;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 8px;
}

.meeting-title {
  flex-basis: 100%;
  margin: 0;
  color: #fffdf7;
  font-size: 1.12rem;
  line-height: 1.24;
  font-weight: 740;
}

.badge {
  display: inline-flex;
  align-items: center;
  min-height: 21px;
  padding: 0 7px;
  border: 1px solid rgba(244, 241, 233, 0.08);
  border-radius: 6px;
  background: rgba(244, 241, 233, 0.06);
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 760;
}

.badge.aa {
  color: var(--aa);
}

.badge.na {
  color: var(--na);
}

.badge.warning {
  background: var(--warning-soft);
  color: var(--warning);
}

.badge.now {
  border-color: rgba(185, 195, 167, 0.32);
  background: rgba(185, 195, 167, 0.18);
  color: #eef5df;
}

.badge.preview {
  color: #c6c0d2;
}

.meeting-meta,
.meeting-notes,
.meeting-types {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.45;
}

.meeting-meta {
  color: #b9baaf;
}

.meeting-types {
  margin-top: 6px;
  color: var(--quiet);
}

.meeting-notes {
  display: -webkit-box;
  margin-top: 6px;
  overflow: hidden;
  color: var(--quiet);
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.meeting-actions {
  display: flex;
  align-items: flex-start;
  gap: 7px;
}

.action-link {
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
  color: var(--muted);
  text-decoration: none;
  transition: background 140ms ease, border-color 140ms ease, color 140ms ease;
}

.action-link:hover {
  border-color: var(--line-strong);
  background: rgba(255, 255, 255, 0.075);
  color: var(--ink);
}

.action-link svg {
  width: 18px;
  height: 18px;
}

.empty-state {
  padding: 38px 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(16, 17, 16, 0.94);
  color: var(--muted);
  text-align: center;
  box-shadow: 0 12px 34px rgba(0, 0, 0, 0.24);
}

.loading {
  opacity: 0.62;
}

@media (max-width: 900px) {
  .control-band {
    grid-template-columns: 1fr;
  }

  .date-strip,
  .segmented {
    justify-self: stretch;
  }

  .segmented {
    grid-auto-columns: 1fr;
  }

  .date-strip {
    justify-content: space-between;
  }
}

@media (max-width: 620px) {
  .app-shell {
    width: min(100% - 18px, 820px);
    padding-top: 18px;
  }

  .topbar {
    align-items: flex-start;
  }

  .meeting-card {
    grid-template-columns: 1fr auto;
  }

  .meeting-time,
  .meeting-main {
    grid-column: 1 / -1;
  }

  .meeting-actions {
    align-items: center;
  }
}
