/* =========================================================
   VERSCHWENDUNGSRECHNER (.waste-config)
   Full Element Styling Audit - Pure Automatic CSS (ACSS)
   ========================================================= */

.brxe-waste-config {
    display: grid;
    gap: var(--content-gap);
}

header {
    display: flex;
    align-self: flex-start !important;
    align-items: flex-start;
}
.waste-config__divider {
    justify-content: flex-start;
    margin-top: -20px;
}
.waste-config__divider .line {
    border-top: 1px solid;
    border-top-width: 0.2rem;
    border-top-color: var(--tertiary);
    width: 120px;
    height: 0.2rem;
}

.waste-config [hidden] {
    display: none !important;
}

.waste-config__layout {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-m);
    align-items: flex-start;
    width: 100%;
    margin-top: var(--space-l);
}

.waste-config__main {
    flex: 1 1 0%;
    min-width: 0;
    width: 100%;
}

.waste-config__step {
    display: flex;
    flex-direction: column;
    gap: var(--space-m);
}

.waste-config__step-heading {
    display: flex;
    align-items: center;
    gap: var(--space-s);
    flex-direction: row;
    width: 100%;
}

.waste-config__step-number {
    flex: 0 0 40px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--primary);
    color: var(--white);
    font-size: var(--text-m);
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.waste-config__step-heading p {
    margin: 0;
}

.waste-config__types {
    display: grid;
    grid-template-columns: var(--grid-3);
    gap: var(--space-m);
    width: 100%;
}

.waste-config__type {
    appearance: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-xs);
    padding: var(--space-m);
    text-align: center;
    background: var(--secondary-ultra-light);
    border: 2px solid transparent;
    border-radius: var(--radius-m);
    box-shadow: none;
    cursor: pointer;
    height: 100%;
    transition:
        transform 0.2s ease,
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        background-color 0.2s ease;

    background-color: var(--bg-ultra-light);
    border-radius: var(--radius-m);
    box-shadow: 0 0 12px -5px var(--neutral-semi-light);
}

.waste-config__type:hover {
    transform: translateY(-2px);
    border-color: var(--primary);
    box-shadow: var(--shadow-m);
}

.waste-config__type:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

/* Titel + Trennlinie */
.waste-config__type strong {
    display: block;
    width: 100%;
    padding-bottom: var(--space-xs);
    font-weight: 700;
    border-bottom: 1px solid currentColor;
}

.waste-config__type.is-active strong {
    color: var(--primary);
}

/* Beschreibung */
.waste-config__type-text {
    font-size: var(--text-s);
    margin: 0;
}
/* ---------------------------------------------------------
   Schritt 2: Karte & Felder
   --------------------------------------------------------- */
.waste-config__card {
    display: flex;
    flex-direction: column;
    gap: var(--space-m);
    width: 100%;
    border-radius: var(--radius);
    box-shadow: var(--box-shadow-1);
    background-color: var(--bg-ultra-light);
    border-radius: var(--radius-m);
    box-shadow: 0 0 12px -5px var(--neutral-semi-light);
    padding-top: var(--space-xl);
    padding-right: var(--space-l);
    padding-left: var(--space-l);
    padding-bottom: var(--space-xxl);
    width: 100%;
}

.waste-config__fields {
    display: flex;
    flex-direction: column;
    gap: var(--space-m);
    width: 100%;
}

.waste-config__field {
    display: flex;
    flex-direction: column;
    gap: var(--space-xs);
    width: 100%;
}

.waste-config__label {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: var(--space-s);
    color: var(--text-dark);
}

.waste-config__label-text {
    display: inline-flex;
    align-items: center;
    gap: var(--space-xs);
}

.waste-config__info-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    width: 1.25em;
    height: 1.25em;
    border-radius: 50%;
    background: var(--primary);
    color: var(--white);
    line-height: 1;
    cursor: help;
}

.waste-config__value-wrapper {
    display: inline-flex;
    align-items: center;
    gap: var(--space-xs);
}

.waste-config__value {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: calc(var(--space-xs) / 2) var(--space-xs);
    border-radius: var(--radius);
    background: var(--primary-ultra-light);
    color: var(--primary-dark);
}

.waste-config__number,
.waste-config__text-input {
    font: inherit;
    color: var(--text-dark);
    background: var(--secondary-ultra-light);
    border: var(--border-size) var(--border-style) transparent;
    border-radius: var(--radius);
    outline: none;
    transition:
        border-color 0.2s ease,
        background-color 0.2s ease;
}

.waste-config__text-input {
    width: 100%;
    padding: var(--space-xs) var(--space-s);
}

.waste-config__number {
    width: 4.5em;
    padding: calc(var(--space-xs) / 2) var(--space-xs);
    text-align: right;
}

.waste-config__number:focus,
.waste-config__text-input:focus {
    background: var(--white);
    border-color: var(--primary);
}

.waste-config__unit {
    color: var(--text-dark-muted);
}

/* Range Slider */
.waste-config input[type='range'] {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 8px;
    margin: calc(var(--space-xs) / 2) 0;
    border-radius: 999px;
    cursor: pointer;
    background: linear-gradient(
        to right,
        var(--primary) var(--fill, 0%),
        var(--neutral-light) var(--fill, 0%)
    );
}

.waste-config input[type='range']:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 4px;
}

.waste-config input[type='range']::-webkit-slider-runnable-track {
    height: 8px;
    background: transparent;
}

.waste-config input[type='range']::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 22px;
    height: 22px;
    margin-top: -7px;
    border: 3px solid var(--white);
    border-radius: 50%;
    background: var(--primary);
    box-shadow: var(--box-shadow-1);
    transition: transform 0.15s ease;
}

.waste-config input[type='range']::-webkit-slider-thumb:hover {
    transform: scale(1.15);
}

.waste-config input[type='range']::-moz-range-track {
    height: 8px;
    background: transparent;
}

.waste-config input[type='range']::-moz-range-thumb {
    width: 22px;
    height: 22px;
    border: 3px solid var(--white);
    border-radius: 50%;
    background: var(--primary);
    box-shadow: var(--box-shadow-1);
}

/* ---------------------------------------------------------
   Live-Vorschau
   --------------------------------------------------------- */
.waste-config__preview {
    /*display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-xs);
    width: 100%;
    padding: var(--space-m);
    text-align: center;
    background: var(--secondary-ultra-dark);
    color: var(--text-light);
    border-radius: var(--radius); */
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-xs);
    width: 100%;
    padding: var(--space-m);
    text-align: center;
    /* background: var(--secondary-ultra-dark); */
    /* color: var(--text-light); */
    /* border-radius: var(--radius); */
    display: flex;
    flex-direction: column;
    gap: var(--space-m);
    width: 100%;
    border-radius: var(--radius);
    box-shadow: var(--box-shadow-1);
    background-color: var(--bg-ultra-light);
    border-radius: var(--radius-m);
    box-shadow: 0 0 12px -5px var(--neutral-semi-light);
    /* padding-top: var(--space-xl); */
    padding-right: var(--space-l);
    /* padding-left: var(--space-l); */
    /* padding-bottom: var(--space-xxl); */
    width: 100%;
}
.waste-config__total-cost,
.waste-config__preview strong {
    font-size: var(--h3);
    line-height: var(--h3-line-height);
}

.waste-config__preview-label {
    text-transform: uppercase;
}

.waste-config__preview-meta {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: var(--space-xs) var(--space-m);
}

/* ---------------------------------------------------------
   Aktionen (Buttons kommen aus ACSS: .btn .btn--primary etc.)
   --------------------------------------------------------- */
.waste-config__actions {
    display: flex;
    flex-flow: row wrap;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-s);
}

.waste-config__actions--center {
    justify-content: center;
}

.waste-config__btn--dashed {
    background-color: rgba(0, 0, 0, 0) !important;
    color: var(--tertiary) !important;
}

/* ---------------------------------------------------------
   Schritt 3: Ergebnisliste
   --------------------------------------------------------- */
.waste-config__list {
    display: grid;
    grid-template-columns: var(--grid-3);
    gap: var(--space-s);
    margin: 0 !important;
    padding: 0 !important;
    list-style: none !important;
        width: 100%;
}

.waste-config__item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-s);
    padding: var(--space-s) var(--space-m);
    background: var(--secondary-ultra-light);
    border-radius: var(--radius);
    background-color: var(--bg-ultra-light);
    border-radius: var(--radius-m);
    box-shadow: 0 0 12px -5px var(--neutral-semi-light);
    width: 100%;
}

.waste-config__item-content {
    display: flex;
    flex-direction: column;
    gap: calc(var(--space-xs) / 2);
}

.waste-config__item-content span {
    color: var(--text-dark-muted);
}

.waste-config__item-remove,
.waste-config__sidebar-remove {
    appearance: none;
    flex: 0 0 auto;
    font: inherit;
    background: var(--secondary-ultra-light);
    border-radius: var(--radius-circle);
    cursor: pointer;
    transition:
        background-color 0.2s ease,
        color 0.2s ease;
}

.waste-config__item-remove,
.waste-config__sidebar-remove {
    padding: 0 calc(var(--space-xs) / 2);
}

.waste-config__item-remove:hover,
.waste-config__sidebar-remove:hover {
    background: var(--danger);
    color: var(--white);
}

/* Gesamtergebnis */
.waste-config__total {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: var(--space-m);
    width: 100%;
    border-radius: var(--radius);
    box-shadow: var(--box-shadow-1);
    background-color: var(--bg-ultra-light);
    border-radius: var(--radius-m);
    box-shadow: 0 0 12px -5px var(--neutral-semi-light);
    padding: var(--space-l) var(--space-m);
    width: 100%;
}

.waste-config__total-label {
    text-transform: uppercase;
}

.waste-config__total-stats {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: var(--space-m) var(--space-l);
    width: 100%;
    padding-top: var(--space-s);
    border-top: var(--border-size) var(--border-style)
        color-mix(in oklch, var(--white) 25%, transparent);
}

.waste-config__total-stats div {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.waste-config__total-stats span {
    margin-top: calc(var(--space-xs) / 2);
}

.waste-config__total-text {
    max-width: 55ch;
    margin: 0;
    font-size: var(--text-s);
    text-align: center;
}

.waste-config__disclaimer {
    max-width: 60ch;
    margin: var(--space-s) auto 0;
    text-align: center;
    color: var(--text-dark-muted);
}

.waste-config__cta {
    margin-top: var(--space-s);
    text-align: center;
}

.waste-config__cta-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}

/* ---------------------------------------------------------
   Akkordeon (Rahmendaten)
   --------------------------------------------------------- */
.waste-config__accordion-wrap {
    margin-top: var(--space-m);
}

.waste-config__accordion {
    overflow: hidden;
    border-radius: var(--radius);
    display: flex;
    flex-direction: column;
    width: 100%;
    border-radius: var(--radius);
    box-shadow: var(--box-shadow-1);
    background-color: var(--bg-ultra-light);
    border-radius: var(--radius-m);
    box-shadow: 0 0 12px -5px var(--neutral-semi-light);
    width: 100%;
}

.waste-config__accordion-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-s) var(--space-m);
    color: var(--text-dark);
    cursor: pointer;
    user-select: none;
    transition:
        background-color 0.2s ease,
        color 0.2s ease;
}

.waste-config__accordion-summary:hover {
    background: var(--secondary-ultra-light);
}

.waste-config__accordion-arrow {
    transition: transform 0.2s ease;
}

.waste-config__accordion[open] .waste-config__accordion-arrow {
    transform: rotate(180deg);
}

.waste-config__accordion-card {
    margin: 0;
    padding: var(--space-m);
    border: 0;
    border-top: var(--border-size) var(--border-style) var(--black);
    border-radius: 0;
    box-shadow: none;
}

/* ---------------------------------------------------------
   Sidebar
   --------------------------------------------------------- */
.waste-config__sidebar {
    flex: 0 0 300px;
    position: sticky;
    top: calc(var(--space-l) + var(--header-height));
    padding: var(--space-m);
    display: flex;
    flex-direction: column;
    gap: var(--space-m);
    width: 100%;
    border-radius: var(--radius);
    box-shadow: var(--box-shadow-1);
    background-color: var(--bg-ultra-light);
    border-radius: var(--radius-m);
    box-shadow: 0 0 12px -5px var(--neutral-semi-light);
}

.waste-config__sidebar-title {
    margin: 0 0 var(--space-s);
}

.waste-config__sidebar-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.waste-config__sidebar-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-xs);
    padding: var(--space-xs) 0;
    border-bottom: var(--border-size) var(--border-style) var(--secondary);
}

.waste-config__sidebar-info strong {
    display: block;
}

.waste-config__sidebar-footer-label {
    text-transform: uppercase;
}

.waste-config__sidebar-footer {
    color: var(--text-dark-muted);
    font-size: var(--text-s);
}

.waste-config__sidebar-total {
    color: var(--primary);
    font-size: var(--h4);
    font-weight: 700;
}

.editbasic {
    color: var(--primary);
}

/* ---------------------------------------------------------
   Responsive & Reduced Motion
   --------------------------------------------------------- */
@media screen and (max-width: 990px) {
    .waste-config__types,
    .waste-config__list {
        grid-template-columns: var(--grid-2);
    }
    .waste-config__layout {
        flex-direction: column;
    }

    .waste-config__sidebar {
        flex: 1 1 auto;
        width: 100%;
        position: static;
    }
}

@media screen and (max-width: 768px) {
    .waste-config__types,
    .waste-config__list {
        grid-template-columns: 1fr;
        width: 100%;
    }
}

@media screen and (max-width: 478px) {
    .waste-config__types,
    .waste-config__list {
        grid-template-columns: 1fr;
    }
}

@media (prefers-reduced-motion: reduce) {
    .waste-config *,
    .waste-config *::before,
    .waste-config *::after {
        animation: none !important;
        transition: none !important;
    }
}
