* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --bg: #f7f1e8;
    --bg-soft: #efe5d7;
    --surface: rgba(255, 250, 243, 0.78);
    --surface-2: rgba(255, 255, 255, 0.72);
    --text: #2a2520;
    --muted: #6c6358;
    --line: #e7dac8;
    --accent: #c59056;
    --accent-soft: #e8c9a3;
    --radius-lg: 18px;
    --radius-md: 12px;
    --shadow: 0 14px 35px rgba(42, 37, 32, 0.08);
    --shadow-hover: 0 20px 40px rgba(42, 37, 32, 0.12);
    --nav-height: 130px;
    --logo-size: 115px;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: Inter, "Segoe UI", Roboto, Arial, sans-serif;
    color: var(--text);
    background-image: linear-gradient(rgba(247, 241, 232, 0.52), rgba(239, 229, 215, 0.52)), url("pictures/wooden photo.jpg");
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    line-height: 1.6;
}

img {
    max-width: 100%;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
}

.container {
    width: min(1120px, 92%);
    margin: 0 auto;
}

.section {
    padding: 4rem 0;
}

.section-title {
    font-size: clamp(1.6rem, 3vw, 2.1rem);
    font-weight: 700;
    letter-spacing: 0.02em;
    margin-bottom: 1rem;
}

.section-lead {
    color: var(--muted);
    max-width: 62ch;
    margin-bottom: 2rem;
}

.page-header {
    padding: 3rem 0 2.2rem;
}

.page-header h1 {
    font-size: clamp(1.8rem, 4vw, 2.6rem);
    margin-bottom: 0.45rem;
}

.page-header p {
    color: var(--muted);
}

header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(255, 253, 248, 0.86);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(10px);
    transition: background 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease, backdrop-filter 0.25s ease;
}

header.is-top {
    background: rgba(255, 253, 248, 0.62);
    border-bottom-color: transparent;
    backdrop-filter: blur(2px);
    box-shadow: none;
}

nav {
    min-height: var(--nav-height);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.logo {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    font-size: 1.1rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.logo-image {
    height: var(--logo-size);
    width: auto;
    max-width: min(220px, 38vw);
    border-radius: 0;
    object-fit: contain;
    border: none;
}

.nav-links {
    display: flex;
    align-items: center;
    list-style: none;
    gap: 1.3rem;
}

.nav-links a {
    color: var(--muted);
    font-weight: 500;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--text);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 0.7rem;
}

.icon-btn,
.menu-toggle {
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.86);
    color: var(--text);
    border-radius: 999px;
    cursor: pointer;
    padding: 0.55rem 0.9rem;
    font: inherit;
}

.menu-toggle {
    display: none;
    font-weight: 700;
}

.cart-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.4rem;
    min-height: 1.4rem;
    margin-left: 0.35rem;
    border-radius: 999px;
    font-size: 0.78rem;
    color: white;
    background: var(--accent);
}

.hero {
    padding: 4.8rem 0 3.4rem;
}

.hero-wrap {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 2rem;
    align-items: center;
}

.hero h1 {
    font-size: clamp(2rem, 4.6vw, 3.25rem);
    line-height: 1.1;
    margin-bottom: 1rem;
}

.hero p {
    color: var(--muted);
    margin-bottom: 1.4rem;
    max-width: 58ch;
}

.hero-card {
    background: linear-gradient(145deg, #fffdf9, #f8efdf);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    padding: 2rem;
    box-shadow: var(--shadow);
}

.hero-badges {
    display: flex;
    gap: 0.6rem;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.4rem 0.75rem;
    border-radius: 999px;
    background: #fff;
    border: 1px solid var(--line);
    color: var(--muted);
    font-size: 0.82rem;
}

.cta-row {
    display: flex;
    gap: 0.8rem;
    flex-wrap: wrap;
}

#featured .cta-row {
    justify-content: center;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.featured-cta {
    display: flex;
    justify-content: center;
    margin-top: 2.2rem;
}

.btn {
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--surface-2);
    color: var(--text);
    padding: 0.75rem 1.05rem;
    cursor: pointer;
    font-weight: 600;
    font: inherit;
}

.btn-primary {
    border-color: transparent;
    background: var(--accent);
    color: #fff;
}

.btn-primary:hover {
    filter: brightness(0.95);
}

.cta-button {
    border: 1px solid transparent;
    border-radius: 10px;
    background: var(--accent);
    color: #fff;
    padding: 0.75rem 1.05rem;
    cursor: pointer;
    font-weight: 600;
    font: inherit;
}

.cta-button:hover {
    filter: brightness(0.95);
}

.btn-soft:hover,
.icon-btn:hover,
.menu-toggle:hover,
.filter-btn:hover {
    border-color: #d9c5ad;
    background: #fff;
}

.category-row {
    display: flex;
    gap: 0.6rem;
    flex-wrap: wrap;
}

.filter-btn {
    border: 1px solid var(--line);
    background: var(--surface);
    color: var(--muted);
    border-radius: 999px;
    cursor: pointer;
    font: inherit;
    font-size: 0.92rem;
    padding: 0.5rem 0.9rem;
}

.filter-btn.active {
    color: var(--text);
    border-color: #d9c5ad;
    background: #fff;
}

.category-tabs {
    display: flex;
    gap: 0.6rem;
    flex-wrap: wrap;
    margin-bottom: 1.2rem;
}

.tab-button {
    border: 1px solid var(--line);
    background: var(--surface);
    color: var(--muted);
    border-radius: 999px;
    cursor: pointer;
    font: inherit;
    font-size: 0.92rem;
    padding: 0.5rem 0.9rem;
}

.tab-button.active {
    color: var(--text);
    border-color: #d9c5ad;
    background: #fff;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1rem;
    align-items: stretch;
    grid-auto-rows: 1fr;
}

.product-card {
    background: var(--surface-2);
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-hover);
}

.product-media {
    height: 220px;
    display: grid;
    place-items: center;
    background: linear-gradient(145deg, #f8ede0, #f2e5d3);
    font-size: 2.4rem;
    position: relative;
    overflow: hidden;
}

.product-media-link {
    display: block;
    width: 100%;
    height: 100%;
    cursor: zoom-in;
    border: none;
    background: transparent;
    padding: 0;
}

.product-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-media-fallback {
    color: var(--muted);
    font-size: 1rem;
}

.product-info {
    padding: 0.9rem;
}

.product-top {
    display: flex;
    justify-content: space-between;
    align-items: start;
    gap: 0.6rem;
    margin-bottom: 0.4rem;
}

.product-title {
    font-size: 1rem;
    font-weight: 700;
}

.product-price {
    font-weight: 700;
    color: #7f5834;
    white-space: nowrap;
}

.product-desc {
    color: var(--muted);
    font-size: 0.9rem;
    margin-bottom: 0.8rem;
}

.product-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.5rem;
}

.pill {
    font-size: 0.75rem;
    color: var(--muted);
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 0.2rem 0.55rem;
    background: var(--surface);
}

.product-pill {
    position: absolute;
    left: 0.65rem;
    bottom: 0.65rem;
    background: rgba(255, 250, 243, 0.94);
}

body.lightbox-open {
    overflow: hidden;
}

.image-lightbox {
    position: fixed;
    inset: 0;
    background: rgba(24, 21, 18, 0.86);
    z-index: 2100;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 0.8rem;
    padding: 1rem;
}

.image-lightbox.is-hidden {
    display: none;
}

.lightbox-stage {
    display: grid;
    justify-items: center;
    gap: 0.6rem;
    min-width: 0;
}

.lightbox-stage img {
    max-width: min(94vw, 1100px);
    max-height: 82vh;
    border-radius: 12px;
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.35);
    object-fit: contain;
}

#lightboxCaption {
    color: #fff7eb;
    text-align: center;
    margin: 0;
}

.lightbox-close,
.lightbox-nav {
    border: 1px solid rgba(255, 255, 255, 0.35);
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    border-radius: 999px;
    cursor: pointer;
    line-height: 1;
}

.lightbox-close {
    position: absolute;
    top: 0.85rem;
    right: 0.85rem;
    width: 2.25rem;
    height: 2.25rem;
    font-size: 1.35rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.lightbox-nav {
    width: 2.4rem;
    height: 2.4rem;
    font-size: 1.6rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

@media (max-width: 720px) {
    .image-lightbox {
        grid-template-columns: 1fr;
        gap: 0.35rem;
    }

    .lightbox-nav {
        position: fixed;
        top: 50%;
        transform: translateY(-50%);
        width: 2.75rem;
        height: 2.75rem;
        font-size: 1.75rem;
        background: rgba(17, 15, 13, 0.42);
        border-color: rgba(255, 255, 255, 0.55);
        z-index: 2101;
    }

    .lightbox-prev {
        left: 0.6rem;
    }

    .lightbox-next {
        right: 0.6rem;
    }

    .lightbox-close {
        width: 2.6rem;
        height: 2.6rem;
        font-size: 1.5rem;
        background: rgba(17, 15, 13, 0.42);
        border-color: rgba(255, 255, 255, 0.55);
    }

    .lightbox-stage img {
        max-height: 78vh;
    }
}

.split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.soft-card {
    border: 1px solid var(--line);
    background: var(--surface-2);
    border-radius: var(--radius-lg);
    padding: 1.2rem;
    box-shadow: var(--shadow);
}

.controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.8rem;
    flex-wrap: wrap;
    margin-bottom: 1.2rem;
}

.controls input,
.controls select {
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--surface-2);
    color: var(--text);
    font: inherit;
    padding: 0.6rem 0.8rem;
}

.controls input {
    min-width: min(360px, 92vw);
}

.empty-state {
    color: var(--muted);
    padding: 2rem 0;
}

footer {
    border-top: 1px solid var(--line);
    margin-top: 2rem;
    padding: 2rem 0;
    color: var(--muted);
    text-align: center;
}

.footer-contact {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.6rem;
    margin: 1rem 0;
}

.footer-contact-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
}

.footer-contact-item svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    color: var(--accent);
}

.footer-contact-item a {
    color: var(--muted);
    text-decoration: none;
}

.footer-contact-item a:hover {
    color: var(--accent);
}


.social-links {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-bottom: 1rem;
}

.social-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-soft), var(--accent));
    color: white;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(197, 144, 86, 0.2);
}

.social-icon:hover {
    transform: translateY(-3px) scale(1.1);
    box-shadow: 0 8px 20px rgba(197, 144, 86, 0.35);
    background: linear-gradient(135deg, var(--accent), var(--accent-soft));
}

.social-icon svg {
    width: 24px;
    height: 24px;
}

/* Cart drawer */
.cart-overlay {
    position: fixed;
    inset: 0;
    background: rgba(42, 37, 32, 0.25);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
    z-index: 1100;
}

.cart-overlay.open {
    opacity: 1;
    pointer-events: auto;
}

.cart-drawer {
    position: fixed;
    top: 0;
    right: 0;
    height: 100dvh;
    width: min(380px, 92vw);
    background: var(--surface-2);
    border-left: 1px solid var(--line);
    transform: translateX(100%);
    transition: transform 0.25s ease;
    z-index: 1200;
    display: flex;
    flex-direction: column;
}

.cart-drawer.open {
    transform: translateX(0);
}

.cart-head,
.cart-foot {
    padding: 1rem;
    border-bottom: 1px solid var(--line);
}

.cart-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cart-foot {
    border-top: 1px solid var(--line);
    border-bottom: 0;
    margin-top: auto;
}

.cart-items {
    padding: 0.8rem 1rem;
    overflow: auto;
    display: grid;
    gap: 0.7rem;
}

.cart-item {
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 0.7rem;
    background: var(--surface);
}

.cart-item-top {
    display: flex;
    justify-content: space-between;
    gap: 0.8rem;
    margin-bottom: 0.5rem;
}

.cart-item-title {
    font-size: 0.92rem;
    font-weight: 600;
}

.qty-row {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
}

.qty-btn {
    border: 1px solid var(--line);
    background: var(--surface-2);
    border-radius: 8px;
    width: 28px;
    height: 28px;
    cursor: pointer;
    font-weight: 700;
}

.totals {
    display: grid;
    gap: 0.4rem;
    margin-bottom: 0.8rem;
}

.totals div {
    display: flex;
    justify-content: space-between;
}

.totals .grand {
    font-weight: 700;
}

/* About + contact */
.about-grid,
.contact-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 1rem;
}

.contact-card {
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: var(--surface-2);
    padding: 1rem;
}

.contact-card h4 {
    margin-bottom: 0.4rem;
}

.contact-card p {
    color: var(--muted);
}

.about-photo-card {
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.about-photo-image {
    width: 100%;
    max-height: 420px;
    object-fit: cover;
    border-radius: 12px;
}

/* Admin support */
.photo-panel {
    background: var(--surface-2);
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    padding: 1rem;
    margin-bottom: 1rem;
}

.photo-panel h3 {
    margin-bottom: 0.4rem;
}

.photo-panel p,
.panel-hint {
    color: var(--muted);
}

.admin-layout {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
}

.admin-card {
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: var(--surface);
    padding: 1rem;
}

.admin-card h3 {
    margin-bottom: 0.45rem;
}

.admin-card-full {
    grid-column: 1 / -1;
}

.admin-form-grid {
    display: grid;
    gap: 0.65rem;
}

.admin-form-grid input,
.admin-form-grid select,
.admin-form-grid textarea,
.admin-inline-row input {
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 0.65rem 0.75rem;
    font: inherit;
    background: var(--surface-2);
    color: var(--text);
}

.admin-form-grid textarea {
    resize: vertical;
    min-height: 92px;
}

.admin-inline-check {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--muted);
}

.admin-inline-row {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 0.6rem;
    margin-bottom: 0.7rem;
}

.admin-form-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.admin-list {
    display: grid;
    gap: 0.6rem;
}

.admin-list-row {
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--surface-2);
    padding: 0.7rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.8rem;
}

.admin-row-actions {
    display: flex;
    gap: 0.4rem;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.admin-auth,
.photo-panel-form {
    display: grid;
    gap: 0.65rem;
}

.admin-auth {
    grid-template-columns: 1fr auto;
}

.photo-panel-form {
    grid-template-columns: 1fr 1fr 1fr auto;
}

.photo-panel input,
.photo-panel select {
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 0.65rem 0.75rem;
    font: inherit;
}

.admin-logout-btn,
.remove-photo-btn {
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--surface);
    padding: 0.6rem 0.75rem;
    cursor: pointer;
    font: inherit;
}

.remove-photo-btn {
    width: 100%;
    margin-top: 0.6rem;
}

.uploaded-product-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.is-hidden {
    display: none !important;
}

@media (max-width: 900px) {
    .hero-wrap,
    .split,
    .about-grid,
    .contact-grid {
        grid-template-columns: 1fr;
    }

    .admin-layout {
        grid-template-columns: 1fr;
    }

    .admin-list-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .admin-row-actions {
        justify-content: flex-start;
    }

    .photo-panel-form {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 760px) {
    :root {
        --nav-height: 110px;
        --logo-size: 95px;
    }

    .menu-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    .nav-links {
        position: fixed;
        top: var(--nav-height);
        left: -100%;
        width: 100%;
        background: var(--surface-2);
        border-bottom: 1px solid var(--line);
        flex-direction: column;
        gap: 0;
        transition: left 0.2s ease;
    }

    .nav-links.active {
        left: 0;
    }

    .nav-links li {
        width: 100%;
        text-align: center;
        border-bottom: 1px solid var(--line);
        padding: 0.85rem 0;
    }

    .admin-auth {
        grid-template-columns: 1fr;
    }

}
