/* ================================================================
   Kerfa's Corner – Main Styles v4
   Refined Premium E-commerce Aesthetic | UI/UX Polish
   ================================================================ */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;600;800&family=Playfair+Display:ital,wght@0,700;1,700&family=Plus+Jakarta+Sans:wght@400;500;600;700&display=swap');

:root {
    /* Taste-driven Color Palette - Refined */
    --primary: #FF7EB3;
    /* Strawberry Frosting */
    --primary-hover: #E6669D;
    --secondary: #1D4E89;
    /* Deep Royal Trust */
    --secondary-light: #3A6EA5;
    --accent: #FDF2F5;
    /* Soft Pink Cream */
    --warm-bg: #FFFBFB;
    /* Off-white warm dough */
    --glass: rgba(255, 255, 255, 0.85);

    /* Typography */
    --font-display: 'Outfit', sans-serif;
    --font-serif: 'Playfair Display', serif;
    --font-body: 'Plus Jakarta Sans', sans-serif;

    /* Elevation & Curves */
    --shadow-soft: 0 5px 15px rgba(255, 126, 179, 0.08);
    --shadow-md: 0 10px 30px rgba(29, 78, 137, 0.1);
    --shadow-lg: 0 15px 40px rgba(255, 126, 179, 0.2);
    --radius-sm: 10px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --radius-pill: 50px;

    /* Animations */
    --transition-fast: all 0.3s ease;
    --transition-spring: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* ── Base Styles ── */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--warm-bg);
    color: var(--secondary);
    font-family: var(--font-body);
    line-height: 1.7;
    overflow-x: hidden;
}

h1,
h2,
h3,
h4 {
    font-family: var(--font-display);
    color: var(--secondary);
    font-weight: 800;
}

.serif {
    font-family: var(--font-serif);
    font-style: italic;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* ── Navbar ── */
.navbar {
    background: var(--glass);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 143, 177, 0.1);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: var(--transition-fast);
}

.navbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.navbar-brand {
    font-family: var(--font-display);
    font-size: 1.8rem;
    font-weight: 900;
    color: var(--secondary);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.brand-icon {
    font-size: 2.5rem;
    color: var(--primary);
    filter: drop-shadow(0 4px 6px rgba(255, 126, 179, 0.3));
    animation: pulseHeart 2s infinite;
}

@keyframes pulseHeart {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.1);
    }

    100% {
        transform: scale(1);
    }
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2.5rem;
    align-items: center;
}

.nav-links a {
    text-decoration: none;
    color: var(--secondary);
    font-weight: 700;
    font-size: 0.95rem;
    transition: var(--transition-fast);
    position: relative;
}

.nav-links a:after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 3px;
    background: var(--primary);
    border-radius: 5px;
    transition: var(--transition-fast);
}

.nav-links a:hover {
    color: var(--primary);
}

.nav-links a:hover:after {
    width: 100%;
}

/* ── Appetizing Hero ── */
.hero {
    padding: 8rem 0 6rem;
    background: radial-gradient(circle at 80% 20%, var(--accent) 0%, transparent 40%),
        radial-gradient(circle at 10% 80%, #E0F2FF 0%, transparent 30%);
    text-align: center;
    position: relative;
}

.hero-tag {
    display: inline-block;
    background: var(--accent);
    color: var(--primary-dark);
    padding: 0.5rem 1.5rem;
    border-radius: var(--radius-pill);
    font-weight: 800;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 1.5rem;
}

.hero h1 {
    font-size: clamp(3rem, 8vw, 5rem);
    line-height: 0.9;
    margin-bottom: 1.5rem;
}

.hero p {
    font-size: 1.25rem;
    color: #576D80;
    max-width: 650px;
    margin: 0 auto 3rem;
    font-weight: 500;
}

/* ── Modern Product Grid ── */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 3rem;
    padding: 4rem 0;
}

.product-card {
    background: white;
    border-radius: var(--radius-xl);
    overflow: hidden;
    transition: var(--transition-spring);
    border: 1px solid transparent;
    position: relative;
}

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

.product-image-container {
    position: relative;
    width: 100%;
    aspect-ratio: 1/1.1;
    overflow: hidden;
    background: var(--accent);
}

.product-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 1.2s ease;
}

.product-card:hover .product-img {
    transform: scale(1.15);
}

.product-badge {
    position: absolute;
    top: 1.5rem;
    left: 1.5rem;
    background: rgba(255, 255, 255, 0.9);
    padding: 0.4rem 1rem;
    border-radius: var(--radius-pill);
    font-weight: 800;
    font-size: 0.75rem;
    color: var(--primary);
    backdrop-filter: blur(10px);
}

.product-details {
    padding: 2rem;
}

.product-cat {
    font-size: 0.75rem;
    font-weight: 800;
    color: var(--primary);
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

.product-title {
    font-size: 1.5rem;
    margin-bottom: 0.75rem;
}

.product-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1.5rem;
}

.product-price {
    font-size: 1.5rem;
    font-weight: 900;
    color: var(--secondary);
}

/* ── Buttons ── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 1.1rem 2.2rem;
    border-radius: var(--radius-pill);
    font-weight: 800;
    font-size: 1rem;
    text-decoration: none;
    cursor: pointer;
    transition: var(--transition-spring);
    border: none;
    white-space: nowrap;
}

.btn-primary {
    background: var(--primary);
    color: white !important;
    box-shadow: 0 10px 25px rgba(255, 126, 179, 0.4);
}

.btn-primary:hover {
    background: var(--primary-hover);
    transform: scale(1.05) translateY(-2px);
    box-shadow: 0 15px 30px rgba(255, 126, 179, 0.5);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--secondary);
    color: var(--secondary);
}

.btn-outline:hover {
    background: var(--secondary);
    color: white;
}

.btn-ghost {
    background: var(--accent);
    color: var(--primary);
}

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

/* ── Floating Cart ── */
.floating-cart {
    position: fixed;
    bottom: 3rem;
    right: 3rem;
    width: 80px;
    height: 80px;
    background: var(--secondary);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    box-shadow: var(--shadow-lg);
    z-index: 999;
    text-decoration: none;
    transition: var(--transition-spring);
}

.floating-cart:hover {
    transform: scale(1.1) rotate(-10deg);
}

.cart-count-badge {
    position: absolute;
    top: -10px;
    right: -10px;
    background: var(--primary);
    color: white;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    border: 4px solid var(--warm-bg);
}

/* ── Flash Messages ── */
.flash {
    width: 100%;
    position: fixed;
    top: 2rem;
    left: 50%;
    transform: translateX(-50%);
    padding: 1rem 2.5rem;
    border-radius: var(--radius-pill);
    font-weight: 700;
    color: white;
    z-index: 2000;
    box-shadow: var(--shadow-lg);
    animation: slideDown 0.5s var(--transition-spring);
}

.flash-success {
    background: #10B981;
}

.flash-error {
    background: var(--primary);
}

@keyframes slideDown {
    from {
        top: -50px;
        opacity: 0;
    }

    to {
        top: 2rem;
        opacity: 1;
    }
}

/* ── Responsive ── */
@media (max-width: 768px) {
    .container {
        padding: 0 1.5rem;
    }

    .hero {
        padding: 5rem 0 3rem;
    }

    .hero h1 {
        font-size: 3rem;
    }

    .product-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .nav-links {
        display: none;
    }

    .floating-cart {
        bottom: 1.5rem;
        right: 1.5rem;
        width: 64px;
        height: 64px;
    }
}

/* ── Utilities ── */
.text-center {
    text-align: center;
}

.mb-2 {
    margin-bottom: 1rem;
}

.mt-4 {
    margin-top: 2rem;
}

.flex {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.fade-in {
    animation: fadeIn 0.5s var(--transition-fast);
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}