:root {
    color-scheme: light;
    --ink: #17211f;
    --muted: #65706c;
    --line: #dce4de;
    --paper: #f8faf7;
    --panel: #ffffff;
    --accent: #0f766e;
    --accent-dark: #134e4a;
    --gold: #b7791f;
    --rose: #be123c;
    --shadow: 0 18px 45px rgba(23, 33, 31, .12);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--ink);
    background:
        radial-gradient(circle at top left, rgba(15, 118, 110, .11), transparent 34rem),
        linear-gradient(180deg, #fdfdf9 0%, var(--paper) 48%, #eef5f1 100%);
}

a {
    color: inherit;
    text-decoration: none;
}

button,
input,
select,
textarea {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: .9rem clamp(1rem, 4vw, 4rem);
    border-bottom: 1px solid rgba(245, 197, 66, .28);
    color: #f8faf7;
    background:
        linear-gradient(135deg, rgba(11, 31, 29, .98), rgba(19, 78, 74, .96) 55%, rgba(23, 33, 31, .98));
    box-shadow: 0 18px 38px rgba(14, 43, 40, .24);
    backdrop-filter: blur(18px);
}

.brand,
.top-nav {
    display: flex;
    align-items: center;
    gap: .75rem;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: .8rem;
}

.brand {
    font-weight: 800;
    min-width: 0;
    color: #fffdf7;
}

.brand span {
    display: block;
    max-width: min(42vw, 24rem);
    overflow-wrap: anywhere;
    font-size: clamp(1rem, 1.9vw, 1.45rem);
    line-height: 1.05;
    text-shadow: 0 8px 22px rgba(0, 0, 0, .28);
}

.brand-logo {
    flex: 0 0 auto;
    width: 2.65rem;
    height: 2.65rem;
    border: 1px solid rgba(255, 255, 255, .45);
    border-radius: .65rem;
    box-shadow: 0 12px 26px rgba(0, 0, 0, .28), 0 0 0 4px rgba(245, 197, 66, .12);
    animation: logo-rise .7s ease-out both, logo-gleam 4.8s ease-in-out 1.1s infinite;
    transform-origin: 50% 70%;
    transition: transform .25s ease, box-shadow .25s ease;
}

.brand:hover .brand-logo {
    transform: translateY(-1px) rotate(-2deg) scale(1.04);
    box-shadow: 0 16px 34px rgba(0, 0, 0, .32), 0 0 0 4px rgba(245, 197, 66, .2);
}

@keyframes logo-rise {
    from {
        opacity: 0;
        transform: translateY(.35rem) scale(.94);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes logo-gleam {
    0%,
    72%,
    100% {
        filter: brightness(1) saturate(1);
    }

    78% {
        filter: brightness(1.12) saturate(1.08);
    }
}

@media (prefers-reduced-motion: reduce) {
    .brand-logo {
        animation: none;
        transition: none;
    }
}

.top-nav a {
    position: relative;
    padding: .55rem .1rem;
    color: rgba(248, 250, 247, .74);
    font-weight: 700;
    transition: color .2s ease;
}

.top-nav a.active,
.top-nav a:hover {
    color: #fffdf7;
}

.top-nav a.active::after,
.top-nav a:hover::after {
    position: absolute;
    right: 0;
    bottom: .25rem;
    left: 0;
    height: 2px;
    border-radius: 999px;
    background: var(--gold);
    content: "";
}

.auth-button {
    display: inline-flex;
    min-height: 2.35rem;
    align-items: center;
    justify-content: center;
    padding: .55rem .95rem;
    border: 1px solid rgba(245, 197, 66, .56);
    border-radius: .45rem;
    color: #17211f;
    background: #f5c542;
    box-shadow: 0 10px 24px rgba(0, 0, 0, .18);
    font-weight: 900;
    white-space: nowrap;
    transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}

.auth-button:hover {
    background: #ffd166;
    box-shadow: 0 14px 30px rgba(0, 0, 0, .22);
    transform: translateY(-1px);
}

.user-badge {
    display: inline-flex;
    min-height: 2.35rem;
    align-items: center;
    justify-content: center;
    padding: .55rem .85rem;
    border: 1px solid rgba(255, 255, 255, .28);
    border-radius: .45rem;
    color: #fffdf7;
    background: rgba(255, 255, 255, .12);
    font-weight: 900;
    line-height: 1;
    white-space: nowrap;
}

.pill {
    display: inline-grid;
    min-width: 1.35rem;
    height: 1.35rem;
    place-items: center;
    padding: 0 .35rem;
    border-radius: 999px;
    color: white;
    background: var(--rose);
    font-size: .78rem;
}

.currency-menu {
    position: relative;
    margin-left: auto;
}

.currency-trigger {
    display: grid;
    width: 2.45rem;
    height: 2.45rem;
    place-items: center;
    border: 1px solid rgba(255, 255, 255, .34);
    border-radius: .45rem;
    background: rgba(255, 255, 255, .1);
    color: #fffdf7;
    cursor: pointer;
    font-size: 1.3rem;
    font-weight: 900;
    line-height: 1;
}

.currency-trigger:hover,
.currency-trigger[aria-expanded="true"] {
    border-color: #b7cbc3;
    background: #eef8f5;
}

.currency-options {
    position: absolute;
    top: calc(100% + .55rem);
    right: 0;
    z-index: 20;
    display: none;
    min-width: 14rem;
    gap: 0;
    padding: .35rem;
    border: 1px solid var(--line);
    border-radius: .55rem;
    background: white;
    box-shadow: var(--shadow);
}

.currency-options a {
    display: block;
    padding: .78rem .85rem;
    border-radius: .45rem;
}

.currency-options a strong,
.currency-options a span {
    display: block;
}

.currency-options a span {
    margin-top: .16rem;
    color: var(--muted);
    font-size: .9rem;
    font-weight: 800;
}

.currency-options a:hover,
.currency-options a.active {
    background: #eef8f5;
    color: var(--accent-dark);
}

.currency-options small {
    margin-top: .3rem;
    color: var(--muted);
    line-height: 1.45;
}

main {
    width: min(1180px, calc(100% - 2rem));
    margin: 0 auto;
    padding: 2rem 0 4rem;
}

.hero {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(19rem, .75fr);
    gap: clamp(1.5rem, 5vw, 4rem);
    align-items: center;
    min-height: calc(100svh - 7rem);
    padding: 2rem 0;
}

.hero-copy h1 {
    max-width: 12ch;
    margin: .35rem 0 1rem;
    font-size: clamp(3rem, 8vw, 6.8rem);
    line-height: .9;
    letter-spacing: 0;
}

.hero-copy p {
    max-width: 42rem;
    color: var(--muted);
    font-size: 1.1rem;
    line-height: 1.7;
}

.eyebrow {
    margin: 0;
    color: var(--accent-dark);
    font-size: .78rem;
    font-weight: 900;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: .8rem;
    margin-top: 1.6rem;
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 2.85rem;
    padding: .8rem 1rem;
    border: 1px solid var(--line);
    border-radius: .45rem;
    cursor: pointer;
    font-weight: 850;
}

.button.primary {
    color: white;
    border-color: var(--accent-dark);
    background: var(--accent-dark);
}

.button:disabled {
    cursor: not-allowed;
    opacity: .62;
}

.button.secondary {
    color: var(--accent-dark);
    background: white;
}

.button.full {
    width: 100%;
}

.hero-card {
    display: flex;
    justify-content: center;
}

.featured-card-showcase {
    width: min(24rem, 100%);
    align-items: center;
}

.featured-card-photo {
    position: relative;
    display: grid;
    gap: .7rem;
    width: 100%;
    margin: 0;
    padding: 2.35rem .55rem .75rem;
    border: 1px solid rgba(255, 255, 255, .78);
    border-radius: .85rem;
    background:
        linear-gradient(145deg, rgba(255, 255, 255, .94), rgba(255, 255, 255, .72)),
        radial-gradient(circle at top, rgba(245, 197, 66, .2), transparent 62%);
    box-shadow: 0 24px 55px rgba(23, 33, 31, .22);
    cursor: pointer;
    transform: rotate(2deg);
    transition: transform .22s ease, box-shadow .22s ease;
}

.featured-card-photo:focus-visible {
    outline: 3px solid var(--gold);
    outline-offset: .25rem;
}

.featured-card-photo:hover {
    box-shadow: 0 30px 65px rgba(23, 33, 31, .28);
    transform: rotate(1deg) translateY(-.25rem);
}

.featured-card-photo img {
    display: block;
    width: 100%;
    aspect-ratio: 5 / 7;
    border-radius: .55rem;
    object-fit: cover;
}

.featured-card-photo img[hidden] {
    display: none;
}

.card-image-placeholder {
    display: grid;
    width: 100%;
    aspect-ratio: 5 / 7;
    place-items: center;
    padding: 1rem;
    border: 1px dashed rgba(15, 23, 42, .28);
    border-radius: .55rem;
    background: rgba(248, 250, 252, .88);
    color: var(--muted);
    font-weight: 900;
    text-align: center;
}

.card-image-placeholder[hidden] {
    display: none;
}

.featured-card-side {
    position: absolute;
    top: .65rem;
    left: .75rem;
    z-index: 2;
}

.featured-card-lines {
    display: grid;
    gap: .28rem;
    padding: .85rem;
    border: 0;
    border-radius: .5rem;
    color: white;
    background: rgba(15, 23, 42, .72);
    box-shadow: 0 12px 28px rgba(0, 0, 0, .22);
    cursor: pointer;
    font: inherit;
    text-align: left;
    transition: background .2s ease, transform .2s ease;
}

.featured-card-lines:hover {
    background: rgba(15, 23, 42, .86);
    transform: translateY(-1px);
}

.featured-card-lines strong {
    font-size: 1.05rem;
}

.featured-card-lines span {
    color: rgba(255, 255, 255, .8);
    font-size: .9rem;
}

.modal-open {
    overflow: hidden;
}

.card-detail-modal {
    position: fixed;
    inset: 0;
    z-index: 50;
    display: grid;
    place-items: center;
    padding: 1rem;
}

.card-detail-modal[hidden] {
    display: none;
}

.card-detail-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, .58);
    backdrop-filter: blur(5px);
}

.card-detail-panel {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(16rem, .95fr) minmax(18rem, 1.05fr);
    gap: 1.2rem;
    width: min(58rem, 100%);
    max-height: min(42rem, calc(100svh - 2rem));
    overflow: auto;
    padding: 1.1rem;
    border: 1px solid rgba(255, 255, 255, .74);
    border-radius: .75rem;
    background: #fbfdfb;
    box-shadow: 0 28px 75px rgba(15, 23, 42, .38);
}

.card-detail-close {
    position: absolute;
    top: .7rem;
    right: .7rem;
    display: grid;
    width: 2.35rem;
    height: 2.35rem;
    place-items: center;
    border: 1px solid var(--line);
    border-radius: .45rem;
    background: white;
    color: var(--ink);
    cursor: pointer;
    font-size: 1.35rem;
    font-weight: 900;
    line-height: 1;
}

.card-detail-close:hover {
    border-color: #99d7cc;
    color: var(--accent-dark);
}

.card-detail-media {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .8rem;
    align-content: start;
    padding-top: 2.8rem;
}

.card-detail-media figure {
    display: grid;
    gap: .5rem;
    margin: 0;
}

.card-detail-media img,
.card-detail-image-empty {
    width: 100%;
    aspect-ratio: 5 / 7;
    border: 1px solid var(--line);
    border-radius: .55rem;
    background: white;
    object-fit: cover;
}

.card-detail-media img[hidden],
.card-detail-image-empty[hidden] {
    display: none;
}

.card-detail-image-empty {
    display: grid;
    place-items: center;
    padding: 1rem;
    color: var(--muted);
    font-weight: 900;
    text-align: center;
}

.card-detail-media figcaption {
    color: var(--muted);
    font-size: .82rem;
    font-weight: 900;
    text-align: center;
}

.card-detail-content {
    display: grid;
    align-content: start;
    gap: .75rem;
    padding: 2.8rem .35rem .35rem;
}

.card-detail-content h2 {
    margin: 0;
    padding-right: 2.5rem;
    font-size: clamp(1.7rem, 4vw, 2.55rem);
    line-height: 1;
}

.card-detail-content p {
    margin: 0;
    color: var(--muted);
    font-weight: 850;
    line-height: 1.45;
}

.card-detail-list {
    gap: .55rem;
    margin-top: .25rem;
}

.card-detail-list div {
    align-items: start;
    padding: .58rem 0;
}

.sample-card {
    position: relative;
    display: grid;
    grid-template-rows: auto 1fr auto;
    min-height: 20rem;
    padding: 1rem;
    overflow: hidden;
    border: .55rem solid #fff;
    border-radius: .7rem;
    background:
        linear-gradient(145deg, color-mix(in srgb, var(--c2) 35%, transparent), transparent 58%),
        radial-gradient(circle at 20% 18%, var(--c3), transparent 16rem),
        linear-gradient(150deg, var(--c1), var(--c2));
    box-shadow: var(--shadow);
    color: white;
}

.sample-card.large {
    width: min(25rem, 82vw);
    aspect-ratio: 3 / 4.25;
    transform: rotate(3deg);
}

.card-badge {
    justify-self: start;
    padding: .32rem .55rem;
    border-radius: .35rem;
    background: rgba(255, 255, 255, .9);
    color: var(--ink);
    font-size: .72rem;
    font-weight: 900;
}

.card-art {
    align-self: center;
    justify-self: center;
    display: grid;
    width: 58%;
    aspect-ratio: 1;
    place-items: center;
    border: 1px solid rgba(255, 255, 255, .55);
    border-radius: 50%;
    background: rgba(255, 255, 255, .15);
    box-shadow: inset 0 0 45px rgba(255, 255, 255, .22);
    font-size: clamp(2.5rem, 7vw, 5rem);
    font-weight: 950;
}

.card-lines {
    display: grid;
    gap: .25rem;
    padding: .8rem;
    border-radius: .45rem;
    background: rgba(15, 23, 42, .62);
}

.card-lines span {
    color: rgba(255, 255, 255, .78);
    font-size: .85rem;
}

.notice {
    margin: 0 0 1rem;
    padding: 1rem;
    border: 1px solid #99f6e4;
    border-radius: .5rem;
    background: #f0fdfa;
    color: #115e59;
    font-weight: 800;
}

.notice.error {
    border-color: #fecdd3;
    background: #fff1f2;
    color: #9f1239;
}

.login-body {
    min-height: 100svh;
    display: grid;
    place-items: center;
}

.login-shell {
    width: min(28rem, calc(100% - 2rem));
    padding: 0;
}

.register-shell {
    width: min(46rem, calc(100% - 2rem));
}

.login-panel {
    display: grid;
    gap: 1.3rem;
    padding: 1.35rem;
    border: 1px solid var(--line);
    border-radius: .75rem;
    background: rgba(255, 255, 255, .92);
    box-shadow: var(--shadow);
}

.login-brand {
    justify-content: start;
    color: var(--ink);
}

.login-brand span {
    max-width: none;
    font-size: 1.1rem;
    line-height: 1.1;
    text-shadow: none;
}

.login-copy {
    display: grid;
    gap: .35rem;
}

.login-copy h1 {
    margin: 0;
    font-size: clamp(1.9rem, 7vw, 2.65rem);
    line-height: 1;
    letter-spacing: 0;
}

.login-secondary {
    display: grid;
    gap: .7rem;
    padding-top: .95rem;
    border-top: 1px solid var(--line);
    color: var(--muted);
    font-weight: 800;
    text-align: center;
}

.page-heading {
    display: grid;
    gap: .45rem;
    max-width: 46rem;
    margin: 1rem 0 2rem;
}

.page-heading h1 {
    margin: 0;
    font-size: clamp(2.2rem, 6vw, 4.7rem);
    line-height: .98;
    letter-spacing: 0;
}

.page-heading p:last-child {
    margin: 0;
    color: var(--muted);
    font-size: 1.05rem;
    line-height: 1.7;
}

.metrics {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-bottom: 2rem;
}

.metrics div,
.panel,
.listing-card {
    border: 1px solid var(--line);
    border-radius: .65rem;
    background: rgba(255, 255, 255, .88);
    box-shadow: 0 10px 28px rgba(23, 33, 31, .07);
}

.metrics div {
    padding: 1rem;
}

.metrics span {
    display: block;
    font-size: clamp(1.4rem, 3vw, 2.1rem);
    font-weight: 950;
}

.metrics p {
    margin: .2rem 0 0;
    color: var(--muted);
}

.quick-links {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
}

.action-card {
    display: grid;
    gap: .35rem;
    padding: 1.1rem;
}

.action-card span {
    color: var(--accent-dark);
    font-size: .78rem;
    font-weight: 900;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.action-card strong {
    font-size: 1.15rem;
}

.action-card:hover {
    border-color: #99d7cc;
    transform: translateY(-1px);
}

.market-layout {
    display: grid;
    grid-template-columns: 18rem minmax(0, 1fr);
    gap: 1.25rem;
    align-items: start;
}

.panel {
    padding: 1.1rem;
}

.filters {
    position: sticky;
    top: 5.3rem;
}

.filters h2,
.section-heading h2 {
    margin: .25rem 0 0;
}

.stacked-form,
.listing-form {
    display: grid;
    gap: .9rem;
}

.registration-form {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.registration-form > button,
.registration-form input[type="hidden"],
.registration-form .form-hint {
    grid-column: 1 / -1;
}

.registration-form .form-full {
    grid-column: 1 / -1;
}

.phone-input-row {
    display: grid;
    grid-template-columns: 5.8rem minmax(0, 1fr);
    gap: .5rem;
}

.password-input-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 2.7rem;
    gap: .5rem;
}

.password-toggle {
    display: grid;
    width: 2.7rem;
    min-height: 2.7rem;
    place-items: center;
    padding: 0;
    border: 1px solid var(--line);
    border-radius: .42rem;
    background: #f8faf7;
    color: var(--accent-dark);
    cursor: pointer;
}

.password-toggle svg {
    width: 1.15rem;
    height: 1.15rem;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.password-toggle .icon-eye-off,
.password-toggle.is-visible .icon-eye {
    display: none;
}

.password-toggle.is-visible .icon-eye-off {
    display: block;
}

.phone-code {
    text-align: center;
    font-weight: 900;
}

.form-hint {
    margin: -.35rem 0 .1rem;
    color: var(--muted);
    font-size: .88rem;
    line-height: 1.45;
}

label {
    display: grid;
    gap: .35rem;
    color: var(--muted);
    font-size: .9rem;
    font-weight: 800;
}

input,
select,
textarea {
    width: 100%;
    min-height: 2.7rem;
    padding: .72rem .78rem;
    border: 1px solid var(--line);
    border-radius: .42rem;
    background: white;
    color: var(--ink);
}

textarea {
    min-height: 7rem;
    resize: vertical;
    line-height: 1.5;
}

input[readonly] {
    background: #f3f7f5;
    color: var(--muted);
    cursor: not-allowed;
}

.locked-field {
    background: #f3f7f5;
    color: var(--muted);
    cursor: not-allowed;
    pointer-events: none;
}

input[type="file"] {
    padding: .58rem .72rem;
}

.image-upload-field {
    position: relative;
    display: grid;
    gap: .35rem;
    color: var(--muted);
    font-size: .9rem;
    font-weight: 800;
}

.image-upload-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .65rem;
}

.image-upload-row {
    display: grid;
    gap: .65rem;
    align-items: center;
}

.image-upload-row {
    grid-template-columns: minmax(0, 1fr) auto;
}

.image-upload-trigger {
    width: auto;
    min-height: 2.35rem;
    justify-self: start;
    padding: .55rem .85rem;
    border-color: var(--accent-dark);
    background: #f8faf7;
    color: var(--accent-dark);
    box-shadow: 0 4px 10px rgba(19, 78, 74, .12);
    cursor: pointer;
    font-size: .9rem;
    font-weight: 900;
    transition: background .2s ease, border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}

.image-upload-trigger:hover,
.image-upload-trigger:focus-visible {
    border-color: var(--accent);
    background: #eef8f5;
    box-shadow: 0 8px 16px rgba(15, 118, 110, .16);
    transform: translateY(-1px);
}

.image-upload-trigger:focus-visible {
    outline: 3px solid rgba(183, 121, 31, .32);
    outline-offset: .16rem;
}

.image-upload-menu {
    position: absolute;
    top: calc(100% - .15rem);
    left: 0;
    z-index: 8;
    display: grid;
    width: min(100%, 18rem);
    gap: .35rem;
    padding: .4rem;
    border: 1px solid var(--line);
    border-radius: .5rem;
    background: white;
    box-shadow: 0 14px 34px rgba(23, 33, 31, .16);
}

.image-upload-menu[hidden] {
    display: none;
}

.image-upload-menu button {
    min-height: 2.35rem;
    padding: .55rem .65rem;
    border: 0;
    border-radius: .35rem;
    background: #f3f7f5;
    color: var(--accent-dark);
    cursor: pointer;
    font-weight: 900;
    text-align: left;
}

.image-upload-menu button:hover {
    background: #eef8f5;
}

.visually-hidden-file {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.field-hint {
    color: var(--muted);
    font-size: .82rem;
    font-weight: 700;
    line-height: 1.4;
}

.inline-scan-status {
    color: var(--accent-dark);
    font-weight: 900;
    white-space: nowrap;
}

.listing-form.is-scanning input,
.listing-form.is-scanning select,
.listing-form.is-scanning button {
    cursor: progress;
}

.listing-form.is-scanning label:not(.image-upload-field) {
    opacity: .62;
}

.prefixed-input {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    min-height: 2.7rem;
    border: 1px solid var(--line);
    border-radius: .42rem;
    background: white;
    overflow: hidden;
}

.prefixed-input span {
    align-self: stretch;
    display: grid;
    place-items: center;
    padding: 0 .78rem;
    border-right: 1px solid var(--line);
    background: #f3f7f5;
    color: var(--muted);
    font-size: .86rem;
    font-weight: 900;
}

.prefixed-input input {
    min-height: auto;
    border: 0;
    border-radius: 0;
}

.seller-note {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--line);
}

.seller-note p {
    margin: .35rem 0 0;
    color: var(--muted);
    line-height: 1.5;
}

.section-heading {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.section-heading > span,
.section-heading > strong {
    color: var(--accent-dark);
    font-weight: 950;
}

.section-heading.compact {
    align-items: center;
}

.card-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
}

.listing-card {
    overflow: hidden;
}

.listing-card .button {
    white-space: nowrap;
}

.requires-login-button {
    padding-inline: .55rem;
    font-size: .78rem;
}

.listing-card .sample-card {
    min-height: 15rem;
    border-width: .35rem;
    border-radius: 0;
    box-shadow: none;
}

.market-card-photo {
    min-height: 15rem;
    padding: 2.15rem .65rem .75rem;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    transform: none;
}

.market-card-photo:hover {
    box-shadow: none;
    transform: translateY(-.15rem);
}

.market-card-photo img {
    width: min(100%, 13.5rem);
    justify-self: center;
}

.market-card-photo .card-image-placeholder {
    width: min(100%, 13.5rem);
    justify-self: center;
}

.market-card-photo .featured-card-lines {
    padding: .75rem;
}

.listing-body {
    display: grid;
    gap: .85rem;
    padding: 1rem;
}

.listing-detail-button {
    display: grid;
    gap: .9rem;
    width: 100%;
    padding: .9rem;
    border: 1px solid #d7e1dc;
    border-radius: .55rem;
    background: #f3f7f5;
    color: inherit;
    cursor: pointer;
    font: inherit;
    text-align: left;
    transition: background .2s ease, border-color .2s ease, transform .2s ease;
}

.listing-detail-button:hover,
.listing-detail-button:focus-visible {
    border-color: #99d7cc;
    background: #eef8f5;
    transform: translateY(-1px);
}

.listing-detail-button:focus-visible {
    outline: 3px solid rgba(183, 121, 31, .34);
    outline-offset: .15rem;
}

.listing-title {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: .75rem;
}

.listing-name {
    color: var(--ink);
    font-size: 1.08rem;
    font-weight: 950;
    line-height: 1.25;
}

.listing-title strong {
    color: var(--accent-dark);
    white-space: nowrap;
}

.listing-facts {
    display: grid;
    gap: .45rem;
}

.listing-fact {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    border-bottom: 1px dashed var(--line);
    padding-bottom: .35rem;
}

.listing-fact span {
    color: var(--muted);
    font-weight: 800;
}

.listing-fact strong {
    color: var(--ink);
    font-weight: 850;
    text-align: right;
}

dl {
    display: grid;
    gap: .45rem;
    margin: 0;
}

dl div {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    border-bottom: 1px dashed var(--line);
    padding-bottom: .35rem;
}

dt {
    color: var(--muted);
    font-weight: 800;
}

dd {
    margin: 0;
    text-align: right;
}

.commerce-zone {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(20rem, .85fr);
    gap: 1.25rem;
    margin-top: 1.25rem;
}

.listing-form {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.listing-form .form-hint {
    grid-column: 1 / -1;
}

.listing-form button {
    grid-column: 1 / -1;
}

.card-scan-status:empty {
    display: none;
}

.cart-items {
    display: grid;
    gap: .75rem;
    margin-bottom: 1rem;
}

.cart-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: .8rem;
    border: 1px solid var(--line);
    border-radius: .45rem;
    background: #fbfdfb;
}

.cart-item span {
    display: block;
    margin-top: .2rem;
    color: var(--muted);
    font-size: .9rem;
}

.cart-item button {
    border: 0;
    background: transparent;
    color: var(--rose);
    cursor: pointer;
    font-weight: 900;
}

.messages-layout {
    display: grid;
    grid-template-columns: minmax(17rem, .7fr) minmax(0, 1.3fr);
    gap: 1.25rem;
    align-items: start;
}

.conversation-list {
    position: sticky;
    top: 5.3rem;
}

.conversation-items {
    display: grid;
    gap: .7rem;
}

.conversation-item {
    display: grid;
    gap: .45rem;
    padding: .85rem;
    border: 1px solid var(--line);
    border-radius: .55rem;
    background: #f8faf7;
    transition: background .2s ease, border-color .2s ease, transform .2s ease;
}

.conversation-item:hover,
.conversation-item.active {
    border-color: #99d7cc;
    background: #eef8f5;
    transform: translateY(-1px);
}

.conversation-link {
    display: grid;
    gap: .45rem;
}

.conversation-link span {
    display: grid;
    gap: .2rem;
}

.conversation-link em,
.conversation-link small,
.conversation-link p {
    color: var(--muted);
}

.conversation-link em {
    font-style: normal;
    font-weight: 850;
}

.conversation-link small {
    font-size: .78rem;
    font-weight: 850;
}

.conversation-link p {
    margin: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.conversation-card-button,
.conversation-card-missing {
    justify-self: start;
    min-height: 2.2rem;
    padding: .55rem .7rem;
    border: 1px solid var(--line);
    border-radius: .42rem;
    background: white;
    color: var(--accent-dark);
    font-size: .82rem;
    font-weight: 900;
}

.conversation-card-button {
    cursor: pointer;
}

.conversation-card-button:hover,
.conversation-card-button:focus-visible {
    border-color: #99d7cc;
    background: #f0fdfa;
}

.conversation-card-missing {
    color: var(--muted);
}

.conversation-panel,
.message-form {
    display: grid;
    gap: 1rem;
}

.conversation-header {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 1rem;
    border-bottom: 1px solid var(--line);
    padding-bottom: 1rem;
}

.conversation-header-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: .65rem;
}

.conversation-header h2,
.empty-conversation h2 {
    margin: .25rem 0;
    font-size: clamp(1.65rem, 4vw, 2.55rem);
    line-height: 1;
}

.conversation-header p,
.empty-conversation p {
    margin: 0;
    color: var(--muted);
    line-height: 1.5;
}

.message-thread {
    display: grid;
    gap: .75rem;
    max-height: 30rem;
    overflow: auto;
    padding: .2rem;
}

.message-bubble {
    display: grid;
    gap: .45rem;
    width: min(33rem, 88%);
    padding: .85rem;
    border: 1px solid var(--line);
    border-radius: .65rem;
    background: #f8faf7;
}

.message-bubble.mine {
    justify-self: end;
    border-color: #99d7cc;
    background: #eef8f5;
}

.message-bubble.theirs {
    justify-self: start;
}

.message-bubble div {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .75rem;
}

.message-bubble span {
    color: var(--muted);
    font-size: .78rem;
    font-weight: 850;
    white-space: nowrap;
}

.message-bubble p {
    margin: 0;
    color: var(--ink);
    line-height: 1.55;
}

.empty-state {
    margin: 0;
    color: var(--muted);
    line-height: 1.6;
}

@media (max-width: 980px) {
    .hero,
    .market-layout,
    .commerce-zone,
    .messages-layout {
        grid-template-columns: 1fr;
    }

    .hero {
        min-height: auto;
    }

    .filters,
    .conversation-list {
        position: static;
    }

    .card-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .card-detail-panel {
        grid-template-columns: 1fr;
    }

    .card-detail-media {
        padding-top: 2.8rem;
    }

    .card-detail-content {
        padding-top: .35rem;
    }
}

@media (max-width: 680px) {
    .site-header {
        align-items: start;
        flex-direction: column;
    }

    .brand span {
        max-width: 100%;
    }

    .header-actions {
        width: 100%;
        align-items: start;
        justify-content: space-between;
        gap: 1rem;
        flex-wrap: wrap;
    }

    .top-nav {
        flex-wrap: wrap;
    }

    .hero-copy h1 {
        font-size: 3rem;
        line-height: .95;
    }

    .metrics,
    .card-grid,
    .quick-links,
    .registration-form,
    .listing-form {
        grid-template-columns: 1fr;
    }

    .image-upload-row {
        grid-template-columns: 1fr;
    }

    .section-heading,
    .listing-title,
    .listing-fact,
    .conversation-header,
    dl div {
        align-items: start;
        flex-direction: column;
    }

    .listing-fact strong,
    dd {
        text-align: left;
    }

    .card-detail-media {
        grid-template-columns: 1fr;
    }

    .message-bubble {
        width: 100%;
    }

    .message-bubble div {
        align-items: start;
        flex-direction: column;
    }

    .conversation-header-actions {
        justify-content: flex-start;
    }
}
