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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    min-height: 100vh;
    color: #333;
    line-height: 1.6;
}

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

header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    padding: 20px 0;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

.logo h1 {
    font-size: 28px;
    margin-bottom: 5px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.subtitle {
    font-size: 14px;
    opacity: 0.9;
    font-style: italic;
}

nav .nav-links {
    list-style: none;
    display: flex;
    gap: 20px;
}

nav .nav-links li a {
    color: #fff;
    text-decoration: none;
    font-size: 16px;
    padding: 8px 15px;
    border-radius: 20px;
    transition: background 0.3s;
}

nav .nav-links li a:hover {
    background: rgba(255,255,255,0.2);
}

.hamburger {
    display: none;
    font-size: 28px;
    cursor: pointer;
    padding: 10px;
}

.search-bar {
    background: #fff;
    padding: 25px;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    margin-bottom: 30px;
}

#searchInput {
    width: 100%;
    padding: 12px 20px;
    border: 2px solid #e0e0e0;
    border-radius: 25px;
    font-size: 16px;
    transition: border-color 0.3s;
    margin-bottom: 15px;
}

#searchInput:focus {
    border-color: #667eea;
    outline: none;
    box-shadow: 0 0 10px rgba(102,126,234,0.3);
}

.category-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.filter-btn {
    padding: 8px 18px;
    border: none;
    border-radius: 20px;
    background: #f0f0f0;
    color: #555;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 14px;
}

.filter-btn.active, .filter-btn:hover {
    background: #667eea;
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(102,126,234,0.4);
}

.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
}

.card {
    background: #fff;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.08);
    overflow: hidden;
    transition: all 0.3s ease;
    border: 1px solid rgba(0,0,0,0.05);
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.15);
}

.card-body {
    padding: 20px;
}

.card h3 {
    font-size: 18px;
    margin-bottom: 10px;
}

.card h3 a {
    color: #333;
    text-decoration: none;
    transition: color 0.3s;
}

.card h3 a:hover {
    color: #667eea;
}

.card p {
    color: #666;
    font-size: 14px;
    margin-bottom: 10px;
}

.category-tag {
    display: inline-block;
    padding: 4px 12px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    border-radius: 12px;
    font-size: 12px;
    margin-bottom: 10px;
}

.rating {
    margin-bottom: 10px;
}

.star {
    font-size: 20px;
    cursor: pointer;
    color: #ddd;
    transition: color 0.2s;
}

.star.filled {
    color: #f39c12;
}

.star:hover {
    color: #f1c40f;
}

.fav-btn {
    padding: 8px 15px;
    border: none;
    border-radius: 20px;
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    color: #fff;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 14px;
}

.fav-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 10px rgba(231,76,60,0.4);
}

.add-form {
    background: #fff;
    padding: 25px;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    margin-top: 30px;
}

.add-form h3 {
    margin-bottom: 15px;
    color: #333;
}

.add-form input {
    width: 100%;
    padding: 10px 15px;
    margin-bottom: 10px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 14px;
    transition: border-color 0.3s;
}

.add-form input:focus {
    border-color: #667eea;
    outline: none;
}

.add-form button {
    padding: 12px 30px;
    border: none;
    border-radius: 25px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    cursor: pointer;
    font-size: 16px;
    transition: all 0.3s;
}

.add-form button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(102,126,234,0.4);
}

footer {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    padding: 20px 0;
    margin-top: 40px;
    text-align: center;
}

footer a {
    color: #f1c40f;
    text-decoration: none;
}

footer a:hover {
    text-decoration: underline;
}

.login-form, .admin-panel {
    background: #fff;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    max-width: 500px;
    margin: 0 auto;
}

.login-form h2, .admin-panel h2 {
    margin-bottom: 20px;
    color: #333;
}

.login-form input, .admin-form input, .admin-form textarea {
    width: 100%;
    padding: 10px 15px;
    margin-bottom: 10px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 14px;
    transition: border-color 0.3s;
}

.login-form input:focus, .admin-form input:focus, .admin-form textarea:focus {
    border-color: #667eea;
    outline: none;
}

.admin-form textarea {
    height: 80px;
    resize: vertical;
}

.login-form button, .admin-form button {
    padding: 12px 30px;
    border: none;
    border-radius: 25px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    cursor: pointer;
    font-size: 16px;
    transition: all 0.3s;
}

.login-form button:hover, .admin-form button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(102,126,234,0.4);
}

.btn-danger {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%) !important;
}

.admin-item {
    border-bottom: 1px solid #eee;
    padding: 15px 0;
    margin-bottom: 10px;
}

.inline-form {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

.inline-form input, .inline-form textarea {
    flex: 1;
    min-width: 120px;
}

.alert {
    padding: 12px 20px;
    border-radius: 10px;
    margin-bottom: 20px;
    font-weight: bold;
}

.alert-error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.alert-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

@media (max-width: 768px) {
    .header-container {
        flex-direction: column;
        text-align: center;
    }
    
    .hamburger {
        display: block;
    }
    
    .nav-links {
        display: none;
        flex-direction: column;
        width: 100%;
        text-align: center;
        padding-top: 10px;
    }
    
    .nav-links.show {
        display: flex;
    }
    
    .card-grid {
        grid-template-columns: 1fr;
    }
    
    .inline-form {
        flex-direction: column;
    }
    
    .inline-form input, .inline-form textarea {
        width: 100%;
    }
}