:root {
  --crew-bg: #190e21;
  --crew-panel: #24132c;
  --crew-border: #684e66;
  --crew-ink: #f4ebdc;
  --crew-muted: #c8b9c7;
  --crew-school: #642483;
  --crew-gold: #edc66c;
  --crew-header-from: #38203e;
  --crew-header-to: #22112a;
  --crew-control: #35203e;
  --crew-bubble: #3b2543;
  --crew-input: #140b1a;
  --crew-accent-ink: #241829;
}
.crew-weather {
  margin: 16px 0;
  padding: 20px;
  border: 1px solid var(--crew-border);
  border-radius: 14px;
  background: var(--crew-panel);
  color: var(--crew-ink);
  font:
    16px/1.5 Arial,
    sans-serif;
  overflow-wrap: anywhere;
}
.crew-weather a {
  color: var(--crew-gold);
}
.crew-weather-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.crew-weather-grid strong {
  display: block;
  font-size: 22px;
}
.crew-weather-grid strong.is-missing {
  font-size: 14px;
  white-space: nowrap;
}
.crew-weather-grid span,
.crew-weather small {
  display: block;
  font-size: 13px;
}
.crew-weather summary {
  cursor: pointer;
  min-height: 44px;
  padding: 10px 0;
}
.crew-weather-alert {
  border-top: 1px solid var(--crew-gold);
}
.crew-weather-alert p {
  white-space: pre-line;
}
.crew-school-weather {
  margin-top: 24px;
}
.crew-school-weather select {
  max-width: 100%;
  min-height: 44px;
  font-size: 16px;
}
#school-map:has(.crew-destination) > .crew-school-weather {
  display: none;
}
.crew-event-meta {
  font-size: 14px;
}
.crew-form label.crew-confirm {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}
.crew-form .crew-confirm input {
  width: 24px;
  height: 24px;
  min-height: 24px;
  margin: 0;
  flex: none;
}
.my-yard-page
  .yn-dashboard[data-active-school="southern"]
  [data-dashboard-school="southern"][aria-pressed="true"] {
  color: #190e21;
}
.yn-map-panel,
.hc-map-wrap {
  position: relative;
  isolation: isolate;
}
@media (max-width: 390px) {
  .crew-weather-grid {
    grid-template-columns: 1fr 1fr;
  }
  .crew-weather-grid > div:last-child {
    grid-column: 1/-1;
  }
  .crew-weather {
    padding: 16px;
  }
}
.crew-shell,
.crew-preview {
  color: var(--crew-ink);
  font-family: Arial, Helvetica, sans-serif;
  line-height: 1.5;
  font-size: 16px;
  color-scheme: dark;
}
.crew-shell *,
.crew-preview * {
  box-sizing: border-box;
}
.crew-shell[hidden],
.crew-shell [hidden] {
  display: none !important;
}
.crew-open {
  overflow: hidden;
  background: var(--crew-bg) !important;
}
.crew-open > :not(.crew-shell) {
  display: none !important;
}
.crew-shell {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: radial-gradient(
    ellipse at top,
    var(--crew-header-from),
    var(--crew-bg) 70%
  );
  display: flex;
  justify-content: center;
  padding: 28px 20px;
  height: var(--crew-height, 100dvh);
  top: var(--crew-top, 0px);
}
.crew-panel {
  width: min(100%, 900px);
  min-width: 0;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--crew-border);
  background: var(--crew-bg);
  border-radius: 22px;
  overflow: hidden;
  box-shadow: 0 22px 100px #09040db0;
}
.crew-header {
  flex: none;
  padding: 24px 32px 22px;
  border-bottom: 1px solid var(--crew-border);
  background: linear-gradient(
    130deg,
    var(--crew-header-from),
    var(--crew-header-to)
  );
}
.crew-topline {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
}
.crew-eyebrow {
  font-size: 12px;
  letter-spacing: 0.18em;
  font-weight: 700;
  margin: 0;
  text-transform: uppercase;
  color: var(--crew-gold);
}
.crew-titleline {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}
.crew-title {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.04;
  letter-spacing: -0.035em;
  margin: 12px 0 10px;
  overflow-wrap: anywhere;
  max-width: 650px;
}
.crew-members-button {
  display: flex !important;
  align-items: center;
  gap: 12px !important;
  border: 0 !important;
  padding: 0 !important;
  background: none !important;
  color: var(--crew-muted) !important;
  text-align: left;
  min-height: 44px;
}
.crew-avatars {
  display: flex;
  padding-left: 0;
}
.crew-avatar {
  display: grid;
  place-items: center;
  background: var(--crew-control);
  border: 2px solid var(--crew-bg);
  border-radius: 50%;
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  font-size: 12px;
  font-weight: bold;
  color: var(--crew-ink);
  overflow: hidden;
  object-fit: cover !important;
  max-width: none !important;
  aspect-ratio: 1;
}
.crew-avatars .crew-avatar + .crew-avatar {
  margin-left: -11px;
}
.crew-avatar img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
}
.crew-shell button,
.crew-shell a.crew-primary,
.crew-preview a.crew-primary {
  font: inherit;
  cursor: pointer;
  min-height: 44px;
  min-width: 44px;
  padding: 9px 14px;
  border: 1px solid var(--crew-border);
  border-radius: 10px;
  color: var(--crew-ink);
  background: var(--crew-control);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  line-height: 1.4;
}
.crew-shell button:hover {
  border-color: var(--crew-gold);
}
.crew-shell button:disabled {
  opacity: 0.55;
  cursor: wait;
}
.crew-shell .crew-primary,
.crew-preview .crew-primary {
  background: var(--crew-gold) !important;
  color: var(--crew-accent-ink) !important;
  border-color: var(--crew-gold) !important;
  font-weight: 700 !important;
}
.crew-shell :focus-visible,
.crew-destination :focus-visible {
  outline: 3px solid var(--crew-gold);
  outline-offset: 3px;
}
.crew-shell .crew-back {
  background: none;
  border: 0;
  padding-left: 0;
  color: var(--crew-gold);
}
.crew-stream {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 26px 32px;
  scrollbar-color: var(--crew-border) transparent;
  scroll-padding-bottom: 20px;
}
.crew-day {
  text-align: center;
  font-size: 12px;
  letter-spacing: 0.12em;
  color: var(--crew-muted);
  text-transform: uppercase;
  margin: 0 0 24px;
}
.crew-message {
  display: flex;
  gap: 10px;
  align-items: flex-end;
  margin: 0 0 24px;
  min-width: 0;
}
.crew-message.own {
  flex-direction: row-reverse;
}
.crew-message-main {
  max-width: 78%;
  min-width: 0;
}
.crew-message.own .crew-message-main {
  max-width: 80%;
}
.crew-sender {
  font-size: 13px;
  margin: 0 0 6px;
  color: var(--crew-muted);
}
.crew-bubble {
  padding: 15px 18px;
  background: var(--crew-bubble);
  border: 1px solid var(--crew-border);
  border-radius: 18px 18px 18px 4px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  line-height: 1.55;
}
.own .crew-bubble {
  background: var(--crew-school);
  border-color: var(--crew-gold);
  border-radius: 18px 18px 4px 18px;
}
.crew-message-meta {
  font-size: 12px;
  color: var(--crew-muted);
  margin: 6px 2px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}
.own .crew-message-meta {
  justify-content: flex-end;
}
.crew-message-meta button {
  font-size: 12px;
  min-height: 32px;
  padding: 3px 8px;
}
.crew-location {
  border: 1px solid var(--crew-gold);
  border-radius: 15px;
  background: var(--crew-panel);
  overflow: hidden;
  min-width: 0;
  width: 340px;
  max-width: 100%;
}
.crew-location-head {
  padding: 18px 18px 14px;
}
.crew-location h3 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 23px;
  line-height: 1.15;
  margin: 10px 0;
  overflow-wrap: anywhere;
  color: var(--crew-ink);
}
.crew-location p {
  margin: 5px 0;
  font-size: 13px;
  color: var(--crew-muted);
  overflow-wrap: anywhere;
}
.crew-location .crew-eyebrow {
  color: var(--crew-gold);
  font-size: 12px;
}
.crew-map-preview {
  height: 142px;
  background: var(--crew-control);
  position: relative;
  isolation: isolate;
}
.crew-map-preview .leaflet-control-attribution {
  font-size: 9px !important;
}
.crew-map-preview.leaflet-container {
  font-family: inherit;
}
.crew-map-preview img.leaflet-tile,
.leaflet-pane img.leaflet-tile {
  max-width: none !important;
  max-height: none !important;
  width: 256px !important;
  height: 256px !important;
  border: 0 !important;
  border-radius: 0 !important;
  object-fit: fill !important;
  aspect-ratio: auto !important;
  filter: none !important;
}
.crew-location-foot {
  padding: 14px 16px;
}
.crew-location-foot a {
  width: 100%;
  font-size: 14px;
}
.crew-location-foot small {
  display: block;
  color: var(--crew-muted);
  font-size: 12px;
  margin-top: 10px;
}
.crew-location-actions {
  display: flex;
  gap: 7px;
  flex-wrap: wrap;
  margin-top: 10px;
}
.crew-location-actions button {
  font-size: 12px;
  min-height: 36px;
  padding: 5px 9px;
}
.crew-image {
  display: block;
  max-width: 100% !important;
  width: auto;
  max-height: 350px;
  object-fit: contain;
  border-radius: 12px;
}
.crew-composer {
  flex: none;
  padding: 14px 24px max(16px, env(safe-area-inset-bottom));
  border-top: 1px solid var(--crew-border);
  background: var(--crew-panel);
}
.crew-compose-row {
  display: flex;
  align-items: flex-end;
  gap: 10px;
}
.crew-compose-row textarea {
  flex: 1;
  min-width: 0;
  resize: none;
  height: 48px;
  max-height: 120px;
  background: var(--crew-input);
  color: var(--crew-ink);
  font: inherit;
  padding: 12px 14px;
  border: 1px solid var(--crew-border);
  border-radius: 12px;
  line-height: 1.4;
}
.crew-status {
  font-size: 12px;
  color: var(--crew-muted);
  margin: 8px 0 0;
  min-height: 18px;
}
.crew-status:empty {
  display: none;
}
.crew-notice {
  padding: 9px 24px;
  background: var(--crew-control);
  color: var(--crew-ink);
  font-size: 13px;
  border-bottom: 1px solid var(--crew-border);
  flex: none;
}
.crew-form {
  display: grid;
  gap: 18px;
  max-width: 560px;
  margin: 16px auto;
}
.crew-form label {
  display: grid;
  gap: 6px;
  font-size: 14px;
  color: var(--crew-ink);
}
.crew-form input,
.crew-form select,
.crew-form textarea {
  width: 100%;
  font: inherit;
  padding: 12px;
  min-height: 46px;
  border: 1px solid var(--crew-border);
  border-radius: 9px;
  background: var(--crew-input);
  color: var(--crew-ink);
}
.crew-form h2 {
  font:
    30px/1.15 Georgia,
    serif;
  margin: 8px 0;
}
.crew-form p {
  margin: 0;
}
.crew-muted {
  color: var(--crew-muted);
  font-size: 14px;
}
.crew-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.crew-room {
  display: flex !important;
  justify-content: space-between !important;
  width: 100%;
  text-align: left;
  gap: 18px !important;
  margin-bottom: 14px;
  padding: 18px !important;
}
.crew-room strong {
  display: block;
  font:
    23px Georgia,
    serif;
}
.crew-room small {
  display: block;
  margin-top: 8px;
  font-size: 13px;
  color: var(--crew-muted);
}
.crew-dialog {
  background: var(--crew-panel);
  color: var(--crew-ink);
  border: 1px solid var(--crew-border);
  border-radius: 18px;
  width: min(560px, calc(100vw - 24px));
  max-height: 85dvh;
  overflow: auto;
  padding: 22px;
  font-family: Arial, sans-serif;
}
.crew-dialog::backdrop {
  background: #0c0716c9;
}
.crew-dialog-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
}
.crew-dialog-head h2 {
  font:
    28px Georgia,
    serif;
  margin: 0;
}
.crew-dialog .crew-form {
  margin-bottom: 0;
}
.crew-member {
  display: flex;
  gap: 12px;
  align-items: center;
  margin: 18px 0;
}
.crew-member p {
  margin: 0;
}
.crew-member small {
  display: block;
  color: var(--crew-muted);
}
.crew-link-output {
  width: 100%;
  background: var(--crew-input);
  color: var(--crew-ink);
  border: 1px solid var(--crew-border);
  padding: 10px;
  font-size: 14px;
}
.crew-inline-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.crew-destination {
  padding: 24px;
  background: #24132c;
  border: 1px solid #b79968;
  border-radius: 16px;
  color: #f4ebdc;
  margin: 0 0 22px;
  position: relative;
}
.crew-destination h2 {
  font:
    32px/1.1 Georgia,
    serif;
  margin: 12px 0;
}
.crew-destination p {
  color: #d4c8d3;
  font-size: 15px;
}
.crew-destination a,
.crew-destination button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border: 1px solid #b79968;
  padding: 10px 15px;
  border-radius: 9px;
  background: #edc66c;
  color: #241829;
  font: 700 14px Arial;
  text-decoration: none;
  cursor: pointer;
  margin: 5px;
}
.crew-destination .crew-return {
  background: transparent;
  color: #f4ebdc;
}
.crew-destination [role="status"] {
  min-height: 22px;
}
.crew-pin {
  width: 24px !important;
  height: 24px !important;
  background: var(--crew-gold) !important;
  border: 4px solid #241829 !important;
  border-radius: 50% !important;
  box-shadow: 0 0 0 4px #edc66c66;
}
.crew-visitor-pin {
  background: #75bee4 !important;
}
.crew-preview {
  margin: 0;
  min-height: 100dvh;
  display: grid;
  place-items: center;
  background: var(--crew-bg);
  padding: 24px;
}
.crew-preview-card {
  max-width: 540px;
  border: 1px solid var(--crew-border);
  border-radius: 20px;
  padding: 36px;
}
.crew-preview h1 {
  font:
    54px Georgia,
    serif;
  margin: 20px 0;
}
@media (max-width: 600px) {
  .crew-shell {
    padding: 0;
  }
  .crew-panel {
    border: 0;
    border-radius: 0;
    width: 100%;
  }
  .crew-header {
    padding: max(18px, env(safe-area-inset-top)) 20px 18px;
  }
  .crew-topline {
    margin-bottom: 16px;
  }
  .crew-title {
    font-size: 32px;
    max-width: 100%;
    margin: 10px 0;
  }
  .crew-stream {
    padding: 22px 16px;
  }
  .crew-message {
    gap: 7px;
    margin-bottom: 24px;
  }
  .crew-message > .crew-avatar {
    width: 29px;
    height: 29px;
    flex-basis: 29px;
    font-size: 10px;
  }
  .crew-message-main,
  .crew-message.own .crew-message-main {
    max-width: calc(100% - 36px);
  }
  .crew-bubble {
    padding: 13px 15px;
  }
  .crew-composer {
    padding: 12px 14px max(14px, env(safe-area-inset-bottom));
  }
  .crew-compose-row {
    gap: 8px;
  }
  .crew-compose-row button {
    padding: 10px;
    min-width: 44px;
  }
  .crew-form {
    margin: 10px 0;
  }
  .crew-grid {
    grid-template-columns: 1fr;
  }
  .crew-notice {
    padding: 8px 18px;
  }
  .crew-location {
    width: 316px;
  }
  .crew-location-head {
    padding: 15px;
  }
  .crew-map-preview {
    height: 133px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .crew-shell * {
    scroll-behavior: auto !important;
    transition: none !important;
    animation: none !important;
  }
}
/* Location actions live in an accessible menu so the actual destination stays prominent. */
.crew-location-open {
  display: flex;
  gap: 8px;
}
.crew-location-open a {
  flex: 1;
  min-width: 0;
}
.crew-location-open button {
  flex: 0 0 44px;
  padding: 6px;
}
@media (max-width: 600px) {
  .crew-header {
    padding-bottom: 12px;
  }
  .crew-topline {
    margin-bottom: 8px;
  }
  .crew-title {
    font-size: 30px;
    margin: 5px 0 8px;
  }
  .crew-header .crew-eyebrow {
    font-size: 11px;
  }
  .crew-topline .crew-back {
    min-height: 36px;
  }
  .crew-message {
    margin-bottom: 18px;
  }
  .crew-location-head {
    padding: 13px 15px 10px;
  }
  .crew-location h3 {
    font-size: 22px;
    margin: 7px 0;
  }
  .crew-map-preview {
    height: 116px;
  }
  .crew-location-foot {
    padding: 12px 14px;
  }
  .crew-location-foot small {
    margin-top: 7px;
  }
  .crew-day {
    margin-bottom: 15px;
  }
}
@media (min-width: 415px) and (max-width: 600px) {
  .crew-header {
    padding-top: 12px;
    padding-bottom: 8px;
  }
  .crew-topline {
    margin-bottom: 4px;
  }
  .crew-stream {
    padding-top: 16px;
    padding-bottom: 16px;
  }
  .crew-message {
    margin-bottom: 12px;
  }
  .crew-day {
    margin-bottom: 10px;
  }
  .crew-map-preview {
    height: 105px;
  }
  .crew-location p {
    margin: 2px 0;
  }
}
/* Shared destinations use the retained map immediately below this compact directions card. */
@media (min-width: 1000px) {
  .crew-header {
    padding: 16px 28px 12px;
  }
  .crew-topline {
    margin-bottom: 10px;
  }
  .crew-title {
    font-size: 36px;
    margin: 6px 0 8px;
  }
  .crew-stream {
    padding: 18px 28px;
  }
  .crew-day {
    margin-bottom: 14px;
  }
  .crew-message {
    margin-bottom: 14px;
  }
  .crew-bubble {
    padding: 11px 16px;
  }
  .crew-location {
    width: 520px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }
  .crew-location-head {
    padding: 14px 16px;
  }
  .crew-map-preview {
    height: 100%;
    min-height: 150px;
  }
  .crew-location-foot {
    grid-column: 1/-1;
    padding: 12px 16px;
  }
}
.hc-map-section:has(.crew-destination) > .hc-section-head {
  display: none;
}
.hc-map-section:has(.crew-destination) .hc-map-controls,
.hc-map-section:has(.crew-destination) .hc-map-sidebar,
.hc-map-section:has(.crew-destination) .hc-upload-bar {
  display: none;
}
.hc-map-section:has(.crew-destination) .hc-map-layout {
  grid-template-columns: minmax(0, 1fr);
}
.crew-destination .crew-event-meta a {
  background: none;
  color: #edc66c;
  border: 0;
  padding: 0;
  text-decoration: underline;
}
.crew-destination {
  padding: 18px;
}
.crew-destination h2 {
  font-size: 27px;
  margin: 8px 0;
}
.crew-destination p {
  font-size: 14px;
  line-height: 1.4;
  margin: 7px 0;
}
.crew-destination a,
.crew-destination button {
  font-size: 13px;
  padding: 9px 10px;
  margin: 4px 2px;
}
.crew-destination .crew-eyebrow {
  font-size: 12px;
}
