/* REL-ACCESS-1B pilot only: staff cannot access incomplete pages. */
body.access1b-staff [data-route]:not([data-route="projects"]):not([data-route="home"]),
body.access1b-staff #productionNavGroup,
body.access1b-staff .rel-access-nav,
body.access1b-staff #projectNew,
body.access1b-staff #projectTrashOpen,
body.access1b-staff #projectContextBar,
body.access1b-staff #projectViewList ~ button {display:none!important}
.rel-access-invitation{margin-top:12px;padding:12px;border:1px solid #a6c7ad;overflow-wrap:anywhere;user-select:text}
.rel-access-activation{margin-top:16px;text-align:left}
.rel-access-activation summary{cursor:pointer}
.rel-access-activation .rel-access-form{margin-top:12px}
.rel-access-pane .rel-access-inline button{font-size:11px;padding:7px 10px}

body.access1b-staff #homeNew,
body.access1b-staff #homeView .dashboard-lower,
body.access1b-staff #homeView .section-heading,
body.access1b-staff #homeView #recent,
body.access1b-staff #homeView #recentPager,
body.access1b-staff #homeView .stat:first-child,
body.access1b-staff #projectDetail button {display:none!important}
body.access1b-staff #homeProjectHighlights{display:grid;gap:8px}
body.access1b-staff #homeProjectHighlights button{text-align:left}

/* Invitation fix3: space account actions and provide immediately visible code. */
.rel-access-account-actions{display:flex;gap:10px;flex-wrap:wrap;align-items:center;margin-top:9px}
.rel-access-account-actions button{margin:0;min-height:38px;padding:8px 12px;line-height:1.3}
.rel-access-account-actions button:disabled{opacity:.52;cursor:not-allowed}
.rel-access-action-feedback{color:#ffc7b7!important;margin:8px 0 0;overflow-wrap:anywhere}
.rel-access-invite-dialog{position:fixed;max-width:min(540px,calc(100vw - 32px));width:100%;max-height:calc(100dvh - 40px);overflow:auto;background:#1e2922;color:#eef2ee;border:1px solid #698674;border-radius:9px;padding:0;box-shadow:0 20px 72px #000b;box-sizing:border-box}
.rel-access-invite-dialog::backdrop{background:rgba(0,0,0,.75)}
.rel-access-invite-body{padding:24px;display:grid;gap:14px}
.rel-access-invite-body h2{font-size:19px;margin:0}
.rel-access-invite-body p{margin:0;line-height:1.6}
.rel-access-invite-body label{font-size:13px;color:#ceddd1}
.rel-access-invite-body textarea{width:100%;min-width:0;min-height:76px;background:#101713;color:#fff;border:1px solid #6b8a75;border-radius:6px;box-sizing:border-box;padding:12px;font:14px/1.5 ui-monospace,monospace;overflow-wrap:anywhere;resize:none}
.rel-access-invite-body textarea:focus-visible{outline:2px solid #b2d0b5;outline-offset:2px}
.rel-access-invite-buttons{display:flex;gap:10px;flex-wrap:wrap}
.rel-access-invite-buttons button{min-width:104px;min-height:42px}
@media(max-width:540px){.rel-access-invite-body{padding:17px}.rel-access-account-actions button{flex:1 1 120px}.rel-access-invite-buttons button{flex:1}}

/* REL-GATE-1: project lead works inside restricted project overview only. */
body.access1b-staff.access1b-lead #projectNew,
body.access1b-staff.access1b-lead #projectDetail button {display:inline-flex!important}
body.access1b-staff.access1b-lead #projectDetail .rel-access-pane {max-width:860px;margin:24px 0}
