@import url('https://fonts.googleapis.com/css2?family=Golos+Text:wght@400;500;600;700&display=swap');

.web-form-container {
  --icc-navy: #0b1f3a;
  --icc-blue: #1f4f95;
  --icc-blue-2: #2f6fc2;
  --icc-text: #172b46;
  --icc-muted: #55657d;
  --icc-border: #d8e3f1;
  --icc-radius: 12px;
  --icc-font: 'Golos Text', -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  max-width: 1040px !important;
  margin: 0 auto !important;
  padding: 32px 20px 80px !important;
  font-family: var(--icc-font) !important;
  color: var(--icc-text) !important;
}

body {
  background: linear-gradient(170deg, #eef2f9 0%, #f5f7fc 50%, #eef2f9 100%) !important;
}

.web-form-container .web-form-header {
  display: block !important;
  margin: 0 0 18px !important;
}

.web-form-container .web-form-head {
  margin-bottom: 10px !important;
}

.web-form-container .web-form-title {
  font-size: 42px !important;
  font-weight: 700 !important;
  line-height: 1.15 !important;
  letter-spacing: -0.02em !important;
  color: var(--icc-navy) !important;
  white-space: normal !important;
  overflow: visible !important;
  text-overflow: unset !important;
}

.web-form-container .web-form-actions {
  display: none !important;
}

.web-form-container .web-form-introduction {
  background: linear-gradient(180deg, #f8fbff 0%, #f0f6fd 100%);
  border: 1px solid var(--icc-border);
  border-left: 4px solid var(--icc-blue-2);
  border-radius: 0 16px 16px 0;
  padding: 14px 18px;
  margin: 12px 0 24px 0;
  color: var(--icc-text);
  font-size: 14.5px;
  line-height: 1.65;
}

.web-form-container .web-form {
  background: #ffffff !important;
  border: 1px solid rgba(191, 209, 232, 0.85) !important;
  border-radius: 24px !important;
  box-shadow:
    0 2px 8px rgba(15, 34, 58, 0.04),
    0 20px 60px rgba(15, 34, 58, 0.08) !important;
  padding: 34px 32px 28px !important;
}

.web-form-container .web-form-body,
.web-form-container .web-form-wrapper {
  background: transparent !important;
}

.web-form-container .form-section,
.web-form-container .section-body,
.web-form-container .form-page {
  background: transparent !important;
}

.web-form-container .section-head,
.web-form-container h5.section-head {
  background: linear-gradient(90deg, #091829 0%, #14305c 50%, #1f4f95 100%) !important;
  color: #ffffff !important;
  padding: 11px 18px !important;
  margin: 22px 0 14px 0 !important;
  border-radius: 14px !important;
  font-size: 11px !important;
  font-weight: 700 !important;
  letter-spacing: 0.09em !important;
  text-transform: uppercase !important;
  line-height: 1.3 !important;
  border: none !important;
}

.web-form-container .frappe-control {
  margin-bottom: 18px !important;
}

.web-form-container .frappe-control .control-label,
.web-form-container .control-label {
  font-size: 11px !important;
  font-weight: 700 !important;
  color: #5f7088 !important;
  text-transform: uppercase !important;
  letter-spacing: 0.06em !important;
  margin-bottom: 6px !important;
  line-height: 1.4 !important;
}

.web-form-container .frappe-control input[type="text"],
.web-form-container .frappe-control input[type="email"],
.web-form-container .frappe-control input[type="tel"],
.web-form-container .frappe-control input[type="number"],
.web-form-container .frappe-control input[type="url"],
.web-form-container .frappe-control input[type="search"],
.web-form-container .frappe-control input[type="date"],
.web-form-container .frappe-control input[type="password"],
.web-form-container .frappe-control textarea,
.web-form-container .frappe-control select {
  width: 100% !important;
  box-sizing: border-box !important;
  background: linear-gradient(180deg, #fafcff 0%, #f6f9ff 100%) !important;
  border: 1.5px solid var(--icc-border) !important;
  border-radius: var(--icc-radius) !important;
  font-family: var(--icc-font) !important;
  font-size: 14px !important;
  line-height: 1.45 !important;
  color: var(--icc-text) !important;
  padding: 11px 14px !important;
  min-height: 46px !important;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease !important;
}

.web-form-container .frappe-control textarea {
  min-height: 96px !important;
  resize: vertical !important;
}

.web-form-container .frappe-control input:focus,
.web-form-container .frappe-control textarea:focus,
.web-form-container .frappe-control select:focus {
  background: #ffffff !important;
  border-color: var(--icc-blue-2) !important;
  box-shadow: 0 0 0 4px rgba(47, 111, 194, 0.12) !important;
  outline: none !important;
}

.web-form-container .text-muted,
.web-form-container .help-box,
.web-form-container .control-input-help {
  color: var(--icc-muted) !important;
  font-size: 12px !important;
}

.web-form-container .web-form-footer {
  margin-top: 28px !important;
  padding-top: 8px !important;
}

.web-form-container .btn-primary,
.web-form-container button.btn-primary {
  background: linear-gradient(90deg, #0b1f3a 0%, #1f4f95 100%) !important;
  border: none !important;
  border-radius: 12px !important;
  color: #fff !important;
  font-weight: 600 !important;
  padding: 12px 20px !important;
  min-height: 46px !important;
  box-shadow: 0 10px 24px rgba(31, 79, 149, 0.20) !important;
}

.web-form-container .btn-primary:hover,
.web-form-container button.btn-primary:hover {
  filter: brightness(1.03);
}

@media (max-width: 768px) {
  .web-form-container {
    padding: 20px 14px 56px !important;
  }

  .web-form-container .web-form {
    padding: 22px 16px 20px !important;
    border-radius: 18px !important;
  }

  .web-form-container .web-form-title {
    font-size: 30px !important;
  }

  .web-form-container .section-head,
  .web-form-container h5.section-head {
    margin-top: 18px !important;
    padding: 10px 14px !important;
  }
}

/* ── Гарантированный показ кнопки Отправить ── */
.submit-btn,
button.submit-btn,
.page-form-actions .submit-btn,
.page-form-actions {
  display: inline-flex !important;
  visibility: visible !important;
  opacity: 1 !important;
}

.page-form-actions {
  display: flex !important;
  justify-content: flex-end !important;
  padding: 20px 0 10px !important;
  margin-top: 16px !important;
}

.submit-btn {
  min-height: 50px !important;
  min-width: 200px !important;
  padding: 0 32px !important;
  border: 0 !important;
  border-radius: 13px !important;
  background: linear-gradient(135deg, #0b1f3a 0%, #1f4f95 100%) !important;
  color: #fff !important;
  font-size: 15px !important;
  font-weight: 700 !important;
  cursor: pointer !important;
  align-items: center !important;
  justify-content: center !important;
  box-shadow: 0 10px 24px rgba(31,79,149,0.25) !important;
}

/* ── Кнопка скрыта через .web-form-actions display:none — исправляем ── */
.web-form-actions {
  display: flex !important;
  justify-content: flex-end !important;
  padding: 20px 0 8px !important;
  margin-top: 16px !important;
  border-top: 1px solid #d8e3f1 !important;
}

.web-form-footer {
  display: block !important;
  height: auto !important;
}

/* ФИКС: Frappe скрывает .web-form-actions через display:none */
.web-form-actions { display: flex !important; justify-content: flex-end !important; padding: 20px 0 !important; border-top: 1px solid #d8e3f1 !important; }
.web-form-footer { display: block !important; min-height: 80px !important; }
.submit-btn { display: inline-flex !important; align-items: center !important; justify-content: center !important; min-height: 50px !important; min-width: 200px !important; padding: 0 32px !important; border: 0 !important; border-radius: 13px !important; background: linear-gradient(135deg,#0b1f3a,#1f4f95) !important; color: #fff !important; font-size: 15px !important; font-weight: 700 !important; cursor: pointer !important; box-shadow: 0 10px 24px rgba(31,79,149,0.25) !important; }


/* Мобильный — кнопки одна над другой */
@media (max-width: 600px) {
  .web-form-footer .web-form-actions {
    flex-direction: column !important;
    padding: 16px 0 !important;
    gap: 10px !important;
    width: 100% !important;
  }
  .web-form-footer .web-form-actions .discard-btn,
  .web-form-footer .web-form-actions .submit-btn {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    margin: 0 !important;
    display: flex !important;
    justify-content: center !important;
  }
}
