/* 字体汇集插件前台样式 */

/* 全局容器样式 */
.xb_freefont_container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
    background: linear-gradient(135deg, #a8edea, #fed6e3);
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

/* 主标题样式 */
.xb_freefont_title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #4a1e6b;
    text-align: center;
    margin-bottom: 40px;
    padding-bottom: 10px;
    border-bottom: 3px solid #7c3aed;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.1);
}

/* 提示通知样式 */
.xb_freefont_notice {
    margin-bottom: 20px;
}

.xb_freefont_notice .notice {
    padding: 12px 16px;
    border-radius: 6px;
    font-size: 0.9rem;
}

.xb_freefont_notice .notice-success {
    background-color: #e6fafa;
    border-left: 5px solid #14b8a6;
    color: #0d9488;
}

.xb_freefont_notice .notice-error {
    background-color: #fee4e6;
    border-left: 5px solid #ef1d48;
    color: #9f1239;
}

/* 分类导航样式 */
.xb_freefont_categories {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    justify-content: center;
}

.xb_freefont_category {
    padding: 10px 20px;
    background: linear-gradient(90deg, #14b8a6, #0d9488);
    color: #fff;
    border-radius: 5px;
    text-decoration: none !important;
    transition: all 0.3s ease;
    font-weight: 500;
}

.xb_freefont_category:hover,
.xb_freefont_category.active {
    background: linear-gradient(90deg, #7c3aed, #6d28d9);
    color: #ffffff;
    transform: translateY(-3px);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.2);
}

/* 表格样式 */
.xb_freefont_table {
    display: grid;
    grid-template-columns: 2fr 1fr 0.8fr 0.8fr 1.2fr 1fr 1fr 1fr 3fr;
    background-color: #ffffff;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 20px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.xb_freefont_table_header {
    display: contents;
}

.xb_freefont_table_row {
    display: contents;
}

.xb_freefont_table_row.even .xb_freefont_table_cell {
    background-color: #fefbff;
}

.xb_freefont_table_row.odd .xb_freefont_table_cell {
    background-color: #f5f3ff;
}

.xb_freefont_table_cell {
    padding: 14px;
    border-bottom: 1px solid #e5e7eb;
    align-items: center;
    color: #1f2937;
}

.xb_freefont_table_header .xb_freefont_table_cell {
    background: linear-gradient(90deg, #7c3aed, #6d28d9);
    color: #ffffff;
    font-weight: 600;
    text-align: center;
}

.xb_freefont_table_row:hover .xb_freefont_table_cell {
    background-color: #ede9fe;
}

.xb_freefont_font_name {
    font-weight: 600;
    color: #4a1e6b;
}

/* 字体总数统计样式 */
.xb_freefont_count {
    text-align: center;
    padding: 15px;
    background: linear-gradient(90deg, #fefbff, #f5f3ff);
    border-radius: 8px;
    margin-bottom: 20px;
    font-size: 1.1rem;
    color: #4a1e6b;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.xb_freefont_count_number {
    font-weight: 700;
    color: #7c3aed;
}

/* 预览图片样式 */
.xb_freefont_preview_image {
    max-width: 100px;
    max-height: 50px;
    object-fit: contain;
    border-radius: 4px;
    cursor: pointer;
    margin: 0 auto;
    display: block;
}

/* 按钮和链接样式 */
.xb_freefont_download, .xb_freefont_link {
    width: 90px;
    line-height: 1.5;
    padding: 6px 0;
    text-align: center;
    border-radius: 6px;
    transition: all 0.3s ease;
    box-sizing: border-box;
    cursor: pointer;
    text-decoration: none !important;
    display: inline-block;
}

.xb_freefont_download.font {
    background: linear-gradient(90deg, #14b8a6, #0d9488);
    color: #ffffff;
}

.xb_freefont_download.cloud {
    background: linear-gradient(90deg, #7c3aed, #6d28d9);
    color: #ffffff;
}

.xb_freefont_link {
    background: linear-gradient(90deg, #f472b6, #db2777);
    color: #ffffff;
}

.xb_freefont_download:hover,
.xb_freefont_link:hover {
    transform: translateY(-2px);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.2);
}

/* 分页按钮样式 */
.xb_freefont_page_link {
    padding: 8px 16px;
    background: linear-gradient(90deg, #e5e7eb, #d1d5db);
    color: #1f2937;
    border-radius: 5px;
    text-decoration: none !important;
    transition: all 0.3s ease;
}

.xb_freefont_page_link.current,
.xb_freefont_page_link:hover {
    background: linear-gradient(90deg, #7c3aed, #6d28d9);
    color: #ffffff;
    transform: translateY(-2px);
}

/* 分页容器样式 */
.xb_freefont_pagination {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
}

/* 广告内容样式 */
.xb_freefont_ad_content {
    padding: 20px;
    background-color: #ffffff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    margin-top: 20px;
}

.xb_freefont_ad_content img {
    max-width: 300px;
    max-height: 200px;
    object-fit: contain;
}

/* 密码弹窗样式 */
.xb_freefont_modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.xb_freefont_modal_content {
    background-color: #ffffff;
    padding: 20px;
    border-radius: 12px;
    max-width: 400px;
    width: 90%;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    text-align: center;
}

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

.xb_freefont_password_form .xb_freefont_instruction {
    font-size: 0.9rem;
    color: #888888;
    line-height: 1.5;
}

.xb_freefont_password_form input {
    padding: 10px;
    border: 1px solid #d1d5db;
    border-radius: 5px;
    font-size: 1rem;
}

.xb_freefont_password_form button {
    padding: 10px;
    background: linear-gradient(90deg, #7c3aed, #1d28d9);
    color: #ffffff;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 120px;
    align-self: center;
}

.xb_freefont_password_form button:hover {
    background: linear-gradient(90deg, #6d28d9, #5b21b6);
    transform: translateY(-2px);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.2);
}

/* 错误提示样式 */
.xb_freefont_error {
    color: #e11d48;
    background-color: #fee4e6;
    padding: 10px;
    border-radius: 6px;
    margin-bottom: 10px;
    font-size: 0.9rem;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .xb_freefont_table {
        display: block;
    }

    .xb_freefont_table_row {
        display: block;
        margin-bottom: 20px;
        border: 1px solid #d1d5db;
        border-radius: 8px;
        background-color: #ffffff;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    }

    .xb_freefont_table_row.even {
        background-color: #fffbff;
    }

    .xb_freefont_table_row.odd {
        background-color: #f3f3ff;
    }

    .xb_freefont_table_cell {
        display: block;
        padding: 12px 16px;
        border-bottom: none;
        border-top: 1px solid #e5e7eb;
        background-color: inherit;
    }

    .xb_freefont_table_header .xb_freefont_table_cell {
        display: none;
    }

    .xb_freefont_table_row .xb_freefont_table_cell::before {
        content: attr(data-label);
        font-weight: 600;
        color: #4a1e6b;
        margin-bottom: 5px;
        display: block;
    }

    .xb_freefont_table_row .xb_freefont_table_cell:nth-child(1)::before { content: "字体名称: "; }
    .xb_freefont_table_row .xb_freefont_table_cell:nth-child(2)::before { content: "版权协议: "; }
    .xb_freefont_table_row .xb_freefont_table_cell:nth-child(3)::before { content: "版本: "; }
    .xb_freefont_table_row .xb_freefont_table_cell:nth-child(4)::before { content: "大小: "; }
    .xb_freefont_table_row .xb_freefont_table_cell:nth-child(5)::before { content: "预览图片: "; }
    .xb_freefont_table_row .xb_freefont_table_cell:nth-child(6)::before { content: "官方链接: "; }
    .xb_freefont_table_row .xb_freefont_table_cell:nth-child(7)::before { content: "网盘链接: "; }
    .xb_freefont_table_row .xb_freefont_table_cell:nth-child(8)::before { content: "官网: "; }
    .xb_freefont_table_row .xb_freefont_table_cell:nth-child(9)::before { content: "说明: "; }

    .xb_freefont_title {
        font-size: 1.8rem;
        margin-bottom: 50px;
    }

    .xb_freefont_categories {
        flex-direction: column;
        align-items: center;
    }

    .xb_freefont_category {
        width: auto;
        min-width: 120px;
        text-align: center;
    }

    .xb_freefont_download,
    .xb_freefont_link,
    .xb_freefont_page_link,
    .xb_freefont_password_form button {
        width: 100px;
        height: 34px;
        line-height: 1.5;
        font-size: 0.9rem;
        padding: 8px 0;
        text-align: center;
        box-sizing: border-box;
    }

    .xb_freefont_modal_content {
        width: 95%;
        padding: 15px;
    }

    .xb_freefont_preview_image {
        max-width: 80px;
        max-height: 40px;
    }

    .xb_freefont_count {
        font-size: 0.95rem;
        padding: 10px;
    }
}