/* ==========================================================================
   Custom Styles for ecom1.ru
   ========================================================================== */

/* Root Variables - Aspro Style */
:root {
    --primary-color: #000000;
    --primary-hover: #333333;
    --secondary-color: #00a8e6;
    --text-dark: #1a1a1a;
    --text-muted: #666666;
    --text-light: #999999;
    --bg-light: #f5f7fa;
    --bg-white: #ffffff;
    --border-color: #e0e0e0;
    --border-light: #f0f0f0;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.12);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.16);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --border-radius: 32px;
    --border-radius-lg: 32px;
}

/* Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif;
    color: var(--text-dark);
    line-height: 1.6;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    background: linear-gradient(135deg, #faf7f5 0%, #fff 100%);
    background-attachment: fixed;
}

/* Header - Aspro Style */
.header {
    background-color: var(--bg-white) !important;
    box-shadow: var(--shadow-sm);
    border-bottom: 1px solid var(--border-light);
}

.navbar {
    padding: 1rem 0;
}

.navbar-brand {
    font-weight: 700;
    font-size: 1.5rem;
    color: var(--text-dark) !important;
    letter-spacing: -0.02em;
}

.navbar-nav .nav-link {
    color: var(--text-dark) !important;
    font-weight: 500;
    padding: 0.5rem 1rem !important;
    transition: var(--transition);
    border-radius: var(--border-radius);
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
    color: var(--primary-color) !important;
    background-color: rgba(0, 102, 204, 0.05);
}

/* Footer - Aspro Style */
.footer {
    margin-top: auto;
    background-color: #1a1a1a;
    color: #ffffff;
    padding: 3rem 0;
}

.footer p {
    color: rgba(255, 255, 255, 0.7);
    margin: 0;
}

/* Sections - Aspro Style */
section {
    min-height: 200px;
    padding: 4rem 0;
}

section h2 {
    margin-bottom: 1rem;
    font-weight: 700;
    font-size: 2.5rem;
    line-height: 1.2;
    color: var(--text-dark);
    letter-spacing: -0.02em;
    text-align: left;
}

section h3 {
    font-weight: 600;
    font-size: 1.5rem;
    line-height: 1.3;
    color: var(--text-dark);
    letter-spacing: -0.01em;
    text-align: left;
}

section p.lead {
    font-size: 1.25rem;
    line-height: 1.6;
    color: var(--text-muted);
    font-weight: 400;
    text-align: left;
}

section .text-center.mb-5 {
    text-align: left !important;
}

.hero-section {
    min-height: 600px;
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, #f5f7fa 0%, #ffffff 100%);
    position: relative;
    padding: 5rem 0;
}

.hero-section h1 {
    font-size: 3rem;
    font-weight: 700;
    line-height: 1.2;
    color: var(--text-dark);
    letter-spacing: -0.03em;
    margin-bottom: 2rem;
}

/* Square Cards (1:1 aspect ratio) - Aspro Style */
.square-card {
    aspect-ratio: 1 / 1;
    border: 1px solid var(--border-light) !important;
    border-radius: var(--border-radius-lg) !important;
    transition: var(--transition);
    background: var(--bg-white);
}



.square-card .card-body {
    padding: 2rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.square-card i {
    margin-bottom: 1rem;
}

#partnersCanvas {
    opacity: 0.6;
    z-index: 1;
}

.partners-section .container {
    z-index: 2;
}

/* CTA Modal */
.modal-fullscreen .modal-body {
    overflow-y: auto;
}

.form-control-lg {
    padding: 1rem 1.5rem;
    font-size: 1.1rem;
}

.form-floating>.form-control {
    height: calc(3.5rem + 2px);
    line-height: 1.25;
}

.form-floating>label {
    padding: 1rem 0.75rem;
}

.form-control {
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    transition: var(--transition);
}

.form-control:focus {
    box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.1);
    background-color: var(--bg-white) !important;
    border: 1px solid var(--primary-color) !important;
    outline: none;
}

.form-control.bg-light {
    background-color: var(--bg-light) !important;
}

/* Button Check/Radio Styles */
.btn-check:checked+.btn-outline-secondary {
    background-color: rgba(0, 102, 204, 0.1);
    color: var(--primary-color);
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.1);
}

.btn-outline-secondary {
    border: 1px solid var(--border-color);
    color: var(--text-dark);
    font-weight: 500;
    padding: 0.5rem 1.5rem;
    border-radius: var(--border-radius);
    transition: var(--transition);
    background-color: transparent;
}

.btn-outline-secondary:hover {
    background-color: var(--bg-light);
    color: var(--text-dark);
    border-color: var(--border-color);
    transform: translateY(-1px);
}

/* Buttons - Aspro Style */
.btn-primary {
    background-color: var(--primary-color);
    border: none;
    font-weight: 600;
    transition: var(--transition);
    border-radius: var(--border-radius);
    padding: 0.75rem 2rem;
    font-size: 1rem;
}

.btn-primary:hover {
    background-color: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    color: white;
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-outline-primary {
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    background-color: transparent;
    font-weight: 600;
    border-radius: var(--border-radius);
    padding: 0.75rem 2rem;
    transition: var(--transition);
}

.btn-outline-primary:hover {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

/* Quiz Transitions */
.quiz-step {
    animation: fadeIn 0.5s ease-in-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.form-check-input:checked {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-outline-primary {
    color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-outline-primary:hover {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

/* Offers Section - Aspro Style */
.offers-section {
    background-color: var(--bg-white);
    padding: 5rem 0;
}

.offer-card {
    border: 1px solid var(--border-light) !important;
    border-radius: var(--border-radius-lg) !important;
    background: var(--bg-white);
    height: 100%;
    aspect-ratio: 1 / 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.offer-icon {
    flex-shrink: 0;
    width: 64px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 102, 204, 0.1);
    border-radius: var(--border-radius);
}

.offer-card .card-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-dark);
}

.offer-card .card-text {
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--text-muted);
}

.offer-card ul li {
    font-size: 0.9rem;
    line-height: 1.5;
    color: var(--text-dark);
}

.offer-card .btn-outline-primary {
    margin-top: auto;
}

/* Advantages Section (без рамки) */
.offers-section .col-md-6:last-child h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-dark);
}

.offers-section .col-md-6:last-child ul li {
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--text-dark);
}

.offers-section .col-md-6:last-child ul li strong {
    color: var(--primary-color);
    font-weight: 600;
}

/* Partners Section - Aspro Style */
.partners-section {
    padding: 5rem 0;
    background: var(--bg-light);
}

.partner-item {
    background: var(--bg-white);
    border-radius: var(--border-radius-lg);
    transition: var(--transition);
    border: 1px solid var(--border-light);
    padding: 2rem;
    height: 100%;
}



.partner-logo {
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.partnersSwiper {
    padding-bottom: 50px;
}

/* About Section - Aspro Style */
.about-section {
    background-color: var(--bg-white);
    padding: 5rem 0;
}

.about-section .card {
    border: 1px solid var(--border-light);
    border-radius: var(--border-radius-lg);
    transition: var(--transition);
    background: var(--bg-white);
}



.achievement-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 102, 204, 0.1);
    border-radius: 50%;
    transition: var(--transition);
}



/* Cases Section - Aspro Style */
.cases-section {
    padding: 5rem 0;
    background: var(--bg-light);
}

/* Cases Masonry Grid */
.cases-grid {
    column-count: 3;
    column-gap: 1.5rem;
}

@media (max-width: 992px) {
    .cases-grid {
        column-count: 2;
    }
}

@media (max-width: 576px) {
    .cases-grid {
        column-count: 1;
    }
}

.case-card-masonry {
    break-inside: avoid;
    margin-bottom: 1.5rem;
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    background: var(--bg-white);
    width: 100%;
    display: block;
    /* Fix for some browsers */
}



.case-card-masonry .case-image {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 200px;
}

/* Ensure content inside fits */
.case-content {
    position: relative;
    z-index: 1;
}

/* Achievements Section - Aspro Style */
.achievements-section {
    background-color: var(--bg-white);
    padding: 5rem 0;
}

.achievements-section .card {
    transition: var(--transition);
    border: 1px solid var(--border-light) !important;
    border-radius: var(--border-radius-lg) !important;
    background: var(--bg-white);
    height: 100%;
}



.achievements-section .display-5 {
    color: var(--primary-color);
    font-weight: 700;
    letter-spacing: -0.02em;
}

/* Reviews Section - Aspro Style */
.reviews-section {
    background-color: var(--bg-light);
    padding: 5rem 0;
}

.review-avatar {
    width: 60px;
    height: 60px;
    flex-shrink: 0;
}

.reviewsSwiper {
    padding-bottom: 50px;
    padding-top: 20px;
}

.reviewsSwiper .swiper-slide .card {
    border: 1px solid var(--border-light);
    border-radius: var(--border-radius-lg);
    background: var(--bg-white);
    transition: var(--transition);
}



.reviewsSwiper .swiper-button-next,
.reviewsSwiper .swiper-button-prev {
    color: var(--primary-color);
    background: var(--bg-white);
    width: 44px;
    height: 44px;
    border-radius: 50%;
    box-shadow: var(--shadow-sm);
}

.reviewsSwiper .swiper-button-next:after,
.reviewsSwiper .swiper-button-prev:after {
    font-size: 18px;
    font-weight: 700;
}

.reviewsSwiper .swiper-pagination-bullet {
    background-color: var(--border-color);
    opacity: 1;
}

.reviewsSwiper .swiper-pagination-bullet-active {
    background-color: var(--primary-color);
    width: 24px;
    border-radius: 4px;
}

/* Technologies Section - Aspro Style */
.technologies-section {
    background-color: var(--bg-white);
    padding: 5rem 0;
}

.technology-item {
    background: var(--bg-white);
    border-radius: var(--border-radius-lg);
    transition: var(--transition);
    border: 1px solid var(--border-light);
    padding: 2rem;
    height: 100%;
}

.technology-item:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
    border-color: var(--primary-color);
}

.technology-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 102, 204, 0.1);
    border-radius: var(--border-radius);
    transition: var(--transition);
}



.technologiesSwiper {
    padding-bottom: 50px;
}

.technologiesSwiper .swiper-pagination-bullet {
    background-color: var(--border-color);
    opacity: 1;
}

.technologiesSwiper .swiper-pagination-bullet-active {
    background-color: var(--primary-color);
    width: 24px;
    border-radius: 4px;
}

/* Technologies Masonry Grid */
.technologies-masonry {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 1rem;
}

.technologies-masonry .technology-item {
    background: var(--bg-white);
    border-radius: var(--border-radius);
    transition: var(--transition);
    border: 1px solid var(--border-light);
}



@media (max-width: 768px) {
    .technologies-masonry {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
        gap: 0.75rem;
    }
}

/* CTA Section - Aspro Style */
.cta-section {
    padding: 5rem 0;
    background: var(--bg-light);
}

.cta-section .card {
    border: none;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-lg);
    background: var(--bg-white);
}

/* Modal - Aspro Style */
.modal-content {
    border: none;
    border-radius: var(--border-radius-lg);
}

.modal-header {
    border-bottom: 1px solid var(--border-light);
}

.modal-body {
    padding: 2rem;
}

/* Progress Bar - Aspro Style */
.progress {
    background-color: var(--bg-light);
    border-radius: 4px;
    height: 4px;
}

.progress-bar {
    background-color: var(--primary-color);
    border-radius: 4px;
}

/* Text Colors - Aspro Style */
.text-muted {
    color: var(--text-muted) !important;
}

.text-primary {
    color: var(--primary-color) !important;
}

/* Cards General - Aspro Style */
.card {
    border: 1px solid var(--border-light);
    border-radius: var(--border-radius-lg);
    transition: var(--transition);
}

.card-title {
    font-weight: 600;
    color: var(--text-dark);
}

.card-text {
    color: var(--text-muted);
    line-height: 1.6;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    section {
        padding: 3rem 0;
    }

    section h2 {
        font-size: 2rem;
    }

    .hero-section h1 {
        font-size: 2rem;
    }
}

/* Mobile-specific utility classes for hero cards */
@media (max-width: 767px) {
    .fs-md-1 {
        font-size: 2.5rem !important;
    }

    .small-md-regular {
        font-size: 0.75rem !important;
    }

    .square-card .card-body.p-2 {
        padding: 0.5rem !important;
    }

    .mb-md-3 {
        margin-bottom: 0.5rem !important;
    }
}

@media (min-width: 768px) {
    .fs-md-1 {
        font-size: 3rem !important;
    }

    .small-md-regular {
        font-size: 1.25rem !important;
    }

    .p-md-3 {
        padding: 1rem !important;
    }
}

/* Hero Cards - Colorful & Icon Background */
.hero-card {
    position: relative;
    overflow: hidden;
    border: none;
    border-radius: var(--border-radius-lg);
    color: white;
    height: 100%;
    min-height: 140px;
    aspect-ratio: 1 / 1;
    transition: var(--transition);
    box-shadow: var(--shadow-md);
    z-index: 1;
}



.hero-card-body {
    position: relative;
    z-index: 2;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.hero-card-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 0;
    line-height: 1.3;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.hero-card-icon {
    position: absolute;
    bottom: -20px;
    right: -20px;
    font-size: 6rem;
    opacity: 0.25;
    transform: rotate(-15deg);
    pointer-events: none;
    z-index: 1;
    color: rgba(255, 255, 255, 0.8);
}

/* Gradient Variants */
.hero-card-1 {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.hero-card-2 {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

.hero-card-3 {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

.hero-card-4 {
    background: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
}

/* Hero CTA Button */
.hero-cta-btn {
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    background: transparent;
    border-radius: var(--border-radius-lg);
    font-weight: 700;
    transition: var(--transition);
}

@media (min-width: 992px) {
    .hero-cta-btn {
        font-size: 2rem;
    }
}

@media (max-width: 768px) {
    .hero-cta-btn {
        min-height: 80px;
        /* 2x bigger height for mobile */
        font-size: 1.2rem;
    }
}

/* Force center alignment for Achievements section */
#achievements .text-center,
#achievements h2,
#achievements h3,
#achievements p {
    text-align: center !important;
}



/* Mobile adjustments for Hero Cards (4 in a row) */
@media (max-width: 768px) {
    .hero-card-title {
        font-size: 0.6rem !important;
        line-height: 1.1;
        word-wrap: break-word;
    }

    .hero-card-body {
        padding: 0.5rem !important;
    }

    .hero-card-icon {
        font-size: 2rem;
        bottom: -5px;
        right: -5px;
    }

    /* Ensure cards stay square and small */
    .hero-card {
        min-height: auto;
    }
}

/* Hero Swiper Styles */
.heroSwiper {
    width: 100%;
    padding-bottom: 40px;
}

.heroSwiper .swiper-slide {
    width: 25%;
    height: auto;
}

.heroSwiper .swiper-slide .hero-card {
    height: 100%;
    width: 100%;
}

.heroSwiper .swiper-scrollbar {
    background: rgba(0, 0, 0, 0.1);
    border-radius: 10px;
    height: 4px;
}

.heroSwiper .swiper-scrollbar-drag {
    background: var(--primary-color);
    border-radius: 10px;
}

/* Mobile: adjusted cards (0.9x) */
@media (max-width: 768px) {
    .heroSwiper .swiper-slide {
        width: 32.5%;
    }

    .heroSwiper .swiper-slide .hero-card {
        transform: scale(0.9);
        transform-origin: center;
    }
}

/* ==========================================================================
   New Styles for Mobile Border Radius & Offer Cards
   ========================================================================== */

/* Mobile Global Border Radius (16px) */
@media (max-width: 767px) {
    :root {
        --border-radius: 16px;
        --border-radius-lg: 16px;
    }
}

/* Offer Cards Styling - New Gradients */
.offer-card-1 {
    background: linear-gradient(135deg, #e8505b 0%, #f3a0d1 100%);
}

.offer-card-2 {
    background: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
}

.offer-card-3 {
    background: linear-gradient(135deg, #30cfd0 0%, #330867 100%);
}

.offer-card {
    color: white;
    border: none !important;
}



.offer-card .card-body {
    position: relative;
    z-index: 2;
}

.offer-card .card-title,
.offer-card .h4,
.offer-card li {
    color: white !important;
}

.offer-card .text-muted {
    color: rgba(255, 255, 255, 0.8) !important;
}

.offer-card .text-primary {
    color: white !important;
}

.offer-card .btn-outline-primary {
    border-color: white;
    color: white;
}

.offer-card .btn-outline-primary:hover {
    background-color: white;
    color: var(--primary-color);
    border-color: white;
}

.offer-card-bg-icon {
    position: absolute;
    bottom: -20px;
    right: -20px;
    font-size: 8rem;
    opacity: 0.2;
    transform: rotate(-15deg);
    pointer-events: none;
    z-index: 1;
    color: white;
}

/* Desktop styles for Offer Cards */
@media (min-width: 768px) {
    .offer-card .card-body {
        padding: 3rem !important;
    }

    .offer-card .card-title {
        font-size: 2rem !important;
    }

    .offer-card .h4 {
        font-size: 1.75rem !important;
    }

    .offer-card .card-text {
        font-size: 1.1rem !important;
    }

    .offer-card ul li {
        font-size: 1rem !important;
    }
}

/* Mobile Layout Fix for Offer Cards */
@media (max-width: 767px) {
    .offer-card {
        aspect-ratio: auto !important;
        height: auto !important;
        min-height: 300px;
    }

    .offer-card-bg-icon {
        font-size: 6rem;
    }
}

/* Utility Classes */
.text-limit-700 {
    max-width: 700px;
}

.card-transparent {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
}

/* Force center alignment for transparent cards in offers section */
#offers .card-transparent h3,
#offers .card-transparent p {
    text-align: center !important;
}

/* Force center alignment for About section statistics */
#about .text-center h3,
#about .text-center p {
    text-align: center !important;
}