/* 地址管理页面专用样式 */

/* 地址页面独立的page-container样式 */
.page-container {
    padding: 20px !important;
}

/* 左侧菜单栏样式 */
.sidebar-nav {
    background: #fff;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.profile-avatar {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--primary-color), #ff6b6b);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 15px;
    color: white;
    font-size: 32px;
}

.sidebar-nav h5 {
    font-weight: 600;
    color: #333;
    margin-bottom: 5px;
}

.nav-menu {
    list-style: none;
    padding: 0;
    margin: 0;
}

.nav-menu li {
    margin-bottom: 8px;
}

.nav-menu a {
    display: flex;
    align-items: center;
    padding: 12px 16px;
    color: #666;
    text-decoration: none;
    border-radius: 6px;
    transition: all 0.3s ease;
    font-size: 14px;
}

.nav-menu a:hover {
    background-color: #f8f9fa;
    color: var(--primary-color);
}

.nav-menu a.active {
    background-color: var(--primary-color);
    color: white;
}

.nav-menu a i {
    width: 20px;
    margin-right: 12px;
    text-align: center;
}

/* 地址卡片样式 */
.address-card {
    transition: all 0.3s ease;
    position: relative;
    border: 2px solid #e9ecef;
}

.address-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.address-card.border-primary {
    border-color: var(--primary-color) !important;
    box-shadow: 0 0 0 0.2rem rgba(var(--primary-color-rgb), 0.25);
}

/* 地址选择单选框样式 */
.address-radio {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.address-radio:checked {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

/* 地址操作按钮组 */
.address-actions {
    border-top: 1px solid #f8f9fa;
    padding-top: 12px;
    margin-top: 12px;
}

.address-actions .btn {
    font-size: 12px;
    padding: 6px 12px;
}

/* 添加新地址卡片样式 */
.card-custom[href] {
    transition: all 0.3s ease;
    border: 2px dashed #dee2e6;
    background-color: #f8f9fa;
}

.card-custom[href]:hover {
    border-color: var(--primary-color);
    background-color: #fff;
    text-decoration: none;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.card-custom[href]:hover .text-muted {
    color: var(--primary-color) !important;
}

.card-custom[href]:hover .fa-plus {
    color: var(--primary-color) !important;
}

/* 地址标签样式 */
.badge {
    font-size: 11px;
    padding: 4px 8px;
}

.badge.bg-primary {
    background-color: var(--primary-color) !important;
}

/* 页面标题和操作按钮区域 */
#pageActions {
    display: flex;
    gap: 12px;
}

#pageActions .btn {
    white-space: nowrap;
}

/* 地址信息文字样式 */
.address-card h5 {
    font-weight: 600;
    color: #333;
    margin-bottom: 4px;
}

.address-card p {
    line-height: 1.4;
}

.address-card .text-muted {
    font-size: 14px;
}

/* 删除动画 */
@keyframes fadeOut {
    from {
        opacity: 1;
        transform: scale(1);
    }
    to {
        opacity: 0;
        transform: scale(0.8);
    }
}

/* 响应式设计 */
@media (max-width: 767px) {
    /* 移动端页面容器样式 */
    .page-container {
        padding: 0 !important;
    }

    /* 移动端隐藏左侧菜单 */
    .col-md-3 {
        display: none;
    }
    
    .col-md-9 {
        flex: 0 0 100%;
        max-width: 100%;
    }
    
    /* 移动端地址管理内容块样式 */
    .col-md-9 > .d-flex.justify-content-between.align-items-center {
        margin: 20px 15px;
    }
    
    /* 移动端地址列表样式 */
    .col-md-9 > .row {
        padding: 0 15px;
    }
    
    .address-card {
        margin-bottom: 16px;
    }
    
    #pageActions {
        flex-direction: column;
        gap: 8px;
    }
    
    #pageActions .btn {
        width: 100%;
    }
    
    .address-actions {
        flex-wrap: wrap;
    }
    
    .address-actions .btn {
        flex: 1;
        min-width: 80px;
    }
    
    .d-flex.justify-content-between.align-items-center {
        flex-direction: row;
        align-items: stretch;
        gap: 16px;
    }
    
    #pageTitle {
        text-align: center;
        margin-bottom: 0;
    }
}

@media (max-width: 576px) {
    .address-actions .btn {
        font-size: 11px;
        padding: 5px 8px;
    }
    
    .card-custom[href] {
        min-height: 120px !important;
    }
    
    .card-custom[href] .fa-plus {
        font-size: 2rem !important;
    }
    
    .card-custom[href] h5 {
        font-size: 16px;
    }
}
