:root {
  --accent: #ca9b52;
  --text: #464646;
  --title: #030303;
  --muted: #a1a1a1;
  --bg: #fff;
  --wrap: 1140px;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 15px/1.7 "Open Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-decoration: none; transition: color .2s, opacity .2s; }
a:hover { color: rgba(202, 155, 82, .8); }
h1, h2, h3 { color: var(--title); font-weight: 600; line-height: 1.3; }
hr { border: 0; border-top: 1px solid #e6e6e6; margin: 40px 0; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 16px 60px; }
.wrap.narrow { max-width: 860px; }
.center { text-align: center; }

/* fejléc + menü */
.site-header { padding: 28px 16px 22px; text-align: center; }
.logo { display: inline-block; }
.logo img { margin: 0 auto; }
.main-nav { background: #fff; box-shadow: 0 1px 5px rgba(0,0,0,.1); position: relative; z-index: 20; text-align: center; }
.main-nav ul { list-style: none; margin: 0; padding: 0; }
.main-nav > ul > li { display: inline-block; position: relative; }
.main-nav a { display: block; color: #000; padding: 0 18px; line-height: 52px; text-transform: uppercase; font-size: 13px; letter-spacing: .08em; }
.main-nav a:hover, .main-nav .current > a { color: var(--accent); }
.main-nav .sub { display: none; position: absolute; top: 100%; left: 0; min-width: 100%; background: #fff; box-shadow: 0 3px 8px rgba(0,0,0,.08); text-align: left; white-space: nowrap; }
.main-nav .sub a { line-height: 42px; }
.main-nav .has-sub:hover > .sub, .main-nav .has-sub:focus-within > .sub { display: block; }
.nav-toggle { display: none; background: none; border: 0; font-size: 24px; line-height: 52px; width: 100%; cursor: pointer; color: #000; }

@media (max-width: 800px) {
  .nav-toggle { display: block; }
  .main-nav > ul { display: none; border-top: 1px solid #eee; }
  .main-nav.open > ul { display: block; }
  .main-nav > ul > li { display: block; }
  .main-nav a { line-height: 44px; }
  .main-nav .sub { display: block; position: static; box-shadow: none; padding-left: 18px; }
}

/* főoldali slider */
.slider { position: relative; height: clamp(320px, 62vh, 640px); overflow: hidden; background: #111; margin-bottom: 36px; }
.slide { position: absolute; inset: 0; opacity: 0; transition: opacity 1s ease; pointer-events: none; }
.slide.active { opacity: 1; pointer-events: auto; }
.slide > img { width: 100%; height: 100%; object-fit: cover; }
.slide::after { content: ""; position: absolute; inset: 0; background: rgba(0,0,0,.28); }
.slide-info { position: absolute; z-index: 2; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; color: #fff; padding: 0 20px; }
.slide-info h2 { margin: 0; font-size: clamp(26px, 4vw, 44px); font-weight: 600; }
.slide-info h2 a { color: #fff; }
.slide-info p { margin: 6px 0 22px; font-size: 16px; letter-spacing: .08em; text-transform: uppercase; }
.button { color: #fff; border: 1px solid #fff; padding: 8px 26px; text-transform: uppercase; font-size: 12px; letter-spacing: .12em; }
.button:hover { background: #fff; color: #000; }
.dots { position: absolute; z-index: 3; bottom: 14px; left: 0; right: 0; text-align: center; }
.dot { width: 10px; height: 10px; border-radius: 50%; border: 1px solid #fff; background: transparent; margin: 0 5px; padding: 0; cursor: pointer; }
.dot.active { background: #fff; }

.social { display: flex; justify-content: center; gap: 36px; margin: 0; }
.social img { width: 40px; height: 40px; opacity: .85; transition: opacity .2s; }
.social a:hover img { opacity: 1; }

/* oldalak */
.page-title { text-align: center; font-size: 28px; margin: 36px 0 26px; }
.content table { border-collapse: collapse; }
.content td { padding: 4px 18px 4px 0; vertical-align: baseline; }
.person { display: grid; grid-template-columns: minmax(180px, 1fr) 2fr; gap: 30px; align-items: start; margin: 30px 0; }
.person h2 { font-size: 26px; margin: 10px 0 16px; }
@media (max-width: 700px) { .person { grid-template-columns: 1fr; } }

/* projekt kártyák */
.tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.tiles.two { grid-template-columns: repeat(2, 1fr); }
.tile { position: relative; display: block; aspect-ratio: 3 / 2; overflow: hidden; background: #222; }
.tiles.two .tile { aspect-ratio: 4 / 3; }
.tile img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease, opacity .3s; }
.tile:hover img { transform: scale(1.04); opacity: .8; }
.tile-title { position: absolute; left: 0; right: 0; bottom: 0; padding: 40px 14px 12px; color: #fff; text-align: center; font-size: 14px; line-height: 1.35;
  background: linear-gradient(transparent, rgba(0,0,0,.6)); }
.tiles.two .tile-title { top: 0; display: flex; align-items: center; justify-content: center; font-size: 26px; letter-spacing: .12em; background: rgba(0,0,0,.25); padding: 0; }
@media (max-width: 900px) { .tiles { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .tiles, .tiles.two { grid-template-columns: 1fr; } }

/* projekt oldal */
.facts { text-align: center; opacity: .6; margin: -10px 0 18px; }
.text { max-width: 760px; margin: 0 auto 30px; text-align: justify; hyphens: auto; }
.back { text-align: center; margin-top: 40px; }

/* galéria (sorokba igazított, arányos) */
.gallery { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.gallery li { flex: calc(var(--ar) * 100) 1 calc(var(--ar) * 240px); min-width: 0; }
.gallery::after { content: ""; flex-grow: 1000000; }
.gallery a { display: block; background: #eee; }
.gallery img { width: 100%; height: auto; transition: opacity .25s; }
.gallery a:hover img { opacity: .8; }

/* videók */
.videos { display: grid; gap: 30px; }
.video { position: relative; display: block; width: 100%; aspect-ratio: 16 / 9; border: 0; padding: 0; background: #000; cursor: pointer; }
.video img, .video iframe { width: 100%; height: 100%; object-fit: cover; border: 0; }
.play { position: absolute; left: 50%; top: 50%; width: 76px; height: 54px; margin: -27px 0 0 -38px; border-radius: 14px; background: rgba(0,0,0,.75); }
.play::after { content: ""; position: absolute; left: 31px; top: 15px; border-left: 20px solid #fff; border-top: 12px solid transparent; border-bottom: 12px solid transparent; }
.video:hover .play { background: var(--accent); }

/* lábléc */
.site-footer { text-align: center; padding: 30px 16px 40px; border-top: 1px solid #eee; color: var(--muted); font-size: 13px; position: relative; }
.site-footer p { margin: 0; }
.to-top { position: absolute; left: 50%; top: -18px; transform: translateX(-50%); width: 36px; height: 36px; background: #fff; border: 1px solid #ddd; border-radius: 50%; cursor: pointer; font-size: 18px; color: #666; }
.to-top:hover { color: var(--accent); border-color: var(--accent); }

/* lightbox */
.lightbox { position: fixed; inset: 0; z-index: 100; background: rgba(239,239,239,.97); display: none; align-items: center; justify-content: center; }
.lightbox.open { display: flex; }
.lightbox img { max-width: 94vw; max-height: 90vh; width: auto; height: auto; object-fit: contain; box-shadow: 0 2px 20px rgba(0,0,0,.15); }
.lightbox button { position: absolute; background: rgba(137,137,137,.85); color: #fff; border: 0; cursor: pointer; font-size: 26px; width: 44px; height: 44px; line-height: 44px; }
.lightbox button:hover { background: var(--accent); }
.lb-close { top: 0; right: 0; }
.lb-prev, .lb-next { top: 50%; margin-top: -22px; }
.lb-prev { left: 0; } .lb-next { right: 0; }
.lb-count { position: absolute; bottom: 10px; left: 0; right: 0; text-align: center; font-size: 13px; color: #555; }
