/**
 * Meetups & Events page (2.0) — hero, events calendar, how-it-works, community.
 * Gear Up grid + Quick View come from quick-view.css; merch from main-style.css.
 * Enqueued on page-meetups-events.php.
 */

.ts-meetups { background: var(--white); }

/* ── HERO ── */
.ts-meetups .meetups-hero {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 480px;
  background: var(--charcoal);
  background-size: cover;
  background-position: center;
  text-align: center;
}
.ts-meetups .meetups-hero-overlay { position: absolute; inset: 0; background: rgba(28,26,24,0.72); }
.ts-meetups .meetups-hero-content { position: relative; z-index: 2; padding: 72px 40px; max-width: 900px; animation: fadeUp 0.7s var(--ease-out) both; }
.ts-meetups .meetups-hero-eyebrow {
  font-family: var(--ff-body);
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-weight: 600;
  color: rgba(255,255,255,0.45);
  margin-bottom: 18px;
  display: block;
}
.ts-meetups .meetups-hero-title {
  font-family: 'Inter', sans-serif;
  font-size: clamp(48px, 9vw, 88px);
  font-weight: 800;
  color: #fff;
  line-height: 0.95;
  letter-spacing: -0.05em;
  margin-bottom: 24px;
}
.ts-meetups .meetups-hero-sub {
  font-family: var(--ff-mono);
  font-size: 18px;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: rgba(255,255,255,0.55);
  line-height: 1.7;
  margin-bottom: 36px;
}
.ts-meetups .meetups-hero-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--terra);
  color: #fff;
  border: 1px solid var(--terra);
  border-radius: 4px;
  padding: 14px 44px;
  font-family: var(--ff-body);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  transition: all 0.2s var(--ease-out);
}
/* Free Choice, NOT Mascot — and Ink text, because Free Choice is too light for white (2.1 redline). */
.ts-meetups .meetups-hero-btn:hover { background: var(--free-choice); border-color: var(--free-choice); color: var(--ink); }

/* ── CALENDAR ── */
.ts-meetups .calendar-section { background: var(--white); padding: 64px 10%; }
/* Copy block left, Subscribe button right, baselines aligned. This rule was
   missing entirely — only the <900px override below existed, setting
   `flex-direction: column` on an element that had never been made a flex
   container, so the button stacked under the heading at every width. */
.ts-meetups .calendar-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 40px;
  margin-bottom: 36px;
}
/* LOCKED (2.1 redline): Fri-Yay, NOT Mascot — deliberate extra energy on this page.
   Client-confirmed; do not normalise during a future hover sweep. */
.ts-meetups .calendar-eyebrow { font-size: 11px; font-weight: 700; letter-spacing: 0.22em; text-transform: uppercase; color: var(--fri-yay); margin-bottom: 8px; }
.ts-meetups .calendar-title {
  font-family: 'Inter', sans-serif;
  font-size: 36px;
  font-weight: 700;
  color: var(--charcoal);
  letter-spacing: -0.05em;
  line-height: 1.1;
  margin-bottom: 10px;
}
.ts-meetups .calendar-sub { font-size: 14px; color: var(--stone); line-height: 1.75; max-width: 680px; }
.ts-meetups .calendar-subscribe-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--charcoal);
  color: #fff;
  border: 1px solid var(--charcoal);
  padding: 12px 28px;
  font-family: var(--ff-body);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s var(--ease-out);
  white-space: nowrap;
  flex-shrink: 0;
  /* Sits on the copy block's bottom edge rather than stretching to its height,
     which is what `align-items: flex-end` on the header would otherwise do to
     an anchor. */
  align-self: flex-end;
}
.ts-meetups .calendar-subscribe-btn:hover { background: var(--terra); border-color: var(--terra); }
.ts-meetups .calendar-embed {
  background: #F5F5F3;
  border: 1px solid var(--border);
  min-height: 520px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 14px;
}
.ts-meetups .calendar-embed iframe { width: 100%; min-height: 520px; border: 0; display: block; }
/* When a real calendar (AddEvent widget or iframe) is present, drop the grey
 * placeholder box + centring so the calendar can fill the full width. */
.ts-meetups .calendar-embed--live {
  background: transparent;
  border: none;
  min-height: 0;
  display: block;
  padding: 0;
}
.ts-meetups .calendar-embed .ae-emd-cal { width: 100%; }
.ts-meetups .calendar-embed-icon { font-size: 40px; opacity: 0.6; }
.ts-meetups .calendar-embed-label { font-size: 13px; color: var(--stone); letter-spacing: 0.02em; text-align: center; padding: 0 20px; }

/* ── HOW IT WORKS ── */
.ts-meetups .how-it-works { background: var(--white); padding: 40px 10% 80px; }
.ts-meetups .how-it-works-inner {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  /* gap:0 so each step's left edge IS the column boundary — that's where the
     .hiw-step separator draws. Any gap here would float the separators off the
     boundary and give the three columns uneven gutters. */
  gap: 0;
  max-width: 1100px;
  margin: 0 auto;
  position: relative;
}
/* Connecting line behind the dots — DASHED, not solid. Runs from the centre of
   the first dot to the centre of the last, i.e. inset one half-column (100%/6)
   at each end. */
.ts-meetups .how-it-works-inner::before {
  content: '';
  position: absolute;
  top: 10px;
  left: calc(100% / 6);
  right: calc(100% / 6);
  border-top: 2px dashed #D5D0CB;
  pointer-events: none;
  z-index: 0;
}
.ts-meetups .hiw-step { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 0 48px; position: relative; }
/* Vertical rule between steps. Starts at 64px so it clears the dot and the
   dashed connector above it, rather than cutting through them. */
.ts-meetups .hiw-step:not(:first-child)::before {
  content: '';
  position: absolute;
  left: 0;
  top: 64px;
  bottom: 0;
  width: 1px;
  background: var(--border);
}
.ts-meetups .hiw-dot { width: 20px; height: 20px; border-radius: 50%; margin-bottom: 36px; position: relative; z-index: 1; flex-shrink: 0; }
.ts-meetups .hiw-dot-1 { background: var(--terra); }
.ts-meetups .hiw-dot-2 { background: var(--mascot); }
.ts-meetups .hiw-dot-3 { background: #cb9d86; }
.ts-meetups .hiw-num {
  font-family: 'Inter', sans-serif;
  font-size: 48px;
  font-weight: 800;
  letter-spacing: -0.05em;
  line-height: 1;
  color: var(--charcoal);
  margin-bottom: 16px;
}
.ts-meetups .hiw-step:nth-child(1) .hiw-num { color: var(--terra); }
.ts-meetups .hiw-step:nth-child(2) .hiw-num { color: var(--mascot); }
.ts-meetups .hiw-step:nth-child(3) .hiw-num { color: #cb9d86; }
.ts-meetups .hiw-title {
  font-family: 'Inter', sans-serif;
  font-size: 22px;
  font-weight: 700;
  color: var(--charcoal);
  letter-spacing: -0.04em;
  line-height: 1.2;
  margin-bottom: 14px;
}
.ts-meetups .hiw-body { font-size: 14px; color: var(--stone); line-height: 1.65; max-width: 280px; }

/* ── EVENTS GRID + FILTER SIDEBAR ── */
.ts-meetups .merch-grid-section { background: var(--white); padding: 48px 10% 96px; }
.ts-meetups .merch-grid-inner { display: grid; grid-template-columns: 260px 1fr; gap: 48px; align-items: start; }
.ts-meetups .merch-sidebar { background: var(--white); border: none; overflow: hidden; position: sticky; top: 130px; }
.ts-meetups .sidebar-heading {
  font-family: 'Inter', sans-serif;
  font-size: 24px;
  font-weight: 700;
  color: var(--charcoal);
  letter-spacing: -0.05em;
  line-height: 1.2;
  padding: 0 0 16px;
  border-bottom: 2px solid var(--charcoal);
  margin-bottom: 4px;
}
.ts-meetups .sidebar-search { padding: 16px 0; border-bottom: 1px solid var(--border); }
.ts-meetups .sidebar-search-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #F5F5F3;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 9px 16px;
  transition: border-color 0.2s;
}
.ts-meetups .sidebar-search-wrap:focus-within { border-color: var(--charcoal); }
.ts-meetups .sidebar-search-icon { color: var(--stone); flex-shrink: 0; }
.ts-meetups .sidebar-search-input {
  border: none;
  background: transparent;
  font-family: var(--ff-body);
  font-size: 12px;
  color: var(--charcoal);
  width: 100%;
  outline: none;
}
.ts-meetups .sidebar-search-input::placeholder { color: var(--dust); }
.ts-meetups .sidebar-filter-group { border-bottom: 1px solid var(--border); }
.ts-meetups .sidebar-filter-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 0;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--charcoal);
  cursor: pointer;
  user-select: none;
}
.ts-meetups .sidebar-chevron { color: var(--ink); transition: transform 0.2s; flex-shrink: 0; }
.ts-meetups .sidebar-filter-group.is-collapsed .sidebar-chevron { transform: rotate(-90deg); }
.ts-meetups .sidebar-filter-group.is-collapsed .sidebar-filter-body { display: none; }
.ts-meetups .sidebar-filter-body { padding: 4px 0 14px; display: flex; flex-direction: column; gap: 10px; }
.ts-meetups .sidebar-check {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: var(--ink);
  cursor: pointer;
  transition: color 0.15s;
  margin: 0;
}
.ts-meetups .sidebar-check:hover { color: #000; font-weight: 700; }
.ts-meetups .sidebar-check input[type="checkbox"],
.ts-meetups .sidebar-check input[type="radio"] {
  accent-color: var(--charcoal);
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  cursor: pointer;
  margin: 0;
}
.ts-meetups .sidebar-clear-btn {
  display: block;
  margin: 12px 0 0;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--stone);
  cursor: pointer;
  transition: color 0.2s;
  background: none;
  border: none;
  text-align: left;
  padding: 0;
}
.ts-meetups .sidebar-clear-btn:hover { color: var(--charcoal); }

.ts-meetups .merch-grid-content { min-width: 0; }
.ts-meetups .dept-row-label {
  font-family: 'Inter', sans-serif;
  font-size: 22px;
  font-weight: 700;
  color: var(--charcoal);
  letter-spacing: -0.05em;
  margin: 0 0 16px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: baseline;
  gap: 24px;
}
.ts-meetups .dept-tab-links { display: flex; gap: 16px; font-size: 13px; font-weight: 400; letter-spacing: 0.02em; }
.ts-meetups .dept-tab-links a { text-decoration: underline; text-underline-offset: 3px; color: var(--charcoal); }
.ts-meetups .dept-tab-links a:hover { color: var(--mascot); font-weight: 700; }
.ts-meetups .merch-grid-content .merch-product-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }

/* Event-card additions on top of the shared .merch-product-card (quick-view.css). */
.ts-meetups .merch-product-img-link { display: block; width: 100%; height: 100%; }
/* LOCKED (2.1 redline): event-card tags stay Fri-Yay, NOT Mascot. */
.ts-meetups .merch-product-cat { color: var(--fri-yay); font-weight: 600; }
.ts-meetups .event-meta { font-family: var(--ff-mono); font-size: 10px; color: var(--stone); letter-spacing: 0.04em; margin-top: 2px; }
.ts-meetups .merch-product-footer {margin-top: 10px;}
.ts-meetups .merch-product-price.free-price { color: var(--terra); }
/* Event "Reserve / Get Tickets / Watch Now" button.
 *
 * Restates .ts-world .merch-add-btn from world-grid.css, which already matches
 * the reference exactly. This page can't inherit it — world-grid.css is scoped
 * to .ts-world and the meetups wrapper is .ts-meetups — so the card fell
 * through to quick-view.css's unscoped .merch-add-btn instead: UPPERCASE, a
 * heavy Charcoal border and square corners. `text-transform: none` is the part
 * that undoes it; without that the label keeps shouting.
 *
 * Scoped rather than fixed in quick-view.css because that rule still dresses
 * the Travel page and the quick-view modal, which want the louder treatment. */
.ts-meetups .merch-add-btn {
  font-family: var(--ff-body);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: none;
  color: var(--charcoal);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 6px 14px;
  background: transparent;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s var(--ease-out);
}
.ts-meetups .merch-add-btn:hover { background: var(--charcoal); color: #fff; border-color: var(--charcoal); }
.ts-meetups .merch-badge.free { background: var(--free-choice); color: var(--ink); }
.ts-meetups .merch-badge.paid { background: #fff; color: var(--charcoal); border: 1px solid #D8D4CE; }
.ts-meetups .merch-badge.replay { background: var(--stone); color: #fff; }
.ts-meetups .merch-badge.new { background: var(--terra); color: #fff; }
.ts-meetups .merch-wishlist {
  position: absolute;
  top: 10px;
  right: 12px;
  z-index: 3;
  font-size: 18px;
  color: var(--stone);
  background: rgba(255,255,255,0.85);
  border: none;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  line-height: 1;
  transition: color 0.2s, background 0.2s;
}
.ts-meetups .merch-wishlist:hover { color: var(--mascot); background: #fff; }
.ts-meetups .ev-empty { padding: 56px 24px; text-align: center; color: var(--stone); font-size: 14px; }

/* ── COMMUNITY (2-col opt-in) ── */
.ts-meetups .community-section { overflow: hidden; background: var(--terra); border-top: 1px solid var(--border); }
.ts-meetups .community-inner { display: grid; grid-template-columns: 1fr 1fr; gap: 0; align-items: stretch; min-height: 580px; }
.ts-meetups .community-img {
  background: linear-gradient(160deg, #2a2826 0%, #3d3733 35%, #544e4a 65%, #6e6560 100%);
  background-size: cover;
  background-position: center;
  min-height: 580px;
}
.ts-meetups .community-text {
  display: flex;
  flex-direction: column;
  gap: 22px;
  padding: 80px 10% 80px 64px;
  justify-content: center;
  background: var(--terra);
}
.ts-meetups .community-eyebrow { font-size: 11px; letter-spacing: 0.22em; text-transform: uppercase; font-weight: 700; color: var(--terra-pale); }
.ts-meetups .community-title {
  font-family: 'Inter', sans-serif;
  font-size: 42px;
  font-weight: 700;
  color: #fff;
  letter-spacing: -0.05em;
  line-height: 1.05;
}
.ts-meetups .community-title em { font-style: italic; font-weight: 400; color: var(--terra-pale); }
.ts-meetups .community-body { font-size: 15px; color: rgba(255,255,255,0.88); line-height: 1.8; max-width: 420px; }
.ts-meetups .community-body em { font-style: italic; }
.ts-meetups .community-optin { display: flex; flex-direction: column; gap: 4px; margin-top: 4px; }
.ts-meetups .community-optin-heading { font-size: 13px; font-weight: 800; letter-spacing: 0.18em; text-transform: uppercase; color: #fff; margin-bottom: 8px; }
.ts-meetups .community-optin-label { font-family: var(--ff-body); font-size: 15px; font-weight: 400; color: rgba(255,255,255,0.88); line-height: 1.8; margin-bottom: 8px; max-width: 340px; }
.ts-meetups .community-optin-form { display: flex; gap: 0; max-width: 400px; }
.ts-meetups .community-optin-input {
  flex: 1;
  border: 1.5px solid rgba(255,255,255,0.5);
  border-right: none;
  padding: 12px 16px;
  font-family: var(--ff-body);
  font-size: 13px;
  color: var(--charcoal);
  background: #fff;
  outline: none;
  border-radius: 0;
  box-shadow: 0 6px 20px rgba(28,26,24,0.22);
}
.ts-meetups .community-optin-input::placeholder { color: var(--dust); }
.ts-meetups .community-optin-btn {
  background: var(--charcoal);
  color: #fff;
  border: 1.5px solid var(--charcoal);
  padding: 12px 22px;
  font-family: var(--ff-body);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.2s ease-out;
  white-space: nowrap;
  border-radius: 0;
}
.ts-meetups .community-optin-btn:hover { background: var(--terra-pale); border-color: var(--terra-pale); color: var(--charcoal); }
.ts-meetups .community-optin-confirm { font-size: 13px; font-weight: 600; color: #fff; letter-spacing: 0.03em; padding: 12px 0; }

/* ── BLOG ── */
.ts-meetups .blog-section {
  background: var(--white);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 96px 40px;
}
.ts-meetups .blog-inner { max-width: 1260px; margin: 0 auto; }
.ts-meetups .blog-header { display: flex; align-items: flex-end; justify-content: space-between; margin-bottom: 56px; padding-bottom: 40px; border-bottom: 1px solid var(--border); gap: 24px; }
.ts-meetups .blog-eyebrow { font-size: 12px; font-weight: 600; letter-spacing: 0.22em; text-transform: uppercase; color: var(--ink); margin-bottom: 12px; }
.ts-meetups .blog-title { font-family: 'Inter', sans-serif; font-size: 32px; font-weight: 700; color: var(--charcoal); letter-spacing: -0.05em; line-height: 1.1; }
.ts-meetups .blog-browse { font-size: 13px; font-weight: 600; color: var(--charcoal); text-decoration: underline; text-underline-offset: 4px; transition: color 0.15s; white-space: nowrap; margin-bottom: 10px; }
.ts-meetups .blog-browse:hover { color: var(--terra); }
.ts-meetups .blog-grid { display: grid; grid-template-columns: 1fr 1.4fr; gap: 32px; align-items: stretch; }
.ts-meetups .blog-featured { display: flex; flex-direction: column; text-decoration: none; color: inherit; border-radius: 8px; overflow: hidden; background: var(--white); box-shadow: var(--shadow-sm); transition: box-shadow 0.3s var(--ease-out), transform 0.3s var(--ease-out); height: 100%; }
.ts-meetups .blog-featured:hover { box-shadow: var(--shadow-lg); transform: translateY(-3px); }
.ts-meetups .blog-featured-img { width: 100%; flex: 1; min-height: 200px; position: relative; overflow: hidden; border-top: 3px solid var(--free-choice); border-radius: 8px 8px 0 0; }
.ts-meetups .blog-featured-body { padding: 28px 28px 32px; display: flex; flex-direction: column; gap: 10px; background: #F8F8F8; }
.ts-meetups .blog-featured-title { font-family: 'Inter', sans-serif; font-size: 24px; font-weight: 700; letter-spacing: -0.05em; color: var(--charcoal); line-height: 1.2; }
.ts-meetups .blog-featured-excerpt { font-size: 14px; color: var(--charcoal); line-height: 1.75; }
.ts-meetups .blog-side { display: flex; flex-direction: column; gap: 24px; }
.ts-meetups .blog-card { display: grid; grid-template-columns: 240px 1fr; text-decoration: none; color: inherit; border-radius: 8px; overflow: hidden; background: var(--white); box-shadow: var(--shadow-sm); transition: box-shadow 0.3s var(--ease-out), transform 0.3s var(--ease-out); }
.ts-meetups .blog-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-3px); }
.ts-meetups .blog-card-img { width: 100%; height: 100%; min-height: 160px; position: relative; overflow: hidden; }
.ts-meetups .blog-card-body { padding: 20px 22px; display: flex; flex-direction: column; gap: 8px; justify-content: center; background: #F8F8F8; }
.ts-meetups .blog-card-title { font-family: 'Inter', sans-serif; font-size: 17px; font-weight: 700; letter-spacing: -0.05em; color: var(--charcoal); line-height: 1.35; }
.ts-meetups .blog-meta { font-size: 11px; font-weight: 500; letter-spacing: 0.06em; color: var(--charcoal); text-transform: uppercase; }
.ts-meetups .blog-featured-tag,
.ts-meetups .blog-card-tag { position: absolute; top: 14px; left: 14px; font-size: 10px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; background: var(--white); color: var(--charcoal); padding: 4px 10px; border-radius: 4px; }
.ts-meetups .blog-read-link { font-size: 12px; font-weight: 600; letter-spacing: 0.06em; color: var(--charcoal); text-decoration: underline; text-underline-offset: 3px; transition: color 0.15s; margin-top: 4px; }
.ts-meetups .blog-featured:hover .blog-read-link,
.ts-meetups .blog-card:hover .blog-read-link { color: var(--terra); }

/* ── RESPONSIVE ── */
@media (max-width: 1100px) {
  .ts-meetups .merch-grid-inner { grid-template-columns: 1fr; }
  .ts-meetups .merch-sidebar { position: static; }
  .ts-meetups .merch-grid-content .merch-product-grid { grid-template-columns: repeat(2, 1fr); }
  /* minmax(0, 1fr): a bare 1fr grew to the opt-in form's width and pushed
   * "Get Access" flush against the screen edge on phones. */
  .ts-meetups .community-inner { grid-template-columns: minmax(0, 1fr); }
  .ts-meetups .community-img { min-height: 360px; }
}
@media (max-width: 900px) {
  .ts-meetups .how-it-works-inner { grid-template-columns: 1fr; gap: 40px; }
  .ts-meetups .how-it-works-inner::before { display: none; }
  /* Steps stack here, so the column separators would run down the left of each
     row instead of between columns. Goes away with the connector above it. */
  .ts-meetups .hiw-step:not(:first-child)::before { display: none; }
  .ts-meetups .hiw-step { padding: 0 24px; }
  .ts-meetups .calendar-section, .ts-meetups .how-it-works { padding-left: 6%; padding-right: 6%; }
  .ts-meetups .blog-grid { grid-template-columns: 1fr; }
  .ts-meetups .blog-card { grid-template-columns: 130px 1fr; }
}
@media (max-width: 600px) {
  .ts-meetups .merch-grid-content .merch-product-grid { grid-template-columns: 1fr; }
  .ts-meetups .community-title { font-size: 34px; }
  .ts-meetups .community-text { padding: 56px 32px; }
  .ts-meetups .calendar-header { flex-direction: column; align-items: flex-start; }
  .ts-meetups .calendar-subscribe-btn { align-self: flex-start; }
  .ts-meetups .blog-section { padding: 64px 24px; }
  .ts-meetups .blog-card { grid-template-columns: 1fr; }
}
