/* Defenda Produkt-Selector Premium v1.4 */

.defenda-selector-premium {
    --defenda-red: #992222;
    --defenda-red-dark: #7f1c1c;
    --defenda-black: #111111;
    --defenda-card: #ffffff;
    --defenda-border: #e7e7ea;
    --defenda-muted: #666b75;
    --defenda-shadow: 0 24px 60px rgba(17, 17, 17, 0.08);
    --defenda-radius: 24px;
    color: var(--defenda-black);
    font-family: inherit;
}

.defenda-selector-premium * { box-sizing: border-box; }

.defenda-hero,
.defenda-family-section,
.defenda-options-panel,
.defenda-preview-shell,
.defenda-summary-sticky {
    background: var(--defenda-card);
    border: 1px solid var(--defenda-border);
    border-radius: var(--defenda-radius);
    box-shadow: var(--defenda-shadow);
}

.defenda-hero {
    padding: 34px;
    margin-bottom: 24px;
    background:
        radial-gradient(circle at 15% 20%, rgba(153, 34, 34, 0.10), transparent 30%),
        radial-gradient(circle at 85% 10%, rgba(153, 34, 34, 0.08), transparent 24%),
        linear-gradient(135deg, #ffffff 0%, #faf6f6 100%);
}

.defenda-eyebrow {
    margin: 0 0 10px;
    color: var(--defenda-red);
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .09em;
    font-size: 12px;
}

.defenda-selector-premium h2,
.defenda-selector-premium h3 {
    margin: 0 0 12px;
    line-height: 1.2;
}

.defenda-selector-premium h2 { font-size: 34px; }
.defenda-selector-premium h3 { font-size: 23px; }

.defenda-muted {
    color: var(--defenda-muted);
    margin: 0;
    line-height: 1.6;
}

.defenda-hero-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 22px;
}

.defenda-hero-badges span {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 10px 14px;
    background: rgba(153, 34, 34, 0.08);
    color: var(--defenda-red);
    font-weight: 700;
    font-size: 14px;
}

.defenda-family-section { padding: 26px; margin-bottom: 24px; }
.defenda-section-head { margin-bottom: 18px; }

.defenda-family-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
}

.defenda-family-card {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    border: 1px solid var(--defenda-border);
    background: #fbfbfc;
    border-radius: 20px;
    padding: 16px;
    cursor: pointer;
    transition: .22s ease;
}

.defenda-family-card:hover {
    transform: translateY(-2px);
    border-color: rgba(153, 34, 34, 0.35);
}

.defenda-family-card input { display: none; }

.defenda-family-card.is-active {
    border-color: var(--defenda-red);
    background: linear-gradient(180deg, rgba(153, 34, 34, 0.09), rgba(153, 34, 34, 0.03));
    box-shadow: inset 0 0 0 1px rgba(153, 34, 34, 0.15);
}

.defenda-family-icon {
    width: 48px;
    height: 48px;
    flex: 0 0 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 16px;
    background: linear-gradient(180deg, var(--defenda-red), var(--defenda-red-dark));
    color: #ffffff;
    font-weight: 800;
    letter-spacing: .04em;
    font-size: 14px;
}

.defenda-family-content strong {
    display: block;
    font-size: 16px;
    margin-bottom: 6px;
}

.defenda-family-content small {
    display: block;
    color: var(--defenda-muted);
    line-height: 1.45;
}

.defenda-layout {
    display: grid;
    grid-template-columns: 1.1fr 1.25fr 0.95fr;
    gap: 24px;
    align-items: start;
}

.defenda-options-panel,
.defenda-summary-sticky { padding: 24px; }

.defenda-preview-shell {
    padding: 24px;
    min-height: 760px;
    background:
        radial-gradient(circle at center, rgba(153, 34, 34, 0.08), transparent 40%),
        linear-gradient(180deg, #ffffff 0%, #fafafa 100%);
}

.defenda-preview-head { margin-bottom: 14px; }

.defenda-image-stage {
    position: relative;
    width: min(100%, 760px);
    aspect-ratio: 1 / 1;
    margin: 0 auto;
}

.defenda-layer {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    opacity: 0;
    transform: scale(.985);
    transition: opacity .25s ease, transform .25s ease;
    pointer-events: none;
}

.defenda-layer.is-visible {
    opacity: 1;
    transform: scale(1);
}

.defenda-options-list {
    display: grid;
    gap: 12px;
}

.defenda-option-card {
    display: none;
    border: 1px solid var(--defenda-border);
    border-radius: 18px;
    background: #fcfcfc;
    padding: 14px;
    transition: .2s ease;
}

.defenda-option-card.is-active-family { display: block; }
.defenda-option-card:hover {
    border-color: rgba(153, 34, 34, 0.35);
    transform: translateY(-1px);
}

.defenda-option-card.is-checked {
    border-color: var(--defenda-red);
    background: rgba(153, 34, 34, 0.05);
}

.defenda-option-top {
    display: flex;
    gap: 12px;
    align-items: center;
}

.defenda-option-check {
    position: relative;
    width: 26px;
    height: 26px;
    flex: 0 0 26px;
}

.defenda-option-check input {
    position: absolute;
    opacity: 0;
    inset: 0;
    cursor: pointer;
}

.defenda-check-ui {
    display: block;
    width: 26px;
    height: 26px;
    border: 1px solid #c7c9cf;
    border-radius: 8px;
    background: #ffffff;
    position: relative;
}

.defenda-option-card.is-checked .defenda-check-ui {
    border-color: var(--defenda-red);
    background: var(--defenda-red);
}

.defenda-option-card.is-checked .defenda-check-ui::after {
    content: "";
    position: absolute;
    left: 8px;
    top: 4px;
    width: 7px;
    height: 12px;
    border-right: 2px solid #fff;
    border-bottom: 2px solid #fff;
    transform: rotate(45deg);
}

.defenda-option-text strong {
    display: block;
    line-height: 1.25;
    margin-bottom: 3px;
    font-size: 15px;
}

.defenda-option-text small {
    color: var(--defenda-muted);
    display: block;
    font-size: 13px;
}

.defenda-option-extra-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px dashed #d6d8dd;
    opacity: .45;
}

.defenda-option-extra-grid.has-mp {
    grid-template-columns: 1fr 1fr;
}

.defenda-option-card.is-checked .defenda-option-extra-grid { opacity: 1; }

.defenda-option-field span {
    display: block;
    margin-bottom: 6px;
    font-size: 13px;
    color: var(--defenda-muted);
    font-weight: 700;
}

.defenda-qty-input,
.defenda-mp-select {
    width: 100%;
    border: 1px solid var(--defenda-border);
    border-radius: 12px;
    padding: 10px 12px;
    font: inherit;
    background: #ffffff;
}

.defenda-summary-sticky {
    position: sticky;
    top: 20px;
}

.defenda-selected-group {
    border: 1px solid var(--defenda-border);
    border-radius: 18px;
    background: #fbfbfc;
    padding: 16px;
    margin-bottom: 20px;
}

.defenda-selected-family-label {
    display: block;
    color: var(--defenda-red);
    margin-bottom: 10px;
    font-weight: 800;
}

.defenda-selected-list {
    margin: 0;
    padding-left: 18px;
    min-height: 140px;
}

.defenda-selected-list li {
    margin-bottom: 8px;
    line-height: 1.45;
}

.defenda-note-box {
    margin-bottom: 22px;
    border-radius: 20px;
    background: linear-gradient(180deg, #1c1c1f, #111111);
    color: #ffffff;
    padding: 18px;
}

.defenda-note-box p {
    margin: 8px 0 0;
    color: rgba(255,255,255,.82);
    line-height: 1.5;
}

.defenda-contact label {
    display: block;
    margin-bottom: 12px;
    font-weight: 700;
}

.defenda-contact input[type="text"],
.defenda-contact input[type="email"],
.defenda-contact textarea {
    display: block;
    width: 100%;
    margin-top: 6px;
    padding: 12px 14px;
    border-radius: 14px;
    border: 1px solid var(--defenda-border);
    background: #ffffff;
    font: inherit;
}

.defenda-contact textarea { resize: vertical; }

.defenda-contact input:focus,
.defenda-contact textarea:focus,
.defenda-qty-input:focus,
.defenda-mp-select:focus {
    outline: none;
    border-color: var(--defenda-red);
    box-shadow: 0 0 0 3px rgba(153, 34, 34, 0.12);
}

.defenda-privacy {
    display: flex !important;
    gap: 10px;
    align-items: flex-start;
    font-weight: 400 !important;
    line-height: 1.5;
}

.defenda-privacy input {
    margin-top: 4px;
    accent-color: var(--defenda-red);
}

.defenda-button {
    width: 100%;
    border: none;
    border-radius: 16px;
    background: linear-gradient(180deg, var(--defenda-red), var(--defenda-red-dark));
    color: #ffffff;
    padding: 15px 20px;
    font-size: 16px;
    font-weight: 800;
    cursor: pointer;
    transition: .2s ease;
}

.defenda-button:hover {
    transform: translateY(-1px);
    filter: brightness(.96);
}

.defenda-alert {
    padding: 14px 18px;
    border-radius: 14px;
    margin-bottom: 18px;
    font-weight: 700;
}

.defenda-alert-success { background: #e9f7ef; color: #146c43; }
.defenda-alert-error { background: #fdecec; color: #992222; }

@media (max-width: 1500px) {
    .defenda-family-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 1220px) {
    .defenda-layout { grid-template-columns: 1fr; }
    .defenda-preview-shell { min-height: 520px; order: -1; }
    .defenda-summary-sticky { position: static; }
}

@media (max-width: 820px) {
    .defenda-family-grid { grid-template-columns: repeat(2, 1fr); }
    .defenda-selector-premium h2 { font-size: 28px; }
    .defenda-selector-premium h3 { font-size: 21px; }
    .defenda-hero,
    .defenda-family-section,
    .defenda-options-panel,
    .defenda-preview-shell,
    .defenda-summary-sticky { padding: 20px; }
    .defenda-option-extra-grid.has-mp { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
    .defenda-family-grid { grid-template-columns: 1fr; }
    .defenda-preview-shell { min-height: 400px; }
    .defenda-hero-badges { gap: 8px; }
    .defenda-hero-badges span { font-size: 12px; padding: 8px 12px; }
}




/* v1.6 Automatischer Anfragekorb */
.defenda-family-card {
    position: relative;
}

.defenda-family-icon {
    width: 48px;
    height: 48px;
    flex: 0 0 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 16px;
    background: linear-gradient(180deg, var(--defenda-red), var(--defenda-red-dark));
    color: #ffffff;
}

.defenda-family-icon svg {
    width: 24px;
    height: 24px;
    display: block;
}

.defenda-family-card.is-configured::after {
    content: "im Anfragekorb";
    position: absolute;
    right: 12px;
    top: 12px;
    font-size: 11px;
    line-height: 1;
    font-weight: 800;
    color: #ffffff;
    background: var(--defenda-red);
    padding: 6px 8px;
    border-radius: 999px;
}

.defenda-family-card.is-configured {
    border-color: rgba(153, 34, 34, 0.55);
}

.defenda-summary-family-item {
    margin-bottom: 14px !important;
}

.defenda-summary-family-item > strong {
    display: block;
    color: var(--defenda-red);
    margin-bottom: 6px;
}

.defenda-summary-family-item ul {
    margin-top: 6px;
    padding-left: 18px;
}

.defenda-summary-family-item li {
    margin-bottom: 6px;
}


/* v1.7 Textbereinigung */
.defenda-hero-copy .defenda-muted {
    max-width: 760px;
}
