/* Within website — shared styles: tokens, nav bar, live wall, store buttons */
:root {
  --blue: rgb(13,65,225);
  --blue-dark: rgb(9,45,160);
  --blue-light: rgb(165,186,253);
  --ink: rgb(14,17,28);
  --magenta: rgb(175,0,232);
  --green: rgb(53,255,105);
  --white: #fff;
  --gap: 6px;
  --row: 150px;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--ink); color: var(--white); font-family: "Space Grotesk", system-ui, sans-serif; -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }

/* ───────── top bar ───────── */
.bar {
  position: sticky; top: 0; z-index: 20;
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 18px;
  height: 64px; padding: 0 22px;
  background: var(--blue);
  box-shadow: 0 6px 24px rgba(0,0,0,0.25);
}
.logo { height: 26px; display: block; flex-shrink: 0; }
.brand { justify-self: start; display: flex; }
.links { display: flex; align-items: center; gap: 4px; padding: 4px; border-radius: 14px; background: rgba(255,255,255,0.10); }
.links a { padding: 8px 16px; border-radius: 10px; font-size: 14px; font-weight: 600; color: rgba(255,255,255,0.82); transition: background 160ms, color 160ms; }
.links a:hover { color: #fff; background: rgba(255,255,255,0.10); }
.links a[aria-current="page"] { color: var(--blue); background: #fff; }
.actions { justify-self: end; display: flex; align-items: center; gap: 10px; }
.login { display: inline-flex; align-items: center; height: 40px; padding: 0 16px; border-radius: 12px; font-size: 14px; font-weight: 700; color: #fff; box-shadow: inset 0 0 0 1.5px rgba(255,255,255,0.55); transition: background 160ms; }
.login:hover { background: rgba(255,255,255,0.12); }
.cta {
  display: inline-flex; align-items: center; gap: 8px; flex-shrink: 0;
  height: 40px; padding: 0 16px; border-radius: 12px;
  background: var(--white); color: var(--blue); font-weight: 700; font-size: 14px;
}
.cta:hover { background: rgb(235,240,255); }

/* ───────── live wall ───────── */
/* the wall is a row of independent vertical feeds; posts fall in at the top of a column */
.wall { display: flex; gap: var(--gap); padding: var(--gap); align-items: flex-start; overflow: hidden; }
.col { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; gap: var(--gap); }
.col:nth-child(even) { margin-top: calc(var(--row) * -0.6); } /* staggered start, like feeds mid-scroll */
.post {
  position: relative; overflow: hidden; border-radius: 14px; background: rgb(30,34,48);
  height: calc(var(--row) * 2); flex-shrink: 0;
}
.post.tall { height: calc(var(--row) * 2.9); }
.post.big { height: calc(var(--row) * 3.4); }
.post .img { position: absolute; inset: 0; background-size: cover; background-position: center; transition: transform 900ms cubic-bezier(.2,.7,.2,1); }
.post:hover .img { transform: scale(1.05); }
.post::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,0.35) 0%, rgba(0,0,0,0) 28%, rgba(0,0,0,0) 52%, rgba(0,0,0,0.78) 100%); pointer-events: none; }

.who { position: absolute; z-index: 2; left: 12px; right: 12px; top: 12px; display: flex; align-items: center; gap: 8px; }
.av { width: 30px; height: 30px; border-radius: 50%; flex-shrink: 0; background: #fff center/cover no-repeat; border: 2px solid rgba(255,255,255,.9); display: grid; place-items: center; font-size: 12px; font-weight: 700; color: #fff; }
.nm { font-size: 13px; font-weight: 700; text-shadow: 0 1px 6px rgba(0,0,0,.4); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nm small { display: block; font-size: 11px; font-weight: 500; opacity: .85; }
.kind { margin-left: auto; flex-shrink: 0; padding: 4px 9px; border-radius: 99px; font-size: 10.5px; font-weight: 700; letter-spacing: .03em; background: rgba(255,255,255,.92); color: var(--ink); }
.kind.offer { background: var(--green); color: rgb(4,60,30); }
.kind.creator { background: var(--magenta); color: #fff; }
.kind.collab { background: var(--blue); color: #fff; }

.cap { position: absolute; z-index: 2; left: 12px; right: 12px; bottom: 12px; }
.cap p { margin: 0 0 8px; font-size: 13px; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; text-shadow: 0 1px 8px rgba(0,0,0,.45); }
.post.big .cap p { font-size: 17px; font-weight: 600; -webkit-line-clamp: 3; }
.meta { display: flex; align-items: center; gap: 10px; font-size: 11.5px; font-weight: 600; color: rgba(255,255,255,.88); }
.meta .likes { display: inline-flex; align-items: center; gap: 4px; font-variant-numeric: tabular-nums; }
.meta .peek { display: inline-flex; align-items: center; gap: 4px; padding: 3px 8px 3px 7px; border-radius: 99px; background: rgba(255,255,255,0.2); backdrop-filter: blur(6px); font-size: 11px; font-weight: 700; color: #fff; }
.meta .ago { margin-left: auto; opacity: .8; font-weight: 500; }

/* new-post arrival — the slide itself is done in JS (FLIP); CSS only handles the glow + badge */
.post { transition: box-shadow 1.4s ease; will-change: transform; }
.post.fresh { box-shadow: 0 0 0 2px var(--blue), 0 0 28px rgba(13,65,225,.5); }
.post.fresh::before {
  content: "Just posted"; position: absolute; z-index: 3; left: 50%; top: 50%; transform: translate(-50%,-50%);
  padding: 7px 13px; border-radius: 99px; background: var(--blue); font-size: 12px; font-weight: 700;
  box-shadow: 0 6px 20px rgba(13,65,225,.5); animation: badge 3.2s ease both;
}
@keyframes badge { 0% { opacity: 0; transform: translate(-50%,-30%); } 25%, 75% { opacity: 1; transform: translate(-50%,-50%); } 100% { opacity: 0; transform: translate(-50%,-50%); } }
@media (prefers-reduced-motion: reduce) { .post, .post .img { transition: none; } }
/* search filter on the wall: non-matching posts fade back */
.post.dimmed { opacity: .14; filter: grayscale(1) blur(1px); pointer-events: none; transition: opacity 500ms ease, filter 500ms ease; }
.post { transition: box-shadow 1.4s ease, opacity 500ms ease, filter 500ms ease; }
.likes.bump { animation: bump 420ms ease; }
@keyframes bump { 40% { transform: scale(1.25); color: #ff8fab; } }


/* ───────── inner pages: live feed as a dimmed backdrop ───────── */
.backdrop { position: fixed; inset: 64px 0 0 0; z-index: 0; overflow: hidden; pointer-events: none; }
.backdrop .wall { min-height: 100%; }
.backdrop .post::before { display: none; } /* no "Just posted" badges behind the copy */
.dim {
  position: fixed; inset: 64px 0 0 0; z-index: 1; pointer-events: none;
  background:
    radial-gradient(ellipse 70% 60% at 50% 40%, rgba(10,13,26,0.70), rgba(10,13,26,0.86) 70%),
    linear-gradient(180deg, rgba(10,13,26,0.2), rgba(10,13,26,0.6));
  backdrop-filter: blur(3px) saturate(80%); -webkit-backdrop-filter: blur(3px) saturate(80%);
}
.glass {
  background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.12); border-radius: 22px;
  backdrop-filter: blur(18px) saturate(140%); -webkit-backdrop-filter: blur(18px) saturate(140%);
}

.stores { display: flex; flex-direction: column; gap: 8px; flex-shrink: 0; }
.store { display: flex; align-items: center; gap: 9px; height: 44px; padding: 0 14px; border-radius: 12px; background: #000; font-size: 11px; line-height: 1.1; }
.store b { display: block; font-size: 14.5px; font-weight: 700; }
.store svg { flex-shrink: 0; }

@media (max-width: 860px) {
  .links a { padding: 8px 11px; font-size: 13px; }
}
@media (max-width: 680px) {
  .bar { grid-template-columns: auto 1fr auto; }
  .links { justify-self: end; background: none; padding: 0; }
  .links a { display: none; }
}
@media (max-width: 560px) {
  :root { --row: 120px; --gap: 4px; }
  .bar { padding: 0 16px; gap: 10px; }
  .cta span { display: none; }
}
