*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: 'Open Sans', system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", sans-serif;
  font-weight: 300;
  color: #ffffff;
  background: #000;
}

/* ============================= */
/*        KÖZÖS HERO STÍLUSOK    */
/* ============================= */

.hero {
  position: relative;
  min-height: 100vh;
  width: 100%;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  overflow: hidden;
}

/* 1. szekció háttere: csak a canvas animáció, nincs külön bg-kép */
.hero-1 {
  background: #000;
}

.hero-2 {
  background-image: url("images/nyito-bg-2.jpg");
}

.hero-3 {
  background-image: url("images/nyito-bg-3.jpg");
}

/* Sötét overlay – canvas fölé is kerül, de logó/szöveg fölött is */
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    rgba(0, 0, 0, 0.35),
    rgba(0, 0, 0, 0.1) 45%,
    rgba(0, 0, 0, 0.25)
  );
  pointer-events: none;
  z-index: 1;
}

.hero-inner {
  position: relative;
  width: 100%;
  max-width: 1365px;
  margin: 0 auto;
  height: 100vh;
  z-index: 2; /* overlay fölött */
}

/* CANVAS – animációs háttér az 1. szekcióban */
.hero-animation {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  z-index: 0;
}

/* ============================= */
/* 1. SZEKCIÓ – LOGÓ + IDÉZET    */
/* ============================= */

.hero-1-inner {
  padding: 0 8%;
}

/* LOGÓ – bal felső harmad */
.hero-logo {
  position: absolute;
  left: 5%;
  top: 22%;
  will-change: transform;
}

.hero-logo img {
  height: 80px;
  max-width: 100%;
}

/* IDÉZET – bal alsó-középső sáv */
.hero-1-text {
  position: absolute;
  left: 5%;
  top: 55%;
  max-width: 700px;
  will-change: transform;
}

/* KÖZÖS SZÖVEGSTÍLUSOK */
.quote-idezet {
  margin: 0 0 20px;
  font-size: 2.0rem;
  line-height: 1.25;
}

.quote-text {
  margin: 0 0 10px;
  font-size: 1.75rem;
  line-height: 1.25;
}

.quote-text2 {
  margin: 0 0 10px;
  font-size: 1.35rem;
  line-height: 1.5;
}

.quote-author {
  margin: 0;
  font-size: 0.9rem;
  letter-spacing: 0.08em;
}

/* TELJES KÉPERNYŐS BRANDELT LOADER */
.hero-loader{
  position: fixed;
  inset: 0;
  background: #000;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  z-index: 20000;
  opacity: 1;
  transition: opacity 0.6s ease;
}

.hero-loader.hidden{
  opacity: 0;
  pointer-events: none;
}

/* SVG LOGÓ */
.dd-loader{
  width: 220px;
  height: auto;
  overflow: visible;
  opacity: 0;                 /* ne villanjon be “készen” */
  transition: opacity 0.15s ease;
}

/* csak akkor jelenik meg, amikor a JS már beállította a dash értékeket */
.hero-loader.dd-ready .dd-loader{
  opacity: 1;
}

/* stroke alap (fallback) */
.dd-stroke{
  fill: none;
  stroke: #ffffff;
  stroke-width: 18px;
  stroke-linecap: round;
  stroke-linejoin: round;

  stroke-dasharray: 1;
  stroke-dashoffset: 1;

  animation: none;
}

/* Rajzolás közben: gradient + glow */
.hero-loader { will-change: opacity; }

.hero-loader.is-drawing .dd-stroke{
  stroke: url(#ddGrad);
  /* iOS/Safari-barát glow */
  filter: drop-shadow(0 0 6px rgba(255,255,255,0.55))
          drop-shadow(0 0 14px rgba(132,175,179,0.35));
}

@keyframes ddDraw{
  to { stroke-dashoffset: 0; }
}

/* pulzálás a végén */
.dd-stroke.dd-pulse{
  animation: ddPulse 1.8s ease-in-out infinite;
}

@keyframes ddPulse{
  0%   { opacity: 1; }
  50%  { opacity: 0.65; }
  100% { opacity: 1; }
}

/* Szöveg */
.dd-loading-text{
  margin-top: 20px;
  font-size: 0.9rem;
  letter-spacing: 0.13em;
  color: #999;
  animation: ddFadeText 1.8s ease-in-out infinite;
}

@keyframes ddFadeText{
  0%   { opacity: 0.4; }
  50%  { opacity: 0.9; }
  100% { opacity: 0.4; }
}

/* ============================= */
/* ÁLTALÁNOS SPLIT SZEKCIÓK      */
/* (2., 3., 4., 5. szekciók)     */
/* ============================= */

.hero-split-inner {
  padding: 0 5%;
  display: flex;
  align-items: center;
  min-height: 80vh;
}

.hero-split-content {
  width: 100%;
  display: flex;
  align-items: center;        /* SZÖVEG és PNG/GRID közepe egy vonalban */
  justify-content: space-between;
  gap: 20px;
}

/* BAL OLDALI SZÖVEG BLOKK */
.hero-split-text {
  max-width: 520px;
  will-change: transform;
}

/* JOBB OLDALI PNG BLOKK / GRID WRAPPER */
.hero-image-wrapper {
  display: flex;
  align-items: center;
  justify-content: center;
  will-change: transform;
}

/* Alap 1:1 kép (3., 4., 5. szekció) */
.hero-image {
  width: 50vw;
  max-width: 600px;
  aspect-ratio: 1 / 1;
}

.hero-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* ============================= */
/*           LÁBLÉC              */
/* ============================= */

.footer-logo {
  width: 120px;
  margin-bottom: 12px;
  opacity: 0.95;
}

.footer-col-brand {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.footer {
  background: #0e0e0e;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding: 40px 0 20px;
}

.footer-inner {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto 16px;
  padding: 0 20px;

  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 32px;
  align-items: end;
}

.footer-col h3 {
  margin: 0 0 12px;
  font-size: 1rem;
  letter-spacing: 0.08em;
}

.footer-col p {
  margin: 0 0 8px;
  font-size: 0.9rem;
  line-height: 1.6;
  color: #d4d4d4;
}

.footer-col a {
  color: #ffffff;
  text-decoration: none;
}

.footer-col a:hover {
  color: #a4c5d0;
  text-decoration: none;
}

.footer-bottom {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 10px;
}

.footer-bottom p {
  margin: 0;
  font-size: 0.8rem;
  color: #9a9a9a;
}
/* KATTINTHATÓ SZIMPLA KÉPEK (Single) */
.hero-image img {
  cursor: pointer;
  transition: transform 0.3s ease;
  will-change: transform;
}

.hero-image img:hover {
  transform: scale(1.03); /* Pici nagyítás, mint a gridnél */
}
/* ============================= */
/*       2×2 KÉPRÁCS (GRID)      */
/* ============================= */

.image-grid-2x2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-auto-rows: 1fr;
  gap: 30px;

  width: 38vw;
  max-width: 560px;
}

.image-grid-2x2 .grid-item {
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: visible;
  background: transparent;
  transform: translateZ(0);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* Kép + videó ugyanúgy viselkedjen */
.image-grid-2x2 img,
.image-grid-2x2 video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

/* Finom hover: az EGÉSZ tile jön előrébb */
.image-grid-2x2 .grid-item:hover {
  transform: scale(1.04);
  box-shadow:none;
}

/* VEGYES RÁCS (2 kicsi felül, 1 széles alul) */
.image-grid-mixed .grid-item:nth-child(3) {
  grid-column: span 2;   /* Átéri a 2 oszlopot */
  aspect-ratio: 2.1 / 1; /* Fekvő képarány (szélesebb, mint magas) */
  object-fit: cover;
}

/* Mobilon is maradjon meg a fekvő arány a 3. képnél */
@media (max-width: 768px) {
  .image-grid-mixed .grid-item:nth-child(3) {
    aspect-ratio: 2 / 1;
  }
}

/* ============================= */
/*     HAMBURGER MENU BUTTON     */
/* ============================= */

.menu-button {
  position: fixed;
  top: 24px;
  right: 24px;
  width: 34px;
  height: 28px;
  cursor: pointer;
  z-index: 10001;

  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.menu-button div {
  height: 4px;
  background: #fff;
  border-radius: 2px;
  transition: 0.3s;
}

/* ANIMÁLT X ÁLLAPOT */
.menu-button.active div:nth-child(1) {
  transform: translateY(12px) rotate(45deg);
}
.menu-button.active div:nth-child(2) {
  opacity: 0;
}
.menu-button.active div:nth-child(3) {
  transform: translateY(-12px) rotate(-45deg);
}

/* ============================= */
/* KÉP / VIDEÓ LIGHTBOX (Javított) */
/* ============================= */

.image-lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.50);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  
  display: flex;
  align-items: center;
  justify-content: center;
  
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 9999;
}

.image-lightbox.active {
  opacity: 1;
  pointer-events: auto;
}

.image-lightbox-content {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;

  /* --- ALAPÉRTELMEZETT (MOBIL) --- */
  /* Mobilon maradjon nagy, majdnem teljes képernyő */
  width: 95vw;
  max-height: 85vh;

  /* Animációk */
  transform: scale(0.92);
  opacity: 0;
  transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1), 
              opacity 0.4s ease-out;
}

/* --- ASZTALI NÉZET (Javított méretek) --- */
/* Ha a képernyő szélesebb, mint 768px (tablet/desktop) */
@media (min-width: 769px) {
  .image-lightbox-content {
    width: auto;       /* Hagyjuk, hogy a kép aránya döntsön */
    max-width: 800px;  /* Limitáljuk a szélességet (kb. a korábbi 80%-a) */
    max-height: 80vh;  /* A magasságot is visszafogjuk */
  }
}

.image-lightbox.active .image-lightbox-content {
  transform: scale(1);
  opacity: 1;
}

.image-lightbox-content img,
.image-lightbox-content video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  
  /* JAVÍTÁS: Árnyék (box-shadow) eltávolítva a PNG-k miatt! */
  box-shadow: none; 
  
  border-radius: 4px;
}
/* ============================= */
/*        SIDE NAV MENU          */
/* ============================= */

.side-nav {
  position: fixed;
  top: 0;
  right: -260px;
  width: 260px;
  height: 100vh;
  background: rgba(0,0,0,0.92);
  padding: 80px 30px;
  transition: right 0.35s ease;
  z-index: 10000;
}

.side-nav.open {
  right: 0;
}

.side-nav ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

/* Alapállapot: láthatatlan, kicsit lejjebb tolva */
.side-nav li {
  margin-bottom: 22px;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.35s ease, transform 0.35s ease;
}

/* Megnyitott menü esetén felúsznak és látszanak */
.side-nav.open li {
  opacity: 1;
  transform: translateY(0);
}

/* LÉPCSŐZETES KÉSLELTETÉS */
.side-nav.open li:nth-child(1) { transition-delay: 0.05s; }
.side-nav.open li:nth-child(2) { transition-delay: 0.10s; }
.side-nav.open li:nth-child(3) { transition-delay: 0.15s; }
.side-nav.open li:nth-child(4) { transition-delay: 0.20s; }
.side-nav.open li:nth-child(5) { transition-delay: 0.25s; }
.side-nav.open li:nth-child(6) { transition-delay: 0.30s; }

.side-nav a {
  color: white;
  font-size: 1.1rem;
  text-decoration: none;
  letter-spacing: 0.05em;
}

.side-nav a:hover {
  opacity: 0.7;
}

.side-nav a.active {
  color: #9cbdc8;
  font-weight: 400;
  opacity: 1 !important;
}

/* ============================= */
/*        MENU OVERLAY           */
/* ============================= */

.menu-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
  z-index: 9990;
}

.menu-overlay.visible {
  opacity: 1;
  pointer-events: auto;
}

/* ============================= */
/*        RESPONSIVE / TABLET    */
/* ============================= */

@media (max-width: 1024px) {
  .hero-inner {
    max-width: 100%;
    padding: 0 20px;
  }

  .hero-logo img {
    height: 70px;
  }

  .quote-text {
    font-size: 1.45rem;
  }

  .quote-text2 {
    font-size: 1.1rem;
  }

  .hero-image {
    width: 80vw;
    max-width: 400px;
  }
}

/* ============================= */
/* MOBIL (<= 768px)              */
/* ============================= */

@media (max-width: 768px) {
.hero-section {
    /* Biztosítjuk, hogy a fő dobozban a tartalom felül kezdődjön */
    align-items: flex-start !important; 
    height: 100vh; /* Mobilon fix magasság */
  }
  .hero-1-inner {
    padding: 10vh 30px 0; 
    display: flex;
    flex-direction: column;
    justify-content: flex-start; !important;
    align-items: flex-start;     
    text-align: left;            
    height: 100%; 
    min-height: 100%;
  }

  .hero-logo {
    position: relative;
    /* A logót kivételesen KÖZÉPRE igazítjuk vízszintesen */
    align-self: felx-start;       
    
    /* Távolság a logó és az alatta lévő szöveg között */
    margin-top: 0;
	margin-bottom: 40px;      
  }

  .hero-logo img {
    height: 70px; /* Kisebb logó (eddig 90px volt) */
    width: auto;
 }

  .hero-1-text {
    position: relative;
    max-width: 100%;
    text-align: left; 
  }

  .quote-idezet {
    font-size: 1.3rem; 
    line-height: 1.4;
    margin-bottom: 15px;
  }
  
  .quote-author {
    font-size: 0.9rem;
	margin-left: 2px;
  }

  /* 2-6. SZEKCIÓ (SPLIT) */
  .hero-split-inner {
    padding: 60px 20px;
    display: flex;
    flex-direction: column;
    justify-content: center; 
    align-items: center;     
    min-height: 130vh;
    text-align: center;
	height: auto;
  }

  .hero-split-content {
/* Ez a doboz nyúlik meg, hogy kitöltse a 130vh-t */
    flex: 1; 
    display: flex;
    flex-direction: column;
    
    /* JAVÍTÁS: ARÁNYOS ELOSZTÁS */
    /* A space-evenly egyenlő helyet rak a szöveg FÖLÉ, KÖZÉ és a kép ALÁ is. */
    justify-content: space-evenly; 
    
    align-items: center;
    width: 100%;
    
    /* Ha mégis kellene minimális fix távolság, ez megmaradhat, 
       de a space-evenly általában megoldja: */
    gap: 20px;
  }
  
  .hero-split-text {
    max-width: 100%;
  }

  .quote-text {
    font-size: 1.35rem;
  }

  .quote-text2 {
    font-size: 1.05rem;
  }

  .hero-image {
    width: 90vw;
    max-width: 420px;
  }

  .image-grid-2x2 {
    width: 90vw;
    max-width: 360px;
    gap: 25px;
    grid-template-columns: repeat(2, 1fr);
  }
/* ============================= */
  /* HAMBURGER MENÜ SZÍN JAVÍTÁS   */
  /* ============================= */

  .menu-toggle span {
    /* A vonalak színe legyen fehér */
    background-color: #ffffff !important; 
  }
  
  /* Ha esetleg kerete is van, vagy ikon, akkor ez is kellhet: */
  .menu-toggle {
    color: #ffffff !important;
  }
/* ============================= */
  /* LOADER MÉRET MOBILON          */
  /* ============================= */
  
  /* A logó méretét 220px-ről 150px-re csökkentjük */
  .dd-loader {
    width: 150px; 
  }

  /* A vonalvastagságot is arányosan vékonyítjuk (20px -> 12px), 
     hogy ne legyen túl tömör a rajz */
  .dd-stroke {
    stroke-width: 14px;
  }
  /* LÁBLÉC */
  .footer-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 30px;
  }

  .footer-col {
    width: 100%;
    align-items: center;
  }
  
  .footer-col-brand {
    align-items: center;
  }
  
  .footer-logo {
    margin: 0 auto 12px;
  }

  .image-lightbox-content {
    width: 95vw;
  }
}