/* Avasto.online - Global Design System */

:root {
    /* Color Palette - Emerald & Dark Premium */
    --primary: #10b981;    /* Emerald 500 */
    --primary-dark: #059669;
    --primary-light: #d1fae5;
    --secondary: #0f172a;  /* Slate 900 */
    --accent: #f59e0b;     /* Amber 500 */
    --background: #f8fafc; /* Slate 50 */
    --surface: #ffffff;
    --text-main: #1e293b;  /* Slate 800 */
    --text-muted: #64748b; /* Slate 500 */
    
    /* Spacing & Borders */
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.12);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -1px rgba(0,0,0,0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -2px rgba(0,0,0,0.05);
    
    /* Layout */
    --header-height: 70px;
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: var(--background);
    color: var(--text-main);
    line-height: 1.5;
    overflow-x: hidden;
}

/* Typography Overrides (Placeholder until Google Fonts loaded in views) */
h1, h2, h3 { font-weight: 700; letter-spacing: -0.025em; }

/* Layout Components */
.container {
    max-width: 500px; /* Mobile focused container */
    margin: 0 auto;
    padding: 0 20px;
}

.header {
    height: var(--header-height);
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.logo {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--secondary);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
}

.logo span { color: var(--primary); }

/* Search Bar */
.search-container {
    margin: 20px 0;
}

.search-bar {
    width: 100%;
    padding: 14px 20px;
    border-radius: var(--radius-md);
    border: 1px solid #e2e8f0;
    background: white;
    font-size: 1rem;
    outline: none;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-sm);
}

.search-bar:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px var(--primary-light);
}

/* Categories Slider */
.categories-wrapper {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    padding-bottom: 10px;
    margin-bottom: 20px;
    scrollbar-width: none;
}

.categories-wrapper::-webkit-scrollbar { display: none; }

.category-pill {
    padding: 10px 20px;
    background: white;
    border-radius: var(--radius-lg);
    border: 1px solid #e2e8f0;
    white-space: nowrap;
    font-weight: 500;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.category-pill.active {
    background: var(--secondary);
    color: white;
    border-color: var(--secondary);
}

/* Product Cards */
.products-grid {
    display: grid;
    grid-template-columns: 1fr; /* Single column for high impact mobile feed */
    gap: 24px;
    padding-bottom: 40px;
}

.product-card {
    background: var(--surface);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
}

.product-card:active {
    transform: scale(0.98);
}

.product-image {
    width: 100%;
    height: 350px;
    object-fit: cover;
    background-color: #eee;
}

.product-badge {
    position: absolute;
    top: 15px;
    left: 15px;
    background: rgba(15, 23, 42, 0.8);
    color: white;
    padding: 4px 12px;
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    backdrop-filter: blur(4px);
}

.product-details {
    padding: 20px;
}

.product-tienda {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 4px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.product-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--secondary);
}

.product-price {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--primary);
    margin-bottom: 15px;
}

.action-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.btn {
    padding: 12px;
    border-radius: var(--radius-md);
    text-align: center;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

.btn-secondary {
    background: #f1f5f9;
    color: var(--secondary);
}

.btn-primary {
    background: var(--primary);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.btn-primary:hover {
    background: var(--primary-dark);
}

/* Animations */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.product-card {
    animation: fadeInUp 0.5s ease-out forwards;
}
