/* ==================== КОРНЕВЫЕ ПЕРЕМЕННЫЕ ==================== */
:root {
  /* Цвета */
  --card-bg: #0F1629; /* Темно-синий фон карточек */
  --text-primary: #FFFFFF; /* Основной текстовый цвет */
  --text-secondary: #CBD5E1; /* Второстепенный текстовый цвет */
  --accent: #59DEFA; /* Основной акцентный цвет (голубой) */
  --accent-light: #8BEBFB; /* Светлый акцентный цвет */
  
  /* Радиусы скругления */
  --radius-lg: 20px; /* Большой радиус */
  --radius-md: 12px; /* Средний радиус */
  --radius-sm: 8px; /* Маленький радиус */
  
  /* Переменная для эффекта рассеивания у логотипов клиентов */
  --mask-fade-size: 55%;
}

/* ==================== ОСНОВНОЙ КОНТЕНТ ==================== */
main {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  padding: 20px;
  box-sizing: border-box;
}

/* ==================== ОСНОВНАЯ СЕТКА КОНТАКТОВ ==================== */
.contact-layout {
  display: flex;
  flex-wrap: wrap;
  gap: 40px;
  width: 100%;
  margin-bottom: 60px;
  margin-top: 100px;
  position: relative; /* Для абсолютного позиционирования ссылок */
}

/* ==================== ЛЕВЫЙ БЛОК — КОНТАКТЫ + ФОРМА ==================== */
.contact-info {
  flex: 1 1 400px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 40px 30px;
  border-radius: 50px; /* как в feature-card, вместо 1rem */
  /* Жидкое стекло — точно как в feature-card */
 
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  
  
}

/* Скрытие заголовка h1 для SEO */
.contact-info h1 {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.contact-info h2 {
  font-family: 'Montserrat', sans-serif;
  font-size: 2.2rem;
  color: var(--text-primary);
  margin-bottom: 16px;
  background: white;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  text-align: center;
}

.contact-info p.contact-subtitle {
  color: var(--text-secondary);
  font-size: 1.05rem;
  margin-bottom: 30px;
  line-height: 1.6;
  text-align: center;
}

/* ==================== КОНТАКТНАЯ ИНФОРМАЦИЯ ==================== */
.contact-details {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  margin-bottom: 2rem;
  padding: 1.5rem;
  background: rgba(11, 11, 38, 0.4);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 2px solid rgba(43, 83, 193, 0.5);
  border-radius: 20px;
  box-shadow: 
    0 0 10px rgba(43, 83, 193, 0.4),
    0 2px 10px rgba(0, 0, 0, 0.2);
}

.contact-detail-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

.contact-icon {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(59, 130, 246, 0.2);
  border: 2px solid rgba(59, 130, 246, 0.5);
  border-radius: 12px;
  color: var(--accent);
  transition: all 0.3s ease;
}

.contact-detail-item:hover .contact-icon {
  background: rgba(59, 130, 246, 0.3);
  border-color: rgba(59, 130, 246, 0.8);
  transform: scale(1.05);
  box-shadow: 0 0 15px rgba(59, 130, 246, 0.5);
}

.contact-detail-content {
  flex: 1;
}

.contact-detail-content h3 {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin: 0 0 0.5rem 0;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.contact-detail-content a {
  color: var(--text-primary);
  text-decoration: none;
  font-size: 1.1rem;
  font-weight: 500;
  transition: all 0.3s ease;
  display: inline-block;
}

.contact-detail-content a:hover {
  color: var(--accent);
  transform: translateX(4px);
}

.contact-detail-content p {
  color: var(--text-primary);
  font-size: 1rem;
  margin: 0;
  line-height: 1.6;
}

/* ==================== ФОРМА ==================== */
.callback-form {

 
  padding: 25px;


  flex: 1 1 400px;
  display: flex;
  flex-direction: column;
  justify-content: center;

  border-radius: 24px; /* как в feature-card, вместо 1rem */
  /* Жидкое стекло — точно как в feature-card */
  background: rgba(11, 11, 38, 0.35);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 2px solid rgba(43, 83, 193, 0.7); /* как в feature-card */
  /* Неоновое свечение — идентичное feature-card */
  box-shadow: 
    0 0 10px rgba(43, 83, 193, 0.8),
    0 0 25px rgba(43, 83, 193, 0.6),
    0 0 50px rgba(43, 83, 193, 0.4);
}

.form-group {
  margin-bottom: 20px;
}

label {
  display: block;
  font-size: 0.95rem;
  color: var(--text-secondary);
  margin-bottom: 8px;
  font-weight: 500;
}

input, select, textarea {
  width: 100%;
  padding: 14px 16px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 1rem;
  transition: all 0.3s ease;
  box-sizing: border-box;
  font-family: 'Inter', sans-serif;
  resize: vertical;
}

textarea {
  min-height: 100px;
  line-height: 1.5;
}

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(0, 229, 255, 0.2);
  background: rgba(0, 229, 255, 0.08);
}

input.error, select.error, textarea.error {
  border-color: #ef4444 !important;
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.2) !important;
}

.error-message {
  color: #ef4444;
  font-size: 0.85rem;
  margin-top: 6px;
  display: block;
}

/* ==================== ПЕРЕКЛЮЧАТЕЛЬ СОГЛАСИЯ ==================== */

.consent-container {
  display: flex;
  align-items: center;
  gap: 15px;
  margin: 20px 0;
  padding: 15px;
  background: rgba(15, 23, 42, 0.5);
  border-radius: 12px;
  border: 1px solid rgba(59, 130, 246, 0.3);
}

.consent-toggle {
  position: relative;
  display: inline-block;
  width: 33px;
  height: 18px;
}

.consent-checkbox {
  opacity: 0;
  width: 0;
  height: 0;
  position: absolute;
}

.consent-slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #4a5568;
  transition: .3s;
  border-radius: 24px;
}

.consent-slider:before {
  position: absolute;
  content: "";
  height: 14px;
  width: 14px;
  left: 3px;
  top: 50%;
  transform: translateY(-50%); /* Центрирует по вертикали */
  background-color: white;
  transition: .3s;
  border-radius: 50%;
}

.consent-checkbox:checked + .consent-slider {
  background-color: #3b82f6;
}

.consent-checkbox:checked + .consent-slider:before {
  transform: translate(18px, -50%); /* Сохраняет вертикальное центрирование */
}

.consent-checkbox:focus + .consent-slider {
  box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.3);
}

.consent-text {
  margin: 0;
  color: #e2e8f0;
  font-size: 0.95rem;
  line-height: 1.5;
  flex: 1;
}

.consent-text a {
  color: #59DEFA;
  text-decoration: none;
  border-bottom: 1px dotted #59DEFA;
}

.consent-text a:hover {
  border-bottom: 1px solid #59DEFA;
}

/* Адаптивность */
@media (max-width: 768px) {
  .consent-container {
    flex-direction: row;
    gap: 12px;
    padding: 12px;
  }
  
  .consent-text {
    font-size: 0.9rem;
  }
  
  .consent-toggle {
    width: 45px;
    height: 22px;
  }
  
  .consent-slider:before {
    height: 16px;
    width: 16px;
    left: 3px;
    bottom: 3px;
  }
  
  .consent-checkbox:checked + .consent-slider:before {
    transform: translate(28px, -50%);
  }
}

/* ==================== КНОПКА ОТПРАВКИ ==================== */
.submit-btn {
  width: 100%;
  padding: 16px;
  font-size: 1.1rem;
  font-weight: 600;
  background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 0 20px rgba(59, 130, 246, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  /* Стили для состояния по умолчанию (когда disabled через JS) */
  opacity: 0.7;
  pointer-events: none;
}

.submit-btn:hover:not(:disabled) {
  box-shadow: 0 6px 15px rgba(0, 229, 255, 0.5);
  transform: translateY(-2px);
}

.submit-btn:active:not(:disabled) {
  transform: translateY(0);
  box-shadow: 0 2px 5px rgba(0, 229, 255, 0.3);
}

.submit-btn:enabled {
  opacity: 1;
  pointer-events: all;
}

.submit-btn:disabled {
  background: #cccccc;
  color: #666666;
  cursor: not-allowed;
  box-shadow: none;
  transform: none;
  opacity: 0.5; /* Переопределяем для состояния disabled */
}

/* Стиль спиннера */
.spinner {
  display: inline-block;
  width: 18px;
  height: 18px;
  border: 2px solid #000;
  border-top-color: transparent;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  /* Скрыто по умолчанию */
  display: none;
}

.submit-btn:disabled .spinner {
  display: inline-block;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* ==================== ПРАВЫЙ БЛОК — ФОТО И КОНТАКТЫ ==================== */
.contact-image-wrapper {
  flex: 2 1 400px;
  position: relative;
  display: flex;
  flex-direction: column;
}

.contact-image {
  flex-grow: 1;
  min-height: 400px;
  background: url('/assets/Contacts/20250903_0614_Futuristic BIZON Reception_simple_compose_01k46j72ksejnvd6p4jce7g1ww.png') no-repeat center center;
  background-size: cover;
  position: relative;
  border-radius: 50px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.contact-image::before {
  content: "";
  position: absolute;
  inset: 0;
  /* Градиент снизу вверх, затемняющий только нижнюю часть */
  background: linear-gradient(0deg, rgba(15, 22, 41, 0.4) 0%, rgba(15, 22, 41, 0.2) 30%, transparent 60%);
  z-index: 1;
  border-radius: inherit; /* Наследует скругление от родителя */
}

/* ==================== ССЫЛКИ НА МЕССЕНДЖЕРЫ НА ФОТО ==================== */
/* Абсолютное позиционирование внутри .contact-image-wrapper */
.contact-links-below-image {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 16px;
  z-index: 2;
  padding: 0 10px;
  width: 100%;
  justify-content: center;
}

/* Стили для ссылок на фото */
.contact-link--below {
  width: auto;
  padding: 10px 20px;
  background: rgba(15, 22, 41, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  text-decoration: none;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 10px;
  transition: all 0.3s ease;
  backdrop-filter: blur(4px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  white-space: nowrap;
}

.contact-link--below:hover {
  background: rgba(0, 229, 255, 0.2);
  border-color: var(--accent);
  box-shadow: 0 6px 15px rgba(0, 229, 255, 0.4);
  transform: translateY(-2px);
}

/* Стили для иконок в ссылках на фото */
.contact-link--below svg {
  width: 24px;
  height: 24px;
  min-width: 24px;
  filter: drop-shadow(0 0 2px rgba(0, 0, 0, 0.5));
  transition: filter 0.3s ease;
}

.contact-link--below:hover svg {
  filter: drop-shadow(0 0 6px rgba(0, 229, 255, 0.8));
}

/* ==================== СЕКЦИЯ КЛИЕНТОВ ==================== */
.clients {
  width: 100%;
  text-align: center;
  margin-bottom: 60px;
  padding: 0 20px;
  box-sizing: border-box;
}

.clients h2 {
  font-size: 1.8rem;
  margin-bottom: 30px;
  color: var(--text-primary);
}

.clients-track {
  overflow: hidden;
  /* Используем переменную для гибкой настройки */
  mask-image: linear-gradient(
    to right,
    transparent,
    black var(--mask-fade-size),
    black calc(100% - var(--mask-fade-size)),
    transparent
  );
  -webkit-mask-image: linear-gradient(
    to right,
    transparent,
    black var(--mask-fade-size),
    black calc(100% - var(--mask-fade-size)),
    transparent
  );
}

.clients-track-inner {
  display: flex;
  gap: 4rem;
  animation: scroll 10s linear infinite; /* Увеличил скорость */
}

@keyframes scroll {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(calc(-100% / 2)); /* Точное значение для бесшовности */
  }
}

.client-logo {
  height: 60px;
  margin: 0 30px;
  opacity: 0.7;
  transition: opacity 0.3s ease;
  filter: grayscale(100%);
}

.client-logo:hover {
  opacity: 1;
  filter: grayscale(0%);
}

/* ==================== АДАПТИВ ==================== */
@media (max-width: 992px) {
  .contact-layout {
    flex-direction: column;
    align-items: center;
  }

  .contact-info,
  .contact-image-wrapper {
    flex: 1 1 auto;
    width: 100%;
    max-width: 600px;
  }

  .contact-image {
    display: none;
  }

  .contact-image-wrapper {
    position: relative;
  }

  .contact-links-below-image {
    position: absolute;
  }

  .clients h2 {
    font-size: 1.5rem;
  }

  .client-logo {
    height: 50px;
    margin: 0 20px;
  }
}

@media (max-width: 768px) {
  .contact-details {
    padding: 1rem;
    gap: 1rem;
  }

  .contact-icon {
    width: 40px;
    height: 40px;
  }

  .contact-icon svg {
    width: 20px;
    height: 20px;
  }

  .contact-detail-content h3 {
    font-size: 0.85rem;
  }

  .contact-detail-content a,
  .contact-detail-content p {
    font-size: 0.95rem;
  }

  .contact-links-below-image {
    bottom: 15px;
    gap: 12px;
  }

  .contact-link--below {
    padding: 8px 16px;
    font-size: 0.9rem;
  }

  .contact-link--below svg {
    width: 20px;
    height: 20px;
  }

  /* Адаптация переключателя согласия */
  .consent-container {
    flex-direction: row; /* Убедимся, что элементы в ряд */
    gap: 12px;
    padding: 12px;
  }

  .consent-text {
    font-size: 0.9rem;
  }

  /* Адаптация изображения */
  .contact-image {
    min-height: 200px;
  }
}

@media (max-width: 576px) {
  main {
    padding: 15px;
  }

  .contact-info {
    
    padding: 30px 15px;
  }

  .contact-info h2 {
    font-size: 1.8rem;
  }

  .contact-info p.contact-subtitle {
    font-size: 1rem;
    margin-bottom: 25px;
  }

  .callback-form {
    padding: 20px;
  }

  input,
  select {
    padding: 12px 14px;
  }

  .submit-btn {
    padding: 14px;
    font-size: 1rem;
  }

  .contact-links-below-image {
    align-items: center;
    gap: 10px;
  }

  .contact-link--below {
    width: 80%;
    max-width: 250px;
    justify-content: center;
  }

  .clients {
    margin-bottom: 40px;
    padding: 0 10px;
  }

  .clients h2 {
    font-size: 1.3rem;
    margin-bottom: 20px;
  }

  .client-logo {
    height: 40px;
    margin: 0 15px;
  }
  
.contact-layout {
  margin-top: 2.3rem;
}
}