:root {
    --ground: #080b10;
    --surface: #171f30;
    --surface-dark: #101621;
    --ink: #f4f7fb;
    --muted: #8792a5;
    --cyan: #37d9f2;
    --violet: #7c4dff;
    --max: 1120px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
[hidden] { display: none !important; }
body {
    margin: 0;
    min-width: 320px;
    background: var(--ground);
    color: var(--ink);
    font-family: "Plus Jakarta Sans", Arial, sans-serif;
    line-height: 1.4;
}
a { color: inherit; text-decoration: none; }
button, input { font: inherit; }
a:focus-visible, button:focus-visible, input:focus-visible {
    outline: 2px solid var(--cyan);
    outline-offset: 2px;
}

.fs-header {
    min-height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 0 max(16px, calc((100% - var(--max)) / 2));
    background: #0d1119;
}
.fs-back {
    min-height: 38px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 0 14px;
    border-radius: 999px;
    background: #1a2231;
    color: #e7ebf2;
    font-size: .78rem;
    font-weight: 800;
    transition: background .2s ease, transform .2s ease;
}
.fs-back:hover { background: #263247; transform: translateX(-3px); }
.fs-back:active { transform: translateX(-3px) scale(.97); }
.fs-count { color: #aab4c5; font-size: .72rem; font-weight: 700; white-space: nowrap; }
.fs-count::before { content: ""; width: 7px; height: 7px; display: inline-block; margin-right: 7px; border-radius: 50%; background: #34d399; animation: livePulse 1.8s ease-out infinite; }

main { width: min(calc(100% - 32px), var(--max)); margin: 0 auto; }
.fs-content { padding: 38px 0 72px; }
.fs-content-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 22px; }
.fs-title-block h1 { margin: 0; font-size: clamp(2rem, 5vw, 3.5rem); line-height: 1; letter-spacing: -.045em; }
.fs-title-block p { max-width: 540px; margin: 12px 0 0; color: #aab4c5; font-size: .86rem; }
.fs-live { display: flex; align-items: center; gap: 8px; padding: 9px 12px; border-radius: 999px; background: #281711; color: #fb923c; font-size: .72rem; font-weight: 800; white-space: nowrap; }
.fs-live-dot { width: 7px; height: 7px; border-radius: 50%; background: #f97316; animation: livePulse 1.8s ease-out infinite; }
@keyframes livePulse { 0% { box-shadow: 0 0 0 0 rgba(249, 115, 22, .65); } 75%, 100% { box-shadow: 0 0 0 8px rgba(249, 115, 22, 0); } }

.fs-search-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); }
.fs-search-wrap { position: relative; width: 100%; margin-bottom: 14px; }
.fs-search-icon { position: absolute; top: 50%; left: 16px; width: 18px; height: 18px; transform: translateY(-50%); fill: none; stroke: #64748b; stroke-width: 2; pointer-events: none; transition: stroke .2s ease, transform .2s ease; }
.fs-search-wrap:focus-within .fs-search-icon { stroke: #fb923c; transform: translateY(-50%) scale(1.1); }
.fs-search-wrap input { width: 100%; min-height: 50px; padding: 0 16px 0 48px; border: 2px solid #202b3d; border-radius: 12px; background: #101621; color: var(--ink); outline: none; transition: border-color .2s ease, background .2s ease; }
.fs-search-wrap input::placeholder { color: #667287; }
.fs-search-wrap input:focus { border-color: #f97316; background: #131b29; }

.fs-chips { display: flex; gap: 9px; margin: 0 0 26px; padding: 0 0 5px; overflow-x: auto; scrollbar-width: none; }
.fs-chips::-webkit-scrollbar { display: none; }
.fs-chip { flex: 0 0 auto; min-height: 34px; padding: 0 15px; border: 0; border-radius: 999px; background: #151d2a; color: #aeb8c9; font-size: .72rem; font-weight: 800; cursor: pointer; transition: background .2s ease, color .2s ease, transform .2s ease; }
.fs-chip:hover { background: #222e41; color: #fff; transform: translateY(-2px); }
.fs-chip:active { transform: scale(.95); }
.fs-chip.active { background: #f97316; color: #fff; }

.fs-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.fs-card { min-width: 0; display: flex; flex-direction: column; overflow: hidden; border: 0; border-radius: 14px; background: #171f30; animation: cardIn .45s both; transition: transform .25s ease, background .25s ease; }
.fs-card:hover { background: #1c2639; transform: translateY(-6px); }
@keyframes cardIn { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: translateY(0); } }
.fs-image { height: 142px; display: grid; place-items: center; overflow: hidden; background: #101827; }
.fs-image img { width: 100%; height: 100%; object-fit: cover; transition: transform .45s ease; }
.fs-card:hover .fs-image img { transform: scale(1.06); }
.fs-placeholder { display: grid; place-items: center; color: #53627a; font-size: 1.3rem; font-weight: 900; transition: color .25s ease, transform .25s ease; }
.fs-card:hover .fs-placeholder { color: #fb923c; transform: scale(1.06); }
.fs-card-body { min-width: 0; display: flex; flex: 1; flex-direction: column; padding: 13px; }
.fs-category { width: fit-content; max-width: 100%; overflow: hidden; padding: 3px 7px; border-radius: 5px; background: #202b41; color: #a5b4fc; font-size: .62rem; font-weight: 800; text-overflow: ellipsis; white-space: nowrap; }
.fs-card h3 { display: -webkit-box; min-height: 37px; margin: 7px 0 4px; overflow: hidden; color: #fff; font-size: .84rem; line-height: 1.4; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.fs-card-meta { margin-bottom: 10px; color: #94a3b8; font-size: .65rem; }
.fs-card-bottom { display: flex; align-items: flex-end; justify-content: space-between; gap: 8px; margin-top: auto; padding-top: 11px; background: #131b29; margin-right: -13px; margin-bottom: -13px; margin-left: -13px; padding-right: 13px; padding-bottom: 13px; padding-left: 13px; }
.fs-price-wrap { display: flex; min-width: 0; flex-direction: column; }
.fs-price { color: #38bdf8; font-size: 1rem; font-weight: 900; line-height: 1.2; }
.fs-old-price { min-height: 14px; color: #68768b; font-size: .66rem; text-decoration: line-through; }
.fs-stock { color: #34d399; font-size: .66rem; font-weight: 800; }
.fs-order { min-width: 58px; min-height: 28px; display: inline-flex; flex: 0 0 auto; align-items: center; justify-content: center; gap: 4px; padding: 0 9px; border: 0; border-radius: 7px; background: #7357f6; color: #fff; font-size: .68rem; font-weight: 800; cursor: pointer; text-align: center; box-shadow: 0 3px 8px rgba(115, 87, 246, .22); transition: background .18s ease, transform .18s ease, box-shadow .18s ease; }
.fs-order i { font-size: .62rem; }
.fs-order:hover { background: #846df8; transform: translateY(-1px); box-shadow: 0 5px 12px rgba(115, 87, 246, .35); }
.fs-order:active { transform: scale(.95); }
.fs-order[aria-disabled="true"] { background: #30394a; color: #798499; box-shadow: none; pointer-events: none; }
.fs-order[aria-disabled="true"] { background: #30394a; color: #798499; pointer-events: none; }
.fs-state { grid-column: 1 / -1; padding: 56px 20px; border-radius: 14px; background: #101621; color: var(--muted); text-align: center; }
.fs-retry { display: block; margin: 20px auto 0; padding: 11px 20px; border: 0; border-radius: 9px; background: #f97316; color: #fff; font-weight: 900; cursor: pointer; transition: transform .2s ease, background .2s ease; }
.fs-retry:hover { background: #ea580c; transform: translateY(-2px); }
.fs-retry:active { transform: scale(.96); }

.fs-footer {
    margin-top: 40px;
    padding: 42px max(20px, calc((100% - var(--max)) / 2)) 24px;
    border-top: 1px solid #1d2635;
    background: #080b10;
    color: #94a3b8;
    font-size: .82rem;
}
.fs-footer-inner { max-width: var(--max); margin: 0 auto; display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 36px; margin-bottom: 34px; }
.fs-footer-brand { display: flex; align-items: center; gap: 10px; color: #fff; font-size: 1rem; }
.fs-footer-brand img { width: 42px; height: 42px; object-fit: contain; background: #fff; border-radius: 8px; }
.fs-footer-main p { max-width: 350px; color: var(--muted); }
.fs-footer-links { display: flex; flex-direction: column; gap: 10px; }
.fs-footer-links h2 { margin: 0 0 4px; color: #fff; font-size: .85rem; }
.fs-footer-links a { color: var(--muted); }
.fs-footer-links a:hover { color: #fff; }
.fs-footer-bottom { display: flex; justify-content: space-between; gap: 16px; padding-top: 20px; border-top: 1px solid #1d2635; font-size: .72rem; }
.fs-footer-bottom div { display: flex; gap: 16px; flex-wrap: wrap; }
.modern-footer {
    margin-top: 40px;
    padding: 42px max(20px, calc((100% - var(--max)) / 2)) 24px;
    border-top: 1px solid #1d2635;
    background: #080b10;
    color: #94a3b8;
    font-size: .82rem;
}
.mf-container { max-width: var(--max); margin: 0 auto; }
.mf-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 36px; margin-bottom: 34px; }
.mf-bottom { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-top: 20px; border-top: 1px solid #1d2635; font-size: .72rem; }
.mf-bottom-links { display: flex; gap: 16px; }

.floating-chat-widget { position: fixed; right: 24px; bottom: 24px; z-index: 10000; display: flex; flex-direction: column; align-items: flex-end; }
.floating-chat-btn { position: relative; width: 56px; height: 56px; display: flex; align-items: center; justify-content: center; padding: 0; border: 0; border-radius: 50%; background: #16a34a; color: #fff; cursor: pointer; box-shadow: 0 8px 24px rgba(34, 197, 94, .45), 0 0 0 2px rgba(255, 255, 255, .25); transition: all .3s cubic-bezier(.4, 0, .2, 1); }
.floating-chat-btn:hover { transform: scale(1.08) translateY(-2px); box-shadow: 0 12px 28px rgba(34, 197, 94, .65), 0 0 0 2px rgba(255, 255, 255, .3); }
.floating-chat-btn svg { width: 26px; height: 26px; fill: currentColor; }
.icon-chat, .icon-close { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; }
.icon-close { display: none; color: #f87171; }
.icon-close svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
.floating-chat-widget.open .floating-chat-btn { background: #1e293b; transform: rotate(90deg); }
.floating-chat-widget.open .icon-chat, .floating-chat-widget.open .chat-online-dot { display: none; }
.floating-chat-widget.open .icon-close { display: flex; }
.chat-online-dot { position: absolute; top: 2px; right: 2px; width: 14px; height: 14px; border: 2.5px solid #080b10; border-radius: 50%; background: #4ade80; animation: chatPulse 2s infinite; }
@keyframes chatPulse { 0% { box-shadow: 0 0 0 0 rgba(74, 222, 128, .8); } 70% { box-shadow: 0 0 0 9px rgba(74, 222, 128, 0); } 100% { box-shadow: 0 0 0 0 rgba(74, 222, 128, 0); } }
.floating-chat-popup { position: absolute; right: 0; bottom: 68px; width: 310px; padding: 16px; visibility: hidden; opacity: 0; pointer-events: none; border: 1px solid rgba(255, 255, 255, .12); border-radius: 20px; background: #0f172a; box-shadow: 0 20px 40px rgba(0, 0, 0, .65); transform: translateY(14px) scale(.94); transform-origin: bottom right; transition: opacity .25s ease, transform .25s ease, visibility .25s ease; }
.floating-chat-widget.open .floating-chat-popup { visibility: visible; opacity: 1; pointer-events: auto; transform: translateY(0) scale(1); }
.floating-chat-popup-header { margin-bottom: 12px; padding-bottom: 10px; border-bottom: 1px solid rgba(255, 255, 255, .08); }
.fcp-title { display: flex; align-items: center; gap: 6px; margin-bottom: 3px; color: #fff; font-size: 14px; font-weight: 800; }
.fcp-sub { color: #94a3b8; font-size: 11px; }
.floating-chat-options { display: flex; flex-direction: column; gap: 8px; }
.floating-chat-option { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border: 1px solid transparent; border-radius: 14px; color: #fff; }
.floating-chat-option.wa { border-color: rgba(34, 197, 94, .25); background: rgba(34, 197, 94, .12); }
.floating-chat-option.tg { border-color: rgba(56, 189, 248, .25); background: rgba(56, 189, 248, .12); }
.fco-icon { width: 40px; height: 40px; display: flex; flex-shrink: 0; align-items: center; justify-content: center; border-radius: 12px; }
.floating-chat-option.wa .fco-icon { background: #16a34a; }
.floating-chat-option.tg .fco-icon { background: #0284c7; }
.fco-icon svg { width: 20px; height: 20px; fill: currentColor; }
.fco-info { min-width: 0; flex: 1; }
.fco-name, .fco-info strong { display: block; color: #fff; font-size: 13px; font-weight: 700; }
.fco-desc, .fco-info small { display: block; overflow: hidden; color: #94a3b8; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }

@media (max-width: 900px) {
    .fs-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 680px) {
    main { width: calc(100% - 24px); }
    .fs-content { padding: 22px 0 48px; }
    .fs-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
    .fs-image { height: 80px; }
    .fs-card-body { padding: 9px; }
    .fs-card h3 { font-size: .76rem; }
    .fs-card-meta { font-size: .6rem; }
    .fs-price { font-size: .82rem; }
    .fs-order { min-width: 54px; min-height: 27px; padding: 0 8px; font-size: .64rem; }
    .mf-grid { grid-template-columns: 1fr; gap: 24px; }
    .mf-bottom { flex-direction: column; align-items: flex-start; }
    .floating-chat-widget { right: 16px; bottom: 20px; }
}
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
