/* SparkTrail Custom Modern Scrollbar */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: rgba(15, 23, 42, 0.6);
    border-radius: 9999px;
}

::-webkit-scrollbar-thumb {
    background: rgba(51, 65, 85, 0.7);
    border-radius: 9999px;
    border: 1px solid rgba(15, 23, 42, 0.3);
    transition: background-color 0.2s ease;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(245, 158, 11, 0.8);
    box-shadow: 0 0 10px rgba(245, 158, 11, 0.4);
}

::-webkit-scrollbar-corner {
    background: transparent;
}

/* Firefox scrollbar support */
* {
    scrollbar-width: thin;
    scrollbar-color: rgba(51, 65, 85, 0.7) rgba(15, 23, 42, 0.6);
}

/* Custom Scrollbar Helper Classes */
.custom-scrollbar::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}
.custom-scrollbar::-webkit-scrollbar-track {
    background: rgba(15, 23, 42, 0.6);
    border-radius: 9999px;
}
.custom-scrollbar::-webkit-scrollbar-thumb {
    background: rgba(51, 65, 85, 0.7);
    border-radius: 9999px;
}
.custom-scrollbar::-webkit-scrollbar-thumb:hover {
    background: rgba(245, 158, 11, 0.8);
}

/* Hide Scrollbar Utilities */
.scrollbar-none::-webkit-scrollbar,
.no-scrollbar::-webkit-scrollbar {
    display: none;
    width: 0 !important;
    height: 0 !important;
}
.scrollbar-none,
.no-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

/* Prose Typography & Markdown Overrides */
.prose {
    color: #cbd5e1;
}

.prose strong {
    color: #f8fafc;
    font-weight: 700;
}

.prose em {
    color: #cbd5e1;
}

.prose code {
    color: #f59e0b !important;
    background-color: #0f172a !important;
    padding: 0.15em 0.35em !important;
    border-radius: 0.25em !important;
    border: 1px solid #334155 !important;
    font-weight: 500;
}

/* Headings & Dividers */
.prose h1,
.prose h2,
.prose h3,
.prose h4,
.prose h5,
.prose h6 {
    font-weight: 700 !important;
    line-height: 1.3 !important;
    letter-spacing: -0.01em !important;
}

.prose h1 {
    font-size: 1.65em !important;
    color: #f8fafc !important;
    margin-top: 1.25em !important;
    margin-bottom: 0.6em !important;
}

.prose h2 {
    font-size: 1.35em !important;
    color: #f1f5f9 !important;
    margin-top: 1.1em !important;
    margin-bottom: 0.5em !important;
}

.prose h3 {
    font-size: 1.15em !important;
    color: #e2e8f0 !important;
    margin-top: 1em !important;
    margin-bottom: 0.4em !important;
}

.prose h4,
.prose h5,
.prose h6 {
    font-size: 1em !important;
    color: #cbd5e1 !important;
    margin-top: 0.9em !important;
    margin-bottom: 0.3em !important;
}

.prose h1:first-child,
.prose h2:first-child,
.prose h3:first-child,
.prose h4:first-child {
    margin-top: 0 !important;
}

.prose hr {
    border: 0 !important;
    border-top: 1px solid #334155 !important;
    margin: 1.75rem 0 !important;
    opacity: 0.8 !important;
}

/* Table styles */
.prose table {
    width: max-content;
    max-width: 100%;
    border-collapse: collapse;
    margin-bottom: 1em;
}

.prose th,
.prose td {
    border: 1px solid #334155;
    padding: 0.5em 0.75em;
}

.prose th {
    background-color: #1e293b;
    font-weight: 600;
    text-align: left;
}

.prose tr:nth-child(even) {
    background-color: rgba(15, 23, 42, 0.3);
}

/* Blockquote styles */
.prose blockquote {
    border: 1px solid rgba(245, 158, 11, 0.2) !important;
    border-left: 4px solid #f59e0b !important;
    padding: 0.75rem 1.25rem !important;
    margin: 1rem 0 !important;
    color: #cbd5e1 !important;
    font-style: italic !important;
    background-color: rgba(15, 23, 42, 0.6) !important;
    border-radius: 0 0.75rem 0.75rem 0 !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25) !important;
    quotes: none !important;
}

.prose blockquote p {
    margin: 0.25rem 0 !important;
    color: #cbd5e1 !important;
}

.prose blockquote p::before,
.prose blockquote p::after {
    content: "" !important;
}

.prose blockquote blockquote {
    margin: 0.5rem 0 !important;
    border: 1px solid rgba(59, 130, 246, 0.2) !important;
    border-left: 4px solid #3b82f6 !important;
    background-color: rgba(30, 41, 59, 0.6) !important;
}

/* Staggered Entrance Animation */
@keyframes cascadeIn {
    0% {
        opacity: 0;
        transform: translateY(20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.cascade-in {
    animation: cascadeIn 0.4s ease-out forwards;
    opacity: 0;
}

/* Completion Sheen */
@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

.completed-sheen {
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.08), transparent);
    background-size: 200% 100%;
    animation: shimmer 3s infinite linear;
    pointer-events: none;
    z-index: 5;
}

/* Archive Slide Right Animation */
@keyframes slideRightOut {
    0% {
        opacity: 1;
        transform: translateX(0) scale(1);
        max-height: 100px;
        margin-bottom: 0.5rem;
        padding: 0.75rem;
        border-width: 1px;
    }
    40% {
        opacity: 0;
        transform: translateX(50%) scale(0.9);
        max-height: 100px;
        margin-bottom: 0.5rem;
        padding: 0.75rem;
        border-width: 1px;
    }
    100% {
        opacity: 0;
        transform: translateX(50%) scale(0.9);
        max-height: 0;
        margin-bottom: 0;
        padding: 0;
        border-width: 0;
        overflow: hidden;
    }
}

.archive-slide-out {
    animation: slideRightOut 0.5s ease-in-out forwards;
}

/* Star Burst Ignite Animation */
.star-burst-container {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.star-burst-img {
    position: absolute;
    width: 70px;
    height: 70px;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0);
    opacity: 0;
    pointer-events: none;
    z-index: 20;
}

.spark-star-icon {
    position: relative;
    z-index: 10;
}

@keyframes burstPop {
    0% {
        transform: translate(-50%, -50%) scale(0.2);
        opacity: 1;
    }
    70% {
        transform: translate(-50%, -50%) scale(1.7);
        opacity: 1;
    }
    100% {
        transform: translate(-50%, -50%) scale(2.0);
        opacity: 0;
    }
}

.animate-burst .star-burst-img {
    animation: burstPop 0.4s ease-out forwards;
}

@keyframes starPop {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.3);
        filter: brightness(1.5);
    }
    100% {
        transform: scale(1);
    }
}

.animate-burst .spark-star-icon {
    animation: starPop 0.4s ease-out forwards;
}

/* Detail Pane Background */
#detail-panel {
    background-image: url("/static/img/bgs/panebg.7a329f7c6484.webp");
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

/* Top App Header & Toolbar Background (Blended to match Spark List Panel) */
#main-app-header,
header.app-top-header {
    background: rgba(2, 6, 23, 0.2) !important;
}

#toolbar-section {
    background: rgba(2, 6, 23, 0.2) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

/* Toolbar Controls Frosted Glass Styling */
#toolbar-section select,
#toolbar-section #search-filter,
#toolbar-section #view-mode-toggle,
#toolbar-section #quick-add-input,
#toolbar-section #layout-toggle-container {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.08) 0%, rgba(255, 255, 255, 0.02) 100%), rgba(20, 28, 45, 0.65) !important;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
    border-radius: 0.65rem !important;
    box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.1), 0 2px 6px rgba(0, 0, 0, 0.3);
    color: #e2e8f0;
    transition: all 0.2s ease;
}

/* Header Exploration Buttons below Embers Shelf */
#open-nebula-btn,
#open-constellation-btn {
    width: 28px !important;
    height: 28px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.08) 0%, rgba(255, 255, 255, 0.02) 100%), rgba(20, 28, 45, 0.75) !important;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
    border-radius: 0.5rem !important;
    box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.1), 0 2px 5px rgba(0, 0, 0, 0.3);
    transition: all 0.2s ease;
}

#open-nebula-btn:hover {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.14) 0%, rgba(255, 255, 255, 0.05) 100%), rgba(28, 39, 62, 0.85) !important;
    border-color: rgba(245, 158, 11, 0.55) !important;
    box-shadow: 0 0 10px rgba(245, 158, 11, 0.35) !important;
    transform: translateY(-1px);
}

#open-constellation-btn:hover {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.14) 0%, rgba(255, 255, 255, 0.05) 100%), rgba(28, 39, 62, 0.85) !important;
    border-color: rgba(56, 189, 248, 0.55) !important;
    box-shadow: 0 0 10px rgba(56, 189, 248, 0.35) !important;
    transform: translateY(-1px);
}

#toolbar-section #search-filter {
    height: 28px !important;
    line-height: 26px !important;
    padding: 0 10px !important;
    font-size: 12px !important;
    border-radius: 0.65rem !important;
    box-sizing: border-box !important;
    align-self: center !important;
}

#toolbar-section .toolbar-filter-pill {
    height: 28px !important;
    line-height: 26px !important;
    border-radius: 0.65rem !important;
    box-sizing: border-box !important;
    align-self: center !important;
}

#toolbar-section select:hover,
#toolbar-section #search-filter:hover,
#toolbar-section #view-mode-toggle:hover,
#toolbar-section #quick-add-input:hover {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.12) 0%, rgba(255, 255, 255, 0.04) 100%), rgba(28, 39, 62, 0.75) !important;
    border-color: rgba(255, 255, 255, 0.22) !important;
}

#toolbar-section select:focus,
#toolbar-section #search-filter:focus,
#toolbar-section #quick-add-input:focus {
    border-color: rgba(245, 158, 11, 0.65) !important;
    box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.12), 0 0 0 2px rgba(245, 158, 11, 0.25), 0 4px 12px rgba(0, 0, 0, 0.35) !important;
}

#toolbar-section select option {
    background-color: #0f172a;
    color: #f1f5f9;
}

#search-filter-wrapper i.fa-magnifying-glass {
    color: #cbd5e1 !important;
    z-index: 10;
}

/* Unified Spark Stage: Premium Cosmic Glassmorphic Panel */
#spark-unified-stage {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.05) 0%, rgba(255, 255, 255, 0.01) 120px), rgba(15, 23, 42, 0.32) !important;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
    border-top: 1px solid rgba(245, 158, 11, 0.45) !important;
    border-radius: 1rem !important;
    box-shadow: 0 16px 40px -8px rgba(0, 0, 0, 0.55),
                0 0 24px -2px rgba(124, 58, 237, 0.12),
                inset 0 1px 1px 0 rgba(255, 255, 255, 0.18),
                inset 0 0 20px rgba(245, 158, 11, 0.04) !important;
    position: relative;
}

#spark-unified-stage::before {
    content: '';
    position: absolute;
    top: 0;
    left: 8%;
    right: 8%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(251, 191, 36, 0.8), rgba(168, 85, 247, 0.8), transparent);
    pointer-events-none;
    z-index: 25;
}

#detail-panel.spark-editing-mode #spark-unified-stage {
    border-color: rgba(245, 158, 11, 0.5) !important;
    box-shadow: 0 16px 40px -8px rgba(0, 0, 0, 0.65),
                0 0 28px -4px rgba(245, 158, 11, 0.25),
                inset 0 1px 1px 0 rgba(255, 255, 255, 0.25) !important;
}

/* Pinned Header inside Unified Stage */
#detail-header {
    background: rgba(255, 255, 255, 0.03) !important;
    border: none !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
    border-radius: 0 !important;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08) !important;
    position: relative;
}

#detail-header::before {
    display: none !important;
}

#spark-unified-stage #detail-orbiting-sparks-wrapper {
    background: rgba(0, 0, 0, 0.15) !important;
    border-top: none !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06) !important;
}

#detail-header #detail-title {
    color: #f8fafc !important;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.6);
    letter-spacing: -0.01em;
    border-bottom: 1px solid transparent !important;
    font-size: 1.3rem !important;
}

@media (min-width: 1024px) {
    #detail-header #detail-title {
        font-size: 1.45rem !important; /* Increased by 15% (1.25rem -> 1.45rem / ~23px) */
    }
}

#detail-header #detail-title[readonly],
#detail-header #detail-title[readonly]:focus {
    border-bottom: 1px solid transparent !important;
    background-color: transparent !important;
    outline: none !important;
    box-shadow: none !important;
    cursor: default;
}

#detail-panel.spark-editing-mode #detail-header #detail-title:focus,
#detail-header #detail-title:not([readonly]):focus {
    border-bottom: 1px solid #f59e0b !important;
    background-color: rgba(2, 6, 23, 0.3) !important;
    outline: none !important;
    cursor: text;
}

#detail-header-actions button#edit-btn,
#detail-header-actions button#cancel-spark-edit-btn,
#detail-header-actions button#print-single-spark-btn,
#detail-header-actions button#spark-settings-btn {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.08) 0%, rgba(255, 255, 255, 0.02) 100%), rgba(20, 28, 45, 0.8) !important;
    border: 1px solid rgba(255, 255, 255, 0.14) !important;
    box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.1), 0 2px 6px rgba(0, 0, 0, 0.3);
}

#detail-header-actions button#edit-btn,
#detail-header-actions button#cancel-spark-edit-btn,
#detail-header-actions button#spark-settings-btn {
    min-width: 28px;
    height: 26px;
    padding: 0 7px !important;
}

#detail-header-actions button#edit-btn i,
#detail-header-actions button#cancel-spark-edit-btn i,
#detail-header-actions button#spark-settings-btn i {
    font-size: 14px !important; /* +15% over 12px */
}

#detail-header-actions button#edit-btn:hover,
#detail-header-actions button#cancel-spark-edit-btn:hover,
#detail-header-actions button#print-single-spark-btn:hover,
#detail-header-actions button#spark-settings-btn:hover {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.14) 0%, rgba(255, 255, 255, 0.04) 100%), rgba(30, 41, 68, 0.9) !important;
    border-color: rgba(245, 158, 11, 0.4) !important;
    box-shadow: 0 0 12px rgba(245, 158, 11, 0.2), inset 0 1px 1px rgba(255, 255, 255, 0.15);
}

#detail-parent-shortcut-btn {
    height: 24px !important;
    min-height: 24px !important;
    max-height: 24px !important;
}

#detail-desktop-meta-row {
    height: 24px !important;
    min-height: 24px !important;
    display: inline-flex !important;
    align-items: center !important;
    flex-shrink: 0 !important;
}

#detail-category-row {
    height: 24px !important;
    min-height: 24px !important;
    display: inline-flex !important;
    align-items: center !important;
}

#detail-category-badge.hidden,
#detail-panel.spark-editing-mode #detail-category-badge {
    display: none !important;
}

#detail-category-select.hidden {
    display: none !important;
}

#detail-category-badge:not(.hidden) {
    height: 24px !important;
    min-height: 24px !important;
    max-height: 24px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    width: fit-content !important;
    min-width: 80px !important;
    padding-left: 8px !important;
    padding-right: 10px !important;
    white-space: nowrap !important;
}

#detail-category-text {
    text-align: center !important;
    display: inline-block !important;
    line-height: 1 !important;
    white-space: nowrap !important;
}

#detail-category-select {
    height: 24px !important;
    width: auto !important;
    max-width: 200px !important;
}

/* Breadcrumbs Bar: transparent floating sub-panel without border or background */
#detail-breadcrumbs-nav {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    overflow-y: hidden !important;
    scrollbar-width: none !important;
    -ms-overflow-style: none !important;
}

#detail-breadcrumb-wrapper {
    min-height: 36px;
}

#detail-breadcrumbs-nav::-webkit-scrollbar {
    display: none !important;
    width: 0 !important;
    height: 0 !important;
}

/* Disabled Breadcrumbs in Spark Editing Mode */
#detail-panel.spark-editing-mode #detail-breadcrumbs-nav {
    opacity: 0.35 !important;
    pointer-events: none !important;
    cursor: not-allowed !important;
    user-select: none !important;
    filter: grayscale(0.5);
    transition: opacity 0.2s ease;
}

#detail-panel.spark-editing-mode #detail-breadcrumbs-nav * {
    pointer-events: none !important;
    cursor: not-allowed !important;
}

/* Hover lift */
.spark-row {
    transition: transform 0.2s, background-color 0.2s, border-color 0.2s;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    overflow: hidden;
}

.spark-row:hover {
    transform: translateY(-2px);
}

/* Circular Progress Dial */
.progress-dial-container {
    filter: drop-shadow(0 2px 5px rgba(0, 0, 0, 0.4));
    transition: transform 0.2s ease;
}

.progress-dial-container:hover {
    transform: scale(1.06);
}

.progress-ring-circle {
    transition: stroke-dashoffset 0.35s ease, stroke 0.3s ease;
}

/* Base Glint Highlights */
.glint-highlight {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    background-color: rgba(245, 158, 11, 0.08);
    border: 1px solid rgba(245, 158, 11, 0.25);
    border-radius: 6px;
    padding: 0.1rem 0.4rem;
    font-size: 0.875rem;
    vertical-align: middle;
    margin: 0.15rem 0;
}

/* Small, subtle helper tag pill */
.glint-tag-pill {
    font-size: 0.65rem;
    font-weight: 900;
    text-transform: uppercase;
    background: rgba(245, 158, 11, 0.2);
    color: #f59e0b;
    padding: 0.05rem 0.25rem;
    border-radius: 4px;
    font-family: monospace;
}

.glint-text {
    color: #f1f5f9;
    font-weight: 500;
}

/* Color override templates for common categories */
.glint-important {
    background-color: rgba(239, 68, 68, 0.08);
    border-color: rgba(239, 68, 68, 0.25);
}

.glint-important .glint-tag-pill {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

.glint-idea {
    background-color: rgba(59, 130, 246, 0.08);
    border-color: rgba(59, 130, 246, 0.25);
}

.glint-idea .glint-tag-pill {
    background: rgba(59, 130, 246, 0.2);
    color: #3b82f6;
}

/* Special Glints Styling */
.glint-date {
    background-color: rgba(245, 158, 11, 0.1);
    border-color: rgba(245, 158, 11, 0.35);
}

.glint-date .glint-tag-pill {
    background: rgba(245, 158, 11, 0.25);
    color: #fbbf24;
}

.glint-date-error {
    background-color: rgba(239, 68, 68, 0.15) !important;
    border: 1px solid rgba(239, 68, 68, 0.5) !important;
    color: #f87171 !important;
    font-weight: 600;
    padding: 0.15rem 0.5rem;
    border-radius: 6px;
    display: inline-flex;
    align-items: center;
}

.glint-link {
    background-color: rgba(99, 102, 241, 0.12);
    border-color: rgba(99, 102, 241, 0.35);
    color: #a5b4fc;
    transition: all 0.2s ease;
}

.glint-link:hover {
    background-color: rgba(99, 102, 241, 0.25);
    border-color: rgba(99, 102, 241, 0.6);
    color: #ffffff;
    box-shadow: 0 0 12px rgba(99, 102, 241, 0.3);
}

.glint-link .glint-tag-pill {
    background: rgba(99, 102, 241, 0.3);
    color: #818cf8;
}

.glint-link-error {
    background-color: rgba(71, 85, 105, 0.3) !important;
    border: 1px dashed rgba(100, 116, 139, 0.5) !important;
    color: #94a3b8 !important;
    padding: 0.1rem 0.4rem;
    border-radius: 6px;
    display: inline-flex;
    align-items: center;
}

.glint-remindme {
    background-color: rgba(244, 63, 94, 0.1);
    border-color: rgba(244, 63, 94, 0.3);
}

.glint-remindme .glint-tag-pill {
    background: rgba(244, 63, 94, 0.25);
    color: #f43f5e;
}

.glint-done {
    background-color: rgba(71, 85, 105, 0.15);
    border-color: rgba(100, 116, 139, 0.3);
}

.glint-done .glint-tag-pill {
    background: rgba(100, 116, 139, 0.25);
    color: #94a3b8;
}

.glint-done .glint-text {
    text-decoration: line-through;
    opacity: 0.75;
}

.special-glint-badge {
    font-size: 0.6rem;
    font-weight: 800;
    text-transform: uppercase;
    background: rgba(245, 158, 11, 0.2);
    color: #fbbf24;
    border: 1px solid rgba(245, 158, 11, 0.4);
    padding: 0.05rem 0.3rem;
    border-radius: 4px;
}

/* Calendar Widget Styling */
.calendar-day-cell {
    aspect-ratio: 1 / 1;
    min-height: 44px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    padding: 0.35rem 0.2rem;
    border-radius: 0.75rem;
    background-color: rgba(15, 23, 42, 0.7);
    border: 1px solid rgba(51, 65, 85, 0.4);
    color: #94a3b8;
    font-size: 0.75rem;
    font-weight: 600;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    cursor: pointer;
    position: relative;
    user-select: none;
}

.calendar-day-cell:hover {
    background-color: rgba(30, 41, 59, 0.9);
    border-color: rgba(245, 158, 11, 0.5);
    color: #f8fafc;
    z-index: 2;
}

.calendar-day-cell.other-month {
    opacity: 0.35;
    background-color: transparent;
    border-color: transparent;
}

.calendar-day-cell.today-cell {
    border-color: rgba(245, 158, 11, 0.6) !important;
    box-shadow: inset 0 0 0 1px rgba(245, 158, 11, 0.3);
    color: #fbbf24;
}

.calendar-day-cell.has-date-glint {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.18) 0%, rgba(217, 119, 6, 0.1) 100%);
    border-color: rgba(245, 158, 11, 0.6) !important;
    color: #fbbf24;
}

.calendar-day-cell.has-date-glint:hover {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.3) 0%, rgba(217, 119, 6, 0.2) 100%);
    box-shadow: 0 0 12px rgba(245, 158, 11, 0.3);
}

.calendar-day-cell.selected-day-cell {
    background-color: rgba(245, 158, 11, 0.22) !important;
    border-color: #f59e0b !important;
    color: #ffffff !important;
    font-weight: 800;
    box-shadow: inset 0 0 0 1.5px #f59e0b, 0 0 14px rgba(245, 158, 11, 0.35) !important;
    z-index: 5;
}

.calendar-day-cell.selected-day-cell:hover {
    background-color: rgba(245, 158, 11, 0.3) !important;
    border-color: #fbbf24 !important;
    box-shadow: inset 0 0 0 1.5px #fbbf24, 0 0 16px rgba(245, 158, 11, 0.45) !important;
}

.calendar-glint-dot {
    width: 5px;
    height: 5px;
    border-radius: 9999px;
    background-color: #fbbf24;
    box-shadow: 0 0 6px #f59e0b;
}

#calendar-days-grid {
    padding-bottom: 2rem !important;
    margin-bottom: 1.5rem !important;
}

@media (max-width: 767px) {
    #calendar-days-grid {
        padding-bottom: 2.5rem !important;
        margin-bottom: 2rem !important;
    }
    .calendar-day-cell {
        min-height: 36px;
    }
}

/* Mobile Responsiveness Rules (< 768px) */
@media (max-width: 767px) {
    #list-panel {
        width: 100% !important;
        min-width: 0 !important;
        border-right: none !important;
        padding-bottom: 5rem !important;
    }
    #constellation-panel {
        padding-bottom: 5rem !important;
    }
    #spark-stream-container {
        padding-bottom: 6rem !important;
    }
    #detail-panel {
        min-width: 0 !important;
    }
    #detail-panel.mobile-active {
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        right: 0 !important;
        bottom: 0 !important;
        z-index: 300 !important;
        width: 100% !important;
        height: 100% !important;
        height: 100dvh !important;
        max-height: 100dvh !important;
        transform: none !important;
        border-left: none !important;
        box-shadow: none !important;
        background-color: #0f172a !important;
        display: flex !important;
        flex-direction: column !important;
        overflow: hidden !important;
    }
    #detail-panel.mobile-active #detail-scroll-container {
        min-height: 0 !important;
    }
    #detail-panel.mobile-active #editor-wrapper {
        min-height: 0 !important;
    }
    #detail-panel.mobile-active #editor-container {
        min-height: 80px !important;
    }
    #detail-header {
        padding: 0.75rem 0.875rem !important;
        gap: 0.625rem !important;
    }
    #detail-header #detail-title {
        font-size: 1.125rem !important;
        line-height: 1.35 !important;
    }
    .animate-slide-up {
        animation: slideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    }
    @keyframes slideUp {
        from { transform: translateY(100%); }
        to { transform: translateY(0); }
    }
}

/* Watermark Emoji styling */
.spark-card-watermark,
#detail-watermark-emoji {
    font-family: "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji", sans-serif;
    user-select: none;
    pointer-events: none;
    z-index: 10;
    filter: drop-shadow(0 0 16px rgba(245, 158, 11, 0.18));
}

/* Dynamic Ambient Backdrop Glow */
#detail-ambient-glow {
    background: radial-gradient(circle, var(--aura-color, #f59e0b) 0%, transparent 70%);
}

/* Unboxed Seamless Notes Container inside Unified Glass Stage */
#rendered-container {
    background: transparent !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    border: none !important;
    border-radius: 0 !important;
    padding: 0 !important;
    box-shadow: none !important;
    min-height: 100%;
    width: 100%;
    box-sizing: border-box;
}

#rendered-container.hidden {
    display: none !important;
}

#editor-container,
#editor-preview-container {
    background: rgba(15, 23, 42, 0.38) !important;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
}

/* Parsed Markdown <h1> Header Accent Line */
#rendered-container h1 {
    border-bottom: 2px solid var(--theme-accent-color, rgba(245, 158, 11, 0.3));
    padding-bottom: 0.4rem;
    margin-bottom: 1.25rem;
    transition: border-color 0.3s ease;
}

/* ==========================================
   THE SPARKSMITH VISUAL HELPER MODAL STYLES
   ========================================== */
.sparksmith-dialog-card {
    background: radial-gradient(circle at top, #0f1a2e 0%, #080d16 100%);
    box-shadow: 0 0 50px rgba(6, 182, 212, 0.25), inset 0 1px 1px rgba(255, 255, 255, 0.1);
}

.sparksmith-form-card {
    background: rgba(11, 17, 30, 0.7);
    border: 1px solid rgba(56, 189, 248, 0.35);
    box-shadow: 0 0 30px rgba(6, 182, 212, 0.08), inset 0 0 20px rgba(6, 182, 212, 0.03);
}

.active-sparksmith-tab {
    border: 1.5px solid #38bdf8 !important;
    background: rgba(56, 189, 248, 0.12) !important;
    box-shadow: 0 0 18px rgba(56, 189, 248, 0.4), inset 0 0 10px rgba(56, 189, 248, 0.15) !important;
}

.active-sparksmith-tab .sparksmith-icon-badge {
    transform: scale(1.08);
}

.sparksmith-neon-btn {
    border: 1.5px solid #22d3ee;
    background: rgba(6, 182, 212, 0.18);
    box-shadow: 0 0 18px rgba(6, 182, 212, 0.35), inset 0 0 10px rgba(6, 182, 212, 0.15);
    text-shadow: 0 0 8px rgba(6, 182, 212, 0.6);
}

.sparksmith-neon-btn:hover {
    background: rgba(6, 182, 212, 0.35);
    border-color: #67e8f9;
    box-shadow: 0 0 25px rgba(6, 182, 212, 0.65), inset 0 0 15px rgba(6, 182, 212, 0.3);
}

/* Date picker dark-theme styling */
input[type="date"] {
    color-scheme: dark;
}

#sparksmith-date-wrapper input[type="date"]::-webkit-calendar-picker-indicator {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

/* ==========================================
   THE HEARTH EMBERS COMPACT WIDGET STYLES
   ========================================== */

@keyframes emberBreathe {
    0%, 100% {
        transform: scale(1);
        opacity: 0.85;
        box-shadow: 0 0 4px var(--cat-color, #f59e0b);
    }
    50% {
        transform: scale(1.35);
        opacity: 1;
        box-shadow: 0 0 10px var(--cat-color, #f59e0b), 0 0 16px var(--cat-color, #f59e0b);
    }
}

@keyframes emberPulseClick {
    0% {
        transform: scale(0.92);
        filter: brightness(2);
        box-shadow: 0 0 20px var(--cat-color, #f59e0b);
    }
    50% {
        transform: scale(1.15);
        filter: brightness(2.4);
        box-shadow: 0 0 25px var(--cat-color, #f59e0b);
    }
    100% {
        transform: scale(1);
        filter: brightness(1);
    }
}

#hearth-embers-shelf {
    position: relative;
    z-index: 30;
    min-height: 28px;
    height: 28px;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.6), 0 2px 8px rgba(0, 0, 0, 0.4);
    box-sizing: border-box;
}

#hearth-embers-shelf:hover {
    z-index: 40;
}

.hearth-ember-target {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    border-radius: 9999px;
    cursor: pointer;
    user-select: none;
    flex-shrink: 0;
    transition: transform 0.2s ease;
}

.hearth-ember-target .ember-dot {
    width: 9px;
    height: 9px;
    min-width: 9px;
    min-height: 9px;
    border-radius: 9999px;
    background-color: var(--cat-color, #f59e0b);
    animation: emberBreathe 2.4s infinite ease-in-out;
    flex-shrink: 0;
    transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1), 
                box-shadow 0.2s ease, 
                filter 0.2s ease;
    box-sizing: border-box;
}

.hearth-ember-target:hover .ember-dot {
    animation: none;
    transform: scale(1.45);
    filter: brightness(1.3);
    box-shadow: 0 0 10px var(--cat-color, #f59e0b), 0 0 18px var(--cat-color, #f59e0b);
}

.hearth-ember-target.ember-clicked .ember-dot {
    animation: emberPulseClick 0.4s ease-out forwards;
}

/* First Item: Dedicated Hearth Fire Icon */
.hearth-ember-target.hearth-icon-target {
    width: 20px;
    height: 20px;
}

.hearth-ember-target.hearth-icon-target .hearth-fire-icon {
    width: 14px;
    height: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1), filter 0.2s ease;
}

.hearth-ember-target.hearth-icon-target:hover .hearth-fire-icon {
    transform: scale(1.3);
    filter: drop-shadow(0 0 8px rgba(245, 158, 11, 0.95)) brightness(1.25);
}

.hearth-ember-target.hearth-icon-target.ember-clicked .hearth-fire-icon {
    animation: emberPulseClick 0.4s ease-out forwards;
}

/* Dedicated Quickie Bolt Icon */
.hearth-ember-target.quickie-icon-target {
    width: 20px;
    height: 20px;
}

.hearth-ember-target.quickie-icon-target .quickie-bolt-icon {
    width: 14px;
    height: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1), filter 0.2s ease;
}

.hearth-ember-target.quickie-icon-target:hover .quickie-bolt-icon {
    transform: scale(1.3);
    filter: drop-shadow(0 0 8px rgba(251, 191, 36, 0.95)) brightness(1.25);
}

.hearth-ember-target.quickie-icon-target.ember-clicked .quickie-bolt-icon {
    animation: emberPulseClick 0.4s ease-out forwards;
}

/* Floating Neon Capsule Tooltip (Positioned below the Recent Bar to stay within the viewport) */
.hearth-ember-target:hover {
    z-index: 60;
}

.hearth-ember-target .ember-tooltip {
    position: absolute;
    top: calc(100% + 7px);
    left: 50%;
    transform: translate(-50%, -4px);
    opacity: 0;
    pointer-events: none;
    z-index: 1000;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 3.5px 10px;
    background: rgba(9, 14, 24, 0.96);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1.5px solid var(--cat-color, #f59e0b);
    border-radius: 9999px;
    box-shadow: 0 0 16px color-mix(in srgb, var(--cat-color, #f59e0b) 45%, transparent),
                0 6px 20px rgba(0, 0, 0, 0.85);
    white-space: nowrap;
    transition: opacity 0.16s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.16s cubic-bezier(0.16, 1, 0.3, 1);
}

.hearth-ember-target .ember-tooltip::after {
    content: '';
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    border-width: 0 4px 4px 4px;
    border-style: solid;
    border-color: transparent transparent var(--cat-color, #f59e0b) transparent;
}

.hearth-ember-target:hover .ember-tooltip {
    opacity: 1;
    transform: translate(-50%, 0);
}

/* ==========================================================================
   Interaction Media Queries (Touch-Screen vs Fine-Pointer Input)
   ========================================================================== */

/* Target any device where the primary pointing device is coarse (like a finger on a touchscreen: phones, tablets, touch laptops) */
@media (pointer: coarse) {
    #print-single-spark-btn,
    .inline-print-spark-btn {
        display: none !important;
    }
    .progress-dial-container {
        cursor: default !important;
        pointer-events: none !important;
    }
}

/* Ensure devices with fine-pointer inputs (like a desktop with a mouse) continue to display beautifully */
@media (pointer: fine) {
    .progress-dial-container {
        cursor: pointer;
        pointer-events: auto;
    }
}

/* Enable vertical scrolling on intensity track while preserving horizontal drag gesture */
.intensity-track-container {
    touch-action: pan-y;
}

/* Responsive adjustments: Small screen phone mode */
@media (max-width: 767px) {
    #close-calendar-modal-btn {
        display: none !important;
    }
    /* Reverse Stream column order in phone mode: White Hot on top, Quiet Embers at bottom */
    .stream-col-whitehot { order: 1 !important; }
    .stream-col-heat     { order: 2 !important; }
    .stream-col-glow     { order: 3 !important; }
    .stream-col-embers   { order: 4 !important; }
}

/* Stream View Touch Screen & Drag Optimization */
.stream-column {
    touch-action: pan-y;
}

@media (pointer: coarse) {
    .stream-column [draggable="false"],
    .stream-column [draggable="true"] {
        -webkit-user-drag: none;
        touch-action: pan-y;
    }
}

@media (min-width: 768px) {
    /* Standard Desktop Stream order: Quiet Embers leftmost, White Hot rightmost */
    .stream-col-embers   { order: 1 !important; }
    .stream-col-glow     { order: 2 !important; }
    .stream-col-heat     { order: 3 !important; }
    .stream-col-whitehot { order: 4 !important; }
}

/* Intensity Slider Dot (Responsive subtle indicator at current position) */
.intensity-dot {
    position: absolute;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 8px;
    height: 8px;
    border-radius: 9999px;
    background-color: var(--cat-color, #f59e0b);
    border: 1.5px solid rgba(255, 255, 255, 0.95);
    box-shadow: 0 0 6px var(--cat-color, #f59e0b), 0 1px 3px rgba(0, 0, 0, 0.5);
    pointer-events: none;
    transition: left 0.3s cubic-bezier(0.16, 1, 0.3, 1), transform 0.2s ease, width 0.2s ease, height 0.2s ease;
    z-index: 2;
}

@media (min-width: 640px) {
    .intensity-dot {
        width: 9px;
        height: 9px;
    }
}

@media (min-width: 1024px) {
    .intensity-dot {
        width: 10px;
        height: 10px;
        border-width: 2px;
    }
}

.group\/track:hover .intensity-dot {
    transform: translate(-50%, -50%) scale(1.25);
    box-shadow: 0 0 10px var(--cat-color, #f59e0b), 0 0 2px #ffffff, 0 2px 5px rgba(0, 0, 0, 0.6);
}

.intensity-track.is-scrubbing .intensity-fill,
.intensity-track.is-scrubbing .intensity-dot {
    transition: none !important;
}

/* ==========================================================================
   Orbiting Sparks Index Page Mode (When Spark has zero notes & orbiting sparks)
   ========================================================================== */
#detail-orbiting-sparks-wrapper.index-spark-mode {
    max-height: 90vh;
    max-height: 90dvh;
    transition: all 0.3s ease;
}

#detail-orbiting-sparks-wrapper.index-spark-mode > div {
    background: rgba(15, 23, 42, 0.75);
    border-color: rgba(245, 158, 11, 0.35);
    box-shadow: 0 10px 30px -5px rgba(0, 0, 0, 0.5), 0 0 25px rgba(245, 158, 11, 0.12);
}

.index-spark-mode #detail-orbiting-sparks-list {
    max-height: min(calc(90vh - 75px), calc(100dvh - 160px)) !important;
}

@media (min-width: 768px) {
    .index-spark-mode #detail-orbiting-sparks-list {
        max-height: min(calc(90vh - 75px), calc(100vh - 140px)) !important;
    }
}

.index-spark-mode .orbit-spark-capsule {
    padding: 0.45rem 0.8rem;
}

/* ==========================================================================
   Spark Batch Edit / Multi-Select Mode Styles
   ========================================================================== */
#sparks-list.batch-mode-active .spark-batch-checkbox-container {
    display: flex !important;
}

#sparks-list.batch-mode-active .spark-row {
    transition: transform 0.15s ease, border-color 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

#sparks-list.batch-mode-active .spark-row.batch-selected {
    border-color: #f59e0b !important;
    background-color: rgba(245, 158, 11, 0.12) !important;
    box-shadow: 0 0 12px rgba(245, 158, 11, 0.25), inset 0 0 0 1px rgba(245, 158, 11, 0.3) !important;
    transform: scale(1.008);
}

/* Container Query for List Panel to make Floating HUD perfectly adaptive at any resized width */
#list-panel {
    container-type: inline-size;
    container-name: listpanel;
}

#desktop-batch-hud {
    box-sizing: border-box !important;
    max-width: 100% !important;
    width: 100% !important;
    overflow: hidden !important;
    transition: opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1), transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@container listpanel (max-width: 440px) {
    #desktop-batch-hud {
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 0.5rem !important;
        padding: 0.625rem 0.75rem !important;
    }
    #desktop-batch-hud .batch-hud-header {
        width: 100% !important;
        display: flex !important;
        justify-content: space-between !important;
        align-items: center !important;
    }
    #desktop-batch-hud .batch-hud-actions {
        width: 100% !important;
        display: flex !important;
        justify-content: space-between !important;
        gap: 0.375rem !important;
    }
    #desktop-batch-hud .batch-hud-actions button {
        flex: 1 1 0px !important;
        min-width: 0 !important;
        padding-left: 0.375rem !important;
        padding-right: 0.375rem !important;
        justify-content: center !important;
        font-size: 11px !important;
    }
}

#mobile-batch-sheet {
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Spark Settings & Security Modal Tabs */
.spark-settings-tab-btn {
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.spark-type-card {
    transition: border-color 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease, transform 0.15s ease;
}

.spark-type-card:hover {
    transform: translateY(-1px);
}

#spark-settings-panel-type:not(.hidden),
#spark-settings-panel-parent:not(.hidden),
#spark-settings-panel-security:not(.hidden),
#spark-settings-panel-emojis:not(.hidden) {
    animation: fadeInSparkTab 0.18s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes fadeInSparkTab {
    from {
        opacity: 0;
        transform: translateY(3px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ==========================================================================
   Checklist Spark Card & Glowing Completion Dial Styles
   ========================================================================== */
.checklist-spark-card {
    transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1),
                box-shadow 0.25s cubic-bezier(0.16, 1, 0.3, 1),
                border-color 0.2s ease,
                background-color 0.2s ease;
    box-shadow: 0 4px 20px -2px rgba(0, 0, 0, 0.45);
}

.checklist-spark-card:hover {
    box-shadow: 0 6px 24px -2px rgba(245, 158, 11, 0.12),
                0 4px 16px -2px rgba(0, 0, 0, 0.5);
    border-color: rgba(245, 158, 11, 0.4) !important;
}

.checklist-dial-container {
    filter: drop-shadow(0 0 10px rgba(245, 158, 11, 0.25));
    transition: filter 0.3s ease, transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.checklist-spark-card:hover .checklist-dial-container {
    filter: drop-shadow(0 0 16px rgba(245, 158, 11, 0.45));
    transform: scale(1.02);
}

.checklist-progress-arc,
.checklist-progress-arc-bloom,
.checklist-progress-arc-core,
.checklist-detail-progress-arc,
.checklist-detail-progress-arc-bloom,
.checklist-detail-progress-arc-core {
    transition: stroke-dashoffset 0.45s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: stroke-dashoffset;
}

.checklist-check-btn {
    background: transparent;
    border: none;
    outline: none;
    user-select: none;
    -webkit-user-select: none;
    touch-action: manipulation;
    text-decoration: none !important;
}

.checklist-check-btn:focus-visible {
    outline: 2px solid rgba(245, 158, 11, 0.6);
    outline-offset: 2px;
    border-radius: 9999px;
}

.checklist-item {
    transition: background-color 0.15s ease, transform 0.1s ease;
    text-decoration: none !important;
    cursor: pointer !important;
    touch-action: manipulation !important;
    pointer-events: auto !important;
    -webkit-tap-highlight-color: rgba(245, 158, 11, 0.2);
}

.checklist-item:hover {
    background-color: rgba(255, 255, 255, 0.05);
    border-radius: 0.5rem;
}

.checklist-item:active {
    transform: scale(0.99);
}

.checklist-dial-container,
.checklist-dial-container svg {
    overflow: visible !important;
}

/* Detail View Checklist Hero & Circular Checkboxes */
.checklist-detail-hero {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
}

.checklist-detail-hero:hover .checklist-dial-container {
    filter: drop-shadow(0 0 18px rgba(245, 158, 11, 0.5));
    transform: scale(1.02);
}

.checklist-rendered-check-btn {
    background: transparent;
    border: none;
    outline: none;
    padding: 0;
    touch-action: manipulation !important;
    pointer-events: auto !important;
    cursor: pointer !important;
    text-decoration: none !important;
}

.checklist-rendered-check-btn:focus-visible {
    outline: 2px solid rgba(245, 158, 11, 0.6);
    outline-offset: 2px;
    border-radius: 9999px;
}

.checklist-task-text {
    line-height: 1.4;
    transition: color 0.15s ease, opacity 0.15s ease;
}

.checklist-task-text.line-through {
    text-decoration: line-through !important;
}

.checklist-action-btn {
    user-select: none;
    -webkit-user-select: none;
    touch-action: manipulation !important;
    pointer-events: auto !important;
    cursor: pointer !important;
    transition: all 0.15s ease;
}

.checklist-action-btn:focus-visible {
    outline: 2px solid rgba(245, 158, 11, 0.6);
    outline-offset: 2px;
}

/* ==========================================================================
   UNIFIED GLASSMORPHIC TOOLBAR & SEARCH/FILTER BAR (Matching Mockup)
   ========================================================================== */

#toolbar-section {
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.toolbar-unified-search-bar {
    background: rgba(15, 23, 42, 0.65);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04), 0 4px 16px rgba(0, 0, 0, 0.25);
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

.toolbar-unified-search-bar:focus-within {
    border-color: rgba(245, 158, 11, 0.4);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 0 16px rgba(245, 158, 11, 0.15), 0 4px 20px rgba(0, 0, 0, 0.3);
    background: rgba(15, 23, 42, 0.85);
}

.toolbar-unified-search-bar #search-filter {
    height: 28px !important;
    line-height: 26px !important;
    padding: 0 10px !important;
    font-size: 12px !important;
    border-radius: 0.65rem !important;
    box-sizing: border-box !important;
    align-self: center !important;
}

.toolbar-filter-pill {
    height: 28px;
    display: inline-flex;
    align-items: center;
    background-color: rgba(30, 41, 59, 0.75);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 9999px;
    padding-left: 10px;
    padding-right: 22px;
    font-size: 11px;
    font-weight: 500;
    color: #cbd5e1;
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2394a3b8'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2.5' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 7px center;
    background-size: 9px 9px;
    max-width: 140px;
    text-overflow: ellipsis;
    white-space: nowrap;
    overflow: hidden;
    line-height: 1;
}

.toolbar-filter-pill.hidden {
    display: none !important;
}

.toolbar-filter-pill:hover {
    background-color: rgba(51, 65, 85, 0.9);
    border-color: rgba(255, 255, 255, 0.22);
    color: #ffffff;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23f1f5f9'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2.5' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
}

.toolbar-filter-pill:focus {
    outline: none;
    border-color: rgba(245, 158, 11, 0.55);
    box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.25);
    color: #ffffff;
}

.toolbar-filter-pill option {
    background-color: #0f172a;
    color: #e2e8f0;
    padding: 6px 10px;
}

@media (max-width: 1100px) and (min-width: 768px) {
    .toolbar-filter-pill {
        max-width: 105px;
        padding-left: 8px;
        padding-right: 18px;
        font-size: 10.5px;
    }
    .toolbar-unified-search-bar {
        min-width: 220px;
    }
}

/* ==========================================================================
   EXPANDABLE QUICK ADD SPARK (Scrolls out to the left)
   ========================================================================== */

#quick-add-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

#quick-add-wrapper .quick-add-slider {
    width: 0;
    max-width: 0;
    opacity: 0;
    margin-right: 0;
    pointer-events: none;
    transition: width 0.35s cubic-bezier(0.4, 0, 0.2, 1),
                max-width 0.35s cubic-bezier(0.4, 0, 0.2, 1),
                opacity 0.25s ease,
                margin-right 0.3s ease;
}

#quick-add-wrapper.expanded .quick-add-slider {
    width: 260px;
    max-width: 260px;
    opacity: 1;
    margin-right: 8px;
    pointer-events: auto;
}

@media (min-width: 1280px) {
    #quick-add-wrapper.expanded .quick-add-slider {
        width: 300px;
        max-width: 300px;
    }
}

#quick-add-wrapper .quick-add-slider input {
    width: 100%;
}

#quick-add-wrapper.expanded #quick-add-toggle-btn {
    background-color: rgba(245, 158, 11, 0.25);
    border-color: rgba(245, 158, 11, 0.6);
    color: #fbbf24;
}

#quick-add-wrapper.expanded #quick-add-icon {
    transform: rotate(45deg);
}

/* ==========================================================================
   Spark Settings Modal Loading Shimmer Bar
   ========================================================================== */
@keyframes sparkSettingsShimmer {
    0% {
        transform: translateX(-100%);
    }
    50% {
        transform: translateX(100%);
    }
    100% {
        transform: translateX(100%);
    }
}

.spark-settings-shimmer {
    animation: sparkSettingsShimmer 1.4s cubic-bezier(0.4, 0, 0.2, 1) infinite;
    will-change: transform;
}
