/**
 * 前端订单查询样式
 * Custom Order Status Plugin
 */

.cos-tracking-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 40px 20px;
}

/* 标题 */
.cos-tracking-header {
    text-align: center;
    margin-bottom: 40px;
}

.cos-tracking-header h2 {
    font-size: 32px;
    color: #333;
    margin: 0;
}

/* 查询表单 */
.cos-tracking-search {
    max-width: 600px;
    margin: 0 auto 40px;
}

.cos-search-form {
    display: flex;
    gap: 10px;
}

.cos-search-form input[type="text"] {
    flex: 1;
    padding: 15px 20px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 16px;
    transition: border-color 0.3s;
}

.cos-search-form input[type="text"]:focus {
    outline: none;
    border-color: #2196F3;
}

.cos-btn {
    padding: 15px 30px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.cos-btn-primary {
    background-color: #2196F3;
    color: white;
}

.cos-btn-primary:hover {
    background-color: #1976D2;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(33, 150, 243, 0.4);
}

/* 查询结果 */
.cos-tracking-result {
    animation: fadeIn 0.5s;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 订单卡片 */
.cos-order-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
    overflow: hidden;
}

.cos-order-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 30px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.cos-order-header h3 {
    margin: 0;
    font-size: 20px;
}

.cos-order-number {
    font-size: 18px;
    font-weight: 600;
    font-family: monospace;
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 8px;
}

.cos-order-body {
    padding: 30px;
}

.cos-info-row {
    display: flex;
    justify-content: space-between;
    padding: 15px 0;
    border-bottom: 1px solid #f0f0f0;
}

.cos-info-row:last-child {
    border-bottom: none;
}

.cos-label {
    font-weight: 600;
    color: #666;
}

.cos-status {
    display: inline-block;
    padding: 6px 16px;
    border-radius: 20px;
    color: white;
    font-size: 14px;
    font-weight: 600;
}

.cos-tracking-number {
    font-family: monospace;
    font-size: 16px;
    color: #2196F3;
    font-weight: 600;
}

/* 物流信息 */
.cos-logistics-info {
    margin-top: 20px;
    padding: 20px;
    background: #f9f9f9;
    border-radius: 8px;
}

.cos-logistics-info h4 {
    margin-top: 0;
    margin-bottom: 15px;
    color: #333;
}

.cos-logistics-info .cos-info-row {
    border-bottom: none;
    padding: 10px 0;
}

/* 进度时间轴 */
.cos-progress-timeline {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
    padding: 30px;
    margin-bottom: 30px;
}

.cos-progress-timeline h3 {
    margin-top: 0;
    margin-bottom: 30px;
    font-size: 24px;
    color: #333;
}

.cos-timeline {
    position: relative;
}

.cos-timeline::before {
    content: '';
    position: absolute;
    left: 20px;
    top: 20px;
    bottom: 20px;
    width: 3px;
    background: linear-gradient(180deg, #4CAF50 0%, #ccc 100%);
}

.cos-timeline-step {
    position: relative;
    padding-left: 70px;
    margin-bottom: 30px;
}

.cos-timeline-step:last-child {
    margin-bottom: 0;
}

.cos-step-marker {
    position: absolute;
    left: 0;
    top: 0;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: white;
    border: 4px solid white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    transition: all 0.3s;
}

.cos-timeline-step.completed .cos-step-marker {
    transform: scale(1);
}

.cos-timeline-step.current .cos-step-marker {
    transform: scale(1.2);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% {
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
    }
    50% {
        box-shadow: 0 4px 20px rgba(33, 150, 243, 0.5);
    }
}

.cos-timeline-step.pending .cos-step-marker {
    opacity: 0.5;
}

.cos-step-content h4 {
    margin: 0 0 8px 0;
    font-size: 18px;
    color: #333;
}

.cos-timeline-step.pending .cos-step-content h4 {
    color: #999;
}

.cos-step-content p {
    margin: 0;
    color: #666;
    font-size: 14px;
}

.cos-timeline-step.pending .cos-step-content p {
    color: #bbb;
}

/* 媒体画廊 */
.cos-media-gallery {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
    padding: 30px;
    margin-bottom: 30px;
}

.cos-media-gallery h3 {
    margin-top: 0;
    margin-bottom: 20px;
    font-size: 24px;
    color: #333;
}

.cos-gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 15px;
}

.cos-gallery-item {
    position: relative;
    padding-top: 100%;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s, box-shadow 0.3s;
}

.cos-gallery-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.cos-gallery-item img,
.cos-gallery-item video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* 备注信息 */
.cos-order-notes {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
    padding: 30px;
}

.cos-order-notes h3 {
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 20px;
    color: #333;
}

.cos-order-notes p {
    margin: 0;
    line-height: 1.8;
    color: #666;
}

/* 错误提示 */
.cos-tracking-error {
    text-align: center;
    padding: 60px 20px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
}

.cos-tracking-error p {
    font-size: 18px;
    color: #d32f2f;
    margin: 0;
}

/* 响应式 */
@media (max-width: 768px) {
    .cos-tracking-container {
        padding: 20px 15px;
    }
    
    .cos-tracking-header h2 {
        font-size: 24px;
    }
    
    .cos-search-form {
        flex-direction: column;
    }
    
    .cos-order-header {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
    
    .cos-info-row {
        flex-direction: column;
        gap: 8px;
    }
    
    .cos-timeline::before {
        left: 15px;
    }
    
    .cos-timeline-step {
        padding-left: 60px;
    }
    
    .cos-step-marker {
        width: 32px;
        height: 32px;
        font-size: 16px;
    }
    
    .cos-gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }
}

