/* ============================================================
   EMEA QBR Agenda — Hightouch design system
   ============================================================ */

@import url("ht/colors_and_type.css");

:root {
  /* Track colors (from approved mapping)
     All-hands → black, QBR → teal, Workshop → purple,
     Activity → green, Social → warm/yellow, Travel/Break → gray */
  --tr-plenary:  var(--ht-black);
  --tr-qbr:      var(--ht-teal-600);
  --tr-workshop: var(--ht-purple-600);
  --tr-activity: var(--ht-green-600);
  --tr-social:   var(--ht-yellow-700);
  --tr-travel:   var(--ht-gray-500);
  --tr-break:    var(--ht-gray-500);

  /* App-specific surface tokens */
  --paper:    var(--ht-bg);
  --canvas:   var(--ht-bg-subtle);
  --line:     var(--ht-divider);
  --line-2:   var(--ht-border);
  --ink:      var(--ht-fg);
  --ink-2:    var(--ht-fg-muted);
  --ink-3:    var(--ht-fg-subtle);
}

* { box-sizing: border-box; }

html, body, #app {
  margin: 0;
  padding: 0;
  background: var(--canvas);
  color: var(--ink);
  font-family: var(--ht-font-body);
  font-size: var(--ht-text-md);
  line-height: var(--ht-leading-normal);
  height: 100%;
  -webkit-font-smoothing: antialiased;
}

button { font: inherit; color: inherit; cursor: pointer; }
kbd {
  font-family: var(--ht-font-mono);
  font-size: 11px;
  padding: 1px 6px;
  border: 1px solid var(--line-2);
  border-radius: var(--ht-radius-sm);
  background: var(--paper);
  color: var(--ink-2);
  box-shadow: 0 1px 0 var(--line);
}

/* ============================================================
   App shell
   ============================================================ */

.app {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  max-width: 1480px;
  margin: 0 auto;
  background: var(--canvas);
}

/* ============================================================
   Masthead — dark hero with brand pulse
   ============================================================ */

.masthead {
  background: var(--ht-bg-dark);
  color: var(--ht-fg-on-dark);
  padding: var(--ht-space-12) var(--ht-space-10) var(--ht-space-10);
  position: relative;
}

.masthead-inner {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--ht-space-10);
  flex-wrap: wrap;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--ht-space-2);
  font-family: var(--ht-font-meta);
  font-size: var(--ht-meta);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: var(--ht-track-eyebrow);
  color: var(--ht-fg-on-dark-muted);
  margin-bottom: var(--ht-space-3);
}
.eyebrow .pulse {
  width: 8px; height: 8px;
  border-radius: var(--ht-radius-full);
  background: var(--ht-brand-accent);
  box-shadow: 0 0 0 0 rgba(64, 222, 158, 0.6);
  animation: pulse 2.4s var(--ht-ease-out-cubic) infinite;
}
@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 rgba(64, 222, 158, 0.5); }
  70%  { box-shadow: 0 0 0 12px rgba(64, 222, 158, 0); }
  100% { box-shadow: 0 0 0 0 rgba(64, 222, 158, 0); }
}

.masthead h1.ht-hero {
  font-family: var(--ht-font-display);
  font-size: var(--ht-display-2);
  font-weight: 600;
  line-height: var(--ht-leading-tight);
  letter-spacing: var(--ht-track-display);
  margin: 0 0 var(--ht-space-2);
  color: var(--ht-fg-on-dark);
}
.masthead h1 .accent { color: var(--ht-brand-accent); }

.masthead .subtitle {
  font-family: var(--ht-font-body);
  font-size: var(--ht-text-lg);
  color: var(--ht-fg-on-dark-muted);
  margin: 0;
}

.masthead-meta {
  display: grid;
  grid-template-columns: auto auto auto;
  gap: var(--ht-space-8);
  font-family: var(--ht-font-meta);
}
.masthead-meta .item .label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: var(--ht-track-eyebrow);
  color: var(--ht-fg-on-dark-muted);
  margin-bottom: var(--ht-space-1);
}
.masthead-meta .item .value {
  font-family: var(--ht-font-body);
  font-size: var(--ht-text-md);
  color: var(--ht-fg-on-dark);
  font-weight: 500;
}

.logo-mark {
  position: absolute;
  top: var(--ht-space-6);
  right: var(--ht-space-10);
  color: var(--ht-fg-on-dark);
  display: inline-flex;
  align-items: center;
}
.logo-mark svg {
  height: 32px;
  width: auto;
  display: block;
}

/* ============================================================
   Toolbar
   ============================================================ */

.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--ht-space-6);
  padding: var(--ht-space-4) var(--ht-space-10);
  background: var(--paper);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 10;
}

.day-tabs {
  display: flex;
  gap: var(--ht-space-1);
}
.day-tab {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  padding: var(--ht-space-2) var(--ht-space-3);
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--ht-radius-md);
  text-align: left;
  transition: all var(--ht-dur-fast) var(--ht-ease-out-cubic);
}
.day-tab:hover { background: var(--ht-bg-subtle); }
.day-tab.active {
  background: var(--ht-black);
  color: var(--ht-fg-on-dark);
  border-color: var(--ht-black);
  box-shadow: var(--ht-shadow-btn);
}
.day-tab .num {
  font-family: var(--ht-font-mono);
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: var(--ht-track-eyebrow);
  color: var(--ink-3);
}
.day-tab.active .num { color: rgba(255,255,255,0.6); }
.day-tab .date {
  font-family: var(--ht-font-body);
  font-size: var(--ht-text-md);
  font-weight: 500;
  color: var(--ink);
}
.day-tab.active .date { color: var(--ht-fg-on-dark); }

.chips { display: flex; gap: var(--ht-space-1); flex-wrap: wrap; }
.chip {
  display: inline-flex;
  align-items: center;
  gap: var(--ht-space-2);
  padding: 6px var(--ht-space-3);
  background: transparent;
  border: 1px solid var(--line-2);
  border-radius: var(--ht-radius-full);
  font-size: var(--ht-text-sm);
  color: var(--ink-2);
  transition: all var(--ht-dur-fast) var(--ht-ease-out-cubic);
}
.chip:hover { background: var(--ht-bg-subtle); color: var(--ink); }
.chip.active {
  background: var(--ht-black);
  color: var(--ht-fg-on-dark);
  border-color: var(--ht-black);
}
.chip .swatch {
  width: 8px; height: 8px;
  border-radius: var(--ht-radius-full);
  background: var(--track-color, var(--ink-3));
}

/* ============================================================
   Stage — schedule + detail pane
   ============================================================ */

.stage {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: var(--ht-space-6);
  padding: var(--ht-space-6) var(--ht-space-10) var(--ht-space-10);
  flex: 1;
}

@media (max-width: 1100px) {
  .stage { grid-template-columns: 1fr; }
}

/* ============================================================
   Schedule grid
   ============================================================ */

.schedule {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--ht-radius-2xl);
  overflow: hidden;
  box-shadow: var(--ht-shadow-sm);
}

.schedule-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: var(--ht-space-5) var(--ht-space-6) var(--ht-space-4);
  border-bottom: 1px solid var(--line);
  gap: var(--ht-space-4);
}
.schedule-header .title {
  font-family: var(--ht-font-display);
  font-size: var(--ht-display-5);
  font-weight: 600;
  letter-spacing: var(--ht-track-display);
  color: var(--ink);
}
.schedule-header .meta {
  font-family: var(--ht-font-meta);
  font-size: var(--ht-text-sm);
  color: var(--ink-3);
}
.schedule-header em {
  font-style: normal;
  color: var(--ink);
  font-weight: 500;
}
.schedule-header .count {
  font-family: var(--ht-font-mono);
  font-size: 11px;
  color: var(--ink-3);
  text-transform: uppercase;
  letter-spacing: var(--ht-track-eyebrow);
}

.room-headers {
  display: grid;
  grid-template-columns: 64px repeat(3, minmax(0, 1fr));
  border-bottom: 1px solid var(--line);
  background: var(--ht-bg-subtle);
}
.room-headers .gutter-spacer {
  border-right: 1px solid var(--line);
}
.room-headers .room-col {
  padding: var(--ht-space-3) var(--ht-space-4);
  border-right: 1px solid var(--line);
}
.room-headers .room-col:last-child { border-right: 0; }
.room-headers .name {
  font-family: var(--ht-font-display);
  font-size: var(--ht-text-md);
  font-weight: 600;
  color: var(--ink);
  letter-spacing: var(--ht-track-display);
}
.room-headers .suite {
  font-family: var(--ht-font-meta);
  font-size: var(--ht-text-sm);
  color: var(--ink-3);
}

.grid-canvas {
  position: relative;
  background:
    linear-gradient(to right, var(--line) 1px, transparent 1px) 64px 0/var(--col-w, 33.33%) 100%,
    repeating-linear-gradient(to bottom, transparent 0, transparent calc(var(--row-h, 14px) * 12 - 1px), var(--line) calc(var(--row-h, 14px) * 12 - 1px), var(--line) calc(var(--row-h, 14px) * 12));
  background-color: var(--paper);
}

.time-gutter {
  position: absolute;
  left: 0;
  top: 0;
  width: 64px;
  height: 100%;
  border-right: 1px solid var(--line);
  background: var(--paper);
}
.time-gutter .hour {
  position: absolute;
  right: var(--ht-space-3);
  font-family: var(--ht-font-mono);
  font-size: 11px;
  color: var(--ink-3);
  transform: translateY(-50%);
}

.columns {
  display: grid;
  position: relative;
}

/* ============================================================
   Now indicator
   ============================================================ */

.now-line {
  position: absolute;
  height: 1px;
  width: calc(100% - 64px);
  background: var(--ht-danger);
  z-index: 5;
}
.now-line::before {
  content: "";
  position: absolute;
  left: -4px;
  top: -4px;
  width: 9px;
  height: 9px;
  border-radius: var(--ht-radius-full);
  background: var(--ht-danger);
}
.now-label {
  position: absolute;
  left: -56px;
  top: -8px;
  font-family: var(--ht-font-mono);
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: var(--ht-track-eyebrow);
  color: var(--ht-danger);
  background: var(--paper);
  padding: 2px 6px;
  border-radius: var(--ht-radius-sm);
}

/* ============================================================
   Session blocks
   ============================================================ */

.col {
  position: relative;
  border-left: 1px solid var(--line);
}
.col:first-child { border-left: 0; }

.block {
  position: absolute;
  left: 4px;
  right: 4px;
  padding: 6px 10px 4px;
  border-radius: var(--ht-radius-md);
  background: var(--paper);
  border: 1px solid var(--line-2);
  border-left: 3px solid var(--track-color, var(--ink-3));
  box-shadow: var(--ht-shadow-xs);
  cursor: pointer;
  transition:
    box-shadow var(--ht-dur-fast) var(--ht-ease-out-cubic),
    transform  var(--ht-dur-fast) var(--ht-ease-out-cubic),
    border-color var(--ht-dur-fast) var(--ht-ease-out-cubic);
  overflow: hidden;
  z-index: 1;
}
.block:hover {
  box-shadow: var(--ht-shadow-md);
  border-color: var(--track-color, var(--ink-2));
  z-index: 3;
}
.block.is-active {
  box-shadow: var(--ht-shadow-md), 0 0 0 2px color-mix(in oklab, var(--track-color, var(--ht-primary)) 30%, transparent);
  z-index: 3;
}
.block.is-muted { opacity: 0.45; }

.blk-track {
  font-family: var(--ht-font-mono);
  font-size: 9px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: var(--ht-track-eyebrow);
  color: var(--track-color, var(--ink-3));
  margin-bottom: 1px;
  line-height: 1.2;
}
.blk-title {
  font-family: var(--ht-font-body);
  font-size: 13px;
  font-weight: 500;
  color: var(--ink);
  line-height: 1.2;
  text-wrap: balance;
}
.blk-loc {
  font-family: var(--ht-font-meta);
  font-size: 11px;
  color: var(--ink-3);
  margin-top: 1px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.3;
}
.blk-time {
  font-family: var(--ht-font-mono);
  font-size: 10px;
  color: var(--ink-3);
  margin-top: 1px;
  white-space: nowrap;
  line-height: 1.3;
}

.blk-now {
  position: absolute;
  top: var(--ht-space-2);
  right: var(--ht-space-2);
  font-family: var(--ht-font-mono);
  font-size: 9px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: var(--ht-track-eyebrow);
  color: var(--ht-fg-on-dark);
  background: var(--ht-danger);
  padding: 2px 6px;
  border-radius: var(--ht-radius-sm);
}
.blk-tbd {
  position: absolute;
  top: var(--ht-space-2);
  right: var(--ht-space-2);
  font-family: var(--ht-font-mono);
  font-size: 9px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: var(--ht-track-eyebrow);
  color: var(--ht-warning);
  background: var(--ht-warning-bg);
  padding: 2px 6px;
  border-radius: var(--ht-radius-sm);
}

/* Break: muted, dotted divider feel */
.block.is-break {
  background: var(--ht-bg-subtle);
  border: 1px dashed var(--line-2);
  border-left: 1px dashed var(--line-2);
  box-shadow: none;
  display: flex;
  align-items: center;
  justify-content: center;
}
.block.is-break .blk-title {
  font-family: var(--ht-font-meta);
  font-size: var(--ht-text-sm);
  color: var(--ink-3);
  font-weight: 500;
}
.block.is-break:hover {
  background: var(--paper);
  border-color: var(--line-2);
  box-shadow: var(--ht-shadow-xs);
}

/* Travel: dashed border, transparent fill */
.block.is-travel {
  background: transparent;
  border-style: dashed;
  border-left-style: dashed;
  border-left-width: 1px;
  border-color: var(--line-2);
}

/* Ghost (e.g. SE floating across rooms) */
.block.is-ghost {
  background: color-mix(in oklab, var(--track-color) 4%, transparent);
  border: 1px dashed var(--track-color, var(--ink-3));
  border-left: 1px dashed var(--track-color, var(--ink-3));
}
.block.is-ghost .blk-title {
  font-style: italic;
  color: var(--ink-2);
  font-weight: 500;
}
.block.is-ghost:hover {
  background: var(--paper);
  border-style: solid;
}

/* ============================================================
   Detail pane
   ============================================================ */

.detail-pane {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--ht-radius-2xl);
  padding: var(--ht-space-6);
  box-shadow: var(--ht-shadow-sm);
  position: sticky;
  top: 84px;
  align-self: start;
  max-height: calc(100vh - 100px);
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}
.detail-pane.is-empty {
  justify-content: space-between;
  min-height: 360px;
}

.detail-empty-icon {
  width: 36px;
  height: 36px;
  border-radius: var(--ht-radius-md);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--ht-bg-subtle);
  color: var(--ink-3);
  margin-bottom: var(--ht-space-3);
}

.detail-empty h4 {
  font-family: var(--ht-font-display);
  font-size: var(--ht-text-lg);
  font-weight: 600;
  letter-spacing: var(--ht-track-display);
  margin: 0 0 var(--ht-space-2);
  color: var(--ink);
}
.detail-empty p {
  font-size: var(--ht-text-sm);
  color: var(--ink-3);
  margin: 0;
}

.hint {
  display: flex;
  align-items: center;
  gap: var(--ht-space-2);
  font-size: 11px;
  color: var(--ink-3);
  margin-top: var(--ht-space-6);
}

.detail-close {
  position: absolute;
  top: var(--ht-space-4);
  right: var(--ht-space-4);
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--ht-radius-md);
  color: var(--ink-3);
  transition: all var(--ht-dur-fast) var(--ht-ease-out-cubic);
}
.detail-close:hover {
  background: var(--ht-bg-subtle);
  color: var(--ink);
}

.detail-content {
  display: flex;
  flex-direction: column;
  gap: var(--ht-space-5);
}

.detail-track {
  display: flex;
  align-items: center;
  font-family: var(--ht-font-mono);
  font-size: var(--ht-meta);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: var(--ht-track-eyebrow);
  color: var(--track-color, var(--ink-3));
  margin-bottom: var(--ht-space-2);
}
.detail-track .dot {
  width: 6px; height: 6px;
  border-radius: var(--ht-radius-full);
  background: currentColor;
  margin-right: var(--ht-space-2);
}

.detail-title {
  font-family: var(--ht-font-display);
  font-size: var(--ht-display-4);
  font-weight: 600;
  letter-spacing: var(--ht-track-display);
  line-height: var(--ht-leading-snug);
  margin: 0 0 var(--ht-space-3);
  color: var(--ink);
  text-wrap: balance;
}

.detail-when {
  display: flex;
  align-items: center;
  gap: var(--ht-space-2);
  font-family: var(--ht-font-mono);
  font-size: var(--ht-text-sm);
  color: var(--ink-2);
}
.detail-when .duration {
  font-size: 11px;
  color: var(--ink-3);
  background: var(--ht-bg-subtle);
  border: 1px solid var(--line);
  padding: 2px var(--ht-space-2);
  border-radius: var(--ht-radius-sm);
}
.now-pill {
  display: inline-flex;
  align-items: center;
  font-family: var(--ht-font-mono);
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: var(--ht-track-eyebrow);
  color: var(--ht-fg-on-dark);
  background: var(--ht-danger);
  padding: 2px var(--ht-space-2);
  border-radius: var(--ht-radius-sm);
}

.detail-section h5 {
  font-family: var(--ht-font-meta);
  font-size: var(--ht-meta);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: var(--ht-track-eyebrow);
  color: var(--ink-3);
  margin: 0 0 var(--ht-space-2);
}

.detail-summary {
  font-family: var(--ht-font-body);
  font-size: var(--ht-text-md);
  line-height: var(--ht-leading-relaxed);
  color: var(--ink-2);
  margin: 0;
  text-wrap: pretty;
}

.detail-section {
  display: flex;
  flex-direction: column;
}

.logistics {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--ht-space-3) var(--ht-space-4);
  padding-top: var(--ht-space-4);
  border-top: 1px solid var(--line);
}
.logistics .label {
  font-family: var(--ht-font-meta);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: var(--ht-track-eyebrow);
  color: var(--ink-3);
  margin-bottom: 2px;
}
.logistics .value {
  font-family: var(--ht-font-body);
  font-size: var(--ht-text-md);
  color: var(--ink);
  font-weight: 500;
}

.tag-list { display: flex; flex-wrap: wrap; gap: var(--ht-space-1); }
.tag {
  font-family: var(--ht-font-meta);
  font-size: var(--ht-text-sm);
  font-weight: 500;
  padding: 2px var(--ht-space-2);
  border-radius: var(--ht-radius-sm);
  background: var(--ht-bg-subtle);
  color: var(--ink-2);
  border: 1px solid var(--line);
}

.outcomes {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--ht-space-2);
}
.outcome {
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: var(--ht-space-3);
  align-items: start;
  padding: var(--ht-space-3);
  background: var(--ht-bg-subtle);
  border: 1px solid var(--line);
  border-radius: var(--ht-radius-md);
}
.outcome-n {
  font-family: var(--ht-font-mono);
  font-size: 10px;
  font-weight: 600;
  color: var(--ht-fg-on-dark);
  background: var(--track-color, var(--ht-primary));
  width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--ht-radius-sm);
  letter-spacing: var(--ht-track-eyebrow);
}
.outcome-body { min-width: 0; }
.outcome-title {
  font-family: var(--ht-font-body);
  font-size: var(--ht-text-md);
  font-weight: 600;
  line-height: 1.25;
  color: var(--ink);
  margin-bottom: 2px;
}
.outcome-text {
  font-size: var(--ht-text-sm);
  line-height: var(--ht-leading-normal);
  color: var(--ink-2);
  text-wrap: pretty;
}

/* ============================================================
   Footer
   ============================================================ */

.footer {
  padding: var(--ht-space-6) var(--ht-space-10);
  border-top: 1px solid var(--line);
  font-family: var(--ht-font-meta);
  font-size: var(--ht-text-sm);
  color: var(--ink-3);
  display: flex;
  justify-content: space-between;
  gap: var(--ht-space-4);
  flex-wrap: wrap;
}
.footer a { color: var(--ht-primary); text-decoration: none; }
.footer a:hover { text-decoration: underline; }
