/* Contact Form variables
========================================================*/
/* Contact Form Basic Styles 
========================================================*/
.contact-form {
  position: relative;
}
.contact-form label {
  position: relative;
  display: inline-block;
  width: 100%;
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
  margin-bottom: 10px;
}
.contact-form fieldset {
  border: none;
}
.contact-form fieldset > div {
  display: flex;
  align-items: flex-start;
  gap: 22px;
}
.contact-form fieldset > div .btn2 {
  flex-shrink: 0;
}
.contact-form fieldset > div p {
  margin-top: 21px;
  flex: 1;
}
/* Contact Form Placeholder Styles 
========================================================*/
.contact-form ._placeholder {
  width: 100% !important;
  position: absolute;
  left: 0;
  top: 0;
  display: block;
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
  cursor: text;
  border-radius: 0;
  border: 1px solid #d4d4d4;
  background: #fff;
  height: 39px;
  color: #9d9d9d;
  padding: 0 14px;
}
.contact-form ._placeholder.focused {
  opacity: 0.4;
  filter: alpha(opacity=40);
  -webkit-box-shadow: 0px 0px 7px 0px rgba(0, 0, 255, 0.5);
  box-shadow: 0px 0px 7px 0px rgba(0, 0, 255, 0.5);
}
.contact-form ._placeholder.hidden {
  display: none;
}
.contact-form .file ._placeholder {
  display: none;
}
.contact-form .btn2 {
  float: left;
  margin-right: 10px;
}
.contact-form p {
  float: left;
  margin: 0;
}
/* Contact Form Input 
========================================================*/
.contact-form input[type='text'] {
  width: 100%;
  outline: none;
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
  margin: 0;
  border-radius: 0;
  border: 1px solid #d4d4d4;
  background: #fff;
  height: 39px;
  color: #9d9d9d;
  padding: 0 14px;
  resize: none;
}
/* Contact Form File Input 
========================================================*/
.contact-form .input-group {
  position: relative;
  display: table;
  border-collapse: separate;
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
}
.contact-form input.form-control[disabled] {
  cursor: not-allowed;
  background-color: #eeeeee;
  opacity: 1;
}
.contact-form input.form-control {
  position: relative;
  z-index: 2;
  float: left;
  width: 100%;
  margin-bottom: 0;
  padding: 6px 12px;
  -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
  box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
  -webkit-transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;
  -moz-transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;
  transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;
}
.contact-form .input-group-btn:first-child > .btn {
  border-bottom-right-radius: 0;
  border-top-right-radius: 0;
  margin: 0 -1px 0 0;
}
.contact-form .input-group .form-control:last-child {
  border-bottom-left-radius: 0;
  border-top-left-radius: 0;
}
.contact-form .input-group-btn:last-child > .btn {
  border-bottom-left-radius: 0;
  border-top-left-radius: 0;
}
.contact-form .input-group .form-control:first-child {
  border-bottom-right-radius: 0;
  border-top-right-radius: 0;
}
.contact-form input.form-control,
.contact-form .input-group-btn {
  display: table-cell;
  border-collapse: separate;
  float: none !important;
}
.contact-form .input-group-btn label {
  width: auto;
  margin-left: -1px;
}
.contact-form .input-group-btn {
  position: relative;
  font-size: 0;
  white-space: nowrap;
  width: 1%;
  vertical-align: middle;
}
/* Contact Form Button Shimmer Animation
========================================================*/
@keyframes shimmer {
  0% {
    left: -100%;
  }
  16.7% {
    left: 100%;
  }
  16.8%,
  100% {
    left: -100%;
  }
}

/* Contact Form Button Styles (Original btn2 style) 
========================================================*/
.contact-form .contact-submit-button {
  box-shadow: none;
  position: relative;
  text-decoration: none !important;
  padding: 0 23px;
  font: 12px/35px 'tt_squares_condensedregular', sans-serif;
  margin: 0 0 12px 0;
  text-shadow: none;
  color: #ffffff;
  text-transform: uppercase;
  border-radius: 5px;
  border: none;
  background: #313131;
  cursor: pointer;
  -webkit-transition: all 0.25s ease;
  transition: all 0.25s ease;
  overflow: hidden;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
}
.contact-form .contact-submit-button::after {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.4) 45%,
    rgba(255, 255, 255, 0.4) 55%,
    transparent 100%
  );
  animation: shimmer 6s ease-in-out infinite;
  pointer-events: none;
  z-index: 1;
}
.contact-form .contact-submit-button:hover {
  color: #ffffff;
  background: #9F29BA;
  text-decoration: none !important;
  -webkit-transition: all 0.25s ease;
  transition: all 0.25s ease;
}

/* Contact Form Large Button Styles (btn-lg equivalent)
========================================================*/
.contact-form .contact-submit-button-large {
  box-shadow: none;
  position: relative;
  text-decoration: none !important;
  padding: 10px 32px;
  font: 17px/1.33 'tt_squares_condensedregular', sans-serif;
  margin: 0 0 12px 0;
  text-shadow: none;
  color: #ffffff;
  text-transform: uppercase;
  border-radius: 6px;
  border: none;
  background: #313131;
  cursor: pointer;
  -webkit-transition: all 0.25s ease;
  transition: all 0.25s ease;
  overflow: hidden;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
}
.contact-form .contact-submit-button-large::after {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.4) 45%,
    rgba(255, 255, 255, 0.4) 55%,
    transparent 100%
  );
  animation: shimmer 6s ease-in-out infinite;
  pointer-events: none;
  z-index: 1;
}
.contact-form .contact-submit-button-large:hover {
  color: #ffffff;
  background: #9F29BA;
  text-decoration: none !important;
  -webkit-transition: all 0.25s ease;
  transition: all 0.25s ease;
}

/* Contact Form Required Note
========================================================*/
.contact-form .form-required-note {
  font-size: 12px;
  color: #666666;
  font-style: italic;
  margin-top: 8px;
  margin-bottom: 6px;
  padding: 4px 8px;
  background: rgba(0, 0, 0, 0.05);
  border-radius: 4px;
  border-left: 3px solid #9F29BA;
  display: inline-block;
  -webkit-transition: all 0.3s ease;
  transition: all 0.3s ease;
}
.contact-form .form-required-note:hover {
  background: rgba(0, 0, 0, 0.08);
  color: #333333;
  -webkit-transform: translateX(2px);
  transform: translateX(2px);
}

/* Contact Form Input Fields
========================================================*/
.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form input[type="tel"] {
  width: 100%;
  outline: none;
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
  height: 39px;
  border-radius: 5px;
  border: 1px solid #d4d4d4;
  background: #ffffff;
  color: #2d2d2d;
  font: 15px 'tt_squares_condensedregular', sans-serif;
  line-height: 18px;
  padding: 0 14px;
  -webkit-transition: all 0.3s ease;
  transition: all 0.3s ease;
  -webkit-appearance: none;
  -moz-appearance: caret;
  appearance: none;
}
.contact-form input[type="text"]:focus,
.contact-form input[type="email"]:focus,
.contact-form input[type="tel"]:focus {
  border-color: #9F29BA;
  box-shadow: 0 0 0 2px rgba(159, 41, 186, 0.1);
  background: #fafafa;
}
.contact-form input[type="text"]:hover,
.contact-form input[type="email"]:hover,
.contact-form input[type="tel"]:hover {
  border-color: #9F29BA;
}

/* Required Fields Styling
========================================================*/
.contact-form input[required],
.contact-form textarea[required] {
  border-left: 3px solid #9F29BA;
  padding-left: 11px; /* Уменьшаем padding слева, чтобы компенсировать border */
}
.contact-form input[required]:focus,
.contact-form textarea[required]:focus {
  border-left-color: #7C288F;
  box-shadow: 0 0 0 2px rgba(159, 41, 186, 0.1), 
              -3px 0 0 0 #7C288F; /* Добавляем тень слева */
}
.contact-form input[required]:hover,
.contact-form textarea[required]:hover {
  border-left-color: #7C288F;
}

/* Contact Form Inline Button (for same row layout)
========================================================*/
.contact-form .contact-submit-button-inline {
  box-shadow: none;
  position: relative;
  text-decoration: none !important;
  padding: 0 23px;
  font: 12px/35px 'tt_squares_condensedregular', sans-serif;
  margin: 0;
  text-shadow: none;
  color: #ffffff;
  text-transform: uppercase;
  border-radius: 5px;
  border: none;
  background: #313131;
  cursor: pointer;
  -webkit-transition: all 0.25s ease;
  transition: all 0.25s ease;
  overflow: hidden;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 39px; /* Same height as input fields */
  flex: 0 0 auto; /* Don't grow or shrink */
  min-width: 120px; /* Minimum width */
}
.contact-form .contact-submit-button-inline::after {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.4) 45%,
    rgba(255, 255, 255, 0.4) 55%,
    transparent 100%
  );
  animation: shimmer 6s ease-in-out infinite;
  pointer-events: none;
  z-index: 1;
}
.contact-form .contact-submit-button-inline:hover {
  color: #ffffff;
  background: #9F29BA;
  text-decoration: none !important;
  -webkit-transition: all 0.25s ease;
  transition: all 0.25s ease;
}

/* Contact Form Textarea 
========================================================*/
.contact-form textarea {
  width: 100%;
  outline: none;
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
  height: 107px;
  border-radius: 5px;
  border: 1px solid #d4d4d4;
  background: #ffffff;
  color: #2d2d2d;
  font: 15px 'tt_squares_condensedregular', sans-serif;
  line-height: 20px;
  padding: 12px 14px;
  resize: none;
  -webkit-transition: all 0.3s ease;
  transition: all 0.3s ease;
  -webkit-appearance: none;
  -moz-appearance: caret;
  appearance: none;
}
.contact-form textarea:focus {
  border-color: #9F29BA;
  box-shadow: 0 0 0 2px rgba(159, 41, 186, 0.1);
  background: #fafafa;
}
.contact-form textarea:hover {
  border-color: #9F29BA;
}
.contact-form fieldset {
  display: flex;
  flex-direction: column;
  gap: 0;
}
.contact-form .form-row {
  display: flex;
  gap: 10px;
  margin-bottom: 10px;
}
.contact-form .form-field {
  flex: 0 0 249px;
}
/* .contact-form .form-textarea { */
  /* margin-bottom: 32px; */
/* } */

/* Contact Form Labels
========================================================*/
.contact-form label {
  position: relative;
  display: block;
  margin: 0 0 8px 0;
  font-weight: normal;
  font: 15px 'tt_squares_condensedregular', sans-serif;
  line-height: 18px;
  color: #2d2d2d;
  text-align: left;
}
.contact-form label span {
  margin-bottom: 4px;
  display: block;
  color: #2d2d2d;
  font-weight: 500;
}
/* Contact Form Error messages
========================================================*/
.contact-form .error-message {
  position: relative;
  display: block;
  color: #e22004;
  background: none;
  font-weight: 500;
  font-size: 11px;
  font-family: 'tt_squares_condensedregular', sans-serif;
  padding: 2px 0;
  margin-top: 2px;
  margin-bottom: 0;
  border-radius: 0;
  box-shadow: none;
  z-index: 1;
  white-space: normal;
  -webkit-transition: all 0.3s ease;
  transition: all 0.3s ease;
  opacity: 1;
  transform: none;
  height: auto;
  border-left: 2px solid #e22004;
  padding-left: 6px;
  line-height: 1.2;
}

/* Скрываем пустые сообщения об ошибках */
.contact-form .error-message:empty {
  display: none;
}

/* Альтернативный способ - скрываем если только пробелы */
.contact-form .error-message:not(:empty) {
  display: block;
}

/* Contact Form Processing Box
========================================================*/
/* .contact-form .contact-form-loader {
  position: absolute;
  z-index: -1;
  width: 100%;
  height: 100%;
  overflow: hidden;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.9);
  background-image: url('../img/form-loader.gif');
  background-repeat: no-repeat;
  background-position: 50% 50%;
  opacity: 0;
}
.contact-form.processing .contact-form-loader {
  opacity: 1;
  z-index: 99;
  -webkit-transition: all 0.3s ease-in;
  transition: all 0.3s ease-in;
} */
/* Contact Form Modal 
========================================================*/
/* .modal-open {
  overflow: hidden;
}
.contact-form .modal {
  display: none;
  overflow: auto;
  overflow-y: scroll;
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 1050;
  -webkit-overflow-scrolling: touch;
  outline: 0;
}
.contact-form .modal h4 {
  padding: 0;
  margin: 0;
} */
/* .modal.fade .modal-dialog {
  -webkit-transform: translate(0, -25%);
  -ms-transform: translate(0, -25%);
  transform: translate(0, -25%);
  -webkit-transition: -webkit-transform 0.3s ease-out;
  -moz-transition: -moz-transform 0.3s ease-out;
  -o-transition: -o-transform 0.3s ease-out;
  transition: transform 0.3s ease-out;
}
.modal.in .modal-dialog {
  -webkit-transform: translate(0, 0);
  -ms-transform: translate(0, 0);
  transform: translate(0, 0);
}
.modal-content {
  position: relative;
  background-color: #ffffff;
  border: 1px solid #999999;
  border: 1px solid rgba(0, 0, 0, 0.2);
  border-radius: 6px;
  -webkit-box-shadow: 0 3px 9px rgba(0, 0, 0, 0.5);
  box-shadow: 0 3px 9px rgba(0, 0, 0, 0.5);
  background-clip: padding-box;
  outline: none;
}
.modal-backdrop {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 1040;
  background-color: #000000;
}
.modal-backdrop.fade {
  opacity: 0;
  filter: alpha(opacity=0);
}
.modal-backdrop.in {
  opacity: 0.5;
  filter: alpha(opacity=50);
}
.modal-header {
  padding: 15px;
  border-bottom: 1px solid #e5e5e5;
  min-height: 16.42857143px;
}
.modal-header .close {
  margin-top: -2px;
}
.modal-title {
  margin: 0;
  line-height: 1.42857143;
}
.modal-body {
  position: relative;
  padding: 20px;
}
.modal-dialog {
  width: 600px;
  margin: 10px auto;
}
@media only screen and (max-width: 768px) {
  .modal-dialog {
    position: relative;
    width: auto;
    margin: 10px;
  }
} */
/* Contact Form Close icon 
========================================================*/
/* .close {
  float: right;
  font-size: 21px;
  line-height: 1;
  color: #000000;
  text-shadow: 0 1px 0 #ffffff;
  opacity: 0.2;
  filter: alpha(opacity=20);
}
.close:hover,
.close:focus {
  color: #000000;
  text-decoration: none;
  cursor: pointer;
  opacity: 0.5;
  filter: alpha(opacity=50);
}
button.close {
  padding: 0;
  cursor: pointer;
  background: transparent;
  border: 0;
  -webkit-appearance: none;
  appearance: none;
} */
/*---------------------------------------------------------------------------------------------------------------------------*/
@media (min-width: 992px) and (max-width: 1219px) {
  .contact-form .form-row {
    flex-direction: column;
    gap: 0;
  }
  .contact-form .form-field {
    flex: 1;
    width: 100%;
  }
}
/*---------------------------------------------------------------------------------------------------------------------------*/
@media (min-width: 768px) and (max-width: 991px) {
  .contact-form .form-row {
    flex-direction: column;
    gap: 0;
  }
  .contact-form .form-field {
    flex: 1;
    width: 100%;
  }
}
/*---------------------------------------------------------------------------------------------------------------------------*/
@media (max-width: 767px) {
  .contact-form .form-row {
    flex-direction: column;
    gap: 0;
    margin-bottom: 0; /* Убираем отступ снизу на мобильных */
  }
  .contact-form .form-field {
    flex: 1;
    width: 100%;
    margin-bottom: 16px; /* Единообразный отступ между полями */
  }
  .contact-form .form-textarea {
    margin-bottom: 16px; /* Единообразный отступ для textarea */
  }
  .contact-form label {
    margin-bottom: 0; /* Убираем отступ снизу у лейблов на мобильных */
  }
  
  /* Mobile Button Fixes */
  .contact-form .contact-submit-button,
  .contact-form .contact-submit-button-large {
    width: 100%;
    min-height: 44px; /* Минимальная высота для touch-устройств */
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
  }
  
  /* Mobile Inline Button Fixes */
  .contact-form .contact-submit-button-inline {
    width: 100%;
    min-height: 44px;
    margin-top: 16px;
  }
}
