/* Custom styles for ТК Бизнес Сити */

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, rgba(30, 60, 114, 0.85) 0%, rgba(42, 82, 152, 0.8) 100%), 
                url('../images/main/first-screen-1.jpg') center center/cover no-repeat;
    position: relative;
    padding-top: 80px;
    min-height: 67vh;
    display: flex;
    align-items: center;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="25" cy="25" r="1" fill="white" opacity="0.1"/><circle cx="75" cy="75" r="1" fill="white" opacity="0.1"/><circle cx="50" cy="10" r="0.5" fill="white" opacity="0.1"/><circle cx="10" cy="60" r="0.5" fill="white" opacity="0.1"/><circle cx="90" cy="40" r="0.5" fill="white" opacity="0.1"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    opacity: 0.2;
    z-index: 1;
}

.hero-section .container {
    position: relative;
    z-index: 2;
}

.hero-stats {
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Portfolio Images */
.portfolio-image-container {
    position: relative;
    overflow: hidden;
    height: 200px;
}

.portfolio-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.portfolio-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(255, 193, 7, 0.9) 0%, rgba(255, 193, 7, 0.7) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.portfolio-weight {
    color: white;
    font-weight: bold;
    font-size: 1.2rem;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

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

.card:hover .portfolio-overlay {
    opacity: 1;
}

/* Fleet Images */
.fleet-image-container {
    position: relative;
    overflow: hidden;
    height: 333px;
}

.fleet-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.fleet-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(30, 60, 114, 0.9) 0%, rgba(42, 82, 152, 0.7) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.fleet-capacity {
    color: white;
    font-weight: bold;
    font-size: 1.3rem;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
    background: rgba(255, 193, 7, 0.9);
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
}

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

.card:hover .fleet-overlay {
    opacity: 1;
}

/* Gallery Images */
.gallery-item {
    cursor: pointer;
    border-radius: 0.5rem;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.gallery-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.gallery-image-container {
    position: relative;
    overflow: hidden;
    height: 250px;
}

.gallery-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.gallery-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(30, 60, 114, 0.8) 0%, rgba(42, 82, 152, 0.6) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.gallery-item:hover .gallery-image {
    transform: scale(1.1);
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

/* Современное модальное окно галереи */
.gallery-modal-content {
    background: rgba(0, 0, 0, 0.95) !important;
    border: none !important;
    border-radius: 0 !important;
}

.gallery-modal-header {
    position: absolute;
    top: 0;
    right: 0;
    z-index: 1050;
    padding: 1rem;
}

.gallery-close-btn {
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.gallery-close-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
    color: white;
}

.gallery-modal-body {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100vh;
    padding: 0;
}

.gallery-modal-image {
    max-width: 95%;
    max-height: 95vh;
    object-fit: contain;
    border-radius: 0.5rem;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    transition: transform 0.3s ease;
}

.gallery-modal-image:hover {
    transform: scale(1.02);
}

/* Анимация появления модального окна */
#galleryModal .modal-dialog {
    transition: transform 0.3s ease-out;
}

#galleryModal.show .modal-dialog {
    transform: none;
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Navbar adjustments */
.navbar {
    backdrop-filter: blur(10px);
    background-color: rgba(33, 37, 41, 0.95) !important;
}

.navbar-brand {
    font-size: 1.5rem;
}

/* Card hover effects */
.card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15) !important;
}

/* Button hover effects */
.btn {
    transition: all 0.3s ease;
}

.btn-warning:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 193, 7, 0.4);
}

.btn-outline-light:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 255, 255, 0.2);
}

/* Icon animations */
.bi {
    transition: transform 0.3s ease;
}

.card:hover .bi {
    transform: scale(1.1);
}

/* Badge styling */
.badge {
    font-weight: 500;
    padding: 0.5em 0.75em;
}

/* Form styling */
.form-control:focus {
    border-color: #ffc107;
    box-shadow: 0 0 0 0.2rem rgba(255, 193, 7, 0.25);
}

.form-control {
    border-radius: 0.5rem;
    border: 2px solid #e9ecef;
    transition: all 0.3s ease;
}

.form-control:hover {
    border-color: #ffc107;
}

/* Section spacing */
section {
    position: relative;
}

/* Background patterns */
.bg-light {
    background-color: #f8f9fa !important;
    position: relative;
}

.bg-light::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="dots" width="20" height="20" patternUnits="userSpaceOnUse"><circle cx="10" cy="10" r="1" fill="%23dee2e6" opacity="0.3"/></pattern></defs><rect width="100" height="100" fill="url(%23dots)"/></svg>');
    opacity: 0.5;
    pointer-events: none;
}

/* Statistics styling */
.display-6 {
    font-weight: 700;
    line-height: 1.2;
}

/* FAQ Accordion Styles */
.accordion-button {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    border: none;
    padding: 1.5rem;
    font-size: 1.1rem;
    transition: all 0.3s ease;
}

.accordion-button:not(.collapsed) {
    background: linear-gradient(135deg, #ffc107 0%, #ff8c00 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(255, 193, 7, 0.3);
}

.accordion-button:hover {
    background: linear-gradient(135deg, #ffc107 0%, #ff8c00 100%);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 193, 7, 0.4);
}

.accordion-button:focus {
    box-shadow: 0 0 0 0.25rem rgba(255, 193, 7, 0.25);
}

.accordion-button::after {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23ffc107'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");
    transition: all 0.3s ease;
}

.accordion-button:not(.collapsed)::after {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23ffffff'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");
}

.accordion-item {
    border-radius: 15px !important;
    overflow: hidden;
    transition: all 0.3s ease;
}

.accordion-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1) !important;
}

.accordion-body {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    padding: 1.5rem;
    font-size: 1rem;
    line-height: 1.6;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .hero-section {
        text-align: center;
        min-height: 53vh;
    }
    
    .hero-stats {
        margin-top: 2rem;
    }
    
    .display-4 {
        font-size: 2.5rem;
    }
    
    .display-5 {
        font-size: 2rem;
    }
    
    .display-6 {
        font-size: 1.5rem;
    }
    
    .portfolio-image-container {
        height: 180px;
    }
    
    .fleet-image-container {
        height: 267px;
    }
    
    .gallery-image-container {
        height: 200px;
    }
    
    .gallery-close-btn {
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }
    
    .gallery-modal-image {
        max-width: 98%;
        max-height: 90vh;
    }
}

/* Loading animation for stats */
@keyframes countUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-stats .display-6 {
    animation: countUp 1s ease-out;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #ffc107;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #e0a800;
}

/* Focus styles for accessibility */
.nav-link:focus,
.btn:focus,
.form-control:focus {
    outline: 2px solid #ffc107;
    outline-offset: 2px;
}

/* Print styles */
@media print {
    .navbar,
    .btn,
    form {
        display: none !important;
    }
    
    .hero-section {
        background: white !important;
        color: black !important;
    }
    
    .text-white {
        color: black !important;
    }
    
    .text-white-50 {
        color: #6c757d !important;
    }
}
