/* ============================================
   A WRITER'S THOUGHTS - PAGE-SPECIFIC STYLES
   Additional styles for individual pages
   ============================================ */

/* ==================== BOOKS PAGE ==================== */
.books-hero {
    padding-top: 150px;
    padding-bottom: var(--space-4xl);
    background: linear-gradient(180deg, var(--color-void) 0%, var(--color-abyss) 100%);
    text-align: center;
}

.books-hero h1 {
    margin-bottom: var(--space-lg);
}

.series-section {
    padding: var(--space-4xl) 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.series-section:last-child {
    border-bottom: none;
}

.series-header {
    display: flex;
    align-items: center;
    gap: var(--space-lg);
    margin-bottom: var(--space-2xl);
}

.series-header::before,
.series-header::after {
    content: '';
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--color-gold), transparent);
}

.series-title {
    font-family: var(--font-display);
    color: var(--color-gold);
    font-size: var(--text-2xl);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

/* Single Book Detail Page */
.book-detail-hero {
    padding-top: 120px;
    min-height: 80vh;
    display: flex;
    align-items: center;
}

.book-detail-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: var(--space-4xl);
    align-items: start;
}

.book-cover-3d {
    perspective: 1000px;
}

.book-cover-wrapper {
    transform-style: preserve-3d;
    transition: transform 0.6s ease;
}

.book-cover-wrapper:hover {
    transform: rotateY(-15deg) rotateX(5deg);
}

.book-cover-image {
    width: 100%;
    max-width: 400px;
    box-shadow:
        0 30px 60px rgba(0, 0, 0, 0.5),
        10px 10px 30px rgba(0, 0, 0, 0.3);
    border-radius: var(--radius-sm);
}

.book-info h1 {
    font-size: var(--text-4xl);
    margin-bottom: var(--space-sm);
}

.book-series-tag {
    display: inline-block;
    background: var(--gradient-mystic);
    color: var(--color-void);
    padding: var(--space-xs) var(--space-md);
    border-radius: var(--radius-full);
    font-size: var(--text-sm);
    font-weight: 500;
    margin-bottom: var(--space-lg);
}

.book-synopsis {
    font-size: var(--text-lg);
    line-height: 1.9;
    margin-bottom: var(--space-2xl);
}

.book-buy-options {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-md);
    margin-bottom: var(--space-2xl);
}

.buy-option {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    padding: var(--space-sm) var(--space-lg);
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-md);
    color: var(--color-moonlight);
    transition: var(--transition-base);
}

.buy-option:hover {
    background: rgba(212, 175, 55, 0.1);
    border-color: var(--color-gold);
    color: var(--color-gold);
}

.buy-option img {
    width: 24px;
    height: 24px;
}

/* ==================== WORLD/EL'ANTHAR PAGE ==================== */
.world-hero {
    padding-top: 150px;
    padding-bottom: var(--space-4xl);
    text-align: center;
    background:
        radial-gradient(ellipse at center bottom, rgba(123, 92, 255, 0.1), transparent 50%),
        var(--gradient-night);
}

.world-intro {
    max-width: 800px;
    margin: 0 auto;
    font-size: var(--text-lg);
    font-style: italic;
    color: var(--color-silver);
}

.world-map-section {
    padding: var(--space-4xl) 0;
    position: relative;
}

.interactive-map {
    position: relative;
    max-width: 1000px;
    margin: 0 auto;
}

.map-image {
    width: 100%;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
}

.map-hotspot {
    position: absolute;
    width: 40px;
    height: 40px;
    background: rgba(212, 175, 55, 0.3);
    border: 2px solid var(--color-gold);
    border-radius: 50%;
    cursor: pointer;
    transition: var(--transition-base);
    animation: glowPulse 2s infinite;
}

.map-hotspot:hover {
    transform: scale(1.3);
    background: var(--color-gold);
}

.map-hotspot::after {
    content: attr(data-label);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: var(--color-shadow);
    color: var(--color-starlight);
    padding: var(--space-xs) var(--space-sm);
    border-radius: var(--radius-sm);
    font-size: var(--text-xs);
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition-base);
}

.map-hotspot:hover::after {
    opacity: 1;
    visibility: visible;
    bottom: calc(100% + 10px);
}

/* Lore Categories Filter */
.lore-filters {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: var(--space-sm);
    margin-bottom: var(--space-3xl);
}

.filter-btn {
    padding: var(--space-sm) var(--space-lg);
    background: transparent;
    border: 1px solid var(--color-twilight);
    border-radius: var(--radius-full);
    color: var(--color-silver);
    font-family: var(--font-display);
    font-size: var(--text-sm);
    cursor: pointer;
    transition: var(--transition-base);
}

.filter-btn:hover,
.filter-btn.active {
    background: var(--color-gold);
    border-color: var(--color-gold);
    color: var(--color-void);
}

/* ==================== SHOP PAGE ==================== */
.shop-hero {
    padding-top: 150px;
    padding-bottom: var(--space-4xl);
    text-align: center;
    background:
        url('../assets/images/shop-banner.jpg') center/cover no-repeat,
        var(--color-void);
    position: relative;
}

.shop-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(10, 11, 15, 0.85);
}

.shop-hero .container {
    position: relative;
    z-index: 1;
}

.shop-categories {
    display: flex;
    justify-content: center;
    gap: var(--space-lg);
    margin-top: var(--space-2xl);
}

.category-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    text-align: center;
    min-width: 150px;
    transition: var(--transition-base);
}

.category-card:hover {
    background: rgba(212, 175, 55, 0.1);
    border-color: var(--color-gold);
    transform: translateY(-5px);
}

.category-icon {
    font-size: 2rem;
    margin-bottom: var(--space-sm);
}

.cart-indicator {
    position: fixed;
    bottom: var(--space-xl);
    right: var(--space-xl);
    width: 60px;
    height: 60px;
    background: var(--gradient-mystic);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-arcane);
    cursor: pointer;
    transition: var(--transition-base);
    z-index: var(--z-fixed);
}

.cart-indicator:hover {
    transform: scale(1.1);
}

.cart-indicator svg {
    width: 28px;
    height: 28px;
    fill: var(--color-void);
}

.cart-count {
    position: absolute;
    top: -5px;
    right: -5px;
    width: 22px;
    height: 22px;
    background: var(--color-crimson);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--text-xs);
    font-weight: 700;
    color: white;
}

/* ==================== MEMBERSHIP PAGE ==================== */
.membership-hero {
    padding-top: 150px;
    padding-bottom: var(--space-4xl);
    text-align: center;
    background:
        radial-gradient(ellipse at center, rgba(212, 175, 55, 0.1), transparent 60%),
        var(--gradient-night);
}

.membership-benefits {
    padding: var(--space-4xl) 0;
    background: var(--color-abyss);
}

.benefits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--space-xl);
}

.benefit-card {
    text-align: center;
    padding: var(--space-2xl);
}

.benefit-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto var(--space-lg);
    background: linear-gradient(135deg, var(--color-shadow), var(--color-dusk));
    border: 1px solid rgba(212, 175, 55, 0.3);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
}

.benefit-icon svg {
    width: 40px;
    height: 40px;
    stroke: var(--color-gold);
}

.benefit-card h4 {
    margin-bottom: var(--space-sm);
}

/* ==================== JOURNAL PAGE ==================== */
.journal-hero {
    padding-top: 150px;
    min-height: 60vh;
    display: flex;
    align-items: center;
    background:
        linear-gradient(180deg, transparent, var(--color-abyss)),
        url('../assets/images/journal-hero.jpg') center/cover no-repeat;
}

.journal-hero h1 {
    margin-bottom: var(--space-lg);
}

.featured-post {
    background: linear-gradient(135deg, var(--color-shadow), var(--color-dusk));
    border-radius: var(--radius-xl);
    overflow: hidden;
    margin-bottom: var(--space-4xl);
}

.featured-post-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
}

.featured-post-image {
    height: 100%;
    min-height: 400px;
    object-fit: cover;
}

.featured-post-content {
    padding: var(--space-3xl);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.featured-badge {
    display: inline-block;
    background: var(--color-gold);
    color: var(--color-void);
    padding: var(--space-xs) var(--space-md);
    border-radius: var(--radius-full);
    font-size: var(--text-xs);
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    margin-bottom: var(--space-lg);
    width: fit-content;
}

/* ==================== NEWSLETTER PAGE ==================== */
.newsletter-hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--space-4xl) 0;
    background:
        radial-gradient(ellipse at center, rgba(123, 92, 255, 0.15), transparent 50%),
        var(--gradient-night);
}

.newsletter-card {
    max-width: 600px;
    background: linear-gradient(135deg, rgba(26, 29, 40, 0.9), rgba(37, 41, 54, 0.9));
    border: 1px solid rgba(212, 175, 55, 0.2);
    border-radius: var(--radius-xl);
    padding: var(--space-4xl);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.newsletter-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gradient-mystic);
}

.newsletter-icon {
    width: 100px;
    height: 100px;
    margin: 0 auto var(--space-xl);
    background: var(--gradient-mystic);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.newsletter-icon svg {
    width: 50px;
    height: 50px;
    fill: var(--color-void);
}

.newsletter-perks {
    list-style: none;
    margin: var(--space-2xl) 0;
    text-align: left;
}

.newsletter-perks li {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    padding: var(--space-sm) 0;
    color: var(--color-silver);
}

.newsletter-perks li::before {
    content: '✦';
    color: var(--color-gold);
}

/* ==================== MODALS ==================== */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(10, 11, 15, 0.9);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--space-xl);
    z-index: var(--z-modal);
    opacity: 0;
    visibility: hidden;
    transition: var(--transition-base);
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal {
    background: var(--color-shadow);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-xl);
    max-width: 800px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    transform: translateY(30px);
    transition: var(--transition-base);
}

.modal-overlay.active .modal {
    transform: translateY(0);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--space-xl);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.modal-close {
    width: 44px;
    height: 44px;
    background: rgba(255, 255, 255, 0.05);
    border: none;
    border-radius: 50%;
    color: var(--color-moonlight);
    cursor: pointer;
    transition: var(--transition-base);
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    background: var(--color-crimson);
}

.modal-body {
    padding: var(--space-xl);
}

/* ==================== BACK TO TOP ==================== */
.back-to-top {
    position: fixed;
    bottom: var(--space-xl);
    right: var(--space-xl);
    width: 50px;
    height: 50px;
    background: var(--color-shadow);
    border: 1px solid var(--color-gold);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition-base);
    z-index: var(--z-fixed);
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background: var(--color-gold);
    transform: translateY(-3px);
}

.back-to-top svg {
    width: 24px;
    height: 24px;
    stroke: var(--color-gold);
    transition: var(--transition-base);
}

.back-to-top:hover svg {
    stroke: var(--color-void);
}

/* ==================== 404 PAGE ==================== */
.error-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: var(--space-xl);
}

.error-code {
    font-size: clamp(8rem, 20vw, 15rem);
    font-family: var(--font-display);
    background: var(--gradient-mystic);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1;
    margin-bottom: var(--space-lg);
}

.error-message {
    font-size: var(--text-2xl);
    margin-bottom: var(--space-xl);
}

/* ==================== PAGE-SPECIFIC RESPONSIVE ==================== */
@media screen and (max-width: 768px) {
    .book-detail-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .book-cover-image {
        max-width: 280px;
        margin: 0 auto;
    }

    .book-buy-options {
        justify-content: center;
    }

    .featured-post-grid {
        grid-template-columns: 1fr;
    }

    .featured-post-image {
        min-height: 250px;
    }

    .featured-post-content {
        padding: var(--space-xl);
    }

    .featured-post-content h2 {
        font-size: var(--text-xl);
    }

    .shop-categories {
        flex-wrap: wrap;
    }

    .cart-indicator {
        bottom: var(--space-lg);
        right: var(--space-lg);
        width: 50px;
        height: 50px;
    }
}

/* Small mobile devices */
@media screen and (max-width: 575px) {
    .featured-post {
        margin-bottom: var(--space-2xl);
    }

    .featured-post-image {
        min-height: 200px;
    }

    .featured-post-content {
        padding: var(--space-lg);
    }

    .featured-post-content h2 {
        font-size: var(--text-lg);
        line-height: 1.4;
    }

    .featured-post-content p {
        font-size: var(--text-base) !important;
    }

    .featured-badge {
        font-size: 0.65rem;
        padding: var(--space-xs) var(--space-sm);
    }

    .post-category {
        font-size: var(--text-xs);
    }
}