/* Base styles */
:root {
  --primary-color: #c8102e; /* Edinburgh Napier red */
  --secondary-color: #000000; /* Dark gray/black */
  --text-color: #333333;
  --light-color: #f8f9fa;
  --accent-color: #ffcc00; /* Gold accent */
  --spacing-sm: 0.5rem;
  --spacing-md: 1rem;
  --spacing-lg: 2rem;
  --spacing-xl: 3rem;
  --border-radius: 0.25rem;
  --transition-speed: 0.3s;
}

body {
  font-family: 'Open Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
  line-height: 1.6;
  color: var(--light-color);
  background-color: var(--secondary-color);
  margin: 0;
  padding: 0;
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: var(--spacing-md);
}

p {
  margin-bottom: var(--spacing-md);
}

.text-primary {
  color: var(--primary-color) !important;
}

.text-danger {
  color: var(--primary-color) !important;
}

/* Layout */
.page-container {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  max-width: 100%;
  overflow-x: hidden;
}

.info-container {
  display: flex;
  flex-direction: column;
  width: 100%;
  padding: var(--spacing-md);
}

/* Poster styling */
.poster-container {
  position: relative;
  width: 100%;
  min-height: 600px;
  overflow: hidden;
  margin-bottom: var(--spacing-lg);
  border-radius: var(--border-radius);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  display: flex;
  justify-content: center;
  align-items: center;
}

.poster {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity var(--transition-speed) ease-in-out;
}

.poster.active {
  opacity: 1;
  z-index: 1;
}

/* Text content */
.text-container {
  padding: var(--spacing-md);
  background-color: var(--secondary-color);
  border-radius: var(--border-radius);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  margin-bottom: var(--spacing-lg);
}

.text-container .h3,
.text-container .h5 {
  color: var(--primary-color);
}

/* Feature boxes */
.border.bg-dark {
  background-color: var(--secondary-color) !important;
  border-color: var(--primary-color) !important;
  border-width: 2px !important;
  border-radius: var(--border-radius);
  transition: transform var(--transition-speed);
  height: 100%;
}

.border.bg-dark:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.border.bg-dark h4 {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
}

.border.bg-dark p {
  color: var(--light-color);
}

/* Map containers */
.map-container {
  width: 100%;
  margin-bottom: var(--spacing-lg);
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.map-container iframe {
  display: block;
}

/* Responsive styles */
@media (min-width: 768px) {
  .info-container {
    flex-direction: row;
    align-items: flex-start;
    gap: var(--spacing-lg);
    padding: var(--spacing-lg);
  }
  
  .poster-container {
    width: 40%;
    height: auto;
    min-height: 700px; /* Increased from 500px for vertical images */
    max-height: 1000px; /* Increased for vertical images */
    flex-shrink: 0;
    position: sticky;
    top: var(--spacing-lg);
  }
  
  /* Modified poster styling to handle vertical images better */
  .poster {
    height: 100%;
    object-fit: contain; /* Changed from 'cover' to 'contain' to show full image */
    background-color: var(--secondary-color); /* Match background */
    object-position: center top; /* Align to top if image is cut */
  }
  
  .text-container {
    flex-grow: 1;
    margin-top: 0;
  }
  
  .map-container {
    height: 400px;
  }
}

@media (max-width: 768px) {
  .info-container {
    padding: var(--spacing-sm);
  }
  
  .poster-container {
    margin-bottom: var(--spacing-md);
    padding: 10px; /* Add padding for better spacing */
  }
  
  .poster {
    width: 100%;
    height: auto;
    object-fit: contain; /* Ensures the full image is visible */
  }
  
  .border.bg-dark {
    margin-bottom: var(--spacing-md);
  }
  
  .row .col-md-4 {
    margin-bottom: var(--spacing-md);
  }
  
  .map-container {
    height: 300px;
  }
  
  h1 {
    font-size: 2rem;
  }
  
  h2 {
    font-size: 1.5rem;
  }
}

/* Animations */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.fade-in {
  animation: fadeIn 1s ease-in-out;
}
