/* ==========================================================================
   PARIKSHAGYAN BOOKMARKS SYSTEM STYLES
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. CHAPTER PAGE: BOOKMARK BUTTON & WRAPPER
   -------------------------------------------------------------------------- */
.pg-bookmark-wrap {
    position: absolute;
    top: 14px;
    right: 18px;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    margin: 0 0 12px;
}

.pg-bookmark-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 32px;
    padding: 0 12px;
    border: 1px solid #d8dee4;
    border-radius: 999px;
    background: #ffffff;
    color: #374151;
    font-family: inherit;
    font-size: 12px;
    font-weight: 600;
    line-height: 1;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.08);
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.pg-bookmark-btn .pg-bm-icon {
    display: inline-block;
    flex-shrink: 0;
    transition: fill 0.2s ease, stroke 0.2s ease, transform 0.2s ease;
    fill: none;
    stroke: currentColor;
}

.pg-bookmark-btn:hover {
    background: #f8fafc;
    color: #1f2937;
    border-color: #cbd5e1;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.08);
}

.pg-bookmark-btn:hover .pg-bm-icon {
    stroke: #d97706;
}

.pg-bookmark-btn:active {
    transform: scale(0.95);
    background: #f1f5f9;
}

.pg-bookmark-btn:focus-visible {
    outline: 2px solid #d97706;
    outline-offset: 2px;
}

/* Bookmarked (Active) State */
.pg-bookmark-btn.is-bookmarked {
    background: #fffbeb;
    color: #b45309;
    border-color: #fcd34d;
    box-shadow: 0 2px 8px rgba(217, 119, 6, 0.15);
}

.pg-bookmark-btn.is-bookmarked .pg-bm-icon {
    fill: #d97706;
    stroke: #d97706;
}

.pg-bookmark-btn.is-bookmarked:hover {
    background: #fef3c7;
    color: #92400e;
    border-color: #f59e0b;
    transform: translateY(-1px);
}

.pg-bookmark-btn.is-bookmarked:active {
    transform: scale(0.95);
    background: #fde68a;
}

/* --------------------------------------------------------------------------
   2. TOAST NOTIFICATION (CENTER POPUP)
   -------------------------------------------------------------------------- */
.pg-bm-toast {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.85);
    z-index: 999999;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 14px 22px;
    min-width: 220px;
    max-width: min(420px, 90vw);
    border-radius: 14px;
    background: rgba(17, 24, 39, 0.94);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    color: #f9fafb;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.4;
    text-align: center;
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.35), 0 4px 14px rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.14);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.28s cubic-bezier(0.16, 1, 0.3, 1), transform 0.28s cubic-bezier(0.16, 1, 0.3, 1);
    box-sizing: border-box;
}

.pg-bm-toast.is-visible {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
    pointer-events: auto;
}

.pg-bm-toast .pg-bm-toast-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fbbf24;
    flex-shrink: 0;
}

.pg-bm-toast .pg-bm-toast-btn {
    display: inline-flex;
    align-items: center;
    padding: 6px 14px;
    margin-left: 4px;
    background: #2563eb;
    color: #ffffff;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 700;
    text-decoration: none;
    flex-shrink: 0;
    transition: background-color 0.2s ease, transform 0.2s ease;
}

.pg-bm-toast .pg-bm-toast-btn:hover {
    background: #1d4ed8;
    transform: translateY(-1px);
}

/* --------------------------------------------------------------------------
   3. /my-bookmarks/ PAGE CONTAINER & HEADER (SPACE & COLOR OPTIMIZED)
   -------------------------------------------------------------------------- */
body:has(#pgBookmarksContainer),
body:has(.pg-bookmarks-container),
body.pg-bookmarks-page,
body.page-id-3089 {
    padding-top: 72px !important;
    background-color: #f7ede0 !important;
    background-image: url('../../../uploads/bookmark-background.webp') !important;
    background-repeat: no-repeat !important;
    background-position: center top !important;
    background-size: cover !important;
    background-attachment: fixed !important;
    min-height: 100vh !important;
    overflow-x: hidden !important;
}

body:has(#pgBookmarksContainer) .wp-site-blocks,
body:has(#pgBookmarksContainer) .site,
body:has(#pgBookmarksContainer) .site-content,
body:has(#pgBookmarksContainer) main,
body:has(#pgBookmarksContainer) main.wp-block-group,
body:has(#pgBookmarksContainer) .wp-block-group,
body:has(#pgBookmarksContainer) .wp-block-group.alignfull,
body:has(#pgBookmarksContainer) .wp-block-post-content,
body:has(#pgBookmarksContainer) .entry-content,
body:has(.pg-bookmarks-container) .wp-site-blocks,
body:has(.pg-bookmarks-container) .site,
body:has(.pg-bookmarks-container) .site-content,
body:has(.pg-bookmarks-container) main,
body:has(.pg-bookmarks-container) main.wp-block-group,
body:has(.pg-bookmarks-container) .wp-block-group,
body:has(.pg-bookmarks-container) .wp-block-group.alignfull,
body:has(.pg-bookmarks-container) .wp-block-post-content,
body:has(.pg-bookmarks-container) .entry-content,
body.pg-bookmarks-page .wp-site-blocks,
body.pg-bookmarks-page .site,
body.pg-bookmarks-page .site-content,
body.pg-bookmarks-page main,
body.pg-bookmarks-page main.wp-block-group,
body.pg-bookmarks-page .wp-block-group,
body.pg-bookmarks-page .wp-block-group.alignfull,
body.pg-bookmarks-page .wp-block-post-content,
body.pg-bookmarks-page .entry-content,
body.page-id-3089 .wp-site-blocks,
body.page-id-3089 main.wp-block-group,
body.page-id-3089 .wp-block-group.alignfull,
body.page-id-3089 .wp-block-post-content,
body.page-id-3089 .entry-content {
    margin-top: 0 !important;
    padding-top: 0 !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

body:has(#pgBookmarksContainer) .wp-block-post-title,
body:has(.pg-bookmarks-container) .wp-block-post-title,
body.pg-bookmarks-page .wp-block-post-title,
body.page-id-3089 .wp-block-post-title {
    display: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

body:has(#pgBookmarksContainer) .wp-block-post-content > *:first-child,
body:has(#pgBookmarksContainer) .entry-content > *:first-child,
body:has(.pg-bookmarks-container) .wp-block-post-content > *:first-child,
body:has(.pg-bookmarks-container) .entry-content > *:first-child,
body.pg-bookmarks-page .wp-block-post-content > *:first-child,
body.pg-bookmarks-page .entry-content > *:first-child {
    margin-top: 0 !important;
}

.pg-bookmarks-container {
    max-width: 1100px;
    margin: 0 auto 50px !important;
    padding: 10px 20px 0 !important;
    box-sizing: border-box;
    font-family: "Poppins", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.pg-bookmarks-container * {
    font-family: "Poppins", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.pg-bm-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    margin-top: 0 !important;
    margin-bottom: 16px;
    padding-top: 0 !important;
    padding-bottom: 14px;
    border-bottom: 1px solid #e6dac8;
}

.pg-bm-title-group {
    flex: 1;
}

.pg-bm-title-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 4px;
}

.pg-bm-title {
    font-family: "Poppins", system-ui, sans-serif !important;
    font-size: 26px;
    font-weight: 700;
    color: #2c1a10;
    margin: 0;
    letter-spacing: -0.3px;
    line-height: 1.2;
}

.pg-bm-counter {
    font-family: "Poppins", system-ui, sans-serif !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 22px;
    height: 22px;
    padding: 0 8px;
    border-radius: 999px;
    background: #fef3c7;
    color: #92400e;
    font-size: 11.5px;
    font-weight: 700;
    border: 1px solid #fde68a;
}

.pg-bm-subtitle {
    font-family: "Poppins", system-ui, sans-serif !important;
    margin: 0;
    font-size: 13.5px;
    color: #6b5d52;
    line-height: 1.4;
}

.pg-bm-search-wrap {
    position: relative;
    width: 260px;
    flex-shrink: 0;
}

.pg-bm-search-icon {
    position: absolute;
    top: 50%;
    left: 12px;
    transform: translateY(-50%);
    color: #a89f91;
    pointer-events: none;
}

.pg-bm-search-input {
    font-family: "Poppins", system-ui, sans-serif !important;
    width: 100%;
    height: 38px;
    padding: 0 14px 0 36px;
    border: 1px solid #e6dac8;
    border-radius: 999px;
    background: #ffffff;
    color: #2c1a10;
    font-size: 13.5px;
    outline: none;
    box-sizing: border-box;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.pg-bm-search-input:focus {
    border-color: #8d3408;
    box-shadow: 0 0 0 3px rgba(141, 52, 8, 0.12);
}

.pg-bm-search-input::placeholder {
    color: #a89f91;
}

/* --------------------------------------------------------------------------
   4. SUBJECT FILTER PILLS
   -------------------------------------------------------------------------- */
.pg-bm-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 22px;
}

.pg-bm-filter-btn {
    padding: 6px 14px;
    border: 1px solid #e6dac8;
    border-radius: 999px;
    background: #ffffff;
    color: #57534e;
    font-size: 12.5px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    user-select: none;
}

.pg-bm-filter-btn:hover {
    background: #fdfaf6;
    color: #2c1a10;
    border-color: #d7c5ad;
}

.pg-bm-filter-btn.is-active {
    background: #8d3408;
    color: #ffffff;
    border-color: #8d3408;
    box-shadow: 0 3px 8px rgba(141, 52, 8, 0.2);
}

/* --------------------------------------------------------------------------
   5. BOOKMARKS GRID & CARDS
   -------------------------------------------------------------------------- */
.pg-bm-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
    gap: 18px;
}

.pg-bm-card {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 18px 20px;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid #ede2d3;
    border-radius: 14px;
    box-shadow: 0 4px 16px rgba(90, 50, 20, 0.05);
    transition: transform 0.22s ease, box-shadow 0.22s ease, opacity 0.25s ease;
    box-sizing: border-box;
}

.pg-bm-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 22px rgba(90, 50, 20, 0.08);
    border-color: #d7c5ad;
}

.pg-bm-card.is-hidden {
    display: none !important;
}

.pg-bm-card.is-matched {
    background: #fef9c3 !important;
    border-color: #f59e0b !important;
    box-shadow: 0 4px 18px rgba(245, 158, 11, 0.22) !important;
}

.pg-bm-card.is-removing {
    opacity: 0;
    transform: scale(0.92);
}

.pg-bm-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 12px;
}

.pg-bm-badge {
    display: inline-block;
    padding: 3px 9px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 700;
    line-height: 1.3;
    letter-spacing: 0.2px;
}

.pg-bm-badge.badge-ancient {
    background: #fef3c7;
    color: #92400e;
}

.pg-bm-badge.badge-medieval {
    background: #ffedd5;
    color: #9a3412;
}

.pg-bm-badge.badge-modern {
    background: #e0e7ff;
    color: #3730a3;
}

.pg-bm-badge.badge-general {
    background: #eff6ff;
    color: #1d4ed8;
}

.pg-bm-date {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 11.5px;
    color: #8c827a;
    font-weight: 500;
}

.pg-bm-card-title {
    margin: 0 0 18px;
    font-family: "Baloo 2", serif !important;
    font-size: 18px;
    font-weight: 700;
    line-height: 1.4;
}

.pg-bm-card-title a {
    font-family: "Baloo 2", serif !important;
    color: #2c1a10;
    text-decoration: none;
    transition: color 0.2s ease;
}

.pg-bm-card-title a:hover {
    color: #8d3408;
}

.pg-bm-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding-top: 14px;
    border-top: 1px dashed #ede2d3;
}

.pg-bm-read-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 14px;
    border-radius: 8px;
    background: #fbf5ee;
    color: #4a2c11;
    border: 1px solid #ede2d3;
    font-family: "Poppins", system-ui, sans-serif !important;
    font-size: 12.5px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
}

.pg-bm-read-link:hover {
    background: #8d3408;
    color: #ffffff;
    border-color: #8d3408;
}

.pg-bm-delete-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #9ca3af;
    cursor: pointer;
    transition: all 0.2s ease;
}

.pg-bm-delete-btn:hover {
    background: #fee2e2;
    color: #dc2626;
}

/* --------------------------------------------------------------------------
   6. EMPTY STATE & GUEST CARD
   -------------------------------------------------------------------------- */
.pg-bm-empty {
    text-align: center;
    padding: 60px 20px;
    background: #ffffff;
    border: 1px dashed #d7c5ad;
    border-radius: 16px;
    margin: 20px 0;
}

.pg-bm-empty.is-hidden {
    display: none !important;
}

.pg-bm-empty-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: #fef3c7;
    color: #8d3408;
    margin-bottom: 16px;
}

.pg-bm-empty-title {
    margin: 0 0 6px;
    font-size: 18px;
    font-weight: 700;
    color: #2c1a10;
}

.pg-bm-empty-desc {
    margin: 0 0 20px;
    font-size: 14px;
    color: #6b5d52;
    max-width: 380px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.5;
}

.pg-bm-btn-browse {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 20px;
    border-radius: 999px;
    background: #8d3408;
    color: #ffffff;
    font-size: 13.5px;
    font-weight: 600;
    text-decoration: none;
    transition: background-color 0.2s ease, transform 0.2s ease;
}

.pg-bm-btn-browse:hover {
    background: #6e2704;
    transform: translateY(-1px);
}

/* Guest Card */
.pg-bm-guest-card {
    max-width: 520px;
    margin: 30px auto 60px;
    padding: 40px 30px;
    background: #ffffff;
    border: 1px solid #ede2d3;
    border-radius: 18px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(90, 50, 20, 0.06);
}

.pg-bm-guest-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: #fef3c7;
    color: #8d3408;
    margin-bottom: 18px;
}

.pg-bm-guest-title {
    margin: 0 0 8px;
    font-size: 22px;
    font-weight: 700;
    color: #2c1a10;
}

.pg-bm-guest-desc {
    margin: 0 0 24px;
    font-size: 14px;
    color: #6b5d52;
    line-height: 1.6;
}

.pg-bm-guest-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.pg-bm-btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: 10px;
    background: #8d3408;
    color: #ffffff;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: background-color 0.2s ease, transform 0.2s ease;
}

.pg-bm-btn-primary:hover {
    background: #6e2704;
    transform: translateY(-1px);
}

.pg-bm-btn-secondary {
    display: inline-block;
    padding: 10px 20px;
    border-radius: 10px;
    background: #fbf5ee;
    color: #4a2c11;
    border: 1px solid #ede2d3;
    font-size: 13.5px;
    font-weight: 600;
    text-decoration: none;
    transition: background-color 0.2s ease;
}

.pg-bm-btn-secondary:hover {
    background: #ede2d3;
}

/* --------------------------------------------------------------------------
   7. DARK MODE SUPPORT (PREMIUM GLASS & GOLDEN AMBER PALETTE)
   -------------------------------------------------------------------------- */
body.dark-mode:has(#pgBookmarksContainer),
body.dark-mode:has(.pg-bookmarks-container),
body.dark-mode.pg-bookmarks-page,
body.dark:has(#pgBookmarksContainer),
body.dark:has(.pg-bookmarks-container),
body.dark.pg-bookmarks-page,
body.dark-mode.page-id-3089,
body.dark.page-id-3089 {
    background-color: #111015 !important;
    background-image: linear-gradient(180deg, rgba(17, 16, 22, 0.76) 0%, rgba(20, 19, 26, 0.82) 50%, rgba(17, 16, 22, 0.90) 100%), url('../../../uploads/bookmark-background.webp') !important;
    background-repeat: no-repeat !important;
    background-position: center top !important;
    background-size: cover !important;
    background-attachment: fixed !important;
    color: #f8fafc !important;
}

body.dark-mode .pg-bookmark-wrap .pg-bookmark-btn,
body.dark .pg-bookmark-wrap .pg-bookmark-btn {
    background: rgba(30, 30, 38, 0.9) !important;
    border-color: rgba(255, 255, 255, 0.12) !important;
    color: #e2e8f0 !important;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.5) !important;
}

body.dark-mode .pg-bookmark-wrap .pg-bookmark-btn:hover,
body.dark .pg-bookmark-wrap .pg-bookmark-btn:hover {
    background: #3f3f46 !important;
    color: #ffffff !important;
    border-color: #52525b !important;
}

body.dark-mode .pg-bookmark-wrap .pg-bookmark-btn.is-bookmarked,
body.dark .pg-bookmark-wrap .pg-bookmark-btn.is-bookmarked {
    background: rgba(45, 25, 10, 0.9) !important;
    border-color: #b45309 !important;
    color: #fbbf24 !important;
}

body.dark-mode .pg-bookmark-wrap .pg-bookmark-btn.is-bookmarked .pg-bm-icon,
body.dark .pg-bookmark-wrap .pg-bookmark-btn.is-bookmarked .pg-bm-icon {
    fill: #fbbf24 !important;
    stroke: #fbbf24 !important;
}

body.dark-mode .pg-bm-header,
body.dark .pg-bm-header {
    border-bottom-color: rgba(255, 255, 255, 0.08) !important;
}

body.dark-mode .pg-bm-title,
body.dark .pg-bm-title {
    color: #f8fafc !important;
}

body.dark-mode .pg-bm-subtitle,
body.dark .pg-bm-subtitle {
    color: #94a3b8 !important;
}

body.dark-mode .pg-bm-counter,
body.dark .pg-bm-counter {
    background: rgba(245, 158, 11, 0.14) !important;
    color: #fbbf24 !important;
    border: 1px solid rgba(245, 158, 11, 0.35) !important;
}

body.dark-mode .pg-bm-search-input,
body.dark .pg-bm-search-input {
    background: rgba(26, 26, 34, 0.85) !important;
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
    color: #f8fafc !important;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35) !important;
}

body.dark-mode .pg-bm-search-input::placeholder,
body.dark .pg-bm-search-input::placeholder {
    color: #94a3b8 !important;
}

body.dark-mode .pg-bm-search-input:focus,
body.dark .pg-bm-search-input:focus {
    border-color: #fbbf24 !important;
    box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.25) !important;
}

body.dark-mode .pg-bm-search-icon svg,
body.dark .pg-bm-search-icon svg {
    stroke: #94a3b8 !important;
}

body.dark-mode .pg-bm-filter-btn,
body.dark .pg-bm-filter-btn {
    background: rgba(26, 26, 34, 0.8) !important;
    backdrop-filter: blur(10px) !important;
    -webkit-backdrop-filter: blur(10px) !important;
    border: 1px solid rgba(255, 255, 255, 0.09) !important;
    color: #cbd5e1 !important;
}

body.dark-mode .pg-bm-filter-btn:hover,
body.dark .pg-bm-filter-btn:hover {
    background: rgba(255, 255, 255, 0.1) !important;
    color: #ffffff !important;
    border-color: rgba(255, 255, 255, 0.18) !important;
}

body.dark-mode .pg-bm-filter-btn.is-active,
body.dark .pg-bm-filter-btn.is-active {
    background: linear-gradient(135deg, #d97706, #b45309) !important;
    color: #ffffff !important;
    border-color: #f59e0b !important;
    box-shadow: 0 4px 14px rgba(217, 119, 6, 0.35) !important;
}

body.dark-mode .pg-bm-card,
body.dark .pg-bm-card {
    background: rgba(26, 26, 34, 0.82) !important;
    backdrop-filter: blur(14px) !important;
    -webkit-backdrop-filter: blur(14px) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.04) !important;
}

body.dark-mode .pg-bm-card:hover,
body.dark .pg-bm-card:hover {
    border-color: rgba(245, 158, 11, 0.45) !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6), 0 0 20px rgba(245, 158, 11, 0.12) !important;
    transform: translateY(-2px);
}

body.dark-mode .pg-bm-card-subject,
body.dark .pg-bm-card-subject {
    background: rgba(245, 158, 11, 0.12) !important;
    color: #fbbf24 !important;
    border: 1px solid rgba(245, 158, 11, 0.3) !important;
}

body.dark-mode .pg-bm-card-date,
body.dark .pg-bm-card-date {
    color: #94a3b8 !important;
}

body.dark-mode .pg-bm-card-date svg,
body.dark .pg-bm-card-date svg {
    stroke: #94a3b8 !important;
}

body.dark-mode .pg-bm-card-title a,
body.dark .pg-bm-card-title a {
    color: #f8fafc !important;
}

body.dark-mode .pg-bm-card-title a:hover,
body.dark .pg-bm-card-title a:hover {
    color: #fbbf24 !important;
}

body.dark-mode .pg-bm-card-footer,
body.dark .pg-bm-card-footer {
    border-top: 1px solid rgba(255, 255, 255, 0.07) !important;
}

body.dark-mode .pg-bm-read-link,
body.dark .pg-bm-read-link {
    background: linear-gradient(135deg, #b45309, #8d3408) !important;
    color: #ffffff !important;
    border: 1px solid rgba(245, 158, 11, 0.3) !important;
    box-shadow: 0 4px 12px rgba(180, 83, 9, 0.3) !important;
}

body.dark-mode .pg-bm-read-link:hover,
body.dark .pg-bm-read-link:hover {
    background: linear-gradient(135deg, #d97706, #b45309) !important;
    box-shadow: 0 6px 16px rgba(217, 119, 6, 0.45) !important;
    color: #ffffff !important;
}

body.dark-mode .pg-bm-delete-btn,
body.dark .pg-bm-delete-btn {
    background: rgba(239, 68, 68, 0.1) !important;
    border: 1px solid rgba(239, 68, 68, 0.22) !important;
    color: #f87171 !important;
}

body.dark-mode .pg-bm-delete-btn:hover,
body.dark .pg-bm-delete-btn:hover {
    background: rgba(239, 68, 68, 0.25) !important;
    border-color: #ef4444 !important;
    color: #ffffff !important;
}

body.dark-mode .pg-bm-card.is-matched,
body.dark .pg-bm-card.is-matched {
    background: rgba(55, 30, 8, 0.9) !important;
    border-color: #f59e0b !important;
    box-shadow: 0 8px 26px rgba(245, 158, 11, 0.25) !important;
}

body.dark-mode .pg-bm-empty,
body.dark-mode .pg-bm-guest-card,
body.dark .pg-bm-empty,
body.dark .pg-bm-guest-card {
    background: rgba(26, 26, 34, 0.85) !important;
    backdrop-filter: blur(14px) !important;
    border-color: rgba(255, 255, 255, 0.08) !important;
}

body.dark-mode .pg-bm-empty-title,
body.dark-mode .pg-bm-guest-title,
body.dark .pg-bm-empty-title,
body.dark .pg-bm-guest-title {
    color: #f8fafc !important;
}

body.dark-mode .pg-bm-empty-desc,
body.dark-mode .pg-bm-guest-desc,
body.dark .pg-bm-empty-desc,
body.dark .pg-bm-guest-desc {
    color: #94a3b8 !important;
}

body.dark-mode .pg-bm-btn-secondary,
body.dark .pg-bm-btn-secondary {
    background: rgba(255, 255, 255, 0.08) !important;
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
    color: #e2e8f0 !important;
}

body.dark-mode .pg-bm-btn-secondary:hover,
body.dark .pg-bm-btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15) !important;
    color: #ffffff !important;
}

/* --------------------------------------------------------------------------
   8. MOBILE RESPONSIVENESS (PERFECT FIT - ZERO SIDE WASTAGE)
   -------------------------------------------------------------------------- */
@media (max-width: 768px) {
    body:has(#pgBookmarksContainer) .wp-site-blocks,
    body:has(#pgBookmarksContainer) .site,
    body:has(#pgBookmarksContainer) .site-content,
    body:has(#pgBookmarksContainer) main,
    body:has(#pgBookmarksContainer) main.wp-block-group,
    body:has(#pgBookmarksContainer) .wp-block-group,
    body:has(#pgBookmarksContainer) .wp-block-group.alignfull,
    body:has(#pgBookmarksContainer) .wp-block-post-content,
    body:has(#pgBookmarksContainer) .entry-content,
    body:has(.pg-bookmarks-container) .wp-site-blocks,
    body:has(.pg-bookmarks-container) .site,
    body:has(.pg-bookmarks-container) .site-content,
    body:has(.pg-bookmarks-container) main,
    body:has(.pg-bookmarks-container) main.wp-block-group,
    body:has(.pg-bookmarks-container) .wp-block-group,
    body:has(.pg-bookmarks-container) .wp-block-group.alignfull,
    body:has(.pg-bookmarks-container) .wp-block-post-content,
    body:has(.pg-bookmarks-container) .entry-content,
    body.pg-bookmarks-page .wp-site-blocks,
    body.pg-bookmarks-page .site,
    body.pg-bookmarks-page .site-content,
    body.pg-bookmarks-page main,
    body.pg-bookmarks-page main.wp-block-group,
    body.pg-bookmarks-page .wp-block-group,
    body.pg-bookmarks-page .wp-block-group.alignfull,
    body.pg-bookmarks-page .wp-block-post-content,
    body.pg-bookmarks-page .entry-content,
    body.page-id-3089 .wp-site-blocks,
    body.page-id-3089 main.wp-block-group,
    body.page-id-3089 .wp-block-group.alignfull,
    body.page-id-3089 .wp-block-post-content,
    body.page-id-3089 .entry-content {
        margin-left: 0 !important;
        margin-right: 0 !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    .pg-bookmarks-container {
        padding: 6px 12px 0 !important;
        margin: 0 auto 90px !important;
    }

    .pg-bm-header {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
        margin-bottom: 12px;
        padding-bottom: 10px;
    }

    .pg-bm-title {
        font-size: 21px;
    }

    .pg-bm-subtitle {
        font-size: 12.5px;
    }

    .pg-bm-search-wrap {
        width: 100%;
    }

    .pg-bm-search-input {
        height: 36px;
        font-size: 13px;
    }

    .pg-bm-filters {
        display: flex;
        gap: 6px;
        flex-wrap: nowrap;
        overflow-x: auto;
        padding-bottom: 6px;
        margin-bottom: 14px;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }

    .pg-bm-filters::-webkit-scrollbar {
        display: none;
    }

    .pg-bm-filter-btn {
        flex-shrink: 0;
        white-space: nowrap;
        padding: 5px 12px;
        font-size: 12px;
    }

    .pg-bm-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .pg-bm-card {
        padding: 15px 16px 14px;
        border-radius: 12px;
    }

    .pg-bm-card-title {
        font-size: 17px;
        margin-bottom: 14px;
    }

    .pg-bm-card-footer {
        padding-top: 10px;
    }
}

@media (max-width: 480px) {
    .pg-bookmarks-container {
        padding: 4px 10px 0 !important;
    }

    .pg-bookmark-wrap {
        top: 12px;
        right: 12px;
        margin: 0 0 8px;
    }

    .pg-bookmark-btn {
        height: 28px;
        padding: 0 9px;
        font-size: 11.5px;
        gap: 4px;
    }

    .pg-bm-card {
        padding: 13px 13px 11px;
    }

    .pg-bm-card-title {
        font-size: 16px;
        margin-bottom: 12px;
    }

    .pg-bm-read-link {
        padding: 6px 12px;
        font-size: 12px;
    }
}
