/* DS Group shop theme — dark navy + orange.
   Standalone stylesheet (public/css/shop.css). Plain CSS on purpose:
   the shop does not depend on a Vite rebuild to look right. */

:root {
    --shop-bg: #0a0f1e;
    --shop-bg-soft: #0f1628;
    --shop-panel: #131a2e;
    --shop-panel-2: #182238;
    --shop-border: #232c44;
    --shop-border-soft: #1b2338;
    --shop-text: #f3f4f6;
    --shop-text-2: #cbd5e1;
    --shop-muted: #8b98b3;
    --shop-orange: #f97316;
    --shop-orange-2: #ea580c;
    --shop-orange-soft: rgba(249, 115, 22, .14);
    --shop-green: #22c55e;
    --shop-red: #ef4444;
    --shop-amber: #f59e0b;
}

.shop-body {
    background: var(--shop-bg) !important;
    color: var(--shop-text);
    min-height: 100vh;
}

.brand-gradient {
    background: linear-gradient(90deg, #f05020, #f08010) !important;
}
.brand-gradient-soft {
    background: linear-gradient(90deg, rgba(240, 80, 32, .16), rgba(240, 128, 16, .08)) !important;
}
.brand-gradient-gold {
    background: linear-gradient(90deg, #f59e0b, #f97316) !important;
}

/* ---------- Header ---------- */
.shop-header {
    position: sticky;
    top: 0;
    z-index: 40;
    background: rgba(10, 15, 30, .96);
    border-bottom: 1px solid var(--shop-border);
    backdrop-filter: blur(6px);
}
.shop-header-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 16px;
    height: 60px;
    display: flex;
    align-items: center;
    gap: 16px;
}
.shop-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--shop-text);
    font-weight: 700;
    font-size: 17px;
    letter-spacing: .2px;
    white-space: nowrap;
}
.shop-brand img { height: 34px; width: auto; }
.shop-brand .shop-brand-tag {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--shop-orange);
}
.shop-header-nav {
    display: none;
    align-items: center;
    gap: 4px;
    margin-left: 8px;
}
.shop-header-nav a {
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    color: var(--shop-text-2);
    text-decoration: none;
}
.shop-header-nav a:hover, .shop-header-nav a.shop-nav-active {
    background: var(--shop-panel);
    color: #fff;
}
.shop-header-spacer { flex: 1; }

.shop-currency {
    display: flex;
    border: 1px solid var(--shop-border);
    border-radius: 999px;
    overflow: hidden;
    background: var(--shop-panel);
}
.shop-currency a {
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 700;
    color: var(--shop-muted);
    text-decoration: none;
}
.shop-currency a.shop-currency-active {
    background: var(--shop-orange);
    color: #fff;
}

.shop-bell {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 999px;
    color: var(--shop-text-2);
    text-decoration: none;
    border: 1px solid var(--shop-border);
    background: var(--shop-panel);
}
.shop-bell-dot {
    position: absolute;
    top: 7px;
    right: 8px;
    min-width: 15px;
    height: 15px;
    padding: 0 3px;
    border-radius: 999px;
    background: var(--shop-red);
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

.shop-balance {
    display: none;
    align-items: center;
    gap: 6px;
    padding: 7px 12px;
    border-radius: 999px;
    background: rgba(34, 197, 94, .12);
    border: 1px solid rgba(34, 197, 94, .35);
    color: #4ade80;
    font-size: 13px;
    font-weight: 700;
    text-decoration: none;
    white-space: nowrap;
}
.shop-avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 999px;
    background: linear-gradient(135deg, #f05020, #f08010);
    color: #fff;
    font-weight: 700;
    font-size: 15px;
    text-decoration: none;
    border: none;
    cursor: pointer;
}

/* ---------- Layout ---------- */
.shop-main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px 16px 110px;
}
.shop-footer {
    max-width: 1200px;
    margin: 0 auto;
    padding: 8px 16px 110px;
    color: var(--shop-muted);
    font-size: 12px;
    text-align: center;
}
.shop-footer a { color: var(--shop-orange); text-decoration: none; }

/* ---------- Cards / panels ---------- */
.shop-card {
    background: var(--shop-panel);
    border: 1px solid var(--shop-border);
    border-radius: 14px;
}
.shop-card-body { padding: 18px; }
.shop-section-title {
    font-size: 17px;
    font-weight: 700;
    color: var(--shop-text);
}
.shop-muted { color: var(--shop-muted); }
.shop-link { color: var(--shop-orange); text-decoration: none; font-weight: 600; }
.shop-link:hover { text-decoration: underline; }

/* ---------- Buttons / inputs ---------- */
.shop-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border-radius: 10px;
    padding: 10px 18px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    border: 1px solid transparent;
    transition: filter .15s ease, background .15s ease;
}
.shop-btn:hover { filter: brightness(1.08); }
.shop-btn-primary {
    background: linear-gradient(90deg, #f05020, #f08010);
    color: #fff;
}
.shop-btn-outline {
    background: transparent;
    border-color: var(--shop-orange);
    color: var(--shop-orange);
}
.shop-btn-ghost {
    background: var(--shop-panel-2);
    border-color: var(--shop-border);
    color: var(--shop-text);
}
.shop-btn-danger { background: #dc2626; color: #fff; }
.shop-btn-success { background: #16a34a; color: #fff; }
.shop-btn-sm { padding: 7px 12px; font-size: 12px; border-radius: 8px; }
.shop-btn-block { width: 100%; }
.shop-btn:disabled { opacity: .5; cursor: not-allowed; }

.shop-input, .shop-select, .shop-textarea {
    display: block;
    width: 100%;
    border-radius: 10px;
    border: 1px solid var(--shop-border);
    background: var(--shop-bg-soft);
    color: var(--shop-text);
    padding: 10px 12px;
    font-size: 14px;
    outline: none;
}
.shop-input:focus, .shop-select:focus, .shop-textarea:focus {
    border-color: var(--shop-orange);
    box-shadow: 0 0 0 3px rgba(249, 115, 22, .18);
}
.shop-input::placeholder { color: #5b6b8c; }
.shop-label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--shop-text-2);
    margin-bottom: 6px;
}

/* ---------- Badges ---------- */
.shop-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    border-radius: 999px;
    padding: 3px 10px;
    font-size: 11px;
    font-weight: 700;
    white-space: nowrap;
}
.shop-badge-green { background: rgba(34, 197, 94, .14); color: #4ade80; }
.shop-badge-red { background: rgba(239, 68, 68, .14); color: #f87171; }
.shop-badge-amber { background: rgba(245, 158, 11, .14); color: #fbbf24; }
.shop-badge-blue { background: rgba(59, 130, 246, .14); color: #60a5fa; }
.shop-badge-purple { background: rgba(168, 85, 247, .14); color: #c084fc; }
.shop-badge-gray { background: rgba(148, 163, 184, .16); color: #cbd5e1; }
.shop-badge-orange { background: var(--shop-orange-soft); color: #fb923c; }

/* ---------- Product grid ---------- */
.shop-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
}
.shop-product-card {
    display: flex;
    flex-direction: column;
    background: var(--shop-panel);
    border: 1px solid var(--shop-border);
    border-radius: 14px;
    overflow: hidden;
    text-decoration: none;
    color: var(--shop-text);
    transition: border-color .15s ease, transform .15s ease;
}
.shop-product-card:hover { border-color: var(--shop-orange); transform: translateY(-2px); }
.shop-product-img {
    height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--shop-bg-soft);
    border-bottom: 1px solid var(--shop-border-soft);
    padding: 12px;
}
.shop-product-img img { max-height: 96px; max-width: 100%; object-fit: contain; }
.shop-product-img .shop-product-icon {
    width: 52px;
    height: 52px;
    border-radius: 12px;
    background: var(--shop-orange-soft);
    color: var(--shop-orange);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: 700;
}
.shop-product-body { padding: 14px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.shop-product-name { font-weight: 700; font-size: 14px; line-height: 1.3; }
.shop-product-cat { font-size: 12px; color: var(--shop-muted); }
.shop-product-foot {
    margin-top: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding-top: 8px;
}
.shop-price { font-size: 17px; font-weight: 800; color: var(--shop-orange); }
.shop-price-sub { font-size: 11px; color: var(--shop-muted); font-weight: 400; }
.shop-stock { font-size: 12px; color: var(--shop-muted); }

.shop-chips { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: none; }
.shop-chips::-webkit-scrollbar { display: none; }
.shop-chip {
    flex-shrink: 0;
    padding: 7px 14px;
    border-radius: 999px;
    border: 1px solid var(--shop-border);
    background: var(--shop-panel);
    color: var(--shop-text-2);
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
}
.shop-chip:hover { border-color: var(--shop-orange); color: #fff; }
.shop-chip-active { background: var(--shop-orange); border-color: var(--shop-orange); color: #fff; }

.shop-filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}
.shop-filter-bar .shop-input { flex: 1; min-width: 180px; }
.shop-filter-bar .shop-select { width: auto; min-width: 150px; }
.shop-toggle {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 600;
    color: var(--shop-text-2);
    cursor: pointer;
    user-select: none;
}
.shop-toggle input { accent-color: var(--shop-orange); width: 16px; height: 16px; }

/* ---------- Quantity selector ---------- */
.shop-qty { display: flex; flex-wrap: wrap; gap: 8px; }
.shop-qty-btn {
    min-width: 44px;
    padding: 8px 10px;
    border-radius: 9px;
    border: 1px solid var(--shop-border);
    background: var(--shop-panel-2);
    color: var(--shop-text);
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
}
.shop-qty-btn:hover { border-color: var(--shop-orange); }
.shop-qty-btn.shop-qty-active {
    background: var(--shop-orange);
    border-color: var(--shop-orange);
    color: #fff;
}

/* ---------- Stats ---------- */
.shop-stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.shop-stat {
    background: var(--shop-panel);
    border: 1px solid var(--shop-border);
    border-radius: 14px;
    padding: 16px;
}
.shop-stat-label { font-size: 12px; font-weight: 600; color: var(--shop-muted); text-transform: uppercase; letter-spacing: .5px; }
.shop-stat-value { margin-top: 6px; font-size: 22px; font-weight: 800; color: var(--shop-text); }

.shop-account {
    background: linear-gradient(135deg, #131a2e, #1a2340);
    border: 1px solid var(--shop-border);
    border-radius: 16px;
    padding: 20px;
}
.shop-account-row { display: flex; align-items: center; gap: 14px; }
.shop-account-avatar {
    width: 52px;
    height: 52px;
    border-radius: 999px;
    background: linear-gradient(135deg, #f05020, #f08010);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    font-weight: 800;
    color: #fff;
    flex-shrink: 0;
}

.shop-quick {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
}
.shop-quick a {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 14px 6px;
    border-radius: 12px;
    background: var(--shop-panel);
    border: 1px solid var(--shop-border);
    color: var(--shop-text-2);
    font-size: 12px;
    font-weight: 600;
    text-decoration: none;
    text-align: center;
}
.shop-quick a:hover { border-color: var(--shop-orange); color: #fff; }
.shop-quick .shop-quick-icon { font-size: 20px; }

.shop-list-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 13px 14px;
    border-radius: 12px;
    border: 1px solid var(--shop-border-soft);
    background: var(--shop-bg-soft);
    color: var(--shop-text);
    text-decoration: none;
}
.shop-list-row:hover { border-color: var(--shop-orange); }

/* ---------- Tables (dark) ---------- */
.shop-table-wrap { overflow-x: auto; }
.shop-table { min-width: 100%; border-collapse: collapse; font-size: 14px; }
.shop-table th {
    text-align: left;
    padding: 10px 14px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .6px;
    color: var(--shop-muted);
    border-bottom: 1px solid var(--shop-border);
    white-space: nowrap;
}
.shop-table td {
    padding: 12px 14px;
    border-bottom: 1px solid var(--shop-border-soft);
    color: var(--shop-text-2);
    white-space: nowrap;
    vertical-align: middle;
}
.shop-table tr:last-child td { border-bottom: none; }

/* ---------- Tabs ---------- */
.shop-tabs { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; }
.shop-tabs::-webkit-scrollbar { display: none; }
.shop-tab {
    flex-shrink: 0;
    padding: 8px 16px;
    border-radius: 999px;
    border: 1px solid var(--shop-border);
    background: var(--shop-panel);
    color: var(--shop-text-2);
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
}
.shop-tab:hover { color: #fff; border-color: var(--shop-orange); }
.shop-tab-active { background: var(--shop-orange); border-color: var(--shop-orange); color: #fff; }

/* ---------- Gateway pills ---------- */
.shop-gw { display: flex; flex-wrap: wrap; gap: 8px; }
.shop-gw label {
    flex: 1;
    min-width: 7rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px 12px;
    border-radius: 10px;
    border: 1px solid var(--shop-border);
    background: var(--shop-panel-2);
    color: var(--shop-text-2);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    text-align: center;
}
.shop-gw label.shop-gw-active {
    border-color: var(--shop-orange);
    background: var(--shop-orange-soft);
    color: #fb923c;
}
.shop-gw input { display: none; }

.shop-help {
    font-size: 13px;
    color: var(--shop-muted);
    white-space: pre-line;
    line-height: 1.55;
}
.shop-alert {
    border-radius: 12px;
    padding: 12px 14px;
    font-size: 14px;
    margin-bottom: 18px;
    border: 1px solid;
}
.shop-alert-success { background: rgba(34, 197, 94, .1); border-color: rgba(34, 197, 94, .35); color: #4ade80; }
.shop-alert-error { background: rgba(239, 68, 68, .1); border-color: rgba(239, 68, 68, .35); color: #f87171; }
.shop-alert-info { background: rgba(59, 130, 246, .1); border-color: rgba(59, 130, 246, .35); color: #60a5fa; }
.shop-alert-amber { background: rgba(245, 158, 11, .1); border-color: rgba(245, 158, 11, .35); color: #fbbf24; }

.shop-empty { text-align: center; padding: 44px 16px; color: var(--shop-muted); }
.shop-empty-title { font-size: 15px; font-weight: 700; color: var(--shop-text-2); }
.shop-code {
    display: block;
    background: var(--shop-bg-soft);
    border: 1px solid var(--shop-border);
    border-radius: 10px;
    padding: 10px 12px;
    font-family: ui-monospace, monospace;
    font-size: 13px;
    color: var(--shop-text);
    word-break: break-all;
}
.shop-kv {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    font-size: 14px;
    padding: 9px 0;
    border-bottom: 1px solid var(--shop-border-soft);
}
.shop-kv:last-child { border-bottom: none; }
.shop-kv span:first-child { color: var(--shop-muted); }
.shop-kv span:last-child { font-weight: 600; text-align: right; }

/* Pagination (overrides the light component inside the shop) */
.shop-pagination nav { border-top-color: var(--shop-border) !important; }
.shop-pagination p { color: var(--shop-muted) !important; }
.shop-pagination a, .shop-pagination span {
    background: var(--shop-panel) !important;
    border-color: var(--shop-border) !important;
    color: var(--shop-text-2) !important;
}
.shop-pagination a:hover { border-color: var(--shop-orange) !important; color: #fff !important; }
.shop-pagination span[aria-current="page"], .shop-pagination .bg-brand-600 {
    background: var(--shop-orange) !important;
    color: #fff !important;
    border-color: var(--shop-orange) !important;
}

/* ---------- Bottom nav (mobile) ---------- */
.shop-bottomnav {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 40;
    background: rgba(15, 22, 40, .98);
    border-top: 1px solid var(--shop-border);
    display: flex;
    padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
}
.shop-bottomnav a, .shop-bottomnav button {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    padding: 6px 2px;
    background: none;
    border: none;
    color: var(--shop-muted);
    font-size: 11px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
}
.shop-bottomnav a.shop-bottomnav-active, .shop-bottomnav button.shop-bottomnav-active { color: var(--shop-orange); }
.shop-bottomnav .shop-bottomnav-icon { font-size: 20px; line-height: 1; }
.shop-bottomnav .shop-bottomnav-add {
    background: linear-gradient(135deg, #f05020, #f08010);
    color: #fff;
    border-radius: 999px;
    width: 46px;
    height: 46px;
    margin-top: -22px;
    font-size: 24px;
    justify-content: center;
    box-shadow: 0 4px 14px rgba(240, 80, 32, .45);
    flex: none;
}

/* Slide-over menu */
.shop-menu-backdrop {
    position: fixed;
    inset: 0;
    z-index: 50;
    background: rgba(0, 0, 0, .6);
}
.shop-menu {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 51;
    background: var(--shop-panel);
    border-top: 1px solid var(--shop-border);
    border-radius: 18px 18px 0 0;
    padding: 10px 16px calc(20px + env(safe-area-inset-bottom));
}
.shop-menu a, .shop-menu button {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 13px 10px;
    background: none;
    border: none;
    border-bottom: 1px solid var(--shop-border-soft);
    color: var(--shop-text);
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    text-align: left;
}
.shop-menu a:last-child, .shop-menu button:last-child { border-bottom: none; }
.shop-menu .shop-menu-danger { color: #f87171; }

@media (min-width: 640px) {
    .shop-grid { grid-template-columns: repeat(3, 1fr); }
    .shop-stats { grid-template-columns: repeat(4, 1fr); }
}
@media (min-width: 768px) {
    .shop-header-nav { display: flex; }
    .shop-balance { display: inline-flex; }
    .shop-bottomnav { display: none; }
    .shop-main { padding-bottom: 40px; }
    .shop-footer { padding-bottom: 40px; }
}
@media (min-width: 1024px) {
    .shop-grid { grid-template-columns: repeat(4, 1fr); }
}
