/* ========================= 
   АНИМАЦИИ
========================= */

/* Базовые стили анимации */
[data-animation] {
    opacity: 0;
    transform: translateY(50px);
    transition: all 0.6s ease;
}

[data-animation].animated {
    opacity: 1;
    transform: translateY(0);
}

/* Анимации появления */
.animated.fadeInUp {
    animation: fadeInUp 0.6s ease forwards;
}

.animated.fadeInLeft {
    animation: fadeInLeft 0.6s ease forwards;
}

.animated.fadeInRight {
    animation: fadeInRight 0.6s ease forwards;
}

.animated.slideInLeft {
    animation: slideInLeft 0.6s ease forwards;
}

.animated.slideInRight {
    animation: slideInRight 0.6s ease forwards;
}

.animated.rollIn {
    animation: rollIn 0.8s ease forwards;
}

/* Keyframes */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-100px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(100px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes rollIn {
    from {
        opacity: 0;
        transform: translateX(-100%) rotate(-120deg);
    }
    to {
        opacity: 1;
        transform: translateX(0) rotate(0deg);
    }
}

/* ========================= 
   ЛОГОТИПЫ ПАРТНЕРОВ
========================= */

.cmsmasters_clients_grid_wrap {
    width: 100%;
    margin-top: 30px;
}

.cmsmasters_clients_grid {
    display: flex;
    justify-content: center;
    width: 100%;
}

.cmsmasters_clients_items {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    max-width: 900px;
    margin: 0 auto;
    width: 100%;
}

.cmsmasters_clients_item {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 140px;
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 8px;
    padding: 20px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: relative;
    overflow: hidden;
}

.cmsmasters_clients_item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
    transition: left 0.5s;
}

.cmsmasters_clients_item:hover::before {
    left: 100%;
}

.cmsmasters_clients_item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    border-color: #ddd;
}

.cmsmasters_clients_item img {
    max-width: 100%;
    max-height: 80px;
    width: auto;
    height: auto;
    object-fit: contain;
    filter: grayscale(70%) opacity(0.8);
    transition: all 0.3s ease;
}

.cmsmasters_clients_item:hover img {
    filter: grayscale(0%) opacity(1);
    transform: scale(1.05);
}

/* ========================= 
   АДАПТИВНОСТЬ
========================= */

@media (max-width: 1024px) {
    .cmsmasters_clients_items {
        grid-template-columns: repeat(3, 1fr);
        gap: 25px;
    }
}

@media (max-width: 768px) {
    .cmsmasters_clients_items {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
    
    .cmsmasters_clients_item {
        height: 120px;
        padding: 15px;
    }
    
    .cmsmasters_clients_item img {
        max-height: 70px;
    }
}

@media (max-width: 480px) {
    .cmsmasters_clients_items {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .cmsmasters_clients_item {
        height: 100px;
        padding: 10px;
    }
    
    .cmsmasters_clients_item img {
        max-height: 60px;
    }
}

/* ========================= 
   ДОПОЛНИТЕЛЬНЫЕ АНИМАЦИИ
========================= */

/* Анимация для изображений */
.cmsmasters_img[data-animation] {
    opacity: 0;
    transition: all 0.8s ease;
}

.cmsmasters_img[data-animation].animated {
    opacity: 1;
}

/* Анимация для кнопок */
.cmsmasters_button {
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.cmsmasters_button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: rgba(255,255,255,0.2);
    transition: left 0.3s ease;
    z-index: -1;
}

.cmsmasters_button:hover::before {
    left: 0;
}

/* Анимация для иконок в списках */
.cmsmasters_icon_list_icon {
    transition: all 0.3s ease;
}

.cmsmasters_icon_list_item:hover .cmsmasters_icon_list_icon {
    transform: rotate(5deg) scale(1.1);
}

/* ========================= 
   PERFORMANCE OPTIMIZATION
========================= */

/* Улучшение производительности анимаций */
[data-animation],
.cmsmasters_clients_item,
.cmsmasters_button,
.cmsmasters_icon_list_icon {
    will-change: transform, opacity;
}

/* Отключение анимаций для пользователей с ограниченными возможностями */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    [data-animation] {
        opacity: 1 !important;
        transform: none !important;
    }
}

/* ========================= 
   ЗАГРУЗОЧНЫЕ СОСТОЯНИЯ
========================= */

/* Состояние загрузки для изображений */
.cmsmasters_clients_item img {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
}

.cmsmasters_clients_item img[src] {
    background: none;
}

/* Состояние загрузки с анимацией скелетона */
@keyframes skeleton {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

.loading .cmsmasters_clients_item img:not([src]) {
    animation: skeleton 1.5s ease-in-out infinite;
}

/* ========================= 
   ПАРТНЕРЫ - СТАТИЧНАЯ СЕТКА
========================= */

.partners-grid-container {
    width: 100%;
    margin-top: 40px;
    padding: 0 20px;
}

.partners-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    max-width: 1000px;
    margin: 0 auto;
}

.partner-logo-item {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 25px;
    background: #ffffff;
    border: 2px solid #f0f0f0;
    border-radius: 10px;
    height: 150px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
    position: relative;
    overflow: hidden;
}

.partner-logo-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, transparent 0%, rgba(52,52,52,0.05) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.partner-logo-item:hover::before {
    opacity: 1;
}

.partner-logo-item:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.15);
    border-color: #e0e0e0;
}

.partner-logo-item img {
    max-width: 100%;
    max-height: 90px;
    width: auto;
    height: auto;
    object-fit: contain;
    filter: grayscale(60%) opacity(0.9);
    transition: all 0.3s ease;
    z-index: 1;
    position: relative;
}

.partner-logo-item:hover img {
    filter: grayscale(0%) opacity(1);
    transform: scale(1.05);
}

/* Адаптивность */
@media (max-width: 1024px) {
    .partners-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 25px;
    }
    
    .partner-logo-item {
        height: 130px;
        padding: 20px;
    }
    
    .partner-logo-item img {
        max-height: 80px;
    }
}

@media (max-width: 768px) {
    .partners-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
    
    .partner-logo-item {
        height: 120px;
        padding: 15px;
    }
    
    .partner-logo-item img {
        max-height: 70px;
    }
    
    .partners-grid-container {
        padding: 0 15px;
    }
}

@media (max-width: 480px) {
    .partners-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .partner-logo-item {
        height: 100px;
        padding: 10px;
    }
    
    .partner-logo-item img {
        max-height: 60px;
    }
    
    .partners-grid-container {
        padding: 0 10px;
    }
}


.hero-content * {
    color: #ffffff !important;
}