/* ==========================================================================
   Font Setup
   ========================================================================== */
@font-face {
  font-family: 'Forum';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('./fonts/forum-custom.woff2') format('woff2');
}

/* ==========================================================================
   Global Styles
   ========================================================================== */

:root {
  --timeline-left: 120px; /* Distance from left for the line */
}

body {
  background-color: #12121a;
  color: #ffecd6;
}

/* Prevent background scrolling when mobile menu is active */
body.no-scroll {
  overflow: hidden;
}

hr {
  color: #4e204c;
  border: 1px solid #4e204c;
}

h1 {
  text-align: center;
}

a {
  color: #ffbd61;
}

a:visited {
  color: #fca23c;
}


/* ==========================================================================
   Global - Navigation
   ========================================================================== */

.navigation, h1, h2, h3 {
  font-family: "Forum", serif;
}

.navigation {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  padding-left: 20px;
  padding-right: 20px;
  margin-bottom: 8px;
  position: relative; /* FIX: Allows z-index to take effect */
  z-index: 100;       /* Pushes nav above background content/grids */
}

.navigation-name {
  flex: 1 0 50%;
  z-index: 101;       /* Keeps logo above the mobile overlay */
  letter-spacing: 2px;
}

.navigation-name a, .navigation-name a:visited {
  text-decoration: none;
  color: #ffbd61;
  /* color: #50dce8; */
}

.navigation-name a:hover {
  color: #fca23c;
  /* color: #56DCC6; */
}

#navigation-links a,
#navigation-links a:visited {
  color: #50dce8;
}

#navigation-links a:hover {
  color: #56DCC6;
}

.navigation-right {
  display: flex; 
  align-items: center;
  justify-content: right;
  flex: 1 0 50%;
  column-gap: 20px;
  font-size: 20px;
}

/* Hide hamburger button on desktop screens */
.menu-toggle {
  display: none;
}

/* Asyas request for some reason */
/* Ensure the main link acts as a block-like container for its children */
.navigation-name a {
  display: inline-flex;
  flex-direction: column;
  position: relative;
}

/* Create the thin line separator and the English name underneath */
.navigation-name a::after {
  /* \A0 is a non-breaking space used to inject content; then we supply the text */
  content: "Borislav Dochev";
  
  /* Typography rules requested by your teacher */
  font-style: italic;
  font-size: 23px; /* Scales down smoothly relative to the main font size */
  font-weight: bold;
  letter-spacing: 4px;
  margin-top: 6px;
  padding-top: 6px;
  
  /* Inherit colors or blend them nicely */
  color: inherit; 
  opacity: 0.85; /* Softens the English text slightly so it doesn't fight the main title */
  
  /* The Line Separator: Formatted as a top border on this pseudo-element */
  border-top: 2px solid rgba(255, 189, 97, 0.4); /* Uses a semi-transparent version of your gold #ffbd61 */
  
  /* Alignment rules */
  text-align: center;
  line-height: 1.2;
}

/* ==========================================================================
   Main Page - Before/After Image Slider
   ========================================================================== */

#gallery-main-page {
  min-height: 500px;
}

/* Container setup */
.image-slider {
  position: relative;
  width: 45vw;
  max-width: 800px;
  margin: 0 auto 2rem;
  overflow: hidden;
  border-radius: 8px; /* Optional: gives it nice rounded corners */
  --position: 50%; /* Default starting position */
}

/* Make both images fill the container perfectly */
.image-slider img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
}

/* Position the "Before" image directly over the "After" image */
.image-after {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  /* This crops the image based on the --position variable */
  clip-path: polygon(0 0, var(--position) 0, var(--position) 100%, 0 100%);
}

/* The invisible native range input that handles dragging/touch automatically */
.slider-input {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0; /* Make it invisible */
  cursor: ew-resize; /* Show drag cursor */
  z-index: 10;
  margin: 0;
}

.slider-line {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--position);
  width: 1px; /* Thinner line */
  background: rgba(255, 255, 255, 0.7); /* Semi-transparent */
  transform: translateX(-50%);
  pointer-events: none;
  z-index: 5;
}

.slider-button {
  position: absolute;
  top: 50%;
  left: var(--position);
  transform: translate(-50%, -50%);
  
  /* Sizing it down */
  width: 40px; 
  height: 40px;
  
  /* Glass effect */
  background: rgba(255, 255, 255, 0.2); 
  backdrop-filter: blur(4px); /* Blurs the image behind the button */
  border: 1px solid rgba(255, 255, 255, 0.5);
  
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  pointer-events: none;
  z-index: 6;
  box-shadow: 0 4px 15px rgba(0,0,0,0.2);
  color: white;
}

/* Make the arrows smaller too */
.slider-button svg {
  width: 14px;
  height: 14px;
}

.label-before, 
.label-after {
  position: absolute;
  top: 15px;
  padding: 6px 12px;
  background: rgba(0, 0, 0, 0.6); /* Semi-transparent dark background */
  color: white;
  font-family: sans-serif;
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  border-radius: 4px;
  
  /* CRITICAL: This prevents the labels from blocking the invisible slider input */
  pointer-events: none; 
  
  /* Puts them above the images but below the slider input */
  z-index: 4; 
}

/* Pin them to their respective corners */
.label-before {
  right: 15px;
}

.label-after {
  left: 15px;
}


/* ==========================================================================
   Main Page - Gallery
   ========================================================================== */

#gallery {
  margin: 20px;
  margin-bottom: unset;
}

.gallery {
  margin-top: 3rem;
}

.heading {
  font-family: "Forum", serif;
  font-weight: bold;
  font-size: 2.2rem;
}

/* Makes sure that the image is scaled in such a way so that the watermark is visible in the bottom right */
.imgCurrent, .nGY2ViewerMediaPan {
  scale: 0.9;
}

/* Prevent page jiggle (Commented out in original build) */
/* default / MD+ */
/* #gallery {
  min-height: 520px;
}  */

/* SM (>=576px && <768px) — same as default, kept for clarity */
/* @media (min-width: 576px) and (max-width: 767.98px) {
  #gallery { min-height: 720px; }
} */

/* XS (mobile) */
/* @media (max-width: 500px) {
  #gallery { min-height: 800px; }
} */


/* ==========================================================================
   Main Page - Video Projects Timeline
   ========================================================================== */

#video-projects {
  padding: 40px;
  padding-top: 0px;
  font-family: sans-serif;
}

.timeline-container {
  position: relative;
  max-width: 1100px;
  margin: 0 auto;
}

/* The Vertical Line */
.timeline-line {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--timeline-left);
  width: 2px;
  background: #3b1139;
  z-index: 1;
  transform: translateX(-50%);
}

.timeline-item {
  position: relative;
  margin-bottom: 50px;
}

/* --- THE MAGIC ALIGNMENT CONTAINER --- */
.item-header {
  display: flex;
  align-items: center; /* Vertically centers the date, dot, and title */
  margin-bottom: 20px;
  position: relative;
}

.timeline-date {
  box-sizing: border-box; /* CRITICAL: Keeps width strict so it doesn't cross the line */
  width: var(--timeline-left);
  padding-right: 35px; 
  text-align: right;
  font-weight: bold;
  font-size: 1.2rem;
  color: #ffecd6cc;
  position: relative;
  font-family: 'Forum';
  transform: translateX(20px); /* left of dot → slide left */
}

/* The Horizontal Connecting Line */
.timeline-date::after {
  content: '';
  position: absolute;
  right: 12px; /* This is the end point near the dot */
  top: 50%;
  transform: translateY(-50%);
  width: 18px; /* Slightly increased the width to make the fade more noticeable */
  height: 2px;
  /* Fades from 50% white to 0% white (transparent) */
  background: linear-gradient(to right, rgba(255, 255, 255, 0.5), transparent);
}

/* Your Glass Dot */
.marker-circle {
  position: absolute;
  left: var(--timeline-left);
  transform: translateX(-50%); 
  width: 24px;
  height: 24px;
  background: rgba(255, 255, 255, 0.1); 
  backdrop-filter: blur(4px);
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 50%;
  z-index: 2;
  box-shadow: 0 0 15px rgba(255,255,255,0.1);
}

.project-title {
  margin: 0;
  padding-left: 25px; /* Pushes the title to the right of the dot */
  color: #50dce8;
  font-size: 1.5rem;
  letter-spacing: 1px;
  transform: translateX(-20px); /* right of dot → slide right */
}

/* --- CONTENT STYLES --- */
.item-content {
  display: flex;
  gap: 30px;
  align-items: flex-start;
  flex-wrap: wrap;
  padding-left: calc(var(--timeline-left) + 25px);
}

.video-box {
  flex: 0 0 50%;
  min-width: 300px;
  transform: translateX(-30px); /* right of line → slide right */
}

.video-box iframe {
  width: 100%;
  aspect-ratio: 16 / 9;
  border: none;
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

.description-box {
  flex: 1;
  font-size: 1.05rem;
  line-height: 1.6;
  background: #211735;
  padding: 20px 25px;
  border-radius: 8px;
  /* border-left: 3px solid rgba(255, 255, 255, 0.3); */
  transform: translateX(-60px); /* further right → slide right with stagger */
}

/* All elements start hidden */
.timeline-date,
.project-title,
.video-box,
.description-box {
  opacity: 0;
  position: relative;
  transition: transform 0.6s ease-in-out, opacity 0.6s ease-out;
}

/* In-view states triggered by Scroll/IntersectionObserver */
.in-view-date  { opacity: 1; transform: translateX(0); }
.in-view-title { opacity: 1; transform: translateX(0); }
.in-view-video { opacity: 1; transform: translateX(0); }
.in-view-desc  { opacity: 1; transform: translateX(0); }


/* ==========================================================================
   Events Page - Grid and Cards Layout
   ========================================================================== */

.event-title {
  text-align: center;
}

.events-cards-container {
  display: flex;
  flex-wrap: wrap;
  column-gap: 20px;
  row-gap: 20px;
  justify-content: center;
}

.events-card-vertical {
  background-color: #2b105066;
  border-radius: 8px;
  max-width: 420px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all 0.2s ease-in-out;
}

.events-card-vertical .events-image {
  overflow: hidden; 
  width: 100%;
  height: 220px;
}

.events-card-vertical .events-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.2s ease-in-out; 
}

.events-card-vertical .events-body {
  padding: 20px;
}

.events-card-vertical .events-title {
  font-family: 'Forum', serif;
  font-weight: bold;
  font-size: 24px;
  line-height: 1.2;
  margin-bottom: 5px;
}

.events-card-vertical .events-title a {
  text-decoration: none;
}

.events-card-vertical .events-date {
  font-family: 'Forum', serif;
  font-size: 14px;
  color: #ffecd6b5;
  margin-bottom: 15px;
}

.events-card-vertical .events-description {
  font-family: sans-serif;
  font-size: 15px;
  line-height: 1.5;
}

.events-card-vertical:hover {
  transform: translateY(-2px);
  background-color: #3a166c8d;
}
.events-card-vertical:hover .events-image img {
  transform: scale(1.05);
}

h2.events-date {
  text-align: center;
}
/* ==========================================================================
  People Page - Cards Layout
  ========================================================================== */

.people-cards-container {
  display: flex;
  flex-wrap: wrap;
  column-gap: 20px;
  row-gap: 20px;
  justify-content: space-evenly;
  padding: 20px; /* Adjust based on your overall layout */
}

.person-card {
  position: relative; /* Crucial for absolute positioning the text inside */
  display: block;
  width: 100%;
  max-width: 280px; /* Slightly narrower than event cards to emphasize portrait feel */
  aspect-ratio: 3 / 4; /* Forces uniform shape for ALL images */
  border-radius: 8px;
  overflow: hidden;
  text-decoration: none;
  transition: transform 0.2s ease-in-out;
}

.person-card .person-image {
  width: 100%;
  height: 100%;
  object-fit: cover; /* Crops both landscape and portrait to fill the box */
  display: block;
  transition: transform 0.3s ease-in-out;
}

/* Hover effects */
.person-card:hover {
  transform: translateY(-4px);
}

.person-card:hover .person-image {
  transform: scale(1.05); /* Subtle zoom on the photo, similar to your events */
}

.person-card:hover .person-name {
  color: #50dce8;
  transition: color 0.2s ease-in-out;
}

/* The text overlay */
.person-card .person-info {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 40px 20px 20px; /* Larger top padding to stretch the gradient fade upward */
  background: linear-gradient(to top, #12121a 0%, rgba(43, 16, 80, 0) 100%);
}

.person-card .person-name {
  font-family: 'Forum', serif;
  font-weight: bold;
  font-size: 24px;
  line-height: 1.2;
  margin: 0;
  color: #ffecd6;
  text-shadow: 1px 1px 3px #12121a,
               2px 2px 4px #12121a;
}

/* =================================
    Individual performers styling
   ================================= */
.angelina-popova-gallery #gallery {
  width: 100%;
  max-width: 1000px;
  margin: 0 auto;
  min-height: 360px;
}

.single-picture-gallery {
  display: flex;
  justify-content: center;
  width: 100%;
}

@media screen and (max-width: 880px) {
  .angelina-popova-gallery #gallery {
    min-height: 300px;
  }
}

/* ==========================================================================
   Performances Subpage (2026_05_15) - Video Grid & Tag Pillars
   ========================================================================== */

/* Container for the whole video section */
.performances-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-evenly;
  gap: 25px;
  margin-top: 20px;
}

/* Individual Video Card */
.video-card {
  flex: 1 1 480px; 
  max-width: 500px;
  min-width: 350px;
  
  background-color: #2b105066;
  border-radius: 8px;
  overflow: hidden;
  
  /* This keeps the content aligned to the top */
  display: flex;
  flex-direction: column;
}

/* Responsive Iframe Wrapper */
.video-wrapper {
  width: 100%;
  aspect-ratio: 16 / 9;
  background-color: #000; /* Placeholder while video loads */
}

.video-wrapper iframe {
  width: 100%;
  height: 100%;
  border: none;
}

/* Info Section under the video */
.video-info {
  padding: 15px;
  display: flex;
  flex-direction: column;
  flex-grow: 1; /* Absorbs the extra space in the card */
  
  /* This ensures the TITLE stays at the top of this section */
  justify-content: flex-start; 
}

.video-title {
  font-family: 'Forum', serif;
  font-size: 22px;
  text-align: center;
  color: #ffecd6;
  margin: 0 0 10px 0;
}

/* The Tag System */
.performer-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  flex-grow: 1;
  align-items: center;
  justify-content: center;
}

.tag {
  display: flex;
  align-items: center;
  background-color: #1a0833; /* Darker contrast against the card */
  color: #ffbd61b5;
  padding: 4px 8px;
  border-radius: 20px; /* Gives the pill shape */
  font-family: sans-serif;
  font-size: 13px;
  border: 1px solid #ffecd640; /* Subtle border for definition */
  transition: all 0.2s ease;
}

.tag:hover {
  background-color: #ffecd6b5;
  color: #1a0833;
  border-color: #ffecd6b5;
}

.icon {
  display: inline-block;
  width: 16px;
  height: 16px;
  margin-right: 8px;
  background-size: contain;
  background-repeat: no-repeat;
  filter: invert(88%) sepia(31%) saturate(471%) hue-rotate(311deg) brightness(109%) contrast(103%);
}

.icon-mic { background-image: url('../images/icons/mic-vocal.svg'); }
.icon-guitar { background-image: url('../images/icons/guitar.svg'); }
.icon-drum { background-image: url('../images/icons/drum.svg'); }
.icon-piano { background-image: url('../images/icons/piano.svg'); }

/* additional styling for when the song was played */
/* Styling for the event link */
.video-event-link {
  font-family: sans-serif;
  font-size: 13px;
  text-align: center;
  color: #ffecd680;
  text-decoration: none;
  margin-bottom: 12px;
  display: inline-block;
  transition: color 0.2s ease;
}

.video-event-link:visited {
  color: #ffecd680;
}

.video-event-link span {
  color: #ffecd6b5;
  border-bottom: 1px dotted #ffecd6b5;
  transition: all 0.2s ease;
}

.video-event-link:hover span {
  color: #ffbd61b5;
  border-bottom-color: #ffbd61b5;
}

/* ==========================================================================
   404 Page Styling
   ========================================================================== */

.error-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-height: 70vh;
  padding: 20px;
}

.error-code {
  font-family: 'Forum', serif;
  font-size: 6rem;
  margin: 0;
  color: #50dce8;
  line-height: 1;
}

.error-message {
  font-family: sans-serif;
  font-size: 1.2rem;
  color: #ffecd6b5;
  margin-top: 10px;
  margin-bottom: 30px;
}

.error-image {
  max-width: 400px;
  width: 100%;
  margin-bottom: 30px;
  border-radius: 8px;
  overflow: hidden;
}

.error-image img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.2s ease-in-out;
}

.error-image:hover img {
  transform: scale(1.05);
}

.btn-back {
  font-family: 'Forum', serif;
  font-size: 1.1rem;
  color: #12121a;
  background-color: #ffbd61;
  text-decoration: none;
  padding: 12px 28px;
  border-radius: 4px;
  font-weight: bold;
  transition: all 0.2s ease-in-out;
}

a.btn-back:visited {
  color: #12121a;
}

.btn-back:hover {
  background-color: #50dce8;
}

/* ==========================================================================
   Person Profile Page
   ========================================================================== */

.person-page-title {
  /* Inherits 'Forum' font-family from your global h1/h2/h3 rules */
  font-size: 3.5rem; /* Increased size for the person's name */
  text-align: center;
  margin-top: 40px;
  margin-bottom: 20px;
  color: #ffecd6;
}

.person-description-container {
  max-width: 800px;
  margin-top: 20px;
  margin-bottom: 30px;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
  padding: 0 20px;
}

.person-description-text {
  font-family: sans-serif;
  font-size: 1.1rem;
  line-height: 1.6;
  color: #ffecd6b5;
}

/* Aligns the role icons nicely with the description text */
.person-description-text .icon {
  vertical-align: text-bottom;
  margin-left: 4px;
  margin-right: 0;
}

.person-divider {
  margin-top: 3.4rem;
  margin-bottom: 3rem;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
}

.person-performances-section {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px 40px;
}

.person-section-title {
  font-family: 'Forum', serif;
  font-size: 28px;
  text-align: center;
  margin-bottom: 30px;
}

/* ==========================================================================
   Responsive Media Queries
   ========================================================================== */

/* Tablet Viewports (Up to 1000px wide) */
@media screen and (max-width: 1000px) {
  .events-cards-container {
    justify-content: space-around;
  }
  h2.events-date {
    text-align: center;
  }
  .image-slider {
    width: 70vw;
  }
  .gallery {
    margin-top: unset;
  }
}

/* Mobile Timeline Adjustments (Up to 990px wide) */
@media screen and (max-width: 990px) {
  :root {
    --timeline-left: 10px; /* Move line closer to left edge */
  }

  #video-projects {
    padding: 20px;
    padding-top: 0px;
  }

  .timeline-line {
    left: var(--timeline-left);
  }

  .item-header {
    flex-direction: column; /* Stack Date and Title vertically */
    align-items: flex-start;
    padding-left: calc(var(--timeline-left) + 25px);
    margin-bottom: 15px;
  }

  .timeline-date {
    width: auto;
    text-align: left;
    padding-right: 0;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.5);
    margin-bottom: 4px;
  }

  .timeline-date::after {
    display: none; /* Hide horizontal connecting line on mobile */
  }

  .marker-circle {
    left: var(--timeline-left);
    top: 10px;
    transform: translateX(-50%);
  }

  .project-title {
    padding-left: 0;
    font-size: 1.25rem;
  }

  .item-content {
    flex-direction: column; /* Stack Video and Description */
    padding-left: calc(var(--timeline-left) + 25px);
    gap: 20px;
  }

  .video-box {
    flex: 1 1 100%;
    width: 100%;
    min-width: unset;
  }

  .description-box {
    width: 100%;
    box-sizing: border-box;
    font-size: 0.95rem;
    padding: 15px;
  }
}

/* Intermediate Mobile/Tablet Transitions (Up to 800px wide) */
@media screen and (max-width: 800px) {
  .image-slider {
    width: 80vw;
  }
}

/* Full-Screen Overlay Mobile Navigation (Up to 600px wide) */
@media screen and (max-width: 600px) {
  .navigation-name {
    flex: 1;
  }

  /* Hamburger Button Styling */
  .menu-toggle {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 21px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 101;
  }

  .hamburger-bar {
    width: 100%;
    height: 3px;
    background-color: #ffecd6;
    border-radius: 2px;
    transition: all 0.3s ease-in-out;
  }

  /* Animate hamburger to 'X' when open */
  .navigation.is-open .hamburger-bar:nth-child(1) {
    transform: translateY(9px) translateX(-4px) rotate(45deg);
    background-color: #50dce8;
    width: 125%;
  }
  .navigation.is-open .hamburger-bar:nth-child(2) {
    opacity: 0;
    width: 0%;
  }
  .navigation.is-open .hamburger-bar:nth-child(3) {
    transform: translateY(-9px) translateX(-4px) rotate(-45deg);
    background-color: #50dce8;
    width: 125%;
  }

  /* Turn links container into full-screen overlay */
  .navigation-right {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: #12121a;
    background-image: linear-gradient(180deg, #12121a 0%, #1c0b3a 100%);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    font-size: 25px;
    row-gap: 30px;
    
    /* Animation & Accessibility state */
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.3s ease, visibility 0.3s ease;
  }

  /* Active State for Mobile Overlay */
  .navigation.is-open .navigation-right {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }
}

/* Small Smartphone Optimization (Up to 540px wide) */
@media screen and (max-width: 540px) {
  .navigation-name {
    font-size: 28px;
  }
}
