/* ===========================
   VARIABLES & RESET
   =========================== */
:root {
    --black: #0a0a0f;
    --card-bg: #16161f;
    --border: #2a2a3a;
    --text: #e8e8f0;
    --muted: #888899;
    --tiktok: #ff0050;
    --facebook: #1877f2;
    --instagram: #e1306c;
    --youtube: #ff0000;
    --accent: #00f5d4;
    --accent2: #7b2fff;
    --price: #f0c040;
    --navbar-h: 56px;
    --tab-h: 44px;
    --font-display: 'Orbitron', monospace;
    --font-body: 'Noto Sans SC', sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
*, *:focus, *:active { outline: none !important; box-shadow: none; -webkit-tap-highlight-color: transparent; }

body {
    background: var(--black);
    color: var(--text);
    font-family: var(--font-body);
    overflow-x: hidden;
    overflow-y: scroll;
}

/* ===========================
   NAVBAR
   =========================== */
.navbar {
    position: fixed;
    top: 0; left: 0; right: 0;
    height: var(--navbar-h);
    background: rgba(10,10,15,0.96);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--border);
    z-index: 200;
}
.navbar-inner {
    max-width: 960px;
    margin: 0 auto;
    padding: 0 16px;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.navbar-brand {
    font-family: var(--font-display);
    font-size: 18px;
    font-weight: 900;
    color: #fff;
    text-decoration: none;
    letter-spacing: -0.01em;
    user-select: none;
    -webkit-user-select: none;
    -ms-user-select: none;
}

.logo-title, .badge, .hero-sub, .trust-bar, .tab-item, .tab-label, .sub-item {
    user-select: none;
    -webkit-user-select: none;
    -ms-user-select: none;
}
.navbar-brand .accent { color: var(--accent); }
.navbar-actions { display: flex; align-items: center; }

.nav-btn {
    border: none;
    border-radius: 8px;
    padding: 7px 14px;
    font-size: 13px;
    font-family: var(--font-body);
    font-weight: 500;
    cursor: pointer;
    white-space: nowrap;
    transition: opacity 0.2s, transform 0.2s;
}
.nav-btn-primary {
    background: linear-gradient(135deg, var(--accent2), #5500cc);
    color: #fff;
    box-shadow: 0 2px 12px rgba(123,47,255,0.35) !important;
}
.nav-btn-primary:hover { opacity: 0.88; transform: translateY(-1px); }
.nav-btn-primary:active { transform: scale(0.97); }

/* ===========================
   PAGE WRAPPER
   =========================== */
.page-wrapper {
    padding-top: var(--navbar-h);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* ===========================
   HERO
   =========================== */
.hero {
    position: relative;
    padding: 52px 24px 44px;
    text-align: center;
    overflow: hidden;
    background: linear-gradient(160deg, #0d0d1a 0%, #0a0a0f 60%, #120a1f 100%);
    border-bottom: 1px solid var(--border);
}
.hero-bg-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(0,245,212,0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0,245,212,0.04) 1px, transparent 1px);
    background-size: 40px 40px;
    pointer-events: none;
}
.hero-content { position: relative; z-index: 1; max-width: 760px; margin: 0 auto; }
.badge {
    display: inline-block;
    background: rgba(0,245,212,0.1);
    border: 1px solid rgba(0,245,212,0.3);
    color: var(--accent);
    font-size: 12px;
    font-weight: 500;
    padding: 5px 16px;
    border-radius: 999px;
    letter-spacing: 0.05em;
    margin-bottom: 18px;
}
.logo-title {
    font-family: var(--font-display);
    font-size: clamp(32px, 7vw, 64px);
    font-weight: 900;
    color: #fff;
    letter-spacing: -0.02em;
    line-height: 1;
    margin-bottom: 14px;
    text-shadow: 0 0 60px rgba(123,47,255,0.4);
}
.logo-title .accent { color: var(--accent); text-shadow: 0 0 30px rgba(0,245,212,0.6); }
.hero-sub {
    font-size: 14px;
    color: var(--muted);
    font-weight: 300;
    margin-bottom: 28px;
    letter-spacing: 0.02em;
}
.trust-bar {
    display: inline-flex;
    align-items: center;
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 12px 24px;
    gap: 20px;
    flex-wrap: wrap;
    justify-content: center;
}
.trust-item { display: flex; flex-direction: column; align-items: center; gap: 2px; }
.trust-num { font-family: var(--font-display); font-size: 17px; font-weight: 700; color: var(--accent); }
.trust-label { font-size: 11px; color: var(--muted); }
.trust-divider { width: 1px; height: 28px; background: var(--border); }

/* ===========================
   TAB NAV
   =========================== */
.tab-nav {
    position: sticky;
    top: var(--navbar-h);
    z-index: 100;
    background: rgba(10,10,15,0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
}
.tab-nav-inner { display: flex; max-width: 960px; margin: 0 auto; padding: 0 8px; height: var(--tab-h); }
.tab-item {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: var(--tab-h);
    padding: 0 8px;
    color: var(--muted);
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    border-bottom: 3px solid transparent;
    transition: color 0.2s, border-color 0.2s;
    white-space: nowrap;
}
.tab-icon { width: 18px; height: 18px; flex-shrink: 0; }
.tab-label { font-size: 13px; }
.tab-item:hover { color: var(--text); }
.tab-item.active { color: #fff; }
.tab-item.active.tiktok    { border-color: var(--tiktok);    color: var(--tiktok); }
.tab-item.active.facebook  { border-color: var(--facebook);  color: var(--facebook); }
.tab-item.active.instagram { border-color: var(--instagram); color: var(--instagram); }
.tab-item.active.youtube   { border-color: var(--youtube);   color: var(--youtube); }

/* ===========================
   SUB NAV
   =========================== */
.sub-nav {
    position: sticky;
    top: calc(var(--navbar-h) + var(--tab-h));
    z-index: 99;
    background: rgba(10,10,15,0.92);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border);
    overflow-x: auto;
    scrollbar-width: none;
}
.sub-nav::-webkit-scrollbar { display: none; }
.sub-nav-inner {
    display: flex;
    max-width: 960px;
    margin: 0 auto;
    padding: 0 12px;
    gap: 4px;
}
.sub-item {
    flex-shrink: 0;
    padding: 7px 14px;
    font-size: 12px;
    font-weight: 500;
    color: var(--muted);
    text-decoration: none;
    border-radius: 6px;
    margin: 5px 0;
    transition: color 0.15s, background 0.15s;
    white-space: nowrap;
}
.sub-item:hover { color: var(--text); background: rgba(255,255,255,0.06); }
.sub-item.active { color: var(--accent); background: rgba(0,245,212,0.1); font-weight: 700; }

/* ===========================
   PRODUCTS
   =========================== */
.product-section {
    flex: 1;
    max-width: 960px;
    width: 100%;
    margin: 0 auto;
    padding: 28px 16px 48px;
}
.product-list { display: flex; flex-direction: column; gap: 12px; }

.empty-tip {
    text-align: center;
    color: var(--muted);
    font-size: 14px;
    padding: 60px 0;
}

.product-card {
    display: flex;
    align-items: center;
    gap: 16px;
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 16px 18px;
    transition: border-color 0.25s, transform 0.2s, box-shadow 0.25s;
    position: relative;
    overflow: hidden;
}
.product-card::before {
    content: '';
    position: absolute;
    left: 0; top: 0; bottom: 0;
    width: 3px;
    background: linear-gradient(to bottom, var(--accent), var(--accent2));
    opacity: 0;
    transition: opacity 0.25s;
}
.product-card:hover {
    border-color: rgba(0,245,212,0.3);
    transform: translateX(3px);
    box-shadow: 0 4px 28px rgba(0,245,212,0.07);
}
.product-card:hover::before { opacity: 1; }

.product-img-wrap {
    position: relative;
    flex-shrink: 0;
    width: 64px; height: 64px;
    background: rgba(255,255,255,0.04);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border);
}
.product-svg { width: 34px; height: 34px; }
.product-badge {
    position: absolute;
    top: -7px; right: -7px;
    background: var(--accent2);
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 999px;
    letter-spacing: 0.03em;
    white-space: nowrap;
}
.product-info { flex: 1; min-width: 0; }
.product-title {
    font-size: 14px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.product-desc {
    font-size: 12px;
    color: var(--muted);
    line-height: 1.5;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.product-price { display: flex; align-items: baseline; gap: 4px; flex-wrap: wrap; }
.product-stock {
    display: flex;
    align-items: center;
    gap: 5px;
    margin-bottom: 7px;
}
.stock-dot {
    width: 6px; height: 6px;
    background: #00dc64;
    border-radius: 50%;
    flex-shrink: 0;
    box-shadow: 0 0 5px rgba(0,220,100,0.5);
}
.stock-text {
    font-size: 11px;
    color: var(--muted);
}

.price-currency {
    font-size: 10px;
    font-weight: 700;
    color: var(--muted);
    letter-spacing: 0.06em;
    text-transform: uppercase;
    padding: 1px 5px;
    border: 1px solid var(--border);
    border-radius: 4px;
    line-height: 1.7;
}
.price-amount {
    font-family: var(--font-display);
    font-size: 18px;
    font-weight: 700;
    color: var(--price);
    letter-spacing: 0.01em;
}
.price-unit {
    font-size: 11px;
    color: var(--muted);
    white-space: nowrap;
}
.product-action { flex-shrink: 0; }

.buy-btn {
    display: flex;
    align-items: center;
    gap: 5px;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.14);
    color: #e8e8f0;
    border-radius: 10px;
    padding: 10px 16px;
    font-size: 13px;
    font-weight: 700;
    font-family: var(--font-body);
    cursor: pointer;
    white-space: nowrap;
    transition: background 0.2s, border-color 0.2s, transform 0.15s;
    outline: none;
}
.buy-btn:hover { background: rgba(255,255,255,0.14); border-color: rgba(255,255,255,0.25); transform: translateY(-1px); }
.buy-btn:active { transform: scale(0.97); }
.buy-btn:focus { outline: none; }
.btn-arrow { transition: transform 0.2s; display: inline-block; }
.buy-btn:hover .btn-arrow { transform: translateX(3px); }

/* ===========================
   FOOTER
   =========================== */
.footer {
    text-align: center;
    padding: 20px 16px;
    border-top: 1px solid var(--border);
    font-size: 12px;
    color: var(--muted);
    margin-top: auto;
}
.footer a { color: var(--accent); text-decoration: none; }
.footer a:hover { text-decoration: underline; }

/* ===========================
   MODALS
   =========================== */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.78);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s;
}
.modal-overlay.show { opacity: 1; pointer-events: all; }
.modal-box {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 18px;
    padding: 32px 28px;
    max-width: 400px;
    width: 100%;
    text-align: center;
    position: relative;
    transform: translateY(16px);
    transition: transform 0.25s;
    box-shadow: 0 20px 60px rgba(0,0,0,0.55);
}
.modal-overlay.show .modal-box { transform: translateY(0); }
.modal-close {
    position: absolute;
    top: 12px; right: 14px;
    background: none; border: none;
    color: var(--muted); font-size: 18px;
    cursor: pointer; transition: color 0.15s;
    line-height: 1;
}
.modal-close:hover { color: #fff; }
.modal-icon { font-size: 38px; margin-bottom: 10px; }
.modal-title { font-size: 15px; font-weight: 700; color: #fff; margin-bottom: 8px; }
.modal-msg { font-size: 13px; color: var(--muted); line-height: 1.7; }
.modal-btns { display: flex; gap: 10px; justify-content: center; margin-top: 20px; }
.modal-btn-primary {
    background: linear-gradient(135deg, var(--accent2), #5500cc);
    color: #fff; border: none; border-radius: 8px;
    padding: 10px 28px; font-size: 14px; font-weight: 700;
    font-family: var(--font-body); cursor: pointer;
    transition: opacity 0.2s;
}
.modal-btn-primary:hover { opacity: 0.85; }

/* Contact modal */
.modal-contact-box { max-width: 440px; text-align: left; padding: 22px 22px 18px; }
.contact-header {
    display: flex; align-items: center; gap: 12px;
    margin-bottom: 14px; padding-bottom: 14px;
    border-bottom: 1px solid var(--border);
}
.contact-header-icon {
    font-size: 26px; width: 46px; height: 46px;
    background: rgba(0,245,212,0.08);
    border: 1px solid rgba(0,245,212,0.2);
    border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.contact-header-title { font-size: 15px; font-weight: 700; color: #fff; margin-bottom: 2px; }
.contact-header-sub { font-size: 12px; color: var(--muted); }
.contact-notice {
    display: flex; align-items: flex-start; gap: 8px;
    background: rgba(0,245,212,0.06);
    border: 1px solid rgba(0,245,212,0.15);
    border-radius: 8px; padding: 9px 11px;
    font-size: 12px; color: var(--muted); line-height: 1.6;
    margin-bottom: 14px;
}
.contact-notice-dot {
    width: 6px; height: 6px; background: var(--accent);
    border-radius: 50%; flex-shrink: 0; margin-top: 5px;
}
.contact-group-label {
    display: flex; align-items: center; gap: 7px;
    font-size: 11px; font-weight: 700; color: var(--muted);
    letter-spacing: 0.07em; text-transform: uppercase; margin-bottom: 7px;
}
.contact-group-icon { width: 14px; height: 14px; color: var(--accent); flex-shrink: 0; }
.contact-cards { display: flex; flex-direction: column; gap: 7px; }
.contact-card {
    display: flex; align-items: center; gap: 10px;
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--border);
    border-radius: 10px; padding: 11px 13px;
    text-decoration: none;
    transition: border-color 0.2s, background 0.2s;
}
.contact-card:hover {
    border-color: rgba(0,245,212,0.3);
    background: rgba(0,245,212,0.05);
}
.contact-card-label { font-size: 11px; color: var(--muted); margin-bottom: 2px; }
.contact-card-value { font-size: 14px; font-weight: 600; color: #fff; }
.contact-card-arrow { margin-left: auto; font-size: 15px; color: var(--accent); flex-shrink: 0; }
.contact-footer {
    margin-top: 14px; padding-top: 12px;
    border-top: 1px solid var(--border);
    font-size: 12px; color: var(--muted); text-align: center;
}

/* Offline modal */
.offline-modal-icon { font-size: 42px; margin-bottom: 10px; }
.offline-modal-tip {
    margin-top: 10px; font-size: 12px; color: var(--muted);
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--border);
    border-radius: 8px; padding: 8px 12px; line-height: 1.6;
}

/* ===========================
   PRODUCT ID & COPY
   =========================== */
.product-id-row {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 4px;
}
.product-id {
    font-size: 11px;
    color: var(--muted);
    font-family: monospace;
    letter-spacing: 0.03em;
}
.copy-id-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 18px; height: 18px;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--muted);
    padding: 0;
    border-radius: 3px;
    transition: color 0.15s, background 0.15s;
    flex-shrink: 0;
}
.copy-id-btn svg { width: 12px; height: 12px; }
.copy-id-btn:hover { color: var(--accent); background: rgba(0,245,212,0.1); }
.copy-id-btn.copied { color: #00dc64; }

/* Buy modal ID box */
.buy-id-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 10px 14px;
    margin: 14px 0 12px;
}
.buy-id-label {
    font-size: 12px;
    color: var(--muted);
}
.buy-id-value {
    font-family: monospace;
    font-size: 15px;
    font-weight: 700;
    color: var(--accent);
    letter-spacing: 0.05em;
}
.copy-id-main-btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    background: linear-gradient(135deg, var(--accent2), #5500cc);
    color: #fff;
    border: none;
    border-radius: 10px;
    padding: 12px;
    font-size: 14px;
    font-weight: 700;
    font-family: var(--font-body);
    cursor: pointer;
    transition: opacity 0.2s, background 0.3s;
    box-shadow: 0 4px 14px rgba(123,47,255,0.3) !important;
}
.copy-id-main-btn svg { width: 16px; height: 16px; flex-shrink: 0; }
.copy-id-main-btn:hover { opacity: 0.88; }
.copy-id-main-btn.copied {
    background: linear-gradient(135deg, #00a550, #007a3a);
    box-shadow: 0 4px 14px rgba(0,165,80,0.3) !important;
}

/* TOAST */
.toast {
    position: fixed;
    bottom: 28px;
    left: 50%;
    transform: translateX(-50%) translateY(16px);
    background: #1e1e2e;
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 10px 18px;
    font-size: 13px;
    color: var(--text);
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    z-index: 1100;
    transition: opacity 0.2s, transform 0.2s;
    box-shadow: 0 6px 24px rgba(0,0,0,0.45);
}
.toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}
.toast.success { border-color: rgba(0,220,100,0.35); color: #00dc64; }
.toast.error   { border-color: rgba(255,80,80,0.35);  color: #ff6464; }

/* ===========================
   RESPONSIVE
   =========================== */
@media (max-width: 480px) {
    .tab-label { font-size: 11px; }
    .tab-icon  { width: 14px; height: 14px; }
    .tab-item  { padding: 11px 4px; gap: 3px; }

    .product-card { gap: 10px; padding: 12px 10px; flex-wrap: wrap; }
    .product-img-wrap { width: 52px; height: 52px; }
    .product-svg { width: 28px; height: 28px; }
    .product-title { font-size: 13px; }
    .price-amount { font-size: 16px; }
    .product-desc { -webkit-line-clamp: 1; }

    .product-action { width: 100%; }
    .buy-btn { width: 100%; justify-content: center; }

    .trust-divider { display: none; }
    .trust-bar { gap: 12px; padding: 10px 14px; }

    .modal-box { padding: 24px 18px; }
    .modal-contact-box { padding: 18px 16px 14px; }
}