/* ============================================================
   CSS VARIABLES
   ============================================================ */
:root {
    /* Primary Colors */
    --color-black: #0a0a0f;
    --color-deep-black: #050508;
    --color-midnight-navy: #0d1117;
    --color-dark-blue: #0f1a2e;
    --color-deep-red: #8b0000;
    --color-crimson: #a01515;
    --color-bright-red: #c0392b;
    --color-soft-red: #e74c3c;
    --color-glowing-red: #ff2d2d;
    --color-white: #f5f0e8;
    --color-pure-white: #ffffff;
    --color-cream: #e8dcc8;
    --color-gold: #d4a853;
    --color-gold-light: #f0d78c;

    /* Glass Colors */
    --glass-bg: rgba(15, 15, 30, 0.55);
    --glass-bg-light: rgba(25, 25, 50, 0.4);
    --glass-border: rgba(255, 255, 255, 0.1);
    --glass-border-hover: rgba(255, 255, 255, 0.25);
    --glass-shadow: rgba(0, 0, 0, 0.4);

    /* Gradient Colors */
    --gradient-dark: linear-gradient(135deg, #0a0a0f 0%, #0f1a2e 50%, #0d1117 100%);
    --gradient-red: linear-gradient(135deg, #8b0000 0%, #c0392b 50%, #a01515 100%);
    --gradient-gold: linear-gradient(135deg, #d4a853 0%, #f0d78c 50%, #b8943d 100%);
    --gradient-card: linear-gradient(145deg, rgba(25, 25, 50, 0.6) 0%, rgba(15, 15, 30, 0.8) 100%);
    --gradient-hero-overlay: linear-gradient(180deg, rgba(5, 5, 8, 0.7) 0%, rgba(15, 26, 46, 0.85) 50%, rgba(10, 10, 15, 0.95) 100%);

    /* Fonts */
    --font-cinzel: 'Cinzel', serif;
    --font-cormorant: 'Cormorant Garamond', serif;
    --font-playfair: 'Playfair Display', serif;
    --font-raleway: 'Raleway', sans-serif;
    --font-inter: 'Inter', sans-serif;
    --font-eb-garamond: 'EB Garamond', serif;

    /* Spacing */
    --section-padding: 100px 0;
    --section-padding-mobile: 60px 0;

    /* Transitions */
    --transition-smooth: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --transition-bounce: all 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    --transition-slow: all 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);

    /* Border Radius */
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --radius-xl: 32px;
    --radius-full: 50%;

    /* Z-Index */
    --z-preloader: 10000;
    --z-navbar: 1000;
    --z-hero-content: 10;
    --z-particles: 1;
    --z-floating-books: 5;
    --z-back-to-top: 999;
}

/* ============================================================
   RESET & BASE STYLES
   ============================================================ */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
    scrollbar-width: thin;
    scrollbar-color: var(--color-deep-red) var(--color-deep-black);
}

html::-webkit-scrollbar {
    width: 8px;
}

html::-webkit-scrollbar-track {
    background: var(--color-deep-black);
}

html::-webkit-scrollbar-thumb {
    background: var(--color-deep-red);
    border-radius: 4px;
}

html::-webkit-scrollbar-thumb:hover {
    background: var(--color-crimson);
}

body {
    font-family: var(--font-inter);
    background-color: var(--color-deep-black);
    color: var(--color-white);
    overflow-x: hidden;
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    position: relative;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-smooth);
}

ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ============================================================
   PRELOADER
   ============================================================ */
.preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--color-deep-black);
    z-index: var(--z-preloader);
    display: none;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    transition: opacity 0.6s ease, visibility 0.6s ease;
}

html.show-home-preloader .preloader {
    display: flex;
}

.preloader.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.preloader-content {
    text-align: center;
    position: relative;
    z-index: 2;
}

.preloader-book {
    position: relative;
    width: 80px;
    height: 100px;
    margin: 0 auto 30px;
    animation: preloaderBookFloat 2s ease-in-out infinite;
}

.preloader-book-cover {
    width: 80px;
    height: 100px;
    background: var(--gradient-red);
    border-radius: 4px 8px 8px 4px;
    position: relative;
    box-shadow: 0 10px 40px rgba(139, 0, 0, 0.6), 0 0 80px rgba(255, 45, 45, 0.3);
}

.preloader-book-spine {
    position: absolute;
    left: 0;
    top: 0;
    width: 12px;
    height: 100%;
    background: linear-gradient(90deg, #5a0000 0%, #8b0000 100%);
    border-radius: 4px 0 0 4px;
}

.preloader-book-pages {
    position: absolute;
    right: 4px;
    top: 3px;
    width: 60px;
    height: 94px;
    perspective: 200px;
}

.preloader-page {
    position: absolute;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, #f5f0e8 0%, #e8dcc8 50%, #d5c9b0 100%);
    border-radius: 0 4px 4px 0;
    transform-origin: left center;
    animation: preloaderPageFlip 2.5s ease-in-out infinite;
}

.preloader-page-1 {
    animation-delay: 0s;
}

.preloader-page-2 {
    animation-delay: 0.3s;
    background: linear-gradient(180deg, #ede6d8 0%, #ddd0b8 50%, #cbc0a5 100%);
}

.preloader-page-3 {
    animation-delay: 0.6s;
    background: linear-gradient(180deg, #e8dfce 0%, #d8cbb5 50%, #c5b99e 100%);
}

.preloader-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 45, 45, 0.3) 0%, transparent 70%);
    animation: preloaderGlowPulse 1.5s ease-in-out infinite;
}

@keyframes preloaderBookFloat {
    0%,
    100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-12px);
    }
}

@keyframes preloaderPageFlip {
    0%,
    100% {
        transform: rotateY(0deg);
    }
    50% {
        transform: rotateY(-25deg);
    }
}

@keyframes preloaderGlowPulse {
    0%,
    100% {
        opacity: 0.5;
        transform: translate(-50%, -50%) scale(1);
    }
    50% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1.3);
    }
}

.preloader-text {
    margin-bottom: 10px;
    display: flex;
    justify-content: center;
    gap: 3px;
}

.preloader-letter {
    font-family: var(--font-cinzel);
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--color-pure-white);
    display: inline-block;
    animation: preloaderLetterFade 1.4s ease-in-out infinite;
}

.preloader-letter:nth-child(1) {
    animation-delay: 0s;
}
.preloader-letter:nth-child(2) {
    animation-delay: 0.1s;
}
.preloader-letter:nth-child(3) {
    animation-delay: 0.2s;
}
.preloader-letter:nth-child(4) {
    animation-delay: 0.3s;
}
.preloader-letter:nth-child(5) {
    animation-delay: 0.4s;
}
.preloader-letter:nth-child(6) {
    animation-delay: 0.5s;
}
.preloader-letter:nth-child(7) {
    animation-delay: 0.6s;
}

@keyframes preloaderLetterFade {
    0%,
    100% {
        opacity: 0.3;
        transform: translateY(0);
    }
    50% {
        opacity: 1;
        transform: translateY(-8px);
    }
}

.preloader-subtitle {
    font-family: var(--font-cormorant);
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.6);
    margin-bottom: 20px;
    letter-spacing: 2px;
}

.preloader-progress {
    width: 200px;
    height: 3px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    overflow: hidden;
    margin: 0 auto;
}

.preloader-progress-bar {
    height: 100%;
    background: var(--gradient-red);
    border-radius: 10px;
    width: 0%;
    animation: preloaderProgress 2s ease-in-out forwards;
}

@keyframes preloaderProgress {
    0% {
        width: 0%;
    }
    50% {
        width: 60%;
    }
    100% {
        width: 100%;
    }
}

.preloader-particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

/* ============================================================
   GLASS NAVBAR
   ============================================================ */
.glass-navbar {
    background: rgba(10, 10, 20, 0.75);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--glass-border);
    padding: 12px 0;
    transition: var(--transition-smooth);
    z-index: var(--z-navbar);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.5);
}

.glass-navbar.scrolled {
    background: rgba(8, 8, 16, 0.9);
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 45, 45, 0.3);
    box-shadow: 0 4px 40px rgba(139, 0, 0, 0.3), 0 0 60px rgba(0, 0, 0, 0.7);
}

.navbar-glow-line {
    display: none !important;
}

.glass-navbar.scrolled .navbar-glow-line {
    display: none !important;
}

.brand-logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.brand-icon {
    font-size: 1.8rem;
    color: var(--color-glowing-red);
    animation: brandIconPulse 3s ease-in-out infinite;
}

@keyframes brandIconPulse {
    0%,
    100% {
        text-shadow: 0 0 10px rgba(255, 45, 45, 0.5);
    }
    50% {
        text-shadow: 0 0 25px rgba(255, 45, 45, 0.9), 0 0 50px rgba(255, 45, 45, 0.4);
    }
}

.brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1;
}

.brand-name {
    font-family: var(--font-cinzel);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-pure-white);
    letter-spacing: 1px;
}

.brand-sub {
    font-family: var(--font-cormorant);
    font-size: 0.7rem;
    color: var(--color-gold-light);
    letter-spacing: 3px;
    text-transform: uppercase;
}

.navbar-nav .nav-link {
    color: rgba(255, 255, 255, 0.8) !important;
    font-family: var(--font-raleway);
    font-weight: 500;
    font-size: 0.9rem;
    padding: 8px 16px !important;
    position: relative;
    letter-spacing: 0.5px;
    transition: var(--transition-smooth);
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
    color: var(--color-pure-white) !important;
}

.navbar-nav .nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background: var(--color-glowing-red);
    transition: width 0.3s ease;
    border-radius: 2px;
}

.navbar-nav .nav-link::after,
.navbar-nav .nav-link:hover::after,
.navbar-nav .nav-link.active::after {
    display: none !important;
    content: none !important;
}

.navbar-nav .dropdown-toggle::after,
.navbar-nav .dropdown-toggle:hover::after,
.navbar-nav .dropdown-toggle.active::after {
    position: static;
    width: 0;
    height: 0;
    margin-left: 0.255em;
    vertical-align: 0.255em;
    content: "";
    background: transparent;
    border-top: 0.3em solid;
    border-right: 0.3em solid transparent;
    border-bottom: 0;
    border-left: 0.3em solid transparent;
    transform: none;
}

.nav-link-icon {
    font-size: 0.8rem;
    margin-right: 4px;
    color: var(--color-glowing-red);
}

.glass-navbar .dropdown-menu {
    border-radius: 8px;
    padding: 8px;
}

.glass-navbar .dropdown-item {
    border-radius: 6px;
    font-family: var(--font-raleway);
    font-size: 0.9rem;
    transition: var(--transition-smooth);
}

.glass-navbar .dropdown-item:hover,
.glass-navbar .dropdown-item:focus {
    background: rgba(255, 45, 45, 0.16);
    color: #fff !important;
}

.btn-nav-cta {
    background: var(--gradient-red);
    color: var(--color-pure-white);
    border: none;
    padding: 10px 22px;
    border-radius: 30px;
    font-family: var(--font-raleway);
    font-weight: 600;
    font-size: 0.85rem;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition-bounce);
    box-shadow: 0 4px 20px rgba(139, 0, 0, 0.5);
    position: relative;
    overflow: hidden;
}

.btn-nav-cta:hover,
.btn-nav-cta.active {
    transform: translateY(-3px);
    box-shadow: 0 8px 30px rgba(255, 45, 45, 0.6);
    color: var(--color-pure-white);
}

.btn-nav-cta::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.2) 0%, transparent 60%);
    animation: btnShine 3s infinite;
}

@keyframes btnShine {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

.custom-toggler {
    border: none;
    padding: 8px;
    background: transparent;
    cursor: pointer;
    position: relative;
    width: 40px;
    height: 30px;
}

.toggler-line {
    display: block;
    width: 28px;
    height: 2px;
    background: var(--color-pure-white);
    margin: 6px auto;
    transition: var(--transition-smooth);
    border-radius: 2px;
}

.custom-toggler[aria-expanded="true"] .toggler-line-1 {
    transform: translateY(8px) rotate(45deg);
}

.custom-toggler[aria-expanded="true"] .toggler-line-2 {
    opacity: 0;
}

.custom-toggler[aria-expanded="true"] .toggler-line-3 {
    transform: translateY(-8px) rotate(-45deg);
}

/* ============================================================
   HERO SECTION
   ============================================================ */
.hero-section {
    position: relative;
    min-height: 100vh;
    background: var(--gradient-dark);
    overflow: hidden;
    display: flex;
    align-items: center;
}

.particles-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: var(--z-particles);
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--gradient-hero-overlay);
    z-index: 2;
}

.hero-glow-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    z-index: 3;
    pointer-events: none;
}

.hero-glow-orb-1 {
    width: 400px;
    height: 400px;
    background: rgba(139, 0, 0, 0.25);
    top: -100px;
    left: -100px;
    animation: orbFloat1 8s ease-in-out infinite;
}

.hero-glow-orb-2 {
    width: 350px;
    height: 350px;
    background: rgba(15, 26, 46, 0.4);
    bottom: -80px;
    right: -80px;
    animation: orbFloat2 10s ease-in-out infinite;
}

.hero-glow-orb-3 {
    width: 250px;
    height: 250px;
    background: rgba(212, 168, 83, 0.15);
    top: 50%;
    right: 30%;
    animation: orbFloat3 7s ease-in-out infinite;
}

@keyframes orbFloat1 {
    0%,
    100% {
        transform: translate(0, 0);
    }
    33% {
        transform: translate(40px, 30px);
    }
    66% {
        transform: translate(-20px, -30px);
    }
}

@keyframes orbFloat2 {
    0%,
    100% {
        transform: translate(0, 0);
    }
    33% {
        transform: translate(-30px, -20px);
    }
    66% {
        transform: translate(25px, 35px);
    }
}

@keyframes orbFloat3 {
    0%,
    100% {
        transform: translate(0, 0);
    }
    50% {
        transform: translate(-40px, 25px);
    }
}

.hero-container {
    position: relative;
    z-index: var(--z-hero-content);
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.15);
    padding: 8px 18px;
    border-radius: 30px;
    font-size: 0.85rem;
    color: var(--color-gold-light);
    font-family: var(--font-raleway);
    letter-spacing: 1px;
    margin-bottom: 20px;
    animation: badgeGlow 3s ease-in-out infinite;
}

@keyframes badgeGlow {
    0%,
    100% {
        box-shadow: 0 0 15px rgba(212, 168, 83, 0.2);
    }
    50% {
        box-shadow: 0 0 30px rgba(212, 168, 83, 0.5);
    }
}

.hero-badge-dot {
    width: 8px;
    height: 8px;
    background: var(--color-glowing-red);
    border-radius: 50%;
    animation: dotPulse 1.5s ease-in-out infinite;
}

@keyframes dotPulse {
    0%,
    100% {
        box-shadow: 0 0 5px var(--color-glowing-red);
    }
    50% {
        box-shadow: 0 0 20px var(--color-glowing-red), 0 0 40px rgba(255, 45, 45, 0.6);
    }
}

.hero-title {
    font-family: var(--font-cinzel);
    font-weight: 900;
    margin-bottom: 15px;
}

.hero-title-line-1 {
    display: block;
    font-size: 4.5rem;
    color: var(--color-pure-white);
    letter-spacing: 3px;
    text-shadow: 0 0 40px rgba(255, 255, 255, 0.3), 0 0 80px rgba(139, 0, 0, 0.4);
    line-height: 1.1;
}

.hero-title-line-2 {
    display: block;
    font-size: 2.8rem;
    color: var(--color-gold-light);
    letter-spacing: 8px;
    font-weight: 600;
    line-height: 1.3;
}

.hero-typed-wrapper {
    font-family: var(--font-cormorant);
    font-size: 1.6rem;
    color: var(--color-cream);
    margin-bottom: 20px;
    min-height: 40px;
    font-style: italic;
}

.hero-typed-prefix {
    color: rgba(255, 255, 255, 0.7);
}

.hero-typed-text {
    color: var(--color-gold-light);
    font-weight: 600;
}

.hero-paragraph {
    font-family: var(--font-raleway);
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 30px;
    max-width: 550px;
    line-height: 1.8;
}

.hero-buttons {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 40px;
}

.btn-hero-primary {
    background: var(--gradient-red);
    color: var(--color-pure-white);
    border: none;
    padding: 14px 32px;
    border-radius: 30px;
    font-family: var(--font-raleway);
    font-weight: 600;
    font-size: 1rem;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: var(--transition-bounce);
    box-shadow: 0 6px 25px rgba(139, 0, 0, 0.5);
    position: relative;
    overflow: hidden;
}

.btn-hero-primary:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(255, 45, 45, 0.6);
    color: var(--color-pure-white);
}

.btn-hero-secondary {
    background: transparent;
    color: var(--color-pure-white);
    border: 2px solid rgba(255, 255, 255, 0.3);
    padding: 14px 32px;
    border-radius: 30px;
    font-family: var(--font-raleway);
    font-weight: 600;
    font-size: 1rem;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: var(--transition-bounce);
    position: relative;
    overflow: hidden;
}

.btn-hero-secondary:hover {
    border-color: var(--color-gold-light);
    color: var(--color-gold-light);
    transform: translateY(-4px);
    box-shadow: 0 8px 30px rgba(212, 168, 83, 0.3);
}

.btn-shine {
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.6s ease;
}

.btn-hero-primary:hover .btn-shine,
.btn-hero-secondary:hover .btn-shine {
    left: 100%;
}

.hero-stats {
    display: flex;
    gap: 25px;
    align-items: center;
    flex-wrap: wrap;
}

.hero-stat-item {
    text-align: center;
}

.hero-stat-number {
    display: block;
    font-family: var(--font-cinzel);
    font-size: 2rem;
    font-weight: 700;
    color: var(--color-pure-white);
}

.hero-stat-label {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.5);
    letter-spacing: 1px;
    text-transform: uppercase;
}

.hero-stat-divider {
    width: 1px;
    height: 40px;
    background: rgba(255, 255, 255, 0.15);
}

.hero-image-col {
    position: relative;
}

.hero-image-wrapper {
    position: relative;
}

.hero-image-frame {
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6), 0 0 80px rgba(139, 0, 0, 0.2);
    animation: heroImageZoom 20s ease-in-out infinite;
}

@keyframes heroImageZoom {
    0%,
    100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

.hero-image {
    width: 100%;
    height: 500px;
    object-fit: cover;
    border-radius: var(--radius-lg);
    transition: transform 0.5s ease;
}

.hero-image-glow-ring {
    position: absolute;
    top: -4px;
    left: -4px;
    right: -4px;
    bottom: -4px;
    border-radius: calc(var(--radius-lg) + 4px);
    border: 2px solid rgba(255, 45, 45, 0.3);
    animation: glowRingPulse 3s ease-in-out infinite;
    pointer-events: none;
}

@keyframes glowRingPulse {
    0%,
    100% {
        box-shadow: 0 0 15px rgba(255, 45, 45, 0.2), inset 0 0 15px rgba(255, 45, 45, 0.1);
    }
    50% {
        box-shadow: 0 0 40px rgba(255, 45, 45, 0.5), inset 0 0 30px rgba(255, 45, 45, 0.2);
    }
}

.hero-floating-card {
    position: absolute;
    z-index: 5;
    animation: floatingCardBounce 4s ease-in-out infinite;
}

.hero-floating-card-1 {
    top: 30px;
    left: -30px;
    animation-delay: 0s;
}

.hero-floating-card-2 {
    bottom: 40px;
    right: -25px;
    animation-delay: 1.5s;
}

@keyframes floatingCardBounce {
    0%,
    100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-15px);
    }
}

.mini-book-card {
    background: var(--glass-bg);
    backdrop-filter: blur(15px);
    border: 1px solid var(--glass-border);
    border-radius: 30px;
    padding: 10px 18px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    color: var(--color-pure-white);
    white-space: nowrap;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
}

.mini-book-card i {
    color: var(--color-gold-light);
}

.hero-scroll-indicator {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.75rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    animation: scrollFade 2s ease-in-out infinite;
}

@keyframes scrollFade {
    0%,
    100% {
        opacity: 0.5;
    }
    50% {
        opacity: 1;
    }
}

.scroll-mouse {
    width: 24px;
    height: 38px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 14px;
    position: relative;
}

.scroll-wheel {
    width: 4px;
    height: 8px;
    background: var(--color-glowing-red);
    border-radius: 2px;
    position: absolute;
    top: 6px;
    left: 50%;
    transform: translateX(-50%);
    animation: scrollWheel 1.5s ease-in-out infinite;
}

@keyframes scrollWheel {
    0% {
        top: 6px;
        opacity: 1;
    }
    100% {
        top: 22px;
        opacity: 0;
    }
}

.scroll-arrow {
    animation: scrollArrowBounce 1.5s ease-in-out infinite;
}

@keyframes scrollArrowBounce {
    0%,
    100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(6px);
    }
}

.hero-bottom-gradient {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 150px;
    background: linear-gradient(to top, var(--color-deep-black) 0%, transparent 100%);
    z-index: 4;
}

/* Floating Books */
.floating-books-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: var(--z-floating-books);
    pointer-events: none;
}

.floating-book {
    position: absolute;
    font-size: 2rem;
    color: rgba(255, 255, 255, 0.15);
    animation: floatingBookDrift 8s ease-in-out infinite;
}

.floating-book i {
    filter: drop-shadow(0 0 10px rgba(139, 0, 0, 0.4));
}

.floating-book-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 45, 45, 0.2) 0%, transparent 70%);
}

.floating-book-1 {
    top: 15%;
    left: 8%;
    animation-delay: 0s;
}
.floating-book-2 {
    top: 25%;
    right: 10%;
    animation-delay: 1.5s;
}
.floating-book-3 {
    top: 60%;
    left: 5%;
    animation-delay: 3s;
}
.floating-book-4 {
    top: 70%;
    right: 8%;
    animation-delay: 4.5s;
}
.floating-book-5 {
    top: 40%;
    left: 15%;
    animation-delay: 6s;
}
.floating-book-6 {
    top: 50%;
    right: 18%;
    animation-delay: 2s;
}

@keyframes floatingBookDrift {
    0%,
    100% {
        transform: translateY(0) rotate(0deg);
    }
    25% {
        transform: translateY(-20px) rotate(3deg);
    }
    50% {
        transform: translateY(-5px) rotate(-2deg);
    }
    75% {
        transform: translateY(-25px) rotate(4deg);
    }
}

/* ============================================================
   SEARCH SECTION
   ============================================================ */
.search-section {
    padding: 0 0 40px;
    margin-top: -50px;
    position: relative;
    z-index: 20;
}

.search-wrapper {
    max-width: 700px;
    margin: 0 auto;
    padding: 8px;
    border-radius: 50px;
    position: relative;
}

.search-inner {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 5px;
    position: relative;
    z-index: 2;
}

.search-icon {
    font-size: 1.3rem;
    color: rgba(255, 255, 255, 0.5);
    margin-left: 15px;
}

.search-input {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--color-pure-white);
    font-family: var(--font-raleway);
    font-size: 1rem;
    padding: 12px 5px;
    outline: none;
}

.search-input::placeholder {
    color: rgba(255, 255, 255, 0.35);
}

.btn-search {
    background: var(--gradient-red);
    color: var(--color-pure-white);
    border: none;
    padding: 12px 28px;
    border-radius: 30px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition-bounce);
}

.btn-search:hover {
    box-shadow: 0 6px 25px rgba(255, 45, 45, 0.5);
    color: var(--color-pure-white);
}

.search-suggestions {
    position: absolute;
    bottom: -30px;
    left: 50px;
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.suggestion-tag {
    font-size: 0.7rem;
    color: rgba(255, 255, 255, 0.4);
    cursor: pointer;
    padding: 3px 10px;
    border-radius: 15px;
    background: rgba(255, 255, 255, 0.04);
    transition: var(--transition-smooth);
}

.suggestion-tag:hover {
    color: var(--color-gold-light);
    background: rgba(255, 255, 255, 0.1);
}

.search-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 90%;
    height: 80%;
    background: radial-gradient(ellipse, rgba(255, 45, 45, 0.08) 0%, transparent 70%);
    border-radius: 50px;
    z-index: 1;
    pointer-events: none;
}

/* ============================================================
   GLASS CARD BASE
   ============================================================ */
.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    transition: var(--transition-smooth);
}

.glass-card:hover {
    border-color: var(--glass-border-hover);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5), 0 0 30px rgba(139, 0, 0, 0.15);
}

/* ============================================================
   SECTION HEADERS
   ============================================================ */
.section-header {
    margin-bottom: 60px;
}

.section-subtitle {
    display: inline-block;
    font-family: var(--font-cormorant);
    font-size: 1.1rem;
    color: var(--color-gold-light);
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-bottom: 10px;
}

.section-title {
    font-family: var(--font-cinzel);
    font-size: 2rem;
    font-weight: 700;
    color: var(--color-pure-white);
    margin-bottom: 10px;
    letter-spacing: 1px;
}

.section-divider {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 15px;
}

.divider-line {
    width: 50px;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 45, 45, 0.6), transparent);
}

.divider-icon {
    color: var(--color-glowing-red);
    font-size: 1.2rem;
}

.section-description {
    font-family: var(--font-raleway);
    color: rgba(255, 255, 255, 0.6);
    max-width: 600px;
    margin: 0 auto;
    font-size: 1rem;
    line-height: 1.7;
}

/* ============================================================
   STORY SECTION
   ============================================================ */
.story-section {
    padding: var(--section-padding);
    background: var(--color-deep-black);
    position: relative;
    overflow: hidden;
}

.story-particles-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(ellipse at 30% 50%, rgba(139, 0, 0, 0.06) 0%, transparent 60%),
        radial-gradient(ellipse at 70% 30%, rgba(15, 26, 46, 0.4) 0%, transparent 50%);
    pointer-events: none;
}

.story-image-wrapper {
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.6);
}

.story-image {
    width: 100%;
    height: 450px;
    object-fit: cover;
    border-radius: var(--radius-lg);
}

.story-image-frame-glow {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: var(--radius-lg);
    box-shadow: inset 0 0 60px rgba(139, 0, 0, 0.3);
    pointer-events: none;
}

.story-floating-orb {
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
}

.story-orb-1 {
    width: 80px;
    height: 80px;
    background: rgba(255, 45, 45, 0.2);
    top: -30px;
    right: -25px;
    filter: blur(30px);
    animation: orbFloat1 6s ease-in-out infinite;
}

.story-orb-2 {
    width: 60px;
    height: 60px;
    background: rgba(212, 168, 83, 0.2);
    bottom: -20px;
    left: -20px;
    filter: blur(25px);
    animation: orbFloat2 7s ease-in-out infinite;
}

.story-content {
    padding-left: 20px;
}

.story-heading {
    font-family: var(--font-playfair);
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--color-pure-white);
    margin-bottom: 20px;
    line-height: 1.3;
}

.story-text {
    font-family: var(--font-raleway);
    color: rgba(255, 255, 255, 0.65);
    margin-bottom: 15px;
    font-size: 1rem;
    line-height: 1.8;
}

.story-features-mini {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    margin: 25px 0;
}

.story-mini-item {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--color-gold-light);
    font-family: var(--font-raleway);
    font-weight: 500;
    font-size: 0.9rem;
}

.story-mini-item i {
    font-size: 1.2rem;
}

.btn-story {
    background: var(--gradient-red);
    color: var(--color-pure-white);
    border: none;
    padding: 14px 30px;
    border-radius: 30px;
    font-family: var(--font-raleway);
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    transition: var(--transition-bounce);
    box-shadow: 0 6px 25px rgba(139, 0, 0, 0.4);
}

.btn-story:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 35px rgba(255, 45, 45, 0.5);
    color: var(--color-pure-white);
}

/* ============================================================
   BOOKS SECTION
   ============================================================ */
.books-section {
    padding: var(--section-padding);
    background: var(--color-midnight-navy);
    position: relative;
    overflow: hidden;
}

.books-bg-glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    pointer-events: none;
    z-index: 0;
}

.books-bg-glow-1 {
    width: 500px;
    height: 500px;
    background: rgba(139, 0, 0, 0.1);
    top: -150px;
    left: -150px;
}

.books-bg-glow-2 {
    width: 400px;
    height: 400px;
    background: rgba(15, 26, 46, 0.5);
    bottom: -100px;
    right: -100px;
}

/* Smart Filters */
.smart-filters {
    margin-bottom: 40px;
    position: relative;
    z-index: 2;
}

.filter-wrapper {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
}

.filter-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: rgba(255, 255, 255, 0.7);
    padding: 10px 20px;
    border-radius: 30px;
    font-family: var(--font-raleway);
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition-bounce);
    display: flex;
    align-items: center;
    gap: 6px;
}

.filter-btn i {
    font-size: 0.9rem;
}

.filter-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--color-pure-white);
    border-color: rgba(255, 255, 255, 0.3);
}

.filter-btn.active {
    background: var(--gradient-red);
    border-color: transparent;
    color: var(--color-pure-white);
    box-shadow: 0 4px 20px rgba(255, 45, 45, 0.4);
}

.audio-only-filter {
    width: fit-content;
    margin: 18px auto 0;
    padding: 11px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    color: rgba(255, 255, 255, 0.72);
    background: rgba(255, 255, 255, 0.045);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 14px;
    cursor: pointer;
    transition: var(--transition-smooth);
}

.audio-only-filter:hover,
.audio-only-filter:has(input:focus-visible) {
    color: #fff;
    border-color: rgba(255, 45, 45, 0.45);
    background: rgba(255, 45, 45, 0.08);
}

.audio-only-filter input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.audio-only-control {
    width: 42px;
    height: 24px;
    padding: 2px;
    display: flex;
    align-items: center;
    flex: 0 0 auto;
    background: rgba(255, 255, 255, 0.12);
    border-radius: 999px;
    transition: var(--transition-smooth);
}

.audio-only-control i {
    width: 20px;
    height: 20px;
    display: grid;
    place-items: center;
    color: rgba(255, 255, 255, 0.75);
    background: #2b2b33;
    border-radius: 50%;
    font-size: 0.68rem;
    transition: var(--transition-bounce);
}

.audio-only-filter input:checked + .audio-only-control {
    background: var(--gradient-red);
    box-shadow: 0 0 20px rgba(255, 45, 45, 0.28);
}

.audio-only-filter input:checked + .audio-only-control i {
    color: var(--color-blood-red);
    background: #fff;
    transform: translateX(18px);
}

.audio-only-filter strong,
.audio-only-filter small {
    display: block;
}

.audio-only-filter strong {
    color: #fff;
    font-size: 0.86rem;
}

.audio-only-filter small {
    margin-top: 1px;
    font-size: 0.72rem;
}

/* Books Grid */
.books-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
    position: relative;
    z-index: 2;
}

#catalogResults {
    min-height: 220px;
    transition: opacity 180ms ease, transform 180ms ease;
}

#catalogResults.catalog-results-loading {
    opacity: 0.42;
    transform: translateY(4px);
    pointer-events: none;
}

.explore-empty-state {
    grid-column: 1 / -1;
    padding: 42px 30px;
    text-align: center;
}

.explore-empty-state > i {
    display: block;
    margin-bottom: 12px;
    color: var(--color-glowing-red);
    font-size: 2rem;
}

.explore-empty-state h4 {
    margin-bottom: 10px;
    color: #fff;
}

.explore-empty-state p {
    margin: 0;
    color: rgba(255, 255, 255, 0.65);
}

.explore-pagination span {
    margin: 0 16px;
    color: rgba(255, 255, 255, 0.75);
}

.book-card-wrapper {
    perspective: 1000px;
}

.book-card {
    position: relative;
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: var(--transition-smooth);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.book-card:hover {
    transform: translateY(-10px);
    border-color: rgba(255, 45, 45, 0.4);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6), 0 0 40px rgba(139, 0, 0, 0.2);
}

.book-card-badge {
    position: absolute;
    top: 14px;
    left: 14px;
    right: auto;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 1px;
    z-index: 5;
    text-transform: uppercase;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
}

.badge-premium {
    background: linear-gradient(135deg, rgba(212, 168, 83, 0.95), rgba(184, 148, 61, 0.95));
    color: #0d0d12;
    border: 1px solid rgba(240, 215, 140, 0.6);
}

.badge-free {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.9), rgba(5, 150, 105, 0.9));
    color: #ffffff;
    border: 1px solid rgba(110, 231, 183, 0.5);
}

.book-card-image-wrapper {
    position: relative;
    height: 240px;
    overflow: hidden;
    background: linear-gradient(160deg, #2a1212, #120c0c);
}

.book-card-fallback {
    display: none;
    position: absolute;
    inset: 0;
    align-items: flex-end;
    padding: 18px;
    background:
        linear-gradient(180deg, rgba(18, 8, 8, 0.15), rgba(18, 8, 8, 0.88)),
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.04) 0 12px, transparent 12px 28px);
}

.book-card-image-wrapper:not(:has(img)) .book-card-fallback {
    display: flex;
}

.book-card-fallback span {
    color: #fff;
    font-family: "Playfair Display", serif;
    font-size: 22px;
    line-height: 1.2;
}

.book-card-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.book-card:hover .book-card-image {
    transform: scale(1.1);
}

.book-card-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.book-card:hover .book-card-overlay {
    opacity: 1;
}

.book-card-preview-btn {
    color: var(--color-pure-white);
    background: rgba(255, 45, 45, 0.8);
    padding: 10px 20px;
    border-radius: 25px;
    font-size: 0.85rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: var(--transition-bounce);
}

.book-card-preview-btn:hover {
    background: var(--color-glowing-red);
    color: var(--color-pure-white);
    transform: scale(1.05);
}

.book-card-shine {
    position: absolute;
    top: 0;
    left: -100%;
    width: 60%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.08), transparent);
    transform: skewX(-20deg);
    transition: left 0.6s ease;
    pointer-events: none;
}

.book-card:hover .book-card-shine {
    left: 120%;
}

.book-card-body {
    padding: 18px;
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
}

.book-card-title {
    font-family: var(--font-playfair);
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--color-pure-white);
    margin: 6px 0 4px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.35;
    min-height: 2.7em;
}

.book-card-author {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.5);
    margin-bottom: 10px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.book-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: auto;
    padding-top: 10px;
}

.book-card-category {
    font-size: 0.75rem;
    color: var(--color-gold-light);
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: 600;
}



.book-card-rating {
    display: flex;
    align-items: center;
    gap: 2px;
    margin-bottom: 14px;
}

.book-card-rating i {
    color: #f0d78c;
    font-size: 0.75rem;
}

.rating-number {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.6);
    margin-left: 5px;
}



.book-card-price {
    font-family: var(--font-cinzel);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--color-pure-white);
}

.free-label {
    color: #27ae60;
}

.btn-book-card {
    background: var(--gradient-red);
    color: var(--color-pure-white);
    border: none;
    padding: 8px 18px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 5px;
    transition: var(--transition-bounce);
}

.btn-book-card:hover {
    box-shadow: 0 4px 18px rgba(255, 45, 45, 0.4);
    color: var(--color-pure-white);
    transform: translateY(-2px);
}

.btn-book-card-free {
    background: #27ae60;
}

.btn-book-card-free:hover {
    box-shadow: 0 4px 18px rgba(39, 174, 96, 0.4);
}

.book-card-border-glow {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, rgba(255, 45, 45, 0.5), transparent);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.book-card:hover .book-card-border-glow {
    opacity: 1;
}

.books-load-more {
    margin-top: 50px;
    position: relative;
    z-index: 2;
}

.btn-load-more {
    background: transparent;
    border: 2px solid rgba(255, 255, 255, 0.2);
    color: var(--color-pure-white);
    padding: 14px 35px;
    border-radius: 30px;
    font-family: var(--font-raleway);
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    transition: var(--transition-bounce);
}

.btn-load-more:hover {
    border-color: var(--color-glowing-red);
    color: var(--color-glowing-red);
    box-shadow: 0 6px 25px rgba(255, 45, 45, 0.2);
}

/* ============================================================
   AUDIO SECTION
   ============================================================ */
.audio-section {
    padding: var(--section-padding);
    background: var(--color-deep-black);
    position: relative;
}

.audio-bg-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(ellipse at 30% 60%, rgba(139, 0, 0, 0.06) 0%, transparent 50%),
        radial-gradient(ellipse at 70% 40%, rgba(212, 168, 83, 0.04) 0%, transparent 50%);
    pointer-events: none;
}

.audio-card {
    padding: 40px 35px;
    text-align: center;
    height: 100%;
}

.audio-card-icon-wrapper {
    width: 80px;
    height: 80px;
    margin: 0 auto 25px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.audio-card-icon {
    font-size: 2.5rem;
    color: var(--color-glowing-red);
    position: relative;
    z-index: 2;
}

.audio-card-icon-glow {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 45, 45, 0.3) 0%, transparent 70%);
    animation: iconGlowPulse 2s ease-in-out infinite;
}

@keyframes iconGlowPulse {
    0%,
    100% {
        transform: scale(1);
        opacity: 0.5;
    }
    50% {
        transform: scale(1.3);
        opacity: 1;
    }
}

.audio-card-audio .audio-card-icon {
    color: var(--color-gold-light);
}

.audio-card-audio .audio-card-icon-glow {
    background: radial-gradient(circle, rgba(212, 168, 83, 0.3) 0%, transparent 70%);
}

.audio-card-title {
    font-family: var(--font-playfair);
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--color-pure-white);
    margin-bottom: 15px;
}

.audio-card-text {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.95rem;
    line-height: 1.7;
    margin-bottom: 20px;
}

.audio-card-features {
    text-align: left;
    margin-bottom: 25px;
}

.audio-card-features li {
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 10px;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.audio-card-features li i {
    color: #27ae60;
}

.btn-audio-card {
    background: var(--gradient-red);
    color: var(--color-pure-white);
    border: none;
    padding: 12px 28px;
    border-radius: 30px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition-bounce);
}

.btn-audio-card:hover {
    box-shadow: 0 6px 25px rgba(255, 45, 45, 0.4);
    color: var(--color-pure-white);
    transform: translateY(-2px);
}

.btn-audio-card-alt {
    background: linear-gradient(135deg, #d4a853, #b8943d);
    color: #1a1a1a;
}

.btn-audio-card-alt:hover {
    box-shadow: 0 6px 25px rgba(212, 168, 83, 0.5);
    color: #1a1a1a;
}

/* ============================================================
   FEATURES SECTION
   ============================================================ */
.features-section {
    padding: var(--section-padding);
    background: var(--color-dark-blue);
    position: relative;
    overflow: hidden;
}

.features-bg-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(120px);
    pointer-events: none;
}

.features-bg-orb-1 {
    width: 600px;
    height: 600px;
    background: rgba(139, 0, 0, 0.08);
    top: -200px;
    right: -200px;
}

.features-bg-orb-2 {
    width: 500px;
    height: 500px;
    background: rgba(15, 26, 46, 0.6);
    bottom: -150px;
    left: -150px;
}

.feature-card {
    padding: 30px 25px;
    text-align: center;
    height: 100%;
    position: relative;
    z-index: 2;
}

.feature-icon-box {
    width: 65px;
    height: 65px;
    border-radius: 50%;
    background: rgba(255, 45, 45, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 1.6rem;
    color: var(--color-glowing-red);
    border: 1px solid rgba(255, 45, 45, 0.2);
    transition: var(--transition-smooth);
}

.feature-card:hover .feature-icon-box {
    background: rgba(255, 45, 45, 0.2);
    border-color: rgba(255, 45, 45, 0.5);
    box-shadow: 0 0 30px rgba(255, 45, 45, 0.3);
}

.feature-card-title {
    font-family: var(--font-playfair);
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--color-pure-white);
    margin-bottom: 10px;
}

.feature-card-text {
    color: rgba(255, 255, 255, 0.55);
    font-size: 0.88rem;
    line-height: 1.6;
}

.feature-card-support {
    border-color: rgba(212, 168, 83, 0.24);
}

.feature-card-link {
    width: fit-content;
    margin: 18px auto 0;
    padding: 9px 15px;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: #fff;
    background: rgba(255, 45, 45, 0.12);
    border: 1px solid rgba(255, 45, 45, 0.28);
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 700;
    transition: var(--transition-smooth);
}

.feature-card-link:hover {
    color: #fff;
    background: var(--gradient-red);
    transform: translateY(-2px);
}

/* Swiper Slider for Real Libryzo Features */
.features-swiper-container {
    width: 100%;
    position: relative;
    padding: 10px 0 20px;
}

.featuresSwiper {
    width: 100%;
    padding: 20px 6px 30px;
    overflow: hidden;
    position: relative;
}

.featuresSwiper .swiper-wrapper {
    align-items: stretch;
}

.featuresSwiper .swiper-slide {
    height: auto;
    display: flex;
    flex-shrink: 0;
    box-sizing: border-box;
}

.featuresSwiper .swiper-slide .feature-card {
    width: 100%;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    text-align: center;
    border-radius: 20px;
    padding: 32px 22px 26px;
    background: linear-gradient(145deg, rgba(20, 24, 38, 0.85), rgba(10, 14, 24, 0.92));
    border: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.2, 1), border-color 0.35s ease, box-shadow 0.35s ease;
    min-height: 310px;
}

.featuresSwiper .swiper-slide .feature-card:hover {
    transform: translateY(-8px);
    border-color: rgba(255, 45, 45, 0.5);
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.55), 0 0 30px rgba(255, 45, 45, 0.18);
}

.featuresSwiper .swiper-slide .feature-card .feature-icon-box {
    width: 66px;
    height: 66px;
    border-radius: 18px;
    background: linear-gradient(135deg, rgba(255, 45, 45, 0.16), rgba(212, 168, 83, 0.1));
    border: 1px solid rgba(255, 45, 45, 0.28);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 18px;
    font-size: 1.65rem;
    color: var(--color-glowing-red);
    transition: all 0.35s ease;
    box-shadow: 0 8px 20px rgba(255, 45, 45, 0.12);
}

.featuresSwiper .swiper-slide .feature-card:hover .feature-icon-box {
    transform: scale(1.1) rotate(4deg);
    background: linear-gradient(135deg, rgba(255, 45, 45, 0.3), rgba(212, 168, 83, 0.2));
    border-color: rgba(255, 45, 45, 0.6);
    box-shadow: 0 10px 28px rgba(255, 45, 45, 0.35);
}

.featuresSwiper .swiper-slide .feature-card .feature-card-title {
    font-family: var(--font-playfair);
    font-size: 1.18rem;
    font-weight: 700;
    color: var(--color-pure-white);
    margin-bottom: 10px;
    letter-spacing: 0.2px;
}

.featuresSwiper .swiper-slide .feature-card .feature-card-text {
    flex-grow: 1;
    color: rgba(255, 255, 255, 0.65);
    font-size: 0.88rem;
    line-height: 1.6;
    margin-bottom: 18px;
}

.featuresSwiper .swiper-slide .feature-card .feature-card-link {
    width: fit-content;
    margin: auto auto 0;
    padding: 8px 18px;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: #fff;
    background: rgba(255, 45, 45, 0.12);
    border: 1px solid rgba(255, 45, 45, 0.3);
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.25s ease;
}

.featuresSwiper .swiper-slide .feature-card .feature-card-link:hover {
    color: #fff;
    background: var(--gradient-red);
    border-color: var(--color-glowing-red);
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(255, 45, 45, 0.45);
}

/* Slider Controls: Navigation Arrows and Dynamic Pagination */
.features-swiper-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    margin-top: 15px;
    position: relative;
    z-index: 10;
}

.features-swiper-nav-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-pure-white);
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.16);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
    cursor: pointer;
    font-size: 1.1rem;
    transition: all 0.22s ease;
    flex-shrink: 0;
}

.features-swiper-nav-btn:hover {
    background: var(--gradient-red);
    border-color: var(--color-glowing-red);
    transform: scale(1.08);
    color: #fff;
    box-shadow: 0 0 18px rgba(255, 45, 45, 0.5);
}

.features-swiper-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: auto !important;
    position: static !important;
}

.features-swiper-pagination .swiper-pagination-bullet {
    width: 10px;
    height: 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.3);
    opacity: 1;
    transition: all 0.25s ease;
    cursor: pointer;
    margin: 0 !important;
}

.features-swiper-pagination .swiper-pagination-bullet-active {
    width: 28px;
    background: var(--gradient-red);
    box-shadow: 0 0 12px rgba(255, 45, 45, 0.6);
}

@media (max-width: 680px) {
    .features-swiper-container {
        padding: 5px 0 15px;
    }
    .featuresSwiper {
        padding: 12px 2px 20px;
    }
    .featuresSwiper .swiper-slide .feature-card {
        padding: 24px 16px 20px;
        min-height: 270px;
    }
    .features-swiper-controls {
        gap: 12px;
        margin-top: 14px;
    }
    .features-swiper-nav-btn {
        width: 38px;
        height: 38px;
        font-size: 0.95rem;
    }
    .featuresSwiper .swiper-slide .feature-card .feature-card-title {
        font-size: 1.05rem;
    }
    .featuresSwiper .swiper-slide .feature-card .feature-card-text {
        font-size: 0.83rem;
    }
}

/* ============================================================
   CATEGORIES SECTION
   ============================================================ */
.categories-section {
    padding: var(--section-padding);
    background: var(--color-deep-black);
}

.category-card {
    padding: 25px 20px;
    text-align: center;
    cursor: pointer;
    transition: var(--transition-bounce);
    height: 100%;
}

.category-card:hover {
    transform: translateY(-8px);
    border-color: rgba(255, 45, 45, 0.4);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.5), 0 0 25px rgba(139, 0, 0, 0.2);
}

.category-icon-wrapper {
    width: 55px;
    height: 55px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 15px;
    font-size: 1.4rem;
    color: var(--color-gold-light);
    transition: var(--transition-smooth);
}

.category-card:hover .category-icon-wrapper {
    background: rgba(255, 45, 45, 0.15);
    color: var(--color-glowing-red);
    box-shadow: 0 0 25px rgba(255, 45, 45, 0.3);
}

.category-name {
    font-family: var(--font-playfair);
    font-size: 1rem;
    font-weight: 600;
    color: var(--color-pure-white);
    margin-bottom: 5px;
}

.category-count {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.4);
}

/* ============================================================
   TIMELINE SECTION
   ============================================================ */
.timeline-section {
    padding: var(--section-padding);
    background: var(--color-midnight-navy);
    position: relative;
    overflow: hidden;
}

.timeline-bg-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(139, 0, 0, 0.05) 0%, transparent 70%);
    pointer-events: none;
}

.timeline-wrapper {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

.timeline-wrapper::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(180deg, transparent, rgba(255, 45, 45, 0.5), rgba(212, 168, 83, 0.5), rgba(255, 45, 45, 0.5), transparent);
    transform: translateX(-50%);
}

.timeline-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 50px;
    position: relative;
}

.timeline-item-right {
    flex-direction: row-reverse;
}

.timeline-marker {
    position: absolute;
    left: 50%;
    top: 0;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.timeline-dot {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--color-glowing-red);
    border: 3px solid var(--color-deep-black);
    box-shadow: 0 0 20px rgba(255, 45, 45, 0.6);
    z-index: 2;
}

.timeline-line {
    width: 2px;
    height: 50px;
    background: rgba(255, 255, 255, 0.1);
}

.timeline-content {
    width: 42%;
    padding: 25px;
    margin-left: 8%;
    margin-right: 8%;
}

.timeline-item-right .timeline-content {
    margin-left: 8%;
    margin-right: 8%;
}

.timeline-step {
    display: inline-block;
    background: var(--gradient-red);
    color: var(--color-pure-white);
    padding: 4px 14px;
    border-radius: 15px;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 1px;
    margin-bottom: 12px;
}

.timeline-title {
    font-family: var(--font-playfair);
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--color-pure-white);
    margin-bottom: 8px;
}

.timeline-text {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
    line-height: 1.7;
}

/* ============================================================
   WHY SECTION
   ============================================================ */
.why-section {
    padding: var(--section-padding);
    background: var(--color-deep-black);
    position: relative;
    overflow: hidden;
}

.why-bg-orb-1 {
    position: absolute;
    width: 400px;
    height: 400px;
    background: rgba(212, 168, 83, 0.05);
    border-radius: 50%;
    filter: blur(100px);
    top: -100px;
    right: -100px;
    pointer-events: none;
}

.why-card {
    padding: 30px 25px;
    height: 100%;
    position: relative;
    overflow: hidden;
}

.why-card-number {
    position: absolute;
    top: 15px;
    right: 20px;
    font-family: var(--font-cinzel);
    font-size: 3rem;
    font-weight: 900;
    color: rgba(255, 255, 255, 0.03);
    line-height: 1;
}

.why-card-icon {
    font-size: 2rem;
    color: var(--color-glowing-red);
    margin-bottom: 15px;
}

.why-card-title {
    font-family: var(--font-playfair);
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--color-pure-white);
    margin-bottom: 10px;
}

.why-card-text {
    color: rgba(255, 255, 255, 0.55);
    font-size: 0.9rem;
    line-height: 1.7;
}

/* ============================================================
   TESTIMONIALS SECTION
   ============================================================ */
.testimonials-section {
    padding: var(--section-padding);
    background: var(--color-deep-black);
    overflow: hidden;
}

.testimonialSwiper {
    width: 100%;
    padding: 20px 20px 65px;
    position: relative;
    overflow: hidden;
}

.testimonialSwiper .swiper-wrapper {
    align-items: stretch;
}

.testimonialSwiper .swiper-slide {
    height: auto;
    display: flex;
    flex-shrink: 0;
    box-sizing: border-box;
}

.testimonial-card {
    width: 100%;
    padding: 35px 28px;
    margin: 0;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    border-radius: 20px;
    background: rgba(15, 23, 42, 0.65);
    border: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.testimonial-card:hover {
    transform: translateY(-6px);
    border-color: rgba(240, 215, 140, 0.35);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5), 0 0 30px rgba(139, 0, 0, 0.2);
}

.testimonial-quote-icon {
    font-size: 3rem;
    color: rgba(255, 45, 45, 0.2);
    position: absolute;
    top: 15px;
    right: 25px;
    font-style: italic;
}

.testimonial-text {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1rem;
    line-height: 1.8;
    margin-bottom: 25px;
    font-style: italic;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 14px;
}

.testimonial-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: var(--gradient-red);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-cinzel);
    font-weight: 700;
    font-size: 1.2rem;
    color: var(--color-pure-white);
}

.testimonial-info h5 {
    font-family: var(--font-playfair);
    font-size: 1rem;
    font-weight: 700;
    color: var(--color-pure-white);
    margin-bottom: 2px;
}

.testimonial-role {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.5);
}

.testimonial-rating {
    margin-top: 5px;
}

.testimonial-rating i {
    color: #f0d78c;
    font-size: 0.75rem;
}

.testimonialSwiper .swiper-button-prev,
.testimonialSwiper .swiper-button-next {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(20, 20, 35, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.16);
    color: #fff !important;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
    transition: all 0.25s ease;
    top: 50%;
    transform: translateY(-50%);
}

.testimonialSwiper .swiper-button-prev::after,
.testimonialSwiper .swiper-button-next::after {
    font-size: 1rem;
    font-weight: 800;
}

.testimonialSwiper .swiper-button-prev:hover,
.testimonialSwiper .swiper-button-next:hover {
    background: var(--gradient-red);
    border-color: var(--color-glowing-red);
    box-shadow: 0 0 18px rgba(255, 45, 45, 0.5);
}

.testimonialSwiper .swiper-button-prev {
    left: 4px;
}

.testimonialSwiper .swiper-button-next {
    right: 4px;
}

.testimonialSwiper .swiper-pagination {
    bottom: 15px;
}

.testimonialSwiper .swiper-pagination-bullet {
    width: 10px;
    height: 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.3);
    opacity: 1;
    transition: all 0.25s ease;
    cursor: pointer;
}

.testimonialSwiper .swiper-pagination-bullet-active {
    width: 26px;
    background: var(--gradient-red);
    box-shadow: 0 0 12px rgba(255, 45, 45, 0.6);
}

@media (max-width: 767px) {
    .testimonialSwiper {
        padding: 15px 0 55px;
    }
    .testimonialSwiper .swiper-button-prev,
    .testimonialSwiper .swiper-button-next {
        display: none;
    }
}

/* ============================================================
   FAQ SECTION
   ============================================================ */
.faq-section {
    padding: var(--section-padding);
    background: var(--color-dark-blue);
}

.faq-accordion .accordion-item {
    margin-bottom: 15px;
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md) !important;
    overflow: hidden;
    background: transparent;
}

.faq-accordion .accordion-button {
    background: transparent;
    color: var(--color-pure-white);
    font-family: var(--font-playfair);
    font-size: 1.05rem;
    font-weight: 600;
    padding: 20px 25px;
    box-shadow: none;
    display: flex;
    align-items: center;
    gap: 12px;
}

.faq-accordion .accordion-button:not(.collapsed) {
    background: rgba(255, 45, 45, 0.05);
    color: var(--color-glowing-red);
    box-shadow: none;
}

.faq-accordion .accordion-button::after {
    filter: brightness(3);
}

.faq-question-icon {
    color: var(--color-glowing-red);
    font-size: 1.1rem;
}

.faq-accordion .accordion-body {
    color: rgba(255, 255, 255, 0.6);
    padding: 0 25px 20px 60px;
    line-height: 1.7;
}

/* ============================================================
   CTA SECTION
   ============================================================ */
.cta-section {
    position: relative;
    padding: 120px 0;
    overflow: hidden;
}

.cta-bg-image-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

.cta-bg-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cta-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(5, 5, 8, 0.85);
    z-index: 1;
}

.cta-glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    z-index: 2;
    pointer-events: none;
}

.cta-glow-1 {
    width: 400px;
    height: 400px;
    background: rgba(139, 0, 0, 0.2);
    top: -100px;
    right: -100px;
}

.cta-glow-2 {
    width: 300px;
    height: 300px;
    background: rgba(212, 168, 83, 0.1);
    bottom: -80px;
    left: -80px;
}

.cta-container {
    position: relative;
    z-index: 3;
}

.cta-title {
    font-family: var(--font-cinzel);
    font-size: 2.8rem;
    font-weight: 900;
    color: var(--color-pure-white);
    margin-bottom: 20px;
    letter-spacing: 1px;
}

.cta-text {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 35px;
    max-width: 650px;
    margin-left: auto;
    margin-right: auto;
}

.cta-buttons {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 30px;
}

.btn-cta-primary {
    background: var(--gradient-red);
    color: var(--color-pure-white);
    border: none;
    padding: 16px 35px;
    border-radius: 30px;
    font-family: var(--font-raleway);
    font-weight: 600;
    font-size: 1.05rem;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: var(--transition-bounce);
    box-shadow: 0 8px 30px rgba(139, 0, 0, 0.5);
    position: relative;
    overflow: hidden;
}

.btn-cta-primary:hover {
    transform: translateY(-4px);
    box-shadow: 0 14px 45px rgba(255, 45, 45, 0.6);
    color: var(--color-pure-white);
}

.btn-cta-secondary {
    background: transparent;
    border: 2px solid rgba(255, 255, 255, 0.3);
    color: var(--color-pure-white);
    padding: 16px 35px;
    border-radius: 30px;
    font-family: var(--font-raleway);
    font-weight: 600;
    font-size: 1.05rem;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: var(--transition-bounce);
}

.btn-cta-secondary:hover {
    border-color: var(--color-gold-light);
    color: var(--color-gold-light);
    transform: translateY(-4px);
}

.cta-trust-badges {
    display: flex;
    gap: 25px;
    justify-content: center;
    flex-wrap: wrap;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.85rem;
}

.cta-trust-badges span {
    display: flex;
    align-items: center;
    gap: 6px;
}

.cta-trust-badges i {
    color: var(--color-gold-light);
}

/* ============================================================
   FOOTER
   ============================================================ */
.footer-section {
    background: var(--color-deep-black);
    padding: 80px 0 30px;
    position: relative;
    overflow: hidden;
}

.footer-top-glow {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, rgba(255, 45, 45, 0.6), rgba(212, 168, 83, 0.4), rgba(255, 45, 45, 0.6), transparent);
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
    font-family: var(--font-cinzel);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-pure-white);
}

.footer-logo i {
    color: var(--color-glowing-red);
    font-size: 1.6rem;
}

.footer-brand-text {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.9rem;
    line-height: 1.7;
    margin-bottom: 20px;
}

.footer-social {
    display: flex;
    gap: 12px;
}

.footer-social-link {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.6);
    transition: var(--transition-bounce);
}

.footer-social-link:hover {
    background: rgba(255, 45, 45, 0.15);
    border-color: rgba(255, 45, 45, 0.4);
    color: var(--color-glowing-red);
    transform: translateY(-3px);
}

.footer-heading {
    font-family: var(--font-playfair);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--color-pure-white);
    margin-bottom: 20px;
}

.footer-list li {
    margin-bottom: 10px;
}

.footer-list li a {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.88rem;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition-smooth);
}

.footer-list li a:hover {
    color: var(--color-glowing-red);
    transform: translateX(5px);
}

.footer-list li a i {
    font-size: 0.7rem;
    color: var(--color-glowing-red);
}

.footer-contact-list li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 12px;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.88rem;
}

.footer-contact-list li i {
    color: var(--color-glowing-red);
    margin-top: 3px;
}

.footer-divider {
    height: 1px;
    background: rgba(255, 255, 255, 0.06);
    margin: 40px 0 25px;
}

.footer-copyright {
    color: rgba(255, 255, 255, 0.4);
    font-size: 0.85rem;
    margin-bottom: 0;
}

.footer-heart {
    color: var(--color-glowing-red);
    animation: heartBeat 1.5s ease-in-out infinite;
}

@keyframes heartBeat {
    0%,
    100% {
        transform: scale(1);
    }
    25% {
        transform: scale(1.2);
    }
    50% {
        transform: scale(1);
    }
    75% {
        transform: scale(1.15);
    }
}

.footer-bottom-links button {
    appearance: none;
    border: 0;
    padding: 0;
    background: transparent;
    color: rgba(255, 255, 255, 0.4);
    font-size: 0.85rem;
    transition: var(--transition-smooth);
    cursor: pointer;
}

.footer-bottom-links button:hover,
.footer-bottom-links button:focus-visible {
    color: var(--color-glowing-red);
}

.footer-dot {
    color: rgba(255, 255, 255, 0.2);
    margin: 0 8px;
}

.footer-magic-dust {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

.legal-modal {
    --bs-modal-bg: transparent;
}

.legal-modal .modal-content {
    overflow: hidden;
    color: rgba(255, 255, 255, 0.76);
    background:
        radial-gradient(circle at 15% 0%, rgba(255, 45, 45, 0.16), transparent 34%),
        linear-gradient(145deg, rgba(24, 17, 22, 0.99), rgba(8, 8, 12, 0.99));
    border: 1px solid rgba(212, 168, 83, 0.26);
    border-radius: 18px;
    box-shadow: 0 28px 90px rgba(0, 0, 0, 0.72);
}

.legal-modal .modal-header,
.legal-modal .modal-footer {
    border-color: rgba(255, 255, 255, 0.09);
    padding: 20px 24px;
}

.legal-modal .modal-body {
    padding: 24px;
}

.legal-modal-kicker,
.legal-updated {
    color: var(--color-gold-light);
    font-size: 0.76rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.legal-modal .modal-title {
    margin-top: 3px;
    color: var(--color-pure-white);
    font-family: var(--font-playfair);
    font-size: clamp(1.5rem, 3vw, 2rem);
}

.legal-modal .modal-body h3 {
    margin: 22px 0 8px;
    color: var(--color-pure-white);
    font-family: var(--font-playfair);
    font-size: 1.08rem;
}

.legal-modal .modal-body h3:first-of-type {
    margin-top: 14px;
}

.legal-modal .modal-body p {
    margin-bottom: 0;
    line-height: 1.75;
}

.legal-modal .legal-updated {
    margin-bottom: 4px;
}

.legal-modal-close {
    padding: 10px 22px;
    color: #fff;
    background: linear-gradient(135deg, var(--color-blood-red), var(--color-glowing-red));
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 999px;
    font-weight: 700;
}

.legal-modal-close:hover,
.legal-modal-close:focus-visible {
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 10px 24px rgba(255, 45, 45, 0.24);
}

.footer-account-identity {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px;
    background: rgba(255, 255, 255, 0.045);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
}

.footer-account-avatar {
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    color: #fff;
    background: var(--gradient-red);
    border-radius: 50%;
    font-family: var(--font-cinzel);
    font-weight: 700;
}

.footer-account-identity small,
.footer-account-identity strong {
    display: block;
}

.footer-account-identity small {
    color: rgba(255, 255, 255, 0.42);
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.footer-account-identity strong {
    max-width: 160px;
    overflow: hidden;
    color: #fff;
    font-size: 0.86rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.footer-guest-note {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    color: rgba(255, 255, 255, 0.42);
    font-size: 0.78rem;
    line-height: 1.5;
}

.footer-guest-note > i {
    margin-top: 3px;
    color: var(--color-gold-light);
}

/* ============================================================
   MEMBER SUPPORT CENTER
   ============================================================ */
.support-page {
    min-height: 100vh;
    color: #fff;
    background: var(--color-deep-black);
}

.support-hero {
    position: relative;
    overflow: hidden;
    padding: 155px 0 76px;
    background:
        linear-gradient(180deg, rgba(9, 9, 14, 0.25), var(--color-deep-black)),
        radial-gradient(circle at 50% 10%, rgba(139, 0, 0, 0.18), transparent 55%);
}

.support-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    pointer-events: none;
}

.support-orb-one {
    top: 50px;
    left: -100px;
    width: 280px;
    height: 280px;
    background: rgba(255, 45, 45, 0.16);
}

.support-orb-two {
    right: -80px;
    bottom: -130px;
    width: 320px;
    height: 320px;
    background: rgba(212, 168, 83, 0.11);
}

.support-hero-copy {
    position: relative;
    z-index: 1;
    max-width: 780px;
    margin: 0 auto;
    text-align: center;
}

.support-hero-copy h1 {
    margin: 12px 0 16px;
    font-family: var(--font-playfair);
    font-size: clamp(2.25rem, 6vw, 4.6rem);
    font-weight: 700;
}

.support-hero-copy p {
    max-width: 660px;
    margin: 0 auto;
    color: rgba(255, 255, 255, 0.64);
    font-size: 1.04rem;
    line-height: 1.75;
}

.support-content {
    padding: 0 0 90px;
}

.support-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.65fr) minmax(260px, 0.75fr);
    gap: 24px;
    align-items: start;
}

.support-form-card,
.support-info-card,
.support-request-card,
.support-empty {
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.support-form-card {
    padding: clamp(24px, 5vw, 42px);
}

.support-card-heading {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 24px;
}

.support-card-heading span:not(.support-card-icon) {
    color: var(--color-gold-light);
    font-size: 0.74rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.support-card-heading h2,
.support-info-card h2,
.support-history-heading h2 {
    margin: 2px 0 0;
    color: #fff;
    font-family: var(--font-playfair);
}

.support-card-icon {
    width: 48px;
    height: 48px;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    color: #fff;
    background: var(--gradient-red);
    border-radius: 14px;
    box-shadow: 0 10px 30px rgba(255, 45, 45, 0.24);
}

.support-account-email {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 26px;
    padding: 13px 15px;
    background: rgba(212, 168, 83, 0.08);
    border: 1px solid rgba(212, 168, 83, 0.2);
    border-radius: 12px;
}

.support-account-email > i {
    color: var(--color-gold-light);
    font-size: 1.2rem;
}

.support-account-email small,
.support-account-email strong {
    display: block;
}

.support-account-email small {
    color: rgba(255, 255, 255, 0.48);
}

.support-account-email strong {
    color: #fff;
    word-break: break-word;
}

.support-form {
    display: grid;
    gap: 20px;
}

.support-field label {
    display: block;
    margin-bottom: 8px;
    color: rgba(255, 255, 255, 0.88);
    font-size: 0.86rem;
    font-weight: 700;
}

.support-field > small {
    display: block;
    margin-top: 7px;
    color: rgba(255, 255, 255, 0.42);
    font-size: 0.75rem;
}

.support-form-control {
    width: 100%;
    padding: 13px 15px;
    color: #fff;
    background: rgba(255, 255, 255, 0.055);
    border: 1px solid rgba(255, 255, 255, 0.13);
    border-radius: 10px;
    outline: none;
    transition: var(--transition-smooth);
}

.support-form-control:focus {
    background: rgba(255, 255, 255, 0.075);
    border-color: rgba(255, 45, 45, 0.58);
    box-shadow: 0 0 0 4px rgba(255, 45, 45, 0.08);
}

.support-form-control option {
    color: #111;
}

.support-form textarea {
    min-height: 160px;
    resize: vertical;
}

.support-form .errorlist {
    margin: 7px 0 0;
    padding: 0;
    color: #ff8b8b;
    font-size: 0.78rem;
    list-style: none;
}

.support-submit {
    width: fit-content;
    padding: 12px 24px;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: #fff;
    background: var(--gradient-red);
    border: 0;
    border-radius: 999px;
    font-weight: 700;
}

.support-submit:hover {
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgba(255, 45, 45, 0.25);
}

.support-info-card {
    position: sticky;
    top: 110px;
    padding: 28px;
}

.support-info-card h2 {
    margin: 16px 0 20px;
}

.support-info-card ul {
    display: grid;
    gap: 16px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.support-info-card li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.86rem;
    line-height: 1.55;
}

.support-info-card li i {
    margin-top: 3px;
    color: var(--color-gold-light);
}

.support-history {
    padding-top: 76px;
}

.support-history-heading,
.support-request-top,
.support-request-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}

.support-history-count {
    padding: 7px 11px;
    color: rgba(255, 255, 255, 0.65);
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 999px;
    font-size: 0.78rem;
}

.support-request-list {
    display: grid;
    gap: 18px;
    margin-top: 24px;
}

.support-request-card {
    padding: 26px;
}

.support-request-id {
    color: var(--color-gold-light);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.support-request-card h3 {
    margin: 4px 0 0;
    color: #fff;
    font-family: var(--font-playfair);
    font-size: 1.3rem;
}

.support-status {
    padding: 6px 10px;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
}

.support-status-new {
    color: #ffabab;
    background: rgba(255, 45, 45, 0.13);
}

.support-status-read {
    color: #f6d68f;
    background: rgba(212, 168, 83, 0.12);
}

.support-status-replied {
    color: #89e6ad;
    background: rgba(34, 197, 94, 0.12);
}

.support-status-resolved {
    color: #93c5fd;
    background: rgba(59, 130, 246, 0.14);
}

.support-status-closed {
    color: #c2c2cb;
    background: rgba(255, 255, 255, 0.08);
}

.support-request-meta {
    justify-content: flex-start;
    flex-wrap: wrap;
    margin: 14px 0;
    color: rgba(255, 255, 255, 0.46);
    font-size: 0.76rem;
}

.support-request-meta span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.support-request-book {
    width: fit-content;
    margin: 0 0 12px;
    padding: 7px 10px;
    color: #fff;
    background: rgba(255, 255, 255, 0.055);
    border-radius: 8px;
    font-weight: 600;
}

.support-request-book i {
    margin-right: 7px;
    color: var(--color-glowing-red);
}

.support-request-message {
    margin: 0;
    color: rgba(255, 255, 255, 0.66);
    line-height: 1.7;
}

.support-admin-reply {
    margin-top: 22px;
    padding: 20px;
    background: rgba(212, 168, 83, 0.07);
    border: 1px solid rgba(212, 168, 83, 0.18);
    border-left: 3px solid var(--color-gold-light);
    border-radius: 12px;
}

.support-admin-reply > span {
    color: var(--color-gold-light);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.support-admin-reply h4 {
    margin: 7px 0;
    color: #fff;
    font-size: 1rem;
}

.support-admin-reply p {
    margin-bottom: 8px;
    color: rgba(255, 255, 255, 0.68);
    line-height: 1.65;
}

.support-admin-reply small {
    color: rgba(255, 255, 255, 0.4);
}

.support-resolution-note {
    margin-top: 16px;
    padding: 11px 13px;
    display: flex;
    align-items: center;
    gap: 9px;
    color: #bfdbfe;
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(96, 165, 250, 0.2);
    border-radius: 10px;
    font-size: 0.82rem;
    font-weight: 600;
}

.support-resolution-note i {
    color: #60a5fa;
}

.support-empty {
    padding: 46px 24px;
    text-align: center;
}

.support-empty > i {
    color: var(--color-glowing-red);
    font-size: 2.2rem;
}

.support-empty h3 {
    margin: 12px 0 7px;
    color: #fff;
}

.support-empty p {
    margin: 0;
    color: rgba(255, 255, 255, 0.52);
}

@media (max-width: 991px) {
    .support-layout {
        grid-template-columns: 1fr;
    }

    .support-info-card {
        position: static;
    }
}

@media (max-width: 575px) {
    .support-hero {
        padding: 125px 0 55px;
    }

    .support-request-top,
    .support-history-heading {
        align-items: flex-start;
        flex-direction: column;
    }

    .support-request-card {
        padding: 20px;
    }
}

/* ============================================================
   BACK TO TOP
   ============================================================ */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--gradient-red);
    border: none;
    color: var(--color-pure-white);
    font-size: 1.3rem;
    cursor: pointer;
    z-index: var(--z-back-to-top);
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: var(--transition-smooth);
    box-shadow: 0 6px 25px rgba(139, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 35px rgba(255, 45, 45, 0.6);
}

/* ============================================================
   MAGIC SPARKLES
   ============================================================ */
.magic-sparkles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 4;
}

.sparkle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--color-gold-light);
    border-radius: 50%;
    animation: sparkleFloat 4s ease-in-out infinite;
}

@keyframes sparkleFloat {
    0% {
        transform: translateY(0) scale(1);
        opacity: 0;
    }
    20% {
        opacity: 1;
    }
    80% {
        opacity: 1;
    }
    100% {
        transform: translateY(-100px) scale(0);
        opacity: 0;
    }
}

/* ============================================================
   BOOK CARD HIDDEN STATE (for filtering)
   ============================================================ */
.book-card-wrapper.hidden-card,
.book-card-wrapper.filter-hidden,
.book-card-wrapper.search-hidden,
.book-card-wrapper.load-more-hidden {
    display: none;
}

/* ============================================================
   BLOG PAGES
   ============================================================ */
.blog-hero-section,
.blog-detail-hero {
    position: relative;
    padding: 150px 0 60px;
    background: var(--gradient-dark);
    overflow: hidden;
}

.blogs-list-section,
.blog-detail-content-section {
    position: relative;
    padding: 40px 0 100px;
    background: var(--color-deep-black);
}

.blogs-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 28px;
}

.blog-search-form {
    max-width: 860px;
    margin: 36px auto 0;
    padding: 10px;
}

.blog-search-inner {
    display: flex;
    align-items: center;
    gap: 12px;
}

.blog-search-inner > i {
    color: var(--color-gold-light);
    font-size: 1.2rem;
    margin-left: 10px;
    flex: 0 0 auto;
}

.blog-search-inner input {
    flex: 1 1 auto;
    min-width: 0;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 999px;
    color: var(--color-pure-white);
    font-family: var(--font-raleway);
    padding: 13px 18px;
    outline: none;
    transition: var(--transition-smooth);
}

.blog-search-inner input:focus {
    border-color: rgba(212, 168, 83, 0.5);
    box-shadow: 0 0 0 4px rgba(212, 168, 83, 0.08);
}

.blog-search-inner input::placeholder {
    color: rgba(255, 255, 255, 0.45);
}

.btn-blog-search {
    flex: 0 0 auto;
    background: var(--gradient-red);
    color: var(--color-pure-white);
    border: none;
    border-radius: 999px;
    padding: 12px 22px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-raleway);
    font-weight: 700;
}

.btn-blog-search:hover {
    color: var(--color-pure-white);
    transform: translateY(-2px);
    box-shadow: 0 10px 28px rgba(255, 45, 45, 0.35);
}

.blog-search-clear {
    display: inline-flex;
    margin: 10px 0 2px 18px;
    color: var(--color-gold-light);
    font-family: var(--font-raleway);
    font-size: 0.86rem;
    font-weight: 700;
}

.blog-search-clear:hover {
    color: var(--color-pure-white);
}

.blog-card {
    overflow: hidden;
    display: flex;
    flex-direction: column;
    min-height: 100%;
    transition: var(--transition-bounce);
}

.blog-card:hover {
    transform: translateY(-8px);
    border-color: rgba(255, 45, 45, 0.28);
    box-shadow: 0 22px 55px rgba(0, 0, 0, 0.45), 0 0 34px rgba(255, 45, 45, 0.12);
}

.blog-card-image-link {
    position: relative;
    display: block;
    height: 240px;
    overflow: hidden;
}

.blog-card-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.blog-card:hover .blog-card-image {
    transform: scale(1.06);
}

.blog-card-category,
.blog-detail-category {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    max-width: 100%;
    background: rgba(255, 45, 45, 0.88);
    color: var(--color-pure-white);
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 999px;
    padding: 7px 14px;
    font-family: var(--font-raleway);
    font-size: 0.74rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.blog-card-category {
    position: absolute;
    left: 18px;
    bottom: 18px;
}

.blog-card-body {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    padding: 24px;
}

.blog-card-meta,
.blog-detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 18px;
    color: rgba(255, 255, 255, 0.62);
    font-family: var(--font-raleway);
    font-size: 0.82rem;
}

.blog-card-meta span,
.blog-detail-meta span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.blog-card-meta i,
.blog-detail-meta i {
    color: var(--color-gold-light);
}

.blog-card-title {
    margin: 16px 0 12px;
    font-family: var(--font-playfair);
    font-size: 1.45rem;
    font-weight: 800;
    line-height: 1.25;
    color: var(--color-pure-white);
}

.blog-card-title a:hover {
    color: var(--color-gold-light);
}

.blog-card-excerpt {
    color: rgba(255, 255, 255, 0.68);
    font-family: var(--font-raleway);
    font-size: 0.95rem;
    line-height: 1.8;
    margin-bottom: 22px;
}

.btn-blog-read {
    align-self: flex-start;
    margin-top: auto;
    background: var(--gradient-red);
    color: var(--color-pure-white);
    border: none;
    border-radius: 999px;
    padding: 10px 20px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-raleway);
    font-weight: 700;
    font-size: 0.86rem;
    transition: var(--transition-bounce);
}

.btn-blog-read:hover {
    color: var(--color-pure-white);
    transform: translateY(-3px);
    box-shadow: 0 10px 28px rgba(255, 45, 45, 0.4);
}

.blog-empty-state {
    grid-column: 1 / -1;
    padding: 48px 24px;
    text-align: center;
}

.blog-empty-state i {
    display: block;
    color: var(--color-gold-light);
    font-size: 2.6rem;
    margin-bottom: 16px;
}

.blog-empty-state h2 {
    color: var(--color-pure-white);
    font-family: var(--font-playfair);
    margin-bottom: 10px;
}

.blog-empty-state p {
    color: rgba(255, 255, 255, 0.64);
    margin: 0;
}

.blog-detail-header {
    max-width: 900px;
    margin: 0 auto;
    text-align: center;
}

.blog-back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--color-gold-light);
    font-family: var(--font-raleway);
    font-weight: 700;
    margin-bottom: 24px;
}

.blog-back-link:hover {
    color: var(--color-pure-white);
}

.blog-detail-title {
    font-family: var(--font-cinzel);
    font-size: clamp(2rem, 5vw, 4.2rem);
    font-weight: 900;
    color: var(--color-pure-white);
    line-height: 1.15;
    margin: 22px 0;
}

.blog-detail-meta {
    justify-content: center;
}

.blog-detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 34px;
    align-items: start;
}

.blog-article-main {
    min-width: 0;
}

.blog-detail-image {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    border-radius: var(--radius-md);
    border: 1px solid var(--glass-border);
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.45);
    margin-bottom: 30px;
}

.blog-detail-excerpt {
    color: var(--color-cream);
    font-family: var(--font-cormorant);
    font-size: 1.55rem;
    line-height: 1.65;
    margin: 0 0 28px;
}

.blog-content {
    padding: 42px;
}

.blog-paragraph-block + .blog-paragraph-block {
    margin-top: 36px;
}

.blog-paragraph-block h2 {
    color: var(--color-gold-light);
    font-family: var(--font-playfair);
    font-size: 1.75rem;
    font-weight: 800;
    line-height: 1.25;
    margin-bottom: 14px;
}

.blog-paragraph-block p,
.blog-content > p {
    color: rgba(255, 255, 255, 0.76);
    font-family: var(--font-eb-garamond);
    font-size: 1.18rem;
    line-height: 1.95;
    text-align: justify;
    margin: 0;
}

.blog-tags {
    margin-top: 28px;
    padding: 24px;
}

.blog-tags-title {
    display: block;
    color: var(--color-pure-white);
    font-family: var(--font-playfair);
    font-size: 1.15rem;
    font-weight: 800;
    margin-bottom: 14px;
}

.blog-tags-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.blog-tags-list span {
    color: var(--color-gold-light);
    background: rgba(212, 168, 83, 0.08);
    border: 1px solid rgba(212, 168, 83, 0.22);
    border-radius: 999px;
    padding: 8px 14px;
    font-family: var(--font-raleway);
    font-size: 0.83rem;
    font-weight: 700;
}

.blog-detail-sidebar {
    position: sticky;
    top: 110px;
    display: grid;
    gap: 22px;
}

.blog-sidebar-card {
    padding: 24px;
}

.blog-sidebar-card h2 {
    color: var(--color-pure-white);
    font-family: var(--font-playfair);
    font-size: 1.2rem;
    font-weight: 800;
    margin-bottom: 18px;
}

.blog-sidebar-card li {
    display: flex;
    align-items: center;
    gap: 10px;
    color: rgba(255, 255, 255, 0.72);
    margin-bottom: 12px;
    font-family: var(--font-raleway);
    font-size: 0.9rem;
}

.blog-sidebar-card li:last-child {
    margin-bottom: 0;
}

.blog-sidebar-card li i {
    color: var(--color-gold-light);
}

.related-blog-link {
    display: block;
    padding: 14px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.related-blog-link span {
    display: block;
    color: var(--color-pure-white);
    font-family: var(--font-raleway);
    font-weight: 700;
    line-height: 1.45;
}

.related-blog-link small {
    display: block;
    color: rgba(255, 255, 255, 0.5);
    margin-top: 5px;
}

.related-blog-link:hover span {
    color: var(--color-gold-light);
}

/* ============================================================
   PROFILE PAGE
   ============================================================ */
.profile-hero-section {
    position: relative;
    padding: 145px 0 42px;
    background: var(--gradient-dark);
    overflow: hidden;
}

.profile-content-section {
    padding: 42px 0 100px;
    background: var(--color-deep-black);
}

.profile-hero-card {
    display: flex;
    align-items: center;
    gap: 28px;
    padding: 34px;
    max-width: 980px;
    margin: 0 auto;
}

.profile-avatar-large,
.profile-picture-preview {
    border-radius: 50%;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle at 30% 20%, rgba(212, 168, 83, 0.28), rgba(255, 45, 45, 0.22));
    border: 2px solid rgba(212, 168, 83, 0.42);
    color: var(--color-pure-white);
    font-family: var(--font-cinzel);
    font-weight: 800;
    box-shadow: 0 16px 45px rgba(0, 0, 0, 0.35);
}

.profile-avatar-large {
    width: 128px;
    height: 128px;
    flex: 0 0 128px;
    font-size: 3.1rem;
}

.profile-picture-preview {
    width: 150px;
    height: 150px;
    font-size: 3.4rem;
    margin: 4px 0 22px;
}

.profile-avatar-large img,
.profile-picture-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-hero-copy h1 {
    color: var(--color-pure-white);
    font-family: var(--font-cinzel);
    font-size: clamp(2rem, 4vw, 3.4rem);
    font-weight: 900;
    line-height: 1.1;
    margin: 8px 0 10px;
}

.profile-hero-copy p {
    color: rgba(255, 255, 255, 0.62);
    font-family: var(--font-raleway);
    margin: 0;
    overflow-wrap: anywhere;
}

.profile-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px;
    align-items: start;
    max-width: 1050px;
    margin: 0 auto;
}

.profile-panel {
    padding: 28px;
    width: 100%;
}

.profile-password-panel {
    grid-column: 1 / -1;
    max-width: 760px;
    justify-self: center;
}

.profile-panel-header {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 24px;
}

.profile-panel-header > i {
    flex: 0 0 46px;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: rgba(255, 45, 45, 0.14);
    border: 1px solid rgba(255, 45, 45, 0.24);
    color: var(--color-gold-light);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}

.profile-panel-header h2 {
    color: var(--color-pure-white);
    font-family: var(--font-playfair);
    font-size: 1.45rem;
    font-weight: 800;
    margin: 0 0 5px;
}

.profile-panel-header p {
    color: rgba(255, 255, 255, 0.58);
    font-family: var(--font-raleway);
    font-size: 0.92rem;
    margin: 0;
    line-height: 1.6;
}

.profile-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.profile-password-form {
    max-width: 720px;
    width: 100%;
    margin: 0 auto;
}

.profile-form label {
    color: var(--color-gold-light);
    font-family: var(--font-raleway);
    font-size: 0.86rem;
    font-weight: 700;
    margin-top: 8px;
}

.profile-form input[type="text"],
.profile-form input[type="password"],
.profile-form input[type="file"] {
    width: 100%;
    min-width: 0;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: var(--radius-sm);
    color: var(--color-pure-white);
    font-family: var(--font-raleway);
    padding: 13px 15px;
    outline: none;
    transition: var(--transition-smooth);
}

.profile-form input[type="file"] {
    cursor: pointer;
}

.profile-form input[type="file"]::file-selector-button {
    background: rgba(212, 168, 83, 0.16);
    border: 1px solid rgba(212, 168, 83, 0.28);
    color: var(--color-gold-light);
    border-radius: 999px;
    padding: 8px 13px;
    margin-right: 12px;
    font-family: var(--font-raleway);
    font-weight: 700;
    cursor: pointer;
}

.profile-form input:focus {
    border-color: rgba(212, 168, 83, 0.5);
    box-shadow: 0 0 0 4px rgba(212, 168, 83, 0.08);
}

.profile-field-error {
    color: #ffb4b4;
    background: rgba(255, 45, 45, 0.1);
    border: 1px solid rgba(255, 45, 45, 0.18);
    border-radius: var(--radius-sm);
    padding: 9px 11px;
    font-family: var(--font-raleway);
    font-size: 0.83rem;
}

.btn-profile-action {
    align-self: flex-start;
    margin-top: 12px;
    background: var(--gradient-red);
    color: var(--color-pure-white);
    border: none;
    border-radius: 999px;
    padding: 12px 22px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-raleway);
    font-weight: 700;
}

.btn-profile-action:hover {
    color: var(--color-pure-white);
    transform: translateY(-2px);
    box-shadow: 0 10px 28px rgba(255, 45, 45, 0.35);
}

/* ============================================================
   PERSONAL LIBRARY
   ============================================================ */
.personal-library-page {
    background: var(--color-deep-black);
}

.library-hero-section {
    position: relative;
    padding: 128px 0 26px;
    background: var(--gradient-dark);
    overflow: hidden;
}

.library-hero-card {
    position: relative;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 24px;
    padding: 28px;
}

.library-user-avatar {
    width: 96px;
    height: 96px;
    border-radius: 50%;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle at 30% 20%, rgba(212, 168, 83, 0.28), rgba(255, 45, 45, 0.2));
    border: 2px solid rgba(212, 168, 83, 0.4);
    color: var(--color-pure-white);
    font-family: var(--font-cinzel);
    font-size: 2.4rem;
    font-weight: 900;
}

.library-user-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.library-hero-copy h1 {
    color: var(--color-pure-white);
    font-family: var(--font-cinzel);
    font-size: clamp(2rem, 4.5vw, 3.7rem);
    font-weight: 900;
    line-height: 1.05;
    margin: 6px 0 8px;
}

.library-hero-copy p {
    color: rgba(255, 255, 255, 0.66);
    font-family: var(--font-raleway);
    margin: 0;
}

.btn-library-customize,
.btn-library-search,
.btn-library-mini,
.btn-library-card-action.primary {
    background: var(--gradient-red);
    color: var(--color-pure-white);
    border: none;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-family: var(--font-raleway);
    font-weight: 700;
    transition: var(--transition-bounce);
}

.btn-library-customize {
    padding: 12px 18px;
}

.btn-library-search {
    padding: 12px 22px;
}

.btn-library-mini {
    padding: 9px 14px;
    margin-top: 12px;
    font-size: 0.82rem;
}

.btn-library-customize:hover,
.btn-library-search:hover,
.btn-library-mini:hover,
.btn-library-card-action.primary:hover {
    color: var(--color-pure-white);
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgba(255, 45, 45, 0.35);
}

.library-stats-grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 16px;
    margin-top: 18px;
}

.library-stat-card {
    padding: 18px;
    display: grid;
    gap: 6px;
    min-height: 126px;
}

.library-stat-card i {
    color: var(--color-gold-light);
    font-size: 1.55rem;
}

.library-stat-card span {
    color: var(--color-pure-white);
    font-family: var(--font-cinzel);
    font-size: 2rem;
    font-weight: 900;
    line-height: 1;
}

.library-stat-card small {
    color: rgba(255, 255, 255, 0.62);
    font-family: var(--font-raleway);
}

.library-badges-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
}

.library-earned-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    color: var(--color-gold-light);
    font-family: var(--font-raleway);
    font-size: 0.84rem;
    font-weight: 800;
}

.library-earned-badge i {
    color: var(--color-glowing-red);
}

.library-controls-section {
    padding: 20px 0 16px;
}

.library-search-card {
    padding: 12px;
}

.library-search-row {
    display: grid;
    grid-template-columns: minmax(240px, 1fr) 180px 190px auto;
    gap: 10px;
    align-items: center;
}

.library-search-input {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 999px;
    padding: 0 14px;
}

.library-search-input i {
    color: var(--color-gold-light);
}

.library-search-input input,
.library-search-row select,
.library-customize-panel select {
    width: 100%;
    min-width: 0;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 999px;
    color: var(--color-pure-white);
    font-family: var(--font-raleway);
    padding: 12px 14px;
    outline: none;
}

.library-search-input input {
    background: transparent;
    border: 0;
    padding-left: 0;
}

.library-search-row select option,
.library-customize-panel select option {
    background: #111118;
    color: #fff;
}

.library-clear-link {
    display: inline-block;
    color: var(--color-gold-light);
    font-family: var(--font-raleway);
    font-weight: 700;
    font-size: 0.86rem;
    margin: 10px 0 0 14px;
}

.library-view-toolbar {
    display: flex;
    justify-content: flex-end;
    margin-top: 12px;
}

.library-view-buttons {
    display: inline-flex;
    gap: 8px;
    padding: 6px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.library-view-buttons button {
    width: 40px;
    height: 40px;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: rgba(255, 255, 255, 0.6);
}

.library-view-buttons button.active {
    background: var(--gradient-red);
    color: var(--color-pure-white);
}

.library-continue-section {
    padding: 8px 0 22px;
}

.library-section-heading {
    margin-bottom: 14px;
}

.library-section-heading h2 {
    color: var(--color-pure-white);
    font-family: var(--font-playfair);
    font-size: 2rem;
    font-weight: 800;
}

.library-continue-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.library-continue-card {
    display: grid;
    grid-template-columns: 92px minmax(0, 1fr);
    gap: 14px;
    padding: 14px;
}

.library-continue-card img {
    width: 92px;
    height: 132px;
    object-fit: cover;
    border-radius: var(--radius-sm);
}

.library-continue-card h3 {
    color: var(--color-pure-white);
    font-family: var(--font-playfair);
    font-size: 1.08rem;
    font-weight: 800;
    margin-bottom: 5px;
}

.library-continue-card p,
.library-continue-card small {
    color: rgba(255, 255, 255, 0.62);
    margin: 0 0 8px;
}

.library-progress-bar {
    height: 8px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
    overflow: hidden;
    margin-bottom: 8px;
}

.library-progress-bar span {
    display: block;
    height: 100%;
    background: var(--gradient-gold);
}

.library-books-section {
    padding: 8px 0 90px;
}

.library-books-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 22px;
    align-items: stretch;
}

.library-book-card {
    overflow: hidden;
    display: grid;
    grid-template-columns: 150px minmax(0, 1fr);
    min-height: 288px;
    transition: var(--transition-bounce);
}

.library-book-card:hover {
    transform: translateY(-6px);
    border-color: rgba(212, 168, 83, 0.28);
    box-shadow: 0 22px 55px rgba(0, 0, 0, 0.48);
}

.library-book-cover {
    position: relative;
    min-height: 100%;
}

.library-book-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.library-book-access {
    position: absolute;
    top: 12px;
    left: 12px;
    border-radius: 999px;
    padding: 6px 10px;
    color: #fff;
    font-family: var(--font-raleway);
    font-size: 0.72rem;
    font-weight: 800;
}

.library-book-access.free {
    background: rgba(24, 150, 88, 0.88);
}

.library-book-access.purchased {
    background: rgba(212, 168, 83, 0.88);
    color: #17120a;
}

.library-book-body {
    padding: 18px;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.library-book-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-bottom: 8px;
}

.library-book-badges span {
    color: var(--color-gold-light);
    border: 1px solid rgba(212, 168, 83, 0.25);
    background: rgba(212, 168, 83, 0.08);
    border-radius: 999px;
    padding: 4px 9px;
    font-family: var(--font-raleway);
    font-size: 0.7rem;
    font-weight: 800;
}

.library-book-body h2 {
    color: var(--color-pure-white);
    font-family: var(--font-playfair);
    font-size: 1.25rem;
    font-weight: 800;
    line-height: 1.22;
    margin-bottom: 6px;
}

.library-book-author,
.library-book-category {
    color: rgba(255, 255, 255, 0.62);
    font-family: var(--font-raleway);
    font-size: 0.85rem;
    line-height: 1.45;
    margin: 0 0 5px;
}

.library-book-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    color: rgba(255, 255, 255, 0.58);
    font-size: 0.8rem;
    margin: 6px 0 14px;
}

.library-book-meta i {
    color: var(--color-gold-light);
    margin-right: 5px;
}

.library-card-progress {
    margin: 4px 0 14px;
}

.library-card-progress > div:first-child {
    display: flex;
    justify-content: space-between;
    color: rgba(255, 255, 255, 0.62);
    font-family: var(--font-raleway);
    font-size: 0.78rem;
    font-weight: 800;
    margin-bottom: 6px;
}

.library-card-progress strong {
    color: var(--color-gold-light);
}

.library-book-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: auto;
}

.btn-library-card-action {
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.06);
    color: rgba(255, 255, 255, 0.84);
    border-radius: 999px;
    padding: 8px 12px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: var(--font-raleway);
    font-size: 0.78rem;
    font-weight: 800;
}

.btn-library-card-action:hover {
    color: var(--color-gold-light);
    border-color: rgba(212, 168, 83, 0.36);
}

.btn-library-card-action.danger:hover {
    color: #ffb4b4;
    border-color: rgba(255, 45, 45, 0.42);
}

.library-wishlist-form {
    display: inline-flex;
}

.library-remove-form {
    display: inline-flex;
}

.library-empty-state {
    max-width: 760px;
    margin: 12px auto 0;
    padding: 54px 24px;
    text-align: center;
}

.library-empty-state i {
    color: var(--color-gold-light);
    font-size: 3rem;
    margin-bottom: 16px;
}

.library-empty-state h2 {
    color: var(--color-pure-white);
    font-family: var(--font-playfair);
    font-size: 2rem;
    font-weight: 800;
}

.library-empty-state p {
    color: rgba(255, 255, 255, 0.64);
    margin-bottom: 22px;
}

.library-empty-actions {
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

.library-customize-panel {
    position: fixed;
    top: 92px;
    right: 22px;
    z-index: 1300;
    width: min(92vw, 360px);
    max-height: calc(100vh - 112px);
    padding: 22px;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    transform: translateX(calc(100% + 40px));
    opacity: 0;
    pointer-events: none;
    transition: var(--transition-smooth);
    scrollbar-width: thin;
    scrollbar-color: rgba(240, 215, 140, 0.5) rgba(255, 255, 255, 0.08);
}

.library-customize-panel::-webkit-scrollbar {
    width: 8px;
}

.library-customize-panel::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.08);
    border-radius: 999px;
}

.library-customize-panel::-webkit-scrollbar-thumb {
    background: rgba(240, 215, 140, 0.5);
    border-radius: 999px;
}

.library-customize-panel.open {
    transform: translateX(0);
    opacity: 1;
    pointer-events: auto;
}

.library-customize-header {
    position: sticky;
    top: -22px;
    z-index: 2;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding: 0 0 12px;
    background: linear-gradient(180deg, rgba(15, 15, 30, 0.96), rgba(15, 15, 30, 0.78));
    backdrop-filter: blur(12px);
}

.library-customize-header h2 {
    color: var(--color-pure-white);
    font-family: var(--font-playfair);
    font-size: 1.25rem;
    font-weight: 800;
    margin: 0;
}

.library-customize-header button {
    width: 34px;
    height: 34px;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
}

.library-customize-panel label {
    display: block;
    color: var(--color-gold-light);
    font-family: var(--font-raleway);
    font-size: 0.84rem;
    font-weight: 800;
    margin: 12px 0 7px;
}

.library-toggle-list label {
    color: rgba(255, 255, 255, 0.72);
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
}

.library-style-preview-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 9px;
    margin: 10px 0 14px;
}

.library-style-preview {
    display: grid;
    grid-template-columns: 86px minmax(0, 1fr);
    gap: 10px;
    align-items: center;
    width: 100%;
    padding: 9px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.055);
    color: rgba(255, 255, 255, 0.82);
    text-align: left;
    transition: var(--transition-smooth);
}

.library-style-preview:hover,
.library-style-preview.active {
    border-color: rgba(240, 215, 140, 0.42);
    background: rgba(240, 215, 140, 0.08);
    color: #fff;
}

.library-style-preview strong,
.library-style-preview small {
    display: block;
}

.library-style-preview strong {
    font-family: var(--font-raleway);
    font-size: 0.84rem;
    font-weight: 800;
}

.library-style-preview small {
    color: rgba(255, 255, 255, 0.58);
    font-size: 0.72rem;
}

.library-style-preview-art {
    position: relative;
    height: 52px;
    display: flex;
    align-items: end;
    justify-content: center;
    gap: 5px;
    overflow: hidden;
    border-radius: 7px;
    padding: 8px 8px 10px;
}

.library-style-preview-art::after {
    content: "";
    position: absolute;
    left: 6px;
    right: 6px;
    bottom: 6px;
    height: 6px;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.32);
}

.library-style-preview-art i {
    position: relative;
    z-index: 1;
    width: 12px;
    height: 30px;
    border-radius: 2px 4px 4px 2px;
    background: linear-gradient(180deg, #9b2438, #42111c);
    box-shadow: 0 7px 10px rgba(0, 0, 0, 0.28);
}

.library-style-preview-art i:nth-child(2) {
    height: 36px;
    background: linear-gradient(180deg, #d0a947, #5d3d12);
}

.library-style-preview-art i:nth-child(3) {
    height: 27px;
    background: linear-gradient(180deg, #2f7a82, #103238);
}

.library-style-preview-art.grid {
    align-items: center;
    background: rgba(255, 255, 255, 0.07);
}

.library-style-preview-art.grid::after {
    display: none;
}

.library-style-preview-art.grid i {
    width: 18px;
    height: 28px;
    border-radius: 4px;
}

.library-style-preview-art.wooden {
    background: linear-gradient(180deg, #422110, #140907);
}

.library-style-preview-art.wooden::after {
    background: linear-gradient(180deg, #8c4a23, #35170b);
}

.library-style-preview-art.dark {
    background: linear-gradient(180deg, #16171d, #030304);
}

.library-style-preview-art.dark::after {
    background: linear-gradient(180deg, #343641, #08090c);
}

.library-style-preview-art.glass {
    background: linear-gradient(135deg, rgba(180, 230, 255, 0.24), rgba(22, 42, 54, 0.42));
    border: 1px solid rgba(190, 235, 255, 0.2);
}

.library-style-preview-art.glass::after {
    background: rgba(190, 235, 255, 0.34);
}

.library-style-preview-art.fantasy {
    background:
        radial-gradient(circle at 20% 18%, rgba(240, 215, 140, 0.42), transparent 22%),
        linear-gradient(180deg, #19301f, #080a07);
}

.library-style-preview-art.fantasy::after {
    background: linear-gradient(180deg, #936b29, #2b1c08);
    box-shadow: 0 0 12px rgba(240, 215, 140, 0.2);
}

.library-customize-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin: 12px 0 8px;
}

.library-customize-actions .btn-library-search {
    flex: 1 1 120px;
}

.library-customize-status {
    min-height: 18px;
    margin: 0;
    color: rgba(255, 255, 255, 0.66);
    font-family: var(--font-raleway);
    font-size: 0.78rem;
    font-weight: 700;
}

.personal-library-page.bookshelf-style-changing .library-books-grid {
    animation: libraryBookshelfFade 260ms ease;
}

@keyframes libraryBookshelfFade {
    0% {
        opacity: 0.64;
        transform: translateY(8px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.personal-library-page[data-view-mode="list"] .library-books-grid {
    grid-template-columns: 1fr;
}

.personal-library-page[data-view-mode="list"] .library-book-card {
    grid-template-columns: 132px minmax(0, 1fr);
    min-height: 220px;
}

.personal-library-page[data-view-mode="shelf"] .library-books-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    align-items: end;
    background: linear-gradient(180deg, rgba(80, 36, 20, 0.24), rgba(12, 8, 6, 0.1));
    border: 1px solid rgba(212, 168, 83, 0.16);
    border-radius: var(--radius-md);
    padding: 22px 18px 30px;
}

.personal-library-page[data-view-mode="shelf"] .library-book-card {
    grid-template-columns: 1fr;
    min-height: auto;
    transform-origin: bottom center;
}

.personal-library-page[data-view-mode="shelf"] .library-book-cover {
    height: 280px;
}

.personal-library-page[data-view-mode="shelf"] .library-book-body {
    padding: 14px;
}

.personal-library-page[data-card-size="small"] .library-books-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.personal-library-page[data-card-size="small"] .library-book-card {
    grid-template-columns: 118px minmax(0, 1fr);
    min-height: 238px;
}

.personal-library-page[data-card-size="large"] .library-books-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.personal-library-page[data-card-size="large"] .library-book-card {
    grid-template-columns: 190px minmax(0, 1fr);
    min-height: 330px;
}

.personal-library-page[data-view-mode="list"][data-card-size] .library-books-grid {
    grid-template-columns: 1fr;
}

.personal-library-page[data-view-mode="list"][data-card-size="small"] .library-book-card {
    grid-template-columns: 118px minmax(0, 1fr);
    min-height: 205px;
}

.personal-library-page[data-view-mode="list"][data-card-size="medium"] .library-book-card {
    grid-template-columns: 150px minmax(0, 1fr);
    min-height: 245px;
}

.personal-library-page[data-view-mode="list"][data-card-size="large"] .library-book-card {
    grid-template-columns: 190px minmax(0, 1fr);
    min-height: 315px;
}

.personal-library-page[data-view-mode="shelf"] .library-books-grid,
.personal-library-page[data-view-mode="shelf"][data-card-size="large"] .library-books-grid {
    position: relative;
    grid-template-columns: repeat(auto-fill, minmax(138px, 1fr));
    gap: 34px 18px;
    align-items: end;
    padding: 34px 26px 58px;
    overflow: hidden;
    background:
        linear-gradient(90deg, rgba(255, 255, 255, 0.05), transparent 18%, rgba(255, 255, 255, 0.035) 36%, transparent 56%),
        repeating-linear-gradient(90deg, rgba(71, 35, 18, 0.42) 0 22px, rgba(34, 18, 12, 0.48) 22px 44px),
        linear-gradient(180deg, #1c110c 0%, #0b0705 100%);
    border: 1px solid rgba(212, 168, 83, 0.2);
    border-radius: 8px;
    box-shadow: inset 0 0 60px rgba(0, 0, 0, 0.5), 0 24px 70px rgba(0, 0, 0, 0.36);
    perspective: 900px;
}

.personal-library-page[data-view-mode="shelf"] .library-books-grid::before,
.personal-library-page[data-view-mode="shelf"] .library-books-grid::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    pointer-events: none;
}

.personal-library-page[data-view-mode="shelf"] .library-books-grid::before {
    top: 0;
    bottom: 0;
    background:
        linear-gradient(90deg, rgba(7, 4, 3, 0.8), transparent 5%, transparent 95%, rgba(7, 4, 3, 0.82)),
        repeating-linear-gradient(180deg, transparent 0 286px, rgba(216, 156, 82, 0.26) 286px 294px, rgba(48, 20, 10, 0.92) 294px 322px);
    z-index: 0;
}

.personal-library-page[data-view-mode="shelf"] .library-books-grid::after {
    bottom: 22px;
    height: 26px;
    background: linear-gradient(180deg, #7a3e1f, #2f160c 58%, #130906);
    box-shadow: 0 -8px 18px rgba(246, 194, 104, 0.13), 0 18px 32px rgba(0, 0, 0, 0.55);
    z-index: 1;
}

.personal-library-page[data-view-mode="shelf"] .library-book-card,
.personal-library-page[data-view-mode="shelf"][data-card-size="large"] .library-book-card {
    position: relative;
    z-index: 2;
    display: block;
    min-height: 252px;
    height: 286px;
    width: min(100%, 162px);
    justify-self: center;
    overflow: visible;
    border: 0;
    border-radius: 4px 7px 7px 4px;
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.16), rgba(0, 0, 0, 0.06) 18%, rgba(0, 0, 0, 0.24));
    box-shadow: -10px 16px 22px rgba(0, 0, 0, 0.4), inset 10px 0 18px rgba(255, 255, 255, 0.08), inset -10px 0 18px rgba(0, 0, 0, 0.24);
    transform: rotate(var(--book-tilt, -1deg)) translateY(var(--book-lift, 0));
    transform-origin: bottom center;
    transition: transform 220ms ease, filter 220ms ease, box-shadow 220ms ease;
}

.personal-library-page[data-view-mode="shelf"] .library-book-card::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 -9px;
    width: 14px;
    border-radius: 4px 0 0 4px;
    background:
        linear-gradient(90deg, rgba(255, 255, 255, 0.22), transparent 42%),
        linear-gradient(180deg, var(--book-spine, #8a1f2d), color-mix(in srgb, var(--book-spine, #8a1f2d), #000 38%));
    box-shadow: inset -4px 0 9px rgba(0, 0, 0, 0.28);
}

.personal-library-page[data-view-mode="shelf"] .library-book-card::after {
    content: "";
    position: absolute;
    left: -12px;
    right: -7px;
    bottom: -19px;
    height: 18px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.34);
    filter: blur(8px);
    z-index: -1;
}

.personal-library-page[data-view-mode="shelf"] .library-book-card:nth-child(6n + 1) {
    --book-spine: #8c2030;
    --book-tilt: -2.4deg;
    --book-lift: 8px;
}

.personal-library-page[data-view-mode="shelf"] .library-book-card:nth-child(6n + 2) {
    --book-spine: #1e5b68;
    --book-tilt: 1.6deg;
    --book-lift: -3px;
}

.personal-library-page[data-view-mode="shelf"] .library-book-card:nth-child(6n + 3) {
    --book-spine: #926a22;
    --book-tilt: -0.8deg;
    --book-lift: 12px;
}

.personal-library-page[data-view-mode="shelf"] .library-book-card:nth-child(6n + 4) {
    --book-spine: #3d4c88;
    --book-tilt: 2.2deg;
    --book-lift: 2px;
}

.personal-library-page[data-view-mode="shelf"] .library-book-card:nth-child(6n + 5) {
    --book-spine: #315f35;
    --book-tilt: -1.5deg;
    --book-lift: -7px;
}

.personal-library-page[data-view-mode="shelf"] .library-book-card:nth-child(6n) {
    --book-spine: #5f2c62;
    --book-tilt: 1deg;
    --book-lift: 6px;
}

.personal-library-page[data-view-mode="shelf"] .library-book-card:hover {
    z-index: 5;
    filter: saturate(1.08);
    box-shadow: -16px 24px 34px rgba(0, 0, 0, 0.46), 0 0 0 1px rgba(240, 215, 140, 0.28), inset 10px 0 18px rgba(255, 255, 255, 0.09);
    transform: translateY(-16px) rotate(0deg) scale(1.04);
}

.personal-library-page[data-view-mode="shelf"] .library-book-cover {
    position: absolute;
    inset: 0;
    height: auto;
    border-radius: 4px 7px 7px 4px;
    overflow: hidden;
}

.personal-library-page[data-view-mode="shelf"] .library-book-cover::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(0, 0, 0, 0.5), transparent 18%, transparent 72%, rgba(255, 255, 255, 0.12)),
        linear-gradient(180deg, transparent 62%, rgba(0, 0, 0, 0.58));
}

.personal-library-page[data-view-mode="shelf"] .library-book-cover img {
    filter: contrast(1.04) saturate(0.96);
}

.personal-library-page[data-view-mode="shelf"] .library-book-access {
    top: 10px;
    left: 10px;
    padding: 5px 8px;
    font-size: 0.66rem;
}

.personal-library-page[data-view-mode="shelf"] .library-book-body {
    position: absolute;
    left: 10px;
    right: 10px;
    bottom: 10px;
    z-index: 2;
    min-width: 0;
    padding: 12px;
    border-radius: 7px;
    background: linear-gradient(180deg, rgba(8, 6, 5, 0.08), rgba(8, 6, 5, 0.86));
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 180ms ease, transform 180ms ease;
}

.personal-library-page[data-view-mode="shelf"] .library-book-card:hover .library-book-body,
.personal-library-page[data-view-mode="shelf"] .library-book-card:focus-within .library-book-body {
    opacity: 1;
    transform: translateY(0);
}

.personal-library-page[data-view-mode="shelf"] .library-book-badges,
.personal-library-page[data-view-mode="shelf"] .library-book-category,
.personal-library-page[data-view-mode="shelf"] .library-book-meta,
.personal-library-page[data-view-mode="shelf"] .library-card-progress {
    display: none;
}

.personal-library-page[data-view-mode="shelf"] .library-book-body h2 {
    display: -webkit-box;
    margin-bottom: 4px;
    overflow: hidden;
    color: #fff;
    font-size: 1rem;
    line-height: 1.18;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.72);
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.personal-library-page[data-view-mode="shelf"] .library-book-author {
    display: -webkit-box;
    margin-bottom: 8px;
    overflow: hidden;
    color: rgba(255, 255, 255, 0.74);
    font-size: 0.74rem;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
}

.personal-library-page[data-view-mode="shelf"] .library-book-actions {
    gap: 6px;
}

.personal-library-page[data-view-mode="shelf"] .btn-library-card-action {
    width: 32px;
    height: 32px;
    justify-content: center;
    padding: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.12);
}

.personal-library-page[data-view-mode="shelf"] .btn-library-card-action span {
    display: none;
}

.personal-library-page[data-view-mode="shelf"] .library-wishlist-form,
.personal-library-page[data-view-mode="shelf"] .library-remove-form {
    display: inline-flex;
}

.personal-library-page[data-bookshelf-style="wooden"] .library-books-grid {
    background:
        linear-gradient(90deg, rgba(255, 255, 255, 0.05), transparent 18%, rgba(255, 255, 255, 0.035) 36%, transparent 56%),
        repeating-linear-gradient(90deg, rgba(71, 35, 18, 0.42) 0 22px, rgba(34, 18, 12, 0.48) 22px 44px),
        linear-gradient(180deg, #1c110c 0%, #0b0705 100%);
    border-color: rgba(212, 168, 83, 0.2);
}

.personal-library-page[data-bookshelf-style="dark"] .library-hero-section {
    background: linear-gradient(135deg, #040405 0%, #101116 48%, #050507 100%);
}

.personal-library-page[data-bookshelf-style="dark"] .library-books-grid {
    background:
        linear-gradient(90deg, rgba(255, 255, 255, 0.03), transparent 20%, rgba(255, 255, 255, 0.025) 42%, transparent 70%),
        repeating-linear-gradient(90deg, rgba(22, 23, 28, 0.8) 0 28px, rgba(6, 7, 10, 0.92) 28px 56px),
        linear-gradient(180deg, #111216 0%, #030304 100%);
    border-color: rgba(255, 255, 255, 0.11);
    box-shadow: inset 0 0 70px rgba(0, 0, 0, 0.74), 0 24px 70px rgba(0, 0, 0, 0.44);
}

.personal-library-page[data-bookshelf-style="dark"] .library-books-grid::before {
    background:
        linear-gradient(90deg, rgba(0, 0, 0, 0.84), transparent 6%, transparent 94%, rgba(0, 0, 0, 0.84)),
        repeating-linear-gradient(180deg, transparent 0 286px, rgba(255, 255, 255, 0.1) 286px 292px, rgba(2, 2, 3, 0.95) 292px 322px);
}

.personal-library-page[data-bookshelf-style="dark"] .library-books-grid::after {
    background: linear-gradient(180deg, #2a2b32, #0d0e12 58%, #030304);
}

.personal-library-page[data-bookshelf-style="dark"] .library-book-card::before {
    background:
        linear-gradient(90deg, rgba(255, 255, 255, 0.16), transparent 42%),
        linear-gradient(180deg, color-mix(in srgb, var(--book-spine, #26323f), #fff 4%), color-mix(in srgb, var(--book-spine, #26323f), #000 54%));
}

.personal-library-page[data-bookshelf-style="glass"] .library-hero-section {
    background: linear-gradient(135deg, #06080b 0%, #10202a 52%, #07090d 100%);
}

.personal-library-page[data-bookshelf-style="glass"] .library-books-grid {
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.13), rgba(255, 255, 255, 0.03)),
        radial-gradient(circle at 25% 10%, rgba(120, 210, 255, 0.15), transparent 36%),
        linear-gradient(180deg, rgba(10, 18, 24, 0.86), rgba(3, 7, 10, 0.95));
    border-color: rgba(160, 220, 255, 0.26);
    box-shadow: inset 0 0 80px rgba(130, 210, 255, 0.08), 0 24px 70px rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(18px);
}

.personal-library-page[data-bookshelf-style="glass"] .library-books-grid::before {
    background:
        linear-gradient(90deg, rgba(255, 255, 255, 0.14), transparent 12%, transparent 88%, rgba(255, 255, 255, 0.12)),
        repeating-linear-gradient(180deg, transparent 0 286px, rgba(190, 235, 255, 0.42) 286px 290px, rgba(120, 200, 255, 0.12) 290px 318px);
}

.personal-library-page[data-bookshelf-style="glass"] .library-books-grid::after {
    background: linear-gradient(180deg, rgba(210, 245, 255, 0.45), rgba(130, 200, 230, 0.16) 58%, rgba(20, 45, 56, 0.28));
    box-shadow: 0 -8px 18px rgba(190, 235, 255, 0.18), 0 18px 32px rgba(0, 0, 0, 0.38);
}

.personal-library-page[data-bookshelf-style="glass"] .library-book-card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0.04));
    border: 1px solid rgba(190, 235, 255, 0.22);
    box-shadow: -10px 16px 24px rgba(0, 0, 0, 0.34), inset 8px 0 16px rgba(255, 255, 255, 0.12);
}

.personal-library-page[data-bookshelf-style="fantasy"] .library-hero-section {
    background: linear-gradient(135deg, #050706 0%, #102219 46%, #211609 100%);
}

.personal-library-page[data-bookshelf-style="fantasy"] .library-books-grid {
    background:
        radial-gradient(circle at 16% 12%, rgba(240, 215, 140, 0.18), transparent 25%),
        radial-gradient(circle at 86% 10%, rgba(72, 170, 112, 0.18), transparent 30%),
        repeating-linear-gradient(90deg, rgba(31, 69, 43, 0.44) 0 24px, rgba(20, 38, 28, 0.55) 24px 48px),
        linear-gradient(180deg, #142015 0%, #080a07 100%);
    border-color: rgba(240, 215, 140, 0.28);
    box-shadow: inset 0 0 80px rgba(240, 215, 140, 0.08), 0 24px 70px rgba(0, 0, 0, 0.42);
}

.personal-library-page[data-bookshelf-style="fantasy"] .library-books-grid::before {
    background:
        linear-gradient(90deg, rgba(2, 5, 3, 0.75), transparent 6%, transparent 94%, rgba(2, 5, 3, 0.78)),
        repeating-linear-gradient(180deg, transparent 0 286px, rgba(240, 215, 140, 0.32) 286px 294px, rgba(47, 34, 11, 0.9) 294px 322px);
}

.personal-library-page[data-bookshelf-style="fantasy"] .library-books-grid::after {
    background: linear-gradient(180deg, #83612a, #2b1c08 58%, #080503);
    box-shadow: 0 -8px 18px rgba(240, 215, 140, 0.18), 0 18px 32px rgba(0, 0, 0, 0.52);
}

.personal-library-page[data-bookshelf-style="fantasy"] .library-book-card::before {
    box-shadow: inset -4px 0 9px rgba(0, 0, 0, 0.3), 0 0 16px rgba(240, 215, 140, 0.15);
}

.personal-library-page[data-bookshelf-style="fantasy"] .library-book-card:hover {
    box-shadow: -16px 24px 34px rgba(0, 0, 0, 0.46), 0 0 26px rgba(240, 215, 140, 0.22), inset 10px 0 18px rgba(255, 255, 255, 0.09);
}

.personal-library-page[data-theme-style="royal"] .library-hero-section {
    background: linear-gradient(135deg, #09090d 0%, #241707 52%, #0f1118 100%);
}

.personal-library-page[data-theme-style="royal"] .glass-card {
    border-color: rgba(240, 215, 140, 0.18);
    box-shadow: 0 18px 48px rgba(212, 168, 83, 0.1), 0 18px 48px rgba(0, 0, 0, 0.34);
}

.personal-library-page[data-theme-style="cyber"] .library-hero-section {
    background: linear-gradient(135deg, #050508 0%, #071827 48%, #22040d 100%);
}

.personal-library-page[data-theme-style="cyber"] .glass-card {
    border-color: rgba(72, 190, 255, 0.18);
    box-shadow: 0 0 32px rgba(72, 190, 255, 0.08), 0 18px 48px rgba(0, 0, 0, 0.38);
}

.personal-library-page[data-theme-style="cozy"] .library-hero-section {
    background: linear-gradient(135deg, #080706 0%, #1b1110 50%, #0d1117 100%);
}

.personal-library-page[data-theme-style="cozy"] .glass-card {
    background: linear-gradient(145deg, rgba(42, 25, 22, 0.68), rgba(14, 14, 22, 0.84));
}

.library-confetti-piece {
    position: fixed;
    top: -18px;
    z-index: 3000;
    width: 9px;
    height: 14px;
    border-radius: 2px;
    pointer-events: none;
    animation: libraryConfettiFall 2.2s ease-in forwards;
}

@keyframes libraryConfettiFall {
    0% {
        opacity: 1;
        transform: translateY(-20px) rotate(0deg);
    }
    100% {
        opacity: 0;
        transform: translateY(105vh) rotate(540deg);
    }
}

.personal-library-page[data-theme-style="cozy"] .library-books-grid {
    background: linear-gradient(180deg, rgba(80, 36, 20, 0.22), rgba(12, 8, 6, 0.08));
    border: 1px solid rgba(212, 168, 83, 0.12);
    border-radius: var(--radius-md);
    padding: 18px;
}

/* ============================================================
   RESPONSIVE MEDIA QUERIES
   ============================================================ */

/* Large Desktop */
@media (max-width: 1400px) {
    .hero-title-line-1 {
        font-size: 3.8rem;
    }
    .hero-title-line-2 {
        font-size: 2.4rem;
    }
}

/* Desktop */
@media (max-width: 1200px) {
    .books-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .blogs-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .blog-detail-layout {
        grid-template-columns: minmax(0, 1fr) 280px;
    }
    .profile-grid {
        gap: 22px;
    }
    .library-books-grid,
    .personal-library-page[data-card-size="small"] .library-books-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .library-stats-grid,
    .personal-library-page[data-view-mode="shelf"] .library-books-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
    .library-search-row {
        grid-template-columns: minmax(240px, 1fr) 160px 170px auto;
    }
    .hero-title-line-1 {
        font-size: 3.2rem;
    }
    .hero-title-line-2 {
        font-size: 2rem;
    }
    .hero-image {
        height: 400px;
    }
    .section-title {
        font-size: 2.5rem;
    }
    .timeline-content {
        width: 40%;
    }
}

/* Tablet Landscape */
@media (max-width: 992px) {
    .hero-section {
        min-height: auto;
        padding: 120px 0 60px;
    }
    .hero-text-col {
        text-align: center;
        margin-bottom: 40px;
    }
    .hero-paragraph {
        max-width: 100%;
    }
    .hero-buttons {
        justify-content: center;
    }
    .hero-stats {
        justify-content: center;
    }
    .hero-image {
        height: 350px;
    }
    .hero-floating-card-1 {
        left: 10px;
    }
    .hero-floating-card-2 {
        right: 10px;
    }
    .story-content {
        padding-left: 0;
        margin-top: 30px;
    }
    .timeline-wrapper::before {
        left: 30px;
    }
    .timeline-item,
    .timeline-item-right {
        flex-direction: row;
    }
    .timeline-marker {
        left: 30px;
    }
    .timeline-content {
        width: 80%;
        margin-left: 60px !important;
        margin-right: 0 !important;
    }
    .navbar-collapse {
        background: rgba(10, 10, 20, 0.95);
        backdrop-filter: blur(20px);
        border-radius: var(--radius-md);
        padding: 15px;
        margin-top: 10px;
    }
    .filter-wrapper {
        gap: 8px;
    }
    .filter-btn {
        padding: 8px 15px;
        font-size: 0.78rem;
    }
    .books-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 18px;
    }
    .blog-detail-layout {
        grid-template-columns: 1fr;
    }
    .blog-detail-sidebar {
        position: static;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .profile-hero-card {
        align-items: flex-start;
    }
    .profile-grid {
        grid-template-columns: 1fr;
    }
    .profile-password-panel {
        grid-column: auto;
    }
    .library-hero-card {
        grid-template-columns: auto minmax(0, 1fr);
    }
    .btn-library-customize {
        grid-column: 1 / -1;
        justify-self: start;
    }
    .library-stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .library-search-row {
        grid-template-columns: 1fr 1fr;
    }
    .library-search-input,
    .btn-library-search {
        grid-column: 1 / -1;
    }
    .library-continue-grid {
        grid-template-columns: 1fr;
    }
    .personal-library-page[data-card-size="large"] .library-books-grid {
        grid-template-columns: 1fr;
    }
    .cta-title {
        font-size: 2.2rem;
    }
}

/* Tablet Portrait */
@media (max-width: 768px) {
    .hero-title-line-1 {
        font-size: 2.6rem;
    }
    .hero-title-line-2 {
        font-size: 1.6rem;
        letter-spacing: 5px;
    }
    .hero-typed-wrapper {
        font-size: 1.2rem;
    }
    .hero-paragraph {
        font-size: 0.95rem;
    }
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    .hero-stats {
        gap: 15px;
    }
    .hero-stat-number {
        font-size: 1.5rem;
    }
    .hero-stat-divider {
        height: 30px;
    }
    .hero-image {
        height: 300px;
    }
    .section-title {
        font-size: 2rem;
    }
    .books-grid {
        grid-template-columns: 1fr 1fr;
        gap: 15px;
    }
    .blog-hero-section,
    .blog-detail-hero {
        padding: 125px 0 45px;
    }
    .blogs-grid,
    .blog-detail-sidebar {
        grid-template-columns: 1fr;
    }
    .blog-card-image-link {
        height: 220px;
    }
    .blog-content {
        padding: 28px;
    }
    .blog-detail-excerpt {
        font-size: 1.28rem;
    }
    .blog-paragraph-block p,
    .blog-content > p {
        font-size: 1.08rem;
        line-height: 1.85;
    }
    .blog-search-inner {
        flex-wrap: wrap;
    }
    .blog-search-inner input {
        flex-basis: calc(100% - 44px);
    }
    .btn-blog-search {
        width: 100%;
        justify-content: center;
    }
    .profile-hero-section {
        padding: 125px 0 36px;
    }
    .profile-hero-card {
        flex-direction: column;
        align-items: center;
        text-align: center;
        padding: 28px 22px;
    }
    .profile-avatar-large {
        width: 112px;
        height: 112px;
        flex-basis: 112px;
        font-size: 2.7rem;
    }
    .book-card-image-wrapper {
        height: 180px;
    }
    .search-input {
        font-size: 0.85rem;
    }
    .btn-search {
        padding: 10px 20px;
        font-size: 0.85rem;
    }
    .newsletter-input-group {
        flex-direction: column;
    }
    .footer-bottom .row {
        text-align: center;
    }
    .footer-bottom .text-md-end {
        text-align: center !important;
        margin-top: 10px;
    }
    .cta-title {
        font-size: 1.8rem;
    }
    .cta-text {
        font-size: 0.95rem;
    }
    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    .audio-card {
        padding: 30px 20px;
    }
}

/* Mobile Large */
@media (max-width: 576px) {
    .library-customize-panel {
        top: 84px;
        left: 12px;
        right: 12px;
        width: auto;
        max-height: calc(100vh - 104px);
        padding: 18px;
        transform: translateY(calc(100% + 32px));
    }
    .library-customize-panel.open {
        transform: translateY(0);
    }
    .library-customize-header {
        top: -18px;
    }
    .hero-title-line-1 {
        font-size: 2rem;
    }
    .hero-title-line-2 {
        font-size: 1.3rem;
        letter-spacing: 4px;
    }
    .hero-badge {
        font-size: 0.7rem;
        padding: 6px 14px;
    }
    .hero-typed-wrapper {
        font-size: 1rem;
    }
    .hero-stats {
        flex-direction: column;
        gap: 10px;
    }
    .hero-stat-divider {
        width: 40px;
        height: 1px;
    }
    .hero-image {
        height: 250px;
    }
    .hero-floating-card {
        display: none;
    }
    .books-grid {
        grid-template-columns: 1fr;
        gap: 18px;
    }
    .book-card-image-wrapper {
        height: 220px;
    }
    .blogs-list-section,
    .blog-detail-content-section {
        padding-bottom: 70px;
    }
    .blog-card-body,
    .blog-sidebar-card,
    .blog-tags {
        padding: 20px;
    }
    .blog-card-title {
        font-size: 1.25rem;
    }
    .blog-card-meta,
    .blog-detail-meta {
        gap: 9px 12px;
        font-size: 0.78rem;
    }
    .blog-detail-title {
        font-size: 1.9rem;
    }
    .blog-content {
        padding: 22px;
    }
    .blog-paragraph-block h2 {
        font-size: 1.45rem;
    }
    .blog-search-form {
        padding: 9px;
    }
    .blog-search-inner {
        gap: 8px;
    }
    .blog-search-inner input {
        padding: 12px 14px;
        font-size: 0.86rem;
    }
    .blog-search-clear {
        margin-left: 10px;
    }
    .profile-panel {
        padding: 22px;
    }
    .profile-panel-header {
        gap: 12px;
    }
    .profile-panel-header h2 {
        font-size: 1.25rem;
    }
    .profile-picture-preview {
        width: 128px;
        height: 128px;
        font-size: 2.8rem;
    }
    .btn-profile-action {
        width: 100%;
        justify-content: center;
    }
    .library-hero-section {
        padding-top: 118px;
    }
    .library-hero-card {
        grid-template-columns: 1fr;
        text-align: center;
        justify-items: center;
        padding: 24px 18px;
    }
    .btn-library-customize {
        justify-self: stretch;
        width: 100%;
    }
    .library-stats-grid {
        grid-template-columns: 1fr 1fr;
        gap: 12px;
    }
    .library-stat-card {
        min-height: 112px;
        padding: 15px;
    }
    .library-search-row {
        grid-template-columns: 1fr;
    }
    .library-search-input,
    .btn-library-search {
        grid-column: auto;
    }
    .library-view-toolbar {
        justify-content: center;
    }
    .library-books-grid,
    .personal-library-page[data-card-size="small"] .library-books-grid,
    .personal-library-page[data-card-size="large"] .library-books-grid {
        grid-template-columns: 1fr;
    }
    .library-book-card,
    .personal-library-page[data-view-mode="list"] .library-book-card,
    .personal-library-page[data-card-size="small"] .library-book-card,
    .personal-library-page[data-card-size="large"] .library-book-card {
        grid-template-columns: 128px minmax(0, 1fr);
        min-height: 236px;
    }
    .library-book-actions {
        gap: 7px;
    }
    .btn-library-card-action {
        padding: 8px 10px;
    }
    .section-title {
        font-size: 1.7rem;
    }
    .section-subtitle {
        font-size: 0.9rem;
    }
    .filter-wrapper {
        gap: 6px;
    }
    .filter-btn {
        padding: 7px 12px;
        font-size: 0.72rem;
        border-radius: 20px;
    }
    .story-heading {
        font-size: 1.6rem;
    }
    .timeline-content {
        width: 88%;
        margin-left: 50px !important;
    }
    .newsletter-card {
        padding: 30px 20px;
    }
    .cta-title {
        font-size: 1.5rem;
    }
    .cta-trust-badges {
        flex-direction: column;
        gap: 10px;
        align-items: center;
    }
    .faq-accordion .accordion-button {
        font-size: 0.9rem;
        padding: 15px 18px;
    }
    .faq-accordion .accordion-body {
        padding: 0 18px 15px 45px;
        font-size: 0.85rem;
    }
    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 40px;
        height: 40px;
        font-size: 1.1rem;
    }
    .stat-number {
        font-size: 2rem;
    }
    .brand-name {
        font-size: 1.2rem;
    }
    .brand-icon {
        font-size: 1.4rem;
    }
    .library-stats-grid {
        grid-template-columns: 1fr;
    }
    .library-book-card,
    .personal-library-page[data-view-mode="list"] .library-book-card,
    .personal-library-page[data-card-size="small"] .library-book-card,
    .personal-library-page[data-card-size="large"] .library-book-card {
        grid-template-columns: 1fr;
    }
    .library-book-cover {
        height: 260px;
    }
    .library-book-actions,
    .library-wishlist-form,
    .btn-library-card-action {
        width: 100%;
    }
    .btn-library-card-action {
        justify-content: center;
    }
    .library-continue-card {
        grid-template-columns: 80px minmax(0, 1fr);
    }
    .library-continue-card img {
        width: 80px;
        height: 116px;
    }
    .personal-library-page[data-view-mode="shelf"] .library-books-grid,
    .personal-library-page[data-view-mode="shelf"][data-card-size="large"] .library-books-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 30px 12px;
        padding: 26px 16px 50px;
    }
    .personal-library-page[data-view-mode="shelf"] .library-book-card,
    .personal-library-page[data-view-mode="shelf"][data-card-size="large"] .library-book-card {
        display: block;
        grid-template-columns: none;
        width: min(100%, 138px);
        height: 232px;
        min-height: 232px;
    }
    .personal-library-page[data-view-mode="shelf"] .library-book-cover {
        height: auto;
    }
    .personal-library-page[data-view-mode="shelf"] .library-book-body {
        left: 8px;
        right: 8px;
        bottom: 8px;
        padding: 10px;
    }
    .personal-library-page[data-view-mode="shelf"] .library-book-body h2 {
        font-size: 0.9rem;
    }
    .personal-library-page[data-view-mode="shelf"] .btn-library-card-action {
        width: 30px;
        height: 30px;
    }
}

/* Mobile Small */
@media (max-width: 400px) {
    .hero-title-line-1 {
        font-size: 1.7rem;
    }
    .hero-title-line-2 {
        font-size: 1.1rem;
        letter-spacing: 3px;
    }
    .hero-section {
        padding: 100px 0 40px;
    }
    .book-card-image-wrapper {
        height: 180px;
    }
    .section-title {
        font-size: 1.4rem;
    }
    .btn-hero-primary,
    .btn-hero-secondary {
        padding: 12px 22px;
        font-size: 0.85rem;
    }
    .newsletter-title {
        font-size: 1.3rem;
    }
}

/* ============================================================
   MOBILE OVERFLOW & ALIGNMENT FIXES
   ============================================================ */
@media (max-width: 576px) {
    html,
    body {
        width: 100%;
        max-width: 100%;
        overflow-x: clip;
    }

    body {
        position: relative;
    }

    .container,
    .container-fluid,
    .row,
    main,
    section {
        max-width: 100%;
    }

    .row {
        --bs-gutter-x: 1.25rem;
    }

    .glass-navbar {
        width: 100%;
        max-width: 100vw;
    }

    .glass-navbar .container {
        display: flex;
        align-items: center;
        flex-wrap: wrap;
        gap: 8px;
    }

    .navbar-brand {
        min-width: 0;
        max-width: calc(100vw - 86px);
        margin-right: 0;
        flex: 1 1 auto;
    }

    .brand-logo {
        min-width: 0;
        gap: 8px;
    }

    .brand-text,
    .brand-name,
    .brand-sub {
        min-width: 0;
    }

    .brand-name,
    .brand-sub {
        white-space: nowrap;
    }

    .brand-sub {
        letter-spacing: 2px;
    }

    .custom-toggler {
        flex: 0 0 40px;
        margin-left: auto;
    }

    .navbar-collapse {
        flex: 0 0 100%;
        max-width: 100%;
        overflow: hidden;
        order: 3;
    }

    .navbar-nav {
        align-items: stretch !important;
        width: 100%;
    }

    .navbar-nav .nav-link,
    .btn-nav-cta {
        width: 100%;
        justify-content: center;
        text-align: center;
        white-space: normal;
    }

    .hero-section,
    .books-section,
    .search-section {
        width: 100%;
        max-width: 100vw;
        overflow-x: clip;
    }

    .hero-section {
        padding-left: 0;
        padding-right: 0;
    }

    .hero-container,
    .hero-text-col,
    .hero-image-col,
    .hero-image-wrapper,
    .hero-image-frame {
        max-width: 100%;
        min-width: 0;
    }

    .hero-section .row.min-vh-100 {
        min-height: auto !important;
        width: 100%;
        margin-left: 0;
        margin-right: 0;
    }

    .hero-text-col,
    .hero-image-col {
        padding-left: 0.75rem;
        padding-right: 0.75rem;
    }

    .hero-paragraph {
        margin-left: auto;
        margin-right: auto;
    }

    .hero-buttons,
    .cta-buttons {
        width: 100%;
        align-items: stretch;
    }

    .btn-hero-primary,
    .btn-hero-secondary,
    .btn-cta-primary,
    .btn-cta-secondary,
    .btn-story,
    .btn-load-more {
        max-width: 100%;
        justify-content: center;
        text-align: center;
        white-space: normal;
    }

    .hero-glow-orb,
    .books-bg-glow,
    .cta-glow,
    .newsletter-glow-orb,
    .story-floating-orb {
        max-width: 70vw;
        max-height: 70vw;
    }

    .hero-glow-orb-2,
    .books-bg-glow-2,
    .cta-glow-1,
    .newsletter-glow-orb-2 {
        right: 0 !important;
        max-width: 50vw !important;
    }

    .floating-books-container,
    .magic-sparkles {
        overflow: hidden;
        max-width: 100vw;
    }

    .floating-book {
        font-size: 1.25rem;
    }

    .floating-book-2,
    .floating-book-4,
    .floating-book-6 {
        right: 6%;
    }

    .search-section {
        padding-left: 0;
        padding-right: 0;
    }

    .search-wrapper {
        width: 100%;
        max-width: 100% !important;
        margin-left: auto !important;
        margin-right: auto !important;
        border-radius: 24px;
        padding: 8px;
        overflow: hidden;
    }

    .search-inner {
        width: 100%;
        gap: 7px;
        padding: 4px;
        flex-wrap: nowrap;
    }

    .search-icon {
        flex: 0 0 auto;
        margin-left: 7px;
        font-size: 1rem;
    }

    .search-input {
        min-width: 0;
        width: auto;
        flex: 1 1 auto;
        padding: 10px 2px;
    }

    .btn-search {
        flex: 0 0 auto;
        padding: 10px 13px;
        gap: 5px;
        max-width: 38%;
        white-space: nowrap;
        justify-content: center;
    }

    .search-suggestions {
        position: relative;
        left: auto;
        bottom: auto;
        justify-content: center;
        padding: 4px 8px 10px;
        max-width: 100%;
    }

    .suggestion-tag {
        max-width: 100%;
        overflow-wrap: anywhere;
        text-align: center;
    }

    .smart-filters {
        width: 100%;
        max-width: 100%;
        overflow: hidden;
    }

    .filter-wrapper {
        width: 100%;
        justify-content: center;
        align-items: center;
        gap: 8px;
        padding: 0 4px;
    }

    .filter-btn {
        max-width: 100%;
        justify-content: center;
        text-align: center;
        line-height: 1.25;
        white-space: normal;
        overflow-wrap: anywhere;
    }

    .books-grid,
    .book-card-wrapper,
    .book-card {
        width: 100%;
        max-width: 100%;
        min-width: 0;
    }

    .book-card-footer {
        gap: 10px;
        flex-wrap: wrap;
    }

    .book-card-preview-btn {
        max-width: 100%;
        justify-content: center;
        white-space: nowrap;
    }

    .hero-section .glass-card {
        max-width: 100%;
        padding-left: 20px !important;
        padding-right: 20px !important;
    }

    .hero-section form .d-flex.justify-content-between {
        flex-wrap: nowrap;
        gap: 10px;
        align-items: center !important;
    }

    .hero-section form .form-check {
        display: flex;
        align-items: center;
        gap: 7px;
        min-width: 0;
        margin-bottom: 0;
        padding-left: 0;
    }

    .hero-section form .form-check-input {
        flex: 0 0 16px;
        width: 16px;
        height: 16px;
        margin: 0;
    }

    .hero-section form .form-check-label,
    .hero-section form .d-flex.justify-content-between a {
        white-space: nowrap;
        line-height: 1.2;
    }

    .hero-section form .form-check-label {
        font-size: 0.86rem;
    }

    .hero-section form .d-flex.justify-content-between a {
        flex: 0 0 auto;
        font-size: 0.86rem !important;
    }

    .back-to-top {
        right: max(12px, env(safe-area-inset-right));
        bottom: max(14px, env(safe-area-inset-bottom));
    }
}

@media (max-width: 430px) {
    .glass-navbar .container {
        padding-left: 14px;
        padding-right: 14px;
    }

    .search-wrapper {
        border-radius: 20px;
    }

    .btn-search {
        padding-left: 11px;
        padding-right: 11px;
        font-size: 0.78rem;
    }

    .filter-btn {
        padding: 7px 11px;
        font-size: 0.72rem;
    }
}

@media (max-width: 360px) {
    .brand-name {
        font-size: 1.08rem;
    }

    .brand-sub {
        font-size: 0.58rem;
        letter-spacing: 1.5px;
    }

    .search-inner {
        gap: 5px;
    }

    .search-icon {
        margin-left: 5px;
    }

    .btn-search {
        padding-left: 9px;
        padding-right: 9px;
        max-width: 36%;
    }

    .hero-section .glass-card {
        padding-left: 16px !important;
        padding-right: 16px !important;
    }

    .hero-section form .form-check-label,
    .hero-section form .d-flex.justify-content-between a {
        font-size: 0.8rem !important;
    }
}

.footer-bottom-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    align-items: center;
    gap: 0;
    position: relative;
    z-index: 2;
}

.footer-bottom-links a {
    color: rgba(255, 255, 255, 0.4);
    font-size: 0.85rem;
    text-decoration: none;
    transition: var(--transition-smooth);
}

.footer-bottom-links a:hover,
.footer-bottom-links a:focus-visible {
    color: var(--color-glowing-red);
}

.legal-page {
    min-height: 100vh;
    color: #fff;
    background: var(--color-deep-black);
}

.legal-content {
    padding: 0 0 80px;
}

.legal-article {
    max-width: 860px;
    margin: 0 auto 40px;
    padding: 36px;
    line-height: 1.8;
}

.legal-article h2 {
    margin-top: 8px;
    color: var(--color-gold-light);
    font-size: 1.7rem;
}

.legal-toc {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 18px;
    margin-bottom: 24px;
    padding: 14px 16px;
    border: 1px solid rgba(238, 211, 149, 0.28);
    border-radius: 14px;
    background: rgba(16, 14, 20, 0.45);
}

.legal-downloads {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 14px;
    justify-content: center;
    margin: 22px auto 0;
    max-width: 860px;
}

.legal-downloads a {
    color: #eed395;
    font-size: 0.9rem;
}

.legal-download-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #eed395;
    color: #19130a !important;
    border-radius: 10px;
    padding: 10px 16px;
    font-weight: 700;
    text-decoration: none;
}

.legal-download-button:hover {
    background: #fff0bf;
    color: #19130a !important;
}

.legal-section {
    margin-top: 36px;
    padding-top: 8px;
    scroll-margin-top: 120px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.legal-section:first-of-type {
    border-top: 0;
    margin-top: 20px;
}

@media print {
    .navbar,
    .footer-section,
    .support-hero,
    .legal-toc {
        display: none !important;
    }

    .legal-page,
    .legal-article {
        background: #fff !important;
        color: #111 !important;
        box-shadow: none !important;
        max-width: none;
    }
}

.legal-article a {
    color: #eed395;
}

.purchase-legal,
.book-purchase-legal {
    margin-top: 14px;
    font-size: 0.88rem;
    color: rgba(255, 255, 255, 0.68);
    max-width: 640px;
    line-height: 1.6;
}

.purchase-legal a {
    color: #eed395;
}

.commerce-legal-footer {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 18px;
    justify-content: center;
    padding: 24px 16px 40px;
    font-size: 0.85rem;
}

.commerce-legal-footer a {
    color: #eed395;
}

.refund-eligibility-card {
    border: 1px solid rgba(238, 211, 149, 0.28);
    border-radius: 16px;
    padding: 16px 18px;
    margin: 8px 0 16px;
    background: rgba(16, 14, 20, 0.55);
}

.refund-eligibility-card h3 {
    font-size: 1rem;
    margin-bottom: 10px;
}

.refund-eligibility-card dl {
    display: grid;
    gap: 8px;
    margin: 0;
}

.refund-eligibility-card dt {
    color: rgba(255, 255, 255, 0.55);
    font-size: 0.8rem;
}

.refund-eligibility-card dd {
    margin: 0;
    font-weight: 600;
}

.refund-eligibility-status.is-eligible {
    color: #86efac;
}

.refund-eligibility-status.is-ineligible {
    color: #fca5a5;
}

.refund-eligibility-reason {
    margin: 10px 0 0;
}

.refund-loading,
.refund-error {
    margin: 8px 0 0;
}

.refund-error {
    color: #fca5a5;
}

.refund-summary {
    display: grid;
    gap: 12px;
}

.refund-summary div {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    padding-bottom: 8px;
}

.support-status-eligible,
.support-status-approved,
.support-status-refunded {
    background: rgba(22, 101, 52, 0.25);
    color: #86efac;
}

.support-status-under_review,
.support-status-processing,
.support-status-pending {
    background: rgba(146, 64, 14, 0.25);
    color: #fde68a;
}

.support-status-rejected,
.support-status-failed,
.support-status-cancelled {
    background: rgba(185, 28, 28, 0.25);
    color: #fca5a5;
}

@media (max-width: 767px) {
    .footer-bottom-links {
        justify-content: flex-start;
        margin-top: 12px;
    }

    .legal-article,
    .refund-eligibility-card {
        padding: 22px 18px;
    }
}

/* ============================================================
   GLOBAL LUXURY FORM CONTROLS & INPUT ENHANCEMENTS
   ============================================================ */
.form-control,
.form-select {
    background: rgba(18, 18, 30, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #ffffff;
    border-radius: 12px;
    padding: 12px 16px;
    font-size: 0.95rem;
    transition: all 0.3s ease;
}

.form-control:focus,
.form-select:focus {
    background: rgba(22, 22, 38, 0.9);
    border-color: rgba(240, 215, 140, 0.65);
    box-shadow: 0 0 0 3px rgba(199, 40, 50, 0.25), 0 0 16px rgba(216, 173, 82, 0.18);
    color: #ffffff;
    outline: none;
}

.form-control::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

.input-group-text {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: var(--color-gold-light, #f0d78c);
}

.form-check-input {
    background-color: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.22);
    cursor: pointer;
}

.form-check-input:checked {
    background-color: var(--color-crimson, #a01515);
    border-color: var(--color-gold-light, #f0d78c);
    box-shadow: 0 0 10px rgba(255, 45, 45, 0.5);
}
