/* ============ INIAS landing – style.css (v6) ============ */

/* ---------- Design Tokens ---------- */
:root {
  --clr-maroon: #760000;
  --clr-blue: #73aff3;
  --clr-brown: #281812;
  --radius: 20px;
  --t-ease: 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  --w: 250px;
  --h: 710px;
  --gap: 0.25rem;
}

/* ---------- Reset / Base ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font: 400 16px/2.1 "Segoe UI", Arial, sans-serif;
  background: var(--clr-maroon);
  color: var(--clr-blue);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ---------- Deck Wrapper ---------- */
.deck-wrapper {
  display: flex;
  justify-content: center;
}

.deck-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border: 0;
  filter: brightness(0.8);
  z-index: -1;
  pointer-events: none;
}

body {
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* ---------- Tile Grid ---------- */
.tile-grid {
  display: flex;
  gap: var(--gap);
  perspective: 1200px;
  justify-content: center;
  padding: 0.1rem;
  flex-direction: nowrap;
}

.card {
  position: relative;
  width: var(--w);
  height: var(--h);
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  flex-shrink: 0;
  transition: transform var(--t-ease), filter var(--t-ease),
    opacity var(--t-ease);
}

.card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(40, 24, 18, 0.35);
  backdrop-filter: brightness(0.85);
  background-image: var(--img1);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  transition: inherit;
}

.card span {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font: 800 2.4rem/1 "Segoe UI", sans-serif;
  color: var(--clr-blue);
  mix-blend-mode: difference;
  pointer-events: none;
}

.card--left {
  transform: translateX(-0%);
}
.card--left2 {
  transform: translateX(-0%);
}
.card--center {
  transform: translateZ(0px);
}
.card--right2 {
  transform: translateX(0%);
}
.card--right {
  transform: translateX(0%);
}

@media (hover: hover) {
  .tile-grid:hover .card:not(:hover) {
    opacity: 0.35;
    filter: blur(2px) brightness(0.45);
    transform: scale(0.94);
  }
  .tile-grid .card:hover {
    opacity: 1;
    filter: none;
    transform: translateZ(140px) scale(1.06) rotateY(0deg) !important;
    z-index: 5;
  }
}

.main-footer {
  background: var(--clr-brown);
  color: var(--clr-blue);
  text-align: center;
  padding: 2rem 1rem;
  font-size: 0.9rem;
  margin-top: 3rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  width: 100%;
  box-shadow: 0 -2px 12px rgba(0, 0, 0, 0.3);
}

.main-footer p {
  margin: 0.5rem 0;
}

.main-footer a {
  color: var(--clr-blue);
  text-decoration: none;
  font-weight: 500;
}

.main-footer a:hover {
  text-decoration: underline;
}

/* ---------- PC-screen Fallback ---------- */
@media (max-width: 1250px) and (min-width: 769px) {
  .tile-grid {
    flex-wrap: wrap; /* kaarten naar nieuwe rij */
    justify-content: center;
    gap: 1rem;
    max-width: 100%;
  }

  .card {
    width: 40vw;
    height: 60vh;
  }
}

/* ---------- Mobile Fallback ---------- */
@media (max-width: 768px) {
  body {
    padding: 0;
    margin: 0;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    align-items: center; /* center content horizontally */
    justify-content: flex-start; /* keep content aligned to top vertically */
  }

  .tile-grid {
    flex-direction: column;
    gap: 1rem;
    padding: 1rem;
    height: 100vh;
    justify-content: flex-start;
    align-items: center;
    width: 100%; /* span full width so children can center within viewport */
    overflow-y: auto;
    overflow-x: hidden;
  }

  .card {
    width: 100%;
    height: 60vh;
    max-width: 400px;
    max-height: 300px;
    flex: 0 0 auto;
    transform: none !important;
    margin: 0 auto;
    border-radius: 15px;
  }

  .card span {
    font-size: 1.5rem;
    font-weight: 600;
  }

  /* Subpage mobile improvements */
  body.subpage {
    padding: 1rem;
    min-height: 100vh;
    overflow-x: hidden;
  }

  .sub-header {
    margin-bottom: 1.5rem;
  }

  .sub-header h1 {
    font-size: 2rem;
  }

  .content {
    padding: 1.5rem;
    margin: 0;
    border-radius: 15px;
  }

  .content h2 {
    font-size: 1.3rem;
  }

  .photo-grid {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 0.8rem;
  }

  .video-block {
    gap: 1.5rem;
  }

  .video-block video {
    max-width: 100%;
  }

  .contact-form {
    padding: 1.5rem;
    margin: 1rem auto;
  }

  .main-footer {
    padding: 1rem;
    text-align: center;
  }

  .main-footer p {
    font-size: 0.9rem;
  }
}

/* ---------- Small Mobile Devices ---------- */
@media (max-width: 480px) {
  .card {
    width: 100%;
    height: 55vh;
    max-height: 250px;
  }

  .card span {
    font-size: 1.3rem;
  }

  .sub-header h1 {
    font-size: 1.8rem;
  }

  .content {
    padding: 1rem;
  }

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

/* ============ Subpages ============ */

body.subpage {
  background: var(--clr-maroon);
  color: var(--clr-blue);
  font: 400 17px/1.8 "Segoe UI", Arial, sans-serif;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 4rem 1rem;
  min-height: 100vh;
}

.sub-header {
  text-align: center;
  margin-bottom: 2rem;
}

.sub-header h1 {
  font-size: 2.5rem;
  margin: 0;
  color: var(--clr-blue);
}

.sub-header h1 span {
  font-weight: 800;
}

.sub-header nav a {
  color: var(--clr-blue);
  text-decoration: none;
  font-weight: 500;
  margin-top: 1rem;
  display: inline-block;
}

.sub-header nav a:hover {
  text-decoration: underline;
}

.content {
  background-color: var(--clr-brown);
  padding: 3rem;
  border-radius: var(--radius);
  max-width: 700px;
  width: 100%;
  box-shadow: 0 0 40px rgba(0, 0, 0, 0.5);
}

.content h2 {
  font-size: 1.5rem;
  color: var(--clr-blue);
  margin-top: 2rem;
}

.content p,
.content li {
  color: white;
  margin-top: 1rem;
}

em {
  color: #ffffff;
}

.contact-form {
  display: grid;
  gap: 1rem;
  padding: 2rem;
  background: var(--clr-brown);
  border-radius: var(--radius);
  max-width: 700px;
  margin: 2rem auto;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.3);
}

.contact-form label {
  font-weight: bold;
  color: var(--clr-blue);
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 0.8rem;
  border-radius: 10px;
  border: none;
  font-size: 1rem;
  font-family: inherit;
}

.contact-form button {
  width: fit-content;
  padding: 0.8rem 1.4rem;
  background: var(--clr-blue);
  color: var(--clr-brown);
  border: none;
  font-weight: bold;
  border-radius: 12px;
  cursor: pointer;
  transition: background 0.3s ease;
}

.contact-form button:hover {
  background: #96caff;
}

.photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
  margin-top: 2rem;
}

.photo-grid img {
  width: 100%;
  height: auto;
  border-radius: 12px;
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.4);
  transition: transform 0.3s ease;
}

.photo-grid video {
  width: 100%;
  height: auto;
  border-radius: 12px;
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.4);
  transition: transform 0.3s ease;
}

.video-block {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  margin-top: 2rem;
}

.video-block video {
  width: 100%;
  border-radius: 12px;
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.4);
  transition: transform 0.3s ease;
}

@media (hover: hover) and (pointer: fine) {
  .photo-grid img:hover {
    transform: scale(2);
  }

  .photo-grid video:hover {
    transform: scale(1.3);
  }

  .video-block video:hover {
    transform: scale(1.3);
  }
}
