body {
  margin: 0;
  font-family: Arial, sans-serif;
  background: #121212;
  color: white;
}

nav {
  display: flex;
  justify-content: center;
  gap: 20px;
  padding: 1em;
  background-color: #1f1f1f;
  flex-wrap: wrap;
  transition: max-height 0.3s ease;
}

nav a {
  color: white;
  text-decoration: none;
  transition: color 0.3s;
}

nav a:hover {
  color: #00aaff;
}

.hamburger {
  display: none;
  flex-direction: column;
  cursor: pointer;
  padding: 1em;
}

.hamburger div {
  width: 25px;
  height: 3px;
  background-color: white;
  margin: 4px 0;
  transition: 0.4s;
}

@media (max-width: 768px) {
  nav {
    flex-direction: column;
    align-items: center;
    max-height: 0;
    overflow: hidden;
  }

  nav.active {
    max-height: 300px;
  }

  .hamburger {
    display: flex;
    justify-content: flex-end;
  }
}

.landing-container {
  display: flex;
  width: 100%;
  height: 100vh;
}

.landing-box {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: flex-end; /* Push content to bottom */
  background-size: cover;
  background-position: center;
  text-decoration: none;
  transition: transform 0.3s ease;
  position: relative;
}

.landing-box:hover {
  transform: scale(1.02);
}

.landing-box span {
  width: 100%; /* Full width of the box */
  background: rgba(0, 0, 0, 0.6); /* Transparent black background */
  padding: 1em;
  font-size: 1.5em;
  color: white;
  text-align: center;
}


footer {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  padding: 1rem;
  background: #111;
  align-items: center;
}

footer a {
  display: flex;
  align-items: center;
  color: white;
  text-decoration: none;
  transition: transform 0.2s ease;
}

footer a:hover {
  transform: scale(1.2);
}

footer i.fa-twitter {
  font-size: 32px;
}

footer img.bluesky-icon {
  height: 32px;
  width: auto;
  display: block;
}

.profile-picture {
  width: 150px;
  height: 150px;
  object-fit: cover;
  border: 3px solid #000;
  border-radius: 12px;
  float: left;
  margin: 0 1.5em 1em 0;
  display: block;
}

/* Optional: Add a subtle shadow for depth */
.profile-picture {
  width: 200px;
  height: 200px;
  object-fit: cover;
  border: 3px solid #000;
  border-radius: 12px;
  float: left;
  margin: 0 1.5em 1em 0;
  display: block;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

/* Clear float after the about-box to prevent layout issues */
.about-box::after {
  content: "";
  display: table;
  clear: both;
}

/* Style for links within the about section */
.about-box a {
  color: white;
  font-weight: bold;
  text-decoration: none;
  transition: all 0.3s ease;
}

.about-box a:hover {
  color: #cccccc;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.about-box p {
  text-align: justify;
}

/* For the writing info sections */
.writing-info p {
  margin: 0;
  line-height: 1.4;
  text-align: justify; /* Add this line */
}

/* For project info sections */
.project-info p {
  text-align: justify;
}

/* If you want to justify text in modal content */
.modal-content p {
  text-align: justify;
}

/* Alternative: Apply to all paragraphs globally */
p {
  text-align: justify;
}

/* Update the existing writing box styles */
.writing-box {
  display: flex;
  flex-wrap: wrap;
  background: #2a2a2a;
  margin-bottom: 1em;
  border-radius: 8px;
  overflow: hidden;
  align-items: center; /* Center align items vertically */
  min-height: 120px; /* Set a smaller minimum height */
}

.writing-box img {
  width: 100%;
  max-width: 200px;
  height: 120px;
  object-fit: cover;
  flex-shrink: 0;
  box-sizing: border-box; /* Add this to all writing box images */
}

.writing-info {
  padding: 1em;
  flex: 1;
  min-width: 250px; /* Minimum width before wrapping */
}

.writing-info h3 {
  margin: 0 0 0.5em 0; /* Reduce spacing around heading */
  font-size: 1.2em;
}

.writing-info p {
  margin: 0; /* Remove default paragraph margins */
  line-height: 1.4; /* Slightly tighter line spacing */
}

/* Add white background to Heterotopias logo specifically */
.writing-box img[alt="Heterotopias"] {
  background-color: white;
  padding: 15px; /* Adds some padding around the logo */
  border-radius: 8px; /* Optional: rounds the corners to match your design */
}

/* Responsive adjustments */
@media (max-width: 600px) {
  .writing-box {
    flex-direction: column;
    min-height: auto;
  }
  
  .writing-box img {
    max-width: 100%;
    height: 150px;
  }
}

.playtesting-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1em;
  padding: 2em;
}

@media (max-width: 900px) {
  .playtesting-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

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

.play-box {
  background-size: cover;
  background-position: center;
  aspect-ratio: 460 / 215;
  cursor: pointer;
  transition: transform 0.3s;
  border: 2px solid #333;
  border-radius: 8px; /* ADDED: Border radius for play boxes */
}

/* ADDED: Hover effect for play boxes */
.play-box:hover {
  transform: scale(1.05);
  border-color: #00aaff;
}

.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.modal.hidden {
  display: none;
}

.modal-content {
  background: #1f1f1f;
  color: white;
  padding: 2rem;
  max-width: 600px;
  width: 90%;
  border-radius: 10px;
  position: relative;
  text-align: left;
  max-height: 80vh; /* ADDED: Prevent modal from being too tall */
  overflow-y: auto; /* ADDED: Allow scrolling if content is too long */
}

.modal-list {
  list-style-type: disc;
  padding-left: 1.5em;
  margin-bottom: 0.5em;
}

/* ADDED: Better spacing for modal list items */
.modal-list li {
  margin-bottom: 0.5em;
}

/* ADDED: Style for links in modal */
.modal-list a {
  color: #00aaff;
  text-decoration: none;
}

.modal-list a:hover {
  text-decoration: underline;
}

#modal-close {
  position: absolute;
  top: 10px;
  right: 15px;
  font-size: 28px;
  cursor: pointer;
  color: #ccc; /* ADDED: Better color for close button */
}

/* ADDED: Hover effect for close button */
#modal-close:hover {
  color: #00aaff;
}

.modal-banner {
  display: block;
  width: 100%;
  aspect-ratio: 460 / 215;
  object-fit: cover;
  border-radius: 8px; /* CHANGED: From 10px 10px 0 0 to 8px for consistency */
  margin-bottom: 1rem;
}

.about-contact {
  display: flex;
  flex-wrap: wrap;
  gap: 2em;
  padding: 2em;
  justify-content: space-around;
}

.about-box, .contact-box {
  flex: 1;
  min-width: 300px;
  background: #2a2a2a;
  padding: 2em;
  border-radius: 8px;
}

.contact-box input,
.contact-box textarea {
  width: 100%;
  padding: 0.5em;
  margin-bottom: 1em;
  background: #1f1f1f;
  border: 1px solid #444;
  color: white;
  border-radius: 4px;
}

.contact-box button {
  background: #00aaff;
  color: white;
  padding: 0.7em 1.5em;
  border: none;
  border-radius: 4px;
  cursor: pointer;
}

.contact-box button:hover {
  background: #008fcc;
}

.projects, .writing {
  padding: 2em;
}

.project-box, .writing-box {
  display: flex;
  flex-wrap: wrap;
  background: #2a2a2a;
  margin-bottom: 1em;
  border-radius: 8px;
  overflow: hidden;
}

.project-box img, .writing-box img {
  width: 100%;
  max-width: 300px;
  height: auto;
  object-fit: cover;
}

.project-info, .writing-info {
  padding: 1em;
  flex: 1;
}