@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,500;0,600;0,700;1,300;1,400;1,500&family=Plus+Jakarta+Sans:wght@300;400;500;600;700&family=Syne:wght@400;500;600;700;800&display=swap');

/* ==========================================
   DESIGN TOKENS & VARIABLES
   ========================================== */
:root {
    --bg-dark: #020104; /* Deep void black */
    --bg-card: rgba(12, 8, 22, 0.4); /* Premium glassmorphism */
    --bg-card-hover: rgba(18, 12, 32, 0.55);
    --border-glow: rgba(168, 85, 247, 0.1); 
    --border-glow-focus: rgba(168, 85, 247, 0.25);
    
    --accent-purple: #c084fc; /* Electric lavender */
    --accent-lavender: #e9d5ff; /* Soft lavender mist */
    --accent-pink: #fbcfe8; /* Muted pink highlight */
    --accent-glow: rgba(168, 85, 247, 0.12);
    
    --text-cream: #fcfbfe; 
    --text-sand: #cbd5e1; 
    --text-muted: #625776; 
    
    /* Fonts */
    --font-display: 'Syne', sans-serif;
    --font-serif: 'Cormorant Garamond', Georgia, serif;
    --font-sans: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
    
    /* Transitions */
    --ease-premium: cubic-bezier(0.16, 1, 0.3, 1);
    --transition-smooth: all 0.6s var(--ease-premium);
    --transition-fast: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    
    /* Layers */
    --z-loader: 1000;
    --z-modal: 900;
    --z-header: 100;
    --z-cursor: 50;
    --z-content: 10;
    --z-particles: 2;
    --z-blobs: 1;
}

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
    background-color: var(--bg-dark);
    color: var(--text-cream);
    overflow-x: hidden;
}

body {
    font-family: var(--font-sans);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    background: radial-gradient(circle at 50% 15%, #100624 0%, var(--bg-dark) 75%);
    background-attachment: fixed;
    position: relative;
    overflow-x: hidden;
    min-height: 100vh;
}

/* Noise overlay */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    opacity: 0.02;
    pointer-events: none;
    z-index: 999;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 5px;
}
::-webkit-scrollbar-track {
    background: var(--bg-dark);
}
::-webkit-scrollbar-thumb {
    background: var(--text-muted);
    border-radius: 10px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--accent-purple);
}

/* Selection */
::selection {
    background: var(--accent-glow);
    color: var(--accent-lavender);
}

/* ==========================================
   AMBIENT BLOBS & PARTICLES
   ========================================== */
.ambient-blobs-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    pointer-events: none;
    z-index: var(--z-blobs);
    overflow: hidden;
}

.ambient-blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(140px);
    opacity: 0.07;
    mix-blend-mode: screen;
}

.blob-1 {
    top: 15%;
    left: 20%;
    width: 350px;
    height: 350px;
    background: var(--accent-purple);
    animation: blob-float 16s infinite alternate ease-in-out;
}

.blob-2 {
    bottom: 25%;
    right: 15%;
    width: 450px;
    height: 450px;
    background: #c084fc;
    animation: blob-float 20s infinite alternate-reverse ease-in-out;
}

@keyframes blob-float {
    0% { transform: translate(0px, 0px) scale(1); }
    50% { transform: translate(40px, -50px) scale(1.08); }
    100% { transform: translate(-20px, 30px) scale(0.96); }
}

#ambient-particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    pointer-events: none;
    z-index: var(--z-particles);
}

.cursor-glow {
    position: fixed;
    top: 0;
    left: 0;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(168, 85, 247, 0.03) 0%, rgba(168, 85, 247, 0) 70%);
    transform: translate(-50%, -50%);
    pointer-events: none;
    z-index: var(--z-cursor);
    mix-blend-mode: screen;
}

.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 2px;
    background: linear-gradient(to right, var(--accent-purple), var(--accent-pink));
    width: 0%;
    z-index: var(--z-header);
}

/* ==========================================
   TOP NAVIGATION NAVBAR
   ========================================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 1.5rem 3rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: var(--z-header);
    background: rgba(2, 1, 4, 0.4);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(168, 85, 247, 0.05);
}

.navbar-logo {
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-cream);
    text-decoration: none;
    letter-spacing: -0.01em;
    cursor: pointer;
    transition: var(--transition-fast);
}
.navbar-logo:hover {
    color: var(--accent-purple);
    text-shadow: 0 0 10px rgba(168, 85, 247, 0.45);
}

.navbar-links {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-btn {
    font-family: var(--font-sans);
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-sand);
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    transition: var(--transition-fast);
    padding: 0.4rem 1rem;
    border-radius: 20px;
}
.nav-btn:hover {
    color: var(--accent-purple);
    background: rgba(168, 85, 247, 0.06);
}

/* Visually highlighted pill button with pulse and glowing border */
.nav-btn-highlight {
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.12) 0%, rgba(251, 207, 232, 0.12) 100%) !important;
    border: 1px solid rgba(168, 85, 247, 0.35);
    color: var(--accent-lavender) !important;
    padding: 0.55rem 1.4rem !important;
    border-radius: 50px !important;
    font-weight: 600;
    letter-spacing: 0.06em;
    box-shadow: 0 0 15px rgba(168, 85, 247, 0.08);
    animation: support-btn-pulse 2.8s infinite alternate ease-in-out;
}
.nav-btn-highlight:hover {
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.22) 0%, rgba(251, 207, 232, 0.22) 100%) !important;
    border-color: var(--accent-purple);
    color: var(--text-cream) !important;
    box-shadow: 0 0 22px rgba(168, 85, 247, 0.35);
    transform: translateY(-1px);
}
@keyframes support-btn-pulse {
    0% {
        box-shadow: 0 0 10px rgba(168, 85, 247, 0.05);
        border-color: rgba(168, 85, 247, 0.35);
    }
    100% {
        box-shadow: 0 0 20px rgba(168, 85, 247, 0.22);
        border-color: rgba(168, 85, 247, 0.7);
    }
}

/* Typography */
h1, h2, h3, h4 {
    font-family: var(--font-display);
    font-weight: 700;
    color: var(--text-cream);
}

p {
    font-family: var(--font-sans);
    color: var(--text-sand);
    font-size: 0.95rem;
    font-weight: 300;
}

@keyframes float-slow {
    0% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-10px) rotate(1.2deg); }
    100% { transform: translateY(0px) rotate(0deg); }
}

@keyframes pulse-ring {
    0% { transform: scale(0.6); opacity: 0.8; }
    100% { transform: scale(2.2); opacity: 0; }
}

/* ==========================================
   GLASSMORPHISM BASE CARD
   ========================================== */
.glass-card {
    background: var(--bg-card);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid var(--border-glow);
    border-radius: 16px;
    padding: 2.2rem;
    transition: var(--transition-smooth);
    position: relative;
    overflow: hidden;
}
.glass-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -50%;
    width: 200%;
    height: 100%;
    background: linear-gradient(90deg, rgba(255,255,255,0) 0%, rgba(255, 255, 255, 0.01) 50%, rgba(255,255,255,0) 100%);
    transform: skewX(-25deg);
    transition: 0.8s var(--ease-premium);
    pointer-events: none;
}
.glass-card:hover {
    border-color: var(--border-glow-focus);
    background: var(--bg-card-hover);
    transform: translateY(-4px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.4), 0 5px 20px rgba(168, 85, 247, 0.03);
}
.glass-card:hover::before {
    left: 150%;
}

/* Sections */
section {
    position: relative;
    z-index: var(--z-content);
    padding: 8rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.section-tag {
    font-family: var(--font-sans);
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.25em;
    color: var(--accent-purple);
    margin-bottom: 0.8rem;
    display: inline-block;
    font-weight: 600;
}

.section-title {
    font-size: 2.5rem;
    line-height: 1.2;
    margin-bottom: 1.2rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--text-cream) 40%, var(--accent-purple) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.section-subtitle {
    font-size: 1.05rem;
    color: var(--text-sand);
    max-width: 560px;
    margin-bottom: 3rem;
    font-weight: 300;
}

/* ==========================================
   1. LOADING SCREEN
   ========================================== */
.loader-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: #020104;
    z-index: var(--z-loader);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    transition: opacity 1s var(--ease-premium), visibility 1s var(--ease-premium);
}

.loader-quote-container {
    max-width: 600px;
    padding: 2rem;
    text-align: center;
}

.loader-quote {
    font-family: var(--font-serif);
    font-size: 1.8rem;
    font-style: italic;
    color: var(--text-cream);
    line-height: 1.5;
    margin-bottom: 2rem;
    min-height: 80px;
}

.loader-bar {
    width: 120px;
    height: 1px;
    background: rgba(168, 85, 247, 0.15);
    position: relative;
    overflow: hidden;
    margin: 0 auto;
}

.loader-progress {
    width: 0%;
    height: 100%;
    background: var(--accent-purple);
    position: absolute;
    top: 0;
    left: 0;
    transition: width 2.2s cubic-bezier(0.1, 0.8, 0.25, 1);
}

.loader-fade-out {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

/* ==========================================
   2. HERO SPLIT GRID SECTION
   ========================================== */
.hero-section {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    padding-top: 10rem;
    padding-bottom: 5rem;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1.25fr 1fr;
    gap: 5rem;
    width: 100%;
    align-items: center;
}

.hero-left {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
}

/* 1. Book Title styling (stretches across top of hero section) */
.hero-title {
    font-size: 4rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 3.5rem;
    background: linear-gradient(135deg, var(--text-cream) 20%, var(--accent-purple) 65%, var(--accent-pink) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -0.03em;
    width: 100%;
}

/* 2. Author name styling */
.hero-author-name {
    font-family: var(--font-serif);
    font-size: 1.4rem;
    color: var(--accent-pink);
    font-style: italic;
    margin-bottom: 0.3rem;
}

/* 3. Number of pages styling */
.hero-pages-count {
    font-family: var(--font-sans);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
    font-weight: 600;
}

/* 4. Description styling */
.hero-description {
    font-size: 1.05rem;
    color: var(--text-sand);
    margin-bottom: 2rem;
    max-width: 520px;
    line-height: 1.7;
}

/* Stats horizontal flex row */
.hero-stats-row {
    display: flex;
    align-items: center;
    gap: 2rem;
    margin-bottom: 2.5rem;
    background: rgba(168, 85, 247, 0.03);
    border: 1px solid rgba(168, 85, 247, 0.12);
    padding: 0.75rem 1.6rem;
    border-radius: 12px;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    width: fit-content;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2), 0 0 15px rgba(168, 85, 247, 0.02);
    position: relative;
    overflow: hidden;
}
.hero-stats-row::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(110deg, transparent 0%, rgba(255, 255, 255, 0.08) 45%, transparent 65%);
    transform: translateX(-120%);
    animation: stat-sheen 6s var(--ease-premium) infinite;
    pointer-events: none;
}

/* 5. Download count styling */
.hero-download-stat {
    font-family: var(--font-sans);
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-cream);
    letter-spacing: 0.02em;
}
.hero-download-stat span {
    font-family: var(--font-display);
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--accent-purple);
    text-shadow: 0 0 12px rgba(192, 132, 252, 0.35);
    margin-right: 2px;
}

/* 6. Star rating styling */
.hero-rating-stat {
    font-family: var(--font-sans);
    font-size: 1rem;
    color: var(--accent-pink);
    font-weight: 700;
    letter-spacing: 0.02em;
    text-shadow: 0 0 12px rgba(251, 207, 232, 0.35);
    border-left: 1px solid rgba(168, 85, 247, 0.2);
    padding-left: 1.5rem;
}

/* 7. CTA Buttons */
.hero-ctas {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    width: 100%;
}

/* Immersive Buttons */
.btn-primary {
    font-family: var(--font-sans);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    text-decoration: none;
    color: #020104;
    background: linear-gradient(135deg, var(--accent-purple), var(--accent-pink));
    padding: 0.95rem 1.8rem;
    border-radius: 50px;
    border: none;
    cursor: pointer;
    transition: var(--transition-fast);
    box-shadow: 0 4px 15px rgba(168, 85, 247, 0.2);
    position: relative;
    overflow: hidden;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.btn-primary::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.35), transparent);
    transition: 0.6s;
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(168, 85, 247, 0.35);
}
.btn-primary:hover::after {
    left: 100%;
}
.btn-primary:disabled {
    cursor: not-allowed;
    opacity: 0.72;
    transform: none;
}
.btn-primary.is-loading {
    color: rgba(2, 1, 4, 0.76);
}
.btn-primary.is-loading::before {
    content: '';
    width: 14px;
    height: 14px;
    border: 2px solid rgba(2, 1, 4, 0.28);
    border-top-color: #020104;
    border-radius: 50%;
    margin-right: 0.55rem;
    animation: upload-spin 0.8s linear infinite;
}

.btn-secondary {
    font-family: var(--font-sans);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    text-decoration: none;
    color: var(--text-cream);
    background: transparent;
    padding: 0.95rem 1.8rem;
    border-radius: 50px;
    border: 1px solid rgba(168, 85, 247, 0.2);
    cursor: pointer;
    transition: var(--transition-fast);
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.btn-secondary:hover {
    border-color: var(--accent-purple);
    background: rgba(168, 85, 247, 0.08);
    transform: translateY(-2px);
}

.btn-text {
    font-family: var(--font-sans);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    text-decoration: none;
    color: var(--text-sand);
    cursor: pointer;
    transition: var(--transition-fast);
    border-bottom: 1px solid var(--text-muted);
    padding-bottom: 2px;
}
.btn-text:hover {
    color: var(--accent-purple);
    border-color: var(--accent-purple);
}

/* Hero Right: Mockup (aligned to left parallel to descriptions) */
.hero-right {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    position: relative;
}

.book-ambient-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(168, 85, 247, 0.18) 0%, rgba(168, 85, 247, 0) 70%);
    filter: blur(50px);
    z-index: 1;
    pointer-events: none;
}

.book-wrapper {
    perspective: 1200px;
    z-index: 2;
    will-change: transform;
    animation: float-slow 7s ease-in-out infinite;
}

.book-3d {
    width: 220px;
    height: 310px;
    position: relative;
    transform-style: preserve-3d;
    will-change: transform;
    animation: book-rotate-cinematic 20s infinite linear;
}

/* Double-sided cover structure */
.book-cover-front {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    transform-origin: left center;
    transform: translate3d(0, 0, 12px);
    transform-style: preserve-3d;
    z-index: 10;
    will-change: transform;
    animation: cover-open-close 20s infinite linear;
}

.book-cover-front::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('./assets/book_cover.png');
    background-size: cover;
    background-position: center;
    border-radius: 2px 6px 6px 2px;
    backface-visibility: hidden;
    z-index: 2;
    box-shadow: inset -2px 0 5px rgba(255, 255, 255, 0.1), inset 12px 12px 20px rgba(255, 255, 255, 0.06), 0 0 5px rgba(0, 0, 0, 0.2);
}

.book-cover-front::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #140d24; /* Purple-black inside paper lining */
    border-radius: 6px 2px 2px 6px;
    transform: rotateY(180deg);
    backface-visibility: hidden;
    z-index: 1;
    border: 1px solid rgba(168, 85, 247, 0.15);
}

.book-cover-back {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    transform-origin: left center;
    transform: translate3d(0, 0, -12px) rotateY(180deg);
    transform-style: preserve-3d;
    z-index: 0;
}

.book-cover-back::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('./assets/book.back.png');
    background-size: cover;
    background-position: center;
    border-radius: 6px 2px 2px 6px;
    backface-visibility: hidden;
    z-index: 2;
    box-shadow: inset 2px 0 5px rgba(255, 255, 255, 0.1), 0 0 5px rgba(0, 0, 0, 0.2);
}

.book-cover-back::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #140d24; /* Purple-black inside paper lining */
    border-radius: 2px 6px 6px 2px;
    transform: rotateY(180deg);
    backface-visibility: hidden;
    z-index: 1;
    border: 1px solid rgba(168, 85, 247, 0.15);
}

/* Spine Depth */
.book-spine-3d {
    position: absolute;
    top: 0;
    left: 0;
    width: 24px;
    height: 100%;
    background: #09050f;
    border-left: 1px solid rgba(255, 255, 255, 0.08);
    border-right: 1px solid rgba(0, 0, 0, 0.4);
    transform-origin: left center;
    transform: translate3d(0, 0, 12px) rotateY(-90deg);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 5;
    overflow: hidden;
}

.book-spine-3d span {
    color: var(--accent-lavender);
    font-size: 0.55rem;
    font-family: var(--font-display);
    text-transform: uppercase;
    letter-spacing: 0.25em;
    transform: rotate(90deg);
    white-space: nowrap;
    opacity: 0.8;
    text-shadow: 0 0 5px rgba(168, 85, 247, 0.3);
}

/* Layered Pages & Creases */
.book-page-3d {
    position: absolute;
    left: 4px;
    top: 4px;
    width: 212px;
    height: 302px;
    background: linear-gradient(90deg, #eae5d8 0%, #faf7f0 6%, #faf7f0 95%, #ede9df 100%);
    border-radius: 0 4px 4px 0;
    transform-origin: left center;
    transform-style: preserve-3d;
    transition: transform 1.4s var(--ease-premium);
    box-shadow: inset 4px 0 10px rgba(0, 0, 0, 0.05), 1px 1px 3px rgba(0, 0, 0, 0.1);
    z-index: 5;
    will-change: transform;
}

.book-page-depth-1 {
    transform: translate3d(0, 0, 8px);
    animation: page-1-swing 20s infinite linear;
}

.book-page-depth-2 {
    transform: translate3d(0, 0, 3px);
    animation: page-2-swing 20s infinite linear;
}

.book-page-depth-3 {
    transform: translate3d(0, 0, -2px);
    animation: page-3-swing 20s infinite linear;
}

.book-page-depth-4 {
    transform: translate3d(0, 0, -7px);
    animation: page-4-swing 20s infinite linear;
}

.page-content {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
    padding: 1.8rem 1.2rem;
    box-sizing: border-box;
    backface-visibility: hidden;
}

.page-num {
    font-family: var(--font-sans);
    font-size: 0.65rem;
    color: var(--text-muted);
    text-align: right;
    font-weight: 600;
    opacity: 0.6;
}

.page-text {
    font-family: var(--font-serif);
    font-size: 0.8rem;
    font-style: italic;
    color: #2b221a;
    line-height: 1.5;
    text-align: left;
    margin: auto 0;
}

/* Closed Page Edges */
.book-edge-right {
    position: absolute;
    left: 216px;
    top: 4px;
    width: 16px;
    height: 302px;
    transform-origin: left center;
    transform: translate3d(0, 0, 8px) rotateY(90deg);
    background: repeating-linear-gradient(to right, #ded4c1, #ded4c1 1px, #faf7f0 1px, #faf7f0 2px);
    z-index: 4;
    will-change: opacity;
    animation: edges-fade 20s infinite linear;
}

.book-edge-top {
    position: absolute;
    left: 4px;
    top: 4px;
    width: 212px;
    height: 16px;
    transform-origin: top center;
    transform: translate3d(0, 0, 8px) rotateX(-90deg);
    background: repeating-linear-gradient(to bottom, #ded4c1, #ded4c1 1px, #faf7f0 1px, #faf7f0 2px);
    z-index: 4;
    will-change: opacity;
    animation: edges-fade 20s infinite linear;
}

.book-edge-bottom {
    position: absolute;
    left: 4px;
    top: 290px;
    width: 212px;
    height: 16px;
    transform-origin: bottom center;
    transform: translate3d(0, 0, 8px) rotateX(90deg);
    background: repeating-linear-gradient(to bottom, #ded4c1, #ded4c1 1px, #faf7f0 1px, #faf7f0 2px);
    z-index: 4;
    will-change: opacity;
    animation: edges-fade 20s infinite linear;
}

/* Cinematic Animations */

/* Continuous, custom velocity rotation keyframes */
@keyframes book-rotate-cinematic {
    0% {
        transform: rotateY(-10deg) rotateX(10deg);
    }
    10% {
        transform: rotateY(10deg) rotateX(10deg);
    }
    15% {
        transform: rotateY(30deg) rotateX(10deg);
    }
    20% {
        transform: rotateY(50deg) rotateX(10deg);
    }
    25% {
        transform: rotateY(90deg) rotateX(10deg);
    }
    50% {
        transform: rotateY(180deg) rotateX(10deg);
    }
    75% {
        transform: rotateY(270deg) rotateX(10deg);
    }
    80% {
        transform: rotateY(290deg) rotateX(10deg);
    }
    85% {
        transform: rotateY(310deg) rotateX(10deg);
    }
    90% {
        transform: rotateY(330deg) rotateX(10deg);
    }
    95% {
        transform: rotateY(340deg) rotateX(10deg);
    }
    100% {
        transform: rotateY(350deg) rotateX(10deg); /* seamless loop wrap with -10deg */
    }
}

/* Front Cover Swing */
@keyframes cover-open-close {
    0%, 20%, 75%, 100% {
        transform: translate3d(0, 0, 12px) rotateY(0deg);
    }
    80%, 95%, 5% {
        transform: translate3d(0, 0, 12px) rotateY(-145deg);
    }
}

/* Pages Fanning & Bending Out */
@keyframes page-1-swing {
    0%, 20%, 80%, 100% {
        transform: translate3d(0, 0, 8px) rotateY(0deg) skewY(0deg) scaleX(1);
    }
    82.5% {
        transform: translate3d(0, 0, 8px) rotateY(-65deg) skewY(-3deg) scaleX(0.92);
    }
    85%, 95%, 5%, 15% {
        transform: translate3d(0, 0, 8px) rotateY(-130deg) skewY(0deg) scaleX(1);
    }
    17.5% {
        transform: translate3d(0, 0, 8px) rotateY(-65deg) skewY(3deg) scaleX(0.92);
    }
}

@keyframes page-2-swing {
    0%, 15%, 85%, 100% {
        transform: translate3d(0, 0, 3px) rotateY(0deg) skewY(0deg) scaleX(1);
    }
    87.5% {
        transform: translate3d(0, 0, 3px) rotateY(-55deg) skewY(-3deg) scaleX(0.92);
    }
    90%, 95%, 5%, 10% {
        transform: translate3d(0, 0, 3px) rotateY(-110deg) skewY(0deg) scaleX(1);
    }
    12.5% {
        transform: translate3d(0, 0, 3px) rotateY(-55deg) skewY(3deg) scaleX(0.92);
    }
}

@keyframes page-3-swing {
    0%, 10%, 90%, 100% {
        transform: translate3d(0, 0, -2px) rotateY(0deg) skewY(0deg) scaleX(1);
    }
    92.5% {
        transform: translate3d(0, 0, -2px) rotateY(-45deg) skewY(-3deg) scaleX(0.92);
    }
    95%, 5% {
        transform: translate3d(0, 0, -2px) rotateY(-90deg) skewY(0deg) scaleX(1);
    }
    7.5% {
        transform: translate3d(0, 0, -2px) rotateY(-45deg) skewY(3deg) scaleX(0.92);
    }
}

@keyframes page-4-swing {
    0%, 20%, 75%, 100% {
        transform: translate3d(0, 0, -7px) rotateY(0deg);
    }
    80%, 5% {
        transform: translate3d(0, 0, -7px) rotateY(-5deg);
    }
}

/* Edges Fading Out on Open */
@keyframes edges-fade {
    0%, 15%, 80%, 100% {
        opacity: 0;
    }
    20%, 75% {
        opacity: 1;
    }
}

.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    color: var(--text-muted);
    font-size: 0.65rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    text-decoration: none;
    transition: var(--transition-fast);
}
.scroll-indicator:hover {
    color: var(--accent-purple);
}
.scroll-indicator span {
    width: 1px;
    height: 35px;
    background: linear-gradient(to bottom, var(--text-muted), transparent);
    margin-top: 8px;
    display: block;
    position: relative;
    overflow: hidden;
}
.scroll-indicator span::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 15px;
    background: var(--accent-purple);
    animation: scroll-dot 2.2s cubic-bezier(0.16, 1, 0.3, 1) infinite;
}

@keyframes scroll-dot {
    0% { transform: translateY(-15px); }
    100% { transform: translateY(35px); }
}

/* ==========================================
   3. SIMPLIFIED ANALYTICS (NOT USED ANYMORE)
   ========================================== */
.analytics-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2.5rem;
    margin-top: 1.5rem;
}

.metric-card {
    text-align: center;
    padding: 3rem 2rem;
}

.metric-num {
    font-family: var(--font-display);
    font-size: 3.4rem;
    font-weight: 800;
    line-height: 1;
    margin-bottom: 0.8rem;
    background: linear-gradient(135deg, var(--text-cream) 35%, var(--accent-purple) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -0.03em;
}

.metric-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.2em;
    font-weight: 500;
}

/* ==========================================
   4. RANDOM "TODAY'S LESSON" SECTION
   ========================================== */
.lesson-card-wrapper {
    max-width: 800px;
    margin: 0 auto;
}

.lesson-card {
    text-align: center;
    position: relative;
    padding: 5.5rem 4rem;
    overflow: visible;
}

.quote-icon {
    font-family: var(--font-serif);
    font-size: 7rem;
    line-height: 1;
    color: var(--border-glow-focus);
    position: absolute;
    top: 1.2rem;
    left: 3rem;
    opacity: 0.12;
    pointer-events: none;
}

.lesson-quote {
    font-family: var(--font-serif);
    font-size: 2.1rem;
    line-height: 1.55;
    font-style: italic;
    color: var(--text-cream);
    margin-bottom: 2.5rem;
    position: relative;
    z-index: 2;
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.lesson-author {
    font-family: var(--font-sans);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--text-muted);
    margin-bottom: 2.8rem;
}

.lesson-actions {
    display: flex;
    justify-content: center;
    gap: 1.2rem;
    flex-wrap: wrap;
}

/* ==========================================
   5. REVIEWS SECTION
   ========================================== */
.reviews-section {
    max-width: 100%;
    padding-left: 0;
    padding-right: 0;
    overflow: hidden;
}

.reviews-section-header {
    max-width: 1200px;
    margin: 0 auto 3.5rem;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    flex-wrap: wrap;
    gap: 1.5rem;
}

.reviews-track-container {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 1.8rem;
    position: relative;
}

.reviews-track {
    display: flex;
    gap: 1.8rem;
    width: max-content;
}

.track-left {
    animation: scroll-left 52s linear infinite;
}
.track-right {
    animation: scroll-right 52s linear infinite;
}

.reviews-track-container:hover .reviews-track {
    animation-play-state: paused;
}

@keyframes scroll-left {
    0% { transform: translateX(0); }
    100% { transform: translateX(calc(-50% - 0.9rem)); }
}
@keyframes scroll-right {
    0% { transform: translateX(calc(-50% - 0.9rem)); }
    100% { transform: translateX(0); }
}

.review-card {
    flex: 0 0 calc((100% - 4.5rem) / 3);
    background: var(--bg-card);
    border: 1px solid var(--border-glow);
    border-radius: 16px;
    padding: 2rem;
    backdrop-filter: blur(24px);
    transition: var(--transition-smooth);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}
.review-card:hover {
    border-color: var(--border-glow-focus);
    background: var(--bg-card-hover);
    transform: translateY(-4px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.4), 0 5px 20px rgba(168, 85, 247, 0.04);
}

.review-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.review-stars {
    display: flex;
    gap: 2px;
    color: var(--accent-purple);
    font-size: 0.85rem;
}

.review-user {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-cream);
}
.review-country {
    font-size: 0.72rem;
    color: var(--text-muted);
}

.review-text {
    font-size: 0.82rem;
    color: var(--text-sand);
    line-height: 1.55;
    font-style: italic;
}

/* Write a review Modal Trigger */
.review-write-overlay {
    position: fixed;
    top: 0;
    right: -450px;
    width: 420px;
    height: 100vh;
    background: rgba(2, 1, 4, 0.98);
    backdrop-filter: blur(25px);
    border-left: 1px solid var(--border-glow-focus);
    z-index: var(--z-modal);
    transition: right 0.5s var(--ease-premium);
    padding: 4rem 2.5rem;
    box-shadow: -20px 0 50px rgba(0,0,0,0.8);
    overflow-y: auto;
}
.review-write-overlay.active {
    right: 0;
}

.overlay-close {
    position: absolute;
    top: 2rem;
    left: 2.5rem;
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 1.8rem;
    cursor: pointer;
    transition: var(--transition-fast);
}
.overlay-close:hover {
    color: var(--accent-purple);
}

.overlay-title {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    margin-top: 1.8rem;
}
.overlay-subtitle {
    font-size: 0.85rem;
    color: var(--text-sand);
    margin-bottom: 2.5rem;
}

/* Form inputs */
.form-group {
    margin-bottom: 1.8rem;
    position: relative;
}

.form-label {
    display: block;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--text-muted);
    margin-bottom: 0.4rem;
    transition: var(--transition-fast);
}

.form-input {
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 1px solid rgba(168, 85, 247, 0.18);
    color: var(--text-cream);
    padding: 0.7rem 0;
    font-family: var(--font-sans);
    font-size: 0.95rem;
    transition: var(--transition-fast);
    outline: none;
}
.form-input:focus {
    border-color: var(--accent-purple);
}

.form-input::placeholder {
    color: var(--text-muted);
    opacity: 0.45;
}

.star-rating-select {
    display: flex;
    gap: 8px;
    margin-top: 0.4rem;
}
.star-rating-select span {
    font-size: 1.4rem;
    color: var(--text-muted);
    cursor: pointer;
    transition: var(--transition-fast);
}
.star-rating-select span:hover,
.star-rating-select span.active {
    color: var(--accent-purple);
    transform: scale(1.1);
}

/* ==========================================
   6. SIMPLIFIED ABOUT THE AUTHOR PAGE
   ========================================== */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1.3fr;
    gap: 4rem;
    align-items: center;
}

.about-left {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
}

.author-profile-wrapper {
    position: relative;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid var(--accent-purple);
    box-shadow: 0 0 35px rgba(168, 85, 247, 0.25), 0 15px 35px rgba(0,0,0,0.6);
}
.author-profile-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.88;
    transition: var(--transition-smooth);
}
.author-profile-wrapper:hover .author-profile-img {
    transform: scale(1.05);
}
.author-glow-halo {
    position: absolute;
    top: -20px;
    left: -20px;
    width: 340px;
    height: 340px;
    background: radial-gradient(circle, rgba(168, 85, 247, 0.18) 0%, rgba(0,0,0,0) 70%);
    filter: blur(40px);
    z-index: -1;
}

.author-meta-card {
    width: 300px;
    margin-top: 1.5rem;
    text-align: center;
}

/* Glowing Inline Links */
.inline-glow-link {
    color: var(--accent-purple);
    text-decoration: none;
    font-weight: 600;
    border-bottom: 1px dashed rgba(168, 85, 247, 0.4);
    transition: var(--transition-fast);
    padding-bottom: 1px;
}
.inline-glow-link:hover {
    color: var(--accent-pink);
    border-color: var(--accent-pink);
    text-shadow: 0 0 8px rgba(168, 85, 247, 0.5);
}

.about-right {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.story-heading {
    font-size: 2.1rem;
    margin-bottom: 1.2rem;
    color: var(--accent-lavender);
}

.story-text {
    line-height: 1.75;
    color: var(--text-sand);
    font-size: 1.02rem;
    margin-bottom: 1.5rem;
    font-weight: 300;
}

.reader-postcard {
    margin-top: 2rem;
    padding: 2.5rem;
    border-style: dashed;
    border-color: rgba(168, 85, 247, 0.22);
    background: rgba(168, 85, 247, 0.01);
}
.postcard-heading {
    font-family: var(--font-serif);
    font-size: 1.6rem;
    font-style: italic;
    color: var(--accent-pink);
    margin-bottom: 0.8rem;
}
.postcard-sig {
    font-family: var(--font-serif);
    font-size: 1.25rem;
    font-style: italic;
    color: var(--accent-purple);
    margin-top: 1.2rem;
    text-align: right;
}

/* About Connect Grid Styles */
.connect-link {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    background: rgba(168, 85, 247, 0.02);
    border: 1px solid rgba(168, 85, 247, 0.12);
    border-radius: 12px;
    padding: 0.9rem 1.1rem;
    text-decoration: none;
    transition: var(--transition-fast);
}
.connect-link:hover {
    background: rgba(168, 85, 247, 0.08);
    border-color: var(--accent-purple);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(168, 85, 247, 0.08);
}
.connect-icon {
    font-size: 1.4rem;
    color: var(--accent-purple);
}
.connect-label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-cream);
}
.connect-desc {
    display: block;
    font-size: 0.72rem;
    color: var(--text-muted);
}

/* Reviews Carousel Slider Refactor */
.reviews-carousel-wrapper {
    position: relative;
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 1.8rem;
    padding: 0 1rem;
}
.reviews-carousel-viewport {
    overflow: hidden;
    width: 100%;
    padding: 1rem 0.5rem 2.2rem;
}
.reviews-carousel-track {
    display: flex;
    gap: 2.25rem;
    transition: transform 0.75s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: transform;
}
.reviews-carousel-nav {
    background: rgba(168, 85, 247, 0.04);
    border: 1px solid rgba(168, 85, 247, 0.15);
    color: var(--text-cream);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    cursor: pointer;
    transition: var(--transition-fast);
    z-index: 10;
    flex-shrink: 0;
}
.reviews-carousel-nav:hover {
    background: var(--accent-purple);
    color: #020104;
    border-color: var(--accent-purple);
    box-shadow: 0 0 20px rgba(168, 85, 247, 0.4);
    transform: scale(1.05);
}
.reviews-carousel-dots {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 1rem;
    margin-bottom: 2rem;
}
.carousel-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: rgba(168, 85, 247, 0.18);
    cursor: pointer;
    transition: var(--transition-fast);
}
.carousel-dot.active {
    background: var(--accent-purple);
    width: 25px;
    border-radius: 12px;
    box-shadow: 0 0 10px rgba(168, 85, 247, 0.45);
}

/* Footer SVG Icon styles */
.footer-socials {
    display: flex;
    justify-content: center;
    gap: 2.2rem;
    margin-bottom: 3.5rem;
    align-items: center;
}
.social-icon-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: rgba(168, 85, 247, 0.03);
    border: 1px solid rgba(168, 85, 247, 0.1);
    color: var(--text-muted);
    transition: var(--transition-fast);
}
.social-icon-link:hover {
    color: var(--accent-purple);
    background: rgba(168, 85, 247, 0.08);
    border-color: var(--accent-purple);
    transform: translateY(-4px);
    box-shadow: 0 6px 20px rgba(168, 85, 247, 0.2);
}
.footer-svg-icon {
    width: 20px;
    height: 20px;
    fill: currentColor;
    transition: var(--transition-fast);
}

/* ==========================================
   7. DOWNLOAD SECTION & EMAIL HUB
   ========================================== */
.download-container {
    max-width: 950px;
    margin: 0 auto;
}

.download-layout {
    display: grid;
    grid-template-columns: 1fr 1.1fr;
    gap: 4rem;
    align-items: center;
}

.download-info h3 {
    font-size: 2.1rem;
    margin-bottom: 1.2rem;
    color: var(--accent-purple);
}

.download-form-card {
    padding: 3rem;
    border: 1px solid rgba(168, 85, 247, 0.22);
    box-shadow: 0 15px 45px rgba(0, 0, 0, 0.5), 0 0 30px rgba(168, 85, 247, 0.06);
    background: rgba(12, 8, 22, 0.55);
    transition: var(--transition-smooth);
}
.download-form-card:hover {
    border-color: rgba(168, 85, 247, 0.35);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6), 0 0 40px rgba(168, 85, 247, 0.12);
    transform: translateY(-4px);
}

/* Success Modal */
.success-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(2, 1, 4, 0.96);
    backdrop-filter: blur(28px);
    z-index: var(--z-modal);
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition-smooth);
}
.success-modal.active {
    opacity: 1;
    visibility: visible;
}

.success-content {
    max-width: 520px;
    padding: 3rem;
    text-align: center;
    transform: translateY(40px);
    transition: var(--transition-smooth);
}
.success-modal.active .success-content {
    transform: translateY(0);
}

.success-icon-wrap {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: rgba(168, 85, 247, 0.05);
    border: 1px solid var(--accent-purple);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.8rem;
    box-shadow: 0 0 15px rgba(168, 85, 247, 0.15);
}
.success-icon-wrap span {
    font-size: 1.8rem;
    color: var(--accent-purple);
}

.success-title {
    font-size: 2.1rem;
    margin-bottom: 0.8rem;
    color: var(--text-cream);
}
.success-text {
    font-size: 0.95rem;
    color: var(--text-sand);
    line-height: 1.65;
    margin-bottom: 2.2rem;
}

/* ==========================================
   8. VIRTUAL SIGNING SECTION (PREMIUM)
   ========================================== */
.signing-container {
    max-width: 1000px;
    margin: 0 auto;
}

.signing-card {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 3.5rem;
    align-items: center;
    position: relative;
    overflow: visible;
    border: 1px solid rgba(168, 85, 247, 0.25) !important;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.55), 0 0 35px rgba(168, 85, 247, 0.08) !important;
    background: rgba(12, 8, 22, 0.6) !important;
    transition: var(--transition-smooth);
}
.signing-card:hover {
    border-color: rgba(168, 85, 247, 0.4) !important;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.65), 0 0 45px rgba(168, 85, 247, 0.15) !important;
    transform: translateY(-4px);
}
.signing-card::after {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: inherit;
    background: linear-gradient(135deg, rgba(192, 132, 252, 0.18), transparent 38%, rgba(45, 212, 191, 0.12));
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.45s var(--ease-premium);
}
.signing-card:hover::after {
    opacity: 1;
}

.signing-badge {
    position: absolute;
    top: -15px;
    left: 40px;
    background: linear-gradient(135deg, var(--accent-purple), var(--accent-pink));
    color: #020104;
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    box-shadow: 0 4px 15px rgba(168, 85, 247, 0.25);
}

.signing-info h3 {
    font-size: 2.3rem;
    margin-bottom: 1rem;
}

.signing-price {
    font-family: var(--font-serif);
    font-size: 2.1rem;
    color: var(--accent-purple);
    margin-bottom: 1.2rem;
}
.signing-price span {
    font-size: 1rem;
    font-family: var(--font-sans);
    color: var(--text-muted);
}

.signing-scarcity-box {
    margin-bottom: 2.2rem;
}
.scarcity-label {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    color: var(--text-sand);
    margin-bottom: 0.5rem;
}
.scarcity-label span:last-child {
    color: var(--accent-purple);
    font-weight: 600;
}
.scarcity-bar {
    width: 100%;
    height: 4px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
    overflow: hidden;
}
.scarcity-progress {
    width: 34%;
    height: 100%;
    background: linear-gradient(to right, var(--accent-purple), var(--accent-pink));
    border-radius: 4px;
    transition: width 1s var(--ease-premium);
}

.payment-review-steps {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.65rem;
    margin: 0 0 1.35rem;
}
.payment-step {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.75rem;
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.018);
    opacity: 0.72;
    animation: step-rise 0.55s var(--ease-premium) both;
}
.payment-step:nth-child(2) {
    animation-delay: 0.08s;
}
.payment-step:nth-child(3) {
    animation-delay: 0.16s;
}
.payment-step.active {
    opacity: 1;
    border-color: rgba(45, 212, 191, 0.22);
    background: rgba(45, 212, 191, 0.035);
}
.payment-step-index {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    background: rgba(168, 85, 247, 0.13);
    color: var(--accent-lavender);
    font-size: 0.72rem;
    font-weight: 800;
}
.payment-step.active .payment-step-index {
    background: rgba(45, 212, 191, 0.16);
    color: #99f6e4;
}
.payment-step strong,
.payment-step span:last-child {
    display: block;
}
.payment-step strong {
    font-size: 0.72rem;
    color: var(--text-cream);
    line-height: 1.1;
}
.payment-step span:last-child {
    margin-top: 0.2rem;
    color: var(--text-muted);
    font-size: 0.64rem;
    line-height: 1.2;
}

/* File Receipt Uploader */
.file-upload-wrapper {
    margin-top: 1.5rem;
}

.file-upload-drag {
    display: block;
    border: 1px dashed rgba(168, 85, 247, 0.26);
    border-radius: 14px;
    padding: 2rem 1.25rem;
    text-align: center;
    background:
        radial-gradient(circle at 50% 0%, rgba(45, 212, 191, 0.06), transparent 46%),
        rgba(168, 85, 247, 0.018);
    cursor: pointer;
    transition: var(--transition-fast);
    position: relative;
    overflow: hidden;
    outline: 1px solid transparent;
}
.file-upload-drag::before {
    content: '';
    position: absolute;
    inset: 8px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.035);
    pointer-events: none;
}
.file-upload-drag:hover,
.file-upload-drag.drag-over {
    border-color: var(--accent-purple);
    background:
        radial-gradient(circle at 50% 0%, rgba(45, 212, 191, 0.10), transparent 48%),
        rgba(168, 85, 247, 0.04);
    transform: translateY(-2px);
    box-shadow: 0 16px 35px rgba(0, 0, 0, 0.24), 0 0 0 1px rgba(192, 132, 252, 0.08);
}
.file-upload-drag.has-file {
    border-style: solid;
    border-color: rgba(45, 212, 191, 0.42);
    background:
        radial-gradient(circle at 50% 0%, rgba(45, 212, 191, 0.13), transparent 48%),
        rgba(45, 212, 191, 0.035);
}
.file-upload-drag.is-invalid {
    border-color: rgba(248, 113, 113, 0.55);
    animation: receipt-shake 0.38s ease;
}

.upload-icon {
    width: 46px;
    height: 46px;
    margin: 0 auto 0.8rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    font-size: 1.45rem;
    color: #99f6e4;
    background: rgba(45, 212, 191, 0.11);
    border: 1px solid rgba(45, 212, 191, 0.18);
    transition: var(--transition-fast);
    animation: upload-float 2.6s ease-in-out infinite;
}
.file-upload-drag:hover .upload-icon {
    color: var(--accent-lavender);
    background: rgba(168, 85, 247, 0.16);
    border-color: rgba(168, 85, 247, 0.25);
}

.upload-text {
    display: block;
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text-sand);
    line-height: 1.35;
}
.upload-hint {
    display: block;
    max-width: 300px;
    margin: 0.5rem auto 0;
    font-size: 0.72rem;
    color: var(--text-muted);
    line-height: 1.45;
}
.upload-status-pill {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    padding: 0.28rem 0.48rem;
    border-radius: 999px;
    background: rgba(168, 85, 247, 0.12);
    border: 1px solid rgba(168, 85, 247, 0.15);
    color: var(--accent-lavender);
    font-size: 0.62rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}
.file-upload-drag.has-file .upload-status-pill {
    color: #99f6e4;
    background: rgba(45, 212, 191, 0.12);
    border-color: rgba(45, 212, 191, 0.2);
}

.receipt-preview-box {
    margin-top: 1rem;
    display: none;
    align-items: center;
    gap: 0.9rem;
    padding: 0.85rem 1rem;
    background: rgba(45, 212, 191, 0.035);
    border: 1px solid rgba(45, 212, 191, 0.12);
    border-radius: 12px;
    animation: preview-in 0.35s var(--ease-premium) both;
}
.receipt-preview-img {
    width: 46px;
    height: 46px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid rgba(45, 212, 191, 0.18);
}
.receipt-preview-details {
    flex-grow: 1;
}
.receipt-filename {
    font-size: 0.75rem;
    color: var(--text-cream);
    display: block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 140px;
}
.receipt-filesize {
    font-size: 0.65rem;
    color: var(--text-muted);
}
.receipt-remove-btn {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 1.1rem;
    transition: var(--transition-fast);
}
.receipt-remove-btn:hover {
    color: var(--accent-purple);
}

/* Instructions Slide-in Drawer */
.payment-drawer {
    position: fixed;
    top: 0;
    right: -450px;
    width: 420px;
    height: 100vh;
    background:
        linear-gradient(180deg, rgba(6, 4, 12, 0.99), rgba(2, 1, 4, 0.99)),
        radial-gradient(circle at top right, rgba(45, 212, 191, 0.06), transparent 38%);
    backdrop-filter: blur(25px);
    border-left: 1px solid var(--border-glow-focus);
    z-index: var(--z-modal);
    transition: right 0.5s var(--ease-premium);
    padding: 4rem 2.5rem;
    box-shadow: -20px 0 50px rgba(0,0,0,0.8);
    overflow-y: auto;
}
.payment-drawer.active {
    right: 0;
}
.payment-drawer.active > * {
    animation: drawer-content-in 0.55s var(--ease-premium) both;
}
.payment-drawer.active > *:nth-child(3) {
    animation-delay: 0.04s;
}
.payment-drawer.active > *:nth-child(4) {
    animation-delay: 0.08s;
}
.payment-drawer.active > *:nth-child(5) {
    animation-delay: 0.12s;
}
.payment-drawer.active > *:nth-child(6) {
    animation-delay: 0.16s;
}

.payment-details-card {
    padding: 1.5rem;
    border-radius: 12px;
    background: rgba(168, 85, 247, 0.015);
    border: 1px solid rgba(168, 85, 247, 0.06);
    margin-bottom: 1.8rem;
}

.bank-detail-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.8rem;
    font-size: 0.88rem;
    position: relative;
}
.bank-detail-row:last-child {
    margin: 0;
}
.bank-detail-row span:first-child {
    color: var(--text-muted);
}
.bank-detail-row span:last-child {
    color: var(--text-cream);
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition-fast);
}
.bank-detail-row span:last-child:hover {
    color: var(--accent-purple);
}

.payment-help-text {
    font-family: var(--font-sans);
    font-size: 0.8rem;
    color: var(--text-muted);
    text-align: center;
    margin-top: 1.5rem;
    line-height: 1.4;
}
.payment-help-text a {
    color: var(--accent-purple);
    text-decoration: none;
    border-bottom: 1px solid var(--border-glow-focus);
    padding-bottom: 1px;
    transition: var(--transition-fast);
}
.payment-help-text a:hover {
    color: var(--accent-pink);
    border-color: var(--accent-pink);
}

/* ==========================================
   9. SUPPORT THE AUTHOR SECTION
   ========================================== */
.support-section {
    text-align: center;
    padding-top: 2rem;
    padding-bottom: 5rem;
}

.support-card {
    max-width: 600px;
    margin: 0 auto;
    padding: 4.5rem 2.8rem;
}

.support-mug-wrapper {
    margin-bottom: 1.8rem;
    position: relative;
    display: inline-block;
}

.coffee-cup-svg {
    width: 65px;
    height: 65px;
    stroke: var(--accent-purple);
    stroke-width: 1.5;
    fill: none;
}

.coffee-fluid {
    fill: var(--accent-purple);
    transform: translateY(20px);
    transition: transform 0.6s var(--ease-premium);
}
.support-card:hover .coffee-fluid {
    transform: translateY(5px);
}

.support-title {
    font-size: 2.1rem;
    margin-bottom: 1rem;
    color: var(--accent-purple);
}

/* ==========================================
   10. FOOTER (REDESIGNED & MINIMAL)
   ========================================== */
.footer-section {
    background: rgba(2, 1, 3, 0.4);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid rgba(168, 85, 247, 0.06);
    padding: 3rem 2rem;
    margin-top: 4rem;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.8rem;
}

.footer-top {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    width: 100%;
}

.footer-brand {
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    background: linear-gradient(135deg, var(--text-cream) 40%, var(--accent-purple) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.footer-socials {
    display: flex;
    justify-content: center;
    gap: 1.8rem;
    margin: 0;
}

.social-icon-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: rgba(168, 85, 247, 0.02);
    border: 1px solid rgba(168, 85, 247, 0.08);
    color: var(--text-muted);
    transition: var(--transition-fast);
}
.social-icon-link:hover {
    color: var(--accent-purple);
    background: rgba(168, 85, 247, 0.08);
    border-color: var(--accent-purple);
    transform: translateY(-3px);
    box-shadow: 0 0 15px rgba(168, 85, 247, 0.25);
}

.footer-svg-icon {
    width: 18px;
    height: 18px;
    fill: currentColor;
    transition: var(--transition-fast);
}

.footer-bottom {
    width: 100%;
    border-top: 1px solid rgba(168, 85, 247, 0.06);
    padding-top: 1.5rem;
    display: flex;
    justify-content: center;
    align-items: center;
}

.footer-meta {
    font-family: var(--font-sans);
    font-size: 0.72rem;
    color: var(--text-muted);
    font-weight: 300;
    letter-spacing: 0.03em;
}

/* Copy notification toast */
.toast-alert {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translate(-50%, 100px);
    background: rgba(10, 6, 18, 0.95);
    border: 1px solid var(--accent-purple);
    backdrop-filter: blur(10px);
    border-radius: 50px;
    padding: 0.7rem 1.8rem;
    color: var(--text-cream);
    font-size: 0.8rem;
    z-index: 2000;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 8px 20px rgba(0,0,0,0.5);
    pointer-events: none;
}
.toast-alert.active {
    transform: translate(-50%, 0);
}

/* ==========================================
   INTERSECTION OBSERVATIONS REVEALS
   ========================================== */
.reveal-item {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 1s var(--ease-premium), transform 1s var(--ease-premium);
}
.reveal-item.revealed {
    opacity: 1;
    transform: translateY(0);
}

.delay-100 { transition-delay: 0.1s; }
.delay-200 { transition-delay: 0.2s; }
.delay-300 { transition-delay: 0.3s; }

/* ==========================================
   MOBILE RESPONSIVENESS
   ========================================== */
@media (max-width: 1024px) {
    .navbar {
        padding: 1.2rem 2rem;
    }
    
    .hero-section {
        padding-top: 7rem;
        align-items: center;
        text-align: center;
    }
    
    /* Using contents display to let children of .hero-left participate in .hero-grid order */
    .hero-left {
        display: contents;
    }
    
    .hero-grid {
        display: flex;
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 2rem;
        width: 100%;
    }
    
    /* Mobile hero layout order stack: Title -> Book cover -> Description/Author -> Stats -> Buttons */
    .hero-title {
        order: 1;
        font-size: 3.2rem;
        text-align: center;
        margin-bottom: 1.2rem;
        width: 100%;
    }
    
    .hero-right {
        order: 2;
        display: flex;
        justify-content: center;
        align-items: center;
        margin-bottom: 2rem;
        width: 100%;
    }
    
    .hero-author-name {
        order: 3;
        font-size: 1.3rem;
        margin-bottom: 0.3rem;
        display: block;
    }
    
    .hero-pages-count {
        order: 4;
        font-size: 0.78rem;
        margin-bottom: 1.5rem;
        display: block;
    }
    
    .hero-description {
        order: 5;
        font-size: 1.05rem;
        line-height: 1.7;
        margin-bottom: 2rem;
        max-width: 520px;
        text-align: center;
    }
    
    .hero-stats-row {
        order: 6;
        display: flex;
        justify-content: center;
        gap: 1.5rem;
        margin-bottom: 2.2rem;
        width: fit-content;
        max-width: 100%;
    }
    
    .hero-ctas {
        order: 7;
        display: flex;
        justify-content: center;
        gap: 0.8rem;
        flex-wrap: wrap;
        width: 100%;
    }
    
    .about-grid {
        grid-template-columns: 1fr;
        gap: 3.5rem;
        text-align: center;
    }
    
    .about-left {
        margin: 0 auto;
    }
    
    .about-right {
        align-items: center;
    }
    
    .download-layout {
        grid-template-columns: 1fr;
        gap: 2.5rem;
        text-align: center;
    }
    
    .signing-card {
        grid-template-columns: 1fr;
        gap: 2.5rem;
        text-align: center;
    }
    .signing-badge {
        left: 50%;
        transform: translateX(-50%);
    }
    .scarcity-label {
        width: 85%;
        margin: 0 auto 0.5rem;
    }
    .scarcity-bar {
        width: 85%;
        margin: 0 auto;
    }
    .file-upload-drag {
        width: 85%;
        margin: 0 auto;
    }
    .receipt-preview-box {
        width: 85%;
        margin: 1rem auto 0;
    }
    
    .review-card {
        flex: 0 0 calc((100% - 2.25rem) / 2) !important;
    }
}

@media (max-width: 768px) {
    section {
        padding: 4.5rem 1.2rem;
    }
    .section-title {
        font-size: 2.1rem;
    }
    .hero-title {
        font-size: 2.6rem;
    }
    .lesson-quote {
        font-size: 1.55rem;
    }
    .lesson-card {
        padding: 4rem 1.5rem;
    }
    .quote-icon {
        left: 1.2rem;
        font-size: 5rem;
    }
    .review-write-overlay,
    .payment-drawer {
        width: 100vw;
        right: -100vw;
    }
    .payment-review-steps {
        grid-template-columns: 1fr;
    }
    .payment-step {
        justify-content: flex-start;
    }
    .review-card {
        flex: 0 0 100% !important;
    }
    .reviews-carousel-wrapper {
        gap: 0.5rem;
        padding: 0;
    }
    .reviews-carousel-nav {
        display: none !important;
    }
    .connect-grid {
        grid-template-columns: 1fr !important;
    }
    
    .author-profile-wrapper {
        width: 250px;
        height: 250px;
    }
    .author-glow-halo {
        width: 290px;
        height: 290px;
    }
}

@media (max-width: 768px) {
    .hero-right {
        transform: scale(0.85);
        transform-origin: center center;
        margin-bottom: 1rem;
    }
}
@media (max-width: 480px) {
    .hero-right {
        transform: scale(0.72);
        transform-origin: center center;
        margin-bottom: 0.5rem;
    }
}

@keyframes upload-spin {
    to { transform: rotate(360deg); }
}

@keyframes stat-sheen {
    0%, 62% { transform: translateX(-120%); }
    100% { transform: translateX(120%); }
}

@keyframes upload-float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-4px); }
}

@keyframes receipt-shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-6px); }
    75% { transform: translateX(6px); }
}

@keyframes preview-in {
    from {
        opacity: 0;
        transform: translateY(8px) scale(0.98);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes drawer-content-in {
    from {
        opacity: 0;
        transform: translateX(18px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes step-rise {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
