/* LMB Ride Calendar – ride colors for every view, month ads, sticky sidebar ads, map pop-ups.
   CATEGORY COLORS are NOT set here. They come from lmb_color_scheme() in
   mu-plugins/lmb-ride-calendar.php, which outputs --lmb-cat-bg / --lmb-cat-fg / --lmb-cat-accent
   for each colored category. Rides without a colored category are white. */
:root {
  --lmb-blue: #0b5a8a;
  --lmb-text: #23272d;
  --lmb-font: "Montserrat", sans-serif;
}

/* ---------- LIST VIEW (tiles) ---------- */
.lmb-ride-list__month { margin: 50px 0 0; }
.lmb-ride-list__month:first-child { margin-top: 20px; }
.lmb-ride-list__grid { display: flex; flex-wrap: wrap; }

.lmb-ride-card {
  display: block;
  width: 100%;
  margin: 5px 0.5%;
  padding: 1.5%;
  color: var(--lmb-cat-fg, var(--lmb-text));
  background-color: var(--lmb-cat-bg, #fff); /* no category color = white */
  border: var(--lmb-cat-border-w, 1px) solid var(--lmb-cat-border, #d5dbe1);
  /* Future color-coding hook: set --lmb-ride-strip to draw a strip on the card's left edge. */
  box-shadow: inset 6px 0 0 var(--lmb-ride-strip, transparent);
  transition: 0.3s;
}
@media (min-width: 600px) {
  .lmb-ride-card { width: 24%; margin: 10px 0.5%; }
}
.lmb-ride-list .lmb-ride-card .lmb-ride-card__link,
.lmb-ride-list .lmb-ride-card .lmb-ride-card__link:hover,
.lmb-ride-list .lmb-ride-card .lmb-ride-card__link:focus { display: block; height: 100%; color: inherit !important; text-decoration: none; }

.lmb-ride-card__category {
  position: relative;
  margin-bottom: 10px;
  padding: 0 0 5px;
  font-family: var(--lmb-font);
  font-size: 14px;
  color: var(--lmb-cat-accent, var(--lmb-text));
}
.lmb-ride-card__category::after {
  content: "";
  position: absolute; left: 0; bottom: 0;
  width: 40%; height: 2px;
  background-color: var(--lmb-cat-accent, var(--lmb-blue));
}
.lmb-ride-card__date  { font-family: var(--lmb-font); font-size: 18px; color: var(--lmb-cat-fg, var(--lmb-blue)); }
.lmb-ride-card__title { font-family: var(--lmb-font); font-size: 16px; margin: 10px 0; color: var(--lmb-cat-fg, var(--lmb-text)); }
.lmb-ride-card__description { display: none; font-size: 14px; }
.lmb-ride-card__location { margin: 10px 0 0; font-size: 14px; }
.lmb-ride-card:hover .lmb-ride-card__title,
.lmb-ride-card:focus-within .lmb-ride-card__title { color: var(--lmb-cat-accent, var(--lmb-blue)); }

/* Paid ($1/$2/$5) and LMB tiles show the short description */
.lmb-cat-dollar-per-rider .lmb-ride-card__description,
.lmb-cat-two-dollar-per-rider .lmb-ride-card__description,
.lmb-cat-five-dollar-per-rider .lmb-ride-card__description,
.lmb-cat-lmb-event .lmb-ride-card__description,
.lmb-cat-lmb-cohosted .lmb-ride-card__description { display: block; }

/* Cancelled */
.lmb-ride-card--cancelled-event { opacity: 0.6; }
.lmb-ride-card--cancelled-event .lmb-ride-card__title { text-decoration: line-through; }

/* Between-month ad tile (same size as a ride card, as before) */
.lmb-ride-card--ad { padding: 0; background: none; box-shadow: none; display: flex; align-items: center; justify-content: center; }
.lmb-ride-card--ad img { display: block; max-width: 100%; height: auto; }

/* ---------- GROUPED LIST + GRID: color the calendar leaf below its line ---------- */
/* Only rides with a category color (lmb-cat-… plus a defined --lmb-cat-bg) get a filled leaf. */
.em-item.lmb-cat-dollar-per-rider .em-item-image-placeholder,
.em-item.lmb-cat-two-dollar-per-rider .em-item-image-placeholder,
.em-item.lmb-cat-five-dollar-per-rider .em-item-image-placeholder,
.em-item.lmb-cat-lmb-event .em-item-image-placeholder,
.em-item.lmb-cat-lmb-cohosted .em-item-image-placeholder { opacity: 1 !important; } /* EM fades leaves to 45% */
.em-item[class*="lmb-cat-"] .em-item-image-placeholder { position: relative; }
.em-item[class*="lmb-cat-"] .em-item-image-placeholder::before {
  content: "";
  position: absolute;
  /* matches the leaf drawing: below the binding line, inside the outline */
  top: 29%; right: 3.2%; bottom: 4.8%; left: 3.2%;
  border-radius: 0 0 5px 5px;
  background-color: var(--lmb-cat-bg);
  box-shadow: inset 0 0 0 var(--lmb-cat-border-w, 1px) var(--lmb-cat-border, transparent); /* outline for white cards (LMB Co-Hosted) */
}
.em-item[class*="lmb-cat-"] .em-item-image-placeholder .date { position: relative; z-index: 1; }
.em-item[class*="lmb-cat-"] .em-item-image-placeholder .date span { color: var(--lmb-cat-fg); }

/* ---------- MAP pin pop-up ---------- */
.lmb-map-popup { min-width: 200px; max-width: 280px; font-size: 14px; line-height: 1.35; }
.lmb-map-popup__ride { margin: 0 0 8px; padding-left: 8px; border-left: 4px solid var(--lmb-cat-border, #d5dbe1); }
.lmb-map-popup__date { color: #5a6472; font-size: 13px; }
.lmb-map-popup__more { margin: 0 0 8px; font-size: 13px; }
.lmb-map-popup__place { margin-top: 6px; padding-top: 6px; border-top: 1px solid #d5dbe1; color: #5a6472; font-size: 13px; }

/* ---------- Sidebar ads stay in view while scrolling (desktop only) ---------- */
@media (min-width: 700px) {
  .two-columns > .sidebar.ads { position: sticky; top: 20px; align-self: flex-start; }
}

/* ---------- Add/Edit a Ride form: Ride Type checkboxes ---------- */
.lmb-ride-type-field { border: 0; margin: 0 0 20px; padding: 0; }
.lmb-ride-type-field__legend { font-weight: bold; margin-bottom: 4px; }
.lmb-ride-type-field .field-description { margin: 0 0 8px; font-size: 14px; }
.lmb-ride-type-field__option { display: block; margin: 4px 0; font-weight: normal; cursor: pointer; }
.lmb-ride-type-field__option input { margin-right: 6px; width: auto; }
.lmb-category-field { border: 0; margin: 0 0 20px; padding: 0; }
.lmb-category-field__child { margin-left: 22px; }
.lmb-dpr-tiers { margin: 2px 0 8px 22px; }
.lmb-dpr-tiers .field-description { margin: 0 0 2px; font-size: 14px; }

/* Option name on the first line, a short description under it.
   (Selectors repeat the class so they beat the theme's ".event-attributes label" rule.) */
.lmb-ride-type-field label.lmb-ride-type-field__option { display: grid !important; grid-template-columns: auto 1fr; column-gap: 8px; align-items: baseline; width: auto; max-width: 560px; text-align: left; margin: 6px 0; padding: 0; vertical-align: top; font-weight: normal; }
.lmb-ride-type-field label.lmb-ride-type-field__option input { grid-row: 1 / span 2; margin: 0 !important; width: auto; position: static; }
.lmb-ride-type-field label.lmb-ride-type-field__option .lmb-option__desc { display: block; }
.lmb-option__name { font-weight: 600; }
.lmb-option__desc { grid-column: 2; font-size: 13px; color: #5a6472; line-height: 1.35; }
.lmb-ride-type-field .field-description, .lmb-reveal .field-description { padding-left: 0; }
.lmb-form-block { margin: 0 0 22px; }
/* Boxes that open under a ticked checkbox (Dollar Per Rider amounts, repeat schedule, volunteer email) */
.lmb-reveal { margin: 6px 0 10px 24px; padding: 10px 14px; border-left: 3px solid #7fb8dc; background: #eef1f4; }
.lmb-reveal[hidden] { display: none; }
.lmb-volunteer-field .lmb-reveal label { display: block; font-weight: 600; margin-bottom: 4px; }
.lmb-volunteer-field .lmb-reveal input[type=email] { width: 100%; max-width: 360px; }
.lmb-repeat-field__status { margin: 0; }
.lmb-ride-form .lmb-repeat-field .em-weekly-selector .selectize-control { min-width: 260px; }
/* Flatten EM's nested boxes: no borders on the set, the date fieldset, or the Times fieldset */
.lmb-ride-form .lmb-repeat-field .em-recurrence-set,
.lmb-ride-form .lmb-repeat-field .em-recurrence-set-data,
.lmb-ride-form .lmb-repeat-field .em-recurrence-advanced,
.lmb-ride-form .lmb-repeat-field .em-recurrence-advanced fieldset,
.lmb-ride-form .lmb-repeat-field .em-recurrence-timeranges,
.lmb-ride-form .lmb-repeat-field .em-timeranges,
.lmb-ride-form .lmb-repeat-field .em-timerange { border: 0 !important; box-shadow: none !important; background: transparent !important; padding-left: 0 !important; padding-right: 0 !important; }
.lmb-ride-form .lmb-repeat-field .em-recurrence-set-data { padding: 0 !important; }
.lmb-ride-form .lmb-repeat-field .em-recurrence-advanced legend { font-weight: 600; padding: 0; margin: 0 0 4px; }
.lmb-ride-form .lmb-repeat-field .em-recurrence-advanced > div { margin-bottom: 12px; }
.lmb-ride-form .lmb-repeat-field .em-add-recurrence-set[data-type="exclude"] { font-size: 13px; }

/* Repeat schedule: Events Manager's own tool, trimmed to what organizers need.
   EM's original "This is a recurring event" checkbox in When is hidden; "This ride repeats" drives it. */
.lmb-ride-form .em-event-type { display: none !important; }
.lmb-ride-form .lmb-repeat-field .em-add-recurrence-set[data-type="include"],
.lmb-ride-form .lmb-repeat-field .em-recurrence-type-include .em-recurrence-set-actions,
.lmb-ride-form .lmb-repeat-field .em-recurrence-duration,
.lmb-ride-form .lmb-repeat-field .em-recurrence-timezone,
.lmb-ride-form .lmb-repeat-field .em-recurrence-status,
.lmb-ride-form .lmb-repeat-field .em-recurrence-advanced-description-primary { display: none !important; }

/* ======================================================================
   LIST VIEW – ROWS (Ride Illinois style). Active when LMB_RIDE_LIST_STYLE = 'rows'.
   ====================================================================== */
.lmb-ride-list--rows .lmb-ride-list__grid { display: block; }
.lmb-ride-list--rows .lmb-ride-list__month { font-family: var(--lmb-font); font-size: 24px; margin: 36px 0 12px; color: #0f2a47; }
.lmb-ride-list--rows .lmb-ride-list__month:first-child { margin-top: 10px; }

.lmb-ride-row {
  display: flex;
  align-items: stretch;
  margin: 0 0 12px;
  background: #fff;
  border-radius: 6px;
  overflow: visible;
  box-shadow: inset 0 0 0 var(--lmb-cat-border-w, 1px) var(--lmb-cat-border, #d5dbe1);
}

/* Date block – takes the category color; LMB blue when the ride has none */
.lmb-ride-row__date {
  flex: 0 0 auto;
  min-width: 78px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 12px 10px;
  border-radius: 6px 0 0 6px;
  background: var(--lmb-cat-bg, #fff);
  color: var(--lmb-cat-fg, #0f2a47);
  border-right: var(--lmb-cat-border-w, 1px) solid var(--lmb-cat-border, #d5dbe1);
  font-family: var(--lmb-font);
  text-transform: uppercase;
  text-align: center;
}
.lmb-ride-row__day { display: flex; flex-direction: column; line-height: 1.05; }
.lmb-ride-row__day .m { font-size: 12px; letter-spacing: .04em; }
.lmb-ride-row__day .d { font-size: 26px; font-weight: 700; }
.lmb-ride-row__day .w { font-size: 11px; opacity: .85; }
.lmb-ride-row__day--end .d { font-size: 16px; }
.lmb-ride-row__day--end .m, .lmb-ride-row__day--end .w { font-size: 10px; }
.lmb-ride-row__dash { font-size: 14px; opacity: .8; }

/* The date block covers the row's outline on its top, left and bottom edges, so redraw it there in the
   card's outline color. On a solid card the outline matches the fill, so nothing shows; on a white card
   (no category, or LMB Co-Hosted) the outline continues around the block. */
.lmb-ride-row__date {
  box-shadow: inset var(--lmb-cat-border-w, 1px) 0 0 var(--lmb-cat-border, #d5dbe1),
              inset 0 var(--lmb-cat-border-w, 1px) 0 var(--lmb-cat-border, #d5dbe1),
              inset 0 calc(-1 * var(--lmb-cat-border-w, 1px)) 0 var(--lmb-cat-border, #d5dbe1);
}

/* Middle */
.lmb-ride-row__body { flex: 1 1 auto; display: flex; gap: 14px; align-items: center; padding: 12px 16px; min-width: 0; }
.lmb-ride-row__thumb { flex: 0 0 64px; }
.lmb-ride-row__thumb img { display: block; width: 64px; height: 64px; object-fit: cover; border-radius: 4px; }
.lmb-ride-row__info { min-width: 0; }
.lmb-ride-row__tags { font-family: var(--lmb-font); font-size: 11px; letter-spacing: .05em; text-transform: uppercase; color: #0b5a8a; margin-bottom: 3px; }
.lmb-ride-row__tags .sep { margin: 0 6px; color: #5a6472; }
.lmb-ride-row__title { margin: 0 0 6px; font-family: var(--lmb-font); font-size: 18px; line-height: 1.25; }
.lmb-ride-list .lmb-ride-row__title a { color: #23272d !important; text-decoration: none; }
.lmb-ride-list .lmb-ride-row__title a:hover { color: #0b5a8a !important; text-decoration: underline; }
.lmb-ride-row__chips { display: flex; flex-wrap: wrap; gap: 6px; }
.lmb-ride-row__chip { display: inline-flex; align-items: center; gap: 5px; padding: 2px 10px; border-radius: 999px; background: #eef1f4; font-size: 12.5px; color: #23272d; }
.lmb-ride-row__chip--clock::before { content: "🕒"; font-size: 11px; }
.lmb-ride-row__chip--pin::before { content: "📍"; font-size: 11px; }
.lmb-ride-row__desc { margin: 6px 0 0; font-size: 13.5px; color: #5a6472; }

/* Buttons */
.lmb-ride-row__actions { flex: 0 0 auto; display: flex; flex-direction: column; justify-content: center; gap: 8px; padding: 12px 16px 12px 0; }
.lmb-ride-list .lmb-ride-row__btn,
.lmb-ride-list .lmb-ride-row__actions .em-event-add-to-calendar {
  display: inline-flex; align-items: center; justify-content: center; gap: 4px;
  min-width: 140px; padding: 6px 14px; border-radius: 999px;
  font-family: var(--lmb-font); font-size: 13px; font-weight: 600; line-height: 1.4;
  text-decoration: none; cursor: pointer; white-space: nowrap;
}
.lmb-ride-list .lmb-ride-row__btn--primary { background: #0f2a47 !important; color: #fff !important; border: 2px solid #0f2a47; }
.lmb-ride-list .lmb-ride-row__btn--primary:hover { background: #0b5a8a !important; border-color: #0b5a8a; }
.lmb-ride-list .lmb-ride-row__actions .em-event-add-to-calendar { background: transparent; color: #0f2a47; border: 2px solid #0f2a47; height: auto; margin: 0; }
.lmb-ride-list .lmb-ride-row__actions .em-event-add-to-calendar:hover { background: #eef1f4; }

/* Month-break ad in row layout: centered strip */
.lmb-ride-list--rows .lmb-ride-card--ad { width: 100%; margin: 4px 0 16px; padding: 10px; background: #eef1f4; border-radius: 6px; }

/* Phones: buttons drop below the details */
@media (max-width: 680px) {
  .lmb-ride-row { flex-wrap: wrap; }
  .lmb-ride-row__body { flex-basis: calc(100% - 90px); }
  .lmb-ride-row__actions { flex: 1 1 100%; flex-direction: row; padding: 0 12px 12px; }
  .lmb-ride-list .lmb-ride-row__btn, .lmb-ride-list .lmb-ride-row__actions .em-event-add-to-calendar { flex: 1; min-width: 0; }
  .lmb-ride-row__thumb { display: none; }
}

/* Rows – stronger rules so the theme and Events Manager styles don't override them */
.lmb-ride-list.lmb-ride-list--rows article.lmb-ride-row { margin: 0 0 12px !important; padding: 0 !important; }
.lmb-ride-list.lmb-ride-list--rows .lmb-ride-row h3.lmb-ride-row__title { font-size: 18px !important; line-height: 1.25 !important; margin: 0 0 6px !important; font-weight: 600 !important; letter-spacing: 0 !important; text-transform: none !important; }
.lmb-ride-list.lmb-ride-list--rows .lmb-ride-row .lmb-ride-row__actions a.lmb-ride-row__btn--primary {
  background-color: #0f2a47 !important; color: #fff !important; border: 2px solid #0f2a47 !important; box-shadow: none !important;
}
.lmb-ride-list.lmb-ride-list--rows .lmb-ride-row .lmb-ride-row__actions a.lmb-ride-row__btn--primary:hover { background-color: #0b5a8a !important; border-color: #0b5a8a !important; }
.lmb-ride-list.lmb-ride-list--rows .lmb-ride-row .lmb-ride-row__actions button.em-event-add-to-calendar {
  min-width: 140px !important; height: auto !important; padding: 6px 14px !important; margin: 0 !important;
  border-radius: 999px !important; border: 2px solid #0f2a47 !important; background: #fff !important; color: #0f2a47 !important;
  font-family: var(--lmb-font) !important; font-size: 13px !important; font-weight: 600 !important; text-transform: none !important; letter-spacing: 0 !important; line-height: 1.4 !important;
}
.lmb-ride-list.lmb-ride-list--rows .lmb-ride-row .lmb-ride-row__actions button.em-event-add-to-calendar:hover { background: #eef1f4 !important; }
.lmb-ride-list.lmb-ride-list--rows .lmb-ride-row .lmb-ride-row__actions button.em-event-add-to-calendar .em-icon { display: none; }
.lmb-ride-list.lmb-ride-list--rows .lmb-ride-row__date { flex: 0 0 96px; width: 96px; min-width: 96px; }


/* ---------- CALENDAR view entries: ride name + city, colors from the scheme ---------- */
/* One line each: long ride names are cut off with "…" instead of wrapping */
.em.em-calendar .em-cal-event .lmb-cal-name,
.em.em-calendar .em-cal-event .lmb-cal-town { display: block; line-height: 1.25; white-space: nowrap !important; overflow: hidden; text-overflow: ellipsis; }
.em-cal-event .lmb-cal-name { font-weight: 600; }
.em-cal-event .lmb-cal-town { font-size: .85em; opacity: .85; }
/* Let each entry and each day grow to fit two lines (EM fixes them at 28px / square days) */
.em.em-calendar .em-cal-body.event-style-pill .em-cal-event { height: auto !important; margin: 3px 0 !important; }
.em.em-calendar .em-cal-body.event-style-pill .em-cal-event > div {
  position: static !important; height: auto !important; left: auto !important; right: auto !important;
  padding: 3px 5px !important; border-radius: 4px; white-space: normal !important; overflow: hidden !important;
  font-size: 12px; line-height: 1.25;
}
.em.em-calendar .em-cal-body.even-aspect { grid-template-rows: none !important; grid-auto-rows: minmax(90px, auto) !important; height: auto !important; }
.em.em-calendar .em-cal-body .em-cal-day { height: auto !important; min-width: 0; }
/* Keep all seven day columns equal width, so one-line ride names cut off instead of stretching a column */
.em.em-calendar .em-cal-body.em-cal-days { grid-template-columns: repeat(7, minmax(0, 1fr)) !important; }

/* EM keeps each "Add To Calendar" menu in the page until it is opened.
   Hide it fully so it never shows expanded or widens the page on phones.
   EM removes this class when it opens the menu, so the dropdown still works. */
.em-tooltip-ddm-content { display: none !important; }


/* Ride form: the map sits below the address fields (EM floats the address table; on the block theme
   the map box slid under it and ran into the Details section). */
#em-location-data .em-location-map-container { clear: both; height: auto !important; aspect-ratio: auto !important; padding: 0 !important; }
#em-location-data .em-location-map-container:has(#em-map[style*="display: block"]) { padding-top: 12px !important; }
/* No empty 380px "Location not found" box: the map appears once an address is picked. */
.lmb-ride-form .em-location-map-404 { display: none !important; }
.lmb-ride-form #em-map { height: 380px; }

/* Google place suggestions under the Address field: wide enough to read full names */
.pac-container { min-width: 360px; font-family: inherit; z-index: 100000; }
.lmb-ride-form #location-address { min-width: 320px; }

/* ---------- Add/Edit form: clean layout ----------
   No boxes around sections; Category and Ride Type side by side on wide screens. */
.lmb-ride-form .lmb-form-block fieldset, .lmb-ride-form fieldset.em-timeranges, .lmb-ride-form .em-timerange,
.lmb-ride-form .em-event-datetimes fieldset { border: 0 !important; box-shadow: none !important; padding: 0 !important; margin-left: 0 !important; margin-right: 0 !important; background: transparent !important; }
.lmb-ride-form .em-event-datetimes legend, .lmb-ride-form fieldset.em-timeranges legend { font-weight: 600; padding: 0; }
.lmb-ride-form table.em-location-data, .lmb-ride-form table.em-location-data td, .lmb-ride-form table.em-location-data th { border: 0 !important; background: transparent !important; }
.lmb-ride-form table.em-location-data th { text-align: left; padding: 6px 12px 6px 0; vertical-align: top; }
.lmb-ride-form .lmb-two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 40px; align-items: start; }
.lmb-ride-form .lmb-two-col > .lmb-form-block { margin: 0; min-width: 0; }
.lmb-ride-form .lmb-two-col .lmb-ride-type-field label.lmb-ride-type-field__option { max-width: none; }
@media (max-width: 760px) { .lmb-ride-form .lmb-two-col { grid-template-columns: 1fr; } }
.lmb-field-error { color: #ba0c2f; font-weight: 600; margin: 4px 0 8px; }
/* Two-column field groups: label above its field */
.lmb-ride-form .lmb-two-col--fields .event-attributes { margin: 0 0 14px; }
.lmb-ride-form .lmb-two-col--fields .event-attributes label { display: block; width: auto; text-align: left; margin: 0 0 3px; font-weight: 600; }
.lmb-ride-form .lmb-two-col--fields .event-attributes input[type=text], .lmb-ride-form .lmb-two-col--fields .event-attributes select { width: 100%; max-width: 360px; box-sizing: border-box; }
.lmb-ride-form .lmb-two-col--fields .event-attributes .field-description, .lmb-ride-form .lmb-two-col--fields .event-attributes .maxlength { padding-left: 0; font-size: 13px; }
.lmb-ride-form .lmb-two-col--fields h3 { margin-top: 0; }
/* The old theme pushed the Details heading down 320px to clear a map that no longer sits there. */
.lmb-ride-form h3.event-form-details { margin-top: 24px !important; }
.lmb-ride-form .inside.event-form-details { margin-top: 0 !important; }
/* Form sections (Events Manager 7 template) */
.lmb-ride-form section { margin: 0 0 28px; }
.lmb-ride-form section > h3 { margin: 0 0 10px; }
.lmb-ride-form section h4 { margin: 0 0 4px; }
.lmb-ride-form .lmb-field-note { display: block; font-size: 13px; color: #5a6472; margin: 2px 0 8px; }
.lmb-ride-form .lmb-ride-style-field { margin-top: 8px; }
.lmb-ride-form .lmb-ride-style-field__options { display: flex; flex-wrap: wrap; gap: 4px 32px; }
.lmb-ride-form .lmb-ride-style-field label.lmb-ride-type-field__option { max-width: 260px; }
.lmb-ride-form .lmb-short-description textarea { width: 100%; max-width: 760px; }
.lmb-ride-form .lmb-short-description label, .lmb-ride-form .event-form-describe .event-attributes > label { display: block; width: auto; text-align: left; font-weight: 600; margin: 0 0 4px; }
.lmb-ride-form .event-form-describe .event-attributes { margin: 0 0 18px; }
.lmb-ride-form .event-form-describe .event-attributes .field-description { padding-left: 0; }
.lmb-ride-form .lmb-repeat-field { margin-top: 14px; }
.lmb-ride-form .event-form-name .event-attributes label { display: block; width: auto; text-align: left; font-weight: 600; margin: 8px 0 4px; }
.lmb-ride-form .maxlength { padding-left: 0; font-size: 12px; }

/* ---------- Form: use the site's own fonts and spacing, not Events Manager's ----------
   "inherit" means each theme's font comes through (Montserrat/Open Sans on the current site, Barlow on the rebuild). */
.lmb-ride-form-wrap { --lmb-page-font: inherit; }
.lmb-ride-form-wrap .em.pixelbones, .lmb-ride-form-wrap .em.pixelbones *:not(h1):not(h2):not(h3):not(h4):not(legend):not(.mce-ico):not(.dashicons):not([class*="em-icon"]):not(.mce-container *) { --font-family: var(--lmb-page-font); font-family: inherit !important; }
.em.pixelbones.lmb-ride-form h3, .em.pixelbones.lmb-ride-form h4, .em.pixelbones.lmb-ride-form legend { font-family: var(--lmb-font) !important; letter-spacing: 0; }
.em.pixelbones.lmb-ride-form h3 { font-size: 22px !important; font-weight: 600; line-height: 1.3; margin: 0 0 10px; color: var(--lmb-blue); }
.em.pixelbones.lmb-ride-form h4 { font-size: 16px !important; font-weight: 600; line-height: 1.3; margin: 0 0 4px; }
.em.pixelbones.lmb-ride-form section { margin: 0 0 26px; }
.em.pixelbones.lmb-ride-form p, .em.pixelbones.lmb-ride-form label, .em.pixelbones.lmb-ride-form .field-description { font-size: 15px; line-height: 1.45; }
.em.pixelbones.lmb-ride-form input[type=text], .em.pixelbones.lmb-ride-form input[type=email], .em.pixelbones.lmb-ride-form input[type=date],
.em.pixelbones.lmb-ride-form select, .em.pixelbones.lmb-ride-form textarea { font-size: 15px; height: auto; padding: 6px 10px; margin-bottom: 0; }
.em.pixelbones.lmb-ride-form .event-attributes { margin: 0 0 12px; }
.em.pixelbones.lmb-ride-form .input { font-size: 15px; }
/* Venue picker: one box, not a box inside a box (the theme borders every text input) */
.em.pixelbones.lmb-ride-form .input .selectize-input > input[type], .em.pixelbones.lmb-ride-form .selectize-input > input { border: 0 !important; box-shadow: none !important; padding: 0 !important; height: auto !important; min-height: 0 !important; background: transparent !important; }
.lmb-ride-form .selectize-control.single .selectize-input { padding: 8px 30px 8px 10px; min-height: 0; }
.lmb-ride-form .selectize-control { margin: 0; }
/* Short Description is a Dollar Per Rider perk: shown only when that box is ticked */
.lmb-ride-form .lmb-short-description[hidden] { display: none; }
.lmb-ride-form .lmb-dpr-perk-note { margin: 0 0 14px; }
/* Block theme (rebuild): the form uses the site's wide width, not the 760px reading column */
.entry-content > .em:has(.lmb-ride-form-wrap) { max-width: var(--wp--style--global--wide-size, 1240px) !important; }

/* ---------- PILLS: one tag, every view (list row, grid leaf, calendar entry, map pop-up) ----------
   White pill, navy text, and a colored dot for the tier or LMB involvement, so it reads on any card color. */
.lmb-pills { display: inline-flex; flex-wrap: wrap; gap: 4px; vertical-align: middle; }
.lmb-pill {
  display: inline-flex; align-items: center; gap: 5px;
  font-family: var(--lmb-font); font-size: 11px; font-weight: 700; line-height: 1; letter-spacing: .02em;
  padding: 3px 8px 3px 6px; border-radius: 999px; white-space: nowrap;
  background: #fff; color: #0f2a47; border: 1px solid #d5dbe1; text-transform: none;
}
.lmb-pill::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--lmb-pill, #d5dbe1); box-shadow: inset 0 0 0 2px var(--lmb-pill, #d5dbe1); }
.lmb-pill--dollar-per-rider      { --lmb-pill: #7fb8dc; }
.lmb-pill--two-dollar-per-rider  { --lmb-pill: #f2b61c; }
.lmb-pill--five-dollar-per-rider { --lmb-pill: #ba0c2f; }
.lmb-pill--lmb-event             { --lmb-pill: #0b5a8a; }
.lmb-pill--lmb-cohosted          { --lmb-pill: #0b5a8a; }
.lmb-pill--lmb-cohosted::before  { background: #fff; } /* hollow dot = co-hosted */
.lmb-ride-row__tags .lmb-pills--row { margin-right: 8px; }
.em.em-list.em-grid .em-item .em-item-image { position: relative; padding-bottom: 32px; box-sizing: border-box; }
.em.em-list.em-grid .em-item .em-item-image .lmb-pills--grid { position: absolute; left: 10px; bottom: 8px; z-index: 2; }
.em.em-calendar .em-cal-event .lmb-pills--cal { margin-right: 4px; vertical-align: -1px; }
.em.em-calendar .em-cal-event .lmb-pills--cal .lmb-pill { font-size: 9px; padding: 2px 6px 2px 4px; gap: 3px; }
.em.em-calendar .em-cal-event .lmb-pills--cal .lmb-pill::before { width: 6px; height: 6px; }
.lmb-map-popup__ride .lmb-pills--map { margin-left: 6px; vertical-align: -2px; }

/* ---------- COLOR KEY under the search bar ---------- */
.lmb-color-key { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 18px; margin: 10px 0 14px; font-family: var(--lmb-font); font-size: 13px; color: #23272d; }
.lmb-color-key__item { display: inline-flex; align-items: center; gap: 7px; }
.lmb-color-key__swatch { width: 18px; height: 18px; border-radius: 4px; background: var(--lmb-cat-bg, #fff); border: var(--lmb-cat-border-w, 1px) solid var(--lmb-cat-border, #d5dbe1); }
.lmb-color-key__note { flex-basis: 100%; font-size: 12.5px; color: #5a6472; }

/* ---------- SEARCH BAR (Oct 8, 2026, from 910's staging review) ----------
   The old theme's style.css squeezes Events Manager's search bar to half width (.em-search-main {width:50% !important}),
   which collapses the text fields to icons and pushes the button outside the box. Restore the full-width bar. */
.em.em-search .em-search-main.em-search-main-bar { width: 100% !important; }

/* ---------- HERO SLIDER: one height for every slide ----------
   Slides on the old theme came in three different heights (455, 710, 810 px), so the page jumped on every change.
   Pin every slide image to the theme's intended 1440x455 shape and crop the rest. Scales down on narrow screens. */
header.hero .swiper-slide img,
header.hero .slide img { height: clamp(240px, 31.6vw, 455px) !important; width: 100% !important; object-fit: cover; object-position: center; }
header.hero .swiper-wrapper { height: clamp(240px, 31.6vw, 455px) !important; }
/* Site header above the hero's Donate flyout. The theme gives the flyout z-index 1000 and the header 10,
   so menu dropdowns fell behind it once the hero was held at 455 px. Old theme only. */
header.site-header { z-index: 1001 !important; }

/* Homepage, old theme only: the theme pulls the events box 140px up into the hero and pads it 3%.
   With the hero held at 455px that covered 30% of the photo. Overlap is now 40px, padding is
   tighter, and the Donate flyout sits low in the hero so it reads with the box rather than the menus. */
.home .ride-cal-highlight,
.ride-cal-highlight { margin-top: -40px !important; padding: 28px 2% !important; }
/* At 1290px and up the theme floats the box over the hero and the mission photo rises behind it (leave that alone).
   Below 1290px the theme leaves the box in normal flow with no position, so its z-index is ignored and the hero
   paints over its top edge, while the mission section still carries 319px of padding meant to clear a floated box. */
@media (max-width: 1289px) {
	.ride-cal-highlight { position: relative; z-index: 100; }
	.our-mission-container { padding-top: 48px !important; }
}
header.hero .donate-flyout { top: auto !important; bottom: 60px !important; transform: none !important; }

/* ---------------------------------------------------------------------------
   Sticky search bar and sidebar ads (Andy, Oct 9, 2026)
   The search bar (with its color key) stays at the top of the window while the
   rider scrolls the list. The sidebar ads do the same, with breathing room
   under the admin bar when logged in. Desktop only; phones keep normal flow.
--------------------------------------------------------------------------- */
@media (min-width: 900px) {
	.em.em-search {
		position: sticky;
		top: 0;
		z-index: 40;
		background: #fff !important;
		padding-top: 16px;
		padding-bottom: 8px;
		margin-bottom: 8px;
		box-shadow: 0 10px 12px -12px rgba(15, 42, 71, 0.25);
	}
	body.admin-bar .em.em-search { top: 32px; }

	aside.sidebar.ads { top: 16px; }
	body.admin-bar aside.sidebar.ads { top: calc(32px + 16px); }
}
