/* ============================================
   TABLET STYLES
   769px - 1024px
   ============================================ */

@media (min-width: 769px) and (max-width: 1024px) {
    html, body {
        overflow-x: hidden;
        width: 100%;
        max-width: 100%;
    }

    /* === HEADER === */
    .header__container {
        gap: 24px;
        padding: 8px 8px 8px 12px;
    }

    .header__navigation {
        gap: 32px !important;
    }

    .header__nav-link {
        margin: 0 12px !important;
    }

    /* Hide mobile elements */
    .header__button--mobile,
    .header__telegram-link--mobile {
        display: none !important;
    }

    /* Show desktop telegram link */
    .header__button-container .header__telegram-link:not(.header__telegram-link--mobile) {
        display: flex !important;
    }

    /* === HERO === */
    .hero__text-container {
        max-width: 100%;
        padding: 0 32px;
        margin-top: 180px;
        box-sizing: border-box;
    }

    .hero__main-title {
        font-size: 48px;
    }

    .hero__subtitle {
        font-size: 18px;
    }

    .hero__image-container {
        max-width: 100%;
        margin: 0 24px;
    }

    /* === HERO PRESS === */
    .hero__press {
        gap: 28px;
        padding-top: 16px;
    }

    .hero__press-title {
        font-size: 22px;
    }

    .hero__press-logos {
        gap: 24px;
    }

    .hero__press-logo {
        padding: 20px 32px;
        min-width: 180px;
    }

    .hero__press-logo-img {
        height: 36px;
        max-width: 200px;
    }

    .hero__press-logo:nth-child(1) .hero__press-logo-img {
        height: 52px;
    }

    .hero__press-logo:nth-child(2) .hero__press-logo-img {
        height: 48px;
    }

    .hero__press-logo:nth-child(3) .hero__press-logo-img {
        height: 28px;
    }

    .hero__press-logo:nth-child(4) .hero__press-logo-img {
        height: 32px;
    }

    /* === BENEFITS === */
    .benefits {
        padding: 80px 24px;
        gap: 40px;
    }

    .benefits__title {
        font-size: 40px;
    }

    .benefits__cards {
        flex-direction: row;
        gap: 16px;
        overflow-x: auto;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
        scroll-snap-type: x mandatory;
        padding: 0 16px 16px;
        margin: 0 -16px;
        scrollbar-width: none;
    }

    .benefits__cards::-webkit-scrollbar {
        display: none;
    }

    .benefits__card {
        flex-direction: column;
        align-items: flex-start;
        padding: 24px;
        gap: 16px;
        min-width: 280px;
        flex-shrink: 0;
        scroll-snap-align: start;
    }

    .benefits__card-text {
        text-align: left;
        align-items: flex-start;
    }

    .benefits__card-title {
        text-align: left;
        font-size: 24px;
        margin-bottom: 0;
    }

    .benefits__card-subtitle {
        text-align: left;
    }

    .benefits__card-accent {
        width: 64px;
        height: 7px;
    }

    /* === FEATURES === */
    .features {
        padding: 80px 24px;
        gap: 40px;
    }

    .features__title {
        font-size: 40px;
    }

    .features__container {
        flex-wrap: wrap;
    }

    .features__card {
        flex: 1 1 calc(50% - 12px);
        min-width: 280px;
    }

    /* === HOW IT WORKS STEPS === */
    .how-it-works-steps {
        padding: 60px 24px;
        gap: 20px;
    }

    .how-it-works-steps__title {
        font-size: 36px;
    }






    /* === LIBRARY === */
    .library {
        padding: 60px 24px;
        gap: 40px;
    }

    .library__title {
        font-size: 40px;
    }

    .library__main-content {
        flex-direction: column;
        gap: 8px;
    }

    .library__books-block {
        width: 100%;
    }

    .library__books-list {
        height: auto;
        min-height: 200px;
        padding: 0;
    }

    .library__books-image {
        max-height: none;
        height: auto;
        width: 100%;
        border-radius: 16px;
    }

    /* === HIGHLIGHT === */
    /* === EPUB UPLOAD === */
    .epub-upload {
        padding: 60px 24px;
        gap: 40px;
    }

    .epub-upload__title {
        font-size: 40px;
    }

    .epub-upload__main-content {
        flex-direction: column;
    }

    .epub-upload__image-block {
        width: 100%;
    }

    .epub-upload__image-container {
        height: 400px;
    }

    .epub-upload__info-cards {
        flex-direction: column;
    }

    .highlight {
        padding: 60px 24px;
        gap: 40px;
    }

    .highlight__title {
        font-size: 40px;
    }

    .highlight__main-content {
        flex-direction: column;
    }

    .highlight__image-block {
        width: 100%;
    }

    .highlight__image-container {
        height: auto;
        min-height: 400px;
        padding: 0;
    }

    /* === MEANING === */
    .meaning {
        padding: 60px 24px;
        gap: 40px;
    }

    .meaning__title {
        font-size: 40px;
    }

    .meaning__image-container {
        height: auto;
        min-height: 400px;
        padding: 56px 24px 0;
    }

    .meaning__content {
        gap: 0;
    }

    .meaning__footer {
        flex-direction: row;
    }

    .features-split__container {
        gap: 24px;
    }

    .features-split__content {
        gap: 12px;
        width: 80%;
    }

    .features-split__title {
        font-size: 32px;
    }

    .features-split__item {
        padding: 14px;
        gap: 10px;
    }

    .features-split__item-title {
        font-size: 16px;
    }

    .features-split__item-description {
        font-size: 13px;
    }

    .features-split__icon {
        width: 40px;
        height: 40px;
        min-width: 40px;
    }

    .features-split__image {
        height: auto;
        min-height: 350px;
        padding: 20px 0;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .features-split__image-img {
        width: 100%;
        max-width: none;
        height: auto;
    }

    /* === VIDEO SECTION === */
    .video-section {
        padding: 60px 24px;
        border-radius: 0;
        gap: 40px;
    }

    .video-section__title {
        font-size: 40px;
    }

    .video-section__image-wrapper {
        border-radius: 16px;
    }

    .video-section__play-button {
        width: 112px;
        height: 112px;
    }

    .video-section__play-icon {
        width: 36px;
        height: 36px;
    }

    /* === PHILOSOPHER === */
    .philosopher {
        display: none !important;
    }

    /* === FEATURES GRID === */
    .features-grid {
        padding: 80px 24px;
        margin-top: 0;
        gap: 40px;
    }

    .features-grid__title {
        font-size: 40px;
    }

    .features-grid__container {
        flex-wrap: wrap;
    }

    .features-grid__card {
        flex: 1 1 calc(50% - 12px);
        min-width: 280px;
    }

    /* === BOOKS === */
    .books {
        padding: 80px 24px;
        gap: 40px;
    }

    .books__title {
        font-size: 40px;
    }

    .books__button {
        font-weight: 500;
    }

    .books__container {
        justify-content: flex-start !important;
        gap: 16px !important;
        height: auto !important;
        overflow-x: auto !important;
        padding: 8px 4px 16px !important;
        scroll-snap-type: x mandatory;
        -webkit-overflow-scrolling: touch;
    }

    .books__card {
        flex: 0 0 auto !important;
        width: 180px !important;
        height: 250px !important;
        padding: 0 !important;
        border-radius: 18px !important;
        box-shadow: none !important;
        scroll-snap-align: start;
        cursor: default !important;
        transform: none !important;
        pointer-events: none;
    }

    .books__card::before,
    .books__card-content,
    .books__card-spine-icons,
    .books__card-name,
    .books__card-description {
        display: none !important;
    }

    .books__card--featured,
    .books__card--purple,
    .books__card--cyan,
    .books__card--yellow,
    .books__card--blue,
    .books__card--pink,
    .books__card--purple-pink {
        background-size: cover !important;
        background-position: center !important;
        background-repeat: no-repeat !important;
    }

    .books__card--featured { background-image: url('../img/book_onegin.webp') !important; }
    .books__card--purple { background-image: url('../img/book_geroy.webp') !important; }
    .books__card--cyan { background-image: url('../img/book_otci.webp') !important; }
    .books__card--yellow { background-image: url('../img/book_prestuplenie.webp') !important; }
    .books__card--blue { background-image: url('../img/book_voina.webp') !important; }
    .books__card--pink { background-image: url('../img/book_dushi.webp') !important; }
    .books__card--purple-pink { background-image: url('../img/book_oblomov.webp') !important; }

    .books__scroll-btn {
        display: none !important;
    }

    /* === TESTIMONIALS === */
    .testimonials {
        padding: 80px 24px;
        gap: 40px;
    }

    .testimonials__title {
        font-size: 40px;
        padding: 0;
    }

    .testimonials__container {
        padding: 0;
    }

    .testimonials__card {
        width: 480px;
        min-width: 480px;
    }

    .testimonials__scroll-btn--left {
        left: 12px;
    }

    .testimonials__scroll-btn--right {
        right: 12px;
    }

    /* === SUBSCRIPTION === */
    .subscription {
        padding: 80px 24px;
        gap: 40px;
    }

    .subscription__title {
        font-size: 40px;
    }

    .subscription__container {
        flex-direction: column;
        width: 100%;
        gap: 20px;
    }

    .subscription__card {
        height: auto;
        min-height: auto;
        width: 100%;
        padding: 24px;
        gap: 24px;
    }

    .subscription__price {
        font-size: 24px;
    }

    .subscription__card:nth-child(2) .subscription__price,
    .subscription__card:nth-child(3) .subscription__price {
        font-size: 32px;
    }

    /* === FAQ === */
    .faq {
        padding: 80px 24px;
        gap: 40px;
    }

    .faq__title {
        font-size: 40px;
    }

    .faq__container {
        width: 100%;
    }

    /* === NOT DOING === */
    .not-doing {
        padding: 80px 24px;
        gap: 40px;
    }

    .not-doing__title {
        font-size: 40px;
    }

    .not-doing__grid {
        width: 100%;
    }

    /* === CTA === */
    .cta__title {
        font-size: 48px;
    }

    .cta__footer {
        flex-direction: row;
        text-align: left;
    }

    .cta__footer-text {
        text-align: left;
    }

    .cta__footer-link {
        text-align: left;
    }
}

/* === Touch device optimizations === */
@media (hover: none) and (pointer: coarse) {
    .testimonials__scroll-btn,
    .books__scroll-btn {
        display: none !important;
    }

    /* Increase touch targets */
    .header__button,
    .hero__button,
    .benefits__card,
    .features__card,
    .faq__item {
        min-height: 44px;
    }

    .header__nav-link {
        padding: 12px 0;
    }

    /* Remove hover effects */
    .header__nav-link:hover,
    .header__button:hover,
    .hero__button:hover {
        opacity: 1;
        background-color: inherit;
    }

    /* Active states for buttons */
    .header__button:active,
    .hero__button:active {
        transform: scale(0.98);
        transition: transform 0.1s ease;
    }
}
