.form-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: 100%;
  margin-bottom: 24px;
}

.form-field label {
  font-size: 15px;
  font-weight: 600;
  color: #e3dbf4; /* softened */
}

.form-field input {
  width: 100%;
  padding: 12px 14px;
  border-radius: 12px;
  font-size: 16px;
  font-family: inherit;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.18);
  outline: none;
  transition: border-color 120ms, box-shadow 120ms;
}

.form-field input::placeholder {
  color: rgba(255, 255, 255, 0.35);
}

.form-field input:focus {
  border-color: #b56cff; /* purple accent */
  box-shadow: 0 0 0 3px rgba(181, 108, 255, 0.32);
}

.error-message {
  font-size: 14px;
  color: #ff7882;
  line-height: 1.3;
  display: none; /* hide by default */
}
.info-message {
  font-size: 14px;
  line-height: 1.35;
  color: #cfc7e8; /* soft purple-grey */
  margin-top: 4px;
}

/* show info by default when field is in 'info' state */
.form-field.info .info-message {
  display: block;
}

/* hide error in info state */
.form-field.info .error-message {
  display: none;
}

/* hide info in error state */
.form-field.error .info-message {
  display: none;
}

.form-field textarea {
  width: 100%;
  padding: 12px 14px;
  border-radius: 12px;
  font-size: 16px;
  font-family: inherit;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.18);
  outline: none;
  resize: none;
  min-height: 120px;
  line-height: 1.45;
  transition: border-color 120ms, box-shadow 120ms;
  line-break: anywhere;
}

.form-field textarea::placeholder {
  color: rgba(255, 255, 255, 0.35);
}

.form-field textarea:focus {
  border-color: #b56cff; /* purple accent */
  box-shadow: 0 0 0 3px rgba(181, 108, 255, 0.32);
}

/* Error handling (same as input) */
.form-field.error textarea {
  border-color: #ff4b5c;
  box-shadow: 0 0 0 3px rgba(255, 75, 92, 0.25);
}

.form-field.error input {
  border-color: #ff4b5c;
  box-shadow: 0 0 0 3px rgba(255, 75, 92, 0.25);
}

.form-field.error .error-message {
  display: block;
}

/* container */
.segmented {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

/* hide native radios but keep accessible */
.segmented input[type="radio"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

/* small “button” labels */
.segmented label {
  padding: 6px 10px;
  border-radius: 10px;
  font-size: 14px;
  line-height: 1;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  cursor: pointer;
  user-select: none;
  transition: background 120ms ease, border-color 120ms ease, box-shadow 120ms ease,
    color 120ms ease;
  /* keep them small but tappable */
  min-height: 32px;
  display: inline-flex;
  align-items: center;
}

/* hover */
.segmented label:hover {
  background: rgba(255, 255, 255, 0.12);
}

/* selected state */
.segmented input[type="radio"]:checked + label {
  background: linear-gradient(180deg, rgba(181, 108, 255, 0.35), rgba(181, 108, 255, 0.2));
  border-color: rgba(181, 108, 255, 0.65);
  box-shadow: 0 0 0 3px rgba(181, 108, 255, 0.22);
}

/* keyboard focus ring */
.segmented input[type="radio"]:focus-visible + label {
  outline: 2px solid #b56cff;
  outline-offset: 2px;
}

/* disabled option */
.segmented input[type="radio"]:disabled + label {
  opacity: 0.55;
  cursor: not-allowed;
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.12);
}

/* error state (optional, matches your .form-field.error pattern) */
.form-field.error .segmented label {
  border-color: rgba(255, 75, 92, 0.55);
}
.form-field.error .segmented input:checked + label {
  box-shadow: 0 0 0 3px rgba(255, 75, 92, 0.25);
}

/* The wrapper label */
.checkbox {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 15px;
  cursor: pointer;
  user-select: none;
  color: #fff;
}

/* Hide default checkbox but keep accessibility */
.checkbox input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

/* Custom box */
.checkbox-box {
  width: 18px;
  height: 18px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.18);
  display: inline-flex;
  justify-content: center;
  align-items: center;
  transition: background 120ms ease, border-color 120ms ease, box-shadow 120ms ease;
  flex-shrink: 0;
}

/* Hover highlight */
.checkbox:hover .checkbox-box {
  background: rgba(255, 255, 255, 0.1);
}

/* Checked — purple accent + subtle glow */
.checkbox input:checked + .checkbox-box {
  background: #b56cff;
  border-color: #d5b0ff;
  box-shadow: 0 0 8px rgba(181, 108, 255, 0.45);
}

/* Checkmark */
.checkbox input:checked + .checkbox-box::before {
  content: "✔";
  font-size: 14px;
  line-height: 1;
  color: #fff;
}

/* Focus ring */
.checkbox input:focus-visible + .checkbox-box {
  outline: 2px solid #b56cff;
  outline-offset: 3px;
}

/* Disabled */
.checkbox input:disabled + .checkbox-box {
  opacity: 0.5;
  cursor: not-allowed;
}
.checkbox input:disabled ~ * {
  cursor: not-allowed;
  opacity: 0.6;
}

.form-field button {
  align-self: baseline;
}

/* TODO: No good to override input styles, better to set class for inputs */
.form-field .file-input {
  position: absolute;
  opacity: 0;
  width: 0.1px;
  height: 0.1px;
  overflow: hidden;
  padding: 0;
}

/* custom trigger */
.file-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #fff;
  cursor: pointer;
  font-weight: 600;
  transition: background 120ms ease, border-color 120ms ease;
}

.file-label:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.22);
}

.verify-section {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 16px 20px;
  color: #d8d2e8;
  line-height: 1.5;
}

.verify-text {
  margin-bottom: 8px;
  color: #cfc7e8;
  font-weight: 500;
}

.verify-code {
  background: linear-gradient(90deg, rgba(181, 108, 255, 0.08), rgba(255, 255, 255, 0.03));
  padding: 12px 16px;
  border-radius: 10px;
  overflow-x: auto;
  color: #fff;
  font-size: 14px;
  font-family: ui-monospace, monospace;
  line-height: 1.45;
  white-space: pre-wrap;
}
