:root {
  --bottom-spacing: 9.5vh;
  --font-base: 'Space Mono', monospace;
  --font-accent: "Test Signifier", 'Space Mono', monospace ;
  --font-size-title: 4rem;
  --font-size-subtitle: 2.5rem;
  --font-size-body: 1rem;
  --font-size-label: 1rem;
  --background-color: black;
  --content-primary-color: white;
}

body, html {
  margin: 0;
  padding: 0;
  background-color: var(--background-color);
  font-family: var(--font-base);
  scroll-behavior: smooth;
}

.hero {
  position: relative;
  height: 100vh;
  overflow: hidden;
}


.city-info {
    position: absolute;
    top: 20px;
    color: var(--content-primary-color);
    font-family: var(--font-base);
    background-color: var(--background-color);
    padding: 12px 16px;
    border-radius: 8px;
    font-size: var(--font-size-label);
    line-height: 65%;
    z-index: 10;
  }
  
  .city-info.left {
    left: 20px;
  }
  
  .city-info.right {
    right: 20px;
  }  

canvas#circleCanvas {
 position: absolute;
  top: 0;
  left: 0;
  z-index: 1000; /* Higher than icons */
  width: 100%;
  height: 100%;
  pointer-events: none;    /* So it doesn’t block button clicks */
}


.line {
    position: absolute;
    bottom: var(--bottom-spacing);  /* Adjust the vertical position of the line */
    left: 0;
    width: 100%;
    height: 1vh;
    background-color: var(--content-primary-color);
  }

.me-icon {
    position: absolute;
    bottom: calc(var(--bottom-spacing) + 1vh);        /* vertical spacing relative to screen height */
    left: 8vw;         /* horizontal spacing relative to screen width */
    height: 16vh;       /* dynamic height: 15% of viewport height */
    z-index: 2;
}

.moon-icon {
    position: fixed;
    bottom: 35vh;        /* vertical spacing relative to screen height */
    right: 9vw;         /* horizontal spacing relative to screen width */
    height: 15vh;       /* dynamic height: 15% of viewport height */
}

.moon-layer {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0; /* Behind everything else except background */
  pointer-events: none;
}
  
.view-btn {
  position: absolute;
  bottom: calc(var(--bottom-spacing) / 6);
  left: 50%;
  transform: translateX(-50%);
  z-index: 9999;

  white-space: nowrap;        /* Prevent text wrap */
  max-width: 90vw;            /* Max width: 90% of viewport width */
  padding: 0.5em 1.2em;       /* Adjust padding for better click area */
  box-sizing: border-box;     /* Include padding in width */
}

.nav-menu {
  position: sticky;
  top: 0;
  background-color: var(--background-color);
  
  z-index: 1000;
  padding-top: 2rem;
  padding-bottom: 2rem;
}

.nav-menu a {
  font-family: var(--font-accent);
  font-weight: 100;
  font-size: var(--font-size-subtitle);
  font-style: italic;

  text-decoration: none;
  color: var(--content-primary-color);
  font-weight: normal;
}

.nav-menu a:hover {
  font-weight: normal;
  text-decoration: none;
}

/* detail-section */
/* detail-section */
/* detail-section */

.detail-section {
  margin: 3rem 6rem; /* ~48px */
}

.content-container {
  display: flex;
  flex-direction: row;
  gap: 6rem;
  max-width: 100vw;
}

.text-column {
  flex: 1;
  max-height: none;
  max-width: 65vw;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.section-title{
  font-family: var(--font-accent);
  font-weight: 100;
  font-size: var(--font-size-title);
  font-style: italic;
  text-decoration: none;
  color: var(--content-primary-color);
  font-weight: normal;
  scroll-margin-top: 8rem;

  display: flex;
  justify-content: flex-end;
  align-items: center;
  position: relative;
}

.section-title::before {
  content: "";
  flex: 1;
  height: .25rem;
  background-color: var(--content-primary-color);
  margin-right: 1rem; /* spacing between line and text */
}


.scroll-anchor {
  position: relative;
  top: -6rem; /* Adjust based on your .nav-menu height */
  height: 0;
}


.media-column {
  display: block;
  flex: 1;
  max-width: 35vw;
  position: sticky;
  top: 5rem;
  align-self: flex-start;
  max-height: none;
}

.media-display {
  display: none;
  flex-direction: column;
  gap: 0rem;
}

.media-display.active {
  display: flex;
  flex-direction: column;
  gap: 0rem;
}

.media-display img {
  width: 100%;
  height: auto;
  border-radius: 8px;
}

.media-display p {
  color: var(--content-primary-color); 
  font-size: 1rem;
  margin: 0.5rem 0 0;
  line-height: 1.4;
}

/* New: ensure each inline media appears under item on mobile */
.media-display.inline {
  display: flex;
  flex-direction: column;
  gap: 0rem;
  margin-top: -1rem; /* pull it closer if needed */
}

/* Desktop */
/* Desktop */

@media (min-width: 769px) {
  .content-container {
    display: flex;
    height: auto;          /* ✅ allow content to grow */
    overflow: visible;     /* ✅ allow scrolling */
  }

  .text-column {
    flex: 1;
    overflow-y: auto;
    padding-right: 2rem;
    /* padding-top: rem; */
  }

  .media-column {
    flex: 1;
    position: sticky;
    top: 0rem; /* Adjust if needed based on nav height */
    align-self: flex-start;
    height: fit-content;
    /* padding-top: 8rem; */
  }
}


/* Mobile */
/* Mobile */

@media (max-width: 768px) {
  .content-container {
    flex-direction: column;
    margin-bottom: 6rem;
  }

  .detail-section {
  margin: 1rem 3rem; /* ~48px */
  }

  .text-column {
    width: 100%;
    max-width: 100%;
    z-index: 1;
  }

  .text-column .item {
    width: 100%;
    box-sizing: border-box;
  }


  .media-column {
    position: static;
  }

  .media-display {
    display: none;
  }

  .media-display.inline {
    display: flex;
    flex-direction: column;
    gap: 0rem;
    margin-top: 0rem;
  }

  .moon-icon {
    z-index: 0; /* Behind content */
  }

  .nav-menu a:not(:first-child) {
    display: none;
  }

  .city-info.right {
    display: none;
  }
}
