/* YHSM 快速下单插件样式 */

.yhsm-fast-order-container {
    max-width: 100%;
    margin: 0 auto;
    padding: 15px;
    background: #ffffff;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.yhsm-fast-order-container h2 {
    color: #333;
    font-size: 18px;
    margin-bottom: 15px;
    padding-bottom: 8px;
    border-bottom: 2px solid #e74c3c;
}

/* 输入区域样式 */
.yhsm-input-section {
    margin-bottom: 30px;
}

#yhsm-sku-input {
    width: 100%;
    height: 150px;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    font-family: monospace;
    resize: vertical;
    box-sizing: border-box;
    transition: border-color 0.3s;
}

#yhsm-sku-input:focus {
    outline: none;
    border-color: #4CAF50;
    box-shadow: 0 0 0 2px rgba(76, 175, 80, 0.1);
}

.yhsm-button-primary {
    display: inline-block;
    background: #4CAF50;
    color: white;
    border: none;
    padding: 12px 24px;
    font-size: 16px;
    font-weight: 500;
    border-radius: 6px;
    cursor: pointer;
    margin-top: 15px;
    transition: all 0.3s;
    text-decoration: none;
    text-align: center;
    min-height: 44px;
    box-sizing: border-box;
}

.yhsm-button-primary:hover:not(:disabled) {
    background: #45a049;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(76, 175, 80, 0.3);
}

.yhsm-button-primary:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* 移动端触摸反馈优化 */
@media (max-width: 768px) {
    .yhsm-button-primary {
        width: 100%;
        padding: 12px 18px;
        font-size: 16px; /* 防止iOS缩放 */
    }
    
    .yhsm-button-primary:active:not(:disabled) {
        transform: scale(0.98);
        opacity: 0.9;
    }
    
    /* 输入框优化 */
    #yhsm-sku-input {
        font-size: 16px; /* 防止iOS缩放 */
    }
}

/* 结果区域样式 */
.yhsm-result-section {
    margin-top: 30px;
}

.yhsm-products-grid {
    margin-bottom: 20px;
}

/* 表头样式 - 优化标题行高度 */
.yhsm-product-header {
    background: #4CAF50;
    color: white;
    font-weight: 600;
    margin-bottom: 10px;
    border-radius: 6px 6px 0 0;
    overflow: hidden;
}

.yhsm-product-header .yhsm-product-row {
    padding: 8px 10px;
    font-weight: 600;
    font-size: 12px;
    border-bottom: none;
    min-height: auto;
    height: 40px;
    align-items: center;
}

/* 表头列宽定义 - 必须与数据行列宽完全一致 */
.yhsm-product-header .yhsm-product-name {
    font-size: 13px;
    color: white;
    font-weight: 600;
    flex: 1;
    min-width: 0;
}

.yhsm-product-header .yhsm-product-price,
.yhsm-product-header .yhsm-product-discount-price {
    flex: 0 0 65px;
    text-align: right;
    font-size: 13px;
    color: white;
    font-weight: 600;
    padding-right: 5px;
}

.yhsm-product-header .yhsm-product-quantity {
    flex: 0 0 80px;
    text-align: center;
    font-size: 13px;
    color: white;
    font-weight: 600;
}

.yhsm-product-header .yhsm-product-subtotal {
    flex: 0 0 70px;
    text-align: right;
    font-size: 13px;
    color: white;
    font-weight: 600;
    padding-right: 5px;
}

/* 响应式表头调整 - 必须与数据行响应式调整保持同步 */
@media (max-width: 1200px) {
    .yhsm-product-header .yhsm-product-price,
    .yhsm-product-header .yhsm-product-discount-price {
        flex: 0 0 60px;
        font-size: 12px;
    }
    
    .yhsm-product-header .yhsm-product-quantity {
        flex: 0 0 70px;
        font-size: 12px;
    }
    
    .yhsm-product-header .yhsm-product-subtotal {
        flex: 0 0 65px;
        font-size: 12px;
    }
}

@media (max-width: 768px) {
    .yhsm-product-header .yhsm-product-row {
        padding: 8px 6px;
    }
    
    .yhsm-product-header .yhsm-product-price,
    .yhsm-product-header .yhsm-product-discount-price,
    .yhsm-product-header .yhsm-product-subtotal {
        flex: 0 0 45px;
        font-size: 11px;
        padding-right: 2px;
    }
    
    .yhsm-product-header .yhsm-product-quantity {
        flex: 0 0 55px;
        font-size: 11px;
    }
}

/* 产品行样式 - 确保在所有屏幕尺寸下一行显示 */
.yhsm-product-row {
    display: flex;
    align-items: center;
    padding: 12px 10px;
    border-bottom: 1px solid #eee;
    flex-wrap: nowrap;
    overflow: hidden;
    min-height: 80px;
}

/* 产品项样式 */
.yhsm-product-item {
    border: 1px solid #eee;
    margin-bottom: 8px;
    border-radius: 6px;
    transition: all 0.2s ease;
    overflow: hidden;
    background: #ffffff;
}

.yhsm-product-item:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* 产品图片 */
.yhsm-product-image {
    flex: 0 0 50px;
    height: 50px;
    margin-right: 10px;
    border-radius: 4px;
    overflow: hidden;
    background-color: #f5f5f5;
    display: flex;
    align-items: center;
    justify-content: center;
}

.yhsm-product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* 产品信息容器 - 确保SKU内容在同一行显示 */
.yhsm-product-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
    margin-left: 0;
}

.yhsm-product-name {
    font-size: 14px;
    font-weight: 500;
    color: #333;
    line-height: 1.2;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 4px;
    min-width: 120px;
}

.yhsm-product-sku {
    font-size: 12px;
    color: #666;
    font-family: monospace;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex: none;
}

/* 价格信息布局 */
.yhsm-price-info {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    margin-left: 8px;
    flex: 0 0 120px;
}

/* 价格列样式 - 确保与表头宽度完全一致 */
.yhsm-product-price {
    flex: 0 0 65px;
    text-align: right;
    color: #666;
    font-size: 13px;
    padding-right: 5px;
}

.yhsm-product-discount-price {
    flex: 0 0 65px;
    text-align: right;
    font-weight: 600;
    font-size: 13px;
    padding-right: 5px;
}

.yhsm-product-discount-price .yhsm-discount-price {
    color: #e74c3c;
    padding: 2px 4px;
    background-color: #fff5f5;
    border-radius: 4px;
    font-weight: 700;
    font-size: 13px;
}

.yhsm-discount-price {
    color: #e74c3c;
    font-weight: 600;
    font-size: 13px;
}

.yhsm-regular-price {
    color: #999;
    font-size: 12px;
    text-decoration: line-through;
}

/* 数量输入框样式 - 确保与表头宽度完全一致 */
.yhsm-product-quantity {
    flex: 0 0 80px;
    display: flex;
    justify-content: center;
}

.yhsm-quantity-input {
    width: 60px;
    height: 32px;
    font-size: 14px;
    padding: 0 8px;
    text-align: center;
    border-radius: 4px;
    border: 1px solid #ddd;
}

/* 小计样式 - 确保与表头宽度完全一致 */
.yhsm-product-subtotal {
    flex: 0 0 70px;
    text-align: right;
    font-weight: 600;
    color: #333;
    font-size: 13px;
    padding-right: 5px;
}

.yhsm-subtotal {
    color: #333;
    font-weight: 700;
    font-size: 13px;
}

/* 统一响应式设计 - 确保所有屏幕尺寸下SKU内容在同一行显示 */
@media (max-width: 1200px) {
    .yhsm-product-name {
        font-size: 13px;
    }
    
    .yhsm-product-sku {
        font-size: 11px;
    }
    
    .yhsm-product-price,
    .yhsm-product-discount-price {
        flex: 0 0 60px;
        font-size: 12px;
    }
    
    .yhsm-product-quantity {
        flex: 0 0 70px;
    }
    
    .yhsm-quantity-input {
        width: 50px;
        height: 28px;
        font-size: 13px;
    }
    
    .yhsm-product-subtotal {
        flex: 0 0 65px;
        font-size: 12px;
    }
    
    .yhsm-price-info {
        flex: 0 0 100px;
    }
}

@media (max-width: 992px) {
    .yhsm-product-row {
        padding: 10px 8px;
    }
    
    .yhsm-product-image {
        flex: 0 0 45px;
        height: 45px;
        margin-right: 8px;
    }
    
    .yhsm-product-name {
        font-size: 12px;
        min-width: 100px;
    }
    
    .yhsm-product-sku {
        font-size: 10px;
    }
}

@media (max-width: 768px) {
    .yhsm-product-row {
        padding: 8px 6px;
    }
    
    .yhsm-product-image {
        flex: 0 0 40px;
        height: 40px;
        margin-right: 6px;
    }
    
    .yhsm-product-price,
    .yhsm-product-discount-price {
        flex: 0 0 55px;
        font-size: 11px;
    }
    
    .yhsm-product-quantity {
        flex: 0 0 65px;
    }
    
    .yhsm-quantity-input {
        width: 45px;
        height: 26px;
        font-size: 12px;
        padding: 0 6px;
    }
    
    .yhsm-product-subtotal {
        flex: 0 0 60px;
        font-size: 11px;
    }
    
    .yhsm-price-info {
        flex: 0 0 90px;
    }
}

/* 移动端优化 - 确保小屏幕上依然保持一行显示 */
@media (max-width: 480px) {
    #yhsm-fast-order {
        padding: 10px;
    }
    
    #yhsm-fast-order h2 {
        font-size: 16px;
        margin-bottom: 12px;
    }
    
    .yhsm-product-info {
        min-width: 90px;
    }
    
    .yhsm-product-name {
        font-size: 11px;
    }
    
    .yhsm-product-sku {
        font-size: 10px;
    }
    
    .yhsm-product-price,
    .yhsm-product-discount-price,
    .yhsm-product-subtotal {
        flex: 0 0 45px;
        font-size: 10px;
        padding-right: 2px;
    }
    
    .yhsm-product-quantity {
        flex: 0 0 55px;
    }
    
    .yhsm-quantity-input {
        width: 40px;
        height: 24px;
        font-size: 11px;
    }
    
    #yhsm-add-to-cart {
        padding: 10px 15px;
        font-size: 14px;
        width: 100%;
        margin-top: 15px;
        float: none;
    }
}

/* 超小屏幕优化 - 针对更紧凑的显示环境 */
@media (max-width: 360px) {
    /* 容器样式 */
    .yhsm-fast-order-container {
        padding: 10px;
        margin: 5px;
        max-width: calc(100% - 10px);
    }
    
    /* 表头优化 - 确保所有列可见 */
    .yhsm-product-header .yhsm-product-row {
        font-size: 10px;
        padding: 5px 2px;
        flex-wrap: nowrap;
        overflow-x: auto;
        height: 36px;
    }
    
    /* 产品行样式优化 */
    .yhsm-product-item {
        margin-bottom: 8px;
    }
    
    .yhsm-product-row {
        padding: 6px 3px;
        flex-wrap: nowrap;
        overflow-x: auto;
        min-height: auto;
        align-items: center;
    }
    
    /* 图片尺寸调整 */
    .yhsm-product-image {
        flex: 0 0 30px;
        height: 30px;
        margin-right: 5px;
    }
    
    /* 产品信息调整 */
    .yhsm-product-info {
        flex: 1;
        min-width: 110px;
    }
    
    /* 价格列宽调整 - 确保折扣价格正确显示 */
    .yhsm-product-price {
        flex: 0 0 50px;
        font-size: 11px;
        padding-right: 2px;
    }
    
    .yhsm-product-discount-price {
        flex: 0 0 60px;
        font-size: 11px;
        padding-right: 2px;
    }
    
    /* 隐藏不匹配的容器，避免冲突 */
    .yhsm-price-info {
        display: none !important;
    }
    
    /* 数量输入框调整 */
    .yhsm-product-quantity {
        flex: 0 0 45px;
    }
    
    .yhsm-quantity-input {
        width: 40px;
        height: 26px;
        font-size: 13px;
    }
    
    /* 小计调整 */
    .yhsm-product-subtotal {
        flex: 0 0 50px;
        font-size: 11px;
        padding-right: 2px;
    }
    
    /* 调整字体大小 */
    .yhsm-product-name {
        font-size: 12px;
        line-height: 1.2;
    }
    
    .yhsm-product-sku {
        font-size: 10px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
    
    /* 底部操作栏优化 */
    .yhsm-bottom-bar {
        padding: 15px 10px;
        gap: 15px;
    }
    
    /* 按钮优化 */
    .yhsm-button-primary {
        height: 40px;
        font-size: 14px;
        min-height: 40px;
    }
}

/* 表头样式优化 */
.yhsm-product-header .yhsm-product-row {
    padding: 10px 12px;
    font-size: 12px;
    font-weight: 600;
}

.yhsm-product-header .yhsm-product-name,
.yhsm-product-header .yhsm-product-price,
.yhsm-product-header .yhsm-product-discount-price,
.yhsm-product-header .yhsm-product-quantity,
.yhsm-product-header .yhsm-product-subtotal {
    color: white;
}

/* 响应式设计 - 自适应不同屏幕尺寸 */
@media (max-width: 992px) {
    .yhsm-fast-order-container {
        padding: 15px;
        margin: 15px;
    }
    
    .yhsm-product-row {
        padding: 10px;
    }
    
    .yhsm-price-info {
        flex: 0 0 120px;
    }
    
    .yhsm-product-quantity {
        flex: 0 0 80px;
    }
    
    .yhsm-product-subtotal {
        flex: 0 0 80px;
    }
}

/* 移动设备优化 - 修复折扣价格显示和整体布局 */
@media (max-width: 768px) {
    .yhsm-fast-order-container {
        padding: 10px;
        margin: 0;
        box-shadow: none;
        max-width: 100%;
        overflow-x: hidden;
    }
    
    /* 输入框优化 */
    #yhsm-sku-input {
        height: 100px;
        font-size: 16px; /* 防止iOS缩放 */
        padding: 10px;
    }
    
    /* 按钮优化 */
    #yhsm-check-button,
    #yhsm-add-to-cart {
        height: 44px;
        font-size: 16px;
        padding: 0 20px;
    }
    
    /* 触摸优化 */
    #yhsm-check-button:active:not(:disabled),
    #yhsm-add-to-cart:active:not(:disabled) {
        transform: scale(0.98);
        opacity: 0.9;
    }
    
    /* 输入框优化 */
    .yhsm-quantity-input {
        width: 70px;
        height: 36px;
        font-size: 16px;
        padding: 0 8px;
    }
    
    /* 表头样式 - 确保所有列可见 */
    .yhsm-product-header .yhsm-product-row {
        font-size: 12px;
        padding: 8px 5px;
    }
    
    /* 修复HTML结构与CSS类名不匹配的问题 */
    /* 产品行布局 */
    .yhsm-product-row {
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        justify-content: space-between;
    }
    
    /* 调整列宽 - 确保折扣价格正确显示 */
    .yhsm-product-image {
        flex: 0 0 40px;
        height: 40px;
        margin-right: 8px;
    }
    
    .yhsm-product-info {
        flex: 1;
        min-width: 150px;
    }
    
    .yhsm-product-price {
        flex: 0 0 60px;
        font-size: 13px;
        text-align: center;
    }
    
    .yhsm-product-discount-price {
        flex: 0 0 70px;
        font-size: 13px;
        text-align: center;
        color: #e53935;
        font-weight: bold;
    }
    
    .yhsm-product-quantity {
        flex: 0 0 60px;
        text-align: center;
    }
    
    .yhsm-product-subtotal {
        flex: 0 0 60px;
        text-align: right;
    }
    
    /* 确保价格信息正确显示 */
    .yhsm-price-info {
        display: none; /* 隐藏不匹配的容器，避免冲突 */
    }
    
    /* 调整字体大小 */
    .yhsm-product-name {
        font-size: 14px;
    }
    
    .yhsm-product-sku {
        font-size: 12px;
    }
    
    .yhsm-discount-price {
        font-size: 14px;
    }
    
    .yhsm-regular-price {
        font-size: 11px;
        text-decoration: line-through;
    }
    
    /* 输入框聚焦优化 */
    #yhsm-sku-input:focus,
    .yhsm-quantity-input:focus {
        outline: 2px solid #3498db;
        outline-offset: 2px;
    }
}

/* 平板设备优化 - 增强布局一致性 */
@media (min-width: 769px) and (max-width: 1024px) {
    .yhsm-fast-order-container {
        padding: 15px;
    }
    
    .yhsm-product-row {
        padding: 12px 10px;
    }
    
    .yhsm-product-image {
        flex: 0 0 50px;
        width: 50px;
        height: 50px;
    }
    
    .yhsm-product-info {
        min-width: 180px;
        padding-right: 12px;
    }
    
    .yhsm-product-name {
        font-size: 14px;
    }
    
    .yhsm-product-sku {
        font-size: 12px;
    }
    
    .yhsm-product-price,
    .yhsm-product-discount-price {
        flex: 0 0 70px;
        font-size: 14px;
    }
    
    .yhsm-product-quantity {
        flex: 0 0 90px;
    }
    
    .yhsm-quantity-input {
        width: 50px;
        height: 28px;
        font-size: 14px;
    }
    
    .yhsm-product-subtotal {
        flex: 0 0 80px;
        font-size: 14px;
    }
    
    /* 表头适配平板 */
    .yhsm-product-header .yhsm-product-row {
        height: 44px;
        padding: 10px 10px;
        font-size: 13px;
    }

/* 小屏幕手机优化 */
@media (max-width: 480px) {
    /* 确保所有列可见且正确对齐 */
    .yhsm-product-header .yhsm-product-row {
        font-size: 11px;
        padding: 6px 3px;
        overflow-x: auto;
    }
    
    /* 产品行布局优化 */
    .yhsm-product-row {
        padding: 6px 3px;
    }
    
    /* 隐藏不匹配的容器，避免冲突 */
    .yhsm-price-info {
        display: none !important;
    }
    
    /* 调整列宽 - 确保所有信息可见 */
    .yhsm-product-image {
        flex: 0 0 35px;
        height: 35px;
        margin-right: 6px;
    }
    
    .yhsm-product-info {
        flex: 1;
        min-width: 130px;
    }
    
    .yhsm-product-price {
        flex: 0 0 55px;
        font-size: 12px;
    }
    
    .yhsm-product-discount-price {
        flex: 0 0 65px;
        font-size: 12px;
    }
    
    .yhsm-product-quantity {
        flex: 0 0 50px;
    }
    
    .yhsm-product-subtotal {
        flex: 0 0 55px;
    }
    
    /* 调整字体大小 */
    .yhsm-product-name {
        font-size: 13px;
    }
    
    .yhsm-product-sku {
        font-size: 11px;
    }
    
    /* 输入框优化 */
    .yhsm-quantity-input {
        width: 45px;
        height: 30px;
        font-size: 14px;
    }
}

.yhsm-no-discount {
    color: #333;
    font-weight: 600;
    font-size: 18px;
}

/* 会员折扣标签样式 */
.yhsm-member-discount-tag {
    display: inline-block;
    background-color: #f1c40f;
    color: #333;
    font-size: 12px;
    padding: 2px 8px;
    border-radius: 3px;
    margin-left: 8px;
    font-weight: bold;
}

/* 搜索插件的会员折扣标签样式 */
.clean-role-discount-tag {
    display: inline-block;
    background-color: #f1c40f;
    color: #333;
    font-size: 12px;
    padding: 2px 8px;
    border-radius: 3px;
    margin-left: 8px;
    font-weight: bold;
}

/* 原有数量样式被替换为输入框样式 */

/* 底部操作栏 */
.yhsm-bottom-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 6px;
    border-top: 1px solid #eee;
    flex-wrap: wrap;
    gap: 20px;
}

.yhsm-total-info {
    display: flex;
    gap: 30px;
    font-size: 16px;
}

.yhsm-total-info span {
    font-weight: 500;
    color: #333;
}

.yhsm-total-info strong {
    color: #e53935;
    font-size: 18px;
}

/* 加载和错误提示 */
.yhsm-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px;
    text-align: center;
    transition: opacity 0.3s ease;
}

/* 加载动画 - 移动端优化 */
.yhsm-loading-active {
    opacity: 1 !important;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0% {
        opacity: 0.6;
    }
    50% {
        opacity: 1;
    }
    100% {
        opacity: 0.6;
    }
}

/* 顶部加载条 - 移动端专用 */
.yhsm-top-loading {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: transparent;
    z-index: 9999;
}

.yhsm-top-loading-active {
    background-color: #e74c3c;
    animation: progress 2s infinite ease-in-out;
}

@keyframes progress {
    0% {
        width: 0;
        left: 0;
    }
    50% {
        width: 50%;
        left: 25%;
    }
    100% {
        width: 0;
        left: 100%;
    }
}

.yhsm-loading-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #4CAF50;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 15px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.yhsm-error-message {
    background: #ffebee;
    border-left: 4px solid #f44336;
    padding: 15px;
    margin: 20px 0;
    border-radius: 4px;
    transition: all 0.3s ease;
}

/* 错误提示动画 - 移动端优化 */
.yhsm-error-active {
    animation: shake 0.5s ease-in-out, fadeOut 5s ease-out;
    animation-delay: 0s, 0.5s;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

@keyframes fadeOut {
    0% { opacity: 1; }
    100% { opacity: 0.8; }
}

.yhsm-error-message p {
    color: #c62828;
    margin: 0;
    font-weight: 500;
}

/* 空结果状态 */
.yhsm-empty-result {
    text-align: center;
    padding: 40px;
    color: #666;
}

/* 底部操作栏响应式调整 */
@media (max-width: 768px) {
    .yhsm-fast-order-container {
        margin: 15px;
        padding: 15px;
    }
    
    .yhsm-bottom-bar {
        flex-direction: column;
        align-items: stretch;
    }
    
    .yhsm-total-info {
        flex-direction: column;
        gap: 10px;
    }
    
    .yhsm-button-primary {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .yhsm-product-item {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .yhsm-product-image {
        margin-bottom: 15px;
    }
}

/* 图片上传区域样式 */
.yhsm-image-upload-section {
    margin: 20px 0;
    padding: 15px;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    background-color: #f9f9f9;
}

.yhsm-image-upload-section h4 {
    margin: 0 0 15px 0;
    color: #333;
    font-size: 14px;
    font-weight: 600;
}

.yhsm-upload-area {
    position: relative;
    border: 2px dashed #ddd;
    border-radius: 6px;
    padding: 30px;
    text-align: center;
    background-color: #ffffff;
    transition: all 0.3s ease;
}

.yhsm-upload-area:hover {
    border-color: #4CAF50;
    background-color: #f0f8f0;
}

.yhsm-file-input {
    display: none;
}

.yhsm-upload-label {
    display: block;
    cursor: pointer;
    transition: all 0.3s ease;
}

.yhsm-upload-label:hover {
    color: #4CAF50;
}

.yhsm-upload-icon {
    font-size: 48px;
    margin-bottom: 10px;
}

.yhsm-upload-label p {
    margin: 5px 0;
    color: #666;
    font-size: 14px;
}

.yhsm-upload-hint {
    font-size: 12px !important;
    color: #999 !important;
}

/* 图片预览样式 */
.yhsm-image-preview {
    position: relative;
    margin-top: 15px;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.yhsm-image-preview img {
    width: 100%;
    max-height: 300px;
    object-fit: contain;
    background-color: #f5f5f5;
}

.yhsm-remove-button {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 30px;
    height: 30px;
    background-color: rgba(255, 255, 255, 0.9);
    border: none;
    border-radius: 50%;
    font-size: 20px;
    font-weight: bold;
    color: #e74c3c;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.yhsm-remove-button:hover {
    background-color: #e74c3c;
    color: white;
    transform: scale(1.1);
}

/* OCR 状态样式 */
.yhsm-ocr-status {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 15px;
    padding: 15px;
    background-color: #f0f8f0;
    border-radius: 6px;
}

.yhsm-ocr-spinner {
    width: 20px;
    height: 20px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #4CAF50;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-right: 10px;
}

.yhsm-ocr-status p {
    margin: 0;
    color: #333;
    font-size: 14px;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .yhsm-upload-area {
        padding: 20px;
    }
    
    .yhsm-upload-icon {
        font-size: 36px;
    }
    
    .yhsm-upload-label p {
        font-size: 13px;
    }
    
    .yhsm-image-preview img {
        max-height: 200px;
    }
}

@media (max-width: 480px) {
    .yhsm-image-upload-section {
        padding: 10px;
    }
    
    .yhsm-upload-area {
        padding: 15px;
    }
    
    .yhsm-upload-icon {
        font-size: 28px;
    }
    
    .yhsm-upload-label p {
        font-size: 12px;
    }
    
    .yhsm-image-preview img {
        max-height: 150px;
    }
}