/* CrewCall Sites - /work/ portfolio wall only. Loads after site.css.
   Same shape rule: controls 6px, media and panels 10px. */

/* ---------- hero ---------- */
.wk-hero { padding: clamp(36px, 4.5vw, 64px) 0 clamp(28px, 3.5vw, 44px); }
.wk-hero .wrap { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 24px clamp(32px, 5vw, 72px); align-items: end; }
.wk-hero h1 { max-width: none; margin: 0; font-size: clamp(2.4rem, 4.9vw, 4.25rem); font-variant-numeric: tabular-nums; }
.wk-hero h1 .wk-h2 { display: block; color: var(--muted); }
.wk-hero .lede { max-width: 44ch; margin: 0 0 6px; font-size: clamp(1.05rem, 1.3vw, 1.18rem); text-wrap: pretty; }
@media (max-width: 900px) {
  .wk-hero .wrap { grid-template-columns: 1fr; }
  /* reserve the 4 lines Inter needs, so the font swap doesn't push the wall down */
  .wk-hero .lede { min-height: 6em; }
}

/* ---------- filters ---------- */
.wk-wall { padding: 0; }
.wk-ctl { display: grid; gap: 12px; padding: 20px 0 22px; margin-bottom: clamp(32px, 4vw, 52px); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.wk-row { display: flex; align-items: flex-start; gap: 18px; min-width: 0; }
.wk-lab { flex: 0 0 52px; font: 600 0.75rem/44px var(--f-body); letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.wk-chips { display: flex; flex-wrap: wrap; gap: 8px; min-width: 0; }
.wk-chips .chip { white-space: nowrap; font-variant-numeric: tabular-nums; }
/* counts at full contrast: Steel on light, night-muted on the pressed chip */
.wk-chips .chip .n { opacity: 1; color: var(--muted); }
.wk-chips .chip[aria-pressed="true"] .n { color: var(--night-muted); }
.wk-seg { display: inline-flex; gap: 2px; padding: 3px; border: 1px solid var(--line); border-radius: var(--r-ctl); background: var(--card); }
.wk-seg button { min-height: 44px; min-width: 76px; padding: 0 16px; border: 0; border-radius: 4px; background: transparent; color: var(--ink); font: 600 0.92rem/1 var(--f-body); cursor: pointer; transition: background-color .15s, color .15s; }
.wk-seg button:hover { background: var(--paper-2); }
.wk-seg button[aria-pressed="true"] { background: var(--ink); color: var(--paper); }
.wk-shown { margin: 0 0 0 auto; align-self: center; font-size: 0.9rem; color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; }
.wk-msg { margin: -16px 0 28px; padding: 14px 18px; border: 1px solid var(--line); border-left: 3px solid var(--accent); border-radius: var(--r-ctl); background: var(--card); font-size: 0.95rem; }
.wk-msg a { color: inherit; }

/* ---------- grid: 3 / 2 / 1 ---------- */
.wk-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(40px, 4.4vw, 64px) clamp(16px, 2.2vw, 32px); }
.wk-card { display: flex; flex-direction: column; min-width: 0; }

/* device frame: a browser window in charcoal */
.wk-frame { display: block; padding: 0 5px 5px; border-radius: var(--r-box); background: var(--ink); text-decoration: none;
  box-shadow: 0 1px 2px rgba(21, 23, 27, .08), 0 22px 40px -26px rgba(21, 23, 27, .55);
  transition: transform .5s var(--ease), box-shadow .5s var(--ease); }
.wk-bar { display: flex; align-items: center; gap: 6px; height: 30px; padding: 0 6px; }
.wk-bar > i { width: 8px; height: 8px; border-radius: 50%; background: #3A3F47; flex: none; }
.wk-url { display: flex; align-items: center; gap: 6px; min-width: 0; max-width: 78%; margin: 0 auto; padding: 0 10px; height: 18px; border-radius: 4px; background: var(--night-2); color: var(--night-muted); font: 500 0.6875rem/18px var(--f-body); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wk-url b { width: 6px; height: 6px; border-radius: 50%; background: var(--lime); flex: none; }
.wk-view { display: block; position: relative; aspect-ratio: 16 / 10; overflow: hidden; border-radius: 5px; background: var(--night-2); }
.wk-view img { position: absolute; top: 0; left: 0; width: 100%; }
.wk-view .wk-thumb { height: 100%; object-fit: cover; object-position: top center; }
.wk-view .wk-full { height: auto; max-width: none; opacity: 0; transform: translate3d(0, 0, 0); will-change: transform;
  transition: opacity .3s ease, transform 1.1s var(--ease); }
.wk-card.is-ready .wk-full { opacity: 1; }
.wk-card.is-run .wk-full { transform: translate3d(0, var(--shift, 0), 0); transition: opacity .3s ease, transform var(--dur, 12s) cubic-bezier(.42, 0, .58, 1) .3s; }
.wk-view.noimg { display: grid; place-items: center; background: var(--ink) url("/assets/img/topo-light.png") center / cover; }
.wk-view.noimg::after { content: attr(data-name); color: var(--night-text); font: 800 1.2rem/1.1 var(--f-display); letter-spacing: -0.02em; text-align: center; padding: 0 16px; }
@media (hover: hover) and (pointer: fine) {
  .wk-card:hover .wk-frame, .wk-card:focus-within .wk-frame { transform: translateY(-4px); box-shadow: 0 1px 2px rgba(21, 23, 27, .08), 0 34px 50px -30px rgba(21, 23, 27, .6); }
}

/* card text */
.wk-body { display: flex; flex-direction: column; flex: 1; padding-top: 20px; }
.wk-ttl { display: flex; justify-content: space-between; align-items: flex-start; gap: 14px; margin-bottom: 6px; }
.wk-body h3 { margin: 0; font-size: 1.2rem; }
.wk-meta { margin: 0; color: var(--muted); font-size: 0.92rem; line-height: 1.45; }
.wk-meta span { white-space: nowrap; }
.wk-meta span:not(:last-child)::after { content: " \00B7"; }
.wk-pal { display: flex; flex: none; padding: 3px 0 0 5px; }
.wk-pal i { width: 18px; height: 18px; margin-left: -6px; border-radius: 50%; border: 2px solid var(--paper); background: var(--line); box-shadow: inset 0 0 0 1px rgba(21, 23, 27, .14); }
.wk-acts { display: flex; gap: 10px; margin-top: auto; padding-top: 18px; }
.wk-acts .btn { min-height: 46px; padding: 0 16px; font-size: 0.93rem; gap: 8px; }
.wk-acts .btn svg { width: 16px; height: 16px; }
.wk-live { flex: 0 0 auto; border-color: var(--ink); color: var(--ink); background: transparent; }
.wk-live:hover { background: var(--ink); color: var(--paper); }
.wk-live:hover svg { transform: translate(2px, -2px); }
.wk-get { flex: 1 1 auto; background: var(--ink); color: var(--paper); }
.wk-get:hover { background: var(--accent); color: var(--accent-ink); }

/* empty state */
.wk-empty { padding: clamp(32px, 5vw, 56px); border: 1px dashed var(--line); border-radius: var(--r-box); text-align: center; }
.wk-empty p { margin: 0 0 20px; color: var(--muted); }
.wk-empty p b { color: var(--ink); }
.wk-empty-acts { display: flex; justify-content: center; flex-wrap: wrap; gap: 10px; }

/* ---------- case study slot ---------- */
.wk-case { padding: 0 0 clamp(40px, 5vw, 64px); }
.wk-case-in { display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(24px, 4vw, 56px); align-items: center; padding: clamp(20px, 3vw, 36px); border-radius: var(--r-box); background: var(--night); color: var(--night-text); text-decoration: none; }
.wk-case-media img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; object-position: top; border-radius: 6px; }
.wk-case-txt { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; }
.wk-case .eyebrow { color: var(--lime); margin: 0; }
.wk-case-h { font: 800 clamp(1.6rem, 2.8vw, 2.4rem)/1.08 var(--f-display); letter-spacing: -0.02em; text-wrap: balance; }
.wk-case-sum { color: var(--night-muted); }
.wk-case-meta { font-size: 0.9rem; color: var(--night-muted); }
@media (max-width: 860px) { .wk-case-in { grid-template-columns: 1fr; } }


@media (max-width: 960px) { .wk-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) {
  .wk-grid { grid-template-columns: 1fr; gap: 44px; }
  .wk-ctl { gap: 14px; padding: 16px 0 18px; }
  .wk-row { flex-direction: column; gap: 6px; }
  .wk-lab { flex: none; line-height: 1.2; }
  /* trade chips: one swipeable row instead of eight wrapped ones */
  .wk-chips { flex-wrap: nowrap; overflow-x: auto; width: calc(100% + 2 * var(--gut)); margin: 0 calc(-1 * var(--gut)); padding: 2px var(--gut) 4px; scrollbar-width: none; overscroll-behavior-x: contain;
    -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 40px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 40px), transparent); }
  .wk-chips::-webkit-scrollbar { display: none; }
  .wk-chips .chip { flex: none; }
  .wk-seg { display: flex; width: 100%; }
  .wk-seg button { flex: 1; min-width: 0; padding: 0 8px; }
  .wk-shown { margin: 2px 0 0; align-self: flex-start; }
  .wk-acts .btn { flex: 1 1 0; }
}
@media (prefers-reduced-motion: reduce) {
  .wk-frame, .wk-view .wk-full { transition: none; }
  .wk-view .wk-full { display: none; }
}
