@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,500;0,700;1,400;1,500&family=DM+Sans:wght@300;400;500&display=swap');

/* ══════════════════════════════
   TOKENS
══════════════════════════════ */
:root {
    --cream:   #faf7f2;
    --cream2:  #f0ebe1;
    --cream3:  #e4ddd0;
    --ink:     #111008;
    --ink2:    #2a2820;
    --ink3:    #4a4840;
    --gold:    #c9a96e;
    --gold2:   #e8cc9a;
    --gold3:   #8a6f3a;
    --rose:    #c97a6e;
    --text:    #2a2820;
    --text2:   #6a6558;
    --text3:   #9a9488;
    --border:  #e0d8cc;
    --white:   #ffffff;
    --r:       6px;
    --r-lg:    14px;
    --sh:      0 2px 12px rgba(0,0,0,.07);
    --sh-lg:   0 8px 40px rgba(0,0,0,.12);
    --trans:   .25s ease;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
    font-family: 'DM Sans', system-ui, sans-serif;
    font-weight: 400;
    color: var(--text);
    background: var(--cream);
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

h1, h2, h3, h4 {
    font-family: 'Playfair Display', Georgia, serif;
    font-weight: 400;
    line-height: 1.15;
}

a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }
button { font-family: 'DM Sans', sans-serif; cursor: pointer; }

/* ══════════════════════════════
   NAV
══════════════════════════════ */
.site-nav {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 900;
    transition: background .3s ease, box-shadow .3s ease;
    padding: 0;
    background: transparent;
}
.site-nav.scrolled {
    background: rgba(250,247,242,.95);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 var(--border);
}

/* Force dark nav for specific pages (products, cart, checkout) */
.site-nav.force-dark {
    background: rgba(250,247,242,.95);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 var(--border);
}

.nav-inner {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 32px;
    height: 70px;
    display: flex;
    align-items: center;
    gap: 40px;
}

.nav-brand {
    display: flex;
    align-items: center;
    text-decoration: none;
}
.nav-brand-logo {
    height: 150px;
    width: auto;
    object-fit: contain;
    transition: opacity var(--trans), filter .3s ease;
    filter: brightness(0) invert(1);
}
.site-nav.scrolled .nav-brand-logo,
.site-nav.force-dark .nav-brand-logo {
    filter: brightness(1) invert(0);
}
.nav-brand:hover .nav-brand-logo {
    opacity: 0.8;
}

.nav-links {
    display: flex;
    gap: 32px;
    margin-left: auto;
}
.nav-links a {
    font-size: 0.82rem;
    letter-spacing: .06em;
    color: rgba(255,255,255,.7);
    transition: color .3s ease;
    padding-bottom: 2px;
    border-bottom: 1px solid transparent;
}
.site-nav.scrolled .nav-links a,
.site-nav.force-dark .nav-links a {
    color: var(--text2);
}
.nav-links a:hover {
    color: rgba(255,255,255,.95);
}
.site-nav.scrolled .nav-links a:hover,
.site-nav.scrolled .nav-links a.active,
.site-nav.force-dark .nav-links a:hover,
.site-nav.force-dark .nav-links a.active {
    color: var(--ink);
    border-bottom-color: var(--gold);
}
.nav-links a.active {
    color: var(--gold);
    border-bottom-color: var(--gold);
}

.nav-cart {
    position: relative;
    color: rgba(255,255,255,.8);
    display: flex;
    align-items: center;
    margin-left: 20px;
    transition: color .3s ease;
}
.site-nav.scrolled .nav-cart,
.site-nav.force-dark .nav-cart {
    color: var(--ink);
}
.nav-cart:hover { 
    color: var(--gold); 
}
.site-nav.scrolled .nav-cart:hover,
.site-nav.force-dark .nav-cart:hover { 
    color: var(--gold3); 
}

.cart-badge {
    position: absolute;
    top: -8px; right: -8px;
    width: 18px; height: 18px;
    background: var(--gold);
    color: var(--ink);
    font-size: 0.65rem;
    font-weight: 700;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid rgba(10,8,5,.2);
    transition: border-color .3s ease;
}
.site-nav.scrolled .cart-badge,
.site-nav.force-dark .cart-badge {
    border-color: rgba(250,247,242,.8);
}

.nav-hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    padding: 6px;
    margin-left: 16px;
}
.nav-hamburger span {
    display: block;
    width: 22px; height: 1.5px;
    background: rgba(255,255,255,.8);
    transition: all .3s ease;
}
.site-nav.scrolled .nav-hamburger span,
.site-nav.force-dark .nav-hamburger span {
    background: var(--ink);
}
.nav-hamburger.open span:nth-child(1) { transform: rotate(45deg) translate(5px,5px); }
.nav-hamburger.open span:nth-child(2) { opacity: 0; }
.nav-hamburger.open span:nth-child(3) { transform: rotate(-45deg) translate(5px,-5px); }

.nav-mobile-menu {
    display: none;
    flex-direction: column;
    background: rgba(250,247,242,.98);
    backdrop-filter: blur(16px);
    padding: 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height .3s ease, padding .3s ease;
    border-top: 1px solid rgba(201,169,110,.2);
}
.nav-mobile-menu.open {
    max-height: 300px;
    padding: 16px 0;
}
.nav-mobile-menu a {
    padding: 12px 32px;
    font-size: 0.9rem;
    color: var(--text2);
    border-bottom: 1px solid var(--border);
    transition: background .2s ease, color .2s ease;
}
.nav-mobile-menu a:hover {
    background: var(--cream2);
    color: var(--ink);
}
.nav-mobile-menu a:last-child { border-bottom: none; }

/* ══════════════════════════════
   BUTTONS
══════════════════════════════ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 13px 28px;
    border: none;
    border-radius: var(--r);
    font-size: 0.82rem;
    font-weight: 500;
    letter-spacing: .06em;
    transition: all var(--trans);
    cursor: pointer;
}
.btn-dark {
    background: var(--ink);
    color: var(--cream);
}
.btn-dark:hover { background: var(--ink2); transform: translateY(-1px); box-shadow: var(--sh); }

.btn-gold {
    background: var(--gold);
    color: var(--ink);
}
.btn-gold:hover { background: var(--gold2); transform: translateY(-1px); }

.btn-outline {
    background: transparent;
    color: var(--ink);
    border: 1px solid var(--border);
}
.btn-outline:hover { border-color: var(--ink); background: var(--cream2); }

.btn:disabled { opacity: .5; cursor: not-allowed; transform: none !important; }

/* ══════════════════════════════
   PRODUCT CARDS
══════════════════════════════ */
.product-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--r-lg);
    overflow: hidden;
    transition: all var(--trans);
    cursor: pointer;
    display: flex;
    flex-direction: column;
}
.product-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--sh-lg);
    border-color: var(--cream3);
}

.product-card-img {
    aspect-ratio: 3/4;
    overflow: hidden;
    background: var(--cream2);
    position: relative;
}
.product-card-img img {
    width: 100%; height: 100%;
    object-fit: cover;
    transition: transform .5s ease;
}
.product-card:hover .product-card-img img { transform: scale(1.06); }

.product-card-body {
    padding: 18px 20px 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}
.product-card-tags {
    display: flex; gap: 6px; flex-wrap: wrap;
    margin-bottom: 10px;
}
.tag-sm {
    font-size: 0.65rem;
    font-weight: 500;
    letter-spacing: .08em;
    text-transform: uppercase;
    padding: 3px 9px;
    border-radius: 999px;
    border: 1px solid var(--border);
    color: var(--text2);
    background: var(--cream);
}
.tag-gold { background: rgba(201,169,110,.1); color: var(--gold3); border-color: rgba(201,169,110,.3); }

.product-card-name {
    font-family: 'Playfair Display', serif;
    font-size: 1.2rem;
    margin-bottom: 6px;
    line-height: 1.3;
}
.product-card-price {
    font-size: 0.85rem;
    color: var(--text2);
    margin-bottom: 14px;
}
.product-card-price strong { color: var(--text); font-weight: 500; }

.product-card-btn {
    margin-top: auto;
    padding: 10px;
    background: var(--cream2);
    border: 1px solid var(--border);
    border-radius: var(--r);
    font-size: 0.78rem;
    font-weight: 500;
    color: var(--ink);
    letter-spacing: .04em;
    transition: all var(--trans);
    text-align: center;
}
.product-card-btn:hover { background: var(--ink); color: var(--cream); border-color: var(--ink); }

/* ══════════════════════════════
   FOOTER
══════════════════════════════ */
.site-footer {
    background: var(--ink);
    color: rgba(255,255,255,.4);
    padding: 48px 32px 32px;
    text-align: center;
    margin-top: 80px;
}
.site-footer .footer-brand {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    color: var(--gold);
    margin-bottom: 12px;
}
.site-footer p { 
    font-size: 0.8rem; 
    line-height: 1.8; 
}
.site-footer a { 
    color: rgba(255,255,255,.5); 
    transition: color var(--trans); 
}
.site-footer a:hover { 
    color: var(--gold); 
}

.footer-contact {
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,.1);
}
.footer-contact-label {
    font-size: 0.7rem;
    letter-spacing: .15em;
    text-transform: uppercase;
    color: rgba(255,255,255,.3);
    margin-bottom: 10px;
}
.footer-contact-info {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 0.78rem;
}
.footer-contact-info a {
    color: rgba(255,255,255,.5);
    transition: color var(--trans);
    display: inline-flex;
    align-items: center;
    gap: 6px;
    justify-content: center;
}
.footer-contact-info a:hover {
    color: var(--gold);
}
.footer-contact-info svg {
    width: 14px;
    height: 14px;
    opacity: 0.6;
}

/* ══════════════════════════════
   UTILITIES
══════════════════════════════ */
.container { max-width: 1280px; margin: 0 auto; padding: 0 32px; }
.pt-nav { padding-top: 70px; }

.spinner-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 80px;
    color: var(--text3);
    flex-direction: column;
    gap: 16px;
}
.spinner {
    width: 36px; height: 36px;
    border: 2px solid var(--border);
    border-top-color: var(--gold);
    border-radius: 50%;
    animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Toast */
.toast {
    position: fixed;
    bottom: 32px; right: 32px;
    background: var(--ink);
    color: var(--cream);
    padding: 14px 22px;
    border-radius: var(--r);
    font-size: 0.85rem;
    z-index: 9999;
    transform: translateY(20px);
    opacity: 0;
    transition: all .3s ease;
    pointer-events: none;
    max-width: 320px;
    border-left: 3px solid var(--gold);
}
.toast.show { transform: translateY(0); opacity: 1; }

/* ══════════════════════════════
   RESPONSIVE
══════════════════════════════ */
@media (max-width: 768px) {
    .nav-links { display: none; }
    .nav-hamburger { display: flex; }
    .nav-mobile-menu { display: flex; }
    .container { padding: 0 20px; }
    .nav-brand-logo {
        height: 36px;
    }
}

.nav-inner {
    padding-top: 40px;
    padding-bottom: 40px;
}