/* =====================================================================
   ONYX - uveg + 3D dizajn (index-uj.html)
   A script.js altal hasznalt osztalyok/ID-k valtozatlanok; ez a fajl csak
   a megjelenest adja. A mozgast az onyx-motion.js (DOM) es az onyx-scene.js
   (WebGL hatter) vezerli.
   ===================================================================== */

:root {
  color-scheme: dark;
  --bg: #05070b;
  --text: #f7f3ea;
  --text-2: #d8dcdf;
  --muted: #a2acb4;
  --faint: #6e7881;
  --gold: #d6a84f;
  --gold-2: #f2d38a;
  --gold-deep: #9a722b;
  --teal: #29d2c5;
  --teal-2: #8ff5ec;
  --red: #ff5a67;
  --red-2: #ffb3ba;
  --discord: #5865f2;
  --accent: var(--gold-2);

  --glass-fill: linear-gradient(135deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.035) 44%, rgba(255, 255, 255, 0.06));
  --glass-line: rgba(255, 255, 255, 0.13);
  --glass-shadow: 0 30px 80px -26px rgba(0, 0, 0, 0.7);
  --inner-highlight: inset 0 1px 0 rgba(255, 255, 255, 0.16);
  --lite-fill: rgba(255, 255, 255, 0.045);
  --lite-fill-hover: rgba(255, 255, 255, 0.08);
  --lite-line: rgba(255, 255, 255, 0.09);
  --solid-panel: linear-gradient(160deg, rgba(21, 26, 36, 0.97), rgba(10, 13, 19, 0.98));
  --field-bg: rgba(4, 6, 10, 0.62);

  --r-xl: 30px;
  --r-lg: 22px;
  --r-md: 16px;
  --r-sm: 12px;
  --r-pill: 999px;

  --shell: min(1180px, calc(100% - 40px));
  --topbar-h: 64px;
  --topbar-gap: 14px;
  --header-space: calc(var(--banner-h, 0px) + var(--topbar-gap) + var(--topbar-h) + 22px);

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-soft: cubic-bezier(0.4, 0, 0.2, 1);
  --font-display: "Sora", "Inter", system-ui, sans-serif;
  --font-body: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

/* ---------------------------------------------------------------------
   Alapok
   --------------------------------------------------------------------- */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  background: var(--bg);
  -webkit-text-size-adjust: 100%;
  scrollbar-width: thin;
  scrollbar-color: rgba(214, 168, 79, 0.65) transparent;
}

*::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

*::-webkit-scrollbar-track {
  background: transparent;
}

*::-webkit-scrollbar-thumb {
  border: 3px solid transparent;
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(242, 211, 138, 0.85), rgba(41, 210, 197, 0.7)) padding-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body.cart-open {
  overflow: hidden;
}

::selection {
  background: rgba(214, 168, 79, 0.35);
  color: #fff;
}

/* Csak a folyo szoveg es az urlapmezok jelolhetok ki. A feliratok, gombok, kartyak es a 3D
   elemek nem: kattintgatas, huzas kozben ne villanjon fel rajtuk a kijeloles, es az arany
   (szinatmenetes) feliratok se valjanak kijeloleskor feher dobozza. */
body {
  -webkit-user-select: none;
  user-select: none;
}

p:not(.eyebrow),
li,
input,
textarea,
select,
[contenteditable],
.sale-banner {
  -webkit-user-select: text;
  user-select: text;
}

/* Kattinthato kartyak szovege sem (a <html> is kap data-route-ot, ezert a body alatt). */
button p,
body [data-route] p {
  -webkit-user-select: none;
  user-select: none;
}

h1,
h2,
h3,
h4 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -0.02em;
  overflow-wrap: break-word;
  text-wrap: balance;
}

p {
  margin: 0;
  overflow-wrap: break-word;
}

img {
  max-width: 100%;
}

button,
input,
textarea,
select {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
}

a {
  color: inherit;
}

:focus-visible {
  outline: 2px solid var(--gold-2);
  outline-offset: 3px;
}

.hidden {
  display: none !important;
}

[hidden] {
  display: none !important;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 14px;
  color: var(--gold-2);
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.26em;
  line-height: 1.4;
  text-transform: uppercase;
}

.eyebrow::before {
  content: "";
  flex: 0 0 auto;
  width: 22px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold));
}

/* ---------------------------------------------------------------------
   Kozos 3D ter: hatter, varos, WebGL vaszon, fatyol
   --------------------------------------------------------------------- */

.onyx-backdrop {
  position: fixed;
  inset: 0;
  z-index: -3;
  overflow: hidden;
  pointer-events: none;
  background:
    radial-gradient(1100px 760px at 6% -10%, rgba(214, 168, 79, 0.15), transparent 62%),
    radial-gradient(900px 700px at 104% 106%, rgba(41, 210, 197, 0.12), transparent 60%),
    radial-gradient(760px 560px at 72% 32%, rgba(70, 84, 140, 0.12), transparent 70%),
    linear-gradient(180deg, #06080d 0%, #05070b 55%, #040509 100%);
}

.onyx-city {
  position: absolute;
  inset: -6%;
  background: url("assets/opt/onyx-city.webp") center 32% / cover no-repeat;
  filter: saturate(0.85) brightness(0.6) contrast(1.05);
  opacity: var(--city-o, 0.12);
  transform: scale(var(--city-s, 1.06));
  transition: opacity 1.1s var(--ease-soft);
  will-change: transform, opacity;
}

.onyx-city::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(5, 7, 11, 0.25) 0%, rgba(5, 7, 11, 0.55) 55%, #05070b 100%),
    radial-gradient(ellipse at 50% 38%, transparent 30%, rgba(5, 7, 11, 0.75) 100%);
}

.onyx-aurora {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(600px 300px at 30% 70%, rgba(214, 168, 79, 0.06), transparent 70%),
    radial-gradient(500px 360px at 80% 20%, rgba(41, 210, 197, 0.06), transparent 70%);
}

.onyx-scene {
  position: fixed;
  top: 0;
  left: 0;
  z-index: -2;
  display: block;
  width: 100%;
  height: 100vh;
  height: 100lvh;
  pointer-events: none;
  opacity: 0;
  transition: opacity 1.6s var(--ease-soft);
}

.onyx-scene.is-ready {
  opacity: 1;
}

.onyx-veil {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(ellipse at 50% 45%, transparent 52%, rgba(2, 3, 6, 0.6) 100%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.045 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ---------------------------------------------------------------------
   Uveg-rendszer
   --------------------------------------------------------------------- */

.glass,
.faction-overview-card,
.cart-pill,
.faction-tabs {
  position: relative;
  border: 1px solid var(--glass-line);
  background: var(--glass-fill);
  box-shadow: var(--glass-shadow), var(--inner-highlight);
  -webkit-backdrop-filter: blur(18px) saturate(150%);
  backdrop-filter: blur(18px) saturate(150%);
}

.glass {
  border-radius: var(--r-lg);
}

/* Fenycsik a peremen: bal fent eles, jobb lent arany/turkiz. */
.glass::before {
  content: "";
  position: absolute;
  inset: -1px;
  z-index: 0;
  padding: 1px;
  border-radius: inherit;
  background: linear-gradient(140deg, rgba(255, 255, 255, 0.46), rgba(255, 255, 255, 0.07) 30%, rgba(255, 255, 255, 0) 52%, rgba(214, 168, 79, 0.24) 78%, rgba(41, 210, 197, 0.36));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

/* Eger-kovetett csillanas (onyx-motion.js: --mx, --my, --glare). */
.glass::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  border-radius: inherit;
  background: radial-gradient(460px circle at var(--mx, 50%) var(--my, -20%), rgba(255, 255, 255, 0.1), transparent 45%);
  opacity: var(--glare, 0);
  transition: opacity 0.45s var(--ease-soft);
  pointer-events: none;
}

.glass > * {
  position: relative;
  z-index: 1;
}

/* ---------------------------------------------------------------------
   Gombok
   --------------------------------------------------------------------- */

.primary-action,
.secondary-action,
.checkout-button,
.discord-button {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 24px;
  overflow: hidden;
  border-radius: var(--r-pill);
  font-size: 0.94rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap;
  transition: transform 0.35s var(--ease-out), box-shadow 0.35s var(--ease-out), background 0.3s var(--ease-soft), border-color 0.3s var(--ease-soft), color 0.3s var(--ease-soft), opacity 0.2s;
}

.primary-action,
.checkout-button {
  border: 0;
  background: linear-gradient(135deg, #f6dc9c 0%, var(--gold) 46%, var(--gold-deep) 100%);
  color: #17110a;
  box-shadow: 0 12px 30px -10px rgba(214, 168, 79, 0.65), inset 0 1px 0 rgba(255, 255, 255, 0.6), inset 0 -2px 8px rgba(110, 72, 16, 0.35);
}

.secondary-action {
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.07);
  color: var(--text);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.primary-action::after,
.checkout-button::after,
.discord-button::after,
.secondary-action::after {
  content: "";
  position: absolute;
  inset: -2px auto -2px -60%;
  width: 45%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.45), transparent);
  transform: skewX(-20deg);
  transition: left 0.7s var(--ease-out);
  pointer-events: none;
}

.secondary-action::after {
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.16), transparent);
}

.primary-action:hover,
.checkout-button:hover:not(:disabled),
.discord-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 42px -12px rgba(214, 168, 79, 0.8), inset 0 1px 0 rgba(255, 255, 255, 0.6), inset 0 -2px 8px rgba(110, 72, 16, 0.35);
}

.secondary-action:hover {
  transform: translateY(-2px);
  border-color: rgba(242, 211, 138, 0.42);
  background: rgba(255, 255, 255, 0.11);
}

.primary-action:hover::after,
.checkout-button:hover:not(:disabled)::after,
.discord-button:hover::after,
.secondary-action:hover::after {
  left: 120%;
}

.primary-action:active,
.secondary-action:active,
.checkout-button:active:not(:disabled),
.discord-button:active {
  transform: translateY(0) scale(0.98);
}

.primary-action:disabled,
.secondary-action:disabled,
.checkout-button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
  transform: none;
}

.icon-button {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  transition: background 0.25s, border-color 0.25s, transform 0.35s var(--ease-out);
}

.icon-button:hover {
  border-color: rgba(242, 211, 138, 0.45);
  background: rgba(255, 255, 255, 0.12);
  transform: rotate(90deg);
}

.close-icon {
  display: block;
  width: 16px;
  height: 16px;
  object-fit: contain;
  pointer-events: none;
}

/* Kozos urlapmezok (admin, kosar, egyedi PP). */
#adminAccessCode,
#rulesEditor,
.faction-admin-form input,
.faction-admin-form textarea,
.shop-admin-form input:not([type="checkbox"]),
.shop-admin-form textarea,
.coupon-admin-form input:not([type="checkbox"]),
.shop-bulk-sale-panel input:not([type="checkbox"]),
.cart-coupon input,
.custom-points-row input {
  width: 100%;
  min-height: 48px;
  padding: 12px 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--r-sm);
  background: var(--field-bg);
  color: var(--text);
  outline: none;
  box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.25);
  transition: border-color 0.25s, box-shadow 0.25s, background 0.25s;
}

#adminAccessCode:focus,
#rulesEditor:focus,
.faction-admin-form input:focus,
.faction-admin-form textarea:focus,
.shop-admin-form input:not([type="checkbox"]):focus,
.shop-admin-form textarea:focus,
.coupon-admin-form input:not([type="checkbox"]):focus,
.shop-bulk-sale-panel input:not([type="checkbox"]):focus,
.cart-coupon input:focus,
.custom-points-row input:focus {
  border-color: rgba(41, 210, 197, 0.6);
  background: rgba(4, 6, 10, 0.82);
  box-shadow: 0 0 0 4px rgba(41, 210, 197, 0.1), inset 0 2px 8px rgba(0, 0, 0, 0.25);
}

::placeholder {
  color: rgba(162, 172, 180, 0.6);
}

input[type="checkbox"] {
  accent-color: var(--gold);
}

/* ---------------------------------------------------------------------
   Akcio-csik
   --------------------------------------------------------------------- */

.sale-banner {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 30;
  padding: 8px 16px;
  background: linear-gradient(135deg, #f6dc9c, var(--gold) 50%, var(--gold-deep));
  color: #1a1206;
  font-size: 0.92rem;
  font-weight: 700;
  text-align: center;
  box-shadow: 0 6px 24px rgba(214, 168, 79, 0.3);
}

.sale-banner-text {
  display: inline-block;
  animation: saleBannerFade 0.45s var(--ease-out);
}

/* Kuponcsik: balra a kedvezmeny, kozepen a masolhato kod, jobbra a lejaratig hatralevo ido. */
.sale-banner.sale-strip {
  padding: 0;
  border-bottom: 1px solid rgba(242, 211, 138, 0.18);
  background:
    radial-gradient(ellipse 50% 160% at 10% 50%, rgba(214, 168, 79, 0.18), transparent 70%),
    radial-gradient(ellipse 40% 160% at 92% 50%, rgba(41, 210, 197, 0.08), transparent 70%),
    rgba(9, 11, 16, 0.94);
  color: var(--text);
  font-size: 1rem;
  font-weight: 400;
  text-align: left;
  box-shadow: 0 12px 34px -14px rgba(0, 0, 0, 0.75);
}

.sale-strip-inner {
  width: var(--shell);
  margin: 0 auto;
}

.sale-strip-slide {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  grid-template-areas: "copy action timer";
  align-items: center;
  gap: 24px;
  min-height: 66px;
  padding: 10px 0;
  animation: saleBannerFade 0.45s var(--ease-out);
}

.sale-strip-copy {
  grid-area: copy;
  display: grid;
  gap: 2px;
  min-width: 0;
}

.sale-strip-title,
.sale-strip-text {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.sale-strip-title {
  color: #fff;
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.sale-strip-text {
  color: var(--muted);
  font-size: 0.85rem;
}

.sale-strip-code {
  grid-area: action;
  justify-self: center;
  display: inline-flex;
  align-items: stretch;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: 12px;
  background: none;
  color: inherit;
  cursor: pointer;
  transition: transform 0.25s var(--ease-out), filter 0.25s ease;
}

.sale-strip-code:hover {
  filter: brightness(1.08);
}

.sale-strip-code:active {
  transform: scale(0.97);
}

.sale-strip-code:focus-visible,
.sale-strip-shop:focus-visible {
  outline: 2px solid var(--gold-2);
  outline-offset: 3px;
}

.sale-strip-code-text {
  display: grid;
  place-items: center;
  min-width: 132px;
  padding: 0 22px;
  border: 1px solid rgba(242, 211, 138, 0.55);
  border-right: 0;
  border-radius: 12px 0 0 12px;
  background: rgba(214, 168, 79, 0.12);
  color: var(--gold-2);
  font-family: var(--font-display);
  font-size: 1.08rem;
  font-weight: 800;
  letter-spacing: 0.12em;
}

.sale-strip-code-icon {
  display: grid;
  place-items: center;
  width: 46px;
  border-radius: 0 12px 12px 0;
  background: linear-gradient(135deg, #f6dc9c, var(--gold) 55%, var(--gold-deep));
  color: #17110a;
  box-shadow: 0 8px 22px -8px rgba(214, 168, 79, 0.75);
  transition: background 0.3s ease;
}

.sale-strip-code-icon svg {
  width: 19px;
  height: 19px;
}

.sale-strip-code.is-copied .sale-strip-code-icon {
  background: linear-gradient(135deg, var(--teal-2), var(--teal));
}

.sale-strip-shop {
  grid-area: action;
  justify-self: center;
  min-height: 42px;
  padding: 0 22px;
  border: 0;
  border-radius: var(--r-pill);
  background: linear-gradient(135deg, #f6dc9c, var(--gold) 55%, var(--gold-deep));
  color: #17110a;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.sale-strip-timer {
  grid-area: timer;
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 12px;
}

.sale-strip-timer-label {
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.sale-strip-sep {
  margin: 0 0.32em;
  color: var(--muted);
  opacity: 0.75;
}

.sale-strip-clock {
  padding: 9px 16px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.045);
  color: var(--gold-2);
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* ---------------------------------------------------------------------
   Fejlec (lebego uveg-kapszula)
   --------------------------------------------------------------------- */

.topbar {
  position: fixed;
  z-index: 20;
  top: calc(var(--banner-h, 0px) + var(--topbar-gap));
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  width: min(1200px, calc(100% - 28px));
  height: var(--topbar-h);
  margin: 0 auto;
  padding: 0 10px 0 10px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--r-pill);
  background: linear-gradient(135deg, rgba(20, 24, 33, 0.62), rgba(10, 13, 19, 0.5));
  box-shadow: 0 20px 50px -20px rgba(0, 0, 0, 0.75), inset 0 1px 0 rgba(255, 255, 255, 0.12);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  backdrop-filter: blur(20px) saturate(160%);
  animation: topbarDrop 0.9s var(--ease-out) both;
}

.brand {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  gap: 11px;
  padding: 4px 12px 4px 4px;
  border-radius: var(--r-pill);
  color: var(--text);
  text-decoration: none;
  transition: background 0.3s;
}

.brand:hover {
  background: rgba(255, 255, 255, 0.05);
}

.brand-logo {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  box-shadow: 0 0 0 1px rgba(214, 168, 79, 0.5), 0 6px 18px rgba(0, 0, 0, 0.5), 0 0 26px rgba(214, 168, 79, 0.28);
  transition: transform 0.6s var(--ease-out);
}

.brand:hover .brand-logo {
  transform: rotate(-12deg) scale(1.05);
}

.brand-text {
  display: grid;
  line-height: 1.1;
}

.brand-text strong {
  font-family: var(--font-display);
  font-size: 1.02rem;
  font-weight: 800;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  background: linear-gradient(180deg, #fff 10%, var(--gold-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.brand-text small {
  color: var(--muted);
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.nav-points {
  position: relative;
  display: flex;
  align-items: center;
  gap: 2px;
  min-width: 0;
  padding: 4px;
}

.nav-indicator {
  position: absolute;
  top: 4px;
  bottom: 4px;
  left: 0;
  width: var(--ind-w, 0px);
  border-radius: var(--r-pill);
  background: linear-gradient(135deg, rgba(242, 211, 138, 0.2), rgba(41, 210, 197, 0.14));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22), inset 0 0 0 1px rgba(255, 255, 255, 0.1), 0 6px 18px -6px rgba(214, 168, 79, 0.45);
  opacity: var(--ind-o, 0);
  transform: translateX(var(--ind-x, 0px));
  transition: transform 0.55s var(--ease-out), width 0.55s var(--ease-out), opacity 0.3s;
  pointer-events: none;
}

.nav-dot {
  position: relative;
  z-index: 1;
  height: 42px;
  padding: 0 15px;
  border: 0;
  border-radius: var(--r-pill);
  background: transparent;
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 600;
  white-space: nowrap;
  transition: color 0.3s;
}

.nav-dot:hover,
.nav-dot.active {
  color: var(--text);
}

.nav-dot-shop {
  color: var(--gold-2);
}

.menu-toggle {
  display: none;
  place-items: center;
  align-content: center;
  gap: 4px;
  flex: 0 0 auto;
  width: 46px;
  height: 46px;
  margin-left: auto;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  transition: background 0.25s, border-color 0.25s;
}

.menu-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  transition: transform 0.35s var(--ease-out), opacity 0.2s;
}

.menu-toggle.open {
  border-color: rgba(242, 211, 138, 0.45);
  background: rgba(214, 168, 79, 0.14);
}

.menu-toggle.open span:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

.menu-toggle.open span:nth-child(2) {
  opacity: 0;
}

.menu-toggle.open span:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

/* ---------------------------------------------------------------------
   Oldal-keret
   --------------------------------------------------------------------- */

main {
  position: relative;
}

.page {
  display: none;
  min-height: 100vh;
  overflow-x: clip;
  padding-top: var(--header-space);
  padding-bottom: 32px;
}

.page.active {
  display: block;
}

.legal-shell,
.info-shell {
  position: relative;
  width: var(--shell);
  margin: 0 auto;
}

.page-hero {
  position: relative;
  max-width: 780px;
  margin: clamp(20px, 5vh, 56px) 0 clamp(26px, 4.5vh, 44px);
}

.page-hero h1 {
  font-size: clamp(2.3rem, 6vw, 4.6rem);
  font-weight: 800;
  letter-spacing: -0.035em;
  background: linear-gradient(180deg, #ffffff 15%, #d9dee2 55%, #b89553 115%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.page-hero > p:not(.eyebrow) {
  max-width: 620px;
  margin-top: 16px;
  color: var(--text-2);
  font-size: clamp(1rem, 1.4vw, 1.1rem);
  line-height: 1.7;
}

.gem-anchor {
  pointer-events: none;
}

.gem-anchor-page {
  position: absolute;
  top: clamp(10px, 4vh, 40px);
  right: 2%;
  width: min(30vw, 300px);
  aspect-ratio: 1;
}

.section-heading {
  max-width: 720px;
  margin-bottom: clamp(30px, 5vh, 52px);
}

.section-heading h2 {
  font-size: clamp(2rem, 4.6vw, 3.6rem);
  letter-spacing: -0.03em;
}

.section-heading > p:not(.eyebrow) {
  max-width: 560px;
  margin-top: 16px;
  color: var(--muted);
  font-size: 1.05rem;
}

.section-actions {
  display: flex;
  justify-content: center;
}

/* ---------------------------------------------------------------------
   Fooldal
   --------------------------------------------------------------------- */

.page.home-page {
  padding-top: 0;
}

.hero {
  position: relative;
  display: grid;
  align-items: center;
  min-height: 100vh;
  min-height: 100svh;
  padding: var(--header-space) 0 96px;
}

.hero-inner {
  width: var(--shell);
  margin: 0 auto;
}

.hero-inner > * {
  max-width: 640px;
}

.hero-title {
  display: grid;
  gap: 10px;
}

.hero-title-main {
  display: block;
  font-size: clamp(4.4rem, 15vw, 11.5rem);
  font-weight: 800;
  line-height: 0.86;
  letter-spacing: -0.065em;
  text-transform: uppercase;
  background: linear-gradient(180deg, #ffffff 0%, #f3e9d3 40%, #d2ab5c 88%, #8d6a2a 110%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 18px 48px rgba(214, 168, 79, 0.22));
}

.hero-title-sub {
  display: block;
  padding-left: 0.3em;
  color: var(--text-2);
  font-size: clamp(0.95rem, 2.3vw, 1.75rem);
  font-weight: 600;
  letter-spacing: 0.34em;
  line-height: 1.2;
  text-transform: uppercase;
}

.hero-copy {
  max-width: 520px;
  margin-top: 28px;
  color: var(--text-2);
  font-size: clamp(1rem, 1.5vw, 1.14rem);
  line-height: 1.75;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 36px;
}

.gem-anchor-hero {
  position: absolute;
  top: 50%;
  right: max(2vw, calc((100% - 1180px) / 2 - 2vw));
  width: min(40vw, 560px);
  aspect-ratio: 1;
  transform: translateY(-46%);
}

.scroll-cue {
  position: absolute;
  bottom: 26px;
  left: 50%;
  display: grid;
  justify-items: center;
  gap: 10px;
  padding: 6px 12px;
  border: 0;
  background: none;
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  opacity: calc(1 - var(--hero-p, 0) * 4);
  transform: translateX(-50%);
  transition: color 0.3s;
}

.scroll-cue:hover {
  color: var(--text);
}

.scroll-cue-line {
  position: relative;
  width: 1px;
  height: 46px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.14);
}

.scroll-cue-line::after {
  content: "";
  position: absolute;
  left: 0;
  width: 1px;
  height: 18px;
  background: linear-gradient(180deg, transparent, var(--gold-2));
  animation: scrollCue 2.2s var(--ease-soft) infinite;
}

.home-section {
  position: relative;
  width: var(--shell);
  margin: 0 auto;
  padding: clamp(80px, 13vh, 140px) 0;
}

/* Jellemzok */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}

.feature-card {
  display: flex;
  flex-direction: column;
  min-height: 300px;
  padding: 30px 28px 32px;
}

.feature-index {
  color: var(--faint);
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.24em;
}

.feature-icon {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  margin-top: 20px;
  border-radius: 18px;
  background: linear-gradient(135deg, #f6dc9c, var(--gold) 45%, var(--teal) 130%);
  color: #10141b;
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 800;
  box-shadow: 0 14px 32px -10px rgba(214, 168, 79, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.65);
}

.feature-card h3 {
  margin-top: auto;
  padding-top: 30px;
  font-size: 1.36rem;
}

.feature-card p {
  margin-top: 10px;
  color: var(--muted);
  line-height: 1.7;
}

/* Frakcio-gyuru (sticky, gorgetesre forog) */
.home-factions {
  position: relative;
  height: 290vh;
}

.home-factions-sticky {
  position: sticky;
  top: 0;
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  align-items: center;
  gap: 32px;
  width: var(--shell);
  height: 100vh;
  height: 100svh;
  margin: 0 auto;
  padding-top: calc(var(--header-space) - 10px);
}

.home-factions-copy h2 {
  font-size: clamp(2rem, 4.2vw, 3.4rem);
  letter-spacing: -0.03em;
}

.home-factions-copy > p:not(.eyebrow) {
  max-width: 460px;
  margin-top: 16px;
  color: var(--muted);
  font-size: 1.04rem;
}

.stat-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 26px 0 30px;
}

.stat {
  min-width: 132px;
  padding: 14px 18px;
  border: 1px solid var(--lite-line);
  border-radius: var(--r-md);
  background: var(--lite-fill);
}

.stat strong {
  display: block;
  font-family: var(--font-display);
  font-size: 2.1rem;
  font-weight: 800;
  line-height: 1;
  background: linear-gradient(180deg, #fff, var(--gold-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.stat span {
  display: block;
  margin-top: 6px;
  color: var(--muted);
  font-size: 0.8rem;
}

.ring-stage {
  position: relative;
  height: min(72vh, 640px);
  perspective: 1500px;
  perspective-origin: 50% 42%;
}

.gem-anchor-ring {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 34%;
  aspect-ratio: 1;
  transform: translate(-50%, -50%);
}

.faction-ring {
  --R: clamp(210px, 23vw, 320px);
  --cw: clamp(150px, 14.5vw, 200px);
  --ch: calc(var(--cw) * 1.28);
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  transform-style: preserve-3d;
  transform: translateZ(calc(var(--R) * -1)) rotateX(-7deg) rotateY(var(--ring-rot, 0deg));
}

.ring-card {
  position: absolute;
  top: 0;
  left: 0;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  width: var(--cw);
  height: var(--ch);
  margin: calc(var(--ch) / -2) 0 0 calc(var(--cw) / -2);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 22px;
  background: linear-gradient(165deg, rgba(34, 40, 54, 0.95), rgba(9, 12, 18, 0.97));
  box-shadow: 0 30px 60px -24px rgba(0, 0, 0, 0.8), inset 0 1px 0 rgba(255, 255, 255, 0.2);
  opacity: calc(0.3 + 0.7 * max(var(--f, 1), 0));
  transform: rotateY(calc(var(--i) * 360deg / 7)) translateZ(var(--R));
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
}

.ring-card::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(125deg, rgba(255, 255, 255, 0.2), transparent 38%, transparent 70%, rgba(242, 211, 138, 0.12));
  pointer-events: none;
}

.ring-card img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: cover;
}

.ring-card.is-badge img {
  padding: 14%;
  object-fit: contain;
  background: radial-gradient(circle at 50% 46%, rgba(255, 255, 255, 0.14), transparent 68%);
}

.ring-card figcaption {
  padding: 12px 10px 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  font-family: var(--font-display);
  font-size: 0.86rem;
  font-weight: 700;
  line-height: 1.25;
  text-align: center;
  opacity: calc(max(var(--f, 1), 0) * 1.4 - 0.2);
}

/* Csapat-fal (homoru henger) */
.home-team {
  padding-bottom: clamp(60px, 10vh, 110px);
}

.home-team .section-heading {
  margin-right: auto;
  margin-left: auto;
  text-align: center;
}

.home-team .section-heading > p:not(.eyebrow) {
  margin-right: auto;
  margin-left: auto;
}

.home-team .eyebrow {
  justify-content: center;
}

.wall-stage {
  position: relative;
  height: clamp(380px, 54vh, 500px);
  margin: 0 calc((100vw - 100%) / -2) 26px;
  overflow: hidden;
  perspective: 1000px;
  perspective-origin: 50% 50%;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 14%, #000 86%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 14%, #000 86%, transparent);
}

.team-wall {
  --R: clamp(520px, 62vw, 980px);
  --step: 17deg;
  /* A kozepso kartya sorszama: (kartyak szama - 1) / 2. Az onyx-motion.js is beallitja. */
  --mid: 2.5;
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  transform-style: preserve-3d;
  transform: translateZ(var(--R)) rotateY(var(--wall-rot, 0deg));
}

.wall-card {
  position: absolute;
  top: 0;
  left: 0;
  display: grid;
  justify-items: center;
  width: 176px;
  margin: -104px 0 0 -88px;
  padding: 22px 12px 18px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 22px;
  background: linear-gradient(165deg, rgba(34, 40, 54, 0.95), rgba(9, 12, 18, 0.97));
  box-shadow: 0 26px 50px -22px rgba(0, 0, 0, 0.8), inset 0 1px 0 rgba(255, 255, 255, 0.2);
  opacity: var(--wf, 1);
  transform: rotateY(calc((var(--i) - var(--mid)) * var(--step))) translateZ(calc(var(--R) * -1));
}

.wall-card img {
  display: block;
  width: 108px;
  height: 108px;
  padding: 3px;
  border-radius: 50%;
  background: conic-gradient(from 210deg, #f6dc9c, var(--teal), var(--gold), #f6dc9c);
  object-fit: cover;
  box-shadow: 0 14px 30px -10px rgba(0, 0, 0, 0.8), 0 0 28px -8px rgba(214, 168, 79, 0.45);
}

.wall-card figcaption {
  display: grid;
  gap: 3px;
  margin-top: 14px;
  text-align: center;
}

.wall-card strong {
  font-family: var(--font-display);
  font-size: 0.92rem;
  line-height: 1.2;
}

.wall-card span {
  color: var(--gold-2);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
}

/* Dokumentumok */
.doc-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}

.doc-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  min-height: 250px;
  padding: 28px;
  color: var(--text);
  text-align: left;
}

.doc-icon {
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  margin-bottom: 14px;
  border: 1px solid rgba(214, 168, 79, 0.28);
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(214, 168, 79, 0.16), rgba(41, 210, 197, 0.08));
  color: var(--gold-2);
}

.doc-icon svg {
  width: 26px;
  height: 26px;
}

.doc-card strong {
  font-family: var(--font-display);
  font-size: 1.34rem;
}

.doc-card > span:not(.doc-icon) {
  color: var(--muted);
  line-height: 1.65;
}

.doc-card em {
  margin-top: auto;
  padding-top: 12px;
  color: var(--gold-2);
  font-size: 0.9rem;
  font-style: normal;
  font-weight: 700;
}

.doc-card em span {
  display: inline-block;
  transition: transform 0.35s var(--ease-out);
}

.doc-card:hover em span {
  transform: translateX(5px);
}

/* Bolt-ajanlo */
.home-shop {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 0.7fr);
  align-items: center;
  gap: 28px;
  padding-bottom: clamp(60px, 10vh, 100px);
}

.shop-cta {
  display: grid;
  align-items: center;
  min-height: 340px;
  padding: clamp(28px, 5vw, 60px);
  border-radius: var(--r-xl);
  background:
    radial-gradient(420px 260px at 88% 50%, rgba(214, 168, 79, 0.14), transparent 70%),
    var(--glass-fill);
}

.shop-cta h2 {
  font-size: clamp(1.9rem, 4vw, 3.2rem);
  letter-spacing: -0.03em;
}

.shop-cta p:not(.eyebrow) {
  max-width: 480px;
  margin: 16px 0 30px;
  color: var(--text-2);
  font-size: 1.04rem;
}

.gem-anchor-shop {
  justify-self: center;
  width: min(100%, 300px);
  aspect-ratio: 1;
}

/* ---------------------------------------------------------------------
   PDF oldalak (Szabalyzat, ASZF, Adatvedelem)
   --------------------------------------------------------------------- */

.terms-pdf-page .page-hero h1 {
  font-size: clamp(2rem, 5.2vw, 4rem);
}

.terms-pdf-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 26px;
}

.terms-pdf-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 20px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--r-pill);
  background: rgba(255, 255, 255, 0.07);
  color: var(--text);
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  transition: transform 0.35s var(--ease-out), border-color 0.3s, background 0.3s;
}

.terms-pdf-link:hover {
  border-color: rgba(242, 211, 138, 0.45);
  background: rgba(255, 255, 255, 0.11);
  transform: translateY(-2px);
}

.terms-pdf-viewer {
  position: relative;
  padding: 10px;
  border: 1px solid var(--glass-line);
  border-radius: var(--r-lg);
  background: var(--glass-fill);
  box-shadow: var(--glass-shadow), var(--inner-highlight);
  -webkit-backdrop-filter: blur(18px) saturate(150%);
  backdrop-filter: blur(18px) saturate(150%);
}

.terms-pdf-frame {
  display: block;
  width: 100%;
  height: min(80vh, 1000px);
  min-height: 620px;
  border: 0;
  border-radius: 14px;
  background: #fff;
  color-scheme: light;
}

.pdf-mobile-view {
  display: none;
}

.terms-pdf-page .gem-anchor-page {
  top: 0;
  width: min(20vw, 200px);
}

.terms-pdf-page .legal-grid {
  display: none;
}

/* ---------------------------------------------------------------------
   Admin belepes + szabalyzat-szerkeszto
   --------------------------------------------------------------------- */

.admin-modal {
  position: fixed;
  inset: 0;
  z-index: 70;
  display: grid;
  place-items: center;
  padding: 20px;
}

.admin-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(3, 4, 7, 0.7);
  animation: fadeIn 0.3s var(--ease-soft) both;
}

.rules-access-card {
  position: relative;
  padding: 30px;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: var(--r-lg);
  background: var(--solid-panel);
  box-shadow: 0 40px 120px -30px rgba(0, 0, 0, 0.85), var(--inner-highlight);
}

.admin-login-card {
  z-index: 1;
  display: grid;
  gap: 10px;
  width: min(460px, 100%);
  animation: modalIn 0.5s var(--ease-out) both;
}

.admin-login-card h2 {
  font-size: 1.6rem;
}

.admin-login-card p:not(.eyebrow) {
  margin-bottom: 8px;
  color: var(--muted);
}

.admin-login-card .eyebrow {
  margin-bottom: 4px;
}

.admin-login-card label,
.rules-editor-card label {
  color: var(--text-2);
  font-size: 0.88rem;
  font-weight: 600;
}

.admin-close-button {
  position: absolute;
  top: 16px;
  right: 16px;
}

/* Fizetesi azonosito ablak (sikeres haz / frakcio fejlesztes vasarlas utan) */
.payment-code-card {
  /* Kis kijelzon (tobb koddal) is elerheto maradjon a Rendben gomb. */
  max-height: calc(100vh - 40px);
  max-height: calc(100dvh - 40px);
  overflow-y: auto;
  overscroll-behavior: contain;
}

.payment-code-list {
  display: grid;
  gap: 10px;
  margin: 4px 0 10px;
}

.payment-code-item {
  display: grid;
  gap: 8px;
  padding: 14px 16px;
  border: 1px solid rgba(214, 168, 79, 0.32);
  border-radius: var(--r-md);
  background: rgba(214, 168, 79, 0.07);
}

.payment-code-category {
  color: var(--gold-2);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.payment-code-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.payment-code-value {
  color: var(--text);
  font-family: ui-monospace, "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 1.3rem;
  letter-spacing: 0.06em;
  /* A body-n ki van kapcsolva a kijeloles; a kod egy kattintassal kijelolheto legyen. */
  -webkit-user-select: all;
  user-select: all;
}

.admin-login-card .payment-code-items {
  margin: 0;
  font-size: 0.86rem;
  white-space: pre-line;
}

.rules-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
}

#adminAccessStatus {
  color: var(--red-2);
  font-weight: 600;
}

#rulesSaveStatus {
  color: var(--teal-2);
  font-weight: 600;
}

.rules-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.95fr);
  gap: 20px;
  padding-bottom: 40px;
}

.rules-editor-card,
.rules-preview-card {
  display: grid;
  align-content: start;
  gap: 12px;
  padding: 26px;
}

#rulesEditor {
  min-height: 440px;
  line-height: 1.65;
  resize: vertical;
}

.rules-preview {
  min-height: 440px;
  color: var(--text-2);
  line-height: 1.8;
  white-space: pre-wrap;
}

.rules-preview:empty::before {
  content: "A szabályzat előnézete itt fog megjelenni.";
  color: var(--muted);
}

/* ---------------------------------------------------------------------
   Frakciok
   --------------------------------------------------------------------- */

.faction-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}

.faction-tabs {
  display: inline-flex;
  gap: 4px;
  padding: 5px;
  border-radius: var(--r-pill);
}

.faction-tab {
  min-height: 42px;
  padding: 0 20px;
  border: 0;
  border-radius: var(--r-pill);
  background: transparent;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
  transition: color 0.3s, background 0.35s var(--ease-out), box-shadow 0.35s;
}

.faction-tab:hover {
  color: var(--text);
}

.faction-tab.active {
  background: linear-gradient(135deg, #f6dc9c, var(--gold) 55%, var(--gold-deep));
  color: #17110a;
  box-shadow: 0 8px 22px -8px rgba(214, 168, 79, 0.7), inset 0 1px 0 rgba(255, 255, 255, 0.55);
}

.faction-admin-open {
  min-height: 42px;
  padding: 0 18px;
  font-size: 0.85rem;
}

.faction-overview {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) repeat(2, minmax(0, 0.8fr));
  gap: 14px;
  margin-bottom: 18px;
}

.faction-overview-card {
  min-height: 112px;
  padding: 18px 20px;
  border-radius: var(--r-md);
  animation: fadeUp 0.5s var(--ease-out) both;
}

.faction-overview-main {
  background:
    linear-gradient(135deg, rgba(214, 168, 79, 0.2), rgba(41, 210, 197, 0.08)),
    var(--glass-fill);
}

.faction-overview-card span,
.faction-detail-grid span,
.faction-focus span {
  display: block;
  margin-bottom: 8px;
  color: var(--gold-2);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.faction-overview-card strong {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(1.1rem, 2vw, 1.5rem);
  line-height: 1.1;
}

.faction-overview-card p {
  margin-top: 8px;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.5;
}

.faction-layout {
  display: grid;
  grid-template-columns: minmax(280px, 380px) minmax(0, 1fr);
  align-items: start;
  gap: 18px;
  padding-bottom: 30px;
}

.faction-list {
  display: grid;
  align-content: start;
  gap: 10px;
  padding: 12px;
}

.faction-group {
  display: grid;
}

.faction-group-toggle,
.faction-button {
  width: 100%;
  border: 1px solid var(--lite-line);
  border-radius: var(--r-md);
  background: var(--lite-fill);
  color: var(--text);
  text-align: left;
  transition: border-color 0.3s, background 0.3s, transform 0.35s var(--ease-out), box-shadow 0.3s;
}

.faction-group-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 64px;
  padding: 10px 14px;
}

.faction-group-copy {
  display: grid;
  gap: 3px;
}

.faction-group-copy strong {
  font-size: 0.94rem;
  line-height: 1.2;
}

.faction-group-copy small {
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 600;
}

.faction-count {
  display: grid;
  place-items: center;
  min-width: 36px;
  height: 36px;
  border-radius: 12px;
  background: rgba(41, 210, 197, 0.14);
  color: var(--teal-2);
  font-size: 0.8rem;
  font-weight: 800;
}

.faction-group-toggle:hover,
.faction-group-toggle.active {
  border-color: rgba(242, 211, 138, 0.4);
  background: linear-gradient(135deg, rgba(214, 168, 79, 0.14), rgba(255, 255, 255, 0.03));
}

.faction-group-items {
  display: grid;
  gap: 8px;
  max-height: 0;
  margin: 0 0 0 16px;
  padding-left: 12px;
  overflow: hidden;
  border-left: 1px solid transparent;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-6px);
  transition: max-height 0.4s var(--ease-out), margin-top 0.3s, opacity 0.3s, transform 0.35s var(--ease-out), border-color 0.3s;
}

.faction-group-items.open {
  max-height: 720px;
  margin-top: 8px;
  border-left-color: rgba(214, 168, 79, 0.3);
  opacity: 1;
  pointer-events: auto;
  transform: none;
}

.faction-button {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-height: 70px;
  padding: 10px 12px;
}

.faction-button-mark {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(214, 168, 79, 0.28);
  border-radius: 14px;
  background: rgba(214, 168, 79, 0.1);
  color: var(--gold-2);
  font-family: var(--font-display);
  font-size: 0.74rem;
  font-weight: 800;
  transition: background 0.3s, color 0.3s, border-color 0.3s;
}

.faction-button-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.faction-button-copy strong {
  font-size: 0.94rem;
  line-height: 1.22;
  overflow-wrap: anywhere;
}

.faction-button-copy span {
  color: var(--muted);
  font-size: 0.78rem;
}

.faction-button em {
  justify-self: end;
  max-width: 118px;
  padding: 5px 9px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--r-pill);
  color: var(--muted);
  font-size: 0.66rem;
  font-style: normal;
  font-weight: 700;
  line-height: 1.25;
  text-align: center;
}

.faction-button:hover,
.faction-button.active {
  border-color: rgba(41, 210, 197, 0.45);
  background: linear-gradient(135deg, rgba(41, 210, 197, 0.13), rgba(255, 255, 255, 0.03));
  box-shadow: inset 3px 0 0 var(--teal);
}

.faction-button:hover {
  transform: translateX(3px);
}

.faction-button.active .faction-button-mark,
.faction-button:hover .faction-button-mark {
  border-color: rgba(41, 210, 197, 0.5);
  background: rgba(41, 210, 197, 0.16);
  color: var(--teal-2);
}

.faction-detail {
  position: sticky;
  top: calc(var(--header-space) + 6px);
  display: grid;
  gap: 18px;
  min-height: 320px;
  padding: clamp(22px, 3vw, 32px);
}

.faction-detail > * {
  animation: fadeUp 0.5s var(--ease-out) both;
}

.faction-detail > *:nth-child(2) {
  animation-delay: 0.05s;
}

.faction-detail > *:nth-child(3) {
  animation-delay: 0.1s;
}

.faction-detail > *:nth-child(4) {
  animation-delay: 0.15s;
}

.faction-detail h2 {
  margin: 12px 0 8px;
  font-size: clamp(1.7rem, 3vw, 2.6rem);
  line-height: 1.04;
}

.faction-detail > p,
.faction-empty-state p {
  color: var(--muted);
  line-height: 1.7;
}

.faction-empty-state {
  display: grid;
  align-content: center;
  min-height: 240px;
}

.faction-empty-state .product-tag {
  justify-self: start;
}

.faction-detail-head {
  display: flex;
  align-items: center;
  gap: 20px;
}

.faction-detail-head p {
  color: var(--muted);
  font-weight: 600;
}

.faction-emblem {
  display: grid;
  place-items: center;
  flex: 0 0 84px;
  width: 84px;
  height: 84px;
  border-radius: 24px;
  background: linear-gradient(135deg, #f6dc9c, var(--gold) 45%, var(--teal) 140%);
  color: #11151c;
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 800;
  box-shadow: 0 18px 40px -12px rgba(214, 168, 79, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.6);
}

.faction-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.faction-detail-grid div,
.faction-description,
.faction-focus {
  padding: 16px 18px;
  border: 1px solid var(--lite-line);
  border-radius: var(--r-md);
  background: rgba(0, 0, 0, 0.18);
}

.faction-detail-grid strong,
.faction-focus strong {
  display: block;
  line-height: 1.4;
}

.faction-description h3 {
  margin-bottom: 10px;
  font-size: 0.98rem;
}

.faction-description p {
  color: var(--muted);
  line-height: 1.75;
}

.product-tag {
  display: inline-flex;
  align-items: center;
  align-self: flex-start;
  padding: 5px 11px;
  border: 1px solid rgba(41, 210, 197, 0.3);
  border-radius: var(--r-pill);
  background: rgba(41, 210, 197, 0.1);
  color: var(--teal-2);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

/* Admin panelek (frakcio + bolt): tomor panel, a WebGL ilyenkor szunetel. */
.faction-admin-panel,
.shop-admin-panel {
  position: fixed;
  inset: 0;
  z-index: 44;
  display: grid;
  place-items: center;
  padding: 20px;
}

.faction-admin-backdrop,
.shop-admin-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(3, 4, 7, 0.74);
  animation: fadeIn 0.3s var(--ease-soft) both;
}

.faction-admin-card,
.shop-admin-card {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  width: min(1120px, 100%);
  height: min(820px, calc(100vh - 40px));
  height: min(820px, calc(100dvh - 40px));
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--r-lg);
  background: var(--solid-panel);
  box-shadow: 0 40px 120px -30px rgba(0, 0, 0, 0.9), var(--inner-highlight);
  animation: modalIn 0.5s var(--ease-out) both;
}

.faction-admin-head,
.faction-admin-list-head,
.faction-admin-actions,
.shop-admin-head,
.shop-admin-list-head,
.shop-admin-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.faction-admin-head,
.shop-admin-head {
  padding: 18px 22px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.faction-admin-head .eyebrow,
.shop-admin-head .eyebrow {
  margin-bottom: 6px;
}

.faction-admin-head h2,
.shop-admin-head h2 {
  font-size: 1.35rem;
}

.faction-admin-list-head h3,
.shop-admin-list-head h3 {
  font-size: 1.05rem;
}

.faction-admin-layout,
.shop-admin-layout {
  flex: 1 1 auto;
  display: grid;
  grid-template-columns: minmax(280px, 0.9fr) minmax(360px, 1.1fr);
  gap: 20px;
  min-height: 0;
  padding: 20px 22px;
  overflow: hidden;
}

.faction-admin-layout.is-scrollable,
.shop-admin-layout.is-scrollable {
  overflow-y: auto;
}

.faction-admin-list,
.faction-admin-form,
.shop-admin-list,
.shop-admin-editor-column {
  min-height: 0;
  height: 100%;
  max-height: 100%;
  overflow-y: hidden;
  overscroll-behavior: contain;
}

.faction-admin-list.is-scrollable,
.faction-admin-form.is-scrollable,
.shop-admin-list.is-scrollable,
.shop-admin-editor-column.is-scrollable {
  overflow-y: auto;
}

.faction-admin-list,
.shop-admin-list,
.shop-admin-editor-column,
.shop-admin-form,
.faction-admin-form {
  display: grid;
  align-content: start;
  gap: 10px;
  padding-right: 10px;
  padding-bottom: 10px;
}

.faction-admin-list {
  gap: 14px;
  padding-bottom: 30px;
}

.shop-admin-form {
  height: auto;
  max-height: none;
  overflow: visible;
}

#factionAdminList,
#shopAdminProductList {
  display: grid;
  gap: 10px;
}

.faction-admin-filter {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
  min-height: 46px;
  padding: 4px;
  border: 1px solid var(--lite-line);
  border-radius: var(--r-pill);
  background: rgba(255, 255, 255, 0.03);
}

.faction-admin-filter button {
  border: 0;
  border-radius: var(--r-pill);
  background: transparent;
  color: var(--muted);
  font-weight: 700;
  transition: background 0.3s, color 0.3s;
}

.faction-admin-filter button.active {
  background: rgba(41, 210, 197, 0.16);
  color: var(--text);
  box-shadow: inset 0 0 0 1px rgba(41, 210, 197, 0.32);
}

.faction-admin-group {
  display: grid;
  gap: 8px;
}

.faction-admin-group h4 {
  color: var(--gold-2);
  font-family: var(--font-body);
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.faction-admin-edit,
.shop-admin-edit {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 58px;
  padding: 10px 14px;
  border: 1px solid var(--lite-line);
  border-radius: var(--r-sm);
  background: var(--lite-fill);
  color: var(--text);
  text-align: left;
  transition: border-color 0.25s, background 0.25s;
}

.faction-admin-edit:hover,
.shop-admin-edit:hover {
  border-color: rgba(41, 210, 197, 0.4);
  background: var(--lite-fill-hover);
}

.faction-admin-edit span,
.faction-admin-edit small,
.shop-admin-edit span,
.shop-admin-edit small {
  display: block;
}

.faction-admin-edit small,
.shop-admin-edit small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 0.8rem;
}

.faction-admin-edit em,
.shop-admin-edit em {
  flex: 0 0 auto;
  color: var(--teal-2);
  font-size: 0.72rem;
  font-style: normal;
  font-weight: 700;
}

.faction-admin-empty,
.shop-admin-empty {
  color: var(--muted);
}

.faction-admin-form label,
.shop-admin-list label,
.shop-admin-form label,
.coupon-admin-form label {
  color: var(--text-2);
  font-size: 0.86rem;
  font-weight: 600;
}

.faction-admin-form textarea {
  min-height: 140px;
  resize: vertical;
}

#factionAdminStatusText,
#shopAdminStatusText,
#couponAdminStatusText {
  color: var(--teal-2);
  font-weight: 600;
}

.native-select-hidden,
.native-select-hidden[hidden],
.custom-select[hidden] {
  display: none !important;
}

.custom-select {
  display: grid;
}

.custom-select-button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  min-height: 48px;
  padding: 0 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--r-sm);
  background: var(--field-bg);
  color: var(--text);
  font-weight: 600;
  text-align: left;
  transition: border-color 0.25s, box-shadow 0.25s;
}

.custom-select.open .custom-select-button,
.custom-select-button:focus-visible {
  border-color: rgba(41, 210, 197, 0.6);
  outline: none;
  box-shadow: 0 0 0 4px rgba(41, 210, 197, 0.1);
}

.custom-select-arrow {
  width: 8px;
  height: 8px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  opacity: 0.75;
  transform: rotate(45deg) translateY(-2px);
  transition: transform 0.3s var(--ease-out);
}

.custom-select.open .custom-select-arrow {
  transform: rotate(225deg) translateY(-2px);
}

.custom-select-menu {
  display: grid;
  max-height: 0;
  padding: 0 6px;
  overflow: hidden;
  border: 1px solid transparent;
  border-radius: var(--r-sm);
  background: #0b0e14;
  box-shadow: 0 20px 44px rgba(0, 0, 0, 0.5);
  opacity: 0;
  pointer-events: none;
  transform: translateY(-4px);
  transition: max-height 0.28s var(--ease-out), opacity 0.2s, padding 0.2s, transform 0.25s var(--ease-out);
}

.custom-select.open .custom-select-menu {
  max-height: 200px;
  margin-top: 6px;
  padding: 6px;
  overflow-y: auto;
  border-color: rgba(41, 210, 197, 0.34);
  opacity: 1;
  pointer-events: auto;
  transform: none;
}

.custom-select-menu button {
  min-height: 40px;
  padding: 0 12px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--muted);
  font-weight: 600;
  text-align: left;
}

.custom-select-menu button:hover,
.custom-select-menu button[aria-selected="true"] {
  background: rgba(41, 210, 197, 0.14);
  color: var(--text);
}

/* ---------------------------------------------------------------------
   Csapat
   --------------------------------------------------------------------- */

.team-hierarchy {
  position: relative;
  display: grid;
  gap: 60px;
  padding-bottom: 40px;
}

/* A hierarchia gerince: a szinteket osszekoto fenyvonal. */
.team-hierarchy::before {
  content: "";
  position: absolute;
  top: 20px;
  bottom: 40px;
  left: 50%;
  width: 1px;
  background: linear-gradient(180deg, transparent, rgba(242, 211, 138, 0.55) 6%, rgba(41, 210, 197, 0.45) 94%, transparent);
  box-shadow: 0 0 18px rgba(214, 168, 79, 0.35);
}

.team-tier {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 22px;
}

.team-tier-head {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  align-items: center;
  gap: 16px;
  width: min(580px, 100%);
  padding: 14px 22px 14px 14px;
}

.team-tier-head > span {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  border-radius: 17px;
  background: linear-gradient(135deg, #f6dc9c, var(--gold) 55%, var(--gold-deep));
  color: #17110a;
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 800;
  box-shadow: 0 10px 26px -8px rgba(214, 168, 79, 0.65), inset 0 1px 0 rgba(255, 255, 255, 0.6);
}

.team-tier-head h2 {
  font-size: clamp(1.1rem, 1.8vw, 1.35rem);
}

.team-tier-head p {
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.5;
}

.team-tier-members {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 340px));
  justify-content: center;
  gap: 22px;
  width: 100%;
}

.team-tier-members.team-tier-single {
  grid-template-columns: minmax(0, 340px);
}

/* Barmennyi tulajdonos: egy sorban, ami nem fer ki, kozepre tordelve alatta. */
.team-tier-members.team-tier-owners {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
}

.team-tier-owners > .team-card {
  flex: 0 1 340px;
  min-width: 0;
}

.team-card {
  display: grid;
  justify-items: center;
  align-content: start;
  padding: 30px 26px 28px;
  text-align: center;
}

.team-card-owner {
  background:
    linear-gradient(160deg, rgba(214, 168, 79, 0.2), rgba(214, 168, 79, 0) 55%),
    var(--glass-fill);
}

.team-card-lead {
  background:
    linear-gradient(160deg, rgba(41, 210, 197, 0.12), rgba(41, 210, 197, 0) 55%),
    var(--glass-fill);
}

.team-photo {
  display: block;
  width: 108px;
  height: 108px;
  padding: 3px;
  border-radius: 50%;
  background: conic-gradient(from 210deg, #f6dc9c, var(--teal), var(--gold), #f6dc9c);
  object-fit: cover;
  box-shadow: 0 18px 38px -12px rgba(0, 0, 0, 0.8), 0 0 34px -8px rgba(214, 168, 79, 0.45);
  transition: transform 0.6s var(--ease-out);
}

.team-card-owner .team-photo {
  width: 120px;
  height: 120px;
}

.team-card:hover .team-photo {
  transform: translateZ(0) scale(1.06) rotate(-3deg);
}

.team-card h3 {
  margin-top: 18px;
  font-size: 1.2rem;
}

.team-rank {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  margin-top: 10px;
  padding: 0 12px;
  border: 1px solid rgba(41, 210, 197, 0.32);
  border-radius: var(--r-pill);
  background: rgba(41, 210, 197, 0.1);
  color: var(--teal-2);
  font-size: 0.74rem;
  font-weight: 700;
}

.team-card-owner .team-rank {
  border-color: rgba(242, 211, 138, 0.4);
  background: rgba(214, 168, 79, 0.14);
  color: var(--gold-2);
}

.team-ranks {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-top: 10px;
}

.team-ranks .team-rank {
  margin-top: 0;
}

.team-card-owner .team-rank-ceo {
  border-color: transparent;
  background: linear-gradient(135deg, #f6dc9c, var(--gold) 55%, var(--gold-deep));
  color: #17110a;
  letter-spacing: 0.08em;
  box-shadow: 0 8px 20px -8px rgba(214, 168, 79, 0.7), inset 0 1px 0 rgba(255, 255, 255, 0.55);
}

.team-card p {
  margin-top: 14px;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.65;
}

/* ---------------------------------------------------------------------
   Bolt
   --------------------------------------------------------------------- */

.shop-login {
  position: relative;
  display: grid;
  place-items: center;
  min-height: calc(100vh - var(--header-space) - 40px);
  padding: 20px 0 60px;
}

.login-visual {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 42%, rgba(88, 101, 242, 0.16), transparent 42%);
  pointer-events: none;
}

.login-content {
  display: grid;
  justify-items: center;
  width: min(580px, calc(100% - 32px));
  padding: clamp(30px, 5vw, 48px) clamp(22px, 5vw, 44px);
  text-align: center;
}

.login-emblem {
  width: 76px;
  height: 76px;
  margin-bottom: 20px;
  border-radius: 50%;
  box-shadow: 0 0 0 1px rgba(214, 168, 79, 0.5), 0 14px 36px -10px rgba(0, 0, 0, 0.8), 0 0 40px rgba(214, 168, 79, 0.3);
}

.login-content h1 {
  font-size: clamp(1.8rem, 4.4vw, 2.7rem);
  letter-spacing: -0.03em;
}

.login-content > p:not(.eyebrow):not(.login-error) {
  max-width: 460px;
  margin-top: 14px;
  color: var(--text-2);
}

.discord-button {
  margin-top: 30px;
  min-height: 54px;
  padding: 0 28px;
  border: 0;
  background: linear-gradient(135deg, #7c86ff, var(--discord) 55%, #4550c9);
  color: #fff;
  box-shadow: 0 16px 40px -12px rgba(88, 101, 242, 0.75), inset 0 1px 0 rgba(255, 255, 255, 0.35);
}

.discord-button:hover {
  box-shadow: 0 22px 50px -14px rgba(88, 101, 242, 0.9), inset 0 1px 0 rgba(255, 255, 255, 0.35);
}

.discord-icon {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.18);
}

.discord-icon img {
  display: block;
  width: 18px;
  height: 18px;
  object-fit: contain;
  filter: brightness(0) invert(1);
}

.login-error {
  min-height: 24px;
  margin-top: 14px;
  color: var(--red-2);
  font-weight: 600;
}

.shop-app {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  align-items: start;
  gap: 22px;
  width: var(--shell);
  margin: 12px auto 0;
  padding-bottom: 30px;
}

.shop-sidebar {
  position: sticky;
  top: calc(var(--header-space) + 4px);
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-height: min(520px, calc(100vh - var(--header-space) - 30px));
  padding: 18px;
}

.profile-box {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--lite-line);
  border-radius: var(--r-md);
  background: var(--lite-fill);
}

.profile-box strong {
  display: block;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.profile-box span {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 0.8rem;
}

.avatar {
  display: grid;
  place-items: center;
  flex: 0 0 48px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--gold-2), var(--teal));
  color: #0b0f14;
  font-weight: 800;
  box-shadow: 0 0 0 2px rgba(214, 168, 79, 0.45), 0 0 22px rgba(214, 168, 79, 0.25);
}

.discord-avatar {
  display: block;
  object-fit: cover;
}

.shop-menu {
  display: grid;
  gap: 8px;
}

.shop-link,
.shop-admin-open,
.logout-button {
  width: 100%;
  min-height: 46px;
  padding: 0 16px;
  border: 1px solid transparent;
  border-radius: var(--r-sm);
  background: transparent;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
  text-align: left;
  transition: background 0.3s, border-color 0.3s, color 0.3s, transform 0.35s var(--ease-out);
}

.shop-link:hover,
.shop-link.active {
  border-color: rgba(242, 211, 138, 0.32);
  background: linear-gradient(135deg, rgba(214, 168, 79, 0.18), rgba(41, 210, 197, 0.08));
  color: var(--text);
}

.shop-link:hover {
  transform: translateX(3px);
}

.shop-admin-open {
  margin-top: auto;
  border-color: rgba(41, 210, 197, 0.3);
  color: var(--teal-2);
  text-align: center;
}

/* A Bolt admin gomb csak a Discord-adminoknak latszik; nelkule a kijelentkezes kerul alulra. */
.shop-admin-open.hidden + .logout-button {
  margin-top: auto;
}

.shop-admin-open:hover {
  border-color: rgba(41, 210, 197, 0.55);
  background: rgba(41, 210, 197, 0.1);
  color: var(--text);
}

.logout-button {
  border-color: rgba(255, 90, 103, 0.3);
  color: var(--red-2);
  text-align: center;
}

.logout-button:hover {
  border-color: rgba(255, 90, 103, 0.55);
  background: rgba(255, 90, 103, 0.1);
  color: var(--text);
}

.shop-main {
  min-width: 0;
}

.shop-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin: 8px 0 22px;
}

.shop-head .eyebrow {
  margin-bottom: 10px;
}

.shop-head h1 {
  font-size: clamp(1.9rem, 4vw, 3.1rem);
  font-weight: 800;
  letter-spacing: -0.035em;
}

.cart-pill {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  gap: 12px;
  min-height: 50px;
  padding: 0 7px 0 20px;
  border-radius: var(--r-pill);
  color: var(--text);
  font-size: 0.92rem;
  font-weight: 700;
  white-space: nowrap;
  transition: transform 0.35s var(--ease-out), border-color 0.3s;
}

.cart-pill:hover {
  border-color: rgba(242, 211, 138, 0.45);
  transform: translateY(-2px);
}

.cart-pill span {
  display: grid;
  place-items: center;
  min-width: 36px;
  height: 36px;
  padding: 0 8px;
  border-radius: var(--r-pill);
  background: linear-gradient(135deg, #f6dc9c, var(--gold));
  color: #17110a;
  font-weight: 800;
}

.shop-subtabs {
  display: inline-flex;
  gap: 6px;
  margin-bottom: 20px;
  padding: 5px;
  border: 1px solid var(--lite-line);
  border-radius: var(--r-pill);
  background: var(--lite-fill);
}

.shop-subtab {
  min-height: 38px;
  padding: 0 16px;
  border: 0;
  border-radius: var(--r-pill);
  background: transparent;
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 700;
}

.shop-subtab:hover,
.shop-subtab.active {
  background: rgba(41, 210, 197, 0.14);
  color: var(--text);
}

.custom-points-panel {
  display: grid;
  gap: 16px;
  max-width: 680px;
  padding: clamp(22px, 3.4vw, 36px);
}

.custom-points-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.custom-points-head h2 {
  font-size: 1.35rem;
}

#customPointsSummary {
  color: var(--gold-2);
  font-family: var(--font-display);
  font-size: 1.12rem;
  text-align: right;
}

.custom-points-panel label {
  color: var(--text-2);
  font-size: 0.88rem;
  font-weight: 600;
}

.custom-points-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

.custom-points-row input {
  min-height: 56px;
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 700;
}

.product-button {
  min-height: 44px;
  padding: 0 22px;
  border: 1px solid rgba(242, 211, 138, 0.45);
  border-radius: var(--r-pill);
  background: rgba(214, 168, 79, 0.12);
  color: var(--gold-2);
  font-weight: 700;
  transition: background 0.3s, color 0.3s, transform 0.35s var(--ease-out), box-shadow 0.35s;
}

.product-button:hover {
  background: linear-gradient(135deg, #f6dc9c, var(--gold));
  color: #17110a;
  box-shadow: 0 12px 30px -10px rgba(214, 168, 79, 0.7);
  transform: translateY(-2px);
}

.custom-points-row .product-button {
  min-height: 56px;
  padding: 0 30px;
}

/* Egyseges csuszka; a kitoltest (--fill) az onyx-motion.js allitja. */
.custom-points-range {
  width: 100%;
  height: 8px;
  margin: 10px 0 4px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--gold) 0%, var(--teal) var(--fill, 0%), rgba(255, 255, 255, 0.12) var(--fill, 0%));
  outline: none;
  cursor: pointer;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
}

.custom-points-range::-webkit-slider-runnable-track {
  height: 8px;
  border-radius: 999px;
  background: transparent;
}

.custom-points-range::-webkit-slider-thumb {
  width: 24px;
  height: 24px;
  margin-top: -8px;
  border: 3px solid #0b0e14;
  border-radius: 50%;
  background: linear-gradient(135deg, #fff, var(--gold-2));
  box-shadow: 0 0 0 1px rgba(242, 211, 138, 0.6), 0 0 20px rgba(214, 168, 79, 0.55);
  cursor: grab;
  -webkit-appearance: none;
  appearance: none;
}

.custom-points-range::-moz-range-track {
  height: 8px;
  border-radius: 999px;
  background: transparent;
}

.custom-points-range::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border: 3px solid #0b0e14;
  border-radius: 50%;
  background: linear-gradient(135deg, #fff, var(--gold-2));
  box-shadow: 0 0 0 1px rgba(242, 211, 138, 0.6), 0 0 20px rgba(214, 168, 79, 0.55);
  cursor: grab;
}

.custom-points-range:focus-visible::-webkit-slider-thumb {
  outline: 2px solid var(--teal-2);
  outline-offset: 2px;
}

.custom-points-range:focus-visible::-moz-range-thumb {
  outline: 2px solid var(--teal-2);
  outline-offset: 2px;
}

.custom-points-status {
  min-height: 22px;
  color: var(--gold-2);
  font-size: 0.88rem;
  font-weight: 600;
}

.custom-points-status.error {
  color: var(--red-2);
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.product-card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 260px;
  padding: 22px;
  border: 1px solid var(--glass-line);
  border-radius: var(--r-lg);
  background: var(--glass-fill);
  box-shadow: var(--glass-shadow), var(--inner-highlight);
  -webkit-backdrop-filter: blur(16px) saturate(150%);
  backdrop-filter: blur(16px) saturate(150%);
  animation: fadeUp 0.5s var(--ease-out) both;
  transition: transform 0.4s var(--ease-out), border-color 0.3s;
}

.product-card:hover {
  border-color: rgba(242, 211, 138, 0.4);
  transform: translateY(-4px);
}

.product-card-sale {
  border-color: rgba(242, 211, 138, 0.36);
}

.product-card-tags {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.product-sale-badge {
  padding: 5px 11px;
  border-radius: var(--r-pill);
  background: rgba(214, 168, 79, 0.18);
  color: var(--gold-2);
  font-size: 0.7rem;
  font-weight: 800;
}

.product-card h3 {
  margin: 18px 0 8px;
  font-size: 1.2rem;
}

.product-card p {
  margin-bottom: 20px;
  color: var(--muted);
  line-height: 1.65;
  /* A leiras sortoresei (Bolt admin szovegdoboz) latszanak, pl. a csomagok tartalomlistajanal. */
  white-space: pre-line;
}

.product-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: auto;
}

.price {
  color: var(--gold-2);
  font-family: var(--font-display);
  font-weight: 700;
}

.price-sale {
  display: grid;
  gap: 2px;
}

.price-sale strong {
  font-size: 1.1rem;
}

.old-price {
  color: var(--muted);
  font-size: 0.78rem;
  text-decoration: line-through;
}

.empty-cart {
  padding: 24px;
  border: 1px dashed rgba(255, 255, 255, 0.14);
  border-radius: var(--r-md);
  color: var(--muted);
  text-align: center;
}

/* Bolt admin */
.shop-admin-list-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.shop-admin-list-actions .secondary-action {
  min-height: 40px;
  padding: 0 16px;
  font-size: 0.84rem;
}

.shop-admin-list-actions .active {
  border-color: rgba(242, 211, 138, 0.55);
  background: rgba(214, 168, 79, 0.16);
  color: var(--gold-2);
}

.shop-bulk-sale-panel {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid rgba(214, 168, 79, 0.26);
  border-radius: var(--r-md);
  background: rgba(214, 168, 79, 0.06);
}

.shop-bulk-sale-row,
.shop-bulk-sale-tools {
  display: grid;
  gap: 8px;
}

/* A sorokban 2 vagy 3 elem van (cimke, mezo, gomb): rugalmasan egy sorba rendezzuk. */
.shop-bulk-sale-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
}

.shop-bulk-sale-row label {
  flex: 1 1 auto;
}

.shop-bulk-sale-row input:not([type="checkbox"]) {
  flex: 1 1 90px;
  width: auto;
  min-width: 0;
}

.shop-bulk-sale-tools {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.shop-bulk-sale-panel .primary-action,
.shop-bulk-sale-panel .secondary-action {
  min-height: 44px;
  padding: 0 16px;
  font-size: 0.84rem;
}

.shop-admin-product-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 8px;
}

.shop-admin-product-row.selection-mode {
  grid-template-columns: 40px minmax(0, 1fr);
  align-items: stretch;
}

.shop-admin-row-main {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}

.shop-product-select {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 58px;
  border: 1px solid var(--lite-line);
  border-radius: var(--r-sm);
  background: var(--lite-fill);
  cursor: pointer;
}

.shop-product-select input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.shop-product-select span {
  position: relative;
  width: 20px;
  height: 20px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 6px;
  background: var(--field-bg);
}

.shop-product-select input:checked + span {
  border-color: var(--gold);
  background: var(--gold);
  box-shadow: 0 0 18px rgba(214, 168, 79, 0.35);
}

.shop-product-select input:checked + span::after {
  content: "";
  position: absolute;
  top: 1px;
  left: 5px;
  width: 5px;
  height: 10px;
  border-right: 2px solid #17110a;
  border-bottom: 2px solid #17110a;
  transform: rotate(45deg);
}

.shop-admin-delete {
  min-height: 58px;
  padding: 0 14px;
  border: 1px solid rgba(255, 90, 103, 0.34);
  border-radius: var(--r-sm);
  background: rgba(255, 90, 103, 0.08);
  color: var(--red-2);
  font-size: 0.76rem;
  font-weight: 700;
  transition: background 0.25s, border-color 0.25s;
}

.shop-admin-delete:hover {
  border-color: rgba(255, 90, 103, 0.6);
  background: rgba(255, 90, 103, 0.16);
  color: var(--text);
}

.shop-admin-form textarea {
  min-height: 170px;
  resize: vertical;
}

.shop-sale-toggle {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 14px;
  border: 1px solid var(--lite-line);
  border-radius: var(--r-sm);
  background: var(--lite-fill);
  cursor: pointer;
}

.shop-sale-toggle input {
  width: 18px;
  height: 18px;
}

.shop-sale-fields {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid rgba(214, 168, 79, 0.24);
  border-radius: var(--r-md);
  background: rgba(214, 168, 79, 0.06);
}

.shop-admin-actions .primary-action,
.shop-admin-actions .secondary-action,
.faction-admin-actions .primary-action,
.faction-admin-actions .secondary-action {
  min-height: 44px;
  padding: 0 18px;
  font-size: 0.86rem;
}

.faction-admin-list-head .secondary-action {
  min-height: 40px;
  padding: 0 16px;
  font-size: 0.84rem;
}

.coupon-admin-card {
  display: grid;
  gap: 12px;
  margin-top: 8px;
  padding: 16px;
  border: 1px solid rgba(41, 210, 197, 0.22);
  border-radius: var(--r-md);
  background: rgba(41, 210, 197, 0.05);
}

.coupon-admin-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.coupon-admin-head h3 {
  font-size: 1.02rem;
}

.coupon-admin-form {
  display: grid;
  gap: 10px;
}

.coupon-admin-form .primary-action {
  min-height: 46px;
}

.coupon-admin-check {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 0.9rem;
  cursor: pointer;
}

.coupon-admin-check input {
  width: auto;
  margin: 0;
}

/* Kupon termek-szukites: kategoriak + termekek pipaval, gorgetheto listaban. */
.coupon-product-picker {
  display: grid;
  gap: 8px;
  min-width: 0;
  margin: 0;
  padding: 10px 14px 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--r-sm);
}

.coupon-product-picker legend {
  padding: 0 6px;
  color: var(--text-2);
  font-size: 0.86rem;
  font-weight: 600;
}

.coupon-product-hint {
  margin: 0;
  color: var(--muted);
  font-size: 0.8rem;
  overflow-wrap: anywhere;
}

.coupon-product-list {
  display: grid;
  gap: 10px;
  max-height: 240px;
  padding-right: 4px;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.coupon-product-group {
  display: grid;
  gap: 4px;
}

.coupon-product-picker .coupon-product-category {
  color: var(--text);
  font-weight: 700;
}

.coupon-product-picker .coupon-product-item {
  padding-left: 22px;
  color: var(--muted);
  font-size: 0.85rem;
  font-weight: 500;
}

.coupon-product-item input:disabled + span {
  opacity: 0.6;
}

.coupon-product-missing {
  color: var(--red-2);
  font-size: 0.78rem;
  font-weight: 700;
}

.coupon-admin-list {
  display: grid;
  gap: 8px;
}

.coupon-admin-item {
  display: grid;
  gap: 6px;
  padding: 12px 14px;
  border: 1px solid var(--lite-line);
  border-radius: var(--r-sm);
  background: var(--lite-fill);
}

.coupon-admin-item div {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.coupon-admin-item span,
.coupon-admin-item small {
  color: var(--muted);
}

.coupon-admin-item .coupon-admin-actions {
  justify-content: flex-start;
  margin-top: 2px;
}

.coupon-admin-actions button {
  padding: 5px 14px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--r-pill);
  background: rgba(255, 255, 255, 0.06);
  font-size: 0.8rem;
  font-weight: 600;
}

.coupon-admin-actions button:hover {
  background: rgba(255, 255, 255, 0.12);
}

.coupon-admin-actions .coupon-delete {
  border-color: rgba(255, 90, 103, 0.4);
  color: var(--red-2);
}

.coupon-badge {
  display: inline-block;
  margin-left: 6px;
  padding: 1px 9px;
  border: 1px solid rgba(41, 210, 197, 0.4);
  border-radius: var(--r-pill);
  background: rgba(41, 210, 197, 0.14);
  color: var(--teal-2);
  font-size: 0.7rem;
  font-weight: 700;
  vertical-align: middle;
}

/* Kosar (jobb oldali uveg-fiok) */
.cart-modal {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  justify-items: end;
}

.cart-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(3, 4, 7, 0.62);
  animation: fadeIn 0.3s var(--ease-soft) both;
}

.cart-panel {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  width: min(470px, 100%);
  height: 100vh;
  height: 100dvh;
  padding: 24px 24px max(20px, env(safe-area-inset-bottom));
  overflow: hidden;
  border-left: 1px solid rgba(255, 255, 255, 0.12);
  background: linear-gradient(160deg, rgba(22, 27, 37, 0.88), rgba(9, 12, 18, 0.94));
  box-shadow: -40px 0 100px -30px rgba(0, 0, 0, 0.8), var(--inner-highlight);
  -webkit-backdrop-filter: blur(24px) saturate(140%);
  backdrop-filter: blur(24px) saturate(140%);
  animation: drawerIn 0.55s var(--ease-out) both;
}

.cart-panel-head {
  display: flex;
  flex: 0 0 auto;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.cart-panel-head .eyebrow {
  margin-bottom: 6px;
}

.cart-panel h2 {
  font-size: 1.6rem;
}

.cart-items {
  display: grid;
  flex: 1 1 auto;
  align-content: start;
  gap: 10px;
  min-height: 0;
  padding: 18px 0;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

.cart-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border: 1px solid var(--lite-line);
  border-radius: var(--r-md);
  background: var(--lite-fill);
  animation: fadeUp 0.4s var(--ease-out) both;
}

.cart-item h3 {
  margin-bottom: 4px;
  font-family: var(--font-body);
  font-size: 0.95rem;
}

.cart-item span {
  color: var(--muted);
  font-size: 0.82rem;
}

.remove-item {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 1px solid rgba(255, 90, 103, 0.36);
  border-radius: 50%;
  background: rgba(255, 90, 103, 0.08);
  transition: background 0.25s;
}

.remove-item:hover {
  background: rgba(255, 90, 103, 0.2);
}

.remove-item .close-icon {
  width: 12px;
  height: 12px;
}

.cart-checkout-area {
  flex: 0 0 auto;
  max-height: 62vh;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.cart-consents {
  display: grid;
  gap: 12px;
  min-width: 0;
  margin: 0;
  padding: 16px;
  border: 1px solid var(--lite-line);
  border-radius: var(--r-md);
  background: rgba(255, 255, 255, 0.03);
}

.cart-consents legend {
  padding: 0 8px;
  color: var(--text);
  font-size: 0.86rem;
  font-weight: 700;
}

.cart-consent-option {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  align-items: start;
  gap: 10px;
  color: var(--muted);
  font-size: 0.84rem;
  line-height: 1.5;
  cursor: pointer;
}

.cart-consent-option input {
  width: 18px;
  height: 18px;
  margin: 2px 0 0;
  accent-color: var(--teal);
  cursor: pointer;
}

.cart-consent-option:has(input:checked) {
  color: var(--text);
}

.cart-legal-link {
  color: var(--gold-2);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.cart-legal-link:hover {
  color: var(--teal-2);
}

.cart-consent-hint {
  color: var(--muted);
  font-size: 0.76rem;
  line-height: 1.45;
}

.cart-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.cart-summary span {
  display: block;
  margin-bottom: 2px;
  color: var(--muted);
  font-size: 0.86rem;
}

.cart-summary strong {
  color: var(--gold-2);
  font-family: var(--font-display);
  font-size: 1.3rem;
}

.checkout-button {
  min-height: 52px;
  padding: 0 30px;
}

.cart-discount-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: 10px;
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 700;
}

.cart-discount-row strong {
  color: var(--teal-2);
}

.checkout-message {
  margin-top: 12px;
  color: var(--teal-2);
  line-height: 1.5;
}

.checkout-message:empty {
  display: none;
}

.checkout-message.error {
  color: var(--red-2);
}

.cart-coupon {
  display: grid;
  gap: 9px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.cart-coupon label {
  color: var(--text-2);
  font-size: 0.86rem;
  font-weight: 600;
}

.cart-coupon-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}

.cart-coupon input {
  min-width: 0;
}

.cart-coupon p {
  min-height: 20px;
  color: var(--teal-2);
  font-size: 0.82rem;
  font-weight: 600;
}

.cart-coupon p.error {
  color: var(--red-2);
}

/* Frakcio kod a kosar tetejen (a kuponmezo stilusaval). */
.cart-coupon.cart-faction-code {
  margin: 0 0 14px;
  padding: 0 0 14px;
  border-top: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.cart-faction-code input {
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.cart-faction-code p:not(.error) {
  color: var(--muted);
  font-weight: 500;
  line-height: 1.45;
}

.remove-coupon-button {
  justify-self: start;
  min-height: 36px;
  padding: 0 14px;
  border: 1px solid rgba(255, 90, 103, 0.36);
  border-radius: var(--r-pill);
  background: rgba(255, 90, 103, 0.08);
  color: var(--red-2);
  font-size: 0.82rem;
  font-weight: 700;
}

/* ---------------------------------------------------------------------
   Lablec + "kovetkezo oldal" kartya
   --------------------------------------------------------------------- */

.site-footer {
  position: relative;
  width: var(--shell);
  margin: 30px auto 0;
  padding-bottom: max(26px, env(safe-area-inset-bottom));
}

.next-teaser {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas:
    "label arrow"
    "title arrow"
    "text arrow";
  align-items: center;
  gap: 4px 24px;
  width: 100%;
  padding: clamp(26px, 4.5vw, 46px);
  border-radius: var(--r-xl);
  color: var(--text);
  text-align: left;
}

.next-label {
  grid-area: label;
  color: var(--gold-2);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.26em;
  text-transform: uppercase;
}

.next-title {
  grid-area: title;
  font-family: var(--font-display);
  font-size: clamp(2rem, 5.4vw, 3.8rem);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.next-text {
  grid-area: text;
  margin-top: 4px;
  color: var(--muted);
}

.next-arrow {
  grid-area: arrow;
  display: grid;
  place-items: center;
  width: clamp(56px, 7vw, 72px);
  height: clamp(56px, 7vw, 72px);
  border-radius: 50%;
  background: linear-gradient(135deg, #f6dc9c, var(--gold) 55%, var(--gold-deep));
  color: #17110a;
  box-shadow: 0 14px 34px -10px rgba(214, 168, 79, 0.7), inset 0 1px 0 rgba(255, 255, 255, 0.6);
  transition: transform 0.5s var(--ease-out);
}

.next-arrow svg {
  width: 26px;
  height: 26px;
}

.next-teaser:hover .next-arrow {
  transform: translateX(6px) rotate(-8deg);
}

.footer-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px 24px;
  margin-top: 26px;
  padding-top: 22px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-weight: 700;
  text-decoration: none;
}

.footer-brand img {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  box-shadow: 0 0 0 1px rgba(214, 168, 79, 0.45);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 2px;
}

.footer-links button {
  padding: 8px 12px;
  border: 0;
  border-radius: var(--r-pill);
  background: transparent;
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 600;
  transition: color 0.25s, background 0.25s;
}

.footer-links button:hover,
.footer-links button.active {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
}

.footer-copy {
  color: var(--faint);
  font-size: 0.8rem;
}

/* ---------------------------------------------------------------------
   Suti-ertesites (lebego uveg-kartya, nem takarja el az oldalt)
   --------------------------------------------------------------------- */

.cookie-consent {
  position: fixed;
  right: 0;
  bottom: max(16px, env(safe-area-inset-bottom));
  left: 0;
  z-index: 60;
  display: flex;
  justify-content: center;
  padding: 0 14px;
  pointer-events: none;
}

.cookie-consent-card {
  display: flex;
  align-items: center;
  gap: 20px;
  width: min(780px, 100%);
  padding: 18px 18px 18px 22px;
  background: linear-gradient(135deg, rgba(24, 29, 40, 0.8), rgba(12, 15, 22, 0.86));
  pointer-events: auto;
  animation: cookieIn 0.7s var(--ease-out) 0.6s both;
}

.cookie-consent-copy {
  min-width: 0;
}

.cookie-consent strong {
  display: block;
  margin-bottom: 4px;
  font-size: 0.95rem;
}

.cookie-consent p {
  color: var(--muted);
  font-size: 0.85rem;
  line-height: 1.5;
}

.cookie-consent-actions {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 10px;
}

.cookie-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 16px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--r-pill);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  font-size: 0.88rem;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.25s, border-color 0.25s;
}

.cookie-link:hover {
  border-color: rgba(242, 211, 138, 0.42);
  background: rgba(255, 255, 255, 0.1);
}

/* ---------------------------------------------------------------------
   Mozgas-segedek
   --------------------------------------------------------------------- */

.motion-pending [data-fx] {
  opacity: 0;
}

/* A script.js .reveal animacioja csak az onyx-motion.js altal nem kezelt elemekre. */
.reveal:not([data-fx]) {
  opacity: 0;
  transform: translateY(24px);
}

.reveal.in-view:not([data-fx]) {
  opacity: 1;
  transform: none;
  transition: opacity 0.8s var(--ease-out), transform 0.8s var(--ease-out);
}

.info-heading.reveal,
.shop-login.reveal {
  opacity: 1;
  transform: none;
}

@keyframes topbarDrop {
  from {
    opacity: 0;
    transform: translateY(-24px) scale(0.98);
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
}

@keyframes modalIn {
  from {
    opacity: 0;
    transform: perspective(1200px) translateY(26px) rotateX(10deg) scale(0.96);
  }
}

@keyframes drawerIn {
  from {
    opacity: 0;
    transform: perspective(1400px) translateX(60px) rotateY(-10deg);
  }
}

@keyframes cookieIn {
  from {
    opacity: 0;
    transform: translateY(30px) scale(0.97);
  }
}

@keyframes scrollCue {
  from {
    top: -18px;
  }
  to {
    top: 100%;
  }
}

@keyframes saleBannerFade {
  from {
    opacity: 0;
    transform: translateY(-3px);
  }
}

/* ---------------------------------------------------------------------
   Reszponziv
   --------------------------------------------------------------------- */

@media (max-width: 1080px) {
  .nav-dot {
    padding: 0 11px;
    font-size: 0.84rem;
  }

  .brand-text small {
    display: none;
  }
}

/* 8 menupont (Fejlesztesek) a mobil menu hatara (820px) folott is ferjen ki. */
@media (min-width: 821px) and (max-width: 900px) {
  .nav-dot {
    padding: 0 8px;
  }
}

@media (max-width: 980px) {
  .home-factions {
    height: 250vh;
  }

  .home-factions-sticky {
    grid-template-columns: 1fr;
    grid-template-rows: auto minmax(0, 1fr);
    align-content: start;
    gap: 0;
    padding-top: calc(var(--header-space) + 4px);
    padding-bottom: 16px;
  }

  .home-factions-copy > p:not(.eyebrow) {
    display: none;
  }

  .home-factions-copy h2 {
    font-size: clamp(1.7rem, 6vw, 2.4rem);
  }

  .stat-row {
    margin: 16px 0 18px;
  }

  .stat {
    min-width: 0;
    padding: 10px 14px;
  }

  .stat strong {
    font-size: 1.6rem;
  }

  .ring-stage {
    align-self: stretch;
    height: auto;
    min-height: 0;
  }

  .faction-ring {
    --R: clamp(150px, 38vw, 240px);
    --cw: clamp(120px, 31vw, 170px);
  }

  .faction-layout,
  .rules-layout {
    grid-template-columns: 1fr;
  }

  .faction-detail {
    position: relative;
    top: 0;
  }

  .faction-overview {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .shop-app {
    grid-template-columns: 1fr;
  }

  .shop-sidebar {
    position: relative;
    top: 0;
    min-height: 0;
  }

  .shop-admin-open,
  .shop-admin-open.hidden + .logout-button {
    margin-top: 0;
  }

  .faction-admin-layout,
  .shop-admin-layout,
  .faction-admin-layout.is-scrollable,
  .shop-admin-layout.is-scrollable {
    grid-template-columns: 1fr;
    align-content: start;
    padding-bottom: 34px;
    overflow-y: auto;
    overscroll-behavior: contain;
  }

  .faction-admin-list,
  .faction-admin-form,
  .shop-admin-list,
  .shop-admin-editor-column,
  .shop-admin-form,
  .faction-admin-list.is-scrollable,
  .faction-admin-form.is-scrollable,
  .shop-admin-list.is-scrollable,
  .shop-admin-editor-column.is-scrollable {
    height: auto;
    min-height: auto;
    max-height: none;
    overflow: visible;
  }

  .home-shop {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .gem-anchor-shop {
    order: -1;
    width: min(56vw, 230px);
  }
}

@media (max-width: 820px) {
  .topbar {
    border-radius: 24px;
  }

  .menu-toggle {
    display: inline-grid;
  }

  .nav-indicator {
    display: none;
  }

  .nav-points {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    left: 0;
    display: grid;
    gap: 4px;
    max-height: calc(100vh - var(--header-space));
    max-height: calc(100dvh - var(--header-space));
    padding: 10px;
    overflow-y: auto;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 24px;
    background: linear-gradient(160deg, rgb(20, 24, 33), rgb(10, 13, 19));
    box-shadow: 0 30px 70px -20px rgba(0, 0, 0, 0.85), var(--inner-highlight);
    opacity: 0;
    pointer-events: none;
    transform: translateY(-10px) scale(0.98);
    transform-origin: top center;
    visibility: hidden;
    transition: opacity 0.3s var(--ease-soft), transform 0.4s var(--ease-out), visibility 0.3s;
  }

  .topbar.menu-open .nav-points {
    opacity: 1;
    pointer-events: auto;
    transform: none;
    visibility: visible;
  }

  .nav-dot {
    justify-content: flex-start;
    width: 100%;
    height: 48px;
    padding: 0 16px;
    border-radius: 16px;
    font-size: 0.98rem;
    text-align: left;
  }

  .nav-dot.active {
    background: linear-gradient(135deg, rgba(214, 168, 79, 0.2), rgba(41, 210, 197, 0.1));
  }
}

@media (max-width: 760px) {
  :root {
    --shell: calc(100% - 32px);
    --topbar-h: 60px;
    --topbar-gap: 10px;
  }

  /* Kuponcsik ket sorban: felul a kedvezmeny, alatta a kod es a lejarat. */
  .sale-strip-slide {
    grid-template-columns: auto auto;
    grid-template-areas:
      "copy copy"
      "action timer";
    justify-content: space-between;
    gap: 8px 12px;
    min-height: 0;
    padding: 9px 0 11px;
  }

  .sale-strip-text {
    display: none;
  }

  .sale-strip-code,
  .sale-strip-shop {
    justify-self: start;
  }

  .sale-strip-code {
    height: 38px;
  }

  .sale-strip-code-text {
    min-width: 0;
    max-width: 44vw;
    padding: 0 14px;
    overflow: hidden;
    font-size: 0.95rem;
    text-overflow: ellipsis;
  }

  .sale-strip-code-icon {
    width: 40px;
  }

  .sale-strip-shop {
    min-height: 38px;
  }

  .sale-strip-timer {
    gap: 7px;
  }

  .sale-strip-timer-label {
    font-size: 0.6rem;
    letter-spacing: 0.12em;
  }

  .sale-strip-clock {
    padding: 7px 9px;
    font-size: 0.88rem;
  }

  .sale-strip-sep {
    margin: 0 0.14em;
  }

  .hero {
    align-items: end;
    padding-bottom: 110px;
  }

  .gem-anchor-hero {
    top: calc(var(--header-space) + 2vh);
    right: 50%;
    width: min(76vw, 42vh);
    transform: translateX(50%);
  }

  .hero-title-main {
    font-size: clamp(3.8rem, 22vw, 6.4rem);
  }

  .hero-copy {
    margin-top: 20px;
  }

  .hero-actions {
    margin-top: 28px;
  }

  .feature-grid,
  .doc-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .feature-card {
    min-height: 0;
  }

  .feature-card h3 {
    padding-top: 24px;
  }

  .doc-card {
    min-height: 0;
  }

  .wall-card {
    width: 140px;
    margin: -86px 0 0 -70px;
    padding: 16px 8px 14px;
  }

  .wall-card img {
    width: 84px;
    height: 84px;
  }

  .wall-stage {
    height: clamp(300px, 44vh, 380px);
  }

  .team-wall {
    --R: 560px;
    --step: 15deg;
  }

  .gem-anchor-page {
    top: -10px;
    right: -4%;
    width: 40vw;
  }

  .team-hierarchy::before {
    left: 26px;
  }

  .team-tier-members,
  .team-tier-members.team-tier-single {
    grid-template-columns: minmax(0, 1fr);
  }

  .team-tier-owners > .team-card {
    flex-basis: 100%;
  }

  .faction-overview,
  .faction-detail-grid {
    grid-template-columns: 1fr;
  }

  .faction-button {
    grid-template-columns: 44px minmax(0, 1fr);
  }

  .faction-button em {
    grid-column: 2;
    justify-self: start;
    max-width: 100%;
  }

  .faction-detail-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .faction-toolbar,
  .shop-head,
  .faction-admin-list-head,
  .faction-admin-actions,
  .shop-admin-list-head,
  .shop-admin-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .faction-admin-head,
  .shop-admin-head {
    align-items: flex-start;
    padding: 16px;
  }

  .faction-tabs {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .faction-tab {
    padding: 0 10px;
  }

  .shop-admin-list-actions,
  .shop-bulk-sale-row,
  .shop-bulk-sale-tools,
  .shop-admin-row-main {
    grid-template-columns: 1fr;
  }

  .shop-admin-list-actions {
    display: grid;
  }

  .faction-admin-open,
  .faction-admin-actions button,
  .shop-admin-actions button,
  .shop-admin-list-actions button,
  .shop-admin-delete {
    width: 100%;
  }

  .shop-admin-delete {
    min-height: 42px;
  }

  .faction-admin-panel,
  .shop-admin-panel {
    padding: 10px;
  }

  .faction-admin-card,
  .shop-admin-card {
    height: calc(100vh - 20px);
    height: calc(100dvh - 20px);
  }

  .shop-sidebar {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    padding: 14px;
  }

  .profile-box,
  .shop-menu {
    grid-column: 1 / -1;
  }

  .shop-admin-open,
  .logout-button {
    min-height: 44px;
    padding: 0 10px;
  }

  .cart-pill {
    justify-content: space-between;
  }

  .custom-points-head {
    display: grid;
  }

  #customPointsSummary {
    text-align: left;
  }

  .custom-points-row,
  .cart-coupon-row {
    grid-template-columns: 1fr;
  }

  .product-grid {
    grid-template-columns: 1fr;
  }

  .product-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .cart-summary {
    align-items: stretch;
    flex-direction: column;
  }

  .cookie-consent-card {
    align-items: stretch;
    flex-direction: column;
    gap: 14px;
    padding: 18px;
  }

  .cookie-consent-actions {
    display: grid;
    grid-template-columns: auto 1fr;
  }

  .footer-bar {
    flex-direction: column;
    align-items: flex-start;
  }

  .next-teaser {
    gap: 4px 16px;
  }
}

@media (max-width: 700px) {
  .terms-pdf-viewer {
    padding: 0;
    border: 0;
    background: none;
    box-shadow: none;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }

  .terms-pdf-frame {
    display: none;
  }

  .pdf-mobile-view {
    display: grid;
    gap: 12px;
    width: 100%;
  }

  .pdf-mobile-status,
  .pdf-mobile-error {
    padding: 22px 16px;
    border: 1px solid var(--glass-line);
    border-radius: var(--r-md);
    background: var(--glass-fill);
    color: var(--muted);
    line-height: 1.55;
    text-align: center;
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
  }

  .pdf-mobile-error a {
    color: var(--gold-2);
    font-weight: 700;
  }

  .pdf-mobile-page {
    display: grid;
    place-items: center;
    width: 100%;
    min-height: 180px;
    overflow: hidden;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 16px 36px -12px rgba(0, 0, 0, 0.7);
  }

  .pdf-mobile-page canvas {
    display: block;
    width: 100%;
    height: auto;
  }

  .terms-pdf-link {
    flex: 1 1 150px;
    justify-content: center;
  }
}

@media (max-width: 420px) {
  .brand-text strong {
    font-size: 0.92rem;
    letter-spacing: 0.16em;
  }

  .hero-actions > * {
    flex: 1 1 100%;
  }

  .stat-row {
    flex-wrap: nowrap;
  }
}

/* ---------------------------------------------------------------------
   Tartalekok: nincs backdrop-filter / nincs WebGL / csokkentett mozgas
   --------------------------------------------------------------------- */

@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .glass,
  .faction-overview-card,
  .cart-pill,
  .faction-tabs,
  .product-card,
  .terms-pdf-viewer,
  .topbar {
    background: linear-gradient(145deg, rgba(26, 31, 42, 0.95), rgba(13, 16, 23, 0.97));
  }

  .cart-panel {
    background: linear-gradient(160deg, rgb(22, 27, 37), rgb(9, 12, 18));
  }
}

.no-webgl .onyx-city {
  opacity: max(var(--city-o, 0.12), 0.22);
}

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

  .motion-pending [data-fx] {
    opacity: 1;
  }
}

/* ---------------------------------------------------------------------
   Fejlesztesi tabla (/board, onyx-board.js) - Trello-szeru kategoriak es kartyak
   --------------------------------------------------------------------- */

.kb-shell {
  width: min(1600px, calc(100% - 40px));
  margin: 0 auto;
}

.kb-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 18px;
  margin-bottom: 18px;
  padding: 12px 12px 12px 18px;
}

.kb-toolbar-info,
.kb-toolbar-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
  min-width: 0;
}

.kb-toolbar-actions .primary-action,
.kb-toolbar-actions .secondary-action {
  min-height: 42px;
  padding: 0 20px;
}

.kb-mode {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 30px;
  padding: 0 12px;
  border: 1px solid var(--lite-line);
  border-radius: var(--r-pill);
  background: var(--lite-fill);
  color: var(--text-2);
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.kb-mode::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--teal);
  box-shadow: 0 0 10px var(--teal);
}

.kb-mode.is-admin {
  border-color: rgba(242, 211, 138, 0.35);
  color: var(--gold-2);
}

.kb-mode.is-admin::before {
  background: var(--gold-2);
  box-shadow: 0 0 10px var(--gold);
}

.kb-status {
  color: var(--muted);
  font-size: 0.86rem;
}

.kb-status.error {
  color: var(--red-2);
}

.kb-board {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  min-height: 320px;
  padding: 4px 2px 18px;
  overflow-x: auto;
  overscroll-behavior-x: contain;
}

.kb-loading {
  padding: 40px 6px;
  color: var(--muted);
}

.kb-col {
  position: relative;
  display: flex;
  flex: 0 0 300px;
  flex-direction: column;
  width: 300px;
  max-width: calc(100vw - 56px);
  padding: 12px;
  border: 1px solid var(--glass-line);
  border-radius: var(--r-lg);
  background: linear-gradient(180deg, rgba(20, 25, 34, 0.8), rgba(10, 13, 19, 0.74));
  box-shadow: var(--glass-shadow), var(--inner-highlight);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  backdrop-filter: blur(16px) saturate(140%);
}

.kb-col::before {
  content: "";
  position: absolute;
  top: -1px;
  right: 22px;
  left: 22px;
  height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, transparent, var(--kb-accent, var(--teal)), transparent);
}

.kb-col-head {
  position: relative;
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 36px;
  padding: 0 0 10px 4px;
}

.kb-col-dot {
  flex: 0 0 auto;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--kb-accent, var(--teal));
  box-shadow: 0 0 12px var(--kb-accent, var(--teal));
}

.kb-col-title {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.kb-col-count {
  flex: 0 0 auto;
  min-width: 26px;
  padding: 3px 8px;
  border-radius: var(--r-pill);
  background: rgba(255, 255, 255, 0.07);
  color: var(--text-2);
  font-size: 0.74rem;
  font-weight: 700;
  text-align: center;
}

.kb-col-tools {
  display: flex;
  flex: 0 0 auto;
  gap: 1px;
  opacity: 0;
  transition: opacity 0.2s;
}

.kb-col:hover .kb-col-tools,
.kb-col:focus-within .kb-col-tools,
.kb-col-tools.is-visible {
  opacity: 1;
}

/* Egerrel a gombok rejtve nem foglalnak helyet (a cim teljes hosszaban latszik), raallva a
   fejlec jobb szelere usznak. Erintokepernyon mindig latszanak, a sorban. */
@media (hover: hover) {
  .kb-col-tools:not(.is-visible) {
    position: absolute;
    top: 2px;
    right: -2px;
    padding: 2px;
    border-radius: 11px;
    background: rgba(17, 21, 30, 0.97);
    box-shadow: 0 0 0 1px var(--lite-line), -14px 0 16px -6px rgba(14, 18, 26, 0.95);
    pointer-events: none;
  }

  .kb-col:hover .kb-col-tools,
  .kb-col:focus-within .kb-col-tools {
    pointer-events: auto;
  }
}

@media (hover: none) {
  .kb-col-tools {
    opacity: 1;
  }
}

.kb-tool {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  padding: 0;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: var(--muted);
  transition: background 0.2s, color 0.2s;
}

.kb-tool:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.09);
  color: var(--text);
}

.kb-tool:disabled {
  cursor: default;
  opacity: 0.3;
}

.kb-tool-danger:hover:not(:disabled) {
  background: rgba(255, 90, 103, 0.14);
  color: var(--red-2);
}

.kb-tool-ok {
  color: var(--teal-2);
}

.kb-tool svg,
.kb-add-card svg,
.kb-col-add svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.kb-col-note {
  margin: -4px 4px 10px;
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.5;
}

.kb-cards {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-height: 64px;
}

.kb-card {
  position: relative;
  display: grid;
  gap: 6px;
  padding: 11px 12px 10px;
  border: 1px solid var(--lite-line);
  border-radius: 14px;
  background: linear-gradient(160deg, rgba(37, 43, 55, 0.94), rgba(22, 27, 36, 0.94));
  box-shadow: 0 10px 22px -14px rgba(0, 0, 0, 0.85), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  color: var(--text);
  cursor: pointer;
  transition: border-color 0.2s, transform 0.25s var(--ease-out);
}

.kb-card:hover {
  border-color: rgba(242, 211, 138, 0.32);
  transform: translateY(-1px);
}

.kb-col-bug .kb-card {
  box-shadow: inset 3px 0 0 rgba(255, 90, 103, 0.55), 0 10px 22px -14px rgba(0, 0, 0, 0.85);
}

.kb-can-edit .kb-card {
  cursor: grab;
}

.kb-card-top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.kb-card-no {
  color: var(--faint);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.kb-chip {
  padding: 2px 7px;
  border-radius: var(--r-pill);
  font-size: 0.64rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.kb-chip-discord {
  background: rgba(88, 101, 242, 0.2);
  color: #c0c6ff;
}

.kb-chip-private {
  background: rgba(255, 255, 255, 0.08);
  color: var(--muted);
}

/* Kartya-tipus (a frissites-uzenet szakasza) */
.kb-chip-new {
  background: rgba(87, 242, 135, 0.14);
  color: #8ff0b0;
}

.kb-chip-change {
  background: rgba(108, 196, 255, 0.15);
  color: #a6dcff;
}

.kb-chip-fix {
  background: rgba(255, 159, 107, 0.15);
  color: #ffc39f;
}

.kb-card-title {
  font-size: 0.93rem;
  font-weight: 600;
  line-height: 1.4;
  overflow-wrap: anywhere;
}

.kb-card-desc {
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.kb-card-date {
  color: var(--faint);
  font-size: 0.72rem;
}

/* Kartya alja: datum + a felelosok profilkepei */
.kb-card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 22px;
}

.kb-avatars {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
}

.kb-avatar {
  display: inline-flex;
  flex: 0 0 auto;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  object-fit: cover;
  background: rgba(255, 255, 255, 0.08);
}

.kb-avatars .kb-avatar {
  border: 2px solid #1b2029;
  pointer-events: none;
}

.kb-avatars .kb-avatar + .kb-avatar {
  margin-left: -7px;
}

.kb-avatar-more {
  align-items: center;
  justify-content: center;
  color: var(--text-2);
  font-size: 0.6rem;
  font-weight: 700;
}

.kb-card-fresh {
  animation: kbFresh 2.6s var(--ease-soft) both;
}

@keyframes kbFresh {
  0%,
  35% {
    border-color: rgba(242, 211, 138, 0.8);
    box-shadow: 0 0 0 3px rgba(242, 211, 138, 0.18), 0 10px 22px -14px rgba(0, 0, 0, 0.85);
  }
}

.kb-empty {
  display: grid;
  place-items: center;
  min-height: 64px;
  padding: 12px;
  border: 1px dashed rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  color: var(--faint);
  font-size: 0.82rem;
  text-align: center;
}

.kb-cards:has(.kb-placeholder) .kb-empty {
  display: none;
}

/* Huzas: az eredeti kartya helyen szaggatott helyorzo, a kartya masolata kovet az egerrel. */
.kb-dragging {
  display: none !important;
}

.kb-placeholder {
  flex: 0 0 auto;
  border: 1px dashed rgba(242, 211, 138, 0.5);
  border-radius: 14px;
  background: rgba(242, 211, 138, 0.06);
}

.kb-ghost {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 90;
  margin: 0;
  border-color: rgba(242, 211, 138, 0.55);
  box-shadow: 0 28px 54px -14px rgba(0, 0, 0, 0.9), 0 0 0 1px rgba(242, 211, 138, 0.25);
  opacity: 0.96;
  pointer-events: none;
  transition: none;
  will-change: transform;
}

.kb-is-dragging,
.kb-is-dragging * {
  cursor: grabbing !important;
}

.kb-add-card {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  min-height: 40px;
  margin-top: 10px;
  padding: 0 10px;
  border: 0;
  border-radius: var(--r-sm);
  background: transparent;
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 600;
  transition: background 0.2s, color 0.2s;
}

.kb-add-card:hover {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
}

.kb-composer {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}

.kb-col-new {
  gap: 10px;
}

.kb-composer-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.primary-action.kb-small {
  min-height: 38px;
  padding: 0 16px;
  font-size: 0.86rem;
}

.kb-col-add {
  flex: 0 0 240px;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 240px;
  min-height: 64px;
  border-style: dashed;
  background: rgba(255, 255, 255, 0.03);
  box-shadow: none;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 600;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
  transition: background 0.2s, border-color 0.2s, color 0.2s;
}

.kb-col-add::before {
  display: none;
}

.kb-col-add:hover {
  border-color: rgba(242, 211, 138, 0.4);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
}

.kb-input {
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--r-sm);
  background: var(--field-bg);
  color: var(--text);
  font: inherit;
  font-size: 0.92rem;
  outline: none;
  box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.25);
  transition: border-color 0.25s, box-shadow 0.25s;
}

.kb-input:focus {
  border-color: rgba(41, 210, 197, 0.6);
  box-shadow: 0 0 0 4px rgba(41, 210, 197, 0.1), inset 0 2px 8px rgba(0, 0, 0, 0.25);
}

textarea.kb-input {
  line-height: 1.5;
  resize: vertical;
}

select.kb-input option {
  background: #11151d;
  color: var(--text);
}

.kb-input.kb-rename {
  flex: 1 1 auto;
  min-width: 0;
  min-height: 34px;
  padding: 6px 10px;
}

/* Kartya / frissites ablak (az admin belepo ablak alapjaira) */
.kb-modal-card {
  width: min(620px, 100%);
  max-height: calc(100vh - 40px);
  max-height: calc(100dvh - 40px);
  overflow-y: auto;
  overscroll-behavior: contain;
}

.kb-modal-card h2 {
  padding-right: 48px;
  overflow-wrap: anywhere;
}

.admin-login-card p.kb-modal-text {
  color: var(--text-2);
  line-height: 1.65;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}

.admin-login-card p.kb-modal-text.is-empty {
  color: var(--muted);
}

.admin-login-card p.kb-modal-meta {
  margin: 4px 0 0;
  color: var(--faint);
  font-size: 0.82rem;
  line-height: 1.6;
}

.kb-modal-meta a {
  color: var(--gold-2);
}

.admin-login-card p.kb-warn {
  padding: 10px 12px;
  border: 1px solid rgba(255, 90, 103, 0.35);
  border-radius: var(--r-sm);
  background: rgba(255, 90, 103, 0.08);
  color: var(--red-2);
  font-size: 0.86rem;
}

.kb-form {
  display: grid;
  gap: 8px;
}

.kb-form label {
  margin-top: 4px;
}

.kb-form label.kb-check {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text-2);
  font-weight: 500;
  cursor: pointer;
}

.kb-check input {
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  margin: 0;
}

.admin-login-card p.kb-label {
  margin: 4px 0 0;
  color: var(--text-2);
  font-size: 0.88rem;
  font-weight: 600;
}

/* Szakaszvalto (Hibajavitasok / Atalakitasok / Ujdonsagok) */
.kb-segment {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.kb-form .kb-segment label {
  position: relative;
  margin: 0;
  cursor: pointer;
}

.kb-segment input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.kb-segment span {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 0 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--r-pill);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-2);
  font-size: 0.86rem;
  transition: border-color 0.2s, background 0.2s, color 0.2s;
}

.kb-segment label:hover span {
  border-color: rgba(242, 211, 138, 0.3);
}

.kb-segment input:checked + span {
  border-color: rgba(242, 211, 138, 0.55);
  background: rgba(242, 211, 138, 0.12);
  color: var(--gold-2);
}

.kb-segment input:focus-visible + span {
  box-shadow: 0 0 0 4px rgba(41, 210, 197, 0.18);
}

/* Felelos adminok: valaszto a kartya ablakban (olvaso modban csak a lista) */
.kb-assign {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.kb-form .kb-assign label {
  position: relative;
  margin: 0;
  cursor: pointer;
}

.kb-assign input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.kb-assign-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 36px;
  max-width: 100%;
  padding: 4px 14px 4px 4px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--r-pill);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-2);
  font-size: 0.86rem;
  font-weight: 500;
  overflow-wrap: anywhere;
  transition: border-color 0.2s, background 0.2s, color 0.2s;
}

.kb-assign-chip .kb-avatar {
  width: 26px;
  height: 26px;
}

.kb-assign label:hover .kb-assign-chip {
  border-color: rgba(41, 210, 197, 0.35);
}

.kb-assign input:checked + .kb-assign-chip {
  border-color: rgba(41, 210, 197, 0.6);
  background: rgba(41, 210, 197, 0.13);
  color: var(--text);
}

.kb-assign input:focus-visible + .kb-assign-chip {
  box-shadow: 0 0 0 4px rgba(41, 210, 197, 0.18);
}

/* Frissites embed csik szine: szinvalaszto + gyors szinek */
.kb-color-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.kb-color {
  width: 52px;
  height: 38px;
  padding: 3px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--r-sm);
  background: var(--field-bg);
  cursor: pointer;
}

.kb-swatch {
  width: 28px;
  height: 28px;
  padding: 0;
  border: 2px solid rgba(255, 255, 255, 0.18);
  border-radius: 50%;
  cursor: pointer;
  transition: transform 0.2s, border-color 0.2s;
}

.kb-swatch:hover,
.kb-swatch:focus-visible {
  border-color: rgba(255, 255, 255, 0.7);
  transform: scale(1.1);
  outline: none;
}

/* Frissites ablak: szakaszonkent egy mezo, a cim elott a tipus szinevel */
.kb-form label.kb-section-label {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
}

.kb-section-label::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
}

.kb-form label.kb-section-new::before {
  background: #57f287;
}

.kb-form label.kb-section-change::before {
  background: #6cc4ff;
}

.kb-form label.kb-section-fix::before {
  background: #ff9f6b;
}

.kb-counter.is-over {
  color: var(--red-2);
}

.kb-counter {
  justify-self: end;
  color: var(--faint);
  font-size: 0.76rem;
}

.kb-modal-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: 12px;
}

.kb-danger {
  min-height: 48px;
  margin-left: auto;
  padding: 0 18px;
  border: 1px solid rgba(255, 90, 103, 0.35);
  border-radius: var(--r-pill);
  background: rgba(255, 90, 103, 0.08);
  color: var(--red-2);
  font-size: 0.9rem;
  font-weight: 700;
  transition: background 0.2s, border-color 0.2s;
}

.kb-danger:hover {
  border-color: rgba(255, 90, 103, 0.6);
  background: rgba(255, 90, 103, 0.16);
}

.kb-toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  z-index: 95;
  max-width: min(520px, calc(100% - 32px));
  padding: 12px 18px;
  border: 1px solid rgba(41, 210, 197, 0.35);
  border-radius: var(--r-md);
  background: var(--solid-panel);
  box-shadow: 0 24px 60px -20px rgba(0, 0, 0, 0.85);
  color: var(--text);
  font-size: 0.9rem;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 12px);
  transition: opacity 0.3s var(--ease-soft), transform 0.4s var(--ease-out);
}

.kb-toast.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

.kb-toast.is-error {
  border-color: rgba(255, 90, 103, 0.45);
  color: var(--red-2);
}

@media (max-width: 760px) {
  .kb-shell {
    width: var(--shell);
  }

  .kb-toolbar {
    padding: 12px;
  }

  .kb-toolbar-actions,
  .kb-toolbar-actions > * {
    flex: 1 1 auto;
  }

  .kb-col {
    flex-basis: 272px;
    width: 272px;
  }

  .kb-danger {
    margin-left: 0;
  }
}
