/* ===================================
   Marketplace Landing — Growly ChatStore
   =================================== */

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

body {
    font-family: 'Inter', ui-sans-serif, system-ui, sans-serif;
    -webkit-font-smoothing: antialiased;
}

/* ── GRADIENT TEXT ── */
.text-grad {
    background: linear-gradient(135deg, #60a845 0%, #34d399 60%, #10b981 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ── NAVBAR SCROLL STATE ── */
#navbar {
    background: transparent;
}

#navbar.scrolled {
    background: rgba(2, 6, 23, 0.88);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

/* ── BLOB ANIMATION ── */
@keyframes blob {

    0%,
    100% {
        border-radius: 60% 40% 30% 70%/60% 30% 70% 40%;
        transform: translate(0, 0) scale(1);
    }

    33% {
        border-radius: 30% 60% 70% 40%/50% 60% 30% 60%;
        transform: translate(12px, -18px) scale(1.04);
    }

    66% {
        border-radius: 70% 30% 30% 70%/30% 70% 70% 30%;
        transform: translate(-10px, 12px) scale(0.97);
    }
}

.animate-blob {
    animation: blob 14s ease-in-out infinite;
}

.anim-delay-2 {
    animation-delay: 2s;
}

.anim-delay-4 {
    animation-delay: 4s;
}

/* ── SEARCH GLOW RING ── */
@keyframes searchGlow {

    0%,
    100% {
        opacity: 0.2;
    }

    50% {
        opacity: 0.55;
    }
}

.search-glow {
    animation: searchGlow 2.5s ease-in-out infinite;
}

/* ── TYPEWRITER CURSOR ── */
@keyframes blink {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0;
    }
}

.tw-cursor {
    animation: blink 0.75s step-end infinite;
}

/* ── CATEGORY CHIPS ── */
.chip {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.35rem 0.85rem;
    border-radius: 9999px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: rgba(148, 163, 184, 0.65);
    font-size: 0.8rem;
    font-weight: 500;
    cursor: default;
    user-select: none;
    filter: blur(0.25px);
    transition: all 0.25s ease;
}

.chip:hover {
    background: rgba(96, 168, 69, 0.08);
    border-color: rgba(96, 168, 69, 0.22);
    color: #a7f3d0;
    filter: none;
}

/* ── FLOATING CARDS ── */
@keyframes floatY {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

.float-card {
    animation: floatY 5s ease-in-out infinite;
}

/* ── HERO IMAGE MOSAIC ── */
.hero-mosaic {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    grid-template-rows: repeat(3, 1fr);
    gap: 8px;
    height: 100%;
}

.mosaic-item {
    overflow: hidden;
    border-radius: 14px;
    position: relative;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.45);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.mosaic-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
}

.mosaic-main {
    grid-column: 1 / 4;
    grid-row: 1 / 3;
}

.mosaic-main img {
    object-position: center top;
}

.mosaic-item:nth-child(2) {
    grid-column: 4 / 6;
    grid-row: 1;
}

.mosaic-item:nth-child(3) {
    grid-column: 4 / 6;
    grid-row: 2;
}

.mosaic-item:nth-child(4) {
    grid-column: 1 / 3;
    grid-row: 3;
}

.mosaic-item:nth-child(5) {
    grid-column: 3 / 6;
    grid-row: 3;
}

.img-hover img {
    transition: transform 0.45s ease;
}

.img-hover:hover img {
    transform: scale(1.07);
}

/* ── MARQUEE ── */
.marquee-track {
    overflow: hidden;
}

.marquee-content {
    display: flex;
    gap: 1rem;
    width: max-content;
    animation: marquee 28s linear infinite;
}

@keyframes marquee {
    from {
        transform: translateX(0);
    }

    to {
        transform: translateX(-50%);
    }
}

.marquee-item {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 1rem;
    border-radius: 9999px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.07);
    color: #94a3b8;
    font-size: 0.8rem;
    font-weight: 500;
    white-space: nowrap;
    flex-shrink: 0;
}

/* ── FEATURE CARDS ── */
.feat-card {
    padding: 1.75rem;
    border-radius: 1.25rem;
    background: rgba(255, 255, 255, 0.025);
    border: 1px solid rgba(255, 255, 255, 0.07);
    transition: all 0.35s ease;
    position: relative;
    overflow: hidden;
}

.feat-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at top left, rgba(96, 168, 69, 0.07), transparent 70%);
    opacity: 0;
    transition: opacity 0.35s ease;
    border-radius: inherit;
    pointer-events: none;
}

.feat-card:hover::before {
    opacity: 1;
}

.feat-card:hover {
    border-color: rgba(96, 168, 69, 0.28);
    transform: translateY(-5px);
    box-shadow: 0 20px 50px rgba(96, 168, 69, 0.09);
}

.feat-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    border-radius: 0.875rem;
    background: rgba(96, 168, 69, 0.12);
    border: 1px solid rgba(96, 168, 69, 0.22);
}

/* ── STEP CARDS ── */
.step-card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 1.75rem;
    border-radius: 1.25rem;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.06);
    position: relative;
    transition: border-color 0.3s ease, transform 0.3s ease;
}

.step-card:hover {
    border-color: rgba(96, 168, 69, 0.22);
    transform: translateY(-3px);
}

.step-num {
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.1em;
    color: #60a845;
    background: rgba(96, 168, 69, 0.1);
    border: 1px solid rgba(96, 168, 69, 0.2);
    border-radius: 0.5rem;
    padding: 0.2rem 0.6rem;
    display: inline-block;
}

/* ── GALLERY GRID ── */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    grid-template-rows: 240px 240px;
    gap: 12px;
}

.gallery-item {
    overflow: hidden;
    border-radius: 1rem;
    position: relative;
    cursor: pointer;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.gallery-item:nth-child(1) {
    grid-column: 1 / 5;
    grid-row: 1 / 3;
}

.gallery-item:nth-child(2) {
    grid-column: 5 / 9;
    grid-row: 1;
}

.gallery-item:nth-child(3) {
    grid-column: 9 / 13;
    grid-row: 1;
}

.gallery-item:nth-child(4) {
    grid-column: 5 / 13;
    grid-row: 2;
}

.gallery-item img {
    transition: transform 0.5s ease;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.gallery-item:hover img {
    transform: scale(1.06);
}

.gallery-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 1.5rem 1rem 1rem;
    background: linear-gradient(to top, rgba(2, 6, 23, 0.88), transparent);
    font-size: 0.825rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
    transform: translateY(8px);
    opacity: 0;
    transition: all 0.3s ease;
}

.gallery-item:hover .gallery-caption {
    transform: translateY(0);
    opacity: 1;
}

/* ── SCROLL REVEAL ── */
.reveal {
    opacity: 0;
    transition: opacity 0.65s ease, transform 0.65s ease;
}

.reveal[data-dir="up"] {
    transform: translateY(28px);
}

.reveal[data-dir="left"] {
    transform: translateX(-28px);
}

.reveal[data-dir="right"] {
    transform: translateX(28px);
}

.reveal.visible {
    opacity: 1;
    transform: translate(0, 0);
}

/* ── TOAST ── */
.toast-enter {
    opacity: 1;
    transform: translateY(0);
}

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
    .gallery-grid {
        grid-template-columns: 1fr 1fr;
        grid-template-rows: 180px 180px 180px;
    }

    .gallery-item:nth-child(1) {
        grid-column: 1 / 3;
        grid-row: 1;
    }

    .gallery-item:nth-child(2) {
        grid-column: 1;
        grid-row: 2;
    }

    .gallery-item:nth-child(3) {
        grid-column: 2;
        grid-row: 2;
    }

    .gallery-item:nth-child(4) {
        grid-column: 1 / 3;
        grid-row: 3;
    }
}

@media (max-width: 640px) {
    .hero-mosaic {
        grid-template-columns: repeat(2, 1fr);
        grid-template-rows: repeat(3, 1fr);
    }

    .mosaic-main {
        grid-column: 1 / 3;
        grid-row: 1;
    }

    .mosaic-item:nth-child(2) {
        grid-column: 1;
        grid-row: 2;
    }

    .mosaic-item:nth-child(3) {
        grid-column: 2;
        grid-row: 2;
    }

    .mosaic-item:nth-child(4) {
        grid-column: 1;
        grid-row: 3;
    }

    .mosaic-item:nth-child(5) {
        grid-column: 2;
        grid-row: 3;
    }
}

@media (prefers-reduced-motion: reduce) {

    .animate-blob,
    .float-card,
    .search-glow,
    .tw-cursor,
    .marquee-content {
        animation: none !important;
    }

    .reveal {
        opacity: 1 !important;
        transform: none !important;
    }

    .img-hover img,
    .gallery-item img {
        transition: none !important;
    }
}