:root {
    --bg-app: #FAF9F6;
    --bg-card: #FFFFFF;
    --bg-surface-warm: #F9F7F2;
    --bg-surface-neutral: #F5F5F4;
    --text-primary: #1A1A1A;
    --text-brand: #3D2B1F;
    --text-secondary: #57534E;
    --text-muted: #A8A29E;
    --accent-gold-light: #E5D3B3;
    --accent-gold-rich: #D4AF37;
    --accent-espresso-dark: #2A1D15;
    --border-light: #E7E5E4;
    --border-warm: #E5D3B3;
    --border-active: #3D2B1F;
    --color-success: #064E3B;
    --color-like: #E11D48;
}

* { box-sizing: border-box; }
[x-cloak] { display: none !important; }

body { margin: 0; color: #2f2925; }

.page-rail { width: min(1204px, calc(100% - 40px)); margin-inline: auto; }

.site-header { position: sticky; top: 0; z-index: 50; height: 72px; border-bottom: 1px solid var(--border-light); background: rgba(255, 255, 255, .96); backdrop-filter: blur(12px); }
.header-rail { display: grid; width: min(1204px, calc(100% - 40px)); height: 100%; grid-template-columns: minmax(150px, 1fr) minmax(280px, 620px) minmax(150px, 1fr); align-items: center; gap: 24px; margin-inline: auto; }
.header-rail--catalog { grid-template-columns: minmax(150px, 1fr) minmax(280px, 620px) auto minmax(40px, 1fr); }
.header-brand { display: inline-flex; width: max-content; align-items: center; gap: 10px; text-decoration: none; }
.header-brand-mark { display: grid; width: 36px; height: 36px; flex: none; place-items: center; border-radius: 8px; background: var(--text-brand); color: #fff; font-size: 11px; font-weight: 700; }
.header-brand p { margin: 0; }
.header-search { position: relative; display: flex; width: 100%; height: 44px; align-items: center; border: 1px solid #ded9d5; border-radius: 999px; background: #f8f7f5; padding: 0 14px; transition: border-color 160ms ease, background 160ms ease, box-shadow 160ms ease; }
.header-search:focus-within { border-color: #b9afa8; background: #fff; box-shadow: 0 0 0 3px rgba(61, 43, 31, .06); }
.header-search > svg { width: 17px; height: 17px; flex: none; color: #918984; }
.header-search input { min-width: 0; flex: 1; border: 0; outline: 0; background: transparent; padding: 0 10px; color: var(--text-primary); font: inherit; font-size: 13px; }
.header-search input::placeholder { color: #9c958f; }
.search-suggestions { position: absolute; z-index: 80; top: calc(100% + 9px); right: 0; left: 0; overflow: hidden; border: 1px solid var(--border-light); border-radius: 8px; background: #fff; padding: 6px; box-shadow: 0 18px 45px rgba(42, 29, 21, .15); }
.search-suggestion-group + .search-suggestion-group { margin-top: 4px; border-top: 1px solid #eeeae7; padding-top: 4px; }
.search-suggestion-label { margin: 0; padding: 7px 10px 5px; color: #918984; font-size: 10px; font-weight: 700; text-transform: uppercase; }
.search-suggestion-option { display: flex; width: 100%; min-width: 0; align-items: center; gap: 9px; border: 0; border-radius: 6px; background: transparent; padding: 9px 10px; color: #514a46; font: inherit; font-size: 12px; text-align: left; cursor: pointer; }
.search-suggestion-option:hover, .search-suggestion-option.is-active { background: #f5f3f1; color: var(--text-brand); }
.search-suggestion-option:focus-visible { outline: 2px solid rgba(61, 43, 31, .22); outline-offset: -2px; }
.search-suggestion-option svg { width: 15px; height: 15px; flex: none; color: #918984; }
.search-suggestion-option span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.header-filter-toggle { display: inline-flex; height: 40px; align-items: center; gap: 7px; border: 1px solid #ded9d5; border-radius: 999px; background: #fff; padding: 0 13px; color: #655d58; font: inherit; font-size: 12px; font-weight: 700; cursor: pointer; transition: border-color 160ms ease, background 160ms ease, color 160ms ease; }
.header-filter-toggle:hover, .header-filter-toggle.is-active { border-color: #b9afa8; background: #f5f3f1; color: var(--text-brand); }
.header-filter-toggle:focus-visible { outline: 3px solid rgba(61, 43, 31, .14); outline-offset: 2px; }
.header-filter-toggle svg { width: 16px; height: 16px; }
.account-menu { position: relative; justify-self: end; }
.account-avatar { display: grid; width: 40px; height: 40px; place-items: center; border: 0; border-radius: 50%; background: var(--text-brand); color: #fff; font: 700 12px "Plus Jakarta Sans", sans-serif; cursor: pointer; }
.account-avatar:focus-visible { outline: 3px solid rgba(61, 43, 31, .2); outline-offset: 2px; }
.account-dropdown { position: absolute; top: calc(100% + 10px); right: 0; width: 220px; border: 1px solid var(--border-light); border-radius: 8px; background: #fff; padding: 8px; box-shadow: 0 18px 45px rgba(42, 29, 21, .14); }
.account-dropdown p { margin: 4px 8px 10px; overflow: hidden; color: #817974; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.account-dropdown button { display: flex; width: 100%; align-items: center; gap: 9px; border: 0; border-radius: 6px; background: transparent; padding: 10px 9px; color: var(--text-brand); font: inherit; font-size: 12px; font-weight: 700; cursor: pointer; }
.account-dropdown button:hover { background: #f5f3f1; }
.account-dropdown svg { width: 15px; height: 15px; }

.gallery-band { min-height: calc(100vh - 72px); padding: 14px 0 56px; background: #fdfcfb; }
.catalog-filter-disclosure { display: grid; grid-template-rows: 0fr; transition: grid-template-rows 250ms cubic-bezier(.2,.8,.2,1); }
.catalog-filter-disclosure.is-open { grid-template-rows: 1fr; }
.catalog-filter-disclosure-inner { min-height: 0; overflow: visible; }
.catalog-filter-panel { position: relative; z-index: 20; border-bottom: 1px solid var(--border-light); margin: -14px 0 14px; background: #fff; padding: 14px 0; opacity: 0; transform: translateY(-8px); transition: opacity 200ms ease, transform 250ms cubic-bezier(.2,.8,.2,1); }
.catalog-filter-disclosure.is-open .catalog-filter-panel { opacity: 1; transform: translateY(0); }
.catalog-page { columns: 4; column-gap: 14px; }
.catalog-grid-span, .empty-results { column-span: all; }
.look-card { display: inline-block; width: 100%; min-width: 0; margin-bottom: 14px; break-inside: avoid; }
.card-image { position: relative; overflow: hidden; aspect-ratio: 4/5; border-radius: 12px; background: #eeeae7; }
.look-card:nth-of-type(6n + 2) .card-image,
.look-card:nth-of-type(6n + 5) .card-image { aspect-ratio: 3/4; }
.look-card:nth-of-type(6n + 3) .card-image { aspect-ratio: 1/1; }
.look-card:nth-of-type(6n + 4) .card-image { aspect-ratio: 2/3; }
.card-image::before { position: absolute; inset: 0; background: linear-gradient(105deg, #ece8e4 20%, #f7f5f2 40%, #ece8e4 60%); background-size: 220% 100%; content: ""; opacity: 0; pointer-events: none; }
.card-image.is-loading::before { opacity: 1; animation: image-skeleton 1.25s ease-in-out infinite; }
.card-image-link { display: block; width: 100%; height: 100%; }
.card-image img { display: block; width: 100%; height: 100%; object-fit: cover; opacity: 1; transition: opacity 220ms ease, transform 350ms ease; }
.card-image.is-loading img { opacity: 0; }
.card-image.is-error img { visibility: hidden; }
.look-card:hover .card-image:not(.is-loading) img { transform: scale(1.015); }
.card-actions { position: absolute; z-index: 1; top: 10px; right: 10px; }
.card-actions button { display: grid; width: 37px; height: 37px; place-items: center; border: 1px solid rgba(0,0,0,.08); border-radius: 50%; background: rgba(255,255,255,.94); color: #655d58; opacity: 0; transform: translateY(-4px); transition: opacity 160ms ease, transform 160ms ease, color 160ms ease; cursor: pointer; }
.look-card:hover .card-actions button, .card-actions button:focus-visible { opacity: 1; transform: translateY(0); }
.card-actions button:hover { color: var(--color-like); }
.card-actions svg { width: 17px; height: 17px; }
.save-heart { transition: opacity 220ms ease, transform 220ms cubic-bezier(.2,.8,.2,1), color 220ms ease, background-color 220ms ease !important; }
.save-heart:hover { transform: translateY(0) scale(1.08) !important; }
.save-heart--saved { animation: heart-save 480ms cubic-bezier(.2,.9,.25,1.25); }
.save-heart--removed { animation: heart-remove 320ms ease-out; }
.empty-results { padding: 80px 20px; color: #817974; text-align: center; }

.wishlist-dialog { opacity: 0; transform: translateY(18px) scale(.975); transition: opacity 220ms ease, transform 280ms cubic-bezier(.2,.8,.2,1); }
.wishlist-dialog::backdrop { background: rgba(24, 20, 18, 0); backdrop-filter: blur(0); transition: background 240ms ease, backdrop-filter 240ms ease; }
.wishlist-dialog.is-open { opacity: 1; transform: translateY(0) scale(1); }
.wishlist-dialog.is-open::backdrop { background: rgba(24, 20, 18, .48); backdrop-filter: blur(2px); }
.wishlist-dialog.is-closing { opacity: 0; transform: translateY(10px) scale(.985); }
.wishlist-dialog.is-closing::backdrop { background: rgba(24, 20, 18, 0); backdrop-filter: blur(0); }

.toast-region { position: fixed; z-index: 120; right: 24px; bottom: 24px; pointer-events: none; }
.success-toast { display: flex; min-width: 280px; align-items: center; gap: 12px; border: 1px solid rgba(6,78,59,.16); border-radius: 8px; background: rgba(255,255,255,.98); padding: 13px 16px; color: var(--text-primary); box-shadow: 0 16px 44px rgba(42,29,21,.18); animation: toast-enter 360ms cubic-bezier(.2,.8,.2,1) both; }
.success-toast.is-leaving { animation: toast-leave 260ms ease forwards; }
.success-toast-icon { display: grid; width: 32px; height: 32px; flex: none; place-items: center; border-radius: 50%; background: #e8f5ef; color: var(--color-success); }
.success-toast-icon svg { width: 17px; height: 17px; stroke-width: 2.5; }
.success-toast strong, .success-toast small { display: block; }
.success-toast strong { font-size: 13px; }
.success-toast small { margin-top: 2px; color: #756d68; font-size: 11px; }
.success-toast-action { pointer-events: auto; margin-left: auto; border: 0; background: transparent; padding: 7px 4px; color: var(--color-success); font: inherit; font-size: 12px; font-weight: 700; cursor: pointer; }
.success-toast-action:hover { text-decoration: underline; }

@keyframes heart-save {
    0% { transform: scale(.82); }
    48% { transform: scale(1.22); }
    72% { transform: scale(.96); }
    100% { transform: scale(1); }
}
@keyframes image-skeleton {
    from { background-position: 100% 0; }
    to { background-position: -100% 0; }
}
@keyframes heart-remove {
    0% { transform: scale(1.08); }
    100% { transform: scale(1); }
}
@keyframes toast-enter {
    from { opacity: 0; transform: translateY(14px) scale(.98); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes toast-leave {
    to { opacity: 0; transform: translateY(8px) scale(.98); }
}

.detail-header { height: 72px; border-bottom: 1px solid var(--border-light); background: #fff; }
.detail-header-rail { display: flex; width: min(1204px, calc(100% - 40px)); height: 100%; align-items: center; justify-content: space-between; margin-inline: auto; }
.detail-brand-name { color: var(--text-brand); font: 700 20px "Cormorant Garamond", serif; }
.detail-back { display: inline-flex; align-items: center; gap: 7px; color: #625b56; font-size: 12px; font-weight: 700; text-decoration: none; }
.detail-back svg { width: 15px; height: 15px; }
.detail-layout { display: grid; width: min(1204px, calc(100% - 40px)); grid-template-columns: minmax(0, 1.55fr) minmax(280px, .65fr); align-items: start; gap: 48px; margin: 32px auto 80px; }
.detail-gallery { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.detail-gallery figure { overflow: hidden; margin: 0; border-radius: 6px; background: #eeeae7; }
.detail-gallery figure:first-child { grid-column: 1 / -1; }
.detail-gallery img { display: block; width: 100%; height: auto; }
.detail-image-open { display: block; width: 100%; border: 0; padding: 0; background: transparent; cursor: zoom-in; }
.detail-image-dialog { width: 100vw; max-width: none; height: 100vh; max-height: none; margin: 0; border: 0; padding: 24px; background: rgb(20 18 17 / 96%); }
.detail-image-dialog::backdrop { background: rgb(20 18 17 / 85%); }
.detail-image-dialog > img { display: block; width: 100%; height: 100%; object-fit: contain; }
.detail-image-close { position: fixed; z-index: 1; top: 20px; right: 20px; display: grid; width: 40px; height: 40px; place-items: center; border: 1px solid rgb(255 255 255 / 35%); border-radius: 50%; background: rgb(20 18 17 / 72%); color: #fff; cursor: pointer; }
.detail-image-close svg { width: 18px; height: 18px; }
.detail-image-download { position: fixed; z-index: 1; top: 20px; right: 72px; display: grid; width: 40px; height: 40px; place-items: center; border: 1px solid rgb(255 255 255 / 35%); border-radius: 50%; background: rgb(20 18 17 / 72%); color: #fff; }
.detail-image-download[hidden] { display: none; }
.detail-image-download svg { width: 18px; height: 18px; }
.detail-panel { position: sticky; top: 32px; padding: 12px 0; }
.detail-meta { margin: 0 0 10px; color: #817974; font-size: 10px; font-weight: 700; text-transform: uppercase; }
.detail-panel h1 { margin: 0; color: var(--text-brand); font: 700 42px/.98 "Cormorant Garamond", serif; letter-spacing: 0; }
.detail-description { margin: 20px 0 0; color: #6f6762; font-size: 13px; line-height: 1.7; }
.detail-facts { margin: 28px 0 0; border-top: 1px solid var(--border-light); }
.detail-facts div { display: grid; grid-template-columns: 100px minmax(0, 1fr); gap: 16px; border-bottom: 1px solid var(--border-light); padding: 12px 0; font-size: 12px; }
.detail-facts dt { color: #9b938e; }
.detail-facts dd { margin: 0; color: #514a46; text-align: right; }
.detail-palette { margin-top: 24px; }
.detail-palette p { margin: 0 0 10px; color: #9b938e; font-size: 11px; }
.detail-palette > div { display: flex; gap: 8px; }
.detail-palette span { display: block; width: 22px; height: 22px; border: 1px solid #d9d3cf; border-radius: 50%; }

.font-ui {
    font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.display-heading {
    font-family: "Syne", sans-serif;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.brand-display {
    font-family: "Syne", sans-serif;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--text-brand);
}

.editorial-heading {
    font-family: "Cormorant Garamond", Georgia, serif;
    font-weight: 700;
    letter-spacing: -0.01em;
}

.spec-text {
    font-family: "JetBrains Mono", "SFMono-Regular", Menlo, monospace;
    font-weight: 400;
}

.top-pill {
    border: 1px solid var(--border-light);
    background: var(--bg-card);
    color: var(--text-secondary);
    border-radius: 9999px;
    padding: 0.55rem 0.9rem;
    font-size: 0.75rem;
    font-weight: 600;
    transition: all 160ms ease;
}

.top-pill:hover {
    border-color: var(--border-warm);
    color: var(--text-primary);
    transform: translateY(-1px);
}

.custom-filter {
    position: relative;
    display: inline-block;
}

.custom-filter-trigger {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    min-width: 150px;
    gap: 0.7rem;
    border: 1px solid var(--border-light);
    background: var(--bg-surface-neutral);
    color: var(--text-secondary);
    border-radius: 9999px;
    padding: 0.52rem 0.82rem 0.52rem 0.9rem;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    line-height: 1.2;
    text-transform: capitalize;
    transition: all 180ms ease, box-shadow 180ms ease;
    cursor: pointer;
}

.custom-filter-trigger:hover {
    border-color: var(--border-warm);
    color: var(--text-primary);
}

.custom-filter-trigger:focus-visible {
    outline: none;
    border-color: #c7b69a;
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.14);
}

.custom-filter-trigger svg {
    width: 14px;
    height: 14px;
    flex: none;
    transition: transform 180ms ease;
}

.custom-filter.is-open .custom-filter-trigger svg {
    transform: rotate(180deg);
}

.custom-filter-value {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.custom-filter-menu {
    position: absolute;
    z-index: 80;
    top: calc(100% + 0.55rem);
    left: 0;
    width: min(100%, 200px);
    max-height: min(52vh, 360px);
    overflow-y: auto;
    overflow-x: hidden;
    border: 1px solid var(--border-light);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.98);
    padding: 0.35rem;
    box-shadow: 0 18px 38px rgba(31, 25, 22, 0.12);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-4px);
    transition: opacity 180ms ease, transform 180ms ease, visibility 180ms ease;
    overscroll-behavior: contain;
}

.custom-filter.is-open .custom-filter-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.custom-filter-option {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    width: 100%;
    min-width: 0;
    border: 0;
    border-radius: 10px;
    background: transparent;
    padding: 0.62rem 0.75rem;
    color: var(--text-primary);
    font: inherit;
    font-size: 0.78rem;
    font-weight: 600;
    text-align: left;
    text-transform: capitalize;
    cursor: pointer;
    transition: background 160ms ease, color 160ms ease;
}

.custom-filter-option > svg {
    display: none;
    width: 14px;
    height: 14px;
    flex: none;
}

.custom-filter-option.is-selected > svg {
    display: block;
}

.custom-filter-option:hover,
.custom-filter-option:focus-visible,
.custom-filter-option.is-selected {
    background: #f5f3f1;
    color: var(--text-brand);
}

.custom-filter-option.is-selected {
    background: rgba(61, 43, 31, 0.06);
}

.filter-chip {
    border: 1px solid var(--border-light);
    background: var(--bg-surface-neutral);
    color: var(--text-secondary);
    border-radius: 9999px;
    padding: 0.45rem 0.9rem;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    text-transform: capitalize;
    transition: all 180ms ease;
}

.chip-active {
    background: var(--text-brand);
    border-color: var(--border-active);
    color: var(--bg-app);
}

.site-footer { border-top: 1px solid #ddd8d1; background: #f4f2ee; padding: 44px 0 24px; }
.footer-rail { width: min(1204px, calc(100% - 40px)); margin-inline: auto; }
.footer-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 64px; }
.footer-summary { max-width: 390px; }
.footer-brand { display: inline-flex; align-items: center; gap: 11px; color: var(--text-brand); text-decoration: none; }
.footer-brand-mark { display: grid; width: 34px; height: 34px; place-items: center; border: 1px solid #cfc6bc; border-radius: 50%; color: #765026; font: 700 10px "Plus Jakarta Sans", sans-serif; }
.footer-brand strong { font: 700 24px/.95 "Cormorant Garamond", serif; }

.footer-description {
    margin: 12px 0 0;
    font-size: 13px;
    font-weight: 400;
    line-height: 1.55;
    color: #817a76;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 9px 24px;
    max-width: 590px;
    padding-top: 8px;
    font-size: 12px;
    font-weight: 700;
    color: #574f4a;
}
.footer-links a { color: inherit; text-decoration: none; text-underline-offset: 4px; }
.footer-links a:hover { color: #765026; text-decoration: underline; }
.footer-bottom { display: flex; align-items: center; justify-content: space-between; gap: 32px; margin-top: 34px; border-top: 1px solid #ddd8d1; padding-top: 20px; }

.footer-legal, .footer-note { margin: 0; color: #8b837d; font-size: 10px; }

@media (max-width: 768px) {
    .site-header { height: 64px; }
    .header-rail { width: calc(100% - 24px); grid-template-columns: 40px minmax(0, 1fr) 40px; gap: 10px; }
    .header-rail--catalog { grid-template-columns: 36px minmax(0, 1fr) 38px 38px; gap: 8px; }
    .header-brand p { display: none; }
    .header-search { height: 40px; padding-inline: 11px; }
    .header-search input { font-size: 12px; }
    .search-suggestions { position: fixed; top: 58px; right: 12px; left: 12px; width: auto; }
    .header-filter-toggle { width: 38px; height: 38px; justify-content: center; padding: 0; }
    .header-filter-toggle span { display: none; }
    .account-avatar { width: 38px; height: 38px; }
    .gallery-band { min-height: calc(100vh - 64px); padding-top: 12px; }
    .catalog-filter-panel { margin-top: -12px; padding: 12px 0; }
    .page-rail { width: calc(100% - 24px); }
    .catalog-page { columns: 2; column-gap: 10px; }
    .look-card { margin-bottom: 10px; }
    .card-image { border-radius: 10px; }
    .detail-header { height: 64px; }
    .detail-header-rail { width: calc(100% - 24px); }
    .detail-brand-name { display: none; }
    .detail-layout { width: calc(100% - 24px); grid-template-columns: 1fr; gap: 26px; margin: 12px auto 52px; }
    .detail-gallery { grid-template-columns: 1fr; gap: 10px; }
    .detail-gallery figure:first-child { grid-column: auto; }
    .detail-image-dialog { padding: 12px; }
    .detail-image-close { top: 12px; right: 12px; }
    .detail-image-download { top: 12px; right: 64px; }
    .detail-panel { position: static; padding: 0; }
    .detail-panel h1 { font-size: 34px; }
    .toast-region { right: 12px; bottom: 12px; left: 12px; }
    .success-toast { min-width: 0; width: 100%; }

    .site-footer { padding: 36px 0 22px; }
    .footer-rail { width: calc(100% - 24px); }
    .footer-top, .footer-bottom { align-items: flex-start; flex-direction: column; }
    .footer-top { gap: 26px; }
    .footer-links { justify-content: flex-start; gap: 12px 22px; padding-top: 0; }
    .footer-bottom { gap: 7px; margin-top: 28px; padding-top: 18px; }
}

@media (prefers-reduced-motion: reduce) {
    .catalog-filter-disclosure, .catalog-filter-panel, .wishlist-dialog, .wishlist-dialog::backdrop, .save-heart, .success-toast, .card-image::before { animation: none !important; transition-duration: 0.01ms !important; }
}

@media (min-width: 769px) and (max-width: 1024px) {
    .catalog-page { columns: 3; }
}
