:root {
  --unav-bg: #0d0d0bef;
  --unav-panel: #171611;
  --unav-line: #342f24;
  --unav-text: #f4efe5;
  --unav-muted: #9e988b;
  --unav-gold: #ddb961;
}
.radyan-universal-shell {
  position: sticky; top: 0; z-index: 9999; display: flex; align-items: center;
  gap: 8px; min-height: 58px; padding: 8px clamp(12px, 2.4vw, 32px);
  border-bottom: 1px solid var(--unav-line); background: var(--unav-bg);
  backdrop-filter: blur(20px); color: var(--unav-text);
  font: 13px/1.2 Inter, ui-sans-serif, system-ui, sans-serif;
}
.unav-brand { display: flex; align-items: center; gap: 9px; margin-right: 8px; color: var(--unav-text); text-decoration: none; }
.unav-brand img { width: 34px; height: 34px; border: 1px solid #5d4a29; border-radius: 10px; object-fit: cover; }
.unav-brand span, .unav-user b, .unav-user small { display: block; }
.unav-brand small { color: var(--unav-gold); font-size: 8px; letter-spacing: .14em; }
.unav-links { display: flex; align-items: center; gap: 3px; min-width: 0; }
.unav-link, .unav-more > summary, .unav-account > summary {
  display: flex; align-items: center; gap: 7px; min-height: 38px; padding: 9px 11px;
  border-radius: 10px; color: var(--unav-muted); text-decoration: none;
  white-space: nowrap; cursor: pointer; list-style: none;
}
.unav-link:hover, .unav-link[aria-current="page"], .unav-more[open] > summary, .unav-account[open] > summary { background: #d8b55f17; color: #f3d997; }
.unav-link[aria-current="page"] { box-shadow: inset 0 -2px var(--unav-gold); }
.unav-link span { font-size: 15px; }
.unav-more, .unav-account { position: relative; }
.unav-more > summary::-webkit-details-marker, .unav-account > summary::-webkit-details-marker { display: none; }
.unav-more > summary::after, .unav-account > summary::after { content: "⌄"; color: #777166; }
.unav-popover {
  position: absolute; top: calc(100% + 9px); right: 0; width: min(330px, calc(100vw - 24px));
  padding: 10px; border: 1px solid #51452e; border-radius: 16px; background: #11110f;
  box-shadow: 0 24px 70px #0009;
}
.unav-more .unav-popover { left: 0; right: auto; }
.unav-search { width: 100%; margin: 0 0 8px; padding: 10px 11px; border: 1px solid var(--unav-line); border-radius: 10px; background: #090907; color: var(--unav-text); font: inherit; }
.unav-results { display: grid; gap: 3px; max-height: min(60vh, 520px); overflow: auto; }
.unav-result { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 11px; border-radius: 10px; color: var(--unav-text); text-decoration: none; }
.unav-result:hover, .unav-action:hover { background: #d8b55f12; }
.unav-result small, .unav-user small { color: var(--unav-muted); }
.unav-account { margin-left: auto; }
.unav-account > summary { color: var(--unav-text); }
.unav-account .unav-popover { width: 250px; }
.unav-user { padding: 9px 10px 12px; border-bottom: 1px solid var(--unav-line); margin-bottom: 7px; }
.unav-user small { margin-top: 4px; }
.unav-action { display: block; width: 100%; padding: 10px; border: 0; border-radius: 9px; background: transparent; color: var(--unav-text); text-align: left; text-decoration: none; cursor: pointer; }
.unav-public-simplified { display: flex !important; align-items: center; gap: 4px !important; }
.unav-public-simplified > a, .unav-public-simplified > details > summary { padding: 9px 11px !important; border-radius: 9px !important; color: #999489 !important; text-decoration: none !important; white-space: nowrap; }
.unav-public-simplified details { position: relative; }
.unav-public-simplified summary { list-style: none; cursor: pointer; }
.unav-public-simplified summary::-webkit-details-marker { display: none; }
.unav-public-simplified .unav-popover { top: calc(100% + 7px); }
.unav-session-warning { position: fixed; right: 14px; bottom: 14px; z-index: 10001; display: flex; align-items: center; gap: 10px; max-width: min(420px, calc(100vw - 28px)); padding: 11px 12px; border: 1px solid #6a552b; border-radius: 12px; background: #16130df2; box-shadow: 0 20px 55px #0008; color: var(--unav-text); font: 12px/1.4 Inter, system-ui, sans-serif; }
.unav-session-warning button { border: 1px solid #80662f; border-radius: 999px; padding: 7px 10px; background: #d4af3720; color: #f2d991; cursor: pointer; }
body.has-universal-navigation > header:not(.radyan-universal-shell) nav { display: none !important; }
body.has-universal-navigation > header:not(.radyan-universal-shell) { top: 58px !important; }
.radyan-universal-shell + .hub-head, .radyan-universal-shell + .admin-head { top: 58px !important; }
.radyan-universal-shell ~ main { scroll-margin-top: 70px; }

@media (max-width: 820px) {
  body.has-universal-navigation { padding-bottom: 70px; }
  .radyan-universal-shell { position: fixed; top: auto; bottom: 0; left: 0; right: 0; min-height: 64px; padding: 6px 6px max(6px, env(safe-area-inset-bottom)); border-top: 1px solid var(--unav-line); border-bottom: 0; justify-content: center; }
  .unav-brand { display: none; }
  .unav-links { flex: 1; width: auto; justify-content: space-around; }
  .unav-link, .unav-more > summary, .unav-account > summary { display: grid; justify-items: center; gap: 2px; min-width: 48px; padding: 7px 4px; font-size: 9px; }
  .unav-link span { font-size: 17px; }
  .unav-more > summary::before { content: "•••"; font-size: 13px; letter-spacing: 2px; }
  .unav-more > summary::after, .unav-account > summary::after { display: none; }
  .unav-more .unav-popover, .unav-account .unav-popover { position: fixed; left: 10px; right: 10px; top: auto; bottom: 72px; width: auto; max-height: 68vh; }
  .unav-account { display: block; margin-left: 0; }
  .radyan-universal-shell + .hub-head, .radyan-universal-shell + .admin-head, body.has-universal-navigation > header:not(.radyan-universal-shell) { top: 0 !important; }
  .unav-public-simplified > a:nth-of-type(n+4) { display: none !important; }
  .unav-session-warning { bottom: 78px; }
}

@media (max-width: 520px) {
  .unav-links .unav-link:nth-of-type(n+3) { display: none; }
  .unav-account-label { font-size: 9px; }
}
