:root {
    --primary-bg: #4a0008;      /* زرشکی تیره */
    --secondary-bg: #6300105c;    /* زرشکی کمی روشن‌تر برای کارت‌ها */
    --text-color: #ffffff;      /* متن سفید */
    --accent-color: #ffffff;    /* طلایی لوکس برای تزئینات */
    --border-color: rgba(255, 255, 255, 0.778);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}
@font-face {
    font-family: Vazirmatn;
    src: url(./assets/fonts/Vazirmatn-Regular.ttf)  ;
}
@font-face {
    font-family: Lalezar;
    src: url(./assets/fonts/Lalezar-Regular.ttf);
}
body {
    background-image: linear-gradient(rgba(99, 27, 27, 0.756))  ,  url(./assets/بک.webp) ;
    color: var(--text-color);
    font-family: 'Vazirmatn', sans-serif;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

h1, h2, h3, .brand-title {
    font-family: 'Lalezar', cursive;
    font-weight: normal;
    letter-spacing: 0.5px;
}

header {
    text-align: center;
    padding: 2rem 1rem 1rem;
    border-bottom: 1px solid var(--border-color);
    background: inherit;
    position: relative;
    z-index: 10;
}

.logo-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

/* انیمیشن اصلی جا‌به‌جایی لوگو */
.logo-container img {
    width: 110px;
    height: 110px;
    border-radius: 50%;
    border: 2px solid var(--accent-color);
    
    object-fit: cover;
    box-shadow: 0 0 20px rgba(0,0,0,0.5);
    /* اعمال انیمیشن لودینگ */
    animation: logoSplash 2s cubic-bezier(0.65, 0, 0.35, 1) forwards;
}

.logo-container h1 {
    color: var(--accent-color);
    margin-top: 15px;
    font-size: 2.2rem;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
    /* ظهور عنوان با تاخیر */
    opacity: 0;
    animation: fadeInContent 0.8s ease forwards;
    animation-delay: 1.6s;
}

/* تاخیر در نمایش بخش‌های اصلی تا زمان نشستن لوگو */
main {
    opacity: 0;
    animation: fadeInContent 0.8s ease forwards;
    animation-delay: 0.9s;
}

/* کلیدهای انیمیشن لوگو */
@keyframes logoSplash {
    0% {
        transform: translateY(35vh) scale(2);
        opacity: 0;
    }
    25% {
        transform: translateY(35vh) scale(2);
        opacity: 1;
    }
    60% {
        transform: translateY(35vh) scale(2);
        opacity: 1;
    }
    100% {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

@keyframes fadeInContent {
    from {
        opacity: 0;
        transform: translateY(15px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* بخش سرچ */
.search-section {
    padding: 1.5rem 1rem 0.5rem;
    text-align: center;
}

#search-input {
    width: 100%;
    max-width: 450px;
    padding: 14px 25px;
    border-radius: 30px;
    border: 1px solid var(--border-color);
    background-color: rgba(158, 92, 92, 0.381);
    color: var(--text-color);
    font-family: 'Vazirmatn', sans-serif;
    font-size: 0.95rem;
    outline: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

#search-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

#search-input:focus {
    border-color: var(--accent-color);
    background-color: rgba(0, 0, 0, 0.25);
    box-shadow: 0 0 20px rgba(250, 233, 177, 0.689);
    transform: scale(1.01);
}

/* اسکرول دسته‌بندی‌ها */
.categories-scroll {
    overflow-x: auto;
    white-space: nowrap;
    padding: 15px 1rem;
    margin-bottom: 1rem;
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.categories-scroll::-webkit-scrollbar {
    display: none;
}

#categories-list {
    list-style: none;
    display: inline-flex;
    gap: 12px;
}

.category-btn {
    background-color: transparent;
    color: rgba(255, 255, 255, 0.8);
    border: 1px solid var(--border-color);
    padding: 8px 24px;
    border-radius: 25px;
    cursor: pointer;
    font-family: 'Lalezar', sans-serif;
    font-size: 1rem;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.category-btn.active, .category-btn:hover {
    background-color: var(--accent-color);
    color: var(--primary-bg);
    border-color: var(--accent-color);
    font-weight: bold;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(212, 175, 55, 0.3);
}

/* کارت محصولات و انیمیشن آبشاری */
.menu-container {
    padding: 0 1rem 4rem 1rem;
    display: flex;
    flex-direction: column;
    gap: 1.3rem;
    max-width: 600px;
    margin: 0 auto;
}

.menu-item {
    background-color: var(--secondary-bg);
    /* border: 1px solid var(--border-color); */
    border-bottom: 4px solid var(--border-color);
    border-radius: 16px;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    position: relative;
    box-shadow: 0 8px 20px rgba(0,0,0,0.25);
    overflow: hidden;
    
    /* انیمیشن لود تدریجی */
    opacity: 0;
    animation: cardAppear 0.5s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.menu-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 25px rgba(0,0,0,0.4);
    border-color: rgba(255, 255, 255, 0.5);
}

.menu-item::after {
    content: '';
    position: absolute;
    right: 0;
    top: 20%;
    height: 60%;
    width: 4px;
    background-color: var(--accent-color);
    border-radius: 4px 0 0 4px;
    transition: height 0.3s ease, top 0.3s ease;
}

.menu-item:hover::after {
    height: 80%;
    top: 10%;
}

@keyframes cardAppear {
    from {
        opacity: 0;
        transform: translateY(25px) scale(0.97);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.item-name {
    font-size: 1.4rem;
    color: var(--accent-color);
}

.item-price {
    font-family: 'Vazirmatn', sans-serif;
    font-weight: 700;
    font-size: 1.1rem;
    background-color: rgba(0,0,0,0.25);
    padding: 4px 12px;
    border-radius: 12px;
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.item-desc {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.75);
    line-height: 1.8;
}

.no-results {
    text-align: center;
    padding: 3rem 1rem;
    color: rgba(255, 255, 255, 0.5);
    font-family: 'Vazirmatn', sans-serif;
    animation: fadeInContent 0.4s ease forwards;
}