/* Keep choices separate from the page's full-width text inputs. */
#addSongModal #addSongForm.sl-registration-layout{
  display:grid;
  grid-template-columns:minmax(0,1.15fr) minmax(0,1fr)!important;
  align-items:start;
  gap:16px;
  min-width:0;
  margin:0;
}
#addSongForm .sl-registration-details{min-width:0;padding:20px}
#addSongForm .sl-registration-details-hint{
  margin:0;
  color:var(--sl-muted, #a5b5d0);
  font-size:13px;
  line-height:1.8;
}
#addSongForm .sl-registration-details:has(fieldset:not([hidden])) .sl-registration-details-hint{display:none}
#addSongForm > .sl-add-submit-area{
  grid-column:1/-1;
  margin-top:0;
}
#addSongForm fieldset{
  min-width:0;
  box-sizing:border-box;
  margin:12px 0 4px!important;
  padding:16px!important;
  border:1px solid var(--sl-border, #304b75);
  border-radius:14px;
  background:rgba(6,18,36,.32);
}
#addSongForm fieldset[hidden]{display:none!important}
#addSongForm legend{
  max-width:100%;
  box-sizing:border-box;
  padding:0 8px;
  color:var(--sl-text, #f2f6ff);
  font-size:14px;
  font-weight:700;
  line-height:1.6;
}
#addSongForm .sl-genre-checks{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(min(100%,150px),1fr));
  gap:10px;
}
#addSongForm .sl-genre-checks label{
  display:flex!important;
  align-items:center;
  gap:10px!important;
  min-width:0;
  min-height:48px;
  max-width:100%;
  box-sizing:border-box;
  margin:0!important;
  padding:11px 12px;
  border:1px solid #385276;
  border-radius:10px;
  background:#10223c;
  color:#eaf1ff!important;
  font-size:13px!important;
  font-weight:600!important;
  line-height:1.5;
  overflow-wrap:anywhere;
  cursor:pointer;
  transition:background-color .15s,border-color .15s;
}
#addSongForm .sl-genre-checks label:hover{background:#193354;border-color:#7b9cce}
#addSongForm .sl-genre-checks label:has(input:checked){
  background:#233d75;
  border-color:#99b8ff;
  color:#fff!important;
  box-shadow:inset 0 0 0 1px #99b8ff;
}
#addSongForm .sl-genre-checks label:focus-within{outline:2px solid #b2caff;outline-offset:3px}
#addSongForm .sl-genre-checks input[type="checkbox"]{
  appearance:auto;
  flex:0 0 18px;
  width:18px!important;
  height:18px!important;
  min-height:18px!important;
  margin:0!important;
  padding:0!important;
  accent-color:#8eacff;
  box-shadow:none!important;
  cursor:pointer;
}
#addSongForm .sl-registration-group{margin:20px 0 0}
#addSongForm .sl-registration-group:first-child{margin-top:12px}
#addSongForm .sl-registration-group h4{
  margin:0 0 10px;
  padding-left:10px;
  border-left:3px solid #8eacff;
  color:#d4e2ff;
  font-size:13px;
  line-height:1.5;
}
#addSongForm .sl-registration-hint{
  margin:0 0 12px;
  color:var(--sl-muted, #a5b5d0);
  font-size:12px;
  line-height:1.7;
}
#newPublisher,#newGenre1{width:100%;max-width:100%;box-sizing:border-box;font:inherit}
@media(max-width:1280px), (pointer:coarse){
  #addSongModal #addSongForm.sl-registration-layout{
    grid-template-columns:minmax(0,1fr)!important;
  }
}
@media(max-width:480px){
  #addSongForm fieldset{padding:12px!important}
  #addSongForm .sl-genre-checks{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
  #addSongForm .sl-genre-checks label{padding:10px 8px;font-size:12px!important;gap:8px!important}
}
@media(prefers-reduced-motion:reduce){#addSongForm .sl-genre-checks label{transition:none}}
/* Fit the complete registration form on desktop without shrinking touch targets. */
@media(min-width:1281px) and (pointer:fine){
  html body.sl-redesign.sl-add-song-open #addSongModal.sl-add-song-page-overlay{
    padding:10px 14px!important;
  }
  #addSongModal .sl-add-song-heading{padding:0 4px 8px!important}
  #addSongModal .sl-add-song-heading h2{font-size:clamp(19px,2.6vh,26px)!important}
  #addSongModal .sl-add-song-heading p{margin-top:4px!important;font-size:11px!important}
  #addSongModal #addSongForm.sl-registration-layout{gap:8px 12px}
  #addSongModal #addSongForm .sl-add-song-form-card,
  #addSongModal #addSongForm .sl-registration-details{padding:12px!important}
  #addSongForm .sl-add-song-section-title{padding-bottom:8px;margin-bottom:0}
  #addSongForm .sl-add-song-section-title>span{width:30px;height:30px;flex-basis:30px;font-size:16px}
  #addSongForm .sl-add-form-grid{padding-top:4px;gap:0 10px}
  #addSongForm .sl-add-field{padding:4px 0!important}
  #addSongForm .sl-add-field>label{margin-bottom:4px!important;font-size:11px!important}
  #addSongForm .sl-add-field input:not([type="checkbox"]),
  #addSongForm .sl-add-field select{
    min-height:clamp(28px,4vh,36px)!important;
    padding:5px 9px!important;
    font-size:12px!important;
  }
  #addSongForm .sl-required,#addSongForm .sl-optional{min-height:16px;padding:2px 5px}
  #newCodeUrlCheck:empty{display:none}
  #addSongForm fieldset.sl-add-field{margin:6px 0 0!important;padding:8px!important;border-radius:10px}
  #addSongForm legend{font-size:12px;line-height:1.4}
  #addSongForm .sl-genre-checks{
    grid-template-columns:repeat(auto-fit,minmax(min(100%,105px),1fr));
    gap:5px;
  }
  #addSongForm .sl-genre-checks label{
    min-height:clamp(24px,3.5vh,32px);
    padding:4px 6px;
    gap:5px!important;
    font-size:clamp(10px,1.4vh,12px)!important;
    line-height:1.3;
    border-radius:7px;
  }
  #addSongForm .sl-genre-checks input[type="checkbox"]{
    flex-basis:14px;
    width:14px!important;
    height:14px!important;
    min-height:14px!important;
  }
  #addSongForm .sl-registration-hint{font-size:11px;line-height:1.4;margin:0 0 8px}
  #addSongForm .sl-registration-group,
  #addSongForm .sl-registration-group:first-child{
    display:grid;
    grid-template-columns:76px minmax(0,1fr);
    gap:6px;
    margin:8px 0 0;
    align-items:start;
  }
  #addSongForm .sl-registration-group h4{font-size:10px;line-height:1.4;padding-left:6px;margin:5px 0 0}
  #addSongForm .sl-registration-group .sl-genre-checks{
    grid-template-columns:repeat(auto-fit,minmax(min(100%,91px),1fr));
    gap:4px;
  }
  #addSongForm>.sl-add-submit-area{padding-top:6px;display:flex;align-items:center;justify-content:space-between;gap:10px}
  #addSongFeedback{margin:0!important;min-height:0}
  #addSongForm .sl-add-submit-buttons{flex-shrink:0;margin-left:auto}
  #addSongForm .sl-add-submit-buttons button{min-height:32px!important;padding:5px 12px!important;font-size:11px!important}
}
@media(min-width:1281px) and (max-width:1600px) and (pointer:fine){
  #addSongModal #addSongForm.sl-registration-layout{grid-template-columns:minmax(0,.8fr) minmax(0,1.2fr)!important}
  #addSongForm .sl-registration-group,#addSongForm .sl-registration-group:first-child{grid-template-columns:60px minmax(0,1fr)}
  #addSongForm .sl-registration-group .sl-genre-checks{grid-template-columns:repeat(auto-fit,minmax(min(100%,100px),1fr))}
  #addSongForm #newCategoryChoices,#addSongForm #newGenre6{grid-template-columns:repeat(auto-fit,minmax(min(100%,88px),1fr))}
  #addSongForm #newCategoryChoices label,#addSongForm #newGenre6 label{font-size:10px!important;padding-inline:5px}
}
@media(min-width:1281px) and (max-height:740px) and (pointer:fine){
  html body.sl-redesign.sl-add-song-open #addSongModal.sl-add-song-page-overlay{padding-block:4px!important}
  #addSongModal #addSongForm .sl-add-song-form-card{padding:8px!important}
  #addSongForm .sl-add-song-section-title>span{width:24px;height:24px;flex-basis:24px;font-size:14px}
  #addSongForm .sl-add-song-section-title{padding-bottom:4px}
  #addSongForm .sl-add-field{padding:0!important}
  #addSongForm .sl-add-field input:not([type="checkbox"]),
  #addSongForm .sl-add-field select{min-height:24px!important;padding-block:3px!important}
  #addSongForm fieldset.sl-add-field{padding:4px!important;margin-top:4px!important}
  #addSongForm .sl-genre-checks label{font-size:10px!important;padding:3px 5px;line-height:1.2}
  #addSongForm .sl-registration-group,#addSongForm .sl-registration-group:first-child{margin-top:5px}
  #addSongForm .sl-registration-hint{font-size:10px;margin-bottom:4px}
}
/* Singer names keep a stable card size; aliases use a smaller second line. */
#addSongForm .sl-vocal-choice-text{display:block;min-width:0;line-height:1.2}
#addSongForm .sl-vocal-choice-primary{display:block;white-space:nowrap}
#addSongForm .sl-vocal-choice-text small{display:block;font-size:.75em;line-height:1.2;white-space:nowrap;color:#bacbed}
#addSongForm #newVocalChoices .sl-genre-checks label{height:52px;min-height:52px}
#addSongForm #newVocalChoices .sl-registration-group{margin:20px 0 0}
#addSongForm #newVocalChoices .sl-registration-group+.sl-registration-group{padding-top:8px;border-top:1px solid var(--sl-border-soft, #29415f)}
@media(min-width:1281px) and (pointer:fine){
  #addSongForm #newVocalChoices .sl-registration-group{grid-template-columns:82px minmax(0,1fr);margin:12px 0 0;gap:6px}
  #addSongForm #newVocalChoices .sl-registration-group:first-child{margin-top:8px}
  #addSongForm #newVocalChoices h4{white-space:nowrap;font-size:10px;padding-left:5px}
  #addSongForm #newVocalChoices .sl-genre-checks{grid-template-columns:repeat(auto-fit,minmax(min(100%,102px),1fr))}
  #addSongForm #newVocalChoices .sl-genre-checks label{height:32px;min-height:32px;padding:3px 5px;font-size:11px!important;gap:5px!important}
}
@media(min-width:1281px) and (max-width:1600px) and (pointer:fine){
  #addSongForm #newVocalChoices .sl-genre-checks{grid-template-columns:repeat(auto-fit,minmax(min(100%,96px),1fr))}
  #addSongForm #newVocalChoices .sl-genre-checks label{font-size:10px!important}
}
@media(max-width:360px){
  #addSongForm #newVocalChoices .sl-genre-checks{grid-template-columns:minmax(0,1fr)}
}
@media(min-width:1281px) and (max-height:740px) and (pointer:fine){
  #addSongForm #newVocalChoices{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
  #addSongForm #newVocalChoices .sl-registration-group,
  #addSongForm #newVocalChoices .sl-registration-group:first-child{
    display:block;margin:0;padding:0;border:0;min-width:0;
  }
  #addSongForm #newVocalChoices .sl-registration-group:last-child{grid-column:1/-1}
  #addSongForm #newVocalChoices h4{margin:0 0 5px;font-size:10px}
  #addSongForm #newVocalChoices .sl-genre-checks{grid-template-columns:repeat(auto-fit,minmax(min(100%,90px),1fr));gap:4px}
  #addSongForm #newVocalChoices .sl-genre-checks label{height:28px;min-height:28px;padding:2px 4px;font-size:10px!important;gap:4px!important}
}
@media(min-width:1281px) and (pointer:fine){
  #addSongForm #newPublisherSection>label{
    position:absolute;width:1px;height:1px;min-height:0;
    padding:0!important;margin:-1px!important;overflow:hidden;clip-path:inset(50%);white-space:nowrap;
  }
}
@media(min-width:1281px) and (max-height:740px) and (pointer:fine){
  #addSongModal .sl-add-song-heading p{display:none}
  #addSongModal #addSongForm .sl-registration-details{padding:8px!important}
  #addSongForm #newVocalChoices .sl-registration-group,
  #addSongForm #newVocalChoices .sl-registration-group:first-child{margin:0!important;padding:0!important;border:0!important}
  #addSongForm #newVocalChoices .sl-genre-checks label{height:26px;min-height:26px;padding:1px 4px;font-size:9.5px!important}
}

#addSongForm .sl-registration-detection{margin:3px 0 0!important;font-size:11px;line-height:1.4;color:#8ce3c2}
#addSongForm .sl-registration-detection[hidden]{display:none}
#addSongForm .sl-genre-checks label:has(input:disabled){cursor:default}
@media(min-width:1281px) and (pointer:fine){#addSongForm .sl-registration-detection{font-size:10px;line-height:1.3}}
