/* Rose Pine color scheme */
:root {
    --rp-bg: #232136;
    --rp-surface: #2a273f;
    --rp-overlay: #393552;
    --rp-muted: #6e6a86;
    --rp-subtle: #908caa;
    --rp-text: #e0def4;
    --rp-love: #eb6f92;
    --rp-gold: #f6c177;
    --rp-rose: #ea9a97;
    --rp-pine: #3e8fb0;
    --rp-foam: #9ccfd8;
    --rp-iris: #c4a7e7;
    --rp-highlight: #56526e;
    --rp-badge: #393552;
    --rp-shadow: rgba(20, 18, 31, 0.4);
}

/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: var(--rp-text);
    background-color: var(--rp-bg);
}

/* Container block */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Library container - no side padding */
.library-container .container {
    padding: 0;
}

/* Content pages */
.content-page {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem 0;
}

.content-page h1 {
    color: var(--rp-text);
    margin-bottom: 1rem;
    font-size: 2.5rem;
}

.content-page h2 {
    color: var(--rp-text);
    margin: 2rem 0 1rem 0;
    font-size: 1.5rem;
    border-bottom: 2px solid var(--rp-muted);
    padding-bottom: 0.5rem;
}

.content-page h3 {
    color: var(--rp-text);
    margin: 1.5rem 0 0.5rem 0;
    font-size: 1.25rem;
}

.content-page p {
    margin-bottom: 1rem;
    line-height: 1.7;
}

.content-page ul {
    margin: 1rem 0;
    padding-left: 2rem;
}

.content-page li {
    margin-bottom: 0.5rem;
    line-height: 1.6;
}

.content-page a {
    color: var(--rp-accent);
    text-decoration: none;
}

.content-page a:hover {
    text-decoration: underline;
}

.content-page section {
    margin-bottom: 2rem;
}

/* Footer styles */
.footer {
    background-color: var(--rp-surface);
    border-top: 1px solid var(--rp-muted);
    margin-top: 4rem;
    padding: 2rem 0;
}

.footer__content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer__section h3,
.footer__section h4 {
    color: var(--rp-text);
    margin-bottom: 1rem;
}

.footer__section p {
    color: var(--rp-text-secondary);
    margin-bottom: 0.5rem;
}

.footer__section ul {
    list-style: none;
    padding: 0;
}

.footer__section li {
    margin-bottom: 0.5rem;
}

.footer__section a {
    color: var(--rp-text-secondary);
    text-decoration: none;
}

.footer__section a:hover {
    color: var(--rp-accent);
}

.footer__bottom {
    border-top: 1px solid var(--rp-muted);
    padding-top: 1rem;
    text-align: center;
    color: var(--rp-text-secondary);
}

/* Header block */
.header {
    background-color: var(--rp-surface);
    color: var(--rp-text);
    box-shadow: 0 2px 4px var(--rp-shadow);
}

/* Navbar block */
.navbar {
    padding: 1rem 0;
}

.navbar__container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.navbar__brand {
    font-size: 1.5rem;
}

.navbar__brand-link {
    color: var(--rp-text);
    text-decoration: none;
}

.navbar__menu {
    display: flex;
    gap: 1.5rem;
    align-items: center;
}

.navbar__menu-item {
    color: var(--rp-text);
    text-decoration: none;
    transition: opacity 0.3s;
}

.navbar__menu-item:hover {
    opacity: 0.8;
}

.navbar__limits {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 1rem;
    margin: 0 1rem;
    background: var(--rp-overlay);
    border-radius: 6px;
    border: 1px solid var(--rp-muted);
}

.limits__plan {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--rp-pine);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.limits__usage {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--rp-text);
}

/* Button block */
.btn {
    padding: 0.5rem 1.5rem;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.3s;
    text-decoration: none;
    display: inline-block;
    text-align: center;
}

.btn--primary {
    background-color: var(--rp-pine);
    color: var(--rp-text);
}

.btn--primary:hover {
    background-color: var(--rp-foam);
}

.btn--secondary {
    background-color: var(--rp-muted);
    color: var(--rp-text);
}

.btn--secondary:hover {
    background-color: var(--rp-subtle);
}

.btn--small {
    padding: 0.25rem 0.75rem;
    font-size: 0.875rem;
}

.btn--disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Hero block */
.hero {
    text-align: center;
    padding: 3rem 0;
    background: linear-gradient(135deg, var(--rp-iris) 0%, var(--rp-pine) 100%);
    color: var(--rp-text);
    border-radius: 8px;
    margin: 2rem 0;
}

.hero__title {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.hero__subtitle {
    font-size: 1.2rem;
    opacity: 0.9;
}

/* Search section block */
.search-section {
    background: var(--rp-surface);
    border-radius: 12px;
    padding: 1.5rem;
    margin: 2rem 0;
    box-shadow: 0 2px 4px var(--rp-shadow);
}

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

.search-section__title {
    margin: 0;
    color: var(--rp-text);
    font-size: 1.5rem;
}

.search-section__toggle {
    background: var(--rp-muted);
    color: var(--rp-text);
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
}

.search-section__toggle:hover {
    background: var(--rp-subtle);
}

.search-section__wrapper {
    margin-bottom: 1rem;
}

.search-section__input-wrapper {
    position: relative;
    max-width: 600px;
}

.search-section__icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--rp-muted);
    font-size: 1.1rem;
}

.search-section__input {
    width: 100%;
    padding: 0.75rem 1rem 0.75rem 3rem;
    border: 2px solid var(--rp-overlay);
    border-radius: 8px;
    font-size: 1rem;
    background-color: var(--rp-bg);
    color: var(--rp-text);
    transition: border-color 0.3s;
}

.search-section__input:focus {
    outline: none;
    border-color: var(--rp-pine);
}

/* Advanced filters block */
.advanced-filters {
    display: none;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--rp-overlay);
}

.advanced-filters--visible {
    display: block;
}

.advanced-filters__row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.advanced-filters__group {
    display: flex;
    flex-direction: column;
}

.advanced-filters__label {
    font-weight: 500;
    margin-bottom: 0.5rem;
    color: var(--rp-text);
    font-size: 0.9rem;
}

.advanced-filters__select {
    padding: 0.5rem;
    border: 1px solid var(--rp-overlay);
    border-radius: 6px;
    background: var(--rp-bg);
    color: var(--rp-text);
    font-size: 0.9rem;
}

.advanced-filters__genres,
.advanced-filters__tags {
    margin-bottom: 1.5rem;
}

.advanced-filters__checklist {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.advanced-filters__checkbox {
    display: flex;
    align-items: center;
    cursor: pointer;
    padding: 0.25rem;
    border-radius: 4px;
    transition: background-color 0.2s;
}

.advanced-filters__checkbox:hover {
    background-color: var(--rp-overlay);
}

.advanced-filters__checkbox-input {
    margin-right: 0.5rem;
    transform: scale(1.1);
}

.advanced-filters__checkbox-label {
    font-size: 0.9rem;
    color: var(--rp-text);
}

.advanced-filters__actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 1.5rem;
}

.advanced-filters__btn {
    min-width: 120px;
}

/* Tag selector styles */
.tag-selector {
    border: 1px solid var(--rp-overlay);
    border-radius: 8px;
    padding: 12px;
    background: var(--rp-bg);
    margin-bottom: 8px;
}

.tag-search-container {
    position: relative;
    margin-bottom: 12px;
}

.tag-search-input {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid var(--rp-overlay);
    border-radius: 8px;
    font-size: 14px;
    background: var(--rp-bg);
    color: var(--rp-text);
    transition: border-color 0.2s ease;
}

.tag-search-input:focus {
    outline: none;
    border-color: var(--rp-primary);
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

.tag-search-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--rp-bg);
    border: 1px solid var(--rp-overlay);
    border-top: none;
    border-radius: 0 0 8px 8px;
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    display: none;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.tag-search-result {
    padding: 10px 14px;
    cursor: pointer;
    border-bottom: 1px solid var(--rp-overlay);
    font-size: 14px;
    color: var(--rp-text);
    transition: background-color 0.2s ease;
}

.tag-search-result:hover,
.tag-search-result.highlighted {
    background: var(--rp-overlay);
}

.tag-search-result:last-child {
    border-bottom: none;
}

.selected-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    min-height: 40px;
    padding: 8px;
    border: 1px solid var(--rp-overlay);
    border-radius: 8px;
    background: var(--rp-overlay);
}

.selected-tag {
    display: inline-flex;
    align-items: center;
    background: var(--rp-primary);
    color: white;
    padding: 6px 10px;
    border-radius: 16px;
    font-size: 12px;
    gap: 6px;
    font-weight: 500;
}

.selected-tag .tag-remove {
    background: rgba(255, 255, 255, 0.3);
    border: none;
    color: white;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    transition: background-color 0.2s ease;
}

.selected-tag .tag-remove:hover {
    background: rgba(255, 255, 255, 0.5);
}

.tag-search-help {
    color: var(--rp-text-secondary);
    font-size: 12px;
    margin-top: 6px;
    display: block;
}

/* Books section block */
.books-section {
    margin: 3rem 0;
}

.books-section__title {
    font-size: 1.8rem;
    color: var(--rp-text);
    margin-bottom: 1.5rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Books grid block */
.books-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1.5rem;
    margin: 1.5rem 0;
}

/* Book card block */
.book-card {
    background: var(--rp-surface);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px var(--rp-shadow);
    transition: transform 0.3s, box-shadow 0.3s;
    cursor: pointer;
}

.book-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 12px var(--rp-shadow);
}

.book-card__cover {
    margin-top: 10px;
    width: 100%;
    height: 250px;
    object-fit: cover;
    background-color: var(--rp-highlight);
}

.book-card__info {
    padding: 0.75rem;
}

.book-card__title {
    font-size: 1rem;
    font-weight: bold;
    margin-bottom: 0.4rem;
    line-height: 1.3;
    color: var(--rp-text);
}

.book-card__author {
    color: var(--rp-subtle);
    margin-bottom: 0.4rem;
    font-size: 0.9rem;
}

.book-card__rating {
    color: var(--rp-gold);
    font-size: 0.8rem;
}

.book-card__meta {
    margin: 0.4rem 0;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.book-card__status {
    padding: 0.25rem 0.5rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
}

.book-card__status--ongoing {
    background-color: var(--rp-pine);
    color: var(--rp-text);
}

.book-card__status--completed {
    background-color: var(--rp-pine);
    color: var(--rp-text);
}

.book-card__status--hiatus {
    background-color: var(--rp-gold);
    color: var(--rp-text);
}

.book-card__status--dropped {
    background-color: var(--rp-love);
    color: var(--rp-text);
}

.book-card__genres {
    margin: 0.4rem 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.2rem;
}

.book-card__genre {
    background-color: var(--rp-overlay);
    color: var(--rp-text);
    padding: 0.2rem 0.4rem;
    border-radius: 10px;
    font-size: 0.7rem;
    font-weight: 500;
}

.book-card__tags {
    margin: 0.4rem 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.2rem;
}

.book-card__tag {
    background-color: var(--rp-badge);
    color: var(--rp-text);
    padding: 0.15rem 0.3rem;
    border-radius: 6px;
    font-size: 0.65rem;
    border: 1px solid var(--rp-overlay);
}

.book-card__tag--more {
    background-color: var(--rp-iris);
    color: var(--rp-text);
    font-weight: 500;
}

/* Book details block */
.book-details {
    background: var(--rp-surface);
    border-radius: 12px;
    padding: 2rem;
    margin: 2rem 0;
    box-shadow: 0 4px 12px var(--rp-shadow);
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
}

.book-details__header {
    display: flex;
    gap: 2rem;
    margin-bottom: 0;
}

.book-details__cover {
    width: 280px;
    height: 380px;
    object-fit: cover;
    border-radius: 8px;
    box-shadow: 0 4px 8px var(--rp-shadow);
    flex-shrink: 0;
    background-color: var(--rp-highlight);
}

.book-details__meta {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.book-details__title-section {
    display: flex;
    align-items: baseline;
    gap: 1rem;
    flex-wrap: wrap;
}

.book-details__title {
    font-size: 2.2rem;
    margin: 0;
    color: var(--rp-text);
    font-weight: 700;
    line-height: 1.2;
}

.book-details__original {
    font-size: 1.1rem;
    color: var(--rp-muted);
    margin: 0.5rem 0 0 0;
    font-weight: 400;
    font-style: italic;
}

.book-details__stats {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin: 0;
}

.book-details__stats p {
    margin: 0;
    font-size: 1rem;
    color: var(--rp-text);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    font-weight: normal;
}

/* Genres and tags styling */
.book-details__genres,
.book-details__tags {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0.5rem 0;
    font-size: 0.95rem;
    color: var(--rp-text);
}

.book-details__genres-title,
.book-details__tags-title {
    font-weight: 500;
    color: var(--rp-text);
    white-space: nowrap;
}

.book-details__genres-list,
.book-details__tags-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
    align-items: center;
}

.book-details__genre,
.book-details__tag {
    background-color: var(--rp-overlay);
    color: var(--rp-text);
    padding: 0.2rem 0.4rem;
    border-radius: 8px;
    font-size: 0.7rem;
    font-weight: 500;
    display: inline-block;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid transparent;
    white-space: nowrap;
}

.book-details__genre:hover,
.book-details__tag:hover {
    background-color: var(--rp-iris);
    color: var(--rp-text);
    transform: translateY(-1px);
    box-shadow: 0 2px 6px var(--rp-shadow);
}

.book-details__tag {
    background-color: var(--rp-badge);
    color: var(--rp-text);
    border: 1px solid var(--rp-overlay);
    border-radius: 6px;
    font-size: 0.7rem;
    padding: 0.2rem 0.4rem;
}

.book-details__description {
    margin: 0;
    grid-column: 1 / -1;
    line-height: 1.7;
    padding-top: 1.5rem;
    border-top: 1px solid var(--rp-overlay);
}

.book-details__description h3 {
    margin: 0 0 1rem 0;
    color: var(--rp-text);
    font-size: 1.4rem;
    font-weight: 600;
}

.book-details__description-content {
    display: block;
}

.book-details__description-content p {
    margin: 0 0 1rem 0;
    color: var(--rp-text);
    font-size: 1rem;
    line-height: 1.6;
}

.book-details__description-content p:last-child {
    margin-bottom: 0;
}

.book-details__actions {
    margin: 0;
    display: flex;
    gap: 1rem;
    align-items: center;
    justify-content: flex-start;
    padding: 1.5rem 0;
    border-top: 1px solid var(--rp-overlay);
}

/* Chapters list block */
.chapters-list {
    background: var(--rp-surface);
    border-radius: 8px;
    padding: 1rem;
    margin: 2rem 0;
}

.chapters-list__item {
    padding: 1rem;
    border-bottom: 1px solid var(--rp-overlay);
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background-color 0.3s;
}

.chapters-list__left {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex: 1;
}

.chapters-list__right {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.chapters-list__item:hover {
    background-color: var(--rp-overlay);
}

.chapters-list__item:last-child {
    border-bottom: none;
}

.chapters-list__title {
    font-weight: 500;
    cursor: pointer;
    color: var(--rp-text);
}

.chapters-list__badge {
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 500;
    white-space: nowrap;
}

.chapters-list__badge--free {
    background-color: var(--rp-pine);
    color: var(--rp-text);
}

.chapters-list__badge--premium {
    background-color: var(--rp-rose);
    color: var(--rp-text);
}

.chapters-list__read-btn {
    padding: 0.4rem 1rem;
    background-color: var(--rp-pine);
    color: var(--rp-text);
    border: none;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s;
    white-space: nowrap;
}

.chapters-list__read-btn:hover {
    background-color: var(--rp-foam);
}

/* Compatibility with old btn--small class in chapters */
.chapters-list .btn--small {
    padding: 0.4rem 1rem;
    background-color: var(--rp-pine);
    color: var(--rp-text);
    border: none;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s;
    white-space: nowrap;
}

.chapters-list .btn--small:hover {
    background-color: var(--rp-foam);
}

/* Chapter content block */
.chapter-content {
    background: var(--rp-surface);
    border-radius: 8px;
    padding: 3rem;
    margin: 2rem 0;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.8;
    font-size: 1.1rem;
    color: var(--rp-text);
}

.chapter-content__title {
    margin-bottom: 1rem;
    color: var(--rp-text);
}

.chapter-content__meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 0.5rem;
    font-size: 0.9rem;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--rp-overlay);
}

.chapter-content__book-title {
    color: var(--rp-subtle);
    font-style: italic;
}

.chapter-content__book-title--link {
    color: var(--rp-subtle);
    text-decoration: none;
    cursor: pointer;
    transition: color 0.3s ease;
    font-style: italic;
}

.chapter-content__book-title--link:hover {
    color: var(--rp-pine);
    text-decoration: underline;
}

.chapter-content__status {
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 500;
}

.chapter-content__status--free {
    background-color: var(--rp-pine);
    color: var(--rp-text);
}

.chapter-content__status--premium {
    background-color: var(--rp-rose);
    color: var(--rp-text);
}

.chapter-content__text {
    text-align: left;
    line-height: 1.8;
    font-size: 1.1rem;
    color: var(--rp-text);
    max-width: none;
    margin: 0;
    padding: 0;
}

.chapter-content__text p {
    margin-bottom: 1.2rem;
    text-align: justify;
}

.chapter-content__text p:last-child {
    margin-bottom: 0;
}

/* Chapter navigation block */
.chapter-navigation {
    display: flex;
    justify-content: space-between;
    margin: 2rem auto;
    max-width: 800px;
    gap: 1rem;
}

.chapter-navigation__btn {
    flex: 1;
    text-align: center;
    padding: 0.75rem 1.5rem;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
    border: none;
}

/* Previous chapter button */
.chapter-nav-prev {
    background-color: var(--rp-muted);
    color: var(--rp-text);
}

.chapter-nav-prev:hover:not(.chapter-nav-prev--disabled) {
    background-color: var(--rp-subtle);
    transform: translateY(-1px);
    box-shadow: 0 2px 6px var(--rp-shadow);
}

.chapter-nav-prev--disabled {
    opacity: 0.4;
    cursor: not-allowed;
    background-color: var(--rp-muted);
    color: var(--rp-subtle);
}

.chapter-nav-prev--disabled:hover {
    background-color: var(--rp-muted);
    color: var(--rp-subtle);
    transform: none;
    box-shadow: none;
}

/* Back to book button */
.chapter-nav-back {
    background-color: var(--rp-muted);
    color: var(--rp-text);
}

.chapter-nav-back:hover {
    background-color: var(--rp-subtle);
    transform: translateY(-1px);
    box-shadow: 0 2px 6px var(--rp-shadow);
}

.chapter-nav-back--active {
    background-color: var(--rp-muted);
    color: var(--rp-text);
}

.chapter-nav-back--active:hover {
    background-color: var(--rp-subtle);
    transform: translateY(-1px);
    box-shadow: 0 2px 6px var(--rp-shadow);
}

/* Next chapter button */
.chapter-nav-next {
    background-color: var(--rp-muted);
    color: var(--rp-text);
}

.chapter-nav-next:hover:not(.chapter-nav-next--disabled) {
    background-color: var(--rp-subtle);
    transform: translateY(-1px);
    box-shadow: 0 2px 6px var(--rp-shadow);
}

.chapter-nav-next--disabled {
    opacity: 0.4;
    cursor: not-allowed;
    background-color: var(--rp-muted);
    color: var(--rp-subtle);
}

.chapter-nav-next--disabled:hover {
    background-color: var(--rp-muted);
    color: var(--rp-subtle);
    transform: none;
    box-shadow: none;
}

.chapter-nav-next--active {
    background-color: var(--rp-rose);
    color: var(--rp-text);
}

.chapter-nav-next--active:hover {
    background-color: var(--rp-rose);
    transform: translateY(-1px);
    box-shadow: 0 2px 6px var(--rp-shadow);
}

/* Profile container block */
.profile-container {
    background: var(--rp-surface);
    border-radius: 8px;
    padding: 2rem;
    margin: 2rem 0;
}

.profile-container__header {
    display: flex;
    align-items: flex-start;
    gap: 2rem;
    margin-bottom: 2rem;
}

.profile-container__info {
    flex: 1;
}

.profile-container__avatar {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
}

.profile-container__info h2 {
    margin-bottom: 0.5rem;
    color: var(--rp-text);
}

.profile-container__subscription {
    background: var(--rp-overlay);
    padding: 1.5rem;
    border-radius: 8px;
    margin: 2rem 0;
}

.subscription-plans {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-top: 1rem;
}

.subscription-plan {
    background: var(--rp-surface);
    padding: 1.5rem;
    border-radius: 8px;
    border: 2px solid var(--rp-muted);
    text-align: center;
    transition: border-color 0.3s ease;
}

.subscription-plan:hover {
    border-color: var(--rp-pine);
}

.subscription-plan h4 {
    color: var(--rp-text);
    margin-bottom: 0.5rem;
    font-size: 1.25rem;
}

.plan-price {
    color: var(--rp-gold);
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
}

.subscription-plan p {
    color: var(--rp-subtle);
    margin-bottom: 1rem;
}

.subscription-plan .btn {
    width: 100%;
}

/* Login prompt block */
.login-prompt {
    text-align: center;
    padding: 2rem;
    background: var(--rp-overlay);
    border-radius: 8px;
    margin: 2rem 0;
}

.login-prompt__title {
    color: var(--rp-text);
    margin-bottom: 1rem;
}

.login-prompt__text {
    color: var(--rp-subtle);
    margin-bottom: 1.5rem;
}

/* Premium info block */
.premium-info {
    background: var(--rp-overlay);
    padding: 1rem;
    border-radius: 8px;
    margin: 1rem 0;
    text-align: left;
}

.premium-info__list {
    margin: 0.5rem 0;
    padding-left: 1.5rem;
}

.premium-info__item {
    margin: 0.25rem 0;
    color: var(--rp-text);
}

.premium-info__actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 1.5rem;
}

.premium-info__btn {
    flex: 1;
    max-width: 200px;
}

/* Loading block */
.loading {
    text-align: center;
    font-size: 1.2rem;
    color: var(--rp-subtle);
}

/* Footer block */
.footer {
    background-color: var(--rp-surface);
    color: var(--rp-text);
    text-align: center;
    padding: 2rem 0;
    margin-top: 4rem;
}

/* Responsive design */
@media (max-width: 768px) {
    .navbar__menu {
        flex-direction: column;
        gap: 0.5rem;
    }

    .books-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 1rem;
    }

    .book-details__header {
        flex-direction: column;
        gap: 1.5rem;
    }

    .book-details__cover {
        width: 100%;
        max-width: 300px;
        height: auto;
        margin: 0 auto;
    }

    .book-details__meta {
        gap: 1rem;
    }

    .book-details__title-section {
        justify-content: center;
        text-align: center;
    }

    .book-details__title {
        font-size: 1.8rem;
    }

    .book-details__original {
        font-size: 1rem;
    }

    .book-details__stats {
        gap: 0.4rem;
    }

    .book-details__stats p {
        font-size: 0.9rem;
        justify-content: center;
    }


    .book-details__actions {
        justify-content: flex-start;
    }

    .book-details__description-content {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .chapter-content {
        padding: 1.5rem;
    }

    .advanced-filters__row {
        grid-template-columns: 1fr;
    }

    .advanced-filters__checklist {
        grid-template-columns: 1fr;
    }
}
/* Library styles */
.library-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.library-item {
    display: flex;
    gap: 1rem;
    padding: 1rem;
    background-color: var(--rp-surface);
    border-radius: 8px;
    border: 1px solid var(--rp-overlay);
}

.library-item__cover {
    flex-shrink: 0;
    width: 80px;
    height: 120px;
}

.library-item__cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 4px;
}

.library-item__info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.library-item__info h4 {
    color: var(--rp-text);
    font-size: 1.1rem;
    margin: 0;
}

.library-item__info p {
    color: var(--rp-subtle);
    font-size: 0.9rem;
    margin: 0;
}

.library-item__status {
    display: inline-block;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 500;
    text-transform: capitalize;
}

.library-item__status--reading {
    background-color: var(--rp-pine);
    color: var(--rp-bg);
}

.library-item__status--completed {
    background-color: var(--rp-gold);
    color: var(--rp-bg);
}

.library-item__status--planned {
    background-color: var(--rp-iris);
    color: var(--rp-bg);
}

.library-item__status--dropped {
    background-color: var(--rp-love);
    color: var(--rp-bg);
}

.library-item__progress {
    margin-top: 0.5rem;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background-color: var(--rp-overlay);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 0.25rem;
}

.progress-bar__fill {
    height: 100%;
    background-color: var(--rp-pine);
    transition: width 0.3s ease;
}

.progress-text {
    font-size: 0.8rem;
    color: var(--rp-subtle);
}

.library-item__actions {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    align-items: flex-end;
}

.btn--small {
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
}

/* Profile styles */
.profile-container__library {
    margin-top: 2rem;
}

.profile-container__library h3 {
    color: var(--rp-text);
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

/* Current Subscription */
.current-subscription {
    background: var(--rp-surface);
    border: 1px solid var(--rp-border);
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.subscription-info h4 {
    color: var(--rp-pine);
    margin-bottom: 0.5rem;
    font-size: 1.3rem;
}

.subscription-info .plan-price {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--rp-gold);
    margin-bottom: 0.5rem;
}

.subscription-info p {
    color: var(--rp-subtle);
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.subscription-status {
    font-weight: bold;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.8rem;
}

.subscription-status.active {
    background-color: #d4edda;
    color: #155724;
}

.subscription-status.inactive {
    background-color: #f8d7da;
    color: #721c24;
}

.subscription-actions {
    margin-left: 1rem;
}

/* No Subscription */
.no-subscription {
    text-align: center;
    margin-bottom: 1rem;
}

.no-subscription p {
    color: var(--rp-subtle);
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

/* Mobile responsive for library */
@media (max-width: 768px) {
    .library-item {
        flex-direction: column;
        text-align: center;
    }
    
    .library-item__cover {
        width: 120px;
        height: 180px;
        margin: 0 auto;
    }
    
    .library-item__actions {
        flex-direction: row;
        justify-content: center;
    }
    
    .current-subscription {
        flex-direction: column;
        text-align: center;
    }
    
    .subscription-actions {
        margin-left: 0;
        margin-top: 1rem;
    }
}

/* Skeleton Loading Animation */
@keyframes skeleton-loading {
    0% {
        background-position: -200px 0;
    }
    100% {
        background-position: calc(200px + 100%) 0;
    }
}

.skeleton {
    background: linear-gradient(90deg, var(--rp-surface) 25%, var(--rp-overlay) 50%, var(--rp-surface) 75%);
    background-size: 200px 100%;
    animation: skeleton-loading 1.5s infinite;
    border-radius: 4px;
}

.skeleton-text {
    height: 1rem;
    margin-bottom: 0.5rem;
    border-radius: 4px;
}

.skeleton-text--short {
    width: 60%;
}

.skeleton-text--medium {
    width: 80%;
}

.skeleton-text--long {
    width: 100%;
}

.skeleton-title {
    height: 1.5rem;
    margin-bottom: 1rem;
    border-radius: 4px;
}

.skeleton-cover {
    width: 100%;
    height: 200px;
    border-radius: 8px;
    margin-bottom: 1rem;
}

.skeleton-cover--small {
    height: 120px;
}

.skeleton-cover--large {
    height: 300px;
}

.skeleton-button {
    height: 2.5rem;
    width: 120px;
    border-radius: 6px;
}

.skeleton-button--full {
    width: 100%;
}

.skeleton-avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
}

.skeleton-avatar--large {
    width: 120px;
    height: 120px;
}

.skeleton-card {
    background: var(--rp-surface);
    border-radius: 8px;
    padding: 1.5rem;
    border: 1px solid var(--rp-overlay);
}

.skeleton-list-item {
    display: flex;
    align-items: center;
    padding: 1rem;
    border-bottom: 1px solid var(--rp-overlay);
}

.skeleton-list-item:last-child {
    border-bottom: none;
}

.skeleton-list-item__icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    margin-right: 1rem;
}

.skeleton-list-item__content {
    flex: 1;
}

.skeleton-chapter-content {
    line-height: 1.8;
}

.skeleton-chapter-content .skeleton-text {
    margin-bottom: 1rem;
}

.skeleton-chapter-content .skeleton-text:last-child {
    width: 70%;
}

/* Loading states */
.loading .skeleton {
    display: block;
}

.loading .content {
    display: none;
}

.loaded .skeleton {
    display: none;
}

.loaded .content {
    display: block;
}

/* Mobile responsive for skeletons */
@media (max-width: 768px) {
    .skeleton-cover {
        height: 150px;
    }
    
    .skeleton-cover--small {
        height: 100px;
    }
    
    .skeleton-cover--large {
        height: 200px;
    }
}
