
    /* :global {*/
        /* ========================================================================
   Main Stylesheet
   ======================================================================== */
        /* 1. Variables and foundations */
        /* ========================================================================
   Variables & CSS Custom Properties
   ======================================================================== */
        :root {
    /* Colors */
    --rp-base: #191724;
    --rp-surface: #1f1d2e;
    --rp-overlay: #26233a;
    --rp-muted: #6e6a86;
    --rp-subtle: #908caa;
    --rp-text: #e0def4;
    --rp-text-dark: #1f210b;
    --rp-love: #eb6f92;
    --rp-gold: #f6c177;
    --rp-rose: #ebbcba;
    --rp-pine: #31748f;
    --rp-foam: #9ccfd8;
    --rp-iris: #c4a7e7;

    --rp-highlight-low: #2a283d;
    --rp-highlight-med: #403d52;
    --rp-highlight-high: #524f67;

    /* Spacing */
    --spacing-xs: 0.25rem;
    --spacing-sm: 0.5rem;
    --spacing-md: 1rem;
    --spacing-lg: 1.5rem;
    --spacing-xl: 2rem;
    --spacing-2xl: 3rem;
    --spacing-3xl: 4rem;

    /* Typography */
    --font-family-base: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --font-family-code: "Cascadia Code Nerd Font";
    --font-size-base: 1rem;
    --font-size-sm: 0.875rem;
    --font-size-md: 1.05rem;
    --font-size-lg: 1.2rem;
    --font-size-xl: 1.5rem;
    --font-size-2xl: clamp(2rem, 5vw, 3.5rem);
    --font-size-3xl: clamp(2rem, 4vw, 2.6rem);
    --font-weight-normal: 400;
    --font-weight-medium: 500;
    --font-weight-semibold: 600;
    --font-weight-bold: 700;
    --font-weight-extrabold: 800;
    --line-height-base: 1.7;
    --line-height-heading: 1.1;
    --line-height-title: 1.2;

    /* Border Radius */
    --border-radius-sm: 6px;
    --border-radius-md: 10px;
    --border-radius-lg: 15px;
    --border-radius-xl: 20px;
    --border-radius-pill: 99px;

    /* Transitions & Animations */
    --transition-speed: 0.3s;
    --transition-ease: cubic-bezier(0.645, 0.045, 0.355, 1);
    --transition-cubic-in-out: cubic-bezier(0.66, 0, 0.34, 1);
    --transition-fast: 0.2s;

    /* Enhanced timing functions for iOS-style animations */
    --spring-ease: cubic-bezier(0.175, 0.885, 0.32, 1.275);
    --bounce-ease: cubic-bezier(0.68, -0.55, 0.265, 1.55);
    --elastic-ease: cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --smooth-ease: cubic-bezier(0.4, 0, 0.2, 1);

    /* Drag animation durations */
    --drag-lift-duration: 0.15s;
    --drag-drop-duration: 0.3s;
    --reorder-duration: 0.25s;
    --hover-response-duration: 0.12s;

    /* Transform values */
    --drag-scale: 1.08;
    --drag-rotate: 3deg;
    --hover-lift: -8px;
    --drop-bounce-scale: 1.02;

    /* Box Shadows */
    --box-shadow-sm: 0 3px 8px rgba(0, 0, 0, 0.3);
    --box-shadow-md: 0 6px 20px rgba(0, 0, 0, 0.4);
    --box-shadow-lg: 0 8px 25px rgba(0, 0, 0, 0.45);
    --box-shadow-xl: 0 10px 30px rgba(0, 0, 0, 0.4);
    --box-shadow-2xl: 0 16px 40px rgba(0, 0, 0, 0.6);
    --box-shadow-3xl: 0 35px 70px rgba(0, 0, 0, 0.7);

    /* Other */
    --hover-scale: 1.04;
    --hover-border-color: var(--rp-love);
}
        /* ========================================================================
   Reset & Base Styles
   ======================================================================== */
        /* Box Model Reset */
        *,
::after,
::before {
    box-sizing: border-box;
    font-family: var(--font-family-base);
}
        /* Document Setup */
        html,
body {
    margin: 0;
    padding: 0;
    background-color: var(--rp-base);
    color: var(--rp-text);
    font-family: var(--font-family-base);
    line-height: var(--line-height-base);
    scroll-behavior: smooth;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}
        /* Image Optimization */
        img {
    image-rendering: crisp-edges;
    max-width: 100%;
    height: auto;
}
        /* Button Reset */
        button {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    font: inherit;
    color: inherit;
}
        /* 2. Animations and transitions */
        /* ========================================================================
   Animations & Keyframes
   ======================================================================== */
        /* Core Transition Classes */
        .fade-enter-active,
.fade-leave-active {
    transition: opacity var(--transition-speed) var(--transition-ease);
}
        .fade-enter-from,
.fade-leave-to {
    opacity: 0;
}
        .fade-slide-enter-active,
.fade-slide-leave-active {
    transition:
        opacity var(--transition-speed) var(--transition-ease),
        transform var(--transition-speed) var(--transition-ease);
}
        .fade-slide-enter-from,
.fade-slide-leave-to {
    opacity: 0;
    transform: translateY(20px);
}
        /* Staggered Animations */
        .staggered-item-enter-active {
    animation: fadeInScale 0.6s var(--transition-ease);
}
        .staggered-item-leave-active {
    animation: fadeOutScale 0.4s var(--transition-ease);
}
        /* ========================================================================
   Keyframe Animations
   ======================================================================== */
        /* Fade Animations */
        @keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}
        @keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
        @keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}
        @keyframes fadeInSlideIn {
    from {
        opacity: 0;
        transform: translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}
        @keyframes fadeOutScale {
    from {
        opacity: 1;
        transform: scale(1);
    }
    to {
        opacity: 0;
        transform: scale(0.9);
    }
}
        /* Slide Animations */
        @keyframes slideInFromTop {
    from {
        opacity: 0;
        transform: translateY(-10px) scaleY(0.8);
    }
    to {
        opacity: 1;
        transform: translateY(0) scaleY(1);
    }
}
        @keyframes slideOutToTop {
    from {
        opacity: 1;
        transform: translateY(0) scaleY(1);
    }
    to {
        opacity: 0;
        transform: translateY(-10px) scaleY(0.8);
    }
}
        @keyframes slideInFromLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}
        @keyframes slideInFromRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}
        /* Scale & Bounce Animations */
        @keyframes bounceIn {
    0% {
        transform: scale(0.8);
        opacity: 0;
    }
    50% {
        transform: scale(1.05);
        opacity: 1;
    }
    100% {
        transform: scale(1);
    }
}
        @keyframes popIn {
    0% {
        transform: scale(0);
    }
    80% {
        transform: scale(1.15);
    }
    100% {
        transform: scale(1);
    }
}
        @keyframes pulse {
    0%,
    100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}
        /* Overlay Animations */
        @keyframes fadeOverlayIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}
        @keyframes fadeOverlayOut {
    from {
        opacity: 1;
    }
    to {
        opacity: 0;
    }
}
        @keyframes fadeBackdropIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}
        @keyframes fadeBackdropOut {
    from {
        opacity: 1;
    }
    to {
        opacity: 0;
    }
}
        @keyframes expandIn {
    from {
        opacity: 0;
        transform: scale(0.7);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}
        @keyframes contractOut {
    from {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
    to {
        opacity: 0;
        transform: scale(0.7);
    }
}
        @keyframes morphToList {
    from {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.3;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
        column-count: 1;
    }
}
        @keyframes morphToGrid {
    from {
        opacity: 1;
        transform: scale(1);
        column-count: 1;
    }
    50% {
        opacity: 0.3;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}
        @keyframes cardMorphToList {
    from {
        flex-direction: column;
        transform: scale(1);
    }
    to {
        flex-direction: row;
        transform: scale(1);
    }
}
        @keyframes cardMorphToGrid {
    from {
        flex-direction: row;
        transform: scale(1);
    }
    to {
        flex-direction: column;
        transform: scale(1);
    }
}
        @keyframes menuItemsSlideIn {
    from {
        opacity: 0;
        transform: translateX(-20px) scale(0.8);
    }
    to {
        opacity: 1;
        transform: translateX(0) scale(1);
    }
}
        @keyframes slideInFade {
    from {
        opacity: 0;
        transform: translateX(-10px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}
        @keyframes nestedMenuSlideIn {
    from {
        opacity: 0;
        transform: translateX(-20px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateX(0) scale(1);
    }
}
        @keyframes elasticDrop {
    0% {
        transform: scale(var(--drag-scale)) rotate(var(--drag-rotate)) translateY(var(--hover-lift))
            translateZ(0);
        box-shadow:
            0 20px 60px rgba(0, 0, 0, 0.3),
            0 8px 25px rgba(0, 0, 0, 0.2);
    }
    40% {
        transform: scale(var(--drop-bounce-scale)) rotate(0deg) translateY(0) translateZ(0);
        box-shadow:
            0 12px 40px rgba(0, 0, 0, 0.25),
            0 4px 15px rgba(0, 0, 0, 0.15);
    }
    70% {
        transform: scale(0.98) rotate(0deg) translateY(0) translateZ(0);
        box-shadow: var(--box-shadow-md);
    }
    100% {
        transform: scale(1) rotate(0deg) translateY(0) translateZ(0);
        box-shadow: var(--box-shadow-md);
    }
}
        @keyframes liftOff {
    0% {
        transform: scale(1) rotate(0deg) translateY(0) translateZ(0);
        box-shadow: var(--box-shadow-md);
        filter: brightness(1) saturate(1);
    }
    100% {
        transform: scale(var(--drag-scale)) rotate(var(--drag-rotate)) translateY(var(--hover-lift))
            translateZ(0);
        box-shadow:
            0 20px 60px rgba(0, 0, 0, 0.3),
            0 8px 25px rgba(0, 0, 0, 0.2),
            0 0 0 1px rgba(255, 255, 255, 0.1);
        filter: brightness(1.1) saturate(1.2);
    }
}
        @keyframes dropZonePulse {
    0%,
    100% {
        box-shadow:
            0 0 30px rgba(196, 167, 231, 0.2),
            inset 0 0 0 2px var(--rp-iris);
        transform: scale(0.96) translateY(calc(var(--hover-lift) * 0.3));
    }
    50% {
        box-shadow:
            0 0 40px rgba(196, 167, 231, 0.4),
            inset 0 0 0 3px var(--rp-iris);
        transform: scale(0.94) translateY(calc(var(--hover-lift) * 0.4));
    }
}
        @keyframes successRipple {
    0% {
        box-shadow:
            0 0 0 0 rgba(156, 207, 216, 0.7),
            var(--box-shadow-md);
    }
    70% {
        box-shadow:
            0 0 0 20px rgba(156, 207, 216, 0),
            var(--box-shadow-md);
    }
    100% {
        box-shadow:
            0 0 0 0 rgba(156, 207, 216, 0),
            var(--box-shadow-md);
    }
}
        @keyframes smoothReorder {
    0% {
        opacity: 1;
        transform: scale(1) translateZ(0);
    }
    50% {
        opacity: 0.8;
        transform: scale(0.95) translateZ(0);
    }
    100% {
        opacity: 1;
        transform: scale(1) translateZ(0);
    }
}
        /* 3. Layout systems */
        /* ========================================================================
   Layout Components
   ======================================================================== */
        /* Main Gallery Container */
        .book-gallery {
    padding: var(--spacing-2xl) var(--spacing-xl);
    max-width: 100%;
    margin: 0 auto;
    position: relative;
    background-color: var(--rp-base);
    min-height: 100vh;
    overflow: visible;
    flex-grow: 1;
}
        .book-gallery.idle-background {
    background-image: url("../../../images/deathtoamerica.gif");
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    transition: background-image 1s ease-in-out;
    z-index: 1;
}
        /* Gallery Title */
        .gallery-title {
    text-align: center;
    margin-bottom: 3.5rem;
    font-size: clamp(2rem, 5vw, 3.5rem);
    color: var(--rp-iris);
    font-weight: 800;
    letter-spacing: -0.04em;
    text-shadow:
        0 0 20px rgba(196, 167, 231, 0.3),
        0 0 40px rgba(196, 167, 231, 0.1);
    line-height: 1.1;
    background: linear-gradient(90deg, var(--rp-iris) 0%, var(--rp-foam) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: fadeInDown 1s var(--transition-ease) forwards;
    opacity: 0;
}
        /* Progress Bar */
        .progress-wrapper {
    margin: var(--spacing-xl) 0;
    padding: var(--spacing-lg) 1.8rem;
    text-align: center;
    background-color: var(--rp-surface);
    border-radius: var(--border-radius-lg);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
    border: 1px solid var(--rp-highlight-low);
    display: flex;
    flex-direction: column;
    align-items: center;
    animation: fadeIn 1s var(--transition-ease) 0.5s forwards;
    opacity: 0;
}
        .progress-bar {
    width: 100%;
    max-width: 600px;
    height: 28px;
    background-color: var(--rp-overlay);
    border-radius: 14px;
    overflow: hidden;
    margin-bottom: var(--spacing-md);
    border: 1px solid var(--rp-highlight-med);
    box-shadow: inset 0 2px 5px rgba(0, 0, 0, 0.1);
}
        .progress-fill {
    height: 100%;
    background: linear-gradient(to right, var(--rp-foam), var(--rp-pine), var(--rp-iris));
    transition: width 0.5s var(--transition-ease);
    border-radius: 14px 0 0 14px;
    box-shadow: 0 0 10px rgba(156, 207, 216, 0.5);
}
        .progress-text {
    font-size: var(--font-size-lg);
    color: var(--rp-subtle);
    font-weight: 600;
    letter-spacing: 0.02em;
}
        /* Backdrop */
        .backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(25, 23, 36, 0.85);
    z-index: 999;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    transition:
        opacity var(--transition-speed) var(--transition-ease),
        backdrop-filter var(--transition-speed) var(--transition-ease);
}
        /* ========================================================================
   Grid System & Layout Modes
   ======================================================================== */
        /* Book Grid Base */
        .book-grid {
    column-count: 3;
    column-gap: var(--spacing-xl);
    width: 100%;
    padding-bottom: var(--spacing-2xl);
    transition: all 0.6s var(--transition-ease);
    position: relative;
}
        .book-grid > * {
    break-inside: avoid-column;
    margin-bottom: var(--spacing-xl);
    transition:
        transform var(--reorder-duration) var(--spring-ease),
        opacity var(--reorder-duration) var(--smooth-ease);
}
        /* Grid Transitions */
        .book-grid.transitioning {
    opacity: 0.7;
    pointer-events: none;
}
        .book-grid.entering-list {
    animation: morphToList 0.6s var(--transition-ease) forwards;
}
        .book-grid.entering-grid {
    animation: morphToGrid 0.6s var(--transition-ease) forwards;
}
        /* Enhanced Reordering State */
        .book-grid.is-reordering > * {
    transition:
        transform var(--reorder-duration) var(--elastic-ease),
        opacity var(--reorder-duration) var(--smooth-ease);
}
        /* Smooth repositioning for non-dragged cards */
        .book-grid:not(.is-reordering) > .book-card:not(.is-dragging):not(.is-dragged-over) {
    transition:
        transform var(--reorder-duration) var(--elastic-ease),
        box-shadow var(--hover-response-duration) var(--smooth-ease);
}
        /* List View */
        .book-grid.list-view {
    column-count: 1;
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
    animation: slideInFromLeft 0.4s var(--transition-ease) forwards;
}
        .book-grid.list-view > * {
    break-inside: initial;
    margin-bottom: 0;
    opacity: 0;
    animation: slideInFromRight 0.5s var(--transition-ease) forwards;
    will-change: transform, opacity;
}
        /* Staggered Animation Delays */
        .book-grid.list-view > :nth-child(1) {
    animation-delay: 0.1s;
}
        .book-grid.list-view > :nth-child(2) {
    animation-delay: 0.15s;
}
        .book-grid.list-view > :nth-child(3) {
    animation-delay: 0.2s;
}
        .book-grid.list-view > :nth-child(4) {
    animation-delay: 0.25s;
}
        .book-grid.list-view > :nth-child(5) {
    animation-delay: 0.3s;
}
        .book-grid.list-view > :nth-child(6) {
    animation-delay: 0.35s;
}
        .book-grid.list-view > :nth-child(7) {
    animation-delay: 0.4s;
}
        .book-grid.list-view > :nth-child(8) {
    animation-delay: 0.45s;
}
        .book-grid.list-view > :nth-child(9) {
    animation-delay: 0.5s;
}
        .book-grid.list-view > :nth-child(n + 10) {
    animation-delay: 0.55s;
}
        /* Grid View Animation Delays */
        .book-grid:not(.list-view) > * {
    animation: fadeInScale 0.5s var(--transition-ease) forwards;
    opacity: 0;
}
        .book-grid:not(.list-view) > :nth-child(1) {
    animation-delay: 0.1s;
}
        .book-grid:not(.list-view) > :nth-child(2) {
    animation-delay: 0.15s;
}
        .book-grid:not(.list-view) > :nth-child(3) {
    animation-delay: 0.2s;
}
        .book-grid:not(.list-view) > :nth-child(4) {
    animation-delay: 0.25s;
}
        .book-grid:not(.list-view) > :nth-child(5) {
    animation-delay: 0.3s;
}
        .book-grid:not(.list-view) > :nth-child(6) {
    animation-delay: 0.35s;
}
        .book-grid:not(.list-view) > :nth-child(7) {
    animation-delay: 0.4s;
}
        .book-grid:not(.list-view) > :nth-child(8) {
    animation-delay: 0.45s;
}
        .book-grid:not(.list-view) > :nth-child(9) {
    animation-delay: 0.5s;
}
        .book-grid:not(.list-view) > :nth-child(n + 10) {
    animation-delay: 0.55s;
}
        /* 4. Component styles */
        /* ========================================================================
   Book Card Components
   ======================================================================== */
        .book-card {
    animation: fadeInScale 0.6s var(--transition-ease) forwards;
    background-color: var(--rp-surface);
    border: 2px solid var(--rp-highlight-low);
    border-radius: var(--border-radius-xl);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.45);
    cursor: pointer;
    display: flex;
    flex-direction: column;
    opacity: 0;
    overflow: hidden;
    position: relative;
    transform: scale(0.9);
    width: 100%;

    /* Enhanced base properties for better animation performance */
    transform-origin: center;
    will-change: transform, box-shadow, filter;
    backface-visibility: hidden;
    z-index: 1;

    /* Smooth base transition */
    transition:
        transform var(--hover-response-duration) var(--smooth-ease),
        box-shadow var(--hover-response-duration) var(--smooth-ease),
        border-color var(--hover-response-duration) var(--smooth-ease),
        filter var(--hover-response-duration) var(--smooth-ease);
}
        /* ========================================================================
   Drag-N-Drop
   ======================================================================== */
        .book-card.is-dragging {
    transform: scale(var(--drag-scale)) rotate(var(--drag-rotate)) translateY(var(--hover-lift))
        translateZ(0);

    box-shadow:
        0 20px 60px rgba(0, 0, 0, 0.3),
        0 8px 25px rgba(0, 0, 0, 0.2),
        0 0 0 1px rgba(255, 255, 255, 0.1);

    filter: brightness(1.1) saturate(1.2);
    border-color: var(--rp-iris);
    z-index: 1000;
    opacity: 0.95;
    cursor: grabbing;

    transition:
        transform var(--drag-lift-duration) var(--spring-ease),
        box-shadow var(--drag-lift-duration) var(--spring-ease),
        filter var(--drag-lift-duration) var(--spring-ease),
        border-color var(--drag-lift-duration) var(--spring-ease);
}
        .book-card.is-dragged-over {
    transform: translateY(calc(var(--hover-lift) * 0.3)) scale(0.96) translateZ(0);

    box-shadow:
        0 0 30px rgba(196, 167, 231, 0.4),
        0 4px 20px rgba(196, 167, 231, 0.2),
        inset 0 0 0 2px var(--rp-iris);

    border-color: var(--rp-iris);
    background: linear-gradient(
        135deg,
        var(--rp-surface) 0%,
        rgba(196, 167, 231, 0.08) 50%,
        var(--rp-overlay) 100%
    );

    animation: dropZonePulse 1s var(--elastic-ease) infinite;

    transition:
        transform var(--hover-response-duration) var(--elastic-ease),
        box-shadow var(--hover-response-duration) var(--elastic-ease),
        background var(--hover-response-duration) var(--smooth-ease);
}
        .book-card.is-dropping {
    animation:
        elasticDrop var(--drag-drop-duration) var(--bounce-ease) forwards,
        successRipple 0.6s var(--smooth-ease) 0.1s forwards;
}
        .book-card:hover:not(.expanded):not(.is-dragging):not(.is-dragged-over) {
    transform: translateY(calc(var(--hover-lift) * 0.6)) scale(1.02) translateZ(0);

    box-shadow:
        0 12px 40px rgba(0, 0, 0, 0.4),
        0 4px 15px rgba(0, 0, 0, 0.2);

    border-color: var(--hover-border-color, var(--rp-love));
    background: linear-gradient(135deg, var(--rp-surface) 0%, var(--rp-overlay) 100%);

    transition:
        transform var(--hover-response-duration) var(--elastic-ease),
        box-shadow var(--hover-response-duration) var(--elastic-ease),
        border-color var(--hover-response-duration) var(--smooth-ease),
        background var(--hover-response-duration) var(--smooth-ease);
}
        .book-card:hover:not(.expanded):not(.is-dragging):not(.is-dragged-over)::after {
    opacity: 1;
}
        .book-card:hover:not(.expanded):not(.is-dragging):not(.is-dragged-over) .cover-image {
    transform: scale(var(--hover-scale));
}
        .book-card:hover:not(.expanded):not(.is-dragging):not(.is-dragged-over) .cover-image-small {
    transform: scale(var(--hover-scale));
    will-change: transform;
}
        .book-card::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 50%;
    background: linear-gradient(
        to top,
        rgba(196, 167, 231, 0.08) 0%,
        rgba(196, 167, 231, 0.04) 40%,
        transparent 100%
    );
    opacity: 0;
    transition: opacity var(--transition-speed) var(--transition-ease);
    z-index: 1;
    will-change: opacity;
    pointer-events: none;
}
        /* ========================================================================
   Cover Images
   ======================================================================== */
        .book-cover {
    border-radius: var(--border-radius-lg) var(--border-radius-lg) 0 0;
    line-height: 0;
    overflow: hidden;
    position: relative;
    width: 100%;
}
        .cover-image {
    width: 100%;
    height: fit-content;
    object-fit: cover;
    transition: transform var(--transition-speed) var(--transition-ease);
}
        .book-cover-small {
    position: relative;
    width: 80px;
    height: 120px;
    border-radius: var(--border-radius-sm);
    overflow: hidden;
    flex-shrink: 0;
}
        .cover-image-small {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-speed) var(--transition-ease);
}
        /* ========================================================================
   Book Information
   ======================================================================== */
        .book-info {
    padding: 1.8rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 2;
}
        .book-title {
    font-size: clamp(1.1rem, 1.5vw, 1.35rem);
    font-weight: 800;
    margin-bottom: 0.7rem;
    color: var(--rp-text);
    line-height: 1.3;
    letter-spacing: -0.03em;
}
        .book-author {
    color: var(--rp-subtle);
    font-size: clamp(0.9rem, 1.2vw, 1.1rem);
    font-style: italic;
    margin: 0 0 var(--spacing-md);
}
        /* ========================================================================
   Tags & Genres
   ======================================================================== */
        .book-genres,
.book-tags {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-sm);
    margin-bottom: 1.2rem;
    min-width: 100%;
}
        .book-genre,
.book-tag {
    background-color: var(--rp-highlight-low);
    border-radius: 25px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
    color: var(--rp-text);
    font-weight: 600;
    opacity: 0.95;
    padding: 0.35rem 0.9rem;
    transition:
        background 0.2s,
        transform 0.2s,
        box-shadow 0.2s;
}
        .book-genre:hover,
.book-tag:hover {
    background-color: var(--rp-foam);
    transform: translateY(-2px);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.25);
}
        .read-status {
    background-color: var(--rp-highlight-high);
    border-radius: 25px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
    color: var(--rp-text);
    display: inline-block;
    font-size: var(--font-size-sm);
    font-weight: 600;
    margin-bottom: 1.2rem;
    opacity: 0.95;
    padding: 0.35rem 0.9rem;
    transition: transform var(--transition-speed) var(--transition-ease);
}
        .read-status:hover {
    transform: translateY(-2px);
}
        /* ========================================================================
   Rating System
   ======================================================================== */
        .book-rating {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    margin-top: auto;
    padding-top: 1.2rem;
    padding-bottom: var(--spacing-sm);
    border-top: 1px solid var(--rp-highlight-med);
}
        .stars {
    display: flex;
    gap: 0.2rem;
}
        .star {
    color: var(--rp-muted);
    font-size: var(--font-size-2xl);
    transition: color 0.2s;
}
        .star.filled {
    color: var(--rp-gold);
    text-shadow:
        0 0 8px rgba(246, 193, 119, 0.5),
        0 0 15px rgba(246, 193, 119, 0.2);
    animation: bounceIn 0.5s var(--transition-ease);
}
        .percent-progress-bar-container {
    position: relative;
    background-color: var(--rp-surface);
    border: none;
    box-shadow: var(--box-shadow-lg);
    border-radius: 99px;
    overflow: hidden;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    padding: 5px 15px;
    isolation: isolate;
}
        .percent-progress-bar {
    background-color: var(--rp-love);
    height: 100%;
    position: absolute;
    border-radius: 50px;
    top: 0;
    left: 0;
    transition: width var(--transition-speed) var(--transition-ease);
}
        .progress-bar-text {
    position: relative;
    z-index: 2;
    color: var(--rp-text);
    mix-blend-mode: difference;
    font-family: var(--font-family-base) !important;
    font-weight: 400;
    letter-spacing: 1px;
    font-size: var(--font-size-sm);
    white-space: nowrap;
}
        .percocet {
    font-family: var(--font-family-code) !important;
}
        .is-dragging {
    opacity: 0.5;
    transform: scale(0.95);
    cursor: grabbing;
    transition:
        transform 0.2s ease-out,
        opacity 0.2s ease-out;
    transition:
        transform 0.3s var(--transition-ease),
        box-shadow 0.3s var(--transition-ease),
        opacity 0.3s var(--transition-ease);
}
        .is-dragged-over {
    border-color: var(--rp-iris) !important;
    box-shadow: 0 0 20px rgba(196, 167, 231, 0.5);
    transform: scale(0.98);
    border-radius: var(--border-radius-xl);
    transition: transform 0.2s var(--transition-ease);
}
        .book-card.is-dragging {
    opacity: 0.5;
    transform: scale(0.95);
    cursor: grabbing;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}
        .book-card.is-dragged-over {
    border-color: var(--rp-iris) !important;
    box-shadow: 0 0 20px rgba(196, 167, 231, 0.5);
    transform: translateY(0) scale(1);
}
        .book-card.is-dragging,
.book-card.is-dragged-over,
.book-card:hover {
    transform: translateZ(0);
    will-change: transform, box-shadow;
}
        /* ========================================================================
   List View Components
   ======================================================================== */
        /* List Item Container */
        .book-list-item {
    align-items: center;
    display: flex;
    gap: var(--spacing-md);
    padding: var(--spacing-lg);
    opacity: 0;
    animation: slideInFromRight 0.5s var(--transition-ease) forwards;
}
        /* List View Card Modifications */
        .book-card.list-view {
    transition: all 0.5s var(--transition-ease);
}
        .book-card.transitioning-to-list {
    animation: cardMorphToList 0.5s var(--transition-ease) forwards;
}
        .book-card.transitioning-to-grid {
    animation: cardMorphToGrid 0.5s var(--transition-ease) forwards;
}
        /* Book Details Section */
        .book-details {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    min-width: max-content;
    transition: all 0.4s var(--transition-ease);
}
        .book-primary-info {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    margin-bottom: var(--spacing-sm);
}
        /* List View Typography */
        .book-title-list {
    font-size: 1.2rem;
    font-weight: 700;
    margin: 0;
    color: var(--rp-text);
    line-height: 1.3;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
        .book-author-list {
    font-size: 0.95rem;
    color: var(--rp-subtle);
    margin: 0;
    font-style: italic;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
        /* List View Meta Information */
        .book-meta {
    align-items: center;
    display: flex;
    gap: var(--spacing-md);
    flex-wrap: wrap;
}
        .book-rating-list {
    display: flex;
    align-items: center;
}
        /* List View Stars */
        .stars-small {
    display: flex;
    gap: 0.1rem;
}
        .star-small {
    color: var(--rp-muted);
    font-size: 0.9rem;
    transition: color 0.2s;
}
        .star-small.filled {
    color: var(--rp-gold);
}
        /* List View Tags & Status */
        .book-genres-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}
        .book-genre-small,
.read-status-list {
    color: var(--rp-text);
    padding: 0.2rem 0.6rem;
    font-size: 0.75rem;
    border-radius: var(--border-radius-md);
    white-space: nowrap;
}
        .read-status-list {
    background-color: var(--rp-highlight-med);
    font-weight: 600;
}
        .book-genre-small {
    background-color: var(--rp-highlight-low);
    font-weight: 500;
    opacity: 0.9;
}
        /* ========================================================================
   Explicit Content Handling
   ======================================================================== */
        /* Base Explicit Content Overlay */
        .book-card.explicit-content::before,
.book-expanded.explicit-content::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(40px);
    -webkit-backdrop-filter: blur(40px);
    z-index: 5;
    transition:
        opacity 0.3s,
        backdrop-filter 0.3s;
    pointer-events: none;
    will-change: backdrop-filter, opacity;
}
        /* Hide blur on hover/expand */
        .book-card.expanded.explicit-content::before,
.book-card:hover.explicit-content::before,
.book-expanded.show.explicit-content::before {
    opacity: 0;
    backdrop-filter: blur(0);
    -webkit-backdrop-filter: blur(0);
}
        /* ========================================================================
   Explicit Content Icons - Grid View
   ======================================================================== */
        .explicit-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    z-index: 10;
    opacity: 1;
    transition: opacity 0.3s;
    pointer-events: none;
}
        .explicit-icon * {
    pointer-events: none;
}
        .book-card.expanded .explicit-icon,
.book-card:hover .explicit-icon,
.book-expanded.show .explicit-icon {
    opacity: 0;
}
        .icon-warning {
    font-size: 4em;
    color: var(--rp-love);
    text-shadow: 0 0 10px rgba(0, 0, 0, 0.7);
}
        .explicit-label {
    font-size: 1.1em;
    font-weight: 700;
    color: var(--rp-gold);
    background-color: rgba(0, 0, 0, 0.6);
    padding: 15px;
    margin-top: var(--spacing-md);
    border-radius: 99px;
    white-space: nowrap;
}
        /* ========================================================================
  Explicit Content Icons - List View
  ======================================================================== */
        .explicit-icon-small {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    z-index: 15;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s;
    pointer-events: none;
    width: 60px;
    height: 60px;
}
        .explicit-icon-small.visible {
    opacity: 1;
    visibility: visible;
}
        .explicit-icon-small * {
    pointer-events: none;
    z-index: inherit;
}
        .icon-warning-small {
    font-size: 1.8rem;
    color: var(--rp-love);
    text-shadow: 0 0 5px rgba(0, 0, 0, 0.7);
    position: relative;
    z-index: 200;
}
        .explicit-label-small {
    font-size: 0.6rem;
    font-weight: 700;
    color: var(--rp-gold);
    background-color: rgba(0, 0, 0, 0.7);
    padding: 3px 8px;
    border-radius: 10px;
    white-space: nowrap;
    position: relative;
    z-index: 16;
}
        /* List View Explicit Content Blur */
        .book-card.list-view.explicit-content .book-cover-small::before {
    content: "";
    position: absolute;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 5;
    opacity: 1;
    transition:
        opacity 0.3s,
        backdrop-filter 0.3s;
    pointer-events: none;
}
        .book-card.list-view.expanded.explicit-content .book-cover-small::before,
.book-card.list-view:hover.explicit-content .book-cover-small::before {
    opacity: 1;
    backdrop-filter: blur(0);
    -webkit-backdrop-filter: blur(0);
}
        .book-card.expanded .explicit-icon-small,
.book-card.list-view:hover .explicit-icon-small,
.book-card:hover .explicit-icon-small {
    opacity: 1;
}
        /* ========================================================================
   Filter System
   ======================================================================== */
        /* Filter Pill (Main Search Bar) */
        .filter-pill {
    display: flex;
    align-items: center;
    background-color: var(--rp-overlay);
    border-radius: var(--border-radius-pill);
    border: 2px solid var(--rp-highlight-low);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
    padding: 0.5rem 1.4rem;
    max-width: 600px;
    width: calc(100% - 2rem);
    height: 80px;
    margin: 2.5rem auto 3rem;
    gap: var(--spacing-md);
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    transition: all var(--transition-speed) var(--transition-ease);
    animation: fadeInDown 0.8s var(--transition-ease) 0.3s forwards;
    opacity: 0;
}
        .filter-pill::-webkit-scrollbar {
    display: none;
}
        .filter-pill:focus-within {
    box-shadow:
        0 0 0 4px var(--rp-pine),
        0 6px 20px rgba(0, 0, 0, 0.5);
    border-color: var(--rp-pine);
    transform: translateY(-2px);
}
        /* Search Input */
        .pill-search-input {
    flex: 1;
    background: none;
    border: none;
    outline: none;
    font-size: 1.2rem;
    color: var(--rp-text);
    padding: 0;
    letter-spacing: 0.01em;
    min-width: 0;
}
        .pill-search-input::placeholder {
    color: var(--rp-muted);
    opacity: 0.9;
}
        /* Filter Toggle Button */
        .pill-filter-btn {
    background-color: var(--rp-surface);
    border: none;
    border-radius: 50%;
    width: 2.5rem;
    height: 2.5rem;
    margin: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--rp-iris);
    font-weight: 700;
    font-size: 1.5rem;
    flex-shrink: 0;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.3);
    transition: all 0.25s var(--transition-ease);
}
        .pill-filter-btn:hover {
    background-color: var(--rp-highlight-med);
    color: var(--rp-foam);
    transform: scale(1.1);
    box-shadow: 0 5px 12px rgba(0, 0, 0, 0.4);
}
        /* ========================================================================
   Advanced Filter Bar
   ======================================================================== */
        .filter-bar {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
    padding: var(--spacing-xl);
    border-radius: var(--border-radius-xl);
    margin: var(--spacing-lg) auto;
    max-width: 850px;
    background-color: var(--rp-surface);
    color: var(--rp-text);
    border: 2px solid var(--rp-highlight-low);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}
        .filter-bar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.8rem;
}
        .filter-heading {
    color: var(--rp-iris);
    margin: 0;
    font-size: var(--font-size-3xl);
    font-weight: 700;
    letter-spacing: -0.02em;
}
        .collapse-btn {
    background: none;
    border: none;
    color: var(--rp-love);
    font-size: var(--spacing-xl);
    cursor: pointer;
    /* height: 2.75rem; */
    transition:
        transform 0.3s var(--transition-ease),
        color 0.3s var(--transition-ease);
}
        .collapse-btn:hover {
    transform: rotate(180deg) scale(1.15);
    color: var(--rp-love);
}
        .filter-bar-header .collapse-btn {
    background-color: transparent;
    border: none;
    font-size: var(--spacing-xl);
    cursor: pointer;
    color: var(--rp-text);
    padding: 0 10px;
}
        .filter-bar-header .collapse-btn:hover {
    background-color: transparent !important;
    color: var(--rp-love);
}
        /* Filter Inputs */
        .filter-bar input,
.filter-bar select {
    padding: 0.8rem var(--spacing-md);
    background-color: var(--rp-base);
    border: 1px solid var(--rp-highlight-med);
    border-radius: 10px;
    color: var(--rp-text);
    font-size: 1.05rem;
    transition:
        border-color 0.2s,
        box-shadow 0.2s;
}
        .filter-bar input::placeholder {
    color: var(--rp-muted);
}
        .filter-bar input:focus,
.filter-bar select:focus {
    border-color: var(--rp-iris);
    box-shadow:
        0 0 0 4px var(--rp-iris),
        0 0 0 6px rgba(196, 167, 231, 0.4);
    outline: none;
}
        /* Clear Filters Button */
        .clear-filters-btn {
    align-self: flex-end;
    background-color: var(--rp-love);
    border: none;
    padding: 0.8rem 1.4rem;
    border-radius: var(--border-radius-md);
    color: var(--rp-text);
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.3);
    transition:
        background 0.25s var(--transition-ease),
        transform 0.25s var(--transition-ease),
        box-shadow 0.25s var(--transition-ease);
}
        .clear-filters-btn:hover {
    background-color: var(--rp-gold);
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.4);
}
        /* ========================================================================
   Multi-Select Dropdowns
   ======================================================================== */
        .multi-select {
    margin: 1.2rem 0;
}
        .multi-select label {
    display: block;
    margin-bottom: 0.6rem;
    font-weight: 700;
    color: var(--rp-foam);
    font-size: 1.2rem;
    letter-spacing: 0.02em;
}
        .dropdown {
    position: relative;
    background-color: var(--rp-overlay);
    border: 1px solid var(--rp-highlight-med);
    border-radius: var(--border-radius-md);
    padding: 0.7rem 1.2rem;
    color: var(--rp-text);
    cursor: pointer;
    user-select: none;
    outline: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    transition:
        background-color 0.25s var(--transition-ease),
        border-color 0.25s var(--transition-ease),
        box-shadow 0.25s var(--transition-ease);
}
        .dropdown:hover {
    background-color: var(--rp-highlight-med);
    border-color: var(--rp-iris);
}
        .dropdown:focus {
    border-color: var(--rp-pine);
    box-shadow:
        0 0 0 4px var(--rp-pine),
        0 0 0 6px rgba(49, 116, 143, 0.4);
}
        .dropdown-selected {
    display: flex;
    justify-content: space-between;
    align-items: center;
    min-height: 2rem;
    font-weight: 600;
    font-size: 1.1rem;
}
        .placeholder {
    color: var(--rp-muted);
    font-style: italic;
}
        .selected-items {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 90%;
}
        .dropdown-arrow {
    position: relative;
    font-size: 1.2rem;
    margin-left: 0.8rem;
    color: var(--rp-foam);
    transition: transform 0.2s;
    z-index: 1;
    user-select: none;
}
        /* Dropdown List */
        .dropdown-list {
    position: absolute;
    top: calc(100% + 0.6rem);
    left: 0;
    right: 0;
    max-height: 300px;
    overflow-y: auto;
    background-color: var(--rp-overlay);
    border: 1px solid var(--rp-highlight-med);
    border-radius: var(--border-radius-md);
    z-index: 101;
    box-shadow: 0 8px 25px rgba(25, 23, 36, 0.8);
    padding: var(--spacing-sm) 0;
    list-style: none;
    margin: 0;
    animation: slideInFromTop 0.3s var(--transition-ease) forwards;
    transform-origin: top;
    opacity: 0;
}
        .dropdown-list.closing {
    animation: slideOutToTop 0.3s var(--transition-ease) forwards;
}
        .dropdown-list li {
    padding: 0.7rem 1.4rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    color: var(--rp-text);
    font-weight: 500;
    font-size: 1.05rem;
    user-select: none;
    transition: background-color 0.2s;
}
        .dropdown-list li:hover {
    background-color: var(--rp-highlight-low);
}
        .dropdown-list li.selected {
    background-color: var(--rp-highlight-med);
    color: var(--rp-text);
    font-weight: 700;
}
        .selected-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 5px; /* Adjust as needed for spacing between pills */
}
        .pill {
    display: inline-flex;
    align-items: center;
    background-color: var(--rp-base); /* Example background color */
    border-radius: 999px;
    padding-left: 10px;
    padding-right: 12px;
    font-size: 0.8em;
}
        .pill-deselect-btn {
    background: none;
    border: none;
    color: var(--rp-love);
    cursor: pointer;
    margin-left: 5px;
    font-size: 1.5em;
    padding: 0;
    margin-left: 12px;
}
        /* ========================================================================
   Custom Checkboxes
   ======================================================================== */
        input[type="checkbox"] {
    -webkit-appearance: none;
    appearance: none;
    width: 1.2em;
    height: 1.2em;
    border: 2px solid var(--rp-pine);
    border-radius: 5px;
    margin-right: 0.8rem;
    display: grid;
    place-content: center;
    flex-shrink: 0;
    transition:
        background-color 0.25s var(--transition-ease),
        border-color 0.25s var(--transition-ease);
}
        input[type="checkbox"]::before {
    content: "";
    width: 0.8em;
    height: 0.8em;
    transform: scale(0);
    transition: transform 150ms var(--transition-ease);
    box-shadow: inset 1em 1em var(--rp-rose);
    clip-path: polygon(14% 44%, 0 65%, 50% 100%, 100% 16%, 80% 0%, 43% 62%);
    background-color: var(--rp-rose);
}
        input[type="checkbox"]:checked {
    background-color: var(--rp-pine);
    border-color: var(--rp-pine);
    animation: popIn 0.3s var(--transition-ease);
}
        input[type="checkbox"]:checked::before {
    transform: scale(1);
}
        /* ========================================================================
   View Toggle
   ======================================================================== */
        .view-toggle {
    position: relative;
    display: flex;
    align-items: center;
    align-self: center;
    vertical-align: middle;
    justify-content: center;
    gap: 0.1rem;
    background: var(--rp-surface);
    border-radius: 99px;
    padding: 6px;
    border: 1px solid var(--rp-highlight-low);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    flex-shrink: 0;
    height: 2.75rem;
}
        .view-toggle::before {
    content: "";
    position: absolute;
    top: 6px;
    left: 6px;
    bottom: 6px;
    width: calc(100% - 12px);
    background: linear-gradient(135deg, var(--rp-iris) 0%, var(--rp-foam) 100%);
    border-radius: 99px;
    transition: transform 0.4s var(--transition-ease);
    z-index: 1;
    box-shadow: 0 2px 8px rgba(196, 167, 231, 0.3);
}
        .view-btn {
    position: relative;
    z-index: 2;
    padding: 0.3rem 0.6rem;
    border: none;
    background: none;
    color: var(--rp-base);
    border-radius: var(--border-radius-sm);
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    min-width: 30px;
    justify-content: center;
    letter-spacing: 0.02em;
    transition: all 0.3s var(--transition-ease);
}
        .view-btn:hover {
    color: var(--rp-surface);
    transform: translateY(-1px);
}
        .view-btn.active {
    text-shadow: none;
}
        .view-btn-icon {
    font-size: var(--font-size-base);
    transition: transform 0.3s;
}
        .view-btn:hover .view-btn-icon {
    transform: scale(1.1);
}
        /* ========================================================================
   Expanded Card Modal
   ======================================================================== */
        /* Modal Overlay */
        .expanded-card-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2.5rem;
    pointer-events: none;
    background-color: transparent;
    opacity: 0;
    animation: fadeOverlayIn 0.5s var(--transition-ease) forwards;
    will-change: opacity;
}
        .expanded-card-overlay.closing {
    animation: fadeOverlayOut 0.4s cubic-bezier(0.55, 0.06, 0.68, 0.19) forwards;
}
        /* Modal Content */
        .expanded-card-overlay .book-expanded {
    position: relative;
    border-radius: var(--border-radius-xl);
    border: 2px solid var(--rp-highlight-med);
    box-shadow: 0 35px 70px rgba(0, 0, 0, 0.7);
    width: 100%;
    max-width: 900px;
    max-height: 90vh;
    overflow-y: auto;
    overflow-x: hidden;
    pointer-events: auto;
    background-color: var(--rp-surface);
    transform: scale(0.75) translateY(60px);
    opacity: 0;
    animation: expandIn 0.6s var(--transition-ease) 0.1s forwards;
    word-wrap: break-word;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: center;
    will-change: transform, opacity;
    scrollbar-width: none;
    -ms-overflow-style: none;
}
        .expanded-card-overlay.closing .book-expanded {
    animation: contractOut 0.4s cubic-bezier(0.55, 0.06, 0.68, 0.19) forwards;
}
        .book-expanded * {
    max-width: 100%;
    box-sizing: border-box;
}
        .expanded-card-overlay .book-expanded::-webkit-scrollbar {
    width: 0;
    background: none;
}
        /* ========================================================================
   Modal Header
   ======================================================================== */
        .expanded-header {
    display: flex;
    gap: 2.5rem;
    padding: var(--spacing-2xl);
    z-index: 100;
    background-color: var(--rp-overlay);
    border-radius: var(--border-radius-lg) var(--border-radius-lg) 0 0;
    box-shadow: inset 0 -4px 10px rgba(0, 0, 0, 0.3);
    width: 100%;
    justify-content: center;
    transition:
        background 0.3s,
        box-shadow 0.3s;
    flex-wrap: wrap;
}
        /* Close Button */
        .close-btn {
    position: sticky;
    top: 1.5rem;
    right: 1.5rem;
    font-size: 2.5rem;
    cursor: pointer;
    color: var(--rp-muted);
    z-index: 1000;
    background: none;
    border: none;
    padding: 0 10px;
    will-change: color, transform;
    transition:
        color 0.3s var(--transition-ease),
        transform 0.3s var(--transition-ease);
}
        .close-btn:hover {
    background: none !important;
    color: var(--rp-love) !important;
    transform: rotate(180deg) scale(1.1);
}
        .book-expanded .close-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background-color: transparent;
    border: none;
    font-size: var(--spacing-xl);
    cursor: pointer;
    color: var(--rp-text);
    z-index: 10;
    padding: 0 10px;
}
        .book-expanded .close-btn:hover {
    background-color: var(--rp-love);
}
        /* ========================================================================
   Expanded Cover
   ======================================================================== */
        .expanded-cover {
    flex-shrink: 0;
    width: auto;
    height: auto;
    transform: rotateZ(-2deg);
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 60;
    transition: transform 0.4s var(--transition-ease);
}
        .expanded-cover:hover {
    transform: rotateZ(2deg) scale(1.02);
}
        .expanded-cover-image {
    width: 300px;
    max-width: 100%;
    object-fit: contain;
    background-color: transparent;
    border-radius: 6px;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.7);
    border: 3px solid transparent;
    display: block;
    z-index: 61;
    margin: var(--spacing-xl);
}
        /* ========================================================================
   Expanded Basic Info
   ======================================================================== */
        .expanded-basic-info {
    flex: 1;
    padding-top: 0.8rem;
    text-align: left;
    transition:
        opacity 0.3s,
        transform 0.3s;
}
        .expanded-title {
    font-size: clamp(2rem, 4vw, 2.6rem);
    font-weight: 800;
    margin-bottom: 0.8rem;
    color: var(--rp-text);
    line-height: 1.2;
    letter-spacing: -0.03em;
}
        .expanded-author {
    color: var(--rp-subtle);
    font-size: clamp(1.2rem, 2vw, 1.4rem);
    margin: 0 0 var(--spacing-lg);
    font-style: italic;
}
        .expanded-basic-info .book-genre {
    background-color: var(--rp-surface);
    color: var(--rp-text);
    padding: 0.35rem var(--spacing-md);
    font-size: var(--font-size-base);
    border-radius: 25px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25);
    display: inline-block;
    margin: 0.25rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    transition:
        background 0.2s,
        transform 0.2s,
        box-shadow 0.2s;
}
        .expanded-basic-info .book-genre:hover {
    background-color: var(--rp-foam);
    transform: translateY(-2px);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.25);
}
        /* Expanded Rating */
        .expanded-rating {
    display: inline-flex;
    align-items: center;
    gap: var(--spacing-md);
    margin-top: 0.8rem;
    margin-right: 0;
    justify-content: flex-start;
    padding-left: var(--spacing-sm);
}
        .expanded-rating .star {
    color: var(--rp-muted);
    font-size: var(--spacing-xl);
    transition: color 0.2s;
}
        .expanded-rating .star.filled {
    color: var(--rp-gold);
    text-shadow:
        0 0 8px rgba(246, 193, 119, 0.5),
        0 0 15px rgba(246, 193, 119, 0.2);
    animation: bounceIn 0.5s var(--transition-ease);
}
        /* ========================================================================
   Expanded Content
   ======================================================================== */
        .expanded-content {
    padding: 2.5rem var(--spacing-2xl) var(--spacing-2xl);
    background-color: var(--rp-surface);
    border-radius: 0 0 var(--border-radius-xl) var(--border-radius-xl);
    width: 100%;
    text-align: center;
    transition:
        opacity 0.3s,
        transform 0.3s;
}
        .expanded-content .description-section,
.expanded-content .thoughts-section {
    overflow-wrap: break-word;
    word-break: break-word;
    padding-bottom: var(--spacing-xl);
}
        .expanded-content h4 {
    color: var(--rp-rose);
    margin: 2.5rem 0 var(--spacing-lg);
    font-size: var(--font-size-3xl);
    font-weight: 700;
    border-bottom: 2px solid var(--rp-highlight-med);
    padding-bottom: 0.7rem;
    letter-spacing: 0.03em;
    text-shadow: 0 0 5px rgba(235, 111, 146, 0.2);
}
        .expanded-content p {
    color: var(--rp-text);
    line-height: 1.8;
    margin-bottom: var(--spacing-lg);
    font-size: var(--font-size-lg);
}
        .expanded-content .book-tag {
    background-color: var(--rp-highlight-high);
    color: var(--rp-text);
    padding: 0.35rem var(--spacing-md);
    font-size: var(--font-size-base);
    border-radius: 25px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25);
    display: inline-block;
    margin: 0.25rem;
    font-weight: 600;
    opacity: 0.95;
    transition:
        background 0.2s,
        transform 0.2s,
        box-shadow 0.2s;
}
        .expanded-content .book-tag:hover {
    background-color: var(--rp-foam);
    transform: translateY(-2px);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.25);
}
        /* ========================================================================
   Links Grid
   ======================================================================== */
        .links-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--spacing-lg);
    margin-top: var(--spacing-xl);
    justify-items: center;
}
        .book-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.9rem 1.4rem;
    background-color: var(--rp-overlay);
    border-radius: var(--border-radius-md);
    border: 2px solid var(--rp-highlight-med);
    text-decoration: none;
    color: var(--rp-text);
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    transition: all 0.3s var(--transition-ease);
}
        .book-link:hover {
    background-color: var(--rp-highlight-high);
    transform: translateY(-4px) scale(1.03);
    border-color: var(--rp-foam);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.5);
}
        .link-title {
    font-weight: 700;
    color: var(--rp-text);
    font-size: 1.15rem;
    letter-spacing: 0.01em;
}
        .link-icon {
    font-size: 1.6rem;
    color: var(--rp-foam);
    transition: transform 0.2s;
}
        .book-link:hover .link-icon {
    transform: translateX(5px);
}
        /* 5. Responsive design */
        /* ========================================================================
   Responsive Design
   ======================================================================== */
        /* Mobile First - Small devices (480px and down) */
        @media (max-width: 480px) {
    :root {
        --spacing-xs: 0.2rem;
        --spacing-sm: 0.4rem;
        --spacing-md: 0.8rem;
        --spacing-lg: 1.2rem;
        --spacing-xl: 1.6rem;
        --spacing-2xl: 2rem;
    }

    .book-grid {
        column-count: 1;
        padding: var(--spacing-xl) var(--spacing-md);
    }

    .filter-pill {
        padding: var(--spacing-sm) var(--spacing-md);
        gap: var(--spacing-sm);
        max-width: 95%;
        flex-wrap: wrap;
    }

    .pill-search-input {
        font-size: var(--font-size-base);
        min-width: 150px;
    }

    .pill-filter-btn {
        width: 2rem;
        height: 2rem;
        font-size: 1.2rem;
    }

    .view-toggle {
        padding: 4px;
        width: 100%;
        max-width: 280px;
    }

    .view-btn {
        padding: var(--spacing-sm) 0.75rem;
        font-size: var(--font-size-xs);
        min-width: 70px;
    }

    .view-btn-icon {
        font-size: var(--font-size-base);
    }

    /* Book List Items - Mobile Stack */
    .book-list-item {
        flex-direction: column;
        align-items: flex-start;
        gap: var(--spacing-md);
    }

    .book-cover-small {
        width: 90px;
        height: fit-content;
        align-self: center;
    }

    .book-details {
        align-items: center;
        text-align: center;
    }

    .book-title-list,
    .book-author-list {
        white-space: normal;
        text-align: center;
    }
}
        /* Small devices (560px and down) */
        @media (max-width: 560px) {
    .book-grid {
        column-count: 1;
    }

    .filter-pill {
        padding: var(--spacing-sm) var(--spacing-md);
        gap: var(--spacing-sm);
    }

    .pill-search-input {
        font-size: var(--font-size-base);
    }

    .pill-filter-btn {
        width: 2rem;
        height: 2rem;
        font-size: 1.2rem;
    }
}
        /* Tablets - Portrait mode (767px and down) */
        @media (max-width: 767px) {
    .book-gallery {
        padding: var(--spacing-xl) var(--spacing-lg);
    }

    .gallery-title {
        font-size: 2rem;
        margin-bottom: var(--spacing-2xl);
    }

    /* Expanded Card - Mobile */
    .expanded-card-overlay {
        padding: 0.8rem;
    }

    .expanded-card-overlay .book-expanded {
        max-width: 98%;
        border-radius: 10px;
        text-align: center;
    }

    .expanded-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
        padding: 1.2rem;
        gap: 0.8rem;
    }

    .expanded-cover {
        width: 200px;
        height: auto;
    }

    .expanded-cover-image {
        width: 180px;
        margin: var(--spacing-lg);
    }

    .expanded-basic-info {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .expanded-title {
        font-size: var(--font-size-3xl);
        margin-bottom: 0.3rem;
    }

    .expanded-author {
        font-size: 0.9rem;
    }

    .expanded-rating {
        flex-direction: row;
        display: flex;
        align-items: center;
        justify-content: center;
        margin-right: 0;
        padding-left: 0;
    }

    .expanded-rating .star {
        display: inline-block;
    }

    .expanded-content {
        padding: 1.2rem;
    }

    .expanded-content h4 {
        font-size: 1.6rem;
        margin-bottom: 0.8rem;
        padding-bottom: var(--spacing-sm);
    }

    .expanded-content p {
        font-size: var(--font-size-base);
        line-height: 1.6;
        margin-bottom: var(--spacing-md);
    }

    .links-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
        margin-top: var(--spacing-lg);
    }

    .book-link {
        justify-content: center;
    }

    .book-expanded .book-genres,
    .book-expanded .book-tags {
        flex-direction: column;
    }
}
        /* Tablets - Landscape and small desktops (768px to 991px) */
        @media (min-width: 768px) and (max-width: 991px) {
    .book-gallery {
        padding: var(--spacing-xl) var(--spacing-lg);
    }

    .gallery-title {
        font-size: 2.6rem;
        margin-bottom: var(--spacing-2xl);
    }

    .book-grid {
        column-count: 2;
    }

    .filter-bar {
        padding: var(--spacing-lg);
        gap: var(--spacing-md);
        border-radius: 16px;
    }

    .expanded-header {
        flex-direction: row;
        align-items: flex-start;
        text-align: left;
        padding: var(--spacing-xl);
    }

    .expanded-cover {
        width: 230px;
        height: auto;
    }

    .expanded-content {
        padding: 1.8rem var(--spacing-xl);
    }

    /* List view adjustments */
    .book-title-list,
    .view-btn-icon {
        font-size: var(--font-size-base);
    }

    .book-list-item {
        gap: var(--spacing-md);
        padding: var(--spacing-md);
    }

    .book-cover-small {
        width: 90px;
        height: fit-content;
        margin-top: 0.5rem;
    }

    .book-author-list {
        font-size: var(--font-size-sm);
    }

    .book-meta {
        gap: var(--spacing-sm);
    }
}
        /* Medium desktops (992px to 1199px) */
        @media (min-width: 992px) and (max-width: 1199px) {
    .book-gallery {
        padding: 2.5rem var(--spacing-xl);
    }

    .gallery-title {
        font-size: var(--font-size-4xl);
    }

    .book-grid {
        column-count: 3;
    }

    .filter-bar {
        max-width: 850px;
    }

    .expanded-card-overlay {
        padding: var(--spacing-xl);
    }

    .expanded-card-overlay .book-expanded {
        max-width: 800px;
    }

    .expanded-header {
        padding: 2.5rem;
        gap: var(--spacing-xl);
    }

    .expanded-cover {
        width: 300px;
        height: auto;
    }

    .expanded-title {
        font-size: var(--font-size-4xl);
    }

    .expanded-author {
        font-size: 1.3rem;
    }

    .expanded-content {
        padding: var(--spacing-xl) 2.5rem;
    }
}
        /* Large desktops (1200px and up) */
        @media (min-width: 1200px) {
    .book-gallery {
        padding: var(--spacing-2xl) 2.5rem;
    }

    .book-grid {
        column-count: 3;
    }

    .expanded-card-overlay .book-expanded {
        max-width: 900px;
    }

    .expanded-header {
        padding: var(--spacing-2xl);
        gap: 2.5rem;
    }

    .expanded-cover {
        width: 250px;
        height: auto;
    }

    .expanded-title {
        font-size: 2.6rem;
    }
}
        /* Ultra-wide screens (1400px and up) */
        @media (min-width: 1400px) {
    .book-grid {
        column-count: 4;
        margin: 0 auto;
    }

    .book-gallery {
        margin: 0 auto;
    }
}
        /* High DPI displays */
        @media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .cover-image,
    .cover-image-small,
    .expanded-cover-image {
        image-rendering: -webkit-optimize-contrast;
        image-rendering: crisp-edges;
    }
}
        /* Landscape orientation on mobile */
        @media (max-width: 768px) and (orientation: landscape) {
    .expanded-header {
        flex-direction: row;
        padding: var(--spacing-md);
    }

    .expanded-cover {
        width: 150px;
    }

    .expanded-cover-image {
        width: 120px;
        margin: var(--spacing-md);
    }
}
        /* Reduced motion preferences */
        @media (prefers-reduced-motion: reduce) {
    :root {
        --transition-speed: 0.1s;
        --transition-ease: linear;
    }

    *,
    *::before,
    *::after {
        animation-duration: 0.1s !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.1s !important;
    }

    .book-card:hover:not(.expanded) {
        transform: none;
    }

    .expanded-cover:hover {
        transform: none;
    }
}
        @media print {
    .filter-pill,
    .filter-bar,
    .view-toggle,
    .close-btn,
    .backdrop,
    .expanded-card-overlay {
        display: none !important;
    }

    .book-card {
        break-inside: avoid;
        box-shadow: none;
        border: 1px solid #000;
    }

    .book-grid {
        column-count: 2;
    }
}
        @media (max-width: 768px) {
    .book-grid:not(.list-view) {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: var(--spacing-lg);
    }
}
        @media (max-width: 480px) {
    .book-grid:not(.list-view) {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }
}
        @media (pointer: coarse) {
    :root {
        --drag-scale: 1.1;
        --hover-lift: -12px;
        --drag-lift-duration: 0.1s;
    }

    .book-card.is-dragging {
        transform: scale(var(--drag-scale)) rotate(var(--drag-rotate)) translateY(var(--hover-lift))
            translateZ(0);
    }
}
        @media (prefers-reduced-motion: reduce) {
    :root {
        --drag-lift-duration: 0.05s;
        --drag-drop-duration: 0.1s;
        --reorder-duration: 0.1s;
        --hover-response-duration: 0.05s;
        --drag-scale: 1.02;
        --drag-rotate: 0deg;
        --hover-lift: -2px;
    }

    .book-card.is-dragging {
        filter: none;
    }
}
        /* 6. Theme definitions */
        :global {
    /* My Fingers Hurt :'D */
    :root[data-theme="kanagawa"] {
        --rp-base: #1f1f28;
        --rp-surface: #16161d;
        --rp-overlay: #223249;
        --rp-muted: #54546d;
        --rp-subtle: #727169;
        --rp-text: #dcd7ba;
        --rp-love: #c34043;
        --rp-gold: #c0a36e;
        --rp-rose: #e6c384;
        --rp-pine: #7e9cd8;
        --rp-foam: #7aa89f;
        --rp-iris: #957fb8;
        --rp-highlight-low: #16161d;
        --rp-highlight-med: #223249;
        --rp-highlight-high: #2d4f67;
    }

    html[data-theme="rose-pine"] {
        --rp-base: #191724;
        --rp-surface: #1f1d2e;
        --rp-overlay: #26233a;
        --rp-muted: #6e6a86;
        --rp-subtle: #908caa;
        --rp-text: #e0def4;
        --rp-love: #eb6f92;
        --rp-gold: #f6c177;
        --rp-rose: #ebbcba;
        --rp-pine: #31748f;
        --rp-foam: #9ccfd8;
        --rp-iris: #c4a7e7;
        --rp-highlight-low: #2a283d;
        --rp-highlight-med: #403d52;
        --rp-highlight-high: #524f67;
        --transition-speed: 0.4s;
        --transition-ease: cubic-bezier(0.25, 0.46, 0.45, 0.94);
        --hover-scale: 1.02;
    }

    html[data-theme="rose-pine-moon"] {
        --rp-base: #232136;
        --rp-surface: #2a273a;
        --rp-overlay: #312e43;
        --rp-muted: #8b859e;
        --rp-subtle: #b2accc;
        --rp-text: #e0def4;
        --rp-love: #ea96a6;
        --rp-gold: #e7bc8c;
        --rp-rose: #f0c6c6;
        --rp-pine: #56949f;
        --rp-foam: #9ccfd8;
        --rp-iris: #c4a7e7;
        --rp-highlight-low: #39354d;
        --rp-highlight-med: #4a4561;
        --rp-highlight-high: #5c5775;
    }

    html[data-theme="rose-pine-dawn"] {
        --rp-base: #faf4ed;
        --rp-surface: #fffaf3;
        --rp-overlay: #f2e9e1;
        --rp-muted: #9893a5;
        --rp-subtle: #797593;
        --rp-text: #575279;
        --rp-love: #b4637a;
        --rp-gold: #ea9d34;
        --rp-rose: #d7827e;
        --rp-pine: #286983;
        --rp-foam: #407d9b;
        --rp-iris: #907aa9;
        --rp-highlight-low: #f4ede8;
        --rp-highlight-med: #e4dfd8;
        --rp-highlight-high: #dcd7d1;
    }

    html[data-theme="catppuccin-mocha"] {
        --rp-base: #1e1e2e;
        --rp-surface: #313244;
        --rp-overlay: #45475a;
        --rp-muted: #6c7086;
        --rp-subtle: #9399b2;
        --rp-text: #cdd6f4;
        --rp-love: #f38ba8;
        --rp-gold: #f9e2af;
        --rp-rose: #f5c2e7;
        --rp-pine: #74c7ec;
        --rp-foam: #94e2d5;
        --rp-iris: #cba6f7;
        --rp-highlight-low: #313244;
        --rp-highlight-med: #45475a;
        --rp-highlight-high: #585b70;
    }

    html[data-theme="catppuccin-macchiato"] {
        --rp-base: #24273a;
        --rp-surface: #363a4f;
        --rp-overlay: #494d64;
        --rp-muted: #6e738d;
        --rp-subtle: #939ab7;
        --rp-text: #cad3f5;
        --rp-love: #f5bde6;
        --rp-gold: #eed49f;
        --rp-rose: #f4dbd6;
        --rp-pine: #7dc4e4;
        --rp-foam: #8bd5ca;
        --rp-iris: #c6a0f6;
        --rp-highlight-low: #363a4f;
        --rp-highlight-med: #494d64;
        --rp-highlight-high: #5b6078;
    }

    html[data-theme="catppuccin-frappe"] {
        --rp-base: #303446;
        --rp-surface: #414559;
        --rp-overlay: #51576d;
        --rp-muted: #737994;
        --rp-subtle: #949cbb;
        --rp-text: #c6d0f5;
        --rp-love: #f4b8e4;
        --rp-gold: #e5c890;
        --rp-rose: #eebebe;
        --rp-pine: #81c8be;
        --rp-foam: #85c1dc;
        --rp-iris: #ca9ee6;
        --rp-highlight-low: #414559;
        --rp-highlight-med: #51576d;
        --rp-highlight-high: #626880;
    }

    html[data-theme="catppuccin-latte"] {
        --rp-base: #eff1f5;
        --rp-surface: #e6e9ef;
        --rp-overlay: #dce0e8;
        --rp-muted: #9ca0b0;
        --rp-subtle: #6c6f85;
        --rp-text: #4c4f69;
        --rp-love: #e64553;
        --rp-gold: #df8e1d;
        --rp-rose: #ea76cb;
        --rp-pine: #179299;
        --rp-foam: #04a5e5;
        --rp-iris: #8839ef;
        --rp-highlight-low: #e6e9ef;
        --rp-highlight-med: #dce0e8;
        --rp-highlight-high: #ccd0da;
    }

    html[data-theme="nord"] {
        --rp-base: #2e3440;
        --rp-surface: #3b4252;
        --rp-overlay: #434c5e;
        --rp-muted: #4c566a;
        --rp-subtle: #616e88;
        --rp-text: #eceff4;
        --rp-love: #bf616a;
        --rp-gold: #ebcb8b;
        --rp-rose: #d08770;
        --rp-pine: #5e81ac;
        --rp-foam: #8fbcbb;
        --rp-iris: #b48ead;
        --rp-highlight-low: #3b4252;
        --rp-highlight-med: #434c5e;
        --rp-highlight-high: #4c566a;
    }

    html[data-theme="gruvbox-dark"] {
        --rp-base: #282828;
        --rp-surface: #3c3836;
        --rp-overlay: #504945;
        --rp-muted: #665c54;
        --rp-subtle: #7c6f64;
        --rp-text: #ebdbb2;
        --rp-love: #cc241d;
        --rp-gold: #d79921;
        --rp-rose: #d3869b;
        --rp-pine: #458588;
        --rp-foam: #689d6a;
        --rp-iris: #b16286;
        --rp-highlight-low: #3c3836;
        --rp-highlight-med: #504945;
        --rp-highlight-high: #665c54;
    }

    html[data-theme="gruvbox-light"] {
        --rp-base: #fbf1c7;
        --rp-surface: #f2e5bc;
        --rp-overlay: #ebdbb2;
        --rp-muted: #a89984;
        --rp-subtle: #7c6f64;
        --rp-text: #3c3836;
        --rp-love: #9d0006;
        --rp-gold: #b57614;
        --rp-rose: #af3a03;
        --rp-pine: #076678;
        --rp-foam: #427b58;
        --rp-iris: #8f3f71;
        --rp-highlight-low: #f2e5bc;
        --rp-highlight-med: #ebdbb2;
        --rp-highlight-high: #d5c4a1;
    }

    html[data-theme="alduin"] {
        --rp-base: #202020;
        --rp-surface: #2a2a2a;
        --rp-overlay: #3c3836;
        --rp-muted: #928374;
        --rp-subtle: #a89984;
        --rp-text: #ebdbb2;
        --rp-love: #cc241d;
        --rp-gold: #d79921;
        --rp-rose: #d65d0e;
        --rp-pine: #689d6a;
        --rp-foam: #458588;
        --rp-iris: #b16286;
        --rp-highlight-low: #2a2a2a;
        --rp-highlight-med: #3c3836;
        --rp-highlight-high: #504945;
    }

    html[data-theme="angr"] {
        --rp-base: #1c1c1c;
        --rp-surface: #2e2e2e;
        --rp-overlay: #444444;
        --rp-muted: #888888;
        --rp-subtle: #aaaaaa;
        --rp-text: #f8f8f2;
        --rp-love: #ff6c6b;
        --rp-gold: #f0c674;
        --rp-rose: #d08770;
        --rp-pine: #98c379;
        --rp-foam: #61afef;
        --rp-iris: #c678dd;
        --rp-highlight-low: #2e2e2e;
        --rp-highlight-med: #3f3f3f;
        --rp-highlight-high: #5c5c5c;
    }

    html[data-theme="ayu"] {
        --rp-base: #0f1419;
        --rp-surface: #1f2429;
        --rp-overlay: #2d3237;
        --rp-muted: #5c6773;
        --rp-subtle: #738091;
        --rp-text: #e6e1cf;
        --rp-love: #f07178;
        --rp-gold: #ffb454;
        --rp-rose: #ffa759;
        --rp-pine: #aad94c;
        --rp-foam: #7fd5f5;
        --rp-iris: #c397d8;
        --rp-highlight-low: #1a1f24;
        --rp-highlight-med: #2d343a;
        --rp-highlight-high: #3e4a56;
    }

    html[data-theme="carbonized"] {
        --rp-base: #111111;
        --rp-surface: #222222;
        --rp-overlay: #333333;
        --rp-muted: #888888;
        --rp-subtle: #aaaaaa;
        --rp-text: #dddddd;
        --rp-love: #ff5f5f;
        --rp-gold: #ffd700;
        --rp-rose: #ff875f;
        --rp-pine: #5fffaf;
        --rp-foam: #5fafff;
        --rp-iris: #af5fff;
        --rp-highlight-low: #1a1a1a;
        --rp-highlight-med: #2e2e2e;
        --rp-highlight-high: #444444;
    }

    html[data-theme="gotham"] {
        --rp-base: #0c1014;
        --rp-surface: #11151c;
        --rp-overlay: #1a1f26;
        --rp-muted: #2f3541;
        --rp-subtle: #4e5a65;
        --rp-text: #d3d7de;
        --rp-love: #c23127;
        --rp-gold: #ffdd33;
        --rp-rose: #ff5f87;
        --rp-pine: #2aa198;
        --rp-foam: #26c6da;
        --rp-iris: #9c6cd3;
        --rp-highlight-low: #11151c;
        --rp-highlight-med: #1a1f26;
        --rp-highlight-high: #2f3541;
    }

    html[data-theme="iceberg"] {
        --rp-base: #161821;
        --rp-surface: #1e2132;
        --rp-overlay: #2e3340;
        --rp-muted: #6b7089;
        --rp-subtle: #a1aab8;
        --rp-text: #d2d4de;
        --rp-love: #e27878;
        --rp-gold: #e9b189;
        --rp-rose: #e98989;
        --rp-pine: #84a0c6;
        --rp-foam: #89b8c2;
        --rp-iris: #b4be82;
        --rp-highlight-low: #1e2132;
        --rp-highlight-med: #2e3340;
        --rp-highlight-high: #3e4452;
    }

    html[data-theme="papercolor"] {
        --rp-base: #eeeeee;
        --rp-surface: #ffffff;
        --rp-overlay: #dddddd;
        --rp-muted: #888888;
        --rp-subtle: #aaaaaa;
        --rp-text: #000000;
        --rp-love: #af0000;
        --rp-gold: #af8700;
        --rp-rose: #ff8700;
        --rp-pine: #008700;
        --rp-foam: #005f87;
        --rp-iris: #875f87;
        --rp-highlight-low: #dddddd;
        --rp-highlight-med: #cccccc;
        --rp-highlight-high: #bbbbbb;
    }

    html[data-theme="jellybeans"] {
        --rp-base: #1c1c1c;
        --rp-surface: #262626;
        --rp-overlay: #303030;
        --rp-muted: #808080;
        --rp-subtle: #a0a0a0;
        --rp-text: #e8e8d3;
        --rp-love: #cf6a4c;
        --rp-gold: #fad07a;
        --rp-rose: #f08080;
        --rp-pine: #99ad6a;
        --rp-foam: #8fbfdc;
        --rp-iris: #8197bf;
        --rp-highlight-low: #262626;
        --rp-highlight-med: #303030;
        --rp-highlight-high: #444444;
    }

    html[data-theme="materialbox"] {
        --rp-base: #263238;
        --rp-surface: #2e3c43;
        --rp-overlay: #314549;
        --rp-muted: #546e7a;
        --rp-subtle: #90a4ae;
        --rp-text: #eceff1;
        --rp-love: #ff5370;
        --rp-gold: #ffcb6b;
        --rp-rose: #f07178;
        --rp-pine: #c3e88d;
        --rp-foam: #89ddff;
        --rp-iris: #c792ea;
        --rp-highlight-low: #2e3c43;
        --rp-highlight-med: #314549;
        --rp-highlight-high: #37474f;
    }

    html[data-theme="onedark"] {
        --rp-base: #282c34;
        --rp-surface: #353b45;
        --rp-overlay: #3e4451;
        --rp-muted: #5c6370;
        --rp-subtle: #abb2bf;
        --rp-text: #bbc2cf;
        --rp-love: #e06c75;
        --rp-gold: #e5c07b;
        --rp-rose: #d19a66;
        --rp-pine: #98c379;
        --rp-foam: #56b6c2;
        --rp-iris: #c678dd;
        --rp-highlight-low: #353b45;
        --rp-highlight-med: #3e4451;
        --rp-highlight-high: #4b5263;
    }

    html[data-theme="pink-moon"] {
        --rp-base: #2e1a2f;
        --rp-surface: #3b253b;
        --rp-overlay: #4a2c4a;
        --rp-muted: #b588a0;
        --rp-subtle: #e0a0c0;
        --rp-text: #f9d6e8;
        --rp-love: #ff5f87;
        --rp-gold: #f5b78a;
        --rp-rose: #ffa5c3;
        --rp-pine: #c7d2fe;
        --rp-foam: #b2f0e6;
        --rp-iris: #d0b0ff;
        --rp-highlight-low: #3b253b;
        --rp-highlight-med: #4a2c4a;
        --rp-highlight-high: #5c3a5c;
    }

    html[data-theme="tokyo-night"] {
        --rp-base: #1a1b26;
        --rp-surface: #1f2335;
        --rp-overlay: #2a2f48;
        --rp-muted: #565f89;
        --rp-subtle: #7aa2f7;
        --rp-text: #c0caf5;
        --rp-love: #f7768e;
        --rp-gold: #e0af68;
        --rp-rose: #ff9e64;
        --rp-pine: #9ece6a;
        --rp-foam: #7dcfff;
        --rp-iris: #bb9af7;
        --rp-highlight-low: #1f2335;
        --rp-highlight-med: #2a2f48;
        --rp-highlight-high: #3b4261;
    }
}
        /* 7. Quick menu buttons */
        /* Scrollbar Styling */
        ::-webkit-scrollbar {
    width: 12px;
    height: 12px;
}
        ::-webkit-scrollbar-track {
    background-color: var(--rp-base);
}
        ::-webkit-scrollbar-thumb {
    background-color: var(--rp-foam);
    border-radius: 8px;
    border: 2px solid var(--rp-gold);
}
        ::-webkit-scrollbar-button,
::-webkit-scrollbar-corner {
    display: none;
    width: 0;
    height: 0;
}
        * {
    scrollbar-width: none;
    scrollbar-color: var(--rp-foam) var(--rp-overlay);
    box-sizing: border-box;
}
        select {
    background-color: var(--rp-surface);
    color: var(--rp-text);
    border: 1px solid var(--rp-highlight);
    border-radius: 6px;
    padding: 0.5em 1em;
    font-family: "JetBrains Mono", monospace;
    appearance: none;
    cursor: pointer;
    outline: none;
    box-shadow: 0 0 0 1px var(--rp-highlight);
}
        option {
    background-color: var(--rp-base);
    color: var(--rp-text);
}
        select:focus {
    border-color: var(--rp-gold);
    box-shadow: 0 0 0 2px var(--rp-gold);
}
        body {
    margin: 0;
    font-family: "Inter", sans-serif;
    background-color: var(--rp-base);
    color: var(--rp-text);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}
        /* Buttons and Inputs */
        .quick-buttons button,
.theme-switcher select,
.theme-switcher button,
.lang-switcher-aligned select,
.lang-switcher-aligned button,
.routes-menu-button {
    background-color: var(--rp-surface);
    color: var(--rp-text);
    border: 2px solid var(--rp-highlight-low);
    border-radius: 99px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.8);
    padding: 0.75rem 1.25rem;
    font-size: 0.875rem;
    cursor: pointer;
    width: fit-content;
    height: fit-content;
    outline: none;
    transition:
        all var(--transition-speed) var(--transition-ease),
        background-color 0.3s ease,
        color 0.3s ease,
        border-color 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    appearance: none;
    white-space: nowrap;
}
        .theme-switcher select {
    width: 13rem;
    border-color: var(--rp-gold);
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    background-size: 1.25em;
}
        .theme-switcher select option {
    background-color: var(--rp-surface);
    color: var(--rp-text);
    padding: 0.5rem 1rem;
}
        .theme-switcher select::-ms-expand {
    display: none;
}
        .quick-buttons button:hover,
.theme-switcher select:hover,
.lang-switcher-aligned select:hover,
.routes-menu-button:hover {
    background-color: var(--rp-overlay);
    border-color: var(--rp-iris);
    color: var(--rp-iris);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.6);
    transform: translateY(-3px) scale(1.02);
}
        /* Home Button */
        .home_button {
    width: auto;
    padding: 0.75rem 1rem;
    scale: 100%;
}
        .home_button svg {
    width: 1.25em;
    height: 1.25em;
    stroke: var(--rp-text);
    transition: stroke 0.3s ease;
}
        .home_button:hover svg {
    stroke: var(--rp-gold);
}
        .home_button:active {
    transform: translateY(0);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.6);
}
        /* Language Switcher */
        .lang-switcher-aligned {
    margin-left: auto;
    z-index: 1;
}
        /* Quick Buttons Wrapper */
        .quick-buttons {
    position: fixed;
    top: 1rem;
    right: 1rem;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 0.75rem;
    z-index: 1000;
    animation: fadeInSlideIn 0.5s ease-out forwards;
}
        /* Menu Toggle */
        .menu-toggle {
    background-color: var(--rp-surface);
    color: var(--rp-text);
    border: 2px solid var(--rp-highlight-low);
    border-radius: 99px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.8);
    padding: 0.75rem;
    cursor: pointer;
    outline: none;
    transition:
        all var(--transition-speed) var(--transition-ease),
        background-color 0.3s ease,
        border-color 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}
        .menu-toggle .menu-icon {
    width: 16px;
    height: 16px;
    stroke: var(--rp-text);
    transition: stroke 0.3s ease;
}
        .menu-toggle:hover {
    background-color: var(--rp-iris);
    border-color: var(--rp-foam);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.7);
    transform: translateY(-2px) scale(1.05);
}
        .menu-toggle:hover .menu-icon {
    stroke: var(--rp-base);
}
        /* Menu Items */
        .menu-items {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 0.75rem;
    opacity: 0;
    visibility: hidden;
    transform: translateX(-10px);
    transition: all 0.3s ease;
    pointer-events: none;
}
        .menu-items.open {
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
    pointer-events: auto;
}
        /* Routes Menu */
        .routes-menu-container {
    position: relative;
}
        .routes-dropdown {
    position: absolute;
    top: calc(100% + 0.5rem);
    right: 0;
    background-color: var(--rp-surface);
    border: 2px solid var(--rp-iris);
    border-radius: 10px;
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.6) inset;
    min-width: 160px;
    opacity: 0;
    visibility: hidden;
    justify-content: center;
    align-items: center;
    transform: translateY(-10px) scale(0.95);
    transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    pointer-events: none;
    overflow: visible;
}
        .routes-dropdown.open {
    opacity: 1;
    align-items: center;
    visibility: visible;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}
        .route-item {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    background: none !important;
    border: none !important;
    border-radius: 10px !important;
    padding: 0.75rem 0.1rem !important;
    color: var(--rp-text) !important;
    text-align: left !important;
    cursor: pointer;
    box-shadow: inset 0 4px 16px rgba(0, 0, 0, 0.8) !important;
    font-size: 0.875rem;
    opacity: 0;
    transform: translateX(-10px);
    animation: slideInFade 0.3s ease forwards;
    position: relative;
}
        .route-item.has-children {
    padding-right: 2rem;
}
        .route-item:hover {
    background-color: var(--rp-overlay);
    color: var(--rp-gold);
    transform: translateX(6px);
}
        .route-wrapper {
    position: relative;
}
        .route-item:hover {
    overflow: visible;
}
        .route-item:hover .arrow {
    color: var(--rp-foam);
    transform: translateX(4px) rotate(5deg);
}
        .route-item.current {
    background-color: var(--rp-highlight-med);
    color: var(--rp-gold);
    font-weight: 700;
    border-left: 3px solid var(--rp-gold);
    padding-left: 0.75rem;
}
        .route-item.current:hover {
    background-color: var(--rp-highlight-high);
    color: var(--rp-gold);
}
        .arrow {
    color: var(--rp-muted);
    font-size: 1rem;
    transition: all 0.15s ease;
    margin-left: 10px;
}
        /* Nested Menus */
        .nested-menu {
    position: absolute;
    top: 0;
    left: calc(100% + 0.5rem);
    background-color: var(--rp-surface);
    border: 2px solid var(--rp-foam);
    border-radius: 9px;
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.5);
    min-width: 180px;
    z-index: 1002;
    overflow: hidden;
    opacity: 0;
    transform: translateX(-10px) scale(0.95);
    animation: nestedMenuSlideIn 0.75s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}
        .route-item:hover > .nested-menu {
    opacity: 1;
    transform: translateX(0) scale(1);
    pointer-events: auto;
}
        .nested-route-item {
    display: block;
    width: 100% !important;
    background: none !important;
    border: none !important;
    padding: 0.75rem 1rem;
    color: var(--rp-text);
    border-radius: 5px !important;
    text-align: center !important;
    cursor: pointer;
    font-size: 0.875rem;
    opacity: 0;
    transform: translateX(-10px);
    animation: slideInFade 0.75s ease forwards;
}
        .nested-route-item:hover {
    background-color: var(--rp-overlay);
    color: var(--rp-pine);
    transform: translateX(6px);
}
        .nested-route-item.current {
    background-color: var(--rp-highlight-med);
    color: var(--rp-gold);
    font-weight: 600;
    border-left: 3px solid var(--rp-gold);
    padding-left: 0.75rem;
}
        .nested-route-item.current:hover {
    background-color: var(--rp-highlight-high);
    color: var(--rp-gold);
}
        /* Media Queries */
        @media (max-width: 920px) {
    .quick-buttons button,
    .theme-switcher select,
    .theme-switcher button,
    .lang-switcher-aligned select,
    .lang-switcher-aligned button,
    .routes-menu-button {
        align-items: center;
    }
}
        @media (max-width: 768px) {
    .quick-buttons {
        top: 0.5rem;
        right: 0.5rem;
        gap: 0.5rem;
    }

    .routes-menu-button {
        font-size: 0.75rem;
        padding: 0.6rem 1rem;
    }

    .routes-dropdown {
        min-width: 140px;
        right: -0.5rem;
    }

    .route-item {
        padding: 0.6rem 0.875rem;
        font-size: 0.75rem;
    }

    .route-item.has-children {
        padding-right: 1.75rem;
    }

    .nested-menu {
        min-width: 160px;
        left: calc(100% + 0.25rem);
    }

    .nested-route-item {
        padding: 0.6rem 0.875rem;
        font-size: 0.75rem;
    }

    .arrow {
        font-size: 0.875rem;
    }

    .quick-buttons button,
    .theme-switcher select {
        font-size: 0.75rem;
        padding: 0.6rem 1rem;
    }

    .theme-switcher select {
        padding-right: 2rem;
        background-position: right 0.5rem center;
    }

    .home_button {
        padding: 0.6rem 0.8rem;
    }

    .home_button svg {
        width: 1em;
        height: 1em;
    }

    .menu-toggle {
        padding: 0.4rem;
    }

    .menu-toggle .menu-icon {
        width: 14px;
        height: 14px;
    }

    .menu-items {
        gap: 0.5rem;
    }
}
        /* RTL fixes */
        html[dir="rtl"] .quick-buttons {
    left: 1rem;
    right: auto;
    flex-direction: row-reverse; /* Keep toggle button on the outside */
}
        html[dir="rtl"] .menu-toggle {
    order: -1;
}
        /* Reverse menu-items slide-in for RTL */
        html[dir="rtl"] .menu-items {
    transform: translateX(10px); /* start from the left instead of the right */
}
        html[dir="rtl"] .menu-items.open {
    transform: translateX(0);
}
        html[dir="rtl"] .route-item {
    transform: translateX(10px);
}
        html[dir="rtl"] .route-item:hover {
    transform: translateX(-6px); /* slide inward from the other side */
}
        html[dir="rtl"] .nested-menu {
    left: auto;
    right: calc(100% + 0.5rem); /* nested menu opens to the left */
}
        @media (max-width: 480px) {
    body {
        font-size: 14px; /* Slightly smaller base font for small screens */
        line-height: 1.5;
        padding: 0 0.5rem;
    }

    /* Stack quick buttons vertically for better tapping */
    .quick-buttons {
        flex-direction: column-reverse;
        align-items: flex-end;
        gap: 0.4rem;
        top: 0.5rem;
        right: 0.5rem;
    }

    .quick-buttons button,
    .theme-switcher select,
    .lang-switcher-aligned select,
    .routes-menu-button {
        font-size: 0.7rem;
        padding: 0.5rem 0.75rem;
        min-width: 100%;
    }

    /* Routes dropdown fills width for easy tap targets */
    .routes-dropdown {
        width: 100%;
        left: 10px;
        /* min-width: unset; */
        border-radius: 0;
    }

    .route-item,
    .nested-route-item {
        font-size: 0.7rem;
        padding: 0.5rem;
        text-align: center;
    }

    .nested-menu {
        position: static;
        transform: none;
        opacity: 1;
        animation: none;
        min-width: 100%;
        width: 100%;
        border-radius: 0;
        border: none;
        box-shadow: none;
    }
}
        @media (max-width: 360px) {
    body {
        font-size: 13px;
    }

    .quick-buttons {
        gap: 0.3rem;
        flex-direction: column;
    }

    .quick-buttons button,
    .theme-switcher select,
    .lang-switcher-aligned select,
    .routes-menu-button {
        font-size: 0.65rem;
        padding: 0.4rem 0.6rem;
    }

    .home_button {
        padding: 0.4rem 0.6rem;
    }

    .home_button svg {
        width: 0.9em;
        height: 0.9em;
    }
}
        .locale-switcher select {
    appearance: none;
    background-color: var(--rp-surface);
    color: var(--rp-text);
    cursor: pointer;
    font-family: inherit;
    transition: all 0.2s ease;
}
        .locale-switcher select:hover {
    background-color: var(--rp-highlight-low);
}
        .locale-switcher select:focus {
    outline: none;
    border-color: var(--rp-pine);
    box-shadow: 0 0 0 2px rgba(126, 156, 216, 0.2);
}
        .locale-switcher select:active {
    background-color: var(--rp-highlight-med);
}
        .locale-switcher::after {
    position: absolute;
    top: 50%;
    right: 10px;
    transform: translateY(-50%);
    color: var(--rp-subtle);
    pointer-events: none;
    font-size: 12px;
}
        .locale-switcher select option {
    background-color: var(--rp-surface);
    color: var(--rp-text);
}
        .locale-switcher select option:hover,
.locale-switcher select option:checked {
    background-color: var(--rp-highlight-med);
    color: var(--rp-foam);
}
        .locale-switcher select option {
    background-color: var(--rp-surface);
    color: var(--rp-text);
    font-size: 14px;
    font-weight: 400;
    line-height: 1.4;
    border: none;
    cursor: pointer;
}
        .locale-switcher select option:hover {
    background-color: var(--rp-highlight-med);
    color: var(--rp-foam);
}
        .locale-switcher select option:checked,
.locale-switcher select option:selected {
    background-color: var(--rp-pine);
    color: var(--rp-base);
    font-weight: 500;
}
        .locale-switcher select option:focus {
    background-color: var(--rp-highlight-high);
    color: var(--rp-text);
    outline: none;
}
        .locale-switcher select option:disabled {
    background-color: var(--rp-highlight-low);
    color: var(--rp-muted);
    cursor: auto;
}
        .locale-switcher select::-webkit-scrollbar {
    width: 8px;
}
        .locale-switcher select::-webkit-scrollbar-track {
    background: var(--rp-surface);
}
        .locale-switcher select::-webkit-scrollbar-thumb {
    background: var(--rp-muted);
    border-radius: 4px;
}
        .locale-switcher select::-webkit-scrollbar-thumb:hover {
    background: var(--rp-subtle);
}
        /* 8. Page specific styles */
        .index-header {
    text-align: center;
    margin-bottom: 3.5rem;
    margin-top: 3.5rem;
    font-size: 1.5rem;
    color: var(--rp-iris);
    font-weight: 800;
    letter-spacing: -0.05em;
    word-spacing: -0.1em;
    text-shadow:
        0 0 20px rgba(196, 167, 231, 0.3),
        0 0 40px rgba(196, 167, 231, 0.1);
    line-height: 1.1;
    background: linear-gradient(90deg, var(--rp-iris) 0%, var(--rp-foam) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: fadeInDown 1s var(--transition-ease) forwards;
    opacity: 1;
}
        .index-desc {
    text-wrap-mode: wrap;
}
        .index-footer {
    margin-top: 1rem;
    margin-bottom: 1rem;
    text-align: center;
    color: var(--rp-text);
}
        .buggy {
    width: 300px;
    height: 168px;
    margin-bottom: -3.9rem;
    filter: contrast(95);
    cursor: pointer;
}
        .license-hyper {
    color: aqua;
}
        .loading-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background-color: var(--rp-base);
    padding: 2rem;
}
        .loading-content {
    text-align: center;
    max-width: 400px;
    width: 100%;
}
        .loading-spinner {
    position: relative;
    width: 80px;
    height: 80px;
    margin: 0 auto 2rem auto;
}
        .spinner-ring {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 3px solid transparent;
    border-top-color: var(--rp-rose);
    border-radius: 50%;
    animation: spin 1.5s cubic-bezier(0.68, -0.55, 0.265, 1.55) infinite;
}
        .spinner-ring:nth-child(2) {
    border-top-color: var(--rp-gold);
    animation-delay: -0.4s;
    animation-duration: 1.2s;
}
        .spinner-ring:nth-child(3) {
    border-top-color: var(--rp-love);
    animation-delay: -0.8s;
    animation-duration: 1.8s;
}
        @keyframes spin {
    0% {
        transform: rotate(0deg);
        opacity: 1;
        scale: 1;
    }
    50% {
        opacity: 0.8;
        scale: 0.95;
    }
    100% {
        transform: rotate(360deg);
        opacity: 1;
        scale: 1;
    }
}
        .loading-text h2 {
    color: var(--rp-text);
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    font-weight: 600;
    background: linear-gradient(135deg, var(--rp-rose), var(--rp-gold));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
        .progress-container {
    width: 100%;
    margin-top: 1rem;
}
        .progress-bar {
    width: 100%;
    height: 8px;
    background-color: var(--rp-surface);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
}
        .progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--rp-rose), var(--rp-gold), var(--rp-love));
    background-size: 200% 100%;
    border-radius: 10px;
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    animation: shimmer 2s infinite;
}
        @keyframes shimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}
        .progress-text {
    display: inline-block;
    margin-top: 0.5rem;
    color: var(--rp-subtle);
    font-size: 0.9rem;
    font-weight: 500;
}
        /* Error styles */
        .error-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background-color: var(--rp-base);
    padding: 2rem;
}
        .error-content {
    text-align: center;
    max-width: 400px;
    width: 100%;
    background-color: var(--rp-surface);
    padding: 2rem;
    border-radius: var(--border-radius-xl);
    border: 2px solid var(--rp-love);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}
        .error-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}
        .retry-button {
    margin-top: 1rem;
    padding: 0.75rem 1.5rem;
    background-color: var(--rp-love);
    color: white;
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
    font-weight: 600;
    transition: background-color 0.2s ease;
}
        .retry-button:hover {
    background-color: var(--rp-rose);
}
        /* Main gallery styles */
        .navigation-gallery-wrapper {
    padding: 2rem;
    background-color: var(--rp-base);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: flex-start;
}
        .navigation-gallery {
    display: flex;
    gap: 1.5rem;
    width: 100%;
    max-width: calc(100% - 20px);
}
        .nav-column {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}
        .nav-card {
    animation: fadeInScale 0.6s var(--transition-ease) forwards;
    background-color: var(--rp-surface);
    border: 2px solid var(--rp-highlight-low);
    border-radius: var(--border-radius-xl);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.45);
    overflow: hidden;
    color: var(--text);
    cursor: pointer;
    opacity: 0;
    transform: scale(0.96);
    transition: all var(--hover-response-duration) var(--smooth-ease);
}
        .nav-card:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
    border-color: var(--rp-love);
    background: linear-gradient(135deg, var(--rp-surface) 0%, var(--rp-overlay) 100%);
}
        @keyframes fadeInScale {
    to {
        opacity: 1;
        transform: scale(1);
    }
}
        .card-image-container {
    width: 100%;
    overflow: hidden;
    background-color: var(--rp-surface);
    display: flex;
    justify-content: center;
    align-items: center;
}
        .card-image {
    width: 100%;
    height: auto;
    object-fit: contain;
    transition: transform 0.3s ease;
}
        .nav-card:hover .card-image {
    transform: scale(1.05);
}
        .placeholder-image {
    padding: 2rem;
    color: var(--rp-subtle);
    font-size: 1.5rem;
}
        .card-content {
    padding: 1.2rem;
    transition: background var(--transition-speed) var(--transition-ease);
}
        .nav-card:hover .card-content {
    background: linear-gradient(
        180deg,
        rgba(196, 167, 231, 0.06) 0%,
        rgba(196, 167, 231, 0.12) 100%
    );
}
        .card-title {
    font-size: 1.5rem;
    color: var(--rp-gold);
    margin-bottom: 0.5rem;
    line-height: 1.2;
}
        .card-description {
    color: var(--rp-subtle);
    line-height: 1.4;
}
        .emergency-overlay {
    position: fixed;
    top: 20%;
    left: 50%;
    transform: translateX(-50%);
    background-color: rgba(255, 0, 0, 0.9);
    color: white;
    font-size: 2rem;
    font-weight: bold;
    padding: 1.5rem 3rem;
    border-radius: 1rem;
    z-index: 1000;
    animation:
        shake 0.05s infinite,
        pulse 1s infinite alternate;
    box-shadow: 0 0 30px red;
}
        @keyframes shake {
    0%,
    100% {
        transform: translateX(-50%) translateY(0);
    }
    25% {
        transform: translateX(-48%) translateY(-2px);
    }
    75% {
        transform: translateX(-52%) translateY(2px);
    }
}
        @keyframes pulse {
    0% {
        opacity: 0.8;
    }
    100% {
        opacity: 1;
    }
}
        /* Responsive design */
        @media (max-width: 1000px) {
    .navigation-gallery {
        gap: 1rem;
    }
    .navigation-gallery-wrapper {
        padding: 1rem;
    }
}
        @media (max-width: 900px) {
    .navigation-gallery {
        flex-direction: column;
    }
    .nav-column {
        flex-direction: row;
        flex-wrap: wrap;
    }
    .nav-card {
        flex: 1 1 calc(50% - 0.5rem);
        min-width: 280px;
    }
}
        @media (max-width: 600px) {
    .nav-column {
        flex-direction: column;
    }
    .nav-card {
        flex: none;
    }
}
        .hidden {
    display: none !important;
}
        .invisible {
    visibility: hidden !important;
}
        .sr-only {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}
        /* Focus utilities for accessibility */
        .focus-visible:focus-visible {
    outline: 2px solid var(--rp-iris);
    outline-offset: 2px;
}
        /* Transition utilities */
        .transition-none {
    transition: none !important;
}
        .transition-all {
    transition: all var(--transition-speed) var(--transition-ease);
}
        /* Performance optimizations */
        .will-change-transform {
    will-change: transform;
}
        .will-change-opacity {
    will-change: opacity;
}
        .will-change-auto {
    will-change: auto;
}
        /*}*/
