/* Timeline cards restyled after colleen/safety-card-bb: 12px corners, logo and
   uppercase name on a ruled row, uppercase date bottom-left, Source link
   bottom-right with the ticket-button arrow. Logos stay dark-on-light. */
#context-page .notice-event { border-radius: 12px; }
#context-page .notice-card { display: block; position: relative; height: 100%; min-height: 0; color: var(--navy); border-radius: 12px; padding: 10px 10px 34px; }
#context-page .notice-copy { display: block; }
#context-page .notice-meta {
  display: flex; align-items: center; justify-content: flex-start; gap: 9px;
  min-height: 0; margin: 0 0 11px; padding: 0 0 9px;
  border-bottom: 1px solid rgba(20, 45, 76, 0.15);
  font-size: 12px; font-weight: 800; line-height: 1.2; letter-spacing: .5px;
  text-transform: uppercase; color: var(--navy);
}
#context-page .notice-meta b { font: inherit; font-weight: 800; }
#context-page .notice-icon.logo-icon,
#context-page .notice-event.incident .notice-icon.logo-icon {
  position: static; flex: 0 0 18px; width: 18px; height: 18px; margin: 0;
  border-radius: 0; background: transparent; overflow: hidden;
}
#context-page .notice-icon.logo-icon img { filter: none; }
#context-page .notice-headline { font-size: 13.5px; line-height: 1.3; letter-spacing: -.2px; }
#context-page .notice-headline br { display: none; } /* wrap to the card width, not the old hard breaks */
#context-page .notice-meta time {
  position: absolute; top: auto; right: auto; left: 10px; bottom: 13px; margin: 0;
  font-size: 11px; font-weight: 800; letter-spacing: .5px; text-transform: uppercase;
  color: var(--accent); font-variant-numeric: normal;
}
#context-page .notice-event a.notice-source {
  /* stronger than the old whole-card link rules, which also match this anchor */
  position: absolute; top: auto; left: auto; right: 10px; bottom: 13px;
  display: inline-flex; align-items: center; gap: 3px;
  height: auto; min-height: 0; width: auto; padding: 0; margin: 0;
  border: 0; border-radius: 0; background: none; box-shadow: none;
  font-family: inherit;
  font-size: 10px; font-weight: 700; letter-spacing: .5px; text-transform: uppercase;
  line-height: 1.2; color: var(--navy);
  text-decoration: underline; text-decoration-color: var(--navy); text-underline-offset: 3px;
}
#context-page .notice-event a.notice-source .source-arrow { width: 11px; height: 11px; flex: none; }
#context-page .notice-event a.notice-source:hover { color: var(--accent); text-decoration-color: var(--accent); }
#context-page .notice-event a.notice-source:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 2px; }
@media (max-width: 850px) and (min-width: 651px) {
  #context-page .notice-card { padding: 10px 8px 30px; }
  #context-page .notice-meta { min-height: 0; padding: 0 0 9px; margin-bottom: 8px; font-size: 8px; gap: 7px; }
  #context-page .notice-icon.logo-icon,
  #context-page .notice-event.incident .notice-icon.logo-icon { flex-basis: 15px; width: 15px; height: 15px; }
  #context-page .notice-meta time { left: 8px; bottom: 11px; font-size: 9px; }
  #context-page .notice-event a.notice-source { right: 8px; bottom: 11px; font-size: 9px; }
}
@media (max-width: 650px) {
  #context-page .notice-card { display: block; min-height: 0; padding: 10px 14px 44px; }
  #context-page .notice-meta { min-height: 0; padding: 0 0 9px; margin-bottom: 12px; font-size: 12px; }
  #context-page .notice-icon.logo-icon,
  #context-page .notice-event.incident .notice-icon.logo-icon { flex-basis: 20px; width: 20px; height: 20px; }
  #context-page .notice-meta time { left: 14px; bottom: 15px; font-size: 12px; }
  #context-page .notice-event a.notice-source { right: 14px; bottom: 15px; font-size: 11px; }
}
/* Row heights: room for three-line headlines above the date row. The axis
   SVG stretches with the block, so the axis stays centred on the middle row. */
@media (min-width: 851px) {
  #context-page .notification-timeline { height: 364px; }
  #context-page .notice-events { grid-template-rows: 130px 104px 130px; width: 98%; column-gap: 10px; margin-inline: 0; }
  #context-page .notification-timeline .axis-months { top: 191px; }
}
@media (max-width: 850px) and (min-width: 651px) {
  #context-page .notification-timeline { height: 364px; }
  #context-page .notice-events { grid-template-rows: 130px 104px 130px; width: 98%; margin-inline: 0; gap: 0 6px; }
  #context-page .notification-timeline .axis-months { top: 191px; }
  #context-page .notice-headline { font-size: 10px; line-height: 1.15; letter-spacing: 0; }
  #context-page .notice-headline br { display: none; }
  #context-page .notice-meta { font-size: 8px; letter-spacing: .3px; gap: 7px; }
  #context-page .notice-meta time { font-size: 8px; }
  #context-page .notice-event a.notice-source { font-size: 8px; gap: 2px; }
  #context-page .notice-event a.notice-source .source-arrow { width: 9px; height: 9px; }
}
/* Narrow desktops: slightly smaller type so three-line headlines clear the date row. */
@media (min-width: 851px) and (max-width: 1100px) {
  #context-page .notice-headline { font-size: 11px; line-height: 1.22; letter-spacing: -.1px; }
  #context-page .notice-headline br { display: none; }
  #context-page .notice-meta { font-size: 9.5px; gap: 8px; }
  #context-page .notice-meta time { font-size: 10px; }
  #context-page .notice-event a.notice-source { font-size: 9px; }
  #context-page .notice-event a.notice-source .source-arrow { width: 10px; height: 10px; }
}
/* Closer text as in colleen/safety-card-bb: two stacked bold lines. */
body.airline #context-page .timeline-closer {
  display: block; margin-top: 18px; padding: 10px 0 0; border: 0; background: none; text-align: left;
}
body.airline #context-page .timeline-closer p {
  margin: 0; max-width: none; text-align: left;
  font: 700 16px/1.3 "Helvetica Neue", Helvetica, Arial, sans-serif;
  letter-spacing: normal; text-transform: none; color: #172d43;
}
body.airline #context-page .timeline-closer p + p { margin-top: 12px; }
body.airline #context-page .timeline-closer a {
  color: inherit; font-weight: 700; text-decoration: underline;
  text-decoration-color: currentColor; text-underline-offset: 3px;
}
/* Logos sit a hair higher against the names. */
#context-page .notice-icon.logo-icon,
#context-page .notice-event.incident .notice-icon.logo-icon { position: relative; top: -1px; left: 0; right: auto; }
/* You are here: three centred lines under the last dot, no bar. */
#context-page .axis-months .you-are-here { border: 0; background: none; }
@media (min-width: 601px) {
  #context-page .axis-months .you-are-here {
    position: absolute; left: 97.818%; right: auto; transform: translateX(-50%);
    display: block; width: min-content; padding: 0; text-align: center; white-space: normal;
    font-size: 10px; line-height: 1.1;
  }
}
/* Phones: the same cards as desktop, each tied to its spine dot by a dotted connector. */
@media (max-width: 650px) {
  #context-page .notice-event {
    border: 1px solid #142d4c66; border-radius: 12px; background: transparent; box-shadow: none;
    margin: 0 0 18px;
  }
  #context-page .notice-event:last-child { margin-bottom: 0; }
  /* dot centred on the logo (card padding 10 + half of the 20px logo, nudged 1px up) */
  #context-page .notice-event::before { top: 12.5px; z-index: 1; }
  /* connector runs from the dot's edge to the card border, underneath the dot */
  #context-page .notice-event::after {
    content: ''; position: absolute; left: -19px; width: 19px; top: 18px; height: 0;
    border-top: 1.5px dotted var(--navy); z-index: 0;
  }
}

#context-page .timeline-title-line { display: block; }

/* A late addition, laid over the end of the timeline like a pasted-on note. */
#context-page .timeline-last-minute {
  position: absolute;
  z-index: 2;
  top: 140px;
  right: -30px;
  width: 166px;
  padding: 12px 14px 13px;
  color: var(--paper);
  background: var(--accent);
  border: 2px solid var(--navy);
  border-radius: 2px;
  box-shadow: 4px 5px 0 #142d4c;
  transform: rotate(5deg);
  text-decoration: none;
  transition: transform .15s ease, box-shadow .15s ease;
}
#context-page .timeline-last-minute .notice-meta {
  display: flex;
  align-items: center;
  gap: 5px;
  min-height: 0;
  margin: 0 0 7px;
  padding: 0 0 5px;
  border-color: #f8f7f266;
  color: inherit;
  font: 500 10px/1.2 'IBM Plex Mono', monospace;
  letter-spacing: .08em;
}
#context-page .last-minute-title {
  display: block;
  font: 700 25px/1.06 'Barlow Condensed', 'Arial Narrow', sans-serif;
  letter-spacing: .01em;
}
#context-page .last-minute-first-line { display: flex; align-items: center; gap: 7px; white-space: nowrap; }
#context-page .last-minute-arrow { position: static; width: 19px; height: 19px; flex: none; }
#context-page .timeline-last-minute:hover { transform: rotate(4deg) translateY(-2px); box-shadow: 5px 7px 0 #142d4c; }
#context-page .timeline-last-minute:focus-visible { outline: 3px solid var(--navy); outline-offset: 6px; }
@media (min-width: 651px) {
  body.airline #context-page { overflow: visible; }
  #context-page .notification-timeline { margin-top: 28px; }
  #context-page .timeline-last-minute { top: -122px; right: 2%; }
  #context-page .notification-timeline .axis-months { top: 191px; }
}
#context-page .timeline-late-entry { display: contents; }
@media (max-width: 650px) {
  #context-page .timeline-late-entry { display: block; position: relative; margin: 0 0 0 9px; padding: 26px 0 28px 24px; border-left: 3px solid var(--navy); }
  #context-page .timeline-late-entry::before { content: ''; position: absolute; left: -8px; top: 44px; width: 13px; height: 13px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 1px var(--paper); z-index: 1; }
  #context-page .timeline-late-entry::after { content: ''; position: absolute; left: 0; top: 50px; width: 36px; border-top: 1.5px dotted var(--navy); }
  #context-page .timeline-last-minute { position: relative; display: block; top: auto; right: auto; width: 180px; margin: 0; transform-origin: bottom left; }
}
@media (prefers-reduced-motion: reduce) {
  #context-page .timeline-last-minute { transition: none; }
}

#context-page .timeline-last-minute .last-minute-warning { width: 13px; height: 13px; flex: none; margin: 0; border: 0; filter: none; }

#context-page .timeline-bottom-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 32px; }
#context-page .timeline-legend { flex: 0 0 auto; max-width: 100%; margin: 28px 0 0; text-align: left; color: var(--navy); }
#context-page .timeline-legend h3 { margin: 0 0 6px 4px; font: 700 11px/1.4 'Barlow Condensed', 'Arial Narrow', sans-serif; letter-spacing: .04em; }
#context-page .timeline-legend p { display: flex; align-items: baseline; gap: 7px; margin: 0; font: 400 12px/1.4 'Helvetica Neue', Helvetica, Arial, sans-serif; }
#context-page .timeline-legend-swatch { display: block; flex: 0 0 10px; width: 10px; height: 10px; background: var(--accent); border: 1px solid var(--navy); box-sizing: border-box; }

@media (max-width: 850px) {
 #context-page .timeline-bottom-row { flex-direction: column; gap: 0; }
 #context-page .timeline-legend { align-self: flex-end; margin-top: 22px; }
}

@media (min-width: 651px) {
  #context-page .timeline-bottom-row { width: 98%; }
}

/* The outer row supplies the shared spacing before the footer divider. */
body.airline #context-page .timeline-bottom-row .timeline-closer { margin-bottom: 0; }

#context-page .timeline-legend-swatch-events { background: var(--paper); }
#context-page .timeline-legend p + p { margin-top: 6px; }

/* Recent additions sit above and below the desktop timeline. */
#context-page .timeline-late-cards { display: flex; justify-content: flex-end; gap: 26px; }
#context-page .timeline-late-cards .timeline-last-minute { position: relative; top: auto; right: auto; flex: 0 0 166px; margin: 0; }
@media (min-width: 651px) {
  #context-page > h2 { padding-right: 200px; }
  #context-page .notification-timeline { margin-top: 28px; margin-bottom: 150px; }
  #context-page .timeline-late-cards { display: contents; }
  #context-page .timeline-late-cards .timeline-last-minute { position: absolute; right: 2%; }
  #context-page .timeline-late-cards [data-late-card="hacktron"] { top: -122px; }
  #context-page .timeline-late-cards [data-late-card="google"] { top: calc(100% + 20px); }
}
#context-page .timeline-late-cards { display: contents; }


@media (min-width: 851px) {
 #context-page .notification-timeline { margin-bottom: 8px; }
 #context-page .timeline-bottom-row { display: grid; grid-template-columns: minmax(0, 1fr) max-content; column-gap: 240px; padding-right: 0; min-height: 130px; box-sizing: border-box; }
 #context-page .timeline-legend { justify-self: end; }
 #context-page .timeline-late-cards [data-late-card="google"] { right: calc(2% + 164px); }
}
@media (max-width: 850px) {
 #context-page .timeline-legend { align-self: flex-end; }
}

@media (max-width: 650px) {
  #context-page .timeline-last-minute,
  #context-page .timeline-last-minute:hover { transform: none; }
  /* Same 1.5px rounded stroke and 2/5 dash pattern as the desktop SVG. */
  #context-page .notice-event::after,
  #context-page .timeline-late-entry::after {
    height: 3px;
    border: 0;
    transform: translateY(-.75px);
    background: var(--navy);
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='7' height='3' viewBox='0 0 7 3'%3E%3Cpath d='M0 1.5H7' fill='none' stroke='black' stroke-width='1.5' stroke-dasharray='2 5' stroke-linecap='round'/%3E%3C/svg%3E") repeat-x left center;
  }
}

@media (max-width: 650px) {
  #context-page .timeline-bottom-row .timeline-legend { order: -1; align-self: flex-start; margin-top: 12px; }
}

@media (max-width: 650px) {
  #context-page .notice-events {
    border-left-color: transparent;
    background: linear-gradient(var(--navy), var(--navy)) left 22px / 3px calc(100% - 22px) no-repeat;
    background-origin: border-box;
  }
  #context-page .notification-timeline .axis-months {
    border-left-color: transparent;
    height: auto;
    background: linear-gradient(var(--navy), var(--navy)) left top / 3px calc(100% - 9.5px) no-repeat;
    background-origin: border-box;
  }
  #context-page .notification-timeline .axis-months::before { top: 20px; bottom: auto; margin: 0; transform: none; }
  #context-page .axis-months .you-are-here { line-height: 19px; }
}

@media (max-width: 650px) {
  #context-page .timeline-legend p { margin-left: 4px; }
}
