.settings-switch-track{position:relative;display:block;flex:none;width:38px;height:22px;border-radius:12px;background:var(--muted);transition:background .18s}
.settings-switch-track:after{content:'';position:absolute;left:3px;top:3px;width:16px;height:16px;border-radius:50%;background:var(--bg);transition:transform .18s}
.settings-switch-status{font-size:11px;color:var(--muted);font-weight:550}
html[data-design] .app-page .btn.chat-restore-toggle{display:flex;align-items:center;gap:8px;width:100%;max-width:300px;min-height:44px;margin-top:5px;padding:5px 0;background:transparent;border:0;box-shadow:none;border-radius:0;color:var(--text);font-size:11px;line-height:1.45;text-align:left;white-space:normal}
.chat-restore-toggle .settings-switch-label{flex:1;min-width:0}
.chat-restore-toggle .settings-switch-status{min-width:4em}
.chat-restore-toggle[aria-checked=true] .settings-switch-track{background:var(--green)}
.chat-restore-toggle[aria-checked=true] .settings-switch-track:after{transform:translateX(16px)}
.chat-restore-toggle[aria-checked=true] .settings-switch-status{color:var(--green)}
.chat-restore-state{display:flex;align-items:center;flex-wrap:wrap;gap:5px 10px;margin-top:8px;color:var(--muted);font-size:11px;line-height:1.5}
.chat-restore-state strong{display:inline-flex;align-items:center;gap:5px;color:var(--muted);font-weight:600}
.chat-restore-state strong:before{content:'';width:5px;height:5px;flex:none;border-radius:50%;background:currentColor}
.chat-restore-state[data-enabled=true] strong{color:var(--green)}
.chat-readonly-summary{display:grid;gap:0;margin:20px 0 8px}
.chat-readonly-summary>div{padding:15px 0;border-bottom:1px solid var(--line)}
.chat-readonly-summary dt{margin-bottom:7px;color:var(--muted);font-size:12px}
.chat-readonly-summary dd{margin:0;line-height:1.65;overflow-wrap:anywhere}
.chat-readonly-summary pre{margin:0;white-space:pre-wrap;overflow-wrap:anywhere;font:inherit}
.chat-readonly-footer{flex:none;margin:0;padding:16px 26px;border-top:1px solid var(--line);background:var(--surface)}
@media(max-width:520px){.chat-readonly-footer{padding:14px 18px;flex-wrap:nowrap}.chat-readonly-footer .btn{flex:1;min-width:0}}
.chat-readonly-summary .chat-restore-state{margin:0;font-size:13px}
.chat-readonly-intro{display:flex;gap:10px;align-items:flex-start;color:var(--muted);line-height:1.6;font-size:13px}
.chat-readonly-intro>svg{width:18px;height:18px;margin-top:2px;color:var(--accent)}
.chat-recipient-view{display:flex;align-items:center;justify-content:center;flex:0 0 48px;width:48px;height:48px}
@media(max-width:760px){.chat-recipient-view{width:42px;height:42px;flex-basis:42px}}
html[data-design] .app-page .btn.chat-restore-toggle:hover:not(:disabled){background:transparent;color:var(--accent)}
.chat-restore-toggle:focus-visible{outline:2px solid var(--accent);outline-offset:3px}
@media(max-width:420px){
 html[data-design] .app-page .btn.chat-restore-toggle{display:grid;grid-template-columns:38px minmax(0,1fr);column-gap:8px;row-gap:5px}
 .chat-restore-toggle .settings-switch-label{grid-column:1/-1;overflow-wrap:anywhere}
 .chat-restore-toggle .settings-switch-track{grid-column:1;grid-row:2}
 .chat-restore-toggle .settings-switch-status{grid-column:2;grid-row:2;min-width:0;overflow-wrap:anywhere}
}
.editor-restore-kicker{display:block;margin-bottom:3px;color:var(--accent);font-size:11px;line-height:1.5;font-weight:550}
.bulk-restore-context{margin-top:18px}
.bulk-restore-context>summary{min-height:44px;display:flex;align-items:center;color:var(--muted);font-size:12px;cursor:pointer}
.bulk-restore-context:not([open])>.chat-current-settings{display:none}
html[data-design] .chats-page .chat-selection-head>.actions{flex-wrap:wrap;max-width:100%}
html[data-design] .app-page .btn.subscription-auto-renew{display:flex;align-items:center;justify-content:space-between;gap:20px;min-width:210px;max-width:100%;min-height:62px;padding:9px 7px;background:transparent;border:0;border-radius:6px;box-shadow:none;color:var(--text);font-size:12px;white-space:normal;text-align:left}
.subscription-renew-copy{display:flex;flex:1;min-width:0;flex-direction:column;gap:4px}
.subscription-auto-renew .settings-switch-label{font-size:12px;line-height:1.45;font-weight:500}
.subscription-auto-renew .settings-switch-status{display:flex;align-items:center;gap:6px;font-size:12px;line-height:1.5;font-weight:600;color:var(--muted)}
.subscription-auto-renew .settings-switch-status i{display:block;flex:none;width:6px;height:6px;border-radius:50%;background:currentColor}
.subscription-auto-renew .settings-switch-track{width:44px;height:26px;border-radius:14px;background:#677585}
.subscription-auto-renew .settings-switch-track:after{width:20px;height:20px;background:#fff;box-shadow:0 1px 3px #0003}
.subscription-auto-renew[aria-checked=true] .settings-switch-track{background:#187448}
.subscription-auto-renew[aria-checked=true] .settings-switch-track:after{transform:translateX(18px)}
.subscription-auto-renew[aria-checked=true] .settings-switch-status{color:var(--green)}
html[data-theme=dark] .subscription-auto-renew .settings-switch-track{background:#526171}
html[data-theme=dark] .subscription-auto-renew[aria-checked=true] .settings-switch-track{background:#278453}
.restore-switch input:checked~.settings-switch-track{background:var(--green)}
.restore-switch input:checked~.settings-switch-track:after{transform:translateX(16px)}
.restore-switch input:checked~.settings-switch-status{color:var(--green)}
html[data-design] .app-page .btn.subscription-auto-renew:hover:not(:disabled){background:var(--surface2)}
.subscription-auto-renew:focus-visible,.restore-switch:focus-within{outline:2px solid var(--accent);outline-offset:3px}
@media(max-width:760px){html[data-design] .app-page .account-entry-actions>.btn.subscription-auto-renew{flex:1 1 100%;max-width:300px}.app-page .wallet-subscription-action>.subscription-auto-renew{flex:1 1 100%;max-width:300px}}
.editor-restore{border-block:1px solid var(--line);padding:20px 0;display:flex;align-items:center;gap:20px}
.editor-restore>div:first-child{flex:1;min-width:0}
.editor-restore strong{font-size:14px;font-weight:550;line-height:1.5}
.editor-restore p{margin:5px 0 0;color:var(--muted);font-size:12px;line-height:1.6;max-width:48ch}
.restore-switch{position:relative;display:flex;align-items:center;gap:8px;min-height:44px;cursor:pointer;flex-shrink:0}
.restore-switch input{position:absolute;opacity:0;inset:0;width:100%;height:100%;margin:0;cursor:pointer;z-index:1}
.restore-switch .switch-on{display:none}
.restore-switch input:checked~.settings-switch-status .switch-off{display:none}
.restore-switch input:checked~.settings-switch-status .switch-on{display:inline}
.editor-restore .field{flex:0 1 225px;margin:0;min-width:0}
.editor-restore .field select{width:100%;font-size:12px}
@media(max-width:520px){.editor-restore{align-items:flex-start;gap:12px;flex-wrap:wrap}.editor-restore>div:first-child{flex-basis:100%}.editor-restore .field{flex-basis:100%}.restore-switch{margin-top:0}.bulk-scope>div{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:0 18px}}
@media(prefers-reduced-motion:reduce){.settings-switch-track,.settings-switch-track:after{transition:none}}

.notification-switch{display:flex;align-items:center;justify-content:flex-end;gap:10px;min-width:132px;min-height:44px;color:var(--muted)}
.notification-switch[aria-checked=true]{color:var(--green)}
.notification-switch[aria-checked=true] .settings-switch-track{background:var(--green)}
.notification-switch[aria-checked=true] .settings-switch-track:after{transform:translateX(16px)}
.notification-switch[aria-busy=true] .settings-switch-track{opacity:.55}
