/* ==========================================
   J.A. CRÉA — Premium Artisan E-Commerce
   Color palette from logo: gold/bronze/cream
   ========================================== */

:root {
    --gold: #C9A96E;
    --gold-light: #D4B87A;
    --gold-dark: #A88B4A;
    --bronze: #8B7355;
    --cream: #FAF7F2;
    --cream-dark: #F0EBE3;
    --warm-white: #FDFCFA;
    --text-dark: #2C1810;
    --text-medium: #5C4A3A;
    --text-light: #8B7D72;
    --border: #E8E0D6;
    --shadow-sm: 0 2px 8px rgba(44, 24, 16, 0.06);
    --shadow-md: 0 4px 20px rgba(44, 24, 16, 0.08);
    --shadow-lg: 0 8px 40px rgba(44, 24, 16, 0.12);
    --radius: 12px;
    --radius-sm: 8px;
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
    font-family: 'Montserrat', -apple-system, BlinkMacSystemFont, sans-serif;
    font-weight: 400;
    color: var(--text-dark);
    background: var(--warm-white);
    line-height: 1.7;
    font-size: 15px;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5 {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-weight: 600;
    line-height: 1.2;
    color: var(--text-dark);
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; display: block; }

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ── Buttons ── */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 28px;
    border-radius: var(--radius-sm);
    font-family: 'Montserrat', sans-serif;
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    border: none;
    cursor: pointer;
    transition: var(--transition);
}

.btn-primary {
    background: var(--gold);
    color: #fff;
}
.btn-primary:hover {
    background: var(--gold-dark);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.btn-outline {
    background: transparent;
    border: 1.5px solid var(--gold);
    color: var(--gold-dark);
}
.btn-outline:hover {
    background: var(--gold);
    color: #fff;
}

.btn-lg { padding: 14px 36px; font-size: 14px; }
.btn-full { width: 100%; justify-content: center; }

/* ── Header ── */
.site-header {
    position: sticky;
    top: 0;
    background: var(--cream);
    border-bottom: 1px solid var(--border);
    z-index: 1000;
    padding: 0 0;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 72px;
}

.logo-link {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-img {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
}

.logo-text {
    display: flex;
    flex-direction: column;
}

.logo-name {
    font-family: 'Cormorant Garamond', serif;
    font-size: 22px;
    font-weight: 700;
    color: var(--text-dark);
    line-height: 1.1;
}

.logo-tagline {
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--gold);
    font-weight: 500;
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-link {
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-medium);
    border-radius: var(--radius-sm);
    transition: var(--transition);
}
.nav-link:hover {
    color: var(--gold-dark);
    background: var(--cream);
}

.cart-link {
    position: relative;
}

.cart-count {
    position: absolute;
    top: 2px;
    right: 4px;
    background: var(--gold);
    color: #fff;
    font-size: 10px;
    font-weight: 600;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
}
.menu-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text-dark);
    transition: var(--transition);
}

/* ── Hero ── */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #1E1610;
    overflow: hidden;
}

/* Background photo with dark overlay fade */
.hero-bg-photo {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.hero-bg-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.45;
    filter: saturate(0.5) brightness(0.7);
}

/* Soft vignette edges */
.hero-bg-photo::after {
    content: '';
    position: absolute;
    inset: 0;
    background:
        linear-gradient(to bottom, rgba(30, 22, 16, 0.4) 0%, transparent 25%, transparent 75%, rgba(30, 22, 16, 0.8) 100%);
}

.hero-content {
    position: relative;
    text-align: center;
    padding: 60px 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    z-index: 1;
}

.hero-eyebrow {
    font-family: 'Montserrat', sans-serif;
    font-size: 11px;
    font-weight: 400;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: rgba(201, 169, 110, 0.5);
    margin-bottom: 20px;
    animation: heroFadeIn 0.8s ease-out 0.2s both;
}

.hero-title {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: clamp(48px, 8vw, 88px);
    font-weight: 400;
    font-style: italic;
    color: var(--cream);
    letter-spacing: 2px;
    margin-bottom: 32px;
    line-height: 1;
    animation: heroFadeIn 0.8s ease-out 0.4s both;
}

.hero-separator {
    width: 50px;
    height: 1px;
    background: var(--gold);
    opacity: 0.3;
    margin-bottom: 28px;
    animation: heroFadeIn 0.8s ease-out 0.6s both;
}

.hero-subtitle {
    font-size: 13px;
    color: rgba(250, 247, 242, 0.35);
    max-width: 420px;
    margin: 0 auto 48px;
    font-weight: 300;
    line-height: 1.8;
    letter-spacing: 0.5px;
    animation: heroFadeIn 0.8s ease-out 0.8s both;
}

.btn-hero {
    display: inline-flex;
    align-items: center;
    padding: 15px 44px;
    border: 1px solid rgba(201, 169, 110, 0.25);
    color: var(--gold);
    font-family: 'Montserrat', sans-serif;
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 2.5px;
    text-transform: uppercase;
    background: transparent;
    border-radius: 0;
    cursor: pointer;
    transition: all 0.4s ease;
    animation: heroFadeIn 0.8s ease-out 1s both;
}

.btn-hero:hover {
    background: var(--gold);
    border-color: var(--gold);
    color: #110D09;
    letter-spacing: 3px;
}

@keyframes heroFadeIn {
    0% { opacity: 0; transform: translateY(12px); }
    100% { opacity: 1; transform: translateY(0); }
}

@keyframes heroBgIn {
    0% { opacity: 0; transform: translate(-50%, -50%) scale(0.9); }
    100% { opacity: 0.12; transform: translate(-50%, -50%) scale(1); }
}

/* ── Sections ── */
.section {
    padding: 80px 0;
}

.section-title {
    font-size: 36px;
    text-align: center;
    margin-bottom: 8px;
}

.section-subtitle {
    text-align: center;
    color: var(--text-light);
    font-size: 15px;
    margin-bottom: 48px;
}

.section-cta {
    text-align: center;
    margin-top: 48px;
}

/* ── Categories ── */
.categories-section {
    background: var(--cream);
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
}

.category-card {
    background: var(--warm-white);
    border-radius: var(--radius);
    padding: 40px 28px;
    text-align: center;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    border: 1px solid transparent;
}
.category-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
    border-color: var(--gold-light);
}

.category-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 20px;
    color: var(--gold);
}
.category-icon svg { width: 100%; height: 100%; }

.category-card h3 {
    font-size: 22px;
    margin-bottom: 8px;
}

.category-card p {
    font-size: 13px;
    color: var(--text-light);
    line-height: 1.6;
}

/* ── Product Cards ── */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 28px;
}

.product-card {
    background: #fff;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    border: 1px solid var(--border);
}
.product-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.product-image {
    position: relative;
    aspect-ratio: 1;
    background: var(--cream);
    overflow: hidden;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}
.product-card:hover .product-image img {
    transform: scale(1.05);
}

.product-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    color: var(--border);
}

.product-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: var(--gold);
    color: #fff;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge-sold {
    background: var(--text-medium);
}

.product-info {
    padding: 20px;
}

.product-category {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--gold);
    font-weight: 500;
}

.product-name {
    font-size: 18px;
    margin: 6px 0 8px;
    font-weight: 600;
}

.product-price {
    font-family: 'Montserrat', sans-serif;
    font-size: 16px;
    font-weight: 600;
    color: var(--text-dark);
}

/* ── Page Header ── */
.page-header {
    background: var(--cream);
    padding: 48px 0;
    text-align: center;
    border-bottom: 1px solid var(--border);
}

.page-header h1 {
    font-size: 36px;
    margin-bottom: 8px;
}

.page-header p {
    color: var(--text-light);
    font-size: 15px;
}

/* ── Category Filters ── */
.category-filters {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
    margin-bottom: 40px;
}

.filter-btn {
    padding: 8px 20px;
    border-radius: 24px;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-medium);
    border: 1.5px solid var(--border);
    transition: var(--transition);
}
.filter-btn:hover, .filter-btn.active {
    background: var(--gold);
    color: #fff;
    border-color: var(--gold);
}

/* ── Product Detail ── */
.product-detail { padding-top: 40px; }

.breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--text-light);
    margin-bottom: 32px;
}
.breadcrumb a:hover { color: var(--gold); }
.breadcrumb span { color: var(--text-light); }

.product-detail-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    align-items: start;
}

.gallery-main {
    border-radius: var(--radius);
    overflow: hidden;
    background: var(--cream);
    aspect-ratio: 1;
}
.gallery-main img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-thumbs {
    display: flex;
    gap: 12px;
    margin-top: 12px;
}
.gallery-thumbs .thumb {
    width: 80px;
    height: 80px;
    border-radius: var(--radius-sm);
    object-fit: cover;
    cursor: pointer;
    opacity: 0.6;
    border: 2px solid transparent;
    transition: var(--transition);
}
.gallery-thumbs .thumb.active,
.gallery-thumbs .thumb:hover {
    opacity: 1;
    border-color: var(--gold);
}

.product-detail-info h1 {
    font-size: 32px;
    margin: 8px 0 16px;
}

.product-price-lg {
    font-size: 28px;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 24px;
    font-family: 'Montserrat', sans-serif;
}

.product-description {
    color: var(--text-medium);
    line-height: 1.8;
    margin-bottom: 24px;
    font-size: 14px;
}

.product-stock {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 20px;
}
.in-stock { color: #4A8C5C; }
.out-of-stock { color: #B85C5C; }

.product-actions {
    display: flex;
    gap: 16px;
    align-items: center;
    margin-bottom: 32px;
}

.quantity-selector {
    display: flex;
    align-items: center;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    overflow: hidden;
}
.qty-btn {
    width: 42px;
    height: 42px;
    border: none;
    background: var(--cream);
    font-size: 18px;
    cursor: pointer;
    transition: var(--transition);
    color: var(--text-dark);
}
.qty-btn:hover { background: var(--cream-dark); }
.quantity-selector input {
    width: 48px;
    height: 42px;
    text-align: center;
    border: none;
    font-size: 15px;
    font-family: 'Montserrat', sans-serif;
    font-weight: 500;
    background: #fff;
}

.add-to-cart {
    flex: 1;
}

.product-meta {
    border-top: 1px solid var(--border);
    padding-top: 24px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.meta-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
    color: var(--text-medium);
}
.meta-item svg { color: var(--gold); flex-shrink: 0; }

.related-products {
    margin-top: 80px;
    padding-top: 48px;
    border-top: 1px solid var(--border);
}

/* ── Cart ── */
.cart-grid {
    display: grid;
    grid-template-columns: 1fr 400px;
    gap: 40px;
    align-items: start;
}

.cart-item {
    display: flex;
    gap: 20px;
    padding: 20px 0;
    border-bottom: 1px solid var(--border);
    align-items: center;
}

.cart-item-image {
    width: 100px;
    height: 100px;
    border-radius: var(--radius-sm);
    object-fit: cover;
    background: var(--cream);
    flex-shrink: 0;
}

.cart-item-info { flex: 1; }
.cart-item-info h3 {
    font-size: 16px;
    margin-bottom: 4px;
}
.cart-item-price {
    font-weight: 600;
    color: var(--text-dark);
}

.cart-item-qty {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 8px;
}
.cart-item-qty button {
    width: 28px;
    height: 28px;
    border: 1px solid var(--border);
    border-radius: 4px;
    background: #fff;
    cursor: pointer;
    font-size: 14px;
    transition: var(--transition);
}
.cart-item-qty button:hover { background: var(--cream); }
.cart-item-qty span { font-weight: 500; min-width: 20px; text-align: center; }

.cart-item-remove {
    color: var(--text-light);
    cursor: pointer;
    padding: 8px;
    transition: var(--transition);
    background: none;
    border: none;
    font-size: 13px;
}
.cart-item-remove:hover { color: #B85C5C; }

.cart-summary {
    background: var(--cream);
    border-radius: var(--radius);
    padding: 28px;
    position: sticky;
    top: 96px;
}
.cart-summary h3 {
    font-size: 22px;
    margin-bottom: 20px;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    font-size: 14px;
    color: var(--text-medium);
}
.summary-row.total {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-dark);
    border-top: 2px solid var(--border);
    margin-top: 8px;
    padding-top: 16px;
}

.checkout-form {
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid var(--border);
}
.checkout-form h4 {
    font-size: 16px;
    margin-bottom: 16px;
}
.checkout-form input {
    width: 100%;
    padding: 10px 14px;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    font-family: 'Montserrat', sans-serif;
    font-size: 14px;
    margin-bottom: 10px;
    transition: var(--transition);
    background: #fff;
}
.checkout-form input:focus {
    outline: none;
    border-color: var(--gold);
}
.checkout-form .form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.secure-note {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-top: 12px;
    font-size: 12px;
    color: var(--text-light);
}

/* ── Story Banner ── */
.story-banner {
    background: #2A2018;
    padding: 80px 0;
    text-align: center;
}

.story-content h2 {
    font-size: 36px;
    color: var(--cream);
    margin-bottom: 16px;
}

.story-content p {
    color: rgba(250, 247, 242, 0.7);
    max-width: 600px;
    margin: 0 auto 28px;
    font-size: 15px;
    line-height: 1.8;
}

/* ── About ── */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: start;
}

.about-text h2 {
    font-size: 30px;
    margin-bottom: 20px;
}

.about-text p {
    color: var(--text-medium);
    margin-bottom: 16px;
    line-height: 1.8;
}

.about-values {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.value-card {
    background: var(--cream);
    border-radius: var(--radius);
    padding: 28px;
    text-align: center;
}
.value-card svg {
    color: var(--gold);
    margin-bottom: 12px;
}
.value-card h3 {
    font-size: 18px;
    margin-bottom: 8px;
}
.value-card p {
    font-size: 13px;
    color: var(--text-light);
    line-height: 1.6;
}

/* ── Contact ── */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 360px;
    gap: 48px;
    align-items: start;
}

.contact-form .form-group {
    margin-bottom: 16px;
}
.contact-form label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    margin-bottom: 6px;
    color: var(--text-medium);
}
.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    font-family: 'Montserrat', sans-serif;
    font-size: 14px;
    transition: var(--transition);
    background: #fff;
}
.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--gold);
}
.contact-form textarea { resize: vertical; }

.form-success {
    background: #E8F5E9;
    color: #2E7D32;
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    margin-top: 16px;
    font-size: 14px;
}

.form-error {
    background: #FDE8E8;
    color: #B85C5C;
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    margin-top: 16px;
    font-size: 14px;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.info-card {
    background: var(--cream);
    border-radius: var(--radius);
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 16px;
}
.info-card svg { color: var(--gold); flex-shrink: 0; }
.info-card h4 {
    font-size: 14px;
    margin-bottom: 2px;
    font-family: 'Montserrat', sans-serif;
}
.info-card p {
    font-size: 13px;
    color: var(--text-light);
}

/* ── Success/Cancel Pages ── */
.success-page {
    text-align: center;
    padding: 60px 0;
}
.success-icon svg { color: #4A8C5C; margin: 0 auto 20px; }
.cancel-icon svg { color: #B85C5C; margin: 0 auto 20px; }
.success-page h1 {
    font-size: 32px;
    margin-bottom: 12px;
}
.success-page p {
    color: var(--text-medium);
    margin-bottom: 8px;
}
.success-page .btn { margin-top: 24px; }

/* ── Empty State ── */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-light);
}
.empty-state svg { margin: 0 auto 16px; }
.empty-state h3 { font-size: 22px; margin-bottom: 8px; }
.empty-state .btn { margin-top: 20px; }

/* ── Footer ── */
.site-footer {
    background: var(--text-dark);
    color: rgba(250, 247, 242, 0.7);
    padding: 60px 0 0;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: 40px;
    padding-bottom: 40px;
}

.footer-logo {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    margin-bottom: 12px;
}

.footer-desc {
    font-size: 13px;
    line-height: 1.7;
}

.footer-col h4 {
    font-family: 'Montserrat', sans-serif;
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--cream);
    margin-bottom: 16px;
}

.footer-col a {
    display: block;
    font-size: 13px;
    padding: 4px 0;
    transition: var(--transition);
}
.footer-col a:hover { color: var(--gold-light); }

.footer-social {
    display: flex;
    gap: 12px;
    margin-top: 8px;
}
.footer-social a {
    padding: 0;
    opacity: 0.7;
    transition: var(--transition);
}
.footer-social a:hover { opacity: 1; color: var(--gold-light); }

.footer-bottom {
    border-top: 1px solid rgba(250, 247, 242, 0.1);
    padding: 20px 0;
    text-align: center;
    font-size: 12px;
}

/* ── Toast ── */
.toast {
    position: fixed;
    bottom: 24px;
    right: 24px;
    background: var(--text-dark);
    color: #fff;
    padding: 14px 24px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-weight: 500;
    box-shadow: var(--shadow-lg);
    z-index: 9999;
    transform: translateY(100px);
    opacity: 0;
    transition: var(--transition);
}
.toast.show {
    transform: translateY(0);
    opacity: 1;
}

/* ── Responsive ── */
@media (max-width: 768px) {
    .main-nav {
        position: fixed;
        top: 72px;
        left: 0;
        right: 0;
        background: var(--warm-white);
        flex-direction: column;
        padding: 20px;
        border-bottom: 1px solid var(--border);
        transform: translateY(-120%);
        transition: var(--transition);
        box-shadow: var(--shadow-lg);
    }
    .main-nav.open { transform: translateY(0); }

    .menu-toggle { display: flex; }

    .hero { min-height: 70vh; }
    .hero-title { font-size: 36px; }

    .product-detail-grid { grid-template-columns: 1fr; gap: 28px; }
    .cart-grid { grid-template-columns: 1fr; }
    .about-grid { grid-template-columns: 1fr; }
    .contact-grid { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
    .categories-grid { grid-template-columns: 1fr 1fr; }
    .products-grid { grid-template-columns: 1fr 1fr; }
    .about-values { grid-template-columns: 1fr; }

    .product-actions { flex-direction: column; }
    .add-to-cart { width: 100%; }
}

@media (max-width: 480px) {
    .products-grid { grid-template-columns: 1fr; }
    .categories-grid { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; }
    .checkout-form .form-row { grid-template-columns: 1fr; }
}
