/* ==========================================================================
   Parkland Bundler — configurator + Buy X
   ========================================================================== */

.pk-bundler-section {
    background: #f9fafb;
    padding: 40px 0;
}

.pk-bundler-section .pk-section-header h2 {
    margin: 0 0 20px;
}

/* ── Preset selector ── */

.pk-bundler-presets {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 24px;
}

.pk-bundler-preset {
    padding: 10px 20px;
    border: 2px solid #d5dbd7;
    background: #fff;
    border-radius: 6px;
    font-weight: 600;
    color: #1f2a24;
    cursor: pointer;
    transition: border-color .2s, background .2s, transform .15s;
}

.pk-bundler-preset:hover {
    border-color: #58af3d;
}

.pk-bundler-preset.is-active {
    background: #58af3d;
    border-color: #58af3d;
    color: #fff;
}

/* ── Detail layout ── */

.pk-bundler-detail {
    display: grid;
    grid-template-columns: 1.4fr 1fr;
    gap: 28px;
    align-items: start;
}

.pk-bundler-subtitle {
    margin: 0 0 12px;
    font-size: 1.05em;
}

.pk-bundler-items {
    list-style: none;
    margin: 0;
    padding: 0;
    border: 1px solid #e5e9e6;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
}

.pk-bundler-item {
    display: grid;
    grid-template-columns: auto 1fr auto auto;
    gap: 12px;
    align-items: center;
    padding: 12px 16px;
    border-bottom: 1px solid #eef1ef;
}

.pk-bundler-item:last-child {
    border-bottom: none;
}

.pk-bundler-item-qty {
    font-weight: 700;
    color: #58af3d;
}

.pk-bundler-item-name {
    font-weight: 500;
    color: #1f2a24;
}

.pk-bundler-item-sku {
    font-size: .8em;
    color: #8a938d;
    font-variant-numeric: tabular-nums;
}

.pk-bundler-item-price {
    font-weight: 600;
    white-space: nowrap;
}

/* ── Summary / totals ── */

.pk-bundler-summary {
    background: #fff;
    border: 1px solid #e5e9e6;
    border-radius: 8px;
    padding: 20px;
    position: sticky;
    top: 20px;
}

.pk-bundler-totals {
    width: 100%;
    border-collapse: collapse;
    margin: 0 0 18px;
}

.pk-bundler-totals th,
.pk-bundler-totals td {
    padding: 8px 0;
    text-align: left;
}

.pk-bundler-totals td {
    text-align: right;
    font-variant-numeric: tabular-nums;
}

.pk-bundler-retail td {
    color: #8a938d;
    text-decoration: line-through;
}

.pk-bundler-special th,
.pk-bundler-special td {
    font-size: 1.3em;
    font-weight: 700;
    color: #1f2a24;
    border-top: 1px solid #eef1ef;
    padding-top: 12px;
}

.pk-bundler-saving th,
.pk-bundler-saving td {
    color: #58af3d;
    font-weight: 700;
}

/* ── CTA ── */

.pk-bundler-cta {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.pk-bundler-cta .button {
    width: 100%;
    text-align: center;
}

.pk-bundler-msg {
    margin: 4px 0 0;
    font-size: .85em;
    color: #666;
    min-height: 1.2em;
}

.pk-bundler-item-included {
    font-size: .85em;
    font-weight: 600;
    color: #58af3d;
    text-transform: uppercase;
    letter-spacing: .3px;
}

/* ── Reveal mode: hide special + saving until the button is clicked ── */

.pk-bundler-mode-reveal:not(.is-revealed) .pk-bundler-special,
.pk-bundler-mode-reveal:not(.is-revealed) .pk-bundler-saving {
    display: none;
}

.pk-bundler-reveal {
    width: 100%;
    margin-bottom: 12px;
}

.pk-bundler-mode-reveal.is-revealed .pk-bundler-reveal {
    display: none;
}

/* ── Buy X modules ── */

.pk-buyx {
    margin: 16px 0;
}

.pk-buyx-title {
    margin: 0 0 8px;
    font-weight: 700;
    font-size: .95em;
}

.pk-buyx-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.pk-buyx-item {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border: 2px dashed #cfd6d1;
    border-radius: 6px;
    background: #fff;
    cursor: pointer;
    transition: border-color .2s, background .2s, opacity .2s;
}

.pk-buyx-item:hover {
    border-color: #58af3d;
}

.pk-buyx-item.is-added {
    border-style: solid;
    border-color: #58af3d;
    background: #f4f9f1;
}

.pk-buyx-item.is-loading {
    opacity: .6;
    cursor: wait;
}

.pk-buyx-plus {
    font-weight: 700;
    color: #58af3d;
    font-size: 1.1em;
}

.pk-buyx-price {
    font-weight: 600;
    white-space: nowrap;
}

.pk-buyx-msg {
    margin: 6px 0 0;
    font-size: .85em;
    color: #58af3d;
    min-height: 1.1em;
}

/* ── Mobile ── */

@media (max-width: 768px) {
    .pk-bundler-detail {
        grid-template-columns: 1fr;
    }

    .pk-bundler-summary {
        position: static;
    }

    .pk-bundler-item {
        grid-template-columns: auto 1fr auto;
    }

    .pk-bundler-item-sku {
        display: none;
    }
}
