body {
    font-family: "Helvetica Neue", "PingFang SC", "Microsoft YaHei", sans-serif;
    background: linear-gradient(135deg, #ffeef8 0%, #fff5f7 50%, #f0f4ff 100%);
    color: #333;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    line-height: 1.6;
}

.nav-bar {
    background: rgba(255, 255, 255, 0.9);
    border-radius: 6px;
    padding: 12px 20px;
    margin-bottom: 25px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.back-btn {
    background: #e91e63;
    color: white;
    text-decoration: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.back-btn:hover {
    background: #c2185b;
    transform: translateY(-1px);
}

.page-title {
    color: #e91e63;
    font-size: 16px;
    font-weight: 600;
}

/* 使用说明卡片 */
.instruction-card {
    background: linear-gradient(135deg, #fff9e6, #ffe5f3);
    border-radius: 6px;
    padding: 20px 24px;
    margin-bottom: 30px;
    box-shadow: 0 4px 15px rgba(255, 200, 124, 0.2);
    border: 2px solid rgba(233, 30, 99, 0.1);
}

.instruction-title {
    font-size: 18px;
    font-weight: 600;
    color: #e91e63;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.title-icon {
    width: 24px;
    height: 24px;
    stroke: #e91e63;
    flex-shrink: 0;
}

.instruction-content {
    font-size: 15px;
    color: #555;
    line-height: 1.8;
}

.instruction-step {
    margin: 8px 0;
    padding-left: 20px;
    position: relative;
}

.instruction-step::before {
    content: "";
    position: absolute;
    left: 0;
    top: 8px;
    width: 8px;
    height: 8px;
    background: linear-gradient(135deg, #e91e63, #f06292);
    border-radius: 50%;
}

.instruction-tip {
    margin-top: 12px;
    padding: 10px 15px;
    background: rgba(233, 30, 99, 0.08);
    border-left: 3px solid #e91e63;
    border-radius: 6px;
    font-size: 14px;
    color: #c2185b;
    line-height: 1.6;
}

h1 {
    text-align: center;
    font-size: 28px;
    margin-bottom: 30px;
    background: linear-gradient(135deg, #e91e63, #9c27b0);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 700;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}
h2 {
    background-color: #fce4ec;
    color: #c2185b;
    padding: 10px 16px;
    border-left: 5px solid #ec407a;
    font-size: 17px;
    border-radius: 6px;
    margin-top: 30px;
}
pre {
    background-color: #fff;
    border: 1px solid #f8bbd0;
    padding: 14px;
    white-space: pre-wrap;
    word-wrap: break-word;
    font-size: 16px;
    border-radius: 6px;
    margin-top: 8px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.05);
    transition: all 0.2s;
}
pre:active {
    background-color: #fce4ec;
    transform: scale(0.98);
}
/* 排序功能样式 */
.tag-section {
    margin-bottom: 25px;
    position: relative;
    border-radius: 6px;
    background: #ffffff;
    padding: 20px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(0, 0, 0, 0.06);
}

.tag-section:hover {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
    transform: translateY(-2px);
}

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

.section-number {
    background: linear-gradient(135deg, #e91e63, #ad1457);
    color: white;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 600;
    margin-right: 12px;
    box-shadow: 0 4px 12px rgba(233, 30, 99, 0.3);
}

.section-title {
    flex: 1;
    margin: 0;
    background-color: #fce4ec;
    color: #c2185b;
    padding: 10px 16px;
    border-left: 5px solid #ec407a;
    font-size: 17px;
    border-radius: 6px;
}

.sort-controls {
    display: flex;
    gap: 8px;
    margin-left: 12px;
}

.sort-btn {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

.sort-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.sort-btn:active {
    transform: translateY(0);
}

.sort-input {
    width: 50px;
    padding: 4px 8px;
    border: 2px solid #e1bee7;
    border-radius: 6px;
    text-align: center;
    font-size: 12px;
    background: rgba(255, 255, 255, 0.9);
    -webkit-appearance: none;
    -moz-appearance: textfield;
    appearance: none;
}

.sort-input:focus {
    outline: none;
    border-color: #e91e63;
    box-shadow: 0 0 0 3px rgba(233, 30, 99, 0.1);
}

/* 移动端输入框优化 */
.sort-input::-webkit-outer-spin-button,
.sort-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.reset-btn {
    background: linear-gradient(135deg, #ff6b6b, #ee5a52);
    color: white;
    text-decoration: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(255, 107, 107, 0.3);
}

.reset-btn:hover {
    background: linear-gradient(135deg, #ff5252, #e53935);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(255, 107, 107, 0.4);
}

.nav-controls {
    display: flex;
    gap: 12px;
    align-items: center;
}

/* 手机版优化 */
@media (max-width: 768px) {
    body {
        padding: 10px;
    }
    
    .nav-bar {
        padding: 10px 12px;
        margin-bottom: 15px;
        border-radius: 6px;
        flex-wrap: wrap;
        gap: 10px;
    }
    
    .nav-controls {
        gap: 8px;
    }
    
    .back-btn, .reset-btn {
        font-size: 12px;
        padding: 6px 12px;
    }
    
    .page-title {
        font-size: 15px;
        flex: 1;
        min-width: 100%;
        order: -1;
    }
    
    h1 {
        font-size: 22px;
        margin-bottom: 15px;
    }
    
    .tag-section {
        padding: 12px;
        margin-bottom: 15px;
        border-radius: 6px;
    }
    
    .section-header {
        flex-wrap: wrap;
        gap: 8px;
    }
    
    .section-number {
        width: 28px;
        height: 28px;
        font-size: 12px;
    }
    
    .section-title {
        font-size: 16px;
        padding: 8px 12px;
        flex: 1;
        min-width: 200px;
    }
    
    .sort-controls {
        gap: 8px;
        margin-left: 0;
        flex-wrap: wrap;
        width: 100%;
        margin-top: 8px;
    }
    
    .sort-btn {
        font-size: 13px;
        padding: 8px 16px;
        flex: 1;
    }
    
    .sort-input {
        width: 80px;
        padding: 8px 12px;
        /* 移动端防止自动放大：字体必须>=16px */
        font-size: 16px;
    }
    
    pre {
        font-size: 15px;
        padding: 12px;
    }
}

/* 复制按钮样式 */
.copy-tags-btn {
    background: linear-gradient(135deg, #f472b6, #ec4899);
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(244, 114, 182, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 12px;
}

.copy-tags-btn:hover {
    background: linear-gradient(135deg, #ec4899, #db2777);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(244, 114, 182, 0.4);
}

.copy-tags-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(244, 114, 182, 0.3);
}

.full-width-copy-btn {
    width: 100%;
    margin-top: 12px;
}

.btn-icon {
    width: 18px;
    height: 18px;
    stroke: currentColor;
    fill: none;
    flex-shrink: 0;
}

/* 移动端复制按钮优化 */
@media (max-width: 768px) {
    .copy-tags-btn {
        font-size: 15px;
        padding: 14px 20px;
        margin-top: 10px;
    }
    
    .btn-icon {
        width: 16px;
        height: 16px;
    }
}
