﻿:root {
    /* 2025 Modern Color Palette - AI-inspired Gradients */
    --primary-color: #6366f1;
    --primary-dark: #4f46e5;
    --primary-light: #818cf8;
    --secondary-color: #06b6d4;
    --secondary-dark: #0891b2;
    --secondary-light: #22d3ee;
    --accent-color: #ec4899;
    --accent-dark: #db2777;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --danger-color: #ef4444;
    
    /* Neural Network Inspired Gradients */
    --gradient-primary: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
    --gradient-secondary: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    --gradient-success: linear-gradient(135deg, #0ba360 0%, #3cba92 100%);
    --gradient-ai: linear-gradient(135deg, #6366f1 0%, #8b5cf6 50%, #ec4899 100%);
    --gradient-cyber: linear-gradient(135deg, #00d4ff 0%, #090979 50%, #020024 100%);
    
    /* Text Colors */
    --text-primary: #0f172a;
    --text-secondary: #64748b;
    --text-tertiary: #94a3b8;
    --text-inverse: #f8fafc;
    
    /* Background Colors - Layered */
    --bg-primary: #ffffff;
    --bg-secondary: #f8fafc;
    --bg-tertiary: #f1f5f9;
    --bg-glass: rgba(255, 255, 255, 0.7);
    --bg-glass-dark: rgba(15, 23, 42, 0.7);
    
    /* Border & Shadows - 3D Enhanced */
    --border-color: #e2e8f0;
    --border-glass: rgba(255, 255, 255, 0.2);
    --shadow-xs: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-sm: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    --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);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    --shadow-glow: 0 0 20px rgba(99, 102, 241, 0.4);
    --shadow-glow-pink: 0 0 30px rgba(236, 72, 153, 0.5);
    
    /* Neumorphic Shadows */
    --neuro-light: 6px 6px 12px #d1d9e6, -6px -6px 12px #ffffff;
    --neuro-dark: inset 6px 6px 12px #d1d9e6, inset -6px -6px 12px #ffffff;
    
    /* Border Radius - Smooth & Modern */
    --radius-sm: 0.5rem;
    --radius-md: 0.75rem;
    --radius-lg: 1rem;
    --radius-xl: 1.5rem;
    --radius-2xl: 2rem;
    --radius-full: 9999px;
    
    /* Transitions - Butter Smooth */
    --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: 300ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 500ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-spring: 600ms cubic-bezier(0.34, 1.56, 0.64, 1);
    
    /* Backdrop Blur - Glassmorphism */
    --blur-sm: blur(4px);
    --blur-md: blur(8px);
    --blur-lg: blur(16px);
    --blur-xl: blur(24px);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    width: 100%;
    overflow-x: hidden;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", "Malgun Gothic", "Apple SD Gothic Neo", sans-serif;
    color: var(--text-primary);
    background: #fafafa;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.page {
    min-height: 100vh;
    width: 100%;
    max-width: 100vw;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow-x: hidden;
}

/* Navbar - Clean & Modern */
.navbar {
    background: #ffffff;
    border-bottom: 1px solid #e5e7eb;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: all var(--transition-base);
}

.navbar-container {
    max-width: 1400px;
    width: 100%;
    margin: 0 auto;
    padding: 1rem clamp(0.75rem, 2vw, 2rem);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.navbar-brand .brand-logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: var(--text-primary);
    font-weight: 800;
    font-size: 1.75rem;
    letter-spacing: -0.02em;
    transition: all var(--transition-base);
    position: relative;
}

.navbar-brand .brand-logo:hover {
    transform: translateY(-2px);
}

.brand-emoji {
    font-size: 2.5rem;
}

.brand-text {
    color: #6366f1;
}

.navbar-menu {
    display: flex;
    gap: 0.5rem;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-full);
    text-decoration: none;
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 0.95rem;
    letter-spacing: -0.01em;
    transition: all var(--transition-base);
    position: relative;
    overflow: hidden;
}

.nav-link:hover {
    color: #6366f1;
    background: #f3f4f6;
}

.nav-link.active {
    background: #6366f1;
    color: white;
}

.nav-icon {
    font-size: 1.3rem;
    transition: all var(--transition-base);
}

.nav-link:hover .nav-icon {
    transform: rotate(5deg) scale(1.1);
}

/* Main Content */
.main-content {
    flex: 1;
    width: 100%;
    max-width: 100vw;
    padding: 2rem clamp(0.75rem, 2vw, 1rem);
    overflow-x: hidden;
}

.content-container {
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
}

/* Page Header - Clean & Simple */
.page-header {
    text-align: center;
    margin-bottom: clamp(2rem, 5vw, 3rem);
    padding: clamp(1.5rem, 3vw, 2.5rem) 0;
    width: 100%;
    max-width: 100%;
}

.page-title {
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    font-weight: 800;
    margin-bottom: 0.75rem;
    color: #1f2937;
    letter-spacing: -0.02em;
    width: 100%;
    max-width: 100%;
}

.title-icon {
    font-size: clamp(2rem, 5vw, 3rem);
}

.page-description {
    color: var(--text-secondary);
    font-size: clamp(1rem, 2.5vw, 1.3rem);
    font-weight: 500;
    margin-bottom: 1.5rem;
    letter-spacing: -0.01em;
    line-height: 1.6;
    padding: 0 0.5rem;
    width: 100%;
    max-width: 100%;
}

.stats {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.stat-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1.25rem;
    background: #6366f1;
    color: white;
    border-radius: 2rem;
    font-weight: 600;
    font-size: 0.9rem;
    letter-spacing: -0.01em;
}

.stat-badge.near {
    background: #06b6d4;
}

/* Sort Controls */
.sort-controls {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.sort-controls label {
    font-size: 0.8rem;
    font-weight: 500;
    color: #6b7280;
}

.sort-controls select {
    padding: 0.4rem 0.75rem;
    border: 1px solid #d1d5db;
    border-radius: 0.375rem;
    font-size: 0.8rem;
    font-weight: 500;
    color: #374151;
    background-color: #ffffff;
    cursor: pointer;
    transition: all 0.2s ease;
    outline: none;
    min-width: 90px;
}

.sort-controls select:hover {
    border-color: #9ca3af;
    background-color: #f9fafb;
}

.sort-controls select:focus {
    border-color: #6366f1;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.08);
}

/* Deals Grid */
.deals-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: clamp(1rem, 2vw, 1.5rem);
    margin-bottom: 2rem;
    width: 100%;
    max-width: 100%;
}

/* Deal Card - Clean & Modern */
.deal-card {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    overflow: hidden;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
    transition: all 0.2s ease;
    position: relative;
    width: 100%;
    max-width: 100%;
}

.deal-card.sold-out {
    opacity: 0.7;
}

.deal-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    border-color: #d1d5db;
}

.deal-card.sold-out:hover {
    transform: translateY(-2px);
}

.deal-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.deal-badge-area {
    padding: 0.75rem;
    min-height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    background-color: #ffffff;
}

.deal-image {
    position: relative;
    width: 100%;
    padding-top: 80%;
    background-color: #ffffff;
    overflow: hidden;
}

.deal-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    max-width: 100%;
    object-fit: contain;
    padding: 0.2rem 0.15rem 0.15rem 0.15rem;
    z-index: 1;
}

.no-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4rem;
}

.discount-badge {
    display: none;
}

.discount-badge-inline {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(255, 75, 75, 0.12) 0%, rgba(255, 75, 75, 0.08) 100%);
    color: #ff4b4b;
    padding: 0.25rem 0.6rem;
    border-radius: 0.5rem;
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 0.02em;
    backdrop-filter: blur(8px);
    border: 1.5px solid rgba(255, 75, 75, 0.25);
    box-shadow: 0 2px 8px rgba(255, 75, 75, 0.15);
    transition: all 0.2s ease;
    align-self: flex-end;
}

.discount-badge-inline:hover {
    background: linear-gradient(135deg, rgba(255, 75, 75, 0.18) 0%, rgba(255, 75, 75, 0.12) 100%);
    border-color: rgba(255, 75, 75, 0.4);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(255, 75, 75, 0.2);
}

.discount-badge-inline.near {
    background: linear-gradient(135deg, rgba(255, 184, 0, 0.12) 0%, rgba(255, 184, 0, 0.08) 100%);
    color: #ff8800;
    border: 1.5px solid rgba(255, 184, 0, 0.25);
    box-shadow: 0 2px 8px rgba(255, 184, 0, 0.15);
}

.discount-badge-inline.near:hover {
    background: linear-gradient(135deg, rgba(255, 184, 0, 0.18) 0%, rgba(255, 184, 0, 0.12) 100%);
    border-color: rgba(255, 184, 0, 0.4);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(255, 184, 0, 0.2);
}

.discount-badge-inline.normal {
    background: linear-gradient(135deg, rgba(100, 116, 139, 0.1) 0%, rgba(100, 116, 139, 0.06) 100%);
    color: #64748b;
    border: 1.5px solid rgba(100, 116, 139, 0.2);
    box-shadow: 0 2px 8px rgba(100, 116, 139, 0.1);
}

.discount-badge-inline.normal:hover {
    background: linear-gradient(135deg, rgba(100, 116, 139, 0.15) 0%, rgba(100, 116, 139, 0.1) 100%);
    border-color: rgba(100, 116, 139, 0.3);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(100, 116, 139, 0.15);
}

.zzindeal-badge {
    display: inline-block;
    background: #6366f1;
    color: white;
    padding: 0.35rem 0.85rem;
    border-radius: 1rem;
    font-weight: 700;
    font-size: 0.8rem;
    letter-spacing: -0.01em;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.zzindeal-badge.near-badge {
    background: #06b6d4;
}

/* Sold Out Overlay */
.sold-out-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.3), rgba(0, 0, 0, 0.4));
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1;
}

.sold-out-badge {
    background: linear-gradient(135deg, #1f2937, #111827);
    color: #f3f4f6;
    padding: 0.4rem 1.25rem;
    border-radius: 0.375rem;
    font-weight: 600;
    font-size: 0.85rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.sold-out-overlay-detail {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.75), rgba(249, 250, 251, 0.8));
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
    backdrop-filter: blur(1px);
}

.sold-out-badge-detail {
    background: linear-gradient(135deg, #1f2937, #111827);
    color: #f3f4f6;
    padding: 0.875rem 2.25rem;
    border-radius: 0.75rem;
    font-weight: 600;
    font-size: 1.25rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    border: 1.5px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 10px 25px rgba(31, 41, 55, 0.3);
}

.sold-out-notice {
    background: linear-gradient(135deg, rgba(220, 38, 38, 0.05), rgba(220, 38, 38, 0.02));
    border: 1.5px solid rgba(220, 38, 38, 0.2);
    border-radius: 0.625rem;
    padding: 0.875rem 1.25rem;
    margin-bottom: 1rem;
    text-align: center;
}

.deal-card.normal-product {
    opacity: 0.95;
}

.deal-card.normal-product:hover {
    opacity: 1;
}

.deal-info {
    padding: 1rem 1.25rem 1.25rem;
    border-top: 1px solid #f3f4f6;
}

.deal-title {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 1rem;
    line-height: 1.4;
    color: #1f2937;
    word-break: keep-all;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    min-height: 3.99rem; /* 1.4 line-height * 0.95rem font-size * 3 lines = 3.99rem */
    max-height: 3.99rem;
}

.deal-prices {
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
    align-items: flex-end;
}

.price-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    justify-content: flex-end;
    width: 100%;
}


.price-row.discount-row {
    margin-bottom: 0;
    align-items: baseline;
    gap: 0.4rem;
}

.price-label {
    color: #6b7280;
    font-size: 0.6rem;
    font-weight: 500;
    letter-spacing: -0.01em;
    white-space: nowrap;
}

.price-value {
    font-weight: 700;
    color: #1f2937;
}

.old-price {
    color: #9ca3af;
    font-size: 1.0rem;
    font-weight: 500;
    text-decoration: line-through;
}

.current-price {
    color: #1f2937;
    font-size: 1.20rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.discount-percentage {
    display: none;
}

.savings {
    display: none;
}

.savings .price-label {
    display: none;
}

.savings-price {
    display: none;
}

/* Loading - Neural Network Animation */
.loading-container {
    text-align: center;
    padding: 4rem 1rem;
    position: relative;
}

.spinner {
    width: 4rem;
    height: 4rem;
    margin: 0 auto 2rem;
    position: relative;
}

.spinner::before,
.spinner::after {
    content: '';
    position: absolute;
    border-radius: 50%;
}

.spinner::before {
    width: 100%;
    height: 100%;
    border: 3px solid transparent;
    border-top-color: var(--primary-color);
    border-right-color: var(--primary-color);
    animation: spinOuter 1.5s cubic-bezier(0.68, -0.55, 0.265, 1.55) infinite;
}

.spinner::after {
    width: 70%;
    height: 70%;
    top: 15%;
    left: 15%;
    border: 3px solid transparent;
    border-bottom-color: var(--accent-color);
    border-left-color: var(--accent-color);
    animation: spinInner 1s cubic-bezier(0.68, -0.55, 0.265, 1.55) infinite reverse;
}

@keyframes spinOuter {
    0% {
        transform: rotate(0deg) scale(1);
        opacity: 1;
    }
    50% {
        transform: rotate(180deg) scale(1.1);
        opacity: 0.8;
    }
    100% {
        transform: rotate(360deg) scale(1);
        opacity: 1;
    }
}

@keyframes spinInner {
    0% {
        transform: rotate(0deg) scale(1);
        opacity: 1;
    }
    50% {
        transform: rotate(-180deg) scale(0.9);
        opacity: 0.6;
    }
    100% {
        transform: rotate(-360deg) scale(1);
        opacity: 1;
    }
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 4rem 1rem;
}

.empty-icon {
    font-size: 4rem;
    display: block;
    margin-bottom: 1rem;
}

.empty-state h3 {
    margin-bottom: 0.5rem;
}

.empty-state p {
    color: var(--text-secondary);
}

/* Load More */
.load-more {
    text-align: center;
    margin: 2rem 0;
}

.btn-load-more {
    padding: 0.75rem 2rem;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 0.5rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-load-more:hover:not(:disabled) {
    background-color: var(--primary-dark);
    transform: translateY(-0.125rem);
}

.btn-load-more:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Infinite Scroll */
.loading-more {
    text-align: center;
    padding: 2rem 1rem;
}

.spinner-small {
    width: 2rem;
    height: 2rem;
    border: 0.25rem solid var(--bg-tertiary);
    border-top-color: var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 0.5rem;
}

.scroll-observer {
    height: 1px;
    width: 100%;
    visibility: hidden;
}

/* Search Page - Clean Style */
.search-container {
    max-width: 900px;
    width: 100%;
    margin: 0 auto 3rem;
    padding: 0 clamp(0.5rem, 2vw, 0);
}

.search-box {
    display: flex;
    gap: 0.75rem;
    background: #ffffff;
    padding: 0.5rem;
    border-radius: 0.75rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    border: 1px solid #e5e7eb;
    transition: all 0.2s ease;
    width: 100%;
    max-width: 100%;
    margin-top: 2.75rem;
}

.category-filter-section {
    margin-bottom: 2rem;
    padding-top: 0.25rem;
}

.category-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
    padding-top: 0.25rem;
}

.category-btn {
    padding: 0.6rem 1.2rem;
    background: #ffffff;
    border: 1.5px solid #e5e7eb;
    border-radius: 2rem;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 500;
    font-size: 0.9rem;
    color: #4b5563;
}

.category-btn:hover {
    background: #eef2ff;
    border-color: #6366f1;
    color: #6366f1;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(99, 102, 241, 0.15);
}

.category-btn:active {
    transform: translateY(0);
}

.category-btn.active {
    background: #6366f1;
    border-color: #6366f1;
    color: #ffffff;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(99, 102, 241, 0.25);
}

.category-btn.active:hover {
    background: #4f46e5;
    border-color: #4f46e5;
    color: #ffffff;
}

.btn-clear-category {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.35rem 0.75rem;
    background: #f3f4f6;
    border: 1px solid #d1d5db;
    border-radius: 0.5rem;
    font-size: 0.85rem;
    font-weight: 500;
    color: #6b7280;
    text-decoration: none;
    transition: all 0.2s ease;
}

.btn-clear-category:hover {
    background: #ef4444;
    border-color: #ef4444;
    color: white;
}

.search-box:focus-within {
    border-color: #6366f1;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

.search-input {
    flex: 1;
    padding: 0.875rem 1.25rem;
    border: none;
    border-radius: 0.5rem;
    font-size: 1rem;
    font-weight: 400;
    outline: none;
    background: #f9fafb;
    color: #1f2937;
    transition: all 0.2s ease;
}

.search-input::placeholder {
    color: #9ca3af;
}

.search-input:focus {
    background: #ffffff;
}

.btn-search {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.875rem 1.75rem;
    background: #6366f1;
    color: white;
    border: none;
    border-radius: 0.5rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-search:hover {
    background: #4f46e5;
}

.btn-search:active {
    transform: scale(0.98);
}

.search-results {
    margin-top: 2rem;
}

.results-count {
    margin-bottom: 1.5rem;
    font-size: 1.125rem;
    color: var(--text-secondary);
}

.search-guide {
    text-align: center;
    padding: 3rem 1rem;
    background-color: var(--bg-primary);
    border-radius: 1rem;
    box-shadow: var(--shadow-sm);
}

.guide-icon {
    font-size: 3rem;
    display: block;
    margin-bottom: 1rem;
}

.search-guide h3 {
    margin-bottom: 1rem;
}

.search-guide ul {
    list-style: none;
    text-align: left;
    display: inline-block;
    color: var(--text-secondary);
}

.search-guide li {
    padding: 0.5rem 0;
}

.search-guide li::before {
    content: "• ";
    color: var(--success-color);
    font-weight: bold;
    font-size: 1.2rem;
    margin-right: 0.5rem;
}

/* Footer */
.footer {
    background-color: #1f2937;
    color: #9ca3af;
    padding: 1.5rem 1rem;
    margin-top: 4rem;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
}

.footer-copyright {
    text-align: center;
}

.footer-copyright p {
    color: #6b7280;
    font-size: 0.875rem;
    margin: 0.5rem 0;
}

.footer-contact a {
    color: #9ca3af;
    text-decoration: none;
    transition: color 0.2s ease;
}

.footer-contact a:hover {
    color: #6366f1;
    text-decoration: underline;
}

.footer-legal {
    font-size: 0.75rem !important;
    color: #4b5563 !important;
}

/* ============================================
   RESPONSIVE BREAKPOINTS
   - PC: 1001px and above (4 columns)
   - Tablet: 601px ~ 1000px (3 columns)
   - Mobile: 600px and below (2 columns)
   ============================================ */

/* TABLET: 601px ~ 1000px */
@media (max-width: 1000px) {
    /* Deals Grid - 3 columns */
    .deals-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 1rem;
    }

    /* Deal Title - 3 lines */
    .deal-title {
        font-size: 0.9rem;
        -webkit-line-clamp: 3;
        min-height: 3.78rem; /* 1.4 line-height * 0.9rem font-size * 3 lines */
        max-height: 3.78rem;
    }

    /* Footer */
    .footer {
        padding: 1.25rem 1rem;
    }
    
    .footer-copyright p {
        font-size: 0.8rem;
    }
}

/* MOBILE: 600px and below */
@media (max-width: 600px) {
    /* Navbar */
    .navbar-container {
        flex-direction: column;
        gap: 0.75rem;
        padding: 0.75rem 1rem;
    }

    .navbar-menu {
        width: 100%;
        justify-content: space-around;
        gap: 0.5rem;
    }

    .nav-link {
        flex: 1;
        justify-content: center;
        padding: 0.75rem 0.5rem;
        font-size: 0.85rem;
    }

    .nav-icon {
        font-size: 1.1rem;
    }

    /* Sort Controls */
    .sort-controls {
        gap: 0.4rem;
    }

    .sort-controls label {
        font-size: 0.75rem;
    }

    .sort-controls select {
        padding: 0.35rem 0.6rem;
        font-size: 0.75rem;
        min-width: 80px;
    }

    /* Deals Grid - 2 columns */
    .deals-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }

    /* Deal Card */
    .deal-card {
        max-width: 100%;
    }

    .deal-image {
        padding-top: 80%;
    }

    .deal-image img {
        padding: 0.2rem 0.15rem 0.15rem 0.15rem;
        z-index: 1;
    }

    .deal-info {
        padding: 0.75rem;
    }

    /* Deal Title - 2 lines */
    .deal-title {
        font-size: 0.8rem;
        margin-bottom: 0.5rem;
        line-height: 1.3;
        -webkit-line-clamp: 2;
        min-height: 2.08rem; /* 1.3 line-height * 0.8rem font-size * 2 lines */
        max-height: 2.08rem;
    }

    /* Badge Area */
    .deal-badge-area {
        padding: 0.5rem;
        min-height: 2rem;
    }

    /* Badges */
    .discount-badge-inline {
        font-size: 0.65rem;
        padding: 0.2rem 0.5rem;
    }

    .zzindeal-badge {
        padding: 0.3rem 0.7rem;
        font-size: 0.75rem;
    }

    /* Prices */
    .deal-prices {
        gap: 0.25rem;
    }

    .price-row {
        font-size: 0.75rem;
        gap: 0.3rem;
        flex-wrap: nowrap;
    }

    .price-label {
        font-size: 0.65rem;
    }

    .old-price {
        font-size: 0.8rem;
    }

    .price-value {
        font-size: 0.80rem;
    }

    .current-price {
        font-size: 0.95rem !important;
    }

    /* Search Box */
    .search-box {
        flex-direction: column;
        gap: 0.5rem;
        padding: 0.5rem;
    }

    .search-input {
        padding: 0.75rem 1rem;
        font-size: 0.95rem;
    }

    .btn-search {
        width: 100%;
        justify-content: center;
        padding: 0.75rem 1.5rem;
    }

    /* Category Filter */
    .category-filter-section {
        margin-bottom: 1.5rem;
        margin-left: -0.75rem;
        margin-right: -0.75rem;
        padding-left: 0.75rem;
        padding-right: 0.75rem;
        padding-top: 0.5rem;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        -ms-overflow-style: none;
        cursor: grab;
    }

    .category-filter-section:active {
        cursor: grabbing;
    }

    .category-filter-section::-webkit-scrollbar {
        display: none;
    }

    .category-buttons {
        display: inline-flex;
        flex-wrap: nowrap;
        gap: 0.5rem;
        justify-content: flex-start;
        padding-bottom: 0.5rem;
    }

    .category-btn {
        padding: 0.5rem 1rem;
        font-size: 0.85rem;
        white-space: nowrap;
        flex-shrink: 0;
        user-select: none;
    }

    .category-btn.active {
        background: #6366f1;
        border-color: #6366f1;
        color: #ffffff;
    }

    .btn-clear-category {
        font-size: 0.8rem;
        padding: 0.3rem 0.6rem;
    }
}

/* Product Detail Page */
.product-detail-page {
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    padding: clamp(1rem, 3vw, 2rem) clamp(0.75rem, 2vw, 1rem);
    overflow-x: hidden;
}

/* Partner Notice - Top Banner */
.partner-notice {
    background: #eef2ff;
    color: #4338ca;
    padding: clamp(0.75rem, 2vw, 1rem) clamp(1rem, 3vw, 1.5rem);
    border-radius: 0.5rem;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    border: 1px solid #c7d2fe;
    width: 100%;
    max-width: 100%;
}

.partner-notice p {
    margin: 0;
    font-size: clamp(0.75rem, 2vw, 0.9rem);
    line-height: 1.5;
    word-break: keep-all;
}

/* Disclaimer Section - Bottom Prominent Notice */
.disclaimer-section {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    border: 2px solid #f59e0b;
    border-radius: 1rem;
    padding: clamp(1rem, 3vw, 1.5rem);
    margin-top: 2rem;
    width: 100%;
    max-width: 100%;
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.2);
}

.disclaimer-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(245, 158, 11, 0.3);
}

.disclaimer-icon {
    font-size: 1.5rem;
    flex-shrink: 0;
}

.disclaimer-title {
    font-size: clamp(1rem, 2.5vw, 1.15rem);
    font-weight: 700;
    color: #92400e;
    letter-spacing: -0.01em;
}

.disclaimer-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.disclaimer-list li {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    color: #78350f;
    font-size: clamp(0.8rem, 2vw, 0.9rem);
    line-height: 1.6;
    word-break: keep-all;
}

.disclaimer-bullet {
    font-size: 1rem;
    flex-shrink: 0;
    margin-top: 0.1rem;
}

.disclaimer-list li span:last-child {
    flex: 1;
}

.product-detail-container {
    background-color: var(--bg-primary);
    border-radius: 1rem;
    padding: clamp(1rem, 3vw, 2rem);
    box-shadow: var(--shadow-md);
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
}

.product-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.btn-back {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background-color: var(--bg-secondary);
    color: var(--text-primary);
    border: none;
    border-radius: 0.5rem;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-back:hover {
    background-color: var(--bg-tertiary);
}

.zzindeal-badge.large {
    padding: 0.5rem 1.5rem;
    font-size: 1.125rem;
    border-radius: 0.75rem;
}

.product-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(1.5rem, 4vw, 3rem);
    width: 100%;
    max-width: 100%;
}

.product-image-section {
    display: flex;
    align-items: flex-start;
    justify-content: center;
}

.product-main-image {
    width: auto;
    max-width: 100%;
    height: auto;
    border-radius: 0.75rem;
    object-fit: contain;
}

.no-image-large {
    width: 100%;
    max-width: min(500px, 100%);
    aspect-ratio: 1;
    background-color: #f9fafb;
    border-radius: 0.75rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.no-image-large p {
    color: #9ca3af;
    font-size: 1rem;
}

.product-info-section {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.product-name {
    font-size: clamp(1.1rem, 3vw, 1.4rem);
    font-weight: 700;
    line-height: 1.4;
    margin: 0;
    word-break: keep-all;
}

.product-rating {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.6rem 0;
    margin: 0.4rem 0;
    background: #2d2d2d;
    border-radius: 0.4rem;
    padding: 0.6rem 0.85rem;
}

.rating-star {
    font-size: 1.1rem;
}

.rating-score {
    font-size: 0.9rem;
    font-weight: 600;
    color: #ffffff;
}

.rating-count {
    font-size: 0.8rem;
    color: #9ca3af;
}

.discount-info {
    display: none;
}

.discount-badge-large {
    display: none;
}

.price-info-box {
    background-color: var(--bg-secondary);
    padding: 1.2rem;
    border-radius: 0.75rem;
}

.price-info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.7rem 0;
}

.price-info-row:not(:last-child):not(.discount) {
    border-bottom: 1px solid var(--border-color);
}

.price-info-row.highlight {
    background-color: transparent;
    padding: 0.7rem 0;
}

.info-label {
    font-size: 0.8rem;
    color: #9ca3af;
    font-weight: 500;
    letter-spacing: -0.01em;
}

.info-value {
    font-weight: 700;
}

.info-value.old-price {
    text-decoration: line-through;
    color: #9ca3af;
    font-size: 0.9rem;
}

.info-value.current-price {
    color: #1f2937;
    font-size: 1.5rem;
    letter-spacing: -0.02em;
}

.info-value.discount-rate {
    color: #dc2626;
    font-size: 1.75rem;
    font-weight: 700;
    letter-spacing: -0.03em;
}

.savings-row {
    display: none;
}

.action-section {
    margin-top: 0.8rem;
}

.btn-purchase {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.85rem 1.5rem;
    background: #6366f1;
    color: white;
    border: none;
    border-radius: 0.5rem;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-purchase:hover {
    background: #4f46e5;
    transform: translateY(-2px);
}

.btn-purchase span:first-child {
    font-size: 1.2rem;
}

.recommendation-info {
    background: linear-gradient(135deg, rgba(78, 205, 196, 0.1), rgba(68, 163, 213, 0.1));
    padding: 1.5rem;
    border-radius: 0.75rem;
    border-left: 4px solid var(--secondary-color);
}

.recommendation-info h3 {
    font-size: 1.125rem;
    margin-bottom: 0.5rem;
}

.recommendation-info p {
    margin: 0;
    color: var(--text-secondary);
    line-height: 1.6;
}

.btn-primary {
    padding: 0.75rem 2rem;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 0.5rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

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

/* Price Chart Section */
.price-chart-section {
    margin-top: 3rem;
    padding: 0;
    background: transparent;
}

.chart-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: #1f2937;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.chart-container {
    background: linear-gradient(to bottom, #ffffff 0%, #f9fafb 100%);
    border-radius: 1.25rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    border: 1px solid #e5e7eb;
    width: 100%;
    max-width: 100%;
    overflow: visible;
    position: relative;
}

.chart-container canvas {
    min-height: 350px !important;
    max-height: 380px !important;
    width: 100% !important;
    height: 350px !important;
}

.data-collecting-notice {
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    border: 1px solid #38bdf8;
    border-radius: 1rem;
    padding: 2rem;
    text-align: center;
    box-shadow: 0 4px 6px -1px rgba(56, 189, 248, 0.1);
}

.data-collecting-notice p {
    margin: 0;
    color: #0c4a6e;
    font-size: 1rem;
    font-weight: 500;
    line-height: 1.6;
}

/* ============================================
   PRODUCT DETAIL PAGE - TABLET
   ============================================ */
@media (max-width: 1000px) {
    .product-content {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .product-header {
        flex-direction: row;
        justify-content: space-between;
    }

    .product-detail-container {
        padding: 1rem;
    }

    .price-info-box {
        padding: 1rem;
    }

    .info-label {
        font-size: 0.8rem;
    }

    .info-value {
        font-size: 1rem;
    }

    .info-value.current-price {
        font-size: 1.25rem;
    }

    .info-value.discount-rate {
        font-size: 1.5rem;
    }

    .btn-purchase {
        font-size: 1rem;
        padding: 0.875rem 1.5rem;
    }

    .price-chart-section {
        margin-top: 2rem;
    }

    .chart-title {
        font-size: 1.125rem;
        margin-bottom: 1rem;
    }

    .chart-container canvas {
        min-height: 250px !important;
        max-height: 300px !important;
    }
}

/* ============================================
   PRODUCT DETAIL PAGE - MOBILE
   ============================================ */
@media (max-width: 600px) {
    .product-detail-page {
        padding: 0.75rem 0.5rem;
    }

    .product-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
        margin-bottom: 1rem;
    }

    .btn-back {
        padding: 0.5rem 0.875rem;
        font-size: 0.9rem;
    }

    .zzindeal-badge.large {
        padding: 0.3rem 0.85rem;
        font-size: 0.85rem;
    }

    .product-detail-container {
        padding: 0.75rem;
    }

    .price-info-box {
        padding: 0.875rem;
    }

    .discount-badge-large {
        padding: 0.35rem 0.875rem;
        font-size: 0.95rem;
    }

    .info-value.discount-rate {
        font-size: 1.4rem;
    }


    .chart-container canvas {
        min-height: 200px !important;
        max-height: 250px !important;
    }
}
