/* nlr-shell.css — WP2 of the NLR SYSTEM port. Implements shell SPEC §3.3 (account chip + menu), §4.3 (gateway),
 * §5.2 / admin SPEC §6c (impersonation pill). Values are the computed NLC values (glow.css:227-335, 2285-2301,
 * 3702-3705; styles.css:24, 95; ui-layout.css:34), without backdrop-filter (PLAN D4).
 * Owned by WP2 only (PLAN D2). */

/* ---------- 1. Account host: one chip in the page corner, on every screen after login (PLAN D7) ---------- */
#topbar.topbar {
  position: absolute; top: 12px; right: 18px; bottom: auto; left: auto; z-index: 9000;
  width: auto; max-width: none; margin: 0; padding: 0;
}
/* Overlays that are not modals stay above the chip (modal-back is already 11000). */
body:has(.sheet-back, .sheet, .rapid-back, .galerie-back, .victory) #topbar.topbar { z-index: 45; }
#topbar .account-menu-host {
  position: relative; display: block; width: auto; margin: 0; padding: 0;
  border: 0; border-radius: 0; background: none; box-shadow: none;
}
/* NLC reserves room on the pipeline header so nothing sits under the chip (glow.css:269). */
.app-header { padding-right: 190px; }

.account-chip {
  display: flex; align-items: center; gap: 9px; height: 44px; min-height: 36px; padding: 0 14px 0 5px;
  border: 0; border-radius: 999px; cursor: pointer;
  background: rgba(6, 20, 38, .5); color: #fff; font: 700 13px Montserrat, Inter, sans-serif;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .1), 0 0 16px rgba(212, 175, 55, .15);
  transition: box-shadow .2s ease, border-color .2s ease;
}
.account-chip:hover, .account-chip[aria-expanded="true"] { box-shadow: inset 0 1px 0 rgba(255, 255, 255, .12), 0 0 22px rgba(212, 175, 55, .4); }
.account-chip:focus-visible, .account-menu-head:focus-visible, .account-menu-item:focus-visible { outline: 2px solid #f1d36a; outline-offset: 2px; }
.account-chip > span { display: block; max-width: 140px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.account-chip i, .account-menu-head i {
  width: 34px; height: 34px; flex: 0 0 auto; display: grid; place-items: center; overflow: hidden; border-radius: 50%;
  box-shadow: 0 0 0 1.5px #d4af37; background: #0b1f3a; color: #f1d36a; font-style: normal;
}
.account-chip i span, .account-menu-head i span { display: inline; }
.account-chip b { display: block; color: #d4af37; font-size: 11px; font-weight: 900; }

.account-menu {
  position: absolute; top: 52px; right: 0; width: 300px; display: grid; gap: 0; padding: 8px;
  border: 1px solid rgba(95, 140, 190, .35); border-top-color: rgba(212, 175, 55, .55); border-radius: 18px;
  background: linear-gradient(180deg, rgba(14, 34, 60, .98), rgba(6, 17, 33, .99));
  box-shadow: 0 24px 60px -18px rgba(0, 0, 0, .95);
  font-family: Montserrat, Inter, sans-serif; text-align: left;
}
.account-menu[hidden] { display: none; }
.account-menu::before { content: ""; position: absolute; left: 10%; right: 10%; top: 0; height: 1px; background: var(--glow-edge); }
.account-menu * { font-family: Montserrat, Inter, sans-serif; }

.account-menu-head {
  display: flex; align-items: center; gap: 12px; width: 100%; padding: 12px; margin: 0 0 4px;
  border: 0; border-bottom: 1px solid rgba(255, 255, 255, .07); border-radius: 12px;
  background: transparent; color: #fff; font: 700 12px/1.55 Montserrat, Inter, sans-serif; text-align: left; cursor: pointer;
}
.account-menu-head:hover { background: rgba(255, 255, 255, .04); }
.account-menu-head > span { display: grid; gap: 2px; min-width: 0; }
.account-menu-head strong { display: block; color: #fff; font: 800 .95rem/1.25 Montserrat, Inter, sans-serif; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.account-menu-head small { display: block; color: #c9a54a; font-size: .72rem; font-weight: 700; letter-spacing: .04em; line-height: 1.55; text-transform: none; }

.account-menu-label { padding: 12px 12px 4px; font: 600 .62rem Montserrat, Inter, sans-serif; letter-spacing: .24em; text-transform: uppercase; color: #6f7f95; }

.account-menu-item {
  display: flex; align-items: center; gap: 12px; width: 100%; height: 42px; min-height: 0; padding: 0 12px;
  border: 0; border-radius: 10px; background: transparent; box-shadow: none;
  color: #e6ecf3; font: 600 .88rem Montserrat, Inter, sans-serif; text-align: left; text-decoration: none; cursor: pointer;
}
.account-menu-item:hover { background: rgba(255, 255, 255, .05); color: #fff; }
.account-menu-item svg { flex: 0 0 18px; width: 18px; height: 18px; fill: none; stroke: #c9a54a; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.account-menu-item span { flex: 1; }
.account-menu-sep { height: 1px; margin: 6px 4px; background: rgba(255, 255, 255, .07); }
.account-menu-head + .account-menu-sep { display: none; }
.account-menu-logout, .account-menu-logout span, .account-menu-logout:hover { color: #ffb3bf; }
.account-menu-logout svg { stroke: #ff8a95; }

@media (max-width: 620px) {
  .account-chip > span { display: none; }
  .account-chip { padding-right: 10px; }
  .app-header { padding-right: 80px; }
  /* NLC's 300px menu fits at 390px; keep it inside narrower screens too. */
  .account-menu { width: min(300px, calc(100vw - 36px)); }
}

/* ---------- 2. Gateway (NLC .module-gateway; the scene is body.scene-gateway in nlr-base.css) ---------- */
.module-gateway { position: relative; min-height: 100vh; display: grid; place-items: center; padding: 36px 22px; color: #fff; }
.gateway-content { position: relative; z-index: 1; width: min(1040px, 100%); text-align: center; }
/* NLC centres a ~904px block (7 cards); Rents has 3, so pin the block where NLC's logo sits instead of mid-screen */
@media (min-width: 761px) {
  .module-gateway { place-items: start center; padding-top: max(36px, calc(50dvh - 485px)); }
}
.gateway-logo {
  display: block; width: min(330px, 72vw); height: auto; margin: 0 auto 20px;
  filter: drop-shadow(0 0 18px rgba(212, 175, 55, .35)) drop-shadow(0 8px 24px rgba(0, 0, 0, .5));
}
.gateway-kicker {
  display: inline-flex; align-items: center; gap: 12px; margin: 0;
  font: 800 .7rem/1.55 Inter, system-ui, sans-serif; letter-spacing: .22em; text-transform: uppercase;
  background: linear-gradient(115deg, #ffd968 0%, #d6a92f 45%, #ffe9a8 60%, #d6a92f 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 0 6px rgba(214, 169, 47, .45));
}
.gateway-kicker::before, .gateway-kicker::after { content: ""; flex: 0 0 46px; width: 46px; height: 1px; background: linear-gradient(90deg, transparent, #ffd968); }
.gateway-kicker::after { background: linear-gradient(90deg, #ffd968, transparent); }
.gateway-kicker::after { order: 3; }
.gateway-kicker > span { order: 2; }
.gateway-kicker > .gateway-kicker-extra { order: 2; margin-left: -12px; }
.gateway-kicker-extra::before { content: "\00a0·\00a0"; }
.gateway-content h1 {
  margin: 7px 0 5px; font: 700 clamp(1.65rem, 4vw, 3rem)/1.2 Montserrat, Inter, sans-serif; letter-spacing: .05em;
  background: linear-gradient(170deg, #fff 0%, #dfe6f2 38%, #fff 52%, #b9c6da 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent; text-shadow: none;
  filter: drop-shadow(0 2px 3px rgba(0, 0, 0, .6)) drop-shadow(0 0 22px rgba(214, 169, 47, .22));
}
.gateway-prompt { margin: 0 0 30px; color: #c5d0df; font: 400 1rem/1.55 Inter, system-ui, sans-serif; }
.gateway-prompt b { color: #f1d36a; font-weight: 700; }

/* Rents-only rotating motto, in the NLC glass vocabulary (shell SPEC §4.3). Animations motto-intra / motto-bara stay (styles.css). */
.gateway-motto {
  position: relative; max-width: 640px; min-height: 96px; margin: 0 auto 30px; padding: 14px 30px 18px; border-radius: 16px; overflow: hidden; text-align: center;
  background: linear-gradient(rgba(255, 255, 255, .02) 1px, transparent 1px) 0 0 / 100% 22px, linear-gradient(180deg, rgba(14, 34, 60, .82), rgba(6, 17, 33, .9));
  border: 1px solid rgba(95, 140, 190, .35); border-top-color: rgba(212, 175, 55, .55);
  box-shadow: 0 24px 60px -24px rgba(0, 0, 0, .95);
}
.gateway-motto::before {
  content: ""; position: absolute; left: 10%; right: 10%; top: 0; height: 1px; background: var(--glow-edge);
  font-size: 0; color: transparent;
}
.gateway-motto small {
  display: inline-block; padding: 3px 10px; border-radius: 999px; font: 700 10px Montserrat, Inter, sans-serif; letter-spacing: .24em;
  color: #c9a54a; background: rgba(212, 175, 55, .08); border: 1px solid rgba(212, 175, 55, .45);
}
.gateway-motto p { margin: 10px 0 0; font: 600 clamp(15px, 2vw, 18px)/1.45 Montserrat, Inter, sans-serif; color: #e6ecf3; letter-spacing: 0; }
.gateway-motto .motto-bara { position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: rgba(255, 255, 255, .05); }
.gateway-motto .motto-bara span { background: linear-gradient(90deg, #b68a1e, #d4af37, #ffd968); }

.gateway-modules { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.gateway-card {
  position: relative; overflow: hidden; isolation: isolate;
  min-height: 190px; display: grid; justify-items: center; align-content: center; gap: 12px; padding: 24px 18px;
  border: 1px solid rgba(214, 169, 47, .42); border-radius: 18px; color: #fff; font: 400 16px/1.55 Inter, system-ui, sans-serif; text-align: center; cursor: pointer;
  background:
    radial-gradient(120% 80% at 50% 0%, rgba(255, 217, 104, .10) 0%, transparent 55%),
    linear-gradient(180deg, rgba(20, 44, 76, .82) 0%, rgba(7, 20, 40, .9) 60%, rgba(4, 13, 28, .94) 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .16), inset 0 -3px 0 #d4af37, 0 0 0 1px rgba(0, 0, 0, .25), 0 26px 60px -24px rgba(1, 6, 16, .95), 0 0 26px rgba(214, 169, 47, .12);
  transition: transform .25s cubic-bezier(.2, .75, .25, 1), box-shadow .25s ease, border-color .25s ease;
}
.gateway-card::before {
  content: ""; position: absolute; left: 8%; right: 8%; top: 0; height: 2px; z-index: 1; pointer-events: none;
  background: var(--glow-edge); filter: drop-shadow(0 0 5px rgba(255, 217, 104, .9));
}
/* NLC static sheen strip, parked off-card on the left (glow.css .gateway-card::after) */
.gateway-card::after {
  content: ""; position: absolute; inset: 0 auto 0 -45%; width: 45%; z-index: 0; pointer-events: none;
  background: linear-gradient(104deg, transparent, rgba(255,255,255,.05) 40%, rgba(255,236,170,.18) 50%, rgba(255,255,255,.05) 60%, transparent);
}
.gateway-card:hover, .gateway-card:focus-visible {
  transform: translateY(-6px); border-color: rgba(255, 217, 104, .85); outline: none;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .22), inset 0 -3px 0 #ffd968, 0 30px 70px -24px rgba(1, 6, 16, .95), 0 0 34px rgba(214, 169, 47, .38);
}
.gateway-icon {
  width: 58px; height: 58px; display: grid; place-items: center; border: 0; border-radius: 16px;
  font: 800 1.25rem var(--font-h, Montserrat), sans-serif; color: #ffe08a;
  background: radial-gradient(circle at 50% 28%, rgba(255, 217, 104, .26), rgba(6, 18, 36, .92) 72%);
  box-shadow: 0 0 0 1px rgba(214, 169, 47, .7), 0 0 18px rgba(214, 169, 47, .38), inset 0 1px 0 rgba(255, 255, 255, .3), inset 0 0 12px rgba(0, 0, 0, .5);
  text-shadow: 0 0 10px rgba(255, 217, 104, .7), 0 1px 1px rgba(0, 0, 0, .6);
}
.gateway-copy { display: grid; gap: 3px; }
.gateway-copy strong { font: 700 1.08rem var(--font-h, Montserrat), sans-serif; color: #fff; text-shadow: 0 1px 2px rgba(0, 0, 0, .6); }
.gateway-copy small { color: #c3cede; font: 400 .76rem/1.55 Inter, system-ui, sans-serif; }
.gateway-card > b {
  font: 700 .68rem/1.55 Inter, system-ui, sans-serif; letter-spacing: .05em; text-transform: uppercase;
  background: linear-gradient(115deg, #ffd968 0%, #d6a92f 50%, #ffd968 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 0 6px rgba(214, 169, 47, .4));
}
.gateway-card > b i { font-style: normal; font-size: .9rem; }

@media (max-width: 760px) {
  .module-gateway { padding: 20px 16px 30px; }
  .gateway-content { padding-top: 60px; }
  .gateway-logo { width: 220px; }
  .gateway-card { min-width: 0; gap: 10px; }
  .gateway-copy { min-width: 0; }
  .gateway-card > b { font-size: 10px; }
  .gateway-motto { padding: 12px 18px 16px; }
  /* Rents kicker is longer than NLC's: the country suffix gets its own line, the gold rules stay on the first one. */
  .gateway-kicker { flex-wrap: wrap; justify-content: center; row-gap: 4px; }
  .gateway-kicker > .gateway-kicker-extra { order: 4; flex-basis: 100%; margin-left: 0; }
  .gateway-kicker-extra::before { content: none; }
}
@media (max-width: 700px) {
  .gateway-modules { grid-template-columns: 1fr; }
  .gateway-card { min-height: 112px; grid-template-columns: 52px 1fr auto; justify-items: start; align-content: center; text-align: left; padding: 18px; }
  .gateway-icon { width: 48px; height: 48px; }
  .gateway-card > b { justify-self: end; }
}

/* ---------- 3. "Vezi contul lui…" = NLC impersonation pill, bottom-left (glow.css:3702-3705, auth.css:20) ---------- */
.intrat-ca.impersonation-banner {
  position: fixed; left: 14px; right: auto; bottom: 14px; top: auto; transform: none; z-index: 10020;
  display: flex; align-items: center; flex-wrap: nowrap; justify-content: space-between; gap: 8px; width: auto; max-width: calc(100vw - 28px);
  padding: 5px 5px 5px 12px; border: 1px solid rgba(230, 180, 45, .78); border-radius: 999px;
  background: rgba(8, 25, 43, .96); color: #eef5ff; box-shadow: 0 12px 36px rgba(0, 0, 0, .32);
  font: 600 11.5px/1.2 Inter, Arial, sans-serif; opacity: .85; transition: opacity .2s ease;
}
.intrat-ca.impersonation-banner:hover, .intrat-ca.impersonation-banner:focus-within { opacity: 1; }
.intrat-ca.impersonation-banner > span { max-width: 190px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.intrat-ca.impersonation-banner strong { color: #ffd75a; font-weight: 900; }
.intrat-ca.impersonation-banner button {
  flex: 0 0 auto; padding: 5px 10px; min-height: 0; border: 1px solid rgba(230, 180, 45, .7); border-radius: 999px;
  background: #d7a920; color: #07182c; font: 800 11px/1.2 Inter, Arial, sans-serif; cursor: pointer;
}
.intrat-ca.impersonation-banner button:hover { background: #d7a920; }
