   :root {
      --bg: #07111f;
      --bg-deep: #030812;
      --panel: rgba(13, 28, 48, 0.82);
      --panel-soft: rgba(20, 42, 70, 0.72);
      --text: #eef7ff;
      --muted: #b8c7d9;
      --frost: #93d8ff;
      --frost-soft: #d6f2ff;
      --gold: #e6c06a;
      --line: rgba(214, 242, 255, 0.18);
      --shadow: rgba(0, 0, 0, 0.45);
    }

    * {
      box-sizing: border-box;
      margin: 0;
      padding: 0;
    }

    html {
      scroll-behavior: smooth;
    }

    body {
      font-family: "Inter", "Segoe UI", Arial, sans-serif;
      color: var(--text);
      background:
        radial-gradient(circle at top left, rgba(147, 216, 255, 0.16), transparent 32rem),
        radial-gradient(circle at top right, rgba(230, 192, 106, 0.10), transparent 28rem),
        linear-gradient(180deg, var(--bg), var(--bg-deep));
      min-height: 100vh;
      line-height: 1.7;
    }

    body::before {
      content: "";
      position: fixed;
      inset: 0;
      pointer-events: none;
      background-image:
        linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px);
      background-size: 44px 44px;
      mask-image: linear-gradient(to bottom, rgba(0,0,0,0.6), transparent 80%);
      z-index: 0;
    }

    a {
      color: inherit;
      text-decoration: none;
    }

    .page {
      position: relative;
      z-index: 1;
    }

    .nav {
      position: sticky;
      top: 0;
      z-index: 10;
      display: flex;
      justify-content: center;
      gap: 0.75rem;
      padding: 0.85rem 1rem;
      background: rgba(3, 8, 18, 0.78);
      backdrop-filter: blur(16px);
      border-bottom: 1px solid var(--line);
    }

    .nav a {
      color: var(--muted);
      font-size: 0.9rem;
      letter-spacing: 0.04em;
      text-transform: uppercase;
      padding: 0.35rem 0.6rem;
      border-radius: 999px;
      transition: 180ms ease;
    }

    .nav a:hover {
      color: var(--text);
      background: rgba(147, 216, 255, 0.11);
    }

    .hero {
      min-height: 92vh;
      display: grid;
      place-items: center;
      padding: 5rem 1.25rem;
      text-align: center;
      background:
        linear-gradient(rgba(3, 8, 18, 0.30), rgba(3, 8, 18, 0.80)),
        url("Images/Yard.png") center/cover;
      border-bottom: 1px solid var(--line);
    }

    .hero-card {
      width: min(920px, 100%);
      padding: clamp(2rem, 5vw, 4.5rem);
      border: 1px solid rgba(214, 242, 255, 0.26);
      border-radius: 2rem;
      background: rgba(3, 8, 18, 0.62);
      box-shadow: 0 28px 80px var(--shadow);
      backdrop-filter: blur(10px);
    }

    .hero-logo {
      display: block;
      width: min(320px, 72vw);
      height: auto;
      margin: 0 auto 1.25rem;
      border-radius: 1.25rem;
      filter: drop-shadow(0 0 22px rgba(147, 216, 255, 0.32));
    }

    .eyebrow {
      color: var(--gold);
      text-transform: uppercase;
      letter-spacing: 0.22em;
      font-size: 0.82rem;
      margin-bottom: 1rem;
    }

    h1, h2, h3 {
      font-family: Georgia, "Times New Roman", serif;
      font-weight: 500;
      line-height: 1.12;
      padding-bottom: 20px;
    }

    h1 {
      font-size: clamp(3rem, 9vw, 6.8rem);
      letter-spacing: 0.02em;
      text-shadow: 0 0 32px rgba(147, 216, 255, 0.28);
    }

    .hero-card h1 {
      margin-bottom: 1rem;
    }

    .subtitle {
      color: var(--frost-soft);
      font-size: clamp(1.05rem, 2vw, 1.35rem);
      margin: 1rem auto 0;
      max-width: 760px;
    }

    .tagline {
      color: var(--muted);
      font-size: 1.05rem;
      margin: 0.8rem auto 2rem;
      max-width: 680px;
    }

    .buttons {
      display: flex;
      justify-content: center;
      flex-wrap: wrap;
      gap: 0.85rem;
      margin-top: 1.5rem;
    }

    .btn {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      min-height: 44px;
      padding: 0.75rem 1.1rem;
      border-radius: 999px;
      border: 1px solid rgba(214, 242, 255, 0.24);
      color: var(--text);
      background: rgba(147, 216, 255, 0.10);
      box-shadow: 0 10px 28px rgba(0,0,0,0.25);
      transition: transform 180ms ease, background 180ms ease, border 180ms ease;
    }

    .btn:hover {
      transform: translateY(-2px);
      background: rgba(147, 216, 255, 0.18);
      border-color: rgba(214, 242, 255, 0.45);
    }

    .btn.primary {
      color: #0a1220;
      background: linear-gradient(135deg, var(--gold), #fff0b6);
      border-color: rgba(255, 240, 182, 0.7);
      font-weight: 700;
    }

    .address {
      margin-top: 2rem;
      color: var(--frost-soft);
      font-size: 0.95rem;
    }

    section {
      padding: clamp(2.2rem, 5vw, 3.5rem) 1.25rem;
    }

    .container {
      width: min(1120px, 100%);
      margin: 0 auto;
    }

    .section-heading {
      text-align: center;
      margin-bottom: 2.5rem;
    }

    .section-heading .eyebrow {
      margin-bottom: 0.6rem;
    }

    .officers-subheading {
      margin: 0 auto 0.8rem;
      max-width: 640px;
    }

    .officers-subheading .eyebrow {
      margin-bottom: 0.4rem;
    }

    h2 {
      font-size: clamp(2rem, 5vw, 3.5rem);
    }

    .lead {
      color: var(--muted);
      max-width: 820px;
      margin: 1rem auto 0;
      font-size: 1.05rem;
    }

    .panel {
      background: var(--panel);
      border: 1px solid var(--line);
      border-radius: 1.5rem;
      padding: clamp(1.4rem, 4vw, 2.5rem);
      box-shadow: 0 22px 60px rgba(0,0,0,0.24);
      backdrop-filter: blur(12px);
    }

    .split {
      display: grid;
      grid-template-columns: 1.1fr 0.9fr;
      gap: 1.25rem;
      align-items: stretch;
    }

    .tavern-menus {
      display: grid;
      grid-template-columns: repeat(2, minmax(0, 1fr));
      gap: 1rem;
      margin: 2rem auto 0;
      width: min(1040px, 100%);
      max-width: 1040px;
    }

    .menu-panel {
      background: var(--panel);
      border: 1px solid var(--line);
      border-radius: 1.5rem;
      padding: 1rem;
      box-shadow: 0 18px 45px rgba(0, 0, 0, 0.20);
      width: 100%;
    }

    .menu-panel summary,
    .faq-item summary {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      gap: 0.6rem;
      width: 100%;
      padding: 1rem 1.15rem;
      border-radius: 1.25rem;
      background: rgba(147, 216, 255, 0.08);
      color: var(--text);
      font-size: 1rem;
      font-weight: 600;
      cursor: pointer;
      list-style: none;
      text-align: center;
    }

    .menu-panel summary::-webkit-details-marker,
    .faq-item summary::-webkit-details-marker {
      display: none;
    }

    .faq {
      display: grid;
      gap: 1rem;
      margin-top: 1rem;
    }

    .faq-item {
      background: var(--panel);
      border: 1px solid var(--line);
      border-radius: 1.5rem;
      box-shadow: 0 16px 40px rgba(0, 0, 0, 0.16);
      overflow: hidden;
    }

    .faq-item p {
      margin: 0;
      padding: 1rem 1.15rem 1.2rem;
      color: var(--muted);
      line-height: 1.75;
    }

    .menu-panel summary::-webkit-details-marker {
      display: none;
    }

    .menu-panel > .menu-content {
      display: none;
    }

    .menu-panel[open] summary {
      background: rgba(147, 216, 255, 0.14);
    }

    .menu-panel[open] > .menu-content {
      display: block;
    }
    .menu-panel[open] > .menu-content {
      display: block;
    }

    .menu-content {
      margin-top: 1rem;
      color: var(--muted);
      display: grid;
      gap: 0.65rem;
    }

    .menu-content ul {
      padding-left: 1.1rem;
      margin: 0;
      display: grid;
      gap: 0.45rem;
    }

    .menu-content li {
      position: relative;
      padding-left: 1rem;
    }

    .menu-content li::before {
      content: "•";
      position: absolute;
      left: 0;
      color: var(--gold);
    }

    .about p + p,
    .recruit p + p,
    .rules p + p,
    .panel p + p {
      margin-top: 1rem;
    }

    .officers-grid {
      display: grid;
      gap: 1rem;
      margin-top: 2rem;
    }

    .officer-row {
      display: grid;
      gap: 0.8rem;
      width: min(860px, 100%);
      margin: 0 auto;
      justify-items: center;
    }

    .officer-row--two {
      grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .officer-row--three {
      grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .officer-row--small {
      max-width: 680px;
    }

    .officer-row-divider {
      border: 0;
      height: 1px;
      width: min(70%, 680px);
      margin: 0.5rem auto;
      background: linear-gradient(90deg, transparent, rgba(214, 242, 255, 0.35), transparent);
    }

    .officer-card {
      perspective: 1200px;
      cursor: pointer;
      max-width: 280px;
      width: 100%;
      margin: 0 auto;
    }

    .officer-row--three .officer-card {
      max-width: 250px;
    }

    .officer-row--small .officer-card {
      max-width: 300px;
    }

    .leaders-header {
      margin-top: 2rem;
      display: flex;
      justify-content: center;
    }

    .officer-divider {
      border: 0;
      height: 1px;
      margin: 2rem auto;
      width: min(80%, 680px);
      background: linear-gradient(90deg, transparent, rgba(214, 242, 255, 0.35), transparent);
    }

    .officer-card:focus {
      outline: none;
    }

    .card-inner {
      position: relative;
      width: 100%;
      padding-top: 100%;
      transform-style: preserve-3d;
      transition: transform 0.6s ease;
    }

    .officer-card:hover .card-inner,
    .officer-card:focus-within .card-inner {
      transform: rotateY(180deg);
    }

    .card-face {
      position: absolute;
      inset: 0;
      border-radius: 1.8rem;
      border: 1px solid rgba(255, 255, 255, 0.08);
      background: rgba(3, 8, 18, 0.9);
      box-shadow: 0 18px 45px rgba(0, 0, 0, 0.24);
      display: grid;
      place-items: center;
      text-align: center;
      padding: 1rem;
      backface-visibility: hidden;
      overflow: hidden;
    }

    .card-face.front {
      color: #fff;
      background-size: cover;
      background-position: center;
      background-repeat: no-repeat;
      display: flex;
      flex-direction: column;
      justify-content: flex-end;
      align-items: center;
      padding-bottom: 1.5rem;
    }

    .card-face.back {
      transform: rotateY(180deg);
      background: rgba(3, 8, 18, 0.96);
      overflow: auto;
      overflow-y: scroll;
      overflow-x: hidden;
      display: flex;
      flex-direction: column;
      align-items: center;
      justify-content: flex-start;
    }

    .card-face.back::-webkit-scrollbar {
      width: 6px;
    }

    .card-face.back::-webkit-scrollbar-track {
      background: rgba(147, 216, 255, 0.08);
      border-radius: 3px;
    }

    .card-face.back::-webkit-scrollbar-thumb {
      background: rgba(147, 216, 255, 0.4);
      border-radius: 3px;
    }

    .card-face.back::-webkit-scrollbar-thumb:hover {
      background: rgba(147, 216, 255, 0.6);
    }

    .tavern-cards {
      display: grid;
      grid-template-columns: repeat(2, minmax(0, 1fr));
      gap: 1rem;
      margin-top: 2rem;
    }

    .tavern-card {
      max-width: 520px;
      width: 100%;
    }

    .tavern-card .card-face.front {
      background: linear-gradient(180deg, rgba(3, 8, 18, 0.96), rgba(3, 8, 18, 0.88));
      justify-content: center;
      padding: 1.5rem;
    }

    .tavern-card .tavern-card-content {
      width: 100%;
      display: grid;
      gap: 1rem;
      align-items: start;
    }

    .tavern-card .detail {
      background: rgba(255,255,255,0.05);
      padding: 1rem;
      border-radius: 1rem;
      border: 1px solid rgba(214, 242, 255, 0.12);
    }

    .tavern-card .flip-hint {
      color: var(--gold);
      font-size: 0.8rem;
      letter-spacing: 0.12em;
      text-transform: uppercase;
    }

    .officer-card h3 {
      font-size: clamp(0.95rem, 3vw, 1.1rem);
      margin: 0.3rem 0 0.25rem;
      color: #fff;
    }

    .menu-content table {
      border-spacing: 0 1.2rem;
    }

    .menu-content tbody tr > td:nth-child(2) {
      color: var(--gold);
      font-weight: 600;
    }

    .menu-content th {
      padding: 1rem 1rem;
      border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .menu-content td {
      padding: 1.2rem 1rem;
      border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .officer-card p {
      color: var(--muted);
      margin: 0;
      max-width: none;
      width: 100%;
      font-size: clamp(0.85rem, 2.5vw, 0.95rem);
    }

    .card-face.back p {
      max-width: none;
    }

    .flip-hint {
      margin-top: 2px;
      font-size: clamp(0.7rem, 2.5vw, 0.78rem);
      color: var(--gold);
      text-transform: uppercase;
      letter-spacing: 0.14em;
    }

   .cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  margin-left: 0; 
    }

    #affiliates .container {
      max-width: none;
      width: 100%;
      padding: 0 1.25rem;
    }

#affiliates .cards {
  grid-template-columns: repeat(4, minmax(260px, 1fr));
}

    #affiliates .officer-card {
      max-width: none;
      width: 100%;
    }

.card {
  background: var(--panel-soft);
  border: 1px solid var(--line);
  border-radius: 1.25rem;
  padding: 1.25rem;
  min-height: 180px;
  transition: transform 180ms ease, border 180ms ease;
  width: 100%; 
    }

    .card:hover {
      transform: translateY(-4px);
      border-color: rgba(147, 216, 255, 0.42);
    }

    .icon {
      width: 2.4rem;
      height: 2.4rem;
      display: grid;
      place-items: center;
      margin-bottom: 0.8rem;
      border-radius: 999px;
      color: var(--frost-soft);
      background: rgba(147, 216, 255, 0.10);
      border: 1px solid rgba(147, 216, 255, 0.24);
      overflow: hidden;
    }

    .icon img {
      width: 1.5rem;
      height: 1.5rem;
      object-fit: contain;
      display: block;
    }

    h3 {
      font-size: 1.35rem;
      margin-bottom: 0.55rem;
    }

    .underlined {
      text-decoration: underline;
      text-decoration-color: rgba(147, 216, 255, 0.85);
      text-underline-offset: 0.2rem;
    }

    /* Ensure underlines show when the header is inside a link (.card-link resets decorations) */
    .card-link .underlined {
      text-decoration: underline;
      text-decoration-color: rgba(147, 216, 255, 0.85);
      text-underline-offset: 0.2rem;
    }

    .card p,
    .panel p,
    li {
      color: var(--muted);
    }
    .card-link {
      display: block;
      color: inherit;
      text-decoration: none;
    }

    .card-link:focus {
      outline: 2px solid rgba(147,216,255,0.22);
      outline-offset: 4px;
    }

.tavern {
  background:
    linear-gradient(rgba(3, 8, 18, 0.30), rgba(3, 8, 18, 0.80)),
    url("https://fm-rp.com/Images/bar.png") center/cover fixed;
  border-block: 1px solid var(--line);
}

    .details {
      display: grid;
      gap: 0.8rem;
    }

    .detail {
      padding: 1rem;
      border-radius: 1rem;
      background: rgba(255,255,255,0.045);
      border: 1px solid var(--line);
    }

    .detail strong {
      color: var(--frost-soft);
    }

    ul {
      list-style: none;
      display: grid;
      gap: 0.75rem;
    }

    li {
      position: relative;
      padding-left: 1.55rem;
    }

    li::before {
      content: "✦";
      position: absolute;
      left: 0;
      color: var(--gold);
    }

    .tags {
      display: flex;
      flex-wrap: wrap;
      justify-content: center;
      gap: 0.65rem;
      margin: 1.5rem auto 0;
      max-width: 900px;
    }

    .tag {
      padding: 0.45rem 0.75rem;
      border-radius: 999px;
      color: var(--frost-soft);
      border: 1px solid rgba(147, 216, 255, 0.24);
      background: rgba(147, 216, 255, 0.08);
      font-size: 0.92rem;
    }

    .menu-content tbody tr > td:nth-child(2) {
      color: var(--gold);
      font-weight: 600;
    }

    .menu-panel summary {
      text-align: center;
    }

    /* Slideshow styles replacing previous gallery cards */
    .gallery.slideshow {
      position: relative;
      width: 100%;
      max-width: 1040px;
      margin: 1.5rem auto 0;
      border-radius: 1.25rem;
      overflow: hidden;
      border: 1px solid var(--line);
      background: rgba(3,8,18,0.6);
      height: clamp(220px, 34vw, 420px);
    }

    .gallery .slides {
      position: relative;
      height: 100%;
    }

    .gallery .slide {
      position: absolute;
      inset: 0;
      background-size: cover;
      background-position: center;
      opacity: 0;
      transition: opacity 600ms ease, transform 600ms ease;
      display: flex;
      align-items: flex-end;
      padding: 1rem;
    }

    .gallery .slide.active {
      opacity: 1;
    }

    .gallery .slide span {
      display: inline-block;
      background: linear-gradient(90deg, rgba(10,18,32,0.55), rgba(10,18,32,0.25));
      color: var(--text);
      padding: 0.6rem 0.9rem;
      border-radius: 0.6rem;
      font-weight: 600;
    }

    .slide-prev,
    .slide-next {
      position: absolute;
      top: 50%;
      transform: translateY(-50%);
      background: rgba(0,0,0,0.45);
      color: var(--text);
      border: none;
      width: 44px;
      height: 44px;
      border-radius: 999px;
      display: grid;
      place-items: center;
      cursor: pointer;
      z-index: 6;
    }

    .slide-prev { left: 0.8rem; }
    .slide-next { right: 0.8rem; }

    .slide-dots {
      position: absolute;
      left: 50%;
      transform: translateX(-50%);
      bottom: 0.8rem;
      display: flex;
      gap: 0.5rem;
      z-index: 6;
    }

    .slide-dots .dot {
      width: 10px;
      height: 10px;
      border-radius: 999px;
      background: rgba(255,255,255,0.18);
      border: none;
      cursor: pointer;
      padding: 0;
    }

    .slide-dots .dot.active { background: var(--gold); }

    .cta {
      text-align: center;
    }

    footer {
      padding: 2rem 1.25rem;
      text-align: center;
      color: var(--muted);
      border-top: 1px solid var(--line);
      background: rgba(3, 8, 18, 0.72);
    }

    @media (max-width: 880px) {
    .nav {
        overflow-x: auto;
        justify-content: flex-start;
      }

      .split,
      .cards,
      .gallery,
      .officers-grid {
        grid-template-columns: 1fr;
      }

      .hero {
        min-height: 86vh;
      }

      .hero-card {
        border-radius: 1.3rem;
      }
}