.signed-out .sidebar{display:none}
.signed-out main,.signed-out .skip{display:none}
.signed-out dialog{display:none!important}
.login-surface[hidden]{display:none}
.login-surface{min-height:100svh;padding:clamp(24px,5vw,64px);display:flex;flex-direction:column}
.login-brand{font-size:24px;font-weight:650;letter-spacing:-.03em;color:var(--ink,#262825);text-decoration:none;align-self:flex-start}
.login-body{width:min(100%,420px);margin:auto; padding:40px 0 100px}
.login-body h1{font-size:clamp(28px,4vw,38px);line-height:1.4;letter-spacing:-.03em;font-weight:600;margin:0 0 14px}
.login-body>p{color:#666a62;font-size:15px;margin:0 0 36px}
.login-surface.is-loading:not([hidden]){display:grid;place-items:center}
.auth-mark{display:flex;flex-direction:column;align-items:center;gap:22px;margin-top:-6svh}
.auth-mark .login-brand{align-self:auto;font-size:28px;font-weight:600}
.auth-spinner{width:18px;height:18px;opacity:.55;animation:auth-turn 1.1s linear infinite}
@keyframes auth-turn{to{transform:rotate(360deg)}}
@media(prefers-reduced-motion:reduce){.auth-spinner{animation:none}}
.login-button{width:100%;min-height:50px;font-size:15px;border-radius:12px;background:#fff}
.login-body .login-error{font-size:13px;color:#8b463e;line-height:1.7;margin-top:20px;min-height:1.7em}
.page-head{display:flex;align-items:center;justify-content:space-between;gap:16px}
.page-title,.page-actions{min-width:0}
.cloud-state{min-width:0;max-width:320px;font-size:12px;line-height:1.6;color:#64685f;display:flex;align-items:center;justify-content:flex-end;gap:4px 10px;flex-wrap:wrap;overflow-wrap:anywhere;text-align:right}
.cloud-state[data-kind="error"]{color:#8b463e}
.cloud-state button{font:inherit;color:inherit;background:none;border:0;padding:4px 0;text-decoration:underline;text-underline-offset:4px;white-space:nowrap}
.account-email{font-size:13px;color:#64685f;overflow-wrap:anywhere;margin:0 0 28px}
.account-actions{display:flex;flex-direction:column;align-items:stretch;gap:16px}
@media(max-width:600px){.login-body{padding-bottom:80px}}

.signed-out .workspace-bar,.signed-out .sync-notice{display:none}
.workspace-bar{height:92px;margin-left:235px;padding:32px 6% 0;display:flex;align-items:center;justify-content:flex-end;gap:16px}
.workspace-tools{display:flex;align-items:center;gap:12px}
.workspace-tools .icon-button{width:44px;min-width:44px;height:44px;background:transparent;color:var(--muted)}
.mobile-brand{display:none}
.cloud-state{min-height:44px;max-width:160px;gap:8px;white-space:nowrap;flex-wrap:nowrap}
.cloud-state>.icon{width:15px;height:15px;opacity:.6}
.sync-spinner{width:16px;height:16px;opacity:.65;animation:auth-turn 1.1s linear infinite}
.sync-status-button{min-height:44px;font-size:12px!important;text-decoration:none!important}
.sync-status-button:hover,.sync-status-button:focus-visible{text-decoration:underline!important}
.sync-notice{margin:12px 6% 0 calc(235px + 6%);max-width:1000px;color:#8b463e;font-size:13px;line-height:1.7;display:flex;align-items:center;gap:16px}
.sync-notice[hidden]{display:none}
.sync-notice .text-link{appearance:none;-webkit-appearance:none;border:0;border-radius:0;background:transparent;min-height:44px;white-space:nowrap;color:inherit;font:inherit;text-decoration:underline;text-underline-offset:4px;cursor:pointer}
main{padding-top:8px;min-height:calc(100svh - 92px)}
.account-email{margin-bottom:8px}
.account-sync-status,.sync-description{font-size:13px;line-height:1.7;color:var(--muted);margin:0 0 24px;overflow-wrap:anywhere}
.account-actions{gap:4px}
.account-actions .text-link,.sync-actions .text-link{appearance:none;-webkit-appearance:none;border:0;background:transparent;min-height:48px;padding:10px 0;text-align:left;font:inherit;font-size:14px;color:var(--ink);border-radius:0;cursor:pointer}
.account-actions .text-link:hover,.account-actions .text-link:focus-visible,.sync-actions .text-link:hover,.sync-actions .text-link:focus-visible{text-decoration:underline;text-underline-offset:5px}
.sync-actions{display:flex;flex-direction:column;gap:4px;margin-top:24px}
.sync-actions .secondary{min-height:48px}
.sync-change-list{font-size:13px;color:var(--muted);line-height:1.7;margin:0 0 20px;overflow-wrap:anywhere}
.sync-change-list p{white-space:pre-wrap;margin:4px 0 12px}.sync-change>span{font-size:12px}.sync-history-change{padding-top:4px}
.account-advanced summary{list-style:none;min-height:48px;display:flex;align-items:center;justify-content:space-between;font-size:14px;cursor:pointer}
.account-advanced summary::-webkit-details-marker{display:none}.account-advanced summary .icon{width:15px;height:15px;transform:rotate(90deg)}.account-advanced[open] summary .icon{transform:rotate(-90deg)}
.account-advanced summary:hover,.account-advanced summary:focus-visible{text-decoration:underline;text-underline-offset:5px}
.account-advanced>div{padding:4px 0 8px 12px;display:flex;flex-direction:column}
.backup-loading{min-height:100px;display:grid;place-items:center}
.backup-status{font-size:14px;margin:0 0 20px;line-height:1.7}.backup-status>span{display:block;color:var(--muted);font-size:12px;margin-top:4px}
.backup-version{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;width:100%;gap:4px 16px;padding:16px 0;min-height:64px;text-align:left;border:0;border-bottom:1px solid var(--line);background:transparent;color:var(--ink);font:inherit;cursor:pointer}
.backup-version time{font-size:14px}.backup-version small{grid-column:1;color:var(--muted);font-size:12px}.backup-version>.icon{grid-column:2;grid-row:1/3;width:16px;color:var(--muted)}
.backup-version:hover time,.backup-version:focus-visible time{text-decoration:underline;text-underline-offset:5px}
.restore-changes{margin:24px 0}.restore-changes>h3{font-size:13px;color:var(--muted);margin:0 0 8px}.restore-changes .summary-row{font-size:14px}.restore-changes .summary-row>span{min-width:0;overflow-wrap:anywhere}.restore-changes .summary-row>strong{max-width:65%;overflow-wrap:anywhere;text-align:right}
.backup-footer{display:flex;justify-content:space-between;gap:16px;margin-top:12px}
.backup-footer .text-link{appearance:none;-webkit-appearance:none;border:0;background:transparent;color:var(--ink);font:inherit;font-size:13px;padding:8px 0;min-height:44px;cursor:pointer}
.backup-footer .text-link:hover,.backup-footer .text-link:focus-visible{text-decoration:underline;text-underline-offset:4px}
@media(min-width:1700px){.workspace-bar{padding-right:max(6%,calc((100vw - 1450px)/2))}}
@media(max-width:1100px) and (min-width:701px){.workspace-bar{margin-left:195px;padding-inline:4%}.sync-notice{margin-left:calc(195px + 4%);margin-right:4%}}
@media(max-width:700px){
 .sidebar{height:0;padding:0;background:transparent}.sidebar>.brand,.sidebar-foot{display:none}
 .workspace-bar{position:relative;z-index:5;height:80px;margin-left:0;padding:16px 22px 0;justify-content:space-between}
 .mobile-brand{display:block;color:var(--ink);text-decoration:none;font-size:21px;font-weight:650;letter-spacing:-.03em}
 .workspace-tools{gap:8px}.workspace-tools .icon-button{margin-right:-8px}
 main{padding-top:18px}.page-head{margin-bottom:24px;min-height:40px}.hero{margin-top:0}
 .sync-notice{margin:8px 22px 0;font-size:12px;gap:12px}
}
@media(max-width:360px){.workspace-bar{padding-inline:16px}.sync-notice{margin-inline:16px}}
@media(prefers-reduced-motion:reduce){.sync-spinner{animation:none}}
