الگو:صفحه اصلی مغازه شما/دسته بندی موضوعی: تفاوت میان نسخهها
Esfandiari (بحث | مشارکتها) بدون خلاصۀ ویرایش |
Esfandiari (بحث | مشارکتها) بدون خلاصۀ ویرایش |
||
| خط ۳: | خط ۳: | ||
<div class="faraghaib-custom-container"> | <div class="faraghaib-custom-container"> | ||
<div class="fz-search-wrapper"> | <div class="fz-search-wrapper"> | ||
<input type="text" id="categorySearch" placeholder="جستجو در دستهبندیها..."> | <input type="text" id="categorySearch" placeholder="جستجو در دستهبندیها..."> | ||
</div> | </div> | ||
<div class="fz-filter-bar"> | <div class="fz-filter-bar"> | ||
<button class="fz-filter-btn active" onclick="filterSelection(event, 'all')">همه</button> | <button class="fz-filter-btn active" onclick="filterSelection(event, 'all')">همه</button> | ||
| خط ۱۶: | خط ۱۴: | ||
</div> | </div> | ||
<div id="categoryGrid" class="fz-category-grid"> | <div id="categoryGrid" class="fz-category-grid"> | ||
<div class="fz-card tech"> | <div class="fz-card tech"> | ||
<span class="fz-title">هوش مصنوعی</span> | <span class="fz-title">هوش مصنوعی</span> | ||
| خط ۲۵: | خط ۲۱: | ||
</div> | </div> | ||
<div class="fz-card art"> | <div class="fz-card art"> | ||
<span class="fz-title">نقاشی دیجیتال</span> | <span class="fz-title">نقاشی دیجیتال</span> | ||
| خط ۳۱: | خط ۲۶: | ||
</div> | </div> | ||
<div class="fz-card science"> | <div class="fz-card science"> | ||
<span class="fz-title">فیزیک کوانتوم</span> | <span class="fz-title">فیزیک کوانتوم</span> | ||
| خط ۳۷: | خط ۳۱: | ||
</div> | </div> | ||
<div class="fz-card tech"> | <div class="fz-card tech"> | ||
<span class="fz-title">برنامهنویسی</span> | <span class="fz-title">برنامهنویسی</span> | ||
| خط ۴۳: | خط ۳۶: | ||
</div> | </div> | ||
<div class="fz-card art"> | <div class="fz-card art"> | ||
<span class="fz-title">طراحی گرافیک</span> | <span class="fz-title">طراحی گرافیک</span> | ||
| خط ۵۳: | خط ۴۵: | ||
<style> | <style> | ||
.faraghaib-custom-container { | .faraghaib-custom-container { | ||
direction: rtl !important; | direction: rtl !important; | ||
font-family: | font-family: 'IRANSans', 'IRANSansWeb', Tahoma, Arial, sans-serif !important; | ||
max-width: 1000px !important; | max-width: 1000px !important; | ||
margin: 20px auto !important; | margin: 20px auto !important; | ||
| خط ۶۳: | خط ۵۴: | ||
border-radius: 15px !important; | border-radius: 15px !important; | ||
border: 1px solid #c9e4d5 !important; | border: 1px solid #c9e4d5 !important; | ||
display: block !important; | display: block !important; | ||
box-sizing: border-box !important; | |||
} | |||
.fz-search-wrapper { | |||
margin-bottom: 15px; | |||
text-align: center; | |||
} | } | ||
.fz-search-wrapper input { | .fz-search-wrapper input { | ||
width: 90%; padding: 8px 15px; border: 1px solid #c9e4d5; border-radius: 20px; outline: none; font-size: 14px; | width: 90%; | ||
padding: 8px 15px; | |||
border: 1px solid #c9e4d5; | |||
border-radius: 20px; | |||
outline: none; | |||
font-size: 14px; | |||
font-family: 'IRANSans', 'IRANSansWeb', Tahoma, Arial, sans-serif !important; | |||
} | } | ||
.fz-filter-bar { | |||
.fz-filter-bar { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-bottom: 20px; } | display: flex; | ||
.fz-filter-btn { padding: 5px 15px; border-radius: 15px; border: none; background: #eee; cursor: pointer; font-size: 13px; transition: 0.3s; } | flex-wrap: wrap; | ||
.fz-filter-btn.active { background: #16bd78 !important; color: white !important; } | gap: 8px; | ||
justify-content: center; | |||
margin-bottom: 20px; | |||
} | |||
.fz-filter-btn { | |||
padding: 5px 15px; | |||
border-radius: 15px; | |||
border: none; | |||
background: #eee; | |||
cursor: pointer; | |||
font-size: 13px; | |||
font-family: 'IRANSans', 'IRANSansWeb', Tahoma, Arial, sans-serif !important; | |||
transition: 0.3s; | |||
} | |||
.fz-filter-btn.active { | |||
background: #16bd78 !important; | |||
color: white !important; | |||
} | |||
.fz-category-grid { | .fz-category-grid { | ||
display: grid !important; | display: grid !important; | ||
grid-template-columns: repeat(4, 1fr) !important; | grid-template-columns: repeat(4, 1fr) !important; | ||
gap: | gap: 12px !important; | ||
width: 100% !important; | width: 100% !important; | ||
} | } | ||
.fz-card { | .fz-card { | ||
background: white !important; | background: white !important; | ||
height: | height: 42px !important; | ||
display: flex !important; | display: flex !important; | ||
align-items: center !important; | align-items: center !important; | ||
justify-content: space-between !important; | justify-content: space-between !important; | ||
padding: 0 12px !important; | padding: 0 12px !important; | ||
border-radius: 8px !important; | border-radius: 8px !important; | ||
box-shadow: 0 2px 5px rgba(0,0,0,0.05) !important; | box-shadow: 0 2px 5px rgba(0,0,0,0.05) !important; | ||
border- | border-bottom: 4px solid #ddd !important; | ||
box-sizing: border-box !important; | border-top: none !important; | ||
border-left: none !important; | |||
border-right: none !important; | |||
box-sizing: border-box !important; | |||
cursor: pointer; | cursor: pointer; | ||
transition: | transition: all 0.2s ease; | ||
margin: 0 !important; | margin: 0 !important; | ||
} | } | ||
.fz-card:hover { transform: translateY(- | .fz-card:hover { | ||
transform: translateY(-3px); | |||
box-shadow: 0 4px 10px rgba(0,0,0,0.1) !important; | |||
} | |||
.fz-title { | .fz-title { | ||
font-weight: | font-family: 'IRANSans', 'IRANSansWeb', Tahoma, Arial, sans-serif !important; | ||
font-weight: 500 !important; | |||
color: #333 !important; | color: #333 !important; | ||
font-size: | font-size: 15px !important; | ||
white-space: nowrap; | white-space: nowrap; | ||
overflow: hidden; | overflow: hidden; | ||
text-overflow: ellipsis; | text-overflow: ellipsis; | ||
| خط ۱۲۰: | خط ۱۴۴: | ||
padding: 2px 8px; | padding: 2px 8px; | ||
border-radius: 10px; | border-radius: 10px; | ||
font-family: 'IRANSans', 'IRANSansWeb', Tahoma, Arial, sans-serif !important; | |||
} | } | ||
.fz-card.tech { border-bottom-color: #16bd78 !important; } | |||
.fz-card.tech { border- | .fz-card.art { border-bottom-color: #ff9f43 !important; } | ||
.fz-card.art { border- | .fz-card.science { border-bottom-color: #54a0ff !important; } | ||
.fz-card.science { border- | |||
@media (max-width: 768px) { | @media (max-width: 768px) { | ||
.fz-category-grid { grid-template-columns: repeat(2, 1fr) !important; } | .fz-category-grid { | ||
grid-template-columns: repeat(2, 1fr) !important; | |||
} | |||
} | } | ||
.is-hidden { | |||
.is-hidden { display: none !important; } | display: none !important; | ||
} | |||
</style> | </style> | ||
| خط ۱۴۰: | خط ۱۶۶: | ||
const cards = document.getElementsByClassName("fz-card"); | const cards = document.getElementsByClassName("fz-card"); | ||
const buttons = document.getElementsByClassName("fz-filter-btn"); | const buttons = document.getElementsByClassName("fz-filter-btn"); | ||
for (let btn of buttons) { btn.classList.remove("active"); } | for (let btn of buttons) { | ||
btn.classList.remove("active"); | |||
} | |||
event.currentTarget.classList.add("active"); | event.currentTarget.classList.add("active"); | ||
| خط ۱۵۶: | خط ۱۸۵: | ||
const val = this.value.toLowerCase().trim(); | const val = this.value.toLowerCase().trim(); | ||
const cards = document.getElementsByClassName("fz-card"); | const cards = document.getElementsByClassName("fz-card"); | ||
for (let card of cards) { | for (let card of cards) { | ||
const title = card.querySelector('.fz-title').innerText.toLowerCase(); | const title = card.querySelector('.fz-title').innerText.toLowerCase(); | ||
| خط ۱۶۲: | خط ۱۹۲: | ||
}); | }); | ||
</script> | </script> | ||
</html> | </html> | ||