/* Shared shell helpers for template mounts. */
:root {
  --content-max: 1400px;
  --near-black: #0e0e10;
  --ease-out: cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --ease-expo: cubic-bezier(0.16, 1, 0.3, 1);
}

/* Extra top offset under fixed “promo” header (tall logo) — inner pages + állás */
/* Aloldalak + média: magas promó fejléc + háromszög — extra hely a tartalomnak */
.shell-page-content {
  --shell-header-slot: calc(var(--header-h, 64px) + 72px);
}

/* Álláshirdetés részletek: kompakt fejléc (ugyanaz a slot, mint a sima #header) */
.shell-page-job {
  --shell-header-slot: var(--header-h, 64px);
}

[data-site-header],
[data-site-menu],
[data-site-footer] {
  display: contents;
}

/* Prevent flashes before JS mounts dynamic shell fragments. */
html:not(.shell-ready) [data-site-header],
html:not(.shell-ready) [data-site-menu],
html:not(.shell-ready) [data-site-footer] {
  display: none;
}

/* Shared content-shell chrome (header/menu/footer) */
#header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-h);
  z-index: 900;
  display: flex;
  align-items: center;
  padding: 0 40px;
  transition: color 0.5s var(--ease-out), background 0.5s var(--ease-out), border-color 0.5s var(--ease-out);
  color: var(--shell-header-color, var(--near-black));
  border-bottom: 1px solid var(--shell-header-border, rgba(14,14,16,0.12));
  background: var(--shell-header-bg, rgba(255,255,255,0.85));
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

#header.on-dark {
  color: var(--shell-on-dark-color, var(--white));
  border-bottom-color: var(--shell-on-dark-border, rgba(255,255,255,0.15));
  background: var(--shell-on-dark-bg, rgba(14,14,16,0.85));
}

#header.on-light {
  color: var(--shell-on-light-color, var(--near-black));
  border-bottom-color: var(--shell-on-light-border, rgba(14,14,16,0.1));
  background: var(--shell-on-light-bg, rgba(255,255,255,0.85));
}

.header-logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  margin-right: 48px;
}

.header-logo img {
  height: 28px;
  width: auto;
  filter: var(--shell-logo-filter-default, none);
  transition: filter 0.5s var(--ease-out);
}

#header.on-dark .header-logo img {
  filter: brightness(0) invert(1);
}

#header.on-light .header-logo img {
  filter: none;
}

#header nav {
  display: flex;
  align-items: center;
  gap: 36px;
  flex: 1;
}

#header nav a {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: currentColor;
  position: relative;
  padding-bottom: 3px;
  opacity: var(--shell-nav-opacity, 0.75);
  transition: opacity 0.2s;
}

#header nav a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s var(--ease-expo);
}

#header nav a.active::after,
#header nav a:hover::after {
  transform: scaleX(1);
}

#header nav a:hover,
#header nav a.active {
  opacity: 1;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 24px;
  flex-shrink: 0;
  margin-left: auto;
}

.lang-switch {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
}

.lang-switch a {
  color: currentColor;
  opacity: 0.45;
  transition: opacity 0.2s;
}

.lang-switch a.active {
  opacity: 1;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.lang-divider {
  opacity: 0.25;
  font-weight: var(--shell-lang-divider-weight, 300);
}

.hamburger-btn {
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px 4px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.hamburger-btn span {
  display: block;
  width: 20px;
  height: 1.5px;
  background: currentColor;
}

#menu-overlay {
  position: fixed;
  inset: 0;
  background: var(--blue);
  z-index: 1000;
  display: flex;
  flex-direction: column;
  transform: translateY(-100%);
  transition: transform 0.7s cubic-bezier(0.76, 0, 0.24, 1);
}

#menu-overlay.open {
  transform: translateY(0);
}

.menu-header {
  height: var(--header-h);
  display: flex;
  align-items: center;
  padding: 0 40px;
  border-bottom: 1px solid rgba(255,255,255,0.18);
  flex-shrink: 0;
}

.menu-header .menu-logo img {
  height: 28px;
  filter: brightness(0) invert(1);
}

.menu-close {
  margin-left: auto;
  background: none;
  border: none;
  cursor: pointer;
  width: 32px;
  height: 32px;
  position: relative;
}

.menu-close::before,
.menu-close::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 20px;
  height: 1.5px;
  background: white;
}

.menu-close::before { transform: translate(-50%,-50%) rotate(45deg); }
.menu-close::after  { transform: translate(-50%,-50%) rotate(-45deg); }

.menu-body {
  flex: 1;
  display: flex;
  align-items: center;
  padding: 0 80px;
}

.menu-nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.menu-nav a {
  font-size: clamp(32px, 5vw, 60px);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: white;
  line-height: 1.15;
  display: inline-block;
  transition: opacity 0.2s;
}

.menu-nav a:hover { opacity: 0.5; }

.menu-nav a::before {
  content: attr(data-num);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.15em;
  vertical-align: super;
  margin-right: 16px;
  opacity: 0.5;
}

.menu-footer-bar {
  padding: 32px 80px;
  border-top: 1px solid rgba(255,255,255,0.18);
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  flex-shrink: 0;
  flex-wrap: wrap;
  gap: 24px;
}

.menu-contact {
  color: rgba(255,255,255,0.75);
  font-size: 13px;
  line-height: 1.7;
}

.menu-contact strong { color: white; }

.menu-social { display: flex; gap: 28px; }

.menu-social a {
  color: white;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  opacity: 0.7;
  transition: opacity 0.2s;
}

.menu-social a:hover { opacity: 1; }

footer {
  background: var(--near-black);
  padding: 80px 80px 60px;
}

.footer-grid {
  max-width: 1400px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2.2fr 1fr 1fr 1fr;
  gap: 60px;
  padding-bottom: 48px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.footer-brand img {
  height: 34px;
  filter: brightness(0) invert(1);
  margin-bottom: 24px;
}

.footer-brand p {
  font-size: 14px;
  line-height: 1.75;
  color: rgba(255,255,255,0.45);
  max-width: 280px;
}

.footer-col h4 {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.3);
  margin-bottom: 20px;
}

.footer-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-col ul li a {
  font-size: 14px;
  color: rgba(255,255,255,0.6);
  transition: color 0.2s;
}

.footer-col ul li a:hover { color: white; }

.footer-bottom {
  max-width: 1400px;
  margin: 36px auto 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-bottom p {
  font-size: 12px;
  color: rgba(255,255,255,0.25);
}

.footer-bottom a {
  color: rgba(255,255,255,0.25);
  transition: color 0.2s;
}

.footer-bottom a:hover { color: rgba(255,255,255,0.6); }

/* Aloldalak: csak a főoldal alsó sávja (nincs hasábos blokk) */
footer.footer-bar-only {
  background: var(--near-black);
  padding: 14px max(24px, calc((100vw - var(--content-max)) / 2)) 16px;
}

footer.footer-bar-only .footer-bottom {
  margin: 0 auto;
  max-width: var(--content-max);
}

.shell-page-content footer.footer-bar-only .footer-bottom,
.shell-page-job footer.footer-bar-only .footer-bottom {
  gap: 20px;
}

@media (max-width: 980px) {
  #header {
    padding: 0 22px;
  }

  #header nav {
    gap: 20px;
    overflow-x: auto;
  }

  .menu-body { padding: 0 24px; }
  .menu-footer-bar { padding: 28px 24px; }
  footer { padding: 56px 24px 44px; }

  footer.footer-bar-only {
    padding: 12px 24px 14px;
  }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 34px; }
}

@media (max-width: 680px) {
  .menu-nav a { font-size: 34px; }
  .footer-grid { grid-template-columns: 1fr; }
}

/* Promo header (nagy logó): tömör szín, nincs átlátszóság — sáv és háromszög ugyanaz a --menu-surface */
.shell-page-landing #header,
.shell-page-content #header {
  --menu-surface: #e4e5ea;
  padding-inline: max(24px, calc((100vw - var(--content-max)) / 2));
  color: var(--near-black);
  border-bottom: 1px solid #cdd0d6;
  background: var(--menu-surface);
  box-shadow:
    inset 0 1px 0 #f6f7f9,
    0 10px 28px #c4c6cc;
  transition: color 0.45s var(--ease-out),
    border-color 0.45s var(--ease-out),
    background 0.45s var(--ease-out),
    box-shadow 0.45s var(--ease-out),
    transform 0.6s var(--ease-expo),
    opacity 0.6s var(--ease-expo);
  overflow: visible;
}

.shell-page-landing #header {
  transform: translateY(-100%);
  opacity: 0;
}

.shell-page-landing #header.visible {
  transform: translateY(0);
  opacity: 1;
}

.shell-page-landing #header.on-dark,
.shell-page-content #header.on-dark {
  --menu-surface: #141518;
  color: #fff;
  border-bottom-color: #2c2d32;
  background: var(--menu-surface);
  box-shadow:
    inset 0 1px 0 #2a2b30,
    0 12px 36px #0a0a0c;
}

.shell-page-landing .header-logo,
.shell-page-content .header-logo {
  margin-right: 40px;
  position: relative;
  z-index: 2;
  padding: 64px 0 3px 0;
}

.shell-page-landing .header-logo img,
.shell-page-content .header-logo img {
  height: 100px;
  transform: translateY(0);
  position: relative;
  z-index: 2;
}

/* Háromszög = ugyanaz a tömör --menu-surface mint a sáv (nincs blur / átlátszóság) */
.shell-page-landing .header-logo::after,
.shell-page-content .header-logo::after {
  content: '';
  position: absolute;
  left: 50%;
  width: 124px;
  height: 88px;
  transform: translateX(-50%) translateY(-4px);
  top: calc(50% + (var(--header-h) / 2) - 1px);
  background: var(--menu-surface);
  clip-path: polygon(0 0, 100% 0, 50% 100%);
  pointer-events: none;
  z-index: 1;
  transition: background 0.45s var(--ease-out),
    transform 0.35s var(--ease-expo),
    width 0.25s var(--ease-expo),
    height 0.25s var(--ease-expo);
}

.shell-page-landing #header nav a,
.shell-page-content #header nav a {
  white-space: nowrap;
  opacity: 0.88;
}

.shell-page-landing #header.on-dark nav a,
.shell-page-content #header.on-dark nav a {
  opacity: 0.9;
}

.shell-page-landing .lang-switch a:hover,
.shell-page-content .lang-switch a:hover {
  opacity: 0.8;
}

.shell-page-landing .menu-close,
.shell-page-content .menu-close {
  color: white;
}

.shell-page-landing .menu-nav a,
.shell-page-content .menu-nav a {
  transition: opacity 0.2s, transform 0.2s;
  transform-origin: left;
}

.shell-page-landing footer {
  padding: 0 80px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.shell-page-landing .footer-grid {
  grid-template-columns: minmax(280px, 1fr) minmax(340px, 460px);
  justify-content: space-between;
  gap: 80px;
  align-items: start;
}

.shell-page-landing .footer-brand img {
  margin-bottom: 28px;
}

.shell-page-landing .footer-brand p {
  max-width: 320px;
}

.shell-page-landing .footer-contact-panel {
  border: 1px solid rgba(255,255,255,0.14);
  background: linear-gradient(to bottom, rgba(255,255,255,0.04), rgba(255,255,255,0.01));
  padding: 22px;
}

.shell-page-landing .footer-contact-panel h4 {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.42);
  margin-bottom: 10px;
}

.shell-page-landing .footer-contact-panel p {
  font-size: 13px;
  line-height: 1.7;
  color: rgba(255,255,255,0.5);
  margin-bottom: 14px;
}

.shell-page-landing .contact-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.shell-page-landing .contact-form select,
.shell-page-landing .contact-form input,
.shell-page-landing .contact-form textarea {
  width: 100%;
  padding: 13px 14px;
  border: 1px solid rgba(255,255,255,0.2);
  background: rgba(255,255,255,0.02);
  color: rgba(255,255,255,0.85);
  font-size: 13px;
  font-family: inherit;
  transition: border-color 0.2s, background-color 0.2s, box-shadow 0.2s;
}

.shell-page-landing .contact-form select:focus,
.shell-page-landing .contact-form input:focus,
.shell-page-landing .contact-form textarea:focus {
  outline: none;
  border-color: rgba(0,163,224,0.85);
  box-shadow: 0 0 0 3px rgba(0,163,224,0.15);
  background: rgba(255,255,255,0.06);
}

.shell-page-landing .contact-form textarea {
  min-height: 128px;
  resize: vertical;
  line-height: 1.5;
}

.shell-page-landing .contact-form select option {
  color: #161616;
}

.shell-page-landing .contact-form button {
  padding: 12px 14px;
  border: 1px solid rgba(255,255,255,0.4);
  background: rgba(255,255,255,0.02);
  color: rgba(255,255,255,0.88);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s, background-color 0.2s;
}

.shell-page-landing .contact-form button:hover {
  border-color: rgba(0,163,224,0.85);
  background: rgba(0,163,224,0.2);
  color: white;
}

.shell-page-landing .footer-bottom {
  margin: 32px auto 0;
  gap: 20px;
}

@media (max-width: 900px) {
  .shell-page-landing .header-logo,
  .shell-page-content .header-logo {
    padding: 35px 0 3px 0;
  }

  .shell-page-landing .header-logo img,
  .shell-page-content .header-logo img {
    height: 64px;
    transform: translateY(16px);
  }

  .shell-page-landing .header-logo::after,
  .shell-page-content .header-logo::after {
    width: 82px;
    height: 60px;
    transform: translateX(-50%) translateY(-3px);
  }

  .shell-page-landing .footer-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .shell-page-landing .footer-contact-panel {
    max-width: 460px;
  }
}
