/* ===========================================================================
   فست‌کارت — کارتِ «خلاصهٔ سفارش» و دکمه‌های مسیرِ خرید. دور ۸۱
   ===========================================================================

   سبد (`cart/summary.html`) و ارسال (`shipping/cartsummary.html`) یک خلاصه
   دارند با یک شکل: سطرهای نام و مبلغ، خطِ جمع، «سودِ شما»، و دکمهٔ اصلیِ گامِ
   بعد. تا این دور خلاصهٔ ارسال سطرهای خط‌دار و دکمه‌ای با نیم‌دایرهٔ تزئینیِ
   قالب داشت و خلاصهٔ سبد شکلِ دیگری.
   =========================================================================== */

.fk-summary,
.hs-ship .hs-ship-summary {
    padding: 20px;
    background: var(--theme-surface, #fff);
    border: 1px solid var(--theme-line, #e5e7eb);
    border-radius: var(--theme-radius-lg, 16px);
    box-shadow: var(--theme-shadow-md, 0 8px 24px rgb(15 23 42 / .06));
}
.fk-summary__title,
.hs-ship .hs-ship-summary__title { margin: 0 0 12px; font-size: var(--ds-text-base, 1rem); font-weight: 800; color: var(--theme-ink, #1f2937); }

.fk-summary__total {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin: 16px 0 0;
    padding-top: 14px;
    border-top: 1px dashed var(--theme-line, #e5e7eb);
    color: var(--theme-ink, #1f2937);
    font-weight: 700;
}
.fk-summary__total strong { font-size: var(--ds-text-xl, 1.3rem); font-weight: 900; font-variant-numeric: tabular-nums; }
.fk-summary__total small { font-size: 12px; font-weight: 600; color: var(--theme-ink-muted, #6b7280); }

.fk-summary__save {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 12px 0 0;
    padding: 9px 12px;
    border-radius: var(--theme-radius-sm, 8px);
    background: var(--theme-success-soft, #ecfdf5);
    color: var(--theme-success-ink, #15803d);
    font-size: 12.5px;
}

/* دور ۸۲ — `position` و `isolation` صریح، و بی شبه‌عنصر: کلاسِ `btn-checkout`ِ قالب یک دایرهٔ `::before` دارد که با
   هاور تا ۹۰۰ پیکسل بزرگ می‌شود؛ دکمه‌ای که `position` نداشت آن را نمی‌بُرید و هالهٔ دکمه صفحه را می‌پوشاند و هر
   کلیکی روی صفحه کلیکِ همین دکمه می‌شد. آن کلاس از دکمه‌های این مسیر برداشته شد و این دو خط نمی‌گذارند برگردد. */
.fk-btn::before, .fk-btn::after { content: none !important; }
.fk-btn {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 48px;
    padding: 0 22px;
    border: 1px solid transparent;
    border-radius: var(--theme-radius, 12px);
    font: inherit;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
    transition: background-color .15s ease, box-shadow .15s ease, transform .15s ease;
}
.fk-btn:focus-visible { outline: 2px solid var(--theme-accent, #0da487); outline-offset: 2px; }
.fk-btn--cta { background: var(--theme-cta, var(--theme-accent, #0da487)); color: #fff; }
.fk-btn--cta:hover { background: var(--theme-cta-strong, var(--theme-accent-strong, #0b8c73)); color: #fff; box-shadow: var(--theme-shadow-md, 0 8px 20px rgb(15 23 42 / .12)); }
.fk-btn--primary { background: var(--theme-accent, #0da487); color: #fff; }
.fk-btn--primary:hover { background: var(--theme-accent-strong, #0b8c73); color: #fff; }
.fk-btn--ghost { border-color: var(--theme-line, #e5e7eb); background: var(--theme-surface, #fff); color: var(--theme-ink, #1f2937); }
.fk-btn--ghost:hover { border-color: var(--theme-accent, #0da487); color: var(--theme-accent, #0da487); }
.fk-summary__go { width: 100%; margin-top: 16px; }

/* ===========================================================================
   ریزِ مبلغ‌ها و اقلامِ سفارش — دور ۸۲ (`cart/_lines.html`، `cart/_items.html`)
   سه دسته با تیترِ کوچک؛ سطرِ صفر کم‌رنگ ولی همیشه هست، تا «مالیات صفر است» با «نوشته نشده» یکی نباشد.
   =========================================================================== */
.fk-lines { display: grid; gap: 4px; }
.fk-lines__group {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 10px 0 4px;
    color: var(--theme-ink-muted, #6b7280);
    font-size: 11.5px;
    font-weight: 800;
    letter-spacing: .02em;
}
.fk-lines__group::after { content: ''; flex: 1; height: 1px; background: var(--theme-line, #e5e7eb); }
.fk-lines > .fk-lines__group:first-child { margin-top: 0; }
.fk-lines dl { margin: 0; display: grid; gap: 8px; }
.fk-lines dl > div { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; font-size: 13px; }
.fk-lines dt { margin: 0; font-weight: 500; color: var(--theme-ink-muted, #6b7280); }
.fk-lines dt small { font-size: 11px; }
.fk-lines dd { margin: 0; font-weight: 700; color: var(--theme-ink, #1f2937); font-variant-numeric: tabular-nums; white-space: nowrap; }
.fk-lines dd small { font-weight: 500; font-size: 11px; color: var(--theme-ink-muted, #6b7280); }
.fk-lines .is-zero dd { font-weight: 500; color: var(--theme-ink-muted, #9ca3af); }
.fk-lines .is-off dd { color: var(--theme-success-ink, #15803d); }
.fk-lines .is-sub { padding-top: 6px; border-top: 1px dashed var(--theme-line, #e5e7eb); }
.fk-lines .is-sub dt { color: var(--theme-ink, #1f2937); font-weight: 700; }
.fk-lines .is-note dd { font-weight: 500; font-size: 12px; color: var(--theme-ink-muted, #6b7280); white-space: normal; text-align: end; }

.fk-items { margin-top: 14px; border: 1px solid var(--theme-line, #e5e7eb); border-radius: var(--theme-radius, 12px); background: var(--theme-tint, #f8fafc); }
.fk-items__head { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 12px; cursor: pointer; list-style: none; font-size: 13px; font-weight: 700; color: var(--theme-ink, #1f2937); }
.fk-items__head::-webkit-details-marker { display: none; }
.fk-items__head small { color: var(--theme-ink-muted, #6b7280); font-weight: 500; }
.fk-items__head i { font-size: 11px; color: var(--theme-ink-muted, #6b7280); transition: transform .2s ease; }
.fk-items[open] .fk-items__head i { transform: rotate(180deg); }
.fk-items__head:focus-visible { outline: 2px solid var(--theme-accent, #0da487); outline-offset: 2px; border-radius: var(--theme-radius, 12px); }
.fk-items__list { margin: 0; padding: 0 12px 10px; list-style: none; display: grid; gap: 8px; max-height: 280px; overflow-y: auto; }
.fk-item { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; align-items: center; gap: 10px; }
.fk-item img { width: 44px; height: 44px; object-fit: contain; border-radius: 10px; border: 1px solid var(--theme-line, #e5e7eb); background: var(--theme-surface, #fff); }
.fk-item__text { display: grid; min-width: 0; line-height: 1.5; }
.fk-item__text b { font-size: 12.5px; font-weight: 700; color: var(--theme-ink, #1f2937); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fk-item__text small { font-size: 11px; color: var(--theme-ink-muted, #6b7280); }
.fk-item__total { font-size: 12.5px; font-weight: 800; color: var(--theme-ink, #1f2937); font-variant-numeric: tabular-nums; }
