/* Custom Marketplace Styles */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@400;500;600;700&display=swap');

:root {
    --primary: #002f34;
    /* OLX Dark Teal */
    --accent: #23e5db;
    /* OLX Vibrant Cyan */
    --surface: #ffffff;
    --background: #f2f4f5;
    --text-main: #002f34;
    --text-muted: #5f738c;
    --category-bg: #e9f1f2;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--background);
    color: var(--text-main);
    overflow-x: hidden;
}

h1,
h2,
h3,
h4,
.font-display {
    font-family: 'Outfit', sans-serif;
}

/* Glassmorphism */
.glass {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

/* Card Hover Animation */
.ad-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.ad-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px -10px rgba(0, 47, 52, 0.15);
}

/* Skeleton Loading Animation */
.skeleton {
    background: linear-gradient(90deg, #e5e7eb 25%, #f3f4f6 50%, #e5e7eb 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s infinite linear;
}

@keyframes skeleton-loading {
    0% {
        background-position: 200% 0;
    }

    100% {
        background-position: -200% 0;
    }
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}

/* Mobile Bottom Nav Shadow */
.mobile-nav-shadow {
    box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.05);
}

/* Ripple Effect */
.ripple {
    position: relative;
    overflow: hidden;
}

.ripple:after {
    content: "";
    display: block;
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    pointer-events: none;
    background-image: radial-gradient(circle, #fff 10%, transparent 10.01%);
    background-repeat: no-repeat;
    background-position: 50%;
    transform: scale(10, 10);
    opacity: 0;
    transition: transform .5s, opacity 1s;
}

.ripple:active:after {
    transform: scale(0, 0);
    opacity: .3;
    transition: 0s;
}

/* Category Horizontal Scroll Hide Scrollbar */
.no-scrollbar::-webkit-scrollbar {
    display: none;
}

.no-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

/* Global Responsive & Zoom Fixes */
html,
body {
    max-width: 100%;
    overflow-x: hidden;
    position: relative;
    scroll-behavior: smooth;
}

img {
    max-width: 100%;
    height: auto;
}

/* Fix for long usernames in navbar truncation */
.nav-user-name {
    display: inline-block;
    max-width: 120px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    vertical-align: middle;
}

@media (max-width: 640px) {
    .nav-user-name {
        max-width: 80px;
    }
}