/* Сброс стилей и базовые настройки */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    /* Запрещаем выделение текста */
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    /* Запрещаем перетаскивание элементов */
    -webkit-user-drag: none;
    -khtml-user-drag: none;
    -moz-user-drag: none;
    -o-user-drag: none;
    user-drag: none;
}

/* Разрешаем взаимодействие для интерактивных элементов */
button, input, textarea, select, a {
    -webkit-user-select: auto !important;
    -moz-user-select: auto !important;
    -ms-user-select: auto !important;
    user-select: auto !important;
    pointer-events: auto !important;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #1a1a1a;
    background-color: #f8f9fa;
    overflow-x: hidden;
    /* Дополнительная защита от скриншотов */
    -webkit-touch-callout: none;
    -webkit-tap-highlight-color: transparent;
}

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

/* Основная героичная секция */
.hero-section {
    position: relative;
    height: 100vh;
    min-height: 600px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.background-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    z-index: 2;
}

.hero-content {
    position: relative;
    z-index: 3;
    text-align: center;
    color: white;
    max-width: 800px;
    padding: 2rem;
}

.book-presentation {
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 3rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.main-title {
    font-family: 'Playfair Display', serif;
    font-size: 2.5rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1.5rem;
    color: white;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.main-description {
    font-size: 1.2rem;
    margin-bottom: 2.5rem;
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.6;
}

.action-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.btn-primary {
    background: linear-gradient(135deg, #c9a96e 0%, #b8935a 100%);
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: 0 4px 15px rgba(201, 169, 110, 0.3);
    min-width: 200px;
    justify-content: center;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(201, 169, 110, 0.4);
    background: linear-gradient(135deg, #d4b578 0%, #c39d64 100%);
}

.btn-secondary {
    background: transparent;
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.8);
    padding: 1rem 2rem;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    min-width: 200px;
    justify-content: center;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: white;
    transform: translateY(-2px);
}

/* Заголовок как оверлей */
.header-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding: 1rem 0;
    z-index: 10;
    transition: all 0.3s ease;
}

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

.logo {
    display: flex;
    align-items: center;
    font-size: 1.5rem;
    font-weight: 700;
    gap: 0.5rem;
    color: white;
}

.logo i {
    font-size: 1.8rem;
}

.nav {
    display: flex;
    gap: 2rem;
}

.nav-link {
    color: white;
    text-decoration: none;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.nav-link:hover,
.nav-link.active {
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
}

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

.auth-btn {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    font-weight: 500;
}

.auth-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

.register-btn {
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.login-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.5);
}

.logout-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.5);
}

.profile-btn {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    font-weight: 500;
}

.profile-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

/* Секция деталей книги */
.book-details-section {
    padding: 4rem 0;
    background: white;
}

.details-content {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 2rem;
}

.book-specs {
    margin-bottom: 3rem;
}

.book-specs h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 3rem;
    color: #2d3748;
    text-align: center;
    position: relative;
}

.book-specs h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: linear-gradient(135deg, #c9a96e 0%, #b8935a 100%);
    border-radius: 2px;
}

.book-specs .rating-section {
    margin: 2rem 0;
    padding: 1.5rem;
}

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

.spec-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    background: #f8f9fa;
    border-radius: 15px;
    border-left: 4px solid #c9a96e;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.spec-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.spec-label {
    font-weight: 600;
    color: #4a5568;
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    min-width: 100px;
}

.spec-value {
    color: #2d3748;
    font-weight: 500;
    font-size: 1rem;
    text-align: right;
}

.price-highlight {
    color: #c9a96e;
    font-size: 1.4rem;
    font-weight: 700;
}

.book-description {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.book-description h3 {
    font-size: 2rem;
    font-weight: 600;
    margin-bottom: 2rem;
    color: #2d3748;
    position: relative;
}

.book-description h3::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 2px;
    background: #c9a96e;
    border-radius: 1px;
}

.book-description p {
    font-size: 1.1rem;
    color: #4a5568;
    line-height: 1.8;
    margin-bottom: 1.5rem;
    text-align: justify;
}

.rating-section {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    margin-top: 3rem;
    padding: 2rem;
    background: linear-gradient(135deg, #f8f9fa 0%, #e2e8f0 100%);
    border-radius: 20px;
    box-shadow: inset 0 2px 10px rgba(0,0,0,0.05);
}

.stars {
    color: #f6ad55;
    font-size: 1.5rem;
    display: flex;
    gap: 0.25rem;
}

.rating-text {
    color: #4a5568;
    font-weight: 600;
    font-size: 1.1rem;
}

/* Модальные окна */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
    /* Предотвращаем дергание страницы */
    overflow-y: auto;
    animation: fadeIn 0.3s ease;
    /* Блокируем скролл фона */
    overscroll-behavior: contain;
}

/* Фиксим дергание при открытии модалки */
body.modal-open {
    overflow: hidden !important;
    padding-right: var(--scrollbar-width, 0);
    position: fixed;
    width: 100%;
    height: 100%;
    top: var(--scroll-y, 0);
    left: 0;
}

/* Дополнительная блокировка скролла */
body.modal-open #root,
body.modal-open .hero-section,
body.modal-open main {
    overflow: hidden !important;
    touch-action: none;
}

/* Блокировка скролла на мобильных */
body.modal-open {
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: none;
}


/* Анимации для модальных окон */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes fadeOut {
    from {
        opacity: 1;
    }
    to {
        opacity: 0;
    }
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-50px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.modal-content {
    background-color: white;
    margin: 2% auto;
    padding: 3rem;
    border-radius: 20px;
    width: 90%;
    max-width: 900px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    /* Плавная анимация появления */
    animation: slideIn 0.4s ease-out;
    /* Фиксируем содержимое модалки */
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
}

.close {
    position: absolute;
    top: 1rem;
    right: 1.5rem;
    color: #aaa;
    font-size: 2rem;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s ease;
}

.close:hover {
    color: #000;
}

.modal-book-details {
    display: grid;
    grid-template-columns: 250px 1fr;
    gap: 3rem;
}

.large-cover-placeholder {
    width: 250px;
    height: 350px;
    background: linear-gradient(135deg, #2d3748 0%, #4a5568 100%);
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4rem;
    color: white;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.modal-book-info h2 {
    font-size: 2.5rem;
    font-weight: 700;
    color: #2d3748;
    margin-bottom: 0.5rem;
}

.modal-book-info .author {
    font-size: 1.3rem;
    color: #718096;
    margin-bottom: 1rem;
}

.rating-detail {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
}

.modal-book-info .description {
    font-size: 1.1rem;
    color: #4a5568;
    line-height: 1.7;
    margin-bottom: 2rem;
}

.book-specs {                
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    margin-bottom: 2rem;
}

.spec {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.spec-label {
    font-weight: 600;
    color: #718096;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.action-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.buy-btn-large {
    background: linear-gradient(135deg, #c9a96e 0%, #b8935a 100%);
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(201, 169, 110, 0.3);
    /* Идеальное выравнивание текста */
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex: 1;
    justify-content: center;
    min-width: 200px;
    text-align: center;
    white-space: nowrap;
    line-height: 1;
}

.buy-btn-large:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(201, 169, 110, 0.4);
}

.read-sample-btn {
    background: transparent;
    color: #c9a96e;
    border: 2px solid #c9a96e;
    padding: 1rem 2rem;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex: 1;
    justify-content: center;
    min-width: 200px;
}

.read-sample-btn:hover {
    background: #c9a96e;
    color: white;
    transform: translateY(-2px);
}

/* Стили для уведомлений */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: white;
    padding: 1rem 1.5rem;
    border-radius: 10px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    z-index: 1001;
    transform: translateX(400px);
    transition: transform 0.3s ease;
    border-left: 4px solid #c9a96e;
}

.notification.success {
    border-left-color: #48bb78;
}

.notification.error {
    border-left-color: #f56565;
}

.notification.info {
    border-left-color: #718096;
}

.notification.show {
    transform: translateX(0);
}

.notification-content {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.notification i {
    font-size: 1.2rem;
}

.notification.success i {
    color: #48bb78;
}

.notification.error i {
    color: #f56565;
}

.notification.info i {
    color: #718096;
}

/* Стили модального окна оплаты */
.payment-modal .modal-content {
    max-width: 500px;
}

.payment-header {
    text-align: center;
    margin-bottom: 2rem;
}

.book-summary {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: #f7fafc;
    padding: 1rem;
    border-radius: 10px;
    margin-top: 1rem;
}

.book-summary img {
    width: 60px;
    height: 80px;
    border-radius: 5px;
}

.book-summary h3 {
    margin: 0;
    font-size: 1.1rem;
}

.book-summary p {
    margin: 0.25rem 0;
    color: #718096;
}

.book-summary .price {
    font-weight: 600;
    color: #c9a96e;
    font-size: 1.2rem;
}

.payment-methods h3 {
    margin-bottom: 1.5rem;
    text-align: center;
}

.yukassa-info {
    background: linear-gradient(135deg, #fff8f0 0%, #fff 100%);
    padding: 2.5rem;
    border-radius: 16px;
    text-align: center;
    margin-bottom: 2rem;
    border: 2px solid #bc985f;
    box-shadow: 0 4px 15px rgba(188, 152, 95, 0.1);
}

.yukassa-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.yukassa-logo i {
    font-size: 2.5rem;
    color: #bc985f;
    background: linear-gradient(135deg, #bc985f 0%, #d4af6a 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.yukassa-logo span {
    font-size: 1.8rem;
    font-weight: 700;
    color: #716865;
    letter-spacing: -0.5px;
}

.yukassa-description {
    color: #716865;
    font-size: 1.05rem;
    margin: 0;
    line-height: 1.6;
    font-weight: 500;
}

.pay-button {
    width: 100%;
    background: linear-gradient(135deg, #bc985f 0%, #a8824e 100%);
    color: white;
    border: none;
    padding: 1.2rem;
    border-radius: 12px;
    font-size: 1.15rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    box-shadow: 0 4px 20px rgba(188, 152, 95, 0.3);
}

.yukassa-pay {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    box-shadow: 0 4px 15px rgba(79, 172, 254, 0.3);
    font-size: 1.2rem;
    padding: 1.25rem;
}

.yukassa-pay:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(79, 172, 254, 0.4);
}

.pay-button:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(188, 152, 95, 0.45);
    background: linear-gradient(135deg, #d4af6a 0%, #bc985f 100%);
}

.pay-button:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

/* Модальное окно отрывка */
.sample-modal .modal-content {
    max-width: 800px;
    max-height: 90vh;
}

.sample-header {
    text-align: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e2e8f0;
}

.sample-text {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #2d3748;
    white-space: pre-line;
    position: relative;
    max-height: 60vh;
    overflow-y: auto;
}

.sample-fade {
    position: sticky;
    bottom: 0;
    background: linear-gradient(transparent, white 50%);
    padding: 2rem 0 1rem;
    text-align: center;
}

.buy-full-btn {
    background: linear-gradient(135deg, #c9a96e 0%, #b8935a 100%);
    color: white;
    border: none;
    padding: 0.75rem 2rem;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 1rem;
    /* Фиксим выравнивание текста */
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    white-space: nowrap;
    min-width: 200px;
}

.buy-full-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(201, 169, 110, 0.4);
}

/* Модальные окна авторизации */
.auth-modal .modal-content {
    max-width: 400px;
    padding: 2rem;
}

.auth-header {
    text-align: center;
    margin-bottom: 2rem;
}

.auth-header h2 {
    font-size: 1.8rem;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 0.5rem;
}

.auth-header p {
    color: #718096;
    font-size: 0.95rem;
}

.auth-form .form-group {
    margin-bottom: 1.5rem;
}

.auth-form label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #4a5568;
    font-size: 0.9rem;
}

.auth-form input {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.auth-form input:focus {
    outline: none;
    border-color: #c9a96e;
}

.auth-submit-btn {
    width: 100%;
    background: linear-gradient(135deg, #c9a96e 0%, #b8935a 100%);
    color: white;
    border: none;
    padding: 1rem;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.auth-submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(201, 169, 110, 0.4);
}

.auth-switch {
    text-align: center;
    color: #718096;
    font-size: 0.9rem;
}

.auth-switch a {
    color: #c9a96e;
    text-decoration: none;
    font-weight: 500;
}

.auth-switch a:hover {
    text-decoration: underline;
}

/* Модальное окно профиля */
.profile-modal .modal-content {
    max-width: 600px;
    padding: 2rem;
}

.profile-header {
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 2rem;
    margin-bottom: 2rem;
}

.profile-header h2 {
    font-size: 1.8rem;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 1.5rem;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.user-avatar {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #c9a96e 0%, #b8935a 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: white;
}

.user-details h3 {
    font-size: 1.2rem;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 0.25rem;
}

.user-details p {
    color: #718096;
    font-size: 0.9rem;
}

.profile-content-section h3 {
    font-size: 1.3rem;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 1rem;
}

.user-library {
    min-height: 150px;
    background: #f8f9fa;
    border-radius: 10px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.empty-library {
    text-align: center;
    color: #718096;
    font-style: italic;
}

.library-book {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: white;
    border-radius: 10px;
    margin-bottom: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.library-book:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.library-book-cover {
    width: 50px;
    height: 70px;
    background: linear-gradient(135deg, #c9a96e 0%, #b8935a 100%);
    border-radius: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
}

.library-book-info h4 {
    font-size: 1rem;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 0.25rem;
}

.library-book-info p {
    color: #718096;
    font-size: 0.9rem;
}

/* Стили для кнопки выхода в профиле */
.profile-actions .logout-btn {
    background: #e53e3e;
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 1rem;
}

.profile-actions .logout-btn:hover {
    background: #c53030;
    transform: translateY(-2px);
}

/* Адаптивность */
@media (max-width: 768px) {
    .hero-section {
        height: 100vh;
        min-height: 500px;
    }
    
    .book-presentation {
        padding: 2rem;
        margin: 1rem;
    }
    
    .main-title {
        font-size: 2rem;
    }
    
    .main-description {
        font-size: 1rem;
    }
    
    .action-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .btn-primary,
    .btn-secondary {
        width: 100%;
        max-width: 300px;
    }
    
    .header-content {
        flex-direction: column;
        gap: 1rem;
    }
    
    .nav {
        order: 1;
        width: 100%;
        justify-content: center;
    }
    
    .header-actions {
        order: 2;
        flex-wrap: wrap;
        justify-content: center;
        gap: 0.5rem;
    }
    
    .auth-btn {
        padding: 0.5rem 1rem;
        font-size: 0.8rem;
    }
    
    .logout-btn {
        min-width: 44px;
    }
    
    .auth-btn span {
        display: none;
    }
    
    .details-content {
        padding: 0 1rem;
    }
    
    .book-specs h2 {
        font-size: 2rem;
        margin-bottom: 2rem;
    }
    
    .specs-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .spec-item {
        padding: 1rem;
        flex-direction: column;
        text-align: center;
        gap: 0.5rem;
    }
    
    .spec-label {
        min-width: auto;
        font-size: 0.9rem;
    }
    
    .spec-value {
        text-align: center;
        font-size: 1.1rem;
    }
    
    .book-description h3 {
        font-size: 1.5rem;
    }
    
    .book-description p {
        font-size: 1rem;
        text-align: left;
    }
    
    .book-specs .rating-section {
        flex-direction: column;
        gap: 1rem;
        padding: 1rem;
        margin: 1.5rem 0;
    }
    
    .stars {
        font-size: 1.3rem;
    }
    
    .rating-text {
        font-size: 1rem;
    }
    
    .modal-book-details {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .large-cover-placeholder {
        margin: 0 auto;
    }
    
    .action-buttons {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .book-presentation {
        padding: 1.5rem;
    }
    
    .main-title {
        font-size: 1.8rem;
    }
    
    .modal-content {
        margin: 5% auto;
        padding: 2rem;
        width: 95%;
    }
    
    .specs-grid {
        gap: 0.5rem;
    }
    
    .spec-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    /* Фиксим кнопки на мобильных */
    .buy-full-btn {
        width: 100%;
        min-width: auto;
        font-size: 0.9rem;
        padding: 0.75rem 1rem;
    }
    
    .buy-btn-large {
        font-size: 1rem;
        padding: 0.875rem 1.5rem;
        min-width: auto;
        width: 100%;
    }
    
    .pay-button {
        font-size: 1rem;
        padding: 0.875rem;
    }
}

/* Футер с реквизитами */
.site-footer {
    background: #716865;
    color: #ecf0f1;
    padding: 2rem 0 1rem;
    margin-top: auto;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    text-align: center;
}

.footer-requisites {
    margin-bottom: 1.5rem;
}

.footer-requisites h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: #ecf0f1;
}

.requisites-info {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    font-size: 0.95rem;
    color: #bdc3c7;
}

.requisites-info p {
    margin: 0.25rem 0;
}

.requisites-info strong {
    color: #ecf0f1;
    font-weight: 500;
}

.footer-copyright {
    padding-top: 1rem;
    border-top: 1px solid rgba(236, 240, 241, 0.1);
    font-size: 0.875rem;
    color: #95a5a6;
}

@media (max-width: 768px) {
    .site-footer {
        padding: 1.5rem 0 0.75rem;
    }
    
    .footer-requisites h3 {
        font-size: 1rem;
    }
    
    .requisites-info {
        font-size: 0.875rem;
    }
}