﻿/* v626: independent classic palette; existing styles retain all responsive geometry.
   Important declarations in this layer override unlayered theme/room rules.
   app.js/app-wid.js suspend personal inline !important colours at their source.
   Suffix selectors match complete class tokens, even before state classes. */
@layer for314-classic {
  html.for314-classic-theme, html.for314-classic-theme body {
    color-scheme:light !important;
    --classic-stage:var(--for314-classic-background,#0d1117) !important;
    --classic-face:#d4d0c8 !important;
    --classic-field:#ffffff !important;
    --classic-text:#111111 !important;
    --classic-edge:#606060 !important;
    --classic-raised:inset 1px 1px 0 #ffffff,inset -1px -1px 0 #808080 !important;
    --classic-sunken:inset 1px 1px 0 #808080,inset -1px -1px 0 #ffffff !important;
    --bg:#0d1117 !important; --panel:#d4d0c8 !important; --panel2:#efefef !important;
    --text:#111111 !important; --muted:#404040 !important; --border:#606060 !important; --accent:#000080 !important;
    --chatbg:var(--classic-stage) !important; --wid-chat-bgc:var(--classic-stage) !important;
    --shell-bg:#0d1117 !important; --shell-panel:#d4d0c8 !important;
    --shell-text:#111111 !important; --shell-muted:#404040 !important; --shell-line:#606060 !important;
    --shell-active:#c0c0c0 !important; --shell-glass:#d4d0c8 !important;
    --shell-shine:transparent !important; --shell-input:#ffffff !important; --shell-shadow:transparent !important;
    --for314-room-accent:#d4d0c8 !important; --for314-room-accent-rgb:212,208,200 !important;
    --for314-room-send-fg:#111111 !important; --for314-composer-bg:#d4d0c8 !important; --for314-composer-fg:#111111 !important;
    --for314-chat-bubble-color:#d4d0c8 !important; --for314-chat-text-color:#111111 !important; --for314-message-text-color:#111111 !important;
    /* v634: use the existing room/local font owner, with a shell-only fallback. */
    font-family:var(--for314-room-font-family,Arial,"Hiragino Kaku Gothic ProN","Yu Gothic",Meiryo,sans-serif) !important;
    background:var(--classic-stage) !important; color:#111111 !important; filter:none !important;
  }
  html.for314-classic-theme :is(main,.wrap,.chat,.chatlog,#log,#multiroomShell) {
    background:var(--classic-stage) !important; background-image:none !important; filter:none !important; transition:none !important;
  }
  /* Keep the existing wallpaper layer, including maps and fireworks. The
     graveyard/jail renderer still controls whether wallpaper may be displayed. */
  html.for314-classic-theme body.for314-wallpaper-enabled :is(main,.wrap,.chat,.chatlog,#log) {
    background:transparent !important;
  }
  html.for314-classic-theme :is(button,input,textarea,select,dialog,fieldset,[role="button"],[role="dialog"],
    header,.inputrow,.room-tab-wrap,[class*="modal"],[class*="popup"],[class*="toast"],[class*="panel"],
    [class*="toolbar"],[class*="topbar"],[class*="titlebar"],[class*="title-bar"],[class*="bookmark"],
    [class*="command"],:is([class$="-card"],[class*="-card "]),[class*="-card-head"]) {
    border-radius:0 !important; backdrop-filter:none !important; -webkit-backdrop-filter:none !important; text-shadow:none !important;
  }
  /* Main chrome and dynamically created command windows use the same face. */
  html.for314-classic-theme :is(.tab-topbar,.room-tab-wrap,.room-tab,.room-tab-close,#roomTools,#shellStatus,
    .official-room-list,.official-room-item,header.profile-compact-header,#roomTitleText,.inputrow,
    [role="dialog"],dialog,:is([class$="-modal"],[class*="-modal "]),:is([class$="-popup"],[class*="-popup "]),:is([class$="-sheet"],[class*="-sheet "]),:is([class$="-panel"],[class*="-panel "]),
    :is([class$="-card"],[class*="-card "]),[class*="-card-head"],.command-modal-head,.command-modal-list,.command-row,
    .command-search-wrap,.command-category-nav,.profile-card,.profile-setting-row,.notification-rooms-head,
    .notification-room-item,.for314-reply-composer,.for314-attachment-palette,.for314-attachment-actions,
    .for314-image-attachments,.room-bookmark-bar,.room-bookmarks-bar,.native-like-alert-dialog,
    .native-like-confirm-dialog,.native-like-prompt-dialog,.native-like-alert-message,.native-like-confirm-message,
    .toast,.toast-message,.site-security-markdown,.site-security-modal) {
    background:var(--classic-face) !important; background-image:none !important;
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important;
    border-color:var(--classic-edge) !important; box-shadow:var(--classic-raised) !important; filter:none !important; transition:none !important;
  }
  html.for314-classic-theme :is(header.profile-compact-header,#roomTitleText,.inputrow,.tab-topbar,
    [role="dialog"],:is([class$="-modal"],[class*="-modal "]),:is([class$="-popup"],[class*="-popup "]),:is([class$="-card"],[class*="-card "])) {
    border:1px solid var(--classic-edge) !important;
  }
  html.for314-classic-theme .room-tab-wrap.active {box-shadow:var(--classic-sunken) !important; font-weight:700 !important;}
  html.for314-classic-theme :is(header.profile-compact-header,#roomTitleText,#roomTools,[role="dialog"],
    :is([class$="-modal"],[class*="-modal "]),:is([class$="-popup"],[class*="-popup "]),:is([class$="-sheet"],[class*="-sheet "]),.command-row,.toast,.for314-reply-composer)
    :is(h1,h2,h3,h4,p,label,span,strong,small,div,a,summary,code) {
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important; text-shadow:none !important; filter:none !important;
  }
  html.for314-classic-theme :is(.command-desc,.profile-compact-meta,.profile-compact-title,
    .profile-compact-roomline,.room,.status,.command-category,.command-search-empty) {
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important; text-shadow:none !important;
  }
  /* Public profile / own profile / editor: the sticky heading, bio and avatar
     fallback previously retained dark surfaces under forced black text. */
  html.for314-classic-theme :is(.direct-chat-head,.direct-chat-body,.direct-chat-actions,
    .direct-chat-profile-extra,.direct-chat-profile-bio,.direct-chat-result,
    .direct-chat-profile-editor,.direct-chat-profile-editor-group,.direct-chat-invite-list-head) {
    background:var(--classic-face) !important; background-image:none !important;
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important;
    border-color:var(--classic-edge) !important; border-radius:0 !important;
    text-shadow:none !important; filter:none !important;
  }
  html.for314-classic-theme :is(.direct-chat-avatar,.message-avatar,.profile-avatar,.direct-chat-invite-list-avatar) {
    background:var(--classic-face) !important; background-image:none !important;
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important;
    border-radius:0 !important; box-shadow:var(--classic-sunken) !important; text-shadow:none !important;
  }
  html.for314-classic-theme :is(.direct-chat-avatar,.message-avatar,.profile-avatar) img {
    border-radius:0 !important;
  }
  /* Raised controls and inset white fields. Notification switches retain their
     on/off semantics. No width, position, padding or safe-area overrides. */
  html.for314-classic-theme :is(button,[role="button"]):not([role="switch"]):not(.notification-toggle):not(.piano-key):not(.draw-color-btn):not(.flowergame-petal) {
    background:var(--classic-face) !important; background-image:none !important;
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important;
    border:1px solid var(--classic-edge) !important; box-shadow:var(--classic-raised) !important; filter:none !important; animation:none !important;
  }
  html.for314-classic-theme :is(button,[role="button"]):not([role="switch"]):not(.flowergame-petal):active {box-shadow:var(--classic-sunken) !important;}
  html.for314-classic-theme :is(button,input,textarea,select,[role="button"]):focus-visible {outline:2px solid #000080 !important; outline-offset:2px !important;}
  html.for314-classic-theme :is(input:not([type="checkbox"]):not([type="radio"]):not([type="range"]),textarea,select,#msgInput,#newRoomId,.command-search-input) {
    background:var(--classic-field) !important; background-image:none !important;
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important; caret-color:var(--classic-text) !important;
    border:1px solid #808080 !important; box-shadow:var(--classic-sunken) !important; filter:none !important; animation:none !important;
  }
  html.for314-classic-theme :is(input,textarea)::placeholder {
    color:#505050 !important; -webkit-text-fill-color:#505050 !important; opacity:1 !important; text-shadow:none !important;
  }
  html.for314-classic-theme #imageBtn .for314-photo-icon {stroke:var(--classic-text) !important; fill:none !important; filter:none !important;}
  html.for314-classic-theme #imageBtn .for314-photo-icon-dot {fill:var(--classic-text) !important; stroke:none !important;}
  html.for314-classic-theme :is(.inputrow,header) button svg {color:var(--classic-text) !important; filter:none !important;}
  html.for314-classic-theme :is(header,.tab-topbar,.inputrow,#msgInput,#imageBtn,#commandBtn,#sendBtn,.message-bubble)::before,
  html.for314-classic-theme :is(header,.tab-topbar,.inputrow,#msgInput,#imageBtn,#commandBtn,#sendBtn,.message-bubble)::after {
    background:none !important; background-image:none !important; box-shadow:none !important; filter:none !important; animation:none !important;
  }
  /* Same sent/received colour, including AI, replies and feature-card chrome.
     Embedded photos, video, QR codes, canvas games and iframe content stay intact. */
  html.for314-classic-theme :is(.message-bubble,.image-message-bubble,.video-message-bubble,
    .for314-reply-quote-card,.reply-preview,.reply-quote,.reply-card,.stamp-chat-shell,.site-security-review-bubble,
    .privacy-policy-bubble,.superchat-card) {
    background:var(--classic-face) !important; background-image:none !important; border:1px solid var(--classic-edge) !important;
    border-radius:0 !important; box-shadow:var(--classic-raised) !important;
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important; text-shadow:none !important;
    backdrop-filter:none !important; -webkit-backdrop-filter:none !important; filter:none !important;
  }
  html.for314-classic-theme .message-bubble:not(.for314-glitch-bubble):not(.for314-dot-text-bubble),
  html.for314-classic-theme .message-bubble:not(.for314-glitch-bubble):not(.for314-dot-text-bubble)
    :is(span,p,a,strong,em,small,div,blockquote,pre,code,li,summary),
  html.for314-classic-theme :is(.for314-reply-quote-card,.reply-preview,.reply-card) * {
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important;
    background-image:none !important; text-shadow:none !important; filter:none !important;
  }
  html.for314-classic-theme :is(.for314-reply-quote-card,.reply-preview,.reply-quote,.reply-card) {
    border-left:3px solid #606060 !important; box-shadow:var(--classic-sunken) !important;
  }
  /* Give metadata a readable face on both the dark stage and arbitrary photos. */
  html.for314-classic-theme :is(.message-meta,.image-message-meta,.video-message-meta) {
    width:fit-content !important; max-width:100% !important; background:var(--classic-face) !important;
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important;
    text-shadow:none !important; box-shadow:none !important; filter:none !important; border-radius:0 !important;
  }
  html.for314-classic-theme :is(.message-meta,.image-message-meta,.video-message-meta) * {
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important; text-shadow:none !important; filter:none !important;
  }
  html.for314-classic-theme :is(.message-bubble,.message-meta,#msgInput,.inputrow)
    :is(.for314-personal-rainbow-text,.for314-personal-rainbow-run,[class*="personal-color"]) {
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important; background:none !important; animation:none !important;
  }
  html.for314-classic-theme :is(.for314-personal-rainbow-text,.for314-light-white-text-shadow) {text-shadow:none !important; animation:none !important;}
  html.for314-classic-theme :is([class*="backdrop"],.modal-backdrop) {backdrop-filter:none !important; -webkit-backdrop-filter:none !important;}
  html.for314-classic-theme :is(.danger,.is-danger,[data-action="delete"],.ban-appeal-error) {color:#8b0000 !important; -webkit-text-fill-color:#8b0000 !important;}
  html.for314-classic-theme [role="dialog"] :is(:is([class$="-head"],[class*="-head "]),:is([class$="-body"],[class*="-body "]),:is([class$="-foot"],[class*="-foot "]),:is([class$="-footer"],[class*="-footer "]),:is([class$="-section"],[class*="-section "])) {
    background:var(--classic-face) !important; background-image:none !important;
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important; box-shadow:none !important;
  }
  html.for314-classic-theme :is(.profile-compact-main,.profile-compact-info,.profile-compact-roomline) {
    border-radius:0 !important; backdrop-filter:none !important; -webkit-backdrop-filter:none !important;
  }
  html.for314-classic-theme header.profile-compact-header .room {
    background:var(--classic-face) !important; background-image:none !important;
    border:0 !important; border-radius:0 !important; box-shadow:none !important;
    backdrop-filter:none !important; -webkit-backdrop-filter:none !important;
  }
  html.for314-classic-theme :is(#roomTitleText,.transport-badge) {border-radius:0 !important;}
  html.for314-classic-theme header.profile-compact-header .room::before,
  html.for314-classic-theme header.profile-compact-header .room::after,
  html.for314-classic-theme #roomTitleText::before,
  html.for314-classic-theme #roomTitleText::after {content:none !important; background:none !important; box-shadow:none !important;}
  html.for314-classic-theme :is(button.selected,button.is-active,[role="button"][aria-pressed="true"]) {
    box-shadow:var(--classic-sunken) !important; font-weight:700 !important;
  }
  html.for314-classic-theme #drawColorPalette .draw-color-btn {background:var(--sw) !important;}
  html.for314-classic-theme .piano-key.white {background:#ffffff !important; color:#111111 !important;}
  html.for314-classic-theme .piano-key.black {background:#111111 !important; color:#ffffff !important;}
  html.for314-classic-theme .direct-chat-admin-ban {color:#8b0000 !important; -webkit-text-fill-color:#8b0000 !important;}

  /* v623: mention portal and shared alert/confirm paper deck are created
     outside the chat. Keep their geometry, selection and FIFO behaviour. */
  html.for314-classic-theme :is(.for314-mention-menu,.for314-mention-scroll,
    .for314-mention-group,.for314-mention-row,.for314-prompt-card) {
    background:var(--classic-face) !important; background-image:none !important;
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important;
    border-radius:0 !important; border-color:var(--classic-edge) !important;
    backdrop-filter:none !important; -webkit-backdrop-filter:none !important;
    box-shadow:var(--classic-raised) !important; text-shadow:none !important;
  }
  html.for314-classic-theme :is(.for314-mention-group,.for314-mention-row,.for314-mention-scroll) {box-shadow:none !important;}
  html.for314-classic-theme :is(.for314-mention-name,.for314-mention-status,.for314-mention-main,
    .for314-prompt-message,.for314-prompt-actions) {
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important;
    background:none !important; text-shadow:none !important;
  }
  html.for314-classic-theme .for314-mention-menu {border:1px solid var(--classic-edge) !important;}
  html.for314-classic-theme .for314-mention-item:is(:hover,.is-active) {
    background:#c0c0c0 !important; box-shadow:var(--classic-sunken) !important;
    outline:1px dotted var(--classic-text) !important; outline-offset:-4px !important;
  }
  html.for314-classic-theme .for314-mention-avatar {border-radius:0 !important;}
  /* Use the native input text in classic, including on desktop: no overlapping
     transparent-input mention mirror over the opaque white classic field. */
  html.for314-classic-theme .for314-mention-input-highlight {display:none !important;}
  html.for314-classic-theme #msgInput.for314-mention-highlight-active {
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important;
  }

  /* v625: poll/form and anonymous age/gender surveys have nested dark
     surfaces. Theme those surfaces as well as the outer card. */
  html.for314-classic-theme :is(.poll-option,.poll-timer,.stats-survey-timer) {
    background:var(--classic-face) !important; background-image:none !important;
    border:1px solid var(--classic-edge) !important; border-radius:0 !important;
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important;
    box-shadow:var(--classic-sunken) !important; text-shadow:none !important;
    backdrop-filter:none !important; -webkit-backdrop-filter:none !important;
  }
  /* v626: poll root surfaces stay classic after the closed class is added. */
  html.for314-classic-theme :is(.poll-card,.stats-survey-card) {
    background:var(--classic-face) !important; background-image:none !important;
    border:1px solid var(--classic-edge) !important; border-radius:0 !important;
    box-shadow:var(--classic-raised) !important;
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important;
  }
  html.for314-classic-theme :is(.poll-head,.poll-label,.poll-question,.poll-option-main,
    .poll-option-text,.poll-option-count,.poll-actions,.poll-status,.poll-result,
    .stats-survey-head,.stats-survey-title,.stats-survey-question,.stats-survey-label,
    .stats-survey-count,.stats-survey-foot) {
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important;
    background:transparent !important; border-color:var(--classic-edge) !important;
    border-radius:0 !important; text-shadow:none !important;
  }
  html.for314-classic-theme .poll-option-main input[type="radio"] {accent-color:#111111 !important;}
  html.for314-classic-theme .poll-option:focus-within {outline:1px dotted var(--classic-text) !important; outline-offset:2px !important;}
  html.for314-classic-theme .poll-progress {
    background:#808080 !important; background-image:none !important; border-radius:0 !important;
  }
  html.for314-classic-theme .stats-survey-progress {
    background:#b8b4ac !important; background-image:none !important; border-radius:0 !important;
  }
  html.for314-classic-theme :is(#chatlog,#log) .stats-survey-option.selected {
    background:#c0c0c0 !important; border-color:var(--classic-edge) !important;
    box-shadow:var(--classic-sunken) !important; outline:1px dotted var(--classic-text) !important; outline-offset:-4px !important;
  }

  /* Room-list switch wrappers are role=switch, intentionally excluded from
     generic buttons. Their tracks receive the classic check treatment below. */
  html.for314-classic-theme :is(.notification-room-item,.notification-room-toggle,
    .notification-room-bell,.notification-room-current,.notification-room-title,.notification-room-status) {
    background:var(--classic-face) !important; background-image:none !important;
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important;
    border-radius:0 !important; border-color:var(--classic-edge) !important;
    box-shadow:var(--classic-raised) !important; text-shadow:none !important;
    backdrop-filter:none !important; -webkit-backdrop-filter:none !important;
  }
  html.for314-classic-theme :is(.notification-room-toggle-label,.notification-room-name,
    .notification-room-item-top,.notification-room-identity,.notification-room-labels,.notification-room-actions) {
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important;
    background:transparent !important; border-radius:0 !important; text-shadow:none !important;
  }

  /* Markdown replies use h3/h4 for # through ####. The legacy bubble
     readability rule sets their WebKit text fill to white explicitly. */
  html.for314-classic-theme .site-security-markdown :is(h1,h2,h3,h4,h5,h6) {
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important;
    text-shadow:none !important; -webkit-text-stroke:0 transparent !important;
  }

  /* v628: petals are game pieces, not raised rectangular UI controls.
     Keep the original pseudo-element flower shape and plucked animation. */
  html.for314-classic-theme button.flowergame-petal {
    background:transparent !important; border:0 !important; box-shadow:none !important;
  }
  /* Slide game: opaque classic surfaces throughout the lobby and playfield.
     No hitbox, lane geometry, pointer capture, scoring or timing changes. */
  html.for314-classic-theme :is(.slide-lobby-time,.slide-chip,.slide-game-head,
    .slide-game-timer,.slide-game-score,.slide-live-row,.slide-finish-overlay) {
    background:var(--classic-face) !important; background-image:none !important;
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important;
    border-color:var(--classic-edge) !important; border-radius:0 !important;
    box-shadow:var(--classic-raised) !important; text-shadow:none !important;
    backdrop-filter:none !important; -webkit-backdrop-filter:none !important;
  }
  html.for314-classic-theme :is(.slide-lobby-head,.slide-lobby-desc,.slide-chip,
    .slide-game-title,.slide-game-hud,.slide-game-timer,.slide-game-score,
    .slide-ready-kicker,.slide-ready-count,.slide-ready-note,.slide-lane-label,
    .slide-track-text,.slide-live-row,.slide-finish-overlay,.slide-finish-overlay strong,.slide-finish-overlay small) {
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important;
    text-shadow:none !important;
  }
  html.for314-classic-theme .slide-chip.is-me {box-shadow:var(--classic-sunken) !important; font-weight:700 !important;}
  html.for314-classic-theme :is(.slide-game-body,.slide-ready-wrap) {background:var(--classic-face) !important;}
  html.for314-classic-theme :is(.slide-game-board,.slide-track) {
    background:#efefef !important; background-image:none !important;
    border:1px solid var(--classic-edge) !important; border-radius:0 !important;
    box-shadow:var(--classic-sunken) !important;
  }
  html.for314-classic-theme .slide-game-board::before {background:none !important;}
  html.for314-classic-theme .slide-lanes::before {
    background:repeating-linear-gradient(to bottom,transparent 0,transparent calc(20% - 1px),#a0a0a0 calc(20% - 1px),#a0a0a0 20%) !important;
  }
  html.for314-classic-theme .slide-track::after {background:#b0b0b0 !important;}
  html.for314-classic-theme .slide-track-text::after {content:none !important; animation:none !important;}

  /* Dedicated graveyard/jail scenery sits below the chat at z-index:0.
     Leave the chat surfaces transparent so tombstones, spirits and bars show.
     The existing room renderer still hides personal wallpapers here. */
  html.for314-classic-theme.for314-graveyard-room :is(main,.wrap,.chat,.chatlog,#chatlog,#log) {
    background:transparent !important; background-image:none !important;
  }

  /* v629: automatic and manual translation share this result box below
     the message bubble. Its label and body must use the classic foreground. */
  html.for314-classic-theme .message-translation-result {
    background:var(--classic-face) !important; background-image:none !important;
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important;
    border:1px solid var(--classic-edge) !important; border-radius:0 !important;
    box-shadow:var(--classic-raised) !important; text-shadow:none !important;
    backdrop-filter:none !important; -webkit-backdrop-filter:none !important;
  }
  html.for314-classic-theme :is(.message-translation-result-label,.message-translation-result-text) {
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important;
    text-shadow:none !important;
  }
  /* v636: use a 70% black edge to rainbow glyphs on classic surfaces. */
  @supports ((background-clip:text) or (-webkit-background-clip:text)) {
    html.for314-classic-theme body #chatlog .message-bubble .for314-personal-rainbow-text.for314-personal-rainbow-text {
      background-image:linear-gradient(110deg,#ff755f 0%,#ffae4c 22%,#f0d750 38%,#52d47c 55%,#35c4cd 73%,#4b88ff 100%) !important;
      background-color:transparent !important;
      background-clip:text !important; -webkit-background-clip:text !important;
      color:transparent !important; -webkit-text-fill-color:transparent !important;
      -webkit-text-stroke:.2px rgba(0,0,0,.70) !important;
      text-shadow:none !important; filter:none !important;
    }
    /* v636: smaller reply text gets a finer black edge to retain the fill. */
    html.for314-classic-theme body #chatlog .message-bubble .for314-reply-quote-card .for314-personal-rainbow-text.for314-personal-rainbow-text {
      -webkit-text-stroke:.12px rgba(0,0,0,.70) !important;
    }
  }
  /* Keep the switch semantics, state and tap target; show a sunken checkbox. */
  html.for314-classic-theme .header-notification-switch {
    display:inline-flex !important; align-items:center !important; justify-content:center !important;
    background:transparent !important; border:0 !important; box-shadow:none !important;
  }
  html.for314-classic-theme :is(.header-notification-switch-track,.notification-room-toggle-track) {
    position:relative !important; display:block !important; flex:0 0 auto !important;
    width:22px !important; height:22px !important; box-sizing:border-box !important;
    border:1px solid #808080 !important; border-radius:0 !important;
    background:var(--classic-field) !important; background-image:none !important;
    box-shadow:var(--classic-sunken) !important; transition:none !important;
  }
  html.for314-classic-theme :is(.header-notification-switch-thumb,.notification-room-toggle-thumb) {display:none !important;}
  html.for314-classic-theme :is(.header-notification-switch-track,.notification-room-toggle-track)::after {
    content:""; position:absolute; left:7px; top:2px; width:6px; height:11px;
    box-sizing:border-box; border:solid #111111; border-width:0 3px 3px 0;
    transform:rotate(45deg); opacity:0; background:none; box-shadow:none;
  }
  html.for314-classic-theme :is(.header-notification-switch,.notification-room-toggle)[aria-checked="true"]
    :is(.header-notification-switch-track,.notification-room-toggle-track)::after {opacity:1;}
  html.for314-classic-theme .chat-toast {
    background:var(--classic-face) !important; background-image:none !important;
    color:var(--classic-text) !important; -webkit-text-fill-color:var(--classic-text) !important;
    border:1px solid var(--classic-edge) !important; border-radius:0 !important;
    box-shadow:var(--classic-raised) !important; text-shadow:none !important; filter:none !important;
    backdrop-filter:none !important; -webkit-backdrop-filter:none !important;
    animation:none !important;
  }
}
