/* Page Header */
.page-header {
    padding: 140px 0 80px;
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 50%, #f1f3f4 100%);
    text-align: center;
}

.page-header h1 {
    font-size: 3.5rem;
    font-weight: 900;
    color: var(--primary-black);
    margin-bottom: 20px;
    letter-spacing: -0.02em;
}

.page-header p {
    font-size: 1.3rem;
    color: var(--accent-gray);
    font-weight: 500;
    margin-bottom: 0;
}

/* Cases Gallery */
.cases-gallery {
    padding: 80px 0;
    background-color: var(--primary-white);
}

.case-item {
    cursor: pointer;
    height: 100%;
}

.case-image {
    position: relative;
    border-radius: 15px;
    overflow: hidden;
    height: 300px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: all 0.4s ease;
}

.case-image:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2);
}

.case-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.case-image:hover img {
    transform: scale(1.05);
}

.case-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, rgba(0, 0, 0, 0.7), rgba(156, 54, 130, 0.6));
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: all 0.4s ease;
    color: white;
    text-align: center;
    padding: 20px;
}

.case-image:hover .case-overlay {
    opacity: 1;
}

.case-overlay i {
    font-size: 3rem;
    margin-bottom: 15px;
    color: white;
}

.case-overlay h4 {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: white;
}

.case-overlay p {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 0;
    font-weight: 500;
}

/* Enhanced Lightbox */
.lightbox-info {
    color: white;
    text-align: center;
    margin-top: 25px;
    max-width: 600px;
    padding: 0 20px;
}

.lightbox-info h3 {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 15px;
    color: white;
}

.lightbox-info p {
    font-size: 1.1rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 0;
}

/* Responsive */
@media (max-width: 768px) {
    .page-header {
        padding: 120px 0 60px;
    }
    
    .page-header h1 {
        font-size: 2.5rem;
    }
    
    .page-header p {
        font-size: 1.1rem;
    }
    
    .cases-gallery {
        padding: 60px 0;
    }
    
    .case-image {
        height: 250px;
        margin-bottom: 20px;
    }
    
    .case-overlay i {
        font-size: 2.5rem;
        margin-bottom: 10px;
    }
    
    .case-overlay h4 {
        font-size: 1.1rem;
    }
    
    .case-overlay p {
        font-size: 0.8rem;
    }
    
    .lightbox-info {
        margin-top: 20px;
    }
    
    .lightbox-info h3 {
        font-size: 1.4rem;
        margin-bottom: 10px;
    }
    
    .lightbox-info p {
        font-size: 1rem;
    }
}

@media (max-width: 576px) {
    .page-header {
        padding: 100px 0 40px;
    }
    
    .page-header h1 {
        font-size: 2rem;
    }
    
    .page-header p {
        font-size: 1rem;
    }
    
    .cases-gallery {
        padding: 40px 0;
    }
    
    .case-image {
        height: 200px;
    }
    
    .case-overlay {
        padding: 15px;
    }
    
    .case-overlay i {
        font-size: 2rem;
    }
    
    .lightbox-info h3 {
        font-size: 1.2rem;
    }
    
    .lightbox-info p {
        font-size: 0.9rem;
    }
}



/* Cases Button Section */
.cases-button-section {
    padding: 60px 0;
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 50%, #f1f3f4 100%);
    position: relative;
    overflow: hidden;
}

.cases-button-section::before {
    content: '';
    position: absolute;
    top: -20%;
    left: -10%;
    width: 300px;
    height: 300px;
    background: linear-gradient(45deg, rgba(156, 54, 130, 0.1), rgba(156, 54, 130, 0.03));
    border-radius: 50% 30% 70% 40%;
    transform: rotate(25deg);
    animation: float1 8s ease-in-out infinite;
}

.cases-button-section::after {
    content: '';
    position: absolute;
    top: 60%;
    right: -15%;
    width: 250px;
    height: 250px;
    background: linear-gradient(135deg, rgba(156, 54, 130, 0.08), rgba(156, 54, 130, 0.02));
    clip-path: polygon(30% 0%, 70% 0%, 100% 30%, 100% 70%, 70% 100%, 30% 100%, 0% 70%, 0% 30%);
    transform: rotate(-15deg);
    animation: float2 10s ease-in-out infinite reverse;
}

/* Додаткові геометричні елементи */
.cases-button-section .container::before {
    content: '';
    position: absolute;
    top: 20%;
    right: 20%;
    width: 80px;
    height: 80px;
    background: rgba(156, 54, 130, 0.06);
    transform: rotate(45deg);
    border-radius: 20% 80% 20% 80%;
    animation: spin 15s linear infinite;
}

.cases-button-section .container::after {
    content: '';
    position: absolute;
    bottom: 30%;
    left: 15%;
    width: 60px;
    height: 60px;
    background: linear-gradient(45deg, rgba(156, 54, 130, 0.1), transparent);
    clip-path: polygon(50% 0%, 0% 100%, 100% 100%);
    animation: pulse 6s ease-in-out infinite;
}

/* Анімації */
@keyframes float1 {
    0%, 100% {
        transform: rotate(25deg) translateY(0px) scale(1);
    }
    50% {
        transform: rotate(35deg) translateY(-20px) scale(1.05);
    }
}

@keyframes float2 {
    0%, 100% {
        transform: rotate(-15deg) translateX(0px) scale(1);
    }
    50% {
        transform: rotate(-25deg) translateX(15px) scale(0.95);
    }
}

@keyframes spin {
    0% {
        transform: rotate(45deg);
    }
    100% {
        transform: rotate(405deg);
    }
}

@keyframes pulse {
    0%, 100% {
        opacity: 0.6;
        transform: scale(1);
    }
    50% {
        opacity: 1;
        transform: scale(1.1);
    }
}


.cases-button-content {
    position: relative;
    z-index: 2;
}

.cases-subtitle {
    font-size: 1.3rem;
    color: var(--accent-gray);
    margin-bottom: 2rem;
    font-weight: 500;
    line-height: 1.6;
}

.btn-custom-cases {
    background: linear-gradient(135deg, var(--accent-purple), #b8469a);
    border: none;
    padding: 18px 45px;
    font-weight: 700;
    font-size: 16px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: 12px;
    color: white;
    transition: all 0.4s ease;
    box-shadow: 0 8px 30px rgba(156, 54, 130, 0.25);
    position: relative;
    overflow: hidden;
    border: 2px solid transparent;
}

.btn-custom-cases::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
}

.btn-custom-cases:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 40px rgba(156, 54, 130, 0.4);
    color: white;
    border-color: rgba(255, 255, 255, 0.2);
}

.btn-custom-cases:hover::before {
    left: 100%;
}

.btn-custom-cases:active {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(156, 54, 130, 0.5);
}

/* Пульсація іконки камери */
.btn-custom-cases i {
    animation: cameraIcon 2s ease-in-out infinite;
}

@keyframes cameraIcon {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

.btn-custom-cases:hover i {
    animation: none;
    transform: scale(1.1);
}

/* Responsive */
@media (max-width: 768px) {
    .cases-button-section {
        padding: 50px 0;
    }
    
    .cases-subtitle {
        font-size: 1.1rem;
        margin-bottom: 1.5rem;
    }
    
    .btn-custom-cases {
        padding: 16px 35px;
        font-size: 15px;
        letter-spacing: 0.3px;
    }
}

@media (max-width: 576px) {
    .cases-button-section {
        padding: 40px 0;
    }
    
    .cases-subtitle {
        font-size: 1rem;
        margin-bottom: 1.2rem;
        padding: 0 15px;
    }
    
    .btn-custom-cases {
        padding: 14px 30px;
        font-size: 14px;
        letter-spacing: 0.2px;
        width: 90%;
        max-width: 280px;
    }
}

@media (max-width: 400px) {
    .btn-custom-cases {
        padding: 12px 25px;
        font-size: 13px;
    }
}













/* Video Cases Styles */

/* Video Badge */
.video-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background: linear-gradient(135deg, var(--accent-purple), #b8469a);
    color: white;
    padding: 8px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 5px;
    box-shadow: 0 4px 15px rgba(156, 54, 130, 0.4);
    z-index: 2;
}

.video-badge i {
    font-size: 0.9rem;
}

/* Video Overlay */
.video-overlay {
    background: linear-gradient(135deg, rgba(156, 54, 130, 0.85), rgba(0, 0, 0, 0.7)) !important;
}

.video-overlay i {
    font-size: 4rem !important;
    color: white;
    text-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
    transition: all 0.3s ease;
}

.video-case:hover .video-overlay i {
    transform: scale(1.1);
    color: #fff;
}

/* Video Modal */
.video-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.video-modal.active {
    display: flex;
    opacity: 1;
}

.video-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
}

.video-content {
    position: relative;
    width: 90vw;
    height: 90vh;
    max-width: 1200px;
    max-height: 675px;
    display: flex;
    flex-direction: column;
    animation: videoZoom 0.3s ease;
}

@keyframes videoZoom {
    from {
        transform: scale(0.8);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

.video-close {
    position: absolute;
    top: -50px;
    right: 0;
    background: none;
    border: none;
    color: white;
    font-size: 2rem;
    cursor: pointer;
    padding: 10px;
    transition: all 0.3s ease;
    z-index: 10;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
}

.video-close:hover {
    color: var(--accent-purple);
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}

.video-wrapper {
    width: 100%;
    height: 100%;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.5);
}

.video-wrapper iframe {
    width: 100%;
    height: 100%;
    border: none;
}

/* Responsive Video Modal */
@media (max-width: 768px) {
    .video-content {
        width: 95vw;
        height: 60vh;
        max-height: none;
    }
    
    .video-close {
        top: -40px;
        font-size: 1.5rem;
        width: 40px;
        height: 40px;
    }
    
    .video-badge {
        top: 10px;
        right: 10px;
        padding: 6px 10px;
        font-size: 0.7rem;
    }
    
    .video-overlay i {
        font-size: 3rem !important;
    }
}

@media (max-width: 576px) {
    .video-content {
        width: 98vw;
        height: 50vh;
    }
    
    .video-close {
        top: -35px;
        font-size: 1.3rem;
        width: 35px;
        height: 35px;
    }
    
    .video-badge {
        top: 8px;
        right: 8px;
        padding: 5px 8px;
        font-size: 0.65rem;
    }
    
    .video-badge i {
        font-size: 0.8rem;
    }
    
    .video-overlay i {
        font-size: 2.5rem !important;
    }
}

/* Video aspect ratio for different screen sizes */
@media (max-width: 1200px) {
    .video-content {
        max-height: 600px;
    }
}

@media (min-width: 1400px) {
    .video-content {
        max-width: 1400px;
        max-height: 787px;
    }
}