.rtv-client-area-page {
    background: #070707;
}

.rtv-client-area-page .basic-page {
    min-height: 100svh;
    padding: 0;
}

.rtv-client-area-page .basic-page > article > h1,
.rtv-client-area-page .site-footer {
    display: none;
}

.rtv-client-area-page .consent-banner {
    display: none !important;
}

.rtv-client-area-page .basic-page > article,
.rtv-client-area-page .basic-page > article > .entry-content {
    margin: 0;
    padding: 0;
}

.rtv-portal {
    --portal-black: #070707;
    --portal-ink: #111;
    --portal-paper: #f2f1ec;
    --portal-red: #ff3b2f;
    --portal-muted: rgba(242, 241, 236, 0.58);
    --portal-line: rgba(242, 241, 236, 0.16);
    min-height: 100svh;
    background:
        linear-gradient(rgba(7, 7, 7, 0.72), rgba(7, 7, 7, 0.92)),
        #101010;
    color: var(--portal-paper);
    font-family: var(--ui, Arial, Helvetica, sans-serif);
    font-style: oblique 10deg;
    letter-spacing: 0;
}

.rtv-portal *,
.rtv-portal *::before,
.rtv-portal *::after {
    box-sizing: border-box;
}

.rtv-portal h1,
.rtv-portal h2,
.rtv-portal p {
    margin-top: 0;
}

.rtv-kicker {
    margin-bottom: 12px;
    color: var(--portal-muted);
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
}

.rtv-portal-login {
    display: grid;
    min-height: 100svh;
    place-items: center;
    padding: 32px 20px;
}

.rtv-login-panel {
    width: min(100%, 520px);
    padding: clamp(30px, 5vw, 56px);
    border-top: 2px solid var(--portal-red);
    background: rgba(16, 16, 16, 0.96);
    box-shadow: 0 32px 90px rgba(0, 0, 0, 0.46);
}

.rtv-login-panel h1,
.rtv-dashboard h1,
.rtv-project-bar h1 {
    margin-bottom: 18px;
    font-size: clamp(44px, 7vw, 92px);
    font-weight: 740;
    font-style: oblique 10deg;
    line-height: 0.88;
    text-transform: uppercase;
    transform: skewX(-8deg);
    transform-origin: left;
}

.rtv-login-panel > p:not(.rtv-kicker) {
    max-width: 390px;
    color: var(--portal-muted);
    line-height: 1.55;
}

.rtv-login-panel form {
    margin-top: 34px;
}

.rtv-login-panel .rtv-form-message {
    margin: 24px 0 -10px;
}

.rtv-login-panel form p {
    margin-bottom: 17px;
}

.rtv-login-panel label {
    display: block;
    margin-bottom: 7px;
    color: var(--portal-muted);
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
}

.rtv-login-panel input[type='text'],
.rtv-login-panel input[type='password'] {
    width: 100%;
    height: 48px;
    padding: 0 13px;
    border: 1px solid var(--portal-line);
    border-radius: 0;
    outline: 0;
    background: #080808;
    color: var(--portal-paper);
    font: inherit;
}

.rtv-login-panel input:focus {
    border-color: var(--portal-paper);
}

.rtv-login-panel .login-remember label {
    display: flex;
    align-items: center;
    gap: 9px;
}

.rtv-login-panel input[type='submit'] {
    width: 100%;
    min-height: 50px;
    border: 0;
    border-radius: 0;
    background: var(--portal-red);
    color: white;
    cursor: pointer;
    font: inherit;
    font-size: 12px;
    font-weight: 900;
    text-transform: uppercase;
    transition: filter 180ms ease, transform 180ms ease;
}

.rtv-login-panel input[type='submit']:enabled:is(:hover, :focus-visible) {
    filter: brightness(1.12);
    transform: translateY(-1px);
}

.rtv-dashboard,
.rtv-project-view {
    padding: clamp(24px, 4vw, 64px);
}

.rtv-dashboard-header,
.rtv-project-bar {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 30px;
    max-width: 1600px;
    margin: 0 auto clamp(38px, 6vw, 92px);
}

.rtv-dashboard-header h1,
.rtv-project-bar h1 {
    margin-bottom: 0;
    font-size: clamp(48px, 7.4vw, 118px);
}

.rtv-user-menu {
    display: flex;
    align-items: center;
    gap: 18px;
    padding-top: 8px;
    color: var(--portal-muted);
    font-size: 12px;
    font-weight: 750;
    text-transform: uppercase;
}

.rtv-user-menu a,
.rtv-logout,
.rtv-back {
    transition: color 180ms ease;
    text-underline-offset: 4px;
}

.rtv-user-menu a:is(:hover, :focus-visible),
.rtv-logout:is(:hover, :focus-visible),
.rtv-back:is(:hover, :focus-visible) {
    color: var(--portal-red);
    text-decoration: underline;
}

.rtv-project-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1px;
    max-width: 1600px;
    margin: 0 auto;
    background: transparent;
}

.rtv-dashboard-projects,
.rtv-archived-projects {
    width: min(100%, 1600px);
    margin-inline: auto;
}

.rtv-dashboard-section-heading {
    margin-bottom: 18px;
}

.rtv-dashboard-section-heading h2 {
    margin: 3px 0 0;
    font-size: clamp(25px, 3.2vw, 48px);
    font-weight: 780;
    line-height: 0.95;
    text-transform: uppercase;
}

.rtv-archived-projects {
    margin-top: clamp(40px, 6vw, 78px);
    border-top: 1px solid var(--portal-line);
    border-bottom: 1px solid var(--portal-line);
}

.rtv-archived-projects > summary {
    display: flex;
    min-height: 104px;
    align-items: center;
    justify-content: space-between;
    gap: 22px;
    padding: 20px 14px;
    color: var(--portal-paper);
    cursor: pointer;
    list-style: none;
    transition: background 180ms ease, box-shadow 180ms ease;
}

.rtv-archived-projects > summary:is(:hover, :focus-visible) {
    background: #151515;
    box-shadow: inset 3px 0 0 var(--portal-red);
}

.rtv-archived-projects > summary:is(:hover, :focus-visible) strong {
    text-decoration: underline;
    text-decoration-color: var(--portal-red);
    text-decoration-thickness: 2px;
    text-underline-offset: 5px;
}

.rtv-archived-projects > summary:is(:hover, :focus-visible) > span:last-child {
    color: var(--portal-paper);
}

.rtv-archived-projects > summary::-webkit-details-marker {
    display: none;
}

.rtv-archived-projects > summary > span:first-child {
    display: grid;
    gap: 3px;
}

.rtv-archived-projects > summary small,
.rtv-archived-projects > summary > span:last-child {
    color: var(--portal-muted);
    font-size: 9px;
    font-weight: 850;
    text-transform: uppercase;
}

.rtv-archived-projects > summary strong {
    font-size: clamp(24px, 3vw, 44px);
    line-height: 0.95;
}

.rtv-archived-projects > summary > span:last-child {
    display: flex;
    align-items: center;
    gap: 14px;
    padding-right: 8px;
}

.rtv-archived-projects > summary > span:last-child::after {
    width: 8px;
    height: 8px;
    flex: 0 0 auto;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    content: '';
    transform: translateY(-2px) rotate(45deg);
}

.rtv-archived-projects[open] > summary > span:last-child::after {
    transform: translateY(2px) rotate(225deg);
}

.rtv-archived-projects[open] {
    padding-bottom: 1px;
}

.rtv-project-card {
    display: flex;
    min-height: 310px;
    flex-direction: column;
    padding: clamp(24px, 3vw, 44px);
    border: 1px solid var(--portal-line);
    background: #0b0b0b;
    transition: background 260ms ease, border-color 180ms ease, transform 260ms cubic-bezier(0.22, 1, 0.36, 1);
}

.rtv-project-card:is(:hover, :focus-visible) {
    z-index: 1;
    border-color: rgba(255, 59, 47, 0.72);
    background: #151515;
    transform: scale(1.012);
}

.rtv-project-card.is-archived {
    background: #090909;
    color: rgba(242, 241, 236, 0.78);
}

.rtv-project-card.is-archived:is(:hover, :focus-visible) {
    background: #121212;
}

.rtv-project-card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 9px;
    color: var(--portal-muted);
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
}

.rtv-project-status,
.rtv-project-card-top time,
.rtv-project-updated {
    display: flex;
    align-items: center;
    gap: 9px;
}

.rtv-project-card-top time {
    color: rgba(242, 241, 236, 0.46);
    font-size: 9px;
    white-space: nowrap;
}

.rtv-status-dot {
    width: 8px;
    height: 8px;
    background: var(--portal-red);
    border-radius: 50%;
    box-shadow: 0 0 13px rgba(255, 59, 47, 0.88);
}

.rtv-status-dot.is-archived {
    background: #c4c6c8;
    box-shadow: 0 0 12px rgba(222, 225, 228, 0.36);
}

.rtv-project-card h2 {
    margin: auto 0 12px;
    font-size: clamp(28px, 3vw, 48px);
    font-weight: 720;
    line-height: 0.96;
    text-transform: uppercase;
}

.rtv-project-card > p {
    color: var(--portal-muted);
}

.rtv-project-card-footer {
    display: flex;
    justify-content: space-between;
    padding-top: 18px;
    border-top: 1px solid var(--portal-line);
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
}

.rtv-project-bar {
    align-items: flex-end;
    margin-bottom: clamp(22px, 3vw, 44px);
}

.rtv-external-tour {
    max-width: 1600px;
    margin: 0 auto clamp(34px, 5vw, 72px);
    border: 1px solid var(--portal-line);
    background: #050505;
    box-shadow: 0 30px 90px rgba(0, 0, 0, 0.42);
}

.rtv-external-tour-bar {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
    padding: clamp(20px, 3vw, 38px);
    border-bottom: 1px solid var(--portal-line);
}

.rtv-external-tour-bar .rtv-kicker {
    margin-bottom: 8px;
}

.rtv-external-tour-bar h2 {
    margin: 0;
    font-size: clamp(26px, 4vw, 58px);
    font-weight: 760;
    line-height: 0.95;
    text-transform: uppercase;
}

.rtv-external-tour-bar > span {
    flex: 0 0 auto;
    color: var(--portal-muted);
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
}

.rtv-external-tour-frame {
    position: relative;
    width: 100%;
    min-height: 520px;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: #000;
}

.rtv-external-tour-frame iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
    background: #000;
}

.rtv-camera-world-section {
    width: min(100%, 1600px);
    margin: 1px auto 0;
    border-top: 1px solid var(--portal-line);
    border-bottom: 1px solid var(--portal-line);
    background: #050607;
}

.rtv-camera-world-frame {
    position: relative;
    width: 100%;
    min-height: 680px;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: #050607;
}

.rtv-camera-world-frame iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
    background: #050607;
}

.rtv-interaction-shell > iframe,
.rtv-interaction-shell .rtv-panorama-viewer,
.rtv-interaction-shell .rtv-scene-nav {
    pointer-events: none;
}

.rtv-interaction-shell.is-interactive > iframe,
.rtv-interaction-shell.is-interactive .rtv-panorama-viewer,
.rtv-interaction-shell.is-interactive .rtv-scene-nav {
    pointer-events: auto;
}

.rtv-interaction-shell.is-interactive {
    z-index: 40;
}

.rtv-interaction-gate {
    position: absolute;
    z-index: 12;
    inset: 0;
    display: grid;
    align-content: center;
    justify-items: center;
    gap: 18px;
    padding: 24px;
    background: rgba(5, 5, 5, 0.46);
    backdrop-filter: blur(2px);
    text-align: center;
    overscroll-behavior: auto;
    touch-action: pan-y;
    transition: opacity 220ms ease, visibility 220ms ease;
}

.rtv-interaction-gate p,
.rtv-interaction-gate strong,
.rtv-interaction-gate span {
    display: block;
    margin: 0;
}

.rtv-interaction-gate p > span {
    margin-bottom: 8px;
    color: rgba(242, 241, 236, 0.64);
    font-size: 9px;
    font-weight: 850;
    text-transform: uppercase;
}

.rtv-interaction-gate strong {
    color: var(--portal-paper);
    font-size: clamp(24px, 3vw, 48px);
    font-weight: 780;
    line-height: 0.96;
    text-transform: uppercase;
}

.rtv-external-tour-frame .rtv-external-consent-copy {
    max-width: 560px;
    color: var(--portal-paper);
    font-size: 13px;
    font-weight: 450;
    line-height: 1.5;
    text-transform: none;
}

.rtv-external-consent-copy a {
    color: inherit;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.rtv-interaction-gate button,
.rtv-interaction-exit {
    min-height: 44px;
    padding: 0 16px;
    border: 1px solid rgba(242, 241, 236, 0.42);
    border-radius: 0;
    background: rgba(5, 5, 5, 0.9);
    color: var(--portal-paper);
    cursor: pointer;
    font: inherit;
    font-size: 9px;
    font-weight: 880;
    text-transform: uppercase;
}

.rtv-interaction-gate button:not(:disabled, [aria-disabled='true'], .is-disabled):is(:hover, :focus-visible),
.rtv-interaction-exit:not(:disabled, [aria-disabled='true'], .is-disabled):is(:hover, :focus-visible) {
    border-color: var(--portal-paper);
    background: #1b1b1b;
}

.rtv-interaction-gate button span,
.rtv-interaction-exit span {
    display: inline-block;
    margin-left: 9px;
    color: var(--portal-red);
}

.rtv-interaction-exit {
    position: absolute;
    z-index: 14;
    top: 16px;
    right: 16px;
}

.rtv-interaction-exit[hidden] {
    display: none;
}

@media (min-width: 721px) {
    .rtv-camera-world-frame .rtv-interaction-exit {
        top: 24px;
        right: calc(clamp(22px, 3.4vw, 64px) + 130px);
    }
}

/* Keep the parent Exit control outside Channel Aid's embedded view controls.
   Its own toolbar is independent of iframe width and the number of views. */
.rtv-camera-world-frame[data-world-slug="channel-aid"] {
    scroll-margin-top: 16px;
}

.rtv-camera-world-frame.is-interactive > iframe {
    top: 60px;
    height: calc(100% - 60px);
    scroll-margin-top: 60px;
}

.rtv-camera-world-frame > .rtv-interaction-exit {
    top: 8px;
    right: 16px;
}


.rtv-interaction-shell.is-interactive .rtv-interaction-gate {
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
}

.rtv-location-world-bar {
    width: min(100%, 1600px);
    margin: clamp(34px, 5vw, 72px) auto 0;
    border: 1px solid var(--portal-line);
    background: #0b0b0b;
}

.rtv-location-world-section {
    width: min(100%, 1600px);
    margin: 0 auto;
}

.rtv-location-world-section .rtv-location-world-bar,
.rtv-location-world-section .rtv-viewer-shell,
.rtv-location-world-section .rtv-viewer-review-bar,
.rtv-location-world-section .rtv-marker-editor {
    width: 100%;
}

.rtv-project-bar > div {
    min-width: 0;
}

.rtv-project-bar h1 {
    max-width: 1200px;
    margin: 8px 0 10px;
    overflow-wrap: anywhere;
}

.rtv-back,
.rtv-logout {
    color: var(--portal-muted);
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
}

.rtv-project-meta {
    margin: 0;
    color: var(--portal-muted);
    font-size: 12px;
    font-weight: 750;
    text-transform: uppercase;
}

.rtv-project-updated {
    margin: 12px 0 0;
    color: rgba(242, 241, 236, 0.58);
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
}

.rtv-project-header-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.rtv-project-header-actions form {
    margin: 0;
}

.rtv-project-archive-banner {
    display: flex;
    width: min(100%, 1600px);
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    margin: 0 auto 18px;
    padding: 16px 18px;
    border: 1px solid rgba(210, 214, 218, 0.24);
    background: rgba(210, 214, 218, 0.06);
}

.rtv-project-archive-banner span,
.rtv-project-archive-banner strong {
    font-size: 10px;
    font-weight: 850;
    text-transform: uppercase;
}

.rtv-project-archive-banner strong {
    color: var(--portal-muted);
    text-align: right;
}

.rtv-update-pulse {
    width: 7px;
    height: 7px;
    flex: 0 0 auto;
    border-radius: 50%;
    background: var(--portal-red);
    box-shadow: 0 0 12px rgba(255, 59, 47, 0.78);
}

.rtv-project-index {
    position: sticky;
    z-index: 30;
    top: 14px;
    width: min(100%, 1600px);
    margin: 0 auto 18px;
    border: 1px solid var(--portal-line);
    background: rgba(8, 8, 8, 0.92);
    backdrop-filter: blur(16px);
    transition: opacity 180ms ease, transform 180ms ease;
}

.rtv-interaction-active .rtv-project-index {
    z-index: 5;
    opacity: 0;
    pointer-events: none;
    transform: translateY(-10px);
}

.admin-bar .rtv-project-index {
    top: 46px;
}

.rtv-project-index-links {
    display: flex;
    overflow-x: auto;
    scrollbar-width: none;
}

.rtv-project-index-links::-webkit-scrollbar {
    display: none;
}

.rtv-project-index-link {
    display: flex;
    min-width: max-content;
    min-height: 52px;
    flex: 1 0 auto;
    align-items: center;
    gap: 10px;
    padding: 0 18px;
    border-right: 1px solid var(--portal-line);
    color: var(--portal-muted);
    font-size: 10px;
    font-weight: 820;
    text-transform: uppercase;
    transition: background 180ms ease, color 180ms ease;
}

.rtv-project-index-link:last-child {
    border-right: 0;
}

.rtv-project-index-link > span {
    color: rgba(242, 241, 236, 0.34);
    font-size: 8px;
}

.rtv-project-index-link:is(:hover, :focus-visible),
.rtv-project-index-link.is-active {
    background: #1a1a1a;
    color: var(--portal-paper);
}

.rtv-project-index-link.is-active > span {
    color: var(--portal-red);
    text-shadow: 0 0 12px rgba(255, 59, 47, 0.86);
}

.rtv-project-index-compact {
    display: none;
}

[data-project-section] {
    scroll-margin-top: 96px;
}

.rtv-section-continue {
    display: flex;
    width: min(100%, 1600px);
    min-height: 66px;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin: 1px auto 0;
    padding: 0 clamp(18px, 3vw, 38px);
    border-top: 1px solid var(--portal-line);
    border-bottom: 1px solid var(--portal-line);
    background: #0b0b0b;
    color: var(--portal-muted);
    font-size: 9px;
    font-weight: 850;
    text-transform: uppercase;
    transition: background 180ms ease, color 180ms ease;
}

.rtv-section-continue strong {
    color: var(--portal-paper);
    font-size: 11px;
}

.rtv-section-continue strong span {
    display: inline-block;
    margin-left: 9px;
    color: var(--portal-red);
}

.rtv-section-continue:is(:hover, :focus-visible) {
    background: #171717;
    color: var(--portal-paper);
}

.rtv-viewer-shell {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 280px;
    width: min(100%, 1600px);
    height: min(76svh, 900px);
    min-height: 560px;
    margin: 0 auto;
    overflow: hidden;
    background: #111;
}

.rtv-viewer-shell::after {
    position: absolute;
    inset: 0;
    z-index: 4;
    display: grid;
    background: #0b0b0b;
    color: var(--portal-muted);
    content: 'LOADING LOCATION WORLD';
    font-size: 11px;
    font-weight: 800;
    place-items: center;
    pointer-events: none;
    transition: opacity 500ms ease, visibility 500ms ease;
}

.rtv-viewer-shell.is-ready::after {
    opacity: 0;
    visibility: hidden;
}

.rtv-panorama-viewer {
    position: relative;
    width: 100%;
    height: 100%;
    min-height: 0;
    overflow: hidden;
    background: #0a0a0a;
}

.rtv-webgl-canvas {
    display: block;
    width: 100%;
    height: 100%;
    cursor: grab;
    touch-action: none;
}

.rtv-webgl-canvas.is-dragging {
    cursor: grabbing;
}

.rtv-viewer-controls {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 3;
    display: grid;
    gap: 2px;
}

.rtv-viewer-controls button {
    display: grid;
    width: 34px;
    height: 34px;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: rgba(242, 241, 236, 0.94);
    color: #080808;
    cursor: pointer;
    font: 800 20px/1 Arial, Helvetica, sans-serif;
    place-items: center;
}

.rtv-viewer-controls button:enabled:is(:hover, :focus-visible) {
    background: white;
}

.rtv-viewer-title {
    position: absolute;
    bottom: 0;
    left: 0;
    z-index: 2;
    max-width: min(80%, 420px);
    padding: 13px 16px;
    border-bottom: 3px solid var(--portal-red);
    background: rgba(0, 0, 0, 0.78);
    font-size: 11px;
    font-weight: 850;
    text-transform: uppercase;
}

.rtv-scene-nav {
    position: relative;
    z-index: 5;
    display: flex;
    flex-direction: column;
    overflow: auto;
    border-left: 1px solid var(--portal-line);
    background: rgba(8, 8, 8, 0.96);
}

.rtv-scene-button {
    display: grid;
    grid-template-columns: 34px 1fr;
    min-height: 84px;
    align-items: center;
    gap: 12px;
    padding: 18px 20px;
    border: 0;
    border-bottom: 1px solid var(--portal-line);
    border-radius: 0;
    background: transparent;
    color: var(--portal-muted);
    cursor: pointer;
    font: inherit;
    font-size: 11px;
    font-weight: 800;
    text-align: left;
    text-transform: uppercase;
    transition: background 180ms ease, color 180ms ease;
}

.rtv-scene-button:enabled:is(:hover, :focus-visible),
.rtv-scene-button.is-active {
    background: #181818;
    color: var(--portal-paper);
}

.rtv-scene-button.is-active {
    box-shadow: inset 3px 0 0 var(--portal-red);
}

.rtv-scene-index {
    color: var(--portal-red);
}

.rtv-project-notes {
    display: grid;
    grid-template-columns: minmax(140px, 0.4fr) minmax(0, 1.6fr);
    gap: 36px;
    max-width: 1100px;
    margin: clamp(60px, 9vw, 130px) auto;
    font-size: clamp(18px, 2vw, 28px);
    line-height: 1.45;
}

.rtv-project-notice {
    width: min(100%, 1600px);
    margin: 0 auto 1px;
    padding: 16px 20px;
    border-left: 3px solid #58d68d;
    background: #151515;
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
}

.rtv-project-notice.is-error {
    border-color: var(--portal-red);
}

.rtv-marker-layer {
    position: absolute;
    inset: 0;
    z-index: 2;
    overflow: hidden;
    pointer-events: none;
}

.rtv-viewer-marker {
    --marker-color: #f6d34a;
    position: absolute;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0;
    border: 0;
    background: transparent;
    color: white;
    cursor: pointer;
    font: inherit;
    pointer-events: auto;
    transform: translate(-16px, -16px);
}

.rtv-viewer-marker > span {
    display: grid;
    width: 32px;
    height: 32px;
    border: 2px solid white;
    border-radius: 50%;
    background: var(--marker-color);
    box-shadow: 0 0 0 5px rgba(0, 0, 0, 0.35), 0 0 22px color-mix(in srgb, var(--marker-color) 72%, transparent);
    color: #050505;
    font-size: 8px;
    font-weight: 950;
    place-items: center;
}

.rtv-viewer-marker > strong {
    max-width: 180px;
    padding: 6px 8px;
    overflow: hidden;
    background: rgba(0, 0, 0, 0.82);
    font-size: 9px;
    font-weight: 900;
    text-overflow: ellipsis;
    text-transform: uppercase;
    white-space: nowrap;
}

.rtv-viewer-marker.is-selected > span {
    box-shadow: 0 0 0 5px white, 0 0 30px var(--marker-color);
}

.rtv-viewer-marker:not(:disabled, [aria-disabled='true'], .is-disabled, .is-selected):is(:hover, :focus-visible) > span {
    box-shadow: 0 0 0 3px white, 0 0 30px var(--marker-color);
}

.rtv-viewer-marker.is-crane,
.rtv-marker-tool-dot.is-crane {
    --marker-color: #63d2ff;
}

.rtv-viewer-marker.is-foh,
.rtv-marker-tool-dot.is-foh {
    --marker-color: #ff9161;
}

.rtv-viewer-marker.is-control,
.rtv-marker-tool-dot.is-control {
    --marker-color: #ba8cff;
}

.rtv-viewer-marker.is-ob-van,
.rtv-marker-tool-dot.is-ob-van {
    --marker-color: #60df9b;
}

.rtv-viewer-marker.is-lighting,
.rtv-marker-tool-dot.is-lighting {
    --marker-color: #ff66a8;
}

.rtv-viewer-marker.is-power,
.rtv-marker-tool-dot.is-power {
    --marker-color: #ffe566;
}

.rtv-viewer-marker.is-access,
.rtv-marker-tool-dot.is-access {
    --marker-color: #c5d1d8;
}

.rtv-webgl-canvas.is-placing-marker {
    cursor: crosshair;
}

.rtv-marker-editor,
.rtv-project-documents {
    width: min(100%, 1600px);
    margin: 1px auto 0;
    padding: clamp(24px, 3vw, 42px);
    background: #0b0b0b;
}

.rtv-marker-editor-heading,
.rtv-document-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 30px;
}

.rtv-marker-editor h2,
.rtv-project-documents h2 {
    margin: 0;
    font-size: clamp(26px, 3vw, 46px);
    font-weight: 780;
    line-height: 0.95;
    text-transform: uppercase;
}

.rtv-marker-editor-heading > p,
.rtv-document-heading > p {
    max-width: 430px;
    margin: 0;
    color: var(--portal-muted);
    font-size: 11px;
    font-weight: 750;
    line-height: 1.5;
    text-align: right;
    text-transform: uppercase;
}

.rtv-marker-tools {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-top: 28px;
}

.rtv-marker-tools button {
    display: inline-flex;
    min-height: 42px;
    align-items: center;
    gap: 9px;
    padding: 0 13px;
    border: 1px solid var(--portal-line);
    border-radius: 0;
    background: #070707;
    color: var(--portal-paper);
    cursor: pointer;
    font: inherit;
    font-size: 9px;
    font-weight: 900;
    text-transform: uppercase;
}

.rtv-marker-tools button:enabled:is(:hover, :focus-visible),
.rtv-marker-tools button.is-active {
    border-color: white;
    background: #202020;
}

.rtv-marker-tool-dot {
    width: 9px;
    height: 9px;
    background: var(--marker-color, #f6d34a);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--marker-color, #f6d34a);
}

.rtv-marker-inspector {
    display: grid;
    grid-template-columns: minmax(160px, 0.6fr) minmax(170px, 1fr) minmax(220px, 1.4fr) auto;
    align-items: end;
    gap: 12px;
    margin-top: 20px;
    padding: 18px;
    border: 1px solid var(--portal-line);
}

.rtv-marker-inspector[hidden] {
    display: none;
}

.rtv-marker-inspector > div strong {
    display: block;
    font-size: 11px;
    text-transform: uppercase;
}

.rtv-marker-inspector label {
    color: var(--portal-muted);
    font-size: 9px;
    font-weight: 850;
    text-transform: uppercase;
}

.rtv-marker-inspector input,
.rtv-marker-inspector textarea {
    display: block;
    width: 100%;
    min-height: 42px;
    margin-top: 7px;
    padding: 10px 12px;
    border: 1px solid var(--portal-line);
    border-radius: 0;
    outline: 0;
    background: #070707;
    color: var(--portal-paper);
    font: inherit;
    resize: vertical;
}

.rtv-marker-inspector input:focus,
.rtv-marker-inspector textarea:focus {
    border-color: white;
}

.rtv-marker-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.rtv-marker-actions p {
    margin: 24px 0 0;
    color: var(--portal-muted);
    font-size: 10px;
    font-weight: 750;
    text-transform: uppercase;
}

.rtv-project-documents {
    margin-top: clamp(46px, 7vw, 96px);
}

.rtv-document-upload {
    display: flex;
    align-items: flex-end;
    gap: 8px;
}

.rtv-file-picker {
    display: flex;
    min-height: 47px;
    align-items: center;
    padding: 0 14px;
    border: 1px solid var(--portal-line);
    color: var(--portal-muted);
    cursor: pointer;
    font-size: 10px;
    font-weight: 850;
    text-transform: uppercase;
}

.rtv-file-picker input {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
}

.rtv-file-picker:has(input:enabled):hover,
.rtv-file-picker:has(input:focus-visible) {
    border-color: var(--portal-paper);
    background: #202020;
    color: var(--portal-paper);
}

.rtv-document-upload .rtv-master-button {
    margin-top: 0;
}

.rtv-document-list {
    margin-top: 28px;
    border-top: 1px solid var(--portal-line);
}

.rtv-document-item {
    border-bottom: 1px solid var(--portal-line);
}

.rtv-document-row {
    display: grid;
    grid-template-columns: 48px minmax(0, 1fr) repeat(3, auto);
    min-height: 74px;
    align-items: center;
    gap: 14px;
}

.rtv-document-icon {
    display: grid;
    width: 42px;
    height: 42px;
    border: 1px solid var(--portal-line);
    color: var(--portal-red);
    font-size: 8px;
    font-weight: 900;
    place-items: center;
}

.rtv-document-row strong,
.rtv-document-row span {
    display: block;
}

.rtv-document-row strong {
    overflow-wrap: anywhere;
    font-size: 12px;
}

.rtv-document-row span {
    margin-top: 5px;
    color: var(--portal-muted);
    font-size: 9px;
    font-weight: 750;
    text-transform: uppercase;
}

.rtv-document-preview {
    padding: 0 0 22px 62px;
}

.rtv-document-preview[hidden] {
    display: none;
}

.rtv-document-preview-bar {
    display: flex;
    min-height: 42px;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 0 14px;
    background: #181818;
    color: var(--portal-muted);
    font-size: 9px;
    font-weight: 850;
    text-transform: uppercase;
}

.rtv-document-preview-bar span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rtv-document-preview-bar a {
    flex: 0 0 auto;
    color: var(--portal-paper);
}

.rtv-document-preview iframe {
    display: block;
    width: 100%;
    height: clamp(520px, 72svh, 920px);
    border: 0;
    background: #242424;
}

.rtv-document-glance {
    padding-bottom: 28px;
}

.rtv-document-preview-surface {
    position: relative;
    height: clamp(300px, 38vw, 580px);
    overflow: hidden;
    border: 1px solid rgba(242, 241, 236, 0.12);
    border-top: 0;
    background: #202020;
}

.rtv-document-preview-surface iframe,
.rtv-document-preview-surface img {
    display: block;
    width: 100%;
    height: 100%;
    border: 0;
    background: #242424;
    object-fit: contain;
    pointer-events: none;
}

.rtv-document-preview-open {
    position: absolute;
    z-index: 2;
    inset: 0;
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
    padding: 18px;
    background: rgba(0, 0, 0, 0.04);
    transition: background 180ms ease;
}

.rtv-document-preview-open > span {
    min-height: 40px;
    padding: 0 14px;
    background: rgba(7, 7, 7, 0.92);
    color: var(--portal-paper);
    font-size: 9px;
    font-weight: 880;
    line-height: 40px;
    text-transform: uppercase;
}

.rtv-document-preview-open > span span {
    display: inline;
    margin-left: 8px;
    color: var(--portal-red);
}

.rtv-document-preview-open:hover,
.rtv-document-preview-open:focus-visible {
    background: rgba(255, 255, 255, 0.07);
}

.rtv-viewer-review-bar {
    display: flex;
    width: min(100%, 1600px);
    min-height: 72px;
    align-items: center;
    justify-content: space-between;
    gap: 22px;
    margin: 1px auto 0;
    padding: 14px 20px;
    border: 1px solid var(--portal-line);
    background: #0b0b0b;
}

.rtv-viewer-review-bar .rtv-kicker {
    display: block;
    margin-bottom: 5px;
}

.rtv-viewer-review-bar strong {
    display: block;
    font-size: 11px;
    text-transform: uppercase;
}

.rtv-review-panel {
    width: min(100%, 1600px);
    margin: clamp(46px, 7vw, 96px) auto 0;
    padding: clamp(24px, 3vw, 42px);
    background: #0b0b0b;
}

.rtv-review-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 30px;
    margin-bottom: 28px;
}

.rtv-review-heading h2 {
    margin: 0;
    font-size: clamp(26px, 3vw, 46px);
    font-weight: 780;
    line-height: 0.95;
    text-transform: uppercase;
}

.rtv-review-heading > p {
    max-width: 470px;
    margin: 0;
    color: var(--portal-muted);
    font-size: 10px;
    font-weight: 750;
    line-height: 1.55;
    text-align: right;
    text-transform: uppercase;
}

.rtv-review-layout {
    display: grid;
    grid-template-columns: minmax(280px, 0.62fr) minmax(0, 1.38fr);
    gap: 1px;
    background: var(--portal-line);
}

.rtv-review-form,
.rtv-review-threads {
    padding: clamp(20px, 2.6vw, 34px);
    background: #070707;
}

.rtv-review-read-only {
    display: flex;
    min-height: 260px;
    flex-direction: column;
    justify-content: flex-end;
    padding: clamp(20px, 2.6vw, 34px);
    background: #070707;
}

.rtv-review-read-only span {
    color: #c4c6c8;
    font-size: 9px;
    font-weight: 850;
    text-transform: uppercase;
}

.rtv-review-read-only strong {
    margin-top: 7px;
    font-size: clamp(21px, 2vw, 31px);
    line-height: 1;
    text-transform: uppercase;
}

.rtv-review-read-only p {
    margin: 16px 0 0;
    color: var(--portal-muted);
    font-size: 11px;
    line-height: 1.55;
}

.rtv-review-read-only label {
    margin-top: 22px;
    color: var(--portal-muted);
    font-size: 9px;
    font-weight: 850;
    text-transform: uppercase;
}

.rtv-review-read-only select {
    width: 100%;
    min-height: 45px;
    margin-top: 7px;
    padding: 0 12px;
    border: 1px solid var(--portal-line);
    border-radius: 0;
    background: #0b0b0b;
    color: var(--portal-paper);
    font: inherit;
}

.rtv-review-form > label,
.rtv-review-status legend {
    display: block;
    margin: 0 0 7px;
    color: var(--portal-muted);
    font-size: 9px;
    font-weight: 850;
    text-transform: uppercase;
}

.rtv-review-form > label:not(:first-of-type) {
    margin-top: 18px;
}

.rtv-review-form label > span {
    font-weight: 600;
}

.rtv-review-form select,
.rtv-review-form input[type='number'],
.rtv-review-form textarea {
    width: 100%;
    min-height: 45px;
    padding: 10px 12px;
    border: 1px solid var(--portal-line);
    border-radius: 0;
    outline: 0;
    background: #0b0b0b;
    color: var(--portal-paper);
    font: inherit;
}

.rtv-review-form textarea {
    resize: vertical;
}

.rtv-review-form select:focus,
.rtv-review-form input:focus,
.rtv-review-form textarea:focus {
    border-color: var(--portal-paper);
}

.rtv-review-status {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    margin: 20px 0 0;
    padding: 0;
    border: 0;
}

.rtv-review-status label {
    cursor: pointer;
}

.rtv-review-status input {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
}

.rtv-review-status span {
    display: grid;
    min-height: 45px;
    padding: 6px 10px;
    border: 1px solid var(--portal-line);
    color: var(--portal-muted);
    font-size: 8px;
    font-weight: 900;
    text-align: center;
    text-transform: uppercase;
    place-items: center;
}

.rtv-review-status input:checked + span {
    border-color: var(--portal-paper);
    background: #202020;
    color: var(--portal-paper);
}

.rtv-review-status label:has(input:enabled):hover span {
    border-color: var(--portal-paper);
    background: #202020;
    color: var(--portal-paper);
}

.rtv-review-thread[hidden],
.rtv-review-form [hidden] {
    display: none;
}

.rtv-review-thread-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 22px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--portal-line);
}

.rtv-review-thread-header h3 {
    margin: 10px 0 0;
    font-size: clamp(20px, 2vw, 32px);
    line-height: 1;
    text-transform: uppercase;
}

.rtv-review-thread-header > p {
    margin: 0;
    color: var(--portal-muted);
    font-size: 9px;
    font-weight: 750;
    text-align: right;
    text-transform: uppercase;
}

.rtv-review-status-badge {
    display: inline-flex;
    min-height: 25px;
    align-items: center;
    padding: 0 9px;
    border: 1px solid var(--portal-line);
    color: var(--portal-muted);
    font-size: 8px;
    font-weight: 900;
    text-transform: uppercase;
}

.rtv-review-status-badge.is-approved {
    border-color: rgba(88, 214, 141, 0.55);
    color: #7fe0a8;
}

.rtv-review-status-badge.is-changes {
    border-color: rgba(255, 59, 47, 0.55);
    color: #ff776f;
}

.rtv-review-comment-list {
    max-height: 540px;
    overflow-y: auto;
}

.rtv-review-comment {
    padding: 18px 0;
    border-bottom: 1px solid var(--portal-line);
}

.rtv-review-comment header {
    display: flex;
    justify-content: space-between;
    gap: 18px;
}

.rtv-review-comment header strong,
.rtv-review-comment header span {
    font-size: 9px;
    font-weight: 850;
    text-transform: uppercase;
}

.rtv-review-comment header span {
    color: var(--portal-muted);
    text-align: right;
}

.rtv-review-comment p {
    margin: 10px 0 0;
    color: #d2d1cc;
    font-size: 13px;
    font-style: normal;
    line-height: 1.55;
}

.rtv-activity-card {
    width: min(100%, 1600px);
    margin: 1px auto 0;
}

.rtv-activity-table {
    min-width: 850px;
}

.rtv-activity-table th:first-child {
    width: 180px;
}

.rtv-table-action.is-danger {
    border-color: rgba(255, 59, 47, 0.45);
    color: #ff776f;
}

.rtv-table-action.is-danger:not(:disabled, [aria-disabled='true'], .is-disabled):is(:hover, :focus-visible) {
    border-color: var(--portal-red);
    background: rgba(255, 59, 47, 0.08);
}

.rtv-account-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 7px;
}

.rtv-notice {
    max-width: 1600px;
    margin: 60px auto;
    padding: 40px;
    border: 1px solid var(--portal-line);
    color: var(--portal-muted);
}

.rtv-master-panel {
    max-width: 1600px;
    margin: clamp(72px, 10vw, 150px) auto 0;
    padding-top: clamp(30px, 4vw, 58px);
    border-top: 1px solid var(--portal-line);
}

.rtv-master-header,
.rtv-access-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 30px;
}

.rtv-master-header {
    margin-bottom: 28px;
}

.rtv-master-header h2 {
    margin: 0;
    font-size: clamp(38px, 5.5vw, 86px);
    font-weight: 760;
    line-height: 0.9;
    text-transform: uppercase;
    transform: skewX(-8deg);
    transform-origin: left;
}

.rtv-master-header > p,
.rtv-access-heading > p {
    margin: 0;
    color: var(--portal-muted);
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
}

.rtv-master-layout {
    display: grid;
    grid-template-columns: minmax(280px, 0.62fr) minmax(0, 1.38fr);
    gap: 1px;
    background: var(--portal-line);
}

.rtv-master-card {
    padding: clamp(24px, 3vw, 42px);
    background: #0b0b0b;
}

.rtv-pending-card {
    margin-top: 1px;
}

.rtv-lifecycle-card {
    margin-top: 1px;
}

.rtv-lifecycle-list {
    display: grid;
    gap: 1px;
    background: var(--portal-line);
}

.rtv-lifecycle-row {
    display: flex;
    min-height: 78px;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 15px 17px;
    background: #070707;
}

.rtv-lifecycle-row > div {
    display: grid;
    gap: 4px;
}

.rtv-lifecycle-row > div span,
.rtv-lifecycle-row label {
    color: var(--portal-muted);
    font-size: 9px;
    font-weight: 850;
    text-transform: uppercase;
}

.rtv-lifecycle-row > div strong {
    font-size: 15px;
    text-transform: uppercase;
}

.rtv-lifecycle-row form {
    display: flex;
    align-items: flex-end;
    gap: 9px;
    margin: 0;
}

.rtv-lifecycle-row label {
    display: grid;
    gap: 5px;
}

.rtv-lifecycle-row input[type='date'] {
    min-height: 34px;
    padding: 0 9px;
    border: 1px solid var(--portal-line);
    border-radius: 0;
    background: #0b0b0b;
    color: var(--portal-paper);
    color-scheme: dark;
    font: inherit;
}

.rtv-lifecycle-row.is-archived {
    color: rgba(242, 241, 236, 0.66);
}

.rtv-master-card h3 {
    margin: 0 0 28px;
    font-size: clamp(24px, 2.8vw, 42px);
    font-weight: 760;
    line-height: 0.95;
    text-transform: uppercase;
}

.rtv-invite-form {
    display: flex;
    flex-direction: column;
}

.rtv-invite-form label {
    margin: 16px 0 7px;
    color: var(--portal-muted);
    font-size: 10px;
    font-weight: 850;
    text-transform: uppercase;
}

.rtv-invite-form input,
.rtv-invite-form select,
.rtv-invite-result input {
    width: 100%;
    min-height: 47px;
    padding: 0 13px;
    border: 1px solid var(--portal-line);
    border-radius: 0;
    outline: 0;
    background: #070707;
    color: var(--portal-paper);
    font: inherit;
}

.rtv-invite-form input:focus,
.rtv-invite-form select:focus {
    border-color: var(--portal-paper);
}

.rtv-master-button {
    display: inline-flex;
    min-height: 47px;
    align-items: center;
    justify-content: center;
    margin-top: 24px;
    padding: 0 18px;
    border: 0;
    border-radius: 0;
    background: var(--portal-red);
    color: white;
    cursor: pointer;
    font: inherit;
    font-size: 11px;
    font-weight: 900;
    text-align: center;
    text-transform: uppercase;
}

.rtv-master-button.is-secondary {
    margin: 0;
    background: var(--portal-paper);
    color: var(--portal-black);
}

.rtv-master-button:not(:disabled, [aria-disabled='true'], .is-disabled):is(:hover, :focus-visible) {
    filter: brightness(1.15);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.4);
}

.rtv-master-notice {
    margin-bottom: 1px;
    padding: 18px 22px;
    border-left: 3px solid var(--portal-red);
    background: #151515;
}

.rtv-master-notice.is-success {
    border-color: #58d68d;
}

.rtv-master-notice strong,
.rtv-master-notice > span {
    display: block;
}

.rtv-master-notice > span {
    margin-top: 5px;
    color: var(--portal-muted);
    font-size: 12px;
}

.rtv-invite-result {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
    margin-top: 16px;
}

.rtv-access-heading {
    margin-bottom: 26px;
}

.rtv-access-heading h3 {
    margin-bottom: 0;
}

.rtv-access-heading > p {
    max-width: 260px;
    line-height: 1.5;
    text-align: right;
}

.rtv-access-table-wrap {
    width: 100%;
    overflow-x: auto;
    border: 1px solid var(--portal-line);
}

.rtv-access-table {
    width: 100%;
    min-width: 620px;
    border-collapse: collapse;
    font-size: 11px;
}

.rtv-access-table th,
.rtv-access-table td {
    padding: 15px;
    border-right: 1px solid var(--portal-line);
    border-bottom: 1px solid var(--portal-line);
    text-align: center;
}

.rtv-access-table th:first-child {
    width: 220px;
    text-align: left;
}

.rtv-access-table thead th {
    color: var(--portal-muted);
    font-size: 9px;
    font-weight: 850;
    text-transform: uppercase;
}

.rtv-access-table tbody th strong,
.rtv-access-table tbody th span {
    display: block;
}

.rtv-access-table tbody th span {
    margin-top: 4px;
    color: var(--portal-muted);
    font-size: 10px;
    font-weight: 500;
}

.rtv-access-toggle {
    display: inline-grid;
    cursor: pointer;
    place-items: center;
}

.rtv-access-toggle input {
    width: 18px;
    height: 18px;
    margin: 0;
    accent-color: var(--portal-red);
}

.rtv-access-toggle span {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
}

.rtv-pending-table th:first-child {
    width: 260px;
}

.rtv-invite-status {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: var(--portal-muted);
    font-size: 10px;
    font-weight: 850;
    text-transform: uppercase;
}

.rtv-invite-status::before {
    width: 7px;
    height: 7px;
    background: #f3b53f;
    border-radius: 50%;
    box-shadow: 0 0 10px rgba(243, 181, 63, 0.5);
    content: '';
}

.rtv-invite-status.is-expired::before {
    background: var(--portal-red);
    box-shadow: 0 0 10px rgba(255, 59, 47, 0.55);
}

.rtv-table-action {
    min-height: 35px;
    padding: 0 12px;
    border: 1px solid var(--portal-line);
    border-radius: 0;
    background: transparent;
    color: var(--portal-paper);
    cursor: pointer;
    font: inherit;
    font-size: 9px;
    font-weight: 850;
    text-transform: uppercase;
}

.rtv-table-action:not(:disabled, [aria-disabled='true'], .is-disabled):is(:hover, :focus-visible) {
    border-color: var(--portal-paper);
    background: #202020;
}

.rtv-table-action.is-disabled {
    display: inline-flex;
    align-items: center;
    min-height: 35px;
    margin-top: 0;
    border-color: rgba(255, 255, 255, 0.1);
    color: var(--portal-muted);
    cursor: default;
    opacity: 0.72;
}

.rtv-master-empty,
.rtv-form-message {
    color: var(--portal-muted);
    line-height: 1.55;
}

.rtv-form-message.is-error {
    padding: 13px;
    border-left: 3px solid var(--portal-red);
    background: rgba(255, 59, 47, 0.08);
    color: var(--portal-paper);
}

.rtv-form-message.is-success {
    padding: 13px;
    border-left: 3px solid #58d68d;
    background: rgba(88, 214, 141, 0.08);
    color: var(--portal-paper);
}

/* Only native interactive elements receive interaction cues. */
.rtv-portal :where(a[href], button, summary, select, input[type='submit'], input[type='button'], input[type='checkbox'], input[type='radio']):not(:disabled, [aria-disabled='true'], .is-disabled) {
    cursor: pointer;
}

.rtv-portal :where(a[href], button, input, select, textarea, summary):not(:disabled, [aria-disabled='true'], .is-disabled):focus-visible,
.rtv-file-picker:has(input:focus-visible),
.rtv-review-status input:focus-visible + span {
    outline: 2px solid var(--portal-paper);
    outline-offset: 3px;
}

.rtv-project-index-link:focus-visible,
.rtv-scene-button:focus-visible,
.rtv-document-preview-open:focus-visible {
    outline-offset: -3px;
}

.rtv-portal :where(button, input, select, textarea):disabled,
.rtv-portal :where(a, button, input, select, textarea)[aria-disabled='true'],
.rtv-portal .is-disabled {
    cursor: default;
}

.rtv-portal a[href]:not([aria-disabled='true'], .is-disabled, .rtv-project-card, .rtv-project-index-link, .rtv-section-continue, .rtv-document-preview-open, .rtv-table-action, .rtv-master-button):is(:hover, :focus-visible) {
    color: var(--portal-red);
    text-decoration: underline;
    text-underline-offset: 4px;
}

.rtv-access-toggle:has(input:enabled):hover input {
    outline: 1px solid var(--portal-paper);
    outline-offset: 3px;
}

@media (min-width: 1900px) {
    .rtv-project-index,
    .admin-bar .rtv-project-index {
        position: fixed;
        top: 50%;
        right: 20px;
        width: 128px;
        margin: 0;
        transform: translateY(-50%);
    }

    .rtv-project-index-links {
        display: grid;
        overflow: visible;
    }

    .rtv-project-index-link {
        min-width: 0;
        min-height: 58px;
        padding: 10px 13px;
        border-right: 0;
        border-bottom: 1px solid var(--portal-line);
    }

    .rtv-project-index-link:last-child {
        border-bottom: 0;
    }

    .rtv-project-index-link strong {
        overflow: hidden;
        text-overflow: ellipsis;
    }
}

@media (max-width: 900px) {
    .rtv-project-grid {
        grid-template-columns: 1fr;
    }

    .rtv-project-card {
        min-height: 230px;
    }

    .rtv-viewer-shell {
        display: block;
        height: auto;
        min-height: 0;
    }

    .rtv-panorama-viewer {
        height: 68svh;
        min-height: 480px;
    }

    .rtv-scene-nav {
        display: grid;
        grid-auto-columns: minmax(180px, 1fr);
        grid-auto-flow: column;
        border-top: 1px solid var(--portal-line);
        border-left: 0;
    }

    .rtv-scene-button {
        border-right: 1px solid var(--portal-line);
        border-bottom: 0;
    }

    .rtv-scene-button.is-active {
        box-shadow: inset 0 3px 0 var(--portal-red);
    }

    .rtv-master-layout {
        grid-template-columns: 1fr;
    }

    .rtv-marker-inspector {
        grid-template-columns: 1fr 1fr;
    }

    .rtv-document-heading {
        display: block;
    }

    .rtv-document-upload {
        margin-top: 22px;
    }

    .rtv-review-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .rtv-dashboard,
    .rtv-project-view {
        padding: 20px 14px 40px;
    }

    .rtv-dashboard-header,
    .rtv-project-bar {
        display: block;
    }

    .rtv-dashboard-header h1,
    .rtv-project-bar h1 {
        font-size: clamp(42px, 14vw, 68px);
    }

    .rtv-project-bar h1 {
        width: calc(100% - 14px);
        margin-left: 7px;
    }

    .rtv-user-menu,
    .rtv-logout {
        margin-top: 20px;
    }

    .rtv-project-header-actions {
        align-items: flex-start;
        flex-direction: column;
        gap: 0;
        margin-top: 18px;
    }

    .rtv-project-header-actions .rtv-logout {
        margin-top: 14px;
    }

    .rtv-project-archive-banner {
        align-items: flex-start;
        flex-direction: column;
        gap: 8px;
    }

    .rtv-project-archive-banner strong {
        text-align: left;
    }

    .rtv-archived-projects > summary {
        min-height: 88px;
    }

    .rtv-archived-projects > summary > span:last-child {
        max-width: 92px;
        text-align: right;
    }

    .rtv-lifecycle-row,
    .rtv-lifecycle-row form {
        align-items: stretch;
        flex-direction: column;
    }

    .rtv-lifecycle-row form .rtv-table-action {
        min-height: 40px;
    }

    .rtv-project-bar {
        align-items: flex-start;
    }

    .rtv-project-card-top {
        align-items: flex-start;
    }

    .rtv-project-card-top time {
        max-width: 46%;
        white-space: normal;
        text-align: right;
    }

    .rtv-project-index,
    .admin-bar .rtv-project-index {
        top: 8px;
        margin-bottom: 12px;
    }

    .admin-bar .rtv-project-index {
        top: 54px;
    }

    .rtv-project-index-links {
        display: none;
    }

    .rtv-project-index-compact {
        display: grid;
        grid-template-columns: auto minmax(0, 1fr) auto;
        min-height: 56px;
        align-items: center;
        gap: 12px;
        padding: 0 13px;
        font-size: 9px;
        font-weight: 850;
        text-transform: uppercase;
    }

    .rtv-project-index-compact > span {
        color: var(--portal-red);
        text-shadow: 0 0 12px rgba(255, 59, 47, 0.72);
    }

    .rtv-project-index-compact strong {
        overflow: hidden;
        color: var(--portal-paper);
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .rtv-project-index-compact a {
        color: var(--portal-muted);
        white-space: nowrap;
    }

    .rtv-project-index-compact a[hidden] {
        display: none;
    }

    [data-project-section] {
        scroll-margin-top: 78px;
    }

    .rtv-section-continue {
        min-height: 60px;
        padding: 0 14px;
    }

    .rtv-section-continue > span {
        display: none;
    }

    .rtv-section-continue strong {
        width: 100%;
        text-align: right;
    }

    .rtv-external-tour-bar {
        display: block;
    }

    .rtv-external-tour-bar > span {
        display: block;
        margin-top: 14px;
    }

    .rtv-external-tour-frame {
        min-height: 520px;
        aspect-ratio: 4 / 5;
    }

    .rtv-camera-world-frame {
        min-height: 720px;
        aspect-ratio: 4 / 5;
    }

    .rtv-interaction-gate {
        gap: 14px;
        padding: 20px;
    }

    .rtv-interaction-gate strong {
        font-size: clamp(25px, 8vw, 38px);
    }

    .rtv-interaction-exit {
        top: 10px;
        right: 10px;
    }

    .rtv-project-notes {
        display: block;
        font-size: 18px;
    }

    .rtv-panorama-viewer {
        height: 62svh;
        min-height: 430px;
    }

    .rtv-master-header,
    .rtv-access-heading {
        display: block;
    }

    .rtv-master-header > p,
    .rtv-access-heading > p {
        margin-top: 14px;
        text-align: left;
    }

    .rtv-invite-result {
        grid-template-columns: 1fr;
    }

    .rtv-marker-editor-heading,
    .rtv-marker-actions {
        display: block;
    }

    .rtv-marker-editor-heading > p {
        margin-top: 14px;
        text-align: left;
    }

    .rtv-marker-inspector {
        grid-template-columns: 1fr;
    }

    .rtv-marker-actions .rtv-master-button {
        width: 100%;
    }

    .rtv-document-upload {
        display: grid;
    }

    .rtv-document-row {
        grid-template-columns: 42px minmax(0, 1fr);
        padding: 14px 0;
    }

    .rtv-document-row > .rtv-table-action,
    .rtv-document-row > form {
        grid-column: 2;
    }

    .rtv-document-preview {
        padding: 0 0 18px;
    }

    .rtv-document-preview iframe {
        height: 62svh;
        min-height: 420px;
    }

    .rtv-document-preview-surface {
        height: 240px;
    }

    .rtv-document-preview-surface iframe {
        height: 100%;
        min-height: 0;
    }

    .rtv-document-preview-open {
        padding: 10px;
    }

    .rtv-viewer-review-bar,
    .rtv-review-heading,
    .rtv-review-thread-header {
        display: block;
    }

    .rtv-viewer-review-bar .rtv-table-action {
        width: 100%;
        margin-top: 14px;
    }

    .rtv-review-heading > p,
    .rtv-review-thread-header > p {
        margin-top: 14px;
        text-align: left;
    }

    .rtv-review-status {
        grid-template-columns: 1fr;
    }
}

@media (prefers-reduced-motion: reduce) {
    .rtv-project-card,
    .rtv-login-panel input[type='submit'],
    .rtv-archived-projects > summary {
        transition: none;
    }

    .rtv-project-card:is(:hover, :focus-visible),
    .rtv-login-panel input[type='submit']:enabled:is(:hover, :focus-visible) {
        transform: none;
    }
}

/* Client access: each person keeps their project names beside the controls. */
[data-access-manager] [hidden] {
    display: none !important;
}

[data-access-manager]:not([data-access-enhanced='true']) [data-access-tools] {
    display: none;
}

.rtv-access-tools {
    display: grid;
    grid-template-columns: minmax(220px, 1.6fr) minmax(180px, 1fr) minmax(150px, 0.8fr);
    align-items: end;
    gap: 12px;
    margin: 0 0 18px;
    padding: 18px;
    border: 1px solid var(--portal-line);
    background: #101010;
}

.rtv-access-tools label {
    display: grid;
    min-width: 0;
    gap: 7px;
    color: var(--portal-muted);
    font-size: 9px;
    font-weight: 850;
    text-transform: uppercase;
}

.rtv-access-tools input,
.rtv-access-tools select {
    width: 100%;
    min-width: 0;
    min-height: 44px;
    padding: 0 12px;
    border: 1px solid var(--portal-line);
    border-radius: 0;
    background: #070707;
    color: var(--portal-paper);
    color-scheme: dark;
    font: inherit;
    font-size: 12px;
    font-weight: 500;
    text-transform: none;
}

.rtv-access-tools input::placeholder {
    color: var(--portal-muted);
}

.rtv-access-tools :is(input, select):is(:hover, :focus-visible) {
    border-color: var(--portal-paper);
}

[data-access-results] {
    display: block;
    grid-column: 1 / -1;
    margin: 0;
    color: var(--portal-muted);
    font-size: 10px;
    line-height: 1.5;
}

.rtv-access-client-list {
    display: grid;
    gap: 12px;
}

.rtv-access-client {
    min-width: 0;
    border: 1px solid var(--portal-line);
    background: #080808;
}

.rtv-access-client.has-unsaved-access {
    border-color: rgba(255, 175, 87, 0.7);
}

.rtv-access-client-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    padding: 21px 22px 15px;
}

.rtv-access-client-identity {
    min-width: 0;
}

.rtv-access-client-identity :is(h3, h4, strong) {
    display: block;
    margin: 0;
    color: var(--portal-paper);
    font-size: 16px;
    font-weight: 780;
    line-height: 1.25;
    overflow-wrap: anywhere;
    text-transform: none;
}

.rtv-access-client-identity :is(p, span) {
    display: block;
    margin: 6px 0 0;
    color: var(--portal-muted);
    font-size: 11px;
    line-height: 1.5;
    overflow-wrap: anywhere;
}

[data-access-count] {
    flex: 0 0 auto;
    padding-top: 3px;
    color: var(--portal-muted);
    font-size: 10px;
    font-weight: 750;
    line-height: 1.5;
    text-align: right;
}

[data-access-summary] {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    padding: 0 22px 20px;
}

[data-access-summary] > :is(span, a) {
    display: inline-flex;
    min-height: 28px;
    align-items: center;
    padding: 5px 9px;
    border: 1px solid var(--portal-line);
    color: #d2d1cc;
    font-size: 10px;
    line-height: 1.4;
    overflow-wrap: anywhere;
}

[data-access-summary] > .is-empty,
[data-access-summary] > .rtv-access-none {
    padding: 0;
    border: 0;
    color: var(--portal-muted);
}

.rtv-access-project-chip small {
    margin-left: 8px;
    color: var(--portal-muted);
    font-size: 8px;
    font-weight: 650;
    text-transform: uppercase;
}

[data-access-editor] {
    border-top: 1px solid var(--portal-line);
}

[data-access-editor] > summary {
    display: flex;
    min-height: 48px;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    padding: 13px 22px;
    color: var(--portal-paper);
    cursor: pointer;
    font-size: 10px;
    font-weight: 850;
    list-style: none;
    text-transform: uppercase;
    transition: background-color 140ms ease;
}

[data-access-editor] > summary::-webkit-details-marker {
    display: none;
}

[data-access-editor] > summary > span[aria-hidden='true'] {
    display: none;
}

[data-access-editor] > summary::after {
    content: '+';
    font-size: 19px;
    font-weight: 500;
    line-height: 1;
}

[data-access-editor][open] > summary::after {
    content: '−';
}

[data-access-editor] > summary:is(:hover, :focus-visible),
[data-access-editor][open] > summary {
    background: #1a1a1a;
}

[data-client-access-form] {
    margin: 0;
    padding: 0 22px 20px;
}

.rtv-access-editor-heading {
    position: sticky;
    z-index: 3;
    top: 12px;
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: 8px 16px;
    margin: 0 -1px 14px;
    padding: 16px 0 13px;
    border-bottom: 1px solid var(--portal-line);
    background: #080808;
    box-shadow: 0 6px 0 #080808;
    font-size: 12px;
    line-height: 1.5;
}

.rtv-access-editor-heading :is(p, h4, strong) {
    margin: 0;
    font-size: inherit;
}

.rtv-access-editor-heading > span {
    color: var(--portal-muted);
    font-size: 10px;
}

.rtv-access-project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 265px), 1fr));
    gap: 8px;
    min-width: 0;
    margin: 0;
    padding: 0;
    border: 0;
}

.rtv-access-project {
    display: grid;
    grid-template-columns: 20px minmax(0, 1fr) auto;
    min-width: 0;
    min-height: 78px;
    align-items: center;
    gap: 11px;
    margin: 0;
    padding: 13px;
    border: 1px solid var(--portal-line);
    background: #0c0c0c;
    cursor: pointer;
    transition: background-color 140ms ease, border-color 140ms ease;
}

.rtv-access-project input {
    width: 18px;
    height: 18px;
    margin: 0;
    accent-color: var(--portal-red);
    cursor: pointer;
}

.rtv-access-project-copy {
    min-width: 0;
}

.rtv-access-project-title {
    display: block;
    color: var(--portal-paper);
    font-size: 11px;
    font-weight: 750;
    line-height: 1.45;
    overflow-wrap: anywhere;
}

.rtv-access-project-meta {
    display: block;
    margin-top: 5px;
    color: var(--portal-muted);
    font-size: 9px;
    line-height: 1.4;
    text-transform: uppercase;
}

.rtv-access-state {
    max-width: 75px;
    color: var(--portal-muted);
    font-size: 9px;
    font-weight: 750;
    line-height: 1.45;
    text-align: right;
}

.rtv-access-project:has(input:checked),
.rtv-access-project.is-assigned {
    border-color: rgba(242, 241, 236, 0.43);
    background: #151515;
}

.rtv-access-project:is(.is-pending-add, .is-pending-remove) {
    border-color: rgba(255, 175, 87, 0.7);
}

.rtv-access-project:is(.is-pending-add, .is-pending-remove) .rtv-access-state {
    color: #ffbe79;
}

.rtv-access-project:hover,
.rtv-access-project:has(input:focus-visible) {
    border-color: var(--portal-paper);
    background: #202020;
}

.rtv-access-change-summary {
    margin-top: 14px;
    padding: 12px 14px;
    border-left: 2px solid #ffbe79;
    background: #19140e;
    color: #ded4c5;
    font-size: 11px;
    line-height: 1.6;
    overflow-wrap: anywhere;
}

.rtv-access-change-summary p {
    margin: 0;
}

.rtv-access-change-summary:empty {
    display: none;
}

.rtv-access-change-summary p + p {
    margin-top: 6px;
}

.rtv-access-savebar {
    position: sticky;
    z-index: 4;
    bottom: 12px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-top: 18px;
    padding: 12px;
    border: 1px solid var(--portal-line);
    background: #151515;
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.35);
}

.rtv-access-savebar .rtv-master-button {
    min-height: 42px;
    margin: 0;
    padding: 0 14px;
    font-size: 10px;
}

.rtv-access-savebar button:disabled {
    background: #292929;
    color: var(--portal-muted);
    cursor: default;
}

.rtv-access-dirty {
    flex: 1 1 auto;
    color: #ffbe79;
    font-size: 10px;
    font-weight: 750;
}

.rtv-access-client > .rtv-account-actions {
    justify-content: flex-start;
    padding: 15px 22px;
    border-top: 1px solid var(--portal-line);
}

[data-access-empty] {
    margin: 0;
    padding: 25px 22px;
    border: 1px solid var(--portal-line);
    color: var(--portal-muted);
    font-size: 12px;
    line-height: 1.6;
}

[data-access-manager] :is(summary, input, select, button, a):focus-visible {
    outline: 2px solid var(--portal-paper);
    outline-offset: 3px;
}

@media (max-width: 720px) {
    .rtv-access-tools {
        grid-template-columns: 1fr 1fr;
        padding: 14px;
    }

    .rtv-access-tools > label:first-child {
        grid-column: 1 / -1;
    }

    .rtv-access-client-header {
        padding: 17px 16px 13px;
    }

    [data-access-summary] {
        padding: 0 16px 17px;
    }

    [data-access-count] {
        max-width: 100px;
    }

    [data-access-editor] > summary {
        padding-right: 16px;
        padding-left: 16px;
    }

    [data-client-access-form] {
        padding-right: 16px;
        padding-left: 16px;
    }

    .rtv-access-project-grid {
        grid-template-columns: 1fr;
    }

    .rtv-access-savebar {
        bottom: 8px;
    }

    .rtv-access-dirty {
        flex-basis: 100%;
    }

    .rtv-access-savebar [data-access-save] {
        flex: 1;
    }

    .rtv-access-client > .rtv-account-actions {
        padding-right: 16px;
        padding-left: 16px;
    }
}

@media (prefers-reduced-motion: reduce) {
    [data-access-editor] > summary,
    .rtv-access-project {
        transition: none;
    }
}
