/* --- 1. Global Styles & Variables (Consistent with index.html) --- */
:root {
    --bg-color: #0f0f0f;
    --primary-card-bg: #1a1a1a;
    --text-color: #ffffff;
    --text-muted: #888;
    --accent-color-1: #ff6b6b;
    --accent-color-2: #4ecdc4;
    --header-bg: rgba(15, 15, 15, 0.8);
    --transition-main: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Montserrat', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}


/* ===============================
   GLOBAL LINK RESET
================================ */
a {
    text-decoration: none;
    color: inherit;
}

/* ===============================
   CONTAINER
================================ */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ===============================
   GLOBAL HEADER
================================ */
.global-header {
    position: sticky;
    top: 0;
    width: 100%;
    padding: 16px 0;
    background: rgba(15, 15, 15, 0.75);
    backdrop-filter: blur(14px);
    z-index: 1000;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    transition: background 0.3s ease, box-shadow 0.3s ease;
}

.global-header.scrolled {
    background: rgba(10, 10, 10, 0.9);
    box-shadow: 0 6px 30px rgba(0, 0, 0, 0.35);
}

/* ===============================
   NAV LAYOUT
================================ */
.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* ===============================
   LOGO (FASHION BRAND FEEL)
================================ */
.logo {
    font-size: 1.6rem;
    font-weight: 900;
    letter-spacing: 3px;
    text-transform: uppercase;
    position: relative;
}

.logo::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -6px;
    width: 40%;
    height: 2px;
    background: linear-gradient(90deg, #ff6b6b, #4ecdc4);
    opacity: 0.6;
}

/* ===============================
   NAV LINKS
================================ */
.nav-links {
    display: flex;
    gap: 28px;
}

/* ===============================
   ICON LINKS
================================ */
.nav-links a {
    position: relative;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    transition: all 0.3s ease;
}

/* Icon style */
.nav-links i {
    font-size: 1.15rem;
    color: rgba(255, 255, 255, 0.65);
    transition: transform 0.3s ease, color 0.3s ease;
}

/* Hover effect */
.nav-links a:hover {
    background: rgba(255, 255, 255, 0.08);
}

.nav-links a:hover i {
    color: #ffffff;
    transform: scale(1.15);
}

/* Active page indicator */
.nav-links a.active::after {
    content: '';
    position: absolute;
    bottom: -8px;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #4ecdc4;
}

/* ===============================
   WISHLIST BADGE (OPTIONAL)
================================ */
/* ===============================
   WISHLIST COUNT BADGE
================================ */
.nav-links a[data-count]::before {
    content: attr(data-count);
    position: absolute;
    top: 4px;
    right: 4px;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;

    display: flex;
    align-items: center;
    justify-content: center;

    background: #ff6b6b;
    color: #fff;
    font-size: 0.65rem;
    font-weight: 700;
    line-height: 1;

    border-radius: 999px;
    box-shadow: 0 0 0 2px #0f0f0f;
    pointer-events: none;
}

/* Hide badge when count is 0 or missing */
.nav-links a[data-count="0"]::before,
.nav-links a:not([data-count])::before {
    display: none;
}


/* ===============================
   ACCESSIBILITY
================================ */
.nav-links a:focus-visible {
    outline: 2px solid #4ecdc4;
    outline-offset: 4px;
}


/* --- 3. Wishlist Section --- */
.wishlist-section {
    padding: 60px 0;
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 50px;
}

/* The Grid for Wishlist Items */
#wishlist-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
}

/* Wishlist Item Card */
.product-card {
    background-color: var(--primary-card-bg);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    transition: var(--transition-main);
    position: relative;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.5);
}

.product-image-container {
    width: 100%;
    height: 300px;
    background-color: #000;
}

.product-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-info {
    padding: 20px;
}

.product-name {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 5px;
}

.product-price {
    font-size: 1rem;
    color: var(--accent-color-2);
}

.remove-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 30px;
    height: 30px;
    background-color: rgba(0, 0, 0, 0.5);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.3s;
}

.remove-btn:hover {
    background-color: var(--accent-color-1);
}

.remove-btn svg {
    width: 16px;
    height: 16px;
    fill: #fff;
}

/* Empty Wishlist State */
#empty-wishlist-view {
    text-align: center;
    padding: 80px 20px;
    display: none;
    /* Hidden by default */
}

#empty-wishlist-view h2 {
    font-size: 1.8rem;
    margin-bottom: 15px;
}

#empty-wishlist-view p {
    color: var(--text-muted);
    margin-bottom: 30px;
}

.shop-now-btn {
    display: inline-block;
    padding: 12px 30px;
    background: var(--accent-color-2);
    color: #000;
    font-weight: 600;
    border-radius: 50px;
    transition: var(--transition-main);
}

.shop-now-btn:hover {
    background: #61e6da;
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

/* --- 4. Global Footer (Copied from index.html) --- */
.global-footer {
    background-color: #000;
    padding: 40px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.social-links {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
}

.social-icon {
    fill: var(--text-muted);
    width: 24px;
    height: 24px;
    transition: var(--transition-main);
}

.social-icon:hover {
    fill: var(--accent-color-2);
    transform: translateY(-3px);
}

.copyright {
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* --- 5. Responsive Design --- */
@media (max-width: 900px) {
    #wishlist-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {

    /* On mobile, we can use 2 columns for a compact view, or 1 for larger images. Let's try 2. */
    #wishlist-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }

    .product-image-container {
        height: 200px;
    }

    .product-name {
        font-size: 0.9rem;
    }

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