/**
 * Embroidery cart/minicart styles — loaded on ALL pages (minicart is global).
 * Modal/product-page styles remain in embroidery.css (product pages only).
 */

/* cart popup height fix */
#minicart-content-wrapper .product-item .product,
#minicart-content-wrapper .minicart-items .product-item-details {
    max-height: unset;
    height: auto;
}

/* Minicart price breakdown */
.embroidery-price-breakdown {
    font-size: 13px;
    line-height: 1.6;
}

.embroidery-price-row {
    display: flex;
    justify-content: space-between;
    gap: 8px;
}

.embroidery-price-value {
    font-weight: 600;
    color: #333;
    white-space: nowrap;
}

/* ─── Embroidery Minicart Card ─────────────────────────────────────────── */
.embroidery-minicart-card {
    margin: 8px 0 4px;
    border: 1px solid #b0c4d8;
    border-radius: 4px;
    background: #eef4f9;
    overflow: hidden;
    font-size: 12px;
}

/* Header row */
.embroidery-minicart-header {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 7px 10px;
    background: #0E4169;
    color: #fff;
    cursor: pointer;
    user-select: none;
}

/* Caret toggle */
.embroidery-minicart-toggle {
    display: inline-block;
    width: 0;
    height: 0;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-top: 6px solid #fff;
    transition: transform 0.25s ease;
    flex-shrink: 0;
}

.embroidery-minicart-card.active .embroidery-minicart-toggle {
    transform: rotate(0deg);
}

.embroidery-minicart-card:not(.active) .embroidery-minicart-toggle {
    transform: rotate(-90deg);
}

/* Label */
.embroidery-minicart-label {
    flex: 1;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

/* Price in header */
.embroidery-minicart-price {
    font-size: 12px;
    font-weight: 600;
    color: #c8dff0;
    white-space: nowrap;
}

/* Body — collapsed by default; shown when the card is active.
   State is driven by a KO `css: {active: ...}` binding (see minicart-collapse.js),
   so it survives Knockout re-renders of the cart/checkout summary. */
.embroidery-minicart-body {
    display: none;
    padding: 8px 10px;
}

.embroidery-minicart-card.active .embroidery-minicart-body {
    display: block;
}

/* Each section (Text / Logo) */
.embroidery-minicart-section {
    margin-bottom: 8px;
}

.embroidery-minicart-section:last-child {
    margin-bottom: 0;
}

.embroidery-minicart-section-title {
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    color: #0E4169;
    letter-spacing: 0.06em;
    margin-bottom: 4px;
    border-bottom: 1px solid #c5d8e8;
    padding-bottom: 2px;
}

/* Two-column: thumbnail left, details right */
.embroidery-minicart-row {
    display: flex;
    align-items: flex-start;
    gap: 8px;
}

/* Canvas / logo thumbnail — explicit size so it works before CSS is parsed */
.embroidery-minicart-thumb {
    width: 52px !important;
    height: 52px !important;
    max-width: 52px !important;
    max-height: 52px !important;
    object-fit: contain;
    border: 1px solid #c5d8e8;
    border-radius: 3px;
    background: #fff;
    flex-shrink: 0;
    display: block;
}

/* Details list */
.embroidery-minicart-details {
    list-style: none;
    margin: 0;
    padding: 0;
    flex: 1;
    color: #333;
    line-height: 1.5;
}

.embroidery-minicart-details li {
    font-size: 15px;
}

.embroidery-minicart-details li strong {
    color: #555;
}

/* Checkout order summary — constrain any embroidery logo images */
.opc-block-summary .embroidery-group img,
.osc-order-review .embroidery-group img,
.table-checkout-shipping-method .embroidery-group img {
    max-width: 80px;
    max-height: 80px;
    object-fit: contain;
}
/* ─── end Embroidery Minicart Card ──────────────────────────────────────── */

/* ─── Embroidery Final Sale Message ─────────────────────────────────────── */
.embroidery-final-sale-message {
    background-color: #f7f7f7;
    border-radius: 4px;
    padding: 12px 15px;
    margin: 10px 0 15px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.embroidery-final-sale-message .embroidery-icon {
    font-size: 28px;
    flex-shrink: 0;
    line-height: 1;
}

.embroidery-final-sale-message .embroidery-text {
    font-size: 13px;
    line-height: 1.5;
    color: #444;
}

.embroidery-final-sale-message .embroidery-text p {
    margin: 0;
}
/* ─── end Embroidery Final Sale Message ─────────────────────────────────── */
