/* =====================================================================
   NFT MARKETPLACE PAGE — fully self-contained, all classes/vars prefixed
   "nftm-" so nothing collides with the site's global stylesheets (which
   are loaded on every page, including this one).
   ===================================================================== */
:root {
    /* Deeper obsidian base for a premium, high-contrast feel. */
    --nftm-void: #04060d;
    --nftm-ink: #070a13;
    --nftm-slate: #10151f;
    --nftm-slate-2: #1a2130;
    --nftm-line: rgba(255, 255, 255, 0.08);
    --nftm-line-2: rgba(255, 255, 255, 0.16);

    /* Glass surfaces — translucent so the ambient backdrop glows through,
       paired with backdrop-filter blur on cards. */
    --nftm-glass: rgba(20, 27, 42, 0.55);
    --nftm-glass-2: rgba(255, 255, 255, 0.035);
    --nftm-glass-hi: rgba(255, 255, 255, 0.06);

    --nftm-iris: #9333ea;
    --nftm-iris-deep: #6d28d9;
    --nftm-lilac: #7aa2f7;
    --nftm-aurora: #45e6cf;
    --nftm-teal: #00d4b8;
    --nftm-blue: #3b82f6;
    --nftm-pink: #e879f9;

    --nftm-text: #f4f7fb;
    --nftm-text-dim: #9aa7bd;
    --nftm-text-mute: #64748b;

    --nftm-grad: linear-gradient(135deg, #6d28d9 0%, #3b82f6 55%, #00d4b8 120%);
    --nftm-grad-2: linear-gradient(135deg, #9333ea 0%, #3b82f6 100%);
    --nftm-glow: 0 0 0 1px rgba(147, 51, 234, .35), 0 24px 70px -28px rgba(147, 51, 234, .5);
    --nftm-elev: 0 28px 80px -32px rgba(0, 0, 0, .8);

    --nftm-radius: 18px;
    --nftm-radius-lg: 26px;
    --nftm-font-display: 'Space Grotesk', sans-serif;
    --nftm-font-body: 'Inter', sans-serif;
    --nftm-font-mono: 'Space Mono', monospace;
}

.nftm-page * {
    box-sizing: border-box;
}

.nftm-page {
    background: var(--nftm-ink);
    color: var(--nftm-text);
    font-family: var(--nftm-font-body);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

.nftm-page a {
    color: inherit;
    text-decoration: none;
}

.nftm-wrap {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 32px;
}

.nftm-eyebrow {
    font-family: var(--nftm-font-mono);
    font-size: 12px;
    letter-spacing: .18em;
    text-transform: uppercase;
    color: var(--nftm-aurora);
    display: inline-block;
}

.nftm-mono {
    font-family: var(--nftm-font-mono);
}

.nftm-page h1,
.nftm-page h2,
.nftm-page h3 {
    font-family: var(--nftm-font-display);
    font-weight: 600;
    line-height: 1.08;
    letter-spacing: -.02em;
    margin: 0;
}

.nftm-grad-text {
    background: var(--nftm-grad);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nftm-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: var(--nftm-font-display);
    font-weight: 500;
    font-size: 15px;
    padding: 12px 22px;
    border-radius: 12px;
    cursor: pointer;
    border: none;
    transition: transform .15s ease, box-shadow .15s ease, background .15s ease, color .15s ease, border-color .15s ease;
}

.nftm-btn-primary {
    background: var(--nftm-grad);
    color: #ffffff;
    box-shadow: 0 8px 30px -8px rgba(95, 10, 135, .6);
}

.nftm-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 40px -8px rgba(44, 115, 210, .65);
}

.nftm-btn-ghost {
    background: transparent;
    color: var(--nftm-text);
    border: 1px solid var(--nftm-line-2);
}

.nftm-btn-ghost:hover {
    border-color: var(--nftm-iris);
    background: rgba(123, 31, 162, .12);
}

.nftm-btn-ghost.nftm-connected {
    border-color: var(--nftm-teal);
    color: var(--nftm-aurora);
    background: rgba(0, 194, 168, .10);
}

.nftm-page section {
    position: relative;
}

.nftm-sec-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 24px;
    margin-bottom: 34px;
}

.nftm-sec-head h2 {
    font-size: 34px;
}

.nftm-sec-head p {
    color: var(--nftm-text-dim);
    font-size: 15px;
    margin-top: 8px;
    max-width: 420px;
}

.nftm-see-all {
    font-family: var(--nftm-font-mono);
    font-size: 13px;
    color: var(--nftm-lilac);
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: none;
    border: none;
    cursor: pointer;
}

.nftm-see-all:hover {
    color: var(--nftm-aurora);
}

.nftm-art {
    border-radius: 12px;
    aspect-ratio: 1/1;
    position: relative;
    overflow: hidden;
    background: var(--nftm-slate-2);
}

.nftm-art img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .5s ease;
}

.nftm-nft-card:hover .nftm-art img {
    transform: scale(1.06);
}

/* ============ HEADER / NAV ============ */
/* Floats transparently over the hero at the top of the page — same pattern
   as the site's own .site-header — and only gains a solid/blurred
   background once scrolled (.nftm-scrolled, toggled in nft-marketplace.js). */
.nftm-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1050;
    /* .nftm-page sets overflow-x:hidden for the page body; on this element
       that single-axis value forces the other axis to auto, clipping the
       mobile nav-collapse panel (which sits below the header's own 74px
       box) to nothing. Reset both axes back to visible. */
    overflow: visible;
    background: transparent;
    border-bottom: 1px solid transparent;
    transition: background .4s cubic-bezier(.16, 1, .3, 1),
        border-color .4s ease,
        backdrop-filter .4s ease,
        box-shadow .4s ease;
}

.nftm-header.nftm-scrolled {
    background: rgba(15, 12, 24, .82);
    backdrop-filter: blur(14px);
    border-bottom-color: var(--nftm-line);
    box-shadow: 0 8px 32px rgba(0, 0, 0, .22);
}

.nftm-nav {
    display: flex;
    align-items: center;
    gap: 28px;
    height: 74px;
}

.nftm-brand {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.nftm-brand img {
    max-width: 200px;
    height: 52px;
    object-fit: contain;
}

.nftm-nav-links {
    display: flex;
    align-items: center;
    gap: 26px;
    font-size: 15px;
    font-weight: 500;
}

.nftm-nav-links a,
.nftm-drop-toggle {
    color: var(--nftm-text-dim);
    transition: color .15s;
    background: none;
    border: none;
    cursor: pointer;
    font: inherit;
}

.nftm-nav-links a:hover,
.nftm-nav-links a.nftm-active,
.nftm-drop-toggle:hover,
.nftm-has-drop.nftm-drop-open>.nftm-drop-toggle {
    color: var(--nftm-text);
}

/* ===== nav dropdowns ===== */
.nftm-has-drop {
    position: relative;
}

.nftm-drop-toggle {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 0;
}

.nftm-drop-toggle i {
    font-size: 12px;
    transition: transform .2s ease;
}

.nftm-has-drop:hover>.nftm-drop-toggle i,
.nftm-has-drop.nftm-drop-open>.nftm-drop-toggle i {
    transform: rotate(180deg);
}

.nftm-drop {
    position: absolute;
    top: 100%;
    left: 0;
    z-index: 30;
    min-width: 224px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    margin-top: 14px;
    padding: 10px;
    border: 1px solid var(--nftm-line);
    border-radius: 16px;
    background: rgba(15, 12, 24, .97);
    backdrop-filter: blur(14px);
    box-shadow: 0 30px 60px -24px rgba(0, 0, 0, .75);
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: opacity .2s ease, transform .2s ease, visibility .2s;
}

/* invisible bridge across the 14px gap so the panel doesn't close as the
   pointer travels from the toggle down into it */
.nftm-drop::before {
    content: "";
    position: absolute;
    top: -14px;
    left: 0;
    right: 0;
    height: 14px;
}

.nftm-has-drop:hover>.nftm-drop,
.nftm-has-drop.nftm-drop-open>.nftm-drop {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.nftm-drop a {
    display: block;
    padding: 9px 12px;
    border-radius: 10px;
    font-size: 14px;
    white-space: nowrap;
    transition: background .15s, color .15s;
}

.nftm-drop a:hover {
    background: rgba(255, 255, 255, .06);
    color: var(--nftm-text);
}

.nftm-nav-search {
    flex: 1;
    max-width: 300px;
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--nftm-slate);
    border: 1px solid var(--nftm-line);
    border-radius: 12px;
    padding: 9px 14px;
    color: var(--nftm-text-mute);
    font-size: 14px;
}

.nftm-nav-search input {
    background: none;
    border: none;
    outline: none;
    color: var(--nftm-text);
    font-family: var(--nftm-font-body);
    font-size: 14px;
    width: 100%;
}

.nftm-nav-search input::placeholder {
    color: var(--nftm-text-mute);
}

.nftm-nav-actions {
    display: flex;
    gap: 10px;
    margin-left: auto;
}

.nftm-nav-actions .nftm-btn {
    padding: 10px 18px;
    font-size: 14px;
}

/* Wrapper stays inert on desktop — display:contents lets nav-links/search/
   actions participate directly in the .nftm-nav flex row exactly as if this
   div weren't there. Only takes over as a real panel under the 900px
   breakpoint (see responsive section below). */
.nftm-nav-collapse {
    display: contents;
}

.nftm-nav-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: var(--nftm-slate);
    border: 1px solid var(--nftm-line);
    border-radius: 10px;
    color: var(--nftm-text);
    font-size: 20px;
    cursor: pointer;
    margin-left: auto;
}

/* ============ SEARCH RESULTS DROPDOWN ============
   position:fixed (not absolute) so it's immune to any ancestor's overflow/
   stacking context — top/left/width are set inline via JS to match the
   search input's own screen position (see nft-marketplace.js), so it always
   renders as a normal dropdown directly under the box. */
.nftm-search-wrap {
    position: relative;
}

.nftm-search-results {
    position: fixed;
    background: var(--nftm-slate);
    border: 1px solid var(--nftm-line-2);
    border-radius: 12px;
    box-shadow: 0 20px 50px -10px rgba(0, 0, 0, .6);
    max-height: 320px;
    overflow-y: auto;
    display: none;
    z-index: 100011;
}

.nftm-search-results.nftm-show {
    display: block;
}

.nftm-search-result {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    cursor: pointer;
    border-bottom: 1px solid var(--nftm-line);
    font-size: 14px;
}

.nftm-search-result:last-child {
    border-bottom: none;
}

.nftm-search-result:hover {
    background: var(--nftm-slate-2);
}

.nftm-search-result img {
    width: 34px;
    height: 34px;
    border-radius: 8px;
    object-fit: cover;
    flex-shrink: 0;
}

.nftm-search-result .nftm-sr-name {
    font-weight: 600;
    display: block;
}

.nftm-search-result .nftm-sr-creator {
    color: var(--nftm-text-mute);
    font-size: 12px;
}

.nftm-search-empty {
    padding: 16px;
    text-align: center;
    color: var(--nftm-text-mute);
    font-size: 13px;
}

/* ============ HERO ============ */
.nftm-hero {
    /* Extra top clearance since .nftm-header now floats over this section
       (position:fixed, out of flow) instead of reserving its own space. */
    padding: 128px 0 72px;
    overflow: hidden;
}

.nftm-hero::before {
    content: "";
    position: absolute;
    top: -160px;
    left: -120px;
    width: 640px;
    height: 640px;
    background: radial-gradient(circle, rgba(95, 10, 135, .45), transparent 62%);
    filter: blur(30px);
    z-index: 0;
}

.nftm-hero::after {
    content: "";
    position: absolute;
    top: -60px;
    right: -140px;
    width: 520px;
    height: 520px;
    background: radial-gradient(circle, rgba(44, 115, 210, .30), transparent 60%);
    filter: blur(30px);
    z-index: 0;
}

.nftm-hero .nftm-wrap {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 1.1fr .9fr;
    gap: 56px;
    align-items: center;
}

.nftm-hero h1 {
    font-size: 64px;
    font-weight: 700;
    margin: 20px 0 22px;
}

.nftm-hero p.nftm-lead {
    font-size: 18px;
    color: var(--nftm-text-dim);
    max-width: 460px;
    margin-bottom: 32px;
}

.nftm-hero-cta {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
}

.nftm-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
    margin-top: 56px;
    grid-column: 1/-1;
}

.nftm-stat {
    background: var(--nftm-slate);
    border: 1px solid var(--nftm-line);
    border-radius: 14px;
    padding: 20px;
}

.nftm-stat .nftm-num {
    font-family: var(--nftm-font-mono);
    font-weight: 700;
    font-size: 26px;
    color: var(--nftm-text);
}

.nftm-stat .nftm-lbl {
    font-size: 13px;
    color: var(--nftm-text-mute);
    margin-top: 4px;
}

.nftm-showcase {
    position: relative;
}

.nftm-show-card {
    background: var(--nftm-slate);
    border: 1px solid var(--nftm-line-2);
    border-radius: 22px;
    padding: 16px;
    box-shadow: 0 30px 80px -30px rgba(44, 115, 210, .5);
}

.nftm-show-card .nftm-art {
    aspect-ratio: 4/3;
}

.nftm-show-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 16px;
}

.nftm-show-meta .nftm-who {
    display: flex;
    align-items: center;
    gap: 10px;
}

.nftm-avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: var(--nftm-grad);
    flex-shrink: 0;
    object-fit: cover;
}

.nftm-show-meta .nftm-who b {
    font-family: var(--nftm-font-display);
    font-size: 15px;
    font-weight: 600;
    display: block;
}

.nftm-show-meta .nftm-who span {
    font-size: 12px;
    color: var(--nftm-text-mute);
}

.nftm-bid-box {
    text-align: right;
}

.nftm-bid-box .nftm-k {
    font-size: 11px;
    color: var(--nftm-text-mute);
    text-transform: uppercase;
    letter-spacing: .1em;
}

.nftm-bid-box .nftm-v {
    font-family: var(--nftm-font-mono);
    font-weight: 700;
    font-size: 18px;
    color: var(--nftm-aurora);
}

.nftm-float-tag {
    position: absolute;
    top: -14px;
    right: -14px;
    background: var(--nftm-void);
    border: 1px solid var(--nftm-line-2);
    border-radius: 12px;
    padding: 10px 14px;
    font-family: var(--nftm-font-mono);
    font-size: 12px;
    color: var(--nftm-lilac);
    display: flex;
    align-items: center;
    gap: 7px;
    z-index: 2;
}

.nftm-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--nftm-teal);
    box-shadow: 0 0 10px var(--nftm-teal);
    flex-shrink: 0;
}

/* ============ shared section padding ============ */
.nftm-block {
    padding: 64px 0;
}

.nftm-block-alt {
    background: var(--nftm-void);
}

/* ============ CARD GRIDS ============ */
.nftm-card-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.nftm-nft-card {
    background: var(--nftm-slate);
    border: 1px solid var(--nftm-line);
    border-radius: var(--nftm-radius);
    padding: 14px;
    transition: transform .18s ease, border-color .18s ease, opacity .25s ease;
}

.nftm-nft-card.nftm-hidden {
    display: none;
}

.nftm-nft-card:hover {
    transform: translateY(-4px);
    border-color: var(--nftm-line-2);
}

.nftm-nft-card .nftm-art {
    margin-bottom: 14px;
}

.nftm-nft-card h3 {
    font-size: 17px;
    font-weight: 600;
    margin-bottom: 4px;
}

.nftm-nft-card .nftm-creator {
    font-size: 13px;
    color: var(--nftm-text-mute);
    margin-bottom: 14px;
}

.nftm-card-foot {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--nftm-line);
    padding-top: 12px;
}

.nftm-price .nftm-k {
    font-size: 11px;
    color: var(--nftm-text-mute);
    display: block;
}

.nftm-price .nftm-v {
    font-family: var(--nftm-font-mono);
    font-weight: 700;
    font-size: 15px;
    color: var(--nftm-aurora);
}

.nftm-likes {
    font-family: var(--nftm-font-mono);
    font-size: 13px;
    color: var(--nftm-text-dim);
    display: flex;
    align-items: center;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    border-radius: 8px;
    transition: color .15s;
}

.nftm-likes:hover {
    color: var(--nftm-lilac);
}

.nftm-likes.nftm-liked {
    color: #ff5c8a;
}

/* ============ LIVE AUCTIONS ============ */
.nftm-auc-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.nftm-auc-card {
    background: var(--nftm-slate);
    border: 1px solid var(--nftm-line);
    border-radius: var(--nftm-radius);
    padding: 14px;
    position: relative;
}

.nftm-auc-card .nftm-art {
    margin-bottom: 14px;
}

.nftm-timer {
    position: absolute;
    top: 24px;
    right: 24px;
    background: rgba(11, 8, 19, .82);
    border: 1px solid var(--nftm-line-2);
    border-radius: 10px;
    padding: 7px 11px;
    font-family: var(--nftm-font-mono);
    font-size: 13px;
    font-weight: 700;
    color: var(--nftm-aurora);
    letter-spacing: .03em;
}

.nftm-timer.nftm-ended {
    color: #ff5c5c;
}

.nftm-auc-card h3 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 12px;
}

.nftm-auc-foot {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nftm-bid-btn {
    font-family: var(--nftm-font-display);
    font-weight: 500;
    font-size: 14px;
    background: rgba(0, 194, 168, .12);
    border: 1px solid var(--nftm-teal);
    color: var(--nftm-aurora);
    padding: 8px 16px;
    border-radius: 10px;
    cursor: pointer;
    transition: .15s;
}

.nftm-bid-btn:hover {
    background: var(--nftm-teal);
    color: #0a0f1e;
}

.nftm-bid-btn:disabled {
    opacity: .45;
    cursor: not-allowed;
    background: transparent;
}

/* ============ TABS ============ */
.nftm-tabs {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 30px;
}

.nftm-tab {
    font-family: var(--nftm-font-mono);
    font-size: 13px;
    padding: 8px 16px;
    border-radius: 20px;
    border: 1px solid var(--nftm-line);
    background: transparent;
    color: var(--nftm-text-dim);
    cursor: pointer;
    transition: .15s;
}

.nftm-tab.nftm-on {
    background: var(--nftm-grad);
    color: #ffffff;
    border-color: transparent;
    font-weight: 700;
}

.nftm-tab:not(.nftm-on):hover {
    border-color: var(--nftm-line-2);
    color: var(--nftm-text);
}

/* ============ TOP SELLERS / BUYERS ============ */
.nftm-rank-cols {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.nftm-rank-panel {
    background: var(--nftm-slate);
    border: 1px solid var(--nftm-line);
    border-radius: var(--nftm-radius);
    padding: 8px;
}

.nftm-rank-panel .nftm-ph {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 16px 12px;
}

.nftm-rank-panel .nftm-ph h3 {
    font-size: 17px;
}

.nftm-rank-panel .nftm-ph .nftm-see-all {
    font-size: 12px;
}

.nftm-rank-row {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 11px 16px;
    border-radius: 12px;
    transition: background .15s;
}

.nftm-rank-row:hover {
    background: var(--nftm-slate-2);
}

.nftm-rank-row .nftm-no {
    font-family: var(--nftm-font-mono);
    font-size: 14px;
    color: var(--nftm-text-mute);
    width: 18px;
}

.nftm-rank-row .nftm-avatar {
    width: 40px;
    height: 40px;
}

.nftm-rank-row .nftm-info b {
    font-family: var(--nftm-font-display);
    font-size: 15px;
    font-weight: 600;
    display: block;
}

.nftm-rank-row .nftm-info span {
    font-family: var(--nftm-font-mono);
    font-size: 12px;
    color: var(--nftm-text-mute);
}

.nftm-rank-row .nftm-vol {
    margin-left: auto;
    font-family: var(--nftm-font-mono);
    font-weight: 700;
    font-size: 14px;
    color: var(--nftm-aurora);
}

/* ============ CATEGORIES ============ */
.nftm-cat-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 16px;
}

.nftm-cat {
    background: var(--nftm-slate);
    border: 1px solid var(--nftm-line);
    border-radius: 14px;
    padding: 22px 16px;
    text-align: center;
    transition: .18s;
    cursor: pointer;
}

.nftm-cat:hover {
    transform: translateY(-3px);
    border-color: var(--nftm-iris);
}

.nftm-cat .nftm-ic {
    width: 46px;
    height: 46px;
    border-radius: 12px;
    background: var(--nftm-grad);
    margin: 0 auto 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.nftm-cat b {
    font-family: var(--nftm-font-display);
    font-size: 15px;
    font-weight: 600;
    display: block;
}

.nftm-cat span {
    font-family: var(--nftm-font-mono);
    font-size: 12px;
    color: var(--nftm-text-mute);
}

/* ============ HOW IT WORKS ============ */
.nftm-steps {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.nftm-step {
    background: var(--nftm-slate);
    border: 1px solid var(--nftm-line);
    border-radius: var(--nftm-radius);
    padding: 26px 22px;
    position: relative;
}

.nftm-step .nftm-n {
    font-family: var(--nftm-font-mono);
    font-size: 13px;
    font-weight: 700;
    color: var(--nftm-aurora);
    letter-spacing: .1em;
}

.nftm-step .nftm-ic {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    background: rgba(123, 31, 162, .18);
    border: 1px solid var(--nftm-line-2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    margin: 16px 0;
}

.nftm-step h3 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 8px;
}

.nftm-step p {
    font-size: 14px;
    color: var(--nftm-text-dim);
    margin: 0;
}

/* ============ COLLECTIONS SPOTLIGHT ============ */
.nftm-coll-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.nftm-coll {
    background: var(--nftm-slate);
    border: 1px solid var(--nftm-line);
    border-radius: var(--nftm-radius);
    overflow: hidden;
    transition: .18s;
}

.nftm-coll:hover {
    border-color: var(--nftm-line-2);
    transform: translateY(-4px);
}

.nftm-coll .nftm-banner {
    height: 120px;
    background-size: cover;
    background-position: center;
}

.nftm-coll .nftm-body {
    padding: 0 18px 20px;
    position: relative;
}

.nftm-coll .nftm-avatar {
    width: 56px;
    height: 56px;
    border: 4px solid var(--nftm-slate);
    margin-top: -28px;
    margin-bottom: 12px;
}

.nftm-coll .nftm-name {
    display: flex;
    align-items: center;
    gap: 7px;
}

.nftm-coll .nftm-name b {
    font-family: var(--nftm-font-display);
    font-size: 17px;
    font-weight: 600;
}

.nftm-coll .nftm-verify {
    color: var(--nftm-aurora);
    font-size: 14px;
}

.nftm-coll .nftm-row {
    display: flex;
    gap: 24px;
    margin-top: 14px;
}

.nftm-coll .nftm-row .nftm-k {
    font-size: 11px;
    color: var(--nftm-text-mute);
    text-transform: uppercase;
    letter-spacing: .08em;
}

.nftm-coll .nftm-row .nftm-v {
    font-family: var(--nftm-font-mono);
    font-weight: 700;
    font-size: 15px;
    color: var(--nftm-text);
}

/* ============ NEWSLETTER ============ */
.nftm-cta-band {
    padding: 72px 0;
}

.nftm-cta-inner {
    background-image: url('https://picsum.photos/seed/nftm-cta-bg/1600/900');
    background-size: cover;
    background-position: center;
    border: 1px solid var(--nftm-line-2);
    border-radius: 26px;
    padding: 56px 48px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.nftm-cta-inner::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 50% 0%, rgba(95, 10, 135, .5), rgba(6, 6, 12, .82) 65%);
    z-index: 0;
}

.nftm-cta-inner>* {
    position: relative;
    z-index: 1;
}

.nftm-cta-inner h2 {
    font-size: 40px;
    font-weight: 700;
    margin: 12px 0 14px;
}

.nftm-cta-inner p {
    color: var(--nftm-text-dim);
    max-width: 440px;
    margin: 0 auto 30px;
}

.nftm-sub-form {
    display: flex;
    gap: 12px;
    max-width: 460px;
    margin: 0 auto;
}

.nftm-sub-form input {
    flex: 1;
    background: var(--nftm-void);
    border: 1px solid var(--nftm-line-2);
    border-radius: 12px;
    padding: 14px 18px;
    color: var(--nftm-text);
    font-family: var(--nftm-font-body);
    font-size: 15px;
    outline: none;
}

.nftm-sub-form input::placeholder {
    color: var(--nftm-text-mute);
}

.nftm-sub-msg {
    margin-top: 14px;
    font-size: 14px;
    font-family: var(--nftm-font-mono);
    min-height: 18px;
}

.nftm-sub-msg.nftm-ok {
    color: var(--nftm-aurora);
}

.nftm-sub-msg.nftm-err {
    color: #ff8080;
}

.nftm-socials {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin-top: 28px;
}

.nftm-soc {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: var(--nftm-void);
    border: 1px solid var(--nftm-line);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--nftm-text-dim);
    font-family: var(--nftm-font-mono);
    font-size: 13px;
    transition: .15s;
    cursor: pointer;
}

.nftm-soc:hover {
    border-color: var(--nftm-iris);
    color: var(--nftm-aurora);
}

/* ============ FOOTER ============ */
.nftm-footer {
    background: var(--nftm-void);
    border-top: 1px solid var(--nftm-line);
    padding: 56px 0 32px;
}

.nftm-foot-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}

.nftm-foot-brand p {
    color: var(--nftm-text-mute);
    font-size: 14px;
    max-width: 280px;
    margin-top: 14px;
}

.nftm-foot-col h4 {
    font-family: var(--nftm-font-display);
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 16px;
    color: var(--nftm-text);
}

.nftm-foot-col a {
    display: block;
    color: var(--nftm-text-dim);
    font-size: 14px;
    margin-bottom: 10px;
    transition: color .15s;
}

.nftm-foot-col a:hover {
    color: var(--nftm-aurora);
}

.nftm-foot-bar {
    border-top: 1px solid var(--nftm-line);
    padding-top: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.nftm-foot-bar span {
    font-family: var(--nftm-font-mono);
    font-size: 13px;
    color: var(--nftm-text-mute);
}

/* ============ CREATE / BID MODALS ============
   resources.css bumps .modal-backdrop to z-index:99998 for the site's own
   modals (which are themselves bumped above it) — without a matching bump
   here, that backdrop would sit above these modals via Bootstrap's default
   .modal z-index (1055) and swallow every click. */
.nftm-modal {
    z-index: 100005;
}

.nftm-modal .modal-content {
    background: var(--nftm-slate);
    color: var(--nftm-text);
    border: 1px solid var(--nftm-line-2);
    border-radius: 20px;
}

.nftm-modal .modal-header,
.nftm-modal .modal-footer {
    border-color: var(--nftm-line);
}

.nftm-modal .btn-close {
    filter: invert(1) grayscale(1) brightness(2);
}

.nftm-modal label {
    font-family: var(--nftm-font-mono);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: var(--nftm-text-mute);
    margin-bottom: 6px;
    display: block;
}

.nftm-modal .form-control {
    background: var(--nftm-void);
    border: 1px solid var(--nftm-line-2);
    color: var(--nftm-text);
}

.nftm-modal .form-control:focus {
    background: var(--nftm-void);
    color: var(--nftm-text);
    border-color: var(--nftm-iris);
    box-shadow: 0 0 0 .2rem rgba(123, 31, 162, .25);
}

.nftm-modal-art-preview {
    width: 100%;
    aspect-ratio: 1/1;
    border-radius: 12px;
    overflow: hidden;
    background: var(--nftm-void);
    border: 1px solid var(--nftm-line-2);
    margin-bottom: 16px;
}

.nftm-modal-art-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ============ TOASTS ============ */
.nftm-toast-stack {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 100020;
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: center;
    pointer-events: none;
}

.nftm-toast {
    background: var(--nftm-slate);
    border: 1px solid var(--nftm-line-2);
    color: var(--nftm-text);
    font-size: 14px;
    padding: 12px 20px;
    border-radius: 12px;
    box-shadow: 0 20px 50px -10px rgba(0, 0, 0, .6);
    opacity: 0;
    transform: translateY(10px);
    transition: opacity .25s ease, transform .25s ease;
}

.nftm-toast.nftm-show {
    opacity: 1;
    transform: translateY(0);
}

.nftm-toast.nftm-ok {
    border-color: var(--nftm-teal);
}

.nftm-toast.nftm-warn {
    border-color: #d9a441;
}

/* ============ responsive ============ */
@media(max-width:1100px) {
    .nftm-cat-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media(max-width:900px) {
    .nftm-hero .nftm-wrap {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .nftm-hero h1 {
        font-size: 44px;
    }

    .nftm-stats {
        grid-template-columns: repeat(2, 1fr);
    }

    .nftm-card-grid,
    .nftm-auc-grid,
    .nftm-steps,
    .nftm-coll-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .nftm-cat-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .nftm-rank-cols {
        grid-template-columns: 1fr;
    }

    .nftm-nav-toggle {
        display: flex;
    }

    .nftm-nav-collapse {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        flex-direction: column;
        align-items: stretch;
        gap: 18px;
        padding: 20px;
        background: rgba(15, 12, 24, .96);
        backdrop-filter: blur(14px);
        border-bottom: 1px solid var(--nftm-line);
        box-shadow: 0 20px 40px -20px rgba(0, 0, 0, .5);
    }

    .nftm-nav-collapse.nftm-nav-open {
        display: flex;
    }

    .nftm-nav-links {
        flex-direction: column;
        align-items: stretch;
        gap: 2px;
    }

    /* dropdowns flatten into click-accordions inside the mobile panel */
    .nftm-has-drop {
        width: 100%;
    }

    .nftm-drop-toggle,
    .nftm-nav-links>a {
        display: flex;
        justify-content: space-between;
        align-items: center;
        width: 100%;
        padding: 11px 0;
    }

    .nftm-drop {
        position: static;
        display: none;
        min-width: 0;
        margin: 0 0 6px;
        padding: 2px 0 6px 14px;
        border: none;
        border-left: 1px solid var(--nftm-line);
        border-radius: 0;
        background: none;
        backdrop-filter: none;
        box-shadow: none;
        /* neutralise the desktop hover-popover transition */
        opacity: 1;
        visibility: visible;
        transform: none;
        transition: none;
    }

    .nftm-drop::before {
        display: none;
    }

    /* display:none above beats the desktop :hover rule, so touch hover can't open it —
       only the .nftm-drop-open class (set on click) does */
    .nftm-has-drop.nftm-drop-open>.nftm-drop {
        display: flex;
    }

    .nftm-nav-search {
        max-width: none;
    }

    .nftm-nav-actions {
        margin-left: 0;
        flex-direction: column;
    }

    .nftm-foot-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media(max-width:560px) {
    .nftm-wrap {
        padding: 0 20px;
    }

    .nftm-card-grid,
    .nftm-auc-grid,
    .nftm-steps,
    .nftm-coll-grid,
    .nftm-cat-grid {
        grid-template-columns: 1fr 1fr;
    }

    .nftm-hero h1 {
        font-size: 34px;
    }

    .nftm-sec-head {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .nftm-sec-head p {
        max-width: none;
    }

    .nftm-sub-form {
        flex-direction: column;
    }
}

/* =====================================================================
   ★ PREMIUM ANIMATIONS & SCROLL EFFECTS ★
   Everything below is additive polish — ambient backdrop, scroll progress,
   count-up stats, creator marquee, 3D pointer tilt + spotlight, gradient
   hover glow, magnetic CTAs and a shimmering hero headline. All heavy
   motion is disabled under prefers-reduced-motion at the very bottom.
   ===================================================================== */

/* Content must sit above the fixed ambient backdrop (z-index:0). We do NOT
   give .nftm-page its own position/z-index on purpose: making it a stacking
   context would trap the fixed modals/toasts/search dropdown (z-index 100000+)
   beneath the header — the same trap the header comments warn about. Instead
   the ambient (z-index:0) and these sections (z-index:1) simply order against
   each other inside the shared root stacking context, while the high-z fixed
   overlays stay above everything. */
.nftm-page > section,
.nftm-page > .nftm-cta-band,
.nftm-marquee {
    position: relative;
    z-index: 1;
}

/* ---- Ambient animated backdrop --------------------------------------- */
.nftm-ambient {
    position: fixed;
    inset: 0;
    z-index: 0;
    overflow: hidden;
    pointer-events: none;
}

.nftm-ambient .nftm-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(90px);
    opacity: .55;
    will-change: transform;
}

.nftm-orb-1 {
    width: 620px;
    height: 620px;
    top: -180px;
    left: -160px;
    background: radial-gradient(circle, rgba(95, 10, 135, .55), transparent 65%);
    animation: nftm-orb-a 26s ease-in-out infinite;
}

.nftm-orb-2 {
    width: 560px;
    height: 560px;
    top: 32%;
    right: -180px;
    background: radial-gradient(circle, rgba(44, 115, 210, .42), transparent 65%);
    animation: nftm-orb-b 32s ease-in-out infinite;
}

.nftm-orb-3 {
    width: 500px;
    height: 500px;
    bottom: -160px;
    left: 30%;
    background: radial-gradient(circle, rgba(0, 194, 168, .30), transparent 65%);
    animation: nftm-orb-c 30s ease-in-out infinite;
}

.nftm-ambient .nftm-grid {
    position: absolute;
    inset: -50%;
    background-image:
        linear-gradient(rgba(255, 255, 255, .035) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, .035) 1px, transparent 1px);
    background-size: 56px 56px;
    mask-image: radial-gradient(circle at 50% 40%, #000 0%, transparent 72%);
    -webkit-mask-image: radial-gradient(circle at 50% 40%, #000 0%, transparent 72%);
    animation: nftm-grid-pan 40s linear infinite;
}

@keyframes nftm-orb-a {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50%      { transform: translate(80px, 60px) scale(1.12); }
}

@keyframes nftm-orb-b {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50%      { transform: translate(-70px, 50px) scale(1.08); }
}

@keyframes nftm-orb-c {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50%      { transform: translate(60px, -70px) scale(1.15); }
}

@keyframes nftm-grid-pan {
    0%   { transform: translate(0, 0); }
    100% { transform: translate(56px, 56px); }
}

/* ---- Shimmering hero headline ---------------------------------------- */
.nftm-hero .nftm-grad-text {
    background: linear-gradient(100deg,
        #7b1fa2 0%, #4d8de0 28%, #3dd9c2 50%, #4d8de0 72%, #7b1fa2 100%);
    background-size: 220% auto;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: nftm-shine 6s linear infinite;
}

@keyframes nftm-shine {
    to { background-position: 220% center; }
}

/* Live "bidding now" dot — soft pulse ring. */
.nftm-float-tag .nftm-dot {
    position: relative;
}

.nftm-float-tag .nftm-dot::after {
    content: "";
    position: absolute;
    inset: -4px;
    border-radius: 50%;
    border: 1px solid var(--nftm-teal);
    animation: nftm-ping 1.8s cubic-bezier(0, 0, .2, 1) infinite;
}

@keyframes nftm-ping {
    0%   { transform: scale(.6); opacity: .9; }
    80%, 100% { transform: scale(2.2); opacity: 0; }
}

/* Gentle float for the hero showcase card + its floating tag. */
.nftm-showcase .nftm-show-card {
    animation: nftm-float 7s ease-in-out infinite;
}

.nftm-showcase .nftm-float-tag {
    animation: nftm-float 7s ease-in-out infinite reverse;
}

@keyframes nftm-float {
    0%, 100% { transform: translateY(0); }
    50%      { transform: translateY(-12px); }
}

/* ---- Creator marquee ------------------------------------------------- */
.nftm-marquee {
    overflow: hidden;
    border-top: 1px solid var(--nftm-line);
    border-bottom: 1px solid var(--nftm-line);
    background: var(--nftm-void);
    padding: 18px 0;
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
    mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}

.nftm-marquee-track {
    display: flex;
    align-items: center;
    gap: 26px;
    width: max-content;
    animation: nftm-marquee 32s linear infinite;
}

.nftm-marquee:hover .nftm-marquee-track {
    animation-play-state: paused;
}

.nftm-marquee .nftm-tick {
    font-family: var(--nftm-font-display);
    font-weight: 600;
    font-size: 22px;
    letter-spacing: -.01em;
    color: var(--nftm-text-dim);
    white-space: nowrap;
    transition: color .2s;
}

.nftm-marquee .nftm-tick:hover {
    color: var(--nftm-text);
}

.nftm-marquee .nftm-tick-dot {
    color: var(--nftm-aurora);
    font-size: 12px;
    opacity: .7;
}

@keyframes nftm-marquee {
    to { transform: translateX(-50%); }
}

/* ---- 3D pointer tilt + spotlight glow on cards ----------------------- */
/* Cards read pointer position from --nftm-mx/--nftm-my (0–100%) and a tilt
   from --nftm-rx/--nftm-ry (deg), both set in nft-marketplace.js. These
   rules override the earlier plain translateY hovers (later in the file). */
.nftm-nft-card,
.nftm-auc-card,
.nftm-coll {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    transform: perspective(900px)
        rotateX(var(--nftm-rx, 0deg))
        rotateY(var(--nftm-ry, 0deg));
    transform-style: preserve-3d;
    transition: transform .3s cubic-bezier(.16, 1, .3, 1), border-color .25s ease;
}

.nftm-nft-card:hover,
.nftm-auc-card:hover,
.nftm-coll:hover {
    transform: perspective(900px)
        rotateX(var(--nftm-rx, 0deg))
        rotateY(var(--nftm-ry, 0deg))
        translateY(-6px);
    border-color: var(--nftm-line-2);
}

.nftm-step,
.nftm-cat {
    position: relative;
    isolation: isolate;
    overflow: hidden;
}

/* Spotlight follows the cursor within the card. */
.nftm-nft-card::before,
.nftm-auc-card::before,
.nftm-coll::before,
.nftm-step::before,
.nftm-cat::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    border-radius: inherit;
    background: radial-gradient(340px circle at var(--nftm-mx, 50%) var(--nftm-my, 0%),
        rgba(123, 31, 162, .22), transparent 60%);
    opacity: 0;
    transition: opacity .3s ease;
    pointer-events: none;
}

.nftm-nft-card:hover::before,
.nftm-auc-card:hover::before,
.nftm-coll:hover::before,
.nftm-step:hover::before,
.nftm-cat:hover::before {
    opacity: 1;
}

/* Animated gradient border on hover (masked ring). */
.nftm-nft-card::after,
.nftm-auc-card::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 1px;
    background: linear-gradient(135deg, var(--nftm-iris), var(--nftm-blue), var(--nftm-teal));
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    mask-composite: exclude;
    opacity: 0;
    transition: opacity .3s ease;
    pointer-events: none;
}

.nftm-nft-card:hover::after,
.nftm-auc-card:hover::after {
    opacity: .9;
}

/* Category tiles + steps keep a gentle lift on hover. */
.nftm-step {
    transition: transform .25s cubic-bezier(.16, 1, .3, 1), border-color .25s ease;
}

.nftm-step:hover {
    transform: translateY(-4px);
    border-color: var(--nftm-line-2);
}

/* ---- Magnetic CTA transition smoothing ------------------------------- */
/* JS sets an inline translate on pointer-move; the transition here makes the
   spring-back on pointer-leave feel elastic rather than snappy. */
.nftm-hero-cta .nftm-btn,
.nftm-cta-band .nftm-btn-primary {
    transition: transform .35s cubic-bezier(.16, 1, .3, 1),
        box-shadow .15s ease, background .15s ease;
    will-change: transform;
}

/* Nudge the arrow inside the primary hero CTA on hover. */
.nftm-hero-cta .nftm-btn-primary i {
    transition: transform .25s ease;
}

.nftm-hero-cta .nftm-btn-primary:hover i {
    transform: translateX(4px);
}

/* Count-up stats sit in a tabular-friendly figure so width doesn't jump. */
.nftm-stat .nftm-num {
    font-variant-numeric: tabular-nums;
}

/* ---- Reduced-motion: strip the heavy stuff -------------------------- */
@media (prefers-reduced-motion: reduce) {
    .nftm-orb-1, .nftm-orb-2, .nftm-orb-3,
    .nftm-ambient .nftm-grid,
    .nftm-hero .nftm-grad-text,
    .nftm-showcase .nftm-show-card,
    .nftm-showcase .nftm-float-tag,
    .nftm-float-tag .nftm-dot::after,
    .nftm-marquee-track {
        animation: none !important;
    }

    .nftm-nft-card,
    .nftm-auc-card,
    .nftm-coll {
        transform: none !important;
    }
}

/* =====================================================================
   ★★ PREMIUM REDESIGN v1.2 ★★  (glass surfaces · bento · asymmetry)
   Appended last so it wins the cascade over the base rules above.
   Refines the iris→teal identity into a deeper, glassier, more editorial
   layout without changing any JS hook classes.
   ===================================================================== */

/* ---- Typography & rhythm -------------------------------------------- */
.nftm-block {
    padding: 96px 0;
}

.nftm-wrap {
    max-width: 1240px;
}

.nftm-sec-head {
    margin-bottom: 46px;
    align-items: flex-end;
}

.nftm-sec-head h2 {
    font-size: clamp(30px, 4vw, 46px);
    letter-spacing: -.03em;
    line-height: 1.04;
}

.nftm-sec-head > div > h2 {
    margin-top: 10px;
}

.nftm-sec-head p {
    font-size: 16px;
    max-width: 460px;
    margin-top: 12px;
}

/* Eyebrow gets a leading gradient tick — editorial signature reused across
   every section header. */
.nftm-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--nftm-aurora);
    font-size: 11.5px;
}

.nftm-eyebrow::before {
    content: "";
    width: 26px;
    height: 2px;
    border-radius: 2px;
    background: linear-gradient(90deg, transparent, var(--nftm-aurora));
}

.nftm-see-all {
    padding: 9px 16px;
    border: 1px solid var(--nftm-line);
    border-radius: 999px;
    transition: border-color .2s, color .2s, background .2s;
}

.nftm-see-all:hover {
    border-color: var(--nftm-line-2);
    background: var(--nftm-glass-2);
}

/* ---- Glass surfaces -------------------------------------------------- */
.nftm-nft-card,
.nftm-auc-card,
.nftm-coll,
.nftm-step,
.nftm-cat,
.nftm-rank-panel,
.nftm-stat,
.nftm-show-card,
.nftm-cta-inner,
.nftm-modal .modal-content {
    background: var(--nftm-glass);
    -webkit-backdrop-filter: blur(18px) saturate(150%);
    backdrop-filter: blur(18px) saturate(150%);
    border: 1px solid var(--nftm-line);
    box-shadow: var(--nftm-elev), inset 0 1px 0 var(--nftm-glass-hi);
}

.nftm-nft-card,
.nftm-auc-card,
.nftm-cat,
.nftm-step {
    border-radius: var(--nftm-radius);
}

.nftm-coll,
.nftm-rank-panel {
    border-radius: var(--nftm-radius-lg);
}

.nftm-stat {
    border-radius: 16px;
    padding: 22px 20px;
    transition: transform .25s cubic-bezier(.16, 1, .3, 1), border-color .25s;
}

.nftm-stat:hover {
    transform: translateY(-4px);
    border-color: var(--nftm-line-2);
}

.nftm-stat .nftm-num {
    font-size: 30px;
    background: linear-gradient(120deg, #fff, var(--nftm-lilac));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Hover elevates + intensifies the ring/glow on the interactive cards. */
.nftm-nft-card:hover,
.nftm-auc-card:hover,
.nftm-coll:hover,
.nftm-cat:hover {
    border-color: rgba(147, 51, 234, .4);
    box-shadow: var(--nftm-glow), var(--nftm-elev);
}

/* ---- Buttons -------------------------------------------------------- */
.nftm-btn {
    font-weight: 600;
    letter-spacing: -.01em;
    border-radius: 14px;
    position: relative;
    overflow: hidden;
}

.nftm-btn-primary {
    background: var(--nftm-grad);
    background-size: 160% 160%;
    box-shadow: 0 10px 34px -10px rgba(109, 40, 217, .7);
    transition: transform .25s cubic-bezier(.16, 1, .3, 1), box-shadow .25s, background-position .5s;
}

.nftm-btn-primary:hover {
    background-position: 100% 0;
    box-shadow: 0 18px 48px -12px rgba(59, 130, 246, .7);
}

/* Sheen sweep across the primary button on hover. */
.nftm-btn-primary::after {
    content: "";
    position: absolute;
    top: 0;
    left: -120%;
    width: 60%;
    height: 100%;
    background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .35), transparent);
    transform: skewX(-18deg);
    transition: left .6s ease;
}

.nftm-btn-primary:hover::after {
    left: 130%;
}

.nftm-btn-ghost {
    background: var(--nftm-glass-2);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border-color: var(--nftm-line-2);
}

/* ---- Section backgrounds (deeper alternation) ----------------------- */
.nftm-block-alt {
    background: linear-gradient(180deg, var(--nftm-void), #06090f);
    border-top: 1px solid var(--nftm-line);
    border-bottom: 1px solid var(--nftm-line);
}

/* ===================================================================
   ASYMMETRIC HERO
   =================================================================== */
.nftm-hero {
    padding: 150px 0 84px;
}

.nftm-hero .nftm-wrap {
    grid-template-columns: 1.05fr .95fr;
    gap: 64px;
    align-items: center;
}

.nftm-hero h1 {
    font-size: clamp(46px, 6.4vw, 82px);
    line-height: .98;
    letter-spacing: -.035em;
    margin: 22px 0 24px;
}

.nftm-hero .nftm-eyebrow {
    padding: 7px 14px 7px 12px;
    border: 1px solid var(--nftm-line);
    border-radius: 999px;
    background: var(--nftm-glass-2);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
}

/* Layered depth for the showcase — a soft gradient plate sits behind the
   card and the floating tag lifts above it. */
.nftm-showcase::before {
    content: "";
    position: absolute;
    inset: -14% -10% -14% 4%;
    background: radial-gradient(60% 60% at 60% 40%, rgba(147, 51, 234, .35), transparent 70%);
    filter: blur(30px);
    z-index: -1;
}

.nftm-show-card {
    border-radius: var(--nftm-radius-lg);
    padding: 18px;
}

.nftm-show-card .nftm-art {
    border-radius: 18px;
}

/* Second floating chip — a mini stat that reinforces the asymmetric,
   layered composition. Injected purely via CSS content on the showcase. */
.nftm-showcase .nftm-float-tag {
    top: -16px;
    right: -18px;
    padding: 11px 15px;
    border-radius: 14px;
    background: rgba(6, 9, 16, .9);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
}

.nftm-stats {
    gap: 16px;
    margin-top: 64px;
}

/* ===================================================================
   FEATURED — spotlight + bento
   One large "spotlight" tile beside a grid of standard cards.
   =================================================================== */
#nftmFeaturedGrid {
    grid-template-columns: repeat(3, 1fr);
    grid-auto-rows: 1fr;
    gap: 20px;
}

/* ===================================================================
   LIVE AUCTIONS — asymmetric (lead card wider)
   =================================================================== */
.nftm-auc-grid {
    grid-template-columns: 1.4fr 1fr 1fr;
}

.nftm-auc-card:first-child .nftm-art {
    aspect-ratio: 16/11;
}

/* ===================================================================
   HOW IT WORKS — asymmetric staggered timeline
   =================================================================== */
.nftm-steps {
    gap: 22px;
}

.nftm-step {
    padding: 30px 26px;
}

.nftm-steps .nftm-step:nth-child(even) {
    transform: translateY(28px);
}

.nftm-step .nftm-ic {
    background: var(--nftm-grad-2);
    border: none;
    box-shadow: 0 12px 30px -12px rgba(147, 51, 234, .8);
}

.nftm-step .nftm-n {
    font-size: 34px;
    font-weight: 700;
    color: transparent;
    -webkit-text-stroke: 1px rgba(255, 255, 255, .16);
    letter-spacing: 0;
    display: block;
}

/* ===================================================================
   COLLECTIONS — raise the middle tile for rhythm
   =================================================================== */
.nftm-coll-grid .nftm-coll:nth-child(2) {
    transform: translateY(-24px);
}

.nftm-coll-grid .nftm-coll:nth-child(2):hover {
    transform: translateY(-30px);
}

.nftm-coll .nftm-banner {
    height: 140px;
}

/* ===================================================================
   CATEGORIES — bento (feature tile spans 2×2)
   =================================================================== */
.nftm-cat-grid {
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: 156px;
    gap: 16px;
}

.nftm-cat {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-end;
    text-align: left;
    padding: 22px;
    overflow: hidden;
}

.nftm-cat .nftm-ic {
    margin: 0 0 auto;
}

/* Gapless bento: two wide tiles (first + last) bookend a tidy 4×2 grid —
   Art spans the top-left, Video the bottom-right, everything else 1×1. */
.nftm-cat:first-child,
.nftm-cat:last-child {
    grid-column: span 2;
    justify-content: space-between;
}

.nftm-cat:first-child .nftm-ic,
.nftm-cat:last-child .nftm-ic {
    width: 60px;
    height: 60px;
    font-size: 26px;
}

.nftm-cat:first-child b,
.nftm-cat:last-child b {
    font-size: 20px;
}

/* ===================================================================
   LATEST DROPS — cinematic pinned horizontal-scroll track
   The blade wraps the grid in .nftm-hscroll; JS pins the section and
   translates the track sideways as you scroll (desktop only).
   =================================================================== */
.nftm-hscroll {
    position: relative;
}

.nftm-hscroll-track {
    display: flex;
    gap: 22px;
    will-change: transform;
}

.nftm-hscroll-track .nftm-nft-card {
    flex: 0 0 340px;
}

/* Pinned desktop mode: the section is held in place while the track slides
   sideways; the wrap keeps its left padding so the first card lines up with
   the rest of the page content. */
.nftm-hscroll.nftm-pinned {
    overflow: hidden;
}

.nftm-hscroll.nftm-pinned .nftm-hscroll-wrap {
    overflow: visible;
    max-width: none;
    padding-right: 0;
}

/* Fallback / mobile & reduced-motion: a normal horizontal overflow-scroll
   instead of a pinned scrub, so nothing is unreachable. */
.nftm-hscroll:not(.nftm-pinned) .nftm-hscroll-track {
    overflow-x: auto;
    padding-bottom: 14px;
    scroll-snap-type: x mandatory;
}

.nftm-hscroll:not(.nftm-pinned) .nftm-hscroll-track .nftm-nft-card {
    scroll-snap-align: start;
}

/* ---- Leaderboard polish -------------------------------------------- */
.nftm-rank-panel {
    padding: 12px;
}

.nftm-rank-row {
    border: 1px solid transparent;
}

.nftm-rank-row:hover {
    background: var(--nftm-glass-2);
    border-color: var(--nftm-line);
}

/* ---- Newsletter band ------------------------------------------------ */
.nftm-cta-inner {
    background-image: linear-gradient(rgba(10, 8, 20, .55), rgba(10, 8, 20, .55)), url('https://picsum.photos/seed/nftm-cta-bg/1600/900');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    border-radius: 32px;
    padding: 68px 56px;
}

.nftm-cta-inner h2 {
    font-size: clamp(32px, 4.4vw, 52px);
    letter-spacing: -.03em;
}

/* ---- Marquee sits on the deeper base -------------------------------- */
.nftm-marquee {
    background: transparent;
    padding: 22px 0;
}

/* ===================================================================
   RESPONSIVE — collapse the bento/asymmetry on smaller screens
   =================================================================== */
@media (max-width: 1000px) {
    #nftmFeaturedGrid {
        grid-template-columns: repeat(2, 1fr);
    }

    .nftm-auc-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 900px) {
    /* Re-collapse the hero to one column — this override lives after the base
       @media rule, so it must restate the single-column layout itself. */
    .nftm-hero .nftm-wrap {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .nftm-hero {
        padding: 124px 0 64px;
    }

    .nftm-steps .nftm-step:nth-child(even),
    .nftm-coll-grid .nftm-coll:nth-child(2) {
        transform: none;
    }

    .nftm-auc-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 760px) {
    #nftmFeaturedGrid {
        grid-template-columns: 1fr;
    }

    .nftm-cat-grid {
        grid-template-columns: repeat(2, 1fr);
        grid-auto-rows: 120px;
    }

    .nftm-cat:first-child {
        grid-column: span 2;
    }

    .nftm-cat:first-child .nftm-ic {
        width: 52px;
        height: 52px;
    }

    .nftm-hscroll-track .nftm-nft-card {
        flex-basis: 78%;
    }
}

/* Re-asserted here (after the editorial .nftm-sec-head{align-items:flex-end}
   redefinition above, which is unscoped and would otherwise win the cascade
   at every width) so section titles/subtitles stay centered once stacked. */
@media (max-width: 560px) {
    .nftm-sec-head {
        align-items: center;
    }
}

@media (prefers-reduced-motion: reduce) {
    .nftm-steps .nftm-step:nth-child(even),
    .nftm-coll-grid .nftm-coll:nth-child(2) {
        transform: none;
    }
}
