/* =========================================
   1. GLOBAL RESET & BASE VARS
   ========================================= */
html {
    font-size: 100%;
    -webkit-text-size-adjust: 100%; 
    scroll-behavior: smooth;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

:root {
    --bg-color: #FFFFFF;
    --text-color: #111111;
    --border-color: #EAEAEA; 
    --kodansha-black: #000000; 
    --hover-gray: #888888; 
}

/* =========================================
   CUSTOM TEXT SELECTION
   ========================================= */
::selection { background-color: var(--kodansha-black); color: var(--bg-color); }
::-moz-selection { background-color: var(--kodansha-black); color: var(--bg-color); }

.site-footer ::selection, .site-footer *::selection { background-color: var(--bg-color); color: var(--kodansha-black); }
.site-footer ::-moz-selection, .site-footer *::-moz-selection { background-color: var(--bg-color); color: var(--kodansha-black); }

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    padding: 0; 
    line-height: 1.6;
    overflow-x: hidden; 
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

a:focus-visible, button:focus-visible {
    outline: 0.125rem solid var(--hover-gray);
    outline-offset: 0.125rem;
}

/* =========================================
   2. TOP NAVIGATION
   ========================================= */
.top-nav {
    position: sticky;
    top: 1rem; 
    z-index: 1000; 
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 0.125rem solid var(--kodansha-black); 
    padding: 1rem 1.5rem; 
    background-color: var(--bg-color);
    margin: 1rem 1.5vw 3rem 1.5vw; 
}

.nav-left { display: flex; align-items: center; }

.logo-text {
    font-size: 1.4rem; 
    font-weight: 800; 
    letter-spacing: 0.05rem;
    color: var(--kodansha-black);
}

.nav-right { display: flex; align-items: center; gap: 2rem; }
.nav-links { list-style: none; display: flex; gap: 0.875rem; }

.nav-links li a {
    position: relative;
    text-decoration: none;
    color: var(--kodansha-black);
    font-weight: 500; 
    font-size: 1.25rem; 
    padding-bottom: 0.25rem; 
    transition: color 0.25s ease-out; 
}

.nav-links li a::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 0.125rem;
    bottom: 0;
    left: 0;
    background-color: var(--kodansha-black);
    transform: scaleX(0);
    transform-origin: bottom right;
    transition: transform 0.25s ease-out, background-color 0.25s ease-out;
}

.nav-links li a:hover { color: var(--hover-gray); }
.nav-links li a:hover::after {
    transform: scaleX(1);
    transform-origin: bottom left;
    background-color: var(--hover-gray);
}

.nav-actions { display: flex; gap: 0.625rem; }

.btn-action {
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: var(--kodansha-black);
    border: 0.125rem solid var(--kodansha-black);
    padding: 0.375rem 0.875rem;
    font-size: 0.75rem; 
    font-weight: 700;
    letter-spacing: 0.12rem; 
    text-transform: uppercase;
    transition: all 0.2s ease;
}

.btn-action:hover {
    background-color: var(--kodansha-black);
    border-color: var(--kodansha-black);
    color: var(--bg-color);
}

/* =========================================
   3. HERO & BENTO DASHBOARD
   ========================================= */
.hero {
    padding: 6rem 3rem 4rem 3rem;
    max-width: 75rem;
    margin: 0 auto;
    width: 100%;
}

.hero h1 { font-size: 3rem; font-weight: 600; letter-spacing: -0.02rem; max-width: 50rem; line-height: 1.2; }
.hero h2 { font-size: 1.1rem; font-weight: 400; color: #666666; margin-top: 1rem; letter-spacing: 0.02rem; line-height: 1.6; max-width: 45rem; }

.bento-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-auto-rows: 15rem;
    gap: 1rem;
    max-width: 75rem;
    margin: 0 auto 6rem auto;
    padding: 0 3rem;
    width: 100%; 
}

.bento-card {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    text-decoration: none;
    color: var(--text-color);
    border: 0.0625rem solid var(--border-color);
    background-color: var(--bg-color);
    padding: 2rem;
    transition: border-color 0.2s ease, transform 0.2s ease;
}

.card-content h2 { font-size: 1.1rem; font-weight: 600; margin-bottom: 0.25rem; }
.card-content p { font-size: 0.85rem; color: #666666; }

.card-large { grid-row: span 2; }
.card-large-wide { grid-column: span 2; }
.card-full-wide { grid-column: 1 / -1; }

.bento-card:hover { border-color: #4A5C6A; transform: translateY(-0.125rem); }

/* =========================================
   BENTO CARD MINI PREVIEWS
   ========================================= */
.library-card-special {
    position: relative;
    overflow: hidden; 
}

.mini-manga-stack {
    display: flex;
    align-items: flex-end;
    justify-content: flex-end; 
    width: 100%;
    margin-top: 1rem;
    padding-right: 2rem; 
    padding-bottom: 0.5rem;
}

.mini-manga {
    width: 4.5rem; 
    height: auto;
    border-radius: 4px; 
    position: relative; 
    box-sizing: border-box; 
    border: 1px solid transparent; 
    box-shadow: 4px 0 10px rgba(0, 0, 0, 0.15); 
    flex-shrink: 0;
    
    /* Removed the pixelating crisp-edges code. Returned to smooth rendering. */
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    filter: contrast(1.02) saturate(1.05);
    will-change: transform, margin, border-color, box-shadow;

    transition: transform 0.7s cubic-bezier(0.22, 1, 0.36, 1), 
                margin 0.7s cubic-bezier(0.22, 1, 0.36, 1), 
                border-color 0.3s ease, 
                box-shadow 0.7s cubic-bezier(0.22, 1, 0.36, 1);
    cursor: pointer;
}

/* Organic Base State */
.mini-manga:nth-child(1) { z-index: 5; transform: rotate(-3deg) translateY(2px); }
.mini-manga:nth-child(2) { z-index: 4; transform: rotate(1deg) translateY(-1px); }
.mini-manga:nth-child(3) { z-index: 3; transform: rotate(-2deg) translateY(3px); }
.mini-manga:nth-child(4) { z-index: 2; transform: rotate(2deg) translateY(0px); }
.mini-manga:nth-child(5) { z-index: 1; transform: rotate(-1deg) translateY(2px); }

.mini-manga:not(:first-child) { margin-left: -2.7rem; }

/* Hover Spread */
.library-card-special:hover .mini-manga:not(:first-child) { margin-left: -0.5rem; }

.library-card-special:hover .mini-manga:nth-child(1) { transform: rotate(-4deg) translateY(0); }
.library-card-special:hover .mini-manga:nth-child(2) { transform: rotate(-2deg) translateY(0); }
.library-card-special:hover .mini-manga:nth-child(3) { transform: rotate(0deg) translateY(0); }
.library-card-special:hover .mini-manga:nth-child(4) { transform: rotate(2deg) translateY(0); }
.library-card-special:hover .mini-manga:nth-child(5) { transform: rotate(4deg) translateY(0); }

/* Individual Book Focus */
.library-card-special .mini-manga:nth-child(odd):hover {
    transform: translate(0.25rem, -1.2rem) rotate(-3deg) scale(1.05) !important;
    z-index: 10 !important; 
    border-color: var(--kodansha-black); 
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.3);
}

.library-card-special .mini-manga:nth-child(even):hover {
    transform: translate(0.25rem, -1.2rem) rotate(3deg) scale(1.05) !important;
    z-index: 10 !important; 
    border-color: var(--kodansha-black); 
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.3);
}

/* =========================================
   MAXIMUM IMAGE PROTECTION
   ========================================= */
.protected-img {
    -webkit-user-drag: none !important;
    user-select: none !important;
    -moz-user-select: none !important;
    -webkit-user-select: none !important;
    -ms-user-select: none !important;
    pointer-events: auto; /* Crucial: Keeps the hover state working */
}

/* =========================================
   PREMIUM EASTER EGG GLINT ENGINE (DELAYED & RARE BLUE)
   ========================================= */
/* Base architecture for the localized light burst */
.library-card-special::after {
    content: "✦";
    position: absolute;
    color: #FFFFFF; 
    opacity: 0;
    pointer-events: none; 
    z-index: 100;
    text-shadow: 0 0 12px rgba(255, 255, 255, 1), 0 0 25px rgba(255, 255, 255, 0.8);
    will-change: transform, opacity;
}

/* 
  MASSIVE DELAY INCREASE: 
  Timers are now pushed to 2.5s - 3.5s. 
  You MUST hold the hover peacefully to earn the Easter Egg.
*/

/* Book 1 (Your Lie in April - Far Left) */
.library-card-special:has(.mini-manga:nth-child(1):hover)::after {
    right: 20rem; bottom: 4.5rem;
    font-size: 1.2rem;
    animation: easter-glint-1 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) 2.8s forwards;
}

/* Book 2 (Blue Box - THE RARE BLUE SPARKLE) */
.library-card-special:has(.mini-manga:nth-child(2):hover)::after {
    right: 15rem; bottom: 5.5rem;
    font-size: 1.8rem; 
    color: #88CCFF; /* Ice Blue */
    text-shadow: 0 0 15px rgba(136, 204, 255, 1), 0 0 30px rgba(0, 119, 255, 0.9);
    animation: easter-glint-2 0.7s cubic-bezier(0.34, 1.56, 0.64, 1) 3.5s forwards;
}

/* Book 3 (Kubo) */
.library-card-special:has(.mini-manga:nth-child(3):hover)::after {
    right: 11.5rem; bottom: 3.5rem;
    font-size: 0.9rem; 
    animation: easter-glint-3 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) 2.5s forwards;
}

/* Book 4 (Kaguya-sama) */
.library-card-special:has(.mini-manga:nth-child(4):hover)::after {
    right: 7.5rem; bottom: 6.5rem;
    font-size: 1.4rem;
    animation: easter-glint-4 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) 3.2s forwards;
}

/* Book 5 (Spy x Family - Far Right) */
.library-card-special:has(.mini-manga:nth-child(5):hover)::after {
    right: 3.5rem; bottom: 4rem;
    font-size: 1.1rem;
    animation: easter-glint-5 0.55s cubic-bezier(0.34, 1.56, 0.64, 1) 2.9s forwards;
}

/* 
  REFINED BEAUTIFUL ANIMATIONS:
  Slightly longer duration, softer fade, and an elegant elastic spin.
*/
@keyframes easter-glint-1 {
    0% { opacity: 0; transform: scale(0) rotate(-45deg); }
    40% { opacity: 1; transform: scale(1.2) rotate(45deg); }
    100% { opacity: 0; transform: scale(0) rotate(135deg); }
}

@keyframes easter-glint-2 {
    0% { opacity: 0; transform: scale(0) rotate(0deg); filter: brightness(1); }
    40% { opacity: 1; transform: scale(1.3) rotate(90deg); filter: brightness(1.5); }
    100% { opacity: 0; transform: scale(0) rotate(180deg); filter: brightness(1); }
}

@keyframes easter-glint-3 {
    0% { opacity: 0; transform: scale(0) rotate(30deg); }
    40% { opacity: 1; transform: scale(1.5) rotate(120deg); }
    100% { opacity: 0; transform: scale(0) rotate(210deg); }
}

@keyframes easter-glint-4 {
    0% { opacity: 0; transform: scale(0) rotate(-90deg); }
    40% { opacity: 1; transform: scale(1.1) rotate(0deg); }
    100% { opacity: 0; transform: scale(0) rotate(90deg); }
}

@keyframes easter-glint-5 {
    0% { opacity: 0; transform: scale(0) rotate(15deg); }
    40% { opacity: 1; transform: scale(1.3) rotate(105deg); }
    100% { opacity: 0; transform: scale(0) rotate(195deg); }
}

/* =========================================
   DYNAMIC HOVER TITLES (HTML-BASED MULTILINGUAL FIX)
   ========================================= */
.dynamic-book-title {
    color: var(--hover-gray);
    margin-left: 0.25rem;
    position: absolute;
    pointer-events: none;
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    
    /* THE FIX: Hide the entire container (including the dash) by default */
    opacity: 0;
    transition: opacity 0.3s ease;
}

/* THE FIX: Fade in the entire container when ANY book is hovered */
.library-card-special:has(.mini-manga:hover) .dynamic-book-title {
    opacity: 1;
}

.book-title {
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
    white-space: nowrap;
}

/* Activate the correct title when a specific book is hovered */
.library-card-special:has(.mini-manga:nth-child(1):hover) .title-1,
.library-card-special:has(.mini-manga:nth-child(2):hover) .title-2,
.library-card-special:has(.mini-manga:nth-child(3):hover) .title-3,
.library-card-special:has(.mini-manga:nth-child(4):hover) .title-4,
.library-card-special:has(.mini-manga:nth-child(5):hover) .title-5 {
    display: inline-block;
    opacity: 1;
}

/* Pure Japanese Base Reset - Isolates it from the English fonts */
.jp {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif !important;
    font-weight: 400 !important;
    font-size: 0.9rem !important;
    letter-spacing: normal !important;
    vertical-align: baseline;
}

/* Individual English Stylings */
.title-1 .eng { font-family: 'Caveat', cursive; font-weight: 700; font-size: 1.15rem; display: inline-block; transform: translateY(0.12rem); }
.title-2 .eng { font-family: 'Fredoka', sans-serif; font-weight: 600; font-size: 0.9rem; letter-spacing: -0.02rem; }
.title-3 .eng { font-family: 'Sniglet', cursive; font-weight: 400; font-size: 0.9rem; }
.title-4 .eng { font-family: 'Teko', sans-serif; font-weight: 600; font-size: 1.1rem; letter-spacing: 0.05rem; display: inline-block; transform: translateY(0.08rem); }
.title-5 .eng { font-family: 'Bebas Neue', sans-serif; font-weight: 400; font-size: 1.05rem; letter-spacing: 0.05rem; display: inline-block; transform: translateY(0.08rem); }

/* =========================================
   SHOP BENTO CARD (CREATOR AVATARS)
   ========================================= */
.shop-card-special {
    position: relative;
    overflow: hidden; 
}

.shop-creator-avatars {
    display: flex;
    align-items: flex-end;
    justify-content: flex-end; 
    width: 100%;
    margin-top: 1rem;
    padding-right: 1.5rem; 
    padding-bottom: 0.5rem;
}

/* Enforcing the Perfect Circle & Apple-Style Fluid Physics */
.creator-avatar {
    width: 3.5rem; 
    height: 3.5rem;
    border-radius: 50%; 
    object-fit: cover; 
    
    position: relative;
    border: 0.12rem solid var(--bg-color); 
    
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1); 
    background-color: var(--border-color);
    
    /* Hardware acceleration to force the browser to render this at 60fps */
    will-change: transform, box-shadow, border-color;
    
    /* THE FIX: True iPhone-style fluid animation curve */
    transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1), 
                box-shadow 0.8s cubic-bezier(0.16, 1, 0.3, 1),
                border-color 0.5s ease-out;
    cursor: pointer;
}

/* Organic Base State */
.creator-avatar:nth-child(1) {
    /* THE Z-INDEX FIX: Left logo reverted back to the top */
    z-index: 2; 
    transform: rotate(-2deg);
}

.creator-avatar:nth-child(2) {
    margin-left: -1.2rem; 
    transform: translateY(-4px) rotate(2deg); 
    /* THE Z-INDEX FIX: Right logo tucked underneath again */
    z-index: 1; 
}

/* Base Card Hover: Gentle Separation */
.shop-card-special:hover .creator-avatar:nth-child(1) {
    transform: translateX(-0.4rem) rotate(-5deg);
}

.shop-card-special:hover .creator-avatar:nth-child(2) {
    transform: translateX(0.4rem) translateY(-4px) rotate(5deg);
}

/* =========================================
   INDIVIDUAL AVATAR HOVER (PERSONALIZED COLORS)
   ========================================= */
/* Base Hover Physics */
.shop-card-special .creator-avatar:hover {
    z-index: 10 !important; 
    transform: translateY(-8px) rotate(0deg) !important; 
}

/* 1. Cosy Tales Art Studios - Warm Pastel Yellow Glow */
.shop-card-special .creator-avatar:nth-child(1):hover {
    border-color: #F8E08E; 
    /* Removed the hard ring, leaving only the soft ambient glow */
    box-shadow: 0 8px 20px rgba(248, 224, 142, 0.45);
}

/* 2. Zodingdi - Soft Pastel Lilac Glow */
.shop-card-special .creator-avatar:nth-child(2):hover {
    border-color: #D1C1FA; 
    /* Removed the hard ring, leaving only the soft ambient glow */
    box-shadow: 0 8px 20px rgba(209, 193, 250, 0.45);
}

/* =========================================
   DYNAMIC CREATOR HOVER TITLES
   ========================================= */
.dynamic-creator-title {
    color: var(--hover-gray);
    margin-left: 0.35rem;
    position: absolute;
    pointer-events: none;
    font-family: 'Inter', sans-serif;
    font-size: 0.8rem; 
    font-weight: 500;
    letter-spacing: 0.02rem; 
    
    /* THE FIX: Precisely nudges the smaller text down to match the baseline of "Shop" */
    transform: translateY(0.15rem);
    
    opacity: 0;
    transition: opacity 0.3s ease;
}

/* Fades in the container when ANY avatar is hovered */
.shop-card-special:has(.creator-avatar:hover) .dynamic-creator-title {
    opacity: 1;
}

.creator-name {
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
    white-space: nowrap;
}

/* Activate the correct creator name when hovered */
.shop-card-special:has(.creator-avatar:nth-child(1):hover) .creator-1,
.shop-card-special:has(.creator-avatar:nth-child(2):hover) .creator-2 {
    display: inline-block;
    opacity: 1;
}
/* =========================================
   7. LIBRARY / MANGA SHELF
   ========================================= */
.library-container {
    max-width: 75rem;
    margin: 4rem auto 8rem auto;
    padding: 0 3rem;
    width: 100%;
}

.library-header { text-align: center; margin-bottom: 5rem; }
.library-header h1 { font-size: 3rem; font-weight: 800; letter-spacing: -0.02rem; }
.library-header p { color: #666666; margin-top: 1rem; font-size: 1.1rem; }

.manga-shelf {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2rem 0 4rem 0;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.manga-book {
    width: 12rem;
    height: auto;
    flex-shrink: 0; 
    border-radius: 6px; 
    position: relative;
    box-sizing: border-box; 
    border: 1px solid transparent; 
    box-shadow: 10px 0 20px rgba(0, 0, 0, 0.15); 
    
    /* Removed the pixelating crisp-edges code. Returned to smooth rendering. */
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    filter: contrast(1.02) saturate(1.05);
    will-change: transform, margin, border-color, box-shadow;

    transition: transform 0.7s cubic-bezier(0.22, 1, 0.36, 1), 
                margin 0.7s cubic-bezier(0.22, 1, 0.36, 1), 
                border-color 0.3s ease, 
                box-shadow 0.7s cubic-bezier(0.22, 1, 0.36, 1);
    cursor: pointer;
}

/* Organic Base State */
.manga-book:nth-child(1) { z-index: 8; transform: rotate(-3deg) translateY(3px); }
.manga-book:nth-child(2) { z-index: 7; transform: rotate(1.5deg) translateY(-2px); }
.manga-book:nth-child(3) { z-index: 6; transform: rotate(-2deg) translateY(4px); }
.manga-book:nth-child(4) { z-index: 5; transform: rotate(2.5deg) translateY(-1px); }
.manga-book:nth-child(5) { z-index: 4; transform: rotate(-1.5deg) translateY(2px); }
.manga-book:nth-child(6) { z-index: 3; transform: rotate(3deg) translateY(-3px); }
.manga-book:nth-child(7) { z-index: 2; transform: rotate(-2.5deg) translateY(1px); }
.manga-book:nth-child(8) { z-index: 1; transform: rotate(1deg) translateY(2px); }

.manga-book:not(:first-child) { margin-left: -7.5rem; }

/* Shelf Hover Spread */
.manga-shelf:hover .manga-book:not(:first-child) { margin-left: -2rem; }

.manga-shelf:hover .manga-book:nth-child(1) { transform: rotate(-7deg) translateY(0); }
.manga-shelf:hover .manga-book:nth-child(2) { transform: rotate(-5deg) translateY(0); }
.manga-shelf:hover .manga-book:nth-child(3) { transform: rotate(-3deg) translateY(0); }
.manga-shelf:hover .manga-book:nth-child(4) { transform: rotate(-1deg) translateY(0); }
.manga-shelf:hover .manga-book:nth-child(5) { transform: rotate(1deg) translateY(0); }
.manga-shelf:hover .manga-book:nth-child(6) { transform: rotate(3deg) translateY(0); }
.manga-shelf:hover .manga-book:nth-child(7) { transform: rotate(5deg) translateY(0); }
.manga-shelf:hover .manga-book:nth-child(8) { transform: rotate(7deg) translateY(0); }

/* Individual Book Focus */
.manga-book:nth-child(odd):hover {
    transform: translate(0.5rem, -2.5rem) rotate(-3deg) scale(1.03) !important;
    z-index: 20 !important; 
    border-color: var(--kodansha-black); 
    box-shadow: 0 25px 45px rgba(0, 0, 0, 0.4); 
}

.manga-book:nth-child(even):hover {
    transform: translate(0.5rem, -2.5rem) rotate(3deg) scale(1.03) !important;
    z-index: 20 !important; 
    border-color: var(--kodansha-black); 
    box-shadow: 0 25px 45px rgba(0, 0, 0, 0.4); 
}

/* =========================================
   4. LEGAL PAGES
   ========================================= */
.legal-container { max-width: 50rem; margin: 4rem auto 8rem auto; padding: 0 3rem; width: 100%; }
.legal-header { text-align: center; margin-bottom: 1.5rem; }
.legal-header h1 { font-size: 3rem; font-weight: 800; letter-spacing: -0.02rem; }
.legal-content { font-family: -apple-system, BlinkMacSystemFont, "Helvetica Neue", Helvetica, Arial, sans-serif; }
.legal-content h2 { font-size: 1.1rem; font-weight: 700; text-transform: uppercase; margin: 3rem 0 1rem 0; letter-spacing: 0.05rem; }
.legal-content p, .legal-content ul { margin-bottom: 1.5rem; color: #111111; line-height: 1.7; font-size: 0.95rem; }
.legal-content strong { font-weight: 700; color: #000000; }
.legal-content ul { padding-left: 2rem; }
.legal-content li { margin-bottom: 0.75rem; }
.legal-content a { color: var(--kodansha-black) !important; font-weight: 600; text-decoration: underline; text-decoration-thickness: 0.125rem; text-underline-offset: 0.2rem; transition: color 0.2s ease; }
.legal-content a:hover { color: var(--hover-gray) !important; }

/* =========================================
   5. ARCHITECTURAL FOOTER
   ========================================= */
.site-footer { background-color: var(--kodansha-black); color: var(--bg-color); padding: 5rem calc(1.5vw + 1.5rem) 2rem calc(1.5vw + 1.5rem); margin-top: auto; width: 100%; }
.footer-top { display: flex; justify-content: space-between; width: 100%; }
.footer-brand { width: 42%; padding-right: 3rem; }
.footer-logo { color: var(--bg-color); font-size: 1.5rem; display: block; margin-bottom: 0.5rem; }
.footer-brand h2 { font-size: 2rem; font-weight: 700; margin: 1.5rem 0 1.25rem 0; letter-spacing: -0.03rem; line-height: 1.2; }
.footer-brand p { font-size: 0.875rem; color: #A0A0A0; line-height: 1.7; max-width: 36rem; }
.footer-links { width: 50%; display: grid; grid-template-columns: repeat(3, 1fr); gap: 2.5rem; }
.link-column h3 { font-size: 0.75rem; font-weight: 700; color: var(--bg-color); text-transform: uppercase; letter-spacing: 0.1rem; border-bottom: 0.0625rem solid #333333; padding-bottom: 0.5rem; margin-bottom: 1.25rem; }
.link-column ul { list-style: none; display: flex; flex-direction: column; gap: 0.75rem; }
.link-column a { text-decoration: none; color: #A0A0A0; font-size: 0.7rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08rem; transition: color 0.2s ease; }
.link-column a:hover { color: var(--bg-color); }
.footer-bottom { 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    width: 100%; 
    margin-top: 6rem; 
    padding-top: 2rem; 
    /* THE FIX: Changed from border-bottom to border-top */
    border-top: 0.0625rem solid #333333; 
    font-size: 0.7rem; 
    font-weight: 700; 
    color: #777777; 
    text-transform: uppercase; 
    letter-spacing: 0.08rem; 
}
.footer-bottom-links { display: flex; align-items: center; flex-wrap: wrap; gap: 1.25rem; }
.footer-bottom-links a { color: #777777; text-decoration: none; transition: color 0.2s ease; }
.footer-bottom-links a:hover { color: var(--bg-color); }

/* =========================================
   6. MODERN MOBILE RESPONSIVENESS
   ========================================= */
@media (max-width: 48rem) {
    body { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
    .top-nav { margin: 0; top: 0; width: 100%; border-left: none; border-right: none; border-top: none; padding: max(1rem, env(safe-area-inset-top)) 1.5rem 1rem 1.5rem; }
    .nav-links { display: none; }
    .btn-action { padding: 0.5rem 0.875rem; font-size: 0.7rem; }
    .hero { padding: 3rem max(1.5rem, env(safe-area-inset-right)) 2rem max(1.5rem, env(safe-area-inset-left)); }
    .hero h1 { font-size: 2.25rem; letter-spacing: -0.03rem; line-height: 1.15; }
    .hero h2 { font-size: 1rem; margin-top: 0.75rem; line-height: 1.5; }
    .bento-container { grid-template-columns: 1fr; padding: 0 max(1.5rem, env(safe-area-inset-right)) 0 max(1.5rem, env(safe-area-inset-left)); gap: 1.25rem; }
    .card-large, .card-large-wide, .card-full-wide { grid-row: span 1; grid-column: span 1; }
    .bento-card { padding: 1.5rem; }
    
    /* Disable complex hover effects on mobile for native tap feel */
    .library-card-special:hover .mini-manga:not(:first-child) { margin-left: -2.7rem; }
    .dynamic-book-title { display: none; }

    .legal-container { margin: 1.5rem auto 4rem auto; padding: 0 max(1.5rem, env(safe-area-inset-right)) 0 max(1.5rem, env(safe-area-inset-left)); }
    .legal-header h1 { font-size: 2.2rem; line-height: 1.2; }
    .legal-content h2 { font-size: 1.05rem; margin: 2rem 0 1rem 0; }
    .legal-content p, .legal-content ul { font-size: 0.95rem; line-height: 1.6; }
    .manga-shelf { justify-content: flex-start; padding-bottom: 2rem; }
    .manga-book { width: 8rem; box-shadow: -8px 0 15px rgba(0, 0, 0, 0.2); }
    .manga-book:not(:first-child) { margin-left: -5rem; }
    .footer-top { flex-direction: column; gap: 3rem; }
    .footer-brand, .footer-links { flex: 1 1 auto; width: 100%; padding-right: 0; }
    .footer-links { grid-template-columns: 1fr; gap: 2.5rem; }
    .footer-bottom { flex-direction: column; gap: 1.5rem; text-align: center; }
    .site-footer { padding: 4rem max(1.5rem, env(safe-area-inset-right)) max(2rem, env(safe-area-inset-bottom)) max(1.5rem, env(safe-area-inset-left)); }
}
