/* ============================================================
   PRICILIO v2 — Design System
   Premium dark-mode glassmorphism UI
   ============================================================ */

/* --- Reset & Base --- */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Colors */
    --bg-primary: #06080f;
    --bg-secondary: #0c1021;
    --bg-tertiary: #111630;
    --bg-card: rgba(17, 22, 48, 0.65);
    --bg-card-hover: rgba(24, 30, 60, 0.8);
    --bg-glass: rgba(255, 255, 255, 0.04);
    --bg-glass-strong: rgba(255, 255, 255, 0.08);

    --text-primary: #f1f5f9;
    --text-secondary: rgba(226, 232, 240, 0.72);
    --text-muted: rgba(148, 163, 184, 0.65);
    --text-inverse: #0f172a;

    --accent: #f97316;
    --accent-hover: #fb923c;
    --accent-glow: rgba(249, 115, 22, 0.25);
    --accent-subtle: rgba(249, 115, 22, 0.12);

    --green: #22c55e;
    --green-subtle: rgba(34, 197, 94, 0.12);
    --red: #ef4444;
    --red-subtle: rgba(239, 68, 68, 0.12);
    --blue: #3b82f6;
    --purple: #a855f7;

    --border: rgba(255, 255, 255, 0.06);
    --border-hover: rgba(255, 255, 255, 0.12);
    --border-accent: rgba(249, 115, 22, 0.25);

    /* Shadows */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.15);
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.25);
    --shadow-lg: 0 16px 48px rgba(0, 0, 0, 0.35);
    --shadow-glow: 0 0 40px rgba(249, 115, 22, 0.15);

    /* Typography */
    --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --fs-xs: 0.72rem;
    --fs-sm: 0.82rem;
    --fs-base: 0.92rem;
    --fs-md: 1rem;
    --fs-lg: 1.15rem;
    --fs-xl: 1.35rem;
    --fs-2xl: 1.8rem;
    --fs-3xl: 2.4rem;
    --fs-hero: clamp(2.2rem, 5vw, 3.5rem);

    /* Spacing */
    --space-xs: 4px;
    --space-sm: 8px;
    --space-md: 16px;
    --space-lg: 24px;
    --space-xl: 40px;
    --space-2xl: 64px;

    /* Radii */
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --radius-xl: 28px;
    --radius-full: 999px;

    /* Transitions */
    --ease: cubic-bezier(0.22, 1, 0.36, 1);
    --transition-fast: 0.15s var(--ease);
    --transition-base: 0.25s var(--ease);
    --transition-slow: 0.4s var(--ease);

    /* Layout */
    --max-width: 1280px;
    --navbar-height: 64px;
}

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font);
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Background gradient mesh */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    background:
        radial-gradient(ellipse 80% 60% at 20% 10%, rgba(249, 115, 22, 0.06) 0%, transparent 60%),
        radial-gradient(ellipse 60% 50% at 80% 30%, rgba(59, 130, 246, 0.04) 0%, transparent 55%),
        radial-gradient(ellipse 70% 40% at 50% 90%, rgba(168, 85, 247, 0.03) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

#app {
    position: relative;
    z-index: 1;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
    height: auto;
}

button {
    cursor: pointer;
    font-family: var(--font);
    border: none;
    background: none;
    color: inherit;
}

input, select {
    font-family: var(--font);
    color: var(--text-primary);
}

/* --- Utility --- */
.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 var(--space-lg);
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* --- Glass Card --- */
.glass {
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
}

.glass:hover {
    border-color: var(--border-hover);
    background: var(--bg-card-hover);
}

.glass-strong {
    background: var(--bg-glass-strong);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid var(--border-hover);
    border-radius: var(--radius-lg);
}

/* --- Navbar --- */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--navbar-height);
    z-index: 1000;
    background: rgba(6, 8, 15, 0.82);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
}

.navbar .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
}

.navbar-brand {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    font-size: var(--fs-lg);
    font-weight: 800;
    letter-spacing: -0.02em;
    cursor: pointer;
}

.navbar-brand-icon {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-sm);
    background: linear-gradient(135deg, var(--accent), #f59e0b);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    box-shadow: 0 4px 16px var(--accent-glow);
}

.navbar-nav {
    display: flex;
    align-items: center;
    gap: var(--space-xs);
    list-style: none;
}

.navbar-link {
    padding: 8px 14px;
    font-size: var(--fs-sm);
    font-weight: 600;
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    transition: color var(--transition-fast), background var(--transition-fast);
}

.navbar-link:hover,
.navbar-link.active {
    color: var(--text-primary);
    background: var(--bg-glass-strong);
}

.navbar-search {
    position: relative;
    width: 280px;
}

.navbar-search-input {
    width: 100%;
    padding: 9px 14px 9px 36px;
    background: var(--bg-glass);
    border: 1px solid var(--border);
    border-radius: var(--radius-full);
    font-size: var(--fs-sm);
    outline: none;
    transition: border-color var(--transition-fast), background var(--transition-fast);
}

.navbar-search-input:focus {
    border-color: var(--border-accent);
    background: var(--bg-glass-strong);
}

.navbar-search-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 14px;
    pointer-events: none;
}

/* Mobile nav toggle */
.navbar-toggle {
    display: none;
    width: 36px;
    height: 36px;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: var(--text-secondary);
}

/* --- Page Content --- */
.page {
    padding-top: calc(var(--navbar-height) + var(--space-lg));
    min-height: 100vh;
}

.page-header {
    margin-bottom: var(--space-xl);
}

.page-title {
    font-size: var(--fs-2xl);
    font-weight: 800;
    letter-spacing: -0.03em;
    margin-bottom: var(--space-sm);
}

.page-subtitle {
    color: var(--text-secondary);
    font-size: var(--fs-base);
}

/* --- Hero --- */
.hero {
    padding: var(--space-2xl) 0;
    text-align: center;
    position: relative;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 16px;
    border-radius: var(--radius-full);
    background: var(--accent-subtle);
    color: var(--accent);
    font-size: var(--fs-xs);
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    margin-bottom: var(--space-md);
    animation: fadeInUp 0.6s var(--ease) both;
}

.hero-title {
    font-size: var(--fs-hero);
    font-weight: 900;
    letter-spacing: -0.04em;
    line-height: 1.1;
    margin-bottom: var(--space-md);
    animation: fadeInUp 0.6s var(--ease) 0.1s both;
}

.hero-title .accent {
    background: linear-gradient(135deg, var(--accent), #fbbf24);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-desc {
    color: var(--text-secondary);
    font-size: var(--fs-lg);
    max-width: 560px;
    margin: 0 auto var(--space-xl);
    animation: fadeInUp 0.6s var(--ease) 0.2s both;
}

/* --- Hero Search --- */
.hero-search {
    max-width: 600px;
    margin: 0 auto;
    position: relative;
    animation: fadeInUp 0.6s var(--ease) 0.3s both;
}

.hero-search-input {
    width: 100%;
    padding: 18px 60px 18px 24px;
    font-size: var(--fs-md);
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-hover);
    border-radius: var(--radius-xl);
    outline: none;
    transition: border-color var(--transition-base), box-shadow var(--transition-base);
}

.hero-search-input:focus {
    border-color: var(--accent);
    box-shadow: var(--shadow-glow);
}

.hero-search-input::placeholder {
    color: var(--text-muted);
}

.hero-search-btn {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    width: 44px;
    height: 44px;
    border-radius: var(--radius-md);
    background: linear-gradient(135deg, var(--accent), #f59e0b);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    transition: transform var(--transition-fast), box-shadow var(--transition-fast);
    box-shadow: 0 4px 16px var(--accent-glow);
}

.hero-search-btn:hover {
    transform: translateY(-50%) scale(1.05);
    box-shadow: 0 6px 24px var(--accent-glow);
}

/* --- Stats Bar --- */
.stats-bar {
    display: flex;
    justify-content: center;
    gap: var(--space-xl);
    padding: var(--space-lg) 0;
    margin: var(--space-lg) 0;
    animation: fadeInUp 0.6s var(--ease) 0.4s both;
}

.stat-item {
    text-align: center;
}

.stat-value {
    font-size: var(--fs-2xl);
    font-weight: 900;
    letter-spacing: -0.03em;
    background: linear-gradient(135deg, var(--text-primary), var(--text-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-label {
    font-size: var(--fs-xs);
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 700;
    margin-top: 2px;
}

/* --- Section --- */
.section {
    padding: var(--space-xl) 0;
}

.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--space-lg);
}

.section-title {
    font-size: var(--fs-xl);
    font-weight: 800;
    letter-spacing: -0.02em;
}

.section-link {
    font-size: var(--fs-sm);
    font-weight: 600;
    color: var(--accent);
    transition: color var(--transition-fast);
}

.section-link:hover {
    color: var(--accent-hover);
}

/* --- Category Tiles --- */
.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: var(--space-md);
}

.category-tile {
    padding: var(--space-md);
    border-radius: var(--radius-md);
    background: var(--bg-card);
    border: 1px solid var(--border);
    text-align: center;
    cursor: pointer;
    transition: transform var(--transition-fast), border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.category-tile:hover {
    transform: translateY(-3px);
    border-color: var(--border-accent);
    box-shadow: var(--shadow-md);
}

.category-tile-icon {
    font-size: 28px;
    margin-bottom: var(--space-sm);
}

.category-tile-name {
    font-size: var(--fs-sm);
    font-weight: 700;
    margin-bottom: 2px;
}

.category-tile-count {
    font-size: var(--fs-xs);
    color: var(--text-muted);
}

/* --- Deal Card (Horizontal Layout like reference) --- */
.deals-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
    gap: var(--space-md);
}

.deal-card {
    display: flex;
    flex-direction: row;
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: transform var(--transition-base), border-color var(--transition-base), box-shadow var(--transition-base);
    text-decoration: none;
    color: inherit;
    border: 1px solid var(--border);
    height: 180px;
}

.deal-card:hover {
    transform: translateY(-4px);
    border-color: var(--border-accent);
    box-shadow: var(--shadow-lg);
}

.deal-card-image {
    width: 140px;
    height: 100%;
    object-fit: cover;
    background: rgba(255, 255, 255, 0.03);
    border-right: 1px solid var(--border);
}

.deal-card-body {
    flex: 1;
    padding: var(--space-md);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.deal-card-meta-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 4px;
}

.deal-card-platform {
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--accent);
}

.deal-card-time {
    font-size: 12px;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 4px;
}

.deal-card-time i {
    font-size: 14px;
}

.deal-card-title {
    font-size: 15px;
    font-weight: 700;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: auto; /* Push everything else down */
}

.deal-card-pricing {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 8px;
    margin-bottom: 12px;
}

.deal-card-price {
    font-size: 18px;
    font-weight: 800;
    color: var(--green);
}

.deal-card-mrp {
    font-size: 14px;
    color: var(--text-muted);
    text-decoration: line-through;
}

.deal-card-discount {
    display: inline-block;
    padding: 2px 8px;
    background: var(--red);
    color: white;
    font-size: 11px;
    font-weight: 800;
    border-radius: 4px;
    margin-left: 4px;
}

.deal-card-footer {
    display: flex;
    align-items: center;
    gap: 8px;
}

.deal-card-footer .btn {
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    text-align: center;
    border: none;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.deal-card-footer .btn-buy {
    background: var(--bg-glass-strong);
    color: var(--text-primary);
    border: 1px solid var(--border-hover);
    flex: 1;
    max-width: 100px;
}

.deal-card-footer .btn-buy:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: var(--border-accent);
}

.deal-card-footer .btn-details {
    background: transparent;
    color: var(--text-secondary);
    flex: 1;
    max-width: 100px;
    border: 1px solid var(--border);
}

.deal-card-footer .btn-details:hover {
    background: rgba(255, 255, 255, 0.05);
}

/* --- Product Card --- */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: var(--space-md);
}

.product-card {
    border-radius: var(--radius-lg);
    background: var(--bg-card);
    border: 1px solid var(--border);
    padding: var(--space-md);
    transition: transform var(--transition-base), border-color var(--transition-base), box-shadow var(--transition-base);
    cursor: pointer;
}

.product-card:hover {
    transform: translateY(-4px);
    border-color: var(--border-accent);
    box-shadow: var(--shadow-lg);
}

.product-card-image {
    width: 100%;
    height: 160px;
    object-fit: contain;
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.03);
    margin-bottom: var(--space-md);
}

.product-card-brand {
    font-size: var(--fs-xs);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--blue);
    margin-bottom: var(--space-xs);
}

.product-card-name {
    font-size: var(--fs-base);
    font-weight: 700;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: var(--space-sm);
}

.product-card-pricing {
    display: flex;
    align-items: baseline;
    gap: var(--space-sm);
    margin-bottom: var(--space-sm);
}

.product-card-price {
    font-size: var(--fs-lg);
    font-weight: 800;
}

.product-card-mrp {
    font-size: var(--fs-sm);
    color: var(--text-muted);
    text-decoration: line-through;
}

.product-card-meta {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    font-size: var(--fs-xs);
    color: var(--text-muted);
}

.product-card-rating {
    display: flex;
    align-items: center;
    gap: 3px;
    color: #fbbf24;
    font-weight: 700;
}

/* --- Product Detail --- */
.product-hero {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: var(--space-xl);
    padding: var(--space-xl) 0;
}

.product-image-container {
    border-radius: var(--radius-xl);
    background: var(--bg-card);
    border: 1px solid var(--border);
    padding: var(--space-xl);
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-image-container img {
    max-height: 360px;
    object-fit: contain;
}

.product-info {
    padding: var(--space-md) 0;
}

.product-brand {
    font-size: var(--fs-sm);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--accent);
    margin-bottom: var(--space-sm);
}

.product-name {
    font-size: var(--fs-2xl);
    font-weight: 800;
    letter-spacing: -0.03em;
    margin-bottom: var(--space-md);
    line-height: 1.2;
}

.product-pricing {
    display: flex;
    align-items: baseline;
    gap: var(--space-md);
    margin-bottom: var(--space-md);
}

.product-current-price {
    font-size: 2rem;
    font-weight: 900;
    color: var(--green);
}

.product-mrp {
    font-size: var(--fs-lg);
    color: var(--text-muted);
    text-decoration: line-through;
}

.product-discount-badge {
    display: inline-flex;
    padding: 6px 14px;
    border-radius: var(--radius-full);
    background: var(--green-subtle);
    color: var(--green);
    font-size: var(--fs-sm);
    font-weight: 800;
}

.product-rating-row {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    margin-bottom: var(--space-lg);
    font-size: var(--fs-sm);
    color: var(--text-secondary);
}

.product-rating-stars {
    color: #fbbf24;
    font-weight: 700;
}

.product-actions {
    display: flex;
    gap: var(--space-md);
    margin-top: var(--space-lg);
}

/* --- Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-sm);
    padding: 12px 24px;
    font-size: var(--fs-base);
    font-weight: 700;
    border-radius: var(--radius-md);
    transition: transform var(--transition-fast), box-shadow var(--transition-fast), background var(--transition-fast);
    white-space: nowrap;
}

.btn:hover {
    transform: translateY(-1px);
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent), #f59e0b);
    color: white;
    box-shadow: 0 6px 20px var(--accent-glow);
}

.btn-primary:hover {
    box-shadow: 0 8px 28px rgba(249, 115, 22, 0.35);
}

.btn-secondary {
    background: var(--bg-glass-strong);
    border: 1px solid var(--border-hover);
    color: var(--text-primary);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: var(--border-accent);
}

.btn-lg {
    padding: 16px 32px;
    font-size: var(--fs-md);
    border-radius: var(--radius-lg);
}

/* --- Price Chart Container --- */
.chart-container {
    border-radius: var(--radius-lg);
    background: var(--bg-card);
    border: 1px solid var(--border);
    padding: var(--space-lg);
    margin: var(--space-lg) 0;
}

.chart-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--space-md);
}

.chart-title {
    font-size: var(--fs-lg);
    font-weight: 800;
}

.chart-stats {
    display: flex;
    gap: var(--space-lg);
}

.chart-stat {
    text-align: center;
}

.chart-stat-value {
    font-size: var(--fs-md);
    font-weight: 800;
}

.chart-stat-label {
    font-size: var(--fs-xs);
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.chart-stat-value.low { color: var(--green); }
.chart-stat-value.high { color: var(--red); }
.chart-stat-value.avg { color: var(--blue); }

.chart-canvas {
    width: 100%;
    height: 260px;
    border-radius: var(--radius-md);
}

/* --- Competitors Table --- */
.competitors-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
}

.competitors-table th {
    font-size: var(--fs-xs);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    padding: var(--space-sm) var(--space-md);
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.competitors-table td {
    padding: var(--space-md);
    border-bottom: 1px solid var(--border);
    font-size: var(--fs-sm);
}

.competitors-table tr:hover td {
    background: var(--bg-glass);
}

.competitor-price {
    font-weight: 800;
    color: var(--green);
}

.competitor-lowest {
    background: var(--green-subtle);
    border-radius: var(--radius-full);
    padding: 2px 10px;
}

/* --- Filters --- */
.filters-bar {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    padding: var(--space-md) 0;
    overflow-x: auto;
    scrollbar-width: none;
}

.filters-bar::-webkit-scrollbar {
    display: none;
}

.filter-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: var(--radius-full);
    background: var(--bg-glass);
    border: 1px solid var(--border);
    font-size: var(--fs-sm);
    font-weight: 600;
    white-space: nowrap;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.filter-chip:hover,
.filter-chip.active {
    background: var(--accent-subtle);
    border-color: var(--border-accent);
    color: var(--accent);
}

.filter-select {
    padding: 8px 14px;
    border-radius: var(--radius-full);
    background: var(--bg-glass);
    border: 1px solid var(--border);
    font-size: var(--fs-sm);
    font-weight: 600;
    outline: none;
    cursor: pointer;
    appearance: none;
    padding-right: 32px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%2394a3b8' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
}

/* --- Skeleton Loading --- */
.skeleton {
    background: linear-gradient(90deg, var(--bg-glass) 0%, var(--bg-glass-strong) 50%, var(--bg-glass) 100%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: var(--radius-md);
}

.skeleton-text {
    height: 14px;
    margin-bottom: var(--space-sm);
    border-radius: var(--radius-sm);
}

.skeleton-text.w-75 { width: 75%; }
.skeleton-text.w-50 { width: 50%; }
.skeleton-text.w-25 { width: 25%; }

.skeleton-image {
    width: 100%;
    height: 180px;
    border-radius: var(--radius-md);
}

.skeleton-card {
    border-radius: var(--radius-lg);
    padding: var(--space-md);
    border: 1px solid var(--border);
}

/* --- Empty State --- */
.empty-state {
    text-align: center;
    padding: var(--space-2xl);
    color: var(--text-muted);
}

.empty-state-icon {
    font-size: 48px;
    margin-bottom: var(--space-md);
    opacity: 0.5;
}

.empty-state-title {
    font-size: var(--fs-lg);
    font-weight: 700;
    color: var(--text-secondary);
    margin-bottom: var(--space-sm);
}

/* --- Footer --- */
.footer {
    margin-top: var(--space-2xl);
    padding: var(--space-xl) 0;
    border-top: 1px solid var(--border);
    text-align: center;
    color: var(--text-muted);
    font-size: var(--fs-sm);
}

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

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.animate-in {
    animation: fadeInUp 0.5s var(--ease) both;
}

/* --- Pagination --- */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: var(--space-sm);
    padding: var(--space-xl) 0;
}

.pagination-btn {
    padding: 10px 18px;
    border-radius: var(--radius-md);
    background: var(--bg-glass);
    border: 1px solid var(--border);
    font-size: var(--fs-sm);
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.pagination-btn:hover:not(:disabled) {
    background: var(--accent-subtle);
    border-color: var(--border-accent);
    color: var(--accent);
}

.pagination-btn:disabled {
    opacity: 0.35;
    cursor: not-allowed;
}

.pagination-info {
    font-size: var(--fs-sm);
    color: var(--text-muted);
    padding: 0 var(--space-md);
}

/* --- Page Transition --- */
.page-transition-enter {
    opacity: 0;
    transform: translateY(8px);
}

.page-transition-active {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.3s var(--ease), transform 0.3s var(--ease);
}

/* --- Specs Accordion --- */
.specs-section {
    margin: var(--space-lg) 0;
}

.specs-group {
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    margin-bottom: var(--space-sm);
    overflow: hidden;
}

.specs-group-header {
    padding: var(--space-md);
    font-weight: 700;
    font-size: var(--fs-base);
    background: var(--bg-glass);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.specs-group-header::after {
    content: '▸';
    transition: transform var(--transition-fast);
}

.specs-group.open .specs-group-header::after {
    transform: rotate(90deg);
}

.specs-group-body {
    display: none;
    padding: 0 var(--space-md) var(--space-md);
}

.specs-group.open .specs-group-body {
    display: block;
}

.specs-row {
    display: flex;
    padding: var(--space-sm) 0;
    border-bottom: 1px solid var(--border);
    font-size: var(--fs-sm);
}

.specs-row:last-child {
    border-bottom: none;
}

.specs-key {
    width: 40%;
    color: var(--text-muted);
    font-weight: 600;
}

.specs-value {
    flex: 1;
    color: var(--text-primary);
}

/* --- Responsive --- */
@media (max-width: 1024px) {
    .product-hero {
        grid-template-columns: 1fr;
        gap: var(--space-lg);
    }

    .navbar-search {
        display: none;
    }
}

@media (max-width: 768px) {
    :root {
        --space-lg: 16px;
        --space-xl: 28px;
        --space-2xl: 48px;
    }

    .container {
        padding: 0 var(--space-md);
    }

    .navbar-nav {
        display: none;
    }

    .navbar-toggle {
        display: flex;
    }

    .stats-bar {
        gap: var(--space-lg);
        flex-wrap: wrap;
    }

    .deals-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    }

    .category-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    }

    .hero-search-input {
        padding: 14px 56px 14px 18px;
        font-size: var(--fs-base);
    }

    .product-actions {
        flex-direction: column;
    }

    .chart-header {
        flex-direction: column;
        gap: var(--space-md);
    }

    .chart-stats {
        width: 100%;
        justify-content: space-around;
    }

    /* Prevent zoom on input focus */
    input[type="text"],
    input[type="search"] {
        font-size: 16px !important;
    }
}

/* --- Scrollbar --- */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* === Test Scraper Page === */
.test-scraper-page {
    max-width: 800px;
    margin: 0 auto;
}

.search-section {
    margin-bottom: 2rem;
}

.search-form {
    display: flex;
    gap: 1rem;
}

.search-input {
    flex: 1;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    color: var(--text-primary);
    font-size: 1rem;
}

.search-btn {
    padding: 0 1.5rem;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: var(--radius);
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

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

.scrape-results {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 2rem;
}

.level-indicator {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border);
}

.badge {
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
}

.badge.pending {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-secondary);
}

.badge.success {
    background: rgba(16, 185, 129, 0.15);
    color: #10b981;
}

.badge.error {
    background: rgba(239, 68, 68, 0.15);
    color: #ef4444;
}

.product-preview {
    display: flex;
    gap: 2rem;
}

.preview-img-col {
    width: 250px;
    flex-shrink: 0;
}

.preview-img-col img {
    width: 100%;
    border-radius: var(--radius);
    background: white;
    padding: 1rem;
}

.preview-info-col {
    flex: 1;
}

.preview-prices {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin: 1rem 0;
}

.preview-price {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
}

.preview-mrp {
    font-size: 1.2rem;
    color: var(--text-secondary);
    text-decoration: line-through;
}

.discount-breakdown {
    background: rgba(255, 255, 255, 0.05);
    padding: 1rem;
    border-radius: var(--radius);
    margin-bottom: 1rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

.skeleton-text {
    background: linear-gradient(90deg, rgba(255,255,255,0.05) 25%, rgba(255,255,255,0.1) 50%, rgba(255,255,255,0.05) 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s infinite;
    color: transparent !important;
    border-radius: 4px;
}

@keyframes skeleton-loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

@media (max-width: 768px) {
    .product-preview {
        flex-direction: column;
    }
    .preview-img-col {
        width: 100%;
        max-width: 300px;
        margin: 0 auto;
    }
}

/* Beautiful Specs Table */
.specs-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 12px;
    font-size: 14px;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid var(--border);
}

.specs-table tr:nth-child(odd) {
    background-color: var(--surface-light);
}

.specs-table tr:nth-child(even) {
    background-color: var(--surface);
}

.specs-table td {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border);
}

.specs-table tr:last-child td {
    border-bottom: none;
}

.specs-table .spec-key {
    font-weight: 600;
    color: var(--text);
    width: 35%;
    border-right: 1px solid var(--border);
}

.specs-table .spec-val {
    color: var(--text-muted);
}

