:root {
    --bg: #07070a;
    --panel: #101016;
    --panel-deep: #0b0b10;
    --text: #f5f3f7;
    --muted: #a6a2ae;
    --border: rgba(255, 255, 255, 0.11);
    --primary: #9501d8;
    --primary-bright: #bc42ef;
    --primary-glow: rgba(149, 1, 216, 0.26);
}

* { box-sizing: border-box; }
html { min-height: 100%; background: var(--bg); }
body {
    min-height: 100vh; margin: 0; color: var(--text); background:
        radial-gradient(circle at 14% 18%, rgba(149, 1, 216, 0.18), transparent 27rem),
        radial-gradient(circle at 85% 82%, rgba(0, 219, 222, 0.09), transparent 29rem),
        var(--bg);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
body::before {
    content: ""; position: fixed; inset: 0; pointer-events: none; opacity: .35;
    background-image: radial-gradient(rgba(255,255,255,.38) .7px, transparent .7px);
    background-size: 24px 24px;
    mask-image: linear-gradient(to bottom, black, transparent 78%);
}
a { color: inherit; }
button, input, select { font: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid var(--primary-bright); outline-offset: 3px; }

.account-shell { width: min(1080px, calc(100% - 40px)); margin: 0 auto; padding: 32px 0 46px; position: relative; }
.brand { display: inline-flex; align-items: center; gap: 9px; color: var(--text); font-size: 1.16rem; font-weight: 800; text-decoration: none; }
.brand-icon { display: grid; place-items: center; width: 29px; height: 29px; border-radius: 7px; background: linear-gradient(135deg, #67ef6b, #d7fa4c); color: #261033; font-size: 1rem; }

.account-card { display: grid; grid-template-columns: 1.05fr .95fr; margin-top: clamp(45px, 10vh, 110px); overflow: hidden; border: 1px solid var(--border); border-radius: 22px; background: rgba(16,16,22,.92); box-shadow: 0 28px 90px rgba(0,0,0,.42), 0 0 70px var(--primary-glow); }
.account-loading { margin-top: clamp(45px, 10vh, 110px); padding: clamp(38px, 7vw, 78px); border: 1px solid var(--border); border-radius: 20px; background: linear-gradient(145deg, rgba(149,1,216,.2), transparent 56%), rgba(16,16,22,.9); }.account-loading h1 { margin-bottom: 16px; }.account-loading p:last-child { color: var(--muted); }
.account-intro { min-height: 510px; padding: clamp(34px, 6vw, 72px); border-right: 1px solid var(--border); background: linear-gradient(150deg, rgba(149,1,216,.2), transparent 54%), var(--panel-deep); }
.eyebrow { margin: 0 0 18px; color: var(--primary-bright); font-size: .72rem; letter-spacing: .14em; font-weight: 800; }
h1, h2, p { margin-top: 0; }
h1 { max-width: 470px; margin-bottom: 16px; font-size: clamp(2.45rem, 5vw, 4.5rem); line-height: .95; letter-spacing: -.065em; }
.account-intro > p:not(.eyebrow) { max-width: 430px; color: var(--muted); font-size: 1.03rem; line-height: 1.65; }
.account-preview { margin-top: 56px; display: grid; gap: 12px; }
.preview-line { display: flex; align-items: center; gap: 12px; color: #d8d3de; font-size: .92rem; }
.preview-icon { display: grid; place-items: center; width: 34px; height: 34px; border: 1px solid; border-radius: 9px; font-weight: 800; }
.purple { color: #e288ff; border-color: rgba(226,136,255,.48); background: rgba(149,1,216,.17); }
.cyan { color: #48e9ed; border-color: rgba(72,233,237,.42); background: rgba(0,183,190,.12); }
.gold { color: #f8c832; border-color: rgba(248,200,50,.42); background: rgba(220,157,0,.12); }

.auth-panel { padding: clamp(32px, 5vw, 58px); display: flex; flex-direction: column; justify-content: center; background: rgba(12,12,17,.83); }
.panel-heading h2 { margin-bottom: 8px; font-size: 1.55rem; letter-spacing: -.035em; }
.panel-heading p { color: var(--muted); font-size: .91rem; line-height: 1.55; }
.google-button, .email-button { width: 100%; min-height: 49px; border-radius: 10px; font-weight: 750; transition: transform .18s, border-color .18s, background .18s; }
.google-button { display: flex; justify-content: center; align-items: center; gap: 10px; border: 1px solid var(--border); background: #f7f5f8; color: #17131b; }
.google-button:hover { transform: translateY(-2px); background: #fff; }
.google-mark { display: grid; place-items: center; width: 21px; height: 21px; border-radius: 50%; color: #4285f4; font-weight: 900; }
.divider { display: flex; align-items: center; gap: 12px; margin: 24px 0; color: #807b88; font-size: .78rem; }
.divider::before, .divider::after { content: ""; flex: 1; height: 1px; background: var(--border); }
label { display: block; margin-bottom: 8px; color: #d7d1dc; font-size: .84rem; font-weight: 700; }
input { width: 100%; height: 49px; padding: 0 13px; border: 1px solid var(--border); border-radius: 10px; color: var(--text); background: #0a0a0f; }
select { width: 100%; height: 49px; padding: 0 13px; border: 1px solid var(--border); border-radius: 10px; color: var(--text); background: #0a0a0f; }
input::placeholder { color: #706b76; }
input:focus { border-color: var(--primary-bright); outline: none; }
.email-button { margin-top: 12px; border: 1px solid var(--primary); background: var(--primary); color: white; box-shadow: 0 10px 28px rgba(149,1,216,.22); }
.email-button:hover { transform: translateY(-2px); background: #a910e9; }
.auth-status { min-height: 2.8em; margin: 17px 0 0; color: var(--muted); font-size: .8rem; line-height: 1.5; }
.auth-status.is-error { color: #ff9a9a; }
.auth-status.is-success { color: #91ed9f; }
.legal-copy { margin: 10px 0 0; color: #77727f; font-size: .72rem; line-height: 1.5; }
.back-home { margin: 25px 0 0; text-align: center; color: var(--muted); font-size: .88rem; }
.back-home a { text-decoration: none; }
.back-home a:hover { color: var(--text); }

.member-area { margin-top: clamp(45px, 10vh, 110px); }
.member-header { display: flex; align-items: end; justify-content: space-between; gap: 25px; margin-bottom: 24px; }
.member-header h1 { margin: 0; font-size: clamp(2.25rem, 4.4vw, 3.9rem); }
.member-email { margin: 12px 0 0; color: var(--muted); font-size: .93rem; }
.checkout-notice { margin: 0 0 18px; padding: 13px 15px; border: 1px solid rgba(145,237,159,.35); border-radius: 10px; color: #b9f3c1; background: rgba(44,139,58,.14); font-size: .88rem; line-height: 1.45; }
.checkout-notice.is-cancelled { border-color: rgba(248,200,50,.35); color: #f9db85; background: rgba(154,110,0,.12); }
.signout-button, .portal-button { min-height: 43px; border-radius: 9px; font-weight: 750; }
.signout-button { padding: 0 16px; border: 1px solid var(--border); color: var(--text); background: transparent; }
.signout-button:hover { border-color: #9c95a6; }
.member-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 18px; }
.member-panel { min-height: 270px; padding: 29px; border: 1px solid var(--border); border-radius: 17px; background: rgba(16,16,22,.88); }
.plan-panel { background: linear-gradient(130deg, rgba(149,1,216,.2), transparent 52%), rgba(16,16,22,.9); }
.panel-kicker { margin: 0 0 14px; color: var(--primary-bright); font-size: .7rem; font-weight: 800; letter-spacing: .13em; }
.member-panel h2 { margin: 0 0 8px; font-size: 1.75rem; letter-spacing: -.04em; }
.member-panel > p:not(.panel-kicker):not(.panel-note) { max-width: 410px; color: var(--muted); font-size: .92rem; line-height: 1.55; }
.portal-button { margin-top: 17px; padding: 0 16px; border: 1px solid var(--primary); color: white; background: var(--primary); }
.portal-button:hover:not(:disabled) { background: #a910e9; }
.portal-button:disabled { cursor: not-allowed; opacity: .58; }
.panel-note { margin: 13px 0 0; color: #89828f; font-size: .76rem; line-height: 1.45; }
.member-list { display: grid; gap: 15px; padding: 0; margin: 25px 0; list-style: none; color: #d8d2dc; font-size: .9rem; }
.member-list span { display: inline-block; width: 25px; color: var(--primary-bright); font-weight: 900; }
.hub-link { display: inline-block; margin-top: 6px; color: #f4eaff; font-weight: 750; font-size: .88rem; text-decoration-color: rgba(244,234,255,.35); text-underline-offset: 4px; }
.checkout-choice { display: flex; align-items: center; justify-content: space-between; gap: 22px; margin-top: 18px; padding: 25px 29px; border: 1px solid rgba(188,66,239,.48); border-radius: 17px; background: linear-gradient(100deg, rgba(149,1,216,.2), rgba(16,16,22,.88) 60%); }
.checkout-choice h2 { margin: 0 0 7px; font-size: 1.35rem; letter-spacing: -.035em; }
.checkout-choice p:not(.panel-kicker) { margin: 0; color: var(--muted); font-size: .86rem; }
.checkout-button { min-height: 45px; padding: 0 17px; flex: 0 0 auto; border: 1px solid #f7f3fa; border-radius: 9px; color: #1a1220; background: #f7f3fa; font-weight: 800; }
.checkout-button:hover:not(:disabled) { background: white; transform: translateY(-2px); }
.checkout-button:disabled { cursor: not-allowed; opacity: .58; }

@media (max-width: 760px) {
    .account-shell { width: min(100% - 28px, 520px); padding-top: 22px; }
    .account-card { grid-template-columns: 1fr; margin-top: 38px; }
    .account-intro { min-height: auto; padding: 38px 30px; border-right: 0; border-bottom: 1px solid var(--border); }
    .account-preview { margin-top: 31px; }
    .auth-panel { padding: 36px 30px; }
    .member-header { align-items: start; flex-direction: column; }
    .member-grid { grid-template-columns: 1fr; }
    .checkout-choice { align-items: start; flex-direction: column; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; } }

/* Workspace administrativo */
.workspace { margin-top: 28px; }
.workspace-topbar { align-items: center; margin-bottom: 18px; padding: 0 0 18px; border-bottom: 1px solid var(--border); }
.account-actions { display: flex; align-items: center; gap: 16px; }
.account-actions .member-email { margin: 0; }
.workspace-layout { display: grid; grid-template-columns: 210px minmax(0, 1fr); gap: 18px; }
.workspace-nav { align-self: start; position: sticky; top: 20px; padding: 12px; border: 1px solid var(--border); border-radius: 15px; background: rgba(16,16,22,.84); }
.workspace-nav-label { margin: 9px 10px 7px; color: #7f7887; font-size: .66rem; font-weight: 850; letter-spacing: .12em; }
.workspace-nav-label-lower { margin-top: 24px; }
.workspace-nav-item { display: block; width: 100%; min-height: 38px; padding: 0 10px; border: 0; border-radius: 8px; color: #bdb7c5; background: transparent; text-align: left; font-size: .86rem; font-weight: 700; }
.workspace-nav-item:hover { color: var(--text); background: rgba(255,255,255,.055); }
.workspace-nav-item.is-active { color: var(--text); background: rgba(149,1,216,.2); box-shadow: inset 2px 0 0 var(--primary-bright); }
.workspace-hub-link { display: block; margin: 22px 10px 8px; color: #e6c7f6; font-size: .78rem; font-weight: 750; text-decoration: none; }
.workspace-content { min-width: 0; padding: clamp(28px, 4vw, 48px); border: 1px solid var(--border); border-radius: 18px; background: rgba(16,16,22,.84); }
.workspace-view h1 { max-width: 640px; margin-bottom: 14px; font-size: clamp(2.4rem, 5.2vw, 4.6rem); }
.workspace-lead { max-width: 630px; margin: 0; color: var(--muted); font-size: 1rem; line-height: 1.62; }
.overview-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-top: 36px; }
.overview-card, .empty-panel { padding: 24px; border: 1px solid var(--border); border-radius: 14px; background: rgba(7,7,10,.5); }
.overview-card-accent { background: linear-gradient(150deg, rgba(149,1,216,.22), transparent 70%), rgba(7,7,10,.55); border-color: rgba(188,66,239,.35); }
.overview-card h2, .empty-panel h2 { font-size: 1.22rem; }
.overview-card p, .empty-panel p { color: var(--muted); font-size: .86rem; line-height: 1.57; }
.card-state { display: inline-block; margin-top: 13px; color: #e4b1fa; font-size: .66rem; font-weight: 850; letter-spacing: .1em; }
.empty-panel { max-width: 680px; margin-top: 34px; padding: clamp(26px, 5vw, 45px); }
.empty-symbol { display: grid; place-items: center; width: 38px; height: 38px; margin-bottom: 18px; border: 1px solid rgba(188,66,239,.46); border-radius: 10px; color: #e6a2ff; background: rgba(149,1,216,.16); font-weight: 900; }
.studio-form { display: grid; gap: 9px; margin-top: 25px; max-width: 480px; }
.studio-form label { margin: 5px 0 0; }.studio-form label span { color: #8f8799; font-weight: 500; }
.studio-form .portal-button { justify-self: start; margin-top: 9px; }.form-status { min-height: 1.5em; margin: 2px 0 0; color: var(--muted); font-size: .8rem; }.form-status.is-error { color: #ff9a9a; }.form-status.is-success { color: #91ed9f; }
.studio-list { display: grid; gap: 9px; margin-top: 24px; }.studio-list-item { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 14px; border: 1px solid var(--border); border-radius: 10px; background: rgba(255,255,255,.035); }.studio-list-item strong { font-size: .9rem; }.studio-list-item span { color: #aaa4b0; font-size: .76rem; }
.security-list { display: grid; gap: 0; max-width: 680px; margin-top: 35px; border: 1px solid var(--border); border-radius: 14px; overflow: hidden; }
.security-list > div { display: grid; grid-template-columns: 180px 1fr; gap: 18px; padding: 20px; border-bottom: 1px solid var(--border); background: rgba(7,7,10,.4); }
.security-list > div:last-child { border-bottom: 0; }
.security-list span { color: #8f8799; font-size: .68rem; font-weight: 850; letter-spacing: .1em; }
.security-list strong, .security-list a { color: #ded9e2; font-size: .9rem; text-decoration: none; }
.security-list a:hover { color: #f0ccff; }

@media (max-width: 820px) {
    .workspace-layout { grid-template-columns: 1fr; }
    .workspace-nav { position: static; display: flex; flex-wrap: wrap; gap: 4px; }
    .workspace-nav-label, .workspace-nav-label-lower { display: none; }
    .workspace-nav-item { width: auto; min-height: 35px; }
    .workspace-hub-link { margin: 8px; }
    .overview-grid { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
    .workspace-topbar { align-items: flex-start; flex-direction: column; }
    .account-actions { width: 100%; justify-content: space-between; }
    .workspace-content { padding: 29px 22px; }
    .security-list > div { grid-template-columns: 1fr; gap: 7px; }
}

/* Administração: densidade e hierarquia inspiradas em consoles de produto. */
.workspace { width: min(1440px, calc(100% - 32px)); margin-top: 18px; }
.workspace-topbar { height: 54px; margin: 0; padding: 0 4px 15px; border: 0; }
.workspace-breadcrumb { display: flex; align-items: center; gap: 9px; color: #aaa7b0; font-size: .82rem; }.workspace-breadcrumb strong { color: #efedf1; font-weight: 650; }.breadcrumb-divider { color: #5f5b64; }.workspace-dot { width: 9px; height: 9px; border-radius: 3px; background: #b43de7; box-shadow: 0 0 0 3px rgba(180,61,231,.14); }
.workspace-layout { grid-template-columns: 246px minmax(0, 1fr); gap: 0; min-height: calc(100vh - 120px); border: 1px solid #2a292e; border-radius: 10px; overflow: hidden; background: #141416; }
.workspace-nav { position: static; display: flex; flex-direction: column; min-height: 100%; padding: 13px 10px; border: 0; border-right: 1px solid #2a292e; border-radius: 0; background: #18181b; }
.workspace-brand { display: flex; align-items: center; gap: 9px; padding: 5px 9px 17px; color: #f4f2f5; font-size: .94rem; font-weight: 760; text-decoration: none; }.workspace-brand .brand-icon { width: 23px; height: 23px; border-radius: 6px; font-size: .78rem; }
.studio-context { display: flex; align-items: center; width: 100%; gap: 9px; min-height: 54px; padding: 8px; margin-bottom: 17px; border: 1px solid #34333a; border-radius: 7px; color: #f1eff3; background: #202024; text-align: left; }.studio-context:disabled { opacity: 1; cursor: default; }.studio-context-mark { display: grid; place-items: center; width: 27px; height: 27px; overflow: hidden; border: 1px solid #6d3b88; border-radius: 6px; color: #e4a5ff; background: #321c42; }.studio-context-mark img { width: 100%; height: 100%; object-fit: cover; }.studio-context small { display: block; margin-bottom: 2px; color: #8c8992; font-size: .57rem; font-weight: 800; letter-spacing: .09em; }
.workspace-nav-label { margin: 8px 10px 5px; color: #77747d; font-size: .59rem; }.workspace-nav-label-lower { margin-top: 22px; }.workspace-nav-item { display: flex; align-items: center; gap: 9px; min-height: 34px; padding: 0 9px; border-radius: 5px; color: #aaa7b0; font-size: .8rem; font-weight: 560; }.workspace-nav-item > span { width: 14px; color: #96929c; text-align: center; font-size: .9rem; }.workspace-nav-item:hover { color: #fff; background: #25252a; }.workspace-nav-item.is-active { color: #fff; background: #32213a; box-shadow: none; }.workspace-nav-item.is-active > span { color: #e2a4ff; }.workspace-hub-link { margin: auto 9px 5px; padding-top: 16px; border-top: 1px solid #302f34; color: #aeb0b7; font-size: .74rem; }
.workspace-nav-item.is-unavailable { opacity: .42; cursor: pointer; }.workspace-nav-item.is-unavailable:hover { color: #aaa7b0; background: transparent; }
.workspace-content { padding: clamp(28px, 4vw, 54px); border: 0; border-radius: 0; background: #141416; }.workspace-view h1 { color: #f7f5f7; font-size: clamp(2rem, 3.6vw, 3rem); letter-spacing: -.055em; }.workspace-lead { color: #a5a2aa; font-size: .9rem; }
.overview-metrics { display: grid; grid-template-columns: repeat(3, 1fr); margin-top: 31px; border: 1px solid #2e2d32; border-radius: 8px; overflow: hidden; background: #1a1a1d; }.overview-metrics article { min-height: 92px; padding: 17px 19px; border-right: 1px solid #2e2d32; }.overview-metrics article:last-child { border: 0; }.overview-metrics span { display: block; margin-bottom: 7px; color: #f6f4f6; font-size: 1.35rem; font-weight: 680; letter-spacing: -.05em; }.overview-metrics small { color: #89868e; font-size: .61rem; font-weight: 780; letter-spacing: .085em; }
.usage-metrics { grid-template-columns: repeat(4, 1fr); margin-top: 17px; }.usage-metrics article:last-child { border-right: 0; }
.overview-grid { grid-template-columns: repeat(3, minmax(0,1fr)); gap: 12px; margin-top: 14px; }.overview-card, .empty-panel { border-color: #302f35; border-radius: 8px; background: #1a1a1d; }.overview-card-accent { border-color: #5b3870; background: linear-gradient(135deg, rgba(149,1,216,.18), transparent 75%), #1a1a1d; }.overview-card h2, .empty-panel h2 { color: #f2f0f3; font-size: 1.05rem; }.overview-card p, .empty-panel p { color: #9b98a1; font-size: .82rem; }.card-action { min-height: 31px; margin-top: 13px; padding: 0 10px; border: 1px solid #403d45; border-radius: 5px; color: #ece9ef; background: #29282d; font-size: .75rem; font-weight: 680; }.card-action:hover { border-color: #7a4d90; background: #34223d; }
.member-panel, .checkout-choice { border-color: #302f35; border-radius: 8px; background: #1a1a1d; }.plan-panel { background: linear-gradient(135deg, rgba(149,1,216,.15), transparent 60%), #1a1a1d; }.empty-panel { margin-top: 28px; }.studio-list-item { border-color: #36343b; background: #202024; }.portal-button { border-radius: 5px; }.security-list { border-color: #302f35; border-radius: 8px; }.security-list > div { background: #1a1a1d; border-color: #302f35; }
@media (max-width: 820px) { .workspace { width: min(100% - 24px, 720px); }.workspace-layout { display: block; overflow: visible; }.workspace-nav { min-height: auto; border-right: 0; border-bottom: 1px solid #2a292e; }.workspace-brand, .studio-context { max-width: 290px; }.workspace-nav { flex-direction: row; flex-wrap: wrap; align-items: center; }.workspace-nav-label, .workspace-nav-label-lower { display: none; }.workspace-hub-link { margin: 8px; padding: 0; border: 0; }.overview-metrics { grid-template-columns: 1fr; }.overview-metrics article { min-height: 68px; border-right: 0; border-bottom: 1px solid #2e2d32; } }

/* O estado autenticado é o produto inteiro, não um cartão dentro da landing. */
html:has(#memberArea:not([hidden])) { background: #141416; }
body:has(#memberArea:not([hidden])) { background: #141416; }
body:has(#memberArea:not([hidden]))::before { display: none; }
.account-shell:has(#memberArea:not([hidden])) { width: 100%; min-height: 100vh; margin: 0; padding: 0; }
.account-loading { width: min(680px, calc(100% - 40px)); margin: clamp(64px, 14vh, 160px) auto; }
.profile-onboarding { width: min(620px, calc(100% - 40px)); margin: clamp(46px, 9vh, 100px) auto; padding: clamp(28px, 5vw, 48px); border: 1px solid #302f35; border-radius: 10px; background: linear-gradient(145deg, rgba(149,1,216,.16), transparent 45%), #1a1a1d; box-shadow: 0 25px 80px rgba(0,0,0,.25); }.profile-onboarding-brand { display: flex; align-items: center; gap: 9px; margin-bottom: 35px; color: #f5f2f6; font-size: .96rem; }.profile-onboarding-brand .brand-icon { width: 28px; height: 28px; font-size: .92rem; }.profile-onboarding h1 { max-width: 520px; margin-bottom: 14px; color: #f7f5f7; font-size: clamp(2rem, 5vw, 3.1rem); }.profile-onboarding > p:not(.eyebrow) { max-width: 530px; color: #aaa7b0; font-size: .92rem; line-height: 1.6; }.profile-form { display: grid; gap: 9px; margin-top: 29px; }.profile-form label { margin: 5px 0 0; }.profile-form label span { color: #8f8993; font-weight: 500; }.profile-form-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 10px; }.profile-form-actions .portal-button { margin-top: 0; }.profile-cancel-button { min-height: 44px; padding: 0 17px; border: 1px solid #514b57; border-radius: 7px; background: transparent; color: #ded9e2; font: inherit; cursor: pointer; }.profile-cancel-button:hover { border-color: #9a54b7; color: #fff; }.profile-privacy { margin: 6px 0 0; color: #8f8993; font-size: .72rem; line-height: 1.5; }.profile-privacy a { color: #dca5f3; }
.profile-avatar-field { display: flex; align-items: center; gap: 12px; }.profile-avatar-field img { width: 72px; height: 72px; border: 1px solid #4a3c50; border-radius: 50%; object-fit: cover; background: #101014; }.profile-avatar-field input { flex: 1; }
.workspace { width: 100%; min-height: 100vh; margin: 0; }
.workspace-topbar { height: 62px; padding: 0 24px; border-bottom: 1px solid #2a292e; background: #18181b; }
.workspace-layout { min-height: calc(100vh - 62px); border: 0; border-radius: 0; }
.studio-context { cursor: pointer; }.studio-context > span:nth-child(2) { min-width: 0; flex: 1; }.studio-context select { display: block; width: 100%; height: 19px; padding: 0 4px 0 0; border: 0; color: #f1eff3; background: transparent; font-size: .76rem; font-weight: 700; text-overflow: ellipsis; }.studio-context select:disabled { opacity: 1; cursor: default; }
textarea { width: 100%; min-height: 94px; padding: 11px 13px; border: 1px solid var(--border); border-radius: 7px; resize: vertical; color: var(--text); background: #101014; font: inherit; line-height: 1.45; } textarea:focus { border-color: var(--primary-bright); outline: none; }
.admin-detail-panel { max-width: 760px; margin-top: 16px; padding: 24px; border: 1px solid #302f35; border-radius: 8px; background: #1a1a1d; }.admin-detail-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; }.admin-detail-heading h2 { margin: 0; color: #f2f0f3; font-size: 1.1rem; }.role-chip { display: inline-flex; align-items: center; min-height: 23px; padding: 0 8px; border: 1px solid #4f3a5d; border-radius: 999px; color: #e0a6f5; background: #2b1d33; font-size: .61rem; font-weight: 800; letter-spacing: .08em; }
.admin-list { display: grid; gap: 8px; margin-top: 22px; }.admin-list-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; min-height: 54px; padding: 10px 12px; border: 1px solid #34333a; border-radius: 7px; background: #202024; }.admin-list-row > div:first-child { min-width: 0; }.admin-list-row strong, .admin-list-row span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }.admin-list-row strong { color: #f0edf2; font-size: .8rem; }.admin-list-row span { margin-top: 3px; color: #9b98a1; font-size: .7rem; }.row-controls { display: flex; align-items: center; gap: 7px; flex: 0 0 auto; }.compact-select { width: auto; height: 29px; padding: 0 24px 0 8px; border-radius: 5px; font-size: .72rem; }.row-button { min-height: 29px; padding: 0 8px; border: 1px solid #444149; border-radius: 5px; color: #e9e6eb; background: #29282d; font-size: .7rem; font-weight: 700; }.row-button:hover { border-color: #77717d; background: #333137; }.row-button-danger:hover { border-color: #9e4b5d; color: #ffc2cb; background: #42232b; }.admin-subsection { margin-top: 28px; }.admin-subsection .panel-kicker { margin-bottom: 0; }.activity-list { display: grid; gap: 0; margin-top: 19px; }.activity-list .admin-list-row { min-height: 42px; border-width: 0 0 1px; border-radius: 0; background: transparent; }.activity-list .admin-list-row:last-child { border-bottom: 0; }

@media (max-width: 820px) {
    .workspace { width: 100%; }
    .workspace-topbar { height: auto; min-height: 58px; padding: 12px 16px; }
    .workspace-layout { min-height: calc(100vh - 58px); }
    .admin-list-row { align-items: flex-start; flex-direction: column; }.row-controls { width: 100%; }.compact-select { flex: 1; }
    .profile-onboarding { width: min(100% - 24px, 620px); margin: 24px auto; }
}

/* Detalhes de uso diário do console. */
.workspace-topbar { display: flex; gap: 13px; }
.workspace-topbar-brand { display: inline-flex; align-items: center; gap: 8px; color: #f4f2f5; font-size: .94rem; font-weight: 760; text-decoration: none; }
.workspace-topbar-brand .brand-icon { width: 23px; height: 23px; border-radius: 6px; font-size: .78rem; }
.workspace-breadcrumb { margin-right: auto; }
.member-name { color: #f1eff3; font-size: .82rem; font-weight: 650; }
.member-role { margin-left: -8px; }
.theme-toggle { display: grid; place-items: center; width: 38px; min-height: 32px; padding: 0; border: 1px solid #3c3a41; border-radius: 5px; color: #d8d4dc; background: #232327; font: inherit; font-size: 1rem; }
.theme-toggle:hover { border-color: #67616d; background: #2c2b30; }
.studio-context select { color-scheme: dark; }
.studio-context select:focus, .studio-context select:focus-visible { outline: none; box-shadow: none; }
.studio-context select option { color: #f1eff3; background: #202024; }
.studio-icon-field { display: flex; align-items: center; gap: 10px; }.studio-icon-field input { flex: 1; }.studio-icon-field input[type=file] { min-height: 48px; padding: 7px 12px; line-height: 1.25; }.studio-icon-field input[type=file]::file-selector-button { margin-right: 10px; padding: 6px 9px; border: 1px solid #4a4750; border-radius: 4px; color: #f1eef4; background: #2a292e; font: inherit; font-size: .76rem; font-weight: 700; cursor: pointer; }.studio-icon-field img { width: 42px; height: 42px; flex: 0 0 auto; border: 1px solid #3b3940; border-radius: 8px; object-fit: cover; background: #101014; }
.field-note { margin: -1px 0 2px; color: #8f8993; font-size: .71rem; line-height: 1.45; }.icon-url-option { margin-top: 2px; color: #aaa6af; font-size: .75rem; }.icon-url-option summary { display: inline-flex; align-items: center; min-height: 31px; padding: 0 10px; border: 1px solid #48454e; border-radius: 5px; color: #d8d4dc; background: #242328; font-weight: 700; cursor: pointer; list-style: none; }.icon-url-option summary::-webkit-details-marker { display: none; }.icon-url-option summary::before { content: "▸"; margin-right: 7px; transition: transform .18s; }.icon-url-option[open] summary::before { transform: rotate(90deg); }.icon-url-option[open] summary { margin-bottom: 9px; }.icon-url-option input { margin-top: 0; }
.project-context { display: grid; gap: 7px; max-width: 480px; margin-top: 24px; }.project-context select { min-height: 39px; padding: 0 10px; border: 1px solid #3b3940; border-radius: 6px; color: #f1eff3; background: #101014; font: inherit; font-size: .82rem; }.project-image-field { display: flex; align-items: center; gap: 10px; }.project-image-field input { flex: 1; }.project-image-field img { width: 116px; height: 65px; flex: 0 0 auto; border: 1px solid #3b3940; border-radius: 7px; object-fit: cover; background: #101014; }
.project-profile-field { display: flex; align-items: center; gap: 10px; }.project-profile-field input { flex: 1; }.project-profile-field img { width: 52px; height: 52px; flex: 0 0 auto; border: 1px solid #3b3940; border-radius: 10px; object-fit: cover; background: #101014; }
.cloud-panel { max-width: 760px; }.cloud-connection-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 9px; margin-top: 20px; }.cloud-connection-actions[hidden] { display: none; }.cloud-switch { display: inline-flex; align-items: center; gap: 9px; min-height: 39px; padding: 0 11px; border: 1px solid #3b3940; border-radius: 6px; color: #ded9e2; background: #202024; font-size: .78rem; font-weight: 650; cursor: pointer; }.cloud-switch input { width: auto; accent-color: #b514f1; }
.danger-zone { max-width: 760px; margin-top: 16px; border: 1px solid rgba(233, 92, 104, .45); border-radius: 8px; background: linear-gradient(135deg, rgba(140, 37, 47, .17), transparent 72%), #1a1a1d; }.danger-zone summary { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 76px; padding: 17px 24px; cursor: pointer; list-style: none; }.danger-zone summary::-webkit-details-marker { display: none; }.danger-zone summary .panel-kicker { display: block; margin: 0 0 6px; }.danger-zone summary > span:first-child > strong { display: block; color: #ffe8ea; font-size: 1.05rem; }.danger-zone-toggle { color: #ffd6dc; font-size: .73rem; font-weight: 750; }.danger-zone[open] .danger-zone-toggle { font-size: 0; }.danger-zone[open] .danger-zone-toggle::after { content: "Recolher"; font-size: .73rem; }.danger-zone-body { padding: 0 24px 24px; }.danger-zone-body > p { max-width: 570px; color: #c7afb2; font-size: .82rem; line-height: 1.55; }.danger-zone form { display: grid; max-width: 480px; gap: 9px; margin-top: 19px; }.danger-zone label strong { color: #ffe3e7; }.danger-button { justify-self: start; min-height: 36px; margin-top: 4px; padding: 0 11px; border: 1px solid #a34b59; border-radius: 5px; color: #ffe9ec; background: #672c35; font: inherit; font-size: .76rem; font-weight: 750; }.danger-button:hover { background: #7c3541; }.danger-button:disabled { cursor: not-allowed; opacity: .55; }
.role-catalog { max-width: 760px; margin-top: 16px; padding: 24px; border: 1px solid #302f35; border-radius: 8px; background: #1a1a1d; }.role-catalog h2 { margin-bottom: 18px; color: #f2f0f3; font-size: 1.05rem; }.role-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; }.role-grid article { min-height: 128px; padding: 15px; border: 1px solid #36343b; border-radius: 7px; background: #202024; }.role-grid strong { color: #f2eff4; font-size: .82rem; }.role-grid p { margin: 8px 0 0; color: #9c98a2; font-size: .72rem; line-height: 1.48; }

body.is-light { --bg: #f7f7f9; --panel: #fff; --panel-deep: #f3f2f6; --text: #25222a; --muted: #65616b; --border: rgba(36, 33, 42, .14); color: #25222a; background: #f7f7f9; }
body.is-light::before { display: none; }
body.is-light .account-card { border-color: #dfdde3; background: #fff; box-shadow: 0 22px 55px rgba(33, 29, 40, .12); }
body.is-light .account-loading, body.is-light .account-intro { background: #f5f4f7; }
body.is-light .auth-panel { background: #fff; }
body.is-light .preview-line, body.is-light label { color: #3c3742; }
body.is-light .back-home { color: #65616b; }
body.is-light .workspace-topbar, body.is-light .workspace-nav { border-color: #e2e0e6; background: #fff; }
body.is-light .workspace-layout, body.is-light .workspace-content { background: #f9f9fb; }
body.is-light .workspace-nav { border-right-color: #e2e0e6; }
body.is-light .workspace-topbar-brand, body.is-light .workspace-view h1, body.is-light .overview-card h2, body.is-light .empty-panel h2, body.is-light .admin-detail-heading h2, body.is-light .member-name { color: #26232b; }
body.is-light .workspace-breadcrumb, body.is-light .workspace-lead, body.is-light .overview-card p, body.is-light .empty-panel p { color: #65616b; }
body.is-light .workspace-breadcrumb strong { color: #302c35; }
body.is-light .workspace-nav-item { color: #625d68; } body.is-light .workspace-nav-item.is-active { color: #fff; background: #32213a; }
body.is-light .studio-context, body.is-light .studio-list-item, body.is-light .overview-metrics, body.is-light .overview-card, body.is-light .empty-panel, body.is-light .admin-detail-panel, body.is-light .member-panel, body.is-light .security-list > div, body.is-light .admin-list-row { border-color: #dfdde3; background: #fff; }
body.is-light .overview-metrics article { border-color: #dfdde3; }
body.is-light .overview-metrics article span { color: #292530; }
body.is-light .overview-metrics article small { color: #696370; }
body.is-light .studio-context select, body.is-light .studio-context select option { color: #2e2934; background: #fff; color-scheme: light; }
body.is-light select, body.is-light select option { color: #292530; border-color: #d9d6df; background: #fff; color-scheme: light; }
body.is-light .studio-context small, body.is-light .workspace-nav-label { color: #77717d; }
body.is-light .studio-list-item strong, body.is-light .admin-list-row strong { color: #2e2934; }
body.is-light .theme-toggle { border-color: #d5d2da; color: #403b46; background: #f4f3f6; }
body.is-light .hub-link { color: #5a176e; text-decoration-color: rgba(90, 23, 110, .35); }
body.is-light .workspace-hub-link { color: #493f50; border-top-color: #ddd9e0; }
body.is-light input, body.is-light textarea { color: #292530; border-color: #d9d6df; background: #fff; }
body.is-light .studio-icon-field img { border-color: #d9d6df; background: #f3f2f6; }
body.is-light .studio-icon-field input[type=file]::file-selector-button { border-color: #d3ced8; color: #342e3a; background: #f0edf3; }
body.is-light .icon-url-option summary { border-color: #cdc7d1; color: #493f50; background: #f3f0f5; }
body.is-light .project-context select { border-color: #d9d6df; color: #292530; background: #fff; }.is-light .project-image-field img { border-color: #d9d6df; background: #f3f2f6; }

/* Console unificado: o estúdio vive na navegação e o projeto ativo no topo. */
.workspace { width: min(1520px, 100%); margin-top: 0; }
.workspace-topbar { display: grid; grid-template-columns: minmax(180px, .7fr) minmax(310px, 1.4fr) minmax(260px, .9fr); height: 68px; align-items: center; gap: 18px; padding: 0 22px; border-bottom: 1px solid #292d2d; background: #101314; }
.workspace-topbar-brand { color: #f5f3f6; font-size: 1rem; font-weight: 780; text-decoration: none; letter-spacing: -.03em; }
.workspace-contexts { display: flex; align-items: center; justify-content: center; gap: 14px; min-width: 0; }
.workspace-breadcrumb { flex: 0 0 auto; padding-right: 14px; border-right: 1px solid #343838; }
.workspace-project-context { display: flex; align-items: center; gap: 9px; min-width: 0; color: #9b9da4; font-size: .68rem; font-weight: 780; letter-spacing: .08em; white-space: nowrap; }
.workspace-project-context select { width: min(230px, 24vw); height: 34px; padding: 0 30px 0 10px; border: 1px solid #3a3e3e; border-radius: 6px; color: #f2f3f1; background: #1a1f20; font-size: .78rem; font-weight: 650; letter-spacing: 0; }
.account-actions { justify-content: flex-end; gap: 12px; }
.workspace-layout { min-height: calc(100vh - 68px); border: 0; border-radius: 0; background: #111516; }
.workspace-nav { padding: 17px 12px 13px; border-right-color: #292d2d; background: #0e1212; }
.studio-context { margin-bottom: 21px; border-color: #333a39; border-radius: 8px; background: linear-gradient(125deg, #202927, #171b1c); box-shadow: inset 0 1px rgba(255,255,255,.035); }
.workspace-nav-label { color: #737b7a; }
.workspace-nav-item:hover { background: #1c2221; }
.workspace-nav-item.is-active { background: linear-gradient(90deg, rgba(149,1,216,.28), rgba(149,1,216,.11)); box-shadow: inset 2px 0 0 #c34af2; }
.workspace-content { padding: clamp(30px, 4vw, 64px); background: #111516; }
.workspace-view { max-width: 1240px; }
.workspace-view .eyebrow { margin-bottom: 12px; color: #ce69f7; }
.workspace-view h1 { max-width: 760px; font-size: clamp(2rem, 3.2vw, 3.25rem); }
.overview-metrics { margin-top: 28px; border-color: #303635; background: #171c1c; box-shadow: 0 12px 32px rgba(0,0,0,.14); }
.overview-metrics article { padding: 20px 22px; border-right-color: #303635; }
.overview-metrics span { color: #f6f7f5; font-size: 1.55rem; }
.overview-metrics small { color: #989e9d; }
.overview-grid { gap: 14px; }
.overview-card, .empty-panel, .member-panel, .admin-detail-panel, .role-catalog { border-color: #303635; background: #171c1c; box-shadow: 0 9px 24px rgba(0,0,0,.1); }
.overview-card-accent { border-color: #704784; background: linear-gradient(135deg, rgba(149,1,216,.2), transparent 75%), #171c1c; }
.card-action { border-color: #414948; background: #232a29; }
.card-action:hover { border-color: #a758c8; background: #33223b; }

body.is-light .workspace-topbar { border-bottom-color: #dedfe1; background: #fff; }
body.is-light .workspace-layout, body.is-light .workspace-content { background: #f7f8f8; }
body.is-light .workspace-nav { border-right-color: #dedfe1; background: #fdfdfd; }
body.is-light .studio-context { border-color: #d9dcdf; background: #f6f7f8; }
body.is-light .workspace-project-context { color: #62666a; }
body.is-light .workspace-project-context select { border-color: #d6d9db; color: #292d30; background: #fff; }
body.is-light .overview-metrics, body.is-light .overview-card, body.is-light .empty-panel, body.is-light .member-panel, body.is-light .admin-detail-panel, body.is-light .role-catalog { border-color: #dfe1e3; background: #fff; box-shadow: 0 8px 20px rgba(32,37,39,.05); }
body.is-light .overview-card-accent { border-color: #d8bce5; background: linear-gradient(135deg, rgba(149,1,216,.09), transparent 75%), #fff; }
body.is-light .overview-metrics article { border-right-color: #dfe1e3; }
body.is-light .overview-metrics span { color: #25272a; }

@media (max-width: 920px) {
    .workspace-topbar { grid-template-columns: 1fr auto; height: auto; min-height: 64px; padding: 12px 16px; }
    .workspace-contexts { grid-column: 1 / -1; grid-row: 2; justify-content: flex-start; }
    .workspace-project-context select { width: min(290px, 50vw); }
}
@media (max-width: 560px) {
    .workspace-topbar { display: flex; flex-wrap: wrap; gap: 10px; }
    .workspace-contexts { width: 100%; justify-content: space-between; }
    .workspace-breadcrumb { display: none; }
    .workspace-project-context { flex: 1; justify-content: space-between; }
    .workspace-project-context select { width: min(72vw, 290px); }
}
body.is-light .project-profile-field img { border-color: #d9d6df; background: #f3f2f6; }
body.is-light .cloud-switch { border-color: #d9d6df; color: #332f38; background: #f4f2f6; }
body.is-light .danger-zone { border-color: #e7b7bd; background: #fffafa; }.is-light .danger-zone summary > span:first-child > strong { color: #792b35; }.is-light .danger-zone-toggle { color: #6c3942; }.is-light .danger-zone-body > p { color: #74575a; }.is-light .danger-zone label strong { color: #57262f; }
body.is-light .role-catalog, body.is-light .role-grid article { border-color: #dfdde3; background: #fff; }.is-light .role-catalog h2, .is-light .role-grid strong { color: #2d2933; }.is-light .role-grid p { color: #68636e; }

.production-role-list { display: grid; gap: 9px; margin-top: 18px; }
.production-member-row { display: grid; grid-template-columns: minmax(145px, .75fr) minmax(0, 2fr); gap: 16px; align-items: start; padding: 14px; border: 1px solid #36343b; border-radius: 7px; background: #202024; }
.production-member-row strong, .production-member-row small { display: block; }.production-member-row strong { color: #f3f0f5; font-size: .82rem; }.production-member-row small { margin-top: 4px; color: #96919d; font-size: .7rem; }
.production-role-checks { display: flex; flex-wrap: wrap; gap: 7px; }.production-role-option { display: inline-flex; align-items: center; gap: 6px; min-height: 30px; padding: 0 9px; border: 1px solid #40394a; border-radius: 999px; color: #d9d1df; background: #18171b; font-size: .7rem; cursor: pointer; }.production-role-option input { width: auto; min-height: auto; margin: 0; accent-color: #9501d8; }.production-role-option:has(input:checked) { border-color: #9b38d1; color: #fff; background: #321540; }
body.is-light .production-member-row { border-color: #dfdde3; background: #fff; } body.is-light .production-member-row strong { color: #2d2933; } body.is-light .production-role-option { border-color: #ddd6e3; color: #504a56; background: #faf9fc; } body.is-light .production-role-option:has(input:checked) { border-color: #9b38d1; color: #451460; background: #f6eaff; }
@media (max-width: 700px) { .production-member-row { grid-template-columns: 1fr; gap: 11px; } }

.role-catalog-editor { display: grid; gap: 10px; margin: 18px 0 12px; }.role-editor-card { padding: 14px; border: 1px solid #36343b; border-radius: 7px; background: #202024; }.role-editor-fields { display: grid; grid-template-columns: 1fr minmax(140px, 1.4fr) 66px; gap: 9px; }.role-editor-fields label { display: grid; gap: 5px; color: #aaa4b1; font-size: .67rem; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }.role-editor-fields input { min-height: 36px; padding: 0 8px; }.role-editor-fields input[type=color] { width: 100%; padding: 3px; }.role-permission-checks { display: flex; flex-wrap: wrap; gap: 7px; margin: 12px 0; }.role-permission-checks label { display: inline-flex; align-items: center; gap: 5px; color: #c8c2cc; font-size: .7rem; }.role-permission-checks input { width: auto; min-height: auto; margin: 0; accent-color: #9501d8; }.role-editor-card .row-button { margin-top: 2px; }
body.is-light .role-editor-card { border-color: #dfdde3; background: #fff; } body.is-light .role-editor-fields label, body.is-light .role-permission-checks label { color: #625c69; }
@media (max-width: 700px) { .role-editor-fields { grid-template-columns: 1fr; } .role-editor-fields input[type=color] { width: 66px; } }
@media (max-width: 720px) { .role-grid { grid-template-columns: 1fr; }.role-grid article { min-height: auto; } }
@media (max-width: 820px) { .workspace-topbar { gap: 9px; }.workspace-breadcrumb { margin-right: 0; }.account-actions { margin-left: auto; }.member-name { display: none; } }

/* Integrações ficam agrupadas no painel e são configuradas sem trocar de contexto. */
.integration-modal { position: fixed; z-index: 50; inset: 0; display: grid; place-items: center; padding: 18px; }
.integration-modal[hidden] { display: none; }
.integration-modal-backdrop { position: absolute; inset: 0; background: rgba(5, 4, 8, .72); backdrop-filter: blur(5px); }
.integration-modal-dialog { position: relative; width: min(920px, 100%); max-height: min(860px, calc(100vh - 36px)); overflow: auto; border: 1px solid #3a3740; border-radius: 10px; background: #141416; box-shadow: 0 28px 90px rgba(0, 0, 0, .58); }
.integration-modal-header { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 18px 22px; border-bottom: 1px solid #302f35; background: #1a1a1d; }.integration-modal-header .panel-kicker { margin-bottom: 5px; }.integration-modal-header h2 { margin: 0; color: #f4f2f5; font-size: 1.05rem; }.integration-modal-close { display: grid; place-items: center; width: 32px; height: 32px; border: 1px solid #48454e; border-radius: 5px; color: #ebe8ee; background: #29282d; font-size: 1.35rem; line-height: 1; }.integration-modal-close:hover { border-color: #77717d; background: #343238; }
.integration-modal-body { padding: 26px; }.integration-modal-body .workspace-view { padding: 0; }.integration-modal-body .workspace-view h1 { max-width: none; font-size: clamp(1.7rem, 4vw, 2.35rem); }.integration-modal-body .workspace-lead { max-width: 720px; }.integration-modal-body .cloud-panel { max-width: none; }.integration-modal-body .admin-detail-panel:first-of-type { margin-top: 25px; }
body.has-integration-modal { overflow: hidden; }
body.is-light .integration-modal-backdrop { background: rgba(34, 29, 40, .32); }.is-light .integration-modal-dialog { border-color: #d8d4dd; background: #f9f9fb; box-shadow: 0 28px 75px rgba(33, 29, 40, .22); }.is-light .integration-modal-header { border-color: #dfdde3; background: #fff; }.is-light .integration-modal-header h2 { color: #292530; }.is-light .integration-modal-close { border-color: #d2ced7; color: #403b46; background: #f1eff4; }
@media (max-width: 620px) { .integration-modal { padding: 10px; }.integration-modal-dialog { max-height: calc(100vh - 20px); }.integration-modal-header { padding: 15px 16px; }.integration-modal-body { padding: 22px 16px; } }

/* A navegação é o único cabeçalho do painel. Em telas amplas ela abre ao
   passar o mouse (ou navegar pelo teclado) e mantém só os ícones em repouso. */
body.is-workspace .account-shell { width: 100%; max-width: none; margin: 0; padding: 0; }
body.is-workspace .member-area { margin-top: 0; }
.workspace { width: 100%; }
.workspace-layout, .workspace-layout:has(.workspace-nav:hover), .workspace-layout:has(.workspace-nav:focus-within) { grid-template-columns: minmax(0, 1fr); min-height: 100vh; overflow: visible; }
.workspace-nav { position: fixed; inset: 0 auto 0 0; grid-area: 1 / 1; z-index: 3; width: 76px; height: 100vh; height: 100dvh; overflow-x: hidden; overflow-y: auto; overscroll-behavior-y: contain; scrollbar-width: thin; padding: 14px 12px; transition: width .22s ease, padding .22s ease; }
.workspace-nav:hover, .workspace-nav:focus-within { width: 268px; }
.workspace-content { grid-area: 1 / 1; width: 100%; }
.workspace-view { margin-inline: auto; }
.workspace-brand { min-height: 54px; padding: 2px 5px 20px; gap: 12px; font-size: 1.13rem; white-space: nowrap; }
.workspace-brand img { display: block; width: 44px; height: 44px; flex: 0 0 44px; border-radius: 12px; }
.workspace-nav .nav-icon, .workspace-nav-item > .nav-icon { display: grid; place-items: center; width: 32px; min-width: 32px; height: 32px; color: #aaaeb2; font-size: .97rem; line-height: 1; text-align: center; }
.workspace-nav-item { gap: 8px; min-height: 40px; padding: 4px 7px; white-space: nowrap; }
.workspace-nav-item > .nav-icon { margin-left: 0; }
.workspace-nav-item.is-active > .nav-icon { color: #e8adff; }
.workspace-hub-link { display: flex; align-items: center; gap: 8px; min-height: 42px; margin: auto 1px 8px; padding: 8px 7px; border-top: 1px solid #302f34; white-space: nowrap; }
.workspace-nav-label { min-height: 22px; margin: 13px 8px 5px; white-space: nowrap; }
.workspace-nav-label-lower { margin-top: 18px; }
.studio-context, .project-context-sidebar { display: flex; align-items: center; width: 100%; gap: 9px; min-height: 54px; margin: 0 0 12px; padding: 8px; border: 1px solid #343a39; border-radius: 8px; color: #f1eff3; background: #1b2120; cursor: pointer; white-space: nowrap; }
.project-context-sidebar .nav-copy, .studio-context > span:nth-child(2) { display: block; min-width: 0; flex: 1; overflow: hidden; }
.project-context-sidebar small { display: block; margin-bottom: 2px; color: #8c9292; font-size: .57rem; font-weight: 800; letter-spacing: .09em; }
.project-context-sidebar select { display: block; width: 100%; height: 19px; padding: 0 4px 0 0; border: 0; color: #f1eff3; background: transparent; font: inherit; font-size: .76rem; font-weight: 700; text-overflow: ellipsis; }
.project-context-sidebar select:focus, .project-context-sidebar select:focus-visible { outline: none; box-shadow: none; }
.sidebar-account-actions { display: grid; gap: 5px; margin-top: 14px; padding-top: 13px; border-top: 1px solid #302f34; }
.sidebar-account-actions .member-name { min-height: 18px; padding: 0 8px; color: #e8e7e9; font-size: .78rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sidebar-account-actions .member-role { justify-self: start; margin-left: 8px; }
.sidebar-account-actions .theme-toggle, .sidebar-account-actions .signout-button { display: flex; align-items: center; gap: 8px; width: 100%; min-height: 40px; padding: 4px 7px; border: 0; border-radius: 5px; color: #aaaeb2; background: transparent; font-size: .8rem; font-weight: 600; text-align: left; white-space: nowrap; }
.sidebar-account-actions .theme-toggle:hover, .sidebar-account-actions .signout-button:hover { color: #fff; background: #1c2221; }
.sidebar-account-actions .theme-icon { display: grid; place-items: center; width: 32px; min-width: 32px; height: 32px; font-size: .9rem; }
.sidebar-account-actions .signout-button .nav-icon { color: inherit; }

@media (min-width: 821px) {
    .workspace-nav:not(:hover):not(:focus-within) .nav-copy,
    .workspace-nav:not(:hover):not(:focus-within) .studio-context > span:nth-child(2),
    .workspace-nav:not(:hover):not(:focus-within) .workspace-nav-label { width: 0; max-width: 0; min-width: 0; margin-left: 0; margin-right: 0; padding: 0; overflow: hidden; opacity: 0; pointer-events: none; }
    .workspace-nav:not(:hover):not(:focus-within) .workspace-brand { padding-left: 4px; }
    .workspace-nav:not(:hover):not(:focus-within) .studio-context, .workspace-nav:not(:hover):not(:focus-within) .project-context-sidebar { width: 48px; padding: 8px; }
    .workspace-nav:not(:hover):not(:focus-within) .studio-context-mark { width: 30px; height: 30px; }
    .workspace-nav:not(:hover):not(:focus-within) .workspace-hub-link { margin-left: 0; margin-right: 0; }
    .workspace-nav:not(:hover):not(:focus-within) .sidebar-account-actions .member-role { display: none; }
}

body.is-light .workspace-nav { background: #fff; }
body.is-light .workspace-brand { color: #292d30; }
body.is-light .studio-context, body.is-light .project-context-sidebar { border-color: #d9dcdf; color: #292d30; background: #f6f7f8; }
body.is-light .project-context-sidebar small { color: #73797d; }
body.is-light .project-context-sidebar select { color: #292d30; background: transparent; color-scheme: light; }
body.is-light .sidebar-account-actions { border-top-color: #e0e2e4; }
body.is-light .sidebar-account-actions .member-name { color: #292d30; }
body.is-light .sidebar-account-actions .theme-toggle, body.is-light .sidebar-account-actions .signout-button { color: #60666a; }
body.is-light .sidebar-account-actions .theme-toggle:hover, body.is-light .sidebar-account-actions .signout-button:hover { color: #292d30; background: #edf0f0; }

@media (max-width: 820px) {
    .workspace-layout { display: block; min-height: auto; }
    .workspace-nav { position: static; inset: auto; display: flex; width: 100%; height: auto; max-height: none; flex-direction: row; flex-wrap: wrap; align-items: center; overflow: visible; border-right: 0; }
    .workspace-brand, .studio-context, .project-context-sidebar { width: min(100%, 300px); margin-right: 8px; }
    .workspace-nav-item, .workspace-hub-link, .sidebar-account-actions .theme-toggle, .sidebar-account-actions .signout-button { width: auto; }
    .workspace-nav-label { display: none; }
    .sidebar-account-actions { display: flex; align-items: center; margin: 0 0 0 auto; padding: 0; border: 0; }
    .sidebar-account-actions .member-name, .sidebar-account-actions .member-role { display: none; }
}

/* Tasks web: quadro colaborativo inicial para os projetos online. */
.tasks-workspace-view { max-width: 1500px; }
.tasks-create-panel { margin: 24px 0 16px; padding: 18px; border: 1px solid #34343a; border-radius: 10px; background: #19191d; }
.tasks-create-form { display: grid; grid-template-columns: minmax(180px, 1.2fr) minmax(150px, .7fr) minmax(180px, 1fr) auto; gap: 10px; }
.tasks-create-form input, .tasks-create-form select { width: 100%; min-height: 42px; padding: 0 12px; border: 1px solid #393940; border-radius: 6px; color: #f0edf3; background: #111114; font: inherit; }
.tasks-create-form .portal-button { min-height: 42px; white-space: nowrap; }
.tasks-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 20px 0 10px; color: #aaa6b0; font-size: .8rem; }
.tasks-board { display: grid; grid-template-columns: repeat(4, minmax(220px, 1fr)); align-items: start; gap: 12px; overflow-x: auto; padding-bottom: 12px; }
.tasks-column { min-height: 270px; padding: 12px; border: 1px solid #2e2d34; border-radius: 9px; background: #161619; }
.tasks-column-heading { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 0 0 12px; }
.tasks-column-heading h2 { margin: 0; color: #f0edf3; font-size: .9rem; }
.tasks-column-heading span { display: grid; place-items: center; min-width: 24px; height: 24px; border-radius: 99px; color: #c3bdca; background: #29272e; font-size: .72rem; }
.tasks-column-todo { border-top: 2px solid #827d88; }.tasks-column-in_progress { border-top: 2px solid #ac74db; }.tasks-column-review { border-top: 2px solid #e6b84a; }.tasks-column-done { border-top: 2px solid #58b58c; }
.task-card { display: grid; gap: 9px; margin: 0 0 9px; padding: 12px; border: 1px solid #35343c; border-radius: 7px; background: #202024; }
.task-card > strong { color: #f2eff4; font-size: .84rem; line-height: 1.35; overflow-wrap: anywhere; }
.task-card > p { margin: 0; color: #aaa6b0; font-size: .76rem; line-height: 1.45; white-space: pre-wrap; overflow-wrap: anywhere; }
.task-card-meta { display: flex; align-items: center; justify-content: space-between; gap: 8px; color: #aaa6b0; font-size: .7rem; }
.task-status-select { max-width: 125px; min-height: 29px; padding: 3px 6px; border: 1px solid #403e46; border-radius: 5px; color: #ded9e2; background: #17171a; font: inherit; }
.tasks-column-empty { padding: 18px 6px; color: #76727b; font-size: .76rem; text-align: center; }
body.is-light .tasks-create-panel, body.is-light .tasks-column { border-color: #dedbe3; background: #fff; }
body.is-light .tasks-create-form input, body.is-light .tasks-create-form select, body.is-light .task-status-select { border-color: #d8d4dd; color: #292530; background: #faf9fb; }
body.is-light .tasks-column-heading h2, body.is-light .task-card > strong { color: #292530; }
body.is-light .task-card { border-color: #e1dde5; background: #fbfafc; }
body.is-light .tasks-column-heading span { color: #554f5b; background: #eeeaf1; }
@media (max-width: 1050px) { .tasks-create-form { grid-template-columns: 1fr 1fr; }.tasks-board { grid-template-columns: repeat(4, minmax(235px, 1fr)); } }
@media (max-width: 620px) { .tasks-create-form { grid-template-columns: 1fr; }.tasks-board { grid-template-columns: repeat(4, minmax(245px, 1fr)); }.tasks-create-panel { padding: 13px; } }

/* Tasks: abas leves e ações pontuais em diálogos para manter o quadro livre. */
.tasks-tabs { display: flex; gap: 8px; margin: 25px 0 22px; border-bottom: 1px solid #34333a; }
.tasks-tabs button { min-height: 42px; padding: 0 16px; border: 1px solid transparent; border-radius: 8px 8px 0 0; color: #aaa6b0; background: transparent; font: inherit; font-size: .87rem; font-weight: 700; cursor: pointer; }
.tasks-tabs button.is-active { border-color: #34333a; border-bottom-color: #17171a; color: #f2eff5; background: #202024; }
.tasks-view-heading { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin: 0 0 14px; }
.tasks-view-heading h2 { margin: 0 0 4px; color: #efedf1; font-size: 1.05rem; }
.tasks-view-heading p { margin: 0; color: #95919b; font-size: .76rem; }
.tasks-heading-actions { display: flex; align-items: center; gap: 8px; }
.tasks-heading-actions button, .tasks-board-toolbar > button { min-height: 36px; padding-inline: 12px; }
.tasks-sprints { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 12px; margin-bottom: 29px; }
.tasks-sprint-card { min-width: 0; padding: 15px; border: 1px solid #33323a; border-radius: 9px; background: #1c1c20; }
.tasks-sprint-card-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.tasks-sprint-card h3 { margin: 0 0 4px; color: #f1eef4; font-size: .9rem; }
.tasks-sprint-card-header p, .tasks-sprint-goal { margin: 0; color: #a5a1aa; font-size: .73rem; line-height: 1.45; }
.tasks-sprint-goal { margin-top: 10px; }
.tasks-sprint-count { flex: 0 0 auto; padding: 5px 8px; border-radius: 99px; color: #d7b7eb; background: #352742; font-size: .68rem; }
.tasks-sprint-task-list { display: grid; gap: 5px; margin-top: 12px; }
.tasks-sprint-task-list > small { padding: 3px 8px; color: #89848f; }
.tasks-backlog-heading { padding-top: 4px; }
.tasks-backlog-list { display: grid; gap: 7px; max-width: 920px; }
.tasks-backlog-item { display: grid; grid-template-columns: minmax(0, 1fr) auto 18px; align-items: center; gap: 12px; width: 100%; min-height: 51px; padding: 10px 13px; border: 1px solid #33323a; border-radius: 7px; color: #efedf1; background: #1c1c20; text-align: left; cursor: pointer; }
.tasks-backlog-item:hover, .task-card-open:hover { border-color: #795394; background: #242129; }
.tasks-backlog-item strong { overflow: hidden; font-size: .8rem; text-overflow: ellipsis; white-space: nowrap; }
.tasks-backlog-item > span:nth-child(2) { color: #aaa6b0; font-size: .7rem; }
.tasks-item-arrow { color: #b482d4; font-size: 1.2rem; }
.tasks-empty-state { margin: 0; padding: 22px 16px; border: 1px dashed #3a3840; border-radius: 8px; color: #908b95; font-size: .78rem; text-align: center; }
.tasks-board-toolbar { display: flex; align-items: center; gap: 12px; margin: 6px 0 14px; }
.tasks-search { display: flex; align-items: center; gap: 8px; width: min(330px, 44vw); min-height: 36px; padding: 0 10px; border: 1px solid #393840; border-radius: 6px; color: #9a95a0; background: #19191d; }
.tasks-search input { width: 100%; min-width: 0; border: 0; outline: 0; color: #f2eff5; background: transparent; font: inherit; font-size: .76rem; }
.tasks-mine-filter { display: flex; align-items: center; gap: 7px; margin-right: auto; color: #c5c1ca; font-size: .75rem; cursor: pointer; }
.tasks-mine-filter input { accent-color: #a857dc; color-scheme: dark; }
.tasks-board { display: grid; grid-template-columns: repeat(4, minmax(215px, 1fr)); align-items: start; gap: 12px; overflow-x: auto; padding-bottom: 12px; }
.tasks-column { min-height: 240px; padding: 11px; border: 1px solid #2e2d34; border-radius: 9px; background: #161619; }
.tasks-column-heading { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 0 0 12px; }
.tasks-column-heading h2 { margin: 0; color: #f0edf3; font-size: .8rem; font-weight: 700; }
.tasks-column-heading span { display: grid; place-items: center; min-width: 23px; height: 23px; border-radius: 99px; color: #c3bdca; background: #29272e; font-size: .68rem; }
.tasks-column-todo { border-top: 2px solid #827d88; }.tasks-column-in_progress { border-top: 2px solid #ac74db; }.tasks-column-review { border-top: 2px solid #e6b84a; }.tasks-column-done { border-top: 2px solid #58b58c; }
.task-card { display: grid; gap: 8px; margin: 0 0 8px; padding: 9px; border: 1px solid #33323a; border-radius: 7px; background: #202024; }
.task-card-open { display: grid; gap: 5px; width: 100%; padding: 3px; border: 1px solid transparent; border-radius: 5px; color: inherit; background: transparent; text-align: left; cursor: pointer; }
.task-card-open strong { color: #f2eff4; font-size: .79rem; line-height: 1.35; overflow-wrap: anywhere; }
.task-card-open span { display: -webkit-box; overflow: hidden; color: #aaa6b0; font-size: .67rem; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.task-card-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 7px; color: #aaa6b0; font-size: .65rem; }
.task-priority-chip { padding: 3px 7px; border-radius: 99px; color: #d6b9e8; background: #352742; }
.task-acceptance-progress { color: #a9a3ae; font-size: .65rem; }
.tasks-column-empty { padding: 18px 6px; color: #76727b; font-size: .72rem; text-align: center; }
.tasks-global-status { min-height: 20px; margin-top: 9px; }
.tasks-modal { width: min(610px, calc(100vw - 28px)); max-height: min(90vh, 850px); overflow: auto; padding: 0; border: 1px solid #45414b; border-radius: 11px; color: #f0edf3; background: #1a1a1e; box-shadow: 0 28px 90px rgba(0, 0, 0, .65); }
.tasks-modal::backdrop { background: rgba(5, 4, 8, .72); backdrop-filter: blur(4px); }
.tasks-modal > form { padding: 20px; }
.tasks-modal-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 17px; padding-bottom: 14px; border-bottom: 1px solid #35333b; }
.tasks-modal-header .panel-kicker { margin: 0 0 4px; color: #b68bd0; font-size: .61rem; }
.tasks-modal-header h2 { margin: 0; color: #f2eff5; font-size: 1.06rem; }
.tasks-modal-close { display: grid; place-items: center; flex: 0 0 30px; width: 30px; height: 30px; border: 1px solid #48454e; border-radius: 50%; color: #eeeaf2; background: #28272c; font-size: 1.2rem; line-height: 1; cursor: pointer; }
.tasks-modal-fields { display: grid; gap: 12px; }
.tasks-modal-fields label { display: grid; gap: 6px; color: #c3bec9; font-size: .72rem; font-weight: 700; }
.tasks-modal-fields input, .tasks-modal-fields select, .tasks-modal-fields textarea { width: 100%; min-height: 39px; padding: 9px 10px; border: 1px solid #393840; border-radius: 6px; color: #f0edf3; background: #111114; font: inherit; font-size: .78rem; }
.tasks-modal-fields textarea { resize: vertical; }
.tasks-modal-field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 11px; }
.tasks-modal-actions { display: flex; justify-content: flex-end; gap: 9px; margin-top: 16px; padding-top: 13px; border-top: 1px solid #35333b; }
.tasks-modal-actions button { min-height: 36px; padding: 0 14px; }
.tasks-detail-modal { width: min(940px, calc(100vw - 28px)); }
.tasks-detail-modal > .tasks-modal-header { margin: 0 20px; padding-top: 19px; }
.tasks-detail-layout { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(235px, .75fr); min-height: 380px; }
.tasks-detail-layout > form { min-width: 0; padding: 0 20px 18px; }
.tasks-comments { display: flex; flex-direction: column; justify-content: space-between; min-width: 0; padding: 17px; border-left: 1px solid #33313a; background: #121215; }
.tasks-comments .panel-kicker { margin: 0 0 12px; color: #a9a3ae; font-size: .63rem; font-weight: 800; letter-spacing: .08em; }
.tasks-comment-list { display: grid; align-content: start; gap: 11px; max-height: 390px; overflow: auto; }
.tasks-comment { padding: 9px 10px; border: 1px solid #302e36; border-radius: 7px; background: #1c1b20; }
.tasks-comment > div { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.tasks-comment strong { color: #ebe7ee; font-size: .68rem; }.tasks-comment time { color: #817c87; font-size: .6rem; }
.tasks-comment p { margin: 6px 0 0; color: #c0bbc5; font-size: .72rem; line-height: 1.45; white-space: pre-wrap; overflow-wrap: anywhere; }
.tasks-comment-composer { display: flex; align-items: center; gap: 6px; margin-top: 12px; padding: 4px; border: 1px solid #38363f; border-radius: 99px; background: #1d1c21; }
.tasks-comment-composer input { width: 100%; min-width: 0; height: 31px; padding: 0 9px; border: 0; outline: 0; color: #eeeaf2; background: transparent; font: inherit; font-size: .68rem; }
.tasks-comment-composer button { display: grid; place-items: center; flex: 0 0 28px; width: 28px; height: 28px; border: 0; border-radius: 50%; color: #fff; background: #893db2; cursor: pointer; }
.tasks-comment-status { margin: 4px 8px; font-size: .64rem; }
body.is-light .tasks-tabs { border-color: #dedbe3; } body.is-light .tasks-tabs button { color: #625c69; } body.is-light .tasks-tabs button.is-active { border-color: #dedbe3; border-bottom-color: #fff; color: #292530; background: #fff; }
body.is-light .tasks-sprint-card, body.is-light .tasks-backlog-item, body.is-light .task-card { border-color: #dfdce4; background: #fff; }
body.is-light .tasks-sprint-card h3, body.is-light .tasks-view-heading h2, body.is-light .tasks-backlog-item, body.is-light .task-card-open strong { color: #292530; }
body.is-light .tasks-search, body.is-light .tasks-column { border-color: #dedbe3; background: #f8f7f9; }
body.is-light .tasks-search input, body.is-light .task-assignee-select, body.is-light .task-status-select { color: #292530; }
body.is-light .tasks-modal { border-color: #d8d4dd; color: #292530; background: #f9f9fb; }
body.is-light .tasks-modal-header h2 { color: #292530; } body.is-light .tasks-modal-fields label { color: #625c69; }
body.is-light .tasks-modal-fields input, body.is-light .tasks-modal-fields select, body.is-light .tasks-modal-fields textarea { border-color: #d8d4dd; color: #292530; background: #fff; }
body.is-light .tasks-comments { border-color: #dedbe3; background: #f1eff4; } body.is-light .tasks-comment { border-color: #dedbe3; background: #fff; } body.is-light .tasks-comment strong { color: #292530; } body.is-light .tasks-comment p { color: #625c69; }
@media (max-width: 850px) { .tasks-board { grid-template-columns: repeat(4, minmax(235px, 1fr)); }.tasks-detail-layout { grid-template-columns: 1fr; }.tasks-comments { border-top: 1px solid #33313a; border-left: 0; } }
@media (max-width: 560px) { .tasks-view-heading { align-items: flex-start; }.tasks-view-heading p { max-width: 240px; }.tasks-heading-actions { gap: 6px; }.tasks-heading-actions button { padding-inline: 8px; }.tasks-backlog-item { grid-template-columns: minmax(0, 1fr) 18px; }.tasks-backlog-item > span:nth-child(2) { display: none; }.tasks-board-toolbar { flex-wrap: wrap; }.tasks-search { width: 100%; }.tasks-mine-filter { margin-right: auto; }.tasks-modal-field-row { grid-template-columns: 1fr; }.tasks-modal > form { padding: 16px; }.tasks-detail-layout > form { padding: 0 16px 16px; } }

/* Tasks: backlog em formato de deck, sprints verticais e destinos claros de arraste. */
.tasks-view[data-tasks-view="backlog"] { display: flex; height: calc(100dvh - 350px); min-height: 310px; flex-direction: column; }
.tasks-view[hidden] { display: none !important; }
.tasks-view[data-tasks-view="backlog"] > .tasks-view-heading:first-child { flex: 0 0 auto; }
.tasks-sprints { display: flex; flex-direction: column; gap: 9px; margin-bottom: 20px; }
.tasks-view[data-tasks-view="backlog"] .tasks-sprints { min-height: 0; flex: 1 1 0; overflow-x: hidden; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; }
.tasks-sprint-card { min-height: 58px; flex: 0 0 auto; padding: 0; overflow: hidden; }
.tasks-sprint-summary { display: flex; align-items: center; gap: 11px; min-height: 58px; padding: 11px 14px; list-style: none; cursor: pointer; }
.tasks-sprint-summary::-webkit-details-marker { display: none; }
.tasks-sprint-summary::after { content: "⌄"; margin-left: auto; color: #aaa6b0; transition: transform .15s ease; }
.tasks-sprint-card:not([open]) .tasks-sprint-summary::after { transform: rotate(-90deg); }
.tasks-sprint-info { display: grid; gap: 3px; min-width: 0; }
.tasks-sprint-info strong { color: #f1eef4; font-size: .88rem; }
.tasks-sprint-info small { color: #a5a1aa; font-size: .7rem; }
.tasks-delete-button { min-height: 31px; padding: 0 10px; border: 1px solid #63353a; border-radius: 6px; color: #f0a4a8; background: #291a1d; font: inherit; font-size: .7rem; cursor: pointer; }
.tasks-delete-button:hover { border-color: #9c4e55; color: #ffd5d7; background: #3a2024; }
.tasks-sprint-delete { flex: 0 0 auto; min-height: 28px; padding-inline: 8px; }
.tasks-sprint-actions { display: flex; justify-content: flex-end; padding: 0 13px 8px; }
.tasks-complete-button { min-height: 30px; padding: 0 10px; border: 1px solid #426b58; border-radius: 6px; color: #a8e0bd; background: #19271f; font: inherit; font-size: .7rem; font-weight: 700; cursor: pointer; }
.tasks-complete-button:hover { border-color: #5f9d7c; background: #20392b; }
.tasks-completed-badge { flex: 0 0 auto; padding: 5px 8px; border: 1px solid #426b58; border-radius: 99px; color: #a8e0bd; background: #19271f; font-size: .65rem; font-weight: 750; }
.tasks-sprint-completed-date { color: #91c9a7 !important; }
.tasks-delete-button:disabled { opacity: .55; cursor: wait; }
.tasks-sprint-drag { display: grid; place-items: center; width: 27px; height: 29px; border: 1px solid #393740; border-radius: 6px; color: #aaa3b2; cursor: grab; }
.tasks-sprint-goal { margin: 0 14px 10px 52px; }
.tasks-sprint-task-list { min-height: 70px; margin: 0 12px 12px; padding: 8px; border: 1px dashed #3a3841; border-radius: 8px; }
.tasks-drop-hint { display: grid; place-items: center; min-height: 48px; margin: 0; color: #85808b; font-size: .72rem; text-align: center; }
.tasks-backlog-deck { min-height: 57px; flex: 0 0 auto; margin-top: 4px; border: 1px solid #37353d; border-radius: 9px; background: #1a191e; overflow: hidden; }
.tasks-backlog-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 57px; margin: 0; padding: 9px 14px; list-style: none; cursor: pointer; }
.tasks-backlog-heading::-webkit-details-marker { display: none; }
.tasks-backlog-heading > span { display: grid; gap: 3px; }
.tasks-backlog-heading strong { color: #f1eef4; font-size: .9rem; }
.tasks-backlog-heading small { color: #9e99a4; font-size: .69rem; }
.tasks-backlog-resize { height: min(22vh, 210px); min-height: 100px; max-height: 32vh; flex: 0 0 auto; overflow: auto; resize: vertical; padding: 0 12px 12px; }
.tasks-backlog-list { max-width: none; min-height: 76px; padding: 8px; border: 1px dashed #3a3841; border-radius: 8px; }
.tasks-backlog-item { min-height: 46px; }
.tasks-backlog-item[draggable="true"], .task-card-open[draggable="true"] { cursor: grab; }
.tasks-backlog-item:active, .task-card-open:active, .tasks-sprint-drag:active { cursor: grabbing; }
.tasks-drop-placeholder { display: flex; align-items: center; min-height: 51px; margin: 3px 0; padding: 10px 13px; border: 1px dashed #bb83df; border-radius: 7px; color: #d8b8ed; background: rgba(137, 61, 178, .14); font-size: .73rem; }
.tasks-dropzone.is-drop-target { border-color: #a967d2; background-color: rgba(137, 61, 178, .1); }
.tasks-sprint-card.is-drop-target { outline: 2px dashed #a967d2; outline-offset: 2px; }
.tasks-sprint-picker { display: flex; align-items: center; gap: 7px; color: #c5c1ca; font-size: .74rem; }
.tasks-sprint-picker select { min-height: 36px; max-width: 190px; padding: 0 9px; border: 1px solid #393840; border-radius: 6px; color: #f2eff5; background: #19191d; font: inherit; }
.tasks-column { display: flex; flex-direction: column; }
.tasks-column .task-card { cursor: grab; }
.tasks-column .task-card-open { cursor: grab; }
body.is-light .tasks-backlog-deck { border-color: #dedbe3; background: #fff; }
body.is-light .tasks-backlog-heading strong, body.is-light .tasks-sprint-info strong { color: #292530; }
body.is-light .tasks-delete-button { border-color: #ecc8cb; color: #a4333d; background: #fff5f5; }
body.is-light .tasks-complete-button, body.is-light .tasks-completed-badge { border-color: #badbc7; color: #287449; background: #f0faf4; }
body.is-light .tasks-sprint-picker { color: #625c69; }
body.is-light .tasks-sprint-picker select { border-color: #dedbe3; color: #292530; background: #fff; }
@media (max-width: 820px) { .tasks-view[data-tasks-view="backlog"] { height: calc(100dvh - 420px); min-height: 300px; } }
@media (max-width: 560px) { .tasks-view[data-tasks-view="backlog"] { height: calc(100dvh - 430px); min-height: 280px; }.tasks-backlog-resize { height: 18vh; max-height: 25vh; }.tasks-sprint-summary { padding-inline: 10px; }.tasks-sprint-goal { margin-left: 48px; }.tasks-board-toolbar > button { margin-left: auto; } }

/* Navegação do portal alinhada à referência do Hub. */
.workspace-nav-item { min-height: 48px; border: 1px solid transparent; border-radius: 10px; }
.workspace-nav-item.is-active { border-color: #b31ff0; color: #fff; background: linear-gradient(145deg, #291638, #1b1224); box-shadow: 0 0 12px rgba(179, 31, 240, .16); }
.workspace-nav-item.is-active > .nav-icon { color: #fff; }
.workspace-nav-item.is-active > .nav-image-icon { filter: none; }
.nav-image-icon { display: block; width: 24px; height: 24px; flex: 0 0 24px; object-fit: contain; }
.workspace-brand img { border-radius: 0; }
body.is-workspace:not(.is-light) .workspace-brand img { filter: invert(1); }
.theme-toggle { border: 0 !important; border-radius: 0 !important; background: transparent !important; }
.theme-toggle:hover { border: 0 !important; background: transparent !important; }
.theme-toggle:focus-visible { outline: 2px solid var(--primary-bright); outline-offset: 3px; }
.sidebar-account-actions .theme-icon { display: block; width: 32px; height: 32px; object-fit: contain; }
body.is-light .workspace-nav-item.is-active { border-color: #b31ff0; color: #fff; background: linear-gradient(145deg, #291638, #1b1224); }
@media (min-width: 821px) {
    .workspace-content { padding-left: calc(clamp(28px, 4vw, 54px) + 76px); }
}
@media (max-width: 820px) {
    .workspace { width: 100%; }
    .workspace-layout { display: block; min-height: 100vh; }
    .workspace-nav,
    .workspace-nav:hover,
    .workspace-nav:focus-within { position: fixed; inset: 0 auto 0 0; display: flex; width: 64px; height: 100vh; height: 100dvh; max-height: 100dvh; flex-direction: column; flex-wrap: nowrap; align-items: center; gap: 2px; overflow-x: hidden; overflow-y: auto; padding: 8px 6px; border-right: 1px solid #292d2d; border-bottom: 0; }
    .workspace-content { width: calc(100% - 64px); min-height: 100vh; margin-left: 64px; padding: 22px 14px; }
    .workspace-view { width: 100%; max-width: none; }
    .workspace-brand,
    .studio-context,
    .project-context-sidebar { width: 48px; min-width: 48px; max-width: 48px; min-height: 48px; justify-content: center; margin: 0 0 6px; padding: 4px; }
    .workspace-brand { padding: 2px; }
    .workspace-brand img { width: 40px; height: 40px; flex-basis: 40px; }
    .workspace-brand .nav-copy,
    .studio-context > span:nth-child(2),
    .project-context-sidebar .nav-copy,
    .workspace-nav-label,
    .workspace-nav-item .nav-copy,
    .workspace-hub-link .nav-copy,
    .sidebar-account-actions .nav-copy { display: none; }
    .studio-context-mark { width: 32px; height: 32px; }
    .workspace-nav-item { display: flex; width: 48px; min-width: 48px; min-height: 48px; justify-content: center; gap: 0; margin: 1px 0; padding: 0; }
    .workspace-nav-item > .nav-icon { width: 24px; min-width: 24px; height: 24px; font-size: 1rem; }
    .workspace-hub-link { display: flex; width: 48px; min-height: 44px; justify-content: center; margin: 3px 0; padding: 4px 0; border-top: 1px solid #302f34; }
    .sidebar-account-actions { display: flex; width: 48px; flex-direction: column; align-items: center; gap: 3px; margin: auto 0 0; padding: 8px 0 2px; border-top: 1px solid #302f34; }
    .sidebar-account-actions .theme-toggle,
    .sidebar-account-actions .signout-button { display: flex; width: 48px; min-width: 48px; height: 48px; min-height: 48px; justify-content: center; gap: 0; margin: 0; padding: 0; }
    .sidebar-account-actions .theme-icon { width: 32px; height: 32px; }
    .overview-metrics { grid-template-columns: 1fr; }
    .overview-metrics article { min-height: 68px; border-right: 0; border-bottom: 1px solid #2e2d32; }
}

/* Projetos e tarefas: listas sem barras internas e ações junto do conteúdo. */
.workspace-nav { scrollbar-width: none !important; }
.workspace-nav::-webkit-scrollbar { display: none !important; }
.project-context-sidebar[hidden] { display: none !important; }
.project-context-sidebar { display: grid; grid-template-columns: minmax(0, 1fr); gap: 6px; cursor: default; white-space: normal; }
.project-context-heading { margin: 0 4px 2px; color: #8c9292; font-size: .57rem; font-weight: 800; letter-spacing: .09em; }
.project-context-list { display: grid; gap: 4px; width: 100%; }
.project-switch-item { display: flex; align-items: center; gap: 9px; width: 100%; min-width: 0; min-height: 42px; padding: 4px 6px; border: 1px solid transparent; border-radius: 8px; color: #c3c5c7; background: transparent; text-align: left; cursor: pointer; }
.project-switch-item:hover { color: #fff; background: #1c2221; }
.project-switch-item.is-active { border-color: #42304d; color: #fff; background: #21182a; }
.project-switch-icon { display: grid; place-items: center; width: 34px; min-width: 34px; height: 34px; overflow: hidden; border: 1px solid #363b3b; border-radius: 9px; color: #d8b9eb; background: #29232e; font-size: .85rem; font-weight: 800; }
.project-switch-icon img { display: block; width: 100%; height: 100%; object-fit: cover; }
.project-switch-name { min-width: 0; overflow: hidden; font-size: .74rem; font-weight: 650; text-overflow: ellipsis; white-space: nowrap; }
body.is-light .project-context-heading { color: #73797d; }
body.is-light .project-switch-item { color: #535a5d; }
body.is-light .project-switch-item:hover { color: #292d30; background: #edf0f0; }
body.is-light .project-switch-item.is-active { border-color: #dfc6eb; color: #292d30; background: #f5ebfa; }
body.is-light .project-switch-icon { border-color: #d9dcdf; color: #75449a; background: #f2edf6; }
.tasks-view-heading { justify-content: flex-start; margin-bottom: 10px; }
.tasks-view-heading h2 { margin: 0; }
.tasks-tabs { margin-top: 0; }
.tasks-empty-action { display: flex; align-items: center; justify-content: space-between; gap: 14px; min-height: 58px; margin: 0 0 18px; padding: 8px 12px; border: 1px dashed #393840; border-radius: 8px; }
.tasks-empty-action .tasks-empty-state { padding: 0; border: 0; text-align: left; }
.tasks-inline-create { min-height: 36px; padding: 0 9px; border: 0; border-radius: 6px; color: #c4c0c8; background: transparent; font: inherit; font-size: .82rem; font-weight: 650; text-align: left; cursor: pointer; }
.tasks-inline-create:hover { color: #fff; background: #25242a; }
.tasks-create-sprint-inline { align-self: flex-start; }
.tasks-backlog-content { padding: 0 12px 10px; }
.tasks-backlog-resize { height: auto !important; min-height: 0 !important; max-height: none !important; overflow: visible !important; resize: none !important; padding: 0; }
.tasks-backlog-list { min-height: 48px; }
.tasks-backlog-content > .tasks-inline-create { margin-top: 4px; }
.tasks-view[data-tasks-view="backlog"] { height: auto !important; min-height: 0 !important; }
.tasks-view[data-tasks-view="backlog"] .tasks-sprints { min-height: 0 !important; height: auto !important; flex: 0 0 auto !important; overflow: visible !important; scrollbar-width: none !important; }
body.is-light .tasks-empty-action { border-color: #d8d4dd; }
body.is-light .tasks-inline-create { color: #625c69; }
body.is-light .tasks-inline-create:hover { color: #292530; background: #efedf2; }
@media (min-width: 821px) {
    .workspace-nav:not(:hover):not(:focus-within) .project-switch-item { justify-content: center; padding-inline: 0; }
}
@media (max-width: 820px) {
    .project-context-sidebar { justify-items: center; padding: 4px; }
    .project-switch-item { justify-content: center; width: 48px; min-width: 48px; min-height: 48px; padding: 0; }
    .project-switch-icon { width: 38px; height: 38px; }
    .tasks-empty-action { align-items: flex-start; }
}
.project-context-sidebar select[hidden] { display: none !important; }

/* Grupos recolhíveis para manter os destinos principais sempre acessíveis. */
.workspace-nav-group { display: grid; gap: 2px; width: 100%; margin: 3px 0; }
.workspace-nav-group > .workspace-nav-label { display: flex; align-items: center; gap: 8px; min-height: 48px; margin: 0; padding: 4px 7px; border: 1px solid transparent; border-radius: 10px; color: #aaa7b0; font-family: inherit; font-size: .8rem; font-weight: 560; letter-spacing: normal; text-transform: none; cursor: pointer; list-style: none; }
.workspace-nav-group > .workspace-nav-label::-webkit-details-marker { display: none; }
.workspace-nav-group > .workspace-nav-label::marker { content: ""; }
.workspace-nav-group > .workspace-nav-label::after { content: "⌄"; margin-left: auto; color: #777d7d; font-size: .8rem; }
.workspace-nav-group[open] > .workspace-nav-label::after { content: "⌃"; }
.workspace-nav-group > .workspace-nav-label > .nav-icon { display: grid; place-items: center; width: 32px; min-width: 32px; height: 32px; color: #96929c; font-size: .9rem; }
.workspace-nav-group > .workspace-nav-label:hover { color: var(--text); background: rgba(255,255,255,.045); }
.workspace-nav-group .workspace-nav-item { margin: 0; }
.workspace-nav .docs-nav-item { display: flex; text-decoration: none; }
.workspace-nav .workspace-nav-resources { margin-top: auto; }
.workspace-nav-resources .workspace-hub-link { margin: 0; border: 0; }
.studio-context-mark[hidden] { display: none !important; }
.studio-context-mark > span { color: #f1dcff; font-size: .72rem; font-weight: 850; letter-spacing: .03em; line-height: 1; }
.workspace-nav-item > .nav-image-icon { opacity: .72; }
.workspace-nav-item.is-active > .nav-image-icon { opacity: 1; }
body.is-light .workspace-nav-item:not(.is-active) > .nav-image-icon { filter: brightness(0) saturate(100%); opacity: .52; }
.workspace-nav-item > .nav-image-icon { width: 32px; height: 32px; flex-basis: 32px; padding: 4px; }
.workspace-nav-group > .workspace-nav-label > .nav-image-icon { width: 32px; height: 32px; flex: 0 0 32px; padding: 4px; object-fit: contain; opacity: .72; }
body.is-light .workspace-nav-group > .workspace-nav-label > .nav-image-icon { filter: brightness(0) saturate(100%); opacity: .52; }
.workspace-nav > .workspace-brand,
.workspace-nav > .studio-context,
.workspace-nav > .project-context-sidebar,
.workspace-nav > .workspace-nav-item,
.workspace-nav > .workspace-nav-group,
.workspace-nav > .sidebar-account-actions { flex-shrink: 0; }
@media (min-width: 821px) {
    .workspace-nav .studio-context { height: 48px; min-height: 48px; margin-bottom: 6px; }
    .workspace-nav .studio-context-mark { width: 30px; height: 30px; }
    .workspace-nav:not(:hover):not(:focus-within) .workspace-brand { padding-left: 5px; }
}
@media (max-width: 820px) {
    .workspace-nav-item > .nav-image-icon { width: 24px; height: 24px; flex-basis: 24px; padding: 0; }
    .workspace-nav-group > .workspace-nav-label > .nav-image-icon { width: 24px; height: 24px; flex-basis: 24px; padding: 0; }
}
@media (min-width: 821px) {
    .workspace-nav:not(:hover):not(:focus-within) .workspace-nav-group > .workspace-nav-label { width: 48px; max-width: 48px; min-width: 48px; min-height: 48px; justify-content: flex-start; margin: 0; padding: 0 0 0 7px; overflow: visible; opacity: 1; pointer-events: auto; }
    .workspace-nav:not(:hover):not(:focus-within) .workspace-nav-group > .workspace-nav-label::after { display: none; }
}
body.is-light .workspace-nav-group > .workspace-nav-label { color: #68636e; }
body.is-light .workspace-nav-group > .workspace-nav-label:hover { color: #292530; background: #f1eff3; }
@media (max-width: 820px) {
    .workspace-nav-group { display: grid; width: 100%; justify-items: center; margin: 2px 0; }
    .workspace-nav-group > .workspace-nav-label { display: flex !important; width: 48px; min-width: 48px; min-height: 48px; justify-content: center; margin: 1px 0; padding: 0; }
    .workspace-nav-group > .workspace-nav-label::after { display: none; }
    .workspace-nav-group > .workspace-nav-label .nav-copy { display: none; }
    .workspace-nav-group > .workspace-nav-label > .nav-icon { width: 24px; min-width: 24px; height: 24px; }
    .workspace-nav-group .workspace-nav-item { display: flex; }
    .workspace-nav-resources { margin-top: 0 !important; }
}

/* Tasks: cartões inteiros abrem e podem ser arrastados; barras combinam com o tema. */
.tasks-board { scrollbar-color: #45434c #151518; scrollbar-width: thin; }
.tasks-board::-webkit-scrollbar { height: 9px; }
.tasks-board::-webkit-scrollbar-track { border-radius: 99px; background: #151518; }
.tasks-board::-webkit-scrollbar-thumb { border: 2px solid #151518; border-radius: 99px; background: #45434c; }
.tasks-board::-webkit-scrollbar-thumb:hover { background: #625d69; }
.task-card { cursor: grab; }
.task-card:active { cursor: grabbing; }
.task-card:focus-visible { outline: 2px solid #a967d2; outline-offset: 2px; }
body.is-light .tasks-board { scrollbar-color: #bcb8c2 #eeedf0; }
body.is-light .tasks-board::-webkit-scrollbar-track { background: #eeedf0; }
body.is-light .tasks-board::-webkit-scrollbar-thumb { border-color: #eeedf0; background: #bcb8c2; }
body.is-light .tasks-board::-webkit-scrollbar-thumb:hover { background: #99939f; }
.tasks-acceptance { display: grid; gap: 9px; padding-top: 4px; }
.tasks-acceptance h3 { margin: 0; color: #eeeaf2; font-size: .8rem; }
#taskAcceptanceCriteria { display: grid; gap: 8px; }
.task-acceptance-row { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 8px; }
.task-acceptance-row input { min-width: 0; min-height: 36px; padding: 7px 9px; border: 1px solid #393840; border-radius: 6px; color: #f0edf3; background: #111114; font: inherit; font-size: .75rem; }
.task-acceptance-approval, .tasks-acceptance-hint { color: #a9a3ae; font-size: .67rem; }
.tasks-acceptance-hint { margin: 0; line-height: 1.5; }
.tasks-criterion-remove { width: 30px; height: 30px; border: 0; border-radius: 6px; color: #aaa6b0; background: transparent; font-size: 1.2rem; cursor: pointer; }
.tasks-criterion-remove:hover { color: #fff; background: #302d35; }
body.is-light .tasks-acceptance h3 { color: #292530; }
body.is-light .task-acceptance-row input { border-color: #d8d4dd; color: #292530; background: #fff; }
body.is-light .task-acceptance-approval, body.is-light .tasks-acceptance-hint { color: #625c69; }
body.is-light .tasks-criterion-remove:hover { color: #292530; background: #efedf2; }
@media (max-width: 560px) { .task-acceptance-row { grid-template-columns: minmax(0, 1fr) auto; }.task-acceptance-approval { grid-column: 1; grid-row: 2; }.tasks-criterion-remove { grid-column: 2; grid-row: 1 / span 2; } }

/* Contextos de projeto e estúdio em lista simples, sem cartões encaixados. */
.workspace-nav > .studio-context,
.workspace-nav > .project-context-sidebar { border-color: transparent; border-radius: 0; background: transparent; box-shadow: none; }
.workspace-nav > .studio-context { padding-inline: 4px; }
.workspace-nav > .studio-context .studio-context-mark { border-color: transparent; background: transparent; }
.project-context-sidebar { padding-inline: 0; }
.project-switch-item.is-active { border-color: transparent; color: #fff; background: rgba(255,255,255,.075); }
body.is-light .workspace-nav > .studio-context,
body.is-light .workspace-nav > .project-context-sidebar { border-color: transparent; background: transparent; }
body.is-light .project-switch-item.is-active { border-color: transparent; color: #292d30; background: #edf0f0; }
.tasks-detail-layout.is-comments-collapsed { grid-template-columns: minmax(0, 1fr); min-height: 0; }
.tasks-detail-layout.is-comments-collapsed .tasks-comments { justify-content: flex-start; padding: 0 20px 14px; border: 0; background: transparent; }
.tasks-comments-heading { display: flex; align-items: center; gap: 12px; }
.tasks-comments-heading .panel-kicker { margin: 0; }
.tasks-comments-content { display: flex; min-height: 0; flex-direction: column; justify-content: space-between; gap: 12px; }
.tasks-comments-content[hidden] { display: none !important; }
.tasks-detail-modal .tasks-modal-actions { align-items: center; }
.tasks-detail-modal .tasks-modal-actions button { display: inline-flex; height: 36px; min-height: 36px; align-items: center; justify-content: center; box-sizing: border-box; line-height: 1; }
.tasks-detail-modal #deleteTaskButton { margin-right: auto; }
@media (max-width: 560px) {
    .tasks-detail-modal .tasks-modal-actions { flex-wrap: wrap; }
    .tasks-detail-modal #deleteTaskButton { margin-right: 0; }
    .tasks-detail-modal .tasks-modal-actions [data-close-task-modal] { margin-right: auto; }
}

/* Leitor de documentos HeartSpace Docs */
.workspace-content:has(.docs-reader-view.is-active) { padding:0; }
.docs-reader-view { min-height:100vh; padding:clamp(16px,2vw,28px); }
.reader-status { position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0; }
.reader-heading { display:flex; align-items:flex-start; justify-content:space-between; gap:20px; }
.reader-heading h1 { max-width:720px; }
.reader-editor-link { flex:0 0 auto; margin-top:12px; color:#e8c5f7; font-size:.82rem; font-weight:750; text-decoration:none; }
.reader-editor-link:hover { color:white; }
.reader-layout { display:grid; grid-template-columns:minmax(180px, 220px) minmax(0,1fr); gap:14px; min-height:calc(100vh - 32px); }
.reader-library { align-self:start; position:sticky; top:18px; max-height:calc(100vh - 170px); overflow:auto; border:1px solid var(--border); border-radius:12px; background:rgba(7,7,10,.36); }
.reader-library-heading { position:sticky; top:0; z-index:2; display:flex; align-items:center; justify-content:space-between; gap:8px; padding:13px; border-bottom:1px solid var(--border); background:var(--panel); }
.reader-library-heading strong { font-size:.83rem; }
.reader-document-list { display:grid; gap:3px; padding:7px; }
.reader-document-item { display:grid; gap:5px; width:100%; padding:11px 10px; border:1px solid transparent; border-radius:8px; color:var(--text); background:transparent; text-align:left; }
.reader-document-item:hover,.reader-document-item.is-active { border-color:rgba(188,66,239,.32); background:rgba(149,1,216,.12); }
.reader-document-item strong { overflow:hidden; font-size:.83rem; text-overflow:ellipsis; white-space:nowrap; }
.reader-document-item small,.reader-list-empty { color:var(--muted); font-size:.72rem; }
.reader-list-empty { padding:9px; line-height:1.5; }
.reader-main { min-width:0; }
.reader-toolbar { display:flex; align-items:center; justify-content:flex-end; gap:8px; margin-bottom:8px; }
.reader-toolbar .portal-button { min-height:36px; margin:0; }
.reader-docs-button { display:inline-flex; align-items:center; text-decoration:none; }
.reader-fullscreen-button { min-height:36px; padding-inline:12px; }
.reader-selection-action { position:fixed; z-index:1000; min-height:38px; padding:0 14px; border:1px solid #c45cf0; border-radius:9px; color:#fff; background:#8700c9; box-shadow:0 8px 24px #0008,0 0 0 3px #aa36d533; font-size:.79rem; font-weight:800; white-space:nowrap; }
.reader-selection-action:hover { background:#a10ce4; transform:translateY(-1px); }
.reader-selection-action[hidden] { display:none !important; }
.reader-format-tag { margin-right:auto; color:#d8a8ee; font-size:.65rem; font-weight:850; letter-spacing:.12em; }
.reader-document-title { margin:18px 0 5px; font-size:clamp(1.65rem,3vw,2.35rem); letter-spacing:-.04em; }
.reader-document-subtitle { margin:0 0 18px; color:var(--muted); line-height:1.55; }
.reader-page-controls { display:flex; align-items:center; justify-content:center; gap:16px; margin:12px 0; color:var(--muted); font-size:.74rem; }
.reader-page-controls[hidden] { display:none; }
.reader-page-controls button { padding:7px 10px; border:1px solid var(--border); border-radius:7px; color:var(--text); background:rgba(255,255,255,.04); font-size:.72rem; }
.reader-book-stage { --reader-page-width:794px; --reader-page-height:1123px; --reader-margin-x:76px; --reader-margin-y:72px; position:relative; width:100%; max-width:100%; overflow-x:auto; overflow-y:hidden; scroll-snap-type:none; scroll-behavior:auto; overscroll-behavior-inline:contain; scrollbar-color:#6f6875 #19171d; scrollbar-width:thin; border-radius:3px; background-color:#25232a; box-shadow:0 16px 42px #0005; touch-action:pan-x pan-y; }
.reader-book-stage:focus-visible { outline:none; }
.reader-book-stage .reader-rendered-content { box-sizing:border-box; width:var(--reader-page-width); height:var(--reader-page-height); padding:var(--reader-margin-y) var(--reader-margin-x); color:#27242a; font-family:Inter,ui-sans-serif,system-ui,-apple-system,"Segoe UI",sans-serif; font-size:16px; line-height:1.5; column-width:var(--reader-column-width,642px); column-gap:var(--reader-column-gap,206px); column-fill:auto; }
.reader-page-tail { position:absolute; top:0; height:1px; min-height:1px; pointer-events:none; }
.reader-rendered-content p { margin:0 0 8px; }
.reader-book-stage .reader-rendered-content > * { break-inside:avoid; }
.reader-rendered-content h1 { margin:26px 0 12px; font-size:30px; line-height:1.25; }
.reader-rendered-content h2 { margin:34px 0 12px; font-size:23px; line-height:1.35; }
.reader-rendered-content h3 { margin:24px 0 10px; font-size:20px; line-height:1.35; }
.reader-rendered-content h4 { margin:20px 0 8px; font-size:18px; line-height:1.4; }
.reader-rendered-content h5 { margin:16px 0 6px; font-size:16px; line-height:1.45; }
.reader-rendered-content h6 { margin:14px 0 6px; font-size:15px; line-height:1.45; }
.reader-book-title { margin:0 0 12px !important; color:#201b22 !important; font-size:34px !important; line-height:1.2 !important; letter-spacing:-.04em; font-weight:700; }
.reader-book-subtitle { min-height:1.5em; margin:0 0 36px !important; color:#aaa4b0; font-size:15px; line-height:1.5; }
.reader-book-stage .reader-book-subtitle[hidden] { display:none; }
.reader-rendered-content ul[data-list-type="checklist"] { padding:0; list-style:none; }
.reader-rendered-content li[data-checklist-item] { display:flex; align-items:flex-start; gap:10px; min-height:30px; padding:0; }
.reader-rendered-content .checklist-box { display:inline-grid; flex:0 0 17px; width:17px; height:17px; place-items:center; margin:2px 2px 0 1px; border:1px solid #8a8490; border-radius:4px; color:#fff; background:#6b2386; font-size:12px; font-weight:800; line-height:1; }
.reader-rendered-content li[data-checked="true"] .checklist-text { color:#77717d; text-decoration:line-through; }
.reader-rendered-content .callout { --reader-callout-accent:#4789bd; margin:20px 0; overflow:hidden; border:1px solid color-mix(in srgb,var(--reader-callout-accent) 34%,#ffffff); border-left:3px solid var(--reader-callout-accent); border-radius:9px; background:color-mix(in srgb,var(--reader-callout-accent) 8%,#ffffff); color:#29252d; }
.reader-rendered-content .callout[data-callout-type="abstract"],.reader-rendered-content .callout[data-callout-type="summary"] { --reader-callout-accent:#168a83; }
.reader-rendered-content .callout[data-callout-type="tip"],.reader-rendered-content .callout[data-callout-type="success"],.reader-rendered-content .callout[data-callout-type="callout_decision"] { --reader-callout-accent:#24864c; }
.reader-rendered-content .callout[data-callout-type="question"],.reader-rendered-content .callout[data-callout-type="faq"],.reader-rendered-content .callout[data-callout-type="callout_idea"] { --reader-callout-accent:#8257b0; }
.reader-rendered-content .callout[data-callout-type="warning"],.reader-rendered-content .callout[data-callout-type="callout_warning"],.reader-rendered-content .callout[data-callout-type="callout_risk"] { --reader-callout-accent:#a76b08; }
.reader-rendered-content .callout[data-callout-type="failure"],.reader-rendered-content .callout[data-callout-type="danger"],.reader-rendered-content .callout[data-callout-type="error"],.reader-rendered-content .callout[data-callout-type="bug"],.reader-rendered-content .callout[data-callout-type="callout_review"] { --reader-callout-accent:#b23a4c; }
.reader-rendered-content .callout-heading { display:flex; align-items:center; gap:10px; min-height:43px; padding:8px 12px 4px; color:var(--reader-callout-accent); font-weight:750; }
.reader-rendered-content .callout-icon { display:grid; flex:0 0 20px; width:20px; height:20px; place-items:center; font-size:17px; }
.reader-rendered-content .callout-title { min-width:0; flex:1; }
.reader-rendered-content .callout-body { padding:0 13px 10px 42px; color:#38333d; }
.reader-rendered-content .callout-body > :first-child { margin-top:0; }
.reader-rendered-content .callout-body > :last-child { margin-bottom:3px; }
.reader-rendered-content .callout-body[hidden] { display:none; }
.reader-rendered-content .reader-callout-toggle { display:grid; flex:0 0 28px; width:28px; height:28px; place-items:center; border-radius:6px; color:var(--reader-callout-accent); cursor:pointer; }
.reader-rendered-content .reader-callout-toggle:hover { background:#0000000d; }
.reader-rendered-content .reader-media-fallback { display:inline-flex; align-items:center; min-height:34px; padding:7px 10px; border:1px dashed #aaa3ad; border-radius:7px; color:#69636d; font-size:.8rem; }
.reader-rendered-content figure[data-docs-image] { display:flex; flex-direction:column; width:min(100%,760px); margin:28px auto; }
.reader-rendered-content figure[data-docs-image] img { display:block; width:100%; max-height:680px; border-radius:8px; object-fit:contain; }
.reader-rendered-content figure[data-image-style="banner"] { width:100%; max-width:none; margin-inline:0; }
.reader-rendered-content figure[data-image-style="banner"] img { height:300px; max-height:none; object-fit:cover; }
.reader-rendered-content figure[data-image-style="framed"] img { padding:8px; border:1px solid #aaa; background:#fff; }
.reader-rendered-content figure[data-image-style="rounded"] img { border-radius:24px; }
.reader-rendered-content figure[data-caption-position="top"] figcaption { order:-1; margin:0 0 9px; }
.reader-rendered-content figure[data-caption-align="left"] figcaption { text-align:left; }
.reader-rendered-content figure[data-caption-align="right"] figcaption { text-align:right; }
.reader-rendered-content .reader-mermaid { margin:20px 0; overflow:hidden; border:1px solid #d4ced7; border-radius:10px; background:#fbf9fc; }
.reader-rendered-content .reader-mermaid figcaption { margin:0; padding:8px 12px; border-bottom:1px solid #e6e0e9; color:#62596b; font-size:.75rem; font-weight:700; text-align:left; }
.reader-rendered-content .reader-mermaid-preview { max-width:100%; padding:18px; overflow:auto; }
.reader-rendered-content .reader-mermaid-preview svg { display:block; max-width:100%; height:auto; margin:auto; }
.reader-rendered-content .reader-mermaid-status { margin:0; padding:8px 12px; color:#62596b; font-size:.78rem; }
.reader-rendered-content .reader-mermaid-source { margin:0; padding:12px; overflow:auto; color:#403a45; background:#f2eff4; white-space:pre-wrap; }
.reader-book-stage .reader-rendered-content h1,.reader-book-stage .reader-rendered-content h2,.reader-book-stage .reader-rendered-content h3 { color:#201b22; }
.reader-book-stage .reader-rendered-content a { color:#6e208e; }
.reader-book-stage .reader-rendered-content img { max-width:100%; max-height:55vh; object-fit:contain; }
.reader-book-stage .reader-rendered-content table { width:100%; border-collapse:collapse; }
.reader-book-stage .reader-rendered-content td,.reader-book-stage .reader-rendered-content th { border:1px solid #aaa; padding:6px; }
.reader-canvas-stage { width:100%; height:calc(100vh - 190px); min-height:480px; max-height:none; overflow:auto; padding:clamp(20px,3vw,40px); border:1px solid var(--border); border-radius:12px; background:rgba(7,7,10,.25); }
.reader-canvas-stage .reader-rendered-content { width:100%; max-width:none; margin:0; color:var(--text); font-size:1rem; line-height:1.5; overflow-wrap:anywhere; }
.reader-main:fullscreen { position:relative; box-sizing:border-box; display:flex; flex-direction:column; gap:0; width:100vw; height:100vh; min-height:0; padding:14px 22px; overflow:auto; color:var(--text); background:var(--bg,#111516); }
.reader-main:fullscreen .reader-toolbar { position:absolute; top:8px; right:12px; z-index:11; margin:0; }
.reader-main:fullscreen .reader-format-tag,.reader-main:fullscreen .reader-docs-button,.reader-main:fullscreen .reader-toolbar [data-reader-action="publish"] { display:none; }
.reader-main:fullscreen .reader-fullscreen-button { min-height:32px; }
.reader-main:fullscreen .reader-document-title { flex:0 0 auto; margin:0 0 8px; }
.reader-main:fullscreen .reader-page-controls { flex:0 0 auto; margin:4px 0 8px; }
.reader-main:fullscreen .reader-page-controls.is-fullscreen-overlay:not([hidden]) { position:absolute; inset:0; z-index:5; display:block; margin:0; pointer-events:none; }
.reader-main:fullscreen .reader-page-controls.is-fullscreen-overlay [data-reader-page-info] { display:none; }
.reader-main:fullscreen .reader-page-controls.is-fullscreen-overlay button { position:absolute; display:grid; width:44px; height:44px; padding:0; place-items:center; transform:translateY(-50%); border:1px solid #ffffff36; border-radius:50%; color:#fff; background:#17151de8; box-shadow:0 5px 18px #0005; font-size:1.5rem; line-height:1; pointer-events:auto; }
.reader-main:fullscreen .reader-page-controls.is-fullscreen-overlay button:hover:not(:disabled) { border-color:#d492f0; background:#30213a; }
.reader-main:fullscreen .reader-page-controls.is-fullscreen-overlay button:disabled { opacity:.32; }
.reader-main:fullscreen .reader-book-stage { flex:0 0 auto; }
.reader-main:fullscreen .reader-canvas-stage { flex:1 1 auto; width:100%; height:auto; min-height:0; }
.reader-main:fullscreen .reader-review-footer { flex:0 0 auto; max-height:18vh; overflow:auto; }
.reader-rendered-content > :first-child { margin-top:0; }
.reader-rendered-content h1,.reader-rendered-content h2,.reader-rendered-content h3,.reader-rendered-content h4 { line-height:1.3; }
.reader-rendered-content figure { margin:24px 0; text-align:center; }
.reader-rendered-content figure img { display:block; width:100%; max-width:100%; max-height:650px; margin:auto; object-fit:contain; }
.reader-rendered-content figcaption { margin-top:8px; color:var(--muted); font-size:.8rem; }
.reader-rendered-content pre { overflow:auto; padding:14px; border-radius:8px; background:rgba(0,0,0,.22); white-space:pre-wrap; }
.reader-rendered-content a { color:#d8a2f1; }
.reader-review-footer { margin-top:16px; }
.reader-selected-quote,.reader-comment-card blockquote { margin:0 0 10px; padding:9px 12px; border-left:3px solid var(--primary-bright); color:#d8cae0; background:rgba(149,1,216,.09); font-size:.8rem; line-height:1.5; }
.reader-comment-composer { display:grid; grid-template-columns:minmax(0,1fr) auto auto; align-items:start; gap:8px; margin-bottom:12px; }
.reader-comment-composer textarea,.reader-publish-dialog textarea { min-height:76px; padding:10px; border:1px solid var(--border); border-radius:8px; color:var(--text); background:#0a0a0f; font:inherit; resize:vertical; }
.reader-comment-composer button { align-self:end; min-height:38px; margin:0; }
.reader-comments { border-top:1px solid var(--border); padding-top:10px; }
.reader-comments > summary { color:#c2bbc8; font-size:.75rem; font-weight:750; cursor:pointer; }
.reader-comments-list { display:grid; gap:9px; margin-top:10px; }
.reader-comment-card { padding:12px; border:1px solid var(--border); border-radius:9px; background:rgba(255,255,255,.025); }
.reader-comment-card p { margin:0 0 8px; color:#e2dce6; font-size:.83rem; line-height:1.55; white-space:pre-wrap; }
.reader-comment-card small { color:var(--muted); font-size:.68rem; }
.reader-empty { display:grid; justify-items:center; align-content:center; min-height:400px; padding:30px; text-align:center; }
.reader-empty > span { display:grid; place-items:center; width:44px; height:44px; margin-bottom:16px; border:1px solid rgba(188,66,239,.34); border-radius:12px; color:#dda5f5; background:rgba(149,1,216,.12); font-size:1.3rem; }
.reader-empty h2 { margin:0 0 8px; font-size:1.2rem; }
.reader-empty p { max-width:400px; color:var(--muted); font-size:.87rem; line-height:1.55; }
.reader-publish-dialog { width:min(540px,calc(100% - 28px)); max-height:calc(100vh - 30px); padding:24px; border:1px solid var(--border); border-radius:16px; color:var(--text); background:#141319; box-shadow:0 25px 90px #0009; }
.reader-publish-dialog::backdrop { background:#050408c9; backdrop-filter:blur(5px); }
.reader-publish-dialog .studio-form { max-width:none; margin:0; }
.reader-publish-dialog .admin-detail-heading { display:flex; align-items:center; justify-content:space-between; gap:16px; }
.reader-publish-dialog .admin-detail-heading h2 { margin:0; font-size:1.25rem; }
.reader-publish-dialog .field-note { margin:0; color:var(--muted); font-size:.78rem; line-height:1.5; }
.reader-dialog-actions { display:flex; justify-content:flex-end; gap:9px; }
.reader-dialog-actions button { min-height:40px; margin:0; }
@media(max-width:850px) { .reader-layout { grid-template-columns:1fr; min-height:0; }.reader-library { position:static; max-height:210px; }.reader-document-list { grid-template-columns:repeat(2,minmax(0,1fr)); }.reader-canvas-stage { height:calc(100vh - 360px); } }
@media(max-width:560px) { .docs-reader-view { padding:10px; }.reader-toolbar { flex-wrap:wrap; }.reader-comment-composer { grid-template-columns:1fr 1fr; }.reader-comment-composer textarea { grid-column:1 / -1; }.reader-document-list { grid-template-columns:1fr; }.reader-canvas-stage { min-height:360px; height:calc(100vh - 350px); padding:16px; }.reader-main:fullscreen { padding:8px; }.reader-main:fullscreen .reader-canvas-stage { height:auto; min-height:0; } }
