/* The Serene theme (Richard, Nov 16, 2026: Mock-up H). Chosen per browser under the account circle → Themes; the
   class "serene" on <html> (theme.js, frame.js and erp.js, from the gbc-theme cookie). Without it, Vivid (today's
   look) shows unchanged: every rule here starts with html.serene.
   The 50/30/15/5 split: the photo and the glass are the main colour; navy text and edges the second; the accent is
   warm: champagne gold on the open menu item and every main button (Nov 16 pm), amber dots on the Org Chart at
   night; the icons keep their own colours (the 5%).
   Day: the real photo softened and warmed (serene-day-*). Night: navy two-tone with the lamps glowing a soft blue
   (serene-night-soft-*, Nov 16 pm). The glass: warm white by day, navy at night, with a firmer 1.5 px edge.
   Loaded by the ERP's pages, the shared frame (FRAME_CSS) and PAS's pages (from the ERP's address). */

/* the photos */
html.serene body { background: #e9edf3 url(/static/art/serene-day-2026-11-17.webp) center / cover fixed no-repeat !important; }
html.dark.serene body { background: #040914 url(/static/art/serene-night-soft-2026-11-16.webp) center / cover fixed no-repeat !important; }
html.serene body::before { display: none !important; }

/* the glass: the same pieces as Vivid's glass (look.css), only its colours and edge change */
html.serene { --g-bg: rgba(255, 252, 246, .68); --g-line: rgba(255, 255, 255, .92); --g-blur: blur(18px) saturate(115%);
  --g-shadow: inset 0 1px 0 rgba(255, 255, 255, .85), 0 14px 32px -18px rgba(40, 55, 80, .4); --g-solid: rgba(255, 252, 246, .94);
  --page-glass: rgba(255, 252, 246, .55); }
html.dark.serene { --g-bg: rgba(9, 20, 44, .62); --g-line: rgba(160, 195, 255, .34); --g-blur: blur(20px) saturate(130%);
  --g-shadow: inset 0 1px 0 rgba(160, 200, 255, .1), 0 16px 36px -18px rgba(0, 0, 0, .8); --g-solid: rgba(9, 20, 44, .94);
  --page-glass: rgba(9, 20, 44, .55); }
html.serene body :is(.card:not(.pop), .table-wrap, .stat, .plist, fieldset, .hcard, .sec-light, .main .welcome, .main .adm-note,
  .main .adm-foot, .main .org-nav, .main .sec-titlerow, .main .sec-tools, .main > :is(h1, h2, h3, p), .main .adm-filter,
  .main nav.tabs, .main .tk-tabs, .main .org-tree .node, .side .status-box, .side a:not(.on):not(.status-box a), .side a.admin-btn:not(.on)) {
  border-width: 1.5px !important; }
html.serene .top { background: rgba(255, 252, 246, .55) !important; border: 1.5px solid var(--g-line) !important; }
html.dark.serene .top { background: rgba(9, 20, 44, .55) !important; }
html.serene:not(.dark) body .main { color: #1c2b44; }

/* the open menu item (Nov 16 pm, Richard, highlight 1): champagne gold with dark text; a brighter gold by day so it
   stands out from the warm white glass as it does on the navy night */
html.serene body .side a.on:not(.zz), html.serene body .side a.on:not(.zz):hover {
  background: linear-gradient(180deg, #fbe7b4, #eec463) !important; color: #2a1d05 !important; border-color: transparent !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .7), 0 8px 20px -10px rgba(0, 0, 0, .6) !important; }
html.serene:not(.dark) body .side a.on:not(.zz), html.serene:not(.dark) body .side a.on:not(.zz):hover {
  background: linear-gradient(180deg, #ffe7a3, #f9c440) !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .8), 0 0 0 1px rgba(232, 170, 40, .55), 0 8px 22px -8px rgba(240, 170, 30, .65) !important; }
html.serene body .side a.on:not(.zz) :is(span, small, b, strong) { color: #2a1d05 !important; }
/* the main buttons (Nov 16 pm, Richard): the same champagne gold as the open menu item, brighter by day, dark text */
html.serene body .side a.on .nav-badge { background: #0d1f36 !important; color: #fff !important; }   /* readable on the gold */
html.serene body .btn.primary, html.serene body .signin-card .btn.primary { background: linear-gradient(180deg, #fbe7b4, #eec463) !important; color: #2a1d05 !important; border-color: transparent !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .7), 0 8px 20px -10px rgba(0, 0, 0, .6) !important; }
html.serene:not(.dark) body .btn.primary, html.serene:not(.dark) body .signin-card .btn.primary { background: linear-gradient(180deg, #ffe7a3, #f9c440) !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .8), 0 0 0 1px rgba(232, 170, 40, .55), 0 8px 22px -8px rgba(240, 170, 30, .65) !important; }
html.serene body .btn.primary:hover { filter: brightness(1.05); }
html.serene body .btn.primary svg { color: inherit; }
html.serene body .main .welcome { border-left: 4px solid #f5a524 !important; }

/* the sign-in page (computers and tablets; phones keep their own page) */
html.serene body .sign-photo, html.serene body .sign-fill { background-image: url(/static/art/serene-signin-day-2026-11-16.webp) !important; }
html.dark.serene body .sign-photo, html.dark.serene body .sign-fill { background-image: url(/static/art/serene-signin-night-soft-2026-11-16.webp) !important; }
html.serene:not(.dark) body .signin-main::before { background: rgba(255, 252, 246, .68) !important; border: 1.5px solid rgba(255, 255, 255, .95) !important; }
html.dark.serene body .signin-main::before { background: rgba(9, 20, 44, .62) !important; border: 1.5px solid rgba(160, 195, 255, .4) !important; }

/* the account menu's Themes choice: the chosen one in the gold under Serene (erp.css draws it for Vivid) */
html.serene .theme-pick button[aria-pressed="true"] { background: linear-gradient(180deg, #fbe7b4, #eec463); border-color: #eec463; color: #2a1d05; }

/* the Org Chart's lines at night (Nov 16 pm, Richard): dimmer amber dots, the one colour the night photo doesn't have
   (pale lines vanish into the photo's own string lights); by day they stay as in Vivid */
html.dark.serene .kids::before, html.dark.serene .krow > .node::before, html.dark.serene .krow:not(:last-child)::after {
  border-left: 4px dotted rgba(230, 160, 70, .72) !important; filter: drop-shadow(0 0 2px rgba(230, 150, 50, .45)) !important; }
html.dark.serene .krow::before { border-top: 4px dotted rgba(230, 160, 70, .72) !important;
  filter: drop-shadow(0 0 2px rgba(230, 150, 50, .45)) !important; }
/* Nov 17 (Richard, Mock-up M): the Day photo is the same scene as the Night one (made from the matched pair). */
/* Nov 17 (Richard, Mock-up B): a page shown inside a window (PAS's forms) shows no photo of its own. */
html.serene.embed, html.serene.embed body { background: transparent !important; background-image: none !important; }
/* Nov 17 (Richard, Mock-up L): Serene marks every "currently on" choice with the side menu's champagne gold: tab rows,
   choices in windows, filter pills, on/off switches, ticked boxes, the phone bar's page (Vivid keeps its own). */
html.serene { --hl-a: #fbe7b4; --hl-b: #eec463; --hl-ink: #2a1d05; }
html.serene:not(.dark) { --hl-a: #ffe7a3; --hl-b: #f9c440; }
html.serene body :is(.tabs a.on, .tk-tabs a.on, .show-chips a.on, .wf-count button.on, .seg13 > span.on, .tabbar a.on,
  .chip input:checked + span, .chips input:checked + span, .theme-pick button[aria-pressed="true"]):not(.zz) {
  background: linear-gradient(180deg, var(--hl-a), var(--hl-b)) !important; color: var(--hl-ink) !important; outline-color: transparent !important;
  box-shadow: 0 2px 10px -2px rgba(238, 196, 99, .55) !important; }
html.serene body :is(.tabs a.on, .tk-tabs a.on, .show-chips a.on, .tabbar a.on) :is(span, svg, b, small, strong) { color: var(--hl-ink) !important; }
html.serene body :is(input[type=checkbox], input[type=radio]) { accent-color: var(--hl-b) !important; }
