/* =====================================================
   WEGLOBALCONNECT - CORE STYLES
   ===================================================== */

:root {
    --wg-green: #2E7D32;
    --wg-slate: #263238;
    --wg-orange: #FF9800;
    --wg-light-bg: #f8f9fa;
    --wg-border: #eeeeee;
    --wg-text-dark: #333333;
    --wg-text-muted: #757575;
    --safe-area-bottom: env(safe-area-inset-bottom);
}

* {
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    background-color: var(--wg-light-bg);
    color: var(--wg-text-dark);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    margin: 0;
    padding-top: 60px; /* Space for Fixed Header */
    padding-bottom: 75px; /* Space for Fixed Footer */
    line-height: 1.5;
}

/* =====================================================
   NATIVE APP BAR (HEADER)
   ===================================================== */
.app-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 60px;
    background: var(--wg-slate) !important;
    z-index: 1000;
    display: flex;
    align-items: center;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.app-header .brand-logo {
    font-weight: 800 !important;
    font-size: 1.2rem !important;
    letter-spacing: -0.5px;
    margin-left: 15px;
}

/* =====================================================
   BOTTOM NAVIGATION (FOOTER)
   ===================================================== */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 65px;
    background: #ffffff;
    display: flex;
    justify-content: space-around;
    align-items: center;
    border-top: 1px solid var(--wg-border);
    z-index: 1001;
    padding-bottom: var(--safe-area-bottom);
}

.bottom-nav a {
    color: #9e9e9e;
    text-align: center;
    flex: 1;
    text-decoration: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: 0.2s;
    font-size: 10px;
    font-weight: 700;
}

.bottom-nav a.active { color: var(--wg-green); }
.bottom-nav i { font-size: 24px; margin-bottom: 2px; }

/* Floating Center Action Button (FAB) */
.center-fab-wrapper { margin-top: -30px; }
.center-fab {
    background: var(--wg-green);
    color: white;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 4px solid #ffffff;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

/* =====================================================
   MARKETPLACE COMPONENTS
   ===================================================== */

/* Horizontal Category Scroller */
.cat-container { background: #fff; padding: 15px 0; border-bottom: 1px solid var(--wg-border); }
.cat-scroll { display: flex; overflow-x: auto; gap: 15px; padding: 0 15px; scrollbar-width: none; }
.cat-scroll::-webkit-scrollbar { display: none; }

.cat-item { min-width: 65px; text-align: center; text-decoration: none; color: #333; }
.cat-icon {
    width: 55px; height: 55px; background: #f1f3f4; border-radius: 16px; /* Squircle */
    display: flex; align-items: center; justify-content: center; margin: 0 auto 8px;
    color: var(--wg-green);
}
.cat-item span { font-size: 11px; font-weight: 600; }

/* Product Grid Cards */
.market-card { border-radius: 16px !important; overflow: hidden; border: none !important; margin-bottom: 15px !important; }
.market-card img { height: 130px; width: 100%; object-fit: cover; background-repeat: no-repeat; background-size: cover; }
.market-card .card-content { padding: 12px !important; }
.price { color: var(--wg-green); font-weight: 800; font-size: 1rem; }

/* =====================================================
   DASHBOARD & CLIENT AREA
   ===================================================== */
.card-stat { border-radius: 16px !important; border: none !important; transition: 0.3s; }
.action-btn {
    border-radius: 16px; padding: 15px; text-align: center; background: white;
    border: 1px solid var(--wg-border); text-decoration: none; color: var(--wg-slate);
    display: block; box-shadow: 0 2px 5px rgba(0,0,0,0.02);
}
.action-btn i { font-size: 2rem; color: var(--wg-green); display: block; margin-bottom: 5px; }

/* =====================================================
   MESSAGING & CHAT SYSTEM
   ===================================================== */
.chat-container { display: flex; flex-direction: column; height: calc(100vh - 120px); background: #e5ddd5; overflow-y: auto; padding: 15px; }

.bubble {
    max-width: 80%; padding: 10px 15px; border-radius: 15px; margin-bottom: 10px;
    font-size: 0.95rem; position: relative; box-shadow: 0 1px 2px rgba(0,0,0,0.1);
}
.sent { align-self: flex-end; background: #dcf8c6; border-bottom-right-radius: 2px; }
.received { align-self: flex-start; background: #ffffff; border-bottom-left-radius: 2px; }

.chat-input-bar {
    position: fixed; bottom: 0; left: 0; width: 100%; background: #f0f0f0;
    padding: 10px; display: flex; align-items: center; border-top: 1px solid #ddd;
}

/* =====================================================
   UTILITIES
   ===================================================== */
.shadow-sm { box-shadow: 0 2px 8px rgba(0,0,0,0.05) !important; }
.rounded-20 { border-radius: 20px !important; }

.status-badge {
    font-size: 0.7rem; padding: 3px 10px; border-radius: 10px;
    text-transform: uppercase; font-weight: bold;
}
.bg-wg { background-color: var(--wg-green) !important; color: white; }

.nav-badge {
    position: absolute; top: -2px; right: 20%; background: #f44336;
    color: white; font-size: 9px; padding: 2px 5px; border-radius: 10px;
    min-width: 16px; border: 2px solid #fff;
}

/* Fix for repeating backgrounds mentioned earlier */
.slider .slides li img {
    background-repeat: no-repeat !important;
    background-size: cover !important;
    background-position: center center !important;
}

/* =====================================================
   NATIVE FEEL INTERACTION
   ===================================================== */
button:active, .cat-item:active, .bottom-nav a:active {
    transform: scale(0.96);
    opacity: 0.8;
}