/* AutoShop — Mobile-first RWD storefront */

:root {
    --shop-primary: #e45c3a;
    --shop-primary-dark: #c94a2b;
    --shop-accent: #1b6b5a;
    --shop-bg: #f5f3ef;
    --shop-surface: #ffffff;
    --shop-text: #1a1a1a;
    --shop-muted: #6b7280;
    --shop-border: #e8e4dd;
    --shop-radius: 14px;
    --shop-radius-sm: 10px;
    --shop-shadow: 0 8px 28px rgba(26, 26, 26, 0.06);
    --shop-header-h: 64px;
    --shop-utility-h: 40px;
    --shop-cat-h: 44px;
    --shop-bottom-nav-h: 62px;
    --shop-max: 1200px;
    --shop-font: "Noto Sans TC", "Microsoft JhengHei", system-ui, sans-serif;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
}

body.shop-body {
    margin: 0;
    font-family: var(--shop-font);
    font-size: 16px;
    line-height: 1.55;
    color: var(--shop-text);
    background: var(--shop-bg);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
}

button,
input {
    font: inherit;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

.shop-theme-dark .shop-header,
.shop-theme-dark .shop-cat-bar,
.shop-theme-dark .shop-bottom-nav {
    background: rgba(30, 41, 59, 0.96);
}

.shop-theme-dark .shop-search {
    background: #0f172a;
}

.shop-theme-dark .shop-search input {
    color: var(--shop-text);
}

.shop-theme-dark .rich-text {
    color: #cbd5e1;
}

.shop-theme-dark .product-sticky-bar {
    background: rgba(30, 41, 59, 0.96);
}

/* Header */
.shop-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--shop-border);
}

.shop-header-inner {
    max-width: var(--shop-max);
    margin: 0 auto;
    padding: 10px 14px;
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 10px;
    align-items: center;
}

.shop-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}

.shop-brand-mark {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--shop-primary), #f39b72);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 13px;
    flex-shrink: 0;
}

.shop-brand-text {
    display: none;
    flex-direction: column;
    min-width: 0;
}

.shop-brand-text strong {
    font-size: 15px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.shop-brand-text small {
    font-size: 11px;
    color: var(--shop-muted);
}

.shop-search {
    display: flex;
    align-items: center;
    background: var(--shop-bg);
    border: 1px solid var(--shop-border);
    border-radius: 999px;
    padding: 4px 6px 4px 14px;
    min-width: 0;
}

.shop-search input {
    border: 0;
    background: transparent;
    flex: 1;
    min-width: 0;
    outline: none;
    font-size: 15px;
}

.shop-search button {
    width: 36px;
    height: 36px;
    border: 0;
    border-radius: 50%;
    background: var(--shop-primary);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.shop-cart-btn {
    position: relative;
    width: 42px;
    height: 42px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--shop-surface);
    border: 1px solid var(--shop-border);
}

.shop-cart-count,
.shop-bottom-cart {
    position: absolute;
    top: -4px;
    right: -4px;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    border-radius: 999px;
    background: var(--shop-primary);
    color: #fff;
    font-size: 11px;
    font-style: normal;
    font-weight: 700;
    display: none;
    align-items: center;
    justify-content: center;
}

.shop-cart-count.has-items,
.shop-bottom-cart.has-items {
    display: inline-flex;
}

/* Category bar */
.shop-cat-bar {
    position: sticky;
    top: var(--shop-header-h);
    z-index: 90;
    background: var(--shop-surface);
    border-bottom: 1px solid var(--shop-border);
}

.shop-cat-scroll {
    max-width: var(--shop-max);
    margin: 0 auto;
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding: 10px 14px;
    scrollbar-width: none;
}

.shop-cat-scroll::-webkit-scrollbar {
    display: none;
}

.shop-cat-chip,
.subcat-chip {
    flex-shrink: 0;
    padding: 8px 14px;
    border-radius: 999px;
    background: var(--shop-bg);
    border: 1px solid transparent;
    font-size: 14px;
    color: var(--shop-muted);
    white-space: nowrap;
}

.shop-cat-chip.is-active,
.subcat-chip.is-active {
    background: rgba(228, 92, 58, 0.12);
    color: var(--shop-primary-dark);
    border-color: rgba(228, 92, 58, 0.25);
    font-weight: 600;
}

/* Main */
.shop-main {
    max-width: var(--shop-max);
    margin: 0 auto;
    padding: 16px 14px calc(var(--shop-bottom-nav-h) + 24px);
}

/* Hero */
.hero {
    position: relative;
    overflow: hidden;
    border-radius: calc(var(--shop-radius) + 4px);
    background: var(--shop-hero-bg, linear-gradient(135deg, #fff7f3 0%, #ffffff 55%, #eef7f4 100%));
    border: 1px solid var(--shop-border);
    padding: 28px 22px;
    margin-bottom: 24px;
    min-height: 220px;
}

.hero--image {
    background-image: linear-gradient(120deg, rgba(0, 0, 0, 0.45), rgba(0, 0, 0, 0.15)), var(--hero-image);
    background-size: cover;
    background-position: center;
    color: #fff;
}

.hero--image .hero-eyebrow,
.hero--image p,
.hero--image h1 {
    color: #fff;
    text-shadow: 0 1px 8px rgba(0, 0, 0, 0.35);
}

.hero--image .btn-ghost {
    border-color: rgba(255, 255, 255, 0.65);
    color: #fff;
    background: rgba(255, 255, 255, 0.08);
}

.hero-eyebrow {
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--shop-accent);
    font-weight: 600;
    margin: 0 0 8px;
}

.hero h1 {
    margin: 0 0 10px;
    font-size: clamp(24px, 5vw, 34px);
    line-height: 1.2;
}

.hero p {
    margin: 0 0 18px;
    color: var(--shop-muted);
    max-width: 36ch;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.hero-visual {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.hero-blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(40px);
    opacity: 0.45;
}

.hero-blob-a {
    width: 180px;
    height: 180px;
    background: var(--shop-hero-blob-a, #f9a88f);
    top: -40px;
    right: -20px;
}

.hero-blob-b {
    width: 140px;
    height: 140px;
    background: var(--shop-hero-blob-b, #8fd4c5);
    bottom: -30px;
    right: 30%;
}

/* Sections */
.section {
    margin-bottom: 28px;
}

.section-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.section-head h2 {
    margin: 0;
    font-size: 20px;
}

.section-link {
    color: var(--shop-primary);
    font-size: 14px;
    font-weight: 600;
}

.page-head h1 {
    margin: 0 0 6px;
    font-size: 24px;
}

.page-meta {
    margin: 0 0 16px;
    color: var(--shop-muted);
    font-size: 14px;
}

.subcat-row {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    margin-bottom: 16px;
    padding-bottom: 4px;
}

/* Category grid */
.category-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.category-tile {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px;
    background: var(--shop-surface);
    border: 1px solid var(--shop-border);
    border-radius: var(--shop-radius);
    box-shadow: var(--shop-shadow);
    font-weight: 500;
}

.category-tile-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: rgba(27, 107, 90, 0.1);
    color: var(--shop-accent);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
}

/* Product grid */
.product-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.product-card {
    position: relative;
    background: var(--shop-surface);
    border: 1px solid var(--shop-border);
    border-radius: var(--shop-radius);
    overflow: hidden;
    box-shadow: var(--shop-shadow);
}

.product-card-link {
    display: block;
}

.product-card-media {
    position: relative;
    aspect-ratio: 1 / 1;
    background: #f0eeea;
    overflow: hidden;
}

.product-card-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-card-body {
    padding: 10px 12px 12px;
}

.product-card-title {
    margin: 0 0 8px;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 2.8em;
}

.product-card-price strong {
    color: var(--shop-primary-dark);
    font-size: 16px;
}

.product-card-price del {
    margin-left: 6px;
    color: var(--shop-muted);
    font-size: 12px;
}

.product-card-add {
    position: absolute;
    right: 10px;
    bottom: 10px;
    width: 34px;
    height: 34px;
    border: 0;
    border-radius: 50%;
    background: var(--shop-primary);
    color: #fff;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(228, 92, 58, 0.35);
}

.product-badge {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 600;
}

.product-card-media .product-badge {
    position: absolute;
    top: 8px;
    left: 8px;
}

.badge-hot {
    background: #fee2e2;
    color: #b91c1c;
}

.badge-stock {
    background: #dcfce7;
    color: #166534;
}

.badge-muted {
    background: #f3f4f6;
    color: #6b7280;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 18px;
    border-radius: 12px;
    border: 1px solid transparent;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.15s ease, background 0.15s ease;
}

.btn:active {
    transform: scale(0.98);
}

.btn-primary {
    background: var(--shop-primary);
    color: #fff;
}

.btn-primary:hover {
    background: var(--shop-primary-dark);
}

.btn-ghost {
    background: transparent;
    border-color: var(--shop-border);
    color: var(--shop-text);
}

.btn-block {
    width: 100%;
}

/* Product detail */
.product-detail {
    margin: -4px -14px 0;
}

.product-gallery {
    background: var(--shop-surface);
    border-bottom: 1px solid var(--shop-border);
}

.gallery-track {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
}

.gallery-track::-webkit-scrollbar {
    display: none;
}

.gallery-slide {
    flex: 0 0 100%;
    scroll-snap-align: start;
    aspect-ratio: 1 / 1;
    background: #f0eeea;
}

.gallery-slide img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.gallery-dots {
    display: flex;
    justify-content: center;
    gap: 6px;
    padding: 10px;
}

.gallery-dots span {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #d1d5db;
}

.gallery-dots span.is-active {
    background: var(--shop-primary);
    width: 18px;
    border-radius: 999px;
}

.product-summary,
.product-section {
    padding: 18px 16px;
    background: var(--shop-surface);
    border-bottom: 8px solid var(--shop-bg);
}

.product-title {
    margin: 8px 0 6px;
    font-size: 22px;
    line-height: 1.35;
}

.product-sku {
    margin: 0;
    color: var(--shop-muted);
    font-size: 13px;
}

.product-price-row {
    display: flex;
    align-items: baseline;
    gap: 10px;
    margin-top: 12px;
}

.product-price {
    font-size: 28px;
    color: var(--shop-primary-dark);
}

.product-price-row del {
    color: var(--shop-muted);
}

.product-ship {
    margin: 10px 0 0;
    padding: 8px 12px;
    background: #fff7ed;
    border-radius: var(--shop-radius-sm);
    color: #9a3412;
    font-size: 14px;
}

.product-section h2 {
    margin: 0 0 12px;
    font-size: 18px;
}

.rich-text {
    font-size: 15px;
    color: #374151;
    word-break: break-word;
}

.rich-text img {
    border-radius: var(--shop-radius-sm);
    margin: 8px 0;
}

.product-sticky-bar {
    position: sticky;
    bottom: calc(var(--shop-bottom-nav-h) + 8px);
    z-index: 80;
    margin: 0 14px;
    padding: 12px;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(8px);
    border: 1px solid var(--shop-border);
    border-radius: var(--shop-radius);
    box-shadow: var(--shop-shadow);
    display: grid;
    grid-template-columns: 1fr 1.4fr;
    gap: 12px;
    align-items: center;
}

.sticky-price small {
    display: block;
    color: var(--shop-muted);
    font-size: 12px;
}

.sticky-price strong {
    font-size: 20px;
    color: var(--shop-primary-dark);
}

/* Cart */
.cart-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.cart-item {
    display: grid;
    grid-template-columns: 72px 1fr auto;
    gap: 12px;
    padding: 12px;
    background: var(--shop-surface);
    border: 1px solid var(--shop-border);
    border-radius: var(--shop-radius);
}

.cart-item img {
    width: 72px;
    height: 72px;
    object-fit: cover;
    border-radius: var(--shop-radius-sm);
}

.cart-item-title {
    margin: 0 0 4px;
    font-size: 14px;
    font-weight: 600;
}

.cart-item-meta {
    margin: 0;
    color: var(--shop-muted);
    font-size: 13px;
}

.cart-item-actions {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 8px;
}

.qty-control {
    display: flex;
    align-items: center;
    gap: 8px;
    border: 1px solid var(--shop-border);
    border-radius: 999px;
    padding: 2px;
}

.qty-control button {
    width: 30px;
    height: 30px;
    border: 0;
    border-radius: 50%;
    background: var(--shop-bg);
    cursor: pointer;
}

.cart-summary {
    margin-top: 16px;
    padding: 16px;
    background: var(--shop-surface);
    border-radius: var(--shop-radius);
    border: 1px solid var(--shop-border);
}

.cart-total-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    font-size: 18px;
}

.search-page-form {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
}

.search-page-form input {
    flex: 1;
    min-height: 44px;
    border: 1px solid var(--shop-border);
    border-radius: 12px;
    padding: 0 14px;
    background: var(--shop-surface);
}

/* Pagination */
.shop-pagination {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 24px;
}

.page-btn,
.page-num {
    min-width: 40px;
    min-height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    border: 1px solid var(--shop-border);
    background: var(--shop-surface);
    font-size: 14px;
}

.page-num.is-current {
    background: var(--shop-primary);
    border-color: var(--shop-primary);
    color: #fff;
    font-weight: 700;
}

/* Trust strip */
.trust-strip {
    display: grid;
    gap: 10px;
    margin-top: 8px;
}

.trust-item {
    padding: 14px 16px;
    background: var(--shop-surface);
    border: 1px solid var(--shop-border);
    border-radius: var(--shop-radius);
}

.trust-item strong {
    display: block;
    margin-bottom: 2px;
}

.trust-item span {
    color: var(--shop-muted);
    font-size: 14px;
}

.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: var(--shop-muted);
}

.empty-state-lg h1 {
    color: var(--shop-text);
}

/* Footer */
.shop-footer {
    max-width: var(--shop-max);
    margin: 0 auto;
    padding: 24px 14px calc(var(--shop-bottom-nav-h) + 16px);
    color: var(--shop-muted);
    font-size: 14px;
}

.shop-footer-inner p {
    margin: 0 0 8px;
}

.shop-footer-copy {
    margin-top: 8px;
    font-size: 12px;
    color: var(--shop-muted);
}

.shop-footer-service {
    display: none;
    flex-direction: column;
    gap: 10px;
    margin-top: 18px;
    padding-top: 16px;
    border-top: 1px solid var(--shop-border);
    font-size: 14px;
}

.shop-footer-service-title {
    margin: 0;
    font-weight: 700;
    color: var(--shop-text);
}

.shop-footer-service-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 18px;
}

.shop-footer-service-links a {
    color: var(--shop-text);
    text-decoration: none;
}

.shop-footer-service-links a:hover {
    color: var(--shop-primary);
}

/* Mobile service sheet */
.shop-service-sheet {
    position: fixed;
    inset: 0;
    z-index: 200;
    pointer-events: none;
    visibility: hidden;
}

.shop-service-sheet.is-open {
    pointer-events: auto;
    visibility: visible;
}

.shop-service-sheet-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.45);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.shop-service-sheet.is-open .shop-service-sheet-backdrop {
    opacity: 1;
}

.shop-service-sheet-panel {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    max-height: min(70vh, 420px);
    background: var(--shop-surface);
    border-radius: 16px 16px 0 0;
    border-top: 1px solid var(--shop-border);
    padding: 16px 16px calc(16px + env(safe-area-inset-bottom));
    transform: translateY(100%);
    transition: transform 0.25s ease;
    box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.12);
}

.shop-service-sheet.is-open .shop-service-sheet-panel {
    transform: translateY(0);
}

.shop-service-sheet-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--shop-border);
}

.shop-service-sheet-close {
    border: 0;
    background: transparent;
    font-size: 20px;
    line-height: 1;
    padding: 4px 8px;
    color: var(--shop-muted);
    cursor: pointer;
}

.shop-service-sheet-nav {
    display: flex;
    flex-direction: column;
    gap: 4px;
    overflow-y: auto;
}

.shop-service-sheet-link {
    display: block;
    padding: 14px 12px;
    border-radius: 10px;
    color: var(--shop-text);
    text-decoration: none;
    font-size: 16px;
}

.shop-service-sheet-link:hover,
.shop-service-sheet-link.is-active {
    background: rgba(228, 92, 58, 0.1);
    color: var(--shop-primary-dark);
}

body.shop-service-sheet-open {
    overflow: hidden;
}

.shop-info-page {
    max-width: var(--shop-max);
    margin: 0 auto;
    padding: 8px 14px 32px;
}

.shop-info-body {
    line-height: 1.7;
}

.shop-info-body h2 {
    font-size: 18px;
    margin: 1.25em 0 0.5em;
}

.shop-info-callout {
    padding: 12px 14px;
    border-radius: 10px;
    background: rgba(228, 92, 58, 0.08);
    border: 1px solid rgba(228, 92, 58, 0.2);
}

.shop-info-back {
    margin-top: 24px;
}

.shop-rich-text ul,
.shop-rich-text ol {
    padding-left: 1.25em;
}

/* Bottom nav (mobile) */
.shop-bottom-nav {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 120;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(10px);
    border-top: 1px solid var(--shop-border);
    padding: 6px 8px calc(6px + env(safe-area-inset-bottom));
}

.shop-bottom-nav-btn {
    appearance: none;
    border: 0;
    background: transparent;
    font: inherit;
    width: 100%;
    cursor: pointer;
}

.shop-footer-brand {
    color: var(--shop-text);
    font-weight: 700;
    font-size: 16px;
}

.shop-bottom-nav a,
.shop-bottom-nav-btn {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding: 6px 4px;
    font-size: 11px;
    color: var(--shop-muted);
}

.shop-bottom-nav a.is-active,
.shop-bottom-nav-btn.is-active {
    color: var(--shop-primary-dark);
    font-weight: 600;
}

.shop-bottom-nav span:first-child,
.shop-bottom-nav-btn span:first-child {
    font-size: 18px;
    line-height: 1;
}

/* Toast */
.shop-toast {
    position: fixed;
    left: 50%;
    bottom: calc(var(--shop-bottom-nav-h) + 20px);
    transform: translateX(-50%) translateY(20px);
    opacity: 0;
    pointer-events: none;
    background: rgba(26, 26, 26, 0.92);
    color: #fff;
    padding: 12px 18px;
    border-radius: 999px;
    font-size: 14px;
    z-index: 200;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.shop-toast.is-visible {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* Tablet */
@media (min-width: 640px) {
    .shop-brand-text {
        display: flex;
    }

    .category-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .product-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 16px;
    }

    .trust-strip {
        grid-template-columns: repeat(3, 1fr);
    }

    .product-detail {
        margin: 0;
    }

    .product-sticky-bar {
        margin: 16px 0 0;
        max-width: 480px;
    }
}

/* Desktop */
@media (min-width: 1024px) {
    .shop-header-inner {
        padding: 12px 20px;
    }

    .shop-main {
        padding: 24px 20px 40px;
    }

    .shop-bottom-nav {
        display: none;
    }

    .shop-footer {
        padding-bottom: 32px;
    }

    .shop-footer-service--desktop {
        display: flex;
    }

    .product-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .hero {
        display: grid;
        grid-template-columns: 1.2fr 0.8fr;
        align-items: center;
        min-height: 280px;
        padding: 36px 40px;
    }

    .product-detail {
        display: grid;
        grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
        gap: 24px;
        align-items: start;
    }

    .product-gallery,
    .product-summary,
    .product-section {
        border-radius: var(--shop-radius);
        border: 1px solid var(--shop-border);
        margin-bottom: 0;
    }

    .product-gallery {
        grid-row: span 3;
    }

    .product-sticky-bar {
        position: static;
        grid-column: 2;
    }
}

/* ── 分銷標籤 / LINE / 結帳 ── */
.shop-dist-tag {
    display: inline-block;
    margin-left: 6px;
    padding: 2px 8px;
    font-size: 11px;
    font-style: normal;
    font-weight: 600;
    color: var(--shop-primary);
    background: rgba(228, 92, 58, 0.12);
    border-radius: 999px;
    vertical-align: middle;
}

.shop-line-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    height: 40px;
    padding: 0 10px;
    border-radius: 999px;
    background: #06c755;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    text-decoration: none;
}

a.btn.is-disabled,
#cart-checkout.is-disabled {
    pointer-events: none;
    opacity: 0.45;
}

.checkout-grid {
    display: grid;
    gap: 16px;
}

.checkout-panel {
    padding: 16px;
    background: var(--shop-surface);
    border: 1px solid var(--shop-border);
    border-radius: var(--shop-radius);
}

.checkout-panel h2 {
    margin: 0 0 12px;
    font-size: 16px;
}

.checkout-items,
.checkout-item {
    list-style: none;
    margin: 0;
    padding: 0;
}

.checkout-item {
    display: grid;
    grid-template-columns: 56px 1fr;
    gap: 10px;
    padding: 10px 0;
    border-bottom: 1px solid var(--shop-border);
}

.checkout-item img {
    width: 56px;
    height: 56px;
    object-fit: cover;
    border-radius: 8px;
    background: var(--shop-bg);
}

.checkout-item-meta {
    color: var(--shop-muted);
    font-size: 13px;
}

.checkout-total-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 12px;
    font-size: 18px;
    font-weight: 700;
}

.checkout-form label {
    display: block;
    margin-bottom: 12px;
    font-size: 14px;
}

.checkout-form input,
.checkout-form textarea {
    display: block;
    width: 100%;
    margin-top: 6px;
    padding: 10px 12px;
    border: 1px solid var(--shop-border);
    border-radius: 10px;
    font: inherit;
    background: var(--shop-bg);
}

.checkout-form .req {
    color: var(--shop-primary);
}

.checkout-hint {
    margin: 8px 0 12px;
    font-size: 13px;
    color: var(--shop-muted);
    line-height: 1.5;
}

.checkout-error {
    margin-top: 10px;
    color: #c0392b;
    font-size: 14px;
}

.order-done {
    padding: 16px;
    background: var(--shop-surface);
    border: 1px solid var(--shop-border);
    border-radius: var(--shop-radius);
}

.order-done-lead {
    font-size: 18px;
    font-weight: 600;
}

.order-done-box {
    margin: 16px 0;
    padding: 14px;
    border-radius: 12px;
    background: var(--shop-bg);
}

.bank-info {
    margin: 10px 0 0;
    padding-left: 18px;
}

.order-done-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
}

@media (min-width: 768px) {
    .checkout-grid {
        grid-template-columns: 1fr 1fr;
        align-items: start;
    }
}
