/* NoversX Photos LIVE DESIGN 2 — overlay the accepted DESIGN1 web image.
   No viewer implementation, media endpoints or backend configuration changes. */
:root{--nx-shell-header:74px;--nx-shell-rail:244px}
body.nx-design2{overflow-x:hidden}
body.nx-design2 .app-shell{
  width:auto;max-width:none;margin:0 0 0 var(--nx-shell-rail);
  padding:calc(var(--nx-shell-header) + 12px) 28px 38px;
  transition:margin-left .18s ease;
}
/* ONE full-width sticky/fixed header; reuse the genuine React brand, login and toggles. */
body.nx-design2 .topbar{
  position:fixed;top:0;left:0;right:0;z-index:420;
  box-sizing:border-box;width:100%;height:var(--nx-shell-header);
  display:flex;align-items:center;gap:14px;
  padding:0 22px;margin:0;
  background:var(--nx-bg-primary);
  border-bottom:1px solid var(--nx-border);
  -webkit-backdrop-filter:blur(16px);backdrop-filter:blur(16px);
}
body.nx-design2 .topbar .brand{flex:none;min-width:0;gap:10px}
body.nx-design2 .topbar .brand-mark{width:39px;height:39px;flex:none}
body.nx-design2 .topbar .brand-copy strong{font-size:15px;white-space:nowrap}
body.nx-design2 .topbar .brand-copy span{display:none!important}
body.nx-design2 .topbar .controls{flex:none;display:flex;align-items:center;gap:7px}
body.nx-design2 .topbar .controls .control{min-width:43px;height:40px;padding:0 12px;white-space:nowrap}
.nx2-menu{
  flex:none;width:43px;height:43px;display:grid;place-items:center;
  padding:0;cursor:pointer;border:1px solid var(--nx-border);
  border-radius:12px;background:var(--nx-surface);color:var(--nx-text-primary);
}
.nx2-menu svg{width:22px;height:22px}
.nx2-menu:hover,.nx2-menu:focus-visible{border-color:var(--nx-accent);outline-offset:2px}
.nx2-header-search{
  flex:1 1 400px;display:flex;align-items:center;gap:10px;
  min-width:120px;max-width:760px;margin:0 0 0 auto;
  height:42px;padding:0 14px;
  border:1px solid var(--nx-border);border-radius:23px;
  background:var(--nx-bg-secondary);color:var(--nx-text-secondary);
}
.nx2-header-search:focus-within{border-color:var(--nx-accent);box-shadow:0 0 0 2px var(--nx-accent-soft)}
.nx2-header-search svg{width:19px;height:19px;flex:none}
.nx2-header-search input{
  width:100%;min-width:0;background:transparent;border:0;outline:0;
  color:var(--nx-text-primary);font:inherit;font-size:13px;
}
.nx2-header-search input::placeholder{color:var(--nx-text-secondary);opacity:.9}
.nx2-upload{
  flex:none;display:flex;align-items:center;justify-content:center;gap:7px;
  min-height:42px;padding:0 17px;border:0;border-radius:12px;
  color:#fff;background:var(--nx-accent);font-weight:750;cursor:pointer;
}
.nx2-upload svg{width:19px;height:19px}
.nx2-upload:hover{filter:brightness(1.07)}
.nx2-upload[hidden]{display:none!important}
/* Sidebar is BELOW header; the hamburger in header is its only control. */
body.nx-design2 .nx-shell-sidebar{
  top:var(--nx-shell-header);bottom:0;left:0;right:auto;height:calc(100dvh - var(--nx-shell-header));
  width:var(--nx-shell-rail);padding:0;
  z-index:380;background:var(--nx-bg-secondary);border-right:1px solid var(--nx-border);
  box-shadow:none;
}
body.nx-design2 .nx-shell-section{padding:21px 10px 8px}
body.nx-design2 .nx-shell-bottom{margin-top:auto;padding:10px;border-top:1px solid var(--nx-border)}
body.nx-design2 .nx-shell-bottom .nx-shell-item{width:100%}
body.nx-design2 .nx-shell-item{font-size:13px;font-weight:650}
body.nx-design2 .nx-shell-item svg{width:19px;height:19px;flex:none}
body.nx-design2 .nx-shell-brand,body.nx-design2 .nx-shell-collapse,
body.nx-design2 .nx-shell-mobile-toggle{display:none!important}
body.nx-design2.nx-shell-collapsed{--nx-shell-rail:72px}
body.nx-design2.nx-shell-collapsed .nx-shell-sidebar{width:72px}
body.nx-design2.nx-shell-collapsed .nx-shell-item{justify-content:center;padding:0}
body.nx-design2.nx-shell-collapsed .nx-shell-item span,
body.nx-design2.nx-shell-collapsed .nx-shell-section-title{display:none}
/* Photo-first content: remove Foundation from public gallery, reduce excessive heading. */
body.nx-design2 .foundation-card{display:none!important}
body.nx-design2 .library-panel{padding:8px 0 36px;margin:0;background:transparent}
body.nx-design2 .library-heading{gap:10px;min-height:0;align-items:center}
body.nx-design2 .library-heading h1{font-size:0!important;line-height:1.2;margin:0}
body.nx-design2 .library-heading h1::after{
  content:attr(data-nx-view-title);font-size:25px;font-weight:790;letter-spacing:-.035em;
}
body.nx-design2 .library-heading p,body.nx-design2 .library-kicker{display:none}
body.nx-design2 .library-heading .library-upload-button{display:none}
body.nx-design2 .library-toolbar{margin:7px 0 10px}
body.nx-design2 .library-current{display:none}
body.nx-design2[data-nx-view="search"] .library-heading,
body.nx-design2[data-nx-view="favorites"] .library-heading,
body.nx-design2[data-nx-view="albums"] .library-heading{position:absolute!important;width:1px!important;height:1px!important;overflow:hidden!important;clip-path:inset(50%)!important;pointer-events:none}
body.nx-design2 .nx-live-panel__heading{margin-bottom:12px}
body.nx-design2 .nx-live-panel__heading h2{font-size:24px}
body.nx-design2 .library-grid,body.nx-design2 .nx-live-panel__grid{gap:9px;grid-template-columns:repeat(auto-fill,minmax(172px,1fr))}
body.nx-design2 .library-asset{position:relative;min-width:0;border-radius:13px;overflow:hidden;isolation:isolate}
body.nx-design2 .library-asset__open{display:block;width:100%;min-width:0}
body.nx-design2 .library-asset__media{aspect-ratio:1;overflow:hidden}
body.nx-design2 .library-asset:not(.nx-live-panel__asset) .library-asset__caption{
  position:absolute;inset:auto 0 0 0;z-index:4;
  padding:17px 10px 8px;pointer-events:none;
  background:linear-gradient(0deg,#0d111be6 0%,transparent 100%);
  opacity:0;transition:opacity .16s ease;
}
body.nx-design2 .library-asset:not(.nx-live-panel__asset) .library-asset__caption strong{
  color:#fff!important;text-shadow:0 1px 3px #000a;font-size:12px;
}
body.nx-design2 .library-asset:not(.nx-live-panel__asset):hover .library-asset__caption,
body.nx-design2 .library-asset:not(.nx-live-panel__asset):focus-within .library-asset__caption{opacity:1}
body.nx-design2 .nx-live-panel__heart{top:9px;right:9px}
/* Standalone Settings surface, backed by EXISTING theme/language controls and DOM status. */
body.nx-design2.nx-settings-active .library-panel{display:none!important}
.nx-settings-page[hidden]{display:none!important}
.nx-settings-page{
  position:fixed;top:var(--nx-shell-header);bottom:0;left:var(--nx-shell-rail);right:0;
  z-index:160;overflow:auto;background:var(--nx-bg-primary);color:var(--nx-text-primary);
  padding:24px clamp(18px,4vw,56px) 60px;
}
.nx-settings-wrap{max-width:920px;margin:0 auto}
.nx-settings-wrap h1{font-size:27px;margin:0 0 25px}
.nx-settings-card{background:var(--nx-surface);border:1px solid var(--nx-border);border-radius:17px;padding:23px;margin-bottom:18px}
.nx-settings-card h2{font-size:18px;margin:0 0 16px}
.nx-settings-card p{color:var(--nx-text-secondary);font-size:13px}
.nx-settings-row{display:flex;justify-content:space-between;align-items:center;gap:16px;min-height:56px;border-top:1px solid var(--nx-border)}
.nx-settings-row button{padding:9px 15px;border:1px solid var(--nx-border);border-radius:10px;background:var(--nx-bg-secondary);color:var(--nx-text-primary);cursor:pointer}
.nx-settings-status{display:grid;grid-template-columns:repeat(auto-fill,minmax(175px,1fr));gap:10px}
.nx-settings-status-card{padding:14px;min-height:55px;border-radius:12px;background:var(--nx-bg-secondary);border:1px solid var(--nx-border);font-size:13px;overflow-wrap:anywhere}
/* The original accepted viewer keeps the top-most layer, unchanged. */
body.nx-design2 .nx-viewer{z-index:20000!important}
@media(max-width:1100px){
  body.nx-design2 .topbar{gap:9px;padding:0 12px}
  body.nx-design2 .topbar .controls{gap:5px}
  body.nx-design2 .nx2-upload{padding:0 10px}
}
@media(max-width:860px){
  body.nx-design2,body.nx-design2.nx-shell-collapsed{--nx-shell-rail:0px}
  body.nx-design2 .app-shell{margin:0;padding:calc(var(--nx-shell-header) + 12px) 16px 40px}
  body.nx-design2 .topbar{padding:0 12px!important;height:var(--nx-shell-header)}
  body.nx-design2 .nx-shell-sidebar{width:260px;transform:translateX(-105%);z-index:380}
  body.nx-design2.nx-shell-mobile-open .nx-shell-sidebar{transform:none}
  body.nx-design2 .nx-shell-mobile-shade{display:none;position:fixed;inset:var(--nx-shell-header) 0 0;background:#060915aa;z-index:370}
  body.nx-design2.nx-shell-mobile-open .nx-shell-mobile-shade{display:block}
  body.nx-design2 .nx-settings-page{left:0}
  body.nx-design2.nx-shell-collapsed .nx-shell-sidebar{width:260px}
  body.nx-design2.nx-shell-collapsed .nx-shell-item{justify-content:flex-start;padding:0 12px}
  body.nx-design2.nx-shell-collapsed .nx-shell-item span,
  body.nx-design2.nx-shell-collapsed .nx-shell-section-title{display:initial}
}
@media(max-width:660px){
  :root{--nx-shell-header:66px}
  body.nx-design2 .topbar .brand-copy{display:none}
  body.nx-design2 .topbar .brand-mark{width:35px;height:35px}
  body.nx-design2 .topbar .controls .control{height:37px;min-width:36px;padding:0 7px;font-size:11px}
  body.nx-design2 .nx2-upload{width:40px;height:39px;min-height:39px;padding:0}
  body.nx-design2 .nx2-upload span{display:none}
  body.nx-design2 .nx2-header-search{min-width:54px;height:39px;padding:0 9px;gap:4px}
  body.nx-design2 .nx2-header-search input{font-size:11px}
  body.nx-design2 .library-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media(hover:none){body.nx-design2 .library-asset:not(.nx-live-panel__asset) .library-asset__caption{opacity:1}}
@media(prefers-reduced-motion:reduce){body.nx-design2 .app-shell,body.nx-design2 .nx-shell-sidebar{transition:none}}
