/* فروشگاه و صفحه‌ی دسته — هم‌خانواده‌ی صفحه‌ی اصلی (css/home.css)؛ مینیمال، کارت‌های دوستونه در موبایل. docs/SHOP_PAGES.md */
.sh {
    --sh-ink: #17231b;
    --sh-ink-2: #3f4f44;
    --sh-muted: #5f6d64; /* ۵٫۴:۱ روی سفید (قبلاً ۴٫۴۴) */
    --sh-green: #198754;
    --sh-deep: #0f5a37;
    --sh-soft: #eef6f0;
    --sh-cream: #faf7ef;
    --sh-gold: #a87a22;
    --sh-gold-soft: #f6eedb;
    --sh-line: #e5ebe6;
    --sh-radius: 18px;
    --sh-shadow: 0 18px 50px -24px rgba(23, 50, 32, .28);
    color: var(--sh-ink);
    background: #fff;
    overflow-x: clip;
    padding-bottom: 64px;
}
:root { --sh-nav: 84px; } /* با JS از ارتفاع واقعی هدر fixed-top پر می‌شود */
.sh a { text-decoration: none; }
.sh img { max-width: 100%; }
.sh .number { font-family: inherit; }
.sh [hidden] { display: none !important; }

/* ۱. سربرگ */
.sh-hero { padding: calc(var(--sh-nav) + 28px) 0 28px; background: linear-gradient(180deg, var(--sh-cream) 0%, #fff 100%); }
.sh-crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: .82rem; color: var(--sh-muted); }
.sh-crumbs a { color: var(--sh-muted); }
.sh-crumbs a:hover { color: var(--sh-green); }
.sh-crumbs i { font-size: .7rem; opacity: .6; }
.sh-crumbs span { color: var(--sh-ink-2); font-weight: 600; }
.sh-title { margin: 14px 0 0; font-size: 2.25rem; font-weight: 900; line-height: 1.4; letter-spacing: -.3px; color: var(--sh-ink); }
.sh-lead { max-width: 40em; margin: 10px 0 0; font-size: 1rem; line-height: 2; color: var(--sh-ink-2); }
.sh-lead b { color: var(--sh-ink); font-weight: 800; }
.sh-assure { display: flex; flex-wrap: wrap; gap: 8px 22px; margin: 18px 0 0; padding: 0; list-style: none; }
.sh-assure li { display: flex; align-items: center; gap: 8px; font-size: .84rem; font-weight: 600; color: var(--sh-ink-2); }
.sh-assure i { color: var(--sh-green); }

/* ۲. انواع برنج — زیر هدر ثابت می‌چسبد */
.sh-bar { position: sticky; top: var(--sh-nav); z-index: 20; background: rgba(255, 255, 255, .92); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); border-bottom: 1px solid var(--sh-line); }
.sh-types { display: flex; gap: 8px; padding: 12px 0; overflow-x: auto; scrollbar-width: none; scroll-behavior: smooth; }
.sh-types::-webkit-scrollbar { display: none; }
.sh-type { display: inline-flex; flex: none; align-items: center; gap: 8px; padding: 8px 16px; border: 1px solid var(--sh-line); border-radius: 99px; background: #fff; color: var(--sh-ink); font-size: .88rem; font-weight: 700; white-space: nowrap; transition: border-color .2s, color .2s, background .2s; }
.sh-type small { min-width: 22px; padding: 0 6px; border-radius: 99px; background: var(--sh-soft); color: var(--sh-deep); font-size: .72rem; font-weight: 700; line-height: 1.7; text-align: center; }
.sh-type:hover { border-color: var(--sh-green); color: var(--sh-green); }
.sh-type.is-on { background: var(--sh-ink); border-color: var(--sh-ink); color: #fff; }
.sh-type.is-on small { background: rgba(255, 255, 255, .16); color: #fff; }

/* ۳. ابزار فهرست */
.sh-list { padding-top: 24px; }
.sh-tools { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 20px; margin-bottom: 20px; }
.sh-weights { display: flex; flex-wrap: wrap; gap: 8px; }
.sh-chip { display: inline-flex; align-items: center; gap: 4px; min-height: 38px; padding: 0 14px; border: 1px solid var(--sh-line); border-radius: 10px; background: #fff; color: var(--sh-ink-2); font-family: inherit; font-size: .84rem; font-weight: 700; cursor: pointer; transition: border-color .2s, background .2s, color .2s; }
.sh-chip:hover { border-color: var(--sh-green); color: var(--sh-green); }
.sh-chip[aria-pressed="true"] { background: var(--sh-soft); border-color: var(--sh-green); color: var(--sh-deep); }
.sh-sort { display: flex; align-items: center; gap: 14px; margin-inline-start: auto; }
.sh-count { font-size: .84rem; color: var(--sh-muted); white-space: nowrap; }
.sh-count b { color: var(--sh-ink); }
.sh-select { position: relative; display: inline-flex; align-items: center; margin: 0; }
.sh-select i { position: absolute; inset-inline-start: 12px; font-size: .8rem; color: var(--sh-muted); pointer-events: none; }
.sh-select select { min-height: 38px; padding: 0 34px 0 30px; border: 1px solid var(--sh-line); border-radius: 10px; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%236d7b71' stroke-width='1.5'/%3E%3C/svg%3E") no-repeat left 12px center; color: var(--sh-ink); font-family: inherit; font-size: .84rem; font-weight: 700; -webkit-appearance: none; appearance: none; cursor: pointer; }
.sh-select select:focus-visible, .sh-chip:focus-visible, .sh-type:focus-visible, .sh-add:focus-visible { outline: 2px solid var(--sh-green); outline-offset: 2px; }

/* کارت */
.sh-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
.sh-card { display: flex; flex-direction: column; min-width: 0; background: #fff; border: 1px solid var(--sh-line); border-radius: var(--sh-radius); overflow: hidden; transition: box-shadow .25s, transform .25s, border-color .25s; }
.sh-card:hover { box-shadow: var(--sh-shadow); transform: translateY(-3px); border-color: transparent; }
.sh-card-media { position: relative; display: block; aspect-ratio: 1; background: var(--sh-cream); }
.sh-card-media img { display: block; width: 100%; height: 100%; object-fit: cover; }
/* گوشه‌ی راست عکس‌ها برچسب‌های خودشان را دارد؛ برچسب‌های ما سمت چپ */
.sh-flags { position: absolute; top: 10px; inset-inline-end: 10px; display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }
.sh-flag { padding: 2px 10px; border-radius: 99px; font-size: .72rem; font-weight: 800; line-height: 1.8; white-space: nowrap; box-shadow: 0 4px 12px -6px rgba(0, 0, 0, .35); }
.sh-flag.is-best { background: var(--sh-ink); color: #fff; }
.sh-flag.is-value { background: #7a5816; color: #fff; /* ۶٫۵:۱ (قبلاً --sh-gold = ۳٫۸۳) */ }
.sh-flag.is-off { background: #d9480f; color: #fff; }
.sh-card-body { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; flex: 1; padding: 14px 16px 12px; }
.sh-card-top { display: flex; align-items: center; justify-content: space-between; width: 100%; gap: 8px; }
.sh-kg { padding: 2px 10px; border-radius: 8px; background: var(--sh-gold-soft); color: var(--sh-gold); font-size: .74rem; font-weight: 700; line-height: 1.8; }
.sh-like { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; margin-inline-start: auto; padding: 0; border: 0; border-radius: 50%; background: transparent; color: var(--sh-muted); font-size: .95rem; cursor: pointer; transition: background .2s; }
.sh-like:hover { background: var(--sh-soft); }
.sh-like .text-muted { color: var(--sh-muted) !important; }
.sh-card-title { margin: 0; font-size: .95rem; font-weight: 800; line-height: 1.7; min-height: 3.4em; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.sh-card-title a { color: var(--sh-ink); }
.sh-card-title a:hover { color: var(--sh-green); }
.sh-price { display: flex; flex-direction: column; gap: 0; margin-top: auto; }
.sh-price del { font-size: .78rem; color: var(--sh-muted); line-height: 1.6; }
.sh-price b { font-size: 1.12rem; font-weight: 900; color: var(--sh-ink); }
.sh-price small { font-size: .74rem; color: var(--sh-muted); }
.sh-per-kg { font-size: .76rem; color: var(--sh-deep); font-weight: 600; }
.sh-add { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; margin: 0 16px 16px; border: 0; border-radius: 12px; background: var(--sh-green); color: #fff; font-family: inherit; font-size: .88rem; font-weight: 800; cursor: pointer; transition: background .2s, transform .2s; }
.sh-add:hover { background: var(--sh-deep); }
.sh-add:active { transform: scale(.98); }
.sh-add:disabled { opacity: .7; cursor: wait; }

.sh-none { margin: 24px 0 0; padding: 24px; border-radius: var(--sh-radius); background: var(--sh-soft); text-align: center; color: var(--sh-ink-2); }
.sh-none button { padding: 0; border: 0; background: none; color: var(--sh-green); font-family: inherit; font-weight: 800; cursor: pointer; }
.sh-empty { display: flex; align-items: flex-start; gap: 14px; margin-bottom: 24px; padding: 18px 20px; border: 1px solid var(--sh-gold-soft); border-radius: var(--sh-radius); background: var(--sh-cream); }
.sh-empty > i { margin-top: 4px; font-size: 1.3rem; color: var(--sh-gold); }
.sh-empty b { display: block; font-size: 1rem; }
.sh-empty span { display: block; margin-top: 4px; font-size: .88rem; line-height: 1.9; color: var(--sh-ink-2); }
.sh-empty a { color: var(--sh-green); font-weight: 800; }

/* ۴. روش‌های خرید */
.sh-ways { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-top: 48px; }
.sh-way { display: flex; align-items: center; gap: 14px; padding: 16px 18px; border: 1px solid var(--sh-line); border-radius: var(--sh-radius); background: #fff; color: var(--sh-ink); transition: border-color .2s, box-shadow .2s; }
.sh-way:hover { border-color: var(--sh-green); color: var(--sh-ink); box-shadow: var(--sh-shadow); }
.sh-way b { display: block; font-size: .92rem; font-weight: 800; line-height: 1.7; }
.sh-way small { display: block; font-size: .78rem; color: var(--sh-muted); line-height: 1.8; }
.sh-ico { display: inline-flex; flex: none; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: 12px; background: var(--sh-soft); color: var(--sh-green); font-size: 1.05rem; }

/* ۵. راهنمای خرید دسته — بسته؛ با کلیک روی سربرگ یا + باز می‌شود (متن کامل در HTML برای سئو) */
.sh-about { margin-top: 48px; }
.sh-about-card { border: 1px solid var(--sh-line); border-radius: 20px; background: #fff; transition: box-shadow .25s, border-color .25s; }
.sh-about-card:hover, .sh-about-card[open] { border-color: #d3ddd5; }
.sh-about-card[open] { box-shadow: var(--sh-shadow); }
.sh-about-sum { display: flex; align-items: center; gap: 16px; padding: 20px 24px; cursor: pointer; list-style: none; border-radius: 20px; scroll-margin-top: calc(var(--sh-nav) + 70px); }
.sh-about-sum::-webkit-details-marker { display: none; }
.sh-about-sum:focus-visible { outline: 2px solid var(--sh-green); outline-offset: 2px; }
.sh-about-ico { display: inline-flex; flex: none; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: 12px; background: var(--sh-gold-soft); color: var(--sh-gold); }
.sh-about-text { flex: 1; min-width: 0; }
.sh-about-title { margin: 0; font-size: 1.05rem; font-weight: 800; line-height: 1.7; color: var(--sh-ink); }
.sh-about-hint { display: block; font-size: .84rem; line-height: 1.8; color: var(--sh-muted); }
.sh-about-plus { position: relative; flex: none; width: 40px; height: 40px; border: 1px solid var(--sh-line); border-radius: 50%; background: #fff; transition: background .2s, border-color .2s, transform .3s; }
.sh-about-plus::before, .sh-about-plus::after { content: ""; position: absolute; top: 50%; left: 50%; width: 14px; height: 2px; margin: -1px 0 0 -7px; border-radius: 2px; background: var(--sh-ink); transition: transform .3s, background .2s; }
.sh-about-plus::after { transform: rotate(90deg); }
.sh-about-sum:hover .sh-about-plus { border-color: var(--sh-green); }
.sh-about-card[open] .sh-about-plus { background: var(--sh-ink); border-color: var(--sh-ink); transform: rotate(180deg); }
.sh-about-card[open] .sh-about-plus::before, .sh-about-card[open] .sh-about-plus::after { background: #fff; }
.sh-about-card[open] .sh-about-plus::after { transform: rotate(0deg); }
.sh-about-body { padding: 0 36px 28px; border-top: 1px solid var(--sh-line); animation: sh-fade .3s ease; }
@keyframes sh-fade { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
.sh-toc { margin-top: 24px; padding: 16px 20px; border-radius: 14px; background: var(--sh-cream); }
.sh-toc b { display: block; font-size: .88rem; font-weight: 800; }
.sh-toc ol { columns: 2; column-gap: 32px; margin: 10px 0 0; padding-inline-start: 18px; font-size: .86rem; line-height: 2.1; }
.sh-toc li { break-inside: avoid; }
.sh-toc a { color: var(--sh-ink-2); }
.sh-toc a:hover { color: var(--sh-green); }
.sh-prose { position: relative; margin-top: 20px; font-size: 1rem; line-height: 2.1; color: var(--sh-ink-2); overflow-wrap: anywhere; }
.sh-prose > :first-child { margin-top: 0; }
.sh-prose h2, .sh-prose h3, .sh-prose h4 { margin: 1.6em 0 .6em; color: var(--sh-ink); font-weight: 800; line-height: 1.6; text-align: start !important; scroll-margin-top: calc(var(--sh-nav) + 70px); }
.sh-prose h2 *, .sh-prose h3 *, .sh-prose h4 * { color: inherit !important; font-size: inherit !important; }
.sh-prose h2 { font-size: 1.3rem; }
.sh-prose h3 { font-size: 1.1rem; }
.sh-prose h4 { font-size: 1rem; }
.sh-prose p { margin: 0 0 1em; }
.sh-prose a { color: var(--sh-green); font-weight: 600; text-decoration: underline; text-decoration-color: rgba(25, 135, 84, .3); text-underline-offset: 4px; }
.sh-prose img { display: block; height: auto; margin: 20px auto; border-radius: 16px; }
.sh-prose ul, .sh-prose ol { padding-inline-start: 22px; }
.sh-prose table { display: block; width: 100%; max-width: 100%; margin: 20px 0; overflow-x: auto; border-collapse: collapse; font-size: .9rem; }
.sh-prose th, .sh-prose td { padding: 10px 14px; border: 1px solid var(--sh-line); text-align: center; }
.sh-prose th { background: var(--sh-soft); color: var(--sh-ink); font-weight: 800; }
.sh-prose th span { color: inherit !important; }
.sh-more { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; margin: 16px auto 0; padding: 0 22px; border: 1px solid var(--sh-line); border-radius: 12px; background: #fff; color: var(--sh-ink); font-family: inherit; font-size: .88rem; font-weight: 800; cursor: pointer; }
.sh-more:hover { border-color: var(--sh-ink); }

@media (max-width: 1199.98px) {
    .sh-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 991.98px) {
    .sh-title { font-size: 1.85rem; }
    .sh-ways { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 767.98px) {
    .sh-hero { padding: calc(var(--sh-nav) + 16px) 0 18px; }
    .sh-title { margin-top: 10px; font-size: 1.5rem; }
    .sh-lead { font-size: .9rem; line-height: 1.9; }
    .sh-assure { gap: 6px 14px; margin-top: 12px; }
    .sh-assure li { font-size: .76rem; }
    .sh-types { padding: 10px 0; }
    .sh-type { padding: 7px 13px; font-size: .82rem; }
    .sh-list { padding-top: 16px; }
    .sh-tools { gap: 10px; margin-bottom: 14px; }
    .sh-weights { flex-wrap: nowrap; width: 100%; overflow-x: auto; scrollbar-width: none; }
    .sh-weights::-webkit-scrollbar { display: none; }
    .sh-chip { flex: none; min-height: 36px; padding: 0 12px; font-size: .8rem; }
    .sh-sort { width: 100%; justify-content: space-between; margin: 0; }
    .sh-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
    .sh-card { border-radius: 14px; }
    .sh-card:hover { transform: none; }
    .sh-flags { top: 8px; inset-inline-end: 8px; gap: 4px; }
    .sh-flag { padding: 1px 8px; font-size: .64rem; }
    .sh-card-body { gap: 4px; padding: 10px 10px 8px; }
    .sh-kg { padding: 1px 8px; font-size: .68rem; }
    .sh-like { width: 28px; height: 28px; font-size: .85rem; }
    .sh-card-title { font-size: .82rem; line-height: 1.7; }
    .sh-price b { font-size: .98rem; }
    .sh-per-kg { font-size: .68rem; }
    .sh-add { min-height: 40px; margin: 0 10px 10px; border-radius: 10px; font-size: .78rem; gap: 6px; }
    .sh-ways { margin-top: 32px; gap: 10px; }
    .sh-about { margin-top: 32px; }
    .sh-about-card, .sh-about-sum { border-radius: 16px; }
    .sh-about-sum { gap: 12px; padding: 16px; }
    .sh-about-ico { width: 38px; height: 38px; border-radius: 10px; }
    .sh-about-title { font-size: .95rem; }
    .sh-about-hint { font-size: .76rem; }
    .sh-about-plus { width: 34px; height: 34px; }
    .sh-about-body { padding: 0 16px 20px; }
    .sh-toc ol { columns: 1; }
    .sh-prose { font-size: .94rem; }
    .sh-prose h2 { font-size: 1.12rem; }
}
