/* =============================================================================
   London Inter-Club — Stylesheet
   Logo-derived palette: deep navy on cream, with gold accents.
   ============================================================================= */

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,400;0,500;0,600;0,700;1,400&family=Inter:wght@300;400;500;600&display=swap');

:root {
  --navy:        #1d3a5f;
  --navy-deep:   #0f1f33;
  --navy-soft:   #2d4d77;
  --paper:       #f5ead0;
  --paper-deep:  #ebdfc1;
  --paper-mute:  #ddd0ac;
  --cream:       #faf3e0;
  --ink:         #1a1815;
  --rule-soft:   #c9bfa8;
  --gold:        #c8a047;
  --gold-deep:   #8a7340;
  --muted:       #6b6357;
  --green:       #3d5c3a;
  --red:         #8b2818;
  --amber:       #a86a1c;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: 'Inter', sans-serif;
  font-weight: 400;
  line-height: 1.55;
  min-height: 100vh;
  background-image:
    radial-gradient(ellipse at top, rgba(29, 58, 95, 0.05), transparent 60%),
    radial-gradient(ellipse at bottom, rgba(200, 160, 71, 0.05), transparent 60%);
}

a { color: var(--navy); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ----- Front (public) page ---------------------------------------------- */
body.front-page {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.front-hero {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 3rem 1.5rem;
}

.front-logo {
  width: min(360px, 60vw);
  height: auto;
  margin-bottom: 2rem;
}

.front-title {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 500;
  font-size: clamp(2.5rem, 6vw, 4rem);
  color: var(--navy);
  letter-spacing: 0.01em;
  line-height: 1.05;
  margin-bottom: 0.4rem;
}

.front-tagline {
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  font-size: 1.15rem;
  color: var(--gold-deep);
  margin-bottom: 2.5rem;
  letter-spacing: 0.02em;
}

.front-description {
  max-width: 600px;
  font-size: 1.05rem;
  line-height: 1.7;
  margin-bottom: 2.5rem;
}

.front-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  justify-content: center;
}

.front-footer {
  background: var(--navy-deep);
  color: var(--paper);
  padding: 1rem 1.5rem;
  text-align: center;
  font-size: 0.78rem;
  letter-spacing: 0.05em;
}
.front-footer a { color: var(--paper); border-bottom: 1px solid var(--paper); }

/* ----- v5.5: Events ticker on public homepage -------------------------- */
.events-ticker {
  background: var(--paper-deep, #ede6d3);
  padding: 1.75rem 0 1.5rem;
  border-top: 1px solid var(--rule-soft, #c9bfa8);
  border-bottom: 1px solid var(--rule-soft, #c9bfa8);
}
.events-ticker-header {
  max-width: 1200px;
  margin: 0 auto 1rem;
  padding: 0 1.5rem;
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
  flex-wrap: wrap;
}
.events-ticker-title {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 1.6rem;
  font-weight: 600;
  margin: 0;
  color: var(--ink, #1a1815);
}
.events-ticker-sub {
  font-size: 0.85rem;
  color: var(--muted, #6b6357);
  font-style: italic;
}
.events-ticker-scroll {
  display: flex;
  gap: 0.85rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding: 0 1.5rem 0.5rem;
  /* Edge fade masks so it looks like it scrolls into the page */
  -webkit-mask-image: linear-gradient(90deg,
    transparent 0, #000 2rem, #000 calc(100% - 2rem), transparent 100%);
          mask-image: linear-gradient(90deg,
    transparent 0, #000 2rem, #000 calc(100% - 2rem), transparent 100%);
  scrollbar-width: thin;
}
.events-ticker-scroll::-webkit-scrollbar { height: 8px; }
.events-ticker-scroll::-webkit-scrollbar-thumb {
  background: var(--rule-soft, #c9bfa8);
  border-radius: 4px;
}

.ticker-card {
  flex: 0 0 220px;
  scroll-snap-align: start;
  background: var(--paper, #f5f1e8);
  border: 1px solid var(--rule-soft, #c9bfa8);
  padding: 0.85rem 0.95rem 0.95rem;
  border-left: 3px solid var(--claret, #6b1e2c);
  transition: transform 0.15s, box-shadow 0.15s;
}
.ticker-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}
.ticker-card.is-past {
  opacity: 0.55;
  border-left-color: var(--rule-soft, #c9bfa8);
}
.ticker-card.is-today {
  border-left-color: var(--green, #3d5c3a);
  background: linear-gradient(180deg, rgba(61,92,58,0.06), var(--paper, #f5f1e8) 60%);
}
.ticker-date-label {
  font-size: 0.66rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--muted, #6b6357);
  font-weight: 500;
  margin-bottom: 0.4rem;
}
.ticker-card.is-today .ticker-date-label { color: var(--green, #3d5c3a); }
.ticker-name {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 1.05rem;
  font-weight: 600;
  line-height: 1.25;
  color: var(--ink, #1a1815);
  margin-bottom: 0.3rem;
  /* Constrain to 2 lines on overflow */
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.ticker-club {
  font-size: 0.78rem;
  color: var(--claret, #6b1e2c);
  font-style: italic;
  margin-bottom: 0.4rem;
}
.ticker-full-date {
  font-size: 0.72rem;
  color: var(--muted, #6b6357);
  border-top: 1px solid var(--rule-soft, #c9bfa8);
  padding-top: 0.35rem;
  margin-top: 0.35rem;
}

@media (max-width: 600px) {
  .ticker-card { flex: 0 0 180px; }
  .events-ticker-title { font-size: 1.3rem; }
}

/* ----- Auth pages (login/install) ---------------------------------------
 *
 * v6.9.1 fix: previously body.auth-page used `display:flex` with both
 * horizontal and vertical centering on the body. That worked fine while
 * the only child of <body> was the .auth-card, but as soon as we added
 * <footer class="site-footer"> as a sibling (v6.9), the footer became a
 * second flex item centered alongside the card — appearing as a small
 * pill floating mid-page next to the form (see screenshots in the v6.9.1
 * bug report). The fix is to make body.auth-page a flex *column*: card
 * grows to fill space and centres its contents, footer sits naturally at
 * the bottom full-width.
 */
html, body { min-height: 100%; }
body.auth-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;        /* horizontally centre the card */
  padding: 0;                 /* card has its own margin */
}
body.auth-page > .auth-card {
  /* In a column flex container, margin:auto on a child consumes ALL
     remaining free space top + bottom equally, vertically centring the
     card and pushing the footer to the natural bottom of the column.
     The card overrides its own default margin via this body-scoped rule. */
  margin: auto 1rem;
}
body.auth-page > .site-footer {
  width: 100%;
  flex-shrink: 0;             /* don't compress footer if card is tall */
}

.auth-card {
  background: var(--cream);
  border: 1px solid var(--rule-soft);
  padding: 2.25rem;
  max-width: 440px;
  width: 100%;
  box-shadow: 0 12px 40px rgba(15, 31, 51, 0.08);
}

.auth-logo {
  display: block;
  width: 100px;
  height: 100px;
  margin: 0 auto 1.25rem;
  border-radius: 50%;
  background: var(--paper);
}

.auth-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.75rem;
  font-weight: 500;
  text-align: center;
  color: var(--navy);
  margin-bottom: 0.25rem;
}

.auth-sub {
  text-align: center;
  font-style: italic;
  font-family: 'Cormorant Garamond', serif;
  color: var(--muted);
  margin-bottom: 1.5rem;
}

/* ----- Members area ----------------------------------------------------- */
.site-header {
  background: var(--navy);
  color: var(--paper);
  border-bottom: 4px solid var(--gold);
}
.site-header-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1.25rem;
  gap: 1rem;
  flex-wrap: wrap;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  color: var(--paper);
}
.brand:hover { text-decoration: none; }
.brand-logo {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--paper);
}
.brand-text { line-height: 1.1; }
.brand-primary {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.35rem;
  font-weight: 600;
  display: block;
}
.brand-secondary {
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--paper-mute);
}

.site-nav { display: flex; gap: 0.25rem; flex-wrap: wrap; }
.nav-link {
  color: var(--paper);
  padding: 0.45rem 0.85rem;
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 500;
  text-decoration: none;
  border-radius: 2px;
}
.nav-link:hover { background: var(--navy-soft); text-decoration: none; }
.nav-user { color: var(--gold); }
.nav-logout { color: var(--paper-mute); }
.nav-logout-form { display: inline; margin: 0; padding: 0; }
.nav-logout-button {
  background: none;
  border: 0;
  cursor: pointer;
  font: inherit;
}

.page { padding: 2rem 1rem 3rem; }
.container { max-width: 1200px; margin: 0 auto; }

/* ----- Site footer (members area + public pages, v6.9) ----------------- */
.site-footer {
  background: var(--navy);
  color: var(--paper);
  border-top: 4px solid var(--gold);
  margin-top: 3rem;
}
.site-footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  padding: 0.85rem 1.25rem;
  flex-wrap: wrap;
  font-size: 0.82rem;
  letter-spacing: 0.04em;
}
.site-footer .footer-copy { color: var(--paper); }
.site-footer .footer-sep { color: var(--paper-mute); }
.site-footer .footer-link {
  color: var(--paper);
  text-decoration: none;
}
.site-footer .footer-link:hover { color: var(--gold); text-decoration: underline; }

/* ----- Typography ------------------------------------------------------- */
h1, h2, h3, h4 {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 600;
  color: var(--navy-deep);
}
h1 { font-size: 2.2rem; line-height: 1.1; margin-bottom: 0.4rem; }
h2 { font-size: 1.6rem; margin-bottom: 0.5rem; }
h3 { font-size: 1.25rem; margin-bottom: 0.5rem; }

.page-header {
  margin-bottom: 1.5rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--rule-soft);
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.page-header .subtitle {
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  color: var(--muted);
  font-size: 1.05rem;
}

/* ----- Buttons ---------------------------------------------------------- */
.btn {
  display: inline-block;
  font-family: 'Inter', sans-serif;
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 500;
  padding: 0.65rem 1.3rem;
  border: 1px solid var(--navy);
  background: transparent;
  color: var(--navy);
  cursor: pointer;
  text-decoration: none;
}
.btn:hover { background: var(--navy); color: var(--paper); text-decoration: none; }
.btn-primary { background: var(--navy); color: var(--paper); }
.btn-primary:hover { background: var(--navy-deep); border-color: var(--navy-deep); }
.btn-ghost { border-color: var(--rule-soft); color: var(--muted); padding: 0.45rem 0.95rem; font-size: 0.7rem; }
.btn-ghost:hover { background: var(--rule-soft); color: var(--ink); }
.btn-danger { border-color: var(--red); color: var(--red); }
.btn-danger:hover { background: var(--red); color: var(--paper); }
.btn-sm { padding: 0.4rem 0.75rem; font-size: 0.68rem; }
.btn-gold { background: var(--gold); border-color: var(--gold); color: var(--navy-deep); }
.btn-gold:hover { background: var(--gold-deep); border-color: var(--gold-deep); color: var(--paper); }

/* ----- Forms ------------------------------------------------------------ */
.form-row { margin-bottom: 1rem; }
.form-row-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; }

label {
  display: block;
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.4rem;
  font-weight: 500;
}

input[type="text"], input[type="email"], input[type="tel"], input[type="password"],
input[type="date"], input[type="time"], input[type="number"], input[type="search"],
textarea, select {
  width: 100%;
  background: var(--cream);
  border: 1px solid var(--rule-soft);
  padding: 0.6rem 0.75rem;
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  color: var(--ink);
}
input:focus, textarea:focus, select:focus {
  outline: none;
  border-color: var(--navy);
  background: #fff;
}
textarea { min-height: 80px; resize: vertical; font-family: 'Inter', sans-serif; }
select { cursor: pointer; }

.form-helper-text {
  font-size: 0.78rem;
  color: var(--muted);
  margin-top: 0.3rem;
  font-style: italic;
  font-family: 'Cormorant Garamond', serif;
}

/* ----- Cards & tables --------------------------------------------------- */
.card {
  background: var(--cream);
  border: 1px solid var(--rule-soft);
  padding: 1.25rem 1.5rem;
  margin-bottom: 1rem;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
  background: var(--cream);
  border: 1px solid var(--rule-soft);
}
.data-table thead th {
  text-align: left;
  font-size: 0.65rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 500;
  padding: 0.75rem;
  background: var(--paper-deep);
  border-bottom: 1px solid var(--rule-soft);
}
.data-table tbody td {
  padding: 0.7rem 0.75rem;
  border-bottom: 1px solid var(--rule-soft);
  vertical-align: middle;
}
.data-table tbody tr:hover { background: var(--paper-deep); }
.data-table tbody tr:last-child td { border-bottom: none; }

/* ----- Pills/badges ----------------------------------------------------- */
.pill {
  display: inline-block;
  font-size: 0.65rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.2rem 0.55rem;
  border: 1px solid currentColor;
  font-weight: 500;
}
.pill-admin    { color: var(--red); }
.pill-rep      { color: var(--gold-deep); }
.pill-member   { color: var(--muted); }
.pill-active   { color: var(--green); }
.pill-inactive { color: var(--muted); }

/* ----- Flash messages --------------------------------------------------- */
.flash {
  padding: 0.75rem 1rem;
  margin-bottom: 1rem;
  border-left: 3px solid currentColor;
  background: rgba(255, 255, 255, 0.4);
  font-size: 0.92rem;
}
.flash-success { color: var(--green); background: rgba(61, 92, 58, 0.08); }
.flash-error   { color: var(--red); background: rgba(139, 40, 24, 0.08); }
.flash-info    { color: var(--navy); background: rgba(29, 58, 95, 0.08); }

/* ----- Toast ------------------------------------------------------------ */
.toast {
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%) translateY(120px);
  background: var(--navy-deep);
  color: var(--paper);
  padding: 0.8rem 1.5rem;
  font-size: 0.85rem;
  transition: transform 0.3s ease;
  z-index: 1000;
}
.toast.show { transform: translateX(-50%) translateY(0); }

/* ----- Calendar --------------------------------------------------------- */
.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 1px;
  background: var(--rule-soft);
  border: 1px solid var(--rule-soft);
}
.calendar-day {
  background: var(--cream);
  min-height: 90px;
  padding: 0.4rem;
  font-size: 0.8rem;
}
.calendar-day.other-month { background: var(--paper-deep); color: var(--muted); }
.calendar-day.today { background: rgba(200, 160, 71, 0.18); }
.calendar-day .date {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 600;
  color: var(--navy);
  font-size: 1rem;
}
.calendar-header-row {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  background: var(--navy);
  color: var(--paper);
}
.calendar-header-row .dow {
  text-align: center;
  padding: 0.6rem 0.2rem;
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}
.calendar-event {
  display: block;
  background: var(--navy);
  color: var(--paper);
  padding: 0.15rem 0.35rem;
  font-size: 0.7rem;
  margin-top: 0.25rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.calendar-event:hover { background: var(--navy-deep); text-decoration: none; }
.calendar-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

/* ----- Stat cards ------------------------------------------------------- */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}
.stat-card {
  background: var(--cream);
  border: 1px solid var(--rule-soft);
  border-left: 4px solid var(--navy);
  padding: 1rem 1.2rem;
}
.stat-card.gold  { border-left-color: var(--gold); }
.stat-card.muted { border-left-color: var(--muted); }
.stat-card .label {
  font-size: 0.62rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.2rem;
}
.stat-card .value {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.75rem;
  font-weight: 600;
  color: var(--navy-deep);
}

/* =========================================================================
   EVENT MANAGE — tabs, planning (checklist + log), review
   ========================================================================= */

/* ----- Tabs ------------------------------------------------------------- */
.event-tabs {
  display: flex;
  gap: 0;
  margin: 1rem 0 1.25rem;
  border-bottom: 2px solid var(--rule-soft);
  flex-wrap: wrap;
}
.event-tabs .tab {
  background: transparent;
  border: 0;
  border-bottom: 3px solid transparent;
  padding: 0.7rem 1.2rem;
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.05rem;
  font-weight: 500;
  color: var(--muted);
  cursor: pointer;
  margin-bottom: -2px;
  transition: color 0.15s ease, border-color 0.15s ease;
}
.event-tabs .tab:hover { color: var(--ink); }
.event-tabs .tab.active {
  color: var(--navy);
  border-bottom-color: var(--gold);
}
.tab-meta {
  font-family: 'Inter', sans-serif;
  font-size: 0.72rem;
  font-weight: 400;
  letter-spacing: 0.05em;
  color: var(--muted);
  margin-left: 0.2rem;
}
.tab-panel[hidden] { display: none; }

/* ----- Badges ----------------------------------------------------------- */
.badge {
  display: inline-block;
  font-family: 'Inter', sans-serif;
  font-size: 0.65rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.18rem 0.55rem;
  border: 1px solid currentColor;
  color: var(--muted);
  font-weight: 500;
  vertical-align: middle;
}
.badge-review {
  color: var(--claret, var(--red));
  background: rgba(139, 40, 24, 0.08);
}

/* ----- Checklist -------------------------------------------------------- */
.checklist-add {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}
.checklist-add input[type="text"] { flex: 1; }
.checklist-item {
  display: grid;
  grid-template-columns: auto 1fr auto auto;
  align-items: center;
  gap: 0.6rem;
  padding: 0.55rem 0.7rem;
  background: var(--cream);
  border: 1px solid var(--rule-soft);
  margin-bottom: 0.35rem;
  transition: opacity 0.15s ease;
}
.checklist-item .item-text {
  font-size: 0.93rem;
  outline: none;
  padding: 0.15rem 0.3rem;
  border: 1px dashed transparent;
  min-width: 0;
  word-break: break-word;
}
.checklist-item .item-text:focus { border-color: var(--rule-soft); background: var(--paper); }
.checklist-item.done .item-text { text-decoration: line-through; color: var(--muted); }
.checklist-item.cancelled .item-text { text-decoration: line-through; opacity: 0.5; }
.checklist-item.cancelled { opacity: 0.65; }
.status-dot {
  display: inline-block;
  width: 0.7rem;
  height: 0.7rem;
  border-radius: 50%;
  background: var(--muted);
  flex-shrink: 0;
}
.status-dot.todo        { background: var(--muted); }
.status-dot.in-progress { background: var(--amber); }
.status-dot.done        { background: var(--green); }
.status-dot.cancelled   { background: var(--rule-soft); }
.status-select {
  font-size: 0.78rem;
  padding: 0.25rem 0.4rem;
  background: var(--paper);
  border: 1px solid var(--rule-soft);
  font-family: 'Inter', sans-serif;
  color: var(--ink);
}
.icon-btn {
  background: transparent;
  border: 1px solid var(--rule-soft);
  color: var(--muted);
  width: 1.8rem;
  height: 1.8rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.95rem;
  line-height: 1;
  padding: 0;
  transition: all 0.15s ease;
}
.icon-btn:hover { color: var(--ink); border-color: var(--ink); background: var(--paper); }
.icon-btn.danger:hover { color: var(--red); border-color: var(--red); }

/* ----- Planning log ----------------------------------------------------- */
.log-add {
  padding: 0.85rem;
  background: var(--paper-deep);
  border: 1px solid var(--rule-soft);
  margin-bottom: 0.75rem;
}
.log-add-row {
  display: grid;
  grid-template-columns: 130px 1fr;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}
.log-add textarea { width: 100%; resize: vertical; min-height: 90px; margin-bottom: 0.4rem; }
.log-entry {
  position: relative;
  background: var(--cream);
  border: 1px solid var(--rule-soft);
  border-left: 3px solid var(--muted);
  padding: 0.7rem 0.9rem 0.7rem 0.85rem;
  margin-bottom: 0.55rem;
}
.log-entry.email    { border-left-color: var(--navy); }
.log-entry.call     { border-left-color: var(--gold); }
.log-entry.decision { border-left-color: var(--green); }
.log-entry.note     { border-left-color: var(--muted); }
.log-entry-header {
  font-size: 0.78rem;
  color: var(--muted);
  margin-bottom: 0.3rem;
  padding-right: 1.8rem;
}
.log-entry-type {
  display: inline-block;
  background: var(--paper-deep);
  padding: 0.08rem 0.4rem;
  font-size: 0.65rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink);
  border: 1px solid var(--rule-soft);
}
.log-entry-content {
  font-size: 0.92rem;
  white-space: pre-wrap;
  word-break: break-word;
  color: var(--ink);
  line-height: 1.5;
}
.log-delete {
  position: absolute;
  top: 0.4rem;
  right: 0.4rem;
  background: transparent;
  border: 0;
  color: var(--muted);
  cursor: pointer;
  font-size: 0.9rem;
  padding: 0.1rem 0.35rem;
}
.log-delete:hover { color: var(--red); }

/* ----- Review tab ------------------------------------------------------- */
.review-attendee-row {
  display: grid;
  grid-template-columns: 1fr auto auto auto;
  align-items: center;
  gap: 0.6rem;
  padding: 0.65rem 0.7rem;
  background: var(--cream);
  border: 1px solid var(--rule-soft);
  margin-bottom: 0.35rem;
}
.review-attendee-row:hover { background: var(--paper); }
.ra-name {
  font-size: 0.95rem;
  color: var(--ink);
  word-break: break-word;
}
.ra-name small {
  display: block;
  font-size: 0.72rem;
  color: var(--muted);
  letter-spacing: 0.04em;
  margin-top: 0.15rem;
}
.issue-marker {
  color: var(--amber);
  margin: 0 0.2rem;
  font-size: 0.85rem;
}

/* Review pills (clickable variant of .pill) */
.review-attendee-row .pill {
  cursor: pointer;
  background: transparent;
  font-size: 0.7rem;
  padding: 0.25rem 0.6rem;
  transition: all 0.15s ease;
}
.review-attendee-row .pill:hover { background: var(--paper); }
.pill-not-set { color: var(--muted); border-color: var(--rule-soft); }
.pill-attended { color: var(--paper); background: var(--green); border-color: var(--green); }
.pill-noshow   { color: var(--paper); background: var(--red);   border-color: var(--red); }
.pill-paid     { color: var(--paper); background: var(--green); border-color: var(--green); }
.pill-unpaid   { color: var(--red);   border-color: var(--red); }
.pill-attended:hover, .pill-noshow:hover, .pill-paid:hover {
  opacity: 0.85;
  background: currentColor;
}
.pill-attended:hover { background: var(--green); }
.pill-noshow:hover   { background: var(--red); }
.pill-paid:hover     { background: var(--green); }

/* Incident block (collapsed by default; expanded when toggled) */
.incident-block {
  grid-column: 1 / -1;
  display: none;
  padding-top: 0.5rem;
  border-top: 1px dashed var(--rule-soft);
  margin-top: 0.4rem;
}
.incident-block.active { display: block; }
.incident-block textarea {
  width: 100%;
  margin-top: 0.4rem;
  min-height: 50px;
  resize: vertical;
  font-size: 0.88rem;
}
.flag-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
}
.flag-chip {
  display: inline-block;
  cursor: pointer;
  font-size: 0.7rem;
  letter-spacing: 0.05em;
  padding: 0.2rem 0.55rem;
  background: var(--paper);
  border: 1px solid var(--rule-soft);
  color: var(--muted);
  user-select: none;
  transition: all 0.15s ease;
}
.flag-chip:hover { color: var(--ink); border-color: var(--ink); }
.flag-chip.active {
  background: var(--amber);
  color: var(--paper);
  border-color: var(--amber);
}

/* ----- Mobile ----------------------------------------------------------- */
@media (max-width: 700px) {
  .form-row-pair { grid-template-columns: 1fr; }
  .site-header-inner { flex-direction: column; align-items: flex-start; }
  .site-nav { width: 100%; }
  .calendar-day { min-height: 60px; font-size: 0.72rem; }

  /* Event manage tabs */
  .event-tabs .tab { padding: 0.55rem 0.8rem; font-size: 0.95rem; }

  /* Checklist */
  .checklist-item {
    grid-template-columns: auto 1fr auto;
    grid-template-areas:
      "dot  text   delete"
      ".    status status";
    gap: 0.4rem 0.5rem;
  }
  .checklist-item .status-dot { grid-area: dot; }
  .checklist-item .item-text  { grid-area: text; }
  .checklist-item .status-select { grid-area: status; justify-self: start; }
  .checklist-item .icon-btn { grid-area: delete; }

  /* Planning log */
  .log-add-row { grid-template-columns: 1fr; }

  /* Review attendee row */
  .review-attendee-row {
    grid-template-columns: 1fr;
    gap: 0.4rem;
  }
  .review-attendee-row > div:not(.ra-name):not(.incident-block) {
    display: flex;
    gap: 0.3rem;
    flex-wrap: wrap;
  }
}

/* =========================================================================
   GUEST LIST — sections, capacity banner, drag-and-drop
   ========================================================================= */

.capacity-banner {
  background: var(--paper-deep);
  border: 1px solid var(--rule-soft);
  border-left: 3px solid var(--navy);
  padding: 0.7rem 1rem;
  margin-bottom: 0.85rem;
  font-size: 0.95rem;
}
.capacity-banner.over { border-left-color: var(--red); }
.capacity-banner strong { color: var(--navy); }
.capacity-wait { color: var(--gold-deep); font-weight: 500; }
.capacity-over { color: var(--red); font-weight: 500; }

.guest-section {
  margin-bottom: 1.5rem;
}
.guest-section:last-child { margin-bottom: 0; }
.section-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--navy);
  margin: 0 0 0.5rem;
  padding-bottom: 0.3rem;
  border-bottom: 1px solid var(--rule-soft);
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
}
.section-sub {
  font-family: 'Inter', sans-serif;
  font-size: 0.7rem;
  font-weight: 400;
  letter-spacing: 0.06em;
  color: var(--muted);
  text-transform: uppercase;
}
.section-empty {
  font-style: italic;
  color: var(--muted);
  padding: 0.5rem 0.2rem 0.8rem;
  font-size: 0.9rem;
}

.guest-section-confirmed .section-title { border-bottom-color: var(--green); }
.guest-section-waitlist  .section-title { border-bottom-color: var(--gold); }
.guest-section-tentative .section-title { border-bottom-color: var(--rule-soft); }
.guest-section-declined  .section-title { border-bottom-color: var(--rule-soft); color: var(--muted); }

.btn-link {
  background: transparent;
  border: 0;
  color: inherit;
  font: inherit;
  cursor: pointer;
  padding: 0;
  text-align: left;
}

/* Host chain text shown beneath the name */
.host-chain {
  font-size: 0.78rem;
  color: var(--muted);
  margin-top: 0.15rem;
  font-style: italic;
  font-family: 'Cormorant Garamond', serif;
}
.host-chain strong {
  color: var(--ink);
  font-style: normal;
  font-family: 'Inter', sans-serif;
  font-weight: 500;
  font-size: 0.78rem;
}

/* Mini pill (used inline next to guest names) */
.pill-mini {
  font-size: 0.6rem;
  letter-spacing: 0.07em;
  padding: 0.08rem 0.4rem;
  margin-left: 0.4rem;
  vertical-align: middle;
}

/* Drag handle */
.drag-handle {
  cursor: grab;
  color: var(--rule-soft);
  user-select: none;
  text-align: center;
  font-size: 1rem;
  width: 1.5rem;
}
.drag-handle:hover { color: var(--muted); }
.drag-handle:active { cursor: grabbing; }

.guest-table tr.dragging { opacity: 0.4; }
.guest-table tr.drop-target {
  border-top: 2px solid var(--navy);
}

/* Tighter spacing in nested guest tables */
.guest-table { margin-bottom: 0; }

/* =========================================================================
   MEMBERSHIP REQUEST FLOW
   ========================================================================= */

.auth-card-wide { max-width: 640px; }

.muted-inline { color: var(--muted); font-size: 0.85rem; font-weight: 400; }

.club-checklist {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.4rem;
  padding: 0.6rem;
  background: var(--paper-deep);
  border: 1px solid var(--rule-soft);
  max-height: 220px;
  overflow-y: auto;
}
.club-check {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.92rem;
  font-weight: 400;
  margin: 0;
  padding: 0.15rem 0;
  cursor: pointer;
  color: var(--ink);
}
.club-check input { margin: 0; }

.checkbox-inline {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin: 0 1rem 0.4rem 0;
  font-weight: 400;
  font-size: 0.92rem;
  color: var(--ink);
}

/* Tabs (used on the requests list) */
.tab-strip {
  display: flex;
  gap: 0;
  border-bottom: 2px solid var(--rule-soft);
  margin-top: 0.5rem;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}
.tab-strip .tab {
  display: inline-block;
  padding: 0.55rem 1rem;
  margin-bottom: -2px;
  border-bottom: 3px solid transparent;
  font-family: 'Cormorant Garamond', serif;
  font-size: 1rem;
  color: var(--muted);
  text-decoration: none;
  cursor: pointer;
}
.tab-strip .tab:hover  { color: var(--ink); }
.tab-strip .tab.active { color: var(--navy); border-bottom-color: var(--gold); }

/* Status pills */
.pill-amber  { background: rgba(168, 106, 28, 0.13);  color: var(--amber);   border-color: var(--amber); }
.pill-green  { background: rgba(61, 92, 58, 0.13);    color: var(--green);   border-color: var(--green); }
.pill-muted  { color: var(--muted); }

/* Proofs list on review page */
.file-list { list-style: none; padding: 0; margin: 0; }
.file-row {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  padding: 0.6rem 0;
  border-bottom: 1px solid var(--rule-soft);
}
.file-row:last-child { border-bottom: none; }
.file-thumb {
  width: 72px; height: 72px;
  object-fit: cover;
  background: var(--paper-deep);
  border: 1px solid var(--rule-soft);
}
.file-icon {
  width: 72px; height: 72px;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--paper-deep);
  border: 1px solid var(--rule-soft);
  font-size: 1.8rem;
}
.file-meta { flex: 1; min-width: 0; font-size: 0.9rem; word-break: break-word; }

/* Bulk-action bar (event manage page) */
.bulk-bar {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  padding: 0.6rem 0.8rem;
  margin: 0.5rem 0 0.75rem;
  background: var(--paper-deep);
  border-left: 3px solid var(--navy);
  border-radius: 2px;
}
.bulk-count {
  font-weight: 600;
  font-size: 0.9rem;
  margin-right: 0.5rem;
  color: var(--navy);
}
.bulk-select, .bulk-select-all { cursor: pointer; }

/* Club picker (W1) — additions on top of the .club-checklist / .club-check base */
.club-picker { display: block; }
.club-picker-search {
  width: 100%;
  padding: 0.5rem 0.7rem;
  margin-bottom: 0.4rem;
  border: 1px solid var(--rule-soft);
  background: var(--paper);
  font-size: 0.92rem;
  box-sizing: border-box;
}
.club-picker-freetext {
  margin-top: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.club-picker-other {
  flex: 1;
  padding: 0.4rem 0.6rem;
  border: 1px solid var(--rule-soft);
  background: var(--paper);
  font-size: 0.9rem;
}

/* CSV import per-row club checklist (W1.6) */
.csv-clubs-cell {
  max-width: 360px;
  max-height: 160px;
  overflow-y: auto;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 0.2rem 0.5rem;
  font-size: 0.85rem;
  padding: 0.3rem;
  background: var(--paper-deep);
  border: 1px solid var(--rule-soft);
}
.csv-clubs-cell .club-check { font-size: 0.85rem; padding: 0.05rem 0; }

/* ============================================================
 * v5.6: Public event page + member self-RSVP UI
 * ============================================================ */

body.public-event-page {
  background: var(--paper, #f5f1e8);
  min-height: 100vh;
}
.public-header {
  padding: 1rem 1.5rem;
  text-align: center;
  border-bottom: 1px solid var(--rule-soft, #c9bfa8);
  background: var(--paper-deep, #ede6d3);
}
.public-event-card {
  max-width: 720px;
  margin: 1.5rem auto 2rem;
  background: var(--paper, #f5f1e8);
  border: 1px solid var(--rule-soft, #c9bfa8);
  padding: 1.5rem 1.75rem 1.75rem;
}
.public-event-card h1 {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 1.8rem;
  margin-bottom: 0.75rem;
  color: var(--ink, #1a1815);
}
.public-event-card dl.event-detail-list {
  margin: 1rem 0 1rem;
}
.event-notes h3 {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 1.2rem;
  margin: 1.25rem 0 0.5rem;
}
.event-cta {
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--rule-soft, #c9bfa8);
}
.attendee-count {
  font-size: 0.95rem;
  color: var(--ink, #1a1815);
  margin-bottom: 0.75rem;
}
.attendee-count .muted-inline {
  color: var(--muted, #6b6357);
  font-size: 0.82rem;
}

.rsvp-prompt {
  font-size: 0.92rem;
  margin: 0.5rem 0 0.75rem;
}
.rsvp-pill {
  display: inline-block;
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.2rem 0.5rem;
  margin: 0 0.2rem;
  border: 1px solid currentColor;
  background: transparent;
  font-weight: 500;
}
.rsvp-pill-confirmed { color: var(--green, #3d5c3a); }
.rsvp-pill-tentative { color: var(--amber, #a86a1c); }
.rsvp-pill-declined  { color: var(--red,   #8b2818); }
.rsvp-pill-waitlist  { color: var(--slate, #4a5560); }

.rsvp-button-row {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}
.rsvp-form {
  margin: 0;
  display: inline-block;
}
.rsvp-choice {
  border: 1px solid currentColor;
  background: transparent;
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  padding: 0.55rem 1.2rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.12s;
  font-family: inherit;
}
.rsvp-choice-confirmed { color: var(--green, #3d5c3a); }
.rsvp-choice-tentative { color: var(--amber, #a86a1c); }
.rsvp-choice-declined  { color: var(--red,   #8b2818); }
.rsvp-choice:hover { background: currentColor; color: var(--paper, #f5f1e8) !important; }
.rsvp-choice.is-current {
  background: currentColor;
  color: var(--paper, #f5f1e8) !important;
  font-weight: 600;
}
.rsvp-choice.is-current::before {
  content: '✓ ';
}

.attendees-list-public {
  margin-top: 1.75rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--rule-soft, #c9bfa8);
}
.attendees-list-public h3 {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 1.15rem;
  margin-bottom: 0.75rem;
  color: var(--ink, #1a1815);
}
.attendee-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 0.4rem 0.85rem;
}
.attendee-grid-item {
  font-size: 0.88rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.3rem 0;
}
.attendee-grid-item.attendee-tentative .attendee-name { color: var(--amber, #a86a1c); }
.attendee-grid-item.attendee-waitlist  .attendee-name { color: var(--slate, #4a5560); }
.attendee-name {
  color: var(--ink, #1a1815);
  font-weight: 500;
}
.attendee-status-tag {
  font-size: 0.62rem;
  font-weight: 700;
  color: var(--amber, #a86a1c);
  border: 1px solid var(--amber, #a86a1c);
  padding: 0.05rem 0.35rem;
  letter-spacing: 0.05em;
}
.attendee-status-tag.attendee-status-waitlist {
  color: var(--slate, #4a5560);
  border-color: var(--slate, #4a5560);
}
.attendee-lic-tag {
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: var(--paper, #f5f1e8);
  background: var(--slate, #4a5560);
  padding: 0.1rem 0.4rem;
  text-transform: uppercase;
}

.public-footer {
  text-align: center;
  font-size: 0.78rem;
  color: var(--muted, #6b6357);
  padding: 1rem;
}

/* ============================================================
 * v5.6: Rep guest screen — prototype-styled pills, chips, tags
 * Adopts visual language from the v5.5 prototype mockup.
 * ============================================================ */

/* Guest table */
table.guests {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}
table.guests thead th {
  text-align: left;
  font-size: 0.62rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted, #6b6357);
  font-weight: 500;
  padding: 0.6rem 0.4rem;
  border-bottom: 1px solid var(--rule, #2a2520);
}
table.guests tbody td {
  padding: 0.6rem 0.4rem;
  border-bottom: 1px solid var(--rule-soft, #c9bfa8);
  vertical-align: middle;
}
table.guests tbody tr:hover { background: var(--paper-deep, #ede6d3); }

/* Amber tint when a non-sub-guest isn't tagged with the host club */
table.guests tr.row-unhosted {
  background: rgba(168, 106, 28, 0.06);
}
table.guests tr.row-unhosted:hover {
  background: rgba(168, 106, 28, 0.12);
}

/* Tick / cross icons in Host + LIC columns */
.tick, .cross {
  display: inline-block;
  width: 1.2rem;
  text-align: center;
  font-weight: 600;
}
.tick  { color: var(--green, #3d5c3a); }
.cross { color: var(--rule-soft, #c9bfa8); }

/* Member / Guest / Sub-guest type tags inline next to the name */
.member-tag, .guest-tag, .sub-guest-tag, .lic-tag {
  display: inline-block;
  font-size: 0.6rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 0.15rem 0.45rem;
  font-weight: 500;
  margin-left: 0.3rem;
}
.member-tag    { background: var(--claret, #6b1e2c); color: var(--paper, #f5f1e8); }
.lic-tag       { background: var(--slate,  #4a5560); color: var(--paper, #f5f1e8); }
.guest-tag     { border: 1px solid var(--rule-soft, #c9bfa8); color: var(--muted, #6b6357); }
.sub-guest-tag { border: 1px solid var(--gold, #8a7340); color: var(--gold, #8a7340); }

/* Host chain (italic, small, sits under the name) */
.host-line {
  font-size: 0.75rem;
  color: var(--muted, #6b6357);
  font-style: italic;
  font-family: 'Cormorant Garamond', Georgia, serif;
  margin-top: 0.15rem;
}

/* Clubs column: small chips */
.clubs-cell {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  max-width: 280px;
}
.club-row-chip {
  font-size: 0.66rem;
  letter-spacing: 0.04em;
  padding: 0.12rem 0.4rem;
  border: 1px solid var(--slate, #4a5560);
  color: var(--slate, #4a5560);
  background: rgba(74, 85, 96, 0.06);
  line-height: 1.3;
  white-space: nowrap;
}
.club-row-chip.other {
  border-color: var(--gold, #8a7340);
  color: var(--gold, #8a7340);
  background: rgba(138, 115, 64, 0.06);
  font-style: italic;
}

/* Status pills (RSVP + attendance + payment) - clickable */
.pill {
  display: inline-block;
  cursor: pointer;
  font-size: 0.66rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.28rem 0.55rem;
  border: 1px solid currentColor;
  background: transparent;
  font-family: inherit;
  font-weight: 500;
  transition: all 0.15s;
  white-space: nowrap;
}
.pill:hover { background: currentColor; color: var(--paper, #f5f1e8) !important; }

.pill-confirmed { color: var(--green, #3d5c3a); }
.pill-tentative { color: var(--amber, #a86a1c); }
.pill-waitlist  { color: var(--slate, #4a5560); }
.pill-declined  { color: var(--red,   #8b2818); }
.pill-paid      { color: var(--green, #3d5c3a); }
.pill-unpaid    { color: var(--red,   #8b2818); }
.pill-attended  { color: var(--green, #3d5c3a); }
.pill-noshow    { color: var(--red,   #8b2818); }
.pill-not-set   { color: var(--muted, #6b6357); }
.pill-readonly  { cursor: default; pointer-events: none; opacity: 0.7; }

/* Status-menu popover (shown when a status pill is clicked) */
.status-menu {
  background: var(--paper, #f5f1e8);
  border: 1px solid var(--rule, #2a2520);
  padding: 0.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  box-shadow: 0 4px 14px rgba(0,0,0,0.12);
  min-width: 7rem;
}
.status-menu-item {
  text-align: left;
  padding: 0.35rem 0.7rem;
}

/* ============================================================
 * v5.7: Pill-style club picker
 * Replaces checkbox checklist with clickable chips. The underlying
 * <input type="checkbox"> stays in the DOM (visually hidden) so
 * form submission and keyboard accessibility still work.
 * ============================================================ */

.club-picker {
  border: 1px solid var(--rule-soft, #c9bfa8);
  background: var(--paper, #f5f1e8);
  padding: 0.6rem;
}
.club-picker-search {
  width: 100%;
  margin-bottom: 0.55rem;
  padding: 0.4rem 0.55rem;
  font-size: 0.85rem;
  border: 1px solid var(--rule-soft, #c9bfa8);
  background: var(--paper, #f5f1e8);
}

/* The list becomes a flex-wrap row of pills */
.club-picker > [id$="-list"],
.club-picker .club-picker-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  max-height: 220px;
  overflow-y: auto;
  padding: 0.1rem;
}

/* Each option styled as a chip */
.club-pill,
label.club-pill {
  display: inline-flex !important;
  align-items: center;
  cursor: pointer;
  font-size: 0.78rem !important;
  letter-spacing: 0.03em !important;
  text-transform: none !important;
  padding: 0.32rem 0.7rem !important;
  margin: 0 !important;
  border: 1px solid var(--rule-soft, #c9bfa8) !important;
  background: var(--paper-deep, #ede6d3) !important;
  color: var(--muted, #6b6357) !important;
  user-select: none;
  transition: all 0.12s;
  line-height: 1.2 !important;
  white-space: nowrap !important;
  font-weight: 400 !important;
  vertical-align: middle;
}
/* If you see this rule in DevTools but pills still look broken,
   the CSS is loading but something else is overriding. */
.club-pill:hover {
  border-color: var(--ink, #1a1815);
  color: var(--ink, #1a1815);
}
.club-pill.is-selected {
  background: var(--slate, #4a5560) !important;
  border-color: var(--slate, #4a5560) !important;
  color: var(--paper, #f5f1e8) !important;
  font-weight: 500 !important;
}
.club-pill.is-selected:hover {
  background: var(--ink, #1a1815) !important;
  border-color: var(--ink, #1a1815) !important;
  color: var(--paper, #f5f1e8) !important;
}
.club-pill-label {
  pointer-events: none;
}
/* Keep the checkbox in the DOM for form submission + a11y,
 * but visually hidden. Two layers of defence so it doesn't show even
 * if a more-specific browser default UA rule sneaks in.
 *
 * v6.9.1 fix: do NOT set pointer-events:none on the checkbox. When the
 * pointer-events:none was present, Chrome (and Edge/Brave on Blink)
 * suppressed the synthetic click that a <label> click would otherwise
 * dispatch to its wrapped <input>. Pills then looked clickable but did
 * nothing. The clip + width:1px + opacity:0 already prevent the checkbox
 * from intercepting clicks visually, so pointer-events:none was not
 * needed and was actively breaking clickability. The label-text
 * .club-pill-label keeps pointer-events:none so the click falls through
 * cleanly to the label itself.
 */
.club-pill-checkbox,
.club-pill input[type="checkbox"] {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
  opacity: 0 !important;
}
.club-pill:has(.club-pill-checkbox:focus-visible) {
  outline: 2px solid var(--claret, #6b1e2c);
  outline-offset: 2px;
}

/* "Other clubs" freetext field below the pill list */
.club-picker-freetext {
  margin-top: 0.55rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.club-picker-other {
  flex: 1;
  padding: 0.4rem 0.55rem;
  font-size: 0.85rem;
  border: 1px solid var(--rule-soft, #c9bfa8);
  background: var(--paper, #f5f1e8);
}

/* ============================================================
 * v5.7: Member directory picker (single-click-to-add)
 * ============================================================ */

.m-list {
  max-height: 320px;
  overflow-y: auto;
  background: var(--paper, #f5f1e8);
  border: 1px solid var(--rule-soft, #c9bfa8);
  margin-top: 0.5rem;
}
.picker-helper {
  font-size: 0.78rem;
  color: var(--muted, #6b6357);
  font-style: italic;
  margin: 0.4rem 0 0.2rem;
}
.picker-empty {
  padding: 0.85rem 1rem;
  color: var(--muted, #6b6357);
  font-size: 0.85rem;
  margin: 0;
  line-height: 1.45;
}

.m-row {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-rows: auto auto;
  gap: 0.1rem 0.75rem;
  width: 100%;
  padding: 0.55rem 0.75rem;
  border: 0;
  border-bottom: 1px solid var(--rule-soft, #c9bfa8);
  background: var(--paper, #f5f1e8);
  text-align: left;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.88rem;
  color: var(--ink, #1a1815);
  transition: background 0.1s;
}
.m-row:last-child { border-bottom: 0; }
.m-row:hover {
  background: var(--paper-deep, #ede6d3);
}
.m-row.is-adding {
  opacity: 0.55;
  pointer-events: none;
}
.m-row-main {
  grid-row: 1;
  grid-column: 1;
}
.m-row-main strong {
  font-weight: 600;
  font-size: 0.92rem;
}
.m-row-contact {
  color: var(--muted, #6b6357);
  font-size: 0.78rem;
  margin-left: 0.45rem;
}
.m-row-clubs {
  grid-row: 2;
  grid-column: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  margin-top: 0.15rem;
}
.m-row-club {
  font-size: 0.66rem;
  letter-spacing: 0.04em;
  padding: 0.08rem 0.4rem;
  border: 1px solid var(--slate, #4a5560);
  color: var(--slate, #4a5560);
  background: rgba(74, 85, 96, 0.06);
  white-space: nowrap;
}
.m-row-noclubs {
  font-size: 0.7rem;
  font-style: italic;
  color: var(--muted, #6b6357);
}
.m-row-add {
  grid-row: 1 / span 2;
  grid-column: 2;
  align-self: center;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  padding: 0.3rem 0.7rem;
  border: 1px solid var(--green, #3d5c3a);
  color: var(--green, #3d5c3a);
  background: transparent;
  white-space: nowrap;
  text-transform: uppercase;
  font-weight: 500;
}
.m-row:hover .m-row-add {
  background: var(--green, #3d5c3a);
  color: var(--paper, #f5f1e8);
}

/* v5.7: inline LIC toggle button on guest rows */
.lic-toggle {
  background: transparent;
  border: 0;
  cursor: pointer;
  font-size: 1rem;
  font-weight: 600;
  padding: 0.15rem 0.4rem;
  color: var(--rule-soft, #c9bfa8);
  font-family: inherit;
  transition: color 0.12s, background 0.12s;
}
.lic-toggle:hover {
  background: rgba(74, 85, 96, 0.1);
  color: var(--slate, #4a5560);
}
.lic-toggle.is-lic {
  color: var(--green, #3d5c3a);
}
.lic-toggle.is-lic:hover {
  background: rgba(61, 92, 58, 0.12);
}

/* ----- v6.9 Phase 4: member home dashboard ----------------------------- */

/* P4-9 option (b): slim navy strip below the header, on home.php only.
   Same navy/gold palette as .site-header so it visually extends the
   blue ribbon, but a one-line strip rather than three big cards.       */
.home-stat-strip {
  background: var(--navy-deep);
  color: var(--paper);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.9rem;
  padding: 0.55rem 1rem;
  margin: -1.25rem -1.25rem 1.25rem -1.25rem;  /* bleed to the container edges */
  border-bottom: 1px solid var(--gold);
}
.home-stat-strip strong {
  color: var(--gold);
  font-weight: 600;
  margin-right: 0.25rem;
}
.home-stat-sep { color: var(--paper-mute); }

/* P4-2: 2-column grid. RSVPs + Action items dominate left; Clubs +
   Ticker + Announcements on the right. Single column under ~768px.   */
.home-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 1.25rem;
}
.home-col {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  min-width: 0;  /* prevents the column from blowing out on long titles */
}
@media (max-width: 768px) {
  .home-grid { grid-template-columns: 1fr; }
  .home-stat-strip { flex-wrap: wrap; }
}

/* Tile = card-style container shared by all home-page partials. Tighter
   than .card because the home page has many tiles side-by-side.       */
.tile {
  background: var(--cream);
  border: 1px solid var(--rule-soft);
  padding: 1rem 1.15rem;
}
.tile-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.15rem;
  font-weight: 600;
  margin: 0 0 0.65rem 0;
  color: var(--navy);
}
.tile-empty {
  color: var(--muted);
  font-style: italic;
  margin: 0 0 0.5rem 0;
}

/* List inside a tile: zero-margin, no bullets, hairline dividers.     */
.tile-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.tile-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  padding: 0.45rem 0;
  border-top: 1px solid var(--rule-soft);
}
.tile-row:first-child { border-top: none; }
.tile-row-main {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-width: 0;
  color: inherit;
}
.tile-row-main:hover { text-decoration: none; }
.tile-row-main:hover .tile-row-title { text-decoration: underline; }
.tile-row-title {
  font-weight: 500;
  color: var(--navy);
}
.tile-row-meta {
  font-size: 0.82rem;
  color: var(--muted);
  margin-top: 0.1rem;
}
.tile-row.is-past .tile-row-title { color: var(--muted); }
.tile-row.is-today .tile-row-title { color: var(--gold-deep); }

/* Action-item count badge: right-aligned, subtle.                     */
.tile-count {
  flex: 0 0 auto;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--navy);
  background: var(--paper-deep);
  padding: 0.15rem 0.5rem;
  border-radius: 2px;
}

/* "Your clubs" role labels: monochrome text per P4-4 (Member / Rep /
   Contact). Plain text in a muted box; no colours that imply status. */
.tile-row-roles {
  margin-top: 0.2rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
}
.role-label {
  font-size: 0.65rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  border: 1px solid var(--rule-soft);
  padding: 0.1rem 0.4rem;
  font-weight: 500;
}

/* Announcements tile: a feed of multi-line entries, not a list of
   single rows. Each item gets a title + date + body block.            */
.tile-list-feed { padding: 0; margin: 0; }
.tile-feed-item {
  list-style: none;
  padding: 0.6rem 0;
  border-top: 1px solid var(--rule-soft);
}
.tile-feed-item:first-child { border-top: none; padding-top: 0; }
.tile-feed-title {
  font-size: 0.95rem;
  font-weight: 600;
  margin: 0 0 0.1rem 0;
  color: var(--navy);
}
.tile-feed-date {
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.3rem;
}
.tile-feed-body {
  font-size: 0.9rem;
  color: var(--ink, #2a2520);
}

/* ----- v6.9 Phase 5: clubs accordion ---------------------------------- */

.club-filter {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.85rem;
  margin: 0 0 1rem 0;
}
.club-filter input[type="search"] {
  flex: 1 1 18rem;
  padding: 0.55rem 0.75rem;
  font-size: 0.95rem;
  border: 1px solid var(--rule-soft);
  background: var(--paper);
}
.club-filter-mine {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.88rem;
  color: var(--ink, #2a2520);
  user-select: none;
}
/* The noscript-only Apply button is hidden once JS marks the form as
   enhanced. The <noscript> tag handles the case where JS is absent.   */
.club-filter[data-js-enhanced="1"] noscript { display: none; }

.club-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.club-list-empty {
  text-align: center;
  color: var(--muted);
  font-style: italic;
  padding: 1.5rem 0;
}

/* One accordion row. Reuses the .card visual language but slimmer.    */
.club-accordion {
  background: var(--cream);
  border: 1px solid var(--rule-soft);
}
.club-accordion[open] {
  border-color: var(--navy);
}
.club-summary {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  cursor: pointer;
  list-style: none;
  position: relative;
  padding-right: 2.25rem;  /* room for the disclosure indicator */
}
/* Hide the native triangle / use our own indicator instead.          */
.club-summary::-webkit-details-marker { display: none; }
.club-summary::marker { content: ''; }
.club-summary::after {
  content: '+';
  position: absolute;
  right: 0.85rem;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.1rem;
  color: var(--muted);
  font-weight: 600;
  line-height: 1;
}
.club-accordion[open] > .club-summary::after { content: '−'; }

.club-summary:hover { background: var(--paper-deep); }

.club-summary-main {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  flex: 1 1 auto;
  min-width: 0;
}
.club-summary-crest {
  width: 40px;
  height: 40px;
  object-fit: contain;
  background: var(--paper);
  border: 1px solid var(--rule-soft);
  flex: 0 0 auto;
}
.club-summary-text {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  min-width: 0;
}
.club-summary-name {
  font-weight: 600;
  color: var(--navy);
  font-size: 1rem;
}
.club-summary-desc {
  font-size: 0.88rem;
  color: var(--ink, #2a2520);
  /* one-line clamp without overflow weirdness                        */
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.club-summary-reps {
  font-size: 0.78rem;
  color: var(--muted);
}
.club-summary-actions {
  display: flex;
  gap: 0.3rem;
  flex-wrap: wrap;
  flex: 0 0 auto;
  align-items: center;
}

.club-accordion-body {
  padding: 0.25rem 1rem 1rem 1rem;
  border-top: 1px solid var(--rule-soft);
  background: var(--paper);
}
.club-accordion-body h4 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.05rem;
  font-weight: 600;
  margin: 0.85rem 0 0.4rem 0;
  color: var(--navy);
}
.club-accordion-body h4:first-child { margin-top: 0.5rem; }
.club-accordion-details {
  display: grid;
  grid-template-columns: max-content 1fr;
  column-gap: 1rem;
  row-gap: 0.3rem;
  margin: 0;
}
.club-accordion-details dt {
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.club-accordion-details dd { margin: 0; }
.club-accordion-events {
  list-style: none;
  padding: 0;
  margin: 0;
}
.club-accordion-events li {
  padding: 0.3rem 0;
  border-top: 1px solid var(--rule-soft);
}
.club-accordion-events li:first-child { border-top: none; }

@media (max-width: 600px) {
  .club-summary { flex-wrap: wrap; }
  .club-summary-actions { width: 100%; padding-top: 0.4rem; }
}

/* ============================================================
   v9.1 Part 22 -- structured event menu editor
   (members/events/event-edit.php, driven by event-menu-edit.js)
   ============================================================ */

.menu-editor-panels {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin-top: 0.4rem;
}

@media (max-width: 800px) {
  .menu-editor-panels { grid-template-columns: 1fr; }
}

.menu-panel {
  border: 1px solid var(--rule-soft);
  border-radius: 4px;
  padding: 0.6rem;
  background: var(--cream);
}

.menu-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem;
  margin-bottom: 0.5rem;
  padding-bottom: 0.35rem;
  border-bottom: 1px solid var(--rule-soft);
}

.menu-panel-title {
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0;
}

.menu-panel-empty {
  padding: 0.6rem 0.4rem;
  font-size: 0.8rem;
  font-style: italic;
}

.menu-sections {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.menu-section-card {
  border: 1px solid var(--rule-soft);
  border-radius: 4px;
  background: var(--paper);
  padding: 0.5rem 0.6rem;
}

.menu-section-card.menu-dragging  { opacity: 0.4; }
.menu-section-card.menu-drop-target { border-color: var(--navy); border-style: dashed; }

.menu-section-head {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin-bottom: 0.4rem;
  flex-wrap: wrap;
}

.menu-section-title {
  flex: 1 1 8rem;
  min-width: 6rem;
  font-weight: 500;
  font-size: 0.95rem;
  padding: 0.3rem 0.4rem;
  border: 1px solid var(--rule-soft);
  background: var(--cream);
  border-radius: 3px;
}

.menu-section-default {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.78rem;
  color: var(--muted);
}

.menu-price-input {
  width: 5.5rem;
  padding: 0.25rem 0.35rem;
  border: 1px solid var(--rule-soft);
  background: var(--cream);
  border-radius: 3px;
  font-size: 0.85rem;
  font-variant-numeric: tabular-nums;
  text-align: right;
}

.menu-items {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  margin: 0.35rem 0;
}

.menu-item-row {
  border: 1px solid var(--rule-soft);
  border-radius: 3px;
  background: var(--cream);
  padding: 0.35rem 0.4rem;
}

.menu-item-row.menu-dragging  { opacity: 0.4; }
.menu-item-row.menu-drop-target { border-color: var(--navy); border-style: dashed; }

.menu-item-top,
.menu-item-mid {
  display: flex;
  gap: 0.35rem;
  align-items: center;
}

.menu-item-top { margin-bottom: 0.25rem; }
.menu-item-mid { margin-bottom: 0.25rem; flex-wrap: wrap; }

.menu-item-name {
  flex: 1 1 6rem;
  min-width: 5rem;
  padding: 0.25rem 0.35rem;
  border: 1px solid var(--rule-soft);
  background: var(--paper);
  border-radius: 3px;
  font-size: 0.9rem;
}

.menu-item-price {
  display: inline-flex;
  align-items: center;
  gap: 0.15rem;
  font-size: 0.78rem;
  color: var(--muted);
}

.menu-item-description,
.menu-item-allergen {
  flex: 1 1 0;
  min-width: 8rem;
  padding: 0.25rem 0.35rem;
  border: 1px solid var(--rule-soft);
  background: var(--paper);
  border-radius: 3px;
  font-size: 0.8rem;
}

.menu-item-allergen {
  font-style: italic;
  color: var(--amber);
}

.menu-item-flags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  font-size: 0.7rem;
}

.menu-flag-label {
  display: inline-flex;
  align-items: center;
  gap: 0.15rem;
  padding: 0.1rem 0.35rem;
  border: 1px solid var(--rule-soft);
  border-radius: 2px;
  cursor: pointer;
  background: var(--paper);
}

.menu-flag-cb {
  width: auto;
  margin: 0;
  cursor: pointer;
}

.menu-flag-code {
  font-weight: 500;
  letter-spacing: 0.02em;
}

.menu-drag-handle {
  cursor: grab;
  color: var(--muted);
  user-select: none;
  padding: 0 0.2rem;
  font-size: 0.9rem;
}

.menu-drag-handle:active { cursor: grabbing; }

.menu-item-delete {
  flex: 0 0 auto;
  padding: 0.15rem 0.45rem;
  line-height: 1;
}

.menu-item-add-row {
  margin-top: 0.35rem;
  text-align: left;
}
