/* Randomized Color Theme System */

:root {
    /* Theme Colors - Will be dynamically set by JavaScript */
    --primary-color: #ec4899;
    --primary-light: #f472b6;
    --primary-dark: #be185d;
    
    --secondary-color: #f97316;
    --secondary-light: #fed7aa;
    --secondary-dark: #c2410c;
    
    --accent-color: #fbbf24;
    --accent-light: #fef3c7;
    --accent-dark: #d97706;
    
    --tertiary-color: #06b6d4;
    --tertiary-light: #a5f3fc;
    --tertiary-dark: #0891b2;
    
    --quaternary-color: #8b5cf6;
    --quaternary-light: #d8b4fe;
    --quaternary-dark: #6d28d9;
    
    --bg-gradient-1: linear-gradient(135deg, var(--primary-light), var(--secondary-light));
    --bg-gradient-2: linear-gradient(135deg, var(--secondary-light), var(--accent-light));
    --bg-gradient-3: linear-gradient(135deg, var(--accent-light), var(--tertiary-light));
    --bg-gradient-4: linear-gradient(135deg, var(--tertiary-light), var(--quaternary-light));
    
    --text-color: #1f2937;
    --text-light: #6b7280;
}

/* Hero Section */
.hero-section {
    background: var(--bg-gradient-1);
    transition: all 0.5s ease;
}

.hero-section h1 {
    color: var(--text-color);
    transition: color 0.5s ease;
}

.hero-section p {
    color: var(--text-color);
    transition: color 0.5s ease;
}

.hero-button {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    transition: all 0.5s ease;
}

.hero-button:hover {
    background: linear-gradient(135deg, var(--primary-light), var(--primary-color));
    box-shadow: 0 10px 25px rgba(236, 72, 153, 0.3);
}

/* Trending Section */
.trending-section {
    background: var(--bg-gradient-2);
    transition: all 0.5s ease;
}

.trending-section h2 {
    color: var(--text-color);
}

.trending-section .gradient-underline {
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
}

.product-card {
    background: white;
    border: 2px solid transparent;
    transition: all 0.3s ease;
}

.product-card:hover {
    border-color: var(--secondary-color);
    box-shadow: 0 10px 30px rgba(249, 115, 22, 0.15);
}

.product-card-bg {
    background: linear-gradient(135deg, var(--secondary-light), var(--accent-light));
}

.discount-badge {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
}

.view-all-btn {
    background: linear-gradient(135deg, var(--secondary-color), var(--secondary-dark));
    transition: all 0.5s ease;
}

.view-all-btn:hover {
    background: linear-gradient(135deg, var(--secondary-light), var(--secondary-color));
    box-shadow: 0 10px 25px rgba(249, 115, 22, 0.3);
}

/* Find Us Section */
.find-us-section {
    background: var(--bg-gradient-3);
    transition: all 0.5s ease;
}

.find-us-section h2 {
    color: var(--text-color);
}

.etsy-btn {
    background: linear-gradient(135deg, var(--secondary-color), var(--secondary-dark));
    transition: all 0.5s ease;
}

.etsy-btn:hover {
    background: linear-gradient(135deg, var(--secondary-light), var(--secondary-color));
    box-shadow: 0 10px 25px rgba(249, 115, 22, 0.3);
}

.mercari-btn {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    transition: all 0.5s ease;
}

.mercari-btn:hover {
    background: linear-gradient(135deg, var(--primary-light), var(--primary-color));
    box-shadow: 0 10px 25px rgba(236, 72, 153, 0.3);
}

/* Popular Brands Section */
.brands-section {
    background: linear-gradient(135deg, var(--accent-light), white);
    transition: all 0.5s ease;
}

.brands-section h2 {
    color: var(--text-color);
}

.brands-section .gradient-underline {
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
}

.brand-card {
    background: linear-gradient(135deg, var(--accent-light), var(--secondary-light));
    border-bottom: 3px solid var(--accent-color);
    transition: all 0.3s ease;
}

.brand-card:hover {
    border-bottom-color: var(--primary-color);
    box-shadow: 0 10px 30px rgba(251, 191, 36, 0.2);
    transform: translateY(-5px);
}

/* Why Choose Us Section */
.why-choose-section {
    background: linear-gradient(135deg, var(--accent-light), var(--tertiary-light));
    transition: all 0.5s ease;
}

.why-choose-section h2 {
    color: var(--text-color);
}

.feature-card {
    background: white;
    border-left: 4px solid transparent;
    transition: all 0.3s ease;
}

.feature-card:first-child {
    border-left-color: var(--primary-color);
}

.feature-card:nth-child(2) {
    border-left-color: var(--secondary-color);
}

.feature-card:nth-child(3) {
    border-left-color: var(--tertiary-color);
}

.feature-card h3 {
    color: var(--text-color);
}

.feature-card:hover {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transform: translateY(-5px);
}

/* Removed global transitions to avoid animating everything — keep transitions only where intended */

/* Prevent excessive re-renders */
img, button > span, svg {
    transition: none;
}

/* Smooth animated theme transitions only for footer */
footer {
    transition: background 0.9s ease, background-image 0.9s ease, color 0.6s ease, border-color 0.6s ease, box-shadow 0.6s ease;
}

/* Simple one-time scroll animations (fade/slide up) */
.animate-once {
    opacity: 0;
    transform: translateY(18px);
    will-change: opacity, transform;
}

.animate-once.in-view {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.75s cubic-bezier(.2,.9,.2,1), transform 0.75s cubic-bezier(.2,.9,.2,1);
}

/* Utility: stagger children when container becomes visible */
.animate-once.stagger > * {
    opacity: 0;
    transform: translateY(14px);
}
.animate-once.stagger.in-view > * {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.6s ease, transform 0.6s ease;
}
.animate-once.stagger.in-view > *:nth-child(1) { transition-delay: 0.06s }
.animate-once.stagger.in-view > *:nth-child(2) { transition-delay: 0.12s }
.animate-once.stagger.in-view > *:nth-child(3) { transition-delay: 0.18s }
.animate-once.stagger.in-view > *:nth-child(4) { transition-delay: 0.24s }


/* Navbar and Footer theming - apply theme variables site-wide */
/* Specific navbar selector to override Tailwind utility classes */
#site-nav, header, nav, .site-header, .navbar, .main-nav {
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color)) !important;
    color: white !important;
}

#site-nav a, header a, nav a, .site-header a, .navbar a, .main-nav a {
    color: rgba(255,255,255,0.95) !important;
}

/* Footer theming */
footer, .site-footer, .footer {
    background: linear-gradient(90deg, var(--secondary-dark), var(--primary-dark)) !important;
    color: var(--footer-text-color, #ffffff) !important;
    border-top-color: rgba(255,255,255,0.06) !important;
}

footer a, .site-footer a, .footer a {
    color: #ffffff !important;
    opacity: 0.95;
}

/* Ensure any gray utility classes inside the footer are white for contrast */
footer .text-gray-600,
footer .text-gray-500,
footer .text-gray-400,
footer .text-gray-700,
footer .text-gray-800,
footer p,
footer span,
footer li {
    color: #ffffff !important;
}

/* Replace common Tailwind gray text utilities with themed text color for better contrast */
.text-gray-600,
.text-gray-500,
.text-gray-400,
.text-gray-700,
.text-gray-800 {
    color: var(--text-color) !important;
}

/* Footer links should keep static layout but show the underline animation */
footer a, .site-footer a, .footer a {
    transform: none !important;
    position: relative;
}

footer a::after, .site-footer a::after, .footer a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -4px;
    height: 3px;
    width: 0;
    border-radius: 3px;
    background: rgba(255,255,255,0.18);
    transition: width 0.28s ease, opacity 0.22s ease;
    opacity: 0.95;
}

footer a:hover::after, .site-footer a:hover::after, .footer a:hover::after {
    width: 100%;
}

/* Pagination: completely transparent, no backgrounds, neutral gray color */
.site-pagination,
.site-pagination a,
.site-pagination span {
    background: transparent !important;
    background-image: none !important;
    background-gradient: none !important;
    color: #6b7280 !important;
    box-shadow: none !important;
    border: none !important;
}

.site-pagination a,
.site-pagination span {
    padding: 0.5rem 0.75rem;
    border-radius: 0.5rem;
    transition: color 0.15s ease, transform 0.12s ease;
}

.site-pagination a:hover {
    color: #374151 !important;
    transform: translateY(-2px) scale(1.01);
}

.site-pagination span {
    color: #374151 !important;
}
