Quellcode durchsuchen

added dislikes/favorites with local cache, added support for new version of linux-wallpaperengine-kde

UwU vor 1 Monat
Ursprung
Commit
812eab3a31
73 geänderte Dateien mit 2797 neuen und 927 gelöschten Zeilen
  1. 1 1
      README.md
  2. 1 1
      package.json
  3. 1 1
      packaging/aur/we-manager-bin/PKGBUILD
  4. 14 8
      patches/steamworks-vote/README.md
  5. 15 11
      patches/steamworks-vote/build.sh
  6. 29 7
      patches/steamworks-vote/steamworks-js-client-d-ts.patch
  7. 56 7
      patches/steamworks-vote/steamworks-js-workshop.patch
  8. 66 13
      patches/steamworks-vote/steamworks-rs-ugc.patch
  9. 28 9
      src/main/index.ts
  10. 22 7
      src/main/ipc/config.handlers.ts
  11. 17 0
      src/main/ipc/steam.handlers.ts
  12. 114 0
      src/main/services/appearance.service.ts
  13. 24 6
      src/main/services/config.service.ts
  14. 4 0
      src/main/services/lwe.service.test.ts
  15. 10 2
      src/main/services/lwe.service.ts
  16. 141 0
      src/main/services/steam-list-cache.test.ts
  17. 249 0
      src/main/services/steam-list-cache.ts
  18. 164 200
      src/main/services/steam.service.ts
  19. 30 11
      src/main/steam-host.ts
  20. 37 4
      src/preload/index.ts
  21. 44 1
      src/renderer/src/App.tsx
  22. 128 10
      src/renderer/src/assets/index.css
  23. 34 6
      src/renderer/src/components/common/ContextMenu.tsx
  24. 2 2
      src/renderer/src/components/common/CopyField.tsx
  25. 121 58
      src/renderer/src/components/common/DetailSidebar.tsx
  26. 30 5
      src/renderer/src/components/common/FilterPanel.tsx
  27. 47 41
      src/renderer/src/components/common/GridCard.tsx
  28. 8 8
      src/renderer/src/components/common/GridControls.tsx
  29. 201 0
      src/renderer/src/components/common/PreviewImage.tsx
  30. 2 2
      src/renderer/src/components/common/PreviewSizeToggle.tsx
  31. 1 1
      src/renderer/src/components/common/ScreenSelect.tsx
  32. 8 8
      src/renderer/src/components/common/ShortcutRow.tsx
  33. 1 1
      src/renderer/src/components/common/Toast.tsx
  34. 35 0
      src/renderer/src/components/common/Toggle.tsx
  35. 11 2
      src/renderer/src/components/common/WallpaperContextMenu.tsx
  36. 5 5
      src/renderer/src/components/common/sidebar/CompatSection.tsx
  37. 4 4
      src/renderer/src/components/common/sidebar/EngineFlagsSection.tsx
  38. 5 5
      src/renderer/src/components/common/sidebar/ImageAdjustmentsSection.tsx
  39. 7 7
      src/renderer/src/components/common/sidebar/ThumbnailSection.tsx
  40. 8 8
      src/renderer/src/components/common/sidebar/VideoTrimSection.tsx
  41. 32 27
      src/renderer/src/components/layout/Sidebar.tsx
  42. 3 3
      src/renderer/src/components/layout/StatusBar.tsx
  43. 57 30
      src/renderer/src/components/library/LibraryView.tsx
  44. 18 19
      src/renderer/src/components/library/WallpaperCard.tsx
  45. 7 7
      src/renderer/src/components/playlist/PlaylistItemRow.tsx
  46. 17 42
      src/renderer/src/components/playlist/PlaylistsView.tsx
  47. 14 17
      src/renderer/src/components/playlist/WallpaperPickerModal.tsx
  48. 191 0
      src/renderer/src/components/settings/AppearanceSettings.tsx
  49. 96 0
      src/renderer/src/components/settings/CardBorderSettings.tsx
  50. 1 1
      src/renderer/src/components/settings/DisplaySettings.tsx
  51. 4 4
      src/renderer/src/components/settings/LibraryFoldersSettings.tsx
  52. 24 37
      src/renderer/src/components/settings/PerformanceSettings.tsx
  53. 8 8
      src/renderer/src/components/settings/ScheduleSettings.tsx
  54. 51 146
      src/renderer/src/components/settings/SettingsView.tsx
  55. 0 41
      src/renderer/src/components/settings/VoteBorderSettings.tsx
  56. 12 12
      src/renderer/src/components/setup/SetupScreen.tsx
  57. 72 30
      src/renderer/src/components/workshop/WorkshopBrowser.tsx
  58. 12 13
      src/renderer/src/components/workshop/WorkshopCard.tsx
  59. 19 1
      src/renderer/src/constants/engineFlags.ts
  60. 71 0
      src/renderer/src/hooks/useCardBorders.ts
  61. 97 0
      src/renderer/src/hooks/useFavorites.ts
  62. 0 18
      src/renderer/src/hooks/useVoteBorders.ts
  63. 21 8
      src/renderer/src/hooks/useVotes.ts
  64. 3 0
      src/renderer/src/main.tsx
  65. 44 0
      src/renderer/src/utils/appearance.ts
  66. 42 0
      src/shared/appearance.test.ts
  67. 70 0
      src/shared/appearance.ts
  68. 22 0
      src/shared/cardBorders.test.ts
  69. 36 0
      src/shared/cardBorders.ts
  70. 2 0
      src/shared/engineFlags.test.ts
  71. 1 0
      src/shared/engineFlags.ts
  72. 9 1
      src/shared/ipc-channels.ts
  73. 16 0
      src/shared/types.ts

+ 1 - 1
README.md

@@ -17,7 +17,7 @@ still works as a local library manager.
   `flatpak install --user we-manager.flatpak` (needs Flathub for the runtime). To build it yourself:
   `packaging/flatpak/fetch-sources.sh`, then
   `flatpak-builder --user --install --force-clean build-dir packaging/flatpak/io.github.WallpaperEngineLover.we_manager.yml`.
-- **AUR**: `we-manager-bin`, with `linux-wallpaperengine-kde-bin` or `-git` for the engine.
+- **AUR** (coming soon, AUR registration is paused right now): `we-manager-bin`, with `linux-wallpaperengine-kde-bin` or `-git` for the engine. Until then use the AppImage.
 
 ## Running
 

+ 1 - 1
package.json

@@ -1,6 +1,6 @@
 {
   "name": "we-manager",
-  "version": "0.8.3",
+  "version": "0.8.4",
   "type": "module",
   "description": "Wallpaper Engine workshop manager",
   "author": "UwU <260361707+WallpaperEngineLover@users.noreply.github.com>",

+ 1 - 1
packaging/aur/we-manager-bin/PKGBUILD

@@ -1,4 +1,4 @@
-# Maintainer: UwU <260361707+WallpaperEngineLover@users.noreply.github.com>
+# Maintainer: WallpaperEngineLover <260361707+WallpaperEngineLover@users.noreply.github.com>
 # pkgver and the checksum are set by the aur job of .github/workflows/build.yml on every release
 pkgname=we-manager-bin
 _pkgname=we-manager

+ 14 - 8
patches/steamworks-vote/README.md

@@ -1,4 +1,4 @@
-# steamworks.js vote support patch
+# steamworks.js vote and favorites patch
 
 `steamworks.js` (the Node wrapper this app uses for all Steam integration) doesn't bind
 `ISteamUGC::SetUserItemVote`/`GetUserItemVote` at all - confirmed by reading its actual source and
@@ -17,12 +17,19 @@ Once built and in place, `we_manager` detects and uses them automatically (see
 `getPatchedVoteApi()` in `steam.service.ts`) - the app keeps working without this patch too, just
 falling back to "trust the vote, sync later" instead of genuine confirmation.
 
+Favorites (`ISteamUGC::AddItemToFavorites`/`RemoveItemFromFavorites`, the Workshop's "Favorite"
+button) have the same problem and are in the same patches: `addFavorite(appId, itemId)` and
+`removeFavorite(appId, itemId)`, resolved through `UserFavoriteItemsListChanged_t` (callback id
+3407, `k_iSteamUGCCallbacks` + 7). Without them `we_manager` calls the flat C functions through
+koffi and reports success once the call is enqueued, like votes. `build.sh` upgrades a clone that
+only has the older vote-only patch.
+
 ## What's in this directory
 
-- `steamworks-rs-ugc.patch` - adds `UGC::vote_up_item`/`UGC::user_item_vote` to the `steamworks`
-  Rust crate (`Noxime/steamworks-rs`), mirroring its existing `subscribe_item`/`unsubscribe_item`
+- `steamworks-rs-ugc.patch` - adds `UGC::vote_up_item`/`UGC::user_item_vote` and
+  `UGC::add_item_to_favorites`/`UGC::remove_item_from_favorites` to the `steamworks` Rust crate (`Noxime/steamworks-rs`), mirroring its existing `subscribe_item`/`unsubscribe_item`
   exactly.
-- `steamworks-js-workshop.patch` - adds the corresponding `voteItem`/`getUserVote` napi-exposed
+- `steamworks-js-workshop.patch` - adds the corresponding `voteItem`/`getUserVote`/`addFavorite`/`removeFavorite` napi-exposed
   async functions to `steamworks.js`'s own `src/api/workshop.rs`, mirroring its existing
   `subscribe`/`unsubscribe`.
 - `steamworks-js-client-d-ts.patch` - adds the matching TypeScript declarations to `client.d.ts`.
@@ -36,10 +43,9 @@ All three were generated against and verified (`git apply --check`) to apply cle
 - `Noxime/steamworks-rs` at the exact commit `steamworks.js`'s own `Cargo.toml` pins
   (`fbb79635b06b4feea8261e5ca3e8ea3ef42facf9`).
 
-**Not yet compiled or run** - this sandbox has no Rust toolchain, so the Rust code was written and
-verified by hand against the real upstream source (exact struct layouts/callback ids
-cross-checked against actual `bindgen`-generated output, not guessed) but never built. Do a real
-build + a real vote/like click before trusting it fully.
+Built with `npm run build:debug` (the addon then lists `voteItem`, `getUserVote`, `addFavorite` and
+`removeFavorite` under `workshop`). Votes were confirmed against real Steam; favorites have not been
+clicked against a real Steam account yet.
 
 ## Building it (on your real machine, which has Steam installed and running - required by
 ## steamworks.js's own build)

+ 15 - 11
patches/steamworks-vote/build.sh

@@ -1,5 +1,5 @@
 #!/usr/bin/env bash
-# Idempotent build script for the steamworks.js vote-support patch. Safe to re-run: every step
+# Idempotent build script for the steamworks.js vote and favorites patch. Safe to re-run: every step
 # checks whether it already happened before doing anything.
 #
 # Usage: ./build.sh [path-to-projects-dir]
@@ -32,19 +32,23 @@ if [ ! -d "$STEAMWORKSJS" ]; then
   git clone https://github.com/ceifa/steamworks.js "$STEAMWORKSJS"
 fi
 
+# A clone patched before favorites were added has only the vote half, so anything short of the
+# full patch is reset to upstream first and patched again.
+apply_patch() {
+  local repo="$1" file="$2" marker="$3" patch="$4"
+  if grep -q "$marker" "$repo/$file"; then
+    echo "    already applied"
+    return
+  fi
+  git -C "$repo" checkout -- "$file"
+  git -C "$repo" apply "$patch"
+}
+
 echo "==> Applying steamworks-rs patch (skipped if already applied)"
-if grep -q "vote_up_item" "$STEAMWORKS_RS/src/ugc.rs"; then
-  echo "    already applied"
-else
-  git -C "$STEAMWORKS_RS" apply "$PATCHES_DIR/steamworks-rs-ugc.patch"
-fi
+apply_patch "$STEAMWORKS_RS" src/ugc.rs add_item_to_favorites "$PATCHES_DIR/steamworks-rs-ugc.patch"
 
 echo "==> Applying steamworks.js patch (skipped if already applied)"
-if grep -q "vote_item" "$STEAMWORKSJS/src/api/workshop.rs"; then
-  echo "    already applied"
-else
-  git -C "$STEAMWORKSJS" apply "$PATCHES_DIR/steamworks-js-workshop.patch"
-fi
+apply_patch "$STEAMWORKSJS" src/api/workshop.rs add_favorite "$PATCHES_DIR/steamworks-js-workshop.patch"
 
 echo "==> Pointing steamworks.js's Cargo.toml at the local patched steamworks-rs (skipped if already done)"
 if grep -qF 'Noxime/steamworks-rs' "$STEAMWORKSJS/Cargo.toml" && grep -q '\[patch\.' "$STEAMWORKSJS/Cargo.toml"; then

+ 29 - 7
patches/steamworks-vote/steamworks-js-client-d-ts.patch

@@ -1,6 +1,8 @@
---- a/client.d.ts	2026-09-18 16:42:37.407700450 +0000
-+++ b/client.d.ts	2026-09-18 16:42:37.407700450 +0000
-@@ -268,6 +268,11 @@
+diff --git a/client.d.ts b/client.d.ts
+index a2501ab..5bb674b 100644
+--- a/client.d.ts
++++ b/client.d.ts
+@@ -268,6 +268,11 @@ export declare namespace workshop {
      current: bigint
      total: bigint
    }
@@ -12,22 +14,42 @@
    export const enum UpdateStatus {
      Invalid = 0,
      PreparingConfig = 1,
-@@ -297,6 +302,18 @@
+@@ -296,6 +301,30 @@ export declare namespace workshop {
+    * {@link https://partner.steamgames.com/doc/api/ISteamUGC#UnsubscribeItem}
     */
    export function unsubscribe(itemId: bigint): Promise<void>
-   /**
++  /**
 +   * Sets the current user's vote (up or down) on a workshop item.
 +   *
 +   * {@link https://partner.steamgames.com/doc/api/ISteamUGC#SetUserItemVote}
 +   */
 +  export function voteItem(itemId: bigint, voteUp: boolean): Promise<void>
 +  /**
++   * Adds a workshop item to the current user's favorites list.
++   *
++   * {@link https://partner.steamgames.com/doc/api/ISteamUGC#AddItemToFavorites}
++   */
++  export function addFavorite(appId: number, itemId: bigint): Promise<void>
++  /**
++   * Removes a workshop item from the current user's favorites list.
++   *
++   * {@link https://partner.steamgames.com/doc/api/ISteamUGC#RemoveItemFromFavorites}
++   */
++  export function removeFavorite(appId: number, itemId: bigint): Promise<void>
++  /**
 +   * Gets the current user's existing vote (if any) on a workshop item.
 +   *
 +   * {@link https://partner.steamgames.com/doc/api/ISteamUGC#GetUserItemVote}
 +   */
 +  export function getUserVote(itemId: bigint): Promise<UserItemVote>
-+  /**
+   /**
     * Gets the current state of a workshop item on this client. States can be combined.
     *
-    * @returns a number with the current item state, e.g. 9
+@@ -336,6 +365,7 @@ export declare namespace workshop {
+    * @returns an array of subscribed workshop item ids
+    */
+   export function getSubscribedItems(): Array<bigint>
++  export function deleteItem(itemId: bigint): Promise<void>
+   export const enum UGCQueryType {
+     RankedByVote = 0,
+     RankedByPublicationDate = 1,

+ 56 - 7
patches/steamworks-vote/steamworks-js-workshop.patch

@@ -1,6 +1,17 @@
---- a/src/api/workshop.rs	2026-09-18 16:42:37.406700437 +0000
-+++ b/src/api/workshop.rs	2026-09-18 16:42:37.406700437 +0000
-@@ -108,6 +108,13 @@
+diff --git a/src/api/workshop.rs b/src/api/workshop.rs
+index c8482ca..3046cbe 100644
+--- a/src/api/workshop.rs
++++ b/src/api/workshop.rs
+@@ -7,7 +7,7 @@ pub mod workshop {
+     use napi::threadsafe_function::ThreadsafeFunction;
+     use napi::threadsafe_function::ThreadsafeFunctionCallMode;
+     use std::path::Path;
+-    use steamworks::{ClientManager, FileType, PublishedFileId, UpdateHandle};
++    use steamworks::{AppId, ClientManager, FileType, PublishedFileId, UpdateHandle};
+     use tokio::sync::oneshot;
+ 
+     #[napi(object)]
+@@ -108,6 +108,13 @@ pub mod workshop {
          pub total: BigInt,
      }
  
@@ -14,11 +25,10 @@
      #[derive(Debug)]
      #[napi]
      pub enum UpdateStatus {
-@@ -319,6 +326,52 @@
-             Err(e) => Err(Error::from_reason(e.to_string())),
+@@ -320,6 +327,90 @@ pub mod workshop {
          }
      }
-+
+ 
 +    /// Sets the current user's vote (up or down) on a workshop item.
 +    ///
 +    /// {@link https://partner.steamgames.com/doc/api/ISteamUGC#SetUserItemVote}
@@ -40,6 +50,44 @@
 +        }
 +    }
 +
++    /// Adds a workshop item to the current user's favorites list.
++    ///
++    /// {@link https://partner.steamgames.com/doc/api/ISteamUGC#AddItemToFavorites}
++    #[napi]
++    pub async fn add_favorite(app_id: u32, item_id: BigInt) -> Result<(), Error> {
++        let client = crate::client::get_client();
++        let (tx, rx) = oneshot::channel();
++
++        client.ugc().add_item_to_favorites(
++            AppId(app_id),
++            PublishedFileId(item_id.get_u64().1),
++            |result| {
++                tx.send(result).unwrap();
++            },
++        );
++
++        rx.await.unwrap().map_err(|e| Error::from_reason(e.to_string()))
++    }
++
++    /// Removes a workshop item from the current user's favorites list.
++    ///
++    /// {@link https://partner.steamgames.com/doc/api/ISteamUGC#RemoveItemFromFavorites}
++    #[napi]
++    pub async fn remove_favorite(app_id: u32, item_id: BigInt) -> Result<(), Error> {
++        let client = crate::client::get_client();
++        let (tx, rx) = oneshot::channel();
++
++        client.ugc().remove_item_from_favorites(
++            AppId(app_id),
++            PublishedFileId(item_id.get_u64().1),
++            |result| {
++                tx.send(result).unwrap();
++            },
++        );
++
++        rx.await.unwrap().map_err(|e| Error::from_reason(e.to_string()))
++    }
++
 +    /// Gets the current user's existing vote (if any) on a workshop item.
 +    ///
 +    /// {@link https://partner.steamgames.com/doc/api/ISteamUGC#GetUserItemVote}
@@ -64,6 +112,7 @@
 +            Err(e) => Err(Error::from_reason(e.to_string())),
 +        }
 +    }
- 
++
      /// Gets the current state of a workshop item on this client. States can be combined.
      ///
+     /// @returns a number with the current item state, e.g. 9

+ 66 - 13
patches/steamworks-vote/steamworks-rs-ugc.patch

@@ -1,6 +1,8 @@
---- a/src/ugc.rs	2026-09-18 16:42:37.405700424 +0000
-+++ b/src/ugc.rs	2026-09-18 16:42:37.406700437 +0000
-@@ -517,6 +517,14 @@
+diff --git a/src/ugc.rs b/src/ugc.rs
+index 653ab11..bb93239 100644
+--- a/src/ugc.rs
++++ b/src/ugc.rs
+@@ -517,6 +517,14 @@ pub struct InstallInfo {
      pub timestamp: u32,
  }
  
@@ -15,13 +17,10 @@
  impl<Manager> UGC<Manager> {
      /// Suspends or resumes all workshop downloads
      pub fn suspend_downloads(&self, suspend: bool) {
-@@ -614,6 +622,63 @@
-                     })
-                 },
-             );
-+        }
-+    }
-+
+@@ -617,6 +625,114 @@ impl<Manager> UGC<Manager> {
+         }
+     }
+ 
 +    /// Sets the current user's vote (up or down) on a workshop item.
 +    ///
 +    /// {@link https://partner.steamgames.com/doc/api/ISteamUGC#SetUserItemVote}
@@ -49,6 +48,57 @@
 +        }
 +    }
 +
++    /// Adds a workshop item to the current user's favorites list.
++    ///
++    /// {@link https://partner.steamgames.com/doc/api/ISteamUGC#AddItemToFavorites}
++    pub fn add_item_to_favorites<F>(&self, app_id: AppId, published_file_id: PublishedFileId, cb: F)
++    where
++        F: FnOnce(Result<(), SteamError>) + 'static + Send,
++    {
++        unsafe {
++            let api_call =
++                sys::SteamAPI_ISteamUGC_AddItemToFavorites(self.ugc, app_id.0, published_file_id.0);
++            self.register_favorites_result(api_call, cb);
++        }
++    }
++
++    /// Removes a workshop item from the current user's favorites list.
++    ///
++    /// {@link https://partner.steamgames.com/doc/api/ISteamUGC#RemoveItemFromFavorites}
++    pub fn remove_item_from_favorites<F>(&self, app_id: AppId, published_file_id: PublishedFileId, cb: F)
++    where
++        F: FnOnce(Result<(), SteamError>) + 'static + Send,
++    {
++        unsafe {
++            let api_call = sys::SteamAPI_ISteamUGC_RemoveItemFromFavorites(
++                self.ugc,
++                app_id.0,
++                published_file_id.0,
++            );
++            self.register_favorites_result(api_call, cb);
++        }
++    }
++
++    unsafe fn register_favorites_result<F>(&self, api_call: sys::SteamAPICall_t, cb: F)
++    where
++        F: FnOnce(Result<(), SteamError>) + 'static + Send,
++    {
++        register_call_result::<sys::UserFavoriteItemsListChanged_t, _, _>(
++            &self.inner,
++            api_call,
++            CALLBACK_BASE_ID + 7,
++            move |v, io_error| {
++                cb(if io_error {
++                    Err(SteamError::IOFailure)
++                } else if v.m_eResult != sys::EResult::k_EResultOK {
++                    Err(v.m_eResult.into())
++                } else {
++                    Ok(())
++                })
++            },
++        );
++    }
++
 +    /// Gets the current user's existing vote (if any) on a workshop item.
 +    ///
 +    /// {@link https://partner.steamgames.com/doc/api/ISteamUGC#GetUserItemVote}
@@ -76,6 +126,9 @@
 +                    })
 +                },
 +            );
-         }
-     }
- 
++        }
++    }
++
+     /// Gets the publisher file IDs of all currently subscribed items.
+     pub fn subscribed_items(&self) -> Vec<PublishedFileId> {
+         unsafe {

+ 28 - 9
src/main/index.ts

@@ -2,7 +2,7 @@ import { app, BrowserWindow, net, protocol, shell } from 'electron'
 import path from 'path'
 import { pathToFileURL } from 'url'
 import { IpcChannels } from '@shared/ipc-channels'
-import { isSteamRunning, startVotedItemsSync, onFailedVotesChange, bindSteamToWindow } from './services/steam.service'
+import { isSteamRunning, startUserListSync, onFailedVotesChange, onFavoriteStatusChange, bindSteamToWindow } from './services/steam.service'
 import { initLibrary, checkUnavailableWallpapers, backfillResolutions, onHdrDetected, queueHdrCheck } from './services/library.service'
 import { startWatcher } from './services/watcher.service'
 import { checkOutdatedBackups } from './services/backup.service'
@@ -15,24 +15,38 @@ import { killAllLweProcesses, getLweStatus } from './services/lwe.service'
 import { initDisplay } from './services/display.service'
 import { initSchedule } from './services/schedule.service'
 import { hasStatusNotifierHost } from './utils/platform'
+import { attachAppearance, prepareAppearance, windowAppearanceOptions } from './services/appearance.service'
 
 const startMinimized = process.argv.includes('--minimized')
+prepareAppearance()
+
+// fetch() for GIF still frames in PreviewImage.tsx
+protocol.registerSchemesAsPrivileged([{ scheme: 'wallpaper', privileges: { supportFetchAPI: true, corsEnabled: true } }])
 let isQuitting = false
 let hasKilledLweOnQuit = false
 
 const BACKGROUND_SYNC_INTERVAL_MS = 3 * 60 * 1000
 const TRAY_HOST_WAIT_MS = 10_000
 
-// Keeps "liked" state and library availability fresh without the user having to restart the
-// app or click "Check unavailable" - votes cast on Steam directly (client, community website)
-// and items taken down from the Workshop both eventually show up on their own.
+// picks up votes/favorites made outside the app and items taken down from the Workshop
 function startBackgroundSync(win: BrowserWindow): void {
-  startVotedItemsSync((ids) => {
-    if (!win.isDestroyed()) win.webContents.send(IpcChannels.EVENT_VOTED_IDS_CHANGED, ids)
+  startUserListSync({
+    onLikedChange: (ids) => {
+      if (!win.isDestroyed()) win.webContents.send(IpcChannels.EVENT_VOTED_IDS_CHANGED, ids)
+    },
+    onDislikedChange: (ids) => {
+      if (!win.isDestroyed()) win.webContents.send(IpcChannels.EVENT_DISLIKED_IDS_CHANGED, ids)
+    },
+    onFavoritesChange: (ids) => {
+      if (!win.isDestroyed()) win.webContents.send(IpcChannels.EVENT_FAVORITE_IDS_CHANGED, ids)
+    }
   })
   onFailedVotesChange((failed) => {
     if (!win.isDestroyed()) win.webContents.send(IpcChannels.EVENT_FAILED_VOTES_CHANGED, failed)
   })
+  onFavoriteStatusChange((status) => {
+    if (!win.isDestroyed()) win.webContents.send(IpcChannels.EVENT_FAVORITE_STATUS_CHANGED, status)
+  })
 
   const syncResolutions = async (): Promise<void> => {
     if (await backfillResolutions() && !win.isDestroyed()) {
@@ -100,8 +114,8 @@ function createWindow(): BrowserWindow {
     height: 800,
     minWidth: 900,
     minHeight: 600,
-    backgroundColor: '#0f0f0f',
-    titleBarStyle: 'hiddenInset',
+    ...windowAppearanceOptions(),
+    autoHideMenuBar: true,
     show: !startHidden,
     webPreferences: {
       preload: path.join(__dirname, '../preload/index.cjs'),
@@ -111,6 +125,8 @@ function createWindow(): BrowserWindow {
     }
   })
 
+  attachAppearance(win)
+
   win.webContents.setWindowOpenHandler(({ url }) => {
     shell.openExternal(url)
     return { action: 'deny' }
@@ -141,7 +157,10 @@ app.whenReady().then(() => {
   protocol.handle('wallpaper', async (request) => {
     const filePath = decodeURIComponent(request.url.replace('wallpaper://', ''))
     try {
-      return await net.fetch(pathToFileURL(filePath).toString())
+      const res = await net.fetch(pathToFileURL(filePath).toString())
+      const headers = new Headers(res.headers)
+      headers.set('Access-Control-Allow-Origin', '*')
+      return new Response(res.body, { status: res.status, headers })
     } catch {
       // File not on disk yet (e.g. still downloading) - a rejected fetch here
       // would otherwise surface as an uncaught net::ERR_FILE_NOT_FOUND

+ 22 - 7
src/main/ipc/config.handlers.ts

@@ -3,6 +3,9 @@ import { IpcChannels } from '@shared/ipc-channels'
 import * as path from 'path'
 import type { DisplayMode, EngineFlagPreset, EngineFlags, ExtraLibrary, SteamIdentity } from '@shared/types'
 import { BUILT_IN_PRESETS } from '@shared/engineFlags'
+import { isTranslucent, type Appearance } from '@shared/appearance'
+import type { CardBorders } from '@shared/cardBorders'
+import { applyLiveAppearance, getLaunchAppearance, isAppearanceRestartNeeded } from '../services/appearance.service'
 import {
   getConfiguredWorkshopPath,
   setConfiguredWorkshopPath,
@@ -36,8 +39,10 @@ import {
   setAutostartPlaylistId,
   getKillLweOnQuit,
   setKillLweOnQuit,
-  getVoteBorders,
-  setVoteBorders,
+  getCardBorders,
+  getAppearance,
+  setAppearance,
+  setCardBorders,
   getAudioScreen,
   setAudioScreen,
   getAmbientVolume,
@@ -62,6 +67,7 @@ import {
 import { resetDisplays } from '../services/display.service'
 import { stopPlaylist } from '../services/playlist-player.service'
 import { getDefaultWorkshopPath } from '../utils/paths'
+import { detectDesktopEnv } from '../utils/platform'
 import { DEFAULT_LWE_REPO } from '@shared/constants'
 import { restartWatcher } from '../services/watcher.service'
 import { importWEConfig } from '../services/library.service'
@@ -91,7 +97,7 @@ export function registerConfigHandlers(): void {
     autostartMinimized: getAutostartMinimized(),
     autostartPlaylistId: getAutostartPlaylistId(),
     killLweOnQuit: getKillLweOnQuit(),
-    voteBorders: getVoteBorders(),
+    cardBorders: getCardBorders(),
     audioScreen: getAudioScreen(),
     ambientVolume: getAmbientVolume(),
     defaultAudioSensitivity: getDefaultAudioSensitivity(),
@@ -101,7 +107,11 @@ export function registerConfigHandlers(): void {
     ignoredCreators: getIgnoredCreators(),
     engineFlags: getGlobalEngineFlags(),
     engineFlagPresets: [...BUILT_IN_PRESETS, ...getEngineFlagPresets()],
-    displayMode: getDisplayMode()
+    displayMode: getDisplayMode(),
+    appearance: getAppearance(),
+    appearanceRestartNeeded: isAppearanceRestartNeeded(),
+    windowTranslucent: isTranslucent(getLaunchAppearance()),
+    desktopEnv: detectDesktopEnv()
   }))
 
   ipcMain.handle(IpcChannels.CONFIG_GET_AUTOSTART_SUPPORTED, () => isAutostartSupported())
@@ -132,9 +142,14 @@ export function registerConfigHandlers(): void {
     return { ok: true }
   })
 
-  ipcMain.handle(IpcChannels.CONFIG_SET_VOTE_BORDERS, (_e, enabled: boolean) => {
-    setVoteBorders(enabled)
-    return { ok: true }
+  ipcMain.handle(IpcChannels.CONFIG_SET_CARD_BORDERS, (_e, borders: CardBorders) => {
+    return setCardBorders(borders)
+  })
+
+  ipcMain.handle(IpcChannels.CONFIG_SET_APPEARANCE, (_e, appearance: Partial<Appearance>) => {
+    const next = setAppearance(appearance)
+    applyLiveAppearance(next)
+    return next
   })
 
   ipcMain.handle(IpcChannels.CONFIG_SET_STEAM_IDENTITY, (_e, identity: SteamIdentity) => {

+ 17 - 0
src/main/ipc/steam.handlers.ts

@@ -120,6 +120,23 @@ export function registerSteamHandlers(win: BrowserWindow): void {
     return steam.getVotedUpItemIds()
   })
 
+  ipcMain.handle(IpcChannels.STEAM_GET_DISLIKED_IDS, () => {
+    return steam.getVotedDownItemIds()
+  })
+
+  ipcMain.handle(IpcChannels.STEAM_FAVORITE, async (_e, itemId: string, add: boolean) => {
+    const confirmed = await steam.setFavorite(BigInt(itemId), add)
+    return { ok: true, confirmed }
+  })
+
+  ipcMain.handle(IpcChannels.STEAM_GET_FAVORITE_IDS, () => {
+    return steam.getFavoriteItemIds()
+  })
+
+  ipcMain.handle(IpcChannels.STEAM_GET_FAVORITE_STATUS, () => {
+    return steam.getFavoriteStatus()
+  })
+
   ipcMain.handle(IpcChannels.STEAM_GET_FAILED_VOTES, () => {
     return steam.getFailedVotes()
   })

+ 114 - 0
src/main/services/appearance.service.ts

@@ -0,0 +1,114 @@
+import { app, nativeTheme, type BrowserWindow, type BrowserWindowConstructorOptions } from 'electron'
+import { isTranslucent, launchAppearanceKey, wantsBlur, type Appearance } from '@shared/appearance'
+import { getAppearance } from './config.service'
+import { detectDesktopEnv } from '../utils/platform'
+
+type Koffi = typeof import('koffi')
+
+// transparency and X11/Wayland are fixed at window creation
+let launchAppearance: Appearance | null = null
+let mainWindow: BrowserWindow | null = null
+
+function onX11(): boolean {
+  const ozone = app.commandLine.getSwitchValue('ozone-platform')
+  if (ozone) return ozone === 'x11'
+  return !process.env.WAYLAND_DISPLAY || process.env.ELECTRON_OZONE_PLATFORM_HINT === 'x11'
+}
+
+/** Before app ready: KWin only blurs X11 windows, so Wayland goes through XWayland */
+export function prepareAppearance(): void {
+  launchAppearance = getAppearance()
+  if (wantsBlur(launchAppearance) && detectDesktopEnv() === 'kde' && !onX11()) {
+    app.commandLine.appendSwitch('ozone-platform', 'x11')
+  }
+}
+
+export function getLaunchAppearance(): Appearance {
+  return launchAppearance ?? getAppearance()
+}
+
+export function isAppearanceRestartNeeded(): boolean {
+  const current = getAppearance()
+  const launch = getLaunchAppearance()
+  if (isTranslucent(current) !== isTranslucent(launch)) return true
+  if (onX11()) return false
+  return launchAppearanceKey(current) !== launchAppearanceKey(launch)
+}
+
+function darkBackground(theme: Appearance['theme']): boolean {
+  return theme === 'dark' || (theme === 'system' && nativeTheme.shouldUseDarkColors)
+}
+
+export function windowAppearanceOptions(): Pick<BrowserWindowConstructorOptions, 'transparent' | 'backgroundColor'> {
+  const appearance = getLaunchAppearance()
+  nativeTheme.themeSource = appearance.theme
+  if (isTranslucent(appearance)) return { transparent: true, backgroundColor: '#00000000' }
+  return { backgroundColor: darkBackground(appearance.theme) ? '#0e0f12' : '#f3f4f7' }
+}
+
+export function attachAppearance(win: BrowserWindow): void {
+  mainWindow = win
+  win.once('ready-to-show', () => updateBlur(getAppearance()))
+  win.on('show', () => updateBlur(getAppearance()))
+}
+
+export function applyLiveAppearance(appearance: Appearance): void {
+  nativeTheme.themeSource = appearance.theme
+  updateBlur(appearance)
+}
+
+let x11: {
+  display: unknown
+  blurAtom: bigint | number
+  change: (...args: unknown[]) => number
+  remove: (...args: unknown[]) => number
+  flush: (display: unknown) => number
+} | null = null
+
+function getX11(): typeof x11 {
+  if (x11) return x11
+  // eslint-disable-next-line @typescript-eslint/no-require-imports
+  const koffi: Koffi = require('koffi')
+  const lib = koffi.load('libX11.so.6')
+  const openDisplay = lib.func('void *XOpenDisplay(const char *name)')
+  const internAtom = lib.func('unsigned long XInternAtom(void *display, const char *name, int onlyIfExists)')
+  const display = openDisplay(null)
+  if (!display) throw new Error('XOpenDisplay failed')
+  x11 = {
+    display,
+    blurAtom: internAtom(display, '_KDE_NET_WM_BLUR_BEHIND_REGION', 0),
+    change: lib.func(
+      'int XChangeProperty(void *display, unsigned long w, unsigned long property, unsigned long type, int format, int mode, const uint8_t *data, int nelements)'
+    ),
+    remove: lib.func('int XDeleteProperty(void *display, unsigned long w, unsigned long property)'),
+    flush: lib.func('int XFlush(void *display)')
+  }
+  return x11
+}
+
+const XA_CARDINAL = 6
+const PROP_MODE_REPLACE = 0
+
+function nativeWindowId(win: BrowserWindow): bigint {
+  const handle = win.getNativeWindowHandle()
+  return handle.length >= 8 ? handle.readBigUInt64LE(0) : BigInt(handle.readUInt32LE(0))
+}
+
+// an empty _KDE_NET_WM_BLUR_BEHIND_REGION blurs the whole window
+function updateBlur(appearance: Appearance): void {
+  const win = mainWindow
+  if (!win || win.isDestroyed() || !onX11() || !isTranslucent(getLaunchAppearance())) return
+  try {
+    const lib = getX11()!
+    const id = nativeWindowId(win)
+    if (id === 0n) return
+    if (wantsBlur(appearance)) {
+      lib.change(lib.display, id, lib.blurAtom, XA_CARDINAL, 32, PROP_MODE_REPLACE, Buffer.alloc(8), 0)
+    } else {
+      lib.remove(lib.display, id, lib.blurAtom)
+    }
+    lib.flush(lib.display)
+  } catch (err) {
+    console.warn('[Appearance] Could not set the KDE blur property:', (err as Error)?.message ?? err)
+  }
+}

+ 24 - 6
src/main/services/config.service.ts

@@ -3,6 +3,8 @@ import * as fs from 'fs'
 import * as path from 'path'
 import { app } from 'electron'
 import { WE_APP_ID } from '@shared/constants'
+import { normalizeAppearance, type Appearance } from '@shared/appearance'
+import { normalizeCardBorders, type CardBorders } from '@shared/cardBorders'
 import type { DisplayMode, EngineFlagPreset, EngineFlags, ExtraLibrary, SteamIdentity } from '@shared/types'
 
 interface AppConfig {
@@ -20,8 +22,9 @@ interface AppConfig {
   autostartMinimized: boolean
   autostartPlaylistId: string | null
   killLweOnQuit: boolean
-  /** Green outline on liked wallpapers, red on ones whose like failed */
+  /** Legacy, only read to migrate into cardBorders */
   voteBorders: boolean
+  cardBorders: CardBorders | null
   recommendedFpsEnabled: boolean
   recommendedWebFpsEnabled: boolean
   audioScreen: string | null
@@ -39,6 +42,7 @@ interface AppConfig {
   engineFlags: EngineFlags
   engineFlagPresets: EngineFlagPreset[]
   displayMode: DisplayMode
+  appearance: Appearance
 }
 
 const store = new Store<AppConfig>({
@@ -60,6 +64,7 @@ const store = new Store<AppConfig>({
     autostartPlaylistId: null,
     killLweOnQuit: false,
     voteBorders: true,
+    cardBorders: null,
     audioScreen: null,
     ambientVolume: null,
     defaultAudioSensitivity: 1,
@@ -69,7 +74,8 @@ const store = new Store<AppConfig>({
     ignoredCreators: [],
     engineFlags: {},
     engineFlagPresets: [],
-    displayMode: 'shared'
+    displayMode: 'shared',
+    appearance: normalizeAppearance(undefined)
   }
 })
 
@@ -152,12 +158,24 @@ export function setKillLweOnQuit(enabled: boolean): void {
   store.set('killLweOnQuit', enabled)
 }
 
-export function getVoteBorders(): boolean {
-  return store.get('voteBorders')
+export function getAppearance(): Appearance {
+  return normalizeAppearance(store.get('appearance'))
 }
 
-export function setVoteBorders(enabled: boolean): void {
-  store.set('voteBorders', enabled)
+export function setAppearance(appearance: Partial<Appearance>): Appearance {
+  const next = normalizeAppearance({ ...getAppearance(), ...appearance })
+  store.set('appearance', next)
+  return next
+}
+
+export function getCardBorders(): CardBorders {
+  return normalizeCardBorders(store.get('cardBorders'), store.get('voteBorders'))
+}
+
+export function setCardBorders(borders: CardBorders): CardBorders {
+  const next = normalizeCardBorders(borders)
+  store.set('cardBorders', next)
+  return next
 }
 
 /** 'wallpaper-engine' connects under WE's app id, 'standalone' under a neutral test app id. Read on every connect. */

+ 4 - 0
src/main/services/lwe.service.test.ts

@@ -68,6 +68,10 @@ describe('buildHotswapLines', () => {
     ])
   })
 
+  it('switches the video decoder live', () => {
+    expect(buildHotswapLines({ hwdec: 'vaapi-copy' })).toEqual(['hwdec=vaapi-copy'])
+  })
+
   it('replaces the layer lists when either one is present, even empty', () => {
     expect(buildHotswapLines({ disabledObjects: [] })).toEqual(['layers=1'])
     expect(buildHotswapLines({ disabledObjects: ['12'], enabledObjects: ['fog'] })).toEqual([

+ 10 - 2
src/main/services/lwe.service.ts

@@ -16,6 +16,7 @@ import type {
   CrashPhase,
   EngineFlags,
   ScreenTarget,
+  HwdecBackend,
   XrayMode
 } from '@shared/types'
 import {
@@ -1278,6 +1279,10 @@ function supportsAnimationHotswap(): boolean {
   return supportsFlag('disable-animations=on')
 }
 
+function supportsHwdecHotswap(): boolean {
+  return supportsFlag('hwdec=<backend>')
+}
+
 // flags a hotswap can't change, a running engine launched with different ones has to be restarted
 function launchKey(options: LweLaunchOptions): string {
   const flags = options.engineFlags ?? {}
@@ -1286,7 +1291,7 @@ function launchKey(options: LweLaunchOptions): string {
     disabledEffects: supportsEffectHotswap() ? [] : (options.disabledEffects ?? []),
     enabledEffects: supportsEffectHotswap() ? [] : (options.enabledEffects ?? []),
     disableAnimations: supportsAnimationHotswap() ? false : !!flags.disableAnimations,
-    flags: engineFlagArgs(flags)
+    flags: engineFlagArgs(supportsHwdecHotswap() ? { ...flags, hwdec: undefined } : flags)
   })
 }
 
@@ -1322,6 +1327,7 @@ export interface HotswapOptions {
   disabledEffects?: string[]
   enabledEffects?: string[]
   disableAnimations?: boolean
+  hwdec?: HwdecBackend
 }
 
 /**
@@ -1344,6 +1350,7 @@ export function buildHotswapLines(options: HotswapOptions): string[] {
     for (const id of options.enabledEffects ?? []) lines.push(`enable-effect=${id}`)
   }
   if (options.disableAnimations !== undefined) lines.push(`disable-animations=${options.disableAnimations ? 'on' : 'off'}`)
+  if (options.hwdec !== undefined) lines.push(`hwdec=${options.hwdec}`)
   if (options.volume !== undefined) lines.push(`volume=${options.volume}`)
   if (options.fps !== undefined) lines.push(`fps=${options.fps}`)
   // on/off keeps engines without the disabled mode working
@@ -1476,7 +1483,8 @@ function hotswapOptionsFor(wallpaperPath: string, options: LweLaunchOptions): Ho
     ...(supportsEffectHotswap()
       ? { disabledEffects: options.disabledEffects ?? [], enabledEffects: options.enabledEffects ?? [] }
       : {}),
-    ...(supportsAnimationHotswap() ? { disableAnimations: !!options.engineFlags?.disableAnimations } : {})
+    ...(supportsAnimationHotswap() ? { disableAnimations: !!options.engineFlags?.disableAnimations } : {}),
+    ...(supportsHwdecHotswap() ? { hwdec: options.engineFlags?.hwdec ?? 'auto' } : {})
   }
 }
 

+ 141 - 0
src/main/services/steam-list-cache.test.ts

@@ -0,0 +1,141 @@
+import { afterEach, describe, expect, it, vi } from 'vitest'
+
+vi.mock('electron', () => ({ app: { on: () => {} } }))
+vi.mock('electron-store', () => ({
+  default: class {
+    private data: Record<string, unknown>
+    constructor(opts: { defaults: Record<string, unknown> }) {
+      this.data = structuredClone(opts.defaults)
+    }
+    get(key: string): unknown {
+      return this.data[key]
+    }
+    set(key: string, value: unknown): void {
+      this.data[key] = value
+    }
+  }
+}))
+
+import { SteamListCache, type ListSource, type VerifyListener } from './steam-list-cache'
+
+function source(lists: string[][], accountIds: number[] = [1]): ListSource & { syncs: number } {
+  const src = {
+    syncs: 0,
+    canSync: () => true,
+    getAccountId: async () => accountIds[Math.min(src.syncs, accountIds.length - 1)],
+    crawl: async (_account: number, onPage: (ids: string[]) => void) => {
+      const ids = lists[Math.min(src.syncs, lists.length - 1)]
+      src.syncs++
+      onPage(ids)
+      return new Set(ids)
+    }
+  }
+  return src
+}
+
+async function sync(cache: SteamListCache): Promise<void> {
+  ;(cache as unknown as { store: { set: (k: string, v: number) => void } }).store.set('lastFullSync', 0)
+  cache.maybeSync()
+  await vi.waitFor(() => expect((cache as unknown as { syncInFlight: boolean }).syncInFlight).toBe(false))
+}
+
+describe('SteamListCache', () => {
+  it('drops an id only after two crawls in a row miss it', async () => {
+    const cache = new SteamListCache('Test', 'test', source([['a', 'b'], ['a'], ['a']]))
+    await sync(cache)
+    expect(cache.list().sort()).toEqual(['a', 'b'])
+    await sync(cache)
+    expect(cache.has('b')).toBe(true)
+    await sync(cache)
+    expect(cache.has('b')).toBe(false)
+  })
+
+  it('keeps a local change over a crawl that has not caught up', async () => {
+    const cache = new SteamListCache('Test', 'test', source([['a']]))
+    cache.record('new', true)
+    cache.record('a', false)
+    await sync(cache)
+    expect(cache.has('new')).toBe(true)
+    expect(cache.has('a')).toBe(false)
+  })
+
+  it('lets a fresh local change win over the per-item check', () => {
+    const cache = new SteamListCache('Test', 'test', source([[]]))
+    cache.record('x', true)
+    expect(cache.applyCheck('x', false)).toBe(true)
+    expect(cache.has('x')).toBe(true)
+  })
+
+  it('starts over when the Steam account changes', async () => {
+    const onChange = vi.fn<(ids: string[]) => void>()
+    const cache = new SteamListCache('Test', 'test', source([['a'], ['z']], [1, 2]))
+    cache.onChange(onChange)
+    await sync(cache)
+    await sync(cache)
+    expect(cache.list()).toEqual(['z'])
+    expect(onChange).toHaveBeenCalled()
+  })
+
+  describe('read-back', () => {
+    afterEach(() => {
+      vi.useRealTimers()
+    })
+
+    it('confirms a change once the crawled list shows it', async () => {
+      vi.useFakeTimers()
+      const src = source([[], ['fav']])
+      const cache = new SteamListCache('Test', 'test', src)
+      const onVerified = vi.fn<VerifyListener>()
+      cache.onVerified(onVerified)
+      cache.record('fav', true)
+      expect(cache.unverified()).toEqual(['fav'])
+
+      await vi.advanceTimersByTimeAsync(15_000)
+      expect(src.syncs).toBe(1)
+      expect(onVerified).not.toHaveBeenCalled()
+      expect(cache.has('fav')).toBe(true)
+
+      await vi.advanceTimersByTimeAsync(45_000)
+      expect(src.syncs).toBe(2)
+      expect(onVerified).toHaveBeenCalledWith('fav', true, true)
+      expect(cache.unverified()).toEqual([])
+
+      await vi.advanceTimersByTimeAsync(30 * 60_000)
+      expect(src.syncs).toBe(2)
+    })
+
+    it('gives up on a change the list still contradicts after the pending TTL', async () => {
+      vi.useFakeTimers()
+      const src = source([['gone']])
+      const cache = new SteamListCache('Test', 'test', src)
+      const onVerified = vi.fn<VerifyListener>()
+      cache.onVerified(onVerified)
+      cache.record('gone', false)
+
+      await vi.advanceTimersByTimeAsync(10 * 60_000)
+      expect(onVerified).not.toHaveBeenCalled()
+      expect(cache.has('gone')).toBe(false)
+
+      await vi.advanceTimersByTimeAsync(6 * 60_000)
+      expect(onVerified).toHaveBeenCalledWith('gone', false, false)
+      expect(cache.has('gone')).toBe(true)
+    })
+
+    it('waits for Steam before reading back', async () => {
+      vi.useFakeTimers()
+      const src = source([['fav']])
+      let running = false
+      src.canSync = () => running
+      const cache = new SteamListCache('Test', 'test', src)
+      const onVerified = vi.fn<VerifyListener>()
+      cache.onVerified(onVerified)
+      cache.record('fav', true)
+
+      await vi.advanceTimersByTimeAsync(2 * 60_000)
+      expect(src.syncs).toBe(0)
+      running = true
+      await vi.advanceTimersByTimeAsync(60_000)
+      expect(onVerified).toHaveBeenCalledWith('fav', true, true)
+    })
+  })
+})

+ 249 - 0
src/main/services/steam-list-cache.ts

@@ -0,0 +1,249 @@
+import Store from 'electron-store'
+import { app } from 'electron'
+
+// a Steam Workshop list (liked, favorited) cached on disk, refreshed by a background crawl
+
+interface ListCacheStore {
+  accountId: number | null
+  // "up" = on the list, named after the liked list's layout
+  up: string[]
+  missing: string[]
+  lastFullSync: number
+  pending: Record<string, { up: boolean; at: number }>
+}
+
+export interface ListSource {
+  canSync: () => boolean
+  getAccountId: () => Promise<number>
+  crawl: (accountId: number, onPage: (ids: string[]) => void) => Promise<Set<string>>
+}
+
+// Steam's lists lag, local changes win until the crawl agrees or this runs out
+const PENDING_TTL_MS = 15 * 60 * 1000
+const SETTLE_MS = 10_000
+const PERSIST_DELAY_MS = 3000
+const FULL_SYNC_INTERVAL_MS = 12 * 60 * 60 * 1000
+const RETRY_AFTER_FAILURE_MS = 10 * 60 * 1000
+const PROGRESS_NOTIFY_INTERVAL_MS = 15 * 1000
+// read-back crawls after a local change, the last one past PENDING_TTL_MS gives up
+const VERIFY_STEPS_MS = [15_000, 60_000, 4 * 60_000, 10 * 60_000, PENDING_TTL_MS + 30_000]
+const VERIFY_RETRY_MS = 60_000
+
+export type VerifyListener = (id: string, on: boolean, confirmed: boolean) => void
+
+function sameIds(a: Set<string>, b: Set<string>): boolean {
+  if (a.size !== b.size) return false
+  for (const id of a) if (!b.has(id)) return false
+  return true
+}
+
+export class SteamListCache {
+  private store: Store<ListCacheStore>
+  private ids: Set<string>
+  // dropped only after two full crawls miss it, pagination drifts
+  private missingLastCycle: Set<string>
+  private pending: Map<string, { up: boolean; at: number }>
+  private persistTimer: ReturnType<typeof setTimeout> | null = null
+  private persistDirty = false
+  private syncInFlight = false
+  private lastSyncFailure = 0
+  private listener: ((ids: string[]) => void) | null = null
+  private verifyListener: VerifyListener | null = null
+  private verifyTimer: ReturnType<typeof setTimeout> | null = null
+  private lastCrawlStart = 0
+
+  constructor(
+    private label: string,
+    storeName: string,
+    private source: ListSource
+  ) {
+    this.store = new Store<ListCacheStore>({
+      name: storeName,
+      defaults: { accountId: null, up: [], missing: [], lastFullSync: 0, pending: {} }
+    })
+    this.ids = new Set(this.store.get('up'))
+    this.missingLastCycle = new Set(this.store.get('missing'))
+    this.pending = new Map(
+      Object.entries(this.store.get('pending')).filter(([, v]) => Date.now() - v.at <= PENDING_TTL_MS)
+    )
+    app.on('will-quit', () => this.flush())
+  }
+
+  has(id: string): boolean {
+    return this.ids.has(id)
+  }
+
+  list(): string[] {
+    return [...this.ids]
+  }
+
+  onChange(cb: (ids: string[]) => void): void {
+    this.listener = cb
+  }
+
+  /** Reports each local change once, after the read-back crawls confirm it or give up */
+  onVerified(cb: VerifyListener): void {
+    this.verifyListener = cb
+    this.scheduleVerify()
+  }
+
+  unverified(): string[] {
+    return [...this.pending.keys()]
+  }
+
+  private notify(): void {
+    this.listener?.([...this.ids])
+  }
+
+  /** A change made here and accepted by Steam */
+  record(id: string, on: boolean): void {
+    this.pending.set(id, { up: on, at: Date.now() })
+    if (on) this.ids.add(id)
+    else this.ids.delete(id)
+    this.missingLastCycle.delete(id)
+    this.persist()
+    this.scheduleVerify()
+  }
+
+  /** A local change younger than SETTLE_MS still wins */
+  applyCheck(id: string, on: boolean): boolean {
+    const pending = this.pending.get(id)
+    if (pending && Date.now() - pending.at < SETTLE_MS) return pending.up
+    this.pending.delete(id)
+    this.missingLastCycle.delete(id)
+    if (this.ids.has(id) !== on) {
+      if (on) this.ids.add(id)
+      else this.ids.delete(id)
+      this.persist()
+      this.notify()
+    }
+    return on
+  }
+
+  private applyPending(fresh: Set<string>): Set<string> {
+    const now = Date.now()
+    const merged = new Set(fresh)
+    for (const [id, change] of this.pending) {
+      const agrees = fresh.has(id) === change.up
+      if (agrees || now - change.at > PENDING_TTL_MS) {
+        this.pending.delete(id)
+        this.verifyListener?.(id, change.up, agrees)
+        continue
+      }
+      if (change.up) merged.add(id)
+      else merged.delete(id)
+    }
+    return merged
+  }
+
+  // batched, a 100k-id list is a few MB
+  private persist(): void {
+    this.persistDirty = true
+    if (this.persistTimer) return
+    this.persistTimer = setTimeout(() => this.flush(), PERSIST_DELAY_MS)
+  }
+
+  private flush(): void {
+    if (this.persistTimer) {
+      clearTimeout(this.persistTimer)
+      this.persistTimer = null
+    }
+    if (!this.persistDirty) return
+    this.persistDirty = false
+    this.store.set('up', [...this.ids])
+    this.store.set('missing', [...this.missingLastCycle])
+    this.store.set('pending', Object.fromEntries(this.pending))
+  }
+
+  private async runFullSync(): Promise<void> {
+    const accountId = await this.source.getAccountId()
+    const known = this.store.get('accountId')
+    if (known !== null && known !== accountId) {
+      this.ids = new Set()
+      this.missingLastCycle = new Set()
+      this.pending.clear()
+      this.notify()
+    }
+    this.store.set('accountId', accountId)
+
+    // additive, a partial crawl can't tell missing from not reached yet
+    let lastNotify = Date.now()
+    const seen = await this.source.crawl(accountId, (pageIds) => {
+      let added = false
+      for (const id of pageIds) {
+        if (!this.ids.has(id) && this.pending.get(id)?.up !== false) {
+          this.ids.add(id)
+          added = true
+        }
+      }
+      if (!added) return
+      this.persist()
+      if (Date.now() - lastNotify >= PROGRESS_NOTIFY_INTERVAL_MS) {
+        lastNotify = Date.now()
+        this.notify()
+      }
+    })
+
+    const fresh = this.applyPending(seen)
+    const merged = new Set(fresh)
+    const missingThisCycle = new Set<string>()
+    for (const id of this.ids) {
+      if (fresh.has(id) || this.missingLastCycle.has(id)) continue
+      merged.add(id)
+      missingThisCycle.add(id)
+    }
+    const changed = !sameIds(this.ids, merged)
+    this.missingLastCycle = missingThisCycle
+    this.ids = merged
+    this.store.set('lastFullSync', Date.now())
+    this.persist()
+    if (changed) this.notify()
+    console.log(`[Steam] ${this.label} synced: ${this.ids.size} items`)
+  }
+
+  maybeSync(): void {
+    if (this.syncInFlight || !this.source.canSync()) return
+    const now = Date.now()
+    if (now - this.store.get('lastFullSync') < FULL_SYNC_INTERVAL_MS) return
+    if (now - this.lastSyncFailure < RETRY_AFTER_FAILURE_MS) return
+    this.startSync()
+  }
+
+  private startSync(): void {
+    this.syncInFlight = true
+    this.lastCrawlStart = Date.now()
+    this.runFullSync()
+      .catch((err) => {
+        this.lastSyncFailure = Date.now()
+        console.warn(`[Steam] ${this.label} sync failed, will retry later:`, err?.message ?? err)
+      })
+      .finally(() => {
+        this.syncInFlight = false
+        this.scheduleVerify()
+      })
+  }
+
+  private scheduleVerify(): void {
+    if (!this.verifyListener) return
+    if (this.verifyTimer) clearTimeout(this.verifyTimer)
+    this.verifyTimer = null
+    if (this.syncInFlight || this.pending.size === 0) return
+    let due = Infinity
+    for (const { at } of this.pending.values()) {
+      // a crawl started before this step can't have seen the change
+      const step = VERIFY_STEPS_MS.find((s) => at + s > this.lastCrawlStart)
+      due = Math.min(due, step === undefined ? this.lastCrawlStart + VERIFY_RETRY_MS : at + step)
+    }
+    this.verifyTimer = setTimeout(() => this.verifyNow(), Math.max(0, due - Date.now()))
+  }
+
+  private verifyNow(): void {
+    this.verifyTimer = null
+    if (this.syncInFlight) return
+    if (!this.source.canSync()) {
+      this.verifyTimer = setTimeout(() => this.verifyNow(), VERIFY_RETRY_MS)
+      return
+    }
+    this.startSync()
+  }
+}

+ 164 - 200
src/main/services/steam.service.ts

@@ -2,13 +2,13 @@ import { execFileSync } from 'child_process'
 import * as fs from 'fs'
 import * as os from 'os'
 import * as path from 'path'
-import Store from 'electron-store'
 import { app, utilityProcess, type BrowserWindow, type UtilityProcess } from 'electron'
 import { WE_APP_ID, STANDALONE_APP_ID } from '@shared/constants'
-import type { DownloadProgressEvent, WorkshopAuthorInfo } from '@shared/types'
+import type { DownloadProgressEvent, FavoriteFailure, FavoriteStatus, WorkshopAuthorInfo } from '@shared/types'
 import { getSteamIdentity } from './config.service'
 import { encodeBigInts, decodeBigInts, type SteamHostResponse } from '../steam-host-protocol'
 import { hostCommand, isFlatpak } from '../utils/flatpak'
+import { SteamListCache } from './steam-list-cache'
 
 // Steam counts a process that called SteamAPI_Init as a running game, which also breaks Steam
 // Game Recording. Like WE's ui32.exe, the connection only lives while the window is shown.
@@ -293,6 +293,7 @@ const USER_ITEM_TYPE = 13 // UGCType.All, since WE items span multiple subtypes
 const CREATION_ORDER_DESC = 1
 const VOTED_UP = 2
 const VOTED_DOWN = 3
+const FAVORITED = 4
 const PAGE_FETCH_TIMEOUT_MS = 8000
 const VOTE_TIMEOUT_MS = 15000
 
@@ -324,73 +325,11 @@ async function getUserItemsPage(
   }
 }
 
-interface VoteCacheStore {
-  accountId: number | null
-  up: string[]
-  missing: string[]
-  lastFullSync: number
-  pending: Record<string, { up: boolean; at: number }>
-}
-
-const voteStore = new Store<VoteCacheStore>({
-  name: 'vote-cache',
-  defaults: { accountId: null, up: [], missing: [], lastFullSync: 0, pending: {} }
-})
-
-let votedUpCache = new Set<string>(voteStore.get('up'))
-
-// an id must be missing on two consecutive full crawls before it is dropped, to absorb pagination drift
-let missingLastCycle = new Set<string>(voteStore.get('missing'))
-
-// Steam's voted-up list lags behind the vote itself, so local votes stay authoritative until the crawl agrees or this window runs out
-const PENDING_VOTE_TTL_MS = 15 * 60 * 1000
-const pendingVotes = new Map<string, { up: boolean; at: number }>(
-  Object.entries(voteStore.get('pending')).filter(([, v]) => Date.now() - v.at <= PENDING_VOTE_TTL_MS)
-)
-
-function applyPendingVotes(fresh: Set<string>): Set<string> {
-  const now = Date.now()
-  const merged = new Set(fresh)
-  for (const [id, vote] of pendingVotes) {
-    if (fresh.has(id) === vote.up || now - vote.at > PENDING_VOTE_TTL_MS) {
-      pendingVotes.delete(id)
-      continue
-    }
-    if (vote.up) merged.add(id)
-    else merged.delete(id)
-  }
-  return merged
-}
-
-const PERSIST_DELAY_MS = 3000
-let persistTimer: ReturnType<typeof setTimeout> | null = null
-let persistDirty = false
-
-function persistVoteCache(): void {
-  persistDirty = true
-  if (persistTimer) return
-  persistTimer = setTimeout(flushVoteCache, PERSIST_DELAY_MS)
-}
-
-function flushVoteCache(): void {
-  if (persistTimer) {
-    clearTimeout(persistTimer)
-    persistTimer = null
-  }
-  if (!persistDirty) return
-  persistDirty = false
-  voteStore.set('up', [...votedUpCache])
-  voteStore.set('missing', [...missingLastCycle])
-  voteStore.set('pending', Object.fromEntries(pendingVotes))
-}
-
-app.on('will-quit', flushVoteCache)
-
 const VOTE_FETCH_CONCURRENCY = 3
 const PAGE_PACING_MS = 150
 
-// list sort orders use the item's publish date, not the vote date, so the only way to get the full liked list is to crawl all of it
-async function fetchVotedItems(
+// lists sort by publish date, not vote date, so a full list means crawling all of it
+async function fetchUserList(
   accountId: number,
   listType: number,
   onPage: (ids: string[]) => void
@@ -428,95 +367,48 @@ async function fetchVotedItems(
   return ids
 }
 
-const FULL_SYNC_INTERVAL_MS = 12 * 60 * 60 * 1000
-const SYNC_CHECK_INTERVAL_MS = 10 * 60 * 1000
-const SYNC_STARTUP_DELAY_MS = 20 * 1000
-const PROGRESS_NOTIFY_INTERVAL_MS = 15 * 1000
+function listSource(listType: number) {
+  return {
+    canSync: isSteamRunning,
+    getAccountId: getLocalAccountId,
+    crawl: (accountId: number, onPage: (ids: string[]) => void) => fetchUserList(accountId, listType, onPage)
+  }
+}
 
-let votedIdsChangeListener: ((ids: string[]) => void) | null = null
-let syncInFlight = false
-let lastSyncFailure = 0
+const likedList = new SteamListCache('Liked list', 'vote-cache', listSource(VOTED_UP))
+const dislikedList = new SteamListCache('Disliked list', 'dislike-cache', listSource(VOTED_DOWN))
+const favoriteList = new SteamListCache('Favorites', 'favorite-cache', listSource(FAVORITED))
 
-function notifyVotedIds(): void {
-  votedIdsChangeListener?.([...votedUpCache])
-}
+const WRITE_ATTEMPTS = 4
+const WRITE_RETRY_BASE_MS = 1500
+// Steam drops overlapping UGC writes
+const WRITE_GAP_MS = 400
 
-async function runFullSync(): Promise<void> {
-  const accountId = await getLocalAccountId()
-  if (voteStore.get('accountId') !== null && voteStore.get('accountId') !== accountId) {
-    votedUpCache = new Set()
-    missingLastCycle = new Set()
-    pendingVotes.clear()
-    notifyVotedIds()
-  }
-  voteStore.set('accountId', accountId)
-
-  let lastNotify = Date.now()
-  const seen = await fetchVotedItems(accountId, VOTED_UP, (pageIds) => {
-    let added = false
-    for (const id of pageIds) {
-      if (!votedUpCache.has(id) && pendingVotes.get(id)?.up !== false) {
-        votedUpCache.add(id)
-        added = true
-      }
-    }
-    if (!added) return
-    persistVoteCache()
-    if (Date.now() - lastNotify >= PROGRESS_NOTIFY_INTERVAL_MS) {
-      lastNotify = Date.now()
-      notifyVotedIds()
-    }
-  })
+let writeQueue: Promise<unknown> = Promise.resolve()
 
-  const fresh = applyPendingVotes(seen)
-  const merged = new Set(fresh)
-  const missingThisCycle = new Set<string>()
-  for (const id of votedUpCache) {
-    if (fresh.has(id)) continue
-    if (missingLastCycle.has(id)) continue
-    merged.add(id)
-    missingThisCycle.add(id)
-  }
-  const changed = !sameIds(votedUpCache, merged)
-  missingLastCycle = missingThisCycle
-  votedUpCache = merged
-  voteStore.set('lastFullSync', Date.now())
-  persistVoteCache()
-  if (changed) notifyVotedIds()
-  console.log(`[Steam] Liked list synced: ${votedUpCache.size} items`)
-}
-
-function maybeRunFullSync(): void {
-  if (syncInFlight || !isSteamRunning()) return
-  const now = Date.now()
-  if (now - voteStore.get('lastFullSync') < FULL_SYNC_INTERVAL_MS) return
-  if (now - lastSyncFailure < SYNC_CHECK_INTERVAL_MS) return
-  syncInFlight = true
-  runFullSync()
-    .catch((err) => {
-      lastSyncFailure = Date.now()
-      console.warn('[Steam] Liked list sync failed, will retry later:', err?.message ?? err)
-    })
-    .finally(() => {
-      syncInFlight = false
-    })
+function queueSteamWrite<T>(run: () => Promise<T>): Promise<T> {
+  const result = writeQueue.then(run)
+  writeQueue = result.catch(() => {}).then(() => sleep(WRITE_GAP_MS))
+  return result
 }
 
-function recordVote(idStr: string, voteUp: boolean): void {
-  pendingVotes.set(idStr, { up: voteUp, at: Date.now() })
-  if (voteUp) votedUpCache.add(idStr)
-  else votedUpCache.delete(idStr)
-  missingLastCycle.delete(idStr)
-  persistVoteCache()
+async function withRetry(what: string, attempt: () => Promise<void>): Promise<void> {
+  let lastErr: unknown
+  for (let i = 0; i < WRITE_ATTEMPTS; i++) {
+    if (i > 0) await sleep(WRITE_RETRY_BASE_MS * 2 ** (i - 1))
+    if (!isSteamRunning()) throw new Error(`Steam is not running - start Steam to ${what}`)
+    if (!(await isSteamOnline())) throw new Error('Steam is offline - check your internet connection and try again')
+    try {
+      await attempt()
+      return
+    } catch (err) {
+      lastErr = err
+      console.warn(`[Steam] Could not ${what} (attempt ${i + 1}/${WRITE_ATTEMPTS}):`, (err as Error)?.message ?? err)
+    }
+  }
+  throw lastErr
 }
 
-const VOTE_ATTEMPTS = 4
-const VOTE_RETRY_BASE_MS = 1500
-// Steam rejects or drops SetUserItemVote calls that overlap, so votes go out one at a time
-const VOTE_GAP_MS = 400
-
-let voteQueue: Promise<unknown> = Promise.resolve()
-
 // kept for this session only, a failure usually means Steam was busy or offline at the time
 const failedVotes = new Map<string, { up: boolean; message: string }>()
 let failedVotesChangeListener: ((failed: Record<string, string>) => void) | null = null
@@ -525,7 +417,7 @@ export function getFailedVotes(): Record<string, string> {
   const out: Record<string, string> = {}
   for (const [id, failure] of failedVotes) {
     // liked elsewhere since, e.g. on the website or picked up by the background sync
-    if (failure.up && votedUpCache.has(id)) failedVotes.delete(id)
+    if ((failure.up ? likedList : dislikedList).has(id)) failedVotes.delete(id)
     else out[id] = failure.message
   }
   return out
@@ -545,90 +437,162 @@ function setVoteFailure(idStr: string, failure: { up: boolean; message: string }
 }
 
 export function voteOnItemAndConfirm(itemId: bigint, voteUp: boolean): Promise<boolean> {
-  const run = voteQueue.then(() => voteWithRetry(itemId, voteUp))
-  voteQueue = run.catch(() => {}).then(() => sleep(VOTE_GAP_MS))
-  return run
-}
-
-async function voteWithRetry(itemId: bigint, voteUp: boolean): Promise<boolean> {
-  let lastErr: unknown
-  for (let attempt = 0; attempt < VOTE_ATTEMPTS; attempt++) {
-    if (attempt > 0) await sleep(VOTE_RETRY_BASE_MS * 2 ** (attempt - 1))
-    if (!isSteamRunning()) throw new Error('Steam is not running - start Steam to like wallpapers')
-    if (!(await isSteamOnline())) throw new Error('Steam is offline - check your internet connection and try again')
+  const idStr = itemId.toString()
+  return queueSteamWrite(async () => {
     try {
-      const ok = await voteOnce(itemId, voteUp)
-      setVoteFailure(itemId.toString(), null)
-      return ok
+      await withRetry(voteUp ? 'like wallpapers' : 'dislike wallpapers', () => voteOnce(itemId, voteUp))
     } catch (err) {
-      lastErr = err
-      console.warn(`[Steam] Vote on ${itemId} failed (attempt ${attempt + 1}/${VOTE_ATTEMPTS}):`, (err as Error)?.message ?? err)
+      const msg = (err as Error)?.message ?? String(err)
+      setVoteFailure(idStr, {
+        up: voteUp,
+        message: `${voteUp ? 'Like' : 'Dislike'} failed after ${WRITE_ATTEMPTS} attempts: ${msg}`
+      })
+      throw new Error(`Could not reach Steam to ${voteUp ? 'like' : 'dislike'} this wallpaper: ${msg}`)
     }
-  }
-  const msg = (lastErr as Error)?.message ?? String(lastErr)
-  setVoteFailure(itemId.toString(), {
-    up: voteUp,
-    message: `${voteUp ? 'Like' : 'Dislike'} failed after ${VOTE_ATTEMPTS} attempts: ${msg}`
+    setVoteFailure(idStr, null)
+    likedList.record(idStr, voteUp)
+    dislikedList.record(idStr, !voteUp)
+    return true
   })
-  throw new Error(`Could not reach Steam to ${voteUp ? 'like' : 'dislike'} this wallpaper: ${msg}`)
 }
 
 // Without the patched steamworks.js, success is reported once SetUserItemVote is enqueued: its result can't be read back,
 // because steamworks.js's manual dispatch loop consumes every call result on the shared Steam pipe first.
-async function voteOnce(itemId: bigint, voteUp: boolean): Promise<boolean> {
-  const idStr = itemId.toString()
+async function voteOnce(itemId: bigint, voteUp: boolean): Promise<void> {
   if (await patchedVoteApiAvailable()) {
     await withTimeout(steamCall('workshop.voteItem', itemId, voteUp), VOTE_TIMEOUT_MS, 'Vote')
   } else {
     await voteOnItem(itemId, voteUp)
   }
-  recordVote(idStr, voteUp)
-  return true
-}
-
-function sameIds(a: Set<string>, b: Set<string>): boolean {
-  if (a.size !== b.size) return false
-  for (const id of a) if (!b.has(id)) return false
-  return true
 }
 
 export async function getVotedUpItemIds(): Promise<string[]> {
-  return [...votedUpCache]
+  return likedList.list()
 }
 
-// a vote this fresh may not have reached Steam's per-item lookup yet
-const VOTE_SETTLE_MS = 10_000
+export function getVotedDownItemIds(): string[] {
+  return dislikedList.list()
+}
 
 export async function refreshItemVote(itemId: bigint): Promise<boolean | null> {
   if (!isSteamRunning() || !(await isSteamOnline().catch(() => false))) return null
-  const idStr = itemId.toString()
   const result = await withTimeout(checkUserVote(itemId), PAGE_FETCH_TIMEOUT_MS, 'getUserVote').catch((err) => {
     console.warn('[Steam] Per-item vote check failed:', err?.message ?? err)
     return null
   })
   if (!result) return null
+  dislikedList.applyCheck(itemId.toString(), result.votedDown)
+  return likedList.applyCheck(itemId.toString(), result.votedUp)
+}
+
+let hasPatchedFavoriteApi: boolean | null = null
+
+async function patchedFavoriteApiAvailable(): Promise<boolean> {
+  if (hasPatchedFavoriteApi === null) {
+    const [add, remove] = await Promise.all([
+      steamCall<boolean>('hasMethod', 'workshop.addFavorite'),
+      steamCall<boolean>('hasMethod', 'workshop.removeFavorite')
+    ])
+    hasPatchedFavoriteApi = add && remove
+  }
+  return hasPatchedFavoriteApi
+}
+
+// favorites belong to WE's app id, even when connected as Spacewar
+async function favoriteOnce(itemId: bigint, add: boolean): Promise<void> {
+  if (await patchedFavoriteApiAvailable()) {
+    const method = add ? 'workshop.addFavorite' : 'workshop.removeFavorite'
+    await withTimeout(steamCall(method, WE_APP_ID, itemId), VOTE_TIMEOUT_MS, 'Favorite')
+  } else {
+    await steamCall<bigint>('favoriteRaw', WE_APP_ID, itemId, add)
+  }
+}
+
+// session-only, like failedVotes
+const failedFavorites = new Map<string, FavoriteFailure>()
+let favoriteStatusListener: ((status: FavoriteStatus) => void) | null = null
 
-  const pending = pendingVotes.get(idStr)
-  if (pending && Date.now() - pending.at < VOTE_SETTLE_MS) return pending.up
-  pendingVotes.delete(idStr)
-  missingLastCycle.delete(idStr)
+export function getFavoriteStatus(): FavoriteStatus {
+  const failed: Record<string, FavoriteFailure> = {}
+  for (const [id, failure] of failedFavorites) {
+    // already as intended, e.g. changed on the website
+    if (favoriteList.has(id) === failure.add) failedFavorites.delete(id)
+    else failed[id] = failure
+  }
+  return { failed, checking: favoriteList.unverified() }
+}
+
+export function onFavoriteStatusChange(cb: (status: FavoriteStatus) => void): void {
+  favoriteStatusListener = cb
+}
+
+function favoriteStatusChanged(): void {
+  favoriteStatusListener?.(getFavoriteStatus())
+}
 
-  if (votedUpCache.has(idStr) !== result.votedUp) {
-    if (result.votedUp) votedUpCache.add(idStr)
-    else votedUpCache.delete(idStr)
-    persistVoteCache()
-    notifyVotedIds()
+favoriteList.onVerified((id, add, confirmed) => {
+  if (confirmed) {
+    failedFavorites.delete(id)
+  } else {
+    console.warn(`[Steam] Favorites list still ${add ? 'misses' : 'has'} ${id}, the change didn't stick`)
+    failedFavorites.set(id, {
+      add,
+      readBack: true,
+      message: `Steam accepted the ${add ? 'favorite' : 'removal'}, but your favorites list still ${add ? "doesn't show" : 'shows'} this wallpaper 15 minutes later`
+    })
   }
-  return result.votedUp
+  favoriteStatusChanged()
+})
+
+export function setFavorite(itemId: bigint, add: boolean): Promise<boolean> {
+  const idStr = itemId.toString()
+  return queueSteamWrite(async () => {
+    try {
+      await withRetry(add ? 'add favorites' : 'remove favorites', () => favoriteOnce(itemId, add))
+    } catch (err) {
+      const msg = (err as Error)?.message ?? String(err)
+      failedFavorites.set(idStr, {
+        add,
+        readBack: false,
+        message: `${add ? 'Adding to' : 'Removing from'} favorites failed after ${WRITE_ATTEMPTS} attempts: ${msg}`
+      })
+      favoriteStatusChanged()
+      throw new Error(`Could not reach Steam to ${add ? 'favorite' : 'unfavorite'} this wallpaper: ${msg}`)
+    }
+    failedFavorites.delete(idStr)
+    favoriteList.record(idStr, add)
+    favoriteStatusChanged()
+    return true
+  })
 }
 
-let voteSyncTimer: ReturnType<typeof setInterval> | null = null
+export function getFavoriteItemIds(): string[] {
+  return favoriteList.list()
+}
 
-export function startVotedItemsSync(onChange: (ids: string[]) => void): void {
-  votedIdsChangeListener = onChange
-  if (voteSyncTimer) return
-  setTimeout(maybeRunFullSync, SYNC_STARTUP_DELAY_MS)
-  voteSyncTimer = setInterval(maybeRunFullSync, SYNC_CHECK_INTERVAL_MS)
+const SYNC_CHECK_INTERVAL_MS = 10 * 60 * 1000
+const SYNC_STARTUP_DELAY_MS = 20 * 1000
+let listSyncTimer: ReturnType<typeof setInterval> | null = null
+
+export function startUserListSync(listeners: {
+  onLikedChange: (ids: string[]) => void
+  onDislikedChange: (ids: string[]) => void
+  onFavoritesChange: (ids: string[]) => void
+}): void {
+  likedList.onChange(listeners.onLikedChange)
+  dislikedList.onChange(listeners.onDislikedChange)
+  favoriteList.onChange((ids) => {
+    listeners.onFavoritesChange(ids)
+    if (failedFavorites.size > 0) favoriteStatusChanged()
+  })
+  if (listSyncTimer) return
+  const tick = (): void => {
+    likedList.maybeSync()
+    dislikedList.maybeSync()
+    favoriteList.maybeSync()
+  }
+  setTimeout(tick, SYNC_STARTUP_DELAY_MS)
+  listSyncTimer = setInterval(tick, SYNC_CHECK_INTERVAL_MS)
 }
 
 export async function getSubscribedItems(): Promise<string[]> {

+ 30 - 11
src/main/steam-host.ts

@@ -12,12 +12,14 @@ function init(appId: number): void {
   client = steamworks.init(appId)
 }
 
-// ISteamUGC::SetUserItemVote and ISteamUser::BLoggedOn are not bound in steamworks.js, so they
-// go through the flat C API. libsteam_api.so is already loaded by steamworks.js, dlopen just
-// returns the existing handle.
+// not bound in steamworks.js, so called through the flat C API of the already loaded libsteam_api.so
 let steamLib: ReturnType<Koffi['load']> | null = null
-let setUserItemVote: ((ugc: unknown, itemId: bigint, voteUp: boolean) => bigint) | null = null
-let ugcPtr: unknown = null
+let ugc: {
+  ptr: unknown
+  setUserItemVote: (ugc: unknown, itemId: bigint, voteUp: boolean) => bigint
+  addItemToFavorites: (ugc: unknown, appId: number, itemId: bigint) => bigint
+  removeItemFromFavorites: (ugc: unknown, appId: number, itemId: bigint) => bigint
+} | null = null
 let isLoggedOn: (() => boolean) | null = null
 
 function getSteamLib(): ReturnType<Koffi['load']> {
@@ -33,21 +35,37 @@ function getSteamLib(): ReturnType<Koffi['load']> {
   return steamLib
 }
 
-function voteRaw(itemId: bigint, voteUp: boolean): bigint {
-  if (!setUserItemVote) {
+function getUgc(): NonNullable<typeof ugc> {
+  if (!ugc) {
     // eslint-disable-next-line @typescript-eslint/no-require-imports
     const koffi: Koffi = require('koffi')
     const lib = getSteamLib()
     const ugcPtrType = koffi.pointer(koffi.opaque('ISteamUGC'))
-    ugcPtr = lib.func('SteamAPI_SteamUGC_v020', ugcPtrType, [])()
-    setUserItemVote = lib.func('SteamAPI_ISteamUGC_SetUserItemVote', 'uint64', [ugcPtrType, 'uint64', 'bool'])
+    ugc = {
+      ptr: lib.func('SteamAPI_SteamUGC_v020', ugcPtrType, [])(),
+      setUserItemVote: lib.func('SteamAPI_ISteamUGC_SetUserItemVote', 'uint64', [ugcPtrType, 'uint64', 'bool']),
+      addItemToFavorites: lib.func('SteamAPI_ISteamUGC_AddItemToFavorites', 'uint64', [ugcPtrType, 'uint32', 'uint64']),
+      removeItemFromFavorites: lib.func('SteamAPI_ISteamUGC_RemoveItemFromFavorites', 'uint64', [ugcPtrType, 'uint32', 'uint64'])
+    }
   }
-  const handle = setUserItemVote(ugcPtr, itemId, voteUp)
-  // k_uAPICallInvalid = 0 means the call failed immediately
+  return ugc
+}
+
+// 0 = k_uAPICallInvalid
+function voteRaw(itemId: bigint, voteUp: boolean): bigint {
+  const api = getUgc()
+  const handle = api.setUserItemVote(api.ptr, itemId, voteUp)
   if (handle === 0n) throw new Error('SetUserItemVote failed')
   return handle
 }
 
+function favoriteRaw(appId: number, itemId: bigint, add: boolean): bigint {
+  const api = getUgc()
+  const handle = add ? api.addItemToFavorites(api.ptr, appId, itemId) : api.removeItemFromFavorites(api.ptr, appId, itemId)
+  if (handle === 0n) throw new Error(add ? 'AddItemToFavorites failed' : 'RemoveItemFromFavorites failed')
+  return handle
+}
+
 function isOnline(): boolean {
   if (!isLoggedOn) {
     // eslint-disable-next-line @typescript-eslint/no-require-imports
@@ -68,6 +86,7 @@ async function call(method: string, args: unknown[]): Promise<unknown> {
   }
   if (!client) throw new Error('Steam not initialized')
   if (method === 'voteRaw') return voteRaw(args[0] as bigint, args[1] as boolean)
+  if (method === 'favoriteRaw') return favoriteRaw(args[0] as number, args[1] as bigint, args[2] as boolean)
   if (method === 'isOnline') return isOnline()
   if (method === 'hasMethod') {
     const [ns, fn] = (args[0] as string).split('.')

+ 37 - 4
src/preload/index.ts

@@ -1,5 +1,8 @@
 import { contextBridge, ipcRenderer } from 'electron'
 import { IpcChannels } from '../shared/ipc-channels'
+import type { Appearance } from '../shared/appearance'
+import type { CardBorders } from '../shared/cardBorders'
+import type { DesktopEnvironment } from '../shared/desktop'
 import type {
   WorkshopQueryParams,
   WorkshopQueryResult,
@@ -35,7 +38,8 @@ import type {
   ScreenTarget,
   ScreenAssignment,
   ScheduleRule,
-  CrashEvent
+  CrashEvent,
+  FavoriteStatus
 } from '../shared/types'
 import type { VideoSegment } from '../shared/videoTrim'
 
@@ -72,10 +76,18 @@ const api = {
       ipcRenderer.invoke(IpcChannels.STEAM_OPEN_WORKSHOP, itemId),
     getVotedIds: (): Promise<string[]> =>
       ipcRenderer.invoke(IpcChannels.STEAM_GET_VOTED_IDS),
+    getDislikedIds: (): Promise<string[]> =>
+      ipcRenderer.invoke(IpcChannels.STEAM_GET_DISLIKED_IDS),
     getFailedVotes: (): Promise<Record<string, string>> =>
       ipcRenderer.invoke(IpcChannels.STEAM_GET_FAILED_VOTES),
     checkVote: (itemId: string): Promise<boolean | null> =>
       ipcRenderer.invoke(IpcChannels.STEAM_CHECK_VOTE, itemId),
+    favorite: (itemId: string, add: boolean): Promise<{ ok: boolean; confirmed: boolean }> =>
+      ipcRenderer.invoke(IpcChannels.STEAM_FAVORITE, itemId, add),
+    getFavoriteIds: (): Promise<string[]> =>
+      ipcRenderer.invoke(IpcChannels.STEAM_GET_FAVORITE_IDS),
+    getFavoriteStatus: (): Promise<FavoriteStatus> =>
+      ipcRenderer.invoke(IpcChannels.STEAM_GET_FAVORITE_STATUS),
     getAuthorInfo: (steamId: string): Promise<WorkshopAuthorInfo | null> =>
       ipcRenderer.invoke(IpcChannels.STEAM_GET_AUTHOR_INFO, steamId)
   },
@@ -135,7 +147,7 @@ const api = {
       autostartMinimized: boolean
       autostartPlaylistId: string | null
       killLweOnQuit: boolean
-      voteBorders: boolean
+      cardBorders: CardBorders
       audioScreen: string | null
       ambientVolume: number | null
       defaultAudioSensitivity: number
@@ -146,6 +158,10 @@ const api = {
       engineFlags: EngineFlags
       engineFlagPresets: EngineFlagPreset[]
       displayMode: DisplayMode
+      appearance: Appearance
+      appearanceRestartNeeded: boolean
+      windowTranslucent: boolean
+      desktopEnv: DesktopEnvironment
     }> => ipcRenderer.invoke(IpcChannels.CONFIG_GET),
     setEngineFlags: (flags: EngineFlags): Promise<{ ok: boolean }> =>
       ipcRenderer.invoke(IpcChannels.CONFIG_SET_ENGINE_FLAGS, flags),
@@ -183,8 +199,10 @@ const api = {
       ipcRenderer.invoke(IpcChannels.CONFIG_SET_TRAY_ENABLED, enabled),
     setKillLweOnQuit: (enabled: boolean): Promise<{ ok: boolean }> =>
       ipcRenderer.invoke(IpcChannels.CONFIG_SET_KILL_LWE_ON_QUIT, enabled),
-    setVoteBorders: (enabled: boolean): Promise<{ ok: boolean }> =>
-      ipcRenderer.invoke(IpcChannels.CONFIG_SET_VOTE_BORDERS, enabled),
+    setCardBorders: (borders: CardBorders): Promise<CardBorders> =>
+      ipcRenderer.invoke(IpcChannels.CONFIG_SET_CARD_BORDERS, borders),
+    setAppearance: (appearance: Partial<Appearance>): Promise<Appearance> =>
+      ipcRenderer.invoke(IpcChannels.CONFIG_SET_APPEARANCE, appearance),
     setAutostart: (
       enabled: boolean,
       minimized: boolean,
@@ -441,6 +459,21 @@ const api = {
       ipcRenderer.on(IpcChannels.EVENT_VOTED_IDS_CHANGED, listener)
       return () => ipcRenderer.off(IpcChannels.EVENT_VOTED_IDS_CHANGED, listener)
     },
+    dislikedIdsChanged: (cb: (ids: string[]) => void): (() => void) => {
+      const listener = (_: Electron.IpcRendererEvent, ids: string[]) => cb(ids)
+      ipcRenderer.on(IpcChannels.EVENT_DISLIKED_IDS_CHANGED, listener)
+      return () => ipcRenderer.off(IpcChannels.EVENT_DISLIKED_IDS_CHANGED, listener)
+    },
+    favoriteIdsChanged: (cb: (ids: string[]) => void): (() => void) => {
+      const listener = (_: Electron.IpcRendererEvent, ids: string[]) => cb(ids)
+      ipcRenderer.on(IpcChannels.EVENT_FAVORITE_IDS_CHANGED, listener)
+      return () => ipcRenderer.off(IpcChannels.EVENT_FAVORITE_IDS_CHANGED, listener)
+    },
+    favoriteStatusChanged: (cb: (status: FavoriteStatus) => void): (() => void) => {
+      const listener = (_: Electron.IpcRendererEvent, status: FavoriteStatus) => cb(status)
+      ipcRenderer.on(IpcChannels.EVENT_FAVORITE_STATUS_CHANGED, listener)
+      return () => ipcRenderer.off(IpcChannels.EVENT_FAVORITE_STATUS_CHANGED, listener)
+    },
     failedVotesChanged: (cb: (failed: Record<string, string>) => void): (() => void) => {
       const listener = (_: Electron.IpcRendererEvent, failed: Record<string, string>) => cb(failed)
       ipcRenderer.on(IpcChannels.EVENT_FAILED_VOTES_CHANGED, listener)

+ 44 - 1
src/renderer/src/App.tsx

@@ -1,5 +1,6 @@
 import { useState, useEffect, Component, type ReactNode } from 'react'
 import { useQueryClient } from '@tanstack/react-query'
+import type { FavoriteStatus } from '@shared/types'
 import Sidebar from './components/layout/Sidebar'
 import WorkshopBrowser from './components/workshop/WorkshopBrowser'
 import LibraryView from './components/library/LibraryView'
@@ -9,6 +10,10 @@ import SetupScreen from './components/setup/SetupScreen'
 import StatusBar from './components/layout/StatusBar'
 import { useToast } from './components/common/Toast'
 import { screenLabel } from './utils/screens'
+import { useConfig } from './hooks/queries'
+import { FAVORITE_STATUS_KEY } from './hooks/useFavorites'
+import { DISLIKED_IDS_KEY } from './hooks/useVotes'
+import { applyAppearance, onSystemThemeChange } from './utils/appearance'
 
 type View = 'workshop' | 'library' | 'playlists' | 'settings'
 
@@ -45,6 +50,14 @@ export default function App() {
     setActiveView('workshop')
   }
 
+  const config = useConfig()
+  useEffect(() => {
+    if (!config) return
+    const apply = (): void => applyAppearance(config.appearance, config.windowTranslucent)
+    apply()
+    return onSystemThemeChange(apply)
+  }, [config])
+
   useEffect(() => {
     window.electronAPI.config.get().then((cfg) => {
       setDefaultPath(cfg.defaultWorkshopPath)
@@ -69,6 +82,36 @@ export default function App() {
     })
   }, [queryClient])
 
+  useEffect(() => {
+    return window.electronAPI.on.dislikedIdsChanged((ids) => {
+      queryClient.setQueryData(DISLIKED_IDS_KEY, ids)
+    })
+  }, [queryClient])
+
+  useEffect(() => {
+    return window.electronAPI.on.favoriteIdsChanged((ids) => {
+      queryClient.setQueryData(['steam-favorite-ids'], ids)
+    })
+  }, [queryClient])
+
+  useEffect(() => {
+    return window.electronAPI.on.favoriteStatusChanged((status) => {
+      const before = queryClient.getQueryData<FavoriteStatus>(FAVORITE_STATUS_KEY)?.failed ?? {}
+      const newReadBackFailures = Object.entries(status.failed).filter(
+        ([id, failure]) => failure.readBack && !before[id]
+      ).length
+      queryClient.setQueryData(FAVORITE_STATUS_KEY, status)
+      if (newReadBackFailures > 0) {
+        showToast(
+          newReadBackFailures === 1
+            ? "A favorite change didn't show up in your Steam favorites - its card has a dashed border"
+            : `${newReadBackFailures} favorite changes didn't show up in your Steam favorites - their cards have a dashed border`,
+          { warning: true, durationMs: 8000 }
+        )
+      }
+    })
+  }, [queryClient, showToast])
+
   useEffect(() => {
     return window.electronAPI.on.failedVotesChanged((failed) => {
       queryClient.setQueryData(['steam-failed-votes'], failed)
@@ -104,7 +147,7 @@ export default function App() {
 
   return (
     <ErrorBoundary>
-      <div className="flex h-full flex-col bg-[#0f0f0f] text-gray-100">
+      <div className="flex h-full flex-col bg-app text-gray-100">
         <div className="flex flex-1 overflow-hidden">
           <Sidebar activeView={activeView} onNavigate={setActiveView} />
           <main className="flex-1 overflow-hidden">

+ 128 - 10
src/renderer/src/assets/index.css

@@ -1,5 +1,68 @@
 @import "tailwindcss";
 
+/* Runtime themable via Settings -> Appearance. "fg" is text and faint overlays (bg-fg/5). */
+@theme {
+  --color-app: rgb(14 15 18 / var(--surface-alpha, 1));
+  --color-chrome: rgb(10 11 13 / var(--surface-alpha, 1));
+  --color-pane: rgb(17 18 22 / var(--surface-alpha, 1));
+  --color-card: #17181c;
+  --color-popup: #1b1c21;
+  --color-sunken: #0c0d10;
+  --color-fg: #ffffff;
+
+  --color-accent-50: oklch(96.2% calc(0.018 * var(--accent-chroma, 1)) var(--accent-hue, 277));
+  --color-accent-100: oklch(93% calc(0.034 * var(--accent-chroma, 1)) var(--accent-hue, 277));
+  --color-accent-200: oklch(87% calc(0.065 * var(--accent-chroma, 1)) var(--accent-hue, 277));
+  --color-accent-300: oklch(78.5% calc(0.115 * var(--accent-chroma, 1)) var(--accent-hue, 277));
+  --color-accent-400: oklch(67.3% calc(0.182 * var(--accent-chroma, 1)) var(--accent-hue, 277));
+  --color-accent-500: oklch(58.5% calc(0.233 * var(--accent-chroma, 1)) var(--accent-hue, 277));
+  --color-accent-600: oklch(51.1% calc(0.262 * var(--accent-chroma, 1)) var(--accent-hue, 277));
+  --color-accent-700: oklch(45.7% calc(0.24 * var(--accent-chroma, 1)) var(--accent-hue, 277));
+  --color-accent-800: oklch(39.8% calc(0.195 * var(--accent-chroma, 1)) var(--accent-hue, 277));
+  --color-accent-900: oklch(35.9% calc(0.144 * var(--accent-chroma, 1)) var(--accent-hue, 277));
+  --color-accent-950: oklch(25.7% calc(0.09 * var(--accent-chroma, 1)) var(--accent-hue, 277));
+}
+
+/* Views assume a dark UI, so the light theme mirrors the gray and status tint scales.
+   Solid 500/600 fills stay. */
+:root[data-theme="light"] {
+  color-scheme: light;
+
+  --color-app: rgb(243 244 247 / var(--surface-alpha, 1));
+  --color-chrome: rgb(233 235 240 / var(--surface-alpha, 1));
+  --color-pane: rgb(248 249 251 / var(--surface-alpha, 1));
+  --color-card: #ffffff;
+  --color-popup: #ffffff;
+  --color-sunken: #e4e6eb;
+  --color-fg: #0f1115;
+
+  --color-gray-100: oklch(21% 0.034 264.665);
+  --color-gray-200: oklch(27.8% 0.033 256.848);
+  --color-gray-300: oklch(37.3% 0.034 259.733);
+  --color-gray-400: oklch(44.6% 0.03 256.802);
+  --color-gray-500: oklch(52% 0.027 264.364);
+  --color-gray-600: oklch(65% 0.022 261.325);
+  --color-gray-700: oklch(80% 0.01 258.338);
+
+  --color-accent-200: oklch(45.7% calc(0.24 * var(--accent-chroma, 1)) var(--accent-hue, 277));
+  --color-accent-300: oklch(48% calc(0.25 * var(--accent-chroma, 1)) var(--accent-hue, 277));
+  --color-accent-400: oklch(51.1% calc(0.262 * var(--accent-chroma, 1)) var(--accent-hue, 277));
+
+  --color-red-300: oklch(50.5% 0.213 27.518);
+  --color-red-400: oklch(57.7% 0.245 27.325);
+  --color-green-300: oklch(52.7% 0.154 150.069);
+  --color-green-400: oklch(52.7% 0.154 150.069);
+  --color-amber-300: oklch(55.5% 0.163 48.998);
+  --color-amber-400: oklch(55.5% 0.163 48.998);
+  --color-yellow-400: oklch(55.4% 0.135 66.442);
+  --color-yellow-500: oklch(55.4% 0.135 66.442);
+  --color-sky-300: oklch(50% 0.134 242.749);
+  --color-sky-400: oklch(58.8% 0.158 241.966);
+  --color-orange-400: oklch(55.3% 0.195 38.402);
+  --color-pink-300: oklch(52.5% 0.223 3.958);
+  --color-pink-400: oklch(59.2% 0.249 0.584);
+}
+
 @layer base {
   * {
     box-sizing: border-box;
@@ -16,14 +79,39 @@
   }
 
   body {
-    background-color: #0f0f0f;
-    color: #e5e5e5;
-    font-family: system-ui, -apple-system, sans-serif;
+    background-color: var(--color-app);
+    color: var(--color-gray-200);
+    font-family: "Inter Variable", Inter, system-ui, -apple-system, sans-serif;
+    font-feature-settings: "cv11", "ss01";
     -webkit-font-smoothing: antialiased;
   }
 
+  :root[data-translucent] body {
+    background-color: transparent;
+  }
+
+  input[type="checkbox"],
+  input[type="radio"],
+  input[type="range"] {
+    accent-color: var(--color-accent-500);
+  }
+
+  ::selection {
+    background-color: color-mix(in oklab, var(--color-accent-500) 35%, transparent);
+  }
+
+  :focus-visible {
+    outline: 2px solid var(--color-accent-500);
+    outline-offset: 1px;
+  }
+
+  input:focus-visible,
+  textarea:focus-visible,
+  select:focus-visible {
+    outline: none;
+  }
+
   select {
-    color-scheme: dark;
     cursor: pointer;
   }
 
@@ -33,22 +121,52 @@
 
   select option,
   select optgroup {
-    background-color: #1a1a1a;
-    color: #d1d5db;
+    background-color: var(--color-popup);
+    color: var(--color-gray-300);
   }
 
   select option:disabled {
-    color: #6b7280;
+    color: var(--color-gray-600);
   }
 
   ::-webkit-scrollbar {
-    width: 6px;
+    width: 8px;
+    height: 8px;
   }
   ::-webkit-scrollbar-track {
     background: transparent;
   }
   ::-webkit-scrollbar-thumb {
-    background: #333;
-    border-radius: 3px;
+    background: color-mix(in oklab, var(--color-fg) 14%, transparent);
+    border: 2px solid transparent;
+    background-clip: padding-box;
+    border-radius: 999px;
+  }
+  ::-webkit-scrollbar-thumb:hover {
+    background-color: color-mix(in oklab, var(--color-fg) 24%, transparent);
+  }
+}
+
+@layer components {
+  .hue-slider {
+    background: linear-gradient(
+      to right,
+      oklch(62% 0.19 0),
+      oklch(62% 0.19 60),
+      oklch(62% 0.19 120),
+      oklch(62% 0.19 180),
+      oklch(62% 0.19 240),
+      oklch(62% 0.19 300),
+      oklch(62% 0.19 360)
+    );
+  }
+
+  .hue-slider::-webkit-slider-thumb {
+    appearance: none;
+    width: 16px;
+    height: 16px;
+    border-radius: 999px;
+    background: white;
+    box-shadow: 0 0 0 2px rgb(0 0 0 / 0.25), 0 1px 4px rgb(0 0 0 / 0.3);
   }
 }

+ 34 - 6
src/renderer/src/components/common/ContextMenu.tsx

@@ -1,11 +1,11 @@
 import { useRef, useState, type ReactNode } from 'react'
-import { ChevronRight, Folder, FolderInput, ThumbsDown, ThumbsUp, Trash2, type LucideIcon } from 'lucide-react'
+import { ChevronRight, Folder, FolderInput, Heart, HeartOff, ThumbsDown, ThumbsUp, Trash2, type LucideIcon } from 'lucide-react'
 import clsx from 'clsx'
 import type { WallpaperFolder } from '@shared/types'
 import { useClickOutside } from '../../hooks/useClickOutside'
 import { useClampedPosition, useFlipSide } from '../../hooks/useContextMenuPosition'
 
-const POPUP_CLASS = 'rounded-lg border border-white/10 bg-[#1a1a1a] py-1 shadow-xl'
+const POPUP_CLASS = 'rounded-xl border border-fg/10 bg-popup/95 p-1 shadow-2xl shadow-black/30 backdrop-blur-md'
 
 export function ContextMenu({
   x,
@@ -50,7 +50,7 @@ export function MenuItem({
     <button
       onClick={onClick}
       className={clsx(
-        'flex w-full items-center gap-2 px-3 py-1.5 hover:bg-white/5',
+        'flex w-full items-center gap-2 rounded-lg px-2.5 py-1.5 hover:bg-fg/5',
         danger ? 'text-red-400' : 'text-gray-300'
       )}
     >
@@ -61,12 +61,12 @@ export function MenuItem({
 }
 
 export function MenuSeparator() {
-  return <div className="my-1 border-t border-white/5" />
+  return <div className="mx-1 my-1 border-t border-fg/5" />
 }
 
 export function MenuSelectionCount({ count }: { count: number }) {
   if (count < 2) return null
-  return <div className="mb-1 border-b border-white/5 px-3 py-1 text-xs text-gray-600">{count} items selected</div>
+  return <div className="mb-1 border-b border-fg/5 px-3 py-1 text-xs text-gray-600">{count} items selected</div>
 }
 
 export function VoteMenuItems({ onVote }: { onVote: (up: boolean) => void }) {
@@ -82,6 +82,34 @@ export function VoteMenuItems({ onVote }: { onVote: (up: boolean) => void }) {
   )
 }
 
+// a mixed selection shows both
+export function FavoriteMenuItems({
+  ids,
+  favorites,
+  onFavorite
+}: {
+  ids: string[]
+  favorites: Set<string>
+  onFavorite: (ids: string[], add: boolean) => void
+}) {
+  const toAdd = ids.filter((id) => !favorites.has(id))
+  const toRemove = ids.filter((id) => favorites.has(id))
+  return (
+    <>
+      {toAdd.length > 0 && (
+        <MenuItem icon={Heart} onClick={() => onFavorite(toAdd, true)}>
+          Add to favorites
+        </MenuItem>
+      )}
+      {toRemove.length > 0 && (
+        <MenuItem icon={HeartOff} onClick={() => onFavorite(toRemove, false)}>
+          Remove from favorites
+        </MenuItem>
+      )}
+    </>
+  )
+}
+
 export function SubMenu({
   icon: Icon,
   label,
@@ -102,7 +130,7 @@ export function SubMenu({
     <div className="relative">
       <button
         onClick={() => setOpen((v) => !v)}
-        className="flex w-full items-center gap-2 px-3 py-1.5 text-gray-300 hover:bg-white/5"
+        className="flex w-full items-center gap-2 rounded-lg px-2.5 py-1.5 text-gray-300 hover:bg-fg/5"
       >
         <Icon size={12} /> {label}
         <ChevronRight size={12} className="ml-auto" />

+ 2 - 2
src/renderer/src/components/common/CopyField.tsx

@@ -22,13 +22,13 @@ export default function CopyField({ text, label }: Props) {
   return (
     <div className="flex items-center gap-2">
       {label && <span className="w-24 shrink-0 truncate text-xs text-gray-500">{label}</span>}
-      <code className="min-w-0 flex-1 truncate rounded bg-white/5 px-2 py-1 text-xs text-gray-300" title={text}>
+      <code className="min-w-0 flex-1 truncate rounded bg-fg/5 px-2 py-1 text-xs text-gray-300" title={text}>
         {text}
       </code>
       <button
         onClick={copy}
         title="Copy"
-        className="shrink-0 rounded p-1.5 text-gray-500 hover:bg-white/5 hover:text-gray-200"
+        className="shrink-0 rounded p-1.5 text-gray-500 hover:bg-fg/5 hover:text-gray-200"
       >
         {copied ? <Check size={13} /> : <Copy size={13} />}
       </button>

+ 121 - 58
src/renderer/src/components/common/DetailSidebar.tsx

@@ -5,6 +5,7 @@ import {
   Star,
   ThumbsUp,
   ThumbsDown,
+  Heart,
   Download,
   Play,
   Loader2,
@@ -38,13 +39,15 @@ import {
   Terminal,
   Sparkles,
   CloudFog,
+  HeartCrack,
   type LucideIcon
 } from 'lucide-react'
 import clsx from 'clsx'
 import { openWorkshopPage, openProfilePage, isWorkshopId } from '../../utils/steam'
 import { WE_TYPES, WE_AGE_RATINGS, canonicalResolutionTag, resolutionsFromTags } from '../../constants/weFilters'
 import { formatFileSize } from '../../utils/format'
-import { useVoteAction, useVotedIds } from '../../hooks/useVotes'
+import { useDislikedIds, useVoteAction, useVotedIds } from '../../hooks/useVotes'
+import { useFavoriteAction, useFavoriteIds, useItemFavoriteStatus } from '../../hooks/useFavorites'
 import { useLweInstalled } from '../../hooks/queries'
 import ScreenSelect from './ScreenSelect'
 import { getPreviewSrc } from '../../utils/preview'
@@ -137,14 +140,14 @@ function LayerRow({
             : 'Forced visible - click to reset to default'
       }
       className={clsx(
-        'flex w-full items-center gap-2 rounded px-1.5 py-1 text-left text-xs transition-colors hover:bg-white/5 disabled:opacity-40',
+        'flex w-full items-center gap-2 rounded px-1.5 py-1 text-left text-xs transition-colors hover:bg-fg/5 disabled:opacity-40',
         state === 'hidden' ? 'text-gray-600' : 'text-gray-300'
       )}
     >
       {state === 'hidden' ? (
         <EyeOff size={12} className="shrink-0 text-gray-600" />
       ) : state === 'forced' ? (
-        <Pin size={12} className="shrink-0 text-indigo-400" />
+        <Pin size={12} className="shrink-0 text-accent-400" />
       ) : (
         <Eye size={12} className="shrink-0 text-gray-500" />
       )}
@@ -179,14 +182,14 @@ function EffectRow({
             : 'Forced visible - click to reset to default'
       }
       className={clsx(
-        'flex w-full items-center gap-2 rounded px-1.5 py-1 text-left text-xs transition-colors hover:bg-white/5 disabled:opacity-40',
+        'flex w-full items-center gap-2 rounded px-1.5 py-1 text-left text-xs transition-colors hover:bg-fg/5 disabled:opacity-40',
         state === 'hidden' ? 'text-gray-600' : 'text-gray-300'
       )}
     >
       {state === 'hidden' ? (
         <EyeOff size={12} className="shrink-0 text-gray-600" />
       ) : state === 'forced' ? (
-        <Pin size={12} className="shrink-0 text-indigo-400" />
+        <Pin size={12} className="shrink-0 text-accent-400" />
       ) : (
         <Eye size={12} className="shrink-0 text-gray-500" />
       )}
@@ -228,12 +231,12 @@ function PropertyRow({
         disabled={busy}
         title={property.name}
         className={clsx(
-          'flex w-full items-center gap-2 rounded px-1.5 py-1 text-left text-xs transition-colors hover:bg-white/5 disabled:opacity-40',
+          'flex w-full items-center gap-2 rounded px-1.5 py-1 text-left text-xs transition-colors hover:bg-fg/5 disabled:opacity-40',
           on ? 'text-gray-200' : 'text-gray-500'
         )}
       >
         {on ? (
-          <ToggleRight size={14} className="shrink-0 text-indigo-400" />
+          <ToggleRight size={14} className="shrink-0 text-accent-400" />
         ) : (
           <ToggleLeft size={14} className="shrink-0 text-gray-600" />
         )}
@@ -263,7 +266,7 @@ function PropertyRow({
           onMouseUp={(e) => { onCommit(e.currentTarget.value); setDraft(null) }}
           onTouchEnd={(e) => { onCommit(e.currentTarget.value); setDraft(null) }}
           onKeyUp={(e) => { onCommit(e.currentTarget.value); setDraft(null) }}
-          className="w-full accent-indigo-500 disabled:opacity-50"
+          className="w-full accent-accent-500 disabled:opacity-50"
         />
       </div>
     )
@@ -279,7 +282,7 @@ function PropertyRow({
           value={value}
           disabled={busy}
           onChange={(e) => onCommit(e.target.value)}
-          className="rounded bg-white/5 px-1.5 py-0.5 text-xs text-gray-300 outline-none disabled:opacity-50"
+          className="rounded bg-fg/5 px-1.5 py-0.5 text-xs text-gray-300 outline-none disabled:opacity-50"
         >
           {property.options?.map((opt) => (
             <option key={opt.value} value={opt.value}>
@@ -333,7 +336,7 @@ function AudioObjectRow({
         onMouseUp={(e) => { onCommit(Number(e.currentTarget.value) / 100); setDraft(null) }}
         onTouchEnd={(e) => { onCommit(Number(e.currentTarget.value) / 100); setDraft(null) }}
         onKeyUp={(e) => { onCommit(Number(e.currentTarget.value) / 100); setDraft(null) }}
-        className="w-full accent-indigo-500 disabled:opacity-50"
+        className="w-full accent-accent-500 disabled:opacity-50"
       />
     </div>
   )
@@ -375,7 +378,7 @@ function SoundTrackRow({
         onMouseUp={(e) => { onCommit(Number(e.currentTarget.value)); setDraft(null) }}
         onTouchEnd={(e) => { onCommit(Number(e.currentTarget.value)); setDraft(null) }}
         onKeyUp={(e) => { onCommit(Number(e.currentTarget.value)); setDraft(null) }}
-        className="w-full accent-indigo-500 disabled:opacity-50"
+        className="w-full accent-accent-500 disabled:opacity-50"
       />
     </div>
   )
@@ -385,7 +388,7 @@ function SidebarButton({ icon: Icon, onClick, children }: { icon: LucideIcon; on
   return (
     <button
       onClick={onClick}
-      className="flex items-center justify-center gap-1.5 rounded-lg bg-white/5 py-1.5 text-xs text-gray-300 transition-colors hover:bg-white/10"
+      className="flex items-center justify-center gap-1.5 rounded-lg bg-fg/5 py-1.5 text-xs text-gray-300 transition-colors hover:bg-fg/10"
     >
       <Icon size={12} />
       {children}
@@ -428,7 +431,12 @@ export default function DetailSidebar({
   const queryClient = useQueryClient()
   const lweInstalled = useLweInstalled()
   const cachedLiked = useVotedIds().has(id)
+  const isDisliked = useDislikedIds().has(id)
   const { vote, isLiking, isDisliking } = useVoteAction()
+  const isFavorite = useFavoriteIds().has(id)
+  const { setFavorite, isPending: isFavoritePending } = useFavoriteAction()
+  const { failure: favoriteFailure, checking: favoriteChecking } = useItemFavoriteStatus(id)
+  const favoriteAdd = favoriteFailure ? favoriteFailure.add : !isFavorite
   const [isApplying, setIsApplying] = useState(false)
   const [unsubConfirm, setUnsubConfirm] = useState(false)
   const [isUnsubscribing, setIsUnsubscribing] = useState(false)
@@ -930,8 +938,8 @@ export default function DetailSidebar({
   }
 
   return (
-    <div className="flex w-80 flex-shrink-0 flex-col overflow-y-auto border-l border-white/5 bg-[#0d0d0d]">
-      <div className="relative aspect-video shrink-0 overflow-hidden bg-[#111]">
+    <div className="flex w-80 flex-shrink-0 flex-col overflow-y-auto border-l border-fg/5 bg-pane">
+      <div className="relative aspect-video shrink-0 overflow-hidden bg-sunken">
         {previewUrl ? (
           <img src={previewUrl} alt={title} className="h-full w-full object-cover" />
         ) : (
@@ -962,11 +970,11 @@ export default function DetailSidebar({
             {author?.avatarUrl ? (
               <img src={author.avatarUrl} alt="" className="h-8 w-8 rounded" />
             ) : (
-              <div className="flex h-8 w-8 items-center justify-center rounded bg-white/5 text-gray-500">
+              <div className="flex h-8 w-8 items-center justify-center rounded bg-fg/5 text-gray-500">
                 <User size={14} />
               </div>
             )}
-            <span className="text-sm text-indigo-300 hover:text-indigo-200">
+            <span className="text-sm text-accent-300 hover:text-accent-200">
               {author?.name ?? '...'}
             </span>
           </button>
@@ -976,23 +984,23 @@ export default function DetailSidebar({
 
         <div className="flex flex-wrap gap-1.5">
           {typeTag && (
-            <span className="rounded bg-white/5 px-2 py-1 text-xs text-gray-300">
+            <span className="rounded bg-fg/5 px-2 py-1 text-xs text-gray-300">
               {typeTag}
               {fileSizeLabel ? ` · ${fileSizeLabel}` : ''}
             </span>
           )}
           {genreTags.map((tag) => (
-            <span key={tag} className="rounded bg-white/5 px-2 py-1 text-xs text-gray-400">
+            <span key={tag} className="rounded bg-fg/5 px-2 py-1 text-xs text-gray-400">
               {tag}
             </span>
           ))}
           {resolutionTags.map((tag) => (
-            <span key={tag} className="rounded bg-white/5 px-2 py-1 text-xs text-gray-400">
+            <span key={tag} className="rounded bg-fg/5 px-2 py-1 text-xs text-gray-400">
               {tag}
             </span>
           ))}
           {ageTag && (
-            <span className="rounded bg-white/5 px-2 py-1 text-xs text-gray-400">{ageTag}</span>
+            <span className="rounded bg-fg/5 px-2 py-1 text-xs text-gray-400">{ageTag}</span>
           )}
         </div>
 
@@ -1001,7 +1009,7 @@ export default function DetailSidebar({
         )}
 
         {localPath && lweInstalled && (objectsLoading || objects.length > 0) && (
-          <div className="border-t border-white/5 pt-3">
+          <div className="border-t border-fg/5 pt-3">
             <div className="flex items-center gap-1.5">
               <button
                 onClick={() => setLayersOpen((v) => !v)}
@@ -1024,7 +1032,7 @@ export default function DetailSidebar({
                   title={fogDisabled ? 'Fog disabled - click to re-enable' : 'Click to disable fog'}
                   className={clsx(
                     'flex shrink-0 items-center gap-1 rounded px-1.5 py-0.5 text-[10px] font-medium normal-case transition-colors disabled:opacity-40',
-                    fogDisabled ? 'bg-white/5 text-gray-500' : 'bg-white/10 text-gray-300 hover:bg-white/15'
+                    fogDisabled ? 'bg-fg/5 text-gray-500' : 'bg-fg/10 text-gray-300 hover:bg-fg/15'
                   )}
                 >
                   {togglingFog ? <Loader2 size={10} className="animate-spin" /> : <CloudFog size={10} />}
@@ -1049,7 +1057,7 @@ export default function DetailSidebar({
         )}
 
         {localPath && lweInstalled && (effectsLoading || effects.length > 0) && (
-          <div className="border-t border-white/5 pt-3">
+          <div className="border-t border-fg/5 pt-3">
             <button
               onClick={() => setEffectsOpen((v) => !v)}
               className="flex w-full items-center gap-1.5 text-xs font-semibold uppercase tracking-wide text-gray-500 hover:text-gray-300"
@@ -1076,7 +1084,7 @@ export default function DetailSidebar({
         )}
 
         {localPath && lweInstalled && libraryMeta?.type && libraryMeta.type !== 'application' && (
-          <div className="border-t border-white/5 pt-3">
+          <div className="border-t border-fg/5 pt-3">
             <div className="mb-1.5 flex items-center gap-1.5 text-xs font-semibold uppercase tracking-wide text-gray-500">
               <Maximize size={12} />
               <span className="flex-1 text-left">Scaling</span>
@@ -1091,7 +1099,7 @@ export default function DetailSidebar({
               value={scalingMode}
               disabled={isCommittingScaling}
               onChange={(e) => commitScaling(e.target.value as ScalingMode)}
-              className="w-full rounded bg-white/5 px-1.5 py-1 text-xs text-gray-300 outline-none disabled:opacity-50"
+              className="w-full rounded bg-fg/5 px-1.5 py-1 text-xs text-gray-300 outline-none disabled:opacity-50"
             >
               {SCALING_MODE_OPTIONS.map((opt) => (
                 <option key={opt.value} value={opt.value}>
@@ -1103,7 +1111,7 @@ export default function DetailSidebar({
         )}
 
         {localPath && lweInstalled && libraryMeta?.type && libraryMeta.type !== 'application' && (
-          <div className="border-t border-white/5 pt-3">
+          <div className="border-t border-fg/5 pt-3">
             <div className="mb-1.5 flex items-center gap-1.5 text-xs font-semibold uppercase tracking-wide text-gray-500">
               {zoomPercent < 100 ? <ZoomOut size={12} /> : <ZoomIn size={12} />}
               <span className="flex-1 text-left">Zoom</span>
@@ -1130,13 +1138,13 @@ export default function DetailSidebar({
               onMouseUp={(e) => commitZoom(Number(e.currentTarget.value))}
               onTouchEnd={(e) => commitZoom(Number(e.currentTarget.value))}
               onKeyUp={(e) => commitZoom(Number(e.currentTarget.value))}
-              className="w-full accent-indigo-500 disabled:opacity-50"
+              className="w-full accent-accent-500 disabled:opacity-50"
             />
           </div>
         )}
 
         {localPath && lweInstalled && libraryMeta?.type && libraryMeta.type !== 'application' && (
-          <div className="border-t border-white/5 pt-3">
+          <div className="border-t border-fg/5 pt-3">
             <div className="mb-1.5 flex items-center gap-1.5 text-xs font-semibold uppercase tracking-wide text-gray-500">
               <Move size={12} />
               <span className="flex-1 text-left">Position</span>
@@ -1164,7 +1172,7 @@ export default function DetailSidebar({
                 onMouseUp={(e) => commitOffset(Number(e.currentTarget.value) / 100, offsetY)}
                 onTouchEnd={(e) => commitOffset(Number(e.currentTarget.value) / 100, offsetY)}
                 onKeyUp={(e) => commitOffset(Number(e.currentTarget.value) / 100, offsetY)}
-                className="w-full accent-indigo-500 disabled:opacity-50"
+                className="w-full accent-accent-500 disabled:opacity-50"
               />
               <span className="w-8 shrink-0 text-right text-[10px] text-gray-400">
                 {Math.round(offsetX * 100)}
@@ -1187,7 +1195,7 @@ export default function DetailSidebar({
                 onMouseUp={(e) => commitOffset(offsetX, Number(e.currentTarget.value) / 100)}
                 onTouchEnd={(e) => commitOffset(offsetX, Number(e.currentTarget.value) / 100)}
                 onKeyUp={(e) => commitOffset(offsetX, Number(e.currentTarget.value) / 100)}
-                className="w-full accent-indigo-500 disabled:opacity-50"
+                className="w-full accent-accent-500 disabled:opacity-50"
               />
               <span className="w-8 shrink-0 text-right text-[10px] text-gray-400">
                 {Math.round(offsetY * 100)}
@@ -1197,7 +1205,7 @@ export default function DetailSidebar({
         )}
 
         {localPath && lweInstalled && libraryMeta?.type && libraryMeta.type !== 'application' && (
-          <div className="border-t border-white/5 pt-3">
+          <div className="border-t border-fg/5 pt-3">
             <div className="flex items-center gap-1.5 text-xs font-semibold uppercase tracking-wide text-gray-500">
               <Zap size={12} />
               <span className="flex-1 text-left">FPS limit</span>
@@ -1224,14 +1232,14 @@ export default function DetailSidebar({
                   commitFps(Number.isFinite(parsed) ? Math.min(240, Math.max(1, parsed)) : fps)
                 }}
                 title="Overrides the app-wide default FPS for this wallpaper only - changes require a relaunch, not live. Empty = use the default."
-                className="w-14 rounded bg-white/5 px-1 py-0.5 text-right normal-case text-gray-400 outline-none focus:ring-1 focus:ring-indigo-500 disabled:opacity-50"
+                className="w-14 rounded bg-fg/5 px-1 py-0.5 text-right normal-case text-gray-400 outline-none focus:ring-1 focus:ring-accent-500 disabled:opacity-50"
               />
             </div>
           </div>
         )}
 
         {localPath && lweInstalled && libraryMeta?.type && libraryMeta.type !== 'application' && (
-          <div className="border-t border-white/5 pt-3">
+          <div className="border-t border-fg/5 pt-3">
             <div className="mb-1.5 flex items-center gap-1.5 text-xs font-semibold uppercase tracking-wide text-gray-500">
               <Gauge size={12} />
               <span className="flex-1 text-left">Playback speed</span>
@@ -1258,7 +1266,7 @@ export default function DetailSidebar({
                   commitSpeed(clamped)
                 }}
                 title="Type an exact speed percentage - applies on Enter or clicking away"
-                className="w-12 rounded bg-white/5 px-1 py-0.5 text-right normal-case text-gray-400 outline-none focus:ring-1 focus:ring-indigo-500 disabled:opacity-50"
+                className="w-12 rounded bg-fg/5 px-1 py-0.5 text-right normal-case text-gray-400 outline-none focus:ring-1 focus:ring-accent-500 disabled:opacity-50"
               />
               <span className="normal-case text-gray-400">%</span>
             </div>
@@ -1278,7 +1286,7 @@ export default function DetailSidebar({
               onTouchEnd={(e) => commitSpeed(Number(e.currentTarget.value))}
               onKeyUp={(e) => commitSpeed(Number(e.currentTarget.value))}
               title="Slows down or speeds up particles, animated effects and scripts (100% = normal speed)"
-              className="w-full accent-indigo-500 disabled:opacity-50"
+              className="w-full accent-accent-500 disabled:opacity-50"
             />
           </div>
         )}
@@ -1305,7 +1313,7 @@ export default function DetailSidebar({
         )}
 
         {localPath && lweInstalled && libraryMeta?.type && libraryMeta.type !== 'application' && (
-          <div className="border-t border-white/5 pt-3">
+          <div className="border-t border-fg/5 pt-3">
             <label className="flex items-center gap-1.5 text-xs font-semibold uppercase tracking-wide text-gray-500">
               <Palette size={12} />
               <span className="flex-1 text-left">Corner color</span>
@@ -1321,14 +1329,14 @@ export default function DetailSidebar({
                 disabled={isCommittingCornerColor}
                 onChange={(e) => commitCornerColor(e.target.value)}
                 title="Color shown outside the wallpaper's bounds (letterboxing / zoomed-out scaling)"
-                className="h-5 w-8 shrink-0 cursor-pointer rounded border border-white/10 bg-transparent p-0 disabled:opacity-50"
+                className="h-5 w-8 shrink-0 cursor-pointer rounded border border-fg/10 bg-transparent p-0 disabled:opacity-50"
               />
             </label>
           </div>
         )}
 
         {localPath && lweInstalled && (libraryMeta?.type === 'video' || libraryMeta?.type === 'scene') && (
-          <div className="border-t border-white/5 pt-3">
+          <div className="border-t border-fg/5 pt-3">
             <div className="mb-1.5 flex items-center gap-1.5 text-xs font-semibold uppercase tracking-wide text-gray-500">
               {volume === 0 ? <VolumeX size={12} /> : <Volume2 size={12} />}
               <span className="flex-1 text-left">Volume</span>
@@ -1359,13 +1367,13 @@ export default function DetailSidebar({
               onMouseUp={(e) => commitVolume(Number(e.currentTarget.value))}
               onTouchEnd={(e) => commitVolume(Number(e.currentTarget.value))}
               onKeyUp={(e) => commitVolume(Number(e.currentTarget.value))}
-              className="w-full accent-indigo-500 disabled:opacity-50"
+              className="w-full accent-accent-500 disabled:opacity-50"
             />
           </div>
         )}
 
         {localPath && lweInstalled && libraryMeta?.type === 'scene' && (
-          <div className="border-t border-white/5 pt-3">
+          <div className="border-t border-fg/5 pt-3">
             <button
               onClick={() => setXray({ xrayFullReveal: !xrayFullReveal, xrayDisabled: false })}
               disabled={isCommittingXray}
@@ -1382,7 +1390,7 @@ export default function DetailSidebar({
               {isCommittingXray ? (
                 <Loader2 size={14} className="animate-spin text-gray-500" />
               ) : xrayFullReveal ? (
-                <ToggleRight size={14} className="text-indigo-400" />
+                <ToggleRight size={14} className="text-accent-400" />
               ) : (
                 <ToggleLeft size={14} className="text-gray-600" />
               )}
@@ -1403,7 +1411,7 @@ export default function DetailSidebar({
               {isCommittingXray ? (
                 <Loader2 size={14} className="animate-spin text-gray-500" />
               ) : xrayDisabled ? (
-                <ToggleRight size={14} className="text-indigo-400" />
+                <ToggleRight size={14} className="text-accent-400" />
               ) : (
                 <ToggleLeft size={14} className="text-gray-600" />
               )}
@@ -1424,7 +1432,7 @@ export default function DetailSidebar({
               {isCommittingParallax ? (
                 <Loader2 size={14} className="animate-spin text-gray-500" />
               ) : disableParallax ? (
-                <ToggleRight size={14} className="text-indigo-400" />
+                <ToggleRight size={14} className="text-accent-400" />
               ) : (
                 <ToggleLeft size={14} className="text-gray-600" />
               )}
@@ -1445,7 +1453,7 @@ export default function DetailSidebar({
               {isCommittingExpandCanvas ? (
                 <Loader2 size={14} className="animate-spin text-gray-500" />
               ) : expandCanvas ? (
-                <ToggleRight size={14} className="text-indigo-400" />
+                <ToggleRight size={14} className="text-accent-400" />
               ) : (
                 <ToggleLeft size={14} className="text-gray-600" />
               )}
@@ -1466,7 +1474,7 @@ export default function DetailSidebar({
               {isCommittingRepairAssets ? (
                 <Loader2 size={14} className="animate-spin text-gray-500" />
               ) : repairAssets ? (
-                <ToggleRight size={14} className="text-indigo-400" />
+                <ToggleRight size={14} className="text-accent-400" />
               ) : (
                 <ToggleLeft size={14} className="text-gray-600" />
               )}
@@ -1479,7 +1487,7 @@ export default function DetailSidebar({
         )}
 
         {localPath && lweInstalled && libraryMeta?.type && libraryMeta.type !== 'application' && (
-          <div className="border-t border-white/5 pt-3">
+          <div className="border-t border-fg/5 pt-3">
             <label className="mb-1.5 flex items-center gap-1.5 text-xs font-semibold uppercase tracking-wide text-gray-500">
               <Terminal size={12} />
               <span className="flex-1 text-left">Custom launch arguments</span>
@@ -1501,13 +1509,13 @@ export default function DetailSidebar({
                 if (e.key === 'Enter') e.currentTarget.blur()
               }}
               placeholder="--render-debug skip-effect=726"
-              className="w-full rounded border border-white/10 bg-black/30 px-2 py-1 text-xs text-gray-200 placeholder:text-gray-600 focus:border-indigo-500/50 focus:outline-none disabled:opacity-50"
+              className="w-full rounded border border-fg/10 bg-black/30 px-2 py-1 text-xs text-gray-200 placeholder:text-gray-600 focus:border-accent-500/50 focus:outline-none disabled:opacity-50"
             />
           </div>
         )}
 
         {localPath && lweInstalled && (propertiesLoading || properties.length > 0) && (
-          <div className="border-t border-white/5 pt-3">
+          <div className="border-t border-fg/5 pt-3">
             <button
               onClick={() => setPropertiesOpen((v) => !v)}
               className="flex w-full items-center gap-1.5 text-xs font-semibold uppercase tracking-wide text-gray-500 hover:text-gray-300"
@@ -1539,7 +1547,7 @@ export default function DetailSidebar({
         )}
 
         {localPath && lweInstalled && (audioObjectsLoading || audioObjects.length > 0) && (
-          <div className="border-t border-white/5 pt-3">
+          <div className="border-t border-fg/5 pt-3">
             <button
               onClick={() => setAudioOpen((v) => !v)}
               className="flex w-full items-center gap-1.5 text-xs font-semibold uppercase tracking-wide text-gray-500 hover:text-gray-300"
@@ -1572,7 +1580,7 @@ export default function DetailSidebar({
         )}
 
         {localPath && lweInstalled && (objectsLoading || soundObjects.length > 0) && (
-          <div className="border-t border-white/5 pt-3">
+          <div className="border-t border-fg/5 pt-3">
             <button
               onClick={() => setSoundTracksOpen((v) => !v)}
               className="flex w-full items-center gap-1.5 text-xs font-semibold uppercase tracking-wide text-gray-500 hover:text-gray-300"
@@ -1628,7 +1636,7 @@ export default function DetailSidebar({
           </>
         )}
 
-        <div className="flex flex-col gap-1.5 border-t border-white/5 pt-3">
+        <div className="flex flex-col gap-1.5 border-t border-fg/5 pt-3">
           <div className="flex gap-1.5">
             <button
               onClick={() => handleVote(true)}
@@ -1637,10 +1645,10 @@ export default function DetailSidebar({
               className={clsx(
                 'flex flex-1 items-center justify-center gap-1.5 rounded-lg py-1.5 text-xs transition-colors disabled:cursor-not-allowed',
                 unavailable
-                  ? 'bg-white/5 text-gray-600 opacity-50'
+                  ? 'bg-fg/5 text-gray-600 opacity-50'
                   : isLiked
                     ? 'bg-green-600/30 text-green-300'
-                    : 'bg-white/5 text-gray-300 hover:bg-white/10'
+                    : 'bg-fg/5 text-gray-300 hover:bg-fg/10'
               )}
             >
               {isLiking ? <Loader2 size={12} className="animate-spin" /> : <ThumbsUp size={12} />}
@@ -1648,17 +1656,72 @@ export default function DetailSidebar({
             </button>
             <button
               onClick={() => handleVote(false)}
-              disabled={isLiking || isDisliking || unavailable}
+              disabled={isLiking || isDisliking || unavailable || (isDisliked && !isLiked)}
               title={unavailable ? 'Removed from the Steam Workshop - voting is no longer possible' : undefined}
               className={clsx(
                 'flex flex-1 items-center justify-center gap-1.5 rounded-lg py-1.5 text-xs transition-colors disabled:cursor-not-allowed',
-                unavailable ? 'bg-white/5 text-gray-600 opacity-50' : 'bg-white/5 text-gray-300 hover:bg-white/10'
+                unavailable
+                  ? 'bg-fg/5 text-gray-600 opacity-50'
+                  : isDisliked && !isLiked
+                    ? 'bg-red-600/25 text-red-300'
+                    : 'bg-fg/5 text-gray-300 hover:bg-fg/10'
               )}
             >
               {isDisliking ? <Loader2 size={12} className="animate-spin" /> : <ThumbsDown size={12} />}
-              Dislike
+              {isDisliked && !isLiked ? 'Disliked' : 'Dislike'}
             </button>
+            {workshopId && (
+              <button
+                onClick={() => setFavorite(id, favoriteAdd)}
+                disabled={isFavoritePending || (unavailable && favoriteAdd)}
+                title={
+                  favoriteFailure
+                    ? 'Try again'
+                    : isFavorite
+                      ? 'In your Steam favorites - click to remove'
+                      : 'Add to your Steam favorites'
+                }
+                aria-pressed={isFavorite}
+                className={clsx(
+                  'flex w-9 items-center justify-center rounded-lg py-1.5 transition-colors disabled:cursor-not-allowed disabled:opacity-50',
+                  favoriteFailure
+                    ? 'bg-red-500/20 text-red-300 hover:bg-red-500/30'
+                    : isFavorite
+                      ? 'bg-pink-500/20 text-pink-300 hover:bg-pink-500/30'
+                      : 'bg-fg/5 text-gray-300 hover:bg-fg/10'
+                )}
+              >
+                {isFavoritePending ? (
+                  <Loader2 size={12} className="animate-spin" />
+                ) : favoriteFailure ? (
+                  <HeartCrack size={12} />
+                ) : (
+                  <Heart size={12} fill={isFavorite ? 'currentColor' : 'none'} />
+                )}
+              </button>
+            )}
           </div>
+          {workshopId && favoriteFailure && (
+            <p className="flex items-start gap-1.5 text-xs text-red-300">
+              <HeartCrack size={12} className="mt-0.5 shrink-0" />
+              <span>
+                {favoriteFailure.message}.{' '}
+                <button
+                  onClick={() => setFavorite(id, favoriteFailure.add)}
+                  disabled={isFavoritePending || (unavailable && favoriteFailure.add)}
+                  className="underline underline-offset-2 hover:text-red-200 disabled:opacity-50"
+                >
+                  Try again
+                </button>
+              </span>
+            </p>
+          )}
+          {workshopId && favoriteChecking && !favoriteFailure && (
+            <p className="flex items-center gap-1.5 text-xs text-gray-500">
+              <Loader2 size={11} className="animate-spin" />
+              Checking your Steam favorites list for the change
+            </p>
+          )}
 
           {canPlay && perScreen && (
             <ScreenSelect targets={targets} value={playScreen} onChange={setPlayScreen} title="Which screen to play on" />
@@ -1668,7 +1731,7 @@ export default function DetailSidebar({
               onClick={handlePlay}
               disabled={isApplying || !lweInstalled}
               title={lweInstalled ? undefined : 'Install linux-wallpaperengine in Settings first'}
-              className="flex items-center justify-center gap-1.5 rounded-lg bg-indigo-600 py-1.5 text-xs text-white transition-colors hover:bg-indigo-500 disabled:cursor-not-allowed disabled:opacity-50"
+              className="flex items-center justify-center gap-1.5 rounded-lg bg-accent-600 py-1.5 text-xs text-white transition-colors hover:bg-accent-500 disabled:cursor-not-allowed disabled:opacity-50"
             >
               {isApplying ? <Loader2 size={12} className="animate-spin" /> : <Play size={12} />}
               Play wallpaper
@@ -1683,7 +1746,7 @@ export default function DetailSidebar({
                 'flex items-center justify-center gap-1.5 rounded-lg py-1.5 text-xs transition-colors',
                 unsubConfirm
                   ? 'bg-red-600 text-white hover:bg-red-500'
-                  : 'bg-white/5 text-gray-300 hover:bg-red-500/20 hover:text-red-400'
+                  : 'bg-fg/5 text-gray-300 hover:bg-red-500/20 hover:text-red-400'
               )}
             >
               {isUnsubscribing ? (

+ 30 - 5
src/renderer/src/components/common/FilterPanel.tsx

@@ -1,5 +1,6 @@
-import { useState, type ReactNode } from 'react'
+import { useEffect, useRef, useState, type ReactNode } from 'react'
 import { ChevronDown, ChevronRight } from 'lucide-react'
+import clsx from 'clsx'
 import { WE_RESOLUTION_GROUPS, setGroupSelected, type FilterItem } from '../../constants/weFilters'
 import { toggle } from '../../utils/array'
 
@@ -7,7 +8,7 @@ import { toggle } from '../../utils/array'
 
 export function FilterPanel({ children }: { children: ReactNode }) {
   return (
-    <div className="w-52 flex-shrink-0 space-y-3 overflow-y-auto border-r border-white/5 bg-[#0d0d0d] px-3 py-3">
+    <div className="w-52 flex-shrink-0 space-y-3 overflow-y-auto border-r border-fg/5 bg-pane px-3 py-3">
       {children}
     </div>
   )
@@ -16,28 +17,52 @@ export function FilterPanel({ children }: { children: ReactNode }) {
 export function CheckItem({
   label,
   checked,
+  indeterminate = false,
+  nested = false,
   count,
   title,
   onChange
 }: {
   label: string
   checked: boolean
+  indeterminate?: boolean
+  // drawn as a CheckGroup branch
+  nested?: boolean
   count?: number
   title?: string
   onChange: () => void
 }) {
+  const inputRef = useRef<HTMLInputElement>(null)
+  useEffect(() => {
+    if (inputRef.current) inputRef.current.indeterminate = indeterminate
+  }, [indeterminate])
   return (
     <label
       title={title}
-      className="flex cursor-pointer items-center gap-2 py-0.5 text-xs text-gray-400 hover:text-gray-200"
+      className={clsx(
+        'relative flex cursor-pointer items-center gap-2 py-0.5 text-xs text-gray-400 hover:text-gray-200',
+        nested &&
+          'before:absolute before:-left-2.5 before:top-1/2 before:w-2 before:border-t before:border-fg/15 after:absolute after:-left-2.5 after:top-0 after:h-full after:border-l after:border-fg/15 last:after:h-1/2'
+      )}
     >
-      <input type="checkbox" checked={checked} onChange={onChange} className="cursor-pointer accent-indigo-500" />
+      <input
+        ref={inputRef}
+        type="checkbox"
+        checked={checked}
+        onChange={onChange}
+        className="cursor-pointer accent-accent-500"
+      />
       <span className="flex-1 truncate">{label}</span>
       {count !== undefined && <span className="text-[11px] text-gray-600">{count}</span>}
     </label>
   )
 }
 
+// children of a CheckItem
+export function CheckGroup({ children }: { children: ReactNode }) {
+  return <div className="ml-[6px] pl-2.5">{children}</div>
+}
+
 export function AllNoneButtons({ onAll, onNone }: { onAll: () => void; onNone: () => void }) {
   return (
     <div className="flex gap-2">
@@ -71,7 +96,7 @@ export function FilterSection({
       >
         {open ? <ChevronDown size={12} /> : <ChevronRight size={12} />}
         <span className="flex-1 text-left">{title}</span>
-        {activeCount > 0 && <span className="rounded-full bg-indigo-600/40 px-1.5 text-indigo-300">{activeCount}</span>}
+        {activeCount > 0 && <span className="rounded-full bg-accent-600/40 px-1.5 text-accent-300">{activeCount}</span>}
       </button>
       {open && (
         <div className="mt-1 space-y-0.5 pl-1">

+ 47 - 41
src/renderer/src/components/common/GridCard.tsx

@@ -1,53 +1,64 @@
 import type { ButtonHTMLAttributes, HTMLAttributes, ReactNode } from 'react'
 import { Check, ExternalLink, Loader2, Play, ThumbsUp, type LucideIcon } from 'lucide-react'
 import clsx from 'clsx'
-import { voteBorderClass } from '../../hooks/useVoteBorders'
+import type { CardBorders } from '@shared/cardBorders'
+import { cardFrames, type CardSteamState } from '../../hooks/useCardBorders'
 import { useVoteAction } from '../../hooks/useVotes'
 import { openWorkshopPage } from '../../utils/steam'
+import PreviewImage from './PreviewImage'
 
 // Building blocks shared by the workshop and library wallpaper cards
 
 interface GridCardProps extends HTMLAttributes<HTMLDivElement> {
   selected: boolean
   isDetailOpen: boolean
-  isLiked: boolean
-  voteError?: string
-  showVoteBorder: boolean
+  steam: CardSteamState
+  borders: CardBorders
   [dataAttr: `data-${string}`]: string
 }
 
-export function GridCard({
-  selected,
-  isDetailOpen,
-  isLiked,
-  voteError,
-  showVoteBorder,
-  className,
-  children,
-  ...rest
-}: GridCardProps) {
+// outside the card, so a liked favorite shows both colors
+const FRAME_INSET_PX = [4, 7]
+
+export function GridCard({ selected, isDetailOpen, steam, borders, className, children, ...rest }: GridCardProps) {
+  const { frames, title } = cardFrames(borders, steam)
   return (
     <div
       {...rest}
-      title={showVoteBorder ? voteError : undefined}
+      data-preview-hover=""
+      title={title}
       className={clsx(
-        'group relative cursor-pointer select-none overflow-hidden rounded-lg bg-[#1a1a1a] transition-all',
-        isDetailOpen ? 'ring-2 ring-sky-400' : selected ? 'ring-2 ring-indigo-500' : 'hover:ring-1 hover:ring-indigo-500/50',
-        showVoteBorder && voteBorderClass(voteError, isLiked),
+        'group relative cursor-pointer select-none rounded-xl bg-card shadow-sm shadow-black/10 transition-all duration-200 hover:-translate-y-0.5 hover:shadow-lg hover:shadow-black/25',
+        isDetailOpen ? 'ring-2 ring-sky-400' : selected ? 'ring-2 ring-accent-500' : 'ring-1 ring-fg/5 hover:ring-accent-500/50',
         className
       )}
     >
-      <div
-        className={clsx(
-          'absolute left-2 top-2 z-10 flex h-5 w-5 items-center justify-center rounded border transition-all',
-          selected
-            ? 'border-indigo-500 bg-indigo-600 text-white opacity-100'
-            : 'border-white/30 bg-black/50 text-transparent opacity-0 group-hover:opacity-100'
-        )}
-      >
-        <Check size={12} />
+      {frames.map((frame, i) => (
+        <div
+          key={frame.kind}
+          aria-hidden
+          className="pointer-events-none absolute border-2"
+          style={{
+            inset: -FRAME_INSET_PX[i],
+            borderRadius: 12 + FRAME_INSET_PX[i],
+            borderColor: frame.color,
+            borderStyle: frame.kind === 'failed' ? 'dashed' : 'solid'
+          }}
+        />
+      ))}
+      <div className="relative h-full overflow-hidden rounded-xl">
+        <div
+          className={clsx(
+            'absolute left-2 top-2 z-10 flex h-5 w-5 items-center justify-center rounded border transition-all',
+            selected
+              ? 'border-accent-500 bg-accent-600 text-white opacity-100'
+              : 'border-white/30 bg-black/50 text-transparent opacity-0 group-hover:opacity-100'
+          )}
+        >
+          <Check size={12} />
+        </div>
+        {children}
       </div>
-      {children}
     </div>
   )
 }
@@ -64,17 +75,12 @@ export function CardPreview({
   children?: ReactNode
 }) {
   return (
-    <div className="relative aspect-video overflow-hidden bg-[#111]">
+    <div className="relative aspect-video overflow-hidden bg-sunken">
       {src ? (
-        <img
+        <PreviewImage
           src={src}
           alt={alt}
-          className={clsx(
-            'h-full w-full object-cover transition-transform duration-300 group-hover:scale-105',
-            dimmed && 'brightness-50'
-          )}
-          loading="lazy"
-          draggable={false}
+          className={clsx('transition-transform duration-300 group-hover:scale-105', dimmed && 'brightness-50')}
         />
       ) : (
         <div className="flex h-full items-center justify-center text-gray-600">No preview</div>
@@ -96,7 +102,7 @@ export function CardOverlay({ children }: { children: ReactNode }) {
 export function ProgressBar({ percentage, className }: { percentage: number; className: string }) {
   return (
     <div className={clsx('overflow-hidden', className)}>
-      <div className="h-full bg-indigo-500 transition-[width]" style={{ width: `${percentage}%` }} />
+      <div className="h-full bg-accent-500 transition-[width]" style={{ width: `${percentage}%` }} />
     </div>
   )
 }
@@ -113,10 +119,10 @@ export function CornerBadge({ className, title, children }: { className: string;
 type ActionTone = 'default' | 'active' | 'danger' | 'muted'
 
 const TONE_CLASS: Record<ActionTone, string> = {
-  default: 'bg-white/5 text-gray-400 hover:bg-white/10 hover:text-gray-200 disabled:cursor-not-allowed disabled:opacity-50',
+  default: 'bg-fg/5 text-gray-400 hover:bg-fg/10 hover:text-gray-200 disabled:cursor-not-allowed disabled:opacity-50',
   active: 'bg-green-600/30 text-green-300 disabled:cursor-default',
-  danger: 'bg-white/5 text-gray-400 hover:bg-red-500/20 hover:text-red-400 disabled:cursor-not-allowed disabled:opacity-50',
-  muted: 'bg-white/5 text-gray-600 opacity-50 disabled:cursor-not-allowed'
+  danger: 'bg-fg/5 text-gray-400 hover:bg-red-500/20 hover:text-red-400 disabled:cursor-not-allowed disabled:opacity-50',
+  muted: 'bg-fg/5 text-gray-600 opacity-50 disabled:cursor-not-allowed'
 }
 
 interface CardActionProps extends ButtonHTMLAttributes<HTMLButtonElement> {
@@ -218,7 +224,7 @@ export function PlayButton({
       title={title}
       className={clsx(
         'flex h-7 w-7 items-center justify-center rounded-full bg-black/60 opacity-0 transition-opacity group-hover:opacity-100 disabled:cursor-not-allowed',
-        ready ? 'text-white hover:bg-indigo-600' : 'text-gray-500'
+        ready ? 'text-white hover:bg-accent-600' : 'text-gray-500'
       )}
     >
       {busy ? <Loader2 size={14} className="animate-spin" /> : <Play size={14} />}

+ 8 - 8
src/renderer/src/components/common/GridControls.tsx

@@ -25,12 +25,12 @@ export function PanelToggle({
       title={open ? `Hide ${label.toLowerCase()}` : `Show ${label.toLowerCase()}`}
       className={clsx(
         'flex items-center gap-2 rounded-lg px-3 py-2 text-sm transition-colors',
-        open || activeCount > 0 ? 'bg-indigo-600 text-white' : 'bg-white/5 text-gray-300 hover:bg-white/10'
+        open || activeCount > 0 ? 'bg-accent-600 text-white' : 'bg-fg/5 text-gray-300 hover:bg-fg/10'
       )}
     >
       <Icon size={14} />
       {label}
-      {activeCount > 0 && <span className="rounded-full bg-white/20 px-1.5 text-xs">{activeCount}</span>}
+      {activeCount > 0 && <span className="rounded-full bg-fg/20 px-1.5 text-xs">{activeCount}</span>}
     </button>
   )
 }
@@ -43,7 +43,7 @@ export function ResetFiltersButton({ onClick }: { onClick: () => void }) {
   return (
     <button
       onClick={onClick}
-      className="flex items-center gap-1 rounded-lg bg-white/5 px-3 py-2 text-sm text-gray-300 hover:bg-white/10"
+      className="flex items-center gap-1 rounded-lg bg-fg/5 px-3 py-2 text-sm text-gray-300 hover:bg-fg/10"
     >
       <X size={14} /> Reset
     </button>
@@ -70,7 +70,7 @@ export function SearchInput({
         title={title}
         value={value}
         onChange={(e) => onChange(e.target.value)}
-        className="w-full rounded-lg bg-white/5 py-2 pl-9 pr-3 text-sm text-gray-200 placeholder-gray-500 outline-none focus:ring-1 focus:ring-indigo-500"
+        className="w-full rounded-lg bg-fg/5 py-2 pl-9 pr-3 text-sm text-gray-200 placeholder-gray-500 outline-none focus:ring-1 focus:ring-accent-500"
       />
     </div>
   )
@@ -96,7 +96,7 @@ export function ToolbarButton({
       onClick={onClick}
       disabled={disabled}
       title={title}
-      className="flex items-center gap-2 rounded-lg bg-white/5 px-3 py-2 text-sm text-gray-300 hover:bg-white/10 disabled:opacity-50"
+      className="flex items-center gap-2 rounded-lg bg-fg/5 px-3 py-2 text-sm text-gray-300 hover:bg-fg/10 disabled:opacity-50"
     >
       {busy ? <Loader2 size={14} className="animate-spin" /> : icon}
       {children}
@@ -116,7 +116,7 @@ export function MarqueeOverlay({ rect }: { rect: MarqueeRect | null }) {
   if (!rect || rect.width <= 3 || rect.height <= 3) return null
   return (
     <div
-      className="pointer-events-none absolute z-20 border border-indigo-500 bg-indigo-500/15"
+      className="pointer-events-none absolute z-20 border border-accent-500 bg-accent-500/15"
       style={{ left: rect.left, top: rect.top, width: rect.width, height: rect.height }}
     />
   )
@@ -140,7 +140,7 @@ export function Pagination({
       <button
         disabled={page <= 1}
         onClick={() => onPage(Math.max(1, page - 1))}
-        className="rounded bg-white/5 px-2.5 py-1 text-gray-300 hover:bg-white/10 disabled:opacity-40"
+        className="rounded bg-fg/5 px-2.5 py-1 text-gray-300 hover:bg-fg/10 disabled:opacity-40"
       >
         Prev
       </button>
@@ -148,7 +148,7 @@ export function Pagination({
       <button
         disabled={!canNext}
         onClick={() => onPage(page + 1)}
-        className="rounded bg-white/5 px-2.5 py-1 text-gray-300 hover:bg-white/10 disabled:opacity-40"
+        className="rounded bg-fg/5 px-2.5 py-1 text-gray-300 hover:bg-fg/10 disabled:opacity-40"
       >
         Next
       </button>

+ 201 - 0
src/renderer/src/components/common/PreviewImage.tsx

@@ -0,0 +1,201 @@
+import { useEffect, useRef, useState } from 'react'
+import clsx from 'clsx'
+import { useConfig } from '../../hooks/queries'
+
+// previewAnimation 'hover': a still frame on a canvas, the animated image laid over it on hover
+
+const HOVER_DELAY_MS = 120
+
+// Steam preview URLs have no extension, so every remote preview takes the still path
+function mayBeAnimated(src: string): boolean {
+  if (src.startsWith('wallpaper://')) return /\.(gif|webp)$/i.test(src)
+  return /^https?:\/\//.test(src)
+}
+
+type StillSource = { source: CanvasImageSource; width: number; height: number }
+
+function drawCover(canvas: HTMLCanvasElement, still: StillSource): void {
+  const box = canvas.getBoundingClientRect()
+  if (box.width === 0 || box.height === 0 || still.width === 0) return
+  const dpr = window.devicePixelRatio || 1
+  canvas.width = Math.round(box.width * dpr)
+  canvas.height = Math.round(box.height * dpr)
+  const scale = Math.max(canvas.width / still.width, canvas.height / still.height)
+  const w = still.width * scale
+  const h = still.height * scale
+  const ctx = canvas.getContext('2d')
+  if (!ctx) return
+  ctx.imageSmoothingQuality = 'high'
+  ctx.drawImage(still.source, (canvas.width - w) / 2, (canvas.height - h) / 2, w, h)
+}
+
+function sniffType(bytes: Uint8Array): string | null {
+  const ascii = (from: number, to: number): string => String.fromCharCode(...bytes.subarray(from, to))
+  if (ascii(0, 4) === 'GIF8') return 'image/gif'
+  if (ascii(0, 4) === 'RIFF' && ascii(8, 12) === 'WEBP') return 'image/webp'
+  return null
+}
+
+function isNearlyBlack(frame: VideoFrame): boolean {
+  const probe = new OffscreenCanvas(16, 16)
+  const ctx = probe.getContext('2d')
+  if (!ctx) return false
+  ctx.drawImage(frame, 0, 0, 16, 16)
+  const px = ctx.getImageData(0, 0, 16, 16).data
+  let sum = 0
+  for (let i = 0; i < px.length; i += 4) sum += px[i] * 0.299 + px[i + 1] * 0.587 + px[i + 2] * 0.114
+  return sum / (px.length / 4) < 12
+}
+
+const MAX_STILL_WIDTH = 960
+
+// a black first frame (fade-in previews) is swapped for one a third of the way in
+async function decodeStill(src: string): Promise<ImageBitmap | null> {
+  if (typeof ImageDecoder === 'undefined') return null
+  const data = await (await fetch(src)).arrayBuffer()
+  const type = sniffType(new Uint8Array(data, 0, Math.min(12, data.byteLength)))
+  if (!type) return null
+  const decoder = new ImageDecoder({ data, type })
+  try {
+    await decoder.tracks.ready
+    const frameCount = decoder.tracks.selectedTrack?.frameCount ?? 1
+    let { image } = await decoder.decode({ frameIndex: 0 })
+    if (frameCount > 1 && isNearlyBlack(image)) {
+      image.close()
+      image = (await decoder.decode({ frameIndex: Math.floor(frameCount / 3) })).image
+    }
+    const width = Math.min(image.displayWidth, MAX_STILL_WIDTH)
+    const bitmap = await createImageBitmap(image, {
+      resizeWidth: width,
+      resizeHeight: Math.round((image.displayHeight * width) / image.displayWidth),
+      resizeQuality: 'high'
+    })
+    image.close()
+    return bitmap
+  } finally {
+    decoder.close()
+  }
+}
+
+// a detached image doesn't animate, so drawing it gives the first frame
+function loadFirstFrame(src: string): Promise<StillSource> {
+  return new Promise((resolve, reject) => {
+    const img = new Image()
+    img.decoding = 'async'
+    img.addEventListener('load', () => resolve({ source: img, width: img.naturalWidth, height: img.naturalHeight }))
+    img.addEventListener('error', reject)
+    img.src = src
+  })
+}
+
+async function loadStill(src: string): Promise<StillSource> {
+  const bitmap = await decodeStill(src).catch(() => null)
+  if (bitmap) return { source: bitmap, width: bitmap.width, height: bitmap.height }
+  return loadFirstFrame(src)
+}
+
+export default function PreviewImage({ src, alt, className }: { src: string; alt: string; className?: string }) {
+  const onHover = useConfig()?.appearance.previewAnimation === 'hover'
+  if (!onHover || !mayBeAnimated(src)) {
+    return <img src={src} alt={alt} className={clsx('h-full w-full object-cover', className)} loading="lazy" draggable={false} />
+  }
+  return <HoverAnimatedImage key={src} src={src} alt={alt} className={className} />
+}
+
+function HoverAnimatedImage({ src, alt, className }: { src: string; alt: string; className?: string }) {
+  const wrapRef = useRef<HTMLDivElement>(null)
+  const canvasRef = useRef<HTMLCanvasElement>(null)
+  const [nearViewport, setNearViewport] = useState(false)
+  const [live, setLive] = useState(false)
+  const [liveLoaded, setLiveLoaded] = useState(false)
+
+  useEffect(() => {
+    const el = wrapRef.current
+    if (!el) return
+    const observer = new IntersectionObserver(
+      (entries) => {
+        if (entries.some((e) => e.isIntersecting)) {
+          setNearViewport(true)
+          observer.disconnect()
+        }
+      },
+      { rootMargin: '300px' }
+    )
+    observer.observe(el)
+    return () => observer.disconnect()
+  }, [])
+
+  useEffect(() => {
+    if (!nearViewport) return
+    const canvas = canvasRef.current
+    if (!canvas) return
+    let cancelled = false
+    let resize: ResizeObserver | null = null
+    let bitmap: ImageBitmap | null = null
+    loadStill(src)
+      .then((still) => {
+        if (still.source instanceof ImageBitmap) bitmap = still.source
+        if (cancelled) {
+          bitmap?.close()
+          return
+        }
+        drawCover(canvas, still)
+        resize = new ResizeObserver(() => drawCover(canvas, still))
+        resize.observe(canvas)
+      })
+      .catch(() => {
+        // broken preview, keep the empty background
+      })
+    return () => {
+      cancelled = true
+      resize?.disconnect()
+      bitmap?.close()
+    }
+  }, [nearViewport, src])
+
+  useEffect(() => {
+    const card = wrapRef.current?.closest<HTMLElement>('[data-preview-hover]') ?? wrapRef.current
+    if (!card) return
+    let timer: ReturnType<typeof setTimeout> | null = null
+    const stop = (): void => {
+      if (timer) clearTimeout(timer)
+      timer = null
+      setLive(false)
+      setLiveLoaded(false)
+    }
+    const enter = (): void => {
+      if (timer) clearTimeout(timer)
+      timer = setTimeout(() => setLive(true), HOVER_DELAY_MS)
+    }
+    const visibility = (): void => {
+      if (document.hidden) stop()
+    }
+    card.addEventListener('pointerenter', enter)
+    card.addEventListener('pointerleave', stop)
+    document.addEventListener('visibilitychange', visibility)
+    return () => {
+      if (timer) clearTimeout(timer)
+      card.removeEventListener('pointerenter', enter)
+      card.removeEventListener('pointerleave', stop)
+      document.removeEventListener('visibilitychange', visibility)
+    }
+  }, [])
+
+  return (
+    <div ref={wrapRef} className={clsx('relative h-full w-full', className)} role="img" aria-label={alt}>
+      <canvas ref={canvasRef} className="absolute inset-0 h-full w-full" />
+      {live && (
+        <img
+          src={src}
+          alt=""
+          draggable={false}
+          onLoad={() => setLiveLoaded(true)}
+          className={clsx(
+            'absolute inset-0 h-full w-full object-cover transition-opacity duration-150',
+            liveLoaded ? 'opacity-100' : 'opacity-0'
+          )}
+        />
+      )}
+    </div>
+  )
+}

+ 2 - 2
src/renderer/src/components/common/PreviewSizeToggle.tsx

@@ -24,8 +24,8 @@ export default function PreviewSizeToggle({
           className={clsx(
             'px-2.5 py-2 transition-colors',
             value === opt.value
-              ? 'bg-indigo-600 text-white'
-              : 'bg-white/5 text-gray-400 hover:text-gray-200'
+              ? 'bg-accent-600 text-white'
+              : 'bg-fg/5 text-gray-400 hover:text-gray-200'
           )}
         >
           {opt.label}

+ 1 - 1
src/renderer/src/components/common/ScreenSelect.tsx

@@ -16,7 +16,7 @@ export default function ScreenSelect({ targets, value, onChange, title = 'Screen
       <select
         value={value}
         onChange={(e) => onChange(e.target.value)}
-        className="rounded bg-white/5 px-1.5 py-1 text-xs text-gray-200 outline-none"
+        className="rounded bg-fg/5 px-1.5 py-1 text-xs text-gray-200 outline-none"
       >
         <option value="*">All screens</option>
         {targets.map((t) => (

+ 8 - 8
src/renderer/src/components/common/ShortcutRow.tsx

@@ -103,7 +103,7 @@ export function ShortcutRow({
           onClick={() => setDraft(draft ? null : (current ?? { type: 'application', file: '', arguments: '' }))}
           disabled={busy}
           title={current ? 'Change shortcut' : 'Assign shortcut'}
-          className="rounded p-0.5 text-gray-400 hover:bg-white/10 hover:text-gray-200 disabled:opacity-40"
+          className="rounded p-0.5 text-gray-400 hover:bg-fg/10 hover:text-gray-200 disabled:opacity-40"
         >
           <Pencil size={12} />
         </button>
@@ -112,7 +112,7 @@ export function ShortcutRow({
             onClick={() => onCommit('')}
             disabled={busy}
             title="Remove shortcut"
-            className="rounded p-0.5 text-gray-400 hover:bg-white/10 hover:text-gray-200 disabled:opacity-40"
+            className="rounded p-0.5 text-gray-400 hover:bg-fg/10 hover:text-gray-200 disabled:opacity-40"
           >
             <X size={12} />
           </button>
@@ -120,7 +120,7 @@ export function ShortcutRow({
       </div>
 
       {draft && (
-        <div className="mt-1.5 space-y-1.5 rounded bg-white/5 p-1.5">
+        <div className="mt-1.5 space-y-1.5 rounded bg-fg/5 p-1.5">
           <div className="flex gap-1">
             {TYPES.map(({ type, label: typeLabel, icon: Icon }) => (
               <button
@@ -128,7 +128,7 @@ export function ShortcutRow({
                 onClick={() => setDraft({ type, file: '', arguments: '' })}
                 className={clsx(
                   'flex flex-1 items-center justify-center gap-1 rounded px-1 py-0.5',
-                  draft.type === type ? 'bg-indigo-500/30 text-indigo-200' : 'text-gray-400 hover:bg-white/5'
+                  draft.type === type ? 'bg-accent-500/30 text-accent-200' : 'text-gray-400 hover:bg-fg/5'
                 )}
               >
                 <Icon size={11} />
@@ -153,7 +153,7 @@ export function ShortcutRow({
                     title={app.file}
                     className={clsx(
                       'block w-full truncate rounded px-1.5 py-0.5 text-left',
-                      draft.file === app.file ? 'bg-indigo-500/30 text-indigo-200' : 'text-gray-300 hover:bg-white/5'
+                      draft.file === app.file ? 'bg-accent-500/30 text-accent-200' : 'text-gray-300 hover:bg-fg/5'
                     )}
                   >
                     {app.name}
@@ -173,7 +173,7 @@ export function ShortcutRow({
               />
               <button
                 onClick={() => pick(draft.type === 'directory' ? 'directory' : 'file')}
-                className="rounded bg-white/5 px-1.5 text-gray-300 hover:bg-white/10"
+                className="rounded bg-fg/5 px-1.5 text-gray-300 hover:bg-fg/10"
               >
                 Browse
               </button>
@@ -204,13 +204,13 @@ export function ShortcutRow({
           )}
 
           <div className="flex justify-end gap-1">
-            <button onClick={() => setDraft(null)} className="rounded px-2 py-0.5 text-gray-400 hover:bg-white/5">
+            <button onClick={() => setDraft(null)} className="rounded px-2 py-0.5 text-gray-400 hover:bg-fg/5">
               Cancel
             </button>
             <button
               onClick={save}
               disabled={!draft.file.trim() || busy}
-              className="rounded bg-indigo-500/80 px-2 py-0.5 text-white hover:bg-indigo-500 disabled:opacity-40"
+              className="rounded bg-accent-500/80 px-2 py-0.5 text-white hover:bg-accent-500 disabled:opacity-40"
             >
               Save
             </button>

+ 1 - 1
src/renderer/src/components/common/Toast.tsx

@@ -45,7 +45,7 @@ export function ToastProvider({ children }: { children: ReactNode }) {
           <div
             key={t.id}
             className={clsx(
-              'flex max-w-sm items-center gap-1.5 rounded-lg border px-3 py-2 text-xs font-medium text-white shadow-2xl',
+              'flex max-w-sm items-center gap-1.5 rounded-xl border px-3 py-2 text-xs font-medium text-white shadow-2xl shadow-black/30 backdrop-blur-md',
               t.warning ? 'border-amber-500/30 bg-amber-600/90' : 'border-green-500/30 bg-green-600/90'
             )}
           >

+ 35 - 0
src/renderer/src/components/common/Toggle.tsx

@@ -0,0 +1,35 @@
+import clsx from 'clsx'
+
+export default function Toggle({
+  on,
+  onClick,
+  disabled = false,
+  title
+}: {
+  on: boolean
+  onClick: () => void
+  disabled?: boolean
+  title?: string
+}) {
+  return (
+    <button
+      type="button"
+      role="switch"
+      aria-checked={on}
+      onClick={onClick}
+      disabled={disabled}
+      title={title}
+      className={clsx(
+        'relative inline-flex h-5 w-9 shrink-0 items-center rounded-full transition-colors disabled:cursor-not-allowed disabled:opacity-50',
+        on ? 'bg-accent-600 shadow-[0_0_10px_-2px] shadow-accent-500/60' : 'bg-fg/10 hover:bg-fg/15'
+      )}
+    >
+      <span
+        className={clsx(
+          'inline-block h-3.5 w-3.5 rounded-full bg-white shadow-sm transition-transform duration-200',
+          on ? 'translate-x-4' : 'translate-x-0.5'
+        )}
+      />
+    </button>
+  )
+}

+ 11 - 2
src/renderer/src/components/common/WallpaperContextMenu.tsx

@@ -8,13 +8,15 @@ import {
   MenuSelectionCount,
   MenuSeparator,
   SubMenu,
-  VoteMenuItems
+  VoteMenuItems,
+  FavoriteMenuItems
 } from './ContextMenu'
 import { useToast } from './Toast'
 import { useConfig, useFolders } from '../../hooks/queries'
 import { useBatchVote } from '../../hooks/useVotes'
+import { useBatchFavorite, useFavoriteIds } from '../../hooks/useFavorites'
 import { useUnsubscribe } from '../../hooks/useWallpaperActions'
-import { openWorkshopPage } from '../../utils/steam'
+import { isWorkshopId, openWorkshopPage } from '../../utils/steam'
 import {
   backupSummary,
   canBrowseCreator,
@@ -49,6 +51,8 @@ export default function WallpaperContextMenu({
   const libraries = config?.extraLibraries ?? []
   const { moveToFolder, removeFromFolders, menuState } = useFolders()
   const batchVote = useBatchVote()
+  const batchFavorite = useBatchFavorite()
+  const favoriteIds = useFavoriteIds()
   const unsubscribe = useUnsubscribe()
 
   const backupable = wallpapers.filter((w) => w.source === 'workshop')
@@ -154,6 +158,11 @@ export default function WallpaperContextMenu({
 
       <MenuSeparator />
       <VoteMenuItems onVote={(up) => run(() => batchVote(ids, up))()} />
+      <FavoriteMenuItems
+        ids={ids.filter(isWorkshopId)}
+        favorites={favoriteIds}
+        onFavorite={(favIds, add) => run(() => batchFavorite(favIds, add))()}
+      />
 
       <MenuSeparator />
       <MenuItem icon={ExternalLink} onClick={run(() => ids.forEach(openWorkshopPage))}>

+ 5 - 5
src/renderer/src/components/common/sidebar/CompatSection.tsx

@@ -53,7 +53,7 @@ export default function CompatSection({ wallpaper, canTest, onChange, onTest }:
   }
 
   return (
-    <div className="border-t border-white/5 pt-3">
+    <div className="border-t border-fg/5 pt-3">
       <button
         onClick={() => setOpen((v) => !v)}
         className="flex w-full items-center gap-1.5 text-xs font-semibold uppercase tracking-wide text-gray-500 hover:text-gray-300"
@@ -78,7 +78,7 @@ export default function CompatSection({ wallpaper, canTest, onChange, onTest }:
               {new Date(compat.lastCrash.at).toLocaleString()}
               {compat.runtimeCrashes ? ` (${compat.runtimeCrashes} while running so far)` : ''}
               {compat.lastCrash.log.length > 0 && (
-                <button onClick={() => setShowLog((v) => !v)} className="ml-1 text-indigo-300 hover:text-indigo-200">
+                <button onClick={() => setShowLog((v) => !v)} className="ml-1 text-accent-300 hover:text-accent-200">
                   {showLog ? 'hide log' : 'show log'}
                 </button>
               )}
@@ -96,7 +96,7 @@ export default function CompatSection({ wallpaper, canTest, onChange, onTest }:
             onBlur={(e) => commitNote(e.target.value)}
             rows={2}
             placeholder="Notes, e.g. needs Show full image, glitches with effects on"
-            className="w-full resize-y rounded border border-white/10 bg-black/30 px-2 py-1 text-xs text-gray-200 placeholder:text-gray-600 focus:border-indigo-500/50 focus:outline-none"
+            className="w-full resize-y rounded border border-fg/10 bg-black/30 px-2 py-1 text-xs text-gray-200 placeholder:text-gray-600 focus:border-accent-500/50 focus:outline-none"
           />
 
           <div className="flex gap-1.5">
@@ -105,7 +105,7 @@ export default function CompatSection({ wallpaper, canTest, onChange, onTest }:
                 onClick={test}
                 disabled={testing}
                 title="Launch it fresh and record whether it survives"
-                className="flex items-center gap-1 rounded bg-white/5 px-2 py-1 text-gray-300 hover:bg-white/10 disabled:opacity-50"
+                className="flex items-center gap-1 rounded bg-fg/5 px-2 py-1 text-gray-300 hover:bg-fg/10 disabled:opacity-50"
               >
                 {testing ? <Loader2 size={11} className="animate-spin" /> : <FlaskConical size={11} />}
                 Test fresh launch
@@ -114,7 +114,7 @@ export default function CompatSection({ wallpaper, canTest, onChange, onTest }:
             {status !== 'ok' && (
               <button
                 onClick={clearStatus}
-                className="flex items-center gap-1 rounded bg-white/5 px-2 py-1 text-gray-300 hover:bg-white/10"
+                className="flex items-center gap-1 rounded bg-fg/5 px-2 py-1 text-gray-300 hover:bg-fg/10"
               >
                 <Undo2 size={11} />
                 Forget crashes

+ 4 - 4
src/renderer/src/components/common/sidebar/EngineFlagsSection.tsx

@@ -10,7 +10,7 @@ interface Props {
   onChange: (patch: Pick<WallpaperMeta, 'engineFlags' | 'fpsOverride'>) => Promise<void>
 }
 
-const selectClass = 'rounded bg-white/5 px-1.5 py-1 text-xs text-gray-200 outline-none disabled:opacity-50'
+const selectClass = 'rounded bg-fg/5 px-1.5 py-1 text-xs text-gray-200 outline-none disabled:opacity-50'
 
 const onOff = (value: boolean | undefined) => (value ? 'on' : 'off')
 
@@ -46,7 +46,7 @@ export default function EngineFlagsSection({ flags = {}, onChange }: Props) {
   }
 
   return (
-    <div className="border-t border-white/5 pt-3">
+    <div className="border-t border-fg/5 pt-3">
       <button
         onClick={() => setOpen((v) => !v)}
         className="flex w-full items-center gap-1.5 text-xs font-semibold uppercase tracking-wide text-gray-500 hover:text-gray-300"
@@ -55,7 +55,7 @@ export default function EngineFlagsSection({ flags = {}, onChange }: Props) {
         <Gauge size={12} />
         <span className="flex-1 text-left">Performance</span>
         {hasEngineFlags(flags) && (
-          <span className="rounded-full bg-indigo-600/30 px-1.5 normal-case text-indigo-300">custom</span>
+          <span className="rounded-full bg-accent-600/30 px-1.5 normal-case text-accent-300">custom</span>
         )}
         {busy && <Loader2 size={11} className="animate-spin" />}
       </button>
@@ -86,7 +86,7 @@ export default function EngineFlagsSection({ flags = {}, onChange }: Props) {
               <button
                 onClick={() => commit({ engineFlags: undefined })}
                 disabled={busy}
-                className="rounded bg-white/5 px-2 py-1 text-xs text-gray-400 hover:bg-white/10 disabled:opacity-50"
+                className="rounded bg-fg/5 px-2 py-1 text-xs text-gray-400 hover:bg-fg/10 disabled:opacity-50"
               >
                 Reset
               </button>

+ 5 - 5
src/renderer/src/components/common/sidebar/ImageAdjustmentsSection.tsx

@@ -19,7 +19,7 @@ const COLOR_SLIDERS: { key: SliderKey; label: string }[] = [
   { key: 'hue', label: 'Hue shift' }
 ]
 
-const selectClass = 'w-full rounded bg-white/5 px-1.5 py-1 text-xs text-gray-200 outline-none disabled:opacity-50'
+const selectClass = 'w-full rounded bg-fg/5 px-1.5 py-1 text-xs text-gray-200 outline-none disabled:opacity-50'
 
 export default function ImageAdjustmentsSection({ adjustments = {}, live, onCommit, onPreview }: Props) {
   const [draft, setDraft] = useState<ImageAdjustments | null>(null)
@@ -60,7 +60,7 @@ export default function ImageAdjustmentsSection({ adjustments = {}, live, onComm
           onMouseUp={() => draft && commit(draft)}
           onTouchEnd={() => draft && commit(draft)}
           onKeyUp={() => draft && commit(draft)}
-          className="w-full accent-indigo-500 disabled:opacity-50"
+          className="w-full accent-accent-500 disabled:opacity-50"
         />
       </div>
     )
@@ -69,7 +69,7 @@ export default function ImageAdjustmentsSection({ adjustments = {}, live, onComm
   const colorsChanged = COLOR_SLIDERS.some(({ key }) => (current[key] ?? NEUTRAL_COLOR_VALUE) !== NEUTRAL_COLOR_VALUE)
 
   return (
-    <div className="border-t border-white/5 pt-3">
+    <div className="border-t border-fg/5 pt-3">
       <div className="mb-1.5 flex items-center gap-1.5 text-xs font-semibold uppercase tracking-wide text-gray-500">
         <SlidersHorizontal size={12} />
         <span className="flex-1 text-left">Image</span>
@@ -103,7 +103,7 @@ export default function ImageAdjustmentsSection({ adjustments = {}, live, onComm
             checked={current.colorEnabled ?? false}
             disabled={busy}
             onChange={(e) => commit({ ...current, colorEnabled: e.target.checked })}
-            className="accent-indigo-500"
+            className="accent-accent-500"
           />
           <span className="flex-1">Color options</span>
           {current.colorEnabled && colorsChanged && (
@@ -136,7 +136,7 @@ export default function ImageAdjustmentsSection({ adjustments = {}, live, onComm
             checked={current.flip ?? false}
             disabled={busy}
             onChange={(e) => commit({ ...current, flip: e.target.checked })}
-            className="accent-indigo-500"
+            className="accent-accent-500"
           />
           Flip horizontally
         </label>

+ 7 - 7
src/renderer/src/components/common/sidebar/ThumbnailSection.tsx

@@ -33,7 +33,7 @@ export default function ThumbnailSection({ wallpaper, canGenerate, onUpdated }:
     run('toggle', () => window.electronAPI.library.update(wallpaper.id, { useOriginalPreview: value }))
 
   return (
-    <div className="border-t border-white/5 pt-3">
+    <div className="border-t border-fg/5 pt-3">
       <button
         onClick={() => setOpen((v) => !v)}
         className="flex w-full items-center gap-1.5 text-xs font-semibold uppercase tracking-wide text-gray-500 hover:text-gray-300"
@@ -41,14 +41,14 @@ export default function ThumbnailSection({ wallpaper, canGenerate, onUpdated }:
         {open ? <ChevronDown size={12} /> : <ChevronRight size={12} />}
         <Camera size={12} />
         <span className="flex-1 text-left">Thumbnail</span>
-        {usingCustom && <span className="rounded-full bg-indigo-600/30 px-1.5 normal-case text-indigo-300">custom</span>}
+        {usingCustom && <span className="rounded-full bg-accent-600/30 px-1.5 normal-case text-accent-300">custom</span>}
         {busy && <Loader2 size={11} className="animate-spin" />}
       </button>
 
       {open && (
         <div className="mt-2 flex flex-col gap-2 text-xs">
           {hasCustom && (
-            <div className="flex overflow-hidden rounded bg-white/5">
+            <div className="flex overflow-hidden rounded bg-fg/5">
               {[
                 { label: 'Custom', original: false },
                 { label: 'Original', original: true }
@@ -59,7 +59,7 @@ export default function ThumbnailSection({ wallpaper, canGenerate, onUpdated }:
                   disabled={busy !== null || usingCustom === !original}
                   className={clsx(
                     'flex-1 py-1',
-                    usingCustom === !original ? 'bg-indigo-600 text-white' : 'text-gray-400 hover:bg-white/10'
+                    usingCustom === !original ? 'bg-accent-600 text-white' : 'text-gray-400 hover:bg-fg/10'
                   )}
                 >
                   {label}
@@ -74,7 +74,7 @@ export default function ThumbnailSection({ wallpaper, canGenerate, onUpdated }:
                 onClick={() => run('generate', () => window.electronAPI.wallpaper.generateThumbnail(wallpaper.id))}
                 disabled={busy !== null}
                 title="Renders the wallpaper with your settings in a small window for a few seconds and saves a frame"
-                className="flex items-center gap-1 rounded bg-white/5 px-2 py-1 text-gray-300 hover:bg-white/10 disabled:opacity-50"
+                className="flex items-center gap-1 rounded bg-fg/5 px-2 py-1 text-gray-300 hover:bg-fg/10 disabled:opacity-50"
               >
                 <Camera size={11} />
                 {busy === 'generate' ? 'Capturing...' : 'Capture'}
@@ -83,7 +83,7 @@ export default function ThumbnailSection({ wallpaper, canGenerate, onUpdated }:
             <button
               onClick={() => run('pick', () => window.electronAPI.wallpaper.pickThumbnail(wallpaper.id))}
               disabled={busy !== null}
-              className="flex items-center gap-1 rounded bg-white/5 px-2 py-1 text-gray-300 hover:bg-white/10 disabled:opacity-50"
+              className="flex items-center gap-1 rounded bg-fg/5 px-2 py-1 text-gray-300 hover:bg-fg/10 disabled:opacity-50"
             >
               <ImagePlus size={11} />
               Choose image
@@ -92,7 +92,7 @@ export default function ThumbnailSection({ wallpaper, canGenerate, onUpdated }:
               <button
                 onClick={() => run('delete', () => window.electronAPI.wallpaper.deleteThumbnail(wallpaper.id))}
                 disabled={busy !== null}
-                className="flex items-center gap-1 rounded bg-white/5 px-2 py-1 text-gray-300 hover:bg-red-500/20 hover:text-red-400 disabled:opacity-50"
+                className="flex items-center gap-1 rounded bg-fg/5 px-2 py-1 text-gray-300 hover:bg-red-500/20 hover:text-red-400 disabled:opacity-50"
               >
                 <ImageOff size={11} />
                 Remove custom

+ 8 - 8
src/renderer/src/components/common/sidebar/VideoTrimSection.tsx

@@ -24,7 +24,7 @@ const SEAM_LEAD = 3
 const NEW_PART_LENGTH = 30
 
 const timeInputClass =
-  'w-16 rounded bg-white/5 px-1 py-0.5 text-right text-gray-300 outline-none focus:ring-1 focus:ring-indigo-500 disabled:opacity-50'
+  'w-16 rounded bg-fg/5 px-1 py-0.5 text-right text-gray-300 outline-none focus:ring-1 focus:ring-accent-500 disabled:opacity-50'
 
 export default function VideoTrimSection({ segments, duration, live, onCommit, onPreview }: Props) {
   const [draft, setDraft] = useState<VideoSegment[] | null>(null)
@@ -152,14 +152,14 @@ export default function VideoTrimSection({ segments, duration, live, onCommit, o
           onTouchEnd={() => draft && commit(draft)}
           onKeyUp={() => draft && commit(draft)}
           title={side === 'start' ? 'Where this part starts' : 'Where this part ends and the next one starts'}
-          className="w-full accent-indigo-500 disabled:opacity-50"
+          className="w-full accent-accent-500 disabled:opacity-50"
         />
       </div>
     )
   }
 
   return (
-    <div className="border-t border-white/5 pt-3">
+    <div className="border-t border-fg/5 pt-3">
       <div className="mb-1.5 flex items-center gap-1.5 text-xs font-semibold uppercase tracking-wide text-gray-500">
         <Scissors size={12} />
         <span className="flex-1 text-left">Video trim</span>
@@ -182,14 +182,14 @@ export default function VideoTrimSection({ segments, duration, live, onCommit, o
 
       <div className="space-y-1.5 text-[11px] text-gray-400">
         {duration !== null && (
-          <div className="relative h-2.5 overflow-hidden rounded bg-white/5">
+          <div className="relative h-2.5 overflow-hidden rounded bg-fg/5">
             {(rows.length ? rows : [{ start: 0 }]).map((s, i) => (
               <button
                 key={i}
                 disabled={!rows.length}
                 onClick={() => setSelected(i)}
                 title={`${formatVideoTime(s.start)} - ${formatVideoTime(endOf(s) ?? duration)}`}
-                className={`absolute inset-y-0 ${rows.length && i === index ? 'bg-indigo-400' : 'bg-indigo-500/50'}`}
+                className={`absolute inset-y-0 ${rows.length && i === index ? 'bg-accent-400' : 'bg-accent-500/50'}`}
                 style={{
                   left: `${(Math.min(s.start, duration) / duration) * 100}%`,
                   width: `${((Math.min(endOf(s) ?? duration, duration) - Math.min(s.start, duration)) / duration) * 100}%`
@@ -201,7 +201,7 @@ export default function VideoTrimSection({ segments, duration, live, onCommit, o
 
         {rows.length === 0 && <p className="text-gray-600">Plays the whole video.</p>}
         {rows.map((s, i) => (
-          <div key={i} className={`flex items-center gap-1.5 rounded px-1 ${i === index ? 'bg-white/5' : ''}`}>
+          <div key={i} className={`flex items-center gap-1.5 rounded px-1 ${i === index ? 'bg-fg/5' : ''}`}>
             <button
               onClick={() => setSelected(i)}
               className={`flex-1 text-left ${i === index ? 'text-gray-200' : 'text-gray-500 hover:text-gray-300'}`}
@@ -235,7 +235,7 @@ export default function VideoTrimSection({ segments, duration, live, onCommit, o
             disabled={busy || newPart() === null}
             onClick={addPart}
             title="Add another part after the last one"
-            className="flex items-center gap-1 rounded bg-white/10 px-1.5 py-0.5 text-[10px] text-gray-300 hover:bg-white/15 disabled:opacity-40"
+            className="flex items-center gap-1 rounded bg-fg/10 px-1.5 py-0.5 text-[10px] text-gray-300 hover:bg-fg/15 disabled:opacity-40"
           >
             <Plus size={9} />
             Add part
@@ -245,7 +245,7 @@ export default function VideoTrimSection({ segments, duration, live, onCommit, o
               disabled={busy}
               onClick={() => onPreview(segments, seamSeek(part))}
               title={`Jumps ${SEAM_LEAD} seconds before the end of part ${index + 1}, to see the cut into the next one`}
-              className="flex items-center gap-1 rounded bg-white/10 px-1.5 py-0.5 text-[10px] text-gray-300 hover:bg-white/15 disabled:opacity-40"
+              className="flex items-center gap-1 rounded bg-fg/10 px-1.5 py-0.5 text-[10px] text-gray-300 hover:bg-fg/15 disabled:opacity-40"
             >
               <Play size={9} />
               Cut

+ 32 - 27
src/renderer/src/components/layout/Sidebar.tsx

@@ -1,4 +1,4 @@
-import { Globe, Library, ListVideo, Settings } from 'lucide-react'
+import { Globe, Library, ListVideo, Settings, type LucideIcon } from 'lucide-react'
 import clsx from 'clsx'
 
 type View = 'workshop' | 'library' | 'playlists' | 'settings'
@@ -8,6 +8,29 @@ interface SidebarProps {
   onNavigate: (view: View) => void
 }
 
+function NavButton({ active, label, icon: Icon, onClick }: { active: boolean; label: string; icon: LucideIcon; onClick: () => void }) {
+  return (
+    <button
+      onClick={onClick}
+      title={label}
+      className={clsx(
+        'relative flex h-10 w-10 items-center justify-center rounded-xl transition-all',
+        active
+          ? 'bg-accent-500/15 text-accent-300 ring-1 ring-accent-500/25'
+          : 'text-gray-500 hover:bg-fg/5 hover:text-gray-300'
+      )}
+    >
+      <span
+        className={clsx(
+          'absolute -left-2 top-1/2 w-1 -translate-y-1/2 rounded-r-full bg-accent-500 transition-all',
+          active ? 'h-5 opacity-100' : 'h-0 opacity-0'
+        )}
+      />
+      <Icon size={20} strokeWidth={active ? 2.2 : 1.8} />
+    </button>
+  )
+}
+
 export default function Sidebar({ activeView, onNavigate }: SidebarProps) {
   const items = [
     { id: 'workshop' as View, label: 'Workshop', icon: Globe },
@@ -16,35 +39,17 @@ export default function Sidebar({ activeView, onNavigate }: SidebarProps) {
   ]
 
   return (
-    <aside className="flex w-14 flex-col items-center gap-2 border-r border-white/5 bg-[#0a0a0a] py-4">
-      {items.map(({ id, label, icon: Icon }) => (
-        <button
-          key={id}
-          onClick={() => onNavigate(id)}
-          title={label}
-          className={clsx(
-            'flex h-10 w-10 items-center justify-center rounded-lg transition-colors',
-            activeView === id
-              ? 'bg-indigo-600 text-white'
-              : 'text-gray-500 hover:bg-white/5 hover:text-gray-300'
-          )}
-        >
-          <Icon size={20} />
-        </button>
+    <aside className="flex w-14 flex-col items-center gap-1.5 border-r border-fg/5 bg-chrome py-3">
+      {items.map(({ id, label, icon }) => (
+        <NavButton key={id} active={activeView === id} label={label} icon={icon} onClick={() => onNavigate(id)} />
       ))}
       <div className="flex-1" />
-      <button
+      <NavButton
+        active={activeView === 'settings'}
+        label="Settings"
+        icon={Settings}
         onClick={() => onNavigate('settings')}
-        title="Settings"
-        className={clsx(
-          'flex h-10 w-10 items-center justify-center rounded-lg transition-colors',
-          activeView === 'settings'
-            ? 'bg-indigo-600 text-white'
-            : 'text-gray-500 hover:bg-white/5 hover:text-gray-300'
-        )}
-      >
-        <Settings size={20} />
-      </button>
+      />
     </aside>
   )
 }

+ 3 - 3
src/renderer/src/components/layout/StatusBar.tsx

@@ -19,7 +19,7 @@ export default function StatusBar() {
   const active = players.filter((p) => p.playlistId)
 
   return (
-    <footer className="flex h-6 items-center gap-3 border-t border-white/5 bg-[#0a0a0a] px-3 text-xs text-gray-500">
+    <footer className="flex h-6 items-center gap-3 border-t border-fg/5 bg-chrome px-3 text-xs text-gray-500">
       <span className="flex items-center gap-1">
         {steamRunning ? (
           <>
@@ -36,8 +36,8 @@ export default function StatusBar() {
 
       {active.map((playback) => (
         <span key={playback.screen} className="flex items-center gap-1.5">
-          <span className="h-3 w-px bg-white/10" />
-          <ListVideo size={12} className="text-indigo-400" />
+          <span className="h-3 w-px bg-fg/10" />
+          <ListVideo size={12} className="text-accent-400" />
           {playlists?.find((p) => p.id === playback.playlistId)?.title ?? 'Playlist'}
           {playback.screen !== '*' && <span className="text-gray-600">on {screenLabel(playback.screen)}</span>}
           <button

+ 57 - 30
src/renderer/src/components/library/LibraryView.tsx

@@ -42,8 +42,9 @@ import {
 } from '../../constants/weFilters'
 import { usePreviewSize, previewGridStyle } from '../../hooks/usePreviewSize'
 import { usePersistentState } from '../../hooks/usePersistentState'
-import { useVoteBorders } from '../../hooks/useVoteBorders'
-import { useVotedIds } from '../../hooks/useVotes'
+import { useCardBorders, useCardSteamState } from '../../hooks/useCardBorders'
+import { useDislikedIds, useVotedIds } from '../../hooks/useVotes'
+import { useFavoriteIds } from '../../hooks/useFavorites'
 import { useConfig, useFolders, useLweInstalled, usePlaybackStates, usePlaylists } from '../../hooks/queries'
 import { useApplyWallpaper, useSubscribe, useUnsubscribe } from '../../hooks/useWallpaperActions'
 import { useSelectableGrid } from '../../hooks/useSelectableGrid'
@@ -59,6 +60,8 @@ interface LibraryFilterState {
   sources: string[]
   failedOnly: boolean
   likedOnly: boolean
+  dislikedOnly: boolean
+  favoritesOnly: boolean
   unavailableOnly: boolean
   outdatedBackupOnly: boolean
 }
@@ -71,6 +74,8 @@ const DEFAULT_STATE: LibraryFilterState = {
   sources: [],
   failedOnly: false,
   likedOnly: false,
+  dislikedOnly: false,
+  favoritesOnly: false,
   unavailableOnly: false,
   outdatedBackupOnly: false
 }
@@ -130,7 +135,7 @@ function TagsFilterSection({
         placeholder="Search tags..."
         value={search}
         onChange={(e) => setSearch(e.target.value)}
-        className="mb-1 w-full rounded bg-white/5 px-2 py-1 text-xs text-gray-200 outline-none focus:ring-1 focus:ring-indigo-500"
+        className="mb-1 w-full rounded bg-fg/5 px-2 py-1 text-xs text-gray-200 outline-none focus:ring-1 focus:ring-accent-500"
       />
       <div className="max-h-64 overflow-y-auto">
         {filtered.length === 0 && <p className="py-1 text-xs text-gray-600">No tags found</p>}
@@ -150,7 +155,7 @@ function TagsFilterSection({
 function folderRowClass(active: boolean): string {
   return clsx(
     'flex items-center gap-2 px-3 py-1.5 text-xs',
-    active ? 'bg-white/5 text-white' : 'text-gray-400 hover:bg-white/5 hover:text-gray-200'
+    active ? 'bg-fg/5 text-fg' : 'text-gray-400 hover:bg-fg/5 hover:text-gray-200'
   )
 }
 
@@ -187,7 +192,10 @@ export default function LibraryView({ onBrowseCreator }: LibraryViewProps) {
   const [ctxMenu, setCtxMenu] = useState<{ x: number; y: number; ids: string[] } | null>(null)
 
   const votedSet = useVotedIds()
-  const { enabled: voteBordersEnabled, failed: failedVotes } = useVoteBorders()
+  const dislikedSet = useDislikedIds()
+  const favoriteSet = useFavoriteIds()
+  const steamStateOf = useCardSteamState()
+  const cardBorders = useCardBorders()
   const lweInstalled = useLweInstalled()
   const isBackupConfigured = useConfig()?.isBackupConfigured ?? false
   const { folders, refetchFolders, moveToFolder } = useFolders()
@@ -199,13 +207,15 @@ export default function LibraryView({ onBrowseCreator }: LibraryViewProps) {
     setFilterState((prev) => ({ ...prev, [key]: value }))
   }
 
-  function toggleFlag(key: 'failedOnly' | 'likedOnly' | 'unavailableOnly' | 'outdatedBackupOnly') {
+  function toggleFlag(key: 'failedOnly' | 'likedOnly' | 'dislikedOnly' | 'favoritesOnly' | 'unavailableOnly' | 'outdatedBackupOnly') {
     setFilterState((prev) => ({ ...prev, [key]: !prev[key] }))
   }
 
   const flagCount =
     (filterState.failedOnly ? 1 : 0) +
     (filterState.likedOnly ? 1 : 0) +
+    (filterState.dislikedOnly ? 1 : 0) +
+    (filterState.favoritesOnly ? 1 : 0) +
     (filterState.unavailableOnly ? 1 : 0) +
     (filterState.outdatedBackupOnly ? 1 : 0)
   const activeCount =
@@ -259,11 +269,13 @@ export default function LibraryView({ onBrowseCreator }: LibraryViewProps) {
       if (filterState.sources.length > 0 && !sources.includes(w.source)) return false
       if (filterState.failedOnly && !w.downloadFailed) return false
       if (filterState.likedOnly && !votedSet.has(w.id)) return false
+      if (filterState.dislikedOnly && !dislikedSet.has(w.id)) return false
+      if (filterState.favoritesOnly && !favoriteSet.has(w.id)) return false
       if (filterState.unavailableOnly && !w.unavailable) return false
       if (filterState.outdatedBackupOnly && !isBackupOutdated(w)) return false
       return true
     })
-  }, [allWallpapers, filterState, votedSet])
+  }, [allWallpapers, filterState, votedSet, dislikedSet, favoriteSet])
 
   const existingIds = useMemo(() => new Set(allWallpapers.map((w) => w.id)), [allWallpapers])
 
@@ -271,10 +283,12 @@ export default function LibraryView({ onBrowseCreator }: LibraryViewProps) {
     () => ({
       failed: allWallpapers.filter((w) => w.downloadFailed).length,
       liked: allWallpapers.filter((w) => votedSet.has(w.id)).length,
+      disliked: allWallpapers.filter((w) => dislikedSet.has(w.id)).length,
+      favorites: allWallpapers.filter((w) => favoriteSet.has(w.id)).length,
       unavailable: allWallpapers.filter((w) => w.unavailable).length,
       outdatedBackup: allWallpapers.filter(isBackupOutdated).length
     }),
-    [allWallpapers, votedSet]
+    [allWallpapers, votedSet, dislikedSet, favoriteSet]
   )
 
   // Removed-from-workshop items with local content that hasn't been backed up yet
@@ -545,14 +559,14 @@ export default function LibraryView({ onBrowseCreator }: LibraryViewProps) {
 
   return (
     <div className="flex h-full flex-col">
-      <div className="flex flex-wrap items-center gap-3 border-b border-white/5 px-4 py-3">
+      <div className="flex flex-wrap items-center gap-3 border-b border-fg/5 px-4 py-3">
         <FiltersToggle open={showFilters} activeCount={activeCount} onClick={() => setShowFilters((v) => !v)} />
         <PanelToggle icon={Folder} label="Folders" open={showFolders} onClick={() => setShowFolders((v) => !v)} />
         <SearchInput value={search} placeholder="Search library..." onChange={setSearch} />
         <select
           value={sort.sortBy ?? 'updatedAt'}
           onChange={(e) => setSort((prev) => ({ ...prev, sortBy: e.target.value as LibraryFilters['sortBy'] }))}
-          className="rounded-lg bg-[#1a1a1a] px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-indigo-500"
+          className="rounded-lg bg-card px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-accent-500"
         >
           <option value="title">Name</option>
           <option value="updatedAt">Date Updated</option>
@@ -564,14 +578,14 @@ export default function LibraryView({ onBrowseCreator }: LibraryViewProps) {
         <button
           onClick={() => setSort((prev) => ({ ...prev, sortDir: prev.sortDir === 'asc' ? 'desc' : 'asc' }))}
           title={sort.sortDir === 'asc' ? 'Ascending' : 'Descending'}
-          className="rounded-lg bg-white/5 px-2 py-2 text-sm text-gray-300 hover:bg-white/10"
+          className="rounded-lg bg-fg/5 px-2 py-2 text-sm text-gray-300 hover:bg-fg/10"
         >
           {sort.sortDir === 'asc' ? '↑' : '↓'}
         </button>
         <select
           value={pageSize}
           onChange={(e) => setPageSize(Number(e.target.value))}
-          className="rounded-lg bg-[#1a1a1a] px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-indigo-500"
+          className="rounded-lg bg-card px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-accent-500"
         >
           <option value={50}>50 / page</option>
           <option value={100}>100 / page</option>
@@ -609,7 +623,7 @@ export default function LibraryView({ onBrowseCreator }: LibraryViewProps) {
         </ToolbarButton>
       </div>
 
-      <div className="flex min-h-10 items-center gap-2 border-b border-white/5 px-4 py-1.5">
+      <div className="flex min-h-10 items-center gap-2 border-b border-fg/5 px-4 py-1.5">
         <span className="text-xs text-gray-600">
           {selectedIds.size > 0
             ? `${selectedIds.size} selected / ${wallpapers.length} wallpapers`
@@ -640,7 +654,7 @@ export default function LibraryView({ onBrowseCreator }: LibraryViewProps) {
               onClick={handleBackupSelection}
               disabled={runningTasks.has('backup-selection') || !isBackupConfigured}
               title={isBackupConfigured ? 'Back up selected wallpapers' : BACKUP_FOLDER_HINT}
-              className="flex items-center gap-1.5 rounded-lg bg-white/5 px-3 py-1.5 text-xs text-gray-300 hover:bg-white/10 disabled:opacity-50"
+              className="flex items-center gap-1.5 rounded-lg bg-fg/5 px-3 py-1.5 text-xs text-gray-300 hover:bg-fg/10 disabled:opacity-50"
             >
               {runningTasks.has('backup-selection') ? (
                 <Loader2 size={12} className="animate-spin" />
@@ -654,13 +668,13 @@ export default function LibraryView({ onBrowseCreator }: LibraryViewProps) {
       </div>
 
       {scanResult && (
-        <div className="border-b border-white/5 px-4 py-2 text-xs text-gray-400">
+        <div className="border-b border-fg/5 px-4 py-2 text-xs text-gray-400">
           Scan complete: {scanResult.imported} imported{scanResult.removed > 0 ? `, ${scanResult.removed} removed` : ''}
         </div>
       )}
 
       {backupProgress.size > 0 && (
-        <div className="border-b border-white/5 px-4 py-2 text-xs text-gray-400">
+        <div className="border-b border-fg/5 px-4 py-2 text-xs text-gray-400">
           {progressVerb(Array.from(backupProgress.values()))} {backupProgress.size} wallpaper
           {backupProgress.size === 1 ? '' : 's'}
           {Array.from(backupProgress.values()).some((p) => p.status === 'verifying')
@@ -676,7 +690,7 @@ export default function LibraryView({ onBrowseCreator }: LibraryViewProps) {
       )}
 
       {backupStatus && (
-        <div className="border-b border-white/5 px-4 py-2 text-xs text-gray-400">
+        <div className="border-b border-fg/5 px-4 py-2 text-xs text-gray-400">
           {backupStatus}
         </div>
       )}
@@ -699,6 +713,20 @@ export default function LibraryView({ onBrowseCreator }: LibraryViewProps) {
                 checked={filterState.likedOnly}
                 onChange={() => toggleFlag('likedOnly')}
               />
+              <CheckItem
+                label="Disliked"
+                title="Show only wallpapers you've disliked on Steam"
+                count={statusCounts.disliked}
+                checked={filterState.dislikedOnly}
+                onChange={() => toggleFlag('dislikedOnly')}
+              />
+              <CheckItem
+                label="Favorites"
+                title="Show only wallpapers in your Steam favorites"
+                count={statusCounts.favorites}
+                checked={filterState.favoritesOnly}
+                onChange={() => toggleFlag('favoritesOnly')}
+              />
               <CheckItem
                 label="Unavailable"
                 title={
@@ -751,7 +779,7 @@ export default function LibraryView({ onBrowseCreator }: LibraryViewProps) {
         )}
 
         {showFolders && (
-        <div className="flex w-48 flex-shrink-0 flex-col border-r border-white/5 overflow-y-auto">
+        <div className="flex w-48 flex-shrink-0 flex-col border-r border-fg/5 overflow-y-auto">
           <div className="flex items-center justify-between px-3 pt-3 pb-1">
             <span className="text-[10px] font-semibold uppercase tracking-wide text-gray-600">
               Folders
@@ -782,7 +810,7 @@ export default function LibraryView({ onBrowseCreator }: LibraryViewProps) {
           </div>
 
           {importStatus && (
-            <div className="px-3 py-1.5 text-[10px] text-gray-400 border-b border-white/5">
+            <div className="px-3 py-1.5 text-[10px] text-gray-400 border-b border-fg/5">
               {importStatus}
             </div>
           )}
@@ -848,11 +876,11 @@ export default function LibraryView({ onBrowseCreator }: LibraryViewProps) {
             <div className="mb-3 flex items-center gap-1.5 text-xs text-gray-400">
               <button
                 onClick={() => setActiveFolder(null)}
-                className="flex items-center gap-1 rounded bg-white/5 px-2 py-1 text-gray-300 hover:bg-white/10"
+                className="flex items-center gap-1 rounded bg-fg/5 px-2 py-1 text-gray-300 hover:bg-fg/10"
               >
                 <ChevronLeft size={12} /> Default
               </button>
-              <FolderOpen size={12} className="ml-1 text-indigo-400" />
+              <FolderOpen size={12} className="ml-1 text-accent-400" />
               <span className="truncate text-gray-200">{activeFolderTitle}</span>
             </div>
           )}
@@ -882,18 +910,18 @@ export default function LibraryView({ onBrowseCreator }: LibraryViewProps) {
                   onContextMenu={(e) => openFolderMenu(e, folder)}
                   onDragOver={(e) => {
                     e.preventDefault()
-                    e.currentTarget.classList.add('ring-2', 'ring-indigo-500')
+                    e.currentTarget.classList.add('ring-2', 'ring-accent-500')
                   }}
                   onDragLeave={(e) => {
-                    e.currentTarget.classList.remove('ring-2', 'ring-indigo-500')
+                    e.currentTarget.classList.remove('ring-2', 'ring-accent-500')
                   }}
                   onDrop={(e) => {
-                    e.currentTarget.classList.remove('ring-2', 'ring-indigo-500')
+                    e.currentTarget.classList.remove('ring-2', 'ring-accent-500')
                     handleDrop(folder.id, dropWallpaperId(e))
                   }}
-                  className="group flex cursor-pointer items-center gap-3 rounded-lg bg-[#1a1a1a] p-4 transition-all hover:ring-1 hover:ring-indigo-500/50"
+                  className="group flex cursor-pointer items-center gap-3 rounded-lg bg-card p-4 transition-all hover:ring-1 hover:ring-accent-500/50"
                 >
-                  <Folder size={28} className="shrink-0 text-indigo-400" />
+                  <Folder size={28} className="shrink-0 text-accent-400" />
                   <div className="min-w-0 flex-1">
                     <p className="truncate text-sm font-medium text-gray-200">
                       {folder.title}
@@ -915,12 +943,11 @@ export default function LibraryView({ onBrowseCreator }: LibraryViewProps) {
                 selected={selectedIds.has(wallpaper.id)}
                 isDetailOpen={detailId === wallpaper.id}
                 lweInstalled={lweInstalled}
-                isLiked={votedSet.has(wallpaper.id)}
-                voteError={failedVotes[wallpaper.id]}
-                showVoteBorder={voteBordersEnabled}
+                steam={steamStateOf(wallpaper.id)}
+                borders={cardBorders}
                 currentPlaylistId={currentPlaylistId}
-                isInCurrentPlaylist={currentPlaylistItemIds.has(wallpaper.id)}
                 previewSize={previewSize}
+                isInCurrentPlaylist={currentPlaylistItemIds.has(wallpaper.id)}
                 backupProgress={backupProgress.get(wallpaper.id) ?? null}
                 onSelect={(e) => handleCardSelect(wallpaper.id, e)}
                 onContextMenu={(e) => openWallpaperCtxMenu(e, wallpaper.id)}

+ 18 - 19
src/renderer/src/components/library/WallpaperCard.tsx

@@ -2,6 +2,8 @@ import { useState, useEffect } from 'react'
 import { useQueryClient } from '@tanstack/react-query'
 import { Loader2, Check, X, Trash2, Download, Archive, AlertTriangle, RotateCw, Plus, FolderOpen, WifiOff } from 'lucide-react'
 import type { BackupProgressEvent, WallpaperMeta } from '@shared/types'
+import type { CardBorders } from '@shared/cardBorders'
+import type { CardSteamState } from '../../hooks/useCardBorders'
 import clsx from 'clsx'
 import CompatBadge from '../common/CompatBadge'
 import { getPreviewSrc } from '../../utils/preview'
@@ -25,9 +27,8 @@ interface WallpaperCardProps {
   selected: boolean
   isDetailOpen: boolean
   lweInstalled: boolean
-  isLiked: boolean
-  voteError?: string
-  showVoteBorder: boolean
+  steam: CardSteamState
+  borders: CardBorders
   currentPlaylistId: string | null
   isInCurrentPlaylist: boolean
   previewSize: PreviewSize
@@ -41,9 +42,8 @@ export default function WallpaperCard({
   selected,
   isDetailOpen,
   lweInstalled,
-  isLiked,
-  voteError,
-  showVoteBorder,
+  steam,
+  borders,
   currentPlaylistId,
   isInCurrentPlaylist,
   previewSize,
@@ -163,9 +163,8 @@ export default function WallpaperCard({
       data-wallpaper-id={wallpaper.id}
       selected={selected}
       isDetailOpen={isDetailOpen}
-      isLiked={isLiked}
-      voteError={voteError}
-      showVoteBorder={showVoteBorder}
+      steam={steam}
+      borders={borders}
       draggable
       onDragStart={(e) => {
         e.dataTransfer.setData('text/wallpaper-id', wallpaper.id)
@@ -178,12 +177,12 @@ export default function WallpaperCard({
       <CardPreview src={previewSrc} alt={wallpaper.title}>
         {wallpaper.downloading && (
           <CardOverlay>
-            <Download size={20} className="text-indigo-400 animate-bounce" />
+            <Download size={20} className="text-accent-400 animate-bounce" />
             <span className="text-xs text-gray-300">
               {downloadPercentage != null ? `Downloading... ${downloadPercentage}%` : 'Downloading...'}
             </span>
             {downloadPercentage != null && (
-              <ProgressBar percentage={downloadPercentage} className="h-1 w-full max-w-[140px] rounded-full bg-white/10" />
+              <ProgressBar percentage={downloadPercentage} className="h-1 w-full max-w-[140px] rounded-full bg-fg/10" />
             )}
           </CardOverlay>
         )}
@@ -194,7 +193,7 @@ export default function WallpaperCard({
             <button
               onClick={handleRedownload}
               disabled={isRedownloading}
-              className="flex items-center gap-1 rounded bg-indigo-600/80 px-2 py-1 text-xs text-white transition-colors hover:bg-indigo-600 disabled:cursor-not-allowed disabled:opacity-50"
+              className="flex items-center gap-1 rounded bg-accent-600/80 px-2 py-1 text-xs text-white transition-colors hover:bg-accent-600 disabled:cursor-not-allowed disabled:opacity-50"
             >
               {isRedownloading ? <Loader2 size={11} className="animate-spin" /> : <RotateCw size={11} />}
               Redownload
@@ -203,13 +202,13 @@ export default function WallpaperCard({
         )}
         {backupProgress != null && (
           <CardOverlay>
-            <Archive size={20} className="text-indigo-400 animate-pulse" />
+            <Archive size={20} className="text-accent-400 animate-pulse" />
             <span className="text-xs text-gray-300">
               {backupProgress.status === 'verifying'
                 ? `Verifying... ${backupProgress.percentage}%`
                 : `${progressVerb([backupProgress])}... ${backupProgress.percentage}%`}
             </span>
-            <ProgressBar percentage={backupProgress.percentage} className="h-1 w-full max-w-[140px] rounded-full bg-white/10" />
+            <ProgressBar percentage={backupProgress.percentage} className="h-1 w-full max-w-[140px] rounded-full bg-fg/10" />
           </CardOverlay>
         )}
         {wallpaper.hdr && (
@@ -225,7 +224,7 @@ export default function WallpaperCard({
           </span>
         )}
         {backupProgress == null && hasBackup(wallpaper) && (
-          <CornerBadge className="bottom-2 right-2 bg-black/60 text-indigo-300" title="Backed up locally">
+          <CornerBadge className="bottom-2 right-2 bg-black/60 text-accent-300" title="Backed up locally">
             <Archive size={12} />
           </CornerBadge>
         )}
@@ -250,7 +249,7 @@ export default function WallpaperCard({
         {wallpaper.tags.length > 0 && (
           <div className="mt-1 flex flex-wrap gap-1">
             {wallpaper.tags.slice(0, 3).map((tag) => (
-              <span key={tag} className="rounded bg-white/5 px-1.5 py-0.5 text-xs text-gray-400">
+              <span key={tag} className="rounded bg-fg/5 px-1.5 py-0.5 text-xs text-gray-400">
                 {tag}
               </span>
             ))}
@@ -267,14 +266,14 @@ export default function WallpaperCard({
             onChange={(e) => setFpsInput(e.target.value)}
             onBlur={handleFpsBlur}
             onKeyDown={(e) => { if (e.key === 'Enter') { e.currentTarget.blur() } }}
-            className="w-16 rounded bg-white/5 px-1.5 py-0.5 text-xs text-gray-300 outline-none focus:ring-1 focus:ring-indigo-500 [appearance:textfield] [&::-webkit-outer-spin-button]:appearance-none [&::-webkit-inner-spin-button]:appearance-none"
+            className="w-16 rounded bg-fg/5 px-1.5 py-0.5 text-xs text-gray-300 outline-none focus:ring-1 focus:ring-accent-500 [appearance:textfield] [&::-webkit-outer-spin-button]:appearance-none [&::-webkit-inner-spin-button]:appearance-none"
           />
         </div>
         {error && <p className="mt-1 text-xs text-red-400">{error}</p>}
         <div className={clsx('mt-2 flex items-center', compact ? 'gap-1' : 'gap-2')}>
           <LikeAction
             id={wallpaper.id}
-            isLiked={isLiked}
+            isLiked={steam.isLiked}
             unavailable={wallpaper.unavailable}
             compact={compact}
             onError={setError}
@@ -308,7 +307,7 @@ export default function WallpaperCard({
               <button
                 onClick={(e) => { e.stopPropagation(); setUnsubState('idle') }}
                 title="Cancel"
-                className={clsx('rounded bg-white/5 text-xs text-gray-400 hover:bg-white/10', compact ? 'p-1.5' : 'px-2 py-1')}
+                className={clsx('rounded bg-fg/5 text-xs text-gray-400 hover:bg-fg/10', compact ? 'p-1.5' : 'px-2 py-1')}
               >
                 {compact ? <X size={11} /> : 'No'}
               </button>

+ 7 - 7
src/renderer/src/components/playlist/PlaylistItemRow.tsx

@@ -59,7 +59,7 @@ export default function PlaylistItemRow({
       onContextMenu={onContextMenu}
       className={clsx(
         'rounded-lg border transition-colors',
-        isCurrent ? 'border-indigo-500/60 bg-indigo-500/10' : 'border-white/5 bg-[#1a1a1a]'
+        isCurrent ? 'border-accent-500/60 bg-accent-500/10' : 'border-fg/5 bg-card'
       )}
     >
       <div className="flex items-center gap-2 p-2">
@@ -68,7 +68,7 @@ export default function PlaylistItemRow({
         <button
           onClick={onPlay}
           title={isCurrent && isPlaying ? 'Now playing' : 'Play this wallpaper'}
-          className="group relative h-10 w-16 shrink-0 overflow-hidden rounded bg-[#111]"
+          className="group relative h-10 w-16 shrink-0 overflow-hidden rounded bg-sunken"
         >
           {previewSrc && (
             <img src={previewSrc} alt="" className="h-full w-full object-cover" loading="lazy" />
@@ -92,7 +92,7 @@ export default function PlaylistItemRow({
           title="View details"
           className="min-w-0 flex-1 text-left"
         >
-          <p className="truncate text-sm text-gray-200 hover:text-white" title={wallpaper?.title}>
+          <p className="truncate text-sm text-gray-200 hover:text-fg" title={wallpaper?.title}>
             {wallpaper?.title ?? item.wallpaperId}
           </p>
           <p className="text-xs text-gray-600">
@@ -102,7 +102,7 @@ export default function PlaylistItemRow({
         <button
           onClick={() => setExpanded((v) => !v)}
           title="Per-wallpaper overrides"
-          className="rounded p-1.5 text-gray-500 hover:bg-white/5 hover:text-gray-300"
+          className="rounded p-1.5 text-gray-500 hover:bg-fg/5 hover:text-gray-300"
         >
           {expanded ? <ChevronUp size={14} /> : <ChevronDown size={14} />}
         </button>
@@ -116,7 +116,7 @@ export default function PlaylistItemRow({
       </div>
 
       {expanded && (
-        <div className="flex flex-wrap items-center gap-4 border-t border-white/5 px-3 py-2">
+        <div className="flex flex-wrap items-center gap-4 border-t border-fg/5 px-3 py-2">
           <label className="flex items-center gap-2 text-xs text-gray-400">
             <Volume2 size={12} />
             Volume
@@ -126,7 +126,7 @@ export default function PlaylistItemRow({
               max={100}
               value={item.volume ?? defaultVolume}
               onChange={(e) => onUpdate({ volume: Number(e.target.value) })}
-              className="w-24 accent-indigo-500"
+              className="w-24 accent-accent-500"
             />
             <span className="w-8 text-gray-300">{item.volume ?? defaultVolume}</span>
             {item.volume !== undefined && (
@@ -150,7 +150,7 @@ export default function PlaylistItemRow({
                 const v = e.target.value.trim()
                 onUpdate({ durationSec: v === '' ? undefined : Number(v) })
               }}
-              className="w-20 rounded bg-white/5 px-2 py-1 text-gray-200 outline-none focus:ring-1 focus:ring-indigo-500"
+              className="w-20 rounded bg-fg/5 px-2 py-1 text-gray-200 outline-none focus:ring-1 focus:ring-accent-500"
             />
           </label>
         </div>

+ 17 - 42
src/renderer/src/components/playlist/PlaylistsView.tsx

@@ -1,4 +1,5 @@
 import { useMemo, useState } from 'react'
+import Toggle from '../common/Toggle'
 import { useQueryClient } from '@tanstack/react-query'
 import {
   ListVideo,
@@ -208,7 +209,7 @@ export default function PlaylistsView({ onBrowseCreator }: PlaylistsViewProps) {
 
   return (
     <div className="flex h-full">
-      <div className="flex w-56 shrink-0 flex-col border-r border-white/5 overflow-y-auto">
+      <div className="flex w-56 shrink-0 flex-col border-r border-fg/5 overflow-y-auto">
         <div className="flex items-center justify-between px-3 pt-3 pb-1">
           <span className="text-[10px] font-semibold uppercase tracking-wide text-gray-600">
             Playlists
@@ -256,15 +257,15 @@ export default function PlaylistsView({ onBrowseCreator }: PlaylistsViewProps) {
             className={clsx(
               'group flex items-center gap-2 px-3 py-2 text-sm',
               activePlaylistId === p.id
-                ? 'bg-white/5 text-white'
-                : 'text-gray-400 hover:bg-white/5 hover:text-gray-200'
+                ? 'bg-fg/5 text-fg'
+                : 'text-gray-400 hover:bg-fg/5 hover:text-gray-200'
             )}
           >
             <ListVideo
               size={14}
               className={clsx(
                 'shrink-0',
-                playbackStates.some((s) => s.playlistId === p.id) ? 'text-indigo-400' : 'text-gray-600'
+                playbackStates.some((s) => s.playlistId === p.id) ? 'text-accent-400' : 'text-gray-600'
               )}
             />
             {renamingId === p.id ? (
@@ -315,7 +316,7 @@ export default function PlaylistsView({ onBrowseCreator }: PlaylistsViewProps) {
           </div>
         ) : (
           <>
-            <div className="border-b border-white/5 px-4 py-3">
+            <div className="border-b border-fg/5 px-4 py-3">
               <div className="flex items-center justify-between">
                 <h2 className="text-lg font-semibold text-gray-100">{activePlaylist.title}</h2>
                 <div className="flex items-center gap-2">
@@ -327,28 +328,28 @@ export default function PlaylistsView({ onBrowseCreator }: PlaylistsViewProps) {
                       <button
                         onClick={handlePrevious}
                         title="Previous"
-                        className="rounded-lg bg-white/5 p-2 text-gray-300 hover:bg-white/10"
+                        className="rounded-lg bg-fg/5 p-2 text-gray-300 hover:bg-fg/10"
                       >
                         <SkipBack size={14} />
                       </button>
                       <button
                         onClick={handlePauseResume}
                         title={isPlaying ? 'Pause' : 'Resume'}
-                        className="rounded-lg bg-indigo-600 p-2 text-white hover:bg-indigo-500"
+                        className="rounded-lg bg-accent-600 p-2 text-white hover:bg-accent-500"
                       >
                         {isPlaying ? <Pause size={14} /> : <Play size={14} />}
                       </button>
                       <button
                         onClick={handleNext}
                         title="Next"
-                        className="rounded-lg bg-white/5 p-2 text-gray-300 hover:bg-white/10"
+                        className="rounded-lg bg-fg/5 p-2 text-gray-300 hover:bg-fg/10"
                       >
                         <SkipForward size={14} />
                       </button>
                       <button
                         onClick={handleStop}
                         title="Stop"
-                        className="rounded-lg bg-white/5 p-2 text-gray-300 hover:bg-red-500/20 hover:text-red-400"
+                        className="rounded-lg bg-fg/5 p-2 text-gray-300 hover:bg-red-500/20 hover:text-red-400"
                       >
                         <Square size={14} />
                       </button>
@@ -357,7 +358,7 @@ export default function PlaylistsView({ onBrowseCreator }: PlaylistsViewProps) {
                     <button
                       onClick={handlePlay}
                       disabled={activePlaylist.items.length === 0}
-                      className="flex items-center gap-2 rounded-lg bg-indigo-600 px-4 py-2 text-sm font-medium text-white hover:bg-indigo-500 disabled:opacity-50"
+                      className="flex items-center gap-2 rounded-lg bg-accent-600 px-4 py-2 text-sm font-medium text-white hover:bg-accent-500 disabled:opacity-50"
                     >
                       <Play size={14} />
                       Play playlist
@@ -374,20 +375,7 @@ export default function PlaylistsView({ onBrowseCreator }: PlaylistsViewProps) {
 
               <div className="mt-3 flex flex-wrap items-center gap-4">
                 <label className="flex items-center gap-2 text-xs text-gray-400">
-                  <button
-                    onClick={() => updateSettings({ randomize: !activePlaylist.settings.randomize })}
-                    className={clsx(
-                      'relative inline-flex h-5 w-9 shrink-0 items-center rounded-full transition-colors',
-                      activePlaylist.settings.randomize ? 'bg-indigo-600' : 'bg-white/10'
-                    )}
-                  >
-                    <span
-                      className={clsx(
-                        'inline-block h-3.5 w-3.5 rounded-full bg-white transition-transform',
-                        activePlaylist.settings.randomize ? 'translate-x-4' : 'translate-x-0.5'
-                      )}
-                    />
-                  </button>
+                  <Toggle on={activePlaylist.settings.randomize} onClick={() => updateSettings({ randomize: !activePlaylist.settings.randomize })} />
                   <Shuffle size={12} />
                   Randomize
                 </label>
@@ -401,7 +389,7 @@ export default function PlaylistsView({ onBrowseCreator }: PlaylistsViewProps) {
                       onChange={(e) =>
                         updateSettings({ sortBy: e.target.value as PlaylistSettings['sortBy'] })
                       }
-                      className="rounded bg-white/5 px-2 py-1 text-gray-200 outline-none focus:ring-1 focus:ring-indigo-500"
+                      className="rounded bg-fg/5 px-2 py-1 text-gray-200 outline-none focus:ring-1 focus:ring-accent-500"
                     >
                       {SORT_OPTIONS.map((o) => (
                         <option key={o.value} value={o.value}>
@@ -421,7 +409,7 @@ export default function PlaylistsView({ onBrowseCreator }: PlaylistsViewProps) {
                     onChange={(e) =>
                       updateSettings({ defaultDurationSec: Math.max(1, Number(e.target.value)) })
                     }
-                    className="w-20 rounded bg-white/5 px-2 py-1 text-gray-200 outline-none focus:ring-1 focus:ring-indigo-500"
+                    className="w-20 rounded bg-fg/5 px-2 py-1 text-gray-200 outline-none focus:ring-1 focus:ring-accent-500"
                   />
                   sec
                 </label>
@@ -430,20 +418,7 @@ export default function PlaylistsView({ onBrowseCreator }: PlaylistsViewProps) {
                   className="flex items-center gap-2 text-xs text-gray-400"
                   title="Videos longer than the duration play to the end once before switching. Shorter videos loop until the duration is up."
                 >
-                  <button
-                    onClick={() => updateSettings({ finishVideos: !activePlaylist.settings.finishVideos })}
-                    className={clsx(
-                      'relative inline-flex h-5 w-9 shrink-0 items-center rounded-full transition-colors',
-                      activePlaylist.settings.finishVideos ? 'bg-indigo-600' : 'bg-white/10'
-                    )}
-                  >
-                    <span
-                      className={clsx(
-                        'inline-block h-3.5 w-3.5 rounded-full bg-white transition-transform',
-                        activePlaylist.settings.finishVideos ? 'translate-x-4' : 'translate-x-0.5'
-                      )}
-                    />
-                  </button>
+                  <Toggle on={!!activePlaylist.settings.finishVideos} onClick={() => updateSettings({ finishVideos: !activePlaylist.settings.finishVideos })} />
                   <Film size={12} />
                   Finish videos
                 </label>
@@ -456,7 +431,7 @@ export default function PlaylistsView({ onBrowseCreator }: PlaylistsViewProps) {
                     max={100}
                     value={activePlaylist.settings.defaultVolume}
                     onChange={(e) => updateSettings({ defaultVolume: Number(e.target.value) })}
-                    className="w-24 accent-indigo-500"
+                    className="w-24 accent-accent-500"
                   />
                   <span className="w-8 text-gray-300">{activePlaylist.settings.defaultVolume}</span>
                 </label>
@@ -470,7 +445,7 @@ export default function PlaylistsView({ onBrowseCreator }: PlaylistsViewProps) {
               </span>
               <button
                 onClick={() => setPickerOpen(true)}
-                className="flex items-center gap-2 rounded-lg bg-white/5 px-3 py-1.5 text-xs text-gray-300 hover:bg-white/10"
+                className="flex items-center gap-2 rounded-lg bg-fg/5 px-3 py-1.5 text-xs text-gray-300 hover:bg-fg/10"
               >
                 <Plus size={12} />
                 Add wallpapers

+ 14 - 17
src/renderer/src/components/playlist/WallpaperPickerModal.tsx

@@ -2,6 +2,7 @@ import { useMemo, useState } from 'react'
 import { useQuery } from '@tanstack/react-query'
 import { Search, X, Plus, Check } from 'lucide-react'
 import { getPreviewSrc } from '../../utils/preview'
+import PreviewImage from '../common/PreviewImage'
 
 interface WallpaperPickerModalProps {
   excludeIds: Set<string>
@@ -49,18 +50,18 @@ export default function WallpaperPickerModal({
 
   return (
     <div className="fixed inset-0 z-50 flex items-center justify-center bg-black/60 p-8">
-      <div className="flex h-full max-h-[600px] w-full max-w-2xl flex-col rounded-xl border border-white/10 bg-[#161616] shadow-2xl">
-        <div className="flex items-center justify-between border-b border-white/5 px-4 py-3">
+      <div className="flex h-full max-h-[600px] w-full max-w-2xl flex-col rounded-xl border border-fg/10 bg-popup shadow-2xl">
+        <div className="flex items-center justify-between border-b border-fg/5 px-4 py-3">
           <h3 className="text-sm font-semibold text-gray-100">Add wallpapers to playlist</h3>
           <button
             onClick={onClose}
-            className="rounded p-1 text-gray-500 hover:bg-white/5 hover:text-gray-300"
+            className="rounded p-1 text-gray-500 hover:bg-fg/5 hover:text-gray-300"
           >
             <X size={16} />
           </button>
         </div>
 
-        <div className="border-b border-white/5 px-4 py-2">
+        <div className="border-b border-fg/5 px-4 py-2">
           <div className="relative">
             <Search size={14} className="absolute left-2.5 top-1/2 -translate-y-1/2 text-gray-500" />
             <input
@@ -69,7 +70,7 @@ export default function WallpaperPickerModal({
               placeholder="Search library..."
               value={search}
               onChange={(e) => setSearch(e.target.value)}
-              className="w-full rounded-lg bg-white/5 py-1.5 pl-8 pr-3 text-sm text-gray-200 placeholder-gray-500 outline-none focus:ring-1 focus:ring-indigo-500"
+              className="w-full rounded-lg bg-fg/5 py-1.5 pl-8 pr-3 text-sm text-gray-200 placeholder-gray-500 outline-none focus:ring-1 focus:ring-accent-500"
             />
           </div>
         </div>
@@ -87,18 +88,14 @@ export default function WallpaperPickerModal({
                 <button
                   key={w.id}
                   onClick={() => toggle(w.id)}
-                  className={`group relative overflow-hidden rounded-lg bg-[#1f1f1f] text-left transition-all ${
-                    isSelected ? 'ring-2 ring-indigo-500' : 'hover:ring-1 hover:ring-indigo-500/50'
+                  data-preview-hover=""
+                  className={`group relative overflow-hidden rounded-xl bg-card text-left transition-all ${
+                    isSelected ? 'ring-2 ring-accent-500' : 'hover:ring-1 hover:ring-accent-500/50'
                   }`}
                 >
-                  <div className="aspect-video bg-[#111]">
+                  <div className="aspect-video bg-sunken">
                     {previewSrc ? (
-                      <img
-                        src={previewSrc}
-                        alt={w.title}
-                        className="h-full w-full object-cover"
-                        loading="lazy"
-                      />
+                      <PreviewImage src={previewSrc} alt={w.title} />
                     ) : (
                       <div className="flex h-full items-center justify-center text-xs text-gray-600">
                         No preview
@@ -109,7 +106,7 @@ export default function WallpaperPickerModal({
                     <span className="truncate text-xs text-gray-300" title={w.title}>
                       {w.title}
                     </span>
-                    {isSelected && <Check size={12} className="shrink-0 text-indigo-400" />}
+                    {isSelected && <Check size={12} className="shrink-0 text-accent-400" />}
                   </div>
                 </button>
               )
@@ -117,12 +114,12 @@ export default function WallpaperPickerModal({
           </div>
         </div>
 
-        <div className="flex items-center justify-between border-t border-white/5 px-4 py-3">
+        <div className="flex items-center justify-between border-t border-fg/5 px-4 py-3">
           <span className="text-xs text-gray-500">{selected.size} selected</span>
           <button
             onClick={handleAdd}
             disabled={selected.size === 0}
-            className="flex items-center gap-2 rounded-lg bg-indigo-600 px-4 py-2 text-sm font-medium text-white hover:bg-indigo-500 disabled:opacity-50"
+            className="flex items-center gap-2 rounded-lg bg-accent-600 px-4 py-2 text-sm font-medium text-white hover:bg-accent-500 disabled:opacity-50"
           >
             <Plus size={14} />
             Add to playlist

+ 191 - 0
src/renderer/src/components/settings/AppearanceSettings.tsx

@@ -0,0 +1,191 @@
+import { useState } from 'react'
+import { useQueryClient } from '@tanstack/react-query'
+import { Check, Monitor, Moon, MousePointer2, Play, RotateCcw, Sun } from 'lucide-react'
+import clsx from 'clsx'
+import {
+  ACCENT_PRESETS,
+  MIN_WINDOW_OPACITY,
+  type Appearance,
+  type PreviewAnimation,
+  type ThemeMode
+} from '@shared/appearance'
+import Toggle from '../common/Toggle'
+import { useConfig } from '../../hooks/queries'
+import { applyAppearance } from '../../utils/appearance'
+
+const THEMES: { value: ThemeMode; label: string; icon: typeof Moon }[] = [
+  { value: 'dark', label: 'Dark', icon: Moon },
+  { value: 'light', label: 'Light', icon: Sun },
+  { value: 'system', label: 'System', icon: Monitor }
+]
+
+const PREVIEW_ANIMATION: { value: PreviewAnimation; label: string; icon: typeof Moon }[] = [
+  { value: 'always', label: 'Always', icon: Play },
+  { value: 'hover', label: 'On hover', icon: MousePointer2 }
+]
+
+function Segmented<T extends string>({
+  options,
+  value,
+  onChange
+}: {
+  options: { value: T; label: string; icon: typeof Moon }[]
+  value: T
+  onChange: (value: T) => void
+}) {
+  return (
+    <div className="inline-flex rounded-xl bg-fg/5 p-1 ring-1 ring-fg/5">
+      {options.map(({ value: option, label, icon: Icon }) => (
+        <button
+          key={option}
+          onClick={() => onChange(option)}
+          className={clsx(
+            'flex items-center gap-1.5 rounded-lg px-3 py-1.5 text-sm transition-all',
+            value === option ? 'bg-card text-gray-100 shadow-sm ring-1 ring-fg/10' : 'text-gray-400 hover:text-gray-200'
+          )}
+        >
+          <Icon size={14} />
+          {label}
+        </button>
+      ))}
+    </div>
+  )
+}
+
+function swatch(hue: number, chroma: number): string {
+  return `oklch(58.5% ${0.233 * chroma} ${hue})`
+}
+
+export default function AppearanceSettings() {
+  const queryClient = useQueryClient()
+  const config = useConfig()
+  const [edited, setDraft] = useState<Appearance | null>(null)
+
+  if (!config) return null
+  const draft = edited ?? config.appearance
+
+  // save on release
+  function preview(patch: Partial<Appearance>) {
+    const next = { ...draft, ...patch }
+    setDraft(next)
+    applyAppearance(next, config!.windowTranslucent)
+  }
+
+  async function save(patch: Partial<Appearance>) {
+    const next = { ...draft, ...patch }
+    setDraft(next)
+    applyAppearance(next, config!.windowTranslucent)
+    await window.electronAPI.config.setAppearance(next)
+    queryClient.invalidateQueries({ queryKey: ['config'] })
+  }
+
+  const isKde = config.desktopEnv === 'kde'
+  const translucent = draft.windowOpacity < 100
+  const presetMatch = ACCENT_PRESETS.find((p) => p.hue === draft.accentHue && p.chroma === draft.accentChroma)
+
+  return (
+    <div>
+      <label className="block text-xs font-medium uppercase tracking-wide text-gray-500">Appearance</label>
+
+      <div className="mt-3">
+        <Segmented options={THEMES} value={draft.theme} onChange={(theme) => save({ theme })} />
+      </div>
+
+      <div className="mt-5">
+        <span className="block text-xs text-gray-400">Accent color</span>
+        <div className="mt-2 flex flex-wrap gap-2">
+          {ACCENT_PRESETS.map((p) => {
+            const active = presetMatch === p
+            return (
+              <button
+                key={p.name}
+                title={p.name}
+                onClick={() => save({ accentHue: p.hue, accentChroma: p.chroma })}
+                className={clsx(
+                  'flex h-7 w-7 items-center justify-center rounded-full text-white ring-offset-2 ring-offset-app transition-transform hover:scale-110',
+                  active && 'ring-2 ring-fg/60'
+                )}
+                style={{ background: swatch(p.hue, p.chroma) }}
+              >
+                {active && <Check size={14} />}
+              </button>
+            )
+          })}
+        </div>
+        <div className="mt-3 flex items-center gap-3">
+          <span className="w-16 shrink-0 text-xs text-gray-500">Custom</span>
+          <input
+            type="range"
+            min={0}
+            max={360}
+            value={draft.accentHue}
+            onChange={(e) => preview({ accentHue: Number(e.target.value), accentChroma: draft.accentChroma || 1 })}
+            onPointerUp={() => save({})}
+            onKeyUp={() => save({})}
+            className="hue-slider h-2 w-full cursor-pointer appearance-none rounded-full"
+            aria-label="Accent hue"
+          />
+        </div>
+      </div>
+
+      <div className="mt-5">
+        <span className="block text-xs text-gray-400">Animated previews</span>
+        <div className="mt-2">
+          <Segmented
+            options={PREVIEW_ANIMATION}
+            value={draft.previewAnimation}
+            onChange={(previewAnimation) => save({ previewAnimation })}
+          />
+        </div>
+        <p className="mt-1 text-xs text-gray-600">
+          On hover, GIF previews show a still frame and only play while the pointer rests on their card, instead of
+          every card in view animating at once.
+        </p>
+      </div>
+
+      <div className="mt-5">
+        <div className="flex items-center justify-between">
+          <span className="text-xs text-gray-400">Window opacity</span>
+          <span className="text-xs tabular-nums text-gray-500">{draft.windowOpacity}%</span>
+        </div>
+        <input
+          type="range"
+          min={MIN_WINDOW_OPACITY}
+          max={100}
+          value={draft.windowOpacity}
+          onChange={(e) => preview({ windowOpacity: Number(e.target.value) })}
+          onPointerUp={() => save({})}
+          onKeyUp={() => save({})}
+          className="mt-2 w-full accent-accent-500"
+          aria-label="Window opacity"
+        />
+        <p className="mt-1 text-xs text-gray-600">
+          Below 100% the desktop shows through the window background. Turning it on or off applies the next time WE
+          Manager starts.
+        </p>
+      </div>
+
+      <label className={clsx('mt-4 flex items-center gap-3', isKde && translucent ? 'cursor-pointer' : 'cursor-default')}>
+        <Toggle
+          on={draft.blur && isKde}
+          onClick={() => save({ blur: !draft.blur })}
+          disabled={!isKde || !translucent}
+        />
+        <span className="text-sm text-gray-300">Blur behind the window</span>
+      </label>
+      <p className="mt-1 text-xs text-gray-600">
+        {isKde
+          ? 'KDE Plasma blurs the desktop behind the translucent window. KWin only does this for X11 windows, so on a Wayland session WE Manager runs through XWayland while blur is on.'
+          : 'Only available on KDE Plasma.'}
+      </p>
+
+      {config.appearanceRestartNeeded && (
+        <p className="mt-3 flex items-center gap-2 rounded-lg bg-amber-600/15 px-3 py-2 text-xs text-amber-300 ring-1 ring-amber-500/30">
+          <RotateCcw size={13} className="shrink-0" />
+          Quit WE Manager and start it again to apply the window changes
+          {config.trayEnabled ? ' (Quit from the tray menu, closing the window only hides it)' : ''}.
+        </p>
+      )}
+    </div>
+  )
+}

+ 96 - 0
src/renderer/src/components/settings/CardBorderSettings.tsx

@@ -0,0 +1,96 @@
+import { useEffect, useRef, useState } from 'react'
+import { useQueryClient } from '@tanstack/react-query'
+import { AlertTriangle, Heart, RotateCcw, ThumbsDown, ThumbsUp, type LucideIcon } from 'lucide-react'
+import { CARD_BORDER_KINDS, DEFAULT_CARD_BORDERS, type CardBorderKind, type CardBorders } from '@shared/cardBorders'
+import Toggle from '../common/Toggle'
+import { useCardBorders } from '../../hooks/useCardBorders'
+
+const ROWS: Record<CardBorderKind, { label: string; hint: string; icon: LucideIcon }> = {
+  liked: { label: 'Liked', hint: 'Wallpapers you liked on Steam', icon: ThumbsUp },
+  disliked: { label: 'Disliked', hint: 'Wallpapers you disliked on Steam', icon: ThumbsDown },
+  favorite: { label: 'Favorite', hint: 'Wallpapers in your Steam favorites', icon: Heart },
+  failed: {
+    label: 'Failed',
+    hint: 'Dashed, where a like, dislike or favorite still failed after retrying (hover the card for the reason, try again from the right-click menu). Kept until the app restarts.',
+    icon: AlertTriangle
+  }
+}
+
+const SAVE_DELAY_MS = 250
+
+export default function CardBorderSettings() {
+  const queryClient = useQueryClient()
+  const saved = useCardBorders()
+  // color pickers fire on every move, save once they settle
+  const [draft, setDraft] = useState<CardBorders | null>(null)
+  const saveTimer = useRef<ReturnType<typeof setTimeout> | null>(null)
+  const borders = draft ?? saved
+
+  useEffect(() => () => {
+    if (saveTimer.current) clearTimeout(saveTimer.current)
+  }, [])
+
+  function change(kind: CardBorderKind, patch: Partial<CardBorders[CardBorderKind]>) {
+    const next = { ...borders, [kind]: { ...borders[kind], ...patch } }
+    setDraft(next)
+    queryClient.setQueryData(['config'], (old: object | undefined) => (old ? { ...old, cardBorders: next } : old))
+    if (saveTimer.current) clearTimeout(saveTimer.current)
+    saveTimer.current = setTimeout(async () => {
+      await window.electronAPI.config.setCardBorders(next)
+      setDraft(null)
+      queryClient.invalidateQueries({ queryKey: ['config'] })
+    }, SAVE_DELAY_MS)
+  }
+
+  return (
+    <div>
+      <label className="block text-xs font-medium uppercase tracking-wide text-gray-500">Card borders</label>
+      <p className="mt-1 text-xs text-gray-600">
+        Outlines around wallpaper cards. A card can show two: like or dislike on the inside, favorite around it.
+      </p>
+      <div className="mt-3 space-y-3">
+        {CARD_BORDER_KINDS.map((kind) => {
+          const { label, hint, icon: Icon } = ROWS[kind]
+          const border = borders[kind]
+          const isDefaultColor = border.color === DEFAULT_CARD_BORDERS[kind].color
+          return (
+            <div key={kind} className="flex items-start gap-3">
+              <Toggle on={border.enabled} onClick={() => change(kind, { enabled: !border.enabled })} />
+              <div className="min-w-0 flex-1">
+                <span className="flex items-center gap-2 text-sm text-gray-300">
+                  <Icon size={14} />
+                  {label}
+                </span>
+                <p className="mt-0.5 text-xs text-gray-600">{hint}</p>
+              </div>
+              <div className="flex items-center gap-1.5">
+                {!isDefaultColor && (
+                  <button
+                    onClick={() => change(kind, { color: DEFAULT_CARD_BORDERS[kind].color })}
+                    title="Reset to the default color"
+                    className="rounded p-1 text-gray-500 hover:bg-fg/10 hover:text-gray-300"
+                  >
+                    <RotateCcw size={12} />
+                  </button>
+                )}
+                <label
+                  title={`${label} border color`}
+                  className="relative h-6 w-10 cursor-pointer overflow-hidden rounded-md ring-1 ring-fg/15"
+                  style={{ background: border.color, opacity: border.enabled ? 1 : 0.4 }}
+                >
+                  <input
+                    type="color"
+                    value={border.color}
+                    onChange={(e) => change(kind, { color: e.target.value })}
+                    className="absolute inset-0 cursor-pointer opacity-0"
+                    aria-label={`${label} border color`}
+                  />
+                </label>
+              </div>
+            </div>
+          )
+        })}
+      </div>
+    </div>
+  )
+}

+ 1 - 1
src/renderer/src/components/settings/DisplaySettings.tsx

@@ -42,7 +42,7 @@ export default function DisplaySettings({ screens }: { screens: string[] }) {
             onClick={() => switchTo(mode)}
             disabled={switching}
             className={`flex items-center gap-2 px-3 py-2 transition-colors ${
-              current === mode ? 'bg-indigo-600 text-white' : 'bg-white/5 text-gray-400 hover:text-gray-200'
+              current === mode ? 'bg-accent-600 text-white' : 'bg-fg/5 text-gray-400 hover:text-gray-200'
             }`}
           >
             {switching && current !== mode ? <Loader2 size={14} className="animate-spin" /> : <Icon size={14} />}

+ 4 - 4
src/renderer/src/components/settings/LibraryFoldersSettings.tsx

@@ -68,7 +68,7 @@ export default function LibraryFoldersSettings() {
       {libraries.length > 0 && (
         <ul className="mt-2 space-y-1">
           {libraries.map((l) => (
-            <li key={l.path} className="flex items-center gap-2 rounded-lg bg-white/5 px-3 py-2 text-sm text-gray-200">
+            <li key={l.path} className="flex items-center gap-2 rounded-lg bg-fg/5 px-3 py-2 text-sm text-gray-200">
               <HardDrive size={14} className="shrink-0 text-gray-500" />
               <input
                 type="text"
@@ -79,7 +79,7 @@ export default function LibraryFoldersSettings() {
                   if (e.key === 'Enter') e.currentTarget.blur()
                 }}
                 title="Library name"
-                className="w-32 shrink-0 rounded bg-transparent px-1 text-gray-100 outline-none focus:bg-white/5 focus:ring-1 focus:ring-indigo-500"
+                className="w-32 shrink-0 rounded bg-transparent px-1 text-gray-100 outline-none focus:bg-fg/5 focus:ring-1 focus:ring-accent-500"
               />
               <span className="flex-1 truncate text-xs text-gray-500" title={l.path}>
                 {l.path}
@@ -88,7 +88,7 @@ export default function LibraryFoldersSettings() {
                 onClick={() => saveAndScan(libraries.filter((x) => x.path !== l.path))}
                 disabled={scanning}
                 title="Remove from the library"
-                className="rounded p-0.5 text-gray-500 hover:bg-white/10 hover:text-gray-200 disabled:opacity-50"
+                className="rounded p-0.5 text-gray-500 hover:bg-fg/10 hover:text-gray-200 disabled:opacity-50"
               >
                 <X size={14} />
               </button>
@@ -99,7 +99,7 @@ export default function LibraryFoldersSettings() {
       <button
         onClick={handleAdd}
         disabled={scanning}
-        className="mt-3 flex items-center gap-2 rounded-lg bg-white/5 px-3 py-2 text-sm text-gray-300 hover:bg-white/10 disabled:opacity-50"
+        className="mt-3 flex items-center gap-2 rounded-lg bg-fg/5 px-3 py-2 text-sm text-gray-300 hover:bg-fg/10 disabled:opacity-50"
       >
         {scanning ? <Loader2 size={16} className="animate-spin" /> : <FolderPlus size={16} />}
         {scanning ? 'Scanning...' : 'Add folder'}

+ 24 - 37
src/renderer/src/components/settings/PerformanceSettings.tsx

@@ -1,4 +1,5 @@
 import { useState } from 'react'
+import Toggle from '../common/Toggle'
 import { useQuery, useQueryClient } from '@tanstack/react-query'
 import { Check, Plus, Save, Trash2 } from 'lucide-react'
 import type { EngineFlagPreset, EngineFlags, FullscreenPauseMode } from '@shared/types'
@@ -12,23 +13,6 @@ interface Props {
   onDefaultFpsChanged: (fps: number | null) => void
 }
 
-function Toggle({ on, onClick }: { on: boolean; onClick: () => void }) {
-  return (
-    <button
-      onClick={onClick}
-      className={`relative inline-flex h-5 w-9 shrink-0 items-center rounded-full transition-colors ${
-        on ? 'bg-indigo-600' : 'bg-white/10'
-      }`}
-    >
-      <span
-        className={`inline-block h-3.5 w-3.5 rounded-full bg-white transition-transform ${
-          on ? 'translate-x-4' : 'translate-x-0.5'
-        }`}
-      />
-    </button>
-  )
-}
-
 function describePreset(preset: EngineFlagPreset): string {
   const parts = BOOLEAN_FLAGS.filter((f) => preset.flags[f.key]).map((f) => f.label.toLowerCase())
   const pause = FULLSCREEN_PAUSE_OPTIONS.find((o) => o.value === preset.flags.fullscreenPause)
@@ -157,7 +141,7 @@ export default function PerformanceSettings({ defaultFps, onDefaultFpsChanged }:
           <select
             value={flags.fullscreenPause ?? 'default'}
             onChange={(e) => saveFlags({ ...flags, fullscreenPause: e.target.value as FullscreenPauseMode })}
-            className="rounded-lg bg-white/5 px-2 py-1.5 text-sm text-gray-200 outline-none"
+            className="rounded-lg bg-fg/5 px-2 py-1.5 text-sm text-gray-200 outline-none"
           >
             {FULLSCREEN_PAUSE_OPTIONS.map((o) => (
               <option key={o.value} value={o.value}>
@@ -166,21 +150,24 @@ export default function PerformanceSettings({ defaultFps, onDefaultFpsChanged }:
             ))}
           </select>
         </label>
-        {CHOICE_FLAGS.map(({ key, label, hint, fallback, options }) => (
-          <label key={key} className="flex items-center gap-3 text-sm text-gray-300" title={hint}>
-            <span>{label}</span>
-            <select
-              value={flags[key] ?? fallback}
-              onChange={(e) => saveFlags({ ...flags, [key]: e.target.value })}
-              className="rounded-lg bg-white/5 px-2 py-1.5 text-sm text-gray-200 outline-none"
-            >
-              {options.map((o) => (
-                <option key={o.value} value={o.value}>
-                  {o.label}
-                </option>
-              ))}
-            </select>
-          </label>
+        {CHOICE_FLAGS.map(({ key, label, hint, note, fallback, options }) => (
+          <div key={key} className={note ? '-mx-3 rounded-lg bg-fg/5 px-3 py-2' : undefined}>
+            <label className="flex items-center gap-3 text-sm text-gray-300" title={hint}>
+              <span>{label}</span>
+              <select
+                value={flags[key] ?? fallback}
+                onChange={(e) => saveFlags({ ...flags, [key]: e.target.value })}
+                className="rounded-lg bg-fg/5 px-2 py-1.5 text-sm text-gray-200 outline-none"
+              >
+                {options.map((o) => (
+                  <option key={o.value} value={o.value}>
+                    {o.label}
+                  </option>
+                ))}
+              </select>
+            </label>
+            {note && <p className="mt-1.5 border-l-2 border-fg/10 pl-2 text-xs text-gray-500">{note}</p>}
+          </div>
         ))}
       </div>
 
@@ -190,14 +177,14 @@ export default function PerformanceSettings({ defaultFps, onDefaultFpsChanged }:
       </p>
       <div className="mt-2 space-y-1.5">
         {presets.map((preset) => (
-          <div key={preset.id} className="flex items-center gap-2 rounded-lg bg-white/5 px-3 py-2">
+          <div key={preset.id} className="flex items-center gap-2 rounded-lg bg-fg/5 px-3 py-2">
             <div className="min-w-0 flex-1">
               <p className="truncate text-sm text-gray-200">{preset.name}</p>
               <p className="truncate text-xs text-gray-500">{describePreset(preset)}</p>
             </div>
             <button
               onClick={() => applyPreset(preset)}
-              className="flex items-center gap-1 rounded bg-indigo-600 px-2 py-1 text-xs text-white hover:bg-indigo-500"
+              className="flex items-center gap-1 rounded bg-accent-600 px-2 py-1 text-xs text-white hover:bg-accent-500"
             >
               {appliedId === preset.id && <Check size={11} />}
               Apply
@@ -229,12 +216,12 @@ export default function PerformanceSettings({ defaultFps, onDefaultFpsChanged }:
           onChange={(e) => setNewName(e.target.value)}
           onKeyDown={(e) => e.key === 'Enter' && createPreset()}
           placeholder="New preset from the current settings"
-          className="flex-1 rounded-lg bg-white/5 px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-indigo-500"
+          className="flex-1 rounded-lg bg-fg/5 px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-accent-500"
         />
         <button
           onClick={createPreset}
           disabled={!newName.trim()}
-          className="flex items-center gap-1.5 rounded-lg bg-white/5 px-3 py-2 text-sm text-gray-300 hover:bg-white/10 disabled:opacity-50"
+          className="flex items-center gap-1.5 rounded-lg bg-fg/5 px-3 py-2 text-sm text-gray-300 hover:bg-fg/10 disabled:opacity-50"
         >
           <Plus size={14} />
           Save

+ 8 - 8
src/renderer/src/components/settings/ScheduleSettings.tsx

@@ -22,7 +22,7 @@ const EMPTY_DRAFT: Draft = {
   screen: '*'
 }
 
-const inputClass = 'rounded-lg bg-white/5 px-2 py-1.5 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-indigo-500'
+const inputClass = 'rounded-lg bg-fg/5 px-2 py-1.5 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-accent-500'
 
 function describeTrigger(trigger: ScheduleTrigger): string {
   if (trigger.type === 'theme') return trigger.theme === 'dark' ? 'When the system goes dark' : 'When the system goes light'
@@ -128,9 +128,9 @@ export default function ScheduleSettings() {
           return (
             <div
               key={rule.id}
-              className={clsx('flex items-center gap-2 rounded-lg bg-white/5 px-3 py-2', !rule.enabled && 'opacity-50')}
+              className={clsx('flex items-center gap-2 rounded-lg bg-fg/5 px-3 py-2', !rule.enabled && 'opacity-50')}
             >
-              <input type="checkbox" checked={rule.enabled} onChange={() => toggle(rule)} className="accent-indigo-500" />
+              <input type="checkbox" checked={rule.enabled} onChange={() => toggle(rule)} className="accent-accent-500" />
               <div className="min-w-0 flex-1">
                 <p className="truncate text-sm text-gray-200">{rule.name}</p>
                 <p className="truncate text-xs text-gray-500">
@@ -156,13 +156,13 @@ export default function ScheduleSettings() {
       {!draft ? (
         <button
           onClick={() => setDraft(EMPTY_DRAFT)}
-          className="mt-2 flex items-center gap-2 rounded-lg bg-white/5 px-3 py-2 text-sm text-gray-300 hover:bg-white/10"
+          className="mt-2 flex items-center gap-2 rounded-lg bg-fg/5 px-3 py-2 text-sm text-gray-300 hover:bg-fg/10"
         >
           <Plus size={14} />
           Add schedule
         </button>
       ) : (
-        <div className="mt-2 space-y-3 rounded-lg border border-white/10 p-3">
+        <div className="mt-2 space-y-3 rounded-lg border border-fg/10 p-3">
           <input
             value={draft.name}
             onChange={(e) => setDraft({ ...draft, name: e.target.value })}
@@ -211,7 +211,7 @@ export default function ScheduleSettings() {
                     }
                     className={clsx(
                       'rounded px-2 py-1 text-xs',
-                      on ? 'bg-indigo-600 text-white' : 'bg-white/5 text-gray-400 hover:text-gray-200'
+                      on ? 'bg-accent-600 text-white' : 'bg-fg/5 text-gray-400 hover:text-gray-200'
                     )}
                   >
                     {label}
@@ -284,10 +284,10 @@ export default function ScheduleSettings() {
           )}
 
           <div className="flex gap-2">
-            <button onClick={save} className="rounded-lg bg-indigo-600 px-4 py-2 text-sm font-medium text-white hover:bg-indigo-500">
+            <button onClick={save} className="rounded-lg bg-accent-600 px-4 py-2 text-sm font-medium text-white hover:bg-accent-500">
               Save
             </button>
-            <button onClick={() => setDraft(null)} className="rounded-lg bg-white/5 px-4 py-2 text-sm text-gray-300 hover:bg-white/10">
+            <button onClick={() => setDraft(null)} className="rounded-lg bg-fg/5 px-4 py-2 text-sm text-gray-300 hover:bg-fg/10">
               Cancel
             </button>
           </div>

+ 51 - 146
src/renderer/src/components/settings/SettingsView.tsx

@@ -1,10 +1,12 @@
 import { useState, useEffect } from 'react'
+import Toggle from '../common/Toggle'
 import { useQuery, useQueryClient } from '@tanstack/react-query'
 import { FolderOpen, Save, Upload, Download, CheckCircle, XCircle, Loader2, Package, Trash2, Monitor, RotateCcw, Archive, LayoutGrid, Power, Skull, Film, Globe, Shield, Bug } from 'lucide-react'
 import type { LweStatus, LwePrebuiltTarget, LweInstallProgress, LinuxDistro, SteamIdentity } from '../../../../shared/types'
 import PerformanceSettings from './PerformanceSettings'
 import DisplaySettings from './DisplaySettings'
-import VoteBorderSettings from './VoteBorderSettings'
+import CardBorderSettings from './CardBorderSettings'
+import AppearanceSettings from './AppearanceSettings'
 import LibraryFoldersSettings from './LibraryFoldersSettings'
 import ScheduleSettings from './ScheduleSettings'
 import CopyField from '../common/CopyField'
@@ -372,6 +374,8 @@ export default function SettingsView() {
       <h2 className="text-lg font-semibold text-gray-100">Settings</h2>
 
       <div className="mt-6 max-w-lg space-y-8">
+        <AppearanceSettings />
+
         <div>
           <label className="block text-xs font-medium uppercase tracking-wide text-gray-500">
             Workshop folder
@@ -387,11 +391,11 @@ export default function SettingsView() {
                 setWorkshopPath(e.target.value)
                 setSaved(false)
               }}
-              className="flex-1 rounded-lg bg-white/5 px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-indigo-500"
+              className="flex-1 rounded-lg bg-fg/5 px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-accent-500"
             />
             <button
               onClick={handleBrowse}
-              className="flex items-center gap-2 rounded-lg bg-white/5 px-3 py-2 text-sm text-gray-300 hover:bg-white/10"
+              className="flex items-center gap-2 rounded-lg bg-fg/5 px-3 py-2 text-sm text-gray-300 hover:bg-fg/10"
             >
               <FolderOpen size={16} />
               Browse
@@ -400,7 +404,7 @@ export default function SettingsView() {
           <button
             onClick={handleSave}
             disabled={!workshopPath}
-            className="mt-3 flex items-center gap-2 rounded-lg bg-indigo-600 px-4 py-2 text-sm font-medium text-white hover:bg-indigo-500 disabled:opacity-50"
+            className="mt-3 flex items-center gap-2 rounded-lg bg-accent-600 px-4 py-2 text-sm font-medium text-white hover:bg-accent-500 disabled:opacity-50"
           >
             <Save size={14} />
             {saved ? 'Saved!' : 'Save'}
@@ -427,11 +431,11 @@ export default function SettingsView() {
                 setBackupSaved(false)
               }}
               placeholder="Not configured"
-              className="flex-1 rounded-lg bg-white/5 px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-indigo-500"
+              className="flex-1 rounded-lg bg-fg/5 px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-accent-500"
             />
             <button
               onClick={handleBrowseBackup}
-              className="flex items-center gap-2 rounded-lg bg-white/5 px-3 py-2 text-sm text-gray-300 hover:bg-white/10"
+              className="flex items-center gap-2 rounded-lg bg-fg/5 px-3 py-2 text-sm text-gray-300 hover:bg-fg/10"
             >
               <FolderOpen size={16} />
               Browse
@@ -440,25 +444,14 @@ export default function SettingsView() {
           <button
             onClick={handleSaveBackup}
             disabled={!backupPath}
-            className="mt-3 flex items-center gap-2 rounded-lg bg-indigo-600 px-4 py-2 text-sm font-medium text-white hover:bg-indigo-500 disabled:opacity-50"
+            className="mt-3 flex items-center gap-2 rounded-lg bg-accent-600 px-4 py-2 text-sm font-medium text-white hover:bg-accent-500 disabled:opacity-50"
           >
             <Save size={14} />
             {backupSaved ? 'Saved!' : 'Save'}
           </button>
 
           <label className="mt-4 flex items-center gap-3 cursor-pointer">
-            <button
-              onClick={handleAutoUnsubscribeToggle}
-              className={`relative inline-flex h-5 w-9 shrink-0 items-center rounded-full transition-colors ${
-                autoUnsubscribeAfterBackup ? 'bg-indigo-600' : 'bg-white/10'
-              }`}
-            >
-              <span
-                className={`inline-block h-3.5 w-3.5 rounded-full bg-white transition-transform ${
-                  autoUnsubscribeAfterBackup ? 'translate-x-4' : 'translate-x-0.5'
-                }`}
-              />
-            </button>
+            <Toggle on={autoUnsubscribeAfterBackup} onClick={handleAutoUnsubscribeToggle} />
             <span className="flex items-center gap-2 text-sm text-gray-300">
               <Archive size={16} />
               Unsubscribe from Steam Workshop after backup
@@ -488,11 +481,11 @@ export default function SettingsView() {
                   value={defaultFps}
                   onChange={(e) => { setDefaultFps(e.target.value); setFpsSaved(false) }}
                   onKeyDown={(e) => e.key === 'Enter' && handleSaveDefaultFps()}
-                  className="w-28 rounded-lg bg-white/5 px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-indigo-500"
+                  className="w-28 rounded-lg bg-fg/5 px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-accent-500"
                 />
                 <button
                   onClick={handleSaveDefaultFps}
-                  className="flex items-center gap-2 rounded-lg bg-indigo-600 px-4 py-2 text-sm font-medium text-white hover:bg-indigo-500"
+                  className="flex items-center gap-2 rounded-lg bg-accent-600 px-4 py-2 text-sm font-medium text-white hover:bg-accent-500"
                 >
                   <Save size={14} />
                   {fpsSaved ? 'Saved!' : 'Save'}
@@ -501,18 +494,7 @@ export default function SettingsView() {
             </div>
             <div>
               <label className="mt-1 flex items-center gap-3 cursor-pointer">
-                <button
-                  onClick={handleRecommendedFpsToggle}
-                  className={`relative inline-flex h-5 w-9 shrink-0 items-center rounded-full transition-colors ${
-                    recommendedFpsEnabled ? 'bg-indigo-600' : 'bg-white/10'
-                  }`}
-                >
-                  <span
-                    className={`inline-block h-3.5 w-3.5 rounded-full bg-white transition-transform ${
-                      recommendedFpsEnabled ? 'translate-x-4' : 'translate-x-0.5'
-                    }`}
-                  />
-                </button>
+                <Toggle on={recommendedFpsEnabled} onClick={handleRecommendedFpsToggle} />
                 <span className="flex items-center gap-2 text-sm text-gray-300">
                   <Film size={16} />
                   Recommended video settings
@@ -527,18 +509,7 @@ export default function SettingsView() {
             </div>
             <div>
               <label className="mt-1 flex items-center gap-3 cursor-pointer">
-                <button
-                  onClick={handleRecommendedWebFpsToggle}
-                  className={`relative inline-flex h-5 w-9 shrink-0 items-center rounded-full transition-colors ${
-                    recommendedWebFpsEnabled ? 'bg-indigo-600' : 'bg-white/10'
-                  }`}
-                >
-                  <span
-                    className={`inline-block h-3.5 w-3.5 rounded-full bg-white transition-transform ${
-                      recommendedWebFpsEnabled ? 'translate-x-4' : 'translate-x-0.5'
-                    }`}
-                  />
-                </button>
+                <Toggle on={recommendedWebFpsEnabled} onClick={handleRecommendedWebFpsToggle} />
                 <span className="flex items-center gap-2 text-sm text-gray-300">
                   <Globe size={16} />
                   Recommended web wallpaper settings
@@ -568,7 +539,7 @@ export default function SettingsView() {
                   </button>
                   <button
                     onClick={() => setResetFpsConfirm(false)}
-                    className="rounded-lg bg-white/5 px-3 py-1.5 text-xs text-gray-400 hover:bg-white/10"
+                    className="rounded-lg bg-fg/5 px-3 py-1.5 text-xs text-gray-400 hover:bg-fg/10"
                   >
                     Cancel
                   </button>
@@ -576,7 +547,7 @@ export default function SettingsView() {
               ) : (
                 <button
                   onClick={handleResetFpsOverrides}
-                  className="flex items-center gap-2 rounded-lg bg-white/5 px-4 py-2 text-sm text-gray-300 hover:bg-white/10"
+                  className="flex items-center gap-2 rounded-lg bg-fg/5 px-4 py-2 text-sm text-gray-300 hover:bg-fg/10"
                 >
                   <RotateCcw size={14} />
                   Reset all FPS overrides
@@ -591,7 +562,7 @@ export default function SettingsView() {
 
         <DisplaySettings screens={screens} />
 
-        <VoteBorderSettings />
+        <CardBorderSettings />
 
         <ScheduleSettings />
 
@@ -613,7 +584,7 @@ export default function SettingsView() {
                 <select
                   value={audioScreen ?? ''}
                   onChange={(e) => handleAudioScreenChange(e.target.value || null)}
-                  className="w-56 rounded-lg bg-white/5 px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-indigo-500"
+                  className="w-56 rounded-lg bg-fg/5 px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-accent-500"
                 >
                   <option value="">All screens (default)</option>
                   {screens.map((s) => (
@@ -626,7 +597,7 @@ export default function SettingsView() {
                   type="button"
                   onClick={handleRefreshScreens}
                   disabled={screensRefreshing}
-                  className="rounded-lg bg-white/5 px-3 py-2 text-sm text-gray-300 outline-none hover:bg-white/10 disabled:opacity-50"
+                  className="rounded-lg bg-fg/5 px-3 py-2 text-sm text-gray-300 outline-none hover:bg-fg/10 disabled:opacity-50"
                   title="Redetect connected screens"
                 >
                   {screensRefreshing ? '...' : 'Redetect'}
@@ -650,11 +621,11 @@ export default function SettingsView() {
                   value={ambientVolume}
                   onChange={(e) => { setAmbientVolume(e.target.value); setAmbientVolumeSaved(false) }}
                   onKeyDown={(e) => e.key === 'Enter' && handleSaveAmbientVolume()}
-                  className="w-44 rounded-lg bg-white/5 px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-indigo-500"
+                  className="w-44 rounded-lg bg-fg/5 px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-accent-500"
                 />
                 <button
                   onClick={handleSaveAmbientVolume}
-                  className="flex items-center gap-2 rounded-lg bg-indigo-600 px-4 py-2 text-sm font-medium text-white hover:bg-indigo-500"
+                  className="flex items-center gap-2 rounded-lg bg-accent-600 px-4 py-2 text-sm font-medium text-white hover:bg-accent-500"
                 >
                   <Save size={14} />
                   {ambientVolumeSaved ? 'Saved!' : 'Save'}
@@ -677,12 +648,12 @@ export default function SettingsView() {
                   value={defaultAudioSensitivity}
                   onChange={(e) => { setDefaultAudioSensitivity(e.target.value); setDefaultAudioSensitivitySaved(false) }}
                   onKeyDown={(e) => e.key === 'Enter' && handleSaveDefaultAudioSensitivity()}
-                  className="w-44 rounded-lg bg-white/5 px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-indigo-500"
+                  className="w-44 rounded-lg bg-fg/5 px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-accent-500"
                 />
                 <span className="text-sm text-gray-500">%</span>
                 <button
                   onClick={handleSaveDefaultAudioSensitivity}
-                  className="flex items-center gap-2 rounded-lg bg-indigo-600 px-4 py-2 text-sm font-medium text-white hover:bg-indigo-500"
+                  className="flex items-center gap-2 rounded-lg bg-accent-600 px-4 py-2 text-sm font-medium text-white hover:bg-accent-500"
                 >
                   <Save size={14} />
                   {defaultAudioSensitivitySaved ? 'Saved!' : 'Save'}
@@ -703,7 +674,7 @@ export default function SettingsView() {
           </p>
           <button
             onClick={handleImportConfig}
-            className="mt-3 flex items-center gap-2 rounded-lg bg-white/5 px-4 py-2 text-sm text-gray-300 hover:bg-white/10"
+            className="mt-3 flex items-center gap-2 rounded-lg bg-fg/5 px-4 py-2 text-sm text-gray-300 hover:bg-fg/10"
           >
             <Upload size={14} />
             Import config.json
@@ -757,7 +728,7 @@ export default function SettingsView() {
                   <button
                     onClick={handleInstallPrebuilt}
                     disabled={isBusy}
-                    className="flex items-center gap-2 rounded-lg bg-indigo-600 px-4 py-2 text-sm font-medium text-white hover:bg-indigo-500 disabled:opacity-50"
+                    className="flex items-center gap-2 rounded-lg bg-accent-600 px-4 py-2 text-sm font-medium text-white hover:bg-accent-500 disabled:opacity-50"
                   >
                     {lweInstalling ? (
                       <Loader2 size={14} className="animate-spin" />
@@ -810,7 +781,7 @@ export default function SettingsView() {
           )}
 
           {sourceBuildVisible && (
-            <div className="mt-2 space-y-2 rounded-lg bg-white/[0.02] p-3">
+            <div className="mt-2 space-y-2 rounded-lg bg-fg/[0.02] p-3">
               <label className="block text-xs text-gray-400">Source repository</label>
               <p className="text-xs text-gray-600">
                 A git URL or a local path. Leave empty to use the default repository.
@@ -820,7 +791,7 @@ export default function SettingsView() {
                 value={lweRepoUrl}
                 onChange={(e) => { setLweRepoUrl(e.target.value); setRepoSaved(false) }}
                 placeholder={defaultLweRepo}
-                className="w-full rounded-lg bg-white/5 px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-indigo-500"
+                className="w-full rounded-lg bg-fg/5 px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-accent-500"
               />
               <div className="flex gap-2 items-center">
                 <input
@@ -828,11 +799,11 @@ export default function SettingsView() {
                   value={lweRepoBranch}
                   onChange={(e) => { setLweRepoBranch(e.target.value); setRepoSaved(false) }}
                   placeholder="branch (default)"
-                  className="w-44 rounded-lg bg-white/5 px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-indigo-500"
+                  className="w-44 rounded-lg bg-fg/5 px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-accent-500"
                 />
                 <button
                   onClick={handleSaveRepo}
-                  className="flex items-center gap-2 rounded-lg bg-white/5 px-4 py-2 text-sm text-gray-300 hover:bg-white/10"
+                  className="flex items-center gap-2 rounded-lg bg-fg/5 px-4 py-2 text-sm text-gray-300 hover:bg-fg/10"
                 >
                   <Save size={14} />
                   {repoSaved ? 'Saved!' : 'Save'}
@@ -847,7 +818,7 @@ export default function SettingsView() {
                 value={lweCmakeArgs}
                 onChange={(e) => { setLweCmakeArgs(e.target.value); setRepoSaved(false) }}
                 placeholder="-DDISABLE_KDE_FEATURES=ON"
-                className="w-full rounded-lg bg-white/5 px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-indigo-500 font-mono"
+                className="w-full rounded-lg bg-fg/5 px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-accent-500 font-mono"
               />
 
               {distro && distro !== 'unknown' && (
@@ -865,7 +836,7 @@ export default function SettingsView() {
                       ? 'Could not detect your distro. Install dependencies manually.'
                       : undefined
                   }
-                  className="flex items-center gap-2 rounded-lg bg-white/5 px-4 py-2 text-sm text-gray-300 hover:bg-white/10 disabled:opacity-50"
+                  className="flex items-center gap-2 rounded-lg bg-fg/5 px-4 py-2 text-sm text-gray-300 hover:bg-fg/10 disabled:opacity-50"
                 >
                   {depsInstalling ? (
                     <Loader2 size={14} className="animate-spin" />
@@ -878,7 +849,7 @@ export default function SettingsView() {
                 <button
                   onClick={handleInstallLwe}
                   disabled={isBusy}
-                  className="flex items-center gap-2 rounded-lg bg-white/5 px-4 py-2 text-sm text-gray-300 hover:bg-white/10 disabled:opacity-50"
+                  className="flex items-center gap-2 rounded-lg bg-fg/5 px-4 py-2 text-sm text-gray-300 hover:bg-fg/10 disabled:opacity-50"
                 >
                   {lweInstalling ? (
                     <Loader2 size={14} className="animate-spin" />
@@ -911,14 +882,14 @@ export default function SettingsView() {
                 ) : lweProgress.stage === 'done' ? (
                   <CheckCircle size={14} className="text-green-400 shrink-0" />
                 ) : (
-                  <Loader2 size={14} className="animate-spin text-indigo-400 shrink-0" />
+                  <Loader2 size={14} className="animate-spin text-accent-400 shrink-0" />
                 )}
                 <p className="text-xs text-gray-300 whitespace-pre-wrap break-all">{lweProgress.message}</p>
               </div>
               {lweProgress.stage !== 'error' && lweProgress.stage !== 'done' && (
-                <div className="h-1.5 w-full rounded-full bg-white/5">
+                <div className="h-1.5 w-full rounded-full bg-fg/5">
                   <div
-                    className="h-full rounded-full bg-indigo-500 transition-all duration-300"
+                    className="h-full rounded-full bg-accent-500 transition-all duration-300"
                     style={{ width: `${lweProgress.percentage}%` }}
                   />
                 </div>
@@ -947,18 +918,7 @@ export default function SettingsView() {
             )}
 
             <label className="mt-3 flex items-center gap-3 cursor-pointer">
-              <button
-                onClick={handleKillLweOnQuitToggle}
-                className={`relative inline-flex h-5 w-9 shrink-0 items-center rounded-full transition-colors ${
-                  killLweOnQuit ? 'bg-indigo-600' : 'bg-white/10'
-                }`}
-              >
-                <span
-                  className={`inline-block h-3.5 w-3.5 rounded-full bg-white transition-transform ${
-                    killLweOnQuit ? 'translate-x-4' : 'translate-x-0.5'
-                  }`}
-                />
-              </button>
+              <Toggle on={killLweOnQuit} onClick={handleKillLweOnQuitToggle} />
               <span className="flex items-center gap-2 text-sm text-gray-300">
                 <Skull size={16} />
                 Kill all linux-wallpaperengine processes when WE Manager quits
@@ -982,18 +942,7 @@ export default function SettingsView() {
             already running needs to be replayed to pick it up.
           </p>
           <label className="mt-3 flex items-center gap-3 cursor-pointer">
-            <button
-              onClick={handleDisablePuppetAnimationToggle}
-              className={`relative inline-flex h-5 w-9 shrink-0 items-center rounded-full transition-colors ${
-                disablePuppetAnimation ? 'bg-indigo-600' : 'bg-white/10'
-              }`}
-            >
-              <span
-                className={`inline-block h-3.5 w-3.5 rounded-full bg-white transition-transform ${
-                  disablePuppetAnimation ? 'translate-x-4' : 'translate-x-0.5'
-                }`}
-              />
-            </button>
+            <Toggle on={disablePuppetAnimation} onClick={handleDisablePuppetAnimationToggle} />
             <span className="flex items-center gap-2 text-sm text-gray-300">
               <Bug size={16} />
               Disable puppet mesh animation
@@ -1010,18 +959,7 @@ export default function SettingsView() {
             that reads your KDE Folder View layout. Clicks pass through to the desktop underneath.
           </p>
           <label className="mt-3 flex items-center gap-3 cursor-pointer">
-            <button
-              onClick={handleDesktopIconsToggle}
-              className={`relative inline-flex h-5 w-9 shrink-0 items-center rounded-full transition-colors ${
-                desktopIconsEnabled ? 'bg-indigo-600' : 'bg-white/10'
-              }`}
-            >
-              <span
-                className={`inline-block h-3.5 w-3.5 rounded-full bg-white transition-transform ${
-                  desktopIconsEnabled ? 'translate-x-4' : 'translate-x-0.5'
-                }`}
-              />
-            </button>
+            <Toggle on={desktopIconsEnabled} onClick={handleDesktopIconsToggle} />
             <span className="flex items-center gap-2 text-sm text-gray-300">
               <Monitor size={16} />
               {desktopIconsEnabled ? 'Desktop icons visible' : 'Desktop icons hidden'}
@@ -1038,18 +976,7 @@ export default function SettingsView() {
           </p>
 
           <label className="mt-3 flex items-center gap-3 cursor-pointer">
-            <button
-              onClick={handleTrayToggle}
-              className={`relative inline-flex h-5 w-9 shrink-0 items-center rounded-full transition-colors ${
-                trayEnabled ? 'bg-indigo-600' : 'bg-white/10'
-              }`}
-            >
-              <span
-                className={`inline-block h-3.5 w-3.5 rounded-full bg-white transition-transform ${
-                  trayEnabled ? 'translate-x-4' : 'translate-x-0.5'
-                }`}
-              />
-            </button>
+            <Toggle on={trayEnabled} onClick={handleTrayToggle} />
             <span className="flex items-center gap-2 text-sm text-gray-300">
               <LayoutGrid size={16} />
               Enable system tray (closing the window minimizes to tray instead of quitting)
@@ -1058,19 +985,7 @@ export default function SettingsView() {
 
           <div className="mt-4 space-y-3">
             <label className="flex items-center gap-3 cursor-pointer">
-              <button
-                onClick={() => autostartSupported && saveAutostart({ enabled: !autostartEnabled })}
-                disabled={!autostartSupported}
-                className={`relative inline-flex h-5 w-9 shrink-0 items-center rounded-full transition-colors disabled:opacity-40 ${
-                  autostartEnabled ? 'bg-indigo-600' : 'bg-white/10'
-                }`}
-              >
-                <span
-                  className={`inline-block h-3.5 w-3.5 rounded-full bg-white transition-transform ${
-                    autostartEnabled ? 'translate-x-4' : 'translate-x-0.5'
-                  }`}
-                />
-              </button>
+              <Toggle on={autostartEnabled} onClick={() => autostartSupported && saveAutostart({ enabled: !autostartEnabled })} disabled={!autostartSupported} />
               <span className="flex items-center gap-2 text-sm text-gray-300">
                 <Power size={16} />
                 Launch on system startup
@@ -1092,21 +1007,11 @@ export default function SettingsView() {
             )}
 
             <label className="flex items-center gap-3 cursor-pointer pl-12">
-              <button
-                onClick={() =>
-                  trayEnabled && autostartEnabled && saveAutostart({ minimized: !autostartMinimized })
-                }
+              <Toggle
+                on={autostartMinimized}
+                onClick={() => saveAutostart({ minimized: !autostartMinimized })}
                 disabled={!trayEnabled || !autostartEnabled}
-                className={`relative inline-flex h-5 w-9 shrink-0 items-center rounded-full transition-colors disabled:opacity-40 ${
-                  autostartMinimized ? 'bg-indigo-600' : 'bg-white/10'
-                }`}
-              >
-                <span
-                  className={`inline-block h-3.5 w-3.5 rounded-full bg-white transition-transform ${
-                    autostartMinimized ? 'translate-x-4' : 'translate-x-0.5'
-                  }`}
-                />
-              </button>
+              />
               <span className="text-sm text-gray-300">
                 Start minimized to tray
                 {!trayEnabled && <span className="text-gray-600"> (enable system tray first)</span>}
@@ -1118,7 +1023,7 @@ export default function SettingsView() {
               <select
                 value={autostartPlaylistId ?? ''}
                 onChange={(e) => saveAutostart({ playlistId: e.target.value || null })}
-                className="w-56 rounded-lg bg-white/5 px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-indigo-500"
+                className="w-56 rounded-lg bg-fg/5 px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-accent-500"
               >
                 <option value="">None</option>
                 {playlists.map((p) => (
@@ -1147,8 +1052,8 @@ export default function SettingsView() {
               onClick={() => handleSteamIdentityChange('wallpaper-engine')}
               className={`flex items-center gap-2 px-3 py-2 transition-colors ${
                 steamIdentity === 'wallpaper-engine'
-                  ? 'bg-indigo-600 text-white'
-                  : 'bg-white/5 text-gray-400 hover:text-gray-200'
+                  ? 'bg-accent-600 text-white'
+                  : 'bg-fg/5 text-gray-400 hover:text-gray-200'
               }`}
             >
               <Shield size={14} />
@@ -1158,8 +1063,8 @@ export default function SettingsView() {
               onClick={() => handleSteamIdentityChange('standalone')}
               className={`flex items-center gap-2 px-3 py-2 transition-colors ${
                 steamIdentity === 'standalone'
-                  ? 'bg-indigo-600 text-white'
-                  : 'bg-white/5 text-gray-400 hover:text-gray-200'
+                  ? 'bg-accent-600 text-white'
+                  : 'bg-fg/5 text-gray-400 hover:text-gray-200'
               }`}
             >
               <Shield size={14} />

+ 0 - 41
src/renderer/src/components/settings/VoteBorderSettings.tsx

@@ -1,41 +0,0 @@
-import { useQueryClient } from '@tanstack/react-query'
-import { ThumbsUp } from 'lucide-react'
-import { useVoteBorders } from '../../hooks/useVoteBorders'
-
-export default function VoteBorderSettings() {
-  const queryClient = useQueryClient()
-  const { enabled } = useVoteBorders()
-
-  async function toggle() {
-    await window.electronAPI.config.setVoteBorders(!enabled)
-    queryClient.invalidateQueries({ queryKey: ['config'] })
-  }
-
-  return (
-    <div>
-      <label className="block text-xs font-medium uppercase tracking-wide text-gray-500">Likes</label>
-      <label className="mt-3 flex items-center gap-3 cursor-pointer">
-        <button
-          onClick={toggle}
-          className={`relative inline-flex h-5 w-9 shrink-0 items-center rounded-full transition-colors ${
-            enabled ? 'bg-indigo-600' : 'bg-white/10'
-          }`}
-        >
-          <span
-            className={`inline-block h-3.5 w-3.5 rounded-full bg-white transition-transform ${
-              enabled ? 'translate-x-4' : 'translate-x-0.5'
-            }`}
-          />
-        </button>
-        <span className="flex items-center gap-2 text-sm text-gray-300">
-          <ThumbsUp size={16} />
-          Show like borders on wallpapers
-        </span>
-      </label>
-      <p className="mt-1 text-xs text-gray-600">
-        Green for wallpapers you liked on Steam, red for ones where the like failed after retrying (hover for the
-        reason). Failed likes are remembered until the app restarts.
-      </p>
-    </div>
-  )
-}

+ 12 - 12
src/renderer/src/components/setup/SetupScreen.tsx

@@ -67,16 +67,16 @@ export default function SetupScreen({ defaultPath, onComplete }: SetupScreenProp
       : '~/.steam/steam/steamapps/workshop/content/431960'
 
   return (
-    <div className="flex h-full items-center justify-center bg-[#0f0f0f]">
-      <div className="w-full max-w-lg rounded-xl border border-white/10 bg-[#1a1a1a] p-8">
+    <div className="flex h-full items-center justify-center bg-app">
+      <div className="w-full max-w-lg rounded-xl border border-fg/10 bg-card p-8">
         <h1 className="text-xl font-semibold text-gray-100">Welcome to WE Manager</h1>
 
         <div className="mt-4 flex items-center gap-2 text-xs text-gray-600">
-          <span className={step === 1 ? 'text-indigo-400' : 'text-gray-500'}>
+          <span className={step === 1 ? 'text-accent-400' : 'text-gray-500'}>
             1. Workshop folder
           </span>
           <ArrowRight size={10} />
-          <span className={step === 2 ? 'text-indigo-400' : 'text-gray-500'}>
+          <span className={step === 2 ? 'text-accent-400' : 'text-gray-500'}>
             2. Import config
           </span>
         </div>
@@ -97,11 +97,11 @@ export default function SetupScreen({ defaultPath, onComplete }: SetupScreenProp
                   type="text"
                   value={selectedPath}
                   onChange={(e) => setSelectedPath(e.target.value)}
-                  className="flex-1 rounded-lg bg-white/5 px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-indigo-500"
+                  className="flex-1 rounded-lg bg-fg/5 px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-accent-500"
                 />
                 <button
                   onClick={handleBrowse}
-                  className="flex items-center gap-2 rounded-lg bg-white/5 px-3 py-2 text-sm text-gray-300 hover:bg-white/10"
+                  className="flex items-center gap-2 rounded-lg bg-fg/5 px-3 py-2 text-sm text-gray-300 hover:bg-fg/10"
                 >
                   <FolderOpen size={16} />
                   Browse
@@ -116,7 +116,7 @@ export default function SetupScreen({ defaultPath, onComplete }: SetupScreenProp
             <button
               onClick={handleConfirmPath}
               disabled={!selectedPath || saving}
-              className="mt-8 flex w-full items-center justify-center gap-2 rounded-lg bg-indigo-600 px-4 py-2.5 text-sm font-medium text-white hover:bg-indigo-500 disabled:opacity-50"
+              className="mt-8 flex w-full items-center justify-center gap-2 rounded-lg bg-accent-600 px-4 py-2.5 text-sm font-medium text-white hover:bg-accent-500 disabled:opacity-50"
             >
               {saving ? (
                 <Loader2 size={16} className="animate-spin" />
@@ -141,9 +141,9 @@ export default function SetupScreen({ defaultPath, onComplete }: SetupScreenProp
               <button
                 onClick={handleImportConfig}
                 disabled={importing}
-                className="flex items-center gap-3 rounded-lg border border-white/10 px-4 py-3 text-left transition-colors hover:bg-white/5 disabled:opacity-50"
+                className="flex items-center gap-3 rounded-lg border border-fg/10 px-4 py-3 text-left transition-colors hover:bg-fg/5 disabled:opacity-50"
               >
-                <Upload size={20} className="text-indigo-400" />
+                <Upload size={20} className="text-accent-400" />
                 <div>
                   <p className="text-sm font-medium text-gray-200">
                     Import existing config.json
@@ -157,7 +157,7 @@ export default function SetupScreen({ defaultPath, onComplete }: SetupScreenProp
               <button
                 onClick={handleCreateFresh}
                 disabled={importing}
-                className="flex items-center gap-3 rounded-lg border border-white/10 px-4 py-3 text-left transition-colors hover:bg-white/5 disabled:opacity-50"
+                className="flex items-center gap-3 rounded-lg border border-fg/10 px-4 py-3 text-left transition-colors hover:bg-fg/5 disabled:opacity-50"
               >
                 <FilePlus size={20} className="text-gray-400" />
                 <div>
@@ -170,7 +170,7 @@ export default function SetupScreen({ defaultPath, onComplete }: SetupScreenProp
             </div>
 
             {importResult && (
-              <div className="mt-4 rounded-lg bg-white/5 px-4 py-3 text-xs text-gray-300">
+              <div className="mt-4 rounded-lg bg-fg/5 px-4 py-3 text-xs text-gray-300">
                 {importResult}
               </div>
             )}
@@ -178,7 +178,7 @@ export default function SetupScreen({ defaultPath, onComplete }: SetupScreenProp
             <button
               onClick={handleFinish}
               disabled={importing}
-              className="mt-6 flex w-full items-center justify-center gap-2 rounded-lg bg-indigo-600 px-4 py-2.5 text-sm font-medium text-white hover:bg-indigo-500 disabled:opacity-50"
+              className="mt-6 flex w-full items-center justify-center gap-2 rounded-lg bg-accent-600 px-4 py-2.5 text-sm font-medium text-white hover:bg-accent-500 disabled:opacity-50"
             >
               <Check size={16} />
               {importResult ? 'Done' : 'Skip & Finish'}

+ 72 - 30
src/renderer/src/components/workshop/WorkshopBrowser.tsx

@@ -10,7 +10,8 @@ import {
   MenuItem,
   MenuSelectionCount,
   MenuSeparator,
-  VoteMenuItems
+  VoteMenuItems,
+  FavoriteMenuItems
 } from '../common/ContextMenu'
 import {
   FiltersToggle,
@@ -20,7 +21,7 @@ import {
   ResetFiltersButton,
   SearchInput
 } from '../common/GridControls'
-import { CheckItem, FilterPanel, FilterSection, ResolutionFilterSection, TagFilterSection } from '../common/FilterPanel'
+import { CheckGroup, CheckItem, FilterPanel, FilterSection, ResolutionFilterSection, TagFilterSection } from '../common/FilterPanel'
 import type { WorkshopQueryType } from '@shared/types'
 import clsx from 'clsx'
 import {
@@ -34,8 +35,9 @@ import {
 } from '../../constants/weFilters'
 import { usePreviewSize, previewGridStyle } from '../../hooks/usePreviewSize'
 import { usePersistentState } from '../../hooks/usePersistentState'
-import { useVoteBorders } from '../../hooks/useVoteBorders'
-import { useBatchVote, useVotedIds } from '../../hooks/useVotes'
+import { useCardBorders, useCardSteamState } from '../../hooks/useCardBorders'
+import { useBatchVote, useDislikedIds, useVotedIds } from '../../hooks/useVotes'
+import { useBatchFavorite, useFavoriteIds } from '../../hooks/useFavorites'
 import { useAllWallpapers, useFolders, useLweInstalled } from '../../hooks/queries'
 import { useApplyWallpaper, useUnsubscribe } from '../../hooks/useWallpaperActions'
 import { useSelectableGrid } from '../../hooks/useSelectableGrid'
@@ -66,6 +68,8 @@ interface WorkshopFilterState extends Record<TagCategory, string[]> {
   showOnly: string[]
   notDownloaded: boolean
   notLiked: boolean
+  notDisliked: boolean
+  notFavorited: boolean
   sizeFilterMode: 'none' | 'lt' | 'gt'
   sizeFilterMb: number
 }
@@ -81,6 +85,8 @@ const DEFAULT_STATE: WorkshopFilterState = {
   genres: ALL_TAGS.genres,
   notDownloaded: false,
   notLiked: false,
+  notDisliked: false,
+  notFavorited: false,
   sizeFilterMode: 'none',
   sizeFilterMb: 100
 }
@@ -141,8 +147,12 @@ export default function WorkshopBrowser({
   const [showIgnored, setShowIgnored] = useState(false)
 
   const votedSet = useVotedIds()
+  const dislikedSet = useDislikedIds()
   const batchVote = useBatchVote()
-  const { enabled: voteBordersEnabled, failed: failedVotes } = useVoteBorders()
+  const favoriteSet = useFavoriteIds()
+  const batchFavorite = useBatchFavorite()
+  const steamStateOf = useCardSteamState()
+  const cardBorders = useCardBorders()
   const lweInstalled = useLweInstalled()
   const applyWallpaper = useApplyWallpaper()
   const unsubscribe = useUnsubscribe()
@@ -168,11 +178,13 @@ export default function WorkshopBrowser({
     )
   ]
 
+  const statusFilterCount = [filters.notDownloaded, filters.notLiked, filters.notDisliked, filters.notFavorited].filter(
+    Boolean
+  ).length
   const activeCount =
     filters.showOnly.length +
     TAG_CATEGORIES.reduce((sum, key) => sum + effective[key].length, 0) +
-    (filters.notDownloaded ? 1 : 0) +
-    (filters.notLiked ? 1 : 0) +
+    statusFilterCount +
     (filters.sizeFilterMode !== 'none' ? 1 : 0)
 
   function clearAll() {
@@ -264,6 +276,8 @@ export default function WorkshopBrowser({
         return false
       if (filters.notDownloaded && playableSet.has(item.publishedFileId)) return false
       if (filters.notLiked && votedSet.has(item.publishedFileId)) return false
+      if (filters.notDisliked && dislikedSet.has(item.publishedFileId)) return false
+      if (filters.notFavorited && favoriteSet.has(item.publishedFileId)) return false
       if (filters.sizeFilterMode !== 'none') {
         if (item.fileSize == null) return false
         if (filters.sizeFilterMode === 'lt' && item.fileSize >= sizeThresholdBytes) return false
@@ -276,7 +290,7 @@ export default function WorkshopBrowser({
         return false
       return true
     })
-  }, [allItems, searchQuery, filters, effective, playableSet, votedSet])
+  }, [allItems, searchQuery, filters, effective, playableSet, votedSet, dislikedSet, favoriteSet])
 
   // Page boundaries are fixed against the full tag-filtered list (ignored creators' items
   // included) so a page's contents don't shift around as the ignore list changes. Within a
@@ -370,6 +384,11 @@ export default function WorkshopBrowser({
         <MenuItem onClick={run(() => unsubscribeIds(menu.ids))}>Unsubscribe</MenuItem>
         <MenuSeparator />
         <VoteMenuItems onVote={(up) => run(() => batchVote(menu.ids, up))()} />
+        <FavoriteMenuItems
+          ids={menu.ids}
+          favorites={favoriteSet}
+          onFavorite={(ids, add) => run(() => batchFavorite(ids, add))()}
+        />
         <MenuSeparator />
         <MenuItem icon={ExternalLink} onClick={run(() => menu.ids.forEach(openWorkshopPage))}>
           Open in Steam Workshop
@@ -404,7 +423,7 @@ export default function WorkshopBrowser({
 
   return (
     <div className="flex h-full flex-col">
-      <div className="flex items-center gap-3 border-b border-white/5 px-4 py-3">
+      <div className="flex items-center gap-3 border-b border-fg/5 px-4 py-3">
         <FiltersToggle open={showFilters} activeCount={activeCount} onClick={() => setShowFilters((v) => !v)} />
         <SearchInput
           value={searchText}
@@ -415,7 +434,7 @@ export default function WorkshopBrowser({
         <select
           value={queryType}
           onChange={(e) => setQueryType(e.target.value as WorkshopQueryType)}
-          className="rounded-lg bg-[#1a1a1a] px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-indigo-500"
+          className="rounded-lg bg-card px-3 py-2 text-sm text-gray-200 outline-none focus:ring-1 focus:ring-accent-500"
         >
           <option value="RankedByVote">Top Rated</option>
           <option value="RankedByPublicationDate">Newest</option>
@@ -431,28 +450,28 @@ export default function WorkshopBrowser({
             <button
               onClick={() => enqueueSubscribe([...selection])}
               title={selectionSize?.title ?? 'Everything selected is already subscribed or queued'}
-              className="flex items-center gap-1.5 rounded-lg bg-indigo-600 px-3 py-2 text-sm text-white hover:bg-indigo-500"
+              className="flex items-center gap-1.5 rounded-lg bg-accent-600 px-3 py-2 text-sm text-white hover:bg-accent-500"
             >
               <Download size={14} /> Subscribe selection
-              {selectionSize && <span className="text-indigo-200">({selectionSize.label})</span>}
+              {selectionSize && <span className="text-accent-200">({selectionSize.label})</span>}
             </button>
           </>
         )}
       </div>
 
       {creatorFilter && (
-        <div className="flex items-center gap-2 border-b border-white/5 bg-indigo-600/10 px-4 py-2 text-xs text-indigo-200">
+        <div className="flex items-center gap-2 border-b border-fg/5 bg-accent-600/10 px-4 py-2 text-xs text-accent-200">
           <User size={12} />
           <span>Showing wallpapers from this creator</span>
           <button
             onClick={() => openProfilePage(creatorFilter)}
-            className="flex items-center gap-1 rounded bg-white/5 px-2 py-1 text-gray-300 hover:bg-white/10"
+            className="flex items-center gap-1 rounded bg-fg/5 px-2 py-1 text-gray-300 hover:bg-fg/10"
           >
             <ExternalLink size={11} /> View Steam profile
           </button>
           <button
             onClick={() => onClearCreatorFilter?.()}
-            className="ml-auto flex items-center gap-1 rounded bg-white/5 px-2 py-1 text-gray-300 hover:bg-white/10"
+            className="ml-auto flex items-center gap-1 rounded bg-fg/5 px-2 py-1 text-gray-300 hover:bg-fg/10"
           >
             <X size={11} /> Clear
           </button>
@@ -472,8 +491,8 @@ export default function WorkshopBrowser({
                     className={clsx(
                       'px-2.5 py-1 transition-colors',
                       filters.filterMode === mode
-                        ? 'bg-indigo-600 text-white'
-                        : 'bg-white/5 text-gray-400 hover:text-gray-200'
+                        ? 'bg-accent-600 text-white'
+                        : 'bg-fg/5 text-gray-400 hover:text-gray-200'
                     )}
                   >
                     {mode === 'or' ? 'Any (OR)' : 'All (AND)'}
@@ -484,7 +503,7 @@ export default function WorkshopBrowser({
 
             <FilterSection
               title="Status"
-              activeCount={(filters.notDownloaded ? 1 : 0) + (filters.notLiked ? 1 : 0)}
+              activeCount={statusFilterCount}
             >
               <CheckItem
                 label="Not downloaded"
@@ -492,16 +511,40 @@ export default function WorkshopBrowser({
                 onChange={() => setFilter('notDownloaded', !filters.notDownloaded)}
               />
               <CheckItem
-                label="Not liked"
-                checked={filters.notLiked}
-                onChange={() => setFilter('notLiked', !filters.notLiked)}
+                label="Not rated"
+                title="Hide wallpapers you've liked or disliked on Steam"
+                checked={filters.notLiked && filters.notDisliked}
+                indeterminate={filters.notLiked !== filters.notDisliked}
+                onChange={() => {
+                  const on = !(filters.notLiked && filters.notDisliked)
+                  setFilters((prev) => ({ ...prev, notLiked: on, notDisliked: on }))
+                }}
+              />
+              <CheckGroup>
+                <CheckItem
+                  nested
+                  label="Not liked"
+                  checked={filters.notLiked}
+                  onChange={() => setFilter('notLiked', !filters.notLiked)}
+                />
+                <CheckItem
+                  nested
+                  label="Not disliked"
+                  checked={filters.notDisliked}
+                  onChange={() => setFilter('notDisliked', !filters.notDisliked)}
+                />
+              </CheckGroup>
+              <CheckItem
+                label="Not favorited"
+                checked={filters.notFavorited}
+                onChange={() => setFilter('notFavorited', !filters.notFavorited)}
               />
             </FilterSection>
             <FilterSection title="File Size" activeCount={filters.sizeFilterMode !== 'none' ? 1 : 0}>
               <select
                 value={filters.sizeFilterMode}
                 onChange={(e) => setFilter('sizeFilterMode', e.target.value as WorkshopFilterState['sizeFilterMode'])}
-                className="w-full rounded bg-[#1a1a1a] px-1.5 py-1 text-xs text-gray-300 outline-none"
+                className="w-full rounded bg-card px-1.5 py-1 text-xs text-gray-300 outline-none"
               >
                 <option value="none">Any size</option>
                 <option value="lt">Less than</option>
@@ -514,7 +557,7 @@ export default function WorkshopBrowser({
                     min={0}
                     value={filters.sizeFilterMb}
                     onChange={(e) => setFilter('sizeFilterMb', Math.max(0, Number(e.target.value) || 0))}
-                    className="w-16 rounded bg-[#1a1a1a] px-1.5 py-1 text-xs text-gray-300 outline-none focus:ring-1 focus:ring-indigo-500"
+                    className="w-16 rounded bg-card px-1.5 py-1 text-xs text-gray-300 outline-none focus:ring-1 focus:ring-accent-500"
                   />
                   <span className="text-xs text-gray-500">MB</span>
                 </div>
@@ -595,9 +638,8 @@ export default function WorkshopBrowser({
                 selected={selection.has(item.publishedFileId)}
                 isDetailOpen={detailId === item.publishedFileId}
                 ignored={ignoredCreatorSet.has(item.creatorSteamId)}
-                isLiked={votedSet.has(item.publishedFileId)}
-                voteError={failedVotes[item.publishedFileId]}
-                showVoteBorder={voteBordersEnabled}
+                steam={steamStateOf(item.publishedFileId)}
+                borders={cardBorders}
                 canPlay={playableSet.has(item.publishedFileId)}
                 lweInstalled={lweInstalled}
                 subscribeState={subscribeEntries.get(item.publishedFileId)?.state}
@@ -616,27 +658,27 @@ export default function WorkshopBrowser({
             </div>
           )}
           {pageIgnoredItems.length > 0 && (
-            <div className="mt-4 flex items-center justify-center gap-2 border-t border-white/5 pt-3 text-xs text-gray-500">
+            <div className="mt-4 flex items-center justify-center gap-2 border-t border-fg/5 pt-3 text-xs text-gray-500">
               <span>
                 {pageIgnoredItems.length} wallpaper{pageIgnoredItems.length === 1 ? '' : 's'} ignored on
                 this page
               </span>
               <button
                 onClick={() => setShowIgnored((v) => !v)}
-                className="rounded bg-white/5 px-2 py-1 text-gray-300 hover:bg-white/10"
+                className="rounded bg-fg/5 px-2 py-1 text-gray-300 hover:bg-fg/10"
               >
                 {showIgnored ? 'Hide ignored' : 'Show ignored'}
               </button>
             </div>
           )}
           {totalFiltered > 0 && (
-            <div className="mt-4 flex items-center justify-between border-t border-white/5 pt-3">
+            <div className="mt-4 flex items-center justify-between border-t border-fg/5 pt-3">
               <div className="flex items-center gap-2 text-xs text-gray-400">
                 <span>Per page:</span>
                 <select
                   value={pageSize}
                   onChange={(e) => setPageSize(Number(e.target.value))}
-                  className="rounded bg-[#1a1a1a] px-2 py-1 text-gray-300 outline-none"
+                  className="rounded bg-card px-2 py-1 text-gray-300 outline-none"
                 >
                   <option value={50}>50</option>
                   <option value={100}>100</option>

+ 12 - 13
src/renderer/src/components/workshop/WorkshopCard.tsx

@@ -1,6 +1,8 @@
 import { useState } from 'react'
 import { Download, Check, Loader2, Clock, AlertTriangle } from 'lucide-react'
 import type { WorkshopItem } from '@shared/types'
+import type { CardBorders } from '@shared/cardBorders'
+import type { CardSteamState } from '../../hooks/useCardBorders'
 import { isSubscribedState, type SubscribeState } from '../../hooks/useSubscriptionQueue'
 import { formatFileSize } from '../../utils/format'
 import { CardPreview, CornerBadge, GridCard, LikeAction, PlayButton, ProgressBar, SteamAction } from '../common/GridCard'
@@ -10,9 +12,8 @@ interface WorkshopCardProps {
   selected: boolean
   isDetailOpen: boolean
   ignored: boolean
-  isLiked: boolean
-  voteError?: string
-  showVoteBorder: boolean
+  steam: CardSteamState
+  borders: CardBorders
   canPlay: boolean
   lweInstalled: boolean
   subscribeState?: SubscribeState
@@ -30,9 +31,8 @@ export default function WorkshopCard({
   selected,
   isDetailOpen,
   ignored,
-  isLiked,
-  voteError,
-  showVoteBorder,
+  steam,
+  borders,
   canPlay,
   lweInstalled,
   subscribeState,
@@ -66,9 +66,8 @@ export default function WorkshopCard({
       data-workshop-id={item.publishedFileId}
       selected={selected}
       isDetailOpen={isDetailOpen}
-      isLiked={isLiked}
-      voteError={voteError}
-      showVoteBorder={showVoteBorder}
+      steam={steam}
+      borders={borders}
       onContextMenu={onContextMenu}
       onClick={onSelect}
     >
@@ -92,7 +91,7 @@ export default function WorkshopCard({
         )}
         {(subscribeState === 'download-queued' || subscribeState === 'downloading') && (
           <CornerBadge
-            className="bottom-2 right-2 bg-black/60 text-indigo-300"
+            className="bottom-2 right-2 bg-black/60 text-accent-300"
             title={
               subscribeState === 'downloading' && downloadPercentage != null
                 ? `Downloading... ${downloadPercentage}%`
@@ -113,7 +112,7 @@ export default function WorkshopCard({
           {fileSizeLabel ? ` · ${fileSizeLabel}` : ''}
         </p>
         <div className="mt-2 flex items-center gap-1.5">
-          <LikeAction id={item.publishedFileId} isLiked={isLiked} />
+          <LikeAction id={item.publishedFileId} isLiked={steam.isLiked} />
           <SteamAction id={item.publishedFileId} />
         </div>
       </div>
@@ -137,7 +136,7 @@ export default function WorkshopCard({
             <Clock size={14} />
           </div>
         ) : subscribeState === 'subscribing' ? (
-          <div className={`${STATUS_CLASS} bg-black/60 text-indigo-300`} title="Subscribing...">
+          <div className={`${STATUS_CLASS} bg-black/60 text-accent-300`} title="Subscribing...">
             <Loader2 size={14} className="animate-spin" />
           </div>
         ) : subscribeState === 'subscribe-error' ? (
@@ -151,7 +150,7 @@ export default function WorkshopCard({
         ) : (
           <button
             onClick={handleSubscribe}
-            className={`${STATUS_CLASS} bg-black/60 text-white opacity-0 transition-opacity hover:bg-indigo-600 group-hover:opacity-100`}
+            className={`${STATUS_CLASS} bg-black/60 text-white opacity-0 transition-opacity hover:bg-accent-600 group-hover:opacity-100`}
           >
             <Download size={14} />
           </button>

+ 19 - 1
src/renderer/src/constants/engineFlags.ts

@@ -1,6 +1,6 @@
 import type { EngineFlags, FullscreenPauseMode } from '@shared/types'
 
-type ChoiceFlag = 'postProcessing' | 'volumetrics' | 'shadows' | 'msaa' | 'ssaa'
+type ChoiceFlag = 'postProcessing' | 'volumetrics' | 'shadows' | 'msaa' | 'ssaa' | 'hwdec'
 // kdeBackgroundLayer is a global desktop setting with its own toggle, wallpapers don't override it
 type BooleanFlag = Exclude<keyof EngineFlags, 'fullscreenPause' | 'kdeBackgroundLayer' | ChoiceFlag>
 
@@ -37,6 +37,8 @@ export const CHOICE_FLAGS: {
   key: ChoiceFlag
   label: string
   hint: string
+  /** Shown under the setting in Settings -> Performance */
+  note?: string
   fallback: string
   options: { value: string; label: string }[]
 }[] = [
@@ -87,5 +89,21 @@ export const CHOICE_FLAGS: {
       { value: 'x3', label: '3x' },
       { value: 'x4', label: '4x' }
     ]
+  },
+  {
+    key: 'hwdec',
+    label: 'Video decoding',
+    hint: 'How video wallpapers and videos inside scenes are decoded. Automatic picks a GPU decoder; if videos crash, stay black or stutter (some NVIDIA drivers, some Intel iGPUs), try Software or a copy mode',
+    note: 'Only change this if videos misbehave. With the proprietary NVIDIA driver, Automatic can pick a decoder that is broken there (e.g. VA-API through nvidia-vaapi-driver), so videos crash, stay black or show green frames: try NVDEC (copy). Copy modes pass frames through system memory, a bit more CPU but they avoid most driver bugs. Software always works but decodes on the CPU. Applies to running wallpapers right away.',
+    fallback: 'auto',
+    options: [
+      { value: 'auto', label: 'Automatic' },
+      { value: 'no', label: 'Software' },
+      { value: 'vaapi', label: 'VA-API' },
+      { value: 'vaapi-copy', label: 'VA-API (copy)' },
+      { value: 'nvdec', label: 'NVDEC' },
+      { value: 'nvdec-copy', label: 'NVDEC (copy)' },
+      { value: 'vulkan', label: 'Vulkan' }
+    ]
   }
 ]

+ 71 - 0
src/renderer/src/hooks/useCardBorders.ts

@@ -0,0 +1,71 @@
+import { useCallback } from 'react'
+import { useQuery } from '@tanstack/react-query'
+import { DEFAULT_CARD_BORDERS, type CardBorderKind, type CardBorders } from '@shared/cardBorders'
+import { useConfig } from './queries'
+import { useDislikedIds, useVotedIds } from './useVotes'
+import { useFavoriteIds, useFavoriteStatus } from './useFavorites'
+
+export function useCardBorders(): CardBorders {
+  return useConfig()?.cardBorders ?? DEFAULT_CARD_BORDERS
+}
+
+export function useFailedVotes(): Record<string, string> {
+  const { data } = useQuery({
+    queryKey: ['steam-failed-votes'],
+    queryFn: () => window.electronAPI.steam.getFailedVotes()
+  })
+  return data ?? {}
+}
+
+export interface CardSteamState {
+  isLiked: boolean
+  isDisliked: boolean
+  isFavorite: boolean
+  voteError?: string
+  favoriteError?: string
+}
+
+export function useCardSteamState(): (id: string) => CardSteamState {
+  const liked = useVotedIds()
+  const disliked = useDislikedIds()
+  const favorites = useFavoriteIds()
+  const failedVotes = useFailedVotes()
+  const favoriteStatus = useFavoriteStatus()
+  return useCallback(
+    (id: string) => ({
+      isLiked: liked.has(id),
+      isDisliked: disliked.has(id),
+      isFavorite: favorites.has(id),
+      voteError: failedVotes[id],
+      favoriteError: favoriteStatus.failed[id]?.message
+    }),
+    [liked, disliked, favorites, failedVotes, favoriteStatus]
+  )
+}
+
+export interface CardFrame {
+  kind: CardBorderKind
+  color: string
+}
+
+// vote frame + favorite frame, a failed change replaces its state
+export function cardFrames(borders: CardBorders, state: CardSteamState): { frames: CardFrame[]; title?: string } {
+  const frames: CardFrame[] = []
+  const errors: string[] = []
+  const add = (kind: CardBorderKind): void => {
+    if (borders[kind].enabled) frames.push({ kind, color: borders[kind].color })
+  }
+
+  if (state.voteError && borders.failed.enabled) {
+    add('failed')
+    errors.push(state.voteError)
+  } else if (state.isLiked) add('liked')
+  else if (state.isDisliked) add('disliked')
+
+  if (state.favoriteError && borders.failed.enabled) {
+    if (!frames.some((f) => f.kind === 'failed')) add('failed')
+    errors.push(state.favoriteError)
+  } else if (state.isFavorite) add('favorite')
+
+  return { frames, title: errors.length > 0 ? errors.join('\n') : undefined }
+}

+ 97 - 0
src/renderer/src/hooks/useFavorites.ts

@@ -0,0 +1,97 @@
+import { useCallback, useMemo, useState } from 'react'
+import { useQuery, useQueryClient } from '@tanstack/react-query'
+import type { FavoriteFailure, FavoriteStatus } from '@shared/types'
+import { useToast } from '../components/common/Toast'
+
+export const FAVORITE_IDS_KEY = ['steam-favorite-ids']
+export const FAVORITE_STATUS_KEY = ['steam-favorite-status']
+
+const NO_STATUS: FavoriteStatus = { failed: {}, checking: [] }
+
+export function useFavoriteStatus(): FavoriteStatus {
+  const { data } = useQuery({
+    queryKey: FAVORITE_STATUS_KEY,
+    queryFn: () => window.electronAPI.steam.getFavoriteStatus(),
+    staleTime: Infinity
+  })
+  return data ?? NO_STATUS
+}
+
+export function useItemFavoriteStatus(id: string): { failure: FavoriteFailure | undefined; checking: boolean } {
+  const status = useFavoriteStatus()
+  return { failure: status.failed[id], checking: status.checking.includes(id) }
+}
+
+export function useFavoriteIds(): Set<string> {
+  const { data } = useQuery({
+    queryKey: FAVORITE_IDS_KEY,
+    queryFn: () => window.electronAPI.steam.getFavoriteIds(),
+    staleTime: Infinity
+  })
+  return useMemo(() => new Set(data ?? []), [data])
+}
+
+function useRecordFavorites(): (ids: string[], add: boolean) => void {
+  const queryClient = useQueryClient()
+  return useCallback(
+    (ids: string[], add: boolean) => {
+      if (ids.length === 0) return
+      const changed = new Set(ids)
+      queryClient.setQueryData<string[]>(FAVORITE_IDS_KEY, (old = []) =>
+        add ? [...new Set([...old, ...ids])] : old.filter((id) => !changed.has(id))
+      )
+    },
+    [queryClient]
+  )
+}
+
+// failures go to onError, else a toast
+export function useFavoriteAction(onError?: (message: string) => void) {
+  const { showToast } = useToast()
+  const recordFavorites = useRecordFavorites()
+  const [pending, setPending] = useState(false)
+  const report = onError ?? ((message: string) => showToast(message, { warning: true }))
+
+  async function setFavorite(id: string, add: boolean): Promise<void> {
+    if (pending) return
+    setPending(true)
+    try {
+      const { confirmed } = await window.electronAPI.steam.favorite(id, add)
+      if (confirmed) recordFavorites([id], add)
+      else report('Could not confirm the favorite on Steam - try again')
+    } catch (err) {
+      report((err as Error).message)
+    } finally {
+      setPending(false)
+    }
+  }
+
+  return { setFavorite, isPending: pending }
+}
+
+// whole selection, one toast
+export function useBatchFavorite(): (ids: string[], add: boolean) => Promise<void> {
+  const { showToast } = useToast()
+  const recordFavorites = useRecordFavorites()
+
+  return async (ids: string[], add: boolean) => {
+    if (ids.length > 1) showToast(`${add ? 'Adding' : 'Removing'} ${ids.length} favorites on Steam...`)
+
+    const results = await Promise.allSettled(ids.map((id) => window.electronAPI.steam.favorite(id, add)))
+    const confirmedIds = ids.filter((_, i) => {
+      const r = results[i]
+      return r.status === 'fulfilled' && r.value.confirmed
+    })
+    recordFavorites(confirmedIds, add)
+
+    const failed = ids.length - confirmedIds.length
+    const done = add ? 'Added' : 'Removed'
+    const what = confirmedIds.length === 1 ? 'favorite' : 'favorites'
+    showToast(
+      failed === 0
+        ? `${done} ${confirmedIds.length} ${what} on Steam`
+        : `${done} ${confirmedIds.length} ${what}, ${failed} failed - their cards have a dashed border, right-click to try again`,
+      failed === 0 ? undefined : { warning: true, durationMs: 5000 }
+    )
+  }
+}

+ 0 - 18
src/renderer/src/hooks/useVoteBorders.ts

@@ -1,18 +0,0 @@
-import { useQuery } from '@tanstack/react-query'
-import { useConfig } from './queries'
-
-export function useVoteBorders(): { enabled: boolean; failed: Record<string, string> } {
-  const config = useConfig()
-  const { data: failed } = useQuery({
-    queryKey: ['steam-failed-votes'],
-    queryFn: () => window.electronAPI.steam.getFailedVotes()
-  })
-  return { enabled: config?.voteBorders ?? true, failed: failed ?? {} }
-}
-
-// an outline sits outside the selection ring, so both stay visible on a selected card
-export function voteBorderClass(voteError: string | undefined, isLiked: boolean): string | false {
-  if (voteError) return 'outline-2 outline-offset-2 outline-red-500'
-  if (isLiked) return 'outline-2 outline-offset-2 outline-green-500/70'
-  return false
-}

+ 21 - 8
src/renderer/src/hooks/useVotes.ts

@@ -3,6 +3,7 @@ import { useQuery, useQueryClient } from '@tanstack/react-query'
 import { useToast } from '../components/common/Toast'
 
 const VOTED_IDS_KEY = ['steam-voted-ids']
+export const DISLIKED_IDS_KEY = ['steam-disliked-ids']
 
 export function useVotedIds(): Set<string> {
   const { data } = useQuery({
@@ -13,17 +14,26 @@ export function useVotedIds(): Set<string> {
   return useMemo(() => new Set(data ?? []), [data])
 }
 
-// Writes confirmed votes into both the liked list and the per-item check the detail sidebar runs,
-// so every view agrees right away instead of waiting for the next background sync
+export function useDislikedIds(): Set<string> {
+  const { data } = useQuery({
+    queryKey: DISLIKED_IDS_KEY,
+    queryFn: () => window.electronAPI.steam.getDislikedIds(),
+    staleTime: Infinity
+  })
+  return useMemo(() => new Set(data ?? []), [data])
+}
+
+// updates every view right away instead of waiting for the next sync
 export function useRecordVotes(): (ids: string[], up: boolean) => void {
   const queryClient = useQueryClient()
   return useCallback(
     (ids: string[], up: boolean) => {
       if (ids.length === 0) return
       const changed = new Set(ids)
-      queryClient.setQueryData<string[]>(VOTED_IDS_KEY, (old = []) =>
-        up ? [...new Set([...old, ...ids])] : old.filter((id) => !changed.has(id))
-      )
+      const put = (old: string[] = []): string[] => [...new Set([...old, ...ids])]
+      const drop = (old: string[] = []): string[] => old.filter((id) => !changed.has(id))
+      queryClient.setQueryData<string[]>(VOTED_IDS_KEY, up ? put : drop)
+      queryClient.setQueryData<string[]>(DISLIKED_IDS_KEY, up ? drop : put)
       for (const id of ids) queryClient.setQueryData(['steam-vote', id], up)
     },
     [queryClient]
@@ -37,15 +47,17 @@ export function useVoteAction(onError?: (message: string) => void) {
   const [pending, setPending] = useState<'like' | 'dislike' | null>(null)
   const report = onError ?? showToast
 
-  async function vote(id: string, up: boolean): Promise<void> {
-    if (pending) return
+  async function vote(id: string, up: boolean): Promise<boolean> {
+    if (pending) return false
     setPending(up ? 'like' : 'dislike')
     try {
       const { confirmed } = await window.electronAPI.steam.vote(id, up)
       if (confirmed) recordVotes([id], up)
       else report(`Could not confirm the ${up ? 'like' : 'dislike'} on Steam - try again`)
+      return confirmed
     } catch (err) {
       report((err as Error).message)
+      return false
     } finally {
       setPending(null)
     }
@@ -74,7 +86,8 @@ export function useBatchVote(): (ids: string[], up: boolean) => Promise<void> {
     showToast(
       failed === 0
         ? `${done} ${confirmedIds.length} on Steam`
-        : `${done} ${confirmedIds.length}, ${failed} could not be confirmed`
+        : `${done} ${confirmedIds.length}, ${failed} failed - their cards have a dashed border, right-click to try again`,
+      failed === 0 ? undefined : { warning: true, durationMs: 5000 }
     )
   }
 }

+ 3 - 0
src/renderer/src/main.tsx

@@ -4,6 +4,9 @@ import { QueryClient, QueryClientProvider } from '@tanstack/react-query'
 import App from './App'
 import { ToastProvider } from './components/common/Toast'
 import './assets/index.css'
+import { applyCachedAppearance } from './utils/appearance'
+
+applyCachedAppearance()
 
 const queryClient = new QueryClient({
   defaultOptions: {

+ 44 - 0
src/renderer/src/utils/appearance.ts

@@ -0,0 +1,44 @@
+import { normalizeAppearance, type Appearance } from '@shared/appearance'
+
+const CACHE_KEY = 'appearance'
+
+const darkQuery = window.matchMedia('(prefers-color-scheme: dark)')
+
+function resolvedTheme(appearance: Appearance): 'dark' | 'light' {
+  if (appearance.theme === 'system') return darkQuery.matches ? 'dark' : 'light'
+  return appearance.theme
+}
+
+export function applyAppearance(appearance: Appearance, translucent: boolean): void {
+  const root = document.documentElement
+  root.dataset.theme = resolvedTheme(appearance)
+  root.style.setProperty('--accent-hue', String(appearance.accentHue))
+  root.style.setProperty('--accent-chroma', String(appearance.accentChroma))
+  if (translucent) {
+    root.dataset.translucent = ''
+    root.style.setProperty('--surface-alpha', String(appearance.windowOpacity / 100))
+  } else {
+    delete root.dataset.translucent
+    root.style.removeProperty('--surface-alpha')
+  }
+  try {
+    localStorage.setItem(CACHE_KEY, JSON.stringify({ appearance, translucent }))
+  } catch {
+    // storage unavailable
+  }
+}
+
+// config arrives after first paint, the cached look avoids a theme flash
+export function applyCachedAppearance(): void {
+  try {
+    const cached = JSON.parse(localStorage.getItem(CACHE_KEY) ?? 'null')
+    if (cached) applyAppearance(normalizeAppearance(cached.appearance), cached.translucent === true)
+  } catch {
+    // nothing cached
+  }
+}
+
+export function onSystemThemeChange(cb: () => void): () => void {
+  darkQuery.addEventListener('change', cb)
+  return () => darkQuery.removeEventListener('change', cb)
+}

+ 42 - 0
src/shared/appearance.test.ts

@@ -0,0 +1,42 @@
+import { describe, expect, it } from 'vitest'
+import { DEFAULT_APPEARANCE, launchAppearanceKey, normalizeAppearance, wantsBlur } from './appearance'
+
+describe('normalizeAppearance', () => {
+  it('fills defaults for a missing or partial value', () => {
+    expect(normalizeAppearance(undefined)).toEqual(DEFAULT_APPEARANCE)
+    expect(normalizeAppearance({ theme: 'light' })).toEqual({ ...DEFAULT_APPEARANCE, theme: 'light' })
+  })
+
+  it('clamps out of range numbers and drops unknown themes', () => {
+    const a = normalizeAppearance({
+      theme: 'neon' as never,
+      accentHue: 500,
+      accentChroma: -1,
+      windowOpacity: 3
+    })
+    expect(a).toEqual({
+      theme: 'dark',
+      accentHue: 360,
+      accentChroma: 0,
+      windowOpacity: 40,
+      blur: false,
+      previewAnimation: 'always'
+    })
+  })
+})
+
+describe('launchAppearanceKey', () => {
+  it('ignores what can change live', () => {
+    const base = normalizeAppearance({ windowOpacity: 80 })
+    expect(launchAppearanceKey({ ...base, windowOpacity: 60, accentHue: 10, theme: 'light' })).toBe(
+      launchAppearanceKey(base)
+    )
+  })
+
+  it('changes when the window has to become transparent or blurred', () => {
+    const opaque = normalizeAppearance({})
+    expect(launchAppearanceKey({ ...opaque, windowOpacity: 90 })).not.toBe(launchAppearanceKey(opaque))
+    expect(wantsBlur({ ...opaque, blur: true })).toBe(false)
+    expect(wantsBlur({ ...opaque, blur: true, windowOpacity: 90 })).toBe(true)
+  })
+})

+ 70 - 0
src/shared/appearance.ts

@@ -0,0 +1,70 @@
+export type ThemeMode = 'dark' | 'light' | 'system'
+/** 'hover' keeps GIF previews still until hovered */
+export type PreviewAnimation = 'always' | 'hover'
+
+export interface Appearance {
+  theme: ThemeMode
+  /** oklch hue */
+  accentHue: number
+  /** 0 = gray (Graphite) */
+  accentChroma: number
+  /** 100 = opaque, lower needs a restart */
+  windowOpacity: number
+  /** KDE blur, via XWayland on Wayland */
+  blur: boolean
+  previewAnimation: PreviewAnimation
+}
+
+export const DEFAULT_APPEARANCE: Appearance = {
+  theme: 'dark',
+  accentHue: 277,
+  accentChroma: 1,
+  windowOpacity: 100,
+  blur: false,
+  previewAnimation: 'always'
+}
+
+export const ACCENT_PRESETS: { name: string; hue: number; chroma: number }[] = [
+  { name: 'Indigo', hue: 277, chroma: 1 },
+  { name: 'Blue', hue: 255, chroma: 1 },
+  { name: 'Sky', hue: 232, chroma: 0.8 },
+  { name: 'Teal', hue: 185, chroma: 0.6 },
+  { name: 'Emerald', hue: 160, chroma: 0.7 },
+  { name: 'Amber', hue: 65, chroma: 0.75 },
+  { name: 'Orange', hue: 45, chroma: 0.85 },
+  { name: 'Rose', hue: 15, chroma: 0.95 },
+  { name: 'Pink', hue: 350, chroma: 0.95 },
+  { name: 'Purple', hue: 305, chroma: 1 },
+  { name: 'Graphite', hue: 277, chroma: 0 }
+]
+
+export const MIN_WINDOW_OPACITY = 40
+
+function clamp(value: unknown, min: number, max: number, fallback: number): number {
+  return typeof value === 'number' && Number.isFinite(value) ? Math.min(max, Math.max(min, value)) : fallback
+}
+
+export function normalizeAppearance(raw: Partial<Appearance> | undefined): Appearance {
+  const theme = raw?.theme === 'light' || raw?.theme === 'system' ? raw.theme : 'dark'
+  return {
+    theme,
+    accentHue: clamp(raw?.accentHue, 0, 360, DEFAULT_APPEARANCE.accentHue),
+    accentChroma: clamp(raw?.accentChroma, 0, 1, DEFAULT_APPEARANCE.accentChroma),
+    windowOpacity: Math.round(clamp(raw?.windowOpacity, MIN_WINDOW_OPACITY, 100, 100)),
+    blur: raw?.blur === true,
+    previewAnimation: raw?.previewAnimation === 'hover' ? 'hover' : 'always'
+  }
+}
+
+export function isTranslucent(appearance: Appearance): boolean {
+  return appearance.windowOpacity < 100
+}
+
+export function wantsBlur(appearance: Appearance): boolean {
+  return isTranslucent(appearance) && appearance.blur
+}
+
+/** Fixed at window creation */
+export function launchAppearanceKey(appearance: Appearance): string {
+  return `${isTranslucent(appearance)}:${wantsBlur(appearance)}`
+}

+ 22 - 0
src/shared/cardBorders.test.ts

@@ -0,0 +1,22 @@
+import { describe, expect, it } from 'vitest'
+import { DEFAULT_CARD_BORDERS, normalizeCardBorders } from './cardBorders'
+
+describe('normalizeCardBorders', () => {
+  it('fills in defaults', () => {
+    expect(normalizeCardBorders(undefined)).toEqual(DEFAULT_CARD_BORDERS)
+    expect(normalizeCardBorders({ liked: { enabled: false } }).liked).toEqual({ enabled: false, color: '#22c55e' })
+  })
+
+  it('rejects colors that are not 6-digit hex', () => {
+    expect(normalizeCardBorders({ favorite: { color: 'red' } }).favorite.color).toBe('#ec4899')
+    expect(normalizeCardBorders({ favorite: { color: '#AABBCC' } }).favorite.color).toBe('#aabbcc')
+  })
+
+  it('carries over the old like-borders switch until borders are saved', () => {
+    const migrated = normalizeCardBorders(undefined, false)
+    expect(migrated.liked.enabled).toBe(false)
+    expect(migrated.failed.enabled).toBe(false)
+    expect(migrated.disliked.enabled).toBe(true)
+    expect(normalizeCardBorders({}, false).liked.enabled).toBe(true)
+  })
+})

+ 36 - 0
src/shared/cardBorders.ts

@@ -0,0 +1,36 @@
+
+export type CardBorderKind = 'liked' | 'disliked' | 'favorite' | 'failed'
+
+export interface CardBorder {
+  enabled: boolean
+  color: string
+}
+
+export type CardBorders = Record<CardBorderKind, CardBorder>
+
+export const CARD_BORDER_KINDS: CardBorderKind[] = ['liked', 'disliked', 'favorite', 'failed']
+
+export const DEFAULT_CARD_BORDERS: CardBorders = {
+  liked: { enabled: true, color: '#22c55e' },
+  disliked: { enabled: true, color: '#ef4444' },
+  favorite: { enabled: true, color: '#ec4899' },
+  failed: { enabled: true, color: '#f59e0b' }
+}
+
+const HEX_COLOR = /^#[0-9a-f]{6}$/i
+
+// legacyVoteBorders covered liked and failed
+export function normalizeCardBorders(value: unknown, legacyVoteBorders = true): CardBorders {
+  const raw = (value && typeof value === 'object' ? value : {}) as Partial<Record<CardBorderKind, Partial<CardBorder>>>
+  const out = {} as CardBorders
+  for (const kind of CARD_BORDER_KINDS) {
+    const fallback = DEFAULT_CARD_BORDERS[kind]
+    const entry = raw[kind] ?? {}
+    const legacyOff = value == null && !legacyVoteBorders && (kind === 'liked' || kind === 'failed')
+    out[kind] = {
+      enabled: typeof entry.enabled === 'boolean' ? entry.enabled : !legacyOff && fallback.enabled,
+      color: typeof entry.color === 'string' && HEX_COLOR.test(entry.color) ? entry.color.toLowerCase() : fallback.color
+    }
+  }
+  return out
+}

+ 2 - 0
src/shared/engineFlags.test.ts

@@ -32,6 +32,8 @@ describe('engineFlagArgs', () => {
     expect(engineFlagArgs({ msaa: 'none' })).toEqual([])
     expect(engineFlagArgs({ ssaa: 'x2' })).toEqual(['--ssaa', 'x2'])
     expect(engineFlagArgs({ ssaa: 'none' })).toEqual([])
+    expect(engineFlagArgs({ hwdec: 'nvdec-copy' })).toEqual(['--hwdec', 'nvdec-copy'])
+    expect(engineFlagArgs({ hwdec: 'auto' })).toEqual([])
     expect(engineFlagArgs({ kdeBackgroundLayer: true })).toEqual(['--layer', 'background'])
     expect(engineFlagArgs({ kdeBackgroundLayer: false })).toEqual([])
   })

+ 1 - 0
src/shared/engineFlags.ts

@@ -67,6 +67,7 @@ export function engineFlagArgs(flags: EngineFlags): string[] {
   if (flags.shadows && flags.shadows !== 'medium') args.push('--shadows', flags.shadows)
   if (flags.msaa && flags.msaa !== 'none') args.push('--msaa', flags.msaa)
   if (flags.ssaa && flags.ssaa !== 'none') args.push('--ssaa', flags.ssaa)
+  if (flags.hwdec && flags.hwdec !== 'auto') args.push('--hwdec', flags.hwdec)
   if (flags.kdeBackgroundLayer) args.push('--layer', 'background')
   return args
 }

+ 9 - 1
src/shared/ipc-channels.ts

@@ -13,8 +13,12 @@ export const IpcChannels = {
   STEAM_VOTE: 'steam:vote',
   STEAM_OPEN_WORKSHOP: 'steam:open-workshop',
   STEAM_GET_VOTED_IDS: 'steam:get-voted-ids',
+  STEAM_GET_DISLIKED_IDS: 'steam:get-disliked-ids',
   STEAM_GET_FAILED_VOTES: 'steam:get-failed-votes',
   STEAM_CHECK_VOTE: 'steam:check-vote',
+  STEAM_FAVORITE: 'steam:favorite',
+  STEAM_GET_FAVORITE_IDS: 'steam:get-favorite-ids',
+  STEAM_GET_FAVORITE_STATUS: 'steam:get-favorite-status',
   STEAM_REDOWNLOAD: 'steam:redownload',
   STEAM_GET_AUTHOR_INFO: 'steam:get-author-info',
 
@@ -109,7 +113,8 @@ export const IpcChannels = {
   // Tray & autostart
   CONFIG_SET_TRAY_ENABLED: 'config:set-tray-enabled',
   CONFIG_SET_KILL_LWE_ON_QUIT: 'config:set-kill-lwe-on-quit',
-  CONFIG_SET_VOTE_BORDERS: 'config:set-vote-borders',
+  CONFIG_SET_CARD_BORDERS: 'config:set-card-borders',
+  CONFIG_SET_APPEARANCE: 'config:set-appearance',
   CONFIG_SET_AUTOSTART: 'config:set-autostart',
   CONFIG_GET_AUTOSTART_SUPPORTED: 'config:get-autostart-supported',
 
@@ -151,7 +156,10 @@ export const IpcChannels = {
   EVENT_BACKUP_PROGRESS: 'event:backup-progress',
   EVENT_PLAYLIST_STATE_CHANGED: 'event:playlist-state-changed',
   EVENT_VOTED_IDS_CHANGED: 'event:voted-ids-changed',
+  EVENT_DISLIKED_IDS_CHANGED: 'event:disliked-ids-changed',
   EVENT_FAILED_VOTES_CHANGED: 'event:failed-votes-changed',
+  EVENT_FAVORITE_IDS_CHANGED: 'event:favorite-ids-changed',
+  EVENT_FAVORITE_STATUS_CHANGED: 'event:favorite-status-changed',
   EVENT_LIBRARY_CHANGED: 'event:library-changed',
   EVENT_DISPLAY_CHANGED: 'event:display-changed',
   EVENT_WALLPAPER_CRASHED: 'event:wallpaper-crashed',

+ 16 - 0
src/shared/types.ts

@@ -162,6 +162,8 @@ export type MsaaQuality = 'none' | 'x2' | 'x4' | 'x8'
 /** Scene supersampling factor per axis, linux-wallpaperengine only */
 export type SsaaQuality = 'none' | 'x2' | 'x3' | 'x4'
 
+export type HwdecBackend = 'auto' | 'no' | 'vaapi' | 'vaapi-copy' | 'nvdec' | 'nvdec-copy' | 'vulkan'
+
 /** linux-wallpaperengine flags that only take effect on a fresh launch */
 export interface EngineFlags {
   disableParticles?: boolean
@@ -177,6 +179,7 @@ export interface EngineFlags {
   shadows?: LightingQuality
   msaa?: MsaaQuality
   ssaa?: SsaaQuality
+  hwdec?: HwdecBackend
   /** --layer background (plasmashell's desktop can cover the wallpaper on KDE, niri needs it); key kept for stored configs */
   kdeBackgroundLayer?: boolean
 }
@@ -357,6 +360,19 @@ export interface ApplyWallpaperOptions {
   backend?: WallpaperBackend
 }
 
+// write failed, or Steam's favorites list never showed it
+export interface FavoriteFailure {
+  add: boolean
+  message: string
+  readBack: boolean
+}
+
+export interface FavoriteStatus {
+  failed: Record<string, FavoriteFailure>
+  // written, not yet in the favorites list
+  checking: string[]
+}
+
 export interface DownloadProgressEvent {
   itemId: string
   bytesDownloaded: number