/* Shared styles for all pages */
:root { --font-display: 'Saira', system-ui, sans-serif; }
html { -webkit-font-smoothing: antialiased; }
body { background: #FFFFFF; }
[hidden] { display: none !important; }

/* Wordmark: the SVG is used as a mask so it can take any color and switch language */
/* Both languages share one box (the taller EN ratio) and are top-aligned, so switching language
   never moves the first line of the name. */
.wordmark { display: block; aspect-ratio: 3700 / 594; background-color: currentColor; -webkit-mask: var(--wm) no-repeat left top / contain; mask: var(--wm) no-repeat left top / contain; }
.wordmark[data-lang-mark="hu"] { --wm: url(wordmark-hu.svg); }
.wordmark[data-lang-mark="en"] { --wm: url(wordmark-en.svg); }

/* Scroll reveal */
[data-reveal] { opacity: 0; transform: translateY(24px); transition: opacity .9s ease, transform .9s cubic-bezier(.16,1,.3,1); }
[data-reveal].in { opacity: 1; transform: none; }

/* Language toggle */
.lang-toggle { border-color: color-mix(in srgb, currentColor 25%, transparent); }
.lang-toggle .knob { transition: transform .35s cubic-bezier(.16,1,.3,1); }
.lang-toggle[data-lang="en"] .knob { transform: translateX(100%); }
.lang-toggle [data-opt] { transition: color .3s; }

/* Nav – default (subpages): light header from the start */
#siteNav { background: rgba(255,255,255,.86); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); color: #004A63; transition: background-color .4s, box-shadow .4s, color .4s; }
#siteNav.scrolled { box-shadow: 0 1px 0 rgba(0,74,99,.08); }
.nav-mark-light { display: none; }
/* Nav – over a dark hero (body[data-nav="hero"]): transparent + white until scrolled */
body[data-nav="hero"] #siteNav:not(.scrolled) { background: transparent; backdrop-filter: none; -webkit-backdrop-filter: none; color: #fff; }
body[data-nav="hero"] #siteNav:not(.scrolled) .nav-mark-light { display: block; }
body[data-nav="hero"] #siteNav:not(.scrolled) .nav-mark-dark { display: none; }

/* Back-to-top button */
#toTop { opacity: 0; transform: translateY(16px) scale(.9); pointer-events: none; transition: opacity .35s, transform .35s cubic-bezier(.16,1,.3,1), background-color .3s; }
#toTop.show { opacity: 1; transform: none; pointer-events: auto; }
#toTop:hover svg { transform: translateY(-2px); }
#toTop svg { transition: transform .3s; }

/* Person photo placeholder (initials on a brand gradient) */
.avatar-ph { background:
    radial-gradient(120% 90% at 80% 0%, rgba(131,197,190,.55), transparent 60%),
    linear-gradient(160deg, #0A5C79 0%, #004A63 55%, #002A39 100%); }

.prose-ebmi p + p { margin-top: 1.1em; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* Active menu item */
#siteNav [aria-current="page"] { color: #43918A; }
body[data-nav="hero"] #siteNav:not(.scrolled) [aria-current="page"] { color: #83C5BE; }
.prose-ebmi > * + * { margin-top: 1em; }

/* Working-group icon chip: on card hover it lifts forward and turns silver with a dark glyph */
.icon-chip { position: relative; isolation: isolate; overflow: hidden; transition: transform .4s cubic-bezier(.16,1,.3,1), box-shadow .4s, color .35s; }
.icon-chip::before { content: ''; position: absolute; inset: 0; z-index: -1; opacity: 0; transition: opacity .35s;
  background: linear-gradient(135deg, #F8FAFB 0%, #DCE3E7 35%, #AEB9BF 62%, #E9EEF1 82%, #C3CCD1 100%); }
.group:hover .icon-chip, .group:focus-visible .icon-chip {
  transform: translateY(-3px) scale(1.12); color: #002A39;
  box-shadow: 0 14px 28px -10px rgba(0,27,37,.5), inset 0 1px 0 rgba(255,255,255,.9), inset 0 -1px 0 rgba(0,42,57,.15); }
.group:hover .icon-chip::before, .group:focus-visible .icon-chip::before { opacity: 1; }
.group:hover .icon-chip svg, .group:focus-visible .icon-chip svg { color: #002A39 !important; stroke-width: 2.1; }
