/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: #0a0a0a;
    color: #ffffff;
    overflow: hidden;
    height: 100vh;
}

.app {
    display: flex;
    flex-direction: column;
    height: 100vh;
    position: relative;
}

/* Landing Page Styles */
.landing-page {
    display: flex;
    flex-direction: column;
    height: 100vh;
    background: linear-gradient(135deg, #0a0a0a 0%, #1a1a1a 50%, #2d2d2d 100%);
    overflow-y: auto;
}

.landing-header {
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
    padding: 2rem 0;
    text-align: center;
    border-bottom: 1px solid #333;
}

.main-title {
    font-size: 2.5rem;
    font-weight: 700;
    background: linear-gradient(45deg, #ff6b6b, #4ecdc4, #45b7d1, #96ceb4, #feca57, #ff9ff3);
    background-size: 300% 300%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: rainbowShift 3s ease-in-out infinite;
    margin-bottom: 0.5rem;
    letter-spacing: 1px;
}

.subtitle {
    font-size: 1.5rem;
    background: linear-gradient(45deg, #4ecdc4, #45b7d1, #96ceb4);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 400;
}

@keyframes rainbowShift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.landing-main {
    flex: 1;
    padding: 2rem;
    overflow-y: auto;
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}

/* Synopsis Section */
.synopsis-section {
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
    border-radius: 16px;
    padding: 2rem;
    margin-bottom: 2rem;
    border: 1px solid #333;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

/* AI Colorization Notice Section */
.ai-notice-section {
    background: linear-gradient(135deg, #1a1a2e 0%, #2d2d3d 100%);
    border-radius: 16px;
    padding: 1.5rem 2rem;
    margin-bottom: 2rem;
    border: 1px solid #4ecdc4;
    box-shadow: 0 8px 32px rgba(78, 205, 196, 0.1);
}

.notice-title {
    font-size: 1.4rem;
    font-weight: 600;
    color: #4ecdc4;
    margin-bottom: 1rem;
}

.notice-content {
    color: #e0e0e0;
    line-height: 1.6;
}

.notice-content p {
    margin: 0;
    font-size: 0.95rem;
}

.synopsis-title {
    font-size: 1.8rem;
    font-weight: 600;
    background: linear-gradient(45deg, #ff6b6b, #4ecdc4);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1.5rem;
}

.synopsis-content {
    display: flex;
    gap: 2rem;
    margin-bottom: 1.5rem;
    align-items: flex-start;
}

.synopsis-image {
    flex-shrink: 0;
    width: 200px;
    height: 280px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
    border: 2px solid transparent;
    background: linear-gradient(45deg, #ff6b6b, #4ecdc4, #45b7d1, #96ceb4);
    padding: 3px;
}

.jjk-cover {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 10px;
}

.synopsis-text {
    flex: 1;
}

.synopsis-text p {
    color: #e0e0e0;
    line-height: 1.7;
    margin-bottom: 1rem;
    font-size: 1rem;
}

.keywords-section {
    border-top: 1px solid #444;
    padding-top: 1.5rem;
    background: linear-gradient(90deg, transparent, rgba(255, 107, 107, 0.1), transparent);
    margin: 0 -2rem -2rem -2rem;
    padding: 1.5rem 2rem 2rem 2rem;
    border-radius: 0 0 16px 16px;
}

.keywords-label {
    color: #4ecdc4;
    font-size: 0.9rem;
    font-weight: 600;
    margin-right: 0.5rem;
}

.keywords {
    color: #b0b0b0;
    font-size: 0.9rem;
}

/* Chapters Section */
.chapters-section {
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
    border-radius: 16px;
    padding: 2rem;
    border: 1px solid #333;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.chapters-header {
    margin-bottom: 1.5rem;
}

.chapters-title {
    font-size: 1.8rem;
    font-weight: 600;
    background: linear-gradient(45deg, #4ecdc4, #45b7d1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}


.search-container {
    margin-bottom: 1.5rem;
}

.search-container input {
    width: 100%;
    background: linear-gradient(135deg, #333 0%, #444 100%);
    border: 2px solid transparent;
    background-clip: padding-box;
    border-radius: 12px;
    padding: 0.75rem 1rem;
    color: #ffffff;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.search-container input::placeholder {
    color: #888;
}

.search-container input:focus {
    outline: none;
    border: 2px solid #4ecdc4;
    box-shadow: 0 0 20px rgba(78, 205, 196, 0.3);
}

/* Chapter Highlights */
.chapter-highlights {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 2rem;
}

.chapter-highlight {
    padding: 1.5rem;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.first-chapter {
    background: linear-gradient(135deg, #333 0%, #444 100%);
    color: #ffffff;
    border: 2px solid transparent;
    background-clip: padding-box;
}

.first-chapter::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, #ff6b6b, #4ecdc4);
    z-index: -1;
    margin: -2px;
    border-radius: 12px;
}

.new-chapter {
    background: linear-gradient(45deg, #ff6b6b, #4ecdc4);
    color: #ffffff;
    box-shadow: 0 8px 24px rgba(255, 107, 107, 0.3);
}

.chapter-highlight:hover {
    transform: translateY(-4px);
}

.first-chapter:hover {
    box-shadow: 0 12px 32px rgba(255, 107, 107, 0.4);
}

.new-chapter:hover {
    box-shadow: 0 12px 32px rgba(78, 205, 196, 0.4);
}

.highlight-label {
    display: block;
    font-size: 0.9rem;
    color: #888;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.new-chapter .highlight-label {
    color: rgba(255, 255, 255, 0.8);
}

.chapter-title {
    font-size: 1.2rem;
    font-weight: 600;
}

/* Chapter List */
.chapter-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    overflow-y: auto;
    width: 100%;
}

.chapter-item {
    background: linear-gradient(135deg, #333 0%, #444 100%);
    border-radius: 12px;
    padding: 1rem 2rem;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    position: relative;
    overflow: hidden;
    min-width: 300px;
    width: 100%;
    display: flex;
    align-items: center;
}

.chapter-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, #ff6b6b, #4ecdc4, #45b7d1, #96ceb4);
    z-index: -1;
    margin: -2px;
    border-radius: 12px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.chapter-item:hover::before {
    opacity: 1;
}

.chapter-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.chapter-item h5 {
    color: #ffffff;
    font-size: 1.1rem;
    font-weight: 600;
    text-align: left;
    padding: 0 1rem;
    margin: 0;
}



.chapters-section h2 {
    font-size: 2rem;
    font-weight: 600;
    margin-bottom: 2rem;
    text-align: center;
    color: #fff;
}

.chapters-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.chapter-card {
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
    border: 1px solid #333;
    border-radius: 16px;
    padding: 2rem;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.chapter-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #ff6b6b, #4ecdc4);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.chapter-card:hover::before {
    transform: scaleX(1);
}

.chapter-card:hover {
    transform: translateY(-8px);
    border-color: #4ecdc4;
    box-shadow: 0 15px 40px rgba(78, 205, 196, 0.2);
}

.chapter-card h3 {
    font-size: 1.4rem;
    font-weight: 600;
    margin-bottom: 0.8rem;
    color: #fff;
}

.chapter-card p {
    color: #888;
    font-size: 1rem;
    margin-bottom: 1rem;
    line-height: 1.5;
}

.chapter-card .page-count {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: rgba(78, 205, 196, 0.2);
    color: #4ecdc4;
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
}

.chapter-card .release-date {
    color: #666;
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

/* Reader View Styles */
.reader-view {
    display: flex;
    flex-direction: column;
    height: 100vh;
}

.back-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    padding: 0.25rem 0.6rem;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.2rem;
    font-weight: 500;
    font-size: 0.8rem;
}

.back-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-1px);
}

.chapter-dropdown {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    padding: 0.25rem 0.6rem;
    border-radius: 4px;
    font-size: 0.8rem;
    min-width: 100px;
    cursor: pointer;
    margin-left: 0.3rem;
}

.chapter-dropdown option {
    background: #1a1a1a;
    color: white;
}

/* Header Styles */
.header {
    background: linear-gradient(135deg, #2a2a2a 0%, #1a1a1a 100%);
    padding: 0.8rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #444;
    z-index: 100;
    flex-shrink: 0;
    min-height: 60px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.header-left {
    display: flex;
    align-items: center;
    gap: 1rem;
}

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

.header-right {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.header .nav-btn {
    background: linear-gradient(135deg, #4ecdc4, #44a08d);
    border: none;
    color: white;
    padding: 0.4rem 0.8rem;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.9rem;
    white-space: nowrap;
}

.header .nav-btn:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(78, 205, 196, 0.3);
}

.header .nav-btn:disabled {
    background: #333;
    color: #666;
    cursor: not-allowed;
    transform: none;
}

/* Smooth Menu Button */
.menu-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 6px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.menu-btn:hover {
    background: rgba(255, 255, 255, 0.1);
}

.hamburger {
    display: flex;
    flex-direction: column;
    gap: 3px;
    width: 20px;
    height: 15px;
}

.hamburger span {
    width: 100%;
    height: 2px;
    background: #fff;
    border-radius: 1px;
    transition: all 0.3s ease;
}

.menu-btn:hover .hamburger span {
    background: #4ecdc4;
}

/* Manga Title */
.manga-title .title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #fff;
    margin-left: 0.5rem;
    transition: color 0.2s ease;
}

.manga-title:hover .title {
    color: #4ecdc4;
}

/* Chapter Navigation */
.chapter-nav {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #fff;
    font-size: 0.9rem;
}

.volume {
    color: #4ecdc4;
    font-weight: 600;
}

.chapter {
    color: #fff;
    font-weight: 500;
}

/* Page Navigation */
.page-nav {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    color: #888;
    font-size: 0.9rem;
}

.current-page {
    color: #4ecdc4;
    font-weight: 600;
}

.page-separator {
    color: #666;
}

.total-pages {
    color: #888;
}

/* Reading Mode Dropdown */
.reading-mode {
    display: flex;
    align-items: center;
}

.mode-dropdown {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    padding: 0.4rem 0.8rem;
    border-radius: 6px;
    font-size: 0.9rem;
    cursor: pointer;
    min-width: 120px;
}

.mode-dropdown option {
    background: #1a1a1a;
    color: white;
}

.header-content .title {
    font-size: 1.8rem;
    font-weight: 700;
    background: linear-gradient(45deg, #ff6b6b, #4ecdc4);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.header-content .subtitle {
    font-size: 0.9rem;
    color: #888;
    margin-top: 0.2rem;
}

.header-controls {
    display: flex;
    gap: 0.3rem;
}

.control-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    padding: 0.25rem 0.6rem;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.2rem;
    font-size: 0.8rem;
}

.control-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-1px);
}

.control-btn .icon {
    font-size: 1.1rem;
}

/* Chapter Selector */
.chapter-selector {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    display: none;
    flex-direction: column;
}

.chapter-selector.active {
    display: flex;
}

.selector-header {
    padding: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #333;
}

.selector-header h2 {
    font-size: 2rem;
    font-weight: 600;
}

.close-btn {
    background: none;
    border: none;
    color: white;
    font-size: 2rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 50%;
    transition: background 0.2s ease;
}

.close-btn:hover {
    background: rgba(255, 255, 255, 0.1);
}

.chapters-grid {
    flex: 1;
    padding: 2rem;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1.5rem;
    overflow-y: auto;
}

.chapter-card {
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
    border: 1px solid #333;
    border-radius: 12px;
    padding: 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.chapter-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #ff6b6b, #4ecdc4);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.chapter-card:hover::before {
    transform: scaleX(1);
}

.chapter-card:hover {
    transform: translateY(-5px);
    border-color: #4ecdc4;
    box-shadow: 0 10px 30px rgba(78, 205, 196, 0.2);
}

.chapter-card h3 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.chapter-card p {
    color: #888;
    font-size: 0.9rem;
}

.chapter-card .page-count {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    background: rgba(78, 205, 196, 0.2);
    color: #4ecdc4;
    padding: 0.2rem 0.5rem;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 500;
}

/* Reader Container */
.reader-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: #1a1a1a;
    position: relative;
    overflow: hidden;
}

/* Reader Viewport */
.reader-viewport {
    flex: 1;
    overflow: auto;
    background: #1a1a1a;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 1rem;
}

.page-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    max-width: 100%;
    width: 100%;
}

.manga-page {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    transition: all 0.3s ease;
    cursor: pointer;
    display: block;
    margin: 0 auto;
}

.manga-page:hover {
    transform: scale(1.02);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.7);
}

/* Reading Modes */
.page-container.single-page .manga-page {
    max-width: 800px;
}

.page-container.double-page {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
}

.page-container.double-page .manga-page {
    max-width: 45%;
    margin: 0.5rem;
}

.page-container.long-strip {
    flex-direction: column;
    align-items: center;
}

.page-container.long-strip .manga-page {
    max-width: 100%;
    margin-bottom: 0.5rem;
}

/* Smooth Menu Panel */
.menu-panel {
    position: fixed;
    top: 0;
    left: -350px;
    width: 350px;
    height: 100%;
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
    border-right: 1px solid #444;
    z-index: 1000;
    transition: left 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    box-shadow: 2px 0 20px rgba(0, 0, 0, 0.3);
}

.menu-panel.active {
    left: 0;
}

.menu-header {
    padding: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #444;
    background: rgba(0, 0, 0, 0.2);
}

.menu-header h3 {
    font-size: 1.2rem;
    font-weight: 600;
    color: #fff;
}

.menu-content {
    flex: 1;
    padding: 1.5rem;
    overflow-y: auto;
}

.menu-section {
    margin-bottom: 2rem;
}

.menu-section h4 {
    font-size: 1rem;
    font-weight: 600;
    color: #4ecdc4;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.chapter-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.chapter-item {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 0.8rem 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    color: #fff;
}

.chapter-item:hover {
    background: rgba(78, 205, 196, 0.1);
    border-color: #4ecdc4;
    transform: translateX(5px);
}

.chapter-item.active {
    background: rgba(78, 205, 196, 0.2);
    border-color: #4ecdc4;
    color: #4ecdc4;
}

.chapter-item h5 {
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 0.3rem;
}

.chapter-item p {
    font-size: 0.8rem;
    color: #888;
    margin: 0;
}

.settings-header {
    padding: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #333;
}

.settings-header h3 {
    font-size: 1.5rem;
    font-weight: 600;
}

.settings-content {
    flex: 1;
    padding: 2rem;
    overflow-y: auto;
}

.setting-group {
    margin-bottom: 2rem;
}

.setting-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #fff;
}

.setting-group input[type="checkbox"] {
    width: 20px;
    height: 20px;
    accent-color: #4ecdc4;
}

.setting-group input[type="range"] {
    width: 100%;
    margin: 0.5rem 0;
    accent-color: #4ecdc4;
}

.setting-group input[type="color"] {
    width: 100%;
    height: 40px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
}

/* Loading Overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: none;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    z-index: 2000;
}

.loading-overlay.active {
    display: flex;
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 3px solid #333;
    border-top: 3px solid #4ecdc4;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 1rem;
}

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

/* Responsive Design */
@media (max-width: 768px) {
    .landing-header {
        padding: 1.5rem;
    }
    
    .landing-header .title {
        font-size: 2.2rem;
    }
    
    .landing-main {
        padding: 1rem;
    }
    
    .search-container {
        margin-bottom: 2rem;
    }
    
    .chapters-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
        gap: 1.5rem;
    }
    
    .chapter-card {
        padding: 1.5rem;
    }
    
    .chapter-card h3 {
        font-size: 1.2rem;
    }
    
    .header {
        padding: 1rem;
        flex-direction: column;
        gap: 1rem;
    }
    
.header-content {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    flex: 1;
}

.header .chapter-info {
    display: flex;
    align-items: center;
    margin-left: 0.5rem;
    gap: 0.3rem;
}

.header .chapter-info span {
    font-size: 0.75rem;
    line-height: 1;
}

.header .chapter-info #currentChapter {
    font-weight: 600;
    color: #fff;
}

.header .chapter-info #pageInfo {
    color: #888;
    font-size: 0.7rem;
}

.header .nav-btn {
    background: linear-gradient(135deg, #4ecdc4, #44a08d);
    border: none;
    color: white;
    padding: 0.25rem 0.6rem;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.2rem;
    font-size: 0.8rem;
    margin: 0 0.1rem;
}

.header .nav-btn:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(78, 205, 196, 0.3);
}

.header .nav-btn:disabled {
    background: #333;
    color: #666;
    cursor: not-allowed;
    transform: none;
}
    
    .chapter-selector-dropdown {
        margin-left: 0;
    }
    
    .chapter-dropdown {
        min-width: 150px;
    }
    
    .reader-controls {
        padding: 1rem;
        flex-wrap: wrap;
        gap: 1rem;
    }
    
    .nav-btn {
        padding: 0.6rem 1rem;
        font-size: 0.9rem;
    }
    
    .reading-modes {
        order: -1;
        width: 100%;
        justify-content: center;
    }
    
    .reader-viewport {
        padding: 1rem;
    }
    
    .page-container.double-page .manga-page {
        max-width: 100%;
        margin: 0.5rem 0;
    }
    
    .settings-panel {
        width: 100%;
        right: -100%;
    }
}

@media (max-width: 480px) {
    .landing-header .title {
        font-size: 1.8rem;
    }
    
    .landing-header .subtitle {
        font-size: 1rem;
    }
    
    .chapters-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .chapter-card {
        padding: 1rem;
    }
    
    .search-box input {
        padding: 0.8rem 2.5rem 0.8rem 1rem;
        font-size: 1rem;
    }
    
    .header-content .title {
        font-size: 1.2rem;
    }
    
    .reader-controls {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .nav-btn {
        width: 100%;
        justify-content: center;
    }
    
    .chapter-info {
        order: -1;
    }
    
    .back-btn {
        padding: 0.6rem 1rem;
        font-size: 0.9rem;
    }
}

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #1a1a1a;
}

::-webkit-scrollbar-thumb {
    background: #4ecdc4;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #44a08d;
}

/* Fullscreen Styles */
body.fullscreen .header,
body.fullscreen .reader-controls {
    display: none;
}

body.fullscreen .reader-container {
    height: 100vh;
}

/* Auto-fit functionality */
.manga-page.auto-fit {
    width: 100%;
    height: auto;
    max-width: none;
}

/* Single Page Mode Styles */
.page-container.singlePage-page {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    position: relative;
}

.page-container.singlePage-page .manga-page {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8);
    transition: all 0.3s ease;
}

.page-container.singlePage-page .manga-page.single-panel-active {
    transform: scale(1.02);
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.9);
}

/* Chapter Progress Bar */
.chapter-progress-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    z-index: 1000;
    display: flex;
    align-items: center;
    transition: all 0.3s ease;
}

.chapter-progress-bar:hover {
    height: 8px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #4ecdc4, #44a08d);
    transition: width 0.3s ease;
    position: relative;
}

.progress-fill::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 2px;
    height: 100%;
    background: rgba(255, 255, 255, 0.8);
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

.progress-info {
    position: absolute;
    bottom: 12px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    padding: 0.5rem 1rem;
    color: white;
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.chapter-progress-bar:hover .progress-info {
    opacity: 1;
}

.progress-text {
    font-weight: 600;
    color: #4ecdc4;
}

.progress-chapter {
    color: #888;
}

/* Single page mode click areas */
.page-container.singlePage-page .manga-page {
    cursor: pointer;
    position: relative;
}

.page-container.singlePage-page .manga-page::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 50%;
    height: 100%;
    background: transparent;
    cursor: w-resize;
    z-index: 1;
}

.page-container.singlePage-page .manga-page::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 50%;
    height: 100%;
    background: transparent;
    cursor: e-resize;
    z-index: 1;
}

/* Responsive adjustments for single page mode */
@media (max-width: 768px) {
    .progress-info {
        bottom: 8px;
        padding: 0.4rem 0.8rem;
        font-size: 0.7rem;
        gap: 0.5rem;
    }
    
    .page-container.singlePage-page .manga-page {
        max-width: 95vw;
        max-height: 85vh;
    }
}