/**
 * Das ist alles gescoped in die Klasse `styled-form`.
 *
 * Bitte um die <form> ein <div class="styled-form"> legen.
 */


/**
 * Forms-Framework: Headline
 * =======================================
 */

.styled-form form > h2 {
    /*text-decoration: underline;
    margin-bottom: 2rem;*/
}


/**
 * Forms-Framework: Äußere Container
 * =======================================
 * form {
 *    h2 {}
 *    form-group... {
 *        .control-label {}
 *        inputs... {}
 *    }
 *    input[autocomplete] { random-position! }
 *    form-group... {
 *        .control-label {}
 *        inputs... {}
 *    }
 * }
 */

.styled-form .form-group {
    margin-bottom: 0;
}

.styled-form .form-group + .form-group,
.styled-form input + .form-group {
    margin-top: 1.5rem;
}

.styled-form .form-group + input { /* <input autocomplete="..." ...> */
    display: none!important;
}

.styled-form .actions {
    margin-top: 1.5rem;
}

.styled-form .control-label {
    font-weight: 600;
}

.styled-form .btn.btn-cancel {
    color: #fff;
    background-color: #dc3545;
    border: 1px solid #dc3545;
    border-radius: 0.25rem;
    transition: color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out;
}

.styled-form .btn-group.previous .btn {
    border-top-left-radius: 0.25rem!important;
    border-bottom-left-radius: 0.25rem!important;
}

/**
 * Forms-Framework: Errors
 * =======================================
 */

.styled-form span.error,
.styled-form span.INFO,
.styled-form span.error::before,
.styled-form span.INFO::before{
    font-size: smaller;
}
.styled-form span.error {
    color: #721c24;
    background-color: #f8d7da;
    padding: .75rem 1.25rem;
    margin-top: 0.5rem;
    border: 1px solid #f5c6cb;
    border-radius: .25rem;
    display: block;
}

.styled-form span.INFO {
    color: #fa8c00;
    background-color: #f8e6bd;
    padding: .75rem 1.25rem;
    margin-top: 0.5rem;
    margin-bottom: 0.5rem;
    border: 1px solid #fa8c00;
    border-radius: .25rem;
    display: block;
}


.styled-form span.error::before,
.styled-form span.INFO::before {
    background: url(bootstrap-icons-1.0.0/exclamation-triangle.svg);
    display: inline-block;
    content: " ";
    height: 1rem;
    width: 1rem;
    background-repeat: no-repeat;
    background-size: contain;
    vertical-align: sub;
    margin-right: 0.5rem;
}



/**
 * Forms-Framework: Checkboxen
 * =======================================
 */

.styled-form .form-check {
    padding-left: 0;
}

.styled-form .form-check-label {
    position: relative;
    padding-left: 1.5rem;
}

.styled-form .form-check-label input[type=checkbox] {
    width: 1px;
    height: 1px;
    opacity: 0;
    position: absolute;
    z-index: -1;
    left: 0.5rem;
    bottom: 0.5rem;
}

.styled-form .form-check-label input[type=checkbox] + span::before { /* defaults */
    display: inline-block;
    content: " ";
    height: 1rem;
    width: 1rem;
    vertical-align: baseline;
    margin-right: 0.5rem;
    margin-left: -1.5rem;
}

.styled-form .form-check-label input[type=checkbox] + span::before { /* unchecked */
    background: url(bootstrap-icons-1.0.0/square.svg);
    background-repeat: no-repeat;
    background-size: contain;
}

.styled-form .form-check-label input[type=checkbox]:checked + span::before { /* checked */
    background: url(bootstrap-icons-1.0.0/check-square-fill.svg);
    background-repeat: no-repeat;
    background-size: contain;
}


/**
 * Forms-Framework: Radios
 * =======================================
 */

.styled-form .form-check-input {
    margin-left: 0;
    position: relative;
}

.styled-form .radio > label {
    margin-bottom: 0;
    position: relative;
    padding-left: 1.5rem;
}

.styled-form .radio input {
    width: 1px;
    height: 1px;
    opacity: 0;
    position: absolute;
    z-index: -1;
    left: 0.5rem;
    bottom: 0.5rem;
}

.styled-form .radio input + span::before { /* defaults */
    display: inline-block;
    content: " ";
    height: 1rem;
    width: 1rem;
    vertical-align: baseline;
    margin-right: 0.5rem;
    margin-left: -1.5rem;
}

.styled-form .radio input + span::before { /* unchecked */
    background: url(bootstrap-icons-1.0.0/circle.svg);
    background-repeat: no-repeat;
    background-size: contain;
}

.styled-form .radio input:checked + span::before { /* checked */
    background: url(bootstrap-icons-1.0.0/check-circle-fill.svg);
    background-repeat: no-repeat;
    background-size: contain;
}


/**
 * Forms-Framework: Confirm-Steps
 * =======================================
 */

.styled-form form > fieldset > legend {
    text-decoration: underline;
    margin-bottom: 2rem;
}

.styled-form .form-group .table-responsive {
    border: 1px solid rgba(0, 0, 0, 0.2);
}

.styled-form .form-group .table {
    margin-bottom: 0
}

.styled-form .form-group .table th,
.styled-form .form-group .table td {
    padding: 0.2rem 0.5rem;
}

.styled-form .form-group .table-responsive tbody tr:nth-of-type(odd) {
    background-color: rgba(0, 0, 0, 0.05);
}

.styled-form .form-group .table-responsive td > img {
    max-width: 100%;
    height: auto;
}
