/* =========================================
   THEME & GLOBAL
========================================= */

:root {
  --color-bg-charcoal: #101014;
  --color-overlay: rgba(5, 5, 8, 0.504); /* Controls Overly of images on Front page*/
  --color-text-main: #c2bebe;
  --color-text-muted: #c5c5c5;

  --font-heading: "Literata", serif;
  --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;

  --layout-max-width: 1120px;
  --spacing-page: 2.5rem;
  
  /* Hamburger Drop-Down Menu Controls */
  --menu-offset-x: 2rem;   /* horizontal distance from burger */
  --menu-offset-y: -0.45rem; /* vertical distance below burger */
  --menu-overlay-bg: rgba(6, 6, 7, 0.541); /* 0.85 = 85% opacity */

  --burger-width: 33px;   /* default 22px → now bigger */
  --burger-height: 4px;   /* thicker lines */
  --burger-gap: 3.3px;      /* spacing between lines */

  /* Hero Stuff & Front Page Controls */
  --logo-opacity: 0.6;
  --title-opacity: 0.9;
  --subtitle-opacity: 0.7;
  --hero-height-offset: 6rem; /* adjust up/down here */

  --subtitle-font-size: 2.2rem; /* you can change this later */

  --title-nudge: -80px;  /* positive = move right, negative = move left */

  --title-subtitle-gap: -0.1rem;  /* adjust freely */

  --hero-image-opacity: 0.9;  /* 0 = invisible, 1 = full strength */

  /* INSTAGRAM Logo */
  --ig-opacity: 1;      /* INSTAGRAM Logo Opacity: 1 = fully visible, 0.5 = half transparent */
  --ig-saturation: 0.5; /* INSTAGRAM Logo Saturration: 1 = normal, 2 = double saturation, 0.5 = muted */
  --ig-offset-x: 1vw;   /* INSTAGRAM Logo Position: move left/right */
  --ig-offset-y: 0px;   /* INSTAGRAM Logo Position: move up/down */

  /* TEMP DEV TOOLS*/
  --debug-grid-color: rgba(255, 255, 0, 0.15); /* soft yellow lines */
  --debug-grid-size: 80px;                     /* grid cell size */

}

/* =========================================
   DEBUG GRID OVERLAY (DEV ONLY)
========================================= */

body.show-grid::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
  background-image:
    linear-gradient(
      to right,
      var(--debug-grid-color) 1px,
      transparent 1px
    ),
    linear-gradient(
      to bottom,
      var(--debug-grid-color) 1px,
      transparent 1px
    );
  background-size: var(--debug-grid-size) var(--debug-grid-size);
}

/* Responsive adjustments for IG logo position */
@media (max-width: 768px) {
  :root {
    --ig-offset-x: 2vw;
  }
}

@media (min-width: 1600px) {
  :root {
    --ig-offset-x: 0.75vw;
  }
}

body.theme--charcoal {
  margin: 0;
  padding: 0;
  background-color: var(--color-bg-charcoal);
  color: var(--color-text-main);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

/* =========================================
   BACKGROUND SLIDESHOW
========================================= */

.hero-slideshow {
  position: fixed;
  inset: 0;
  overflow: hidden;
  z-index: -2;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transition: opacity 1.2s ease-in-out;
}

.hero-bg.is-active {
  opacity: var(--hero-image-opacity);
}

.hero-overlay {
  position: fixed;
  inset: 0;
  background: var(--color-overlay);
  z-index: -1;
}

/* =========================================
   DROPDOWN NAV PANEL (FRONT PAGE)
========================================= */

.site-nav-panel {
  position: absolute;
  top: 100%;                           /* just below the header */
  right: var(--menu-offset-x);
  margin-top: var(--menu-offset-y);  
  display: none;
  background: var(--menu-overlay-bg);  /* controlled in :root */
  border-radius: 8px;
  padding: 0.75rem 1.25rem;
  box-shadow: 0 18px 30px rgba(0, 0, 0, 0.6);
  z-index: 10;

   /* animation bits */
  opacity: 0;
  transform: translateY(-6px);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.site-nav-panel__inner {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  text-align: left;
}

.site-nav-panel a {
  color: var(--color-text-main);
  text-decoration: none;
  font-size: 0.98rem;
  opacity: 0.85;
  white-space: nowrap;
  transition: opacity 0.15s ease-out;
}

.site-nav-panel a:hover {
  opacity: 1;
}

/* When nav is open, show dropdown panel */
body.nav-open .site-nav-panel {
  display: block;
  opacity: 1;
  transform: translateY(0);
}

/* =========================================
   HEADER & NAVIGATION
========================================= */

.site-header {
  position: relative;
  z-index: 2;
  padding: 1.25rem var(--spacing-page) 0.75rem;
}

.site-header__inner {
  max-width: var(--layout-max-width);
  width: 100%;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
}

.site-logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
  top: var(--ig-offset-y);
  left: var(--ig-offset-x);
}

/* Front page: hamburger only, no desktop menu */
.home-page .site-nav--desktop {
  display: none;
}

.home-page .site-nav__toggle {
  display: inline-flex;  /* show hamburger even on desktop */
}

/* INSTAGRAM LOGO */

.site-logo svg {
  width: 2.2vw;   /* 2.2% of the viewport width */
  height: auto;
  opacity: var(--ig-opacity);
  transition: opacity 0.2s ease-out;
  fill: none;
  stroke: var(--color-text-main);
  stroke-width: 1.4;
  filter: saturate(var(--ig-saturation));
  transition: opacity 0.2s ease-out;
}

.site-logo:hover svg {
  opacity: 0.85;
}

.site-nav--desktop {
  display: flex;
  gap: 1.75rem;
}

.site-nav--desktop a {
  color: var(--color-text-main);
  text-decoration: none;
  position: relative;
}

/* underline hover */
.site-nav--desktop a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -0.2rem;
  width: 0;
  height: 1px;
  background-color: var(--color-text-main);
  transition: width 0.2s ease-out;
}

.site-nav--desktop a:hover::after {
  width: 100%;
}

/* Hamburger button */
.site-nav__toggle {
  display: none;                /* default: hidden on desktop (non-home pages) */
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.75;
  margin: 0;
  outline: none;

  /* stack lines vertically when visible */
  display: none;
  align-items: center;
  justify-content: center;
  flex-direction: column;
}

/* The three lines */
.site-nav__toggle span {
  display: block;
  width: var(--burger-width);
  height: var(--burger-height);
  margin: var(--burger-gap) 0;
  background-color: var(--color-text-main);
  border-radius: 2px; /* optional: cleaner look */
}

.site-nav__toggle:hover span {
  opacity: 0.8;
}

.site-header__instagram {
  margin-left: 1.5rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.site-header__instagram svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: var(--color-text-main);
  stroke-width: 1.4;
}

.site-header__instagram:hover svg {
  opacity: 0.85;
}

/* ---------- NAVIGATION POLISH ---------- */

.site-nav--desktop a {
  opacity: 0.75;
  transition: opacity 0.2s ease-out;
}

.site-nav--desktop a:hover {
  opacity: 1;
}

.site-nav--desktop .is-active {
  font-weight: 600;
  opacity: 1;
}

/* =========================================
   HERO (FRONT PAGE)
========================================= */

.hero {
  position: relative;
  z-index: 1;
  min-height: calc(100vh - var(--hero-height-offset));  display: flex;
  flex-direction: column;
  justify-content: center;          /* center hero__content vertically */
  align-items: center;              /* center horizontally */
  padding: 1.5rem var(--spacing-page) 1rem;
}

.hero__content {
  max-width: var(--layout-max-width);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  justify-content: center; /* helps vertical centering */
}

.hero__titles {
  max-width: 640px;
  text-align: center;
}

.hero__title {
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 2.8rem;
  margin: 0 0 var(--title-subtitle-gap);  white-space: nowrap;
  opacity: 0; /* start invisible */
  animation: heroTitleIn 0.9s ease-out forwards;
  animation-delay: 0.35s;
}

.hero__subtitle {
  font-size: var(--subtitle-font-size);;
  color: var(--color-text-muted);
  margin: 0;
  opacity: 0; /* start invisible */
  animation: heroSubtitleIn 0.9s ease-out forwards;
  animation-delay: 0.5s;
}

.hero__logo {
  margin-bottom: 1.2rem;
  opacity: 0;
  transform: translateY(-80px); /* start above the viewport */
  animation: heroLogoDrop 0.9s ease-out forwards;
  animation-delay: 0.1s; /* logo appears slightly before the title */
}

.hero__logo img {
  width: 11vw;
  max-width: 210px;
  height: auto;
  display: block;
}

.hero__content {
  max-width: var(--layout-max-width);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  justify-content: center; /* helps vertical centering */
}

.hero__titles {
  max-width: 640px;
  text-align: center;
  margin: 0 auto;        /* explicit horizontal centering */
}

/* ---------- HERO ANIMATIONS ---------- */

@keyframes heroSlideIn {
  from {
    opacity: 0;
    transform: translateX(100vw);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes heroTitleIn {
  0% {
    opacity: 0;
    transform: translateX(100vw);
  }
  100% {
    opacity: var(--title-opacity);
    transform: translateX(var(--title-nudge));  /* final resting offset */;
  }
}

@keyframes heroSubtitleIn {
  0% {
    opacity: 0;
    transform: translateX(100vw);
  }
  100% {
    opacity: var(--subtitle-opacity);
    transform: translateX(0);
  }
}

@keyframes heroLogoDrop {
  from {
    opacity: 0;
    transform: translateY(-80px);
  }
  to {
    opacity: var(--logo-opacity);
    transform: translateY(0);
  }
}

/* =========================================
   FOOTER
========================================= */

.site-footer {
  position: relative;
  z-index: 2;
  padding: 1.5rem var(--spacing-page) 2rem;
}

.site-footer__inner {
  max-width: var(--layout-max-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center; /* center the credit */
  font-size: 0.85rem;
}

.site-footer__credit {
  font-family: "Literata", serif;   /* different font */
  letter-spacing: 0.12em;
  text-transform: lowercase;
  color: var(--color-text-muted);
  text-decoration: none;
}

.site-footer__credit:hover {
  color: var(--color-text-main);
}

/* =========================================
   GENERIC PAGE LAYOUT
========================================= */

.page {
  position: relative;
  z-index: 1;
  padding: 4rem var(--spacing-page) 3rem;
  min-height: calc(100vh - 6rem);
}

.page__inner {
  max-width: var(--layout-max-width);
  margin: 0 auto;
}

.page-header {
  margin-bottom: 2.5rem;
}

.page-title {
  font-family: var(--font-heading);
  font-weight: 500;
  font-size: 2.1rem;
  margin: 0 0 0.4rem;
}

.page-intro {
  margin: 0;
  color: var(--color-text-muted);
  font-size: 0.98rem;
}

/* =========================================
   MEMBERS GRID (LIST PAGE)
========================================= */

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

.member-card {
  background: rgba(10, 10, 14, 0.85);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.35);
}

.member-card__link {
  color: inherit;
  text-decoration: none;
  display: block;
  height: 100%;
}

.member-card__image img {
  display: block;
  width: 100%;
  height: 220px;
  object-fit: cover;
}

.member-card__body {
  padding: 1rem 1.2rem 1.3rem;
}

.member-card__name {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  margin: 0 0 0.2rem;
}

.member-card__role {
  margin: 0;
  font-size: 0.9rem;
  color: var(--color-text-muted);
}

.member-card:hover {
  transform: translateY(-3px);
  transition: transform 0.18s ease-out;
}

/* =========================================
   MEMBER DETAIL PAGE
========================================= */

.breadcrumb {
  font-size: 0.85rem;
  color: var(--color-text-muted);
  margin-bottom: 1.5rem;
}

.breadcrumb a {
  color: var(--color-text-muted);
  text-decoration: none;
}

.breadcrumb a:hover {
  color: var(--color-text-main);
}

.breadcrumb span {
  margin: 0 0.25rem;
}

.member-detail {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 2.5rem;
  align-items: flex-start;
}

.member-detail__image img {
  width: 100%;
  border-radius: 8px;
  display: block;
  object-fit: cover;
}

.member-detail__name {
  font-family: var(--font-heading);
  font-weight: 500;
  font-size: 2.2rem;
  margin: 0 0 0.3rem;
}

.member-detail__role {
  margin: 0 0 1.2rem;
  font-size: 0.98rem;
  color: var(--color-text-muted);
}

.member-detail__bio {
  margin: 0 0 1.5rem;
  font-size: 0.98rem;
}

.member-detail__meta {
  margin: 0;
  padding: 0;
}

.member-detail__meta div {
  margin-bottom: 0.6rem;
}

.member-detail__meta dt {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-text-muted);
}

.member-detail__meta dd {
  margin: 0.1rem 0 0;
}

/* =========================================
   CONTACT PAGE
========================================= */

.contact-layout {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2rem;
}

.contact-block h2 {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  margin-bottom: 0.4rem;
}

/* =========================================
   GALLERY PAGE
========================================= */

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

.gallery-item__thumb img {
  display: block;
  width: 100%;
  height: 220px;
  object-fit: cover;
  border-radius: 6px;
}

.gallery-item figcaption {
  margin-top: 0.4rem;
  font-size: 0.85rem;
  color: var(--color-text-muted);
}

/* =========================================
   RESPONSIVE OVERRIDES
========================================= */

/* Header / hero / nav */
@media (max-width: 768px) {
  .site-nav--desktop {
    display: none;
  }

  .site-nav__toggle {
    display: block;
  }

  /* When nav is open, show dropdown */
  .site-header.nav-open .site-nav--desktop {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 100%;
    right: var(--spacing-page);
    left: var(--spacing-page);
    padding: 0.75rem 1rem;
    margin-top: 0.5rem;
    background: rgba(10, 10, 14, 0.96);
    border-radius: 8px;
    box-shadow: 0 18px 30px rgba(0, 0, 0, 0.5);
    gap: 0.5rem;
  }

  .site-header.nav-open .site-nav--desktop a {
    padding: 0.25rem 0;
  }

  .hero__title {
    font-size: 2.1rem;
    white-space: normal; /* allow wrapping on smaller screens */
  }
}

@media (max-width: 480px) {
  :root {
    --spacing-page: 1.5rem;
  }

  .hero__title {
    font-size: 1.8rem;
  }
}

/* Members list & member detail */
@media (max-width: 900px) {
  .members-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .member-detail {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .members-grid {
    grid-template-columns: 1fr;
  }

  .page {
    padding-top: 3rem;
  }
}

/* Contact layout */
@media (max-width: 800px) {
  .contact-layout {
    grid-template-columns: 1fr;
  }
}

/* Gallery layout */
@media (max-width: 900px) {
  .gallery-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  .gallery-grid {
    grid-template-columns: 1fr;
  }
}