/* 个人中心页面样式 */

/* 设置按钮 */
.settings-btn {
    color: #666;
    text-decoration: none;
    font-size: 16px;
    padding: 6px;
    border-radius: 4px;
    transition: background-color 0.2s;
}

.settings-btn:hover {
    background-color: #f5f5f5;
    color: #e4393c;
}

/* 个人中心容器 */
.profile-container {
    margin-top: 56px;
    padding-bottom: 70px;
    min-height: calc(100vh - 126px);
}

/* 用户信息卡片 */
.user-card {
    background: linear-gradient(135deg, #e4393c 0%, #d43333 100%);
    color: white;
    padding: 24px 16px;
    margin-bottom: 12px;
}

.user-info {
    display: flex;
    align-items: center;
    margin-bottom: 16px;
}

.user-avatar {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    overflow: hidden;
    margin-right: 16px;
    border: 3px solid rgba(255,255,255,0.3);
}

.user-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.user-details h2 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 4px;
}

.user-phone {
    font-size: 12px;
    opacity: 0.9;
    margin-bottom: 8px;
}

.user-level {
    display: flex;
    align-items: center;
    gap: 12px;
}

.level-badge {
    background: rgba(255,255,255,0.2);
    padding: 3px 10px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 500;
}

.points {
    font-size: 12px;
    opacity: 0.9;
}

.user-actions {
    text-align: center;
}

.edit-profile-btn {
    background: rgba(255,255,255,0.2);
    color: white;
    text-decoration: none;
    padding: 8px 16px;
    border-radius: 4px;
    font-size: 12px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: background-color 0.2s;
}

.edit-profile-btn:hover {
    background: rgba(255,255,255,0.3);
}

/* 快捷功能 */
.quick-actions {
    background: white;
    margin: 12px;
    border-radius: 8px;
    padding: 16px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.action-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.action-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: #333;
    transition: transform 0.2s;
}

.action-item:hover {
    transform: translateY(-1px);
}

.action-icon {
    width: 44px;
    height: 44px;
    border-radius: 8px;
    background: #f8f9fa;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 8px;
    color: #e4393c;
    font-size: 18px;
}

.action-item:nth-child(2) .action-icon {
    background: #fff2f0;
    color: #ff4d4f;
}

.action-item:nth-child(3) .action-icon {
    background: #f6ffed;
    color: #52c41a;
}

.action-item:nth-child(4) .action-icon {
    background: #e6f7ff;
    color: #1890ff;
}

.action-item span {
    font-size: 11px;
    text-align: center;
}

/* 订单状态 */
.order-status {
    background: white;
    margin: 12px;
    border-radius: 8px;
    padding: 16px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.section-header h3 {
    font-size: 16px;
    font-weight: 600;
    color: #333;
}

.view-all {
    color: #999;
    text-decoration: none;
    font-size: 12px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.status-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}

.status-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: #333;
    transition: transform 0.2s;
}

.status-item:hover {
    transform: translateY(-1px);
}

.status-icon {
    position: relative;
    width: 44px;
    height: 44px;
    border-radius: 8px;
    background: #f8f9fa;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 6px;
    color: #e4393c;
    font-size: 18px;
}

.status-count {
    position: absolute;
    top: -4px;
    right: -4px;
    background: #e4393c;
    color: white;
    font-size: 9px;
    padding: 1px 4px;
    border-radius: 8px;
    min-width: 14px;
    text-align: center;
    font-weight: 500;
}

.status-item span {
    font-size: 11px;
    text-align: center;
}

/* 最近订单 */
.recent-orders {
    background: white;
    margin: 12px;
    border-radius: 8px;
    padding: 16px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.order-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.order-item {
    border: 1px solid #f0f0f0;
    border-radius: 8px;
    padding: 12px;
    transition: box-shadow 0.2s;
}

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

.order-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid #f0f0f0;
}

.order-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.order-id {
    font-size: 12px;
    font-weight: 500;
    color: #333;
}

.order-date {
    font-size: 11px;
    color: #999;
}

.order-status-badge {
    padding: 3px 8px;
    border-radius: 10px;
    font-size: 10px;
    font-weight: 500;
}

.order-status-badge.pending {
    background: #fff7e6;
    color: #fa8c16;
}

.order-status-badge.shipped {
    background: #e6f7ff;
    color: #1890ff;
}

.order-status-badge.completed {
    background: #f6ffed;
    color: #52c41a;
}

.order-items {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.order-item-image {
    width: 44px;
    height: 44px;
    border-radius: 6px;
    overflow: hidden;
    flex-shrink: 0;
    background: #f8f9fa;
}

.order-item-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.order-total {
    flex: 1;
    text-align: right;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.order-total span:first-child {
    font-size: 11px;
    color: #999;
}

.total-price {
    font-size: 14px;
    font-weight: 600;
    color: #e4393c;
}

.order-actions {
    display: flex;
    gap: 8px;
}

.action-btn {
    flex: 1;
    padding: 6px 12px;
    border: none;
    border-radius: 4px;
    font-size: 11px;
    cursor: pointer;
    transition: all 0.2s;
}

.action-btn.primary {
    background: #e4393c;
    color: white;
}

.action-btn.primary:hover {
    background: #d43333;
}

.action-btn.secondary {
    background: #f8f9fa;
    color: #666;
    border: 1px solid #e5e5e5;
}

.action-btn.secondary:hover {
    background: #f0f0f0;
}

/* 设置菜单 */
.settings-menu {
    margin: 12px;
}

.menu-section {
    background: white;
    border-radius: 8px;
    margin-bottom: 12px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    overflow: hidden;
}

.menu-item {
    display: flex;
    align-items: center;
    padding: 12px 16px;
    text-decoration: none;
    color: #333;
    border-bottom: 1px solid #f0f0f0;
    transition: background-color 0.2s;
}

.menu-item:last-child {
    border-bottom: none;
}

.menu-item:hover {
    background: #f8f9fa;
}

.menu-icon {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    background: #f8f9fa;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 12px;
    color: #e4393c;
    font-size: 14px;
}

.menu-item span {
    flex: 1;
    font-size: 13px;
}

.menu-item i:last-child {
    color: #ccc;
    font-size: 10px;
}

/* 响应式设计 */
@media (max-width: 480px) {
    .user-info {
        flex-direction: column;
        text-align: center;
    }
    
    .user-avatar {
        margin-right: 0;
        margin-bottom: 12px;
    }
    
    .action-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    
    .status-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }
    
    .order-items {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
    
    .order-total {
        text-align: left;
        width: 100%;
    }
    
    .order-actions {
        flex-direction: column;
    }
}

/* 动画效果 */
@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.user-card,
.quick-actions,
.order-status,
.recent-orders,
.settings-menu {
    animation: slideInUp 0.4s ease-out;
}

.quick-actions { animation-delay: 0.1s; }
.order-status { animation-delay: 0.2s; }
.recent-orders { animation-delay: 0.3s; }
.settings-menu { animation-delay: 0.4s; } 