:root {
    --bg: #faf7f2;
    --bg-alt: #f1ece3;
    --ink: #1f1b16;
    --ink-soft: #4a433b;
    --muted: #7a7369;
    --line: #e4ddd0;
    --accent: #8a3b2f;
    --accent-hover: #6d2e24;
    --max-width: 1200px;
    --radius: 2px;
    --shadow: 0 1px 2px rgba(31, 27, 22, 0.06), 0 8px 24px rgba(31, 27, 22, 0.06);
    --serif: Georgia, "Iowan Old Style", "Apple Garamond", "Times New Roman", serif;
    --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    font-family: var(--sans);
    font-size: 17px;
    line-height: 1.6;
    color: var(--ink);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img { max-width: 100%; display: block; }

a { color: var(--accent); text-decoration: none; }
a:hover, a:focus { color: var(--accent-hover); text-decoration: underline; }

h1, h2, h3 {
    font-family: var(--serif);
    font-weight: 500;
    line-height: 1.2;
    margin: 0 0 0.6em;
    color: var(--ink);
    letter-spacing: -0.01em;
}

h1 { font-size: clamp(2rem, 5vw, 3.4rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); }
h3 { font-size: 1.15rem; }

p { margin: 0 0 1em; }

.container {
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 1.25rem;
}

.skip-link {
    position: absolute;
    left: -9999px;
    top: 0;
    background: var(--ink);
    color: #fff;
    padding: 0.75rem 1rem;
    z-index: 1000;
}
.skip-link:focus { left: 1rem; top: 1rem; }

/* Header */
.site-header {
    background: var(--bg);
    border-bottom: 1px solid var(--line);
    position: sticky;
    top: 0;
    z-index: 50;
    backdrop-filter: saturate(180%) blur(6px);
}

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

.brand {
    display: flex;
    flex-direction: column;
    line-height: 1;
    color: var(--ink);
    text-decoration: none;
}
.brand:hover { text-decoration: none; color: var(--ink); }
.brand-name {
    font-family: var(--serif);
    font-size: 1.5rem;
    letter-spacing: 0.02em;
}
.brand-tag {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.18em;
    color: var(--muted);
    margin-top: 0.35rem;
}

.site-nav ul {
    list-style: none;
    display: flex;
    gap: 1.75rem;
    margin: 0;
    padding: 0;
}
.site-nav a {
    color: var(--ink-soft);
    font-size: 0.95rem;
    letter-spacing: 0.02em;
    padding: 0.25rem 0;
    border-bottom: 1px solid transparent;
}
.site-nav a:hover,
.site-nav a[aria-current="page"] {
    color: var(--ink);
    border-bottom-color: var(--accent);
    text-decoration: none;
}

.nav-toggle {
    display: none;
    background: none;
    border: 0;
    padding: 0.5rem;
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
}
.nav-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--ink);
}

/* Hero */
.hero {
    padding: clamp(3rem, 8vw, 6rem) 0 clamp(3rem, 8vw, 6rem);
    background: linear-gradient(180deg, var(--bg) 0%, var(--bg-alt) 100%);
    border-bottom: 1px solid var(--line);
}
.hero-inner { max-width: 820px; }
.hero-title {
    font-size: clamp(2.4rem, 6vw, 4.2rem);
    margin-bottom: 1rem;
}
.hero-lead {
    font-size: 1.2rem;
    color: var(--ink-soft);
    margin-bottom: 2rem;
    max-width: 48ch;
}
.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; }

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.85rem 1.5rem;
    font-size: 0.95rem;
    letter-spacing: 0.03em;
    border: 1px solid transparent;
    border-radius: var(--radius);
    cursor: pointer;
    text-decoration: none;
    transition: background-color 0.15s, color 0.15s, border-color 0.15s;
    text-align: center;
}
.btn-primary {
    background: var(--accent);
    color: #fff;
}
.btn-primary:hover, .btn-primary:focus {
    background: var(--accent-hover);
    color: #fff;
    text-decoration: none;
}
.btn-secondary {
    background: transparent;
    color: var(--ink);
    border-color: var(--ink);
}
.btn-secondary:hover, .btn-secondary:focus {
    background: var(--ink);
    color: #fff;
    text-decoration: none;
}
.btn-block { display: block; width: 100%; }

.link-arrow {
    font-weight: 500;
    letter-spacing: 0.02em;
}

/* Sections */
section { padding: clamp(3rem, 6vw, 5rem) 0; }
.section-title {
    margin-bottom: 2rem;
    text-align: center;
}
.center { text-align: center; }

.page-header {
    padding: clamp(2.5rem, 5vw, 4rem) 0 clamp(1.5rem, 3vw, 2.5rem);
    border-bottom: 1px solid var(--line);
}
.page-header h1 { margin-bottom: 0.5rem; }
.page-lead { color: var(--ink-soft); font-size: 1.1rem; margin: 0; }

/* Grid */
.grid {
    display: grid;
    gap: 2rem;
}
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }

/* Cards */
.card {
    margin: 0;
    background: #fff;
    box-shadow: var(--shadow);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 1px 2px rgba(31, 27, 22, 0.08), 0 16px 32px rgba(31, 27, 22, 0.08);
}
.card-img {
    aspect-ratio: 4 / 5;
    background: var(--bg-alt);
    background-size: cover;
    background-position: center;
}
.card figcaption {
    padding: 1rem 1.15rem 1.25rem;
}
.card figcaption h3 { margin: 0 0 0.25rem; }
.meta {
    color: var(--muted);
    font-size: 0.88rem;
    margin: 0;
    font-style: italic;
}

/* Placeholders (remove once real images are added) */
.placeholder-1 { background: linear-gradient(135deg, #c9a27e 0%, #8a3b2f 100%); }
.placeholder-2 { background: linear-gradient(135deg, #6b8e7f 0%, #2e4a44 100%); }
.placeholder-3 { background: linear-gradient(135deg, #d6b897 0%, #6d5032 100%); }
.placeholder-4 {
    background: linear-gradient(135deg, #e4ddd0 0%, #c9beab 100%);
    aspect-ratio: 3 / 4;
}

/* About teaser */
.about-teaser { background: var(--bg-alt); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.about-teaser-inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
}
.about-text .section-title { text-align: left; }
.about-img {
    width: 100%;
    max-width: 380px;
    height: auto;
    margin-left: auto;
    box-shadow: var(--shadow);
}

/* Bio page */
.bio-inner {
    display: grid;
    grid-template-columns: 1fr 1.3fr;
    gap: 3rem;
    align-items: start;
}
.bio-img {
    width: 100%;
    max-width: 480px;
    height: auto;
    box-shadow: var(--shadow);
}

/* Gallery feature image (above filters) */
.gallery-feature { padding: 2rem 0 0; }
.gallery-feature img {
    width: 100%;
    height: auto;
    max-height: 60vh;
    object-fit: cover;
    box-shadow: var(--shadow);
}
.bio-text .lead { font-size: 1.2rem; color: var(--ink-soft); }

.prose { max-width: 68ch; margin: 0 auto; }
.prose p { font-size: 1.05rem; }

/* Timeline */
.events {
    list-style: none;
    padding: 0;
    max-width: 620px;
    margin: 0 auto;
}
.events li {
    display: grid;
    grid-template-columns: 80px 1fr;
    gap: 1rem;
    padding: 1rem 0;
    border-bottom: 1px solid var(--line);
}
.events .year {
    font-family: var(--serif);
    font-size: 1.2rem;
    color: var(--accent);
}
.events .event { color: var(--ink-soft); }

/* Gallery filters */
.gallery-filters { padding-top: 2rem; padding-bottom: 0; }
.filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
}
.filter {
    background: transparent;
    border: 1px solid var(--line);
    color: var(--ink-soft);
    padding: 0.55rem 1.1rem;
    font-size: 0.9rem;
    cursor: pointer;
    border-radius: var(--radius);
    transition: all 0.15s;
}
.filter:hover { border-color: var(--ink); color: var(--ink); }
.filter.is-active {
    background: var(--ink);
    color: #fff;
    border-color: var(--ink);
}

/* Shop */
.product-card {
    background: #fff;
    box-shadow: var(--shadow);
    display: flex;
    flex-direction: column;
}
.product-body { padding: 1.15rem 1.25rem 1.5rem; }
.product-body h3 { margin-bottom: 0.25rem; }
.price {
    font-family: var(--serif);
    font-size: 1.35rem;
    color: var(--accent);
    margin: 0.75rem 0 1rem;
}

.shop-info {
    margin-top: 3rem;
    padding: 2rem;
    background: var(--bg-alt);
    border: 1px solid var(--line);
}
.shop-info h2 { margin-top: 0; }
.shop-info ul { padding-left: 1.2rem; margin: 0; }
.shop-info li { margin-bottom: 0.5rem; }

/* Contact */
.contact-inner {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 3rem;
    align-items: start;
}
.contact-form .field { margin-bottom: 1.25rem; }
.contact-form label {
    display: block;
    font-size: 0.9rem;
    margin-bottom: 0.35rem;
    color: var(--ink-soft);
    letter-spacing: 0.02em;
}
.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 0.75rem 0.9rem;
    border: 1px solid var(--line);
    background: #fff;
    font-family: inherit;
    font-size: 1rem;
    color: var(--ink);
    border-radius: var(--radius);
}
.contact-form input:focus,
.contact-form textarea:focus {
    outline: 2px solid var(--accent);
    outline-offset: 1px;
    border-color: var(--accent);
}
.contact-form textarea { resize: vertical; }
.field-hidden {
    position: absolute;
    left: -9999px;
    opacity: 0;
    pointer-events: none;
}
.form-note {
    color: var(--muted);
    font-size: 0.85rem;
    margin-top: 1rem;
}
.contact-aside {
    padding: 1.5rem;
    background: var(--bg-alt);
    border: 1px solid var(--line);
}
.contact-aside h2 { margin-top: 0; font-size: 1.2rem; }
.muted { color: var(--muted); font-size: 0.9rem; }

/* Contact status banner (driven by ?sent=1) */
.form-status {
    padding: 1rem 1.15rem;
    margin-bottom: 1.5rem;
    border: 1px solid var(--line);
    background: #fff;
    font-size: 0.95rem;
}
.form-status.is-success {
    border-color: #6b8e7f;
    background: #eef3ef;
    color: #2e4a44;
}

/* Gallery lightbox */
.gallery .card { cursor: zoom-in; }
.gallery .card:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
}

body.lightbox-open { overflow: hidden; }

.lightbox {
    position: fixed;
    inset: 0;
    background: rgba(20, 17, 13, 0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    z-index: 1000;
    animation: lightbox-fade 0.18s ease-out;
}
@keyframes lightbox-fade { from { opacity: 0; } to { opacity: 1; } }

.lightbox-inner {
    background: var(--bg);
    max-width: 1100px;
    width: 100%;
    max-height: 100%;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
.lightbox-inner img {
    width: 100%;
    height: auto;
    max-height: 80vh;
    object-fit: contain;
    background: var(--bg-alt);
}
.lightbox-swatch {
    width: 100%;
    aspect-ratio: 4 / 5;
    max-height: 80vh;
}
.lightbox-caption {
    padding: 1rem 1.5rem 1.25rem;
    border-top: 1px solid var(--line);
}
.lightbox-caption h3 { margin: 0 0 0.25rem; }
.lightbox-caption .meta { margin: 0; }

.lightbox-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 44px;
    height: 44px;
    background: var(--bg);
    color: var(--ink);
    border: 0;
    border-radius: 50%;
    font-size: 1.6rem;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}
.lightbox-close:hover, .lightbox-close:focus { background: #fff; outline: none; }

/* Footer */
.site-footer {
    background: var(--ink);
    color: #d9d4cb;
    padding: 2.5rem 0;
    margin-top: 4rem;
}
.site-footer a { color: #d9d4cb; }
.site-footer a:hover { color: #fff; }
.footer-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}
.site-footer ul {
    list-style: none;
    display: flex;
    gap: 1.5rem;
    margin: 0;
    padding: 0;
}
.site-footer p { margin: 0; font-size: 0.9rem; color: #a8a198; }

/* Responsive */
@media (max-width: 820px) {
    .nav-toggle { display: flex; }
    .site-nav {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--bg);
        border-bottom: 1px solid var(--line);
        display: none;
    }
    .site-nav.is-open { display: block; }
    .site-nav ul {
        flex-direction: column;
        gap: 0;
        padding: 0.5rem 1.25rem 1rem;
    }
    .site-nav li { border-bottom: 1px solid var(--line); }
    .site-nav li:last-child { border-bottom: 0; }
    .site-nav a { display: block; padding: 0.9rem 0; }

    .about-teaser-inner,
    .bio-inner,
    .contact-inner {
        grid-template-columns: 1fr;
    }
    .about-img, .bio-img { max-width: 100%; margin: 0; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        transition: none !important;
        animation: none !important;
        scroll-behavior: auto !important;
    }
}
