.profile-form .profile-gender {
  grid-column: 1 / -1;
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}
.profile-gender > legend {
  margin: 0 0 10px;
  padding: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.6;
}
.profile-gender-options {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 9px;
}
.profile-form .profile-gender-option {
  position: relative;
  display: block;
  min-width: 0;
  margin: 0;
  cursor: pointer;
}
.profile-form .profile-gender-option > input[type="radio"] {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  min-height: 0;
  margin: 0;
  padding: 0;
  border: 0;
  opacity: 0;
  cursor: pointer;
}
.profile-gender-option > span {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
  padding: 12px 10px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: var(--surface);
  color: var(--text);
  font-size: 13px;
  font-weight: 550;
  line-height: 1.4;
  text-align: center;
  transition: border-color .15s, background .15s, box-shadow .15s;
}
.profile-gender-option > input:hover + span {
  border-color: var(--brand-blue);
  background: var(--blue-soft);
}
.profile-gender-option > input:checked + span {
  border-color: var(--brand-blue);
  background: var(--blue-soft);
  color: var(--brand-deep);
  font-weight: 700;
  box-shadow: inset 0 0 0 1px var(--brand-blue);
}
.profile-gender-option > input:focus-visible + span {
  outline: 3px solid var(--brand-blue);
  outline-offset: 3px;
}
html.vision-mode .profile-gender > legend {
  font-size: 18px;
  color: #111;
}
html.vision-mode .profile-gender-options {
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
}
html.vision-mode .profile-gender-option > span {
  min-height: 54px;
  border: 2px solid #333;
  background: #fff;
  font-size: 18px;
}
html.vision-mode .profile-gender-option > input:checked + span {
  border: 3px solid #111;
  padding: 11px 9px;
  text-decoration: underline;
  text-underline-offset: 4px;
}
html.vision-mode .profile-gender-option > input:focus-visible + span {
  outline-color: #111;
}
@media (max-width: 480px) {
  .profile-gender-options { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .profile-gender-option:last-child { grid-column: 1 / -1; }
}
@media (prefers-reduced-motion: reduce) {
  .profile-gender-option > span { transition: none; }
}
@media (forced-colors: active) {
  .profile-gender-option > input:checked + span { border: 3px solid Highlight; }
  .profile-gender-option > input:focus-visible + span { outline-color: Highlight; }
}
