/* ==========================================================================
   /kontakty — страница обратной связи
   ========================================================================== */
.contact-page {
  background: #f8fbfb;
  padding: 100px 0 80px;
  min-height: 60vh;
}

.contact-breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--dark-text-color);
  margin: 0 0 28px;
  flex-wrap: wrap;
}
.contact-breadcrumb a {
  color: var(--dark-text-color);
  text-decoration: none;
  transition: color 0.15s ease;
}
.contact-breadcrumb a:hover {
  color: var(--gold-color);
}
.contact-breadcrumb span:last-child {
  color: var(--main-bg-color);
  font-weight: 500;
}

/* ---------- Лейаут: слева интро + контакты, справа форма ---------- */
.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1.25fr;
  gap: 48px;
  margin: 0 auto;
}

/* ---------- Левая колонка ---------- */

.contact-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  background: #ffffff;
  border: 1px solid #e5ecec;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  color: var(--dark-text-color);
  margin-bottom: 20px;
}

.contact-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold-color);
  box-shadow: 0 0 0 4px rgba(189, 160, 0, 0.18);
  animation: tools-pulse 2s ease-in-out infinite;
}

.contact-title {
  font-family: "Montserrat", sans-serif;
  font-size: clamp(34px, 4.6vw, 52px) !important;
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.03em;
  color: var(--main-bg-color);
  margin: 0 0 20px !important;
}

.contact-title span {
  display: inline-block;
  position: relative;
  color: var(--gold-color);
  font-style: italic;
}
.contact-title span::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -3px;
  height: 8px;
  background: linear-gradient(
    90deg,
    rgba(247, 203, 202, 0.7),
    rgba(189, 160, 0, 0.3)
  );
  border-radius: 999px;
  z-index: -1;
}

.contact-lead {
  font-size: 16px;
  line-height: 1.55;
  color: var(--dark-text-color);
  margin: 0 0 32px !important;
}

/* Каналы связи */
.contact-channels {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 0;
  list-style: none;
}

.contact-channel {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  background: #ffffff;
  border: 1px solid #e8efef;
  border-radius: 14px;
  text-decoration: none;
  color: var(--main-bg-color);
  transition:
    border-color 0.2s ease,
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.contact-channel:hover {
  border-color: var(--gold-color);
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(17, 17, 17, 0.06);
}

.contact-channel-icon {
  width: 42px;
  height: 42px;
  border-radius: 11px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.contact-channel span:last-child {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.contact-channel strong {
  font-family: "Montserrat", sans-serif;
  font-size: 15px;
  font-weight: 700;
  color: var(--main-bg-color);
  letter-spacing: -0.01em;
}

.contact-channel em {
  font-size: 13px;
  color: var(--dark-text-color);
  font-style: normal;
}

/* ---------- Форма ---------- */
.contact-form-wrap {
  background: #ffffff;
  border: 1px solid #e8efef;
  border-radius: 22px;
  padding: 36px 40px !important;
  box-shadow: 0 12px 32px rgba(17, 17, 17, 0.05);
  align-self: start;
}

.contact-form.is-sent {
  opacity: 0.6;
  pointer-events: none;
}

.contact-field {
  margin-bottom: 22px;
}
.contact-field:last-of-type {
  margin-bottom: 26px;
}

.contact-field label,
.contact-label {
  display: block;
  font-family: "Montserrat", sans-serif;
  font-size: 14px;
  font-weight: 700;
  color: var(--main-bg-color);
  margin-bottom: 8px !important;
  letter-spacing: -0.01em;
}

.contact-hint {
  display: block;
  margin-top: 6px;
  font-size: 12.5px;
  color: var(--dark-text-color);
}

.contact-form input[type="text"],
.contact-form textarea {
  width: 100%;
  padding: 13px 16px;
  font-size: 16px;
  font-family: "Nunito", sans-serif;
  border: 1.5px solid #e5ecec;
  border-radius: 12px;
  background: #f7fafa;
  color: var(--main-bg-color);
  outline: none;
  resize: vertical;
  min-height: 48px;
  -webkit-appearance: none;
  appearance: none;
  transition:
    border-color 0.2s,
    background 0.2s,
    box-shadow 0.2s;
  line-height: 1.4;
}

.contact-form textarea {
  min-height: 140px;
  line-height: 1.5;
}

.contact-form input[type="text"]:hover,
.contact-form textarea:hover {
  background: #fff;
}

.contact-form input[type="text"]:focus,
.contact-form textarea:focus {
  border-color: var(--gold-color);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(189, 160, 0, 0.12);
}

/* Выбор темы — карточки-радио */
.contact-subjects {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.contact-subject {
  cursor: pointer;
  display: flex;
}
.contact-subject input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.contact-subject-card {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 14px 10px;
  min-height: 104px;
  background: #f7fafa;
  border: 1.5px solid #e5ecec;
  border-radius: 12px;
  text-align: center;
  transition: all 0.2s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.contact-subject:hover .contact-subject-card {
  border-color: #d3dcdc;
  background: #fff;
  transform: translateY(-1px);
}

.contact-subject:has(input:checked) .contact-subject-card {
  background: var(--main-bg-color);
  border-color: var(--main-bg-color);
  color: #fff;
  box-shadow: 0 8px 18px rgba(17, 17, 17, 0.14);
  transform: translateY(-2px);
}

.contact-subject-icon {
  font-size: 22px;
  line-height: 1;
}

.contact-subject-name {
  font-family: "Montserrat", sans-serif;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.005em;
}

/* Honeypot — скрытое поле для ботов */
.contact-honey {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
  overflow: hidden;
}

/* Кнопка Отправить */
.contact-submit {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 15px 32px;
  font-family: "Montserrat", sans-serif;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: #fff;
  background: var(--main-bg-color);
  border: none;
  border-radius: 12px;
  cursor: pointer;
  transition:
    background 0.2s ease,
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.contact-submit:hover:not(:disabled) {
  background: var(--gold-color);
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(189, 160, 0, 0.28);
}

.contact-submit:hover:not(:disabled) .contact-submit-arrow {
  transform: translateX(3px);
}

.contact-submit:disabled {
  cursor: not-allowed;
  opacity: 0.7;
}

.contact-submit.is-loading .contact-submit-label::after {
  content: "…";
  display: inline-block;
  margin-left: 2px;
  animation: dots 1s infinite;
}

@keyframes dots {
  0%,
  20% {
    content: ".";
  }
  40% {
    content: "..";
  }
  60%,
  100% {
    content: "…";
  }
}

.contact-submit-arrow {
  flex-shrink: 0;
  transition: transform 0.2s ease;
}

/* Статус (success / error) */
.contact-status {
  margin-top: 18px;
  padding: 14px 18px;
  border-radius: 12px;
  font-size: 14.5px;
  line-height: 1.5;
}

.contact-status-success {
  background: rgba(84, 208, 127, 0.12);
  border: 1px solid rgba(84, 208, 127, 0.35);
  color: #1f6b3a;
}

.contact-status-error {
  background: rgba(220, 72, 72, 0.08);
  border: 1px solid rgba(220, 72, 72, 0.3);
  color: #a02f2f;
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .contact-page {
    padding: 80px 0 60px;
  }
  .contact-layout {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .contact-intro {
    max-width: none;
  }
  .contact-form-wrap {
    padding: 28px 24px;
  }
}

@media (max-width: 520px) {
  .contact-subjects {
    grid-template-columns: 1fr;
  }
  .contact-subject-card {
    flex-direction: row;
    justify-content: flex-start;
    gap: 12px;
    padding: 12px 16px;
  }
  .contact-subject-icon {
    font-size: 18px;
  }
  .contact-submit {
    width: 100%;
    justify-content: center;
  }
}

/* ==========================================================================
   МОДАЛКА УСПЕШНОЙ ОТПРАВКИ
   ========================================================================== */
.contact-modal {
  position: fixed;
  inset: 0;
  z-index: 20000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.28s ease;
}

.contact-modal.is-open {
  opacity: 1;
  pointer-events: auto;
}

.contact-modal[hidden] { display: none; }

.contact-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(17, 17, 17, 0.55);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

.contact-modal-card {
  position: relative;
  max-width: 460px;
  width: 100%;
  background: #ffffff;
  border-radius: 22px;
  padding: 44px 36px 36px;
  text-align: center;
  box-shadow: 0 32px 64px rgba(17, 17, 17, 0.28);
  transform: translateY(16px) scale(0.96);
  transition: transform 0.32s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.contact-modal.is-open .contact-modal-card {
  transform: translateY(0) scale(1);
}

.contact-modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 36px;
  height: 36px;
  border: none;
  background: #f0f6f6;
  color: var(--dark-text-color);
  border-radius: 10px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease, color 0.2s ease;
}

.contact-modal-close:hover {
  background: var(--main-bg-color);
  color: #fff;
}

.contact-modal-check {
  width: 72px;
  height: 72px;
  margin: 0 auto 22px;
  border-radius: 50%;
  background: linear-gradient(135deg, #6fd89a 0%, #54d07f 100%);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 12px 28px rgba(84, 208, 127, 0.4);
  animation: contact-check-pop 0.45s cubic-bezier(0.2, 0.8, 0.2, 1.2);
}

@keyframes contact-check-pop {
  0%   { transform: scale(0.5); opacity: 0; }
  60%  { transform: scale(1.1); opacity: 1; }
  100% { transform: scale(1); opacity: 1; }
}

.contact-modal h2 {
  font-family: "Montserrat", sans-serif;
  font-size: 26px !important;
  font-weight: 800;
  color: var(--main-bg-color);
  margin: 0 0 12px !important;
  letter-spacing: -0.02em;
  text-transform: none;
}

.contact-modal p {
  font-size: 15.5px !important;
  line-height: 1.55;
  color: var(--dark-text-color);
  margin: 0 0 26px !important;
}

.contact-modal-ok {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 140px;
  padding: 13px 28px;
  font-family: "Montserrat", sans-serif;
  font-size: 14.5px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: #fff;
  background: var(--main-bg-color);
  border: none;
  border-radius: 12px;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}

.contact-modal-ok:hover {
  background: var(--gold-color);
  transform: translateY(-1px);
}

/* Разблокированная кнопка submit в :disabled состоянии */
.contact-submit:disabled {
  background: #dde4e4;
  color: #94a0a0;
  cursor: not-allowed;
  box-shadow: none;
  transform: none;
}

.contact-submit:disabled .contact-submit-arrow {
  opacity: 0.5;
}

@media (max-width: 520px) {
  .contact-modal-card {
    padding: 36px 24px 28px;
  }
  .contact-modal h2 { font-size: 22px !important; }
  .contact-modal p { font-size: 14.5px !important; }
  .contact-modal-check { width: 64px; height: 64px; }
}
