/* 游戏云购买页补充样式（基础布局复用 rcs/css/style.css） */

/* ========== 支付确认模态框样式（与物理机购买页一致） ========== */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1000;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
}

.modal-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    border-radius: 8px;
    width: 90%;
    max-width: 450px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid #eee;
}

.modal-header h3 {
    margin: 0;
    font-size: 18px;
    color: #333;
}

.modal-close {
    background: none;
    border: none;
    font-size: 24px;
    color: #999;
    cursor: pointer;
    padding: 0;
    line-height: 1;
}

.modal-close:hover {
    color: #333;
}

.modal-body {
    padding: 20px;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 15px 20px;
    border-top: 1px solid #eee;
}

/* 按钮通用样式 */
.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s;
}

.btn-primary {
    background: #667eea;
    color: white;
}

.btn-primary:hover {
    background: #5a67d8;
}

.btn-secondary {
    background: #fff;
    color: #333;
    border: 1px solid #d9d9d9;
}

.btn-secondary:hover {
    color: #667eea;
    border-color: #667eea;
}

/* 购买栏固定视口底部 */
.order-section {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: calc(100% - 40px);
    max-width: 1160px;
    z-index: 100;
    border-radius: 12px 12px 0 0;
    margin-top: 0;
    padding: 8px 30px;
}
.order-section .order-btn {
    padding: 10px 40px;
}
.order-section .duration-selector {
    margin: 0;
    padding: 0;
    background: transparent;
    border: none;
    display: flex;
    align-items: center;
    gap: 8px;
}
.order-section .duration-label {
    margin: 0;
    font-size: 13px;
    white-space: nowrap;
}
.order-section .duration-options {
    gap: 6px;
}
.order-section .duration-option {
    padding: 5px 12px;
    min-width: 72px;
}
.order-section .duration-name {
    font-size: 12px;
    white-space: nowrap;
}
body {
    padding-bottom: 80px;
}

/* 区域网格 */
.region-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

@media (max-width: 768px) {
    .region-grid {
        grid-template-columns: 1fr;
    }
}

/* 区域分组 */
.region-group {
    margin-bottom: 12px;
    border: 1px solid #eef;
    border-radius: 8px;
    overflow: hidden;
}

.region-group-title {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    background: #f8f9ff;
    font-size: 14px;
    font-weight: 600;
    color: #333;
    cursor: pointer;
    user-select: none;
    transition: background 0.15s ease;
}

.region-group-title:hover {
    background: #eef2ff;
}

.region-arrow {
    margin-left: auto;
    font-size: 11px;
    color: #95a5a6;
    transition: transform 0.2s ease;
}

.region-flag {
    font-size: 14px;
}

.region-delay {
    margin-left: auto;
    font-size: 12px;
    font-weight: 400;
    color: #95a5a6;
}

.region-lines {
    padding: 6px;
}

/* 城市分组 */
.region-city {
    padding: 4px 0;
    border-bottom: 1px dashed #eef;
}
.region-city:last-child {
    border-bottom: none;
}
.region-city-name {
    font-size: 12px;
    color: #94a3b8;
    padding: 4px 12px;
    font-weight: 500;
}
.region-city-lines {
    padding-left: 8px;
}

/* 单条线路 */
.region-line {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.15s ease;
    font-size: 13px;
}

.region-line:hover {
    background: #eef2ff;
}

.region-line.active {
    background: #667eea;
    color: #fff;
}

.region-line.active .line-tag,
.region-line.active .line-ip-tag {
    background: rgba(255, 255, 255, 0.25);
    color: #fff;
}

.line-name {
    flex: 1;
}

.line-tag {
    font-size: 11px;
    padding: 1px 6px;
    border-radius: 8px;
    background: #fee;
    color: #e74c3c;
}

.line-ip-tag {
    font-size: 11px;
    padding: 1px 6px;
    border-radius: 8px;
    background: #e8f5e9;
    color: #2e7d32;
}

/* 计费方式选择器（elastic_dynamic/elastic） */
.charge-type-selector {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 0;
    margin-bottom: 12px;
}

.charge-type-selector .charge-label {
    font-size: 13px;
    color: #666;
    white-space: nowrap;
}

.charge-type-selector .charge-options {
    display: flex;
    gap: 8px;
}

.charge-type-card {
    padding: 6px 16px;
    border: 2px solid #eef;
    border-radius: 8px;
    background: #fff;
    cursor: pointer;
    font-size: 13px;
    color: #555;
    transition: all 0.15s ease;
}

.charge-type-card:hover {
    border-color: #c7d2fe;
}

.charge-type-card.active {
    border-color: #667eea;
    background: #667eea;
    color: #fff;
}

/* 计费方式不可用时置灰（但仍显示标签，不隐藏） */
.charge-type-card.charge-type-disabled {
    opacity: 0.4;
    cursor: not-allowed;
    pointer-events: none;
}

/* CPU 机型选择器 */
.machine-options {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 0;
    margin-bottom: 12px;
    flex-wrap: wrap;
}

.machine-label {
    font-size: 13px;
    color: #666;
    white-space: nowrap;
}

.machine-btn {
    padding: 6px 16px;
    border: 2px solid #eef;
    border-radius: 8px;
    background: #fff;
    cursor: pointer;
    font-size: 13px;
    color: #555;
    transition: all 0.15s ease;
}

.machine-btn:hover {
    border-color: #c7d2fe;
}

.machine-btn.active {
    border-color: #667eea;
    background: #667eea;
    color: #fff;
}

/* 机型缺货按钮置灰 */
.machine-btn.machine-btn-disabled {
    opacity: 0.45;
    cursor: not-allowed;
    background: #f8fafc;
    color: #94a3b8;
    border-color: #e5e7eb;
    position: relative;
}
.machine-btn.machine-btn-disabled:hover {
    border-color: #e5e7eb;
    box-shadow: none;
}

/* 套餐卡片 */
.plan-card {
    position: relative;
    padding: 14px;
    margin-bottom: 10px;
    border: 2px solid #eef;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.15s ease;
    background: #fff;
}

.plan-card:hover {
    border-color: #c7d2fe;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.1);
}

.plan-card.active {
    border-color: #667eea;
    background: #f8f9ff;
}

#plan-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 12px;
}

#plan-list .plan-card {
    margin-bottom: 0;
}

.plan-card.out-of-stock {
    opacity: 0.5;
    cursor: not-allowed;
    background: #f8fafc;
}

.plan-card.out-of-stock:hover {
    border-color: #eef;
    box-shadow: none;
}

.plan-name {
    font-size: 15px;
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
}

.plan-spec-list {
    margin-bottom: 10px;
    text-align: left;
}

.spec-row {
    display: flex;
    align-items: baseline;
    gap: 8px;
    padding: 3px 0;
    font-size: 13px;
    line-height: 1.4;
    text-align: left;
}

.spec-label {
    flex-shrink: 0;
    width: 42px;
    color: #94a3b8;
    font-size: 12px;
}

.spec-value {
    color: #475569;
    flex: 1;
    text-align: left;
}

.plan-price {
    font-size: 20px;
    font-weight: 700;
    color: #e74c3c;
}

.plan-price-unit {
    font-size: 12px;
    font-weight: 400;
    color: #95a5a6;
}

.plan-stock-out {
    position: absolute;
    top: 8px;
    right: 8px;
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 8px;
    background: #eee;
    color: #999;
}

/* ========== 配置滑块区 ========== */

/* 预设配置档位卡片（入门级/高端级等） */
.config-tier-selector {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 10px;
    margin-bottom: 18px;
}

.config-tier-card {
    padding: 12px;
    border: 2px solid #eef;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.15s ease;
    background: #fff;
    text-align: center;
}

.config-tier-card:hover {
    border-color: #c7d2fe;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.1);
}

.config-tier-card.active {
    border-color: #667eea;
    background: #f8f9ff;
}

.config-tier-name {
    font-size: 14px;
    font-weight: 600;
    color: #333;
    margin-bottom: 4px;
}

.config-tier-spec {
    font-size: 12px;
    color: #64748b;
    margin-bottom: 4px;
}

.config-tier-desc {
    font-size: 11px;
    color: #94a3b8;
    line-height: 1.4;
    margin-bottom: 6px;
}

/* 滑块项 */
.config-sliders {
    display: flex;
    flex-direction: column;
    gap: 18px;
    padding: 8px 0;
}

.config-slider-item {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.config-slider-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    font-size: 13px;
}

.config-slider-label {
    color: #555;
    font-weight: 500;
}

.config-slider-value {
    color: #667eea;
    font-weight: 700;
    font-size: 15px;
}

.config-slider-value .unit {
    font-size: 12px;
    font-weight: 400;
    color: #95a5a6;
    margin-left: 2px;
}

.config-slider-range {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: #e2e8f0;
    outline: none;
    cursor: pointer;
}

.config-slider-range::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #667eea;
    cursor: pointer;
    box-shadow: 0 1px 4px rgba(102, 126, 234, 0.4);
    transition: transform 0.1s ease;
}

.config-slider-range::-webkit-slider-thumb:hover {
    transform: scale(1.15);
}

.config-slider-range::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #667eea;
    cursor: pointer;
    border: none;
    box-shadow: 0 1px 4px rgba(102, 126, 234, 0.4);
}


/* 滑块刻度（按百分比绝对定位，确保与滑块刻度位置对应） */
.config-slider-ticks {
    position: relative;
    height: 20px;
    margin-top: 2px;
    padding: 0 9px; /* 补偿滑块 thumb 半宽，让首尾刻度对齐滑块两端 */
}

.slider-tick {
    position: absolute;
    top: 0;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.slider-tick::before {
    content: '';
    display: block;
    width: 1px;
    height: 4px;
    background: #d1d5db;
}

.slider-tick.tick-has-label::before {
    height: 6px;
    background: #9ca3af;
}

.tick-label {
    font-size: 14px;
    font-weight: 500;
    color: #4b5563;
    margin-top: 4px;
    line-height: 1;
    white-space: nowrap;
}

.config-slider-unit-price {
    font-size: 11px;
    color: #94a3b8;
    margin-top: 2px;
}

/* 操作系统样式统一来自 rcs/css/style.css（os-tabs/os-tab/os-list/os-card）*/

/* IP 选项 */
.ip-options .ip-item label {
    display: block;
    margin-bottom: 6px;
    font-size: 13px;
    color: #666;
}

.ip-options .ip-item select {
    width: 100%;
    padding: 8px 12px;
    border: 2px solid #eef;
    border-radius: 8px;
    font-size: 13px;
    box-sizing: border-box;
}

.ip-options .number-input-group {
    display: flex;
    align-items: center;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    background: #fff;
    overflow: hidden;
    width: fit-content;
}
.ip-options .number-input-group input[type="number"] {
    width: 60px;
    border: none;
    text-align: center;
    padding: 8px 4px;
    font-size: 14px;
    font-weight: 600;
    background: transparent;
    -moz-appearance: textfield;
}
.ip-options .number-input-group input[type="number"]::-webkit-outer-spin-button,
.ip-options .number-input-group input[type="number"]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}
.ip-options .number-input-group input[type="number"]:focus {
    outline: none;
}
.ip-options .number-btn {
    width: 36px;
    height: 36px;
    border: none;
    background: #f3f4f6;
    color: #374151;
    font-size: 18px;
    cursor: pointer;
    transition: all 0.2s;
}
.ip-options .number-btn:hover {
    background: linear-gradient(135deg, #37b5c1 0%, #2d9aa5 100%);
    color: #fff;
}
.ip-options .number-btn.minus {
    border-right: 1px solid #e5e7eb;
}
.ip-options .number-btn.plus {
    border-left: 1px solid #e5e7eb;
}
.ip-options .number-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}
.ip-options .number-btn:disabled:hover {
    background: #f3f4f6;
    color: #374151;
}

/* 价格摘要 */
.price-item {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    font-size: 14px;
    color: #555;
}

.price-item .price {
    font-weight: 600;
    color: #333;
}

/* 提示文字 */
.note {
    color: #94a3b8;
    text-align: center;
    padding: 20px;
    font-size: 14px;
}

/* ========== Minecraft 整合包选择器 ========== */

/* 弹窗：加宽加大，内部滚动 */
.mcpack-modal-content {
    width: 96%;
    max-width: 1080px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
}

.mcpack-modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 16px 20px;
}

/* 工具栏：来源切换 + 搜索/筛选 */
.mcpack-toolbar {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 16px;
    position: sticky;
    top: 0;
    background: #fff;
    z-index: 2;
    padding-bottom: 12px;
    border-bottom: 1px solid #f1f1f1;
}

.mcpack-source-tabs {
    display: flex;
    gap: 8px;
}

.mcpack-source-tab {
    padding: 7px 18px;
    border: 2px solid #eef;
    border-radius: 8px;
    background: #fff;
    cursor: pointer;
    font-size: 13px;
    color: #555;
    transition: all 0.15s ease;
}

.mcpack-source-tab:hover {
    border-color: #c7d2fe;
}

.mcpack-source-tab.active {
    border-color: #667eea;
    background: #667eea;
    color: #fff;
}

.mcpack-filters {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.mcpack-search,
.mcpack-loader-select,
.mcpack-mcversion-select {
    padding: 8px 12px;
    border: 2px solid #eef;
    border-radius: 8px;
    font-size: 13px;
    box-sizing: border-box;
    background: #fff;
}

.mcpack-search {
    flex: 1;
    min-width: 220px;
}

.mcpack-loader-select,
.mcpack-mcversion-select {
    min-width: 130px;
    cursor: pointer;
}

.mcpack-search:focus,
.mcpack-loader-select:focus,
.mcpack-mcversion-select:focus {
    outline: none;
    border-color: #667eea;
}

/* 整合包卡片网格 */
.mcpack-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 12px;
}

.mcpack-card {
    position: relative;
    display: flex;
    gap: 10px;
    padding: 12px;
    border: 2px solid #eef;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.15s ease;
    background: #fff;
}

.mcpack-card:hover {
    border-color: #c7d2fe;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.12);
}

.mcpack-card.active {
    border-color: #667eea;
    background: #f8f9ff;
}

.mcpack-card-icon {
    flex-shrink: 0;
    width: 56px;
    height: 56px;
    border-radius: 8px;
    overflow: hidden;
    background: #f1f5f9;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mcpack-card-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.mcpack-card-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.mcpack-card-name {
    font-size: 14px;
    font-weight: 600;
    color: #333;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.mcpack-card-author {
    font-size: 12px;
    color: #94a3b8;
}

.mcpack-card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin: 2px 0;
}

.mcpack-loader-tag,
.mcpack-gv-tag {
    font-size: 11px;
    padding: 1px 6px;
    border-radius: 8px;
    background: #eef2ff;
    color: #4f46e5;
}

.mcpack-gv-tag {
    background: #f0fdf4;
    color: #15803d;
}

.mcpack-card-desc {
    font-size: 12px;
    color: #64748b;
    line-height: 1.4;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.mcpack-card-installs {
    position: absolute;
    top: 8px;
    right: 10px;
    font-size: 11px;
    color: #94a3b8;
    text-align: right;
    line-height: 1.2;
}

.mcpack-card-installs span {
    display: block;
    font-size: 10px;
}

/* 版本下拉（选中卡片内展开） */
.mcpack-version-select {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px dashed #eef;
}

.mcpack-version-select label {
    font-size: 12px;
    color: #555;
    white-space: nowrap;
}

.mcpack-version-select select {
    flex: 1;
    padding: 5px 8px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 12px;
    min-width: 0;
}

.mcpack-version-empty {
    font-size: 12px;
    color: #e74c3c;
    margin-top: 6px;
}

/* 分页 */
.mcpack-pagination {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin-top: 18px;
    flex-wrap: wrap;
}

.mcpack-page-btn {
    min-width: 34px;
    padding: 6px 10px;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    background: #fff;
    cursor: pointer;
    font-size: 13px;
    color: #555;
    transition: all 0.15s ease;
}

.mcpack-page-btn:hover:not(:disabled) {
    border-color: #667eea;
    color: #667eea;
}

.mcpack-page-btn.active {
    background: #667eea;
    color: #fff;
    border-color: #667eea;
}

.mcpack-page-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.mcpack-count {
    text-align: center;
    font-size: 12px;
    color: #94a3b8;
    margin-top: 12px;
}

/* mcpack 应用卡片内：选择按钮 + 选中摘要 */
.app-vars .mcpack-pick-btn {
    width: 100%;
    margin-top: 8px;
    padding: 8px;
}

.mcpack-selected-info {
    background: #f8f9ff;
    border: 1px solid #e0e7ff;
    border-radius: 8px;
    padding: 8px 10px;
    margin-bottom: 8px;
    font-size: 13px;
    line-height: 1.6;
}

.mcpack-selected-row {
    color: #475569;
    word-break: break-all;
}

.mcpack-selected-label {
    color: #94a3b8;
    font-size: 12px;
}

@media (max-width: 768px) {
    .mcpack-modal-content {
        max-width: 100%;
        width: 100%;
        max-height: 92vh;
    }
    .mcpack-grid {
        grid-template-columns: 1fr;
    }
    .mcpack-filters {
        flex-direction: column;
    }
    .mcpack-search,
    .mcpack-loader-select,
    .mcpack-mcversion-select {
        min-width: 0;
        width: 100%;
    }
}

/* ========== MC 服务端核心选择器 ========== */

/* 整合包可选项 toggle（mcpack 应用卡片顶部） */
.mc-mode-toggle-row {
    padding: 4px 0 10px;
    border-bottom: 1px dashed #eef;
    margin-bottom: 10px;
}

.mc-mode-toggle {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: #475569;
    cursor: pointer;
    user-select: none;
}

.mc-mode-toggle input[type="checkbox"] {
    width: 15px;
    height: 15px;
    cursor: pointer;
    accent-color: #667eea;
}

.mc-mode-toggle span {
    font-weight: 500;
}

/* 三个固定类型卡片网格 */
.mc-type-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-bottom: 12px;
}

.mc-type-card {
    padding: 10px 6px;
    border: 2px solid #eef;
    border-radius: 10px;
    background: #fff;
    cursor: pointer;
    text-align: center;
    transition: all 0.15s ease;
}

.mc-type-card:hover {
    border-color: #c7d2fe;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.1);
}

.mc-type-card.active {
    border-color: #667eea;
    background: #f8f9ff;
    color: #667eea;
}

.mc-type-name {
    font-size: 13px;
    font-weight: 600;
}

/* ============================================================
   预装应用图标 + 兜底徽章
   .app-card img 在 rcs/css/style.css 已定义 40x40 圆角 8px 基础样式，
   下面新增图标容器和兜底徽章（图标加载失败时显示首字母）
   ============================================================ */
.app-icon-wrap {
    width: 40px;
    height: 40px;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.app-card .app-icon {
    width: 40px;
    height: 40px;
    object-fit: contain;
    border-radius: 8px;
    transition: transform 0.15s ease;
}

.app-card.active .app-icon {
    transform: scale(1.03);
}

.app-badge {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    background: linear-gradient(135deg, #37b5c1, #1e8a99);
    box-shadow: 0 2px 6px rgba(55, 181, 193, 0.25);
    user-select: none;
}

/* 服务端核心卡片网格 */
.mc-core-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
    gap: 10px;
    margin-bottom: 12px;
}

.mc-core-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 12px 6px 10px;
    border: 2px solid #eef;
    border-radius: 12px;
    background: #fff;
    cursor: pointer;
    text-align: center;
    transition: all 0.15s ease;
}

.mc-core-card:hover {
    border-color: #c7d2fe;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.1);
    transform: translateY(-1px);
}

.mc-core-card.active {
    border-color: #667eea;
    background: #f8f9ff;
    box-shadow: 0 2px 10px rgba(102, 126, 234, 0.18);
}

/* 服务端核心徽章（纯 CSS，作为图标兜底显示）
   - 无 icon_url 时直接显示徽章
   - 有 icon_url 时 img 渲染图标，img 加载失败 onerror 自动切换显示徽章
*/
.mc-core-icon-wrap {
    width: 36px;
    height: 36px;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mc-core-badge {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 700;
    color: #fff;
    letter-spacing: 0.5px;
    background: linear-gradient(135deg, #94a3b8, #64748b);
    box-shadow: 0 2px 6px rgba(100, 116, 139, 0.25);
    user-select: none;
}

/* 不同 MC 类型用不同色系，便于一眼区分 */
.mc-core-mc_vanilla .mc-core-badge {
    background: linear-gradient(135deg, #818cf8, #6366f1);
    box-shadow: 0 2px 6px rgba(99, 102, 241, 0.3);
}
.mc-core-mc_mod .mc-core-badge {
    background: linear-gradient(135deg, #fb923c, #ea580c);
    box-shadow: 0 2px 6px rgba(234, 88, 12, 0.3);
}
.mc-core-mc_fabric .mc-core-badge {
    background: linear-gradient(135deg, #38bdf8, #0284c7);
    box-shadow: 0 2px 6px rgba(2, 132, 199, 0.3);
}

/* 选中态徽章：加亮 + 描边，与卡片 active 一致 */
.mc-core-card.active .mc-core-badge {
    transform: scale(1.05);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.25), 0 2px 8px rgba(102, 126, 234, 0.35);
}

/* 图标（本地路径，已绕过雨云对象存储防盗链） */
.mc-core-card-icon {
    width: 36px;
    height: 36px;
    object-fit: contain;
}
.mc-core-card.active .mc-core-card-icon {
    transform: scale(1.05);
}

.mc-core-name {
    font-size: 13px;
    font-weight: 600;
    color: #333;
    margin-bottom: 2px;
}

.mc-core-desc {
    font-size: 11px;
    color: #94a3b8;
    line-height: 1.3;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

/* 版本下拉行 */
.mc-version-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.mc-version-label {
    font-size: 13px;
    color: #666;
    white-space: nowrap;
}

.mc-version-select {
    flex: 1;
    padding: 6px 10px;
    border: 2px solid #eef;
    border-radius: 8px;
    font-size: 13px;
    color: #333;
    background: #fff;
    cursor: pointer;
    transition: border-color 0.15s ease;
}

.mc-version-select:focus {
    border-color: #667eea;
    outline: none;
}

/* 已选摘要（复用 mcpack-selected-row 风格） */
.mc-selected-summary {
    padding: 10px 12px;
    background: #f8f9ff;
    border: 1px solid #eef;
    border-radius: 8px;
    margin-bottom: 8px;
}

@media (max-width: 768px) {
    .mc-type-grid {
        grid-template-columns: 1fr;
    }
    .mc-core-grid {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    }
    .mc-version-row {
        flex-direction: column;
        align-items: stretch;
    }
}
