body.catalog-page.manufacturing-page {
    padding: calc(var(--header-height) + 20px) 20px 40px;
    background: #e9e9e9;
}

.manufacturing-page__shell {
    width: 100%;
    max-width: none;
    margin: 0;
}

.manufacturing-grid.characters-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
    margin-bottom: 24px;
}

.manufacturing-page .character-card {
    cursor: pointer;
}

.manufacturing-page .character-image-container {
    position: relative;
}

.manufacturing-page .character-image-container .character-image {
    position: relative;
    z-index: 0;
}

.manufacturing-page .mfg-card--media-only {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.manufacturing-page .mfg-card--media-only .character-image-container {
    aspect-ratio: 580 / 425;
    width: 100%;
    height: auto;
}

.manufacturing-pagination {
    margin-top: 8px;
}

.mfg-info-btn {
    position: absolute;
    right: clamp(8px, 1.2vw, 12px);
    bottom: clamp(8px, 1.2vw, 12px);
    z-index: 3;
    width: clamp(34px, 4.2vw, 44px);
    height: clamp(34px, 4.2vw, 44px);
    padding: 0;
    border: none;
    border-radius: 50%;
    background: #0b51ff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 14px rgba(11, 81, 255, 0.35);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.mfg-info-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 18px rgba(11, 81, 255, 0.45);
}

a.mfg-info-btn.mfg-taobao-btn {
    text-decoration: none;
    color: inherit;
}

.mfg-info-btn__glyph,
.mfg-info-btn__icon {
    width: 88%;
    height: 88%;
    object-fit: contain;
    display: block;
    pointer-events: none;
    user-select: none;
}

.mfg-modal[hidden] {
    display: none !important;
}

.mfg-modal {
    position: fixed;
    inset: 0;
    z-index: 1200;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: clamp(12px, 2vw, 24px);
}

.mfg-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(196, 196, 196, 0.72);
}

.mfg-modal__panel {
    position: relative;
    z-index: 1;
    width: min(1720px, calc(100vw - 32px));
    height: min(920px, calc(100vh - 32px));
    max-height: calc(100vh - 32px);
    overflow: hidden;
    background: #d9d9d9;
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.18);
    font-family: 'Source Han Sans CN', 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', sans-serif;
}

.mfg-modal__close {
    position: absolute;
    top: clamp(16px, 2.2vw, 28px);
    right: clamp(16px, 2.2vw, 28px);
    z-index: 3;
    width: 40px;
    height: 40px;
    border: none;
    background: transparent;
    color: #0b51ff;
    cursor: pointer;
    font-size: clamp(28px, 3vw, 36px);
    line-height: 1;
}

.mfg-modal__layout {
    display: flex;
    height: 100%;
    min-height: 0;
}

.mfg-modal__gallery {
    flex: 0 0 58%;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    background: #d9d9d9;
    padding: clamp(16px, 2vw, 28px);
}

.mfg-modal__gallery-stage {
    position: relative;
    flex: 1 1 auto;
    width: 100%;
    min-height: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: clamp(8px, 1vw, 12px);
    overflow: visible;
    cursor: grab;
    touch-action: pan-y pinch-zoom;
    user-select: none;
    -webkit-user-select: none;
}

.mfg-modal__gallery-stage:active {
    cursor: grabbing;
}

.mfg-modal__gallery-frame {
    flex: 1 1 auto;
    min-width: 0;
    height: 100%;
    min-height: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    overflow: visible;
}

.mfg-modal__gallery-media {
    position: relative;
    flex: 0 1 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: 100%;
    max-height: 100%;
    overflow: visible;
    line-height: normal;
}

.mfg-modal__gallery-stack-wrap {
    position: relative;
    flex: 0 0 auto;
    width: 100%;
    max-width: 100%;
}

.mfg-modal__gallery-nav {
    position: absolute;
    inset: 0;
    z-index: 6;
    display: flex;
    align-items: center;
    justify-content: space-between;
    pointer-events: none;
    padding: 0 clamp(4px, 1.5vw, 16px);
}

.mfg-modal__gallery-nav[hidden] {
    display: none !important;
}

.mfg-modal__gallery-btn {
    pointer-events: auto;
    position: relative;
    flex: 0 0 auto;
    width: clamp(44px, 7vw, 72px);
    height: clamp(44px, 7vw, 72px);
    padding: 0;
    border: none;
    background: transparent;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}

.mfg-modal__gallery-btn-bg {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    pointer-events: none;
    user-select: none;
}

.mfg-modal__gallery-btn-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 38%;
    height: auto;
    max-height: 45%;
    object-fit: contain;
    pointer-events: none;
    user-select: none;
}

.mfg-modal__gallery-btn:hover .mfg-modal__gallery-btn-bg {
    filter: brightness(1.08);
}

.mfg-modal__gallery-btn:active .mfg-modal__gallery-btn-bg {
    filter: brightness(0.95);
}

.mfg-modal__gallery-stack {
    position: relative;
    flex: 0 0 auto;
    display: block;
    width: 100%;
    max-width: 100%;
    min-height: 120px;
    overflow: visible;
}

.mfg-modal__gallery-stack .mfg-modal__gallery-img {
    position: absolute;
    left: 50%;
    top: 50%;
    z-index: 1;
    display: block;
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    transform: translate(-50%, -50%);
    opacity: 0;
    transition: opacity 0.4s ease-in-out;
    pointer-events: none;
}

.mfg-modal__gallery-stack .mfg-modal__gallery-img.is-visible {
    opacity: 1;
    pointer-events: auto;
}

.mfg-modal__gallery-img {
    display: block;
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
}

.mfg-modal__nav {
    flex: 0 0 auto;
    width: 44px;
    height: 44px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.72);
    color: rgba(11, 81, 255, 0.75);
    font-size: 18px;
    cursor: pointer;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

.mfg-modal__nav:disabled {
    opacity: 0.35;
    cursor: default;
}

.mfg-modal__dots {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    margin: 14px 0 0;
    padding: 0;
    pointer-events: auto;
}

.mfg-modal__dots:empty {
    display: none;
    margin: 0;
}

.mfg-modal__dot {
    display: inline-block;
    flex-shrink: 0;
    box-sizing: border-box;
    width: 8px;
    height: 8px;
    min-width: 8px;
    min-height: 8px;
    padding: 0;
    border: none;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 0 0 1px rgba(11, 81, 255, 0.28);
    cursor: pointer;
    transition: transform 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
    pointer-events: auto;
}

.mfg-modal__dot.is-active {
    width: 10px;
    height: 10px;
    min-width: 10px;
    min-height: 10px;
    background: #0b51ff;
    box-shadow: none;
}

.mfg-modal__dot:hover:not(.is-active) {
    transform: scale(1.15);
    box-shadow: 0 0 0 1px rgba(11, 81, 255, 0.45);
}

.mfg-modal__detail {
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    flex-direction: column;
    background: #d9d9d9;
    padding: clamp(48px, 6vw, 88px) clamp(28px, 4vw, 56px) clamp(32px, 4vw, 48px);
    overflow-y: auto;
}

.mfg-modal__head {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0;
    text-align: right;
    flex-shrink: 0;
}

.mfg-modal__title {
    margin: 0 0 clamp(12px, 1.4vw, 18px);
    color: #0b51ff;
    font-family: 'Source Han Sans CN', 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', sans-serif;
    font-weight: 500;
    font-style: normal;
    font-size: 48px;
    line-height: 1;
    letter-spacing: 0;
    text-align: right;
}

.mfg-modal__price {
    margin: 0 0 40px;
    color: #0b51ff;
    font-family: 'Source Han Sans CN', 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', sans-serif;
    font-weight: 300;
    font-style: normal;
    font-size: 36px;
    line-height: 1;
    letter-spacing: 0;
    text-align: right;
}

.mfg-modal__status {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 248px;
    margin: 0;
    padding: 8px 18px;
    background: #0b51ff;
    color: #fff;
    font-family: 'Source Han Sans CN', 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', sans-serif;
    font-weight: 400;
    font-style: normal;
    font-size: 20px;
    line-height: 1;
    letter-spacing: 0;
    text-align: center;
    vertical-align: middle;
}

.mfg-modal__status.is-sold-out {
    background: #888585;
}

.mfg-modal__body {
    box-sizing: border-box;
    width: 75%;
    max-width: 75%;
    margin-top: clamp(64px, 10vw, 144px);
    margin-left: auto;
    color: #1a1a1a;
    font-family: 'Source Han Sans CN', 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', sans-serif;
    font-weight: 400;
    font-style: normal;
    font-size: 24px;
    line-height: 45px;
    letter-spacing: 0;
    white-space: pre-wrap;
    text-align: left;
    vertical-align: bottom;
}

.mfg-modal__empty {
    color: #667790;
    font-family: inherit;
    font-weight: 400;
    font-size: 24px;
    line-height: 45px;
}

body.mfg-modal-open {
    overflow: hidden;
}

@media (max-width: 900px) {
    .mfg-modal__panel {
        width: calc(100vw - 16px);
        height: calc(100vh - 16px);
        max-height: calc(100vh - 16px);
    }

    .mfg-modal__layout {
        flex-direction: column;
    }

    .mfg-modal__gallery {
        flex: 0 0 auto;
        width: 100%;
        min-height: 42vh;
    }

    .mfg-modal__gallery-stage {
        flex: 0 0 auto;
        max-height: 36vh;
    }

    .mfg-modal__gallery-frame {
        height: auto;
        max-height: 36vh;
    }

    .mfg-modal__detail {
        flex: 1 1 auto;
        padding: 24px 20px 28px;
    }

    .mfg-modal__body {
        margin-top: 48px;
    }
}

/* PC：每行 3 个（图区 580×425，较原 435 高度共约减 10px） */
@media (min-width: 901px) {
    .manufacturing-page__shell {
        max-width: 1780px;
        margin-left: auto;
        margin-right: auto;
    }

    .manufacturing-grid.characters-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 900px) {
    .manufacturing-grid.characters-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 16px;
    }
}

@media (max-width: 640px) {
    body.catalog-page.manufacturing-page {
        padding: calc(var(--header-height) + 16px) 12px 28px;
    }

    .manufacturing-grid.characters-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 12px;
    }
}
