body {
    font-family: 'Arial', sans-serif;
    background-color: #f4f4f4;
}

.app-container {
    max-width: 1280px !important;
    margin: 0 auto;
    padding: 20px;
    box-sizing: border-box !important;
}

.app-info {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 20px;
    background-color: #fff;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    border-radius: 10px;
    gap: 15px;
}

.app-icon {
    display: flex;
    flex-direction: column;
    align-items: center;
    background-color: #ffffff;
    padding: 20px;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    margin: 0 auto;
    transition: box-shadow 0.3s;
}

.app-icon:hover {
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.app-icon img {
    width: 100px;
    height: 100px;
    margin-bottom: 20px;
    border-radius: 20%; /* Добавляем небольшое закругление к иконке */
    transition: transform 0.3s;
}

.app-icon img:hover {
    transform: scale(1.1); /* При наведении увеличиваем иконку */
}

.app-download-btn {
    background-color: #6200ea;
    color: #fff;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s, transform 0.3s;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    font-weight: 500; /* Делаем текст кнопки немного жирнее */
}

.app-download-btn:hover {
    background-color: #3700b3;
    transform: translateY(-2px); /* При наведении поднимаем кнопку немного вверх */
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.app-details {
    font-size: 14px;
    background-color: #ffffff;
    padding: 20px;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    margin: 0 auto;
    flex-grow: 1;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #e0e0e0;
    padding: 10px 0;
    transition: background-color 0.3s;
}

.detail-row:hover {
    background-color: #f5f5f5;
}

.detail-label {
    font-weight: 500;
    color: #333;
    flex: 1;
}

.detail-value {
    flex: 2;
    text-align: right;
    color: #555;
}

.detail-value a {
    color: #6200ea;
    text-decoration: dotted underline;
}

.app-rating {
    font-size: 14px;
    background-color: #ffffff;
    padding: 20px;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    margin: 0 auto;
    text-align: center;
}

.app-rating > p {
    margin: 0 auto !important;
}

.app-rating > p:nth-child(3) {
    color: #b6b6b6;
}

.stars {
    display: flex;
    justify-content: center;
    margin-bottom: 15px;
}

.star {
    font-size: 25px;
    cursor: pointer;
    color: #e0e0e0; /* Серый цвет для неактивных звезд */
    transition: color 0.3s;
}

.star.active {
    color: #ffd700;
}

.average-rating-badge {
    display: inline-block;
    background-color: #6200ea;
    color: #fff;
    padding: 5px 15px;
    border-radius: 20px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    margin-top: 10px;
}

.average-rating-badge span {
    font-weight: bold;
    font-size: 1.2em;
}

@media (max-width: 768px) {
    .app-info {
        flex-wrap: wrap;
    }

    .app-info #download-btn {
        display: none;
    }
}

@media (max-width: 480px) {
    .app-info .app-icon img {
        width: 150px;
        height: 150px;
    }

    .app-info .app-rating {
        flex-basis: 100%;
    }
}

/* slider styles */
.app-gallery {
    position: relative;
    max-width: 1200px;
    margin: 20px auto;
    overflow: hidden;
}

.slider-container {
    overflow-x: scroll;
    max-height: 400px;
    height: 100%;
    position: relative;
    white-space: nowrap;
    width: calc(100% - 40px);
    margin: 0 auto;
}

.slider-wrapper {
    display: flex;
    transition: all 0.3s;
}

.slide {
    display: inline-block;
    min-width: fit-content;
    position: relative;
    overflow: hidden;
    margin: 0 5px;
    border-radius: 10px;
}

.slide img {
    height: 100%;
    max-height: 400px;
    width: 100%;
    display: block;
    margin: 0 auto;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: #6200ea;
    color: #fff;
    border: none;
    padding: 10px;
    cursor: pointer;
    transition: background-color 0.3s;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    text-align: center;
    line-height: 20px;
    z-index: 10;
}

.slider-btn:hover {
    background-color: #3700b3;
}

.slider-btn > img {
    position: absolute;
    width: 30px;
    height: 30px;
    top: 5px;
    left: 10px;
}

.slider-btn-prev {
    left: 0;
}

.slider-btn-next {
    right: 0;
}

.slider-btn-next > img {
    left: 8px;
}

@media (max-width: 768px) {
    .slider-container {
        width: 100%;
    }
}

/* Video block */
.app-video {
    display: flex;
    justify-content: center;
    margin: 20px auto;
}

.app-video iframe {
    border-radius: 10px;
}

/* Download block */
.app-download {
    display: flex;
    flex-direction: column;
    text-align: center;
    padding: 40px 0;
    background-color: #ffffff;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    border-radius: 10px;
}

.app-download-buttons {
    position: relative;
    display: flex;
    flex-direction: column;
    text-align: center;
    gap: 20px;
}

body .app-download-buttons .file-download-button,
body .app-download-buttons .pmp-light-button {
    pointer-events: auto;
}

body .app-download-buttons .file-download-button.inactive {
    background-color: #797979;
    pointer-events: none;
}

body .app-download-buttons .pmp-light-button.inactive {
    border: 1px solid #797979;
    color: #797979 !important;
    pointer-events: none;
}

.app-download-buttons .file-download-button .app-loader,
.app-download-buttons .pmp-light-button .app-loader {
    display: none;
}

.app-download-buttons .file-download-button.inactive .app-loader,
.app-download-buttons .pmp-light-button.inactive .app-loader {
    display: inline-block;
}

.app-download-buttons .file-download-button img,
.app-download-buttons .pmp-light-button img {
    display: inline-block;
}

.app-download-buttons .file-download-button.inactive img,
.app-download-buttons .pmp-light-button.inactive img {
    display: none;
}

.app-download > p {
    font-size: 24px;
    margin: 15px;
    color: #333;
}

.download-button {
    margin: 15px;
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
    position: relative;
    text-align: left;
    text-decoration: none;
    background-color: #6200ea;
    color: #ffffff !important;
    padding: 12px 24px;
    font-size: 24px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s, transform 0.2s, box-shadow 0.2s;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

body article .app-container .app-download a {
    text-decoration: none !important;
}

.download-button:hover {
    background-color: #3700b3;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.download-button:active {
    background-color: #27006e;
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.download-button .btn-text {
    max-width: calc(100% - 65px);
    flex-basis: calc(100% - 60px);
    font-size: 30px;
}

.file-size, .downloads-count {
    display: block;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.8);
    padding: 0;
    margin: 0;
}

.file-size:before, .downloads-count:before {
    content: '|';
    margin: 0 10px;
    color: rgba(255, 255, 255, 0.5);
}

.file-size:before {
    content: none;
}

.pmp-light-button {
    background: #ffffff;
    border: 1px solid #6200ea;
    color: #6200ea !important;
}

.pmp-light-button:hover {
    background-color: rgba(255, 255, 255, 0.5);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.pmp-light-button:active {
    background-color: rgba(255, 255, 255);
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.pmp-gray-button {
    background: #ffffff;
    border: 1px solid #797979;
    color: #797979 !important;
}

.pmp-gray-button:hover {
    background-color: rgba(255, 255, 255, 0.7);
}

.pmp-gray-button:active {
    background-color: rgba(255, 255, 255, 0.4);
}

@media (max-width: 768px) {
    .download-button {
        justify-content: center;
    }

    .download-button .btn-text {
        flex-basis: 100%;
        max-width: 100%;
        text-align: center;
    }
}

/* Cache block */
.cache-faq {
    background-color: #ffffff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    max-width: 600px;
    margin: 20px auto;
}

.cache-title {
    font-size: 24px;
    font-weight: 500;
    color: #27006e;
    margin-bottom: 20px;
    border-bottom: 2px solid #e0e0e0;
    padding-bottom: 10px;
}

.cache-content {
    font-size: 16px;
    color: #424242;
    text-align: left;
}

.cache-content ol {
    padding-left: 20px;
    margin-top: 10px;
    counter-reset: list-counter;
    list-style-type: none;
}

.cache-content li {
    margin-bottom: 10px;
    line-height: 1.5;
    position: relative;
}

.cache-content li:before {
    content: counter(list-counter) ".";
    counter-increment: list-counter;
    color: #6200ea;
    font-weight: bold;
    position: absolute;
    left: -25px;
    top: 0;
}

.cache-content a {
    color: #6200ea;
    text-decoration: none;
    transition: color 0.3s ease;
}

.cache-content a:hover {
    color: #3700b3;
}

.cache-content p {
    margin: 0;
}

/* Similar apps block */
.app-grid {
    max-width: 1280px !important;
    display: flex;
    flex-wrap: wrap;
    gap: 16px; /* Расстояние между карточками */
    justify-content: center;
}

.app-card {
    display: flex;
    flex-direction: column;
    position: relative;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    padding: 16px;
    width: calc(25% - 16px); /* Для 4 карточек в ряду */
    box-sizing: border-box;
    transition: transform 0.3s;
    cursor: pointer;
    background: #ffffff;
    text-align: center;
}

.app-card:hover {
    transform: scale(1.05);
}

.app-grid .app-card > a {
    display: flex;
    flex-direction: column;
    flex-basis: 100%;
    text-decoration: none !important;
    color: #6200ea;
}

.app-card > a:hover {
    color: #3700b3;
}

.app-card img {
    width: 100%;
    border-radius: 8px;
    margin-bottom: 16px;
}

.app-card .app-title {
    margin-bottom: 16px;
    font-size: 16px;
    font-weight: 500;
    flex-grow: 1;
}

.card-app-rating {
    position: absolute;
    top: 10px;
    right: 10px;
    background-color: rgba(0, 0, 0, 0.6); /* Полупрозрачный фон для лучшей видимости рейтинга */
    padding: 5px 10px;
    border-radius: 5px;
    color: #fff;
    font-weight: bold;
}

/* Пагинация */
.app-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px 0;
}

.app-pagination .page-numbers {
    display: inline-block;
    padding: 8px 12px;
    margin: 0 4px;
    border-radius: 4px;
    text-decoration: none;
    color: #6200ea;
    background-color: #fff;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

.app-pagination .page-numbers:hover {
    background-color: #f5f5f5;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.app-pagination .page-numbers.current {
    color: #fff;
    background-color: #6200ea;
    box-shadow: none;
}

.app-pagination .page-numbers.dots {
    pointer-events: none;
    background-color: transparent;
    box-shadow: none;
    color: #757575;
}

.app-pagination .prev, .app-pagination .next {
    background-color: #e0e0e0;
    color: #424242;
}

.app-pagination .prev:hover, .app-pagination .next:hover {
    background-color: #bdbdbd;
}

/* Мобильная версия */
@media (max-width: 768px) {
    .app-card {
        width: calc(50% - 16px);
    }
}

@media (max-width: 480px) {
    .app-card {
        width: 100%;
    }
}

/* request update result */
#request-result {
    padding: 20px;
    border-radius: 4px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1), 0 1px 3px rgba(0, 0, 0, 0.2); /* Тени для "поднятого" эффекта */
    background-color: #ffffff;
    max-width: 300px;
    margin: 0 auto;
}

#request-result:empty {
    display: none;
}

/* Стили для текста */
#request-result p {
    margin: 0 0 15px;
    font-size: 16px;
    color: #333;
}

/* Убираем отступ у последнего параграфа */
#request-result p:last-child {
    margin-bottom: 0;
}

/* Стили для зеленого текста */
#request-result p.green {
    color: #4caf50; /* Зеленый цвет из палитры Material Design */
    font-weight: 500; /* Полужирное начертание */
}

#request-result p.red {
    color: #f44336; /* Красный цвет из палитры Material Design */
    font-weight: 500; /* Полужирное начертание для акцентирования внимания */
    border-left: 4px solid #f44336; /* Вертикальная линия слева для дополнительного акцентирования */
    padding-left: 10px; /* Отступ слева, чтобы текст не прилипал к линии */
    background-color: #ffebee; /* Светло-красный фон для контраста */
    border-radius: 4px; /* Скругленные углы для соответствия стилю Material Design */
    margin: 10px 0; /* Отступы сверху и снизу для разделения контента */
}

/* Убираем пустые параграфы */
#request-result p:empty {
    display: none;
}

/* Страница загрузки */
.pmp-download-page .app-info {
    flex-wrap: wrap;
}

body .pmp-download-page .app-info a {
    color: #ffffff;
    text-decoration: none !important;
}

.pmp-download-page .download-button {
    flex-basis: 100%;
}

.pmp-download-page .download-button img {
    margin-right: 0;
}

.pmp-download-page .download-button .btn-text {
    text-align: center;
}

/* related apps */
.related-apps-grid {
    padding: 20px;
    background-color: #ffffff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    border-radius: 4px;
    margin: 30px 0;
}

.related-apps-grid__title {
    font-size: 24px;
    font-weight: 500;
    color: #212121;
    margin-bottom: 30px;
    padding-bottom: 10px;
    position: relative;
    text-transform: uppercase;
}

.related-apps-grid__title:after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 2px;
    background-color: #6200ea; /* Primary color for Material Design */
}

/* LOADER */
.app-loader {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    position: relative;
    animation: approtate 1s linear infinite
}

.app-loader:before, .app-loader:after {
    content: "";
    box-sizing: border-box;
    position: absolute;
    inset: 0;
    border-radius: 50%;
    border: 5px solid #FFF;
    animation: prixClipFix 2s linear infinite;
}

.app-loader:after {
    transform: rotate3d(90, 90, 0, 180deg);
    border-color: #6200ea;
}

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

@keyframes prixClipFix {
    0% {
        clip-path: polygon(50% 50%, 0 0, 0 0, 0 0, 0 0, 0 0)
    }
    50% {
        clip-path: polygon(50% 50%, 0 0, 100% 0, 100% 0, 100% 0, 100% 0)
    }
    75%, 100% {
        clip-path: polygon(50% 50%, 0 0, 100% 0, 100% 100%, 100% 100%, 100% 100%)
    }
}
