/* Funnyeye — navbar */

.fe-nav {
z-index: 1000;
  background: #ddd;
  position: relative;
}

.fe-nav:before, .fe-nav:after {
content: " ";
  grid-area: 1 / 1 / 2 / 2;
  display: table;
}

.fe-nav:after {
clear: both;
}

.fe-nav[data-animation="over-left"] .fe-nav-overlay {
width: auto;
}

.fe-nav[data-animation="over-left"] .fe-nav-overlay, .fe-nav[data-animation="over-left"] [data-nav-menu-open] {
z-index: 1;
  top: 0;
  right: auto;
}

.fe-nav[data-animation="over-right"] .fe-nav-overlay {
width: auto;
}

.fe-nav[data-animation="over-right"] .fe-nav-overlay, .fe-nav[data-animation="over-right"] [data-nav-menu-open] {
z-index: 1;
  top: 0;
  left: auto;
}

.fe-nav[data-collapse="all"] .fe-nav-menu {
display: none;
}

.fe-nav[data-collapse="all"] .fe-nav-button, .fe-nav-dropdown-open, .fe-nav-dropdown-toggle-open {
display: block;
}

.fe-navbar {
z-index: 998;
  padding-right: var(--spacing--section-left-and-right);
  padding-left: var(--spacing--section-left-and-right);
  -webkit-backdrop-filter: blur(5px);
  backdrop-filter: blur(5px);
  background-color: #071f4e80;
  transition: background-color .2s;
  position: fixed;
  inset: 0% 0% auto;
}

.fe-navbar:where(.w-variant-91a0cf6d-8056-78c5-8eaf-d56e897ee6e9) {
background-color: var(--colors--white);
}

/* Brand wordmark — text logo, white, split into English + Chinese
   runs that render side-by-side on desktop and stack on phones.  Each
   run uses its own brand font (Lemon Tuesday / FOT-TsukuAOldMin); if
   either is absent, the corresponding project fallback stack takes
   over so the navbar still reads cleanly.  See base.css :root
   --font-logo-en / --font-logo-zh for the font stacks. */
.fe-brand {
  display: block;
  height: 36px;
  width: auto;
  max-width: 220px;
  object-fit: contain;
}

.fe-menu {
margin-left: auto;
  margin-right: auto;
}

.fe-menu-link {
opacity: .8;
  color: var(--colors--white);
  margin-left: 1.25rem;
  margin-right: 1.25rem;
  padding: 0;
  text-decoration: none;
  transition: color .2s, opacity .2s;
}

.fe-menu-link:where(.w-variant-91a0cf6d-8056-78c5-8eaf-d56e897ee6e9) {
color: var(--colors--black);
}

.fe-menu-link:hover {
opacity: 1;
}


/* ---- Dropdown submenu ---- */

.fe-menu-item-has-dropdown {
  position: relative;
  display: inline-block;
}

.fe-menu-link-parent {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  cursor: pointer;
}

.fe-menu-caret {
  font-size: 0.7em;
  opacity: 0.6;
  transition: transform 0.2s, opacity 0.2s;
}

.fe-menu-item-has-dropdown:hover .fe-menu-caret,
.fe-menu-item-has-dropdown:focus-within .fe-menu-caret {
  transform: translateY(1px);
  opacity: 1;
}

.fe-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 12rem;
  padding: 0.5rem 0;
  margin-top: 0.5rem;
  background-color: rgba(0, 0, 0, 0.6);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border-radius: 6px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-4px);
  transition: opacity 0.15s, transform 0.15s, visibility 0.15s;
  z-index: 999;
}

.fe-menu-item-has-dropdown:hover .fe-dropdown,
.fe-menu-item-has-dropdown:focus-within .fe-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.fe-dropdown-item {
  display: block;
  padding: 0.5rem 1.25rem;
  color: var(--colors--white);
  opacity: 0.8;
  text-decoration: none;
  white-space: nowrap;
  transition: opacity 0.2s, background-color 0.2s;
}

.fe-dropdown-item:where(.w-variant-91a0cf6d-8056-78c5-8eaf-d56e897ee6e9) {
  color: var(--colors--black);
}

.fe-dropdown-item:hover,
.fe-dropdown-item:focus-visible {
  opacity: 1;
  background-color: rgba(255, 255, 255, 0.08);
  outline: none;
}


/* ---- Language switcher ---- */
.fe-lang-switcher {
  display: inline-flex;
  align-items: center;
  margin-left: 1.25rem;
  margin-right: 1.25rem;
  font-size: 0.875rem;
  letter-spacing: 0.05em;
  user-select: none;
}

.fe-lang-btn {
  background: transparent;
  border: 0;
  padding: 0.25rem 0.5rem;
  cursor: pointer;
  color: var(--colors--white);
  opacity: 0.5;
  font: inherit;
  letter-spacing: inherit;
  transition: opacity 0.2s, color 0.2s;
}

.fe-lang-btn:where(.w-variant-91a0cf6d-8056-78c5-8eaf-d56e897ee6e9) {
  color: var(--colors--black);
}

.fe-lang-btn:hover {
  opacity: 0.85;
}

.fe-lang-btn.fe-lang-active {
  opacity: 1;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 0.25em;
  text-decoration-thickness: 1px;
}

.fe-lang-btn:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 2px;
  border-radius: 2px;
  opacity: 1;
}

.fe-lang-divider {
  opacity: 0.35;
  margin: 0 0.125rem;
  pointer-events: none;
}


/* ---- Mobile hamburger button (≤ 767px) ---- */

.fe-nav-button {
  display: none;
  /* Visible only inside the @media block below — the desktop bar
     has no use for it.  Bar slots are positioned absolutely so the
     3 bars stack into a single centred icon, then morph to ✕ when
     [data-fe-mobile-menu-open] is set on <body>. */
  position: relative;
  width: 2.25rem;
  height: 2.25rem;
  margin-left: 0.75rem;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  color: var(--colors--white);
  flex: none;
  align-self: center;
}

.fe-nav-button-bar {
  position: absolute;
  left: 0.5rem;
  right: 0.5rem;
  height: 2px;
  background: currentColor;
  border-radius: 1px;
  transition: transform 0.25s ease, opacity 0.2s ease, top 0.25s ease;
}

.fe-nav-button-bar:nth-child(1) { top: 0.65rem; }
.fe-nav-button-bar:nth-child(2) { top: 1.10rem; }
.fe-nav-button-bar:nth-child(3) { top: 1.55rem; }

body[data-fe-mobile-menu-open] .fe-nav-button-bar:nth-child(1) {
  top: 1.10rem;
  transform: rotate(45deg);
}
body[data-fe-mobile-menu-open] .fe-nav-button-bar:nth-child(2) {
  opacity: 0;
}
body[data-fe-mobile-menu-open] .fe-nav-button-bar:nth-child(3) {
  top: 1.10rem;
  transform: rotate(-45deg);
}

.fe-nav-button:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 4px;
  border-radius: 4px;
}


/* ---- Mobile fullscreen overlay ---- */

.fe-mobile-menu {
  /* Hidden by default; the @media block re-uses the same selector
     to give it an actual fullscreen layout below 767px. */
  display: none;
}

@media (max-width: 767px) {
  /* Swap desktop bar contents for the hamburger on phones.  The
     desktop menu / lang switcher / CTA are still in the DOM (kept
     for screen readers and for the dropdown CSS to remain inert),
     they just become invisible. */
  .fe-menu,
  .fe-nav > .fe-container > .fe-lang-switcher,
  .fe-menu-action {
    display: none !important;
  }

  .fe-nav-button {
    display: inline-flex;
  }

  /* The overlay itself: fullscreen navy 900 panel above the fixed
     navbar (navbar is z:998).  The data attribute on <body> drives
     open / close so any caller (hamburger, close button, link,
     ESC) only mutates the body. */
  .fe-mobile-menu {
    display: flex;
    flex-direction: column;
    position: fixed;
    inset: 0;
    z-index: 1001;
    background-color: var(--colors--brand-navy-900);
    color: var(--colors--white);
    padding: 1.25rem var(--spacing--section-left-and-right)
            2.5rem;
    overflow-y: auto;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-12px);
    transition: opacity 0.25s ease, transform 0.3s ease,
                visibility 0s linear 0.3s;
  }

  body[data-fe-mobile-menu-open] .fe-mobile-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    /* visibility flips instantly when opening so the panel is
       interactable during the fade-in. */
    transition: opacity 0.25s ease, transform 0.3s ease,
                visibility 0s linear 0s;
  }

  /* Top row: brand on the left, close button (pill) on the right. */
  .fe-mobile-menu-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.5rem;
  }

  .fe-mobile-menu .fe-brand-img {
    height: 56px;
    max-width: 280px;
  }

  /* Pill-shaped close button with a small "CLOSE" caption next to
     the X — easier to tap (44px target) than the bare 2.25rem X was. */
  .fe-mobile-menu-close {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    height: 2.5rem;
    padding: 0 0.875rem 0 1rem;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 999px;
    background: transparent;
    cursor: pointer;
    color: var(--colors--white);
    font-family: var(--font-body-en);
    font-size: 0.6875rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    transition: background-color 0.2s ease, border-color 0.2s ease;
  }
  :lang(zh) .fe-mobile-menu-close { font-family: var(--font-zh); letter-spacing: 0.1em; }

  .fe-mobile-menu-close:hover,
  .fe-mobile-menu-close:focus-visible {
    background-color: rgba(255, 255, 255, 0.08);
    border-color: var(--colors--brand-gold-500);
    outline: none;
  }

  .fe-mobile-menu-close-bars {
    position: relative;
    width: 0.875rem;
    height: 0.875rem;
    flex: none;
  }

  .fe-mobile-menu-close-caption {
    display: inline-block;
    white-space: nowrap;
    line-height: 1;
  }

  .fe-mobile-menu-close-bar {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 2px;
    background: currentColor;
    border-radius: 1px;
    transform-origin: center;
  }

  .fe-mobile-menu-close-bar:nth-child(1) {
    transform: translateY(-50%) rotate(45deg);
  }
  .fe-mobile-menu-close-bar:nth-child(2) {
    transform: translateY(-50%) rotate(-45deg);
  }

  /* Tiny eyebrow above the menu — sans uppercase tracked out,
     editorial caption style. */
  .fe-mobile-menu-eyebrow {
    font-family: var(--font-display);
    font-size: 0.6875rem;
    letter-spacing: 0.32em;
    color: var(--colors--brand-gold-500);
    text-transform: uppercase;
    margin: 0 0 1.75rem;
    opacity: 0;
    transition: opacity 0.4s ease 80ms;
  }
  body[data-fe-mobile-menu-open] .fe-mobile-menu-eyebrow {
    opacity: 1;
  }

  /* Main nav: vertical, generously spaced. */
  .fe-mobile-menu-nav {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 1.75rem;
  }

  .fe-mobile-menu-group {
    display: flex;
    flex-direction: column;
    gap: 0.625rem;
  }

  /* Top-level link: holds number + label side-by-side + a gold dot on
     hover.  `display: grid` keeps number aligned regardless of label
     length across zh / en.  Background is transparent; the gold accent
     on focus/hover comes from a left pseudo-bar. */
  .fe-mobile-menu-link {
    position: relative;
    display: grid;
    grid-template-columns: auto 1fr;
    align-items: baseline;
    gap: 0.85rem;
    padding: 0.75rem 0 0.75rem 0.85rem;
    color: var(--colors--white);
    text-decoration: none;
    font-weight: 700;
    opacity: 0;
    transform: translateY(8px);
    transition: opacity 0.4s ease, transform 0.4s ease,
                background-color 0.2s ease;
    min-height: 48px;
  }

  /* Gold accent bar that animates in on hover/focus (left side, like
     an editorial section indicator). */
  .fe-mobile-menu-link::before {
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%) scaleY(0);
    transform-origin: center;
    width: 3px;
    height: 1.5rem;
    background-color: var(--colors--brand-gold-500);
    transition: transform 0.2s ease;
    border-radius: 2px;
  }
  .fe-mobile-menu-link:hover::before,
  .fe-mobile-menu-link:focus-visible::before {
    transform: translateY(-50%) scaleY(1);
  }
  .fe-mobile-menu-link:focus-visible {
    outline: none;
  }

  .fe-mobile-menu-num {
    font-family: var(--font-display);
    font-size: 0.75rem;
    letter-spacing: 0.16em;
    color: var(--colors--brand-gold-500);
    opacity: 0.85;
    line-height: 1;
    padding-top: 0.25rem;
  }

  .fe-mobile-menu-label {
    /* Bilingual: zh gets the zh font (heavy), en gets display serif
       (Courier) for editorial weight.  Earlier version used Courier
       for both which read as "thin monospace" — switching to weight
       700 + the language-appropriate family fixes that. */
    font-weight: 700;
    font-size: clamp(1.75rem, 8vw, 2.625rem);
    line-height: 1.1;
    letter-spacing: -0.005em;
  }
  :lang(zh) .fe-mobile-menu-label {
    font-family: var(--font-zh);
    letter-spacing: 0.02em;
  }
  :lang(en) .fe-mobile-menu-label {
    font-family: var(--font-body-en);
    letter-spacing: -0.015em;
  }

  .fe-mobile-menu-link:hover .fe-mobile-menu-label,
  .fe-mobile-menu-link:focus-visible .fe-mobile-menu-label {
    opacity: 0.75;
  }

  /* Sub-list: indented under each group. */
  .fe-mobile-menu-sub {
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
    padding: 0.5rem 0 0.25rem 0.85rem;
    margin-left: 1.45rem;
    border-left: 1px solid rgba(255, 255, 255, 0.18);
  }

  .fe-mobile-menu-sub-link {
    display: inline-block;
    padding: 0.375rem 0 0.375rem 0.5rem;
    color: var(--colors--white);
    text-decoration: none;
    opacity: 0;
    transform: translateY(8px);
    transition: opacity 0.4s ease, transform 0.4s ease, color 0.2s ease;
    min-height: 44px;
    line-height: 1.4;
  }

  .fe-mobile-menu-sub-link::before {
    /* Tiny gold bullet prefix to differentiate from the parent link. */
    content: "";
    display: inline-block;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background-color: var(--colors--brand-gold-500);
    margin-right: 0.625rem;
    vertical-align: middle;
    opacity: 0.55;
    transition: opacity 0.2s ease;
  }
  .fe-mobile-menu-sub-link:hover::before,
  .fe-mobile-menu-sub-link:focus-visible::before {
    opacity: 1;
  }
  .fe-mobile-menu-sub-link:hover .fe-mobile-menu-sub-label,
  .fe-mobile-menu-sub-link:focus-visible .fe-mobile-menu-sub-label {
    opacity: 1;
  }

  .fe-mobile-menu-sub-link:focus-visible {
    outline: none;
  }

  .fe-mobile-menu-sub-label {
    font-weight: 500;
    font-size: 1rem;
    opacity: 0.78;
    letter-spacing: 0.01em;
    vertical-align: middle;
  }
  :lang(zh) .fe-mobile-menu-sub-label {
    font-family: var(--font-zh);
    letter-spacing: 0.04em;
  }
  :lang(en) .fe-mobile-menu-sub-label {
    font-family: var(--font-body-en);
  }

  /* Stagger entrance: each link / sub-link waits a tick longer.
     Counted via :nth-child to avoid inline styles.  The base
     delay is 80ms per step. */
  .fe-mobile-menu-nav > .fe-mobile-menu-group:nth-child(1) .fe-mobile-menu-link,
  .fe-mobile-menu-nav > .fe-mobile-menu-group:nth-child(1) .fe-mobile-menu-sub-link {
    transition-delay: 80ms;
  }
  .fe-mobile-menu-nav > .fe-mobile-menu-group:nth-child(2) .fe-mobile-menu-link,
  .fe-mobile-menu-nav > .fe-mobile-menu-group:nth-child(2) .fe-mobile-menu-sub-link {
    transition-delay: 160ms;
  }
  .fe-mobile-menu-nav > .fe-mobile-menu-group:nth-child(3) .fe-mobile-menu-link,
  .fe-mobile-menu-nav > .fe-mobile-menu-group:nth-child(3) .fe-mobile-menu-sub-link {
    transition-delay: 240ms;
  }
  .fe-mobile-menu-nav > .fe-mobile-menu-group:nth-child(4) .fe-mobile-menu-link,
  .fe-mobile-menu-nav > .fe-mobile-menu-group:nth-child(4) .fe-mobile-menu-sub-link {
    transition-delay: 320ms;
  }
  .fe-mobile-menu-nav > .fe-mobile-menu-group:nth-child(5) .fe-mobile-menu-link,
  .fe-mobile-menu-nav > .fe-mobile-menu-group:nth-child(5) .fe-mobile-menu-sub-link {
    transition-delay: 400ms;
  }

  body[data-fe-mobile-menu-open] .fe-mobile-menu-link,
  body[data-fe-mobile-menu-open] .fe-mobile-menu-sub-link {
    opacity: 1;
    transform: translateY(0);
  }

  .fe-mobile-menu-link:hover .fe-mobile-menu-label,
  .fe-mobile-menu-link:focus-visible .fe-mobile-menu-label {
    opacity: 0.7;
  }

  /* Footer slot: language switcher pinned to the bottom of the
     overlay.  Same look as the desktop lang switcher but the gap
     between ZH / EN opens up a bit. */
  .fe-mobile-menu-foot {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.15);
    opacity: 0;
    transition: opacity 0.4s ease 0.45s;
  }

  body[data-fe-mobile-menu-open] .fe-mobile-menu-foot {
    opacity: 1;
  }

  .fe-mobile-menu-foot .fe-lang-switcher {
    margin: 0;
    font-size: 1rem;
  }

  .fe-mobile-menu-foot .fe-lang-btn {
    padding: 0.5rem 0.75rem;
    opacity: 0.5;
  }

  .fe-mobile-menu-foot .fe-lang-btn.fe-lang-active {
    opacity: 1;
  }
}
