@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;600;700&family=Inter:wght@400;500;600&display=swap');

:root {
    --primary: #b5651d;
    --primary-dark: #8b4513;
    --accent: #d4a84b;
    --bg: #fdfaf6;
    --card: #ffffff;
    --text: #2c1a0e;
    --muted: #7a6552;
    --danger: #c0392b;
    --success: #1e874b;
    --border: #e8ddd0;
    --hero-bg: #f5ede0;
}

* { box-sizing: border-box; }
body {
    margin: 0;
    font-family: 'Inter', 'Segoe UI', Helvetica, Arial, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
}
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { font-family: 'Playfair Display', Georgia, serif; }

/* Announcement bar */
.announcement-bar {
    background: var(--primary);
    color: white;
    text-align: center;
    padding: .45rem 1rem;
    font-size: .82rem;
    letter-spacing: .03em;
}

/* Navbar */
.navbar {
    background: var(--card);
    border-bottom: 1px solid var(--border);
    position: sticky; top: 0; z-index: 100;
}
.nav-container {
    max-width: 1200px; margin: 0 auto; padding: .85rem 1.5rem;
    display: flex; justify-content: space-between; align-items: center;
}
.brand {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem; font-weight: 700; color: var(--text);
    letter-spacing: -.01em;
}
.brand span { color: var(--primary); }
.nav-links { display: flex; gap: 1.4rem; align-items: center; }
.nav-links a, .nav-links .link-btn {
    color: var(--text); font-weight: 500; font-size: .9rem;
    letter-spacing: .02em; text-transform: uppercase;
    background: none; border: none; cursor: pointer; font-family: inherit;
}
.nav-links a:hover { color: var(--primary); text-decoration: none; }
.nav-cart {
    position: relative; display: inline-flex; align-items: center; gap: .3rem;
}
.badge {
    background: var(--primary); color: white; border-radius: 999px;
    padding: 0 7px; font-size: .75rem; font-weight: 600;
}

/* Hero */
.hero {
    background: var(--hero-bg);
    padding: 5rem 1.5rem;
    text-align: center;
    border-bottom: 1px solid var(--border);
}
.hero-inner { max-width: 700px; margin: 0 auto; }
.hero-tag {
    display: inline-block;
    font-size: .78rem; letter-spacing: .15em; text-transform: uppercase;
    color: var(--primary); font-weight: 600; margin-bottom: 1rem;
}
.hero h1 {
    font-size: 3rem; margin: 0 0 1rem; line-height: 1.2;
    color: var(--text);
}
.hero p {
    font-size: 1.1rem; color: var(--muted); margin-bottom: 2rem;
}
.hero-actions { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

/* Container */
.container { max-width: 1200px; margin: 0 auto; padding: 2rem 1.5rem; }

/* Section headings */
.section-header {
    text-align: center; margin-bottom: 2.5rem;
}
.section-header h2 { font-size: 2rem; margin: 0 0 .5rem; }
.section-header p { color: var(--muted); margin: 0; }
.section-divider {
    width: 50px; height: 3px; background: var(--primary);
    margin: .75rem auto 0;
}

/* Buttons */
.btn {
    display: inline-block; padding: .65rem 1.5rem;
    background: var(--primary); color: white;
    border: 2px solid var(--primary); border-radius: 3px;
    font-weight: 600; cursor: pointer; font-size: .9rem;
    letter-spacing: .04em; text-transform: uppercase;
    font-family: 'Inter', sans-serif;
    text-decoration: none; transition: all .2s;
}
.btn:hover { background: var(--primary-dark); border-color: var(--primary-dark); color: white; text-decoration: none; }
.btn.outline {
    background: transparent; color: var(--primary);
}
.btn.outline:hover { background: var(--primary); color: white; }
.btn.primary { background: var(--primary); color: white; }
.btn.primary:hover { background: var(--primary-dark); }
.btn.small { padding: .35rem .8rem; font-size: .8rem; }
.btn.danger { background: white; color: var(--danger); border-color: var(--danger); }
.btn.danger:hover { background: var(--danger); color: white; }

/* Category Grid */
.category-section { padding: 3rem 1.5rem; background: white; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.category-grid {
    max-width: 1200px; margin: 0 auto;
    display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem; margin-top: 2rem;
}
.category-card {
    background: var(--hero-bg); border-radius: 8px;
    padding: 2rem 1rem; text-align: center;
    border: 1px solid var(--border); transition: all .2s;
    text-decoration: none; color: var(--text);
}
.category-card:hover {
    background: var(--primary); color: white;
    text-decoration: none; transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(181,101,29,.2);
}
.category-card .cat-icon { font-size: 2.2rem; display: block; margin-bottom: .75rem; }
.category-card h3 { margin: 0 0 .25rem; font-size: 1.1rem; }
.category-card p { margin: 0; font-size: .85rem; opacity: .75; }

/* Cards / Grid */
.grid {
    display: grid; gap: 1.5rem;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    margin-top: 1.5rem;
}
.card {
    background: var(--card); border-radius: 4px; overflow: hidden;
    border: 1px solid var(--border); transition: all .2s;
}
.card:hover { transform: translateY(-4px); box-shadow: 0 10px 30px rgba(0,0,0,.1); }
.card a { color: inherit; text-decoration: none; display: block; }
.card img { width: 100%; aspect-ratio: 4/3; object-fit: cover; background: #ede8e0; }
.card-body { padding: 1.1rem; }
.card-body h3 { margin: 0 0 .25rem; font-size: 1.05rem; }
.artist { color: var(--muted); font-size: .85rem; margin: 0 0 .5rem; }
.price { color: var(--primary); font-weight: 700; font-size: 1.1rem; margin: 0; font-family: 'Playfair Display', serif; }
.stock { color: var(--success); font-size: .82rem; }
.out { color: var(--danger); font-weight: 600; font-size: .85rem; }

/* About section */
.about-section {
    background: var(--hero-bg);
    padding: 4rem 1.5rem;
    border-top: 1px solid var(--border);
}
.about-inner {
    max-width: 1200px; margin: 0 auto;
    display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: center;
}
.about-text h2 { font-size: 2rem; margin: 0 0 1rem; }
.about-text p { color: var(--muted); margin: 0 0 1rem; }
.about-tag {
    font-size: .78rem; letter-spacing: .15em; text-transform: uppercase;
    color: var(--primary); font-weight: 600; margin-bottom: .75rem; display: block;
}
.about-image-placeholder {
    background: var(--border); border-radius: 8px;
    aspect-ratio: 4/3; display: flex; align-items: center;
    justify-content: center; color: var(--muted); font-size: 3rem;
}
@media (max-width: 768px) { .about-inner { grid-template-columns: 1fr; gap: 2rem; } }

/* Newsletter */
.newsletter-section {
    background: var(--primary);
    color: white; padding: 3.5rem 1.5rem; text-align: center;
}
.newsletter-section h2 { color: white; margin: 0 0 .5rem; font-size: 1.8rem; }
.newsletter-section p { opacity: .9; margin: 0 0 1.5rem; }
.newsletter-form {
    display: flex; gap: .75rem; max-width: 440px; margin: 0 auto;
}
.newsletter-form input {
    flex: 1; padding: .65rem 1rem; border: none; border-radius: 3px;
    font-size: .95rem; font-family: inherit;
}
.newsletter-form .btn {
    background: var(--accent); border-color: var(--accent); color: white; white-space: nowrap;
}
.newsletter-form .btn:hover { background: #b8892e; border-color: #b8892e; }
@media (max-width: 500px) { .newsletter-form { flex-direction: column; } }

/* Detail */
.detail {
    display: grid; grid-template-columns: 1fr 1fr; gap: 3rem;
}
.detail-image img { width: 100%; border-radius: 6px; }
@media (max-width: 700px) { .detail { grid-template-columns: 1fr; } }

/* Tables */
.cart-table, .admin-table {
    width: 100%; border-collapse: collapse; background: var(--card);
    border-radius: 6px; overflow: hidden; margin-top: 1rem;
    border: 1px solid var(--border);
}
.cart-table th, .cart-table td, .admin-table th, .admin-table td {
    padding: .85rem 1rem; border-bottom: 1px solid var(--border); vertical-align: middle;
}
.cart-table th, .admin-table th { background: var(--hero-bg); text-align: left; font-size: .82rem; text-transform: uppercase; letter-spacing: .05em; }
.thumb { width: 50px; height: 50px; object-fit: cover; border-radius: 4px; vertical-align: middle; margin-right: .5rem; }
.thumb-lg { max-width: 200px; border-radius: 6px; }
.right { text-align: right; }
.cart-actions { display: flex; justify-content: flex-end; gap: .75rem; margin-top: 1rem; }

/* Forms */
form label { display: block; margin: .75rem 0; font-weight: 500; font-size: .9rem; }
form input, form textarea, form select {
    display: block; width: 100%; padding: .55rem .75rem; border: 1px solid var(--border);
    border-radius: 4px; font-size: 1rem; margin-top: .25rem;
    font-family: inherit; background: white;
}
form input:focus, form textarea:focus, form select:focus {
    outline: none; border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(181,101,29,.1);
}
.form-stack { max-width: 600px; }
.row-gap { display: flex; gap: .75rem; }
.row-between { display: flex; justify-content: space-between; align-items: center; }

/* Checkout */
.checkout-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 2rem; }
.summary { background: var(--card); padding: 1.5rem; border-radius: 6px; border: 1px solid var(--border); }
.summary ul { list-style: none; padding: 0; }
.summary li { display: flex; justify-content: space-between; padding: .4rem 0; border-bottom: 1px solid var(--border); }
.summary .total { margin-top: 1rem; font-size: 1.2rem; display: flex; justify-content: space-between; font-weight: 700; }
@media (max-width: 700px) { .checkout-grid { grid-template-columns: 1fr; } }

/* Auth */
.auth { max-width: 440px; margin: 2rem auto; background: var(--card); padding: 2rem; border-radius: 8px; border: 1px solid var(--border); }
.auth h1 { text-align: center; margin: 0 0 1.5rem; }

/* Alerts */
.error { background: #fde2de; color: var(--danger); padding: .75rem 1rem; border-radius: 4px; margin: 1rem 0; font-size: .9rem; }
.success { background: #dff7e8; color: var(--success); padding: .75rem 1rem; border-radius: 4px; margin: 1rem 0; font-size: .9rem; }

/* Search */
.search { display: flex; gap: .5rem; max-width: 500px; margin: 1rem 0; }
.search input { flex: 1; }

/* Category Tabs */
.category-tabs { display: flex; gap: .5rem; flex-wrap: wrap; margin: 1.5rem 0; border-bottom: 2px solid var(--border); padding-bottom: .75rem; }
.tab-btn {
    padding: .4rem 1.1rem; border-radius: 999px;
    border: 1px solid var(--border); color: var(--text);
    font-size: .85rem; font-weight: 500; text-decoration: none;
    transition: all .2s;
}
.tab-btn:hover { border-color: var(--primary); color: var(--primary); text-decoration: none; }
.tab-btn.active { background: var(--primary); color: white; border-color: var(--primary); }

/* Admin */
.admin-stats { display: flex; gap: 1rem; margin: 1rem 0; flex-wrap: wrap; }
.stat {
    background: var(--card); padding: 1.5rem; border-radius: 8px;
    text-align: center; flex: 1; min-width: 130px;
    border: 1px solid var(--border);
}
.stat span { font-size: 2.2rem; font-weight: 700; color: var(--primary); font-family: 'Playfair Display', serif; display: block; }
.stat small { color: var(--muted); font-size: .82rem; }
.admin-nav { display: flex; gap: .75rem; margin: 1rem 0 2rem; flex-wrap: wrap; }

/* Footer */
.footer {
    background: var(--text);
    color: #c8b9a8;
    padding: 3rem 1.5rem 1.5rem;
    margin-top: 0;
}
.footer-grid {
    max-width: 1200px; margin: 0 auto;
    display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 2rem;
    padding-bottom: 2rem; border-bottom: 1px solid rgba(255,255,255,.1);
}
.footer-brand { font-family: 'Playfair Display', serif; font-size: 1.3rem; color: white; margin: 0 0 .75rem; }
.footer-brand span { color: var(--accent); }
.footer-desc { font-size: .88rem; line-height: 1.7; margin: 0; }
.footer h4 { color: white; font-size: .82rem; letter-spacing: .1em; text-transform: uppercase; margin: 0 0 1rem; font-family: 'Inter', sans-serif; }
.footer ul { list-style: none; padding: 0; margin: 0; }
.footer ul li { margin-bottom: .5rem; }
.footer ul a { color: #c8b9a8; font-size: .88rem; }
.footer ul a:hover { color: white; text-decoration: none; }
.footer-bottom {
    max-width: 1200px; margin: 1.5rem auto 0;
    display: flex; justify-content: space-between; align-items: center;
    font-size: .82rem; flex-wrap: wrap; gap: .5rem;
}
@media (max-width: 768px) { .footer-grid { grid-template-columns: 1fr; } .footer-bottom { flex-direction: column; } }

.small { font-size: .85rem; color: var(--muted); }
