/* Mobile dark-mode adapters for community, support, chat and editor chrome.
 * Authored rich text and personal profile/game artwork keep their own palette.
 */
@media (max-width: 1200px) {
	html[data-floweralba-theme="dark"] {
		--flower-community-accent: var(--fa-dm-accent);
		--flower-community-accent-dark: var(--fa-dm-accent);
		--flower-community-accent-soft: var(--fa-dm-accent-soft);
		--flower-community-text: var(--fa-dm-text);
		--flower-community-muted: var(--fa-dm-muted);
		--flower-community-line: var(--fa-dm-border);
		--flower-community-surface: var(--fa-dm-surface);
		--flower-community-soft: var(--fa-dm-raised);
		--flower-community-danger: var(--fa-dm-danger);
		--flower-community-shadow: 0 18px 50px rgba(0, 0, 0, .22);
		--fac-pink: var(--fa-dm-accent);
		--fac-pink-dark: var(--fa-dm-accent);
		--fac-pink-soft: var(--fa-dm-accent-soft);
		--fac-ink: var(--fa-dm-text);
		--fac-muted: var(--fa-dm-muted);
		--fac-line: var(--fa-dm-border);
		--fac-surface: var(--fa-dm-surface);
		--fac-canvas: var(--fa-dm-bg);
		--fac-danger: var(--fa-dm-danger);
	}

	/* KBoard's Flower Board skin also serves the customer center. */
	html[data-floweralba-theme="dark"] .flower-board {
		--flower-board-accent: var(--fa-dm-accent);
		--flower-board-accent-strong: var(--fa-dm-accent);
		--flower-board-accent-soft: var(--fa-dm-accent-soft);
		--flower-board-canvas: var(--fa-dm-bg);
		--flower-board-surface: var(--fa-dm-surface);
		--flower-board-surface-soft: var(--fa-dm-raised);
		--flower-board-text: var(--fa-dm-text);
		--flower-board-muted: var(--fa-dm-muted);
		--flower-board-border: var(--fa-dm-border);
		--flower-board-border-strong: var(--fa-dm-border-strong);
		--flower-board-success: var(--fa-dm-success);
		--flower-board-success-soft: #203c33;
		--flower-board-warning: var(--fa-dm-warning);
		--flower-board-warning-soft: #3c3424;
		--flower-board-info: #a3c5ff;
		--flower-board-info-soft: #25344b;
		--flower-board-danger: var(--fa-dm-danger);
		color: var(--fa-dm-text);
	}

	/* The parent theme colors heading elements directly, and its generated
	 * .case27-primary-text rule can be printed later with !important. Limit the
	 * override to template headings so authored document/comment colors survive. */
	html[data-floweralba-theme="dark"] .flower-board .flower-board__heading h1,
	html[data-floweralba-theme="dark"] .flower-board-list .flower-board-list__item-link h2,
	html[data-floweralba-theme="dark"] .flower-board-document .flower-board-document__header > h1,
	html[data-floweralba-theme="dark"] .flower-board-document .flower-board-document__attachments > h2,
	html[data-floweralba-theme="dark"] .flower-board-confirm .flower-board-confirm__panel > h1,
	html[data-floweralba-theme="dark"] .flower-board-hub .flower-board-hub__hero h2,
	html[data-floweralba-theme="dark"] .flower-board-hub .flower-board-hub__section-title h3 {
		color: var(--fa-dm-text) !important;
	}

	html[data-floweralba-theme="dark"].flower-board-page,
	html[data-floweralba-theme="dark"] :is(body.flower-board-page, body.flower-community-members-page),
	html[data-floweralba-theme="dark"] :is(body.flower-board-page, body.flower-community-members-page) :is(#c27-site-wrapper, .elementor, .elementor-section-wrap, .elementor-section, .e-con.e-parent, .i-section) {
		background-color: var(--fa-dm-bg) !important;
	}

	html[data-floweralba-theme="dark"] :is(.flower-board-channels, .flower-board-channels__item, .flower-board-channels__icon, .flower-board-channels__item.is-active .flower-board-channels__icon, .flower-board-list__layout, .flower-board-list__main, .flower-board-list__main > .flower-board__heading, .flower-board-category-tabs__track, .flower-board-list__toolbar, .flower-board-tags-editor__suggestions) {
		background: var(--fa-dm-surface);
		border-color: var(--fa-dm-border);
	}

	html[data-floweralba-theme="dark"] :is(.flower-board-list__tag-filter, .flower-board-list__item--popular, .flower-board-tags-editor__chip, .flower-board-document__tags a, .flower-board-category-tabs__hint, .flower-board--layout-feed .flower-board-list__comments--mobile) {
		background: var(--fa-dm-raised);
		color: var(--fa-dm-muted);
	}

	html[data-floweralba-theme="dark"] .flower-board-list__tag-filter a {
		background: var(--fa-dm-surface);
		color: var(--fa-dm-muted);
	}

	html[data-floweralba-theme="dark"] :is(.flower-board-list__tag-filter a:hover, .flower-board-tags-editor__suggestion:hover, .flower-board-tags-editor__suggestion:focus-visible, .flower-board-list__item-link:hover) {
		background: var(--fa-dm-raised);
		color: var(--fa-dm-text);
	}

	html[data-floweralba-theme="dark"] :is(.flower-board__button--primary, .flower-board-pagination li.active > a, .flower-board__new, .flower-board .kboard-comments-default .comments-submit-button input, .flower-board--comments-modern .flower-board-comments .comments-submit-button button) {
		color: #241c23 !important;
	}

	html[data-floweralba-theme="dark"] :is(.flower-board__button--danger, .flower-board__button--report:hover, .flower-board-report__feedback.is-error) {
		background: #402b35;
		border-color: #76505e;
	}

	html[data-floweralba-theme="dark"] :is(.flower-board-report__notice, .flower-board-report__login, .flower-board__privacy-note) {
		background: #3c3424;
		border-color: #736346;
		color: var(--fa-dm-warning);
	}

	html[data-floweralba-theme="dark"] :is(.flower-board__privacy-note span, .flower-board-tags-editor__feedback.is-notice) {
		color: var(--fa-dm-warning);
	}

	html[data-floweralba-theme="dark"] :is(.flower-board-document__views, .flower-board-document__comment-count, .flower-board-document__navigation time, .flower-board-tags-editor__count, .flower-board-tags-editor__chip > span:last-child, .flower-board-tags-editor__input-row > button) {
		color: var(--fa-dm-muted);
	}

	html[data-floweralba-theme="dark"] .flower-board-hub__hero {
		background: linear-gradient(135deg, var(--fa-dm-surface), var(--fa-dm-accent-soft));
		border-color: var(--fa-dm-border);
	}

	/* Ordinary category labels keep their distinct semantic hues. */
	html[data-floweralba-theme="dark"] :is(.flower-board__badge--category-free, .flower-board__badge--category-beauty, .flower-community-card__badge--free, .flower-community-card__badge--beauty) {
		color: var(--fa-dm-accent);
		background: var(--fa-dm-accent-soft);
	}

	html[data-floweralba-theme="dark"] :is(.flower-board__badge--category-question, .flower-community-card__badge--question) {
		color: #a3c5ff;
		background: #25344b;
	}

	html[data-floweralba-theme="dark"] :is(.flower-board__badge--category-daily, .flower-board__badge--popular, .flower-community-card__badge--daily) {
		color: #cfb9ff;
		background: #352c49;
	}

	html[data-floweralba-theme="dark"] :is(.flower-board__badge--category-food, .flower-community-card__badge--food) {
		color: var(--fa-dm-warning);
		background: #3c3424;
	}

	html[data-floweralba-theme="dark"] :is(.flower-board__badge--category-work, .flower-community-card__badge--work) {
		color: var(--fa-dm-success);
		background: #203c33;
	}

	/* Modern comments contain several deliberate white !important surfaces. */
	html[data-floweralba-theme="dark"] .flower-board--comments-modern :is(.flower-board-document__comments, .flower-board-comments, .flower-board-comments .kboard-comments-wrap, .flower-board-comments__form) {
		background: var(--fa-dm-surface) !important;
		border-color: var(--fa-dm-border);
	}

	html[data-floweralba-theme="dark"] .flower-board--comments-modern :is(.flower-board-comments .comments-header, .flower-board-comments__thread, .flower-board-comments__input-shell, .flower-board-comments .comments-field-wrap, .flower-board-comments .flower-board-comment__menu-panel, .flower-board-comments .kboard-comments-login) {
		background: var(--fa-dm-surface);
		border-color: var(--fa-dm-border);
	}

	html[data-floweralba-theme="dark"] .flower-board--comments-modern :is(.flower-board-comments .comments-sort select, .flower-board-comments input[type="text"], .flower-board-comments input[type="password"], .flower-board-comments .comments-reply-form .kboard-comments-form, .flower-board-comment__restricted, .flower-board-comments .comments-list-file1 a, .flower-board-comments .flower-board-comment__reply-badge) {
		background-color: var(--fa-dm-raised);
		color: var(--fa-dm-text);
		border-color: var(--fa-dm-border);
	}

	html[data-floweralba-theme="dark"] .flower-board--comments-modern :is(.flower-board-comments .comments-header > p, .flower-board-comments .comments-field-label, .flower-board-comments .comments-list-create, .flower-board-comments .comments-list-file1, .flower-board-comments .comments-button-action, .flower-board-comments .flower-board-comment__menu-toggle, .flower-board-comments .flower-board-comment__menu-panel .comments-button-action, .flower-board-comments [data-flower-board-comment-file-name], .flower-board-comments__attachment label) {
		color: var(--fa-dm-muted);
	}

	html[data-floweralba-theme="dark"] .flower-board--comments-modern :is(.flower-board-comments .comments-list-username, .flower-board-comments .comments-button-action:hover, .flower-board-comments .comments-button-action:focus-visible, .flower-board-comments .flower-board-comment__menu-toggle:hover, .flower-board-comments .flower-board-comment__menu.is-open .flower-board-comment__menu-toggle) {
		color: var(--fa-dm-text);
	}

	html[data-floweralba-theme="dark"] .flower-board--comments-modern :is(.flower-board-comments .comments-button-action:hover, .flower-board-comments .comments-button-action:focus-visible, .flower-board-comments .flower-board-comment__menu-toggle:hover, .flower-board-comments .flower-board-comment__menu.is-open .flower-board-comment__menu-toggle, .flower-board-comments .comments-list-controller .comments-button-like.is-active) {
		background: var(--fa-dm-raised);
	}

	html[data-floweralba-theme="dark"] .flower-board--comments-modern :is(.flower-board-comments .flower-board-comment__author-badge, .flower-board-comments__attachment [data-flower-board-attachment-clear]:hover) {
		color: var(--fa-dm-accent);
		background: var(--fa-dm-accent-soft);
	}

	html[data-floweralba-theme="dark"] .flower-board--comments-modern .flower-board-comments .flower-board-comment__menu-panel .comments-button-delete {
		color: var(--fa-dm-danger);
	}

	html[data-floweralba-theme="dark"] .flower-board--comments-modern .flower-board-comments .comments-submit-button button:disabled:not([aria-busy="true"]) {
		background: var(--fa-dm-raised);
		color: var(--fa-dm-muted) !important;
	}

	/* Activity, notifications, rules, shop and inventory surroundings. */
	html[data-floweralba-theme="dark"] .flower-community-members--split {
		--flower-community-text: var(--fa-dm-text);
		--flower-community-muted: var(--fa-dm-muted);
		--flower-community-line: var(--fa-dm-border);
	}
	/* Theme headings and late generated text colors target the element itself.
	 * Keep these overrides on activity template labels, outside profile artwork. */
	html[data-floweralba-theme="dark"] .flower-community-members .flower-community-members__hero h1,
	html[data-floweralba-theme="dark"] .flower-community-members .flower-community-members__section-head h2,
	html[data-floweralba-theme="dark"] .flower-community-members .flower-community-members__settings-intro h2,
	html[data-floweralba-theme="dark"] .flower-community-members .flower-community-card__title-row > h3,
	html[data-floweralba-theme="dark"] .flower-community-members--login > div > h2 {
		color: var(--fa-dm-text) !important;
	}

	html[data-floweralba-theme="dark"] :is(.flower-community-members__tabs, .flower-community-nav, .flower-community-members--login > div, .flower-community-mention-picker, .flower-rank-progress, .flower-badge-cabinet, .flower-shop-item, .flower-inventory-empty, .flower-community-rules-banner, .flower-community-rules-content section, .flower-community-rules-page, .flower-community-members--split .flower-community-setting, .flower-community-members--split .flower-community-settings-link, .flower-community-members--split .flower-community-settings-rules > summary, .flower-community-members--split .flower-notification-preferences__fields) {
		color: var(--fa-dm-text);
		background: var(--fa-dm-surface);
		border-color: var(--fa-dm-border);
	}

	html[data-floweralba-theme="dark"] :is(.flower-community-members__tabs a, .flower-community-members__tabs a svg, .flower-community-nav a, .flower-community-action, .flower-community-card__excerpt, .flower-community-comment span, .flower-community-notification time, .flower-community-blocked-row span, .flower-community-comment p, .flower-community-notification p, .flower-community-rules-banner__description, .flower-community-rules-banner__action, .flower-community-rules-content li, .flower-community-rules-page > header p, .flower-community-anonymity__copy span, .flower-community-anonymity__alias > span, .flower-community-anonymity__alias > small, .flower-community-guest-notice span, .flower-community-guest-quota p, .flower-community-members--split .flower-community-members__groups a, .flower-community-members--split .flower-community-members__tabs a) {
		color: var(--fa-dm-muted);
	}

	html[data-floweralba-theme="dark"] :is(.flower-community-members__tabs a:hover, .flower-community-members__tabs a.is-active, .flower-community-members__tabs a.is-active svg, .flower-community-members--split .flower-community-members__groups a.is-active, .flower-community-members--split .flower-community-members__groups a:hover, .flower-community-members--split .flower-community-members__tabs a:hover, .flower-community-members--split .flower-community-members__tabs a.is-active) {
		color: var(--fa-dm-text);
		background-color: var(--fa-dm-raised);
		border-bottom-color: var(--fa-dm-border-strong);
	}
	/* The upper switch is segmented; the lower activity tabs retain their
	 * existing underline layout instead of inheriting a filled active pill. */
	html[data-floweralba-theme="dark"] .flower-community-members--split .flower-community-members__groups > a {
		color: var(--fa-dm-muted);
		background-color: transparent;
	}
	html[data-floweralba-theme="dark"] .flower-community-members--split .flower-community-members__groups > a:hover {
		color: var(--fa-dm-text);
		background-color: var(--fa-dm-surface);
	}
	html[data-floweralba-theme="dark"] .flower-community-members--split .flower-community-members__groups > a:is(.is-active, [aria-current="true"], [aria-current="page"], [aria-selected="true"]) {
		color: var(--fa-dm-button-text, #e6e6e6);
		background-color: var(--fa-dm-button, #3b3f45);
		border-color: var(--fa-dm-button, #3b3f45);
		box-shadow: none;
	}
	html[data-floweralba-theme="dark"] .flower-community-members--split .flower-community-members__tabs > a,
	html[data-floweralba-theme="dark"] .flower-community-members--split .flower-community-members__tabs > a:hover {
		color: var(--fa-dm-muted);
		background-color: transparent;
		border-bottom-color: transparent;
	}
	html[data-floweralba-theme="dark"] .flower-community-members--split .flower-community-members__tabs > a:hover {
		color: var(--fa-dm-text);
	}
	html[data-floweralba-theme="dark"] .flower-community-members--split .flower-community-members__tabs > a:is(.is-active, [aria-current="page"], [aria-selected="true"]) {
		color: var(--fa-dm-button-text, #e6e6e6);
		background-color: transparent;
		border-bottom-color: #f45f87;
	}
	/* Activity reading rows share the page canvas. The upper segmented switch,
	 * setting cards and colored labels retain their existing surfaces. */
	html[data-floweralba-theme="dark"] .flower-community-members.flower-community-members--split .flower-community-members__tabs,
	html[data-floweralba-theme="dark"] .flower-community-members--split .flower-community-members__panel,
	html[data-floweralba-theme="dark"] .flower-community-members--split .flower-community-members__panel .flower-community-members__section-head,
	html[data-floweralba-theme="dark"] .flower-community-members--split .flower-community-members__panel .flower-community-card,
	html[data-floweralba-theme="dark"] .flower-community-members--split .flower-community-members__panel .flower-community-card__main,
	html[data-floweralba-theme="dark"] .flower-community-members--split .flower-community-members__panel .flower-community-comment,
	html[data-floweralba-theme="dark"] .flower-community-members--split .flower-community-members__panel .flower-community-notification,
	html[data-floweralba-theme="dark"] .flower-community-members--split .flower-community-members__panel .flower-community-notification.is-unread {
		background: var(--fa-dm-bg);
	}
	html[data-floweralba-theme="dark"] .flower-community-members--split .flower-community-members__tabs > a > :is(.flower-notification-badge, .flower-community-tab-count, [data-flower-community-unread-count], strong) {
		border-color: transparent !important;
		box-shadow: none !important;
	}

	html[data-floweralba-theme="dark"] :is(.flower-community-card, .flower-community-comment, .flower-community-notification, .flower-community-blocked-row, .flower-rank-progress, .flower-badge-cabinet, .flower-shop-item, .flower-community-rules-content footer) {
		border-color: var(--fa-dm-border);
	}

	html[data-floweralba-theme="dark"] :is(.flower-community-card__side, .flower-community-card__comments--mobile, .flower-community-members--split .flower-community-card__side, .flower-gamification, .flower-shop, .flower-inventory, .flower-rank-road div, .flower-rank-progress__bar, .flower-anonymous-note, .flower-shop-item footer, .flower-community-rules-content footer, .flower-community-rules-banner__consent, .flower-community-anonymity, .flower-community-anonymity.is-locked, .flower-community-anonymity.is-guest, .flower-board--profile-community .flower-board-comments .flower-community-anonymity, .flower-community-members--split .flower-community-members__groups) {
		background: var(--fa-dm-raised);
		color: var(--fa-dm-muted);
		border-color: var(--fa-dm-border);
	}

	html[data-floweralba-theme="dark"] :is(.flower-community-rules-content h2, .flower-community-rules-page > header h1, .flower-community-rules-content footer strong, .flower-community-anonymity__copy b, .flower-community-anonymity__switch em, .flower-shop-item.is-equipped footer strong) {
		color: var(--fa-dm-text);
	}

	html[data-floweralba-theme="dark"] :is(.flower-community-notification.is-unread, .flower-community-members--split .flower-community-notification.is-unread, .flower-community-guest-notice, .flower-community-guest-quota, .flower-rank-road div.is-current) {
		background: var(--fa-dm-accent-soft);
		color: var(--fa-dm-text);
		border-color: var(--fa-dm-border);
	}

	html[data-floweralba-theme="dark"] :is(.flower-community-notification > .flower-community-notification__symbol, .flower-community-rules-banner__icon, .flower-community-anonymity__alias > button) {
		color: var(--fa-dm-accent);
		background: var(--fa-dm-accent-soft);
	}

	html[data-floweralba-theme="dark"] :is(.flower-community-members__section-actions button, .flower-community-blocked-row button, .flower-community-members--split .flower-community-members__section-actions button, .flower-community-members--split .flower-community-blocked-row button, .flower-badge-cabinet button, .flower-inventory-preview-actions button, .flower-shop-item footer button.is-remove) {
		color: var(--fa-dm-text);
		background: var(--fa-dm-surface);
		border-color: var(--fa-dm-border-strong);
	}

	html[data-floweralba-theme="dark"] :is(.flower-community-members__section-actions button:hover, .flower-badge-cabinet button:hover, .flower-inventory-preview-actions button:hover, .flower-shop-item footer button.is-remove:hover, .flower-community-members--split .flower-community-setting:hover, .flower-community-members--split .flower-community-settings-link:hover, .flower-community-members--split .flower-community-settings-rules > summary:hover) {
		color: var(--fa-dm-text);
		background: var(--fa-dm-raised);
		border-color: var(--fa-dm-border-strong);
	}

	html[data-floweralba-theme="dark"] :is(.flower-inventory-preview-actions button:disabled, .flower-shop-item footer button:disabled, .flower-badge > button:disabled) {
		color: var(--fa-dm-muted);
		background: var(--fa-dm-raised);
		border-color: var(--fa-dm-border);
	}

	html[data-floweralba-theme="dark"] .flower-shop-notice {
		background: #3c3424;
		border-color: #736346;
	}

	html[data-floweralba-theme="dark"] .flower-shop-notice p {
		color: var(--fa-dm-warning);
	}

	html[data-floweralba-theme="dark"] :is(.flower-community-members__empty a, .flower-community-members--login a, .flower-shop-item footer button:not(:disabled):not(.is-remove), .flower-shop-item footer a) {
		color: #241c23;
	}

	html[data-floweralba-theme="dark"] .flower-community-members--split .flower-community-members__empty a {
		background: var(--fa-dm-accent);
	}

	html[data-floweralba-theme="dark"] .flower-community-members--split .flower-notification-preferences__status[data-state="saved"] {
		color: var(--fa-dm-success);
	}

	/* Shared bell panel is appended independently of activity page markup. */
	html[data-floweralba-theme="dark"] .flower-notification-panel {
		--flower-notification-accent: var(--fa-dm-accent);
		background: var(--fa-dm-surface);
		color: var(--fa-dm-text);
		border-color: var(--fa-dm-border);
	}

	html[data-floweralba-theme="dark"] .flower-notification-panel :is(.flower-notification-panel__head, .flower-notification-panel__item, .flower-notification-panel__footer) {
		background: var(--fa-dm-surface);
		color: var(--fa-dm-text);
		border-color: var(--fa-dm-border);
	}

	html[data-floweralba-theme="dark"] .flower-notification-panel :is(.flower-notification-panel__title, .flower-notification-panel__copy strong) {
		color: var(--fa-dm-text);
	}

	html[data-floweralba-theme="dark"] .flower-notification-panel :is(.flower-notification-panel__message, .flower-notification-panel__time, .flower-notification-panel__status, .flower-notification-panel__read-all, .flower-notification-panel__close) {
		color: var(--fa-dm-muted);
	}

	html[data-floweralba-theme="dark"] .flower-notification-panel :is(.flower-notification-panel__item.is-unread, .flower-notification-panel__item:hover, .flower-notification-panel__item:focus-visible, .flower-notification-panel__symbol) {
		background: var(--fa-dm-accent-soft);
	}

	html[data-floweralba-theme="dark"] .flower-notification-panel :is(.flower-notification-panel__symbol, .flower-notification-panel__retry, .flower-notification-panel__footer:hover) {
		color: var(--fa-dm-accent);
		border-color: var(--fa-dm-border-strong);
	}

	html[data-floweralba-theme="dark"] .flower-notification-panel__feedback {
		color: var(--fa-dm-danger);
	}

	/* Chat messages are plain text; photograph/lightbox contents stay intact. */
	html[data-floweralba-theme="dark"] :is(.floweralba-chat-sidebar, .floweralba-chat-sidebar__header, .floweralba-chat-topbar, .floweralba-chat-room, .floweralba-chat-menu, .floweralba-chat-menu button, .floweralba-chat-context, .floweralba-chat-composer-wrap, .floweralba-chat-bubble, .floweralba-chat-dialog) {
		background: var(--fa-dm-surface);
		color: var(--fa-dm-text);
		border-color: var(--fa-dm-border);
	}

	html[data-floweralba-theme="dark"] :is(.floweralba-chat-icon-button, .floweralba-chat-back, .floweralba-chat-sender, .floweralba-chat-room__body time, .floweralba-chat-room__body small, .floweralba-chat-empty small, .floweralba-chat-reply span, .floweralba-chat-replying em, .floweralba-chat-replying button, .floweralba-chat-expired, .floweralba-chat-deleted, .floweralba-chat-message__meta, .floweralba-chat-message__meta button, .floweralba-chat-retention, .floweralba-chat-dialog label, .floweralba-chat-dialog__close) {
		color: var(--fa-dm-muted);
	}

	html[data-floweralba-theme="dark"] :is(.floweralba-chat-search, .floweralba-chat-notice, .floweralba-chat-load-older, .floweralba-chat-date span, .floweralba-chat-reply, .floweralba-chat-replying, .floweralba-chat-attach, .floweralba-chat-compose textarea, .floweralba-chat-dialog select, .floweralba-chat-dialog textarea) {
		background: var(--fa-dm-raised);
		color: var(--fa-dm-text);
		border-color: var(--fa-dm-border-strong);
	}

	html[data-floweralba-theme="dark"] :is(.floweralba-chat-room:hover, .floweralba-chat-room.is-active, .floweralba-chat-message.is-mine .floweralba-chat-bubble, .floweralba-chat-login, .floweralba-chat-fatal) {
		background: var(--fa-dm-accent-soft);
		border-color: var(--fa-dm-border);
	}

	html[data-floweralba-theme="dark"] :is(.floweralba-chat-icon-button:hover, .floweralba-chat-back:hover, .floweralba-chat-menu button:hover, .floweralba-chat-compose textarea:focus) {
		background: var(--fa-dm-raised);
		border-color: var(--fa-dm-accent);
	}

	html[data-floweralba-theme="dark"] :is(.floweralba-chat-reply strong, .floweralba-chat-replying strong, .floweralba-chat-notice button, .floweralba-chat-app.is-uploading .floweralba-chat-composer-wrap::before) {
		color: var(--fa-dm-accent);
	}

	html[data-floweralba-theme="dark"] :is(.floweralba-chat-compose > button, .floweralba-chat-start, .floweralba-chat-start:hover, .floweralba-chat-login a, .floweralba-chat-fatal button, .floweralba-chat-primary, .floweralba-chat-room > b, .floweralba-chat-unread.has-unread) {
		color: #241c23;
	}

	/* Play's night scenes, roulette artwork and score colors are intentional. */
	html[data-floweralba-theme="dark"] .fac-play {
		--fac-ink: var(--fa-dm-text);
		--fac-muted: var(--fa-dm-muted);
		--fac-line: var(--fa-dm-border);
		--fac-pink: var(--fa-dm-accent);
		--fac-paper: var(--fa-dm-bg);
		--fac-surface: var(--fa-dm-surface);
		--fac-selected: var(--fa-dm-raised);
		--fac-on-pink: #241c23;
		--fac-action-bg: var(--fa-dm-accent);
		--fac-action-text: #241c23;
	}

	html[data-floweralba-theme="dark"] .fac-play .fac-test-filters button:is(:hover, .is-active, [aria-pressed="true"]) {
		border-color: var(--fa-dm-border-strong);
	}

	html[data-floweralba-theme="dark"] .fac-play .fac-test-filters button:focus-visible {
		outline-color: var(--fa-dm-accent);
	}

	/* Editor chrome follows the theme; the writing canvas keeps author colors. */
	html[data-floweralba-theme="dark"] .floweralba-editor {
		--floweralba-editor-accent: var(--fa-dm-accent);
		--floweralba-editor-accent-soft: var(--fa-dm-accent-soft);
		--floweralba-editor-text: var(--fa-dm-text);
		--floweralba-editor-muted: var(--fa-dm-muted);
		--floweralba-editor-line: var(--fa-dm-border);
		--floweralba-editor-surface: var(--fa-dm-surface);
		--floweralba-editor-toolbar: var(--fa-dm-raised);
		color: var(--fa-dm-text);
	}

	html[data-floweralba-theme="dark"] .floweralba-editor :is(.floweralba-editor__group, .floweralba-editor__select, .floweralba-editor__link-panel, .floweralba-editor__box-panel, .floweralba-editor__emoji-panel, .floweralba-editor__upload-panel) {
		border-color: var(--fa-dm-border);
	}

	html[data-floweralba-theme="dark"] .floweralba-editor :is(.floweralba-editor__select, .floweralba-editor__link-panel, .floweralba-editor__box-panel, .floweralba-editor__emoji-panel, .floweralba-editor__upload-panel, .floweralba-editor__status, .floweralba-editor__box-option, .floweralba-editor__link-panel input, .floweralba-editor__link-panel button) {
		background-color: var(--fa-dm-surface);
		color: var(--fa-dm-text);
	}

	html[data-floweralba-theme="dark"] .floweralba-editor :is(.floweralba-editor__button, .floweralba-editor__color, .floweralba-editor__link-panel label, .floweralba-editor__emoji-header strong, .floweralba-editor__upload-header strong, .floweralba-editor__box-panel > strong) {
		color: var(--fa-dm-text);
	}

	html[data-floweralba-theme="dark"] .floweralba-editor :is(.floweralba-editor__emoji-tab, .floweralba-editor__emoji-empty, .floweralba-editor__upload-close, .floweralba-editor__emoji-close, .floweralba-editor__upload-hint, .floweralba-editor__upload-status, .floweralba-editor__link-panel small) {
		color: var(--fa-dm-muted);
	}

	html[data-floweralba-theme="dark"] .floweralba-editor :is(.floweralba-editor__button:hover, .floweralba-editor__button:focus-visible, .floweralba-editor__color:hover, .floweralba-editor__color:focus-within, .floweralba-editor__emoji-tab:hover, .floweralba-editor__emoji-tab:focus-visible, .floweralba-editor__upload-close:hover, .floweralba-editor__emoji-close:hover, .floweralba-editor__emoji-option:hover, .floweralba-editor__emoji-option:focus-visible, .floweralba-editor__box-option:hover, .floweralba-editor__box-option:focus-visible) {
		color: var(--fa-dm-text);
		background: var(--fa-dm-raised);
		border-color: var(--fa-dm-border-strong);
	}

	html[data-floweralba-theme="dark"] .floweralba-editor :is(.floweralba-editor__button.is-active, .floweralba-editor__emoji-tab.is-active) {
		color: var(--fa-dm-accent);
		background: var(--fa-dm-accent-soft);
	}

	html[data-floweralba-theme="dark"] .floweralba-editor :is(.floweralba-editor__upload-choose, .floweralba-editor__link-panel button[type="submit"]) {
		color: #241c23;
	}

	html[data-floweralba-theme="dark"] .floweralba-editor :is(.floweralba-editor__upload-status.is-error, .floweralba-editor__counter.is-near-limit) {
		color: var(--fa-dm-danger);
	}

	html[data-floweralba-theme="dark"] .floweralba-editor .floweralba-editor__upload-status.is-success {
		color: var(--fa-dm-success);
	}

	html[data-floweralba-theme="dark"] .floweralba-editor .floweralba-editor__counter.is-below-minimum {
		color: var(--fa-dm-warning);
	}
	/* Activity action controls use the same neutral button palette. */
	html[data-floweralba-theme="dark"] .flower-community-members :is(.flower-community-members__section-actions button, .flower-community-blocked-row button, .flower-community-card__side, .flower-community-members__pagination a, .flower-community-members__empty a, .flower-badge-cabinet button, .flower-inventory-preview-actions button, .flower-shop-item footer button, .flower-shop-item footer a):not(:disabled) {
		color: var(--fa-dm-button-text, #e6e6e6);
		background-color: var(--fa-dm-button, #3b3f45);
		border-color: var(--fa-dm-button, #3b3f45);
	}
	/* A plain comment composer can follow the site mode. Rich-editor canvases
	 * remain separate because their saved author colors must stay legible. */
	html[data-floweralba-theme="dark"] .flower-board .flower-board-comments textarea[name="comment_content"],
	html[data-floweralba-theme="dark"] .flower-board .flower-board-comments textarea[name="comment_content"]:focus {
		background-color: var(--fa-dm-surface);
		color: var(--fa-dm-text);
		color-scheme: dark;
	}
	html[data-floweralba-theme="dark"] .flower-board .flower-board-comments textarea[name="comment_content"]::placeholder {
		color: var(--fa-dm-muted);
		opacity: 1;
	}

	/* Do not recolor descendants: stored inline colors, callouts and previews
	 * must look the same in a rich editor. Published rich-text surfaces are
	 * classified by the shared read-only presentation controller. */
	html[data-floweralba-theme="dark"] :is(.flower-board .kboard-content textarea.wp-editor-area, .floweralba-editor__content, .floweralba-editor__prosemirror, .floweralba-editor .floweralba-editor__source) {
		--flower-board-text: #222630;
		--flower-board-muted: #747b88;
		--flower-board-accent-strong: #b52f5a;
		--floweralba-editor-text: #20252d;
		--floweralba-editor-muted: #747b86;
		--floweralba-editor-line: #e5e7eb;
		--floweralba-editor-surface: #fff;
		background-color: #fff;
		color: #222630;
		color-scheme: light;
	}
}
