/*
 * product-detail.css
 * Locatie: app/design/frontend/<vendor>/<theme>/web/css/product-detail.css
 */

/* ---------------------------------------
   PRODUCT ATTRIBUTEN WRAPPER
--------------------------------------- */

.product-attributes {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin: 10px 0;
}

.product-attributes-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: flex-start;
    min-height: 40px;
}

/* ---------------------------------------
   ATTRIBUTE ITEM BASIS
--------------------------------------- */

.product-attribute-item {
    display: inline-flex;
    align-items: center;
    padding: 6px 12px;
    border: 2px solid;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    white-space: nowrap;
    letter-spacing: .3px;
    line-height: 1;
    min-height: 36px;
    box-sizing: border-box;
}

.product-attribute-item .attribute-icon {
    margin-right: 6px;
    font-size: 14px;
}

.product-attribute-item .attribute-icon i {
    font-size: 14px;
}

.product-attribute-item .attribute-value {
    font-weight: 700;
}

/* ---------------------------------------
   ENERGIELABEL KLEUREN
--------------------------------------- */

.product-attribute-item.energielabel.a { background-color: #00a753; border-color: #00a753; color: #fff; }
.product-attribute-item.energielabel.b { background-color: #97cb31; border-color: #97cb31; color: #fff; }
.product-attribute-item.energielabel.c { background-color: #fef301; border-color: #fef301; color: #333; }
.product-attribute-item.energielabel.d { background-color: #feb800; border-color: #feb800; color: #fff; }
.product-attribute-item.energielabel.e { background-color: #f2020a; border-color: #f2020a; color: #fff; }
.product-attribute-item.energielabel.f { background-color: #ec690d; border-color: #ec690d; color: #fff; }

/* ---------------------------------------
   OVERIGE ATTRIBUTE TYPES
--------------------------------------- */

.product-attribute-item.grip-op-glad-wegdek {
    background-color: #4ba6dd;
    border-color: #4ba6dd;
    color: #fff;
}

.product-attribute-item.externe-rolgeluid-auto-db {
    background-color: #1a1a2e;
    border-color: #1a1a2e;
    color: #fff;
    padding: 6px 12px;
    width: auto;
}

.product-attribute-item.voertuigtype {
    background-color: #f4f5f7;
    border-color: #e2e5ea;
    color: #21314B;
    text-transform: none;
}

.product-attribute-item.voertuigtype .attribute-icon {
    width: 16px;
    height: 16px;
    margin-right: 6px;
}

.product-attribute-item.extra-informatie {
    background-color: #f4f5f7;
    border-color: #e2e5ea;
    color: #21314B;
    text-transform: none;
    align-self: flex-start;
}

/* Fallback */
.product-attribute-item:not(.energielabel):not(.grip-op-glad-wegdek):not(.externe-rolgeluid-auto-db):not(.voertuigtype):not(.extra-informatie) {
    background-color: #f4f5f7;
    border-color: #e2e5ea;
    color: #21314B;
}

/* ---------------------------------------
   TWEEDE RIJ (voertuigtype + extra info)
--------------------------------------- */

.product-attributes-row.second-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
}

.voertuigtype-container,
.extra-info-container {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    margin-left: 0;
}

.voertuigtype-container h4,
.extra-info-container h4 {
    margin: 0 0 8px 0;
    font-size: 14px;
    font-weight: bold;
    color: #333;
    line-height: 1.2;
}

/* ---------------------------------------
   SEIZOEN BADGE (Zomerbanden / Winterbanden)
--------------------------------------- */

.product-info-main .pc-season,
.page-product-simple .pc-season,
.catalog-product-view .pc-season {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: .92rem;
    color: #3d4a5c;
    background: #f4f5f7;
    padding: 6px 14px;
    border-radius: 20px;
    font-weight: 600;
    border: 1px solid #e2e5ea;
    margin: 4px 0;
}

.product-info-main .pc-season i,
.catalog-product-view .pc-season i {
    color: #EF5B33;
}

.product-info-main .swatch-attribute-label,
.product-info-main .seizoen-badge {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: .92rem;
    background: #f4f5f7;
    color: #3d4a5c;
    padding: 6px 14px;
    border-radius: 20px;
    font-weight: 600;
    border: 1px solid #e2e5ea;
}

/* ---------------------------------------
   QTY SELECT — compact naast de knop
--------------------------------------- */

.box-tocart .field.qty .label { display: none; }

.box-tocart .field.qty .control {
    height: 100%;
}

.box-tocart .input-text.qty,
.box-tocart select.qty {
    appearance: none;
    -webkit-appearance: none;
    background-color: #fff;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%2321314B'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 10px 6px;
    border: 1.5px solid #e2e5ea;
    border-radius: 7px;
    color: #1a2233;
    font-family: inherit;
    font-size: .9rem;
    padding: 0 30px 0 12px;
    cursor: pointer;
    transition: border-color .2s;
    /* FIXED: auto breedte zodat de select compact blijft */
    width: auto;
    min-width: 100px;
    max-width: 140px;
    height: 48px;
    box-sizing: border-box;
}

.box-tocart .input-text.qty:focus,
.box-tocart select.qty:focus {
    outline: none;
    border-color: #21314B;
    box-shadow: 0 0 0 3px rgba(33,49,75,.09);
}

/* ---------------------------------------
   ADD TO CART — DESKTOP naast elkaar
--------------------------------------- */

.box-tocart {
    width: 100%;
    max-width: 480px;
}

.box-tocart .fieldset {
    display: flex;
    flex-direction: row;
    align-items: stretch;
    gap: 10px;
    width: 100%;
}

.box-tocart .field.qty {
    /* FIXED: niet meer vaste breedte, maar auto zodat select de maat bepaalt */
    flex: 0 0 auto;
    margin: 0;
}

.box-tocart .actions {
    flex: 1;
    min-width: 0;
}

.box-tocart .action.tocart {
    width: 100%;
    height: 48px;
    box-sizing: border-box;
    white-space: nowrap;
    padding-left: 16px;
    padding-right: 16px;
}

/* ---------------------------------------
   ADD TO CART — MOBIEL onder elkaar
--------------------------------------- */

@media (max-width: 768px) {
    .box-tocart { max-width: 100%; }

    .box-tocart .fieldset {
        flex-direction: column;
        gap: 10px;
    }

    .box-tocart .field.qty {
        flex: none;
        width: 100%;
    }

    /* Op mobiel wél full-width */
    .box-tocart .input-text.qty,
    .box-tocart select.qty {
        width: 100%;
        max-width: 100%;
    }

    .box-tocart .actions { width: 100%; }

    .box-tocart .action.tocart {
        width: 100%;
        height: 48px;
    }
}

/* ---------------------------------------
   USP BLOK
--------------------------------------- */

.product-usp-block {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    margin-top: 28px;
    padding: 20px;
    background: #f4f5f7;
    border-radius: 12px;
    border: 1px solid #e2e5ea;
}

.product-usp-block > div {
    flex: 1 1 200px;
    display: flex;
    gap: 12px;
    align-items: flex-start;
    font-size: .93rem;
    line-height: 1.5;
    color: #3d4a5c;
}

.product-usp-block > div i {
    font-size: 20px;
    color: #EF5B33;
    flex-shrink: 0;
    margin-top: 2px;
}

.product-usp-block > div strong {
    display: block;
    color: #21314B;
    font-weight: 700;
    margin-bottom: 2px;
}