/* =========================================================
   Shlomi Hanukaev — Game Designer Portfolio
   ========================================================= */

:root {
  --bg: #0d0f10;
  --bg-alt: #131619;
  --bg-card: #16191c;
  --teal: #14b8a6;
  --teal-soft: rgba(20, 184, 166, 0.12);
  --white: #f4f5f6;
  --gray: #a9b0b3;
  --gray-dim: #6d7477;
  --border: rgba(255, 255, 255, 0.08);
  --font: "Spline Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --max-width: 1180px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html {
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  color: var(--white);
  font-family: var(--font);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
ul { list-style: none; }
img { max-width: 100%; display: block; }

.section-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 32px;
}

.section-eyebrow {
  color: var(--teal);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-bottom: 12px;
}

.section-title {
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  font-weight: 700;
  margin-bottom: 40px;
  letter-spacing: -0.01em;
}

/* ---------- Particles background ---------- */
#particles-js {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100vh;
  z-index: 0;
  background: radial-gradient(ellipse at top, #14181a 0%, #0d0f10 65%);
}

/* ---------- Reveal animation ---------- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}
.hero-name.reveal.in-view {
  opacity: 0.7;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: 12px 28px;
  border-radius: 6px;
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  transition: all 0.25s ease;
  cursor: pointer;
}

.btn-solid {
  background: var(--teal);
  color: #08201c;
  border: 1px solid var(--teal);
}
.btn-solid:hover {
  background: transparent;
  color: var(--teal);
  transform: translateY(-2px);
}

.btn-outline {
  background: transparent;
  color: var(--teal);
  border: 1px solid var(--teal);
  padding: 9px 22px;
  font-size: 0.9rem;
}
.btn-outline:hover {
  background: var(--teal-soft);
  transform: translateY(-2px);
}

/* ---------- Nav ---------- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(13, 15, 16, 0.75);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s ease, background 0.3s ease;
}
.nav.scrolled {
  border-bottom-color: var(--border);
  background: rgba(13, 15, 16, 0.92);
}

.nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 18px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.logo {
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--white);
  white-space: nowrap;
}
.logo-thin {
  font-weight: 400;
  color: var(--gray);
  margin-left: 4px;
}

.nav-links {
  display: flex;
  gap: 34px;
  margin-left: auto;
  margin-right: 34px;
}
.nav-link {
  font-size: 0.92rem;
  color: var(--gray);
  font-weight: 500;
  position: relative;
  transition: color 0.2s ease;
}
.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 0;
  height: 2px;
  background: var(--teal);
  transition: width 0.25s ease;
}
.nav-link:hover {
  color: var(--white);
}
.nav-link:hover::after {
  width: 100%;
}

.nav-resume {
  flex-shrink: 0;
}

.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--white);
  transition: all 0.3s ease;
}
.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero + Stats pin group ---------- */
.pin-group {
  position: relative;
}

/* ---------- Hero ---------- */
.hero {
  position: sticky;
  top: 0;
  z-index: 2;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 140px 24px 80px;
}

.hero-content {
  max-width: 1400px;
}

.eyebrow {
  color: var(--teal);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  margin-bottom: 22px;
}

.hero-name {
  font-size: clamp(2.8rem, 9vw, 8rem);
  font-weight: 700;
  line-height: 1.02;
  letter-spacing: -0.02em;
  text-transform: uppercase;
  color: var(--white);
  margin-bottom: 28px;
}

.tagline {
  font-size: clamp(1.2rem, 2.6vw, 1.7rem);
  font-weight: 600;
  margin-bottom: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  min-height: 2.2em;
}
.tagline-teal { color: var(--teal); }
.tagline-white { color: var(--white); }
.tagline-sep { color: var(--gray-dim); font-weight: 400; }

.hero-sub {
  color: var(--gray);
  font-size: 1.16rem;
  max-width: 560px;
  margin: 0 auto 36px;
}

/* ---------- Scroll indicator ---------- */
.scroll-indicator {
  position: absolute;
  bottom: 34px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
}
.mouse {
  width: 26px;
  height: 42px;
  border: 2px solid var(--gray-dim);
  border-radius: 14px;
  display: flex;
  justify-content: center;
  padding-top: 8px;
}
.wheel {
  width: 3px;
  height: 8px;
  background: var(--teal);
  border-radius: 2px;
  animation: scrollWheel 1.8s ease-in-out infinite;
}
@keyframes scrollWheel {
  0% { opacity: 1; transform: translateY(0); }
  70% { opacity: 0; transform: translateY(12px); }
  100% { opacity: 0; transform: translateY(12px); }
}

/* ---------- Social rail ---------- */
.social-rail {
  position: fixed;
  right: 26px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 90;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.social-rail::after {
  content: "";
  display: block;
  width: 1px;
  height: 60px;
  background: var(--border);
  margin: 6px auto 0;
}
.rail-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.02);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gray);
  transition: all 0.25s ease;
}
.rail-icon:hover {
  color: var(--teal);
  border-color: var(--teal);
  background: var(--teal-soft);
  transform: translateY(-2px);
}

/* ---------- Stat numbers (shared by any .stat-number, wherever placed) ---------- */
.stat-number {
  display: block;
  font-size: clamp(1.9rem, 2.8vw, 2.6rem);
  font-weight: 700;
  color: var(--teal);
  line-height: 1;
}
.stat-label {
  display: block;
  margin-top: 8px;
  color: var(--gray);
  font-size: 0.85rem;
  letter-spacing: 0.02em;
}

/* ---------- About (also the pin-group's covering panel) ---------- */
.about {
  position: relative;
  z-index: 3;
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  min-height: 80vh;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(200px, 24%);
  align-items: stretch;
}
.about-content {
  grid-column: 1;
  display: flex;
  align-items: flex-start;
  gap: 56px;
  padding: 72px 48px 72px max(24px, calc(50vw - (var(--max-width) / 2) - 120px));
}
.about-stats {
  flex-shrink: 0;
  width: 180px;
  display: flex;
  flex-direction: column;
  gap: 30px;
}
.stat-vertical {
  text-align: left;
  padding-left: 18px;
  border-left: 2px dashed var(--border);
}
.stat-icon {
  display: block;
  color: var(--teal);
  margin-bottom: 10px;
}
.about-text { flex: 1; max-width: 920px; margin: 0; text-align: left; }
.about-heading {
  font-size: clamp(2.3rem, 4.1vw, 3.2rem);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.01em;
  margin: 10px 0 20px;
}
.about-p {
  color: var(--gray);
  font-size: 1.28rem;
  margin-bottom: 14px;
}
.languages {
  display: block;
  color: var(--gray-dim);
  font-size: 0.88rem;
  letter-spacing: 0.02em;
  margin-bottom: 8px;
}
.quick-facts {
  display: block;
  color: var(--gray);
  font-size: 0.92rem;
  letter-spacing: 0.02em;
  margin-top: 24px;
  margin-bottom: 10px;
}
.quick-facts strong {
  color: var(--white);
  font-weight: 600;
}
.about-cta-line {
  color: var(--gray);
  margin-bottom: 16px;
}
.about-contact-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.about-photo {
  grid-column: 2;
  position: relative;
  overflow: hidden;
  min-height: 420px;
  background: linear-gradient(160deg, #1b2023, var(--bg-alt));
}
.about-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* ---------- Experience timeline ---------- */
.experience {
  position: relative;
  z-index: 2;
  padding: 110px 0;
  background: var(--bg-alt);
}
.timeline {
  position: relative;
  max-width: 780px;
  margin-left: 8px;
  padding-left: 32px;
  border-left: 2px solid var(--border);
}
.timeline-item {
  position: relative;
  padding-bottom: 46px;
}
.timeline-item:last-child { padding-bottom: 0; }
.timeline-dot {
  position: absolute;
  left: -39px;
  top: 4px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--bg-alt);
  border: 2px solid var(--teal);
}
.timeline-date {
  display: inline-block;
  color: var(--teal);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 8px;
}
.timeline-role {
  font-size: 1.15rem;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--white);
}
.timeline-org {
  font-weight: 400;
  color: var(--gray);
  font-size: 0.95rem;
}
.timeline-desc {
  color: var(--gray);
  font-size: 0.98rem;
  max-width: 640px;
}

/* ---------- Work / Projects ---------- */
.work {
  position: relative;
  z-index: 2;
  padding: 110px 0;
}
.thumb-1 { background: linear-gradient(135deg, #103732 0%, #0d0f10 100%); }
.thumb-2 { background: linear-gradient(135deg, #0f2a3a 0%, #0d0f10 100%); }
.thumb-3 { background: linear-gradient(135deg, #14332a 0%, #0d0f10 100%); }
.thumb-4 { background: linear-gradient(135deg, #1a2f3d 0%, #0d0f10 100%); }

.work-category {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 48px;
}
.work-category + .work-category {
  margin-top: 64px;
}
.work-category-title {
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--white);
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}

/* ---------- Games grid (poster cards, hover-reveal description) ---------- */
.games-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}
.games-grid-featured {
  grid-template-columns: 1fr;
}
.game-card-featured .game-card-media {
  aspect-ratio: 21 / 9;
}
.game-card {
  position: relative;
  display: block;
  color: rgba(244, 245, 246, 0.85);
  transition: transform 0.35s ease;
}
.game-card::before {
  content: "";
  position: absolute;
  inset: -28px;
  z-index: -1;
  background-image: var(--card-bg);
  background-size: cover;
  background-position: center;
  filter: blur(38px) saturate(1.5) brightness(0.85);
  opacity: 0;
  border-radius: 24px;
  pointer-events: none;
  transition: opacity 0.4s ease;
}
.game-card:hover {
  transform: scale(1.035);
  z-index: 5;
}
.game-card:hover::before {
  opacity: 0.6;
}
.game-card-frame {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 12px;
  border: 1px solid var(--border);
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}
.game-card:hover .game-card-frame {
  border-color: rgba(20, 184, 166, 0.55);
  box-shadow: 0 25px 55px rgba(0, 0, 0, 0.5);
}
.game-card-media {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 3 / 4;
  overflow: hidden;
}
.game-card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform 0.5s ease;
}
.game-card-featured .game-card-img {
  object-position: center 20%;
}
.game-card:hover .game-card-img {
  transform: scale(1.08);
}
.game-card-info {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  max-height: 100%;
  z-index: 2;
  padding: 16px 20px 18px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  overflow: hidden;
  background: linear-gradient(to top, rgba(10, 11, 12, 0.97) 45%, rgba(10, 11, 12, 0) 100%);
  transition: background 0.3s ease;
}
.game-card:hover .game-card-info {
  background: rgba(10, 11, 12, 0.97);
}
.game-card-title {
  display: block;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--white);
}
.game-card-studio {
  display: block;
  color: var(--gray);
  font-size: 0.8rem;
  margin-top: 2px;
}
.game-card-reveal {
  display: block;
  width: 100%;
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, opacity 0.3s ease;
}
.game-card:hover .game-card-reveal {
  max-height: 320px;
  opacity: 1;
}
.game-card-divider {
  display: block;
  margin: 14px 0 12px;
  border-top: 1px dashed rgba(255, 255, 255, 0.22);
}
.game-card-tagline {
  display: block;
  color: var(--white);
  font-size: 1.1rem;
  line-height: 1.5;
  margin-bottom: 10px;
}
.game-card-tagline strong {
  font-weight: 700;
}
.game-card-role {
  display: block;
  color: var(--gray);
  font-size: 1.06rem;
  line-height: 1.5;
}

/* ---------- Skills ---------- */
.skills {
  position: relative;
  z-index: 2;
  padding: 110px 0;
  background: var(--bg-alt);
}
.skills-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
}
.skills-heading {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 20px;
  color: var(--white);
}
.pill-group {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.pill {
  padding: 9px 18px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(20, 184, 166, 0.06);
  color: var(--gray);
  font-size: 0.88rem;
  font-weight: 500;
  transition: all 0.25s ease;
}
.pill:hover {
  border-color: var(--teal);
  color: var(--teal);
  background: var(--teal-soft);
}

/* ---------- Contact / Footer ---------- */
.contact {
  position: relative;
  z-index: 2;
  padding: 120px 0 60px;
  text-align: center;
}
.contact-inner {
  max-width: 780px;
}
.contact-cta {
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  font-weight: 700;
  line-height: 1.35;
  margin-bottom: 44px;
}
.contact-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
  margin-bottom: 56px;
}
.contact-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 20px;
  border-radius: 999px;
  border: 1px solid var(--border);
  color: var(--gray);
  font-size: 0.92rem;
  font-weight: 500;
  transition: all 0.25s ease;
}
.contact-link:hover {
  border-color: var(--teal);
  color: var(--teal);
  background: var(--teal-soft);
  transform: translateY(-2px);
}
.copyright {
  color: var(--gray-dim);
  font-size: 0.85rem;
  border-top: 1px solid var(--border);
  padding-top: 28px;
}

/* =========================================================
   Responsive
   ========================================================= */
@media (max-width: 900px) {
  .about { grid-template-columns: 1fr; }
  .about-photo { grid-column: 1; min-height: 320px; order: -1; }
  .about-content {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 28px;
    margin-left: 0;
    max-width: 100%;
    padding: 60px 24px;
  }
  .about-text { text-align: left; }
  .about-stats { width: 100%; max-width: 320px; }
  .skills-grid { grid-template-columns: 1fr; gap: 40px; }
  .work-category {
    padding: 0 24px;
  }
  .work-category + .work-category {
    margin-top: 48px;
  }
  .games-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }
  .games-grid-featured {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .nav-links {
    position: fixed;
    top: 66px;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: center;
    gap: 0;
    background: rgba(13, 15, 16, 0.98);
    border-bottom: 1px solid var(--border);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    margin: 0;
  }
  .nav-links.open {
    max-height: 320px;
  }
  .nav-links .nav-link {
    padding: 16px 0;
    width: 100%;
    text-align: center;
  }
  .nav-resume { display: none; }
  .hamburger { display: flex; }

  .social-rail { right: 12px; gap: 10px; }
  .rail-icon { width: 34px; height: 34px; }

  .hero { padding-top: 120px; }
  .timeline { padding-left: 26px; margin-left: 2px; }
  .timeline-dot { left: -33px; }
}

@media (max-width: 480px) {
  .section-inner { padding: 0 20px; }
  .hero-name { letter-spacing: -0.01em; }
  .contact-links { flex-direction: column; align-items: stretch; }
  .contact-link { justify-content: center; }
  .games-grid { grid-template-columns: 1fr; }
}

/* =========================================================
   Work card "View Project" link
   ========================================================= */
.project-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 20px;
  color: var(--teal);
  font-weight: 600;
  font-size: 0.9rem;
  transition: gap 0.2s ease;
}
.project-link svg { flex-shrink: 0; transition: transform 0.2s ease; }
.project-link:hover { gap: 13px; }
.project-link:hover svg { transform: translateX(2px); }

/* =========================================================
   Game Detail Pages
   ========================================================= */

/* ---------- Back link ---------- */
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--teal);
  font-size: 0.9rem;
  font-weight: 600;
  transition: gap 0.2s ease;
}
.back-link svg { flex-shrink: 0; transition: transform 0.2s ease; }
.back-link:hover { gap: 12px; }
.back-link:hover svg { transform: translateX(-3px); }

/* ---------- Project hero ---------- */
.project-hero {
  position: relative;
  z-index: 2;
  padding: 150px 0 80px;
}
.project-hero-video-bg {
  position: sticky;
  top: 0;
  overflow: hidden;
  min-height: 640px;
  display: flex;
  align-items: center;
}
.project-hero-video-wrap {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}
.project-hero-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.project-hero-video-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(10, 11, 12, 0.55) 0%, rgba(10, 11, 12, 0.65) 45%, rgba(10, 11, 12, 0.97) 100%);
}
.project-hero-video-bg .project-hero-inner {
  position: relative;
  z-index: 1;
}
.project-hero-inner { max-width: 860px; }
.project-hero-image-bg {
  position: sticky;
  top: 0;
  overflow: hidden;
  min-height: 640px;
  display: flex;
  align-items: center;
  background-image: var(--hero-bg-image);
  background-size: cover;
  background-position: center;
}
.project-hero-image-overlay {
  position: absolute;
  inset: 0;
  z-index: 0;
  background: linear-gradient(180deg, rgba(10, 11, 12, 0.45) 0%, rgba(10, 11, 12, 0.6) 45%, rgba(10, 11, 12, 0.95) 100%);
}
.project-hero-image-bg .project-hero-inner {
  position: relative;
  z-index: 1;
}
.project-hero-inner-center {
  max-width: none;
  width: 100%;
}
.project-hero-back-corner {
  position: absolute;
  top: 32px;
  left: 32px;
  z-index: 2;
  margin-bottom: 0 !important;
}

.hextalia-hero-brand {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 24px;
}
.hextalia-hero-brand-center {
  align-items: center;
  text-align: center;
  margin: 0 auto;
}
.hextalia-hero-logo {
  display: block;
  height: 70px;
  width: auto;
}
.hextalia-hero-logo-large {
  height: clamp(120px, 16vw, 220px);
}
.hextalia-hero-line {
  color: var(--white);
  font-size: 1.5rem;
  font-weight: 600;
  max-width: 480px;
}
.hextalia-hero-steam {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 81px;
  height: 81px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.04);
  color: var(--white);
  transition: all 0.25s ease;
}
.hextalia-hero-steam:hover {
  color: var(--teal);
  border-color: var(--teal);
  background: var(--teal-soft);
  transform: translateY(-2px);
}
.project-hero .back-link { margin-bottom: 36px; }
.project-hero-tag {
  color: var(--teal);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-bottom: 18px;
}
.project-hero-title {
  font-size: clamp(2.2rem, 6vw, 4rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 20px;
  color: var(--white);
}
.project-hero-tagline {
  color: var(--gray);
  font-size: 1.08rem;
  max-width: 640px;
  margin-bottom: 34px;
}

.meta-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 40px;
}
.meta-pill {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 11px 20px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.02);
}
.meta-pill-label {
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gray-dim);
}
.meta-pill-value {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--white);
}

.hero-ctas { display: flex; flex-wrap: wrap; gap: 16px; }

/* ---------- Overview ---------- */
.overview {
  position: relative;
  z-index: 3;
  padding: 90px 0;
  background: var(--bg-alt);
}
.overview-text {
  color: var(--gray);
  font-size: 1.03rem;
  max-width: 840px;
}
.overview-text + .overview-text {
  margin-top: 16px;
}
.overview-role-box {
  margin-top: 24px;
  padding-left: 18px;
  border-left: 2px solid var(--teal);
}
.overview-role-text {
  color: var(--white);
  font-size: 1.03rem;
  line-height: 1.6;
  max-width: 760px;
}
.overview-layout {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 40px;
  width: 100%;
  padding: 0 24px;
}
.overview-visual {
  flex-shrink: 0;
}
.overview-visual-left {
  width: 420px;
  margin-left: -180px;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  align-self: stretch;
}
.overview-tower-img {
  max-width: 100%;
  max-height: 600px;
  object-fit: contain;
  filter: drop-shadow(0 25px 35px rgba(0, 0, 0, 0.45));
}
.overview-copy {
  flex: 0 1 560px;
  min-width: 0;
}
.overview-copy .section-eyebrow,
.overview-copy .section-title {
  margin-bottom: 0;
}
.overview-copy .section-title {
  margin-bottom: 4px;
}
.overview-platform-links {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
}
.overview-platform-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--gray);
  font-size: 0.92rem;
  font-weight: 500;
  transition: color 0.2s ease;
}
.overview-platform-link:hover {
  color: var(--teal);
}
.overview-visual-right {
  position: relative;
  width: 680px;
  height: 450px;
  margin-right: -160px;
}
.overview-shot {
  position: absolute;
  border-radius: 10px;
  border: 1px solid var(--border);
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
  object-fit: cover;
}
.overview-shot-1 {
  top: 0;
  right: 0;
  width: 76%;
  aspect-ratio: 1892 / 1060;
  z-index: 1;
}
.overview-shot-2 {
  bottom: 0;
  left: 0;
  width: 96%;
  aspect-ratio: 1015 / 328;
  z-index: 2;
}

/* ---------- Gallery ---------- */
.gallery {
  position: relative;
  z-index: 2;
  padding: 110px 0;
}
.gallery-no-header {
  padding: 60px 0;
}
.gallery-no-header .gallery-showcase {
  margin-top: 0;
}
.gallery-heading-row { margin-bottom: 8px; }
.gallery-note {
  color: var(--gray-dim);
  font-size: 0.85rem;
  font-style: italic;
  margin: -24px 0 36px;
}

.gallery-showcase {
  width: 100%;
  margin: 36px auto 0;
  padding: 0 24px;
  display: flex;
  align-items: stretch;
  justify-content: center;
  gap: 24px;
}
.gallery-main {
  flex: 0 0 752px;
  max-width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: #000;
}
.gallery-main-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border: 0;
}
.youtube-facade {
  position: relative;
  width: 100%;
  height: 100%;
  display: block;
  padding: 0;
  border: 0;
  cursor: pointer;
  background: #000;
}
.youtube-facade-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.youtube-facade-play {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  transition: transform 0.2s ease;
}
.youtube-facade:hover .youtube-facade-play {
  transform: translate(-50%, -50%) scale(1.1);
}
.gallery-thumbs {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-template-rows: repeat(2, 1fr);
  flex-shrink: 0;
  gap: 12px;
  width: 680px;
  height: auto;
}
.gallery-thumb-item {
  width: 100%;
  height: 100%;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: #000;
}
.gallery-thumb-media {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}
.gallery-thumb-media-path {
  object-position: 20% center;
}
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.gallery-tile {
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  background: var(--bg-card);
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}
.gallery-tile:hover {
  transform: translateY(-5px);
  border-color: rgba(20, 184, 166, 0.4);
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.3);
}
.gallery-thumb {
  height: 160px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(244, 245, 246, 0.85);
}
.thumb-5 { background: linear-gradient(135deg, #2a1f3d 0%, #0d0f10 100%); }
.thumb-6 { background: linear-gradient(135deg, #3d2414 0%, #0d0f10 100%); }
.gallery-caption {
  text-align: center;
  padding: 14px 10px;
  font-size: 0.82rem;
  color: var(--gray);
  font-weight: 500;
  letter-spacing: 0.02em;
  border-top: 1px solid var(--border);
}

/* ---------- Contributions ---------- */
.contributions {
  position: relative;
  z-index: 2;
  padding: 110px 0;
  background: var(--bg-alt);
}
.contrib-list {
  max-width: 840px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.contrib-list li {
  position: relative;
  padding-left: 28px;
  color: var(--gray);
  font-size: 0.98rem;
  line-height: 1.7;
}
.contrib-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 9px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--teal);
}
.contrib-list strong { color: var(--white); font-weight: 600; }
.contrib-block {
  margin-bottom: 64px;
}
.contrib-block:last-child {
  margin-bottom: 0;
}
.contrib-heading {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 16px;
}
.contrib-list li.contrib-sub {
  margin-left: 24px;
}
.contrib-media {
  margin-top: 28px;
  max-width: 760px;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: #000;
}
.contrib-video {
  width: 100%;
  height: auto;
  display: block;
}
.contrib-media-mechanics {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  max-width: none;
  border: none;
  background: none;
}
.contrib-media-mechanics img {
  height: 140px;
  width: auto;
  max-width: 100%;
  object-fit: contain;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--bg-card);
  padding: 12px;
}
.contrib-media-duo {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  border: none;
  background: none;
  padding: 0;
}
.contrib-media-duo video {
  flex: 1 1 340px;
  width: 100%;
  display: block;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: #000;
}

/* ---------- Problem & Solution ---------- */
.problem-solution {
  position: relative;
  z-index: 2;
  padding: 100px 0;
  background: var(--bg-alt);
}
.ps-card {
  max-width: 840px;
  margin-bottom: 32px;
  padding: 28px 32px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--bg);
}
.ps-card:last-child {
  margin-bottom: 0;
}
.ps-problem {
  margin-bottom: 16px;
}
.ps-problem:last-of-type {
  margin-bottom: 20px;
}
.ps-label {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 3px 10px;
  border-radius: 999px;
  margin-bottom: 8px;
}
.ps-problem .ps-label {
  color: #e0665a;
  background: rgba(224, 102, 90, 0.12);
}
.ps-solution .ps-label {
  color: var(--teal);
  background: var(--teal-soft);
}
.ps-problem p,
.ps-solution p,
.ps-scrapped p {
  color: var(--gray);
  font-size: 0.98rem;
  line-height: 1.6;
}
.ps-solution {
  padding-top: 16px;
  border-top: 1px dashed var(--border);
}
.ps-scrapped {
  padding-top: 16px;
  margin-top: 16px;
  border-top: 1px dashed var(--border);
}
.ps-scrapped .ps-label {
  color: #8a8a8a;
  background: rgba(138, 138, 138, 0.15);
}

/* ---------- Project details block ---------- */
.project-details {
  position: relative;
  z-index: 2;
  padding: 100px 0;
}
.details-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  max-width: 980px;
}
.detail-item {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 18px 20px;
  background: rgba(255, 255, 255, 0.02);
}
.detail-label {
  display: block;
  color: var(--teal);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 8px;
}
.detail-value {
  display: block;
  color: var(--white);
  font-size: 0.96rem;
  font-weight: 600;
  line-height: 1.4;
}

/* ---------- Footer back link ---------- */
.footer-back { margin-bottom: 32px; }

/* ---------- Game detail responsive ---------- */
@media (max-width: 900px) {
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
  .details-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 760px) {
  .project-hero { padding-top: 120px; }
}
@media (max-width: 480px) {
  .gallery-grid { grid-template-columns: 1fr; }
  .details-grid { grid-template-columns: 1fr; }
  .meta-pills { gap: 10px; }
  .hero-ctas { flex-direction: column; align-items: stretch; }
  .hero-ctas .btn { text-align: center; }
}

/* ---------- Hextalia page: light theme ---------- */
body.theme-hextalia-light {
  --bg: #faf3d8;
  --bg-alt: #f2ead0;
  --bg-card: #ece0bd;
  --white: #1c3a40;
  --gray: #3f6b72;
  --gray-dim: #5c8790;
  --border: rgba(28, 58, 64, 0.18);
}
body.theme-hextalia-light #particles-js {
  display: none;
}
body.theme-hextalia-light .nav,
body.theme-hextalia-light .project-hero-video-bg {
  --bg: #0d0f10;
  --bg-alt: #131619;
  --bg-card: #16191c;
  --white: #f4f5f6;
  --gray: #a9b0b3;
  --gray-dim: #6d7477;
  --border: rgba(255, 255, 255, 0.08);
}

/* ---------- Twilights In CATATONIA page: peach/orange theme ---------- */
body.theme-twilights {
  --teal: #e8935a;
  --teal-soft: rgba(232, 147, 90, 0.14);
  --white: #f0b285;
}

/* ---------- Jelly's Journey page: purple/magenta theme ---------- */
body.theme-jellys {
  --teal: #d15fc0;
  --teal-soft: rgba(209, 95, 192, 0.14);
  --white: #e6a8dc;
}

/* ---------- Photon Dash page: electric cyan theme ---------- */
body.theme-photon {
  --teal: #2dd4da;
  --teal-soft: rgba(45, 212, 218, 0.14);
  --white: #7de8ec;
}
