
/* 
10/31/25
========================================
form-questions 
========================================
*/

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

form {
  position: relative;
  max-width: 700px;
  min-width: 250px;
  padding: 30px 25px;
  background-color: white;
  border-radius: 30px;
  margin: 40px 0;
  left: 50%;
  transform: translate(-50%, 0);
  z-index: 101; 
}
form h1 {
  color: rgb(149, 147, 147);
  font-weight: 100;
  letter-spacing: 0.01em;
  margin-left: 15px;
  margin-bottom: 10px;
  text-transform: uppercase;
}
form h2 {
  color: rgb(149, 147, 147);
  font-weight: 50;
  letter-spacing: 0.01em;
  margin-left: 10px;
  margin-bottom: 10px;
}
form h6 {
  color: rgb(149, 147, 147);
  letter-spacing: 0.01em;
  margin-left: 15px;
  margin-bottom: 10px;
  font-weight: bolder;
}  
/* * form-button */
form button {
  margin-top: 35px;
  background-color: white;
  border: 1px solid #2d94f5;
  line-height: 0;
  font-size: 17px;
  box-sizing: border-box;
  padding: 20px 15px;
  border-radius: 30px;
  color: #2d94f5;
  font-weight: 100;
  letter-spacing: 0.01em;
  z-index: 102; /* Ensures button is clickable above form elements */
}
form button:hover, form button:focus {
  color: white;
  background-color: #2d94f5;
}
/* * form-question */
form .question {
  width: 100%;
  position: relative;
  margin-bottom: 10px; /* Ensure even spacing between questions */
}
/* * form-input */
form .question input,
form .question textarea,
form .question select {
  appearance: none;
  width: 100%;
  height: 50px; /* Set a consistent height */
  padding: 10px 15px; /* Ensure consistent padding */
  font-size: 17px;
  color: #2d94f5;
  background-color: white;
  font-weight: bold;
  letter-spacing: 0.01em;
  box-sizing: border-box;
  border-radius: 15px;
  border: 1px solid #2d94f5;
  margin: 0; /* Reset margin to ensure consistency */
  line-height: 1.2; 
}
/* Specific adjustments for select elements */
form .question select {
  height: 50px; /* Ensure select elements have consistent height */
  padding-top: 10px; /* Ensure select content is vertically centered */
  padding-bottom: 10px; /* Ensure select content is vertically centered */
}
form .question textarea {
  min-height: 50px; /* height of the textarea */
}
/* Remove bottom margin for the last question to avoid extra space */
form .question:last-child {
  margin-bottom: 0;
}
/* * form-input-focus */
form .question textarea:focus, 
form .question select:focus,
form .question input:focus {
  outline: none;
  background: rgb(255, 254, 184);
  color: #2d94f5;
  padding: 10px 15px; /* Ensure padding remains consistent on focus */
}
/* * form-input-readonly */
form .question textarea[readonly],
form .question input[readonly] {
  margin-left: 7px;
  color: #2d94f5;
  font-size: 17px;
  font-weight: bold;
  outline: none;
  height: -0px;
  padding-bottom: 10px;
  padding-top: 7px;
  border: 0px;
  border-radius: 15px; 
  pointer-events: none;
  background-color: transparent;
  text-transform: lowercase;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
/* * form-label */
form .question label,
form .question textarea + label  {
  transform-origin: left center;
  color: #2d94f5;
  font-weight:bolder;
  letter-spacing: 0.01em;
  font-size: 18px;
  box-sizing: border-box;
  padding: 1.25rem 1.5rem;
  display: block;
  position: absolute;
  margin-top: -40px;
  z-index: 104; 
  pointer-events: none;
  white-space: nowrap; 
}
/* Specific adjustments for textarea labels if needed */
form .question textarea + label {
  background: transparent; /* Ensures label doesn't block textarea content */
  transition: all 0.2s ease-in-out; /* Smooth transition for any animations */
}
form .question input:not(:placeholder-shown) ~ label,
form .question textarea:not(:placeholder-shown) ~ label,
form .question select:not(:placeholder-shown) ~ label {
  text-transform: uppercase;
  font-style: normal;
  font-weight: 300;
  -moz-transform: translate(5px, -35px) scale(0.6);
  -ms-transform: translate(5px, -35px) scale(0.6);
  -webkit-transform: translate(5px, -35px) scale(0.6);
  transform: translate(5px, -35px) scale(0.6);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
form .question select:not(:placeholder-shown) ~ label {
  transform: translate(5px, -34px) scale(0.6);  /* Apply only 1px lower than other labels */
}
form .question :focus ~ label,
form .question textarea:focus ~ label,
form .question select:focus ~ label,
form .question input:focus ~ label {
  color: rgb(68, 68, 68);
  font-weight: 500;
  font-size: 8px;
  font-style: italic;
  margin-top: 5px; 
  -moz-transform: translate(0, -35px);
  -ms-transform: translate(0, -35px);
  -webkit-transform: translate(0, -35px);
  transform: translate(0, -35px);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
form .question textarea:not(:placeholder-shown) ~ label {
  margin-top: -47px;  
}
form .question textarea:focus ~ label {
  margin-top: -7px; 
}
/* * radio-buttons */
.form-check {
  display: flex;
  align-items: center;
  margin-bottom: 1px; /* Spacing between each radio button */
}
.form-check label {
  cursor: pointer;
  color: #2d94f5; 
  font-weight: bold;
}
/*  Adjust styles for address input fields */
form .question .input-group {
  display: flex;
  align-items: center;
  width: 100%;
  position: relative;
}
form .question .input-group input {
  flex: 1;
  padding: 10px 15px;
  padding-right: 10px;
  border-radius: 15px !important;
  height: 50px;
  font-size: 17px;
  color: #2d94f5;
  background-color: white;
  font-weight: bold;
  letter-spacing: 0.01em;
  border: 1px solid #2d94f5;
}
form .question .input-group .input-group-text {
  position: absolute;
  right: 5px;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  padding: 0;
  color: #2d94f5;
  pointer-events: none;
  z-index: 105;
}
/*  Address input label positioning */
form .question .input-group label {
  transform-origin: left center;
  color: #2d94f5;
  font-weight: 100;
  letter-spacing: 0.01em;
  font-size: 14px;
  position: absolute;
  top: -19px;
  left: 5px;
  z-index: 104;
  pointer-events: none;
  white-space: nowrap;
  padding: 0 5px;
  background-color: white;
}
/*  Address input focus and filled states */
form .question .input-group input:focus ~ label,
form .question .input-group input:not(:placeholder-shown) ~ label {
  color: rgb(68, 68, 68);
  font-weight: 500;
  font-size: 10px;
  font-style: italic;
  transform: translate(0, -35px) scale(0.6);
}
/* 
========================================
end of form-questions 
========================================
*/
