body {
  font-family: 'Mukta Mahee', sans-serif;
}

/* Mobile: force form to the top */
@media (max-width: 768px) {
  .form {
    order: -1;
  }
}

/* --- INPUTS & SELECTS (shared styles) --- */
.floating-group input,
.floating-group textarea,
#smartcapture-form-main select,
.input-wrapper input {
  margin-bottom: 0.75em !important;
  box-sizing: border-box !important;
  border-radius: 5px !important;
  width: 100% !important;
  font-size: 14px !important;
  border: 1px solid #ccc !important;
  background-color: rgba(255, 255, 255, 0.7) !important;
  color: #6e747a !important;
}

#smartcapture-form-main select {
  padding: 1em 0.75em !important;
}

#smartcapture-form-main textarea {
  padding: 2em 0.75em !important;
}

.floating-group input,
.floating-group textarea {
  padding: 1em 0.75em !important;
}

.input-wrapper input {
  padding: 1em 1.5em !important;
}

/* --- CHECKBOXES --- */
input[type="checkbox"]{
  margin-right: 3px;
  width: 35px !important;
  height: 35px !important;
  padding: 0 !important;
}

/* Wrap checkbox + text so they align properly */
.checkbox-label {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  line-height: 1.3;
  font-size: 14px;
}

/* Fix checkbox size inflation on iOS/Android */
.checkbox-label input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  width: 10px !important;   /* smaller */
  height: 10px !important;  /* smaller */
  border: 1.5px solid #555; /* thinner border fits better on 10px */
  border-radius: 2px;
  background: #fff;
  margin-top: 2px;
  flex-shrink: 0;
  position: relative;
  box-sizing: border-box;
}

/* Custom checkmark for 10x10 box */
.checkbox-label input[type="checkbox"]:checked {
  background: #0070e0;
  border-color: #0070e0;
}

.checkbox-label input[type="checkbox"]:checked::after {
  content: "";
  position: absolute;
  top: 1px;      /* centered for 10px box */
  left: 3px;     /* centered for 10px box */
  width: 3px;    /* smaller checkmark */
  height: 5px;   /* smaller checkmark */
  border-right: 2px solid #fff;
  border-bottom: 2px solid #fff;
  transform: rotate(45deg);
}

/* Text next to checkbox */
.checkbox-text {
  display: inline-block;
  font-size: 14px;
  color: #333;
  max-width: 90%;
}

/* --- HEADERS & MESSAGES --- */
.header-text {
  padding: 0 !important;
  margin-bottom: 1em;
  font-size: 20px;
  font-weight: 450;
  text-align: start;
}

.success-message,
.error-message {
  padding: 0 !important;
  font-weight: 450;
  font-family: 'Mukta Mahee', sans-serif;
  line-height: 1.1;
}

.success-message {
  font-size: 18px;
}

.error-message {
  font-size: 24px;
  color: #BE1450;
}

/* --- SEARCH ICON --- */
.search-icon {
  position: absolute;
  left: 5px;
  top: 13px;
  width: 15px;
}

/* --- STATUS MESSAGE --- */
#statusMessage {
  width: 100%;
  text-align: left;
  color: red;
  font-size: 12px;
  display: block;
}

/* --- SPINNER --- */
.spinner {
  position: absolute;
  right: 10px;
  top: 14px;
  width: 20px;
  height: 20px;
  border: 2px solid #ccc;
  border-top: 2px solid #555;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  display: none;
  font-weight: 800;
  color: #666;
}

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

/* --- CANCEL BUTTON --- */
.cancel-btn {
  position: absolute;
  right: 12px;
  top: 12px;
  width: 30px;
  height: 30px;
  font-size: 14px;
  line-height: 24px;
  cursor: pointer;
  text-align: center;
  user-select: none;
  font-weight: 800;
  border-radius: 50%;
  background-color: #eee;
  display: none;
  padding: 5px;
  color: #666;
}

.cancel-btn:hover {
  color: #000;
}

#Company.has-value ~ .cancel-btn {
  display: block !important;
}

#Company:not(.has-value) ~ .cancel-btn {
  display: none !important;
}

/* --- FLOATING LABEL GROUPS (shared rules) --- */
.floating-group,
.input-wrapper {
  position: relative;
}

.floating-group label,
.input-wrapper .floating-label {
  position: absolute;
  left: 10px;
  top: 30%;
  transform: translateY(-25%);
  color: #888;
  pointer-events: none;
  background: white;
  padding: 0 4px;
  transition: 0.25s ease;
}

/* FLOAT WHEN VALUE OR FOCUS */
.floating-group input:focus + label,
.floating-group input:valid + label,
.floating-group textarea:focus + label,
.floating-group textarea:valid + label,
.input-wrapper input:not(:placeholder-shown) + .floating-label,
.input-wrapper input:focus + .floating-label {
  top: 0;
  font-size: 13px;
  color: #333;
}

/* --- BUTTON LABEL --- */
.btn-label {
  display: block;
  width: 100%;
  text-align: right;
  margin: 0 !important;
}

/* --- SEARCH RESULTS DROPDOWN --- */
#results {
  display: none;
  position: absolute;
  background-color: white;
  top: 100%;
  left: 0;
  width: 100%;
  z-index: 5;
  border: 1px solid #ccc;
  overflow-y: auto;
  border-radius: 5px;
}

.result-item {
  padding: 6px 8px;
  cursor: pointer;
  color: black;
  text-align: start;
}

.result-item:hover {
  background: #f0f0f0;
}
