/* Colours and moving background from the supplied gmrtc-login-theme reference. */
:root {
    color-scheme: dark;
    --bg: #060b14;
    --surface: rgb(7 17 25 / .356);
    --solid: #102538;
    --glass: rgb(7 17 25 / .5);
    --text: #f8fafc;
    --muted: #94a3b8;
    --line: rgb(255 255 255 / .09);
    --control-line: rgb(148 163 184 / .5);
    --accent: #45a29e;
    --accent-hover: #81c0bd;
    --focus: #66fcf1;
    --gold: #e8cd8a;
    --scene:
        radial-gradient(circle at top left, #07111f, transparent 45%),
        radial-gradient(circle at top right, #0b2430, transparent 45%),
        radial-gradient(circle at bottom right, #031015, transparent 48%),
        radial-gradient(circle at bottom left, #08101d, transparent 48%),
        linear-gradient(135deg, #07111f, #031015);
}
:root[data-theme="light"] {
    color-scheme: light;
    --bg: #edf3f6;
    --surface: rgb(255 255 255 / .9);
    --solid: #fff;
    --glass: rgb(255 255 255 / .5);
    --text: #0f172a;
    --muted: #475569;
    --line: rgb(15 23 42 / .14);
    --control-line: rgb(54 87 106 / .5);
    --accent: #066e65;
    --accent-hover: #00574f;
    --focus: #00796e;
    --gold: #765400;
    --scene: radial-gradient(ellipse at top right, #d6eeeb, transparent 60%), linear-gradient(135deg, #f5f8fa, #edf3f6);
}
html { background-color: var(--bg); color: var(--text); }
.gmrtc-ambient-page {
    position: relative;
    isolation: isolate;
    overflow-x: clip;
    background-color: var(--bg);
    background-image: var(--scene);
    color: var(--text);
}
.gmrtc-ambient-page > .gmrtc-ambient {
    position: fixed;
    z-index: -1;
    inset: 0;
    overflow: hidden;
    contain: strict;
    pointer-events: none;
    background: linear-gradient(180deg, rgb(15 43 57 / .16), rgb(15 43 57 / 0) 86%);
}
.gmrtc-ambient::before, .gmrtc-ambient::after {
    content: "";
    position: absolute;
    width: 130vw;
    height: 150vh;
    pointer-events: none;
    background-repeat: no-repeat;
    transform-origin: 50% 50%;
    opacity: .82;
}
.gmrtc-ambient::before {
    top: -36vh;
    left: -42vw;
    background:
        radial-gradient(ellipse 23% 25% at 62% 64%, rgb(113 75 169 / .18), rgb(113 75 169 / .08) 40%, rgb(113 75 169 / 0) 100%),
        radial-gradient(ellipse 46% 44% at 50% 50%, rgb(64 119 198 / .53), rgb(39 84 149 / .31) 34%, rgb(30 61 104 / .10) 65%, rgb(30 61 104 / 0) 100%);
    transform: translate3d(-3%, -3%, 0) scale(1);
}
.gmrtc-ambient::after {
    top: -30vh;
    left: 12vw;
    background:
        radial-gradient(ellipse 23% 24% at 36% 64%, rgb(106 77 160 / .12), rgb(106 77 160 / 0) 100%),
        radial-gradient(ellipse 46% 44% at 50% 50%, rgb(34 163 154 / .48), rgb(25 111 126 / .29) 36%, rgb(15 66 81 / .09) 66%, rgb(15 66 81 / 0) 100%);
    transform: translate3d(2%, 1%, 0) scale(1);
}
[data-theme="light"] .gmrtc-ambient { opacity: .30; }
@keyframes gmrtc-ambient-left {
    0% { transform: translate3d(-3%, -3%, 0) scale(1); opacity: .72; }
    45% { transform: translate3d(8%, 3%, 0) scale(1.06, 1.13); opacity: .89; }
    100% { transform: translate3d(19%, 19%, 0) scale(1.12, 1.06); opacity: .94; }
}
@keyframes gmrtc-ambient-right {
    0% { transform: translate3d(2%, 1%, 0) scale(1); opacity: .74; }
    55% { transform: translate3d(-7%, 16%, 0) scale(1.12, 1.04); opacity: .85; }
    100% { transform: translate3d(-22%, 17%, 0) scale(1.08, 1.12); opacity: .92; }
}

@font-face {
    font-family: "GMRTC Eras Bold";
    src: local("Eras Bold ITC"), local("ErasITC-Bold"), local("ErasITC-BoldMT"), local("Eras Bold");
    font-style: normal;
    font-weight: 400;
    font-display: swap;
}
.gmrtc-brand {
    --gmrtc-logo-cycle: 23s;
    --gmrtc-rim-from: #14171b;
    --gmrtc-rim-to: #fff;
    display: inline-flex;
    flex: 0 0 auto;
    gap: .55rem;
    align-items: center;
    color: var(--text);
    white-space: nowrap;
}
.gmrtc-brand__mark {
    display: block;
    flex: none;
    width: var(--gmrtc-mark-size, 3.625rem);
    height: var(--gmrtc-mark-size, 3.625rem);
}
.gmrtc-brand__name {
    font: 400 var(--gmrtc-wordmark-size, 1.55rem)/1 "GMRTC Eras Bold", "Eras Bold ITC", "Eras Bold", "Eras Demi ITC", Arial, sans-serif;
    font-synthesis: none;
    letter-spacing: .015em;
}
[data-theme="light"] .gmrtc-brand { --gmrtc-rim-from: #fafafa; --gmrtc-rim-to: #101216; }
.gmrtc-brand__light, [data-theme="light"] .gmrtc-brand__dark { display: none; }
[data-theme="light"] .gmrtc-brand__light { display: inline; }
.gmrtc-brand__registered { opacity: 0; }
@keyframes gmrtc-registration {
    0%, 46%, 100% { opacity: 0; }
    70%, 85% { opacity: 1; }
}
@keyframes gmrtc-colour-mark {
    0%, 46%, 100% { opacity: 1; }
    70%, 85% { opacity: 0; }
}
/* At full brightness the central facets hold for 2.07 s. The rim changes tone during this hold. */
@keyframes gmrtc-star-flash {
    0%, 50%, 72%, 100% { opacity: 0; }
    56%, 65% { opacity: 1; }
}
@keyframes gmrtc-rim-fade {
    0%, 48%, 73%, 100% { opacity: 0; }
    55%, 67% { opacity: 1; }
}
@keyframes gmrtc-rim-tone {
    0%, 56% { fill: var(--gmrtc-rim-from); }
    67%, 100% { fill: var(--gmrtc-rim-to); }
}
@media (max-width: 48rem) {
    .gmrtc-brand__mark { width: var(--gmrtc-mark-size, 2.875rem); height: var(--gmrtc-mark-size, 2.875rem); }
    .gmrtc-brand__name { font-size: var(--gmrtc-wordmark-size, 1.32rem); }
}
@media (prefers-reduced-motion: no-preference) {
    .gmrtc-ambient::before { animation: gmrtc-ambient-left 9s ease-in-out -4s infinite alternate; }
    .gmrtc-ambient::after { animation: gmrtc-ambient-right 12s ease-in-out -9s infinite alternate; }
    .gmrtc-brand__registered { animation: gmrtc-registration var(--gmrtc-logo-cycle) ease-in-out infinite; }
    .gmrtc-brand__main { animation: gmrtc-colour-mark var(--gmrtc-logo-cycle) ease-in-out infinite; }
    .gmrtc-brand__star {
        animation: gmrtc-star-flash var(--gmrtc-logo-cycle) ease-in-out infinite;
        filter: drop-shadow(0 0 12px #eebc59);
    }
    .gmrtc-brand__rim {
        animation: gmrtc-rim-fade var(--gmrtc-logo-cycle) ease-in-out infinite,
                   gmrtc-rim-tone var(--gmrtc-logo-cycle) ease-in-out infinite;
    }
    .gmrtc-motion-paused .gmrtc-brand__rim, .gmrtc-motion-paused .gmrtc-brand__star,
    .gmrtc-motion-paused .gmrtc-ambient::before,
    .gmrtc-motion-paused .gmrtc-ambient::after,
    .gmrtc-motion-paused .gmrtc-brand__registered,
    .gmrtc-motion-paused .gmrtc-brand__main { animation-play-state: paused; }
}
@media (prefers-reduced-motion: reduce), (forced-colors: active), print {
    .gmrtc-brand__main, .gmrtc-brand__rim, .gmrtc-brand__star { animation: none; opacity: 0; }
    .gmrtc-brand__registered { animation: none; opacity: 1; }
}
@media (forced-colors: active), print { .gmrtc-ambient { display: none; } }
@media (forced-colors: active) and (prefers-color-scheme: light), print {
    :root .gmrtc-brand__light { display: inline; }
    :root .gmrtc-brand__dark { display: none; }
}
@media (forced-colors: active) and (prefers-color-scheme: dark) {
    :root .gmrtc-brand__light { display: none; }
    :root .gmrtc-brand__dark { display: inline; }
}

html[data-motion="reduced"] :is(.gmrtc-brand__star, .gmrtc-brand__rim) { animation: none; opacity: 0; }
html[data-motion="reduced"] :is(.gmrtc-brand__registered,.gmrtc-brand__main),
html[data-motion="reduced"] .gmrtc-ambient::before, html[data-motion="reduced"] .gmrtc-ambient::after { animation: none; }
html[data-motion="reduced"] .gmrtc-brand__registered { opacity: 1; }
html[data-motion="reduced"] .gmrtc-brand__main { opacity: 0; }

/* Small and touch screens keep the ambient colours in a still, viewport-sized layer. */
@media screen and (max-width: 64rem), screen and (hover: none) and (pointer: coarse) {
    body.gmrtc-ambient-page > .gmrtc-ambient::before,
    body.gmrtc-ambient-page > .gmrtc-ambient::after {
        inset: 0;
        width: 100%;
        height: 100%;
        animation: none;
        transform: none;
        opacity: .6;
    }
    .gmrtc-brand__star { filter: none; }
}

.gmrtc-back-top {
    position: fixed; z-index: 93; inset-inline-end: max(1rem, env(safe-area-inset-right)); inset-block-end: max(1rem, env(safe-area-inset-bottom));
    display: grid; place-items: center; inline-size: 2.85rem; block-size: 2.85rem; padding: .64rem;
    border: 1px solid var(--control-line); border-radius: 50%; color: var(--text); background: var(--solid);
    box-shadow: 0 .25rem 1.15rem rgb(0 0 0 / .23); cursor: pointer;
}
.gmrtc-back-top svg { width: 100%; height: 100%; }
.gmrtc-back-top:is(:hover,:focus-visible) { color: var(--accent-hover); border-color: currentColor; }
.gmrtc-back-top[hidden] { display: none; }
@media print { .gmrtc-back-top { display: none; } }

details.gmrtc-has-fold-tools { position: relative; }
.gmrtc-ambient-page main details.gmrtc-has-fold-tools[open] > summary { padding-inline-end: 7.6rem; }
.gmrtc-fold-tools { display: inline-flex; align-items: center; gap: .3rem; vertical-align: middle; }
.gmrtc-fold-heading { position: absolute; inset-block-start: .48rem; inset-inline-end: 2.5rem; z-index: 1; }
.gmrtc-ambient-page main .gmrtc-disclosure-control {
    box-sizing: border-box; display: inline-grid; place-items: center; inline-size: 2rem; block-size: 2rem;
    min-inline-size: 0; min-block-size: 0; padding: .4rem; margin: 0;
    border: 1px solid var(--control-line); border-radius: .45rem;
    background: color-mix(in srgb,var(--solid) 65%,transparent); color: var(--text); cursor: pointer;
}
.gmrtc-disclosure-control > svg { display: block; inline-size: 100%; block-size: 100%; }
.gmrtc-ambient-page main .gmrtc-disclosure-control:is(:hover,:focus-visible) { color: var(--accent-hover); border-color: currentColor; }
@media print { .gmrtc-fold-tools, .gmrtc-disclosure-control { display: none !important; } }

.gmrtc-ambient-page main details.gmrtc-has-fold-tools:not([open]) > summary {
    position: relative;
    padding-inline-end: 5.3rem;
}
.gmrtc-fold-when-closed {
    position: absolute; inset-inline-end: 2.5rem; inset-block-start: 50%;
    transform: translateY(-50%);
}
.gmrtc-ambient-page main details[open] > summary .gmrtc-fold-when-closed { display: none; }
.work-cabinet .work-panel .gmrtc-fold-when-closed { inset-inline-end: .68rem; }
