/* Front layout styles ? cloned from rcmbd/index.html */
:root {
  --rotary-blue: #0b4da2;
  --rotary-blue-2: #083b7d;
  --rotary-gold: #f7a81b;
  --ink: #0b1b33;
  --muted: #5a6b86;
  --card: #ffffff;
  --soft: #f5f7fb;
}

body {
  color: var(--ink);
  background: var(--soft);
}

a {
  text-decoration: none;
}

.shadow-soft {
  box-shadow: 0 10px 30px rgba(11, 27, 51, 0.08);
}

/* Top mini bar */
.topbar {
  background: linear-gradient(90deg, var(--rotary-blue-2), var(--rotary-blue));
  color: #fff;
  font-size: 0.9rem;
}

.topbar a {
  color: #fff;
  opacity: 0.9;
}

.topbar a:hover {
  opacity: 1;
}

/* Navbar */
.brand-logo {
  height: 70px;
  width: auto;
}

.navbar {
  background: #fff;
  border-bottom: 1px solid rgba(11, 27, 51, 0.06);
}

.nav-link {
  color: var(--ink);
  font-weight: 600;
}

.nav-link:hover {
  color: var(--rotary-blue);
}

.nav-underline .nav-link.active {
  color: var(--rotary-blue);
  border-bottom: 3px solid var(--rotary-gold);
  padding-bottom: 0.65rem;
}

/* Hero */
.hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(1200px 500px at 20% 20%, rgba(247, 168, 27, 0.25), transparent 60%),
    linear-gradient(120deg, var(--rotary-blue-2), var(--rotary-blue));
  color: #fff;
  border-bottom-left-radius: 28px;
  border-bottom-right-radius: 28px;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    url('https://images.unsplash.com/photo-1520975958225-6662d5c0f6e1?auto=format&fit=crop&w=1800&q=70') center / cover no-repeat;
  opacity: 0.18;
  pointer-events: none;
}

.hero.has-bg::after {
  background-image: var(--hero-bg);
}

.hero-inner {
  position: relative;
  z-index: 1;
  padding: 64px 0 40px;
}

.hero h1 {
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.05;
}

.hero p {
  color: rgba(255, 255, 255, 0.9);
  max-width: 56ch;
}

.hero-cta .btn {
  padding: 0.9rem 1.2rem;
  border-radius: 14px;
  font-weight: 700;
}

.btn-rotary {
  background: var(--rotary-gold);
  border-color: var(--rotary-gold);
  color: #1a1a1a;
}

.btn-rotary:hover {
  filter: brightness(0.95);
  background: var(--rotary-gold);
  border-color: var(--rotary-gold);
  color: #1a1a1a;
}

.btn-outline-light {
  border-width: 2px;
  border-radius: 14px;
  font-weight: 700;
}

/* Gold wave */
.gold-wave {
  position: absolute;
  left: -10%;
  right: -10%;
  bottom: -1px;
  height: 140px;
  background: radial-gradient(120% 120% at 50% 0%, rgba(247, 168, 27, 0.55), rgba(247, 168, 27, 0.12) 55%, transparent 72%);
  transform: skewY(-2deg);
  opacity: 0.9;
  pointer-events: none;
}

/* Stats strip */
.stats-strip {
  margin-top: 15px;
  position: relative;
  z-index: 3;
}

/* When homepage slideshow is present, pull stats over its bottom edge */
.home-slideshow + .stats-strip {
  margin-top: -42px;
}

/* Homepage full-bleed slideshow (inspired by rotaryclubmakati.org) */
.home-slideshow {
  position: relative;
  min-height: clamp(480px, 90vh, 800px);
  overflow: hidden;
  background: #0b1b33;
  color: #fff;
}

.home-slideshow-track {
  position: absolute;
  inset: 0;
}

.home-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.9s ease, visibility 0.9s;
  z-index: 1;
}

.home-slide.is-active {
  opacity: 1;
  visibility: visible;
  z-index: 2;
}

.home-slide-media {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transform: scale(1.06);
  transition: transform 7s ease-out;
}

.home-slide.is-active .home-slide-media {
  transform: scale(1);
}

.home-slide-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(8, 27, 51, 0.28) 0%, rgba(8, 27, 51, 0.55) 45%, rgba(8, 27, 51, 0.82) 100%),
    linear-gradient(90deg, rgba(11, 77, 162, 0.35) 0%, transparent 55%);
}

.home-slide-content {
  position: relative;
  z-index: 3;
  height: 100%;
  min-height: inherit;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 4.5rem 0 5.5rem;
  max-width: 920px;
  margin-left: auto;
  margin-right: auto;
}

.home-slide-eyebrow {
  margin: 0 0 0.65rem;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--rotary-gold, #F7A81B);
}

.home-slide-title {
  margin: 0 0 0.85rem;
  font-size: clamp(1.85rem, 4.6vw, 3.4rem);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  text-shadow: 0 2px 24px rgba(0, 0, 0, 0.35);
  max-width: 16ch;
}

.home-slide-text {
  margin: 0 0 1.35rem;
  font-size: clamp(1rem, 2vw, 1.2rem);
  line-height: 1.55;
  max-width: 42rem;
  color: rgba(255, 255, 255, 0.92);
}

.home-slide-cta {
  align-self: flex-start;
  min-height: 44px;
}

.home-slideshow-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 5;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
  backdrop-filter: blur(6px);
  transition: background 0.15s ease, transform 0.15s ease;
}

.home-slideshow-nav:hover,
.home-slideshow-nav:focus-visible {
  background: rgba(247, 168, 27, 0.92);
  color: #0b1b33;
  outline: none;
  transform: translateY(-50%) scale(1.05);
}

.home-slideshow-prev { left: clamp(0.75rem, 2vw, 1.5rem); }
.home-slideshow-next { right: clamp(0.75rem, 2vw, 1.5rem); }

.home-slideshow-dots {
  position: absolute;
  left: 50%;
  bottom: 1.35rem;
  transform: translateX(-50%);
  z-index: 5;
  display: flex;
  gap: 0.55rem;
  align-items: center;
}

.home-slideshow-dot {
  width: 10px;
  height: 10px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.45);
  transition: width 0.2s ease, background 0.2s ease;
}

.home-slideshow-dot.is-active {
  width: 28px;
  background: var(--rotary-gold, #F7A81B);
}

@media (max-width: 767.98px) {
  .home-slideshow {
    min-height: clamp(420px, 78vh, 640px);
  }

  .home-slide-content {
    padding: 3.25rem 0 4.5rem;
  }

  .home-slideshow-nav {
    width: 42px;
    height: 42px;
  }

  .home-slideshow + .stats-strip {
    margin-top: -28px;
  }
}

.stats-card {
  background: #fff;
  border: 1px solid rgba(11, 27, 51, 0.06);
  border-radius: 18px;
  padding: 18px 14px;
}

.stats-card .icon,
.contact-side .icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(11, 77, 162, 0.08);
  color: var(--rotary-blue);
  font-size: 1.2rem;
  flex-shrink: 0;
}

.stats-card .num {
  font-size: 1.6rem;
  font-weight: 800;
  line-height: 1.1;
}

.stats-card .lbl {
  color: var(--muted);
  font-weight: 600;
  font-size: 0.95rem;
}

/* Section */
.section-title {
  font-weight: 800;
  letter-spacing: -0.01em;
}

.section-sub {
  color: var(--muted);
}

.block-title {
  margin-top: 2rem;
  margin-bottom: 0.75rem;
}

/* Project cards */
.project-card {
  border: 1px solid rgba(11, 27, 51, 0.06);
  border-radius: 18px;
  overflow: hidden;
  background: #fff;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.project-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 34px rgba(11, 27, 51, 0.1);
}

/*.project-card img,
.project-card .img-placeholder {
  height: 190px;
  width: 100%;
  object-fit: cover;
}*/

.project-card .img-placeholder {
  background: #e8eef6;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
}

.project-card .card-body {
  padding: 16px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.project-card .card-title {
  font-weight: 800;
}

.project-card .card-text {
  color: var(--muted);
}

/* Events listing hides the summary; date, place, and Register stay. */
.events-listing .project-card .card-text {
  display: none;
}

.project-card .btn {
  border-radius: 12px;
  font-weight: 700;
  padding: 0.65rem 1rem;
  margin-top: auto;
  align-self: flex-start;
}

/* Events panel */
.events-panel {
  background: #fff;
  border: 1px solid rgba(11, 27, 51, 0.06);
  border-radius: 18px;
  overflow: hidden;
}

.events-head {
  padding: 16px;
  border-bottom: 1px solid rgba(11, 27, 51, 0.06);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.events-head h5 {
  margin: 0;
  font-weight: 800;
}

.calendar {
  padding: 14px 16px;
  border-bottom: 1px solid rgba(11, 27, 51, 0.06);
  font-size: 0.95rem;
  color: var(--muted);
}

.event-item {
  padding: 14px 16px;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  border-bottom: 1px solid rgba(11, 27, 51, 0.06);
}

.event-item:last-child {
  border-bottom: none;
}

.date-badge {
  min-width: 46px;
  border-radius: 14px;
  background: rgba(247, 168, 27, 0.15);
  color: #7a4b00;
  text-align: center;
  padding: 8px 6px;
  font-weight: 800;
  line-height: 1.05;
}

.date-badge span {
  display: block;
  font-size: 0.78rem;
  font-weight: 700;
  opacity: 0.8;
}

.event-meta h6 {
  margin: 0;
  font-weight: 800;
}

.event-meta small {
  color: var(--muted);
  display: block;
  margin-top: 2px;
}

.event-actions {
  margin-left: auto;
}

.event-actions .btn {
  border-radius: 12px;
  font-weight: 700;
  padding: 0.55rem 0.9rem;
}

/* About + Join band */
.band {
  background: linear-gradient(120deg, #ffffff, rgba(11, 77, 162, 0.04));
  border: 1px solid rgba(11, 27, 51, 0.06);
  border-radius: 22px;
  overflow: hidden;
}

.band .content {
  padding: 22px;
}

.band h3 {
  font-weight: 900;
}

.band p {
  color: var(--muted);
}

.band .btn {
  border-radius: 14px;
  font-weight: 800;
  padding: 0.85rem 1.1rem;
}

.band img,
.band .band-img-placeholder {
  width: 100%;
  height: 100%;
  min-height: 280px;
  object-fit: cover;
}

.band .band-img-placeholder {
  background: #e8eef6;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
}

/* News */
.news-card {
  border: 1px solid rgba(11, 27, 51, 0.06);
  border-radius: 18px;
  background: #fff;
  overflow: hidden;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.news-card img,
.news-card .img-placeholder {
  height: 160px;
  width: 100%;
  object-fit: cover;
}

.news-card .img-placeholder {
  background: #e8eef6;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
}

.news-card .card-body {
  padding: 16px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.news-card .card-title {
  font-weight: 800;
}

.news-card .card-text {
  color: var(--muted);
}

/* Page hero (inner pages) */
.page-hero {
  background: #094189;
  color: #fff;
  padding: 15px 0;
}

.page-hero .eyebrow {
  color: var(--rotary-gold);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.85rem;
  margin-bottom: 0.5rem;
}

.page-hero h1 {
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 0;
}

/* Footer */
footer.site-footer {
  background: #0a2450;
  color: rgba(255, 255, 255, 0.86);
  border-top: 6px solid rgba(247, 168, 27, 0.7);
}

footer.site-footer a {
  color: rgba(255, 255, 255, 0.86);
}

footer.site-footer a:hover {
  color: #fff;
}

.footer-title {
  font-weight: 800;
  color: #fff;
}

/* Navbar dropdowns */
.navbar .dropdown-menu {
  min-width: 240px;
  padding: 0.5rem;
  margin-top: 0.35rem !important;
}

/* Show dropdowns on hover (desktop); click still works on mobile */
@media (min-width: 992px) {
  .navbar .nav-item.dropdown {
    position: relative;
  }

  .navbar .nav-item.dropdown:hover > .dropdown-menu,
  .navbar .nav-item.dropdown:focus-within > .dropdown-menu {
    display: block;
    margin-top: 0 !important;
  }

  /* Bridge gap so hover doesn't drop when moving to menu */
  .navbar .nav-item.dropdown::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    height: 14px;
  }

  /* Nested submenu (About ? Messages) opens on hover to the right */
  .navbar .dropdown-submenu {
    position: relative;
  }

  .navbar .dropdown-submenu > .dropdown-menu {
    top: 0;
    left: calc(100% - 4px);
    margin-top: 0 !important;
    display: none;
  }

  .navbar .dropdown-submenu:hover > .dropdown-menu,
  .navbar .dropdown-submenu:focus-within > .dropdown-menu {
    display: block;
  }

  .navbar .dropdown-submenu > .dropdown-item.dropdown-toggle::after {
    margin-left: 0.5rem;
    vertical-align: 0.15em;
  }
}

.navbar .dropdown-item {
  border-radius: 10px;
  font-weight: 600;
  padding: 0.55rem 0.85rem;
  color: var(--ink);
}

.navbar .dropdown-item:hover,
.navbar .dropdown-item:focus,
.navbar .dropdown-item.active {
  background: rgba(11, 77, 162, 0.08);
  color: var(--rotary-blue);
}

.navbar .dropdown-header {
  font-weight: 800;
  color: var(--muted);
  text-transform: uppercase;
  font-size: 0.7rem;
  letter-spacing: 0.06em;
}

.nav-underline .nav-link.dropdown-toggle.active {
  border-bottom: 3px solid var(--rotary-gold);
  padding-bottom: 0.65rem;
}

/* CMS pages */
.cms-hero {
  background:
    radial-gradient(900px 380px at 90% 10%, rgba(247, 168, 27, 0.28), transparent 55%),
    linear-gradient(120deg, var(--rotary-blue-2), var(--rotary-blue));
  color: #fff;
  border-bottom-left-radius: 28px;
  border-bottom-right-radius: 28px;
  padding: 1rem 0;
}

.cms-hero .eyebrow {
  color: var(--rotary-gold);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.85rem;
  margin-bottom: 0.5rem;
}

.cms-breadcrumb {
  --bs-breadcrumb-divider-color: rgba(255, 255, 255, 0.45);
}

.cms-breadcrumb .breadcrumb-item,
.cms-breadcrumb .breadcrumb-item a {
  color: rgba(255, 255, 255, 0.8);
  font-weight: 600;
  font-size: 0.9rem;
}

.cms-breadcrumb .breadcrumb-item.active {
  color: #fff;
}

.cms-panel {
  background: #fff;
  border: 1px solid rgba(11, 27, 51, 0.06);
  border-radius: 24px;
  padding: .5rem;
}

.cms-featured-img {
  width: 100%;
  max-height: 380px;
  object-fit: cover;
  border-radius: 16px;
}

.cms-body {
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--ink);
}

.cms-body h2,
.cms-body h3,
.cms-body h4 {
  font-weight: 800;
  margin-top: 1.5rem;
  margin-bottom: 0.75rem;
  color: var(--rotary-blue-2);
}

.cms-body p {
  margin-bottom: 1rem;
}

.cms-body ul,
.cms-body ol {
  padding-left: 1.25rem;
  margin-bottom: 1rem;
}

.cms-body a {
  color: var(--rotary-blue);
  font-weight: 600;
}

.cms-cta {
  border-top: 1px solid rgba(11, 27, 51, 0.08);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.cms-side {
  background: #fff;
  border: 1px solid rgba(11, 27, 51, 0.06);
  border-radius: 22px;
  padding: 1.25rem;
}

.cms-side-nav a {
  display: block;
  padding: 0.7rem 0.85rem;
  border-radius: 12px;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 0.25rem;
}

.cms-side-nav a:hover {
  background: rgba(11, 77, 162, 0.06);
  color: var(--rotary-blue);
}

.cms-side-nav a.active {
  background: linear-gradient(90deg, rgba(11, 77, 162, 0.12), rgba(247, 168, 27, 0.12));
  color: var(--rotary-blue);
  border-left: 3px solid var(--rotary-gold);
}

/* Detail pages */
.detail-hero {
  position: relative;
  min-height: 100px;
  display: flex;
  align-items: flex-end;
  color: #fff;
  overflow: hidden;
}

.detail-hero-media {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transform: scale(1.02);
  display: none;
}

.detail-hero-overlay {
  position: absolute;
  inset: 0;
  background:#094189;
}

.detail-hero-content {
  position: relative;
  z-index: 1;
  padding: 15px 0;
}

.detail-back {
  display: none;
  align-items: center;
  gap: 0.4rem;
  color: rgba(255, 255, 255, 0.9);
  font-weight: 700;
  margin-bottom: 1rem;
}

.detail-back:hover {
  color: #fff;
}

.detail-badge {
  background: var(--rotary-gold);
  color: #1a1a1a;
  font-weight: 700;
  border-radius: 999px;
  padding: 0.45rem 0.85rem;
  text-decoration: none;
  display: none;
}

.detail-badge-soft {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
}

.detail-badge-gold {
  background: rgba(247, 168, 27, 0.95);
  color: #1a1a1a;
}

.detail-title {    font-weight: 700;
  letter-spacing: 0;
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  line-height: 1.15;
  margin-bottom: 0.85rem;
}

@media (min-width: 768px) {
  .detail-title {
    max-width: 100%;
  }
}

.detail-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  color: rgba(255, 255, 255, 0.88);
  font-weight: 600;
}

.detail-meta-row i {
  margin-right: 0.35rem;
  opacity: 0.9;
}

.detail-panel {
  background: #fff;
  border: 1px solid rgba(11, 27, 51, 0.06);
  border-radius: 22px;
  padding: 1.5rem;
}

.detail-featured-img {
  width: 100%;
  max-height: 420px;
  object-fit: cover;
  border-radius: 16px;
}

/* Detail gallery slideshow (cover + gallery images) */
.gallery-slideshow {
  --gallery-radius: 18px;
  --gallery-accent: var(--rotary-blue, #0B4DA2);
  --gallery-gold: var(--rotary-gold, #F7A81B);
  position: relative;
}

.gallery-slideshow:focus-visible {
  outline: 3px solid rgba(11, 77, 162, 0.35);
  outline-offset: 4px;
  border-radius: var(--gallery-radius);
}

.gallery-slideshow-stage {
  position: relative;
  overflow: hidden;
  border-radius: var(--gallery-radius);
  aspect-ratio: 16 / 10;
  background:
    radial-gradient(520px 220px at 20% 10%, rgba(247, 168, 27, 0.18), transparent 55%),
    linear-gradient(145deg, #0b1b33, #0B4DA2);
  box-shadow: 0 16px 40px rgba(11, 27, 51, 0.12);
}

.gallery-slide {
  position: absolute;
  inset: 0;
  margin: 0;
  opacity: 0;
  visibility: hidden;
  transform: scale(1.04);
  transition:
    opacity 0.7s ease,
    transform 1.1s ease,
    visibility 0.7s;
  z-index: 1;
}

.gallery-slide.is-active {
  opacity: 1;
  visibility: visible;
  transform: scale(1);
  z-index: 2;
}

.gallery-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.gallery-slideshow-scrim {
  position: absolute;
  inset: auto 0 0;
  height: 42%;
  z-index: 3;
  pointer-events: none;
  background: linear-gradient(180deg, transparent 0%, rgba(8, 27, 51, 0.55) 100%);
}

.gallery-slide-caption {
  position: absolute;
  left: 1rem;
  right: 5.5rem;
  bottom: 1.15rem;
  z-index: 4;
  margin: 0;
  color: #fff;
  font-size: clamp(0.9rem, 2.2vw, 1.05rem);
  font-weight: 600;
  line-height: 1.35;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.35);
}

.gallery-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 5;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.92);
  color: var(--gallery-accent);
  box-shadow: 0 8px 22px rgba(11, 27, 51, 0.18);
  transition: transform 0.15s ease, background 0.15s ease, color 0.15s ease;
}

.gallery-nav:hover,
.gallery-nav:focus-visible {
  background: var(--gallery-accent);
  color: #fff;
  transform: translateY(-50%) scale(1.05);
  outline: none;
}

.gallery-nav-prev { left: 0.75rem; }
.gallery-nav-next { right: 0.75rem; }

.gallery-slideshow-meta {
  position: absolute;
  top: 0.85rem;
  right: 0.85rem;
  z-index: 5;
}

.gallery-counter {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0.2rem 0.7rem;
  border-radius: 999px;
  background: rgba(8, 27, 51, 0.55);
  color: #fff;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  backdrop-filter: blur(6px);
}

.gallery-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 3px;
  z-index: 5;
  background: rgba(255, 255, 255, 0.2);
}

.gallery-progress-bar {
  display: block;
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--gallery-gold), #fff);
}

.gallery-thumbs {
  display: none;
  gap: 0.55rem;
  margin-top: 0.75rem;
  overflow-x: auto;
  padding-bottom: 0.15rem;
  scroll-snap-type: x proximity;
  -webkit-overflow-scrolling: touch;
}

.gallery-thumbs::-webkit-scrollbar {
  height: 4px;
}

.gallery-thumbs::-webkit-scrollbar-thumb {
  background: rgba(11, 77, 162, 0.25);
  border-radius: 999px;
}

.gallery-thumb {
  flex: 0 0 auto;
  width: 72px;
  height: 54px;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 10px;
  overflow: hidden;
  background: #e8eef7;
  scroll-snap-align: start;
  opacity: 0.72;
  transition: opacity 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}

.gallery-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.gallery-thumb:hover,
.gallery-thumb:focus-visible {
  opacity: 1;
  outline: none;
  transform: translateY(-1px);
}

.gallery-thumb.is-active {
  opacity: 1;
  border-color: var(--gallery-accent);
  box-shadow: 0 0 0 2px rgba(247, 168, 27, 0.35);
}

@media (max-width: 767.98px) {
  .gallery-slideshow-stage {
    aspect-ratio: 4 / 3;
    border-radius: 14px;
  }

  .gallery-nav {
    width: 40px;
    height: 40px;
  }

  .gallery-nav-prev { left: 0.45rem; }
  .gallery-nav-next { right: 0.45rem; }

  .gallery-slide-caption {
    right: 1rem;
    bottom: 0.9rem;
    font-size: 0.88rem;
  }

  .gallery-thumb {
    width: 64px;
    height: 48px;
  }
}

.detail-lede {
  font-size: 1.2rem;
  color: var(--muted);
  font-style: italic;
  border-left: 4px solid var(--rotary-gold);
  padding-left: 1rem;
  margin-bottom: 1.5rem;
}

.detail-body {
  line-height: 1.5;
  font-size: 1rem;
  color: var(--ink);
}
.detail-body p {
  margin-bottom: .75rem;
}

.detail-side {
  background: #fff;
  border: 1px solid rgba(11, 27, 51, 0.06);
  border-radius: 22px;
  padding: 1.35rem;
}

.detail-side-item {
  display: flex;
  gap: 0.85rem;
  align-items: flex-start;
  margin-bottom: 1rem;
}

.detail-side-item .icon,
.contact-side .icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(11, 77, 162, 0.08);
  color: var(--rotary-blue);
  font-size: 1.15rem;
  flex-shrink: 0;
}

/* Contact page */
.contact-hero {
  background:
    radial-gradient(900px 400px at 85% 20%, rgba(247, 168, 27, 0.28), transparent 55%),
    linear-gradient(120deg, var(--rotary-blue-2), var(--rotary-blue));
  color: #fff;
  border-bottom-left-radius: 28px;
  border-bottom-right-radius: 28px;
  padding: 56px 0 48px;
}

.contact-hero .eyebrow {
  color: var(--rotary-gold);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.85rem;
  margin-bottom: 0.5rem;
}

.contact-stat {
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 16px;
  padding: 0.85rem 0.5rem;
}

.contact-stat .num {
  font-size: 1.4rem;
  font-weight: 800;
  line-height: 1.1;
}

.contact-stat .lbl {
  font-size: 0.8rem;
  opacity: 0.85;
  font-weight: 600;
}

.contact-form-card {
  position: relative;
  background: #fff;
  border: 1px solid rgba(11, 27, 51, 0.06);
  border-radius: 24px;
  padding: 1.75rem;
  overflow: hidden;
}

.contact-form-accent {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 5px;
  background: linear-gradient(90deg, var(--rotary-blue), var(--rotary-gold));
}

.contact-info-card {
  background: #fff;
  border: 1px solid rgba(11, 27, 51, 0.06);
  border-radius: 22px;
  padding: 1.5rem;
}

.contact-map {
  border-radius: 22px;
  border: 1px solid rgba(11, 27, 51, 0.06);
}

.contact-cta-card {
  background: linear-gradient(120deg, var(--rotary-blue-2), var(--rotary-blue));
  color: #fff;
  border-radius: 22px;
  padding: 1.35rem 1.5rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.contact-cta-card .text-secondary {
  color: rgba(255, 255, 255, 0.82) !important;
}

.captcha-box .captcha-question {
  min-width: 72px;
  height: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(11, 77, 162, 0.08);
  border: 1px dashed rgba(11, 77, 162, 0.35);
  border-radius: 14px;
  font-weight: 800;
  color: var(--rotary-blue);
  font-size: 1.15rem;
  flex-shrink: 0;
}

.filter-chips .btn {
  min-height: 40px;
}

/* President Message Board */
.pmb-board {
  background: #fff;
  border: 1px solid rgba(11, 27, 51, 0.06);
  border-radius: 28px;
  overflow: hidden;
}

.pmb-photo-wrap {
  position: relative;
  height: 100%;
  min-height: 320px;
  background: linear-gradient(160deg, var(--rotary-blue-2), var(--rotary-blue));
}

.pmb-photo {
  width: 100%;
  height: 100%;
  min-height: 320px;
  max-height: 460px;
  object-fit: cover;
  display: block;
}

.pmb-photo-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.55);
  font-size: 5rem;
}

.pmb-photo-meta {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 1.25rem 1.35rem;
  background: linear-gradient(180deg, transparent, rgba(8, 59, 125, 0.92));
  color: #fff;
}

.pmb-name {
  font-weight: 800;
  font-size: 1.25rem;
  letter-spacing: -0.01em;
}

.pmb-role {
  opacity: 0.9;
  font-weight: 600;
  font-size: 0.95rem;
  margin-top: 0.15rem;
}

.pmb-content {
  padding: 1.75rem 1.75rem 1.85rem;
}

.pmb-eyebrow {
  color: var(--rotary-gold);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.8rem;
  margin-bottom: 0.85rem;
}

.pmb-quote {
  position: relative;
  margin: 0 0 1.15rem;
  padding: 0.85rem 1rem 0.85rem 2.75rem;
  border-left: 4px solid var(--rotary-gold);
  background: rgba(247, 168, 27, 0.1);
  border-radius: 0 16px 16px 0;
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.45;
  color: var(--rotary-blue-2);
}

.pmb-quote-icon {
  position: absolute;
  left: 0.75rem;
  top: 0.7rem;
  color: var(--rotary-gold);
  font-size: 1.35rem;
}

.pmb-message {
  color: var(--ink);
  max-height: 315px;
  overflow: hidden;
  mask-image: linear-gradient(180deg, #000 70%, transparent);
  -webkit-mask-image: linear-gradient(180deg, #000 70%, transparent);
}

/* Fellowship slideshow: player 85% left, vertical thumbs 15% right */
.fellowship-show {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 85%) minmax(0, 15%);
  align-items: start;
  border-radius: 18px;
  overflow: hidden;
  background: #0b1b33;
  border: 1px solid rgba(11, 27, 51, 0.08);
  box-shadow: 0 12px 32px rgba(11, 27, 51, 0.08);
}

.fellowship-show.is-single {
  grid-template-columns: 100%;
}

.fellowship-show-player {
  position: relative;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  aspect-ratio: 16 / 9;
  min-height: 220px;
  overflow: hidden;
  background: #0b1b33;
}

.fellowship-show-slide {
  position: absolute;
  inset: 0;
  display: block;
  opacity: 0;
  transform: scale(1.035);
  transition: opacity 0.8s ease, transform 1.15s ease;
  pointer-events: none;
  z-index: 0;
  color: #fff;
  text-decoration: none;
}

.fellowship-show-slide.is-active {
  opacity: 1;
  transform: scale(1);
  pointer-events: auto;
  z-index: 1;
}

.fellowship-show-slide img,
.fellowship-show-slide .fellowship-show-fallback {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.fellowship-show-thumb img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
}

.fellowship-show-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(420px 180px at 20% 0%, rgba(247, 168, 27, 0.35), transparent 60%),
    linear-gradient(160deg, var(--rotary-blue), var(--rotary-blue-2));
  color: #fff;
  font-size: 2.5rem;
}

.fellowship-show-caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 3.25rem 1.25rem 1.15rem;
  background: linear-gradient(180deg, rgba(11, 27, 51, 0) 0%, rgba(11, 27, 51, 0.82) 70%);
  pointer-events: none;
}

.fellowship-show-date {
  display: block;
  margin-bottom: 0.25rem;
  color: var(--rotary-gold);
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.fellowship-show-title {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  font-size: clamp(1.15rem, 2.4vw, 1.85rem);
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.02em;
  text-shadow: 0 2px 16px rgba(0, 0, 0, 0.35);
}

.fellowship-show-thumbs {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  width: 15%;
  min-width: 0;
  padding: 6px;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  background: #0b1b33;
  scrollbar-width: thin;
  scrollbar-color: rgba(247, 168, 27, 0.7) transparent;
}

.fellowship-show-thumb {
  flex: 0 0 auto;
  width: 100%;
  height: auto;
  padding: 0;
  border: 0;
  border-radius: 8px;
  overflow: hidden;
  line-height: 0;
  background: #132744;
  cursor: pointer;
  opacity: 0.55;
  transition: opacity 0.35s ease, box-shadow 0.35s ease;
}

.fellowship-show-thumb .fellowship-show-fallback {
  width: 100%;
  aspect-ratio: 16 / 9;
}

.fellowship-show-thumb.is-active,
.fellowship-show-thumb:hover,
.fellowship-show-thumb:focus-visible {
  opacity: 1;
}

.fellowship-show-thumb.is-active {
  box-shadow: inset 0 0 0 2px var(--rotary-gold);
}

.fellowship-show-thumb:focus-visible {
  outline: 2px solid var(--rotary-gold);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  .fellowship-show-slide {
    transition: none;
    transform: none;
  }
}

@media (max-width: 575.98px) {
  .fellowship-show {
    grid-template-columns: 1fr;
  }

  .fellowship-show-player {
    aspect-ratio: 4 / 3;
  }

  .fellowship-show-thumbs {
    position: static;
    width: 100%;
    max-height: 240px;
    overflow-x: hidden;
    overflow-y: auto;
    padding: 8px;
  }

  .fellowship-show-thumb {
    width: 100%;
    height: auto;
  }

  .fellowship-show-caption {
    padding: 2.25rem 0.9rem 0.85rem;
  }
}

/* Homepage carousels — configurable cards per slide (projects/events: 4) */
.home-carousel {
  position: relative;
  padding: 0 2.5rem 2rem;
}

.home-carousel .project-card,
.home-carousel .news-card {
  width: 100%;
}

.home-carousel-control {
  width: auto;
  opacity: 1;
}

.home-carousel-control .home-carousel-btn {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: #fff;
  border: 1px solid rgba(11, 27, 51, 0.1);
  box-shadow: 0 8px 20px rgba(11, 27, 51, 0.1);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--rotary-blue);
  font-size: 1.1rem;
}

.home-carousel-control:hover .home-carousel-btn {
  background: var(--rotary-gold);
  color: #1a1a1a;
  border-color: transparent;
}

.home-carousel-indicators {
  margin-bottom: 0;
  bottom: 0;
}

.home-carousel-indicators [data-bs-target] {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background-color: var(--rotary-blue);
  opacity: 0.3;
  border: 0;
}

.home-carousel-indicators .active {
  opacity: 1;
  background-color: var(--rotary-gold);
}

/* Newsletter band */
.newsletter-band {
  background:
    radial-gradient(700px 280px at 15% 20%, rgba(247, 168, 27, 0.35), transparent 60%),
    linear-gradient(120deg, var(--rotary-blue-2), var(--rotary-blue));
  color: #fff;
  border-radius: 28px;
  padding: 2rem 1.75rem;
  overflow: hidden;
}

.newsletter-eyebrow {
  color: var(--rotary-gold);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.8rem;
}

.newsletter-title {
  font-weight: 800;
  letter-spacing: -0.02em;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
}

.newsletter-sub {
  color: rgba(255, 255, 255, 0.88);
  max-width: 36ch;
}

.newsletter-note {
  color: rgba(255, 255, 255, 0.75);
}

.newsletter-form .form-control {
  border: 0;
}

/* Public newsletter listing + Fancybox flipbook */
.newsletter-issue-card {
  cursor: pointer;
}

.newsletter-issue-card:focus-visible {
  outline: 3px solid rgba(11, 77, 162, 0.35);
  outline-offset: 3px;
  border-radius: 18px;
}

.newsletter-issue-card .project-card {
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.newsletter-issue-card:hover .project-card {
  transform: translateY(-3px);
  box-shadow: 0 14px 34px rgba(11, 27, 51, 0.12);
}

.newsletter-pdf-placeholder {
  background: linear-gradient(145deg, rgba(11, 77, 162, 0.12), rgba(247, 168, 27, 0.18));
  color: var(--rotary-blue);
}

.newsletter-flip-panel {
  display: none;
  width: min(1100px, 96vw);
  max-width: 96vw;
}

.newsletter-fancybox .fancybox__content .newsletter-flip-panel {
  display: block;
}

.newsletter-flip-shell {
  --nl-flip-chrome: 140px;
  width: min(1100px, 96vw);
  height: min(92vh, 920px);
  display: flex;
  flex-direction: column;
  background: #fff;
  border-radius: 18px;
  overflow: hidden;
}

.newsletter-flip-header {
  flex: 0 0 auto;
  padding: 0.9rem 1.15rem 0.55rem;
}

.newsletter-flip-body {
  flex: 1 1 auto;
  min-height: 0;
  height: calc(100% - var(--nl-flip-chrome));
  display: flex;
  flex-direction: column;
}

.newsletter-flip-loading {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.newsletter-flip-stage {
  flex: 1;
  min-height: 0;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.newsletter-flip-viewport {
  flex: 1;
  min-height: 0;
  height: calc(100% - 0px);
  display: flex;
  justify-content: center;
  align-items: center;
  background:
    radial-gradient(600px 280px at 50% 20%, rgba(247, 168, 27, 0.12), transparent 60%),
    #f3f6fb;
  padding: 0.5rem;
  overflow: hidden;
}

#newsletterFlipBook {
  margin: 0 auto;
  max-height: 100%;
}

.newsletter-flip-page {
  background: #fff;
  box-shadow: 0 2px 8px rgba(11, 27, 51, 0.12);
}

.newsletter-flip-footer {
  flex: 0 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: flex-end;
  align-items: center;
  padding: 0.75rem 1.15rem 1rem;
  border-top: 1px solid rgba(11, 27, 51, 0.08);
  background: #fff;
}

#newsletterFlipAutoplay.active {
  background: var(--rotary-blue-2, #083a7a);
}

.newsletter-fancybox .fancybox__content {
  padding: 0;
  background: transparent;
  box-shadow: none;
}

.newsletter-fancybox .fancybox__backdrop {
  background: rgba(11, 27, 51, 0.72);
}

/* Touch targets on mobile */
@media (max-width: 767.98px) {
  .navbar-nav .nav-link,
  .btn {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
  }

  .hero-inner {
    padding: 40px 0 32px;
  }

  .event-item {
    flex-wrap: wrap;
  }

  .event-actions {
    margin-left: 0;
    width: 100%;
  }

  .detail-hero {
    min-height: 280px;
  }

  .detail-panel,
  .contact-form-card {
    padding: 1.15rem;
  }

  .project-card .card-title,
  .news-card .card-title {
    font-size: 1rem;
  }

  .home-carousel {
    padding: 0 0 2.25rem;
  }

  .home-carousel-control .home-carousel-btn {
    width: 36px;
    height: 36px;
  }

  .newsletter-band {
    padding: 1.5rem 1.15rem;
  }

  .pmb-content {
    padding: 1.25rem;
  }

  .pmb-message {
    max-height: none;
    mask-image: none;
    -webkit-mask-image: none;
  }
}

/* Membership commitment form */
.membership-hero {
  background:
    radial-gradient(900px 420px at 10% 30%, rgba(247, 168, 27, 0.32), transparent 55%),
    radial-gradient(700px 360px at 90% 10%, rgba(255, 255, 255, 0.12), transparent 50%),
    linear-gradient(125deg, var(--rotary-blue-2), var(--rotary-blue));
  color: #fff;
  border-bottom-left-radius: 28px;
  border-bottom-right-radius: 28px;
  padding: 56px 0 48px;
}

.membership-hero .eyebrow {
  color: var(--rotary-gold);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.85rem;
  margin-bottom: 0.5rem;
}

.membership-tagline {
  color: var(--rotary-gold);
  font-weight: 700;
  font-size: 1.15rem;
  font-style: italic;
}

.membership-hero-card {
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 20px;
  padding: 1.25rem 1.35rem;
  backdrop-filter: blur(6px);
}

.membership-hero-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--rotary-gold);
  color: #1a1a1a;
  font-size: 1.35rem;
  flex-shrink: 0;
}

.membership-page {
  margin-top: -1.5rem;
  position: relative;
  z-index: 1;
}

.membership-steps {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.5rem;
  background: #fff;
  border-radius: 18px;
  padding: 0.65rem;
  border: 1px solid rgba(11, 27, 51, 0.06);
  box-shadow: 0 10px 30px rgba(11, 27, 51, 0.06);
}

.membership-step {
  border: 0;
  background: transparent;
  border-radius: 12px;
  padding: 0.55rem 0.4rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  color: var(--muted);
  font-weight: 600;
  font-size: 0.78rem;
  min-height: 44px;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.membership-step-num {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(11, 77, 162, 0.08);
  color: var(--rotary-blue);
  font-weight: 800;
  font-size: 0.85rem;
}

.membership-step.is-active {
  background: rgba(11, 77, 162, 0.08);
  color: var(--rotary-blue);
}

.membership-step.is-active .membership-step-num {
  background: var(--rotary-blue);
  color: #fff;
}

.membership-step.is-done .membership-step-num {
  background: var(--rotary-gold);
  color: #1a1a1a;
}

.membership-step:hover {
  transform: translateY(-1px);
  color: var(--rotary-blue);
}

.membership-card {
  position: relative;
  background: #fff;
  border: 1px solid rgba(11, 27, 51, 0.06);
  border-radius: 24px;
  padding: 1.75rem;
  overflow: hidden;
  animation: membershipFadeIn 0.35s ease;
}

.membership-card-accent {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 5px;
  background: linear-gradient(90deg, var(--rotary-blue), var(--rotary-gold));
}

.membership-card .form-control,
.membership-card .form-select,
.membership-card textarea.form-control {
  min-height: 48px;
  font-size: 1rem;
}

.membership-card textarea.form-control {
  min-height: 140px;
}

@keyframes membershipFadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.choice-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.65rem;
}

@media (min-width: 768px) {
  .choice-grid {
    grid-template-columns: 1fr 1fr;
  }

  .choice-grid-sm {
    grid-template-columns: repeat(3, 1fr);
  }
}

.choice-card {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin: 0;
  padding: 0.9rem 1rem;
  border-radius: 14px;
  border: 1.5px solid rgba(11, 27, 51, 0.1);
  background: var(--soft);
  cursor: pointer;
  transition: border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
  min-height: 48px;
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--ink);
}

.choice-card input {
  margin-top: 0.2rem;
  flex-shrink: 0;
  accent-color: var(--rotary-blue);
  width: 1.1rem;
  height: 1.1rem;
}

.choice-card:has(input:checked) {
  border-color: var(--rotary-blue);
  background: rgba(11, 77, 162, 0.07);
  box-shadow: 0 0 0 3px rgba(11, 77, 162, 0.12);
}

.choice-card:hover {
  border-color: rgba(11, 77, 162, 0.45);
}

.referral-card {
  position: relative;
  border: 1px solid rgba(11, 27, 51, 0.08);
  border-radius: 18px;
  padding: 1.15rem 1.15rem 1.15rem 3.25rem;
  background: linear-gradient(135deg, #fff, #f8fafc);
}

.referral-badge {
  position: absolute;
  left: 0.85rem;
  top: 1.15rem;
  width: 36px;
  height: 36px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--rotary-blue), var(--rotary-blue-2));
  color: #fff;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.membership-thanks {
  display: flex;
  gap: 0.85rem;
  align-items: flex-start;
  padding: 1rem 1.15rem;
  border-radius: 16px;
  background: rgba(247, 168, 27, 0.12);
  border: 1px solid rgba(247, 168, 27, 0.35);
}

.membership-thanks i {
  font-size: 1.5rem;
  color: var(--rotary-blue);
}

.membership-nav .btn {
  min-height: 48px;
}

@media (max-width: 767.98px) {
  .membership-steps {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 0.25rem;
    padding: 0.4rem;
  }

  .membership-step-label {
    font-size: 0.65rem;
    line-height: 1.15;
    text-align: center;
  }

  .membership-step-num {
    width: 24px;
    height: 24px;
    font-size: 0.75rem;
  }

  .membership-card {
    padding: 1.15rem;
  }

  .choice-grid-sm {
    grid-template-columns: 1fr;
  }

  .referral-card {
    padding-left: 1.15rem;
    padding-top: 3rem;
  }

  .referral-badge {
    top: 0.85rem;
    left: 0.85rem;
  }
}

/* ==========================================================================
   Mobile-only modernization (phones / small tablets < lg)
   Desktop layout stays untouched above 992px.
   ========================================================================== */

@media (max-width: 991.98px) {
  :root {
    --mobile-dock-h: 68px;
  }

  body.has-mobile-dock {
    padding-bottom: calc(var(--mobile-dock-h) + env(safe-area-inset-bottom, 0px));
  }

  /* Hide top bar on mobile */
  .topbar {
    display: none !important;
  }

  /* Slimmer sticky navbar */
  .site-navbar {
    backdrop-filter: blur(12px);
    background: rgba(255, 255, 255, 0.94) !important;
    box-shadow: 0 6px 20px rgba(11, 27, 51, 0.06);
  }

  .brand-logo {
    height: 52px;
  }

  .mobile-nav-toggle {
    width: 44px;
    height: 44px;
    border-radius: 14px !important;
    background: linear-gradient(145deg, rgba(11, 77, 162, 0.08), rgba(247, 168, 27, 0.14));
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    padding: 0;
  }

  .mobile-nav-toggle:focus {
    box-shadow: 0 0 0 3px rgba(11, 77, 162, 0.2);
  }

  .mobile-nav-toggle-bars {
    display: flex;
    flex-direction: column;
    gap: 5px;
    width: 18px;
  }

  .mobile-nav-toggle-bars span {
    display: block;
    height: 2px;
    width: 100%;
    border-radius: 2px;
    background: var(--rotary-blue);
    transition: transform 0.2s ease, opacity 0.2s ease;
  }

  .mobile-nav-toggle-bars span:nth-child(2) {
    width: 72%;
    margin-left: auto;
  }

  /* Hide Bootstrap collapse menu on mobile ? offcanvas is the nav */
  .site-navbar .navbar-collapse {
    display: none !important;
  }

  /* ---- Offcanvas drawer ---- */
  .mobile-offcanvas {
    width: min(100%, 360px);
    border: 0;
    background: #f7f9fc;
    display: flex;
    flex-direction: column;
  }

  .mobile-offcanvas-hero {
    background:
      radial-gradient(420px 220px at 100% 0%, rgba(247, 168, 27, 0.35), transparent 55%),
      linear-gradient(145deg, var(--rotary-blue-2), var(--rotary-blue));
    color: #fff;
    padding: 1.25rem 1.25rem 1.5rem;
  }

  .mobile-offcanvas-logo {
    height: 48px;
    width: auto;
    margin-bottom: 0.75rem;
    filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.2));
  }

  .mobile-offcanvas-tag {
    font-size: 0.95rem;
    font-weight: 700;
    line-height: 1.3;
    opacity: 0.95;
  }

  .mobile-offcanvas-close {
    width: 42px;
    height: 42px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.16);
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
  }

  .mobile-offcanvas-close:hover,
  .mobile-offcanvas-close:focus {
    background: rgba(255, 255, 255, 0.28);
    color: #fff;
  }

  .mobile-offcanvas-body {
    padding: 1rem 1rem 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
    overflow: hidden;
  }

  .mobile-menu {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    overflow-y: auto;
    flex: 1 1 auto;
    min-height: 0;
    padding-right: 0.15rem;
    -webkit-overflow-scrolling: touch;
  }

  .mobile-menu-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-height: 48px;
    padding: 0.65rem 0.85rem;
    border-radius: 16px;
    font-weight: 700;
    color: var(--ink);
    background: #fff;
    border: 1px solid rgba(11, 27, 51, 0.06);
    width: 100%;
    text-align: left;
    transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
  }

  .mobile-menu-link:hover,
  .mobile-menu-link:focus {
    color: var(--rotary-blue);
    border-color: rgba(11, 77, 162, 0.22);
    box-shadow: 0 8px 20px rgba(11, 27, 51, 0.06);
  }

  .mobile-menu-link.is-active {
    color: var(--rotary-blue);
    border-color: rgba(11, 77, 162, 0.28);
    background: linear-gradient(135deg, rgba(11, 77, 162, 0.08), rgba(247, 168, 27, 0.1));
    box-shadow: 0 0 0 3px rgba(11, 77, 162, 0.08);
  }

  .mobile-menu-icon {
    width: 36px;
    height: 36px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(11, 77, 162, 0.08);
    color: var(--rotary-blue);
    flex-shrink: 0;
  }

  .mobile-menu-link.is-active .mobile-menu-icon {
    background: var(--rotary-blue);
    color: #fff;
  }

  .mobile-menu-chevron {
    margin-left: auto;
    font-size: 0.85rem;
    opacity: 0.55;
    transition: transform 0.2s ease;
  }

  .mobile-menu-toggle[aria-expanded="true"] .mobile-menu-chevron {
    transform: rotate(180deg);
  }

  .mobile-submenu {
    display: grid;
    gap: 0.25rem;
    padding: 0.35rem 0.35rem 0.5rem 2.75rem;
  }

  .mobile-submenu-link {
    display: block;
    padding: 0.65rem 0.85rem;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.92rem;
    color: var(--muted);
    min-height: 44px;
  }

  .mobile-submenu-link.is-active,
  .mobile-submenu-link:hover {
    color: var(--rotary-blue);
    background: rgba(11, 77, 162, 0.07);
  }

  .mobile-submenu-toggle {
    width: 100%;
    border: 0;
    background: transparent;
    text-align: left;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
  }

  .mobile-submenu-level2 {
    padding-left: 0.85rem;
    padding-right: 0;
  }

  .mobile-offcanvas-cta {
    display: grid;
    gap: 0.65rem;
    flex-shrink: 0;
    padding-top: 0.35rem;
    border-top: 1px solid rgba(11, 27, 51, 0.06);
  }

  .mobile-offcanvas-social {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    padding-top: 0.25rem;
  }

  .mobile-offcanvas-social a {
    width: 44px;
    height: 44px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    color: var(--rotary-blue);
    border: 1px solid rgba(11, 27, 51, 0.08);
    font-size: 1.15rem;
  }

  /* ---- Bottom dock ---- */
  .mobile-dock {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1040;
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    align-items: end;
    gap: 2px;
    padding: 0.35rem 0.2rem calc(0.35rem + env(safe-area-inset-bottom, 0px));
    border-radius: 0;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(16px);
    border: 0;
    border-top: 1px solid rgba(11, 27, 51, 0.08);
    box-shadow: 0 -8px 28px rgba(11, 27, 51, 0.1);
  }

  .mobile-dock-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.15rem;
    min-height: 48px;
    padding: 0.2rem;
    border: 0;
    background: transparent;
    color: var(--muted);
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    border-radius: 14px;
    transition: color 0.15s ease, transform 0.15s ease;
  }

  .mobile-dock-item i {
    font-size: 1.2rem;
    line-height: 1;
  }

  .mobile-dock-item.is-active {
    color: var(--rotary-blue);
  }

  .mobile-dock-item.is-active i {
    transform: translateY(-1px);
  }

  .mobile-dock-fab {
    transform: translateY(-14px);
  }

  .mobile-dock-fab-ring {
    width: 52px;
    height: 52px;
    border-radius: 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(145deg, var(--rotary-gold), #ffc14d);
    color: #1a1a1a;
    box-shadow: 0 10px 24px rgba(247, 168, 27, 0.45);
    border: 3px solid #fff;
  }

  .mobile-dock-fab-ring i {
    font-size: 1.35rem;
    font-weight: 800;
  }

  .mobile-dock-fab span:last-child {
    margin-top: 0.1rem;
  }

  /* ---- Quick actions modal (bottom sheet) ---- */
  .mobile-actions-modal .modal-dialog-bottom {
    margin: 0;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    max-width: 100%;
  }

  .mobile-actions-modal.fade .modal-dialog-bottom {
    transform: translateY(110%);
  }

  .mobile-actions-modal.show .modal-dialog-bottom {
    transform: translateY(0);
  }

  .mobile-actions-modal .modal-content {
    border: 0;
    border-radius: 24px 24px 0 0;
    padding-bottom: calc(0.75rem + env(safe-area-inset-bottom, 0px));
    box-shadow: 0 -12px 40px rgba(11, 27, 51, 0.18);
  }

  .mobile-actions-modal .modal-handle {
    width: 42px;
    height: 4px;
    border-radius: 99px;
    background: rgba(11, 27, 51, 0.18);
    margin: 0.65rem auto 0;
  }

  .mobile-actions-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.65rem;
  }

  .mobile-action-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.45rem;
    padding: 0.75rem 0.35rem;
    border-radius: 18px;
    background: var(--soft);
    border: 1px solid rgba(11, 27, 51, 0.06);
    color: var(--ink);
    min-height: 88px;
    font-weight: 700;
    font-size: 0.72rem;
    text-align: center;
  }

  .mobile-action-card:hover,
  .mobile-action-card:focus {
    color: var(--rotary-blue);
    border-color: rgba(11, 77, 162, 0.2);
    background: #fff;
    box-shadow: 0 8px 18px rgba(11, 27, 51, 0.08);
  }

  .mobile-action-icon {
    width: 42px;
    height: 42px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(11, 77, 162, 0.1);
    color: var(--rotary-blue);
    font-size: 1.15rem;
  }

  .mobile-action-icon.is-gold {
    background: rgba(247, 168, 27, 0.2);
    color: #b36b00;
  }

  .mobile-action-icon.is-green {
    background: rgba(25, 135, 84, 0.14);
    color: #198754;
  }

  .mobile-action-icon.is-blue {
    background: rgba(13, 110, 253, 0.12);
    color: #0d6efd;
  }

  /* ---- Heroes & page shells ---- */
  .hero {
    border-bottom-left-radius: 22px;
    border-bottom-right-radius: 22px;
  }

  .hero::after {
    opacity: 0.28;
  }

  .hero-inner {
    padding: 36px 0 28px;
  }

  .hero h1,
  .hero .display-5,
  .membership-hero .display-5,
  .contact-hero .display-5,
  .cms-hero .display-5 {
    font-size: clamp(1.65rem, 7vw, 2.15rem);
    line-height: 1.12;
  }

  .hero .lead,
  .membership-hero .lead,
  .contact-hero .lead {
    font-size: 0.98rem;
    margin-bottom: 1.15rem !important;
  }

  .hero-cta {
    width: 100%;
  }

  .hero-cta .btn {
    flex: 1 1 auto;
    justify-content: center;
    min-width: min(100%, 150px);
    padding: 0.85rem 1rem;
    border-radius: 16px;
  }

  .stats-strip {
    margin-top: -1.25rem;
  }

  .stats-card {
    border-radius: 20px;
    padding: 1rem 0.75rem;
  }

  .stats-card .num {
    font-size: 1.25rem;
  }

  .stats-card .lbl {
    font-size: 0.72rem;
  }

  .stats-card .icon {
    width: 40px;
    height: 40px;
    font-size: 1.05rem;
  }

  .block-title,
  .section-title {
    font-size: 1.35rem;
  }

  .section-sub {
    font-size: 0.92rem;
  }

  main.py-5,
  .membership-page.py-5,
  .contact-page.py-5 {
    padding-top: 1.75rem !important;
    padding-bottom: 1.75rem !important;
  }

  .pmb-board,
  .band,
  .bg-white.border.rounded-4,
  .project-card,
  .news-card,
  .contact-form-card,
  .contact-info-card,
  .membership-card,
  .detail-panel {
    border-radius: 20px !important;
  }

  .pmb-photo-wrap {
    min-height: 240px;
  }

  .membership-hero,
  .contact-hero,
  .cms-hero,
  .detail-hero {
    border-bottom-left-radius: 22px;
    border-bottom-right-radius: 22px;
    padding-top: 2rem;
    padding-bottom: 1.75rem;
  }

  .membership-hero-card {
    padding: 1rem;
    border-radius: 18px;
  }

  .membership-progress {
    position: sticky;
    top: 56px;
    z-index: 20;
    background: rgba(245, 247, 251, 0.92);
    backdrop-filter: blur(10px);
    padding: 0.35rem 0;
    margin-left: -0.25rem;
    margin-right: -0.25rem;
  }

  .membership-nav {
    position: sticky;
    bottom: calc(var(--mobile-dock-h) + env(safe-area-inset-bottom, 0px) + 12px);
    z-index: 15;
    background: rgba(245, 247, 251, 0.94);
    backdrop-filter: blur(10px);
    padding: 0.65rem 0.15rem;
    margin-top: 1rem !important;
    border-radius: 16px;
  }

  .membership-nav .btn {
    flex: 1 1 auto;
    justify-content: center;
  }

  .choice-card {
    border-radius: 16px;
    padding: 0.95rem 1rem;
  }

  .form-control,
  .form-select {
    font-size: 16px; /* avoid iOS zoom */
  }

  .form-control-lg,
  .form-select-lg {
    padding: 0.8rem 1rem;
    border-radius: 16px !important;
  }

  /* Footer accordion */
  .footer-accordion {
    --bs-accordion-bg: transparent;
    --bs-accordion-border-color: rgba(255, 255, 255, 0.14);
    --bs-accordion-btn-color: #fff;
    --bs-accordion-btn-bg: rgba(255, 255, 255, 0.06);
    --bs-accordion-active-color: #fff;
    --bs-accordion-active-bg: rgba(247, 168, 27, 0.18);
    --bs-accordion-btn-focus-box-shadow: none;
  }

  .footer-acc-item {
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 14px !important;
    overflow: hidden;
    margin-bottom: 0.5rem;
    background: rgba(255, 255, 255, 0.04);
  }

  .footer-acc-btn {
    font-weight: 800;
    font-size: 0.95rem;
    box-shadow: none !important;
    min-height: 48px;
  }

  .footer-acc-btn:not(.collapsed) {
    background: rgba(247, 168, 27, 0.18);
    color: #fff;
  }

  .footer-acc-body {
    display: grid;
    gap: 0.55rem;
    padding-top: 0.35rem;
  }

  .footer-acc-body a {
    min-height: 40px;
    display: flex;
    align-items: center;
  }

  /* Copyright-only footer on mobile */
  footer.site-footer {
    padding-top: 1rem !important;
    padding-bottom: 1rem !important;
    border-top-width: 3px;
  }

  footer.site-footer .footer-bottom {
    text-align: center;
  }

  footer.site-footer .footer-bottom small {
    font-size: 0.72rem;
    line-height: 1.35;
  }

  /* Page hero ? title only, tight, square corners */
  .page-hero {
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
    padding: 8px 0 4px;
  }

  .page-hero .eyebrow,
  .page-hero .page-hero-desc,
  .page-hero p {
    display: none !important;
  }

  .page-hero h1,
  .page-hero .display-5 {
    font-size: 1.35rem;
    line-height: 1.2;
    margin: 0;
  }

  /* Filter chips ? horizontal scroll; keep active in view */
  .filter-chips {
    flex-wrap: nowrap !important;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x proximity;
    gap: 0.5rem !important;
    padding-bottom: 0.15rem;
    margin-left: -0.25rem;
    margin-right: -0.25rem;
    padding-left: 0.25rem;
    padding-right: 0.25rem;
    scrollbar-width: none;
  }

  .filter-chips::-webkit-scrollbar {
    display: none;
  }

  .filter-chips .btn {
    flex: 0 0 auto;
    white-space: nowrap;
    scroll-snap-align: center;
    min-height: 40px;
  }

  /* Listing cards ? card-body keeps only clickable title on mobile */
  .listing-grid .project-card .card-body {
    padding: 0.75rem 0.85rem 0.9rem;
  }

  .listing-grid .project-card .card-body > :not(.card-title) {
    display: none !important;
  }

  .listing-grid .project-card .card-title {
    font-size: 0.92rem;
    margin: 0;
    line-height: 1.3;
  }

  .listing-grid .project-card .card-title a {
    color: inherit;
  }

  /* Listing / detail polish */
  .event-item,
  .newsletter-band {
    border-radius: 16px;
  }

  .detail-hero {
    min-height: 240px;
  }

  .contact-hero-stats .contact-stat {
    padding: 0.65rem 0.35rem;
    border-radius: 14px;
  }

  /* Smooth reveal for offcanvas backdrop feel */
  .offcanvas-backdrop.show {
    opacity: 0.55;
  }
}

/* Extra-tight phone tweaks */
@media (max-width: 575.98px) {
  .container {
    padding-left: 1rem;
    padding-right: 1rem;
  }

  .mobile-actions-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .hero-cta {
    flex-direction: column;
  }

  .hero-cta .btn {
    width: 100%;
  }

  .membership-step-label {
    display: none;
  }

  .membership-steps {
    gap: 0.35rem;
  }

  .membership-step {
    justify-content: center;
  }
}

article.project-card img {
  width: 100%;
}
.filter-chips {display: none!important;}
/* Custom YouTube player - fellowship detail (branded chrome, no YT end-screen) */
.yt-player-section .block-title {
  margin-top: 0.25rem;
  margin-bottom: 0.5rem;
}

.ytc {
  display: grid;
  gap: 1rem;
  align-items: stretch;
}

.ytc:has(.ytc-rail) {
  grid-template-columns: minmax(0, 1fr) minmax(220px, 280px);
}

.ytc-shell {
  border-radius: 16px;
  overflow: hidden;
  background: #07111f;
  box-shadow: 0 16px 40px rgba(11, 27, 51, 0.18);
  min-width: 0;
}

.ytc-viewport {
  position: relative;
  background: #07111f;
  --ytc-chrome-h: 64px;
}

.ytc-api,
.ytc-api iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  /* Block native YouTube UI clicks; we drive playback via the API */
  pointer-events: none;
}

.ytc-poster {
  position: absolute;
  inset: 0;
  z-index: 6;
  border: 0;
  padding: 0;
  cursor: pointer;
  background: #07111f;
}

.ytc-poster-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transform: scale(1.02);
}

.ytc-poster-scrim {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(7, 17, 31, 0.15) 0%, rgba(7, 17, 31, 0.55) 100%);
}

.ytc-big-play {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: clamp(64px, 12vw, 84px);
  height: clamp(64px, 12vw, 84px);
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: clamp(1.6rem, 4vw, 2.1rem);
  background: linear-gradient(145deg, var(--rotary-blue, #0b4da2), #083a7a);
  border: 3px solid rgba(247, 168, 27, 0.95);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.35);
  transition: transform 0.18s ease;
}

.ytc-poster:hover .ytc-big-play,
.ytc-poster:focus-visible .ytc-big-play {
  transform: translate(-50%, -50%) scale(1.06);
}

.ytc-ended {
  position: absolute;
  inset: 0;
  z-index: 7;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  background:
    radial-gradient(circle at center, rgba(7, 17, 31, 0.55), rgba(7, 17, 31, 0.88));
  /* Fully covers YouTube more-videos / branding end-screen */
}

.ytc-ended.d-none {
  display: none !important;
}

.ytc-ended-card {
  width: min(420px, 100%);
  text-align: center;
  color: #fff;
}

.ytc-ended-label {
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(247, 168, 27, 0.95);
  margin-bottom: 0.35rem;
}

.ytc-ended-title {
  font-size: clamp(1.05rem, 2.4vw, 1.35rem);
  font-weight: 700;
  margin-bottom: 1rem;
}

.ytc-ended-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  justify-content: center;
}

.ytc-chrome {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 4;
  padding: 0.55rem 0.75rem 0.7rem;
  background: linear-gradient(180deg, transparent, rgba(7, 17, 31, 0.92));
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.2s ease, transform 0.2s ease;
  pointer-events: none;
}

/* Keep chrome inert until playback starts so it never blocks the poster */
.ytc:not(.is-playing) .ytc-chrome {
  opacity: 0 !important;
  pointer-events: none !important;
}

.ytc.is-playing .ytc-viewport:hover .ytc-chrome,
.ytc.is-playing .ytc-viewport:focus-within .ytc-chrome,
.ytc.is-playing .ytc-chrome.is-visible,
.ytc.is-playing .ytc-chrome:focus-within {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.ytc-progress {
  position: relative;
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.22);
  margin-bottom: 0.55rem;
  overflow: hidden;
}

.ytc-progress-bar {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 0%;
  background: linear-gradient(90deg, var(--rotary-gold, #f7a81b), #ffd27a);
}

.ytc-progress-input {
  position: absolute;
  inset: -8px 0;
  width: 100%;
  opacity: 0;
  cursor: pointer;
  margin: 0;
}

.ytc-controls {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  color: #fff;
  min-height: 44px;
}

.ytc-btn {
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}

.ytc-btn:hover,
.ytc-btn:focus-visible {
  background: rgba(255, 255, 255, 0.2);
}

.ytc-time {
  font-size: 0.8rem;
  font-variant-numeric: tabular-nums;
  opacity: 0.9;
  white-space: nowrap;
}

.ytc-time-sep {
  opacity: 0.55;
  margin: 0 0.15rem;
}

.ytc-now {
  flex: 1 1 auto;
  min-width: 0;
  font-size: 0.88rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  padding: 0 0.35rem;
}

.ytc-rail {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  min-height: 0;
  height: 100%;
  overflow-x: hidden;
  overflow-y: auto;
  padding-right: 0.2rem;
}

.ytc-rail-item {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  text-align: left;
  border: 1px solid rgba(11, 27, 51, 0.1);
  background: #fff;
  border-radius: 12px;
  padding: 0.45rem;
  min-height: 44px;
  width: 100%;
  flex: 0 0 auto;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.ytc-rail-item:hover,
.ytc-rail-item:focus-visible {
  border-color: rgba(11, 77, 162, 0.35);
  box-shadow: 0 8px 18px rgba(11, 27, 51, 0.08);
}

.ytc-rail-item.is-active {
  border-color: var(--rotary-blue, #0b4da2);
  background: rgba(11, 77, 162, 0.06);
}

.ytc-rail-thumb {
  position: relative;
  flex: 0 0 92px;
  width: 92px;
  height: 54px;
  border-radius: 8px;
  overflow: hidden;
  background: #0b1b33;
}

.ytc-rail-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.ytc-rail-num {
  position: absolute;
  left: 6px;
  bottom: 5px;
  min-width: 20px;
  height: 20px;
  padding: 0 5px;
  border-radius: 999px;
  background: rgba(7, 17, 31, 0.78);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.ytc-rail-meta {
  min-width: 0;
}

.ytc-rail-title {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  font-size: 0.9rem;
  font-weight: 650;
  color: var(--rotary-navy, #0b1b33);
  line-height: 1.25;
}

.ytc-viewport:fullscreen,
.ytc-viewport:-webkit-full-screen {
  width: 100%;
  height: 100%;
  border-radius: 0;
}

.ytc-viewport:fullscreen .ytc-chrome,
.ytc-viewport:-webkit-full-screen .ytc-chrome {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}

@media (max-width: 991.98px) {
  .ytc:has(.ytc-rail) {
    grid-template-columns: 1fr;
  }

  .ytc-rail {
    flex-direction: row;
    height: auto;
    max-height: none;
    overflow-x: auto;
    overflow-y: hidden;
    padding-bottom: 0.2rem;
  }

  .ytc-rail-item {
    flex: 0 0 min(260px, 78vw);
    width: auto;
  }
}

@media (max-width: 575.98px) {
  .ytc-now {
    display: none;
  }

  .ytc.is-playing .ytc-chrome {
    opacity: 1;
    transform: none;
    pointer-events: auto;
  }
}

/* Public content submission page */
.submission-intro-card {
  background: #fff;
  border: 1px solid rgba(11, 27, 51, 0.06);
  border-radius: 18px;
  padding: 1.15rem 1.1rem;
  box-shadow: 0 10px 28px rgba(11, 27, 51, 0.05);
}

.submission-intro-card .icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(11, 77, 162, 0.1);
  color: var(--rotary-blue);
  font-size: 1.2rem;
  margin-bottom: 0.65rem;
}

.submission-type-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

/* Match submission-intro-card look; keep selectable active state */
.submission-type-option {
  display: block;
  height: 100%;
  margin: 0;
  padding: 1.15rem 1.1rem;
  background: #fff;
  border: 1px solid rgba(11, 27, 51, 0.3);
  border-radius: 18px;
  box-shadow: 0 10px 28px rgba(11, 27, 51, 0.05);
  cursor: pointer;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.submission-type-option .icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(11, 77, 162, 0.1);
  color: var(--rotary-blue);
  font-size: 1.2rem;
  margin-bottom: 0.65rem;
}

.submission-type-option .label {
  display: block;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 0.25rem;
  color: inherit;
}

.submission-type-option .hint {
  display: block;
  font-size: 0.875rem;
  color: var(--bs-secondary-color, #6c757d);
  line-height: 1.4;
  margin: 0;
}

.submission-type-option:hover {
  border-color: rgba(11, 77, 162, 0.28);
  box-shadow: 0 12px 30px rgba(11, 77, 162, 0.08);
}

.submission-type-option.is-active {
  border-color: var(--rotary-blue);
  background: rgba(11, 77, 162, 0.04);
  box-shadow: 0 12px 30px rgba(11, 77, 162, 0.1);
}

.submission-type-option.is-active .icon {
  background: var(--rotary-blue);
  color: #fff;
}

.submission-thanks-icon {
  font-size: 3rem;
  color: #198754;
  line-height: 1;
}

.submission-ai-panel.is-busy,
.submission-form-with-ai.is-ai-generating {
  /* overlay handles interaction lock */
}

.submission-form-with-ai {
  position: relative;
}

.ai-generating-overlay {
  position: absolute;
  inset: 0;
  z-index: 1050;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(3px);
}

.ai-generating-overlay.d-none {
  display: none !important;
}

.ai-generating-overlay__panel {
  max-width: 22rem;
  padding: 1.5rem 1.75rem;
  border-radius: 0.75rem;
  border: 1px solid rgba(11, 27, 51, 0.1);
  background: #fff;
  box-shadow: 0 0.5rem 1.5rem rgba(0, 0, 0, 0.12);
}

.submission-form-with-ai.is-ai-generating {
  pointer-events: none;
}

.submission-form-with-ai.is-ai-generating .ai-generating-overlay {
  pointer-events: auto;
}

.ai-iterations-list .ai-iteration-item {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  border: 1px solid rgba(11, 27, 51, 0.1);
  border-radius: 0.5rem;
  padding: 0.5rem 0.5rem 0.5rem 0.65rem;
  margin-bottom: 0.5rem;
  background: #fff;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.ai-iterations-list .ai-iteration-item:hover {
  border-color: var(--rotary-blue, #0b4da2);
}

.ai-iterations-list .ai-iteration-item.is-active {
  border-color: var(--rotary-blue, #0b4da2);
  box-shadow: 0 0 0 0.15rem rgba(11, 77, 162, 0.2);
  background: rgba(11, 77, 162, 0.04);
}

.ai-iterations-list .ai-iteration-item.is-loading {
  opacity: 0.65;
  pointer-events: none;
}

.ai-iterations-list .ai-iteration-select-btn {
  flex: 1;
  border: 0;
  background: transparent;
  padding: 0.15rem 0;
  text-align: left;
  cursor: pointer;
}

.ai-iterations-list .ai-iteration-delete-btn {
  flex-shrink: 0;
  min-width: 44px;
  min-height: 44px;
  padding: 0.2rem 0.45rem;
}

#ai-voice-btn.active {
  background: #dc3545;
  color: #fff;
  border-color: #dc3545;
}

@media (max-width: 767.98px) {
  .submission-type-grid {
    grid-template-columns: 1fr;
  }
}

/* Post Event landing (QR scan) */
.post-event-hero .detail-back,
.post-event-hero .detail-badge {
  display: inline-flex;
}

.post-event-page .section-title {
  margin-top: 0;
  margin-bottom: 0.75rem;
}

.post-event-form-card {
  position: relative;
  background: #fff;
  border: 1px solid rgba(11, 27, 51, 0.06);
  border-radius: 22px;
  padding: 1.35rem 1.35rem 1.5rem;
  overflow: hidden;
}

.post-event-form-card.sticky-lg-top {
  top: 96px;
}

.post-event-form-card .form-control,
.post-event-form-card .btn {
  min-height: 44px;
}

.post-event-form-card .btn-rotary {
  font-weight: 700;
}

@media (max-width: 991.98px) {
  .post-event-form-card.sticky-lg-top {
    top: 0;
  }
}

/* Members directory */
.members-hero {
  background:
    radial-gradient(900px 420px at 85% 0%, rgba(247, 168, 27, 0.18), transparent 60%),
    linear-gradient(135deg, var(--rotary-blue-2), var(--rotary-blue));
  color: #fff;
  padding: 3rem 0 2.5rem;
  border-bottom-left-radius: 28px;
  border-bottom-right-radius: 28px;
}

.members-hero .eyebrow {
  color: var(--rotary-gold);
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 0.78rem;
}

.members-hero .btn-rotary {
  min-height: 44px;
}

button.member-card {
  display: flex;
  flex-direction: column;
  padding: 0;
  color: inherit;
  font: inherit;
  text-align: center;
  cursor: pointer;
  appearance: none;
}

button.member-card:focus-visible {
  outline: 3px solid var(--rotary-gold);
  outline-offset: 3px;
}

.member-card {
  background: #fff;
  border: 1px solid rgba(11, 27, 51, 0.06);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(11, 27, 51, 0.06);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.member-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 36px rgba(11, 27, 51, 0.12);
}

.member-card-photo-wrap {
  position: relative;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  background: linear-gradient(160deg, rgba(11, 77, 162, 0.08), rgba(247, 168, 27, 0.12));
}

.member-card-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.member-card-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(145deg, var(--rotary-blue), var(--rotary-blue-2));
  color: #fff;
  font-size: clamp(2.5rem, 8vw, 3.5rem);
  font-weight: 800;
}

.member-card-accent {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--rotary-gold), var(--rotary-blue));
}

.member-card-body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 1rem 1rem 1.15rem;
  text-align: center;
}

.member-card-name {
  font-size: clamp(0.95rem, 2.5vw, 1.05rem);
  font-weight: 800;
  color: var(--ink);
  margin-bottom: 0.25rem;
  line-height: 1.3;
}

.member-card-position {
  color: var(--rotary-blue);
  font-weight: 700;
  font-size: 0.82rem;
  margin-bottom: 0.35rem;
}

.member-card-bio {
  color: var(--muted);
  font-size: 0.82rem;
  margin-bottom: 0.35rem;
  line-height: 1.45;
}

.member-card-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.1rem;
  margin-top: auto;
  padding-top: 0.35rem;
  color: var(--rotary-blue);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.member-profile-modal {
  --bs-modal-zindex: 1060;
}

.member-profile-modal .modal-dialog {
  max-height: calc(100dvh - 2rem);
}

.member-profile-content {
  display: flex;
  flex-direction: column;
  max-height: calc(100dvh - 2rem);
  border-radius: 22px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 24px 60px rgba(11, 27, 51, 0.22);
}

.member-profile-layout {
  min-height: 0;
  flex: 1 1 auto;
}

.member-profile-close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  z-index: 2;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background-color: #fff;
  box-shadow: 0 6px 18px rgba(11, 27, 51, 0.16);
  opacity: 1;
}

.member-profile-media {
  min-height: 280px;
  background:
    radial-gradient(420px 220px at 20% 0%, rgba(247, 168, 27, 0.35), transparent 60%),
    linear-gradient(160deg, var(--rotary-blue), var(--rotary-blue-2));
}

.member-profile-photo,
.member-profile-placeholder {
  width: 100%;
  height: 100%;
  min-height: 280px;
  object-fit: cover;
}

.member-profile-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: clamp(3rem, 8vw, 4.5rem);
  font-weight: 800;
}

.member-profile-copy {
  max-height: calc(100dvh - 2rem);
  padding: 1.5rem 1.5rem 1.5rem 1.5rem;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  background: #fff;
  scrollbar-width: thin;
  scrollbar-color: var(--rotary-gold) transparent;
}

.member-profile-eyebrow {
  margin: 0 0 0.45rem;
  color: var(--rotary-gold);
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.member-profile-name {
  margin: 0 0 0.35rem;
  font-size: clamp(1.45rem, 3vw, 1.85rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.2;
  color: var(--ink);
}

.member-profile-position {
  display: inline-flex;
  align-items: center;
  margin: 0;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  background: rgba(11, 77, 162, 0.08);
  color: var(--rotary-blue);
  font-weight: 700;
  font-size: 0.92rem;
}

.member-profile-rule {
  width: 72px;
  height: 3px;
  margin: 1rem 0 0.9rem;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--rotary-gold), var(--rotary-blue));
}

.member-profile-bio {
  color: var(--ink);
  font-size: 1rem;
  line-height: 1.65;
  margin: 0;
}

.member-profile-bio-empty {
  color: var(--muted);
}

@media (min-width: 768px) {
  .member-profile-media {
    position: relative;
  }

  .member-profile-photo,
  .member-profile-placeholder {
    position: absolute;
    inset: 0;
    height: 100%;
  }
}

@media (max-width: 991.98px) {
  .member-profile-modal .modal-dialog {
    max-height: calc(100dvh - 6.5rem);
    margin-bottom: 5.75rem;
  }

  .member-profile-content,
  .member-profile-copy {
    max-height: calc(100dvh - 6.5rem);
  }
}

@media (max-width: 767.98px) {
  .member-profile-media,
  .member-profile-photo,
  .member-profile-placeholder {
    min-height: 220px;
    max-height: 280px;
  }

  .member-profile-photo {
    max-height: 280px;
  }

  .member-profile-copy {
    max-height: calc(100dvh - 280px - 7.5rem);
    padding: 1.25rem 1.1rem 1.35rem;
  }
}

.members-empty-icon {
  width: 72px;
  height: 72px;
  margin-inline: auto;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(11, 77, 162, 0.08);
  color: var(--rotary-blue);
  font-size: 2rem;
}

.members-cta-band {
  background: #fff;
}

.members-cta-panel {
  background: linear-gradient(135deg, rgba(11, 77, 162, 0.04), rgba(247, 168, 27, 0.08));
  border: 1px solid rgba(11, 27, 51, 0.06);
  border-radius: 22px;
  padding: 1.5rem 1.75rem;
}

.members-cta-panel .btn {
  min-height: 44px;
}

@media (max-width: 575.98px) {
  .members-hero {
    padding: 2rem 0 1.75rem;
  }

  .member-card-body {
    padding: 0.85rem 0.75rem 1rem;
  }
}


