/* Modern reset and base styles */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #4a649a; /* Светло-синий вместо ярко-синего */
    --secondary-color: #3a517e; /* Более темный оттенок */
    --accent-color: #64748b; /* Приглушенный серо-синий */
    --background-color: #f8fafc; /* Более мягкий фон вместо чистого белого */
    --text-color: #1e293b; /* Немного более темный для лучей читаемости */
    --text-light: #6b7280; /* Немного более приглушенный */
    --border-radius: 12px;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--background-color);
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* Header styles */
header {
    background-color: rgba(248, 250, 252, 0.95); /* Соответствует основному фону */
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    padding: 0.75rem 0;
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary-color);
    letter-spacing: -0.5px;
}

nav ul {
    display: flex;
    list-style: none;
    gap: 1.5rem;
}

nav a {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    position: relative;
    padding: 0.5rem 0;
    transition: var(--transition);
    font-size: 0.95rem;
}

nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: var(--transition);
}

nav a:hover {
    color: var(--primary-color);
}

nav a:hover::after {
    width: 100%;
}

/* Main content */
main {
    min-height: calc(100vh - 140px - 4rem); /* Учитываем высоту футера */
    display: flex;
    flex-direction: column;
    flex: 1;
}

.flex-grow {
    flex: 1;
    display: flex;
    align-items: center;
}

/* Hero section */
.hero {
    padding: 2.5rem 0 2rem;
    text-align: center;
    background: radial-gradient(circle at top right, rgba(74, 100, 154, 0.03) 0%, transparent 20%),
                radial-gradient(circle at bottom left, rgba(58, 81, 126, 0.03) 0%, transparent 20%);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%234a649a' fill-opacity='0.03'%3E%3Ccircle cx='30' cy='30' r='2'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.3;
    pointer-events: none;
}

.hero h1 {
    font-size: 2.25rem;
    font-weight: 800;
    margin-bottom: 1rem;
    color: var(--text-color);
    line-height: 1.2;
    letter-spacing: -0.5px;
    position: relative;
    z-index: 2;
}

.subtitle {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
    color: var(--text-light);
    font-weight: 400;
    position: relative;
    z-index: 2;
}

.location {
    color: var(--text-light);
    font-size: 1rem;
    position: relative;
    z-index: 2;
}

/* Section styles */
section {
    padding: 2.5rem 0;
    position: relative;
}

section:nth-child(even) {
    background-color: #f1f5f9;
}

section h2 {
    font-size: 2rem;
    margin-bottom: 1.25rem;
    color: var(--text-color);
    text-align: center;
    font-weight: 700;
    position: relative;
    display: inline-block;
    margin-left: auto;
    margin-right: auto;
}

section h2::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 50px;
    height: 3px;
    background: var(--primary-color);
    border-radius: 2px;
}

.product, .contact {
    text-align: center;
    max-width: 700px;
    margin: 0 auto;
}

.product p, .contact p {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    color: var(--text-light);
    line-height: 1.6;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.875rem 1.75rem;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    text-decoration: none;
    border-radius: var(--border-radius);
    font-weight: 600;
    transition: var(--transition);
    border: none;
    cursor: pointer;
    font-size: 1rem;
    box-shadow: var(--shadow-md);
    position: relative;
    overflow: hidden;
}

.btn::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: 0.5s;
}

.btn:hover::before {
    left: 100%;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

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

.contact-info {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    margin-top: 1.5rem;
}

.contact-info a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    font-size: 1.1rem;
    position: relative;
    padding-bottom: 0.25rem;
}

.contact-info a:hover {
    text-decoration: underline;
}

/* Footer */
footer {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color)); /* Используем новые цвета */
    color: white;
    text-align: center;
    padding: 1.5rem 0;
}

footer p {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.8);
}

/* Card effect for sections */
.card {
    background: #ffffff;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-md);
    padding: 1.5rem;
    margin: 1rem auto;
    max-width: 700px;
    transition: var(--transition);
}

.card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

/* Responsive design */
@media (max-width: 768px) {
    .container {
        padding: 0 1.25rem;
    }
    
    header .container {
        flex-direction: column;
        gap: 1rem;
    }

    nav ul {
        gap: 1.25rem;
    }

    .hero {
        padding: 3rem 0 2.5rem;
    }

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

    .subtitle {
        font-size: 1.1rem;
    }

    section {
        padding: 3rem 0;
    }

    section h2 {
        font-size: 1.75rem;
    }

    .card {
        padding: 1.75rem;
        margin: 1.25rem auto;
    }
}

@media (max-width: 480px) {
    .logo {
        font-size: 1.1rem;
    }

    nav ul {
        flex-wrap: wrap;
        justify-content: center;
        gap: 1rem;
    }

    nav a {
        font-size: 0.9rem;
    }

    .hero {
        padding: 2.5rem 0 2rem;
    }

    .hero h1 {
        font-size: 1.75rem;
    }

    .subtitle {
        font-size: 1rem;
    }

    section {
        padding: 2.5rem 0;
    }

    section h2 {
        font-size: 1.5rem;
    }

    .product p, .contact p {
        font-size: 1rem;
    }

    .btn {
        padding: 0.75rem 1.5rem;
        font-size: 0.95rem;
    }
    
    .card {
        padding: 1.5rem;
        margin: 1rem auto;
    }
}

/* Accessibility improvements */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .btn::before {
        transition: none;
    }
}

/* Focus indicators for keyboard navigation */
a:focus, button:focus {
    outline: 2px solid var(--accent-color);
    outline-offset: 2px;
    border-radius: 4px;
}

/* Animation for elements when they come into view */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-on-scroll {
    opacity: 0;
    animation: fadeInUp 0.5s ease-out forwards;
}