/* AYMNET 3D Sanal Mağaza & Genel Merkez - Modern Glassmorphic UI Tasarımı */
:root {
    --bg-dark: #090d16;
    --panel-bg: rgba(15, 23, 42, 0.86);
    --panel-border: rgba(56, 189, 248, 0.25);
    --accent-blue: #38bdf8;
    --accent-emerald: #10b981;
    --accent-pink: #ec4899;
    --accent-amber: #f59e0b;
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --sidebar-width: 390px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    user-select: none;
}

body, html {
    width: 100%;
    height: 100%;
    overflow: hidden;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--bg-dark);
    color: var(--text-main);
}

#canvas-container {
    position: fixed;
    top: 0;
    left: 0;
    width: calc(100% - var(--sidebar-width));
    height: 100%;
    z-index: 1;
}

/* ============================================================================
   TOP HUD BAR (LEFT / CENTER OVER 3D VIEWPORT)
   ============================================================================ */
.hud-top-bar {
    position: fixed;
    top: 14px;
    left: 16px;
    right: calc(var(--sidebar-width) + 16px);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    z-index: 10;
    pointer-events: none;
}

.hud-brand-box, .hud-zone-badge, .hud-controls-pill {
    pointer-events: auto;
    background: var(--panel-bg);
    backdrop-filter: blur(14px);
    border: 1px solid var(--panel-border);
    border-radius: 14px;
    padding: 8px 14px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
}

.hud-logo {
    height: 36px;
    width: auto;
    object-fit: contain;
    filter: drop-shadow(0 0 6px rgba(255,255,255,0.3));
}

.hud-brand-text h1 {
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 0.5px;
    color: #ffffff;
}

.hud-brand-text span {
    font-size: 11px;
    color: var(--accent-blue);
    display: block;
}

.hud-zone-badge {
    font-size: 13px;
    font-weight: 700;
    color: #fff;
    border-left: 4px solid var(--accent-blue);
    padding: 10px 18px;
}

.btn-hud-small {
    background: rgba(56, 189, 248, 0.14);
    color: #e2e8f0;
    border: 1px solid rgba(56, 189, 248, 0.35);
    padding: 7px 12px;
    border-radius: 9px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-hud-small:hover {
    background: rgba(56, 189, 248, 0.28);
    transform: translateY(-1px);
}

/* ============================================================================
   QUICK STORE TELEPORT BAR (UNDER TOP HUD)
   ============================================================================ */
.store-quick-nav {
    position: fixed;
    top: 74px;
    left: 16px;
    right: calc(var(--sidebar-width) + 16px);
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    z-index: 10;
    pointer-events: none;
}

.quick-nav-chip {
    pointer-events: auto;
    background: rgba(15, 23, 42, 0.82);
    backdrop-filter: blur(10px);
    color: #f1f5f9;
    border: 1px solid var(--chip-color, rgba(148, 163, 184, 0.35));
    border-left: 3px solid var(--chip-color, #38bdf8);
    padding: 6px 11px;
    border-radius: 9px;
    font-size: 11.5px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.quick-nav-chip:hover {
    background: rgba(30, 41, 59, 0.96);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.35);
}

/* ============================================================================
   ACTIVE STORE SHELF DRAWER (BOTTOM OF 3D VIEWPORT WHEN INSIDE A STORE)
   ============================================================================ */
.active-store-catalog-bar {
    position: fixed;
    bottom: 16px;
    left: 185px;
    right: calc(var(--sidebar-width) + 16px);
    background: rgba(15, 23, 42, 0.92);
    backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 16px;
    padding: 10px 14px;
    z-index: 12;
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.6);
    transition: all 0.3s ease;
}

.active-store-catalog-bar.hidden {
    opacity: 0;
    pointer-events: none;
    transform: translateY(20px);
}

.store-bar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 8px;
    margin-bottom: 8px;
    border-bottom: 2px solid var(--accent-blue);
}

.store-bar-badge {
    padding: 3px 9px;
    border-radius: 6px;
    font-size: 11.5px;
    font-weight: 800;
    color: #fff;
    margin-right: 8px;
}

.store-bar-npc {
    font-size: 12px;
    font-weight: 600;
    color: #fde68a;
    cursor: pointer;
    text-decoration: underline;
}

.store-bar-ext {
    font-size: 11.5px;
    color: var(--accent-blue);
    text-decoration: none;
    font-weight: 600;
}

.mini-shelf-scroll {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding-bottom: 4px;
}

.mini-shelf-scroll::-webkit-scrollbar {
    height: 5px;
}

.mini-shelf-scroll::-webkit-scrollbar-thumb {
    background: rgba(148, 163, 184, 0.4);
    border-radius: 4px;
}

.mini-shelf-item {
    min-width: 195px;
    background: rgba(30, 41, 59, 0.85);
    border: 1px solid rgba(148, 163, 184, 0.22);
    border-radius: 10px;
    padding: 7px 9px;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.mini-shelf-item:hover {
    border-color: var(--accent-blue);
    background: rgba(30, 41, 59, 1);
}

.mini-shelf-item img {
    width: 40px;
    height: 40px;
    object-fit: contain;
    background: #fff;
    border-radius: 7px;
    padding: 2px;
}

.mini-shelf-info {
    flex: 1;
    overflow: hidden;
}

.mini-shelf-title {
    font-size: 11px;
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.mini-shelf-price {
    font-size: 11px;
    color: var(--accent-emerald);
    font-weight: 700;
}

.mini-shelf-add {
    background: var(--accent-emerald);
    color: #fff;
    border: none;
    border-radius: 7px;
    padding: 6px 8px;
    font-size: 11px;
    font-weight: 800;
    cursor: pointer;
}

/* ============================================================================
   ON-SCREEN KEYBOARD / D-PAD CONTROLS & PROXIMITY PROMPT
   ============================================================================ */
.dpad-container {
    position: fixed;
    bottom: 16px;
    left: 16px;
    z-index: 12;
    background: rgba(15, 23, 42, 0.82);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(148, 163, 184, 0.25);
    border-radius: 14px;
    padding: 10px;
    width: 156px;
    text-align: center;
}

.dpad-label {
    font-size: 10px;
    color: var(--text-muted);
    margin-bottom: 6px;
    font-weight: 600;
}

.dpad-grid {
    display: grid;
    grid-template-columns: repeat(3, 38px);
    grid-template-rows: repeat(2, 34px);
    gap: 5px;
    justify-content: center;
}

.dpad-btn {
    background: rgba(30, 41, 59, 0.95);
    border: 1px solid rgba(56, 189, 248, 0.35);
    color: #fff;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.dpad-btn:active {
    background: var(--accent-blue);
    color: #0f172a;
}

.proximity-prompt {
    position: fixed;
    bottom: 145px;
    left: calc((100% - var(--sidebar-width)) / 2);
    transform: translateX(-50%);
    background: rgba(15, 23, 42, 0.94);
    backdrop-filter: blur(14px);
    border: 2px solid var(--accent-emerald);
    border-radius: 16px;
    padding: 12px 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    z-index: 15;
    box-shadow: 0 12px 35px rgba(16, 185, 129, 0.35);
    animation: pulseBorder 2s infinite;
}

.proximity-prompt.hidden {
    display: none;
}

@keyframes pulseBorder {
    0%, 100% { box-shadow: 0 0 18px rgba(16, 185, 129, 0.35); }
    50% { box-shadow: 0 0 28px rgba(56, 189, 248, 0.65); }
}

.proximity-info strong {
    display: block;
    font-size: 14px;
    color: #fff;
}

.proximity-info span {
    font-size: 12px;
    color: #34d399;
}

.btn-proximity-action {
    background: linear-gradient(135deg, #10b981, #059669);
    color: #fff;
    border: none;
    padding: 9px 16px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
    white-space: nowrap;
}

/* ============================================================================
   RIGHT SIDEBAR (MEMBER LOGIN & ID CARD, LIVE CART, QUESTS & STORIES)
   ============================================================================ */
.right-sidebar {
    position: fixed;
    top: 0;
    right: 0;
    width: var(--sidebar-width);
    height: 100%;
    background: rgba(11, 17, 32, 0.96);
    border-left: 1px solid rgba(56, 189, 248, 0.25);
    display: flex;
    flex-direction: column;
    z-index: 20;
    box-shadow: -10px 0 35px rgba(0, 0, 0, 0.6);
}

.sidebar-header {
    padding: 14px 16px;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.9), rgba(15, 23, 42, 0.95));
    border-bottom: 1px solid rgba(148, 163, 184, 0.15);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.header-user-status {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12.5px;
}

.status-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    display: inline-block;
}

.status-dot.online {
    background: #10b981;
    box-shadow: 0 0 8px #10b981;
}

.status-dot.offline {
    background: #ef4444;
}

.pv-pill {
    background: rgba(16, 185, 129, 0.2);
    color: #34d399;
    border: 1px solid rgba(16, 185, 129, 0.4);
    padding: 2px 7px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 800;
}

/* Sidebar Tabs */
.sidebar-tabs {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    background: rgba(15, 23, 42, 0.9);
    border-bottom: 1px solid rgba(148, 163, 184, 0.18);
}

.sidebar-tab-btn {
    background: transparent;
    color: var(--text-muted);
    border: none;
    border-bottom: 3px solid transparent;
    padding: 12px 6px;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    transition: all 0.2s;
}

.sidebar-tab-btn.active {
    color: #fff;
    border-bottom-color: var(--accent-blue);
    background: rgba(56, 189, 248, 0.08);
}

.tab-badge {
    background: var(--accent-pink);
    color: #fff;
    font-size: 10.5px;
    padding: 1px 6px;
    border-radius: 10px;
    font-weight: 800;
}

.cart-bounce {
    animation: cartBounceAnim 0.45s ease;
}

@keyframes cartBounceAnim {
    0%, 100% { transform: scale(1); }
    40% { transform: scale(1.22); background: rgba(16, 185, 129, 0.25); }
}

.sidebar-tab-content {
    display: none;
    flex: 1;
    overflow-y: auto;
    padding: 16px;
}

.sidebar-tab-content.active {
    display: block;
}

/* ============================================================================
   MEMBER PANEL & AYMNET DIGITAL ID CARD
   ============================================================================ */
.login-alert-box {
    background: rgba(239, 68, 68, 0.12);
    border: 1px solid rgba(239, 68, 68, 0.35);
    border-radius: 12px;
    padding: 12px;
    display: flex;
    gap: 10px;
    margin-bottom: 14px;
}

.login-alert-icon {
    font-size: 22px;
}

.login-alert-box strong {
    font-size: 13px;
    color: #fecaca;
    display: block;
    margin-bottom: 4px;
}

.login-alert-box p {
    font-size: 11.5px;
    color: #cbd5e1;
    line-height: 1.4;
}

.section-label {
    font-size: 11.5px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--accent-blue);
    margin-bottom: 8px;
}

.demo-accounts-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.demo-account-card {
    background: rgba(30, 41, 59, 0.75);
    border: 1px solid rgba(148, 163, 184, 0.22);
    border-radius: 11px;
    padding: 10px 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    transition: all 0.2s;
}

.demo-account-card:hover {
    border-color: var(--accent-blue);
    background: rgba(30, 41, 59, 1);
    transform: translateX(3px);
}

.demo-avatar-circle {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 16px;
    color: #fff;
}

.demo-account-info {
    flex: 1;
}

.demo-account-name {
    font-size: 13px;
    font-weight: 700;
}

.demo-account-rank {
    font-size: 11.5px;
    font-weight: 600;
}

.demo-account-meta {
    font-size: 11px;
    color: var(--text-muted);
}

.btn-demo-select {
    background: var(--accent-blue);
    color: #0f172a;
    border: none;
    padding: 6px 10px;
    border-radius: 7px;
    font-size: 11.5px;
    font-weight: 800;
    cursor: pointer;
}

.custom-login-form {
    display: flex;
    flex-direction: column;
    gap: 8px;
    background: rgba(30, 41, 59, 0.5);
    padding: 12px;
    border-radius: 12px;
    border: 1px solid rgba(148, 163, 184, 0.18);
}

.custom-login-form input, .custom-login-form select {
    background: #0f172a;
    border: 1px solid rgba(148, 163, 184, 0.35);
    color: #fff;
    padding: 9px 11px;
    border-radius: 8px;
    font-size: 12.5px;
}

/* Digital ID Card */
.aym-id-card {
    background: linear-gradient(135deg, #0f172a 0%, #1e1b4b 60%, #064e3b 100%);
    border: 2px solid rgba(56, 189, 248, 0.5);
    border-radius: 16px;
    padding: 14px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5);
    margin-bottom: 14px;
}

.aym-id-card.verified {
    border-color: #10b981;
    box-shadow: 0 8px 25px rgba(16, 185, 129, 0.25);
}

.id-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid rgba(255,255,255,0.12);
    padding-bottom: 8px;
    margin-bottom: 12px;
}

.id-card-logo {
    height: 26px;
}

.id-card-company {
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.6px;
    color: #fff;
}

.id-card-Clearance {
    font-size: 9.5px;
    color: var(--accent-blue);
    font-weight: 700;
}

.id-card-status-chip {
    font-size: 10px;
    font-weight: 800;
    padding: 3px 7px;
    border-radius: 8px;
}

.chip-ok {
    background: rgba(16, 185, 129, 0.25);
    color: #6ee7b7;
    border: 1px solid #10b981;
}

.chip-wait {
    background: rgba(245, 158, 11, 0.25);
    color: #fde68a;
    border: 1px solid #f59e0b;
}

.id-card-body {
    display: flex;
    align-items: center;
    gap: 12px;
}

.id-photo-box {
    width: 56px;
    height: 64px;
    border-radius: 10px;
    border: 2px solid #10b981;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
}

.id-details {
    flex: 1;
}

.id-name {
    font-size: 15px;
    font-weight: 800;
    color: #fff;
}

.id-rank {
    font-size: 12px;
    font-weight: 700;
    margin-bottom: 4px;
}

.id-number {
    font-size: 11px;
    color: #cbd5e1;
}

.id-qr-box {
    width: 48px;
    height: 54px;
    background: #fff;
    border-radius: 7px;
    padding: 4px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.qr-pattern {
    width: 34px;
    height: 34px;
    background-image: radial-gradient(#0f172a 45%, transparent 46%), radial-gradient(#0f172a 45%, transparent 46%);
    background-size: 8px 8px;
    background-position: 0 0, 4px 4px;
}

.id-qr-box span {
    font-size: 8px;
    color: #0f172a;
    font-weight: 800;
}

.id-card-footer {
    margin-top: 12px;
}

.btn-scan-id {
    width: 100%;
    background: linear-gradient(135deg, #38bdf8, #2563eb);
    color: #fff;
    border: none;
    padding: 9px;
    border-radius: 9px;
    font-size: 12px;
    font-weight: 800;
    cursor: pointer;
}

.member-stats-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 12px;
}

.stat-box {
    background: rgba(30, 41, 59, 0.7);
    border: 1px solid rgba(148, 163, 184, 0.2);
    border-radius: 10px;
    padding: 10px;
}

.stat-label {
    font-size: 11px;
    color: var(--text-muted);
    display: block;
}

.stat-val {
    font-size: 14px;
    font-weight: 800;
    color: #fff;
}

.btn-logout {
    width: 100%;
    background: rgba(239, 68, 68, 0.15);
    color: #fca5a5;
    border: 1px solid rgba(239, 68, 68, 0.3);
    padding: 8px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
}

/* ============================================================================
   SHOPPING CART PANEL
   ============================================================================ */
.empty-cart-box {
    text-align: center;
    padding: 36px 16px;
    color: var(--text-muted);
}

.empty-cart-icon {
    font-size: 46px;
    margin-bottom: 10px;
}

.empty-cart-box h4 {
    color: #fff;
    margin-bottom: 6px;
}

.empty-cart-box p {
    font-size: 12.5px;
    line-height: 1.5;
}

.cart-items-list {
    display: flex;
    flex-direction: column;
    gap: 9px;
    max-height: 290px;
    overflow-y: auto;
    margin-bottom: 12px;
}

.cart-item-row {
    background: rgba(30, 41, 59, 0.78);
    border: 1px solid rgba(148, 163, 184, 0.2);
    border-radius: 10px;
    padding: 8px 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.cart-item-row img {
    width: 44px;
    height: 44px;
    object-fit: contain;
    background: #fff;
    border-radius: 8px;
    padding: 2px;
}

.cart-item-info {
    flex: 1;
    overflow: hidden;
}

.cart-item-title {
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.cart-item-meta {
    font-size: 11px;
    color: var(--accent-blue);
    margin-top: 2px;
}

.cart-qty-controls {
    display: flex;
    align-items: center;
    gap: 6px;
}

.cart-qty-controls button {
    width: 24px;
    height: 24px;
    border-radius: 6px;
    border: 1px solid rgba(148, 163, 184, 0.35);
    background: #0f172a;
    color: #fff;
    font-weight: 800;
    cursor: pointer;
}

.coupon-row {
    display: flex;
    gap: 6px;
    margin-bottom: 12px;
}

.coupon-row input {
    flex: 1;
    background: #0f172a;
    border: 1px solid rgba(148, 163, 184, 0.3);
    color: #fff;
    padding: 8px 10px;
    border-radius: 8px;
    font-size: 12px;
}

.coupon-row button {
    background: var(--accent-blue);
    color: #0f172a;
    border: none;
    padding: 8px 12px;
    border-radius: 8px;
    font-weight: 800;
    font-size: 12px;
    cursor: pointer;
}

.cart-summary-box {
    background: rgba(15, 23, 42, 0.9);
    border: 1px solid rgba(148, 163, 184, 0.22);
    border-radius: 12px;
    padding: 12px;
    margin-bottom: 12px;
}

.summary-line {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    margin-bottom: 6px;
    color: #cbd5e1;
}

.summary-line.discount {
    color: #34d399;
}

.summary-line.pv-line {
    color: #fbbf24;
    font-weight: 700;
}

.summary-line.total {
    border-top: 1px solid rgba(148, 163, 184, 0.2);
    padding-top: 8px;
    margin-top: 6px;
    font-size: 14.5px;
    font-weight: 800;
    color: #fff;
}

.btn-checkout-glow, .btn-primary-glow {
    width: 100%;
    background: linear-gradient(135deg, #10b981, #059669);
    color: #fff;
    border: none;
    padding: 11px 16px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.35);
    transition: all 0.2s;
}

.btn-checkout-glow:hover, .btn-primary-glow:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 25px rgba(16, 185, 129, 0.5);
}

/* ============================================================================
   QUESTS & STORY LOG PANEL
   ============================================================================ */
.quest-progress-bar-wrap {
    background: rgba(30, 41, 59, 0.7);
    border-radius: 10px;
    padding: 10px 12px;
    margin-bottom: 12px;
}

.quest-progress-label {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    margin-bottom: 6px;
}

.quest-progress-track {
    height: 8px;
    background: #0f172a;
    border-radius: 6px;
    overflow: hidden;
}

.quest-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #38bdf8, #10b981);
    transition: width 0.4s ease;
}

.quests-list {
    display: flex;
    flex-direction: column;
    gap: 9px;
}

.quest-card {
    background: rgba(30, 41, 59, 0.65);
    border: 1px solid rgba(148, 163, 184, 0.22);
    border-radius: 11px;
    padding: 10px 12px;
    display: flex;
    gap: 10px;
}

.quest-card.completed {
    border-color: #10b981;
    background: rgba(6, 78, 59, 0.3);
}

.quest-status-icon {
    font-size: 11px;
    font-weight: 800;
    background: rgba(56, 189, 248, 0.15);
    color: var(--accent-blue);
    padding: 4px 7px;
    border-radius: 7px;
    height: fit-content;
    white-space: nowrap;
}

.quest-title {
    font-size: 12.5px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 3px;
}

.quest-desc {
    font-size: 11.5px;
    color: #cbd5e1;
    line-height: 1.4;
    margin-bottom: 5px;
}

.quest-reward {
    font-size: 11px;
    color: #fbbf24;
    font-weight: 700;
}

/* ============================================================================
   MODALS (SECURITY SCANNER, NPC STORY, PRODUCT INSPECTION)
   ============================================================================ */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: calc(100% - var(--sidebar-width));
    height: 100%;
    background: rgba(9, 13, 22, 0.72);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 30;
    padding: 20px;
}

.modal-overlay.hidden {
    display: none;
}

.modal-card {
    background: #0f172a;
    border: 1px solid rgba(56, 189, 248, 0.4);
    border-radius: 18px;
    width: 100%;
    max-width: 620px;
    padding: 22px;
    position: relative;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.75);
}

.modal-close-btn {
    position: absolute;
    top: 14px;
    right: 16px;
    background: rgba(148, 163, 184, 0.15);
    color: #fff;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    font-size: 16px;
    cursor: pointer;
}

.npc-dialog-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
}

.npc-avatar-badge {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    background: #1e293b;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    border: 2px solid var(--accent-blue);
}

.npc-role-tag {
    font-size: 12px;
    color: var(--accent-blue);
    font-weight: 600;
}

.npc-speech-text {
    background: rgba(30, 41, 59, 0.85);
    border-left: 4px solid var(--accent-blue);
    padding: 13px 15px;
    border-radius: 10px;
    font-size: 13.5px;
    line-height: 1.55;
    color: #f1f5f9;
    margin-bottom: 14px;
}

.npc-speech-text.error-border {
    border-left-color: #ef4444;
}

.npc-speech-text.success-border {
    border-left-color: #10b981;
}

.security-demo-buttons {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 10px;
}

.btn-sec-demo {
    background: rgba(30, 41, 59, 0.9);
    border: 1px solid rgba(56, 189, 248, 0.4);
    color: #fff;
    padding: 10px 14px;
    border-radius: 10px;
    text-align: left;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-sec-demo:hover {
    background: rgba(56, 189, 248, 0.2);
    border-color: #38bdf8;
}

/* ID Scanner Animation Box */
.scanner-simulation-box {
    background: #090d16;
    border: 2px dashed #38bdf8;
    border-radius: 12px;
    padding: 18px;
    text-align: center;
    position: relative;
    overflow: hidden;
    margin-bottom: 14px;
}

.scanner-laser-line {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: #10b981;
    box-shadow: 0 0 15px #10b981;
    opacity: 0;
}

.scanner-simulation-box.scanning .scanner-laser-line {
    opacity: 1;
    animation: laserSweep 0.9s infinite alternate;
}

@keyframes laserSweep {
    0% { top: 5%; }
    100% { top: 92%; }
}

.scanner-card-preview strong {
    display: block;
    font-size: 15px;
    color: #fff;
}

.scanner-card-preview span {
    font-size: 12px;
    color: #34d399;
}

/* Story & NPC Featured Product */
.story-chapter-badge {
    display: inline-block;
    background: rgba(147, 51, 234, 0.25);
    border: 1px solid #a855f7;
    color: #e9d5ff;
    padding: 4px 10px;
    border-radius: 8px;
    font-size: 11.5px;
    font-weight: 700;
    margin-bottom: 10px;
}

.npc-dialog-paragraphs p {
    font-size: 13px;
    color: #e2e8f0;
    line-height: 1.5;
    margin-bottom: 8px;
    background: rgba(30, 41, 59, 0.6);
    padding: 9px 12px;
    border-radius: 8px;
}

.story-store-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-top: 12px;
}

.story-store-btn {
    background: rgba(30, 41, 59, 0.85);
    border: 1px solid;
    border-radius: 10px;
    padding: 8px 10px;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    text-align: left;
}

.story-store-btn strong {
    display: block;
    font-size: 11.5px;
}

.story-store-btn small {
    font-size: 10.5px;
    color: var(--text-muted);
}

.npc-tip-box {
    background: rgba(245, 158, 11, 0.14);
    border: 1px solid rgba(245, 158, 11, 0.4);
    color: #fde68a;
    padding: 9px 12px;
    border-radius: 9px;
    font-size: 12px;
    margin-bottom: 12px;
}

.npc-featured-product {
    background: rgba(30, 41, 59, 0.8);
    border: 1px solid rgba(148, 163, 184, 0.25);
    border-radius: 12px;
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.npc-featured-product img {
    width: 80px;
    height: 80px;
    object-fit: contain;
    background: #fff;
    border-radius: 10px;
    padding: 4px;
}

/* Product Modal Layout */
.product-modal-layout {
    display: grid;
    grid-template-columns: 210px 1fr;
    gap: 18px;
    align-items: center;
}

.product-modal-img-box {
    background: #fff;
    border-radius: 14px;
    padding: 14px;
    text-align: center;
    position: relative;
    border: 3px solid var(--accent-blue);
}

.product-modal-img-box img {
    width: 100%;
    height: 170px;
    object-fit: contain;
}

.product-code-chip {
    position: absolute;
    top: 8px;
    left: 8px;
    background: #0f172a;
    color: #fff;
    font-size: 10.5px;
    font-weight: 800;
    padding: 3px 7px;
    border-radius: 6px;
}

.product-pv-chip {
    display: inline-block;
    margin-top: 6px;
    background: #064e3b;
    color: #6ee7b7;
    font-size: 11px;
    font-weight: 800;
    padding: 3px 9px;
    border-radius: 10px;
}

.product-store-tag {
    font-size: 11.5px;
    font-weight: 800;
    margin-bottom: 4px;
}

.product-modal-details h2 {
    font-size: 18px;
    margin-bottom: 8px;
}

.product-desc {
    font-size: 12.5px;
    color: #cbd5e1;
    line-height: 1.5;
    margin-bottom: 12px;
}

.product-price-box {
    background: rgba(30, 41, 59, 0.8);
    border-radius: 10px;
    padding: 10px 12px;
    margin-bottom: 14px;
}

.price-label {
    font-size: 11.5px;
    color: var(--text-muted);
}

.price-main {
    font-size: 16px;
    font-weight: 800;
    color: #fff;
    margin-left: 6px;
}

.price-main.line-through {
    text-decoration: line-through;
    color: #94a3b8;
    font-size: 13.5px;
}

.price-discounted {
    font-size: 18px;
    font-weight: 900;
    color: #34d399;
    margin-left: 6px;
}

.member-hint {
    font-size: 11px;
    color: #fbbf24;
    margin-top: 4px;
}

.product-modal-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.btn-add-cart-3d {
    border: none;
    color: #fff;
    padding: 11px 16px;
    border-radius: 10px;
    font-size: 13.5px;
    font-weight: 800;
    cursor: pointer;
}

.btn-real-site {
    text-align: center;
    background: rgba(56, 189, 248, 0.14);
    color: var(--accent-blue);
    border: 1px solid rgba(56, 189, 248, 0.35);
    padding: 8px;
    border-radius: 9px;
    font-size: 12px;
    font-weight: 700;
    text-decoration: none;
}

.order-receipt-box {
    background: rgba(30, 41, 59, 0.85);
    border: 1px solid rgba(16, 185, 129, 0.4);
    border-radius: 12px;
    padding: 12px 16px;
    text-align: left;
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 13px;
}

.order-receipt-box div {
    display: flex;
    justify-content: space-between;
}

/* ============================================================================
   FLY-TO-CART DOM ELEMENT & TOAST NOTIFICATIONS
   ============================================================================ */
.dom-fly-item {
    position: fixed;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: #fff;
    border: 3px solid #10b981;
    box-shadow: 0 0 25px rgba(16, 185, 129, 0.8);
    z-index: 9999;
    pointer-events: none;
    transition: transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.6s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.dom-fly-item img {
    width: 85%;
    height: 85%;
    object-fit: contain;
}

.toast-container {
    position: fixed;
    bottom: 20px;
    right: calc(var(--sidebar-width) + 20px);
    display: flex;
    flex-direction: column;
    gap: 8px;
    z-index: 50;
    max-width: 380px;
    pointer-events: none;
}

.toast-msg {
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(12px);
    border-left: 4px solid var(--accent-blue);
    color: #fff;
    padding: 11px 15px;
    border-radius: 10px;
    font-size: 12.5px;
    line-height: 1.45;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
    transition: all 0.35s ease;
}

.toast-success { border-left-color: #10b981; }
.toast-error { border-left-color: #ef4444; }
.toast-quest { border-left-color: #f59e0b; background: rgba(30, 27, 75, 0.96); }
.toast-msg.fade-out { opacity: 0; transform: translateX(30px); }

.unpaid-warning-banner {
    background: rgba(245, 158, 11, 0.16);
    border: 1px solid rgba(245, 158, 11, 0.45);
    color: #fde68a;
    padding: 9px 11px;
    border-radius: 10px;
    font-size: 11.5px;
    line-height: 1.4;
    margin-bottom: 10px;
}

.police-siren-banner {
    background: linear-gradient(90deg, #dc2626, #1d4ed8, #dc2626);
    background-size: 200% 100%;
    color: #ffffff;
    font-weight: 900;
    font-size: 13px;
    text-align: center;
    padding: 10px;
    border-radius: 10px;
    margin-bottom: 14px;
    letter-spacing: 0.6px;
    animation: policeStrobe 0.65s infinite alternate;
    box-shadow: 0 0 22px rgba(239, 68, 68, 0.6);
}

@keyframes policeStrobe {
    0% { background-position: 0% 50%; box-shadow: 0 0 22px rgba(239, 68, 68, 0.75); }
    100% { background-position: 100% 50%; box-shadow: 0 0 22px rgba(59, 130, 246, 0.75); }
}

