/* Common styles */
body, h1, h2, h3, p { margin:0; padding:0; }
body {
  font-family: 'Raleway', sans-serif;
  color: #e3dac5;
  background: #000;
}
.section { position: relative; padding: 60px 20px; }
.light { background: #fff; color: #000; }
.dark { background: #111; color: #fff; }
.hero {
  background: url('../img/bg/BlackMarbleTexture.png') center/cover no-repeat;
}
.overlay {
  backdrop-filter: brightness(0.6);
  padding: 40px;
  text-align: center;
}

/*Typo*/
h1 { font-family: 'Rubik', sans-serif; font-size:38px; font-weight:bold; }
h2 { font-family: 'Rubik', sans-serif; font-size:32px; font-weight:bold; }
h3 { font-family: 'Rubik', sans-serif; font-size:22px; font-weight:bold; margin: 20px 0; }
p { font-size:20px; line-height:1.5; }
p.italic { font-style: italic; }

.hero-text {
  color: #e3dac5;
}

/* Navigation */
.nav-links a {
  font-size:14px;
  color: gray;
  margin: 0 10px;
  text-decoration:none;
}
.nav-links a:hover, .nav-links a:active {
  color: white;
}

/* Carousels */
.carousel {
  display: flex;
  overflow-x: auto;
  gap: 12px;
  padding: 20px 0;
}
.carousel img {
  flex: 0 0 auto;
  max-width: 200px;
  border-radius: 8px;
}

/* Subscribe */
#subscribe form {
  display: flex;
  gap: 10px;
  margin:20px 0;
}
#subscribe input {
  flex:1;
  padding:10px;
  font-size:16px;
}
#subscribe button {
  font-size:16px;
  padding:10px 20px;
  background: gray;
  color:white;
  border:none;
  cursor: pointer;
}
#subscribe button:hover {
  background: white;
  color:gray;
}
.social a {
  margin: 0 8px;
  color: white;
  text-decoration: none;
}
.social a:hover { text-decoration: underline; }

/* Adaptive */
@media (max-width:600px) {
  h1 { font-size:30px; }
  h3 { font-size:22px; }
  p { font-size:16px; }
}

.hero-logo-block {
  background-color: transparent;
  text-align: center;
  padding: 40px 20px;
}

.hero-logo {
  max-width: 100%;
  height: auto;
}

.hero-text {
  text-align: center;
  padding: 40px 20px;
  max-width: 800px;
  margin: auto;
}

.carousel.characters {
  width: 100%;
  overflow: hidden;
  display: flex;
  justify-content: center;
}

.carousel-track {
  display: flex;
  gap: 16px;
  animation: scrollCarousel 200s linear infinite;
}

.carousel-track img {
  flex: 0 0 auto;
  width: 150px;
  border-radius: 12px;
}

@keyframes scrollCarousel {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-25%); }
}

.about-three-columns {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  text-align: center;
  gap: 40px;
  flex-wrap: wrap;
  margin-bottom: 40px;
}

.about-three-columns {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  gap: 40px;
  flex-wrap: wrap;
  margin-bottom: 40px;
  text-align: center;
}

.about-three-columns .about-block {
  flex: 1 1 300px;
  max-width: 350px;
}

.about-three-columns .about-block img {
  max-width: 100%;
  border-radius: 8px;
  margin-bottom: 16px;
}

.about-three-columns .about-block h2 {
  font-size: 30px;
  font-family: 'Rubik', sans-serif;
  margin-bottom: 8px;
}

/*
===============================
.about-three-columns .about-block p {
  font-size: 18px;
  line-height: 1.4;
}
===============================
*/

/* Move center down */
.about-three-columns .about-block.center {
  margin-top: 40px;
}

/* Adaptive */
@media (max-width: 900px) {
  .about-three-columns {
    flex-direction: column;
    align-items: center;
  }

  .about-three-columns .about-block.center {
    margin-top: 0;
  }
}

.about-header {
  text-align: center;
  max-width: 800px;
  margin: 0 auto 40px auto;
  padding: 0 20px;
}

.about-header h1 {
  font-size: 38px;
  font-family: 'Rubik', sans-serif;
  margin-bottom: 12px;
}
/*
.about-header p {
  font-size: 18px;
  font-family: 'Raleway', sans-serif;
  line-height: 1.4;
}
*/
.about-block img {
  border-radius: 12px;
  transition: transform 0.3s ease;
}

.about-block img:hover {
  transform: scale(2);
  z-index: 2;
}

.about-bg {
  background: url('../img/bg/015bg-mercs-city.png') center/cover no-repeat;
  position: relative;
  z-index: 0;
}

/* Game description block */
.description-section {
  color: white;
  text-align: center;
  padding: 80px 20px;
}
.description-section h1 {
  font-family: 'Rubik', sans-serif;
  font-size: 36px;
  font-weight: bold;
  margin-bottom: 20px;
}
.description-section h2 {
  font-size: 28px;
  font-weight: bold;
  margin-top: 40px;
}

/*
===================================
.description-section p {
  font-size: 18px;
  line-height: 1.6;
  margin: 15px 0;
}
===================================
*/

/* Humanity choice block */
.humanity-section {
  background: url('../img/bg/038bg-gents.png') center/cover no-repeat;
  padding: 80px 20px;
  text-align: center;
  color: #000;
  position: relative;
}
.humanity-header h2 {
  font-size: 32px;
  font-weight: bold;
}
/*
.humanity-header p {
  font-size: 20px;
  margin: 10px 0;
}
*/
.humanity-header h3 {
  font-size: 24px;
  font-weight: bold;
  margin: 20px 0 40px;
}
.humanity-roles {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
}
.role img {
  max-width: 220px;
  border-radius: 8px;
}
/*
.role p {
  margin-top: 10px;
  font-weight: bold;
  font-size: 18px;
}
*/
.humanity-roles img {
  max-width: 220px;
  border-radius: 8px;
  transition: transform 0.3s ease;
}

.humanity-roles img:hover {
  transform: scale(1.15);
  z-index: 2;
}

/* Gradient overlay for Humanity section background */
.humanity-section::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(255,255,255,0.3), rgba(255,255,255,0.3));
  z-index: 0;
}

.humanity-section > * {
  position: relative;
  z-index: 1;
}

/* Section: KSP2 + USP */
.ksp-section {
  background: url('../img/bg/051bg-flawless.png') center/cover no-repeat;
  padding: 80px 20px;
  text-align: center;
  color: #000;
}

.ksp-images {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
  margin-top: 40px;
}

.ksp-images img {
  max-width: 634px;
  border-radius: 8px;
}

.ksp-cards {
  position: relative;
  height: 500px; 
  max-width: 1200px;
  margin: 0 auto;
}

.ksp-cards .card {
  position: absolute;
  max-width: 500px;
  border-radius: 0;
  box-shadow: 0 8px 16px rgba(0,0,0,0);
  transition: transform 0.3s ease;
}

.ksp-cards .card:hover {
  transform: scale(1.02);
}

.ksp-cards .ember {
  top: 0;
  left: 5%;
}

.ksp-cards .chem {
  top: 120px;
  left: 25%;
}

.ksp-cards .hounder {
  top: 250px;
  left: 45%;
}

/* Section: KSP3 – Boss only fights */
.ksp3-section {
  background: url('../img/bg/008bg-hyenas.png') center/cover no-repeat;
  padding: 80px 20px;
  text-align: center;
  color: white; /* Make all text inside this section white */
}

.ksp3-text {
  max-width: 800px;
  margin: 0 auto 40px;
}

.ksp3-text h2 {
  /* Use default h2 styling */
}

.ksp3-text p {
  /* Use default p styling (16px, Raleway Regular) */
}

.ksp3-image img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
}

.ksp3-cards img {
  transition: transform 0.3s ease;
}

.ksp3-image img {
  transition: transform 0.3s ease;
}

.ksp3-image img:hover {
  transform: scale(1.05);
  z-index: 1;
}

/* gallery-section styles */
.gallery-header {
  text-align:center;
  margin-bottom:40px;
}
.gallery-header h2,
.gallery-header p {
  /* use existing h2, p styles */
}

/* grid of 5×3 tiles */
.gallery-grid {
  display:grid;
  grid-template-columns:repeat(5, 1fr);
  grid-gap:10px;
}
.gallery-item img {
  width:100%;
  height:auto;
  cursor:pointer;
  border-radius:8px;
  transition: transform .3s;
}
.gallery-item img:hover {
  transform: scale(1.05);
}

/* lightbox */
.lightbox-overlay {
  position:fixed;
  inset:0;
  background:rgba(0,0,0,0.6);
  backdrop-filter:blur(8px);
  display:flex;
  justify-content:center;
  align-items:center;
  z-index:1000;
  padding:20px;
}
.lightbox-content {
  background:#fff;
  border-radius:8px;
  max-width:90%;
  max-height:90%;
  overflow:auto;
  text-align:left;
}
.lightbox-content img {
  width:100%;
  height:auto;
  display:block;
  border-bottom:1px solid #ccc;
}
.lightbox-text {
  padding:20px;
}
.lightbox-text h3 {
  margin-top:0;
}
/* Gallery section with background */
.gallery-section {
  background: url('../img/bg/061bg-valkyr.png') center/cover no-repeat;
  padding: 80px 20px;
  color: white;
}
/* Modal overlay */
.tile-modal {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 1000;
}
.tile-modal-content {
  background: #dddddd;
  max-width: 800px;
  width: 90%;
  border-radius: 10px;
  padding: 20px;
  text-align: left;
  box-shadow: 0 0 20px rgba(0,0,0,0.4);
}

.tile-modal-content img {
  width: 100%;
  border-radius: 8px;
  margin-bottom: 20px;
}

.modal-text {
  padding: 0;
}

.modal-text h3 {
  font-size: 22px;
  margin-bottom: 10px;
  color: #000;
}

.modal-text p {
  font-size: 16px;
  line-height: 1.6;
  color: #333;
}

.tile-modal-content {
  animation: fadeInScale 0.25s ease;
}

@keyframes fadeInScale {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}
.tile-modal.open {
  display: flex;
}
.modal-text p {
  white-space: pre-line;
}
.gallery-header h2,
.gallery-header p {
  color: #fff;
}

.story-section {
  background: url('../img/bg/064bg-patrol.png') center/cover no-repeat;
  padding: 80px 20px;
  text-align: center;
}

.story-image img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  transition: transform 0.3s ease;
}

.story-image img:hover {
  transform: scale(1.05);
}

.hero-text {
  color: #e3dac5;
}
.team-img {
  transition: transform 0.3s ease;
}
.team-img:hover {
  transform: scale(1.05);
}

.social-icons img {
  width: 50px;
  height: 50px;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.social-icons a:hover img {
  transform: scale(1.1);
}

.social-icons a.inactive img {
  opacity: 0.3;
  pointer-events: none;
}

.footer-section {
  background-color: #000;
  color: #e3dac5;
  text-align: center;
  padding: 60px 20px;
}

.footer-section h2 {
  font-family: 'Rubik', sans-serif;
  font-size: 32px;
  font-weight: bold;
  margin-bottom: 16px;
}

.footer-section .tagline {
  font-size: 18px;
  font-style: italic;
  margin-bottom: 40px;
  line-height: 1.6;
}

.footer-divider {
  border: 0;
  height: 1px;
  background: #444;
  margin: 40px auto;
  width: 60%;
}

.footer-legal {
  font-size: 13px;
  color: #999;
  line-height: 1.6;
  max-width: 800px;
  margin: 0 auto;
}

@media (max-width: 768px) {
  .ksp-cards {
    display: flex;
    flex-direction: column;
    align-items: center;
    height: auto;
    position: static;
    gap: 20px;
  }

  .ksp-cards .card {
    position: static;
    width: 80%;
    max-width: 300px;
  }
}
@media (max-width: 600px) {
  iframe {
    width: 100% !important;
    height: 600px;
  }
}
.form-wrapper {
  background: #111;
  border-radius: 12px;
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.1);
  padding: 16px;
  max-width: 640px;
  margin: 0 auto;
}
iframe {
  width: 100%;
  max-width: 100%;
  border: none;
  border-radius: 8px;
  height: 550px;
}

@media (max-width: 600px) {
  .form-wrapper iframe {
    height: 750px;
  }
}
@media (max-width: 600px) {
  .form-wrapper iframe {
    height: 600px;
  }
}
.story-text-box {
  background: rgba(0, 0, 0, 0.6);
  padding: 24px 32px;
  border-radius: 12px;
  max-width: 800px;
  margin: 0 auto;
}
