/* Основные переменные */
:root {
  --primary-color: #3E63DD;
  --secondary-color: #F77F6A;
  --accent-teal: #4BC7C2;
  --accent-lime: #C0D903;
  --text-dark: #2B2E38;
  --bg-light: #FFFFFF;
  --bg-gradient: linear-gradient(135deg, #FFFFFF 0%, #F4F7FB 100%);
  --shadow-soft: 0 4px 20px rgba(62, 99, 221, 0.1);
  --shadow-hover: 0 8px 30px rgba(62, 99, 221, 0.2);
  --border-radius: 1rem;
  --border-radius-xl: 1.5rem;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Сброс стилей */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Основные стили */
body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
  color: var(--text-dark);
  background: var(--bg-gradient);
  scroll-behavior: smooth;
}

/* Плавная прокрутка для всех элементов */
html {
  scroll-behavior: smooth;
}

/* Смещение для якорей чтобы учесть фиксированный хедер */
section[id] {
  scroll-margin-top: 100px;
}

/* Альтернативный способ для старых браузеров */
section[id]::before {
  content: '';
  display: block;
  height: 100px;
  margin-top: -100px;
  visibility: hidden;
  pointer-events: none;
}

/* Контейнеры */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.section {
  padding: 80px 0;
  position: relative;
}

/* Заголовки */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--text-dark);
}

h1 {
  font-size: 3.5rem;
  line-height: 1.2;
}

h2 {
  font-size: 2.5rem;
  line-height: 1.3;
}

h3 {
  font-size: 1.8rem;
}

/* Кнопки */
.btn {
  display: inline-block;
  padding: 16px 32px;
  border: none;
  border-radius: var(--border-radius);
  font-size: 1.1rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: var(--transition);
  box-shadow: var(--shadow-soft);
  position: relative;
  overflow: hidden;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-teal) 100%);
  color: white;
}

.btn-secondary {
  background: var(--secondary-color);
  color: white;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
}

.btn:active {
  transform: translateY(0);
}

/* Хедер */
header {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  transition: var(--transition);
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
}

/* Эффект хедера при скролле - CSS only */
body:not(:target) header {
  background: rgba(255, 255, 255, 0.95);
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
}

/* Альтернативный эффект для современных браузеров */
@supports (backdrop-filter: blur(10px)) {
  header {
    backdrop-filter: blur(10px);
  }
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 0;
}

.logo {
  height: 50px;
  transition: var(--transition);
}

.logo:hover {
  transform: scale(1.05);
}

/* Навигация */
.nav {
  display: flex;
  list-style: none;
  gap: 2rem;
}

.nav a {
  text-decoration: none;
  color: var(--text-dark);
  font-weight: 500;
  transition: var(--transition);
  position: relative;
}

.nav a::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--primary-color);
  transition: var(--transition);
}

.nav a:hover::after {
  width: 100%;
}

/* Мобильное меню - CSS only */
.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--text-dark);
}

/* Checkbox скрытый для мобильного меню */
#mobile-menu-checkbox {
  display: none;
}

/* Стили для мобильного меню */
@media (max-width: 768px) {
  .mobile-menu-toggle {
    display: block;
  }
  
  .nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    flex-direction: column;
    box-shadow: var(--shadow-soft);
    transform: translateY(-100%);
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 1000;
  }
  
  #mobile-menu-checkbox:checked ~ .header-content .nav {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }
  
  .nav a {
    padding: 1rem;
    border-bottom: 1px solid #f0f0f0;
  }
}

/* Hero секция */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  background: var(--bg-gradient);
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(circle at 30% 20%, rgba(62, 99, 221, 0.1) 0%, transparent 50%);
}

.hero-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  position: relative;
  z-index: 2;
}

.hero-text h1 {
  margin-bottom: 1.5rem;
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-teal) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-text p {
  font-size: 1.25rem;
  margin-bottom: 2rem;
  opacity: 0.8;
}

.hero-image {
  position: relative;
}

.hero-image img {
  width: 100%;
  height: auto;
  border-radius: var(--border-radius-xl);
  box-shadow: var(--shadow-soft);
  transition: var(--transition);
}

.hero-image img:hover {
  transform: scale(1.02);
  box-shadow: var(--shadow-hover);
}

/* Карточки */
.card {
  background: white;
  border-radius: var(--border-radius-xl);
  padding: 2rem;
  box-shadow: var(--shadow-soft);
  transition: var(--transition);
  position: relative;
  overflow: hidden;
  animation: fadeInUp 0.6s ease-out;
}

.card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--primary-color) 0%, var(--accent-teal) 100%);
}

.card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: var(--shadow-hover);
}

/* Анимации появления для элементов */
.hero-text, .hero-image {
  animation: fadeInUp 0.8s ease-out;
}

.hero-text {
  animation-delay: 0.2s;
}

.hero-image {
  animation-delay: 0.4s;
}

/* Сетка */
.grid {
  display: grid;
  gap: 2rem;
}

.grid-2 {
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.grid-3 {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.grid-4 {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

/* Форма */
.form-container {
  background: white;
  border-radius: var(--border-radius-xl);
  padding: 3rem;
  box-shadow: var(--shadow-soft);
  position: relative;
  overflow: hidden;
}

.form-container::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -50%;
  width: 100%;
  height: 200%;
  background: linear-gradient(45deg, transparent 30%, rgba(62, 99, 221, 0.05) 50%, transparent 70%);
  transform: rotate(45deg);
  pointer-events: none;
}

.form-group {
  margin-bottom: 1.5rem;
  position: relative;
}

.form-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--text-dark);
}

.form-control {
  width: 100%;
  padding: 16px 20px;
  border: 2px solid #e1e5e9;
  border-radius: var(--border-radius);
  font-size: 1rem;
  transition: var(--transition);
  background: white;
}

.form-control:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(62, 99, 221, 0.1);
}

.checkbox-group {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
}

.checkbox-group input[type="checkbox"] {
  margin-top: 0.25rem;
  width: 18px;
  height: 18px;
  accent-color: var(--primary-color);
}

/* Подвал */
footer {
  background: var(--text-dark);
  color: white;
  padding: 4rem 0 2rem;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 3rem;
  margin-bottom: 2rem;
}

.footer-section h3 {
  color: white;
  margin-bottom: 1rem;
}

.footer-section p,
.footer-section a {
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  transition: var(--transition);
}

.footer-section a:hover {
  color: var(--accent-teal);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 2rem;
  text-align: center;
  color: rgba(255, 255, 255, 0.6);
}

/* Cookie banner */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: white;
  padding: 1.5rem;
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.1);
  z-index: 10000;
  transform: translateY(100%);
  transition: var(--transition);
}

.cookie-banner.show {
  transform: translateY(0);
}

.cookie-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
  gap: 2rem;
}

.cookie-text {
  flex: 1;
}

.cookie-actions {
  display: flex;
  gap: 1rem;
}

/* Анимации */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in-up {
  animation: fadeInUp 0.6s ease-out;
}

/* Адаптивность */
@media (max-width: 768px) {
  .container {
    padding: 0 15px;
  }
  
  .section {
    padding: 60px 0;
  }
  
  h1 {
    font-size: 2.5rem;
  }
  
  h2 {
    font-size: 2rem;
  }
  
  .nav {
    display: none;
  }
  
  .mobile-menu-toggle {
    display: block;
  }
  
  .hero {
    min-height: calc(100vh - 80px);
    padding-top: 120px;
  }
  
  .hero-content {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 2rem;
  }
  
  .form-container {
    padding: 2rem;
  }
  
  .cookie-content {
    flex-direction: column;
    text-align: center;
  }
  
  .cookie-actions {
    justify-content: center;
  }
}

@media (max-width: 480px) {
  h1 {
    font-size: 2rem;
  }
  
  .btn {
    padding: 12px 24px;
    font-size: 1rem;
  }
  
  .form-container {
    padding: 1.5rem;
  }
  
  .grid {
    gap: 1rem;
  }
}

/* Утилиты */
.text-center {
  text-align: center;
}

.text-primary {
  color: var(--primary-color);
}

.text-secondary {
  color: var(--secondary-color);
}

.mb-2 {
  margin-bottom: 1rem;
}

.mb-3 {
  margin-bottom: 1.5rem;
}

.mb-4 {
  margin-bottom: 2rem;
}

.mt-4 {
  margin-top: 2rem;
}

.hidden {
  display: none;
}

/* Особые эффекты */
.gradient-text {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-teal) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.highlight-box {
  position: relative;
  padding: 2rem;
  background: linear-gradient(135deg, rgba(62, 99, 221, 0.05) 0%, rgba(75, 199, 194, 0.05) 100%);
  border-radius: var(--border-radius-xl);
  border: 1px solid rgba(62, 99, 221, 0.1);
} 