/* ==========================================
   1. GLOBAL & PC DESKTOP LAYOUT (Wider screens)
   ========================================== */

.site-header .wrapper {
    display: flex !important;
    align-items: center !important; /* Forces vertical center */
    justify-content: space-between;
    min-height: 70px;               /* Adjust this to your desired header height */
    position: relative;
}

.site-nav {
  display: flex;
  align-items: center;
  height: 100%; /* Match parent height */
}

/* PC Setup: Hide the separate mobile-only shortcut buttons container on desktop */
.header-quick-links {
  display: none !important;
}

/* PC Setup: Show all menu items horizontally as pill buttons */
.site-nav__menu {
  display: flex !important;
  flex-direction: row !important;
  align-items: center;
  gap: 0.5rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

/* Style every item inside the desktop menu as a button */
.site-nav .page-link {
  font-size: 0.85rem;
  font-weight: 700;
  color: #153d75;
  text-decoration: none;
  white-space: nowrap;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  padding: 0.4rem 0.8rem !important; 
  border: 0.2px solid #cfdbe9;
  border-radius: 999px;
  background: #fff;
  margin-right: 0 !important; /* Overwrite previous standard margins */
  transition: all 0.2s ease;
}

.site-nav .page-link:hover,
.site-nav .page-link:focus-visible {
  color: #153d75;
  text-decoration: underline;
  text-underline-offset: 0.18rem;
  background: #f4f7fa;
}

.site-title--logo {
  display: flex;
  align-items: center;
  margin: 0 !important; /* Remove any default margins */
}

.site-title--logo img {
  display: block;
  height: 44px;
  width: auto;
}

/* ==========================================
   1. GLOBAL & PC DESKTOP LAYOUT (Wider screens)
   ========================================== */

.site-header .wrapper {
    display: flex !important;
    align-items: center !important; /* Forces vertical center */
    justify-content: space-between;
    min-height: 70px;               /* Adjust this to your desired header height */
    position: relative;
}

.site-nav {
  display: flex;
  align-items: center;
  height: 100%; /* Match parent height */
}

/* PC Setup: Hide the separate mobile-only shortcut buttons container on desktop */
.header-quick-links {
  display: none !important;
}

/* PC Setup: Show all menu items horizontally as pill buttons */
.site-nav__menu {
  display: flex !important;
  flex-direction: row !important;
  align-items: center;
  gap: 0.5rem;
  margin: 0;
  padding: 20px;
  list-style: none;
}

/* Style every item inside the desktop menu as a button */
.site-nav .page-link {
  font-size: 0.85rem;
  font-weight: 700;
  color: #153d75;
  text-decoration: none;
  white-space: nowrap;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  padding: 0.4rem 0.8rem !important; 
  border: 0.2px solid #cfdbe9;
  border-radius: 999px;
  background: #fff;
  margin-right: 0 !important; /* Overwrite previous standard margins */
  transition: all 0.2s ease;
}

.site-nav .page-link:hover,
.site-nav .page-link:focus-visible {
  color: #153d75;
  text-decoration: underline;
  text-underline-offset: 0.18rem;
  background: #f4f7fa;
}

.site-title--logo {
  display: flex;
  align-items: center;
  margin: 0 !important; /* Remove any default margins */
}

.site-title--logo img {
  display: block;
  height: 44px;
  width: auto;
}

/* Establish a relative boundary context box layer */
.events-banner-container {
  position: relative;
  width: 100%;
  display: block;
}

/* Hide the native checkbox markup controller element */
.events-toggle-input {
  display: none !important;
}

/* Toggle Button Positioned directly over/inside the banner line row */
.events-toggle-btn {
  position: absolute;
  top: 75px;
  transform: translateY(-50%); /* Keeps button perfectly centered vertically */
  left: 0px;                 /* Placed on right edge inside the track line boundaries */
  z-index: 101;                /* Keeps button layered cleanly on top of sliding text track strings */
  background: #a08c78;
  color: #fff;
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  cursor: pointer;
  font-size: 0.8rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.2s ease, opacity 0.2s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.events-toggle-btn:hover {
  background: #8e7a67; /* Darker variant tone block hover shift effect */
}

/* Base Hidden Structural Setup for Ticker Track Strip Ribbon */
.events-ticker {
  opacity: 0;
  visibility: hidden;
  height: 0;
  overflow: hidden;
  transition: opacity 0.3s ease, height 0.3s ease, visibility 0.3s ease;
  background: #a08c78;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  /* Create an empty cushion space buffer on right side so marquee words don't clip beneath button */
  padding-right: 100px; 
}

/* TRIGGER CONTROL STATE STATE CHANGES: Smoothly expand text track list when toggled open */
.events-toggle-input:checked ~ .events-ticker {
  opacity: 1;
  visibility: visible;
  height: auto; 
}

/* OPTIONAL refinement toggle: Shift button visuals when system switches to open state sequence */
.events-toggle-input:checked ~ .events-toggle-btn {
  background: rgba(255, 255, 255, 0.15); /* Light translucent effect button state overlay blend look */
  border-color: rgba(255, 255, 255, 0.4);
}
  

/* Hide the native form input trigger */
.events-toggle-input {
  display: none !important;
}


.events-toggle-btn:hover {
  background: #8e7a67; /* Slightly darker shade on hover state */
  transform: translateX(-2px); /* Slight interactive wiggle */
}

/* Base State: Hide your ticker banner by default */
.events-ticker {
  opacity: 0;
  visibility: hidden;
  height: 0;
  overflow: hidden;
  transition: opacity 0.3s ease, height 0.3s ease, visibility 0.3s ease;
  background: #a08c78;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

/* TRIGGER STATE: Reveal banner smoothly when checkbox is checked */
.events-toggle-input:checked ~ .events-ticker {
  opacity: 1;
  visibility: visible;
  height: auto; /* Dynamically sizes to hold text item contents */
}

/* OPTIONAL: Shift button position slightly when active if needed */
.events-toggle-input:checked ~ .events-toggle-btn {
  border-radius: 0 0 0 8px; /* Refines edge balance when open */
}


.events-ticker__link {
  display: block;
  text-decoration: none;
  color: #fff;
}

.events-ticker__track {
  display: flex;
  width: max-content;
  /* Adjust the 28s duration higher if the text scrolls too quickly */
  animation: events-ticker-scroll 60s linear infinite; 
}

.events-ticker:hover .events-ticker__track {
  animation-play-state: paused;
}

.events-ticker__group {
  display: flex;
  flex-shrink: 0;
}

.events-ticker__item {
  display: inline-flex;
  align-items: baseline;
  gap: 0.5rem;
  white-space: nowrap;
  padding: 0.55rem 1.5rem;
  font-size: 0.85rem;
}

.events-ticker__item strong {
  font-weight: 700;
}

.events-ticker__meta {
  color: #4a4b4d;
  font-size: 0.8rem;
}

@keyframes events-ticker-scroll {
  0% {
    transform: translateX(0);
  }
  100% {
    /* Moves right-to-left by exactly one full segment length for seamless recycling */
    transform: translateX(100%); 
  }
}

@media (prefers-reduced-motion: reduce) {
  .events-ticker__track {
    animation: none;
  }
}

.header-project-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
  justify-content: flex-end;
  margin-top: 0.25rem;
}

.header-project-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: none;
  background: transparent;
  color: #153d75;
  font-size: 0.82rem;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
  transition: opacity 0.2s ease, color 0.2s ease;
}

.header-about-link {
  order: 999;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  overflow: hidden;
  box-shadow: 0 6px 16px rgba(21, 61, 117, 0.18);
  background: #f8f1e7;
  transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
  flex-shrink: 0;
}

.header-about-link img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center;
  image-rendering: auto;
}

.header-about-link__text {
  display: none;
}

.header-about-link:hover,
.header-about-link:focus-visible {
  transform: scale(1.18);
  box-shadow: 0 10px 22px rgba(21, 61, 117, 0.26);
}

.header-project-links a:hover,
.header-project-links a:focus-visible {
  color: #0d2d57;
  text-decoration: underline;
  text-underline-offset: 0.18rem;
  opacity: 1;
}

.back-to-top {
  position: fixed;
  left: 1.25rem;
  bottom: 1.25rem;
  display: none;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border: none;
  border-radius: 50%;
  background: rgba(20, 49, 92, 0.9);
  color: #fff;
  font-size: 1.7rem;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 10px 20px rgba(20, 49, 92, 0.22);
  z-index: 999;
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: opacity 0.2s ease, visibility 0.2s ease, transform 0.2s ease;
  pointer-events: none;
}

.back-to-top.visible {
  display: flex;
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
}


/* ==========================================
   2. MOBILE LAYOUT ONLY (720px and smaller)
   ========================================== */
@media (max-width: 720px) {
  
  /* Mobile Setup: Keep the base menu hidden until clicked */
  .site-nav__menu {
    display: none !important;
    position: absolute;
    top: calc(100% + 0.5rem);
    right: 0;
    min-width: min(80vw, 260px);
    background: rgba(175, 173, 186, 0.95);
    border: 1px solid #dde5ef;
    border-radius: 0.9rem;
    box-shadow: 0 14px 36px rgba(15, 27, 51, 0.14);
    z-index: 100;
    flex-direction: column !important; /* Revert desktop row to stack vertically */
    align-items: flex-start;
    direction: rtl;
    gap: 0;
  }

  /* CRITICAL FIX: Overwrite desktop !important rule only when trigger checkbox is checked */
  .site-nav.is-mobile .nav-trigger:checked ~ .site-nav__menu {
    display: flex !important;
    align-items: center;
  }

  /* Display your custom standalone 3 mobile buttons bar directly in header */
  .header-quick-links {
    display: flex !important;
    justify-content: center;
    flex-wrap: nowrap !important; 
    align-items: center;
    gap: 0.25rem;
    margin-top: 5px;
    margin-right: 0; 
    width: 100%;
  }

  .header-quick-links a {
    font-size: 0.72rem; 
    font-weight: 700;
    color: #153d75;
    text-decoration: none;
    white-space: nowrap;
    display: flex; 
    justify-content: center;
    align-items: center;
    min-height: 0 !important; 
    padding: 0.4rem 0.7rem !important; 
    border: 0.2px solid #cfdbe9;
    border-radius: 999px;
    background: #fff;
    cursor: pointer;
    flex-shrink: 1; 
  }

  .header-quick-links a:hover,
  .header-quick-links a:focus-visible {
    text-decoration: underline;
    text-underline-offset: 0.18rem;
  }

  /* Reset layout structure of links when rendering inside mobile list dropdown */
  .site-nav .page-link {
    display: block !important;
    margin: 0;
    padding: 0.75rem 0 !important;
    width: 100%;
    border: none !important;      /* Strip the desktop pill border design */
    border-bottom: 1px solid #e2e8f0 !important; /* Add divider lines instead */
    border-radius: 0 !important;  /* Strip desktop rounded corners */
    background: transparent !important;
    text-align: right;
  }

  .site-title--logo img {
    height: 36px;
    width: 36px;
    object-fit: contain;
  }

  .site-nav {
    position: static;
  }

  .header-project-links {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
    width: 100%;
    margin-top: 0.5rem;
    gap: 0.55rem;
  }

  .header-project-links a {
    justify-content: flex-start;
    width: 100%;
    text-align: right;
    white-space: normal;
    padding-bottom: 0.55rem;
    border-bottom: 1px solid #e2e8f0;
  }

  .header-project-links .header-about-link {
    border-bottom: none;
  }

  .header-about-link {
    width: auto;
    height: auto;
    margin-top: 0.25rem;
    border-radius: 0;
    overflow: visible;
    box-shadow: none;
    background: transparent;
    padding: 0;
  }

  .header-about-link img {
    display: none;
  }

  .header-about-link__text {
    display: inline;
    color: #153d75;
    font-size: 0.92rem;
    font-weight: 700;
    line-height: 1.2;
  }

  .back-to-top {
    left: 0.9rem;
    bottom: 0.9rem;
    width: 44px;
    height: 44px;
    font-size: 1.5rem;
  }
}
.events-banner-container {
  display: flex !important;
  flex-direction: row; /* Ensures items are side-by-side */
  align-items: center; /* Vertically centers the button and banner */
  width: 100%;
  background: #a08c78;
  overflow: hidden;
}
/* Hide the native checkbox markup controller element */
.events-toggle-input {
  display: none !important;
}


.events-toggle-btn:hover {
  background: #8e7a67; /* Darker variant tone block hover shift effect */
}

.events-ticker {
  flex-grow: 1; /* Takes up all space from the button's edge to the end of the line */
  opacity: 0;
  visibility: hidden;
  height: 0;
  overflow: hidden;
  transition: opacity 0.3s ease, height 0.3s ease;
}

/* Reveal banner only when toggled */
.events-toggle-input:checked ~ .events-ticker {
  opacity: 1;
  visibility: visible;
  height: 40px; /* Or match your desired header height */
}


/* OPTIONAL refinement toggle: Shift button visuals when system switches to open state sequence */
.events-toggle-input:checked ~ .events-toggle-btn {
  background: rgba(255, 255, 255, 0.15); /* Light translucent effect button state overlay blend look */
  border-color: rgba(255, 255, 255, 0.4);
}
  

/* Hide the native form input trigger */
.events-toggle-input {
  display: none !important;
}


.events-toggle-btn:hover {
  background: #8e7a67; /* Slightly darker shade on hover state */
  transform: translateX(-2px); /* Slight interactive wiggle */
}

/* Base State: Hide your ticker banner by default */
.events-ticker {
  opacity: 0;
  visibility: hidden;
  height: 0;
  overflow: hidden;
  transition: opacity 0.3s ease, height 0.3s ease, visibility 0.3s ease;
  background: #a08c78;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

/* TRIGGER STATE: Reveal banner smoothly when checkbox is checked */
.events-toggle-input:checked ~ .events-ticker {
  opacity: 1;
  visibility: visible;
  height: auto; /* Dynamically sizes to hold text item contents */
}

/* OPTIONAL: Shift button position slightly when active if needed */
.events-toggle-input:checked ~ .events-toggle-btn {
  border-radius: 0 0 0 8px; /* Refines edge balance when open */
}


.events-ticker__link {
  display: block;
  text-decoration: none;
  color: #fff;
}

.events-ticker__track {
  display: flex;
  width: max-content;
  /* Adjust the 28s duration higher if the text scrolls too quickly */
  animation: events-ticker-scroll 60s linear infinite; 
}

.events-ticker:hover .events-ticker__track {
  animation-play-state: paused;
}

.events-ticker__group {
  display: flex;
  flex-shrink: 0;
}

.events-ticker__item {
  display: inline-flex;
  align-items: baseline;
  gap: 0.5rem;
  white-space: nowrap;
  padding: 0.55rem 1.5rem;
  font-size: 0.85rem;
}

.events-ticker__item strong {
  font-weight: 700;
}

.events-ticker__meta {
  color: #4a4b4d;
  font-size: 0.8rem;
}

@keyframes events-ticker-scroll {
  0% {
    transform: translateX(0);
  }
  100% {
    /* Moves right-to-left by exactly one full segment length for seamless recycling */
    transform: translateX(100%); 
  }
}

@media (prefers-reduced-motion: reduce) {
  .events-ticker__track {
    animation: none;
  }
}

.header-project-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
  justify-content: flex-end;
  margin-top: 0.25rem;
}

.header-project-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: none;
  background: transparent;
  color: #153d75;
  font-size: 0.82rem;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
  transition: opacity 0.2s ease, color 0.2s ease;
}

.header-about-link {
  order: 999;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  overflow: hidden;
  box-shadow: 0 6px 16px rgba(21, 61, 117, 0.18);
  background: #f8f1e7;
  transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
  flex-shrink: 0;
}

.header-about-link img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center;
  image-rendering: auto;
}

.header-about-link__text {
  display: none;
}

.header-about-link:hover,
.header-about-link:focus-visible {
  transform: scale(1.18);
  box-shadow: 0 10px 22px rgba(21, 61, 117, 0.26);
}

.header-project-links a:hover,
.header-project-links a:focus-visible {
  color: #0d2d57;
  text-decoration: underline;
  text-underline-offset: 0.18rem;
  opacity: 1;
}

.back-to-top {
  position: fixed;
  left: 1.25rem;
  bottom: 1.25rem;
  display: none;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border: none;
  border-radius: 50%;
  background: rgba(20, 49, 92, 0.9);
  color: #fff;
  font-size: 1.7rem;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 10px 20px rgba(20, 49, 92, 0.22);
  z-index: 999;
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: opacity 0.2s ease, visibility 0.2s ease, transform 0.2s ease;
  pointer-events: none;
}

.back-to-top.visible {
  display: flex;
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
}


/* ==========================================
   2. MOBILE LAYOUT ONLY (720px and smaller)
   ========================================== */
@media (max-width: 720px) {
  
  /* Mobile Setup: Keep the base menu hidden until clicked */
  .site-nav__menu {
    display: none !important;
    position: absolute;
    top: calc(100% + 0.5rem);
    right: 0;
    min-width: min(80vw, 260px);
    background: rgba(175, 173, 186, 0.95);
    border: 1px solid #dde5ef;
    border-radius: 0.9rem;
    box-shadow: 0 14px 36px rgba(15, 27, 51, 0.14);
    z-index: 100;
    flex-direction: column !important; /* Revert desktop row to stack vertically */
    align-items: flex-start;
    direction: rtl;
    gap: 0;
  }

  /* CRITICAL FIX: Overwrite desktop !important rule only when trigger checkbox is checked */
  .site-nav.is-mobile .nav-trigger:checked ~ .site-nav__menu {
    display: flex !important;
    align-items: center;
  }

  /* Display your custom standalone 3 mobile buttons bar directly in header */
  .header-quick-links {
    display: flex !important;
    justify-content: center;
    flex-wrap: nowrap !important; 
    align-items: center;
    gap: 0.25rem;
    margin-top: 5px;
    margin-right: 0; 
    width: 100%;
  }

  .header-quick-links a {
    font-size: 0.72rem; 
    font-weight: 700;
    color: #153d75;
    text-decoration: none;
    white-space: nowrap;
    display: flex; 
    justify-content: center;
    align-items: center;
    min-height: 0 !important; 
    padding: 0.4rem 0.7rem !important; 
    border: 0.2px solid #cfdbe9;
    border-radius: 999px;
    background: #fff;
    cursor: pointer;
    flex-shrink: 1; 
  }

  .header-quick-links a:hover,
  .header-quick-links a:focus-visible {
    text-decoration: underline;
    text-underline-offset: 0.18rem;
  }

  /* Reset layout structure of links when rendering inside mobile list dropdown */
  .site-nav .page-link {
    display: block !important;
    margin: 0;
    padding: 0.75rem 0 !important;
    width: 100%;
    border: none !important;      /* Strip the desktop pill border design */
    border-bottom: 1px solid #e2e8f0 !important; /* Add divider lines instead */
    border-radius: 0 !important;  /* Strip desktop rounded corners */
    background: transparent !important;
    text-align: right;
    line-height: 30px;
  }

  .site-title--logo img {
    height: 36px;
    width: 36px;
    object-fit: contain;
  }

  .site-nav {
    position: static;
    line-height: 30px;
    margin-right: 0.5rem;
  }

  .header-project-links {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
    width: 100%;
    margin-top: 0.5rem;
    gap: 0.55rem;
  }

  .header-project-links a {
    justify-content: flex-start;
    width: 100%;
    text-align: right;
    white-space: normal;
    padding-bottom: 0.55rem;
    border-bottom: 1px solid #e2e8f0;
  }

  .header-project-links .header-about-link {
    border-bottom: none;
  }

  .header-about-link {
    width: auto;
    height: auto;
    margin-top: 0.25rem;
    border-radius: 0;
    overflow: visible;
    box-shadow: none;
    background: transparent;
    padding: 0;
  }

  .header-about-link img {
    display: none;
  }

  .header-about-link__text {
    display: inline;
    color: #153d75;
    font-size: 0.92rem;
    font-weight: 700;
    line-height: 1.2;
  }

  .back-to-top {
    left: 0.9rem;
    bottom: 0.9rem;
    width: 44px;
    height: 44px;
    font-size: 1.5rem;
  }
}
