* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Microsoft YaHei', Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f9f5ea;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

header {
    background-color: #8a1f1f;
    color: white;
    padding: 15px 0;
    margin-bottom: 20px;
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
}

header h1 {
    font-size: 1.8rem;
}

nav ul {
    display: flex;
    list-style: none;
}

nav ul li {
    margin-left: 20px;
}

nav ul li a {
    color: white;
    text-decoration: none;
}

nav ul li a:hover {
    text-decoration: underline;
}

h2 {
    color: #8a1f1f;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #e8d0d0;
}

.recipe-list {
    display: grid;
    gap: 20px;
}

.recipe-card {
    background: white;
    padding: 20px;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    border-left: 4px solid #8a1f1f;
}

.recipe-card h3 {
    margin-bottom: 10px;
}

.recipe-card h3 a {
    color: #8a1f1f;
    text-decoration: none;
}

.recipe-card h3 a:hover {
    text-decoration: underline;
}

.recipe-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 10px;
    font-size: 0.9rem;
    color: #666;
}

.recipe-content {
    margin-bottom: 15px;
}

.btn {
    display: inline-block;
    background: #8a1f1f;
    color: white;
    padding: 8px 15px;
    text-decoration: none;
    border-radius: 4px;
    border: none;
    cursor: pointer;
}

.btn:hover {
    background: #a52a2a;
}

.btn.approve {
    background: #2e8b57;
}

.btn.approve:hover {
    background: #3cb371;
}

.btn.reject {
    background: #dc143c;
}

.btn.reject:hover {
    background: #ff4500;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.form-group textarea {
    min-height: 100px;
    resize: vertical;
}

.error {
    background: #ffebee;
    color: #c62828;
    padding: 10px;
    border-radius: 4px;
    margin-bottom: 20px;
}

.success {
    background: #e8f5e9;
    color: #2e7d32;
    padding: 10px;
    border-radius: 4px;
    margin-bottom: 20px;
}

.pagination {
    margin-top: 30px;
    display: flex;
    justify-content: center;
    gap: 5px;
}

.pagination a {
    padding: 8px 12px;
    border: 1px solid #ddd;
    text-decoration: none;
    color: #8a1f1f;
}

.pagination a.active {
    background: #8a1f1f;
    color: white;
    border-color: #8a1f1f;
}

.pagination a:hover:not(.active) {
    background: #f5f5f5;
}

.filters {
    background: white;
    padding: 15px;
    border-radius: 5px;
    margin-bottom: 20px;
    display: flex;
    gap: 10px;
    align-items: center;
}

.filters select,
.filters input {
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.filters button {
    padding: 8px 15px;
}

.recipe-detail {
    background: white;
    padding: 20px;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.recipe-detail h3 {
    color: #8a1f1f;
    margin: 20px 0 10px;
}

.purchase-info {
    margin-top: 20px;
    padding: 15px;
    background: #e8f5e9;
    border-radius: 4px;
}

.payment-info {
    background: #f5f5f5;
    padding: 15px;
    border-radius: 4px;
    margin-bottom: 20px;
}

.payment-info h3 {
    color: #8a1f1f;
    margin-bottom: 10px;
}

.admin-tabs {
    display: flex;
    border-bottom: 1px solid #ddd;
    margin-bottom: 20px;
}

.tab-link {
    padding: 10px 20px;
    background: #f5f5f5;
    border: 1px solid #ddd;
    border-bottom: none;
    border-radius: 5px 5px 0 0;
    margin-right: 5px;
    cursor: pointer;
}

.tab-link.active {
    background: #8a1f1f;
    color: white;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.pending-recipe {
    background: white;
    padding: 20px;
    border-radius: 5px;
    margin-bottom: 20px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.admin-actions {
    margin-top: 15px;
    display: flex;
    gap: 10px;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

table, th, td {
    border: 1px solid #ddd;
}

th, td {
    padding: 10px;
    text-align: left;
}

th {
    background: #f5f5f5;
}

tr:nth-child(even) {
    background: #f9f9f9;
}

footer {
    background: #333;
    color: white;
    text-align: center;
    padding: 20px 0;
    margin-top: 40px;
}

@media (max-width: 768px) {
    header .container {
        flex-direction: column;
        text-align: center;
    }
    
    nav ul {
        margin-top: 15px;
        flex-wrap: wrap;
        justify-content: center;
    }
    
    nav ul li {
        margin: 5px 10px;
    }
    
    .recipe-meta {
        flex-direction: column;
        gap: 5px;
    }
    
    .filters {
        flex-direction: column;
        align-items: stretch;
    }
    
    .admin-actions {
        flex-direction: column;
    }
    
    .admin-tabs {
        flex-direction: column;
    }
    
    .tab-link {
        margin-bottom: 5px;
        border-radius: 5px;
        border: 1px solid #ddd;
    }
}
.add-category-form {
    background: #f9f9f9;
    padding: 15px;
    border-radius: 5px;
    margin-bottom: 20px;
}

.add-category-form .form-group {
    display: flex;
    gap: 10px;
    align-items: flex-end;
}

.add-category-form input {
    flex: 1;
}

.add-category-form button {
    white-space: nowrap;
}