
/* =========================================
   SHRINEFORSOULS — CHARCOAL THEME TEST
   Active on Index and Explore only
========================================= */

:root {
    --site-background: #181818;
    --panel-background: #262626;

    --text-color: #c5c1ba;
    --soft-text: #a3a3a3;

    --accent-color: #aaaaaa;
    --border-color: #414141;

    --site-header-background: #1d1d1d;
    --site-header-text: #c5c1ba;
    --site-header-soft: #969696;
    --site-header-accent: #b5b5b5;
    --site-header-border: #383838;
}

/* PAGE */

body {
    background-color: var(--site-background);
    color: var(--text-color);
}

/* HEADER */

header,
.top-bar {
    background-color: var(--site-header-background);
    border-bottom: 1px solid var(--site-header-border);
}

.logo,
.site-logo,
nav a,
.top-navigation a {
    color: var(--site-header-text);
}

nav a:hover,
.top-navigation a:hover {
    color: var(--site-header-accent);
}

/* SEARCH */

.top-search-input {
    background-color: #242424;
    border-color: var(--site-header-border);
    color: var(--site-header-text);
}

.top-search-input::placeholder {
    color: var(--site-header-soft);
}

.top-search-input:focus {
    border-color: var(--site-header-accent);
}

/* INDEX */

.small-title {
    color: var(--accent-color);
}

.description,
.bottom-message {
    color: var(--soft-text);
}

.create-account {
    background-color: var(--accent-color);
    border-color: var(--accent-color);
    color: #181818;
}

.create-account:hover {
    background-color: #b6b6b6;
    border-color: #b6b6b6;
}

.hero-navigation-button {
    border-color: var(--border-color);
    color: var(--text-color);
}

.hero-navigation-button:hover {
    background-color: var(--panel-background);
    border-color: var(--accent-color);
    color: var(--text-color);
}

/* EXPLORE */

.explore-page .story-cover {
    background-color: #222222;
}

.explore-page .profile-avatar {
    color: #181818;
}

/* =========================================
   MIDNIGHT SHRINE — HOME
========================================= */

/* Reading cover placeholders */

.reading-cover {
    background-color: #222222;
}

/* Reading progress */

.reading-progress-track {
    background-color: #383838;
}

/* Action buttons */

.continue-button,
.browse-genre-button,
.following-update-button {
    color: #181818;
}

/* New Souls avatars */

.home-soul-avatar {
    color: #181818;
}

/* =========================================
   MIDNIGHT SHRINE — SHARED INTERFACE
   Account, Administration, Create Story/Post
========================================= */

:root {
    --interface-input-background: #202020;
    --interface-subpanel-background: #222222;
    --input-background: #202020;
}

/* Consistent navigation background */

.top-bar {
    background-color: var(--site-header-background);
}

/* =========================================
   ADMIN THEME PRESETS
   Editor interface only
========================================= */

.preset-row {
    background-color: #202020;
}

.preview-note {
    background-color: #222222;
}

/* Admin preset list and editor scrollbars */

.list,
.preset-editor-panel {
    scrollbar-color: #aaaaaa #181818;
}

.list::-webkit-scrollbar-track,
.preset-editor-panel::-webkit-scrollbar-track {
    background: #181818;
}

.list::-webkit-scrollbar-thumb,
.preset-editor-panel::-webkit-scrollbar-thumb {
    background: #aaaaaa;
    border: 2px solid #181818;
}

.list::-webkit-scrollbar-thumb:hover,
.preset-editor-panel::-webkit-scrollbar-thumb:hover {
    background: #c5c1ba;
}

/* =========================================
   CREATE POST — EDITOR INTERFACE
========================================= */

/* Keep media editing controls neutral */

.shrine-media-resize-handle,
.shrine-media-runtime-ui {
    background: rgba(24, 24, 24, 0.96);
}

/* =========================================
   MIDNIGHT SHRINE — POST TEXT BLOCKS
   Default editor colors
========================================= */


/* Quill placeholder */

#blocksContainer .ql-editor.ql-blank::before {
    color: #a3a3a3;
    opacity: 0.85;
}

/* =========================================
   MIDNIGHT — AUTOMATIC POST BLOCK COLORS
========================================= */

:root {
    --sfs-auto-post-block-background: #262626;
    --sfs-auto-post-block-text: #c5c1ba;
}

/* =========================================
   MIDNIGHT SHRINE — LEGACY PAGE VARIABLES
   Supports older variable names.
========================================= */

:root {
    --background: var(--site-background);
    --panel: var(--panel-background);
    --text: var(--text-color);
    --accent: var(--accent-color);
    --border: var(--border-color);

    --subpanel-background: #222222;
    --input-background: #202020;
}

/* =========================================
   MIDNIGHT — ACCOUNT & MANAGEMENT BUTTONS
========================================= */

.recovery-button,
.login-button,
.create-button {
    color: #181818;
}

/* =========================================
   MIDNIGHT — MESSAGES
========================================= */

.new-message-suggestion:hover,
.new-message-suggestion:focus-visible {
    background-color: rgba(170, 170, 170, 0.14);
}

/* =========================================
   MIDNIGHT — CUSTOMIZE INTERFACE ONLY
========================================= */

.settings-panel .media-button.secondary {
    background-color: #202020;
    color: var(--accent-color);
}

/* =========================================
   MIDNIGHT — REMAINING SITE INTERFACES
========================================= */

:root {
    --site-text: #c5c1ba;
    --muted: #a3a3a3;
}

/* Authentication buttons */

.reset-button {
    color: #181818;
}

/* Email confirmation header */

.top-bar {
    background-color: var(--site-header-background);
}

/* Story details: rich summary editor */

#storySummaryToolbar,
#storySummaryToolbar .ql-picker-options {
    background-color: var(--interface-subpanel-background);
}

#storySummaryEditor.ql-container {
    background-color: var(--interface-input-background);
}

/* Midnight profile card fallback:
   Custom member card colors retain priority. */

.sfs-profile-page .content-card,
.sfs-profile-page .bookmark-collection-card,
.sfs-profile-page .posts-status-summary,
.sfs-profile-page .post-profile-card,
.sfs-profile-page .story-profile-card {
    background-color: var(
        --user-card-background,
        color-mix(
            in srgb,
            var(--surface-color) 90%,
            white 10%
        )
    );
}

/* =========================================
   MIDNIGHT — PRESERVE AUTHOR READER THEMES
========================================= */

body.sfs-reader-page {
    background-color: var(--reader-background);
    color: var(--reader-text);
}

/* =========================================
   MIDNIGHT — NOTIFICATIONS
========================================= */

body.sfs-notifications-page {
    --background-color: #181818;
    --surface-color: #262626;
    --surface-soft: #222222;
    --accent-soft: rgba(170, 170, 170, 0.13);
}

/* =========================================
   MIDNIGHT — AUTOMATIC PART BLOCK COLORS
========================================= */

:root {
    --sfs-auto-part-block-background: #262626;
    --sfs-auto-part-block-text: #c5c1ba;
}

/* =========================================
   MIDNIGHT SHRINE
   POINT 26 — MESSAGES THEME
========================================= */

/*
   Match the charcoal Midnight theme.
   These rules affect Messages only.
*/


/* =====================================
   THREE-COLUMN MESSENGER
===================================== */

.messages-shell {
    background:
        var(--panel-background);
}

.messages-shell .shrine-message-rail {
    background:
        var(--site-header-background);
}

.messages-shell .conversation-sidebar {
    background:
        var(--interface-subpanel-background);
}

.messages-shell .conversation-discovery-tools {
    background:
        var(--interface-subpanel-background);
}

.messages-shell .conversation-search-input {
    background:
        var(--interface-input-background);

    color:
        var(--text-color);
}


/* =====================================
   CONVERSATION LIST
===================================== */

.messages-shell .conversation-item {
    background:
        transparent;
}

.messages-shell .conversation-item:hover {
    background:
        #303030;
}

.messages-shell .conversation-item.active {
    background:
        #343434;
}

.messages-shell
.conversation-filter-button.active {
    background:
        #343434;

    border-color:
        var(--border-color);
}


/* =====================================
   CHAT AREA
===================================== */

.messages-shell .thread-panel,
.messages-shell .thread-content,
.messages-shell .group-thread {
    background:
        var(--panel-background);
}

.messages-shell .thread-header {
    background:
        var(--interface-subpanel-background);

    border-bottom-color:
        var(--border-color);
}


/* =====================================
   RECEIVED MESSAGES
===================================== */

.messages-shell
.message-row.theirs
.message-bubble {
    background:
        var(--interface-subpanel-background);

    border-color:
        var(--border-color);
}


/* =====================================
   SENT MESSAGES
===================================== */

.messages-shell
.message-row.mine
.message-bubble {
    background:
        #343434;

    border-color:
        #505050;
}


/* =====================================
   MESSAGE TEXT
===================================== */

.messages-shell .message-text {
    color:
        var(--text-color);
}

/*
   Formatted messages use the normal
   ShrineForSouls typography unless
   their author selected another font.
*/

.messages-shell
.message-text.shrine-formatted-message {
    font-family:
        inherit;
}


/* =====================================
   MESSAGE COMPOSER
===================================== */

.messages-shell .message-composer {
    background:
        var(--panel-background);
}

.messages-shell .message-input {
    background:
        var(--interface-input-background);

    color:
        var(--text-color);
}


/* =====================================
   NOOKS
===================================== */

.messages-shell .shrine-nooks-panel {
    background:
        var(--panel-background);
}

.messages-shell .nook-toolbar {
    background:
        var(--interface-subpanel-background);
}


/* =====================================
   NEW MESSAGE BUTTON
===================================== */

.messages-shell
.shrine-message-rail
#newMessageButton {
    background:
        var(--accent-color);

    color:
        var(--site-background);
}

.messages-shell
.shrine-message-rail
#newMessageButton:hover {
    background:
        #c5c1ba;

    color:
        var(--site-background);
}

/* =========================================
   MIDNIGHT SHRINE
   POINT 26R — NOOK SCROLLBAR FIX
   MATCH GROUP CHAT
========================================= */

/* Main Nooks scrollbar */

#groupThread.nooks-open
#shrineGroupNooks {

    scrollbar-width: thin !important;

    scrollbar-color:
        var(--border-color)
        var(--site-background) !important;

}


/* Scrollbar dimensions */

#groupThread.nooks-open
#shrineGroupNooks::-webkit-scrollbar {

    width: 9px;
    height: 9px;

}


/* Dark scrollbar track */

#groupThread.nooks-open
#shrineGroupNooks::-webkit-scrollbar-track {

    background: var(--site-background);
    border-radius: 999px;

}


/* Subtle scrollbar thumb */

#groupThread.nooks-open
#shrineGroupNooks::-webkit-scrollbar-thumb {

    background: var(--border-color);

    border: 2px solid var(--site-background);
    border-radius: 999px;

}


/* Hover */

#groupThread.nooks-open
#shrineGroupNooks::-webkit-scrollbar-thumb:hover {

    background: var(--soft-text);

}

/* =========================================
   SHRINEFORSOULS
   MIDNIGHT — LIBRARY
========================================= */

body.sfs-library-page {
    --library-background: #181818;
    --library-panel: #262626;
    --library-panel-dark: #202020;

    --library-text: #c5c1ba;
    --library-muted: #a3a3a3;
    --library-accent: #aaaaaa;

    --library-border: #414141;
    --library-border-soft: #383838;

    --library-shelf-top: #505050;
    --library-shelf-middle: #343434;
    --library-shelf-bottom: #242424;
}