/* ============================================================
   Jollence Print Shop – Frontend Styles
   ============================================================ */

:root {
    --jps-black: #0d0d0d;
    --jps-dark:  #1a1a1a;
    --jps-mid:   #555;
    --jps-light: #f7f6f3;
    --jps-white: #ffffff;
    --jps-gold:  #c9a96e;
    --jps-border:#e0ddd6;
    --jps-frame-black: #1c1c1c;
    --jps-frame-brown: #5c3d1e;
    --jps-mat:   #f4f1ec;
    --jps-radius: 4px;
    --jps-shadow: 0 8px 32px rgba(0,0,0,0.18);
}

/* ============================================================
   Isolation layer — the active theme's global CSS (button/input/
   link resets, font overrides, etc.) can otherwise bleed into and
   override these rules since it loads on every page. Every plugin
   surface is wrapped in one of these containers, so scoping a hard
   reset to them keeps this stylesheet self-contained regardless of
   which theme is active.
   ============================================================ */
.jps-gallery-wrap,
.jps-digital-gallery-wrap,
.jps-checkout-wrap,
.jps-account-wrap,
.jps-auth-wrap,
.jps-cart-widget,
.jps-lightbox,
.jps-store-hub-wrap {
    all: initial;
    display: block;
    box-sizing: border-box;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    color: var(--jps-dark);
    line-height: 1.5;
    text-align: left;
}
.jps-gallery-wrap *,
.jps-digital-gallery-wrap *,
.jps-checkout-wrap *,
.jps-account-wrap *,
.jps-auth-wrap *,
.jps-cart-widget *,
.jps-lightbox *,
.jps-store-hub-wrap * {
    box-sizing: border-box;
}
.jps-gallery-wrap img,
.jps-digital-gallery-wrap img,
.jps-checkout-wrap img,
.jps-account-wrap img,
.jps-auth-wrap img,
.jps-cart-widget img,
.jps-lightbox img,
.jps-store-hub-wrap img {
    border-radius: 0;
    margin: 0;
    max-width: none;
    display: block;
}
:where(
    .jps-gallery-wrap,
    .jps-digital-gallery-wrap,
    .jps-checkout-wrap,
    .jps-account-wrap,
    .jps-auth-wrap,
    .jps-cart-widget
) button,
:where(
    .jps-gallery-wrap,
    .jps-digital-gallery-wrap,
    .jps-checkout-wrap,
    .jps-account-wrap,
    .jps-auth-wrap
) select,
:where(
    .jps-gallery-wrap,
    .jps-digital-gallery-wrap,
    .jps-checkout-wrap,
    .jps-account-wrap,
    .jps-auth-wrap
) input,
:where(
    .jps-gallery-wrap,
    .jps-checkout-wrap,
    .jps-account-wrap,
    .jps-auth-wrap
) textarea {
    all: revert;
    box-sizing: border-box;
    font-family: inherit;
}

/* ── Gallery Grid ── */
.jps-gallery-wrap { position: relative; max-width: 1200px; margin: 0 auto; }

.jps-gallery-grid {
    display: grid;
    gap: 28px;
    padding: 20px 0;
}
.jps-gallery-grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
.jps-gallery-grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
.jps-gallery-grid.cols-4 { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 900px) {
    .jps-gallery-grid.cols-3,
    .jps-gallery-grid.cols-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
    .jps-gallery-grid { grid-template-columns: 1fr !important; }
}

/* ── Store Hub (Buy Print / Stock Photos landing) ── */
.jps-store-hub-wrap { max-width: 1100px; margin: 0 auto; padding: 20px 0; }
.jps-store-hub-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 28px;
}
@media (max-width: 700px) {
    .jps-store-hub-grid { grid-template-columns: 1fr; }
}
.jps-store-hub-card {
    display: block;
    text-decoration: none;
    color: inherit;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 4px 24px rgba(0,0,0,0.12);
    background: var(--jps-dark);
    position: relative;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.jps-store-hub-card:hover { transform: translateY(-4px); box-shadow: 0 16px 44px rgba(0,0,0,0.22); }
.jps-store-hub-thumb { position: relative; aspect-ratio: 4/5; background: var(--jps-dark); overflow: hidden; }
.jps-store-hub-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    border-radius: 0 !important;
    margin: 0;
    max-width: none;
    transition: transform 0.5s ease;
}
.jps-store-hub-card:hover .jps-store-hub-thumb img { transform: scale(1.05); }
.jps-store-hub-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.15) 55%, transparent 100%);
}
.jps-store-hub-label {
    position: absolute;
    left: 0; right: 0; bottom: 0;
    padding: 28px 26px 26px;
    color: var(--jps-white);
}
.jps-store-hub-label h2 { margin: 0 0 8px; font-size: 28px; font-weight: 700; letter-spacing: 0.5px; }
.jps-store-hub-label p { margin: 0 0 14px; font-size: 14px; color: rgba(255,255,255,0.85); line-height: 1.5; max-width: 320px; }
.jps-store-hub-cta { font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; color: var(--jps-white); border-bottom: 2px solid var(--jps-gold); padding-bottom: 3px; }

/* ── Gallery Item (large premium print card) ── */
.jps-gallery-item { cursor: pointer; }

.jps-thumb-wrap {
    background: var(--jps-white);
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 2px 18px rgba(0,0,0,0.08);
    border: 1px solid var(--jps-border);
    transition: box-shadow 0.3s ease, transform 0.3s ease;
}
.jps-thumb-wrap:hover {
    box-shadow: 0 14px 40px rgba(0,0,0,0.14);
    transform: translateY(-3px);
}

.jps-thumb-inner {
    position: relative;
    overflow: hidden;
    aspect-ratio: 4/3;
    background: var(--jps-light);
}
.jps-thumb-inner img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    border-radius: 0 !important;
    margin: 0;
    max-width: none;
    transition: transform 0.5s ease;
}
.jps-thumb-wrap:hover .jps-thumb-inner img { transform: scale(1.04); }

.jps-view-btn {
    background: var(--jps-dark);
    color: var(--jps-white);
    border: none;
    padding: 11px 22px;
    font-size: 13px;
    letter-spacing: 0.5px;
    cursor: pointer;
    font-weight: 700;
    border-radius: 999px;
    white-space: nowrap;
    transition: background 0.2s;
}
.jps-view-btn:hover { background: var(--jps-gold); }

.jps-thumb-caption {
    padding: 22px 24px 24px;
}
.jps-thumb-title { display: block; font-size: 20px; font-weight: 700; color: var(--jps-dark); margin-bottom: 14px; }
.jps-thumb-bottom-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.jps-thumb-price-block { display: flex; flex-direction: column; line-height: 1.1; }
.jps-thumb-from-label { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; color: var(--jps-mid); }
.jps-thumb-from { font-size: 22px; font-weight: 700; color: var(--jps-dark); }

/* ── Digital Gallery (compact card) ── */
.jps-digital-gallery-wrap { max-width: 1100px; margin: 0 auto; }
.jps-digital-gallery-grid {
    column-count: 3;
    column-gap: 22px;
}
@media (max-width: 900px) {
    .jps-digital-gallery-grid { column-count: 2; }
}
@media (max-width: 560px) {
    .jps-digital-gallery-grid { column-count: 1; }
}

.jps-digital-card {
    background: var(--jps-white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 14px rgba(0,0,0,0.08);
    border: 1px solid var(--jps-border);
    display: flex;
    flex-direction: column;
    transition: box-shadow 0.2s, transform 0.2s;
    break-inside: avoid;
    -webkit-column-break-inside: avoid;
    page-break-inside: avoid;
    margin-bottom: 22px;
    width: 100%;
}
.jps-digital-card:hover {
    box-shadow: 0 8px 24px rgba(0,0,0,0.14);
    transform: translateY(-2px);
}
.jps-digital-card-img {
    position: relative;
    padding: 10px 10px 0;
    background: var(--jps-white);
}
/* No fixed aspect-ratio here on purpose — the thumb's height follows the
   photo's own proportions, so portrait shots get a taller card and
   landscape shots get a shorter one (mosaic layout), with no cropping. */
.jps-digital-card-thumb { overflow: hidden; border-radius: 8px; background: var(--jps-light); }
.jps-digital-card-thumb img { width: 100%; height: auto; display: block; border-radius: 0 !important; margin: 0; max-width: none; }
.jps-digital-card-badge {
    position: absolute;
    top: 18px;
    left: 18px;
    background: var(--jps-gold);
    color: var(--jps-white);
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 4px 10px;
    border-radius: 20px;
    z-index: 2;
}
.jps-digital-card-info { padding: 16px 16px 18px; display: flex; flex-direction: column; flex: 1; }
.jps-digital-card-title { font-size: 15px; font-weight: 700; color: var(--jps-dark); margin-bottom: 4px; }
.jps-digital-card-desc {
    font-size: 13px;
    color: var(--jps-mid);
    margin: 0 0 10px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.jps-digital-card-divider { border-top: 1px solid var(--jps-border); margin: 4px 0 12px; }
.jps-digital-card-meta-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 14px;
}
.jps-digital-card-meta-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--jps-mid);
    white-space: nowrap;
}
.jps-digital-size-select {
    flex: 1;
    border: 1.5px solid var(--jps-border);
    border-radius: var(--jps-radius);
    padding: 6px 8px;
    font-size: 13px;
    background: var(--jps-white);
}
.jps-digital-card-bottom-row {
    margin-top: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}
.jps-digital-card-price-block { display: flex; flex-direction: column; line-height: 1.1; }
.jps-digital-card-from {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--jps-mid);
}
.jps-digital-card-price { font-size: 18px; font-weight: 700; color: var(--jps-dark); }
.jps-digital-card-btn {
    background: var(--jps-dark);
    color: var(--jps-white);
    border: none;
    padding: 10px 18px;
    font-size: 13px;
    font-weight: 700;
    border-radius: 999px;
    cursor: pointer;
    white-space: nowrap;
    transition: background 0.2s;
}
.jps-digital-card-btn:hover { background: var(--jps-gold); }
.jps-digital-card-btn:disabled { background: #aaa; cursor: not-allowed; }
.jps-digital-license-note { font-size: 12px; color: var(--jps-mid); text-align: center; margin: 22px 0 0; }

.jps-digital-card-open { cursor: pointer; }

/* ── Digital Gallery: Search / Filter Bar ── */
.jps-digital-filter-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 10px;
    padding: 14px 16px;
    background: var(--jps-light);
    border: 1px solid var(--jps-border);
    border-radius: var(--jps-radius);
}
.jps-digital-filter-search { flex: 1 1 220px; min-width: 180px; }
.jps-digital-filter-search input[type="text"] {
    width: 100%;
    border: 1.5px solid var(--jps-border);
    border-radius: var(--jps-radius);
    padding: 9px 12px;
    font-size: 14px;
    background: var(--jps-white);
}
.jps-digital-filter-search input[type="text"]:focus { outline: none; border-color: var(--jps-gold); }
.jps-digital-filter-selects { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.jps-digital-filter-selects select {
    border: 1.5px solid var(--jps-border);
    border-radius: var(--jps-radius);
    padding: 8px 10px;
    font-size: 13px;
    background: var(--jps-white);
    color: var(--jps-dark);
}
.jps-digital-filter-clear {
    background: transparent;
    border: 1.5px solid var(--jps-border);
    border-radius: var(--jps-radius);
    padding: 8px 14px;
    font-size: 13px;
    font-weight: 700;
    color: var(--jps-mid);
    cursor: pointer;
    transition: border-color 0.2s, color 0.2s;
    white-space: nowrap;
}
.jps-digital-filter-clear:hover { border-color: var(--jps-gold); color: var(--jps-dark); }

.jps-digital-results-count { font-size: 13px; color: var(--jps-mid); margin: 0 0 16px; min-height: 18px; }

#jps-digital-gallery-results { transition: opacity 0.15s; }
#jps-digital-gallery-results.jps-loading { opacity: 0.45; pointer-events: none; }

/* ── Digital Gallery: Pagination ── */
.jps-digital-pagination {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin: 30px 0 6px;
}
.jps-digital-page-btn {
    background: var(--jps-white);
    border: 1.5px solid var(--jps-border);
    border-radius: var(--jps-radius);
    padding: 7px 13px;
    font-size: 13px;
    font-weight: 700;
    color: var(--jps-dark);
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s, color 0.2s;
    min-width: 38px;
}
.jps-digital-page-btn:hover:not(:disabled) { border-color: var(--jps-gold); }
.jps-digital-page-btn.is-active { background: var(--jps-dark); border-color: var(--jps-dark); color: var(--jps-white); cursor: default; }
.jps-digital-page-btn:disabled { color: #bbb; cursor: not-allowed; }
.jps-digital-page-ellipsis { color: var(--jps-mid); font-size: 13px; padding: 0 4px; }

@media (max-width: 560px) {
    .jps-digital-filter-bar { flex-direction: column; align-items: stretch; }
    .jps-digital-filter-selects { justify-content: space-between; }
}

.jps-digital-lightbox-inner { max-width: 900px; }
.jps-digital-lightbox-img-panel {
    position: relative;
    flex: 1;
    background: #e8e5e0;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 0;
    padding: 30px 20px;
}
.jps-digital-lightbox-frame {
    display: inline-flex;
    background: var(--jps-white);
    border: 16px solid var(--jps-white);
    box-shadow: 0 4px 24px rgba(0,0,0,0.2);
}
.jps-digital-lightbox-frame img {
    display: block;
    max-width: 420px;
    max-height: 420px;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 0 !important;
    margin: 0;
}
.jps-digital-lightbox-badge { position: absolute; top: 14px; left: 14px; }
.jps-digital-lightbox-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.88);
    cursor: pointer;
}
@media (max-width: 768px) {
    .jps-digital-lightbox-img-panel { max-height: 45vh; }
    .jps-digital-lightbox-frame img { max-width: 280px; max-height: 280px; }
}

/* ── Cart Bubble ── */
.jps-cart-bubble {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: var(--jps-dark);
    color: var(--jps-white);
    border-radius: 50px;
    padding: 12px 20px;
    display: flex;
    align-items: center;
    gap: 8px;
    z-index: 9000;
    box-shadow: var(--jps-shadow);
    text-decoration: none;
    font-size: 14px;
}
.jps-cart-bubble:hover { background: var(--jps-gold); }
.jps-cart-count {
    background: var(--jps-gold);
    color: var(--jps-white);
    border-radius: 50%;
    width: 22px;
    height: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
}
.jps-cart-bubble-link {
    color: var(--jps-white);
    text-decoration: none;
    font-weight: 600;
    font-size: 13px;
    letter-spacing: 0.5px;
}

/* ── Lightbox ── */
.jps-lightbox {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
}
.jps-lightbox-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.88);
    cursor: pointer;
}
.jps-lightbox-inner {
    position: relative;
    z-index: 1;
    display: flex;
    background: var(--jps-white);
    max-width: 1000px;
    width: 95vw;
    max-height: 92vh;
    overflow: hidden;
    box-shadow: 0 24px 80px rgba(0,0,0,0.5);
}
.jps-lightbox-close {
    position: absolute;
    top: 14px;
    right: 18px;
    background: none;
    border: none;
    font-size: 28px;
    color: var(--jps-mid);
    cursor: pointer;
    z-index: 10;
    line-height: 1;
    padding: 0;
}
.jps-lightbox-close:hover { color: var(--jps-black); }

/* ── Frame Visualizer ── */
.jps-visualizer-panel {
    flex: 1;
    background: #e8e5e0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 30px 20px 20px;
    min-width: 0;
}

.jps-visualizer-stage {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
}

.jps-frame-wrap {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.35s ease;
    background: var(--jps-white);
}

/* Print Only: simple thin border */
.jps-frame-wrap.frame-print_only {
    border: 16px solid var(--jps-white);
    box-shadow: 0 4px 24px rgba(0,0,0,0.2);
}
/* Black Wood Frame */
.jps-frame-wrap.frame-black_wood {
    border: 22px solid var(--jps-frame-black);
    box-shadow: inset 0 0 0 3px #3a3a3a, 0 8px 40px rgba(0,0,0,0.4);
}
/* Brown Wood Frame */
.jps-frame-wrap.frame-brown_wood {
    border: 22px solid var(--jps-frame-brown);
    box-shadow: inset 0 0 0 3px #7a5030, 0 8px 40px rgba(0,0,0,0.35);
}

.jps-mat-border {
    background: var(--jps-mat);
    padding: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.jps-print-img {
    display: block;
    max-width: 320px;
    max-height: 320px;
    width: 100%;
    height: auto;
    object-fit: contain;
    border-radius: 0 !important;
    margin: 0;
}

/* Frame selector tabs */
.jps-frame-tabs {
    display: flex;
    gap: 8px;
    margin-top: 16px;
    flex-wrap: wrap;
    justify-content: center;
}
.jps-frame-tab {
    background: rgba(255,255,255,0.7);
    border: 1px solid var(--jps-border);
    padding: 6px 14px;
    font-size: 12px;
    cursor: pointer;
    border-radius: 2px;
    transition: all 0.2s;
}
.jps-frame-tab.active,
.jps-frame-tab:hover {
    background: var(--jps-dark);
    color: var(--jps-white);
    border-color: var(--jps-dark);
}

/* ── Product Panel ── */
.jps-product-panel {
    width: 320px;
    flex-shrink: 0;
    padding: 30px 28px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 0;
}

.jps-product-title {
    font-size: 20px;
    font-weight: 700;
    color: var(--jps-dark);
    margin: 0 0 8px;
    line-height: 1.3;
}
.jps-product-desc {
    font-size: 13px;
    color: var(--jps-mid);
    margin: 0 0 20px;
    line-height: 1.5;
}

.jps-option-group { margin-bottom: 18px; }

.jps-option-label {
    display: block;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    color: var(--jps-mid);
    margin-bottom: 8px;
}

/* Size buttons */
.jps-size-options,
.jps-frame-options {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.jps-size-btn,
.jps-frame-btn {
    background: var(--jps-white);
    border: 1.5px solid var(--jps-border);
    padding: 8px 12px;
    font-size: 12px;
    cursor: pointer;
    border-radius: var(--jps-radius);
    transition: all 0.2s;
    white-space: nowrap;
}
.jps-size-btn:hover,
.jps-frame-btn:hover {
    border-color: var(--jps-dark);
    color: var(--jps-dark);
}
.jps-size-btn.active,
.jps-frame-btn.active {
    background: var(--jps-dark);
    color: var(--jps-white);
    border-color: var(--jps-dark);
}

/* Price */
.jps-price-display {
    font-size: 28px;
    font-weight: 700;
    color: var(--jps-dark);
    margin: 4px 0 12px;
    letter-spacing: -0.5px;
}
.jps-currency { font-size: 18px; margin-right: 2px; }

/* Note */
.jps-note {
    font-size: 12px;
    color: var(--jps-mid);
    background: var(--jps-light);
    padding: 10px 12px;
    border-radius: var(--jps-radius);
    margin-bottom: 16px;
    display: flex;
    gap: 6px;
    align-items: flex-start;
    line-height: 1.5;
}

/* Qty */
.jps-qty-row {
    margin-bottom: 18px;
    display: flex;
    align-items: center;
    gap: 12px;
}
.jps-qty-row .jps-option-label { margin: 0; }
.jps-qty-control {
    display: flex;
    align-items: center;
    border: 1.5px solid var(--jps-border);
    border-radius: var(--jps-radius);
    overflow: hidden;
}
.jps-qty-btn {
    background: var(--jps-light);
    border: none;
    width: 34px;
    height: 34px;
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}
.jps-qty-btn:hover { background: var(--jps-border); }
#jps-qty-input {
    width: 50px;
    text-align: center;
    border: none;
    border-left: 1.5px solid var(--jps-border);
    border-right: 1.5px solid var(--jps-border);
    height: 34px;
    font-size: 15px;
    -moz-appearance: textfield;
}
#jps-qty-input::-webkit-outer-spin-button,
#jps-qty-input::-webkit-inner-spin-button { -webkit-appearance: none; }

/* Add to Cart */
.jps-add-to-cart-btn {
    width: 100%;
    background: var(--jps-dark);
    color: var(--jps-white);
    border: none;
    padding: 14px;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    cursor: pointer;
    border-radius: var(--jps-radius);
    transition: background 0.2s;
    margin-bottom: 10px;
}
.jps-add-to-cart-btn:hover { background: var(--jps-gold); }
.jps-add-to-cart-btn:disabled { background: #aaa; cursor: not-allowed; }

.jps-cart-feedback {
    padding: 10px 14px;
    border-radius: var(--jps-radius);
    font-size: 13px;
    text-align: center;
}
.jps-cart-feedback.success { background: #e8f5e9; color: #2e7d32; }
.jps-cart-feedback.error   { background: #fdecea; color: #c62828; }

/* ── Checkout ── */
.jps-checkout-wrap { max-width: 1000px; margin: 0 auto; padding: 20px 0; }

.jps-checkout-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    align-items: start;
}
@media (max-width: 768px) {
    .jps-checkout-layout { grid-template-columns: 1fr; }
    .jps-lightbox-inner { flex-direction: column; }
    .jps-product-panel { width: 100%; }
}

.jps-checkout-section-title {
    font-size: 16px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: var(--jps-dark);
    border-bottom: 2px solid var(--jps-dark);
    padding-bottom: 10px;
    margin-bottom: 20px;
}

/* Cart items */
.jps-cart-item {
    display: flex;
    gap: 14px;
    padding: 14px 0;
    border-bottom: 1px solid var(--jps-border);
    align-items: flex-start;
}
.jps-cart-item-thumb img {
    width: 72px;
    height: 54px;
    object-fit: cover;
    border: 4px solid var(--jps-white);
    box-shadow: 0 2px 8px rgba(0,0,0,0.12);
}
.jps-cart-item-details { flex: 1; }
.jps-cart-item-title   { font-weight: 600; font-size: 14px; margin-bottom: 4px; }
.jps-cart-item-meta    { font-size: 12px; color: var(--jps-mid); margin-bottom: 4px; }
.jps-cart-item-price   { font-size: 13px; color: var(--jps-mid); margin-bottom: 8px; }
.jps-cart-item-subtotal { font-weight: 700; font-size: 15px; white-space: nowrap; }

.jps-cart-item-qty-row { display: flex; gap: 6px; align-items: center; }
.jps-qty-sm {
    background: var(--jps-light);
    border: 1px solid var(--jps-border);
    width: 26px;
    height: 26px;
    cursor: pointer;
    font-size: 15px;
    border-radius: 2px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.jps-qty-display  { font-size: 14px; min-width: 20px; text-align: center; }
.jps-remove-item  { background: none; border: none; color: #c62828; font-size: 12px; cursor: pointer; text-decoration: underline; }

/* Totals */
.jps-order-totals { margin-top: 20px; }
.jps-total-row {
    display: flex;
    justify-content: space-between;
    padding: 6px 0;
    font-size: 14px;
    color: var(--jps-mid);
}
.jps-grand-total {
    font-size: 18px;
    font-weight: 700;
    color: var(--jps-dark);
    border-top: 2px solid var(--jps-dark);
    margin-top: 6px;
    padding-top: 10px;
}
.jps-free-shipping { color: #2e7d32; font-weight: 600; }
.jps-free-ship-note { font-size: 12px; color: var(--jps-mid); margin-top: 6px; text-align: right; }

/* Form */
.jps-form-group { margin-bottom: 16px; }
.jps-form-group label { display: block; font-size: 12px; font-weight: 600; letter-spacing: 0.5px; color: var(--jps-mid); margin-bottom: 5px; text-transform: uppercase; }
.jps-form-group input,
.jps-form-group select,
.jps-form-group textarea {
    width: 100%;
    border: 1.5px solid var(--jps-border);
    padding: 10px 12px;
    font-size: 14px;
    border-radius: var(--jps-radius);
    box-sizing: border-box;
    transition: border-color 0.2s;
}
.jps-form-group input:focus,
.jps-form-group select:focus,
.jps-form-group textarea:focus {
    outline: none;
    border-color: var(--jps-dark);
}
.req { color: #c62828; }

.jps-form-row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.jps-form-row-3 { display: grid; grid-template-columns: 2fr 1fr 1.5fr; gap: 16px; }
@media (max-width: 600px) {
    .jps-form-row-2,
    .jps-form-row-3 { grid-template-columns: 1fr; }
}

.jps-form-error {
    background: #fdecea;
    color: #c62828;
    padding: 12px 14px;
    border-radius: var(--jps-radius);
    font-size: 13px;
    margin-bottom: 14px;
}

.jps-pay-btn {
    width: 100%;
    background: var(--jps-dark);
    color: var(--jps-white);
    border: none;
    padding: 18px 20px;
    font-size: 17px;
    font-weight: 700;
    cursor: pointer;
    border-radius: 999px;
    transition: background 0.2s, transform 0.15s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 14px;
    box-shadow: 0 6px 18px rgba(0,0,0,0.18);
}
.jps-pay-btn:hover  { background: var(--jps-gold); transform: translateY(-1px); }
.jps-pay-btn:disabled { background: #aaa; cursor: not-allowed; transform: none; }

.jps-payment-note {
    font-size: 12px;
    color: var(--jps-mid);
    text-align: center;
    line-height: 1.5;
}

/* ── Order summary sidebar card ── */
.jps-order-summary-card {
    background: var(--jps-white);
    border: 1px solid var(--jps-border);
    border-radius: 12px;
    box-shadow: 0 2px 14px rgba(0,0,0,0.08);
    padding: 24px;
    margin-top: 24px;
    position: sticky;
    top: 20px;
}
.jps-summary-caption {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--jps-mid);
    text-align: center;
}
.jps-summary-price {
    font-size: 30px;
    font-weight: 700;
    color: var(--jps-dark);
    text-align: center;
    margin: 4px 0 2px;
}
.jps-summary-sub {
    font-size: 12px;
    color: var(--jps-mid);
    text-align: center;
    margin-bottom: 4px;
}
.jps-summary-divider { border-top: 1px solid var(--jps-border); margin: 16px 0; }
.jps-payment-badges {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
}
.jps-pay-logo {
    width: 52px;
    height: auto;
    border-radius: 6px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.15);
}
.jps-discount-amount { color: #2e7d32; font-weight: 600; }
.jps-promo-row {
    display: flex;
    gap: 8px;
    align-items: center;
    margin: 10px 0;
}
#jps-promo-input {
    flex: 1;
    border: 1.5px solid var(--jps-border);
    border-radius: var(--jps-radius);
    padding: 8px 10px;
    font-size: 13px;
    text-transform: uppercase;
}
.jps-promo-btn {
    background: var(--jps-dark);
    color: var(--jps-white);
    border: none;
    border-radius: var(--jps-radius);
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
}
.jps-promo-btn:hover { background: var(--jps-gold); }
.jps-promo-applied-label { font-size: 13px; color: #2e7d32; font-weight: 600; flex: 1; }
.jps-promo-remove-btn {
    background: none;
    border: none;
    color: #c62828;
    font-size: 12px;
    text-decoration: underline;
    cursor: pointer;
}
.jps-promo-error { font-size: 12px; color: #c62828; margin: 4px 0 10px; }

/* Thank you */
.jps-thankyou-wrap { max-width: 560px; margin: 60px auto; text-align: center; padding: 20px; }
.jps-ty-icon { font-size: 56px; margin-bottom: 16px; }
.jps-ty-order-number { background: var(--jps-light); padding: 12px 20px; border-radius: var(--jps-radius); display: inline-block; margin: 14px 0; font-size: 15px; }
.jps-ty-spam-note { font-size: 12px; color: var(--jps-mid); margin-top: -6px; }

.jps-ty-downloads {
    background: var(--jps-white);
    border: 1px solid var(--jps-border);
    border-radius: 12px;
    box-shadow: 0 2px 14px rgba(0,0,0,0.08);
    padding: 20px 24px;
    margin: 20px 0;
    text-align: left;
}
.jps-ty-downloads h3 { margin: 0 0 14px; font-size: 15px; text-transform: uppercase; letter-spacing: 0.5px; color: var(--jps-dark); }
.jps-ty-download-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px solid var(--jps-border);
}
.jps-ty-download-row:last-of-type { border-bottom: none; }
.jps-ty-download-title { font-size: 14px; color: var(--jps-dark); }
.jps-ty-download-btn { margin: 0; padding: 8px 18px; font-size: 13px; border-radius: 999px; white-space: nowrap; }
.jps-ty-download-note { font-size: 12px; color: var(--jps-mid); margin: 14px 0 0; }
.jps-ty-download-note a { color: var(--jps-dark); }

.jps-btn-primary {
    display: inline-block;
    background: var(--jps-dark);
    color: var(--jps-white);
    padding: 12px 28px;
    text-decoration: none;
    font-weight: 600;
    border-radius: var(--jps-radius);
    margin-top: 16px;
}
.jps-btn-primary:hover { background: var(--jps-gold); color: var(--jps-white); }

/* Empty states */
.jps-empty-cart { text-align: center; padding: 60px 20px; }
.jps-empty-icon { font-size: 48px; margin-bottom: 16px; }
.jps-no-photos  { color: var(--jps-mid); padding: 20px; }

/* Cart widget */
.jps-cart-widget { display: inline-block; }
.jps-cart-widget-link {
    display: flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
    color: inherit;
    font-size: 14px;
}
.jps-cart-widget-count {
    background: var(--jps-dark);
    color: var(--jps-white);
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 700;
}
