/**
 * 链接分享系统样式表
 * 设计原则：美观、整洁、大方、动态、多彩
 */

:root {
    --primary-color: #4e73df;
    --secondary-color: #1cc88a;
    --success-color: #1cc88a;
    --info-color: #36b9cc;
    --warning-color: #f6c23e;
    --danger-color: #e74a3b;
    --light-color: #f8f9fc;
    --dark-color: #5a5c69;
    --gradient-primary: linear-gradient(135deg, #4e73df 0%, #224abe 100%);
    --gradient-secondary: linear-gradient(135deg, #1cc88a 0%, #13855c 100%);
    --shadow-sm: 0 .125rem .25rem rgba(0, 0, 0, .075);
    --shadow: 0 .5rem 1rem rgba(0, 0, 0, .15);
    --shadow-lg: 0 1rem 3rem rgba(0, 0, 0, .175);
    --transition-speed: 0.3s;
}

body {
    background-color: #f8f9fc;
    font-family: 'Nunito', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: #5a5c69;
    line-height: 1.6;
    padding-bottom: 2rem;
}

/* 页面标题 */
.page-header {
    background: var(--gradient-primary);
    color: white;
    padding: 2rem 0;
    margin-bottom: 2rem;
    box-shadow: var(--shadow);
    position: relative;
    overflow: hidden;
}

.page-header::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 200%;
    background: rgba(255, 255, 255, 0.1);
    transform: rotate(30deg);
}

.page-header h1 {
    font-weight: 700;
    margin-bottom: 0.5rem;
    position: relative;
    z-index: 1;
}

.page-header p {
    opacity: 0.9;
    margin-bottom: 0;
    position: relative;
    z-index: 1;
}

/* 卡片样式 */
.card {
    border-radius: 0.5rem;
    border: none;
    box-shadow: var(--shadow-sm);
    transition: transform var(--transition-speed), box-shadow var(--transition-speed);
    overflow: hidden;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow);
}

.card-header {
    background-color: white;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    font-weight: 600;
}

.card-title {
    font-weight: 600;
    color: var(--primary-color);
}

/* 链接卡片 */
.link-card {
    transition: all var(--transition-speed);
}

.link-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow);
}

.link-card .card-body {
    padding: 1.5rem;
}

.link-card .card-title {
    margin-bottom: 0.75rem;
    font-size: 1.1rem;
}

.link-card .card-footer {
    background-color: rgba(0, 0, 0, 0.02);
    padding: 0.75rem 1.5rem;
}

.border-primary {
    border-left: 4px solid var(--primary-color) !important;
    border-top: none !important;
    border-right: none !important;
    border-bottom: none !important;
}

.border-success {
    border-left: 4px solid var(--success-color) !important;
    border-top: none !important;
    border-right: none !important;
    border-bottom: none !important;
}

.border-info {
    border-left: 4px solid var(--info-color) !important;
    border-top: none !important;
    border-right: none !important;
    border-bottom: none !important;
}

/* 表单样式 */
.form-control {
    border-radius: 0.5rem;
    padding: 0.75rem 1rem;
    border: 1px solid #d1d3e2;
    font-size: 0.9rem;
    transition: border-color var(--transition-speed), box-shadow var(--transition-speed);
}

.form-control:focus {
    border-color: #bac8f3;
    box-shadow: 0 0 0 0.2rem rgba(78, 115, 223, 0.25);
}

.btn {
    border-radius: 0.5rem;
    padding: 0.75rem 1.5rem;
    font-weight: 600;
    transition: all var(--transition-speed);
}

.btn-primary {
    background: var(--gradient-primary);
    border: none;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #3a5fc8 0%, #1a3a9c 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(78, 115, 223, 0.3);
}

.btn-success {
    background: var(--gradient-secondary);
    border: none;
}

.btn-success:hover {
    background: linear-gradient(135deg, #18ad76 0%, #0f6e4a 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(28, 200, 138, 0.3);
}

/* 分隔线 */
.section-divider {
    display: flex;
    align-items: center;
    margin: 2rem 0;
}

.section-divider::before,
.section-divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid #e3e6f0;
}

.section-divider h5 {
    padding: 0 1rem;
    margin-bottom: 0;
    white-space: nowrap;
    color: #b7b9cc;
    font-weight: 600;
}

/* 动画效果 */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 0.5s ease-out forwards;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .page-header {
        padding: 1.5rem 0;
    }
    
    .card-body {
        padding: 1.25rem;
    }
    
    .btn {
        padding: 0.6rem 1.2rem;
    }
}

/* 自定义滚动条 */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* 链接码结果区域 */
#linkCodeResult {
    transition: all var(--transition-speed);
}

/* 重要链接区域 */
#importantLinks .row {
    margin-bottom: 1.5rem;
}

/* 通知样式增强 */
.swal2-popup {
    border-radius: 0.5rem !important;
    padding: 1rem !important;
}

.swal2-title {
    font-size: 1.25rem !important;
}

.swal2-content {
    font-size: 0.9rem !important;
}

/* 加载动画 */
.spinner-border {
    width: 2rem;
    height: 2rem;
}

/* 链接选项 */
.url-option {
    transition: all var(--transition-speed);
}

.url-option:hover {
    background-color: #f8f9fc;
    transform: translateX(5px);
}

/* 用户信息区域 */
.user-info {
    background-color: white;
    border-radius: 0.5rem;
    padding: 1rem;
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow-sm);
}

.user-info .user-name {
    font-weight: 600;
    color: var(--primary-color);
}

.user-info .badge {
    margin-right: 0.25rem;
    margin-bottom: 0.25rem;
}

/* 页脚 */
.footer {
    margin-top: 3rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e3e6f0;
    text-align: center;
    color: #858796;
    font-size: 0.875rem;
}