/* ── UPFORCED — before/after gallery (ba.js) ─────────────────────────────── */
.ba-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 22px; margin: 0; padding: 0; list-style: none; }
.ba-card { margin: 0; border-radius: 18px; overflow: hidden; background: #fff; box-shadow: 0 10px 30px rgba(7, 30, 49, .10); border: 1px solid #e3ebf2; text-align: left; }
.ba-card[hidden] { display: none; }
.ba { position: relative; overflow: hidden; background: #0b1622; aspect-ratio: 3 / 4; user-select: none; -webkit-user-select: none; touch-action: pan-y; }
.ba--wide { aspect-ratio: 3 / 2; }
.ba--sq { aspect-ratio: 1 / 1; }
.ba img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; max-width: none; pointer-events: none; }
.ba-before { position: absolute; inset: 0; clip-path: inset(0 calc(100% - var(--pos, 50%)) 0 0); will-change: clip-path; }
.ba-line { position: absolute; top: 0; bottom: 0; left: var(--pos, 50%); width: 3px; margin-left: -1.5px; background: #fff; box-shadow: 0 0 10px rgba(0, 0, 0, .45); pointer-events: none; }
.ba-knob { position: absolute; top: 50%; left: var(--pos, 50%); width: 46px; height: 46px; margin: -23px 0 0 -23px; border-radius: 50%; background: #fff; color: #0f1c2d;
  display: grid; place-items: center; box-shadow: 0 6px 18px rgba(0, 0, 0, .35); pointer-events: none; transition: transform .15s ease; }
.ba-knob svg { width: 26px; height: 26px; }
.ba.is-drag .ba-knob, .ba-range:focus-visible ~ .ba-knob { transform: scale(1.1); }
.ba-range:focus-visible ~ .ba-knob { box-shadow: 0 0 0 4px rgba(30, 163, 201, .55), 0 6px 18px rgba(0, 0, 0, .35); }
.ba-range { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: ew-resize; -webkit-appearance: none; appearance: none; background: transparent; z-index: 2; }
.ba-tag { position: absolute; top: 12px; padding: 5px 10px; border-radius: 999px; background: rgba(7, 13, 20, .72); color: #fff; font: 800 11px/1 'Lato', 'Manrope', Arial, sans-serif;
  letter-spacing: .12em; text-transform: uppercase; pointer-events: none; -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); }
.ba-tag--b { left: 12px; }
.ba-tag--a { right: 12px; background: rgba(30, 163, 201, .92); }
/* Photos that already show both halves: two labels, no slider */
.ba--split .ba-tag--b { left: 12px; }
.ba--stack .ba-tag--a { top: auto; bottom: 12px; right: 12px; }
.ba-cap { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 14px 16px 16px; }
.ba-cap b { display: block; color: #0f1c2d; font: 800 16px/1.25 'Lato', 'Manrope', Arial, sans-serif; }
.ba-cap small { display: block; margin-top: 3px; color: #5f7386; font: 500 13px/1.4 'Lato', Arial, sans-serif; }
.ba-cap a { flex: none; color: #1e87b0; font: 800 13px/1 'Lato', Arial, sans-serif; text-decoration: none; white-space: nowrap; }
.ba-cap a:hover { text-decoration: underline; }
.ba-hint { position: absolute; left: 50%; bottom: 14px; transform: translateX(-50%); padding: 6px 12px; border-radius: 999px; background: rgba(7, 13, 20, .72); color: #fff;
  font: 700 12px/1 'Lato', Arial, sans-serif; pointer-events: none; white-space: nowrap; transition: opacity .3s ease; }
.ba.is-used .ba-hint { opacity: 0; }
.ba-filters { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 0 0 26px; }
.ba-filters button { min-height: 40px; padding: 0 16px; border-radius: 999px; border: 1px solid #cfe0ec; background: #fff; color: #174a6a; font: 800 13px/1 'Lato', Arial, sans-serif;
  letter-spacing: .02em; cursor: pointer; transition: background .15s, color .15s, border-color .15s; }
.ba-filters button:hover { border-color: #1ea3c9; }
.ba-filters button[aria-pressed="true"] { background: #0f1c2d; border-color: #0f1c2d; color: #fff; }
@media (max-width: 600px) { .ba-grid { gap: 16px; } .ba-knob { width: 40px; height: 40px; margin: -20px 0 0 -20px; } }
@media (prefers-reduced-motion: reduce) { .ba-knob { transition: none; } }
/* Before & after page */
.ba-stage { min-height: clamp(420px, 56vh, 560px) !important; }
.ba-sec { background: #f4f8fb; }
.ba-note { margin: 22px auto 0 !important; max-width: 640px; text-align: center; color: #6b7f90; font-size: 13.5px; }
/* One shape for every photo, so the cards line up */
.ba-grid .ba, .ba-grid .ba--wide, .ba-grid .ba--sq { aspect-ratio: 1 / 1; }
.ba-grid .ba-card { display: flex; flex-direction: column; }
.ba-grid .ba-cap { flex: 1; align-items: flex-start; }
/* The site's own button styles must not stretch the filters */
.ba-filters button { width: auto !important; flex: 0 0 auto; margin: 0 !important; }
@media (max-width: 700px) {
  .ba-filters { flex-wrap: nowrap; justify-content: flex-start; overflow-x: auto; margin: 0 -16px 20px; padding: 2px 16px 6px; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
  .ba-filters::-webkit-scrollbar { display: none; }
}
/* Home page: six cards on the blue band (three on phones), then the gallery link */
.home-ba-grid { max-width: 1180px; margin: 0 auto; }
.home-ba-grid .ba-cap { text-align: left; }
.home-ba-more { margin-top: 30px; text-align: center; }
.home-ba-btn { display: inline-flex; align-items: center; gap: 10px; min-height: 52px; padding: 0 28px; border-radius: 999px; background: #fff; color: #0f1c2d !important;
  font: 800 15px/1 'Lato', Arial, sans-serif; letter-spacing: .04em; text-transform: uppercase; text-decoration: none !important; box-shadow: 0 10px 24px rgba(7, 30, 49, .2);
  transition: transform .15s ease, box-shadow .15s ease; }
.home-ba-btn:hover { transform: translateY(-2px); box-shadow: 0 14px 30px rgba(7, 30, 49, .26); }
@media (max-width: 700px) { .home-ba-grid .ba-card:nth-child(n+4) { display: none; } }
.home-ba-grid { margin-top: 44px; }
@media (max-width: 700px) { .home-ba-grid { margin-top: 66px; } }
/* Real UPFORCED jobs (gallery.php) */
.ba-own { display: inline-block; margin-right: 7px; padding: 3px 8px; border-radius: 999px; background: #e6f4fa; color: #136f93; font: 800 10.5px/1.2 'Lato', Arial, sans-serif;
  letter-spacing: .08em; text-transform: uppercase; vertical-align: 1px; }
