* { margin: 0; padding: 0; box-sizing: border-box; }
:root {
    --primary-color: #9CAF88;
    --primary-dark: #7A8F6A;
    --text-color: #333;
    --text-light: #666;
    --bg-color: #fff;
    --bg-light: #f8f8f8;
    --border-color: #e0e0e0;
    --font-family: 'Vazirmatn UI FD', 'Vazir', 'Tahoma', 'Apple Color Emoji', 'Segoe UI Emoji', 'Noto Color Emoji', sans-serif;
}
html { font-size: 16px; direction: rtl; }
body { font-family: var(--font-family); color: var(--text-color); background: var(--bg-color); line-height: 1.6; }
.card-no-image,
.empty-emoji,
.table-preview-icon,
.smi-emoji,
.smi-hero-placeholder,
.td-more-placeholder,
.brand-icon {
    font-family: 'Apple Color Emoji', 'Segoe UI Emoji', 'Noto Color Emoji', var(--font-family);
}
h1, h2, h3, h4, h5, h6 { font-weight: 700; line-height: 1.2; margin-bottom: 1rem; }
h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.75rem; }
a { color: var(--primary-color); text-decoration: none; transition: color 0.3s; }
a:hover { color: var(--primary-dark); }
.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
/* ============================
   HEADER
   ============================ */
.site-header {
    background: rgba(255,255,255,0.97);
    backdrop-filter: blur(8px);
    box-shadow: 0 2px 16px rgba(0,0,0,0.08);
    position: sticky; top: 0; z-index: 1000;
}
.header-inner {
    display: flex; align-items: center;
    justify-content: space-between; gap: 1.5rem; padding: 0.9rem 0;
}
.site-branding { flex-shrink: 0; max-width: 220px; }
.logo-link { display: flex; align-items: center; text-decoration: none; }
.site-logo { display: block; height: auto; max-height: 64px; width: auto; object-fit: contain; }
.brand-text-link { display: flex; align-items: center; gap: 8px; color: var(--text-color); font-size: 1.3rem; font-weight: 700; text-decoration: none; }
.brand-text-link:hover { color: var(--primary-dark); }
.brand-icon { font-size: 1.5rem; }
.main-navigation { flex: 1; }
.nav-menu { display: flex; list-style: none; gap: 0.25rem; margin: 0; padding: 0; justify-content: center; }
.nav-menu li { margin: 0; }
.nav-menu a { color: var(--text-color); font-weight: 600; font-size: 0.95rem; padding: 0.5rem 0.9rem; border-radius: 8px; display: block; transition: all 0.2s; }
.nav-menu a:hover { color: var(--primary-dark); background: #f0f4ec; }
.header-actions { display: flex; align-items: center; gap: 0.75rem; flex-shrink: 0; }
.header-phone { display: flex; align-items: center; gap: 6px; font-size: 0.88rem; font-weight: 600; color: var(--text-color); background: var(--bg-light); border: 1px solid var(--border-color); padding: 0.4rem 0.85rem; border-radius: 30px; transition: all 0.2s; white-space: nowrap; }
.header-phone:hover { background: var(--primary-color); border-color: var(--primary-color); color: #fff; }
.header-social { display: flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 50%; background: var(--bg-light); border: 1px solid var(--border-color); color: var(--text-color); transition: all 0.2s; }
.header-social:hover { background: #e1306c; border-color: #e1306c; color: #fff; }
.menu-toggle { display: none; flex-direction: column; gap: 5px; background: none; border: none; cursor: pointer; padding: 8px; border-radius: 8px; transition: background 0.2s; }
.menu-toggle:hover { background: var(--bg-light); }
.hamburger-line { display: block; width: 22px; height: 2.5px; background: var(--text-color); border-radius: 2px; transition: all 0.3s; }
.site-content { min-height: calc(100vh - 300px); }
.site-main { padding: 2rem 0; }

/* ============================
   FOOTER
   ============================ */
.site-footer { background: #1e2227; color: rgba(255,255,255,0.85); padding: 3rem 0 0; margin-top: 5rem; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 3rem; padding-bottom: 2.5rem; border-bottom: 1px solid rgba(255,255,255,0.1); }
.footer-grid.footer-cols-2 { grid-template-columns: 1.4fr 1fr; }
.footer-grid.footer-cols-1 { grid-template-columns: 1fr; }
.footer-col-title { font-size: 1rem; font-weight: 700; color: #fff; margin-bottom: 1.25rem; padding-bottom: 0.6rem; border-bottom: 2px solid var(--primary-color); display: inline-block; }
.footer-logo-link { display: inline-block; margin-bottom: 1rem; }
.footer-logo { max-height: 50px; width: auto; filter: brightness(0) invert(1); }
.footer-brand-name { display: inline-flex; align-items: center; gap: 8px; font-size: 1.2rem; font-weight: 700; color: #fff; text-decoration: none; margin-bottom: 1rem; }
.footer-desc { font-size: 0.9rem; line-height: 1.8; color: rgba(255,255,255,0.65); margin-bottom: 1.25rem; }
.footer-socials { display: flex; flex-direction: column; gap: 10px; }
.social-btn { display: inline-flex; align-items: center; gap: 8px; font-size: 0.85rem; font-weight: 600; padding: 0.4rem 1rem; border-radius: 30px; text-decoration: none; transition: all 0.2s; }
.phone-btn { background: rgba(156,175,136,0.2); color: var(--primary-color); border: 1px solid rgba(156,175,136,0.4); }
.phone-btn:hover { background: var(--primary-color); color: #fff; }
.insta-btn { background: rgba(225,48,108,0.15); color: #e1306c; border: 1px solid rgba(225,48,108,0.3); }
.insta-btn:hover { background: #e1306c; color: #fff; }
.footer-nav { list-style: none; margin: 0; padding: 0; }
.footer-nav li { border-bottom: 1px solid rgba(255,255,255,0.07); }
.footer-nav li:last-child { border-bottom: none; }
.footer-nav a { display: block; padding: 0.5rem 0; color: rgba(255,255,255,0.7); font-size: 0.9rem; transition: color 0.2s; text-decoration: none; }
.footer-nav a::before { content: '← '; opacity: 0.5; }
.footer-nav a:hover { color: var(--primary-color); }
.contact-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.contact-list li { display: flex; align-items: flex-start; gap: 10px; font-size: 0.9rem; color: rgba(255,255,255,0.7); }
.contact-list svg { flex-shrink: 0; margin-top: 3px; fill: var(--primary-color); }
.contact-list a { color: rgba(255,255,255,0.7); }
.contact-list a:hover { color: var(--primary-color); }
.footer-bottom { text-align: center; padding: 1.25rem 0; font-size: 0.85rem; color: rgba(255,255,255,0.4); }

/* ============================
   TABLE SINGLE (td-)
   ============================ */

/* ── Page wrapper ── */
.table-detail-main { padding: 0; }
.table-detail-main .container { max-width: 1000px; }

/* Keep old classes for any other usages */
.entry-content { margin-top: 2rem; line-height: 1.8; }
.screen-reader-text { clip: rect(1px,1px,1px,1px); position: absolute !important; height: 1px; width: 1px; overflow: hidden; }

/* ── Hero ── */
.td-hero {
    position: relative;
    height: 460px;
    overflow: hidden;
    background: #1a2e1a;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}
.td-hero--image .td-hero-overlay {
    position: absolute; inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(0,0,0,0.15) 0%,
        rgba(0,0,0,0.25) 40%,
        rgba(0,0,0,0.72) 100%
    );
    z-index: 1;
}
.td-hero--video .td-hero-overlay {
    position: absolute; inset: 0;
    background: rgba(0,0,0,0.45);
    z-index: 1;
}
.td-hero-video {
    position: absolute; inset: 0;
    width: 100%; height: 100%;
    object-fit: cover; z-index: 0;
}

/* Back button */
.td-back-btn {
    position: absolute; top: 1.25rem; right: 1.5rem; z-index: 10;
    display: inline-flex; align-items: center; gap: 5px;
    background: rgba(255,255,255,0.15); backdrop-filter: blur(6px);
    color: #fff; font-size: 0.83rem; font-weight: 600;
    padding: 0.45rem 1rem; border-radius: 30px;
    text-decoration: none; transition: background 0.2s;
    border: 1px solid rgba(255,255,255,0.28); direction: rtl;
}
.td-back-btn svg { flex-shrink: 0; transform: rotate(180deg); }
.td-back-btn:hover { background: rgba(255,255,255,0.3); color: #fff; }

/* Hero title */
.td-hero-title-wrap {
    position: absolute; bottom: 0; right: 0; left: 0;
    padding: 1.75rem 2rem; z-index: 10;
}
.td-hero-badge {
    display: inline-flex; align-items: center; gap: 5px;
    background: rgba(255,255,255,0.18); backdrop-filter: blur(4px);
    color: rgba(255,255,255,0.9); font-size: 0.78rem; font-weight: 600;
    padding: 0.25rem 0.75rem; border-radius: 20px;
    border: 1px solid rgba(255,255,255,0.25);
    margin-bottom: 0.6rem; letter-spacing: 0.02em;
}
.td-hero-title {
    font-size: 2.6rem; font-weight: 800;
    color: #fff; margin: 0;
    text-shadow: 0 2px 16px rgba(0,0,0,0.45);
    line-height: 1.2;
}

/* ── Main card ── */
.td-main-card {
    display: grid;
    grid-template-columns: 1fr 280px;
    gap: 0;
    background: #fff;
    border-radius: 20px;
    box-shadow: 0 8px 40px rgba(0,0,0,0.1);
    margin-top: -72px;
    position: relative; z-index: 5;
    overflow: hidden;
    margin-bottom: 2.5rem;
}
/* Full-width variant (no QR column) */
.td-main-card--full {
    grid-template-columns: 1fr;
}

/* Info column */
.td-info-col {
    padding: 2.25rem 2.25rem;
    display: flex; flex-direction: column; gap: 1.5rem;
    border-left: 1px solid var(--border-color);
}
.td-info-col--full {
    border-left: none;
    padding: 2.5rem 3rem;
}
.td-info-col--full .td-info-text {
    font-size: 1.05rem;
    line-height: 2.05;
    max-width: 820px;
}
.td-section { }
.td-section-title {
    display: flex; align-items: center; gap: 8px;
    font-size: 1.05rem; font-weight: 700; color: var(--text-color);
    margin: 0 0 0.9rem; padding-bottom: 0.65rem;
    border-bottom: 2px solid var(--border-color);
}
.td-section-title svg { color: var(--primary-color); flex-shrink: 0; }
.td-info-text {
    font-size: 0.97rem; color: var(--text-light);
    line-height: 1.95; margin: 0;
}
.td-info-text p { margin: 0 0 0.75rem; }
.td-info-text p:last-child { margin: 0; }
.td-section--extra .td-section-title { color: var(--primary-dark); }

/* CTA buttons */
.td-cta-row {
    display: flex; gap: 10px; flex-wrap: wrap;
    margin-top: auto; padding-top: 0.5rem;
}
.td-btn-menu {
    display: inline-flex; align-items: center; gap: 7px;
    background: var(--primary-color); color: #fff;
    padding: 0.65rem 1.4rem; border-radius: 30px;
    font-size: 0.9rem; font-weight: 700;
    text-decoration: none; transition: background 0.2s;
}
.td-btn-menu:hover { background: var(--primary-dark); color: #fff; }
.td-btn-back {
    display: inline-flex; align-items: center; gap: 7px;
    border: 2px solid var(--border-color); color: var(--text-light);
    padding: 0.65rem 1.25rem; border-radius: 30px;
    font-size: 0.9rem; font-weight: 600;
    text-decoration: none; transition: all 0.2s;
}
.td-btn-back:hover { border-color: var(--primary-color); color: var(--primary-dark); }

/* QR column */
.td-qr-col {
    display: flex; flex-direction: column; align-items: center;
    padding: 2rem 1.5rem; gap: 1.25rem;
    background: var(--bg-light);
}
.td-qr-card {
    background: #fff; border-radius: 16px;
    padding: 1.5rem 1.25rem;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
    text-align: center; width: 100%;
}
.td-qr-icon { font-size: 2rem; margin-bottom: 0.4rem; }
.td-qr-label { font-size: 0.95rem; font-weight: 700; margin: 0 0 0.25rem; color: var(--text-color); }
.td-qr-hint { font-size: 0.78rem; color: var(--text-light); margin: 0 0 1rem; }
.td-qr-wrap {
    display: flex; justify-content: center; align-items: center;
    margin: 0 auto;
}
.td-qr-wrap canvas { border-radius: 8px; }
.td-qr-url { font-size: 0.75rem; color: var(--text-light); margin: 0.75rem 0 0; word-break: break-all; }

/* Thumbnail preview (when video+image both exist) */
.td-thumb-preview {
    position: relative; width: 100%; border-radius: 10px;
    overflow: hidden; aspect-ratio: 16/9;
}
.td-thumb-preview img { width: 100%; height: 100%; object-fit: cover; display: block; }
.td-thumb-label {
    position: absolute; bottom: 0; left: 0; right: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.6));
    color: #fff; font-size: 0.78rem; padding: 0.5rem 0.75rem;
    text-align: center;
}

/* ── Section headings (gallery / more tables) ── */
.td-section-heading {
    display: flex; align-items: center; gap: 10px;
    font-size: 1.15rem; font-weight: 700;
    color: var(--text-color); margin: 0 0 1.25rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid var(--border-color);
}
.td-section-heading svg { color: var(--primary-color); flex-shrink: 0; }
.td-gallery-count {
    margin-right: auto; background: var(--bg-light);
    font-size: 0.78rem; padding: 0.2rem 0.65rem;
    border-radius: 20px; color: var(--text-light);
    font-weight: 600;
}

/* ── Gallery ── */
.td-gallery-section { margin-bottom: 2.5rem; }
.td-gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 10px;
}
.td-gallery-item {
    position: relative; display: block;
    border-radius: 12px; overflow: hidden;
    aspect-ratio: 4/3; background: var(--bg-light);
    box-shadow: 0 2px 8px rgba(0,0,0,0.07);
    transition: transform 0.25s, box-shadow 0.25s;
}
.td-gallery-item:hover { transform: translateY(-3px); box-shadow: 0 8px 24px rgba(0,0,0,0.14); }
.td-gallery-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.td-gallery-zoom {
    position: absolute; inset: 0;
    display: flex; align-items: center; justify-content: center;
    background: rgba(0,0,0,0.42); color: #fff;
    opacity: 0; transition: opacity 0.22s;
}
.td-gallery-item:hover .td-gallery-zoom { opacity: 1; }

/* ── More tables carousel ── */
.td-more-tables { margin-bottom: 3rem; }
.td-more-scroll {
    display: flex; gap: 14px;
    overflow-x: auto; padding-bottom: 10px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: var(--border-color) transparent;
}
.td-more-scroll::-webkit-scrollbar { height: 4px; }
.td-more-scroll::-webkit-scrollbar-track { background: transparent; }
.td-more-scroll::-webkit-scrollbar-thumb { background: var(--border-color); border-radius: 2px; }

.td-more-card {
    flex: 0 0 140px;
    display: flex; flex-direction: column; align-items: center; gap: 8px;
    text-decoration: none; transition: transform 0.2s;
}
.td-more-card:hover { transform: translateY(-4px); }
.td-more-img {
    width: 140px; height: 100px;
    border-radius: 12px; overflow: hidden;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    flex-shrink: 0; position: relative;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: box-shadow 0.2s;
}
.td-more-card:hover .td-more-img { box-shadow: 0 6px 20px rgba(0,0,0,0.18); }
.td-more-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.td-more-video-thumb, .td-more-placeholder {
    width: 100%; height: 100%;
    display: flex; align-items: center; justify-content: center;
    font-size: 2rem;
}
.td-more-name {
    font-size: 0.85rem; font-weight: 600;
    color: var(--text-color); text-align: center;
    max-width: 130px; line-height: 1.3;
}

/* ============================
   HOMEPAGE HERO
   ============================ */

/* ── Keyframes for gentle blob drift ── */
@keyframes heroBlobDrift {
    0%   { transform: translate(0, 0) scale(1); }
    33%  { transform: translate(18px, -14px) scale(1.04); }
    66%  { transform: translate(-10px, 12px) scale(0.97); }
    100% { transform: translate(0, 0) scale(1); }
}
@keyframes heroBlobDrift2 {
    0%   { transform: translate(0, 0) scale(1); }
    33%  { transform: translate(-16px, 10px) scale(1.03); }
    66%  { transform: translate(12px, -8px) scale(0.98); }
    100% { transform: translate(0, 0) scale(1); }
}

.homepage-hero {
    text-align: center;
    padding: 4rem 1.5rem 3rem;
    margin-bottom: 4rem;
    background: linear-gradient(135deg, #f0f5eb 0%, #f8faf6 60%, #fff 100%);
    border-radius: 20px;
    position: relative; overflow: hidden;
}
.homepage-hero::before {
    content: ''; position: absolute; top: -60px; left: -60px;
    width: 300px; height: 300px; border-radius: 50%;
    background: radial-gradient(circle, rgba(156,175,136,0.18) 0%, rgba(156,175,136,0.04) 70%);
    pointer-events: none;
    animation: heroBlobDrift 12s ease-in-out infinite;
    will-change: transform;
}
.homepage-hero::after {
    content: ''; position: absolute; bottom: -80px; right: -80px;
    width: 420px; height: 420px; border-radius: 50%;
    background: radial-gradient(circle, rgba(212,165,116,0.12) 0%, rgba(156,175,136,0.05) 65%);
    pointer-events: none;
    animation: heroBlobDrift2 16s ease-in-out infinite;
    will-change: transform;
}
.hero-image { margin-bottom: 1.5rem; }
.hero-image img { max-height: 280px; width: auto; border-radius: 12px; box-shadow: 0 4px 20px rgba(0,0,0,0.12); }
.hero-content { position: relative; z-index: 1; }
.hero-title { font-size: 2.8rem; color: var(--primary-dark); margin-bottom: 0.75rem; }
.hero-subtitle { font-size: 1.15rem; color: var(--text-light); max-width: 560px; margin: 0 auto 2rem; line-height: 1.9; }
.hero-cta { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }
.hero-btn-primary { display: inline-block; background: var(--primary-color); color: #fff; padding: 0.75rem 2rem; border-radius: 30px; font-weight: 700; font-size: 1rem; transition: all 0.2s; box-shadow: 0 4px 16px rgba(156,175,136,0.4); }
.hero-btn-primary:hover { background: var(--primary-dark); color: #fff; transform: translateY(-2px); }
.hero-btn-secondary { display: inline-block; background: transparent; color: var(--primary-dark); padding: 0.75rem 2rem; border-radius: 30px; font-weight: 700; font-size: 1rem; border: 2px solid var(--primary-color); transition: all 0.2s; }
.hero-btn-secondary:hover { background: var(--primary-color); color: #fff; }

/* ============================
   SECTION HEADERS
   ============================ */
.section-header {
    display: flex; justify-content: space-between; align-items: flex-end;
    margin-bottom: 1.5rem; padding-bottom: 1rem;
    border-bottom: 2px solid var(--border-color);
}
.section-header-left { }
.section-title { font-size: 1.85rem; color: var(--text-color); margin: 0 0 0.3rem; }
.section-subtitle { font-size: 0.9rem; color: var(--text-light); margin: 0; }
.view-all-link { display: inline-flex; align-items: center; gap: 6px; background: var(--primary-color); color: #fff; padding: 0.5rem 1.25rem; border-radius: 30px; font-size: 0.9rem; font-weight: 600; transition: background 0.3s; white-space: nowrap; }
.view-all-link:hover { background: var(--primary-dark); color: #fff; }

/* ============================
   FILTER TABS  (افقی، قابل swipe و drag)
   ============================ */
.menu-filter-tabs {
    display: flex; gap: 8px; flex-wrap: nowrap;
    overflow-x: auto; overflow-y: hidden;
    padding: 0 0 12px;
    margin-bottom: 2rem; scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    /* iOS Safari: لایه composite جدا می‌سازد تا اسکرول لمسی توسط
       parent‌های overflow:hidden قفل نشود. */
    transform: translateZ(0);
    /* اعلام صریح به مرورگر: این عنصر فقط افقی pan می‌شود
       (کلید رفع قفل‌شدگی swipe در iOS و اندروید). */
    touch-action: pan-x;
    overscroll-behavior-x: contain;
    position: relative;
    /* Drag روی دسکتاپ: نمایش مکان‌نمای grab */
    cursor: grab;
    user-select: none;
    -webkit-user-select: none;
    scroll-behavior: smooth;
    scroll-snap-type: x proximity;
    scroll-padding-inline: 12px;
}
.menu-filter-tabs.is-dragging { cursor: grabbing; scroll-behavior: auto; }
.menu-filter-tabs.is-dragging .filter-tab { pointer-events: none; }
.menu-filter-tabs::-webkit-scrollbar { display: none; }
.filter-tab {
    display: inline-flex; align-items: center; gap: 6px;
    white-space: nowrap; padding: 0.5rem 1.2rem;
    border: 2px solid var(--border-color); border-radius: 30px;
    background: var(--bg-color); cursor: pointer;
    font-family: var(--font-family); font-size: 0.9rem; font-weight: 600;
    color: var(--text-color); transition: all 0.2s; flex-shrink: 0;
    scroll-snap-align: start;
    -webkit-tap-highlight-color: transparent;
}
.filter-tab:hover { border-color: var(--primary-color); color: var(--primary-dark); background: #f0f4ec; }
.filter-tab.active { background: var(--primary-color); border-color: var(--primary-color); color: #fff; box-shadow: 0 3px 12px rgba(156,175,136,0.4); }
.tab-count { font-size: 0.75rem; background: rgba(255,255,255,0.3); padding: 1px 7px; border-radius: 20px; }
.filter-tab.active .tab-count { background: rgba(255,255,255,0.3); }
.filter-tab:not(.active) .tab-count { background: var(--bg-light); color: var(--text-light); }

/* Archive page extra search */
.menu-search-wrap { margin-bottom: 1.5rem; }
.menu-search-inner { display: flex; align-items: center; gap: 10px; background: var(--bg-light); border: 2px solid var(--border-color); border-radius: 30px; padding: 0.6rem 1.2rem; transition: border-color 0.2s; max-width: 500px; }
.menu-search-inner:focus-within { border-color: var(--primary-color); }
.search-icon { font-size: 1rem; flex-shrink: 0; }
#menu-search-input { flex: 1; border: none; background: transparent; font-family: var(--font-family); font-size: 0.95rem; direction: rtl; outline: none; }
.search-clear { background: none; border: none; cursor: pointer; font-size: 1rem; color: var(--text-light); padding: 0; display: none; }
.search-clear.visible { display: block; }
.page-header.menu-archive-header { text-align: center; margin-bottom: 2rem; }
.page-subtitle { font-size: 1rem; color: var(--text-light); margin-top: 0.5rem; }

/* ============================
   MENU ITEM CARDS (New Design)
   ============================ */
.homepage-menu { margin-bottom: 5rem; }

.menu-cards-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
}

.menu-item-card {
    background: var(--bg-color);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0,0,0,0.07);
    transition: transform 0.3s, box-shadow 0.3s;
    display: flex; flex-direction: column;
    border: 1px solid rgba(0,0,0,0.05);
}
.menu-item-card:hover { transform: translateY(-5px); box-shadow: 0 10px 32px rgba(0,0,0,0.13); }
.menu-item-card.hidden { display: none; }

/* Card image */
.card-img-wrap {
    position: relative;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: linear-gradient(135deg, #eef3ea, #e0e8d6);
}
.card-img-wrap a { display: block; height: 100%; }
.card-img-wrap img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.45s ease; display: block; }
.menu-item-card:hover .card-img-wrap img { transform: scale(1.07); }
.card-no-image { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; font-size: 3.5rem; }

/* Category badge (top-right) */
.card-badge {
    position: absolute; top: 10px; right: 10px;
    background: rgba(30,34,39,0.7);
    backdrop-filter: blur(6px);
    color: #fff; font-size: 0.72rem; font-weight: 700;
    padding: 4px 10px; border-radius: 20px;
    pointer-events: none; white-space: nowrap;
}

/* Price badge (bottom-left) */
.card-price-badge {
    position: absolute; bottom: 10px; left: 10px;
    background: var(--primary-color);
    color: #fff; font-size: 0.9rem; font-weight: 700;
    padding: 4px 12px; border-radius: 20px;
    pointer-events: none;
}
.card-price-badge small { font-size: 0.72rem; font-weight: 400; opacity: 0.85; }

/* Card body */
.card-body { padding: 1.1rem 1.2rem 1.25rem; display: flex; flex-direction: column; flex: 1; }
.card-title { font-size: 1.05rem; margin: 0 0 0.45rem; line-height: 1.4; }
.card-title a { color: var(--text-color); text-decoration: none; }
.card-title a:hover { color: var(--primary-dark); }
.card-excerpt { font-size: 0.82rem; color: var(--text-light); line-height: 1.65; margin: 0 0 1rem; flex: 1; }
.card-btn {
    display: block; text-align: center;
    background: var(--bg-light); border: 1.5px solid var(--border-color);
    color: var(--text-color); padding: 0.45rem 1rem;
    border-radius: 10px; font-size: 0.85rem; font-weight: 600;
    transition: all 0.2s; text-decoration: none; margin-top: auto;
}
.card-btn:hover { background: var(--primary-color); border-color: var(--primary-color); color: #fff; }

.menu-no-items, .filter-empty {
    grid-column: 1 / -1; text-align: center;
    padding: 4rem 2rem; color: var(--text-light); font-size: 1rem;
    background: var(--bg-light); border-radius: 12px;
}
.empty-emoji { display: block; font-size: 3rem; margin-bottom: 1rem; }

/* ============================
   HOMEPAGE TABLES SECTION
   ============================ */
.homepage-tables { margin-bottom: 3rem; }

.tables-cards-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.25rem;
}

.tables-preview {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
}

.table-preview-card {
    background: var(--bg-color);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    text-align: center;
    gap: 0;
    transition: box-shadow 0.3s, transform 0.3s;
}
.table-preview-card:hover { box-shadow: 0 6px 20px rgba(0,0,0,0.1); transform: translateY(-3px); }

.table-preview-thumb {
    display: flex;
    align-items: center;
    justify-content: center;
    aspect-ratio: 4 / 3;
    background: var(--bg-light);
    overflow: hidden;
    text-decoration: none;
    color: inherit;
}
.table-preview-thumb:focus-visible { outline: 2px solid var(--primary-color); outline-offset: -2px; }

.table-preview-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.35s ease;
}
.table-preview-card:hover .table-preview-img { transform: scale(1.05); }

.table-preview-thumb .table-preview-icon {
    font-size: 2.75rem;
    line-height: 1;
}

.table-preview-body {
    padding: 1.25rem 1.25rem 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
}

.table-preview-title { font-size: 1.2rem; margin: 0; color: var(--text-color); font-weight: 700; }
.table-preview-title a { color: inherit; }
.table-preview-title a:hover { color: var(--primary-color); }
.table-preview-link { display: inline-flex; align-items: center; gap: 6px; background: var(--primary-color); color: #fff !important; padding: 0.45rem 1rem; border-radius: 8px; font-size: 0.85rem; font-weight: 600; white-space: nowrap; transition: background 0.3s; text-decoration: none; }
.table-preview-link:hover { background: var(--primary-dark); color: #fff !important; }
.table-preview-link:hover { background: var(--primary-dark); color: #fff !important; }

/* ============================
   ARCHIVE PAGES (menu + tables)
   ============================ */
.page-header { margin-bottom: 2rem; padding-bottom: 1rem; border-bottom: 2px solid var(--border-color); }
.page-title { font-size: 2rem; color: var(--text-color); }

.menu-category-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 2rem;
}
.filter-btn {
    padding: 0.5rem 1.25rem;
    border: 2px solid var(--border-color);
    border-radius: 30px;
    background: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-family);
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s;
}
.filter-btn:hover, .filter-btn.active { background: var(--primary-color); border-color: var(--primary-color); color: #fff; }

.tables-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.table-card {
    background: var(--bg-color);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    transition: box-shadow 0.3s, transform 0.3s;
}
.table-card:hover { box-shadow: 0 8px 24px rgba(0,0,0,0.12); transform: translateY(-4px); }

.table-thumbnail { overflow: hidden; aspect-ratio: 4/3; background: var(--bg-light); }
.table-thumbnail img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s; }
.table-card:hover .table-thumbnail img { transform: scale(1.05); }

.table-content { padding: 1.25rem; }
.table-title { font-size: 1.15rem; margin-bottom: 0.5rem; }
.table-title a { color: var(--text-color); }
.table-title a:hover { color: var(--primary-color); }

.table-excerpt { font-size: 0.9rem; color: var(--text-light); line-height: 1.7; margin-bottom: 1rem; }

.table-link {
    display: inline-block;
    background: var(--primary-color);
    color: #fff;
    padding: 0.45rem 1rem;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    transition: background 0.3s;
}
.table-link:hover { background: var(--primary-dark); color: #fff; }

/* ============================
   SINGLE MENU ITEM  (smi-)
   ============================ */

/* Full-page layout */
.single-item-main { padding: 0; }
.single-item-main .container { max-width: 960px; }

/* ── Hero strip ── */
.smi-hero {
    position: relative;
    height: 340px;
    background-color: var(--primary-color);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    overflow: hidden;
}
.smi-hero-overlay {
    position: absolute; inset: 0;
    background: linear-gradient(to bottom, rgba(0,0,0,0.18) 0%, rgba(0,0,0,0.55) 100%);
}
.smi-back-wrap {
    position: absolute; top: 1.25rem; right: 1.5rem; z-index: 10;
}
.smi-back-btn {
    display: inline-flex; align-items: center; gap: 5px;
    background: rgba(255,255,255,0.18); backdrop-filter: blur(6px);
    color: #fff; font-size: 0.85rem; font-weight: 600;
    padding: 0.45rem 1rem; border-radius: 30px;
    text-decoration: none; transition: background 0.2s;
    border: 1px solid rgba(255,255,255,0.3);
    direction: rtl;
}
.smi-back-btn svg { flex-shrink: 0; transform: rotate(180deg); }
.smi-back-btn:hover { background: rgba(255,255,255,0.32); color: #fff; }
.smi-hero-placeholder {
    position: absolute; inset: 0;
    display: flex; align-items: center; justify-content: center;
    font-size: 6rem; z-index: 2; opacity: 0.55;
    filter: drop-shadow(0 2px 8px rgba(0,0,0,0.3));
}

/* ── Main card (info + image) ── */
.smi-card {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 0;
    background: #fff;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 8px 40px rgba(0,0,0,0.1);
    margin-top: -80px;
    position: relative; z-index: 5;
    margin-bottom: 2.5rem;
}

/* Info column */
.smi-info {
    padding: 2.25rem 2.5rem;
    display: flex; flex-direction: column; justify-content: center;
}
.smi-cats {
    display: flex; flex-wrap: wrap; gap: 6px;
    margin-bottom: 0.9rem;
}
.smi-cat-pill {
    background: var(--primary-color); color: #fff;
    padding: 0.2rem 0.85rem; border-radius: 30px;
    font-size: 0.78rem; font-weight: 700;
    text-decoration: none; transition: background 0.2s;
    letter-spacing: 0.01em;
}
.smi-cat-pill:hover { background: var(--primary-dark); color: #fff; }

.smi-title {
    font-size: 2.1rem; font-weight: 800;
    color: var(--text-color); margin: 0 0 1rem;
    line-height: 1.3;
}
.smi-excerpt {
    font-size: 1rem; color: var(--text-light); line-height: 1.9;
    margin: 0 0 1.25rem;
}
.smi-content { font-size: 0.97rem; line-height: 1.8; color: var(--text-color); margin-bottom: 1.25rem; }

.smi-divider {
    border: none; border-top: 1px solid var(--border-color);
    margin: 1.25rem 0;
}

/* Price row (inside info, mobile-visible only) */
.smi-price-row {
    display: none;   /* shown on mobile via media query */
    align-items: center; justify-content: space-between;
    background: var(--bg-light); border-radius: 12px;
    padding: 0.9rem 1.25rem; margin-bottom: 1.5rem;
}
.smi-price-label { font-size: 0.85rem; color: var(--text-light); font-weight: 600; }
.smi-price-value {
    font-size: 1.6rem; font-weight: 800; color: var(--primary-dark);
    display: flex; align-items: baseline; gap: 4px;
}
.smi-price-currency { font-size: 0.9rem; font-weight: 500; color: var(--text-light); }

/* Actions */
.smi-actions { }
.smi-btn-back {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 0.65rem 1.4rem;
    border: 2px solid var(--border-color);
    border-radius: 30px;
    color: var(--text-light); font-size: 0.88rem; font-weight: 600;
    text-decoration: none; transition: all 0.2s;
}
.smi-btn-back svg { transform: rotate(180deg); flex-shrink: 0; }
.smi-btn-back:hover { border-color: var(--primary-color); color: var(--primary-dark); }

/* Image column */
.smi-image-col {
    position: relative; background: var(--bg-light);
    display: flex; flex-direction: column;
}
.smi-main-image {
    flex: 1;
    overflow: hidden; min-height: 280px;
}
.smi-main-image img {
    width: 100%; height: 100%; object-fit: cover;
    display: block; transition: transform 0.6s ease;
}
.smi-card:hover .smi-main-image img { transform: scale(1.04); }
.smi-no-image {
    display: flex; align-items: center; justify-content: center;
    font-size: 6rem; min-height: 280px;
    background: linear-gradient(135deg, #eef6ee, #d9edda);
}

/* Price badge (inside image col, desktop only) */
.smi-price-badge {
    background: var(--primary-color);
    color: #fff; text-align: center;
    padding: 1rem 1.25rem;
    display: flex; flex-direction: column; align-items: center; gap: 2px;
}
.spb-label { font-size: 0.78rem; opacity: 0.85; font-weight: 600; }
.spb-value { font-size: 1.7rem; font-weight: 800; line-height: 1.1; }
.spb-currency { font-size: 0.85rem; opacity: 0.85; }

/* ── Gallery ── */
.smi-gallery-section {
    margin-bottom: 3rem;
}
.smi-gallery-title {
    font-size: 1.15rem; font-weight: 700;
    display: flex; align-items: center; gap: 8px;
    margin-bottom: 1.25rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid var(--border-color);
    color: var(--text-color);
}
.smi-gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 10px;
}
.smi-gallery-item {
    display: block; position: relative;
    border-radius: 12px; overflow: hidden;
    aspect-ratio: 1; background: var(--bg-light);
    box-shadow: 0 2px 8px rgba(0,0,0,0.07);
    transition: transform 0.25s, box-shadow 0.25s;
}
.smi-gallery-item:hover { transform: translateY(-3px); box-shadow: 0 8px 22px rgba(0,0,0,0.14); }
.smi-gallery-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.sgi-zoom {
    position: absolute; inset: 0;
    display: flex; align-items: center; justify-content: center;
    background: rgba(0,0,0,0.4); color: #fff;
    opacity: 0; transition: opacity 0.2s;
}
.smi-gallery-item:hover .sgi-zoom { opacity: 1; }

/* ============================
   LIGHTBOX  (#kamkar-lightbox)
   ============================ */
#kamkar-lightbox {
    display: none;
    position: fixed; inset: 0; z-index: 99999;
}
#kamkar-lightbox.active { display: flex; align-items: center; justify-content: center; }
#kamkar-lightbox .lb-backdrop {
    position: absolute; inset: 0;
    background: rgba(0,0,0,0.92);
    cursor: zoom-out;
}
#kamkar-lightbox .lb-box {
    position: relative; z-index: 1;
    max-width: 90vw; max-height: 90vh;
    display: flex; align-items: center; justify-content: center;
}
#kamkar-lightbox .lb-img {
    max-width: 90vw; max-height: 85vh;
    border-radius: 8px;
    box-shadow: 0 8px 40px rgba(0,0,0,0.7);
    display: block;
    object-fit: contain;
    animation: lbFadeIn .2s ease;
}
@keyframes lbFadeIn { from { opacity: 0; transform: scale(.96); } to { opacity: 1; transform: scale(1); } }
#kamkar-lightbox .lb-close {
    position: fixed; top: 1rem; left: 1rem;
    background: rgba(255,255,255,0.15); border: none; color: #fff;
    font-size: 1.1rem; width: 40px; height: 40px; border-radius: 50%;
    cursor: pointer; display: flex; align-items: center; justify-content: center;
    transition: background .2s; z-index: 2;
}
#kamkar-lightbox .lb-close:hover { background: rgba(255,255,255,0.3); }
#kamkar-lightbox .lb-prev,
#kamkar-lightbox .lb-next {
    position: fixed; top: 50%; transform: translateY(-50%);
    background: rgba(255,255,255,0.15); border: none; color: #fff;
    font-size: 2.2rem; width: 48px; height: 48px; border-radius: 50%;
    cursor: pointer; display: flex; align-items: center; justify-content: center;
    transition: background .2s; z-index: 2; line-height: 1;
}
#kamkar-lightbox .lb-prev { right: 1rem; }
#kamkar-lightbox .lb-next { left: 1rem; }
#kamkar-lightbox .lb-prev:hover,
#kamkar-lightbox .lb-next:hover { background: rgba(255,255,255,0.35); }

/* comments removed — disabled for menu items */

/* ============================
   PAGINATION
   ============================ */
.nav-links { display: flex; justify-content: center; gap: 8px; margin-top: 2rem; }
.nav-links a, .nav-links span { padding: 0.5rem 1rem; border: 1px solid var(--border-color); border-radius: 6px; color: var(--text-color); }
.nav-links .current { background: var(--primary-color); border-color: var(--primary-color); color: #fff; }
