/* Retter-Portal v1.2.83 – ausschließlich Tablet-Inhaltskorrekturen.
   Desktop-, Smartphone- und sämtliche Header-Dateien bleiben unverändert. */

@media (min-width:761px) and (max-width:1180px),
       (min-width:1181px) and (max-width:1366px) and (hover:none) and (pointer:coarse){
  /* Das Einsatzformular bleibt zweispaltig, aber jedes Feld erhält exakt denselben Platz. */
  html body .app-shell .main .content .incident-form{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    gap:16px!important;
    align-items:stretch!important;
  }
  html body .app-shell .main .content .incident-form > :is(label,.smart-select-field){
    align-self:stretch!important;
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    min-height:104px!important;
    height:100%!important;
    margin:0!important;
    padding:14px!important;
    box-sizing:border-box!important;
  }
  html body .app-shell .main .content .incident-form > label,
  html body .app-shell .main .content .incident-form > .incident-command-smart-select,
  html body .app-shell .main .content .incident-form > .incident-command-smart-select > label{
    display:grid!important;
    grid-template-columns:minmax(0,1fr)!important;
    align-content:start!important;
    gap:9px!important;
  }
  html body .app-shell .main .content .incident-form > .incident-command-smart-select > label{
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    margin:0!important;
    padding:0!important;
  }
  html body .app-shell .main .content .incident-form > :is(label,.smart-select-field) :is(input,select,textarea){
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    box-sizing:border-box!important;
  }

  /* Beteiligte Löschzüge: Titel und Erklärung sauber untereinander statt gequetscht nebeneinander. */
  html body .app-shell .main .content .incident-unit-select{
    display:grid!important;
    grid-template-columns:minmax(0,1fr)!important;
    gap:14px!important;
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    padding:18px!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
  }
  html body .app-shell .main .content .incident-unit-select > .form-section{
    display:grid!important;
    grid-template-columns:minmax(0,1fr)!important;
    gap:6px!important;
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    margin:0!important;
    padding:0!important;
  }
  html body .app-shell .main .content .incident-unit-select > .form-section > strong,
  html body .app-shell .main .content .incident-unit-select > .form-section > span{
    display:block!important;
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    margin:0!important;
    text-align:left!important;
    white-space:normal!important;
    word-break:normal!important;
    overflow-wrap:break-word!important;
  }
  html body .app-shell .main .content .incident-unit-select > .form-section > strong{
    font-size:1rem!important;
    line-height:1.25!important;
  }
  html body .app-shell .main .content .incident-unit-select > .form-section > span{
    font-size:.88rem!important;
    line-height:1.45!important;
  }

  /* Einheiten selbst bleiben linksbündig und werden nicht an entgegengesetzte Ränder gedrückt. */
  html body .app-shell .main .content .incident-unit-select .unit-choice-grid{
    display:grid!important;
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    gap:12px!important;
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    margin:0!important;
  }
  html body .app-shell .main .content .incident-unit-select .unit-choice{
    display:grid!important;
    grid-template-columns:22px minmax(0,1fr)!important;
    align-items:center!important;
    justify-content:start!important;
    gap:12px!important;
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    min-height:64px!important;
    margin:0!important;
    padding:13px 14px!important;
    box-sizing:border-box!important;
    overflow:hidden!important;
  }
  html body .app-shell .main .content .incident-unit-select .unit-choice > input{
    position:static!important;
    width:18px!important;
    min-width:18px!important;
    max-width:18px!important;
    height:18px!important;
    min-height:18px!important;
    margin:0!important;
    padding:0!important;
    justify-self:start!important;
  }
  html body .app-shell .main .content .incident-unit-select .unit-choice > span{
    display:grid!important;
    grid-template-columns:minmax(0,1fr)!important;
    gap:3px!important;
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    margin:0!important;
    text-align:left!important;
    overflow:hidden!important;
  }
  html body .app-shell .main .content .incident-unit-select .unit-choice :is(strong,small){
    display:block!important;
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    margin:0!important;
    text-align:left!important;
    white-space:nowrap!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
    word-break:normal!important;
    overflow-wrap:normal!important;
  }

  /* Vollbreitenfelder folgen sauber unter dem Raster. */
  html body .app-shell .main .content .incident-form > :is(.full,section.full,.form-subcard.full){
    grid-column:1 / -1!important;
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
  }
}

@media (min-width:761px) and (max-width:930px){
  html body .app-shell .main .content .incident-form{
    grid-template-columns:minmax(0,1fr)!important;
  }
  html body .app-shell .main .content .incident-form > :is(label,.smart-select-field,.full,section.full,.form-subcard.full){
    grid-column:1!important;
  }
  html body .app-shell .main .content .incident-unit-select .unit-choice-grid{
    grid-template-columns:minmax(0,1fr)!important;
  }
}
