/*
 * Storefront inner pages — BigDeal look (breadcrumb, auth, cart, wishlist, contact,
 * checkout, order success, order history, compare, invoice, account).
 * Colors come from the admin theme tokens, spacing uses logical properties so LTR and RTL match.
 */
.store-theme {
    --bd-primary: var(--store-primary, #ff4c3b);
    --bd-on-primary: var(--theme-on-primary, #fff);
    --bd-primary-soft: color-mix(in srgb, var(--bd-primary) 8%, #fff);
    --bd-primary-line: color-mix(in srgb, var(--bd-primary) 28%, #fff);
    --bd-heading: #333;
    --bd-text: #444;
    --bd-muted: #777;
    --bd-line: #ddd;
    --bd-line-soft: #ececec;
    --bd-light: #f9f9f9;
    --bd-form: #f1f4f7;
    --bd-success: #4ead4e;
    --bd-danger: #e53935;
}

/* ---------- Layout primitives ---------- */
.bd-section { padding: 60px 0; background: var(--bd-light); }
.bd-section--white { background: #fff; }
.bd-container { width: min(100% - 30px, 1400px); margin-inline: auto; }
.bd-container--narrow { width: min(100% - 30px, 1100px); }
.bd-card { position: relative; padding: 30px; background: #fff; border: 1px solid var(--bd-line-soft); box-shadow: 0 10px 30px -18px rgba(0, 0, 0, .18); }
.bd-card + .bd-card { margin-top: 30px; }
:is(.bd-contact-grid, .bd-order-grid, .bd-checkout) > .bd-card + .bd-card { margin-top: 0; }
.bd-card-title { margin: 0 0 22px; color: var(--bd-heading); font-size: clamp(18px, 1.6vw, 22px); font-weight: 700; line-height: 1.25; text-transform: uppercase; letter-spacing: .02em; }
.bd-card-title--center { text-align: center; }
.bd-card-title small { display: block; margin-top: 8px; color: var(--bd-muted); font-size: 14px; font-weight: 400; line-height: 1.7; text-transform: none; letter-spacing: 0; }
.bd-divider { height: 1px; margin: 24px 0; border: 0; background: var(--bd-line); opacity: 1; }
.bd-muted { color: var(--bd-muted); }
.bd-primary { color: var(--bd-primary); }
.bd-link { color: var(--bd-primary) !important; font-weight: 700; transition: opacity .2s; }
.bd-link:hover { opacity: .8; text-decoration: underline; text-underline-offset: 3px; }

/* ---------- Buttons ---------- */
.bd-btn { display: inline-flex; align-items: center; justify-content: center; gap: 9px; min-height: 50px; padding: 12px 34px; border: 1px solid var(--bd-primary); border-radius: 0; background: var(--bd-primary); color: var(--bd-on-primary) !important; font-size: 14px; font-weight: 700; line-height: 1.2; text-align: center; text-transform: uppercase; letter-spacing: .05em; cursor: pointer; transition: background-color .25s, color .25s, border-color .25s, box-shadow .25s, transform .25s; }
.bd-btn:hover { box-shadow: 0 12px 22px -14px color-mix(in srgb, var(--bd-primary) 90%, transparent); filter: brightness(.94); transform: translateY(-1px); }
.bd-btn:focus-visible { outline: 3px solid color-mix(in srgb, var(--bd-primary) 35%, transparent); outline-offset: 2px; }
.bd-btn--outline { background: transparent; color: var(--bd-primary) !important; }
.bd-btn--outline:hover { background: var(--bd-primary); color: var(--bd-on-primary) !important; filter: none; }
.bd-btn--dark { border-color: var(--bd-heading); background: var(--bd-heading); color: #fff !important; }
.bd-btn--light { border-color: var(--bd-line); background: #fff; color: var(--bd-text) !important; }
.bd-btn--light:hover { border-color: var(--bd-primary); color: var(--bd-primary) !important; filter: none; }
.bd-btn--sm { min-height: 40px; padding: 8px 18px; font-size: 12px; }
.bd-btn--block { width: 100%; }
.bd-btn.is-disabled, .bd-btn:disabled { opacity: .5; pointer-events: none; }
.bd-icon-btn { display: inline-grid; width: 40px; height: 40px; flex: 0 0 40px; place-items: center; padding: 0; border: 1px solid var(--bd-line); border-radius: 50%; background: #fff; color: var(--bd-text) !important; font-size: 15px; line-height: 1; cursor: pointer; transition: all .2s; }
.bd-icon-btn:hover { border-color: var(--bd-primary); background: var(--bd-primary); color: var(--bd-on-primary) !important; }
.bd-icon-btn--danger:hover { border-color: var(--bd-danger); background: var(--bd-danger); color: #fff !important; }
.bd-actions { display: inline-flex; align-items: center; justify-content: center; gap: 10px; }
.bd-actions form { margin: 0; }

/* ---------- Forms (BigDeal theme-form) ---------- */
.bd-form { padding: 30px; background: var(--bd-form); }
.bd-form--framed { border: 30px solid #fff; }
.bd-field { margin-bottom: 20px; }
.bd-field:last-child { margin-bottom: 0; }
.bd-label { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-start; gap: 4px 6px; margin-bottom: 9px; color: var(--bd-heading); font-size: 15px; font-weight: 700; line-height: 1.3; }
.bd-label .bd-required { color: var(--bd-danger); }
.bd-label a { margin-inline-start: auto; font-size: 13px; font-weight: 600; }
.bd-input { display: block; width: 100%; min-height: 50px; padding: 11px 20px; border: 1px solid var(--bd-line); border-radius: 0; background: #fff; color: var(--bd-heading); font-size: 15px; line-height: 1.5; box-shadow: none; outline: 0; transition: border-color .2s, box-shadow .2s; }
.bd-input::placeholder { color: #a6a6a6; }
.bd-input:focus { border-color: var(--bd-primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--bd-primary) 14%, transparent); }
textarea.bd-input { min-height: 140px; resize: vertical; }
select.bd-input { padding-inline-end: 44px; appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='none' stroke='%23777' stroke-width='1.6' d='m1 1.5 5 5 5-5'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 18px center; cursor: pointer; }
[dir=rtl] select.bd-input { background-position: left 18px center; }
.bd-input.is-invalid, .bd-input:has(+ .bd-error) { border-color: var(--bd-danger); }
.bd-error { margin: 7px 0 0; color: var(--bd-danger); font-size: 13px; font-weight: 600; }
.bd-hint { margin: 7px 0 0; color: var(--bd-muted); font-size: 13px; }
.bd-check { display: inline-flex; align-items: center; gap: 10px; margin: 0; color: var(--bd-text); font-size: 14px; font-weight: 600; cursor: pointer; }
.bd-check input { width: 18px; height: 18px; margin: 0; accent-color: var(--bd-primary); cursor: pointer; }
.bd-password { position: relative; }
.bd-password .bd-input { padding-inline-end: 52px; }
.bd-password__toggle { position: absolute; top: 50%; inset-inline-end: 8px; display: grid; width: 38px; height: 38px; place-items: center; padding: 0; border: 0; background: transparent; color: var(--bd-muted); font-size: 17px; transform: translateY(-50%); cursor: pointer; }
.bd-password__toggle:hover { color: var(--bd-primary); }
.bd-form-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 20px; }
.bd-form-row > .bd-field--full { grid-column: 1 / -1; }
.bd-form-row > .bd-field:last-child { margin-bottom: 20px; }
.bd-form-row + .bd-btn { margin-top: 6px; }
@media (max-width: 767px) { .bd-form-row { grid-template-columns: 1fr; } }
@media (max-width: 575px) { .bd-form { padding: 20px; } .bd-form--framed { border-width: 12px; } }

/* ---------- Authentication (login, register, forgot, reset) ---------- */
.bd-auth { width: min(100%, 520px); margin-inline: auto; }
.bd-auth--wide { width: min(100%, 680px); }
.bd-auth .bd-card { padding: 30px; }
.bd-auth__icon { display: grid; width: 64px; height: 64px; margin: 0 auto 16px; place-items: center; border-radius: 50%; background: var(--bd-primary-soft); color: var(--bd-primary); font-size: 26px; }
.bd-auth__meta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin: 4px 0 22px; }
.bd-auth__foot { margin-top: 24px; text-align: center; }
.bd-auth__foot p { margin: 0 0 6px; color: var(--bd-muted); font-size: 14px; line-height: 1.8; }
.bd-auth__alt { display: flex; align-items: center; gap: 14px; margin: 24px 0 18px; color: var(--bd-muted); font-size: 13px; font-weight: 700; text-transform: uppercase; }
.bd-auth__alt:before, .bd-auth__alt:after { height: 1px; flex: 1; background: var(--bd-line); content: ""; }
.bd-auth__perks { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 0 0 22px; padding: 0; list-style: none; }
.bd-auth__perks li { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 14px 8px; background: #fff; color: var(--bd-text); font-size: 13px; font-weight: 700; text-align: center; }
.bd-auth__perks i { color: var(--bd-primary); font-size: 20px; }
@media (max-width: 575px) { .bd-auth .bd-card { padding: 18px; } .bd-auth__perks { grid-template-columns: 1fr; } .bd-auth__perks li { flex-direction: row; justify-content: flex-start; } }

/* ---------- Data tables (BigDeal cart-table) ---------- */
.bd-table-card { padding: 30px; background: #fff; border: 1px solid var(--bd-line-soft); box-shadow: 0 10px 30px -18px rgba(0, 0, 0, .18); }
.bd-table { width: 100%; margin: 0; border-collapse: collapse; color: var(--bd-text); }
.bd-table thead th { padding: 0 14px 16px; border-bottom: 1px solid var(--bd-line); color: var(--bd-heading); font-size: 14px; font-weight: 900; line-height: 1.2; text-align: center; text-transform: uppercase; letter-spacing: .05em; white-space: nowrap; }
.bd-table tbody td { padding: 22px 14px; border-bottom: 1px solid var(--bd-line); text-align: center; vertical-align: middle; }
.bd-table tbody tr:last-child td { border-bottom-color: var(--bd-line); }
.bd-table .bd-cell-start { text-align: start; }
.bd-thumb { display: inline-block; width: 90px; height: 90px; overflow: hidden; border: 1px solid var(--bd-line-soft); background: var(--bd-light); }
.bd-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s; }
.bd-thumb:hover img { transform: scale(1.06); }
.bd-thumb--empty { display: inline-grid; place-items: center; color: #c4c4c4; font-size: 28px; }
.bd-product-name { display: block; color: var(--bd-heading) !important; font-size: 16px; font-weight: 700; line-height: 1.45; transition: color .2s; }
a.bd-product-name:hover { color: var(--bd-primary) !important; }
.bd-product-sub { display: block; margin-top: 5px; color: var(--bd-muted); font-size: 13px; line-height: 1.5; }
.bd-price { color: var(--bd-heading); font-size: 18px; font-weight: 400; white-space: nowrap; }
.bd-price--accent { color: var(--bd-primary); font-weight: 700; }
.bd-price-old { margin-inline-start: 6px; color: #aaa; font-size: 14px; text-decoration: line-through; }
.bd-stock { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 700; }
.bd-stock:before { width: 8px; height: 8px; border-radius: 50%; background: currentColor; content: ""; }
.bd-stock--in { color: var(--bd-success); }
.bd-stock--out { color: var(--bd-danger); }
.bd-warning { display: inline-flex; align-items: center; gap: 6px; margin-top: 6px; color: var(--bd-danger); font-size: 13px; font-weight: 700; }
.bd-mobile-meta { display: none; }
@media (max-width: 767px) {
    .bd-table-card { padding: 16px; }
    .bd-table thead { display: none; }
    .bd-table .bd-hide-sm { display: none; }
    .bd-table tbody td { padding: 16px 8px; }
    .bd-table tbody td:first-child { width: 96px; padding-inline-start: 0; }
    .bd-table .bd-cell-start-sm { text-align: start; }
    .bd-thumb { width: 82px; height: 82px; }
    .bd-mobile-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin-top: 12px; }
}

/* Quantity stepper (BigDeal qty-box) */
.bd-qty-form { display: inline-flex; margin: 0; }
.bd-qty { display: inline-flex; align-items: stretch; height: 44px; border: 1px solid var(--bd-line); background: #fff; }
.bd-qty button { display: grid; width: 38px; place-items: center; padding: 0; border: 0; background: #fff; color: var(--bd-text); font-size: 12px; cursor: pointer; transition: color .2s, background-color .2s; }
.bd-qty button:hover { background: var(--bd-light); color: var(--bd-primary); }
.bd-qty input { width: 50px; padding: 0; border: 0; border-inline: 1px solid var(--bd-line); background: #fff; color: var(--bd-heading); font-size: 15px; font-weight: 700; text-align: center; outline: 0; -moz-appearance: textfield; }
.bd-qty input::-webkit-inner-spin-button, .bd-qty input::-webkit-outer-spin-button { margin: 0; -webkit-appearance: none; }
.bd-qty-form.is-saving { opacity: .55; pointer-events: none; }

/* Cart footer + totals */
.bd-cart-foot { display: grid; grid-template-columns: minmax(0, 1fr) 400px; align-items: start; gap: 30px; margin-top: 30px; }
.bd-cart-foot__links { display: flex; flex-wrap: wrap; gap: 12px; }
.bd-totals { padding: 30px; background: #fff; border: 1px solid var(--bd-line-soft); box-shadow: 0 10px 30px -18px rgba(0, 0, 0, .18); }
.bd-totals ul { margin: 0 0 18px; padding: 0; list-style: none; }
.bd-totals li { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 12px 0; border-bottom: 1px dashed var(--bd-line); color: var(--bd-text); font-size: 15px; }
.bd-totals li strong { color: var(--bd-heading); font-weight: 700; }
.bd-totals li.bd-totals__grand { padding-top: 18px; border-bottom: 0; color: var(--bd-heading); font-size: 18px; font-weight: 700; text-transform: uppercase; }
.bd-totals li.bd-totals__grand strong { color: var(--bd-primary); font-size: 24px; }
.bd-totals .bd-btn + .bd-btn { margin-top: 10px; }
.bd-note { display: flex; gap: 9px; margin: 0 0 20px; padding: 12px 14px; background: var(--bd-primary-soft); color: var(--bd-text); font-size: 13px; line-height: 1.7; }
.bd-note i { margin-top: 3px; color: var(--bd-primary); }
@media (max-width: 991px) { .bd-cart-foot { grid-template-columns: 1fr; } .bd-cart-foot__links { order: 2; } }
@media (max-width: 575px) { .bd-cart-foot__links .bd-btn { flex: 1 1 100%; } .bd-totals { padding: 20px; } }

/* ---------- Empty state ---------- */
.bd-empty { padding: 70px 24px; background: #fff; border: 1px solid var(--bd-line-soft); text-align: center; }
.bd-empty__icon { display: grid; width: 96px; height: 96px; margin: 0 auto 22px; place-items: center; border-radius: 50%; background: var(--bd-primary-soft); color: var(--bd-primary); font-size: 38px; }
.bd-empty h2 { margin: 0 0 10px; color: var(--bd-heading); font-size: 22px; font-weight: 700; text-transform: uppercase; }
.bd-empty p { max-width: 460px; margin: 0 auto 26px; color: var(--bd-muted); font-size: 15px; line-height: 1.8; }
.bd-empty[hidden], .bd-empty.hidden, [data-wishlist-grid].hidden, .bd-hidden { display: none !important; }

/* ---------- Status badges ---------- */
.bd-status { display: inline-flex; align-items: center; gap: 7px; padding: 6px 12px; border-radius: 999px; background: #f1f1f1; color: #555; font-size: 12px; font-weight: 800; line-height: 1; text-transform: uppercase; letter-spacing: .04em; white-space: nowrap; }
.bd-status:before { width: 7px; height: 7px; border-radius: 50%; background: currentColor; content: ""; }
.bd-status--warning { background: #fff5e0; color: #b7791f; }
.bd-status--primary { background: #e8efff; color: #2f5bd3; }
.bd-status--info { background: #e3f6fb; color: #0e7f9c; }
.bd-status--success { background: #e7f6e9; color: #2e7d32; }
.bd-status--danger { background: #fdecec; color: #c62828; }
.bd-status--secondary { background: #f1f1f1; color: #555; }

/* ---------- Contact page ---------- */
.bd-contact-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 30px; align-items: stretch; }
.bd-contact-grid--single { grid-template-columns: 1fr; }
.bd-contact-intro { margin: 0 0 26px; color: var(--bd-muted); font-size: 15px; line-height: 1.85; }
.bd-contact-list { margin: 0; padding: 0; list-style: none; }
.bd-contact-list li { display: grid; grid-template-columns: 120px minmax(0, 1fr); align-items: center; gap: 22px; padding: 22px 0; border-bottom: 1px solid var(--bd-line-soft); }
.bd-contact-list li:first-child { padding-top: 0; }
.bd-contact-list li:last-child { border-bottom: 0; padding-bottom: 0; }
.bd-contact-icon { display: flex; flex-direction: column; align-items: center; gap: 8px; padding-inline-end: 22px; border-inline-end: 1px solid var(--bd-line); text-align: center; }
.bd-contact-icon i { display: grid; width: 48px; height: 48px; place-items: center; border-radius: 50%; background: var(--bd-primary-soft); color: var(--bd-primary); font-size: 20px; }
.bd-contact-icon h6 { margin: 0; color: var(--bd-primary); font-size: 13px; font-weight: 700; line-height: 1.3; text-transform: uppercase; }
.bd-contact-value p { margin: 0; color: var(--bd-heading); font-size: 16px; line-height: 1.7; overflow-wrap: anywhere; }
.bd-contact-value a { color: var(--bd-heading); transition: color .2s; }
.bd-contact-value a:hover { color: var(--bd-primary); }
.bd-contact-value [dir=ltr] { unicode-bidi: isolate; }
.bd-social { display: flex; flex-wrap: wrap; gap: 10px; margin: 26px 0 0; padding: 0; list-style: none; }
.bd-social a { display: grid; width: 42px; height: 42px; place-items: center; border: 1px solid var(--bd-line); border-radius: 50%; background: #fff; color: var(--bd-text); font-size: 17px; transition: all .25s; }
.bd-social a:hover { border-color: var(--bd-primary); background: var(--bd-primary); color: var(--bd-on-primary); transform: translateY(-2px); }
.bd-contact-form .bd-card-title { margin-bottom: 8px; }
.bd-contact-form .bd-contact-intro { margin-bottom: 20px; }
.bd-map { margin-top: 30px; padding: 30px; background: var(--bd-form); border: 30px solid #fff; box-shadow: 0 10px 30px -18px rgba(0, 0, 0, .18); }
.bd-map iframe { display: block; width: 100%; height: 450px; border: 0; }
.bd-map__bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.bd-map__bar h3 { display: flex; align-items: center; gap: 10px; margin: 0; color: var(--bd-heading); font-size: 18px; font-weight: 700; text-transform: uppercase; }
.bd-map__bar h3 i { color: var(--bd-primary); }
@media (max-width: 991px) { .bd-contact-grid { grid-template-columns: 1fr; } }
@media (max-width: 575px) {
    .bd-contact-list li { grid-template-columns: 1fr; gap: 12px; }
    .bd-contact-icon { flex-direction: row; justify-content: flex-start; padding: 0; border: 0; }
    .bd-map { padding: 12px; border-width: 12px; }
    .bd-map iframe { height: 320px; }
}

/* ---------- Checkout ---------- */
.bd-checkout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 30px; align-items: start; }
.bd-checkout-title { display: flex; align-items: center; gap: 12px; margin: 0 0 25px; color: var(--bd-heading); font-size: 22px; font-weight: 700; text-transform: uppercase; }
.bd-checkout-title span { display: grid; width: 34px; height: 34px; place-items: center; border-radius: 50%; background: var(--bd-primary); color: var(--bd-on-primary); font-size: 15px; }
.bd-checkout .bd-card + .bd-card { margin-top: 30px; }
:is(.bd-contact-grid, .bd-order-grid, .bd-checkout) > .bd-card + .bd-card { margin-top: 0; }
.bd-order-box__head { display: flex; justify-content: space-between; gap: 15px; padding-bottom: 20px; margin-bottom: 20px; border-bottom: 1px solid var(--bd-line); color: var(--bd-text); font-size: 20px; font-weight: 700; text-transform: uppercase; }
.bd-order-lines { margin: 0 0 22px; padding: 0 0 4px; border-bottom: 1px solid var(--bd-line); list-style: none; }
.bd-order-lines li { display: grid; grid-template-columns: 56px minmax(0, 1fr) auto; align-items: center; gap: 14px; margin-bottom: 18px; color: var(--bd-text); font-size: 15px; }
.bd-order-lines img, .bd-order-lines .bd-order-lines__ph { width: 56px; height: 56px; border: 1px solid var(--bd-line-soft); background: var(--bd-light); object-fit: cover; }
.bd-order-lines .bd-order-lines__ph { display: grid; place-items: center; color: #c4c4c4; font-size: 20px; }
.bd-order-lines strong { display: block; color: var(--bd-heading); font-size: 15px; font-weight: 700; line-height: 1.4; }
.bd-order-lines small { color: var(--bd-muted); font-size: 13px; }
.bd-order-lines .bd-order-lines__price { color: var(--bd-heading); font-size: 16px; white-space: nowrap; }
.bd-order-sums { margin: 0 0 22px; padding: 0 0 4px; border-bottom: 1px solid var(--bd-line); list-style: none; }
.bd-order-sums li { display: flex; justify-content: space-between; gap: 15px; margin-bottom: 16px; color: var(--bd-heading); font-size: 16px; font-weight: 600; }
.bd-order-sums li span:last-child { color: var(--bd-primary); font-weight: 400; }
.bd-order-total { display: flex; justify-content: space-between; gap: 15px; margin: 0 0 28px; color: var(--bd-heading); font-size: 20px; font-weight: 700; text-transform: uppercase; }
.bd-order-total span:last-child { color: var(--bd-primary); font-size: 24px; }
.bd-payment-options { display: grid; gap: 12px; margin: 0 0 24px; padding: 0; list-style: none; }
.bd-radio { position: relative; display: flex; align-items: flex-start; gap: 12px; padding: 16px 18px; border: 1px solid var(--bd-line); background: #fff; cursor: pointer; transition: border-color .2s, background-color .2s, box-shadow .2s; }
.bd-radio:hover { border-color: var(--bd-primary-line); }
.bd-radio input { width: 18px; height: 18px; flex: 0 0 18px; margin: 2px 0 0; accent-color: var(--bd-primary); cursor: pointer; }
.bd-radio strong { display: block; color: var(--bd-heading); font-size: 15px; font-weight: 700; }
.bd-radio small { display: block; margin-top: 4px; color: var(--bd-muted); font-size: 13px; line-height: 1.6; }
.bd-radio:has(input:checked) { border-color: var(--bd-primary); background: var(--bd-primary-soft); box-shadow: inset 3px 0 0 var(--bd-primary); }
[dir=rtl] .bd-radio:has(input:checked) { box-shadow: inset -3px 0 0 var(--bd-primary); }
.bd-secure { display: flex; align-items: center; justify-content: center; gap: 8px; margin: 14px 0 0; color: var(--bd-muted); font-size: 13px; }
.bd-secure i { color: var(--bd-success); }
@media (min-width: 992px) { .bd-checkout__aside { position: sticky; top: 100px; } }
@media (max-width: 991px) { .bd-checkout { grid-template-columns: 1fr; } }

/* ---------- Order success / order details ---------- */
.bd-success { padding: 60px 0 50px; background: #fff; text-align: center; }
.bd-success__icon { display: grid; width: 92px; height: 92px; margin: 0 auto 20px; place-items: center; border-radius: 50%; background: color-mix(in srgb, var(--bd-success) 12%, #fff); color: var(--bd-success); font-size: 50px; animation: bdPop .5s cubic-bezier(.2, .9, .3, 1.4) both; }
.bd-success h2 { margin: 0 0 12px; color: var(--bd-heading); font-size: clamp(24px, 2.6vw, 36px); font-weight: 700; text-transform: uppercase; }
.bd-success p { max-width: 640px; margin: 0 auto 6px; color: var(--bd-muted); font-size: 17px; line-height: 1.8; }
.bd-success .bd-success__ref { display: inline-flex; gap: 8px; margin-top: 14px; padding: 9px 18px; border: 1px dashed var(--bd-primary-line); background: var(--bd-primary-soft); color: var(--bd-heading); font-size: 15px; }
.bd-success .bd-success__ref strong { color: var(--bd-primary); }
@keyframes bdPop { from { opacity: 0; transform: scale(.5); } to { opacity: 1; transform: scale(1); } }
.bd-order-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 30px; align-items: start; }
.bd-order-grid--detail { grid-template-columns: minmax(0, 1fr) 400px; }
.bd-product-order h3, .bd-order-side h3 { margin: 0 0 20px; color: var(--bd-heading); font-size: clamp(18px, 1.6vw, 22px); font-weight: 700; line-height: 1.2; text-transform: uppercase; }
.bd-order-item { display: grid; grid-template-columns: 100px repeat(3, minmax(0, 1fr)); align-items: center; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--bd-line-soft); }
.bd-order-item:first-of-type { padding-top: 0; }
.bd-order-item .bd-thumb { width: 100px; height: 100px; }
.bd-order-item h4 { margin: 0 0 6px; color: var(--bd-muted); font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.bd-order-item h5 { margin: 0; color: var(--bd-heading); font-size: 15px; font-weight: 700; line-height: 1.45; }
.bd-order-item h5 small { display: block; margin-top: 3px; color: var(--bd-muted); font-size: 12.5px; font-weight: 400; }
.bd-total-sec { margin: 18px 0; padding: 16px 0; border-block: 1px solid var(--bd-line); list-style: none; }
.bd-total-sec li { display: flex; justify-content: space-between; gap: 15px; padding: 5px 0; color: var(--bd-heading); font-size: 16px; }
.bd-final-total { display: flex; justify-content: space-between; gap: 15px; margin: 0; color: var(--bd-heading); font-size: 22px; font-weight: 700; text-transform: uppercase; }
.bd-final-total span:last-child { color: var(--bd-primary); }
.bd-order-side { display: grid; grid-template-columns: 1fr 1fr; gap: 26px 30px; }
.bd-order-side > .bd-order-side__full { grid-column: 1 / -1; }
.bd-order-side h4 { margin: 0 0 12px; color: var(--bd-heading); font-size: 17px; font-weight: 700; text-transform: uppercase; }
.bd-order-detail { margin: 0; padding: 0; list-style: none; }
.bd-order-detail li { display: flex; flex-wrap: wrap; gap: 6px; padding: 3px 0; color: var(--bd-text); font-size: 15px; line-height: 1.7; }
.bd-order-detail li span { color: var(--bd-muted); }
.bd-delivery-sec { padding: 28px; background: var(--bd-primary-soft); border: 1px dashed var(--bd-primary-line); text-align: center; }
.bd-delivery-sec h3 { margin: 0 0 8px; color: var(--bd-heading); font-size: 18px; font-weight: 500; text-transform: none; }
.bd-delivery-sec h2 { margin: 0; color: var(--bd-primary); font-size: clamp(20px, 2vw, 28px); font-weight: 700; }
.bd-order-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 34px; }
.bd-timeline { position: relative; margin: 0; padding: 0; list-style: none; }
.bd-timeline li { position: relative; padding-inline-start: 34px; padding-bottom: 22px; }
.bd-timeline li:last-child { padding-bottom: 0; }
.bd-timeline li:before { position: absolute; top: 4px; inset-inline-start: 0; width: 16px; height: 16px; border: 3px solid var(--bd-primary); border-radius: 50%; background: #fff; content: ""; }
.bd-timeline li:first-child:before { background: var(--bd-primary); }
.bd-timeline li:not(:last-child):after { position: absolute; top: 22px; bottom: 0; inset-inline-start: 7px; width: 2px; background: var(--bd-line); content: ""; }
.bd-timeline strong { display: block; color: var(--bd-heading); font-size: 15px; font-weight: 700; }
.bd-timeline small { color: var(--bd-muted); font-size: 13px; }
.bd-timeline p { margin: 6px 0 0; color: var(--bd-text); font-size: 14px; line-height: 1.7; }
@media (max-width: 991px) { .bd-order-grid, .bd-order-grid--detail { grid-template-columns: 1fr; } }
@media (max-width: 575px) {
    .bd-order-item { grid-template-columns: 80px minmax(0, 1fr); }
    .bd-order-item .bd-thumb { width: 80px; height: 80px; grid-row: span 3; }
    .bd-order-side { grid-template-columns: 1fr; }
    .bd-final-total { font-size: 18px; }
}

/* ---------- Order history ---------- */
.bd-order-thumbs { display: inline-flex; align-items: center; }
.bd-order-thumbs .bd-thumb { width: 64px; height: 64px; border: 2px solid #fff; border-radius: 50%; box-shadow: 0 2px 8px rgba(0, 0, 0, .1); }
.bd-order-thumbs .bd-thumb + .bd-thumb { margin-inline-start: -18px; }
.bd-order-thumbs__more { display: grid; width: 40px; height: 40px; margin-inline-start: -10px; place-items: center; border: 2px solid #fff; border-radius: 50%; background: var(--bd-heading); color: #fff; font-size: 12px; font-weight: 700; }
.bd-order-no { color: var(--bd-muted); font-size: 14px; }
.bd-order-no strong { color: var(--bd-heading); font-weight: 700; }

/* ---------- Account area ---------- */
.bd-account { display: grid; grid-template-columns: 290px minmax(0, 1fr); gap: 30px; align-items: start; }
/* Grid items may shrink below their content (wide tables then use their own small-screen layout instead of widening the page). */
.bd-account > * { min-width: 0; }
.bd-account-nav { padding: 0; background: #fff; border: 1px solid var(--bd-line-soft); box-shadow: 0 10px 30px -18px rgba(0, 0, 0, .18); }
.bd-account-nav__head { display: flex; align-items: center; gap: 14px; padding: 24px; background: var(--bd-primary); color: var(--bd-on-primary); }
.bd-account-nav__avatar { display: grid; width: 52px; height: 52px; flex: 0 0 52px; place-items: center; border-radius: 50%; background: color-mix(in srgb, var(--bd-on-primary) 20%, transparent); font-size: 21px; font-weight: 800; text-transform: uppercase; }
.bd-account-nav__head strong, .bd-account-nav__head small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bd-account-nav__head strong { font-size: 16px; }
.bd-account-nav__head small { opacity: .8; font-size: 13px; }
.bd-account-nav__head > div { min-width: 0; }
.bd-account-nav ul { margin: 0; padding: 10px 0; list-style: none; }
.store-theme .bd-account-nav li a, .store-theme .bd-account-nav li button { display: flex; width: 100%; align-items: center; gap: 12px; padding: 13px 24px; border: 0; border-inline-start: 3px solid transparent; background: transparent; color: var(--bd-text); font-size: 15px; font-weight: 700; text-align: start; transition: all .2s; cursor: pointer; }
.bd-account-nav li a i, .bd-account-nav li button i { width: 18px; color: var(--bd-muted); text-align: center; }
.bd-account-nav li a:hover, .bd-account-nav li button:hover { background: var(--bd-light); color: var(--bd-primary); }
.bd-account-nav li a.is-active { border-inline-start-color: var(--bd-primary); background: var(--bd-primary-soft); color: var(--bd-primary); }
.bd-account-nav li a.is-active i { color: var(--bd-primary); }
.bd-account-nav form { margin: 0; }
.bd-account-nav li.bd-account-nav__logout { margin-top: 6px; padding-top: 6px; border-top: 1px solid var(--bd-line-soft); }
.bd-account-nav li.bd-account-nav__logout button:hover { color: var(--bd-danger); }
@media (max-width: 991px) {
    .bd-account { grid-template-columns: 1fr; }
    .bd-account-nav ul { display: flex; overflow-x: auto; padding: 0; }
    .bd-account-nav li { flex: 0 0 auto; }
    .store-theme .bd-account-nav li a, .store-theme .bd-account-nav li button { padding: 14px 18px; border-inline-start: 0; border-bottom: 3px solid transparent; white-space: nowrap; }
    .store-theme .bd-account-nav li a.is-active { border-bottom-color: var(--bd-primary); }
    .bd-account-nav li.bd-account-nav__logout { margin: 0; padding: 0; border: 0; }
}

/* ---------- Compare ---------- */
.bd-compare-toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 20px; }
.bd-compare-toolbar p { margin: 0; color: var(--bd-muted); font-size: 15px; }
.bd-compare-wrap { overflow-x: auto; background: #fff; border: 1px solid var(--bd-line); box-shadow: 0 10px 30px -18px rgba(0, 0, 0, .18); }
.bd-compare { width: 100%; min-width: max-content; margin: 0; border-collapse: collapse; color: var(--bd-heading); }
.bd-compare th, .bd-compare td { min-width: 240px; padding: 18px 20px; border: 1px solid var(--bd-line); vertical-align: middle; }
.bd-compare th[scope=row] { position: sticky; z-index: 1; inset-inline-start: 0; width: 180px; min-width: 180px; background: #f1f1f1; color: var(--bd-heading); font-size: 14px; font-weight: 700; text-align: start; text-transform: uppercase; letter-spacing: .05em; }
.bd-compare td { text-align: center; }
.bd-compare__remove { display: inline-flex; align-items: center; gap: 7px; padding: 0; border: 0; background: transparent; color: var(--bd-muted); font-size: 14px; font-weight: 700; cursor: pointer; transition: color .2s; }
.bd-compare__remove:hover { color: var(--bd-danger); }
.bd-compare__image { display: block; width: 185px; height: 185px; margin: 0 auto 16px; overflow: hidden; background: var(--bd-light); }
.bd-compare__image img { width: 100%; height: 100%; object-fit: cover; }
.bd-compare__price { display: block; margin-bottom: 16px; color: var(--bd-heading); font-size: 15px; }
.bd-compare__price strong { color: var(--bd-primary); font-size: 18px; }
.bd-compare__desc { max-width: 280px; margin: 0 auto; color: var(--bd-muted); font-size: 14px; line-height: 1.75; text-align: start; }
.bd-compare__rating { color: #ffa200; font-size: 14px; letter-spacing: 2px; }

/* ---------- Invoice (BigDeal theme-invoice) ---------- */
.bd-invoice { padding: 40px; background: #fff; border: 1px solid var(--bd-line-soft); box-shadow: 0 10px 30px -18px rgba(0, 0, 0, .18); }
.bd-invoice__header { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; padding-bottom: 30px; }
.bd-invoice__logo img { max-width: 190px; max-height: 70px; object-fit: contain; }
.bd-invoice__company { margin: 0; padding: 0; list-style: none; text-align: end; }
.bd-invoice__company li { color: var(--bd-text); font-size: 15px; line-height: 1.8; }
.bd-invoice__company li h2 { margin: 0 0 4px; color: var(--bd-primary); font-size: 24px; font-weight: 700; text-transform: uppercase; }
.bd-invoice__company li i { width: 18px; margin-inline-end: 6px; color: var(--bd-primary); text-align: center; }
.bd-invoice__band { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 30px; padding: 22px 24px; background: var(--bd-primary-soft); border-inline-start: 4px solid var(--bd-primary); }
.bd-invoice__band ul { margin: 0; padding: 0; list-style: none; }
.bd-invoice__band li { color: var(--bd-primary); font-size: 15px; font-weight: 700; line-height: 1.9; }
.bd-invoice__band li span { margin-inline-start: 5px; color: var(--bd-text); font-weight: 400; }
.bd-invoice__band ul:last-child { text-align: end; }
.bd-invoice-table { width: 100%; border-collapse: collapse; }
.bd-invoice-table th { padding: 15px; background: rgba(238, 238, 238, .55); color: var(--bd-text); font-size: 14px; font-weight: 700; text-align: start; text-transform: uppercase; white-space: nowrap; }
.bd-invoice-table tbody td { padding: 15px; border: 2px solid #fff; background: rgba(238, 238, 238, .3); color: var(--bd-heading); font-weight: 700; }
.bd-invoice-table tbody td h3 { margin: 0; color: #000; font-size: 16px; font-weight: 700; }
.bd-invoice-table tbody td p { margin: 4px 0 0; color: var(--bd-muted); font-size: 13px; font-weight: 400; }
.bd-invoice-table tfoot td { padding: 10px 15px; color: var(--bd-text); font-weight: 700; }
.bd-invoice-table tfoot tr:first-child td { padding-top: 26px; }
.bd-invoice-table tfoot tr.bd-invoice-table__grand td:nth-child(n+2) { padding-block: 15px; background: var(--bd-primary-soft); color: var(--bd-primary); font-size: 17px; }
.bd-invoice-table .bd-num { text-align: end; white-space: nowrap; }
.bd-invoice__note { margin: 28px 0 0; color: var(--bd-muted); font-size: 14px; text-align: center; }
.bd-print-bar { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; margin-top: 30px; }
@media (max-width: 767px) {
    .bd-invoice { padding: 20px; }
    .bd-invoice__header, .bd-invoice__band { display: block; }
    .bd-invoice__company, .bd-invoice__band ul:last-child { margin-top: 16px; text-align: start; }
    .bd-invoice-wrap { overflow-x: auto; }
    .bd-invoice-table { min-width: 620px; }
    .bd-print-bar .bd-btn { flex: 1 1 100%; }
}
@media print {
    @page { margin: 12mm; }
    body.store-theme { background: #fff !important; }
    body.store-theme > header, body.store-theme > footer, .bigdeal-store-header, .cosmetic-store-header, .adaptive-store-header, .store-header-sticky-spacer,
    body.store-theme footer, .product-breadcrumb, .bd-print-bar, .bd-no-print, [data-flash-alert], [data-store-ajax-alert] { display: none !important; }
    .bd-section { padding: 0 !important; background: #fff !important; }
    .bd-container { width: 100%; }
    .bd-invoice { padding: 0; border: 0; box-shadow: none; }
    .bd-invoice__band, .bd-invoice-table th, .bd-invoice-table tbody td, .bd-invoice-table tfoot tr.bd-invoice-table__grand td { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
    /* Only the page content prints: everything outside <main> (header, newsletter strip, footer, side panels, dialogs) is taken out
       of the layout, so nothing can widen or shift the printed page. */
    body.store-theme > :not(main) { display: none !important; }
    html, body.store-theme { width: auto !important; min-width: 0 !important; overflow: visible !important; }
    /* A printed page is about 700px wide, so the small-screen rules apply: the invoice table fits the page instead of scrolling. */
    .bd-invoice-wrap { overflow: visible !important; }
    .bd-invoice-table { min-width: 0 !important; }
}

/* ---------- Shared section heading inside pages ---------- */
.bd-section-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 22px; }
.bd-section-head .bd-card-title { margin: 0; }

@media (max-width: 575px) {
    .bd-section { padding: 36px 0; }
    .bd-card { padding: 20px; }
    .bd-empty { padding: 50px 18px; }
}
[dir=rtl] .bd-flip-rtl { transform: scaleX(-1); }
@media (max-width: 1399px) { .bd-account .bd-order-grid { grid-template-columns: 1fr; } }
/* BigDeal sets list items inline-block globally; these lists stack vertically. */
.bd-invoice__band li, .bd-invoice__company li, .bd-timeline li, .bd-account-nav li { display: block; }

/* Categories page: square tiles tinted with the theme colour; on hover the tile lifts, a light sweep crosses it,
   a ring draws in, the image eases in, an arrow chip slides out and the name gets a growing underline. */
.store-category-grid { --tile-tint: color-mix(in srgb, var(--store-primary) 14%, #fff); display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 28px 20px; }
.store-category-tile { display: flex; flex-direction: column; align-items: center; min-width: 0; color: inherit; text-align: center; text-decoration: none; opacity: 0; animation: store-category-in .6s cubic-bezier(.22, 1, .36, 1) forwards; animation-delay: calc(var(--tile-index, 0) * 45ms); }
.store-category-tile:hover, .store-category-tile:focus-visible { color: inherit; text-decoration: none; }
.store-category-tile__media { position: relative; display: flex; width: 100%; aspect-ratio: 1; align-items: center; justify-content: center; overflow: hidden; border-radius: 18px; background: var(--tile-tint); box-shadow: 0 0 0 0 transparent, inset 0 0 0 0 transparent; isolation: isolate; transition: transform .5s cubic-bezier(.22, 1, .36, 1), box-shadow .5s cubic-bezier(.22, 1, .36, 1); }
.store-category-tile__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .9s cubic-bezier(.22, 1, .36, 1), filter .6s ease; }
.store-category-tile__media::after { position: absolute; inset: 0; z-index: 1; background: linear-gradient(115deg, transparent 30%, rgba(255, 255, 255, .55) 48%, transparent 66%); content: ""; transform: translateX(-120%); pointer-events: none; }
.store-category-tile__placeholder { color: color-mix(in srgb, var(--store-primary) 45%, #8a8a8a); font-size: 26px; transition: transform .6s cubic-bezier(.34, 1.56, .64, 1), color .4s ease; }
.store-category-tile__arrow { position: absolute; top: 12px; inset-inline-end: 12px; z-index: 2; display: flex; width: 34px; height: 34px; align-items: center; justify-content: center; border-radius: 50%; color: var(--theme-on-primary, #fff); background: var(--store-primary); font-size: 14px; opacity: 0; transform: translate(-8px, 8px) scale(.6); transition: opacity .35s ease, transform .45s cubic-bezier(.34, 1.56, .64, 1); }
[dir=rtl] .store-category-tile__arrow { transform: translate(8px, 8px) scale(.6); }
.store-category-tile__name { position: relative; max-width: 100%; margin-top: 14px; padding-bottom: 3px; overflow: hidden; color: #1f1f1f; font-size: 16px; font-weight: 800; text-overflow: ellipsis; white-space: nowrap; transition: color .35s ease; }
.store-category-tile__name::after { position: absolute; right: 0; bottom: 0; left: 0; height: 2px; margin: 0 auto; border-radius: 2px; background: var(--store-primary); content: ""; transform: scaleX(0); transition: transform .45s cubic-bezier(.22, 1, .36, 1); }
.store-category-tile__count { margin-top: 2px; color: #777; font-size: 13px; transition: color .35s ease; }

@media (hover: hover) {
    .store-category-tile:hover .store-category-tile__media { transform: translateY(-6px); box-shadow: 0 18px 34px -16px color-mix(in srgb, var(--store-primary) 55%, transparent), inset 0 0 0 2px color-mix(in srgb, var(--store-primary) 60%, transparent); }
    .store-category-tile:hover .store-category-tile__media::after { transform: translateX(120%); transition: transform .9s cubic-bezier(.22, 1, .36, 1); }
    .store-category-tile:hover .store-category-tile__media img { transform: scale(1.08); filter: saturate(1.08); }
    .store-category-tile:hover .store-category-tile__placeholder { color: var(--store-primary); transform: scale(1.25) rotate(-8deg); }
    .store-category-tile:hover .store-category-tile__arrow { opacity: 1; transform: translate(0, 0) scale(1); }
    .store-category-tile:hover .store-category-tile__name { color: var(--store-primary); }
    .store-category-tile:hover .store-category-tile__name::after { transform: scaleX(1); }
    .store-category-tile:hover .store-category-tile__count { color: #555; }
}
.store-category-tile:focus-visible { outline: none; }
.store-category-tile:focus-visible .store-category-tile__media { box-shadow: 0 0 0 3px color-mix(in srgb, var(--store-primary) 45%, transparent); }
.store-category-tile:active .store-category-tile__media { transform: translateY(-2px) scale(.98); transition-duration: .15s; }

@keyframes store-category-in { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }

@media (max-width: 1199px) { .store-category-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (max-width: 991px) { .store-category-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px 16px; } }
@media (max-width: 575px) {
    .store-category-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 14px; }
    .store-category-tile__media { border-radius: 14px; }
    .store-category-tile__name { margin-top: 10px; font-size: 14px; }
}
@media (prefers-reduced-motion: reduce) {
    .store-category-tile { opacity: 1; animation: none; }
    .store-category-tile *, .store-category-tile *::after { transition: none !important; }
}
.dark .store-category-grid { --tile-tint: color-mix(in srgb, var(--store-primary) 18%, #0f172a); }
.dark .store-category-tile__name { color: #f1f5f9; }
.dark .store-category-tile__count { color: #94a3b8; }
