/* --- Overrides for Global Styles --- */
html, body {
  overflow: auto !important; /* This forces the scrollbar to appear, overriding layout-styles.css */
}

/* General Page Styles */
.page-wrapper {
  color: #E2E7EB; /* Parchment text color */
  font-family: 'Times New Roman', Times, serif;
  position: relative;
  box-sizing: border-box;
  border: 15px solid #000000;
  border-top: 0px;
  background-image: url('../images/BackgroundE.jpg'); /* New background image */
  background-size: cover;
  background-repeat: no-repeat;
  background-position: center top;
}

/* Title container */
.title-container {
    position: absolute;
    top: 10px; /* Brought title up */
    left: 0;
    right: 0;
    text-align: center;
    font-variant: small-caps;
    font-size: 1.8rem;
    z-index: 2;
    margin-bottom: 30px; /* Added space below title */
}

/* Main content area for extras */
.extras-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: start;
    position: relative;
    z-index: 1;
    padding: 160px 5% 20px 5%; /* Adjusted top padding */
    max-width: 1400px;
    margin: 0 auto;
}

/* Column wrappers */
.column-left, .column-right {
    display: flex;
    flex-direction: column;
    gap: 0; /* Let the section margin handle spacing */
}

.content-section {
    background-color: rgba(95, 65, 82, 0.8);
    border: 2px solid #000000;
    border-radius: 8px;
    padding: 10px;
    margin-bottom: 40px;
    text-align: center;
    box-shadow: 0 0 15px rgba(0,0,0,0.7);
}

.section-title {
    font-size: 1.8rem;
    font-variant: small-caps;
    margin-top: 0;
    margin-bottom: 10px;
    color: #E2E7EB;
}

.section-subtitle {
    font-style: italic;
    font-size: 1.1rem;
    margin-top: 0;
    margin-bottom: 25px;
    color: #E2E7EB;
}

/* Video container styling */
.video-container {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
    height: 0;
    overflow: hidden;
    margin-bottom: 15px;
    border: 1px solid #000000;
    box-shadow: 0 0 8px rgba(0,0,0,0.5);
}

.video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.video-caption {
    font-style: italic;
    font-size: 0.95rem;
    margin-top: 10px;
    color: #E2E7EB;
}

/* Video grid for "Reel Bits & Bites" */
.video-grid {
    display: grid;
    grid-template-columns: 1fr; /* Only one column of videos in this section */
    gap: 20px;
    margin-top: 30px;
}

/* Coming Soon styling */
.coming-soon-text {
    font-size: 1.2rem;
    font-weight: bold;
    color: #E2E7EB;
    margin-top: 20px;
    border: 1px dashed #E2E7EB;
    display: inline-block;
    padding: 10px 20px;
    border-radius: 5px;
}

/* --- Mobile Responsive Styles --- */
@media (max-width: 900px) {
  .layout-container {
    background-image: url('../images/mobile_background_dark.jpg');
  }
  
  .go-back-button {
    display: inline-block;
    position: absolute;
    top: 10px; 
    left: 15px;
    z-index: 1002;
  }

  .page-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 60px 15px 30px 15px;
  }

  .title-container {
    position: relative;
    top: auto;
    left: auto;
    right: auto;
    width: 95%;
    text-align: center;
    margin: 0 auto 25px auto;
    padding-top: 20px;
    font-size: 1.5rem;
  }

  .extras-content {
      padding: 20px 5% 30px 5%;
      grid-template-columns: 1fr;
  }

  .content-section {
      padding: 20px;
      margin-bottom: 30px;
  }

  .section-title {
      font-size: 1.5rem;
  }

  .section-subtitle {
      font-size: 1rem;
  }

  .video-grid {
      grid-template-columns: 1fr;
  }
}

/* --- Pop-up (Modal) Styles --- */
.modal-overlay {
  display: none; /* Hidden by default */
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.8);
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

.modal-content {
  position: relative;
  padding: 20px;
  background: #fff;
  border-radius: 5px;
  max-width: 90%;
  max-height: 90%;
}

.close-button {
  position: absolute;
  top: 10px;
  right: 15px;
  font-size: 2rem;
  font-weight: bold;
  color: #000;
  cursor: pointer;
}

/* --- NEW STYLES FOR THE TEXT POP-UP --- */
.text-modal-content {
  background-color: #5F4152; /* Dark mauve color from your screenshot */
  color: #E6DED5; /* Parchment text color */
  font-family: 'Times New Roman', Times, serif;
  border: 1px solid #E6DED5;
  text-align: center;
  padding: 40px 60px;
  max-width: 600px;
}

.text-modal-body .modal-header {
    font-size: 1.2rem;
    font-variant: small-caps;
    letter-spacing: 2px;
    margin-bottom: 25px;
}

.text-modal-body .modal-title {
    font-size: 2.5rem;
    font-weight: bold;
    margin-bottom: 5px;
}

.text-modal-body .modal-series {
    font-size: 1.1rem;
    margin-bottom: 30px;
}

.text-modal-body .modal-description {
    font-size: 1.3rem;
    line-height: 1.5;
}

/* Make the close button visible on the dark background */
.text-modal-content .close-button {
  color: #E6DED5;
}