/* ============================================
   Work / portfolio visuals: shared by Home, Services, Portfolio
   ============================================ */

/* ---------- Section heading ---------- */
.section-head {
  display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between;
  gap: 24px; margin-bottom: clamp(32px, 4vw, 52px);
}
.section-head .label {
  display: inline-flex; align-items: center; gap: 10px;
  color: var(--red-bright); font-weight: 700; font-size: .92rem; margin-bottom: 12px;
}
.section-head .label::before {
  content: ''; width: 22px; height: 2px; background: var(--red-bright);
}
.section-head p.lead { margin-top: 14px; max-width: 52ch; }
.link-arrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-weight: 700; color: var(--off-white);
  border-bottom: 1px solid var(--grey-line); padding-bottom: 4px;
  transition: border-color .3s var(--ease), color .3s var(--ease);
}
.link-arrow:hover { color: var(--red-bright); border-color: var(--red-bright); }
.link-arrow .arr { transition: transform .3s var(--ease); }
.link-arrow:hover .arr { transform: translateX(4px); }
[dir="rtl"] .link-arrow .arr { transform: scaleX(-1); }
[dir="rtl"] .link-arrow:hover .arr { transform: scaleX(-1) translateX(4px); }

/* ---------- Clients marquee ---------- */
.clients {
  border-block: 1px solid var(--grey-line);
  padding-block: 30px;
  overflow: hidden;
  position: relative;
}
.clients::before, .clients::after {
  content: ''; position: absolute; top: 0; bottom: 0; width: 120px; z-index: 2; pointer-events: none;
}
.clients::before { left: 0;  background: linear-gradient(90deg, var(--black), transparent); }
.clients::after  { right: 0; background: linear-gradient(-90deg, var(--black), transparent); }
.clients-label {
  text-align: center; color: var(--grey); font-size: .85rem; font-weight: 600; margin-bottom: 18px;
}
.clients-track {
  display: flex; align-items: center; gap: clamp(46px, 6vw, 84px); width: max-content;
  animation: marquee 34s linear infinite;
}
.clients { direction: ltr; }
.clients:hover .clients-track { animation-play-state: paused; }
.client-mark {
  font-size: clamp(1.3rem, 2.4vw, 1.8rem); font-weight: 900; color: var(--grey);
  white-space: nowrap; letter-spacing: .02em; opacity: .75;
  transition: color .3s var(--ease), opacity .3s var(--ease);
  direction: ltr;
}
.client-mark:hover { color: var(--off-white); opacity: 1; }
.client-mark.is-ar { font-weight: 800; }
.client-mark small { font-size: .55em; font-weight: 600; opacity: .7; margin-inline-start: 6px; }

/* ---------- Stats ---------- */
.stats {
  display: grid; grid-template-columns: repeat(4, 1fr);
  border: 1px solid var(--grey-line); border-radius: var(--radius); overflow: hidden;
  background: var(--grey-line); gap: 1px;
}
.stat { background: var(--black-soft); padding: clamp(24px, 3vw, 36px); }
.stat strong {
  display: block; font-size: clamp(2.2rem, 4.4vw, 3.4rem); font-weight: 900; line-height: 1;
  color: var(--off-white);
  direction: ltr; unicode-bidi: isolate;
}
.stat span { display: block; margin-top: 10px; color: var(--grey); font-size: .92rem; font-weight: 600; }
@media (max-width: 760px) { .stats { grid-template-columns: repeat(2, 1fr); } }

/* ---------- Media tile (shared) ---------- */
.tile {
  position: relative; display: block; overflow: hidden;
  border-radius: var(--radius); background: var(--black-card);
  border: 1px solid var(--grey-line);
}
.tile img, .tile video {
  width: 100%; height: 100%; object-fit: cover; display: block;
  transition: transform .9s var(--ease), filter .6s var(--ease);
}
.tile:hover img { transform: scale(1.045); }
button.tile { padding: 0; cursor: zoom-in; font: inherit; color: inherit; width: 100%; }

/* ---------- Featured case (Friday) ---------- */
.case-feature {
  display: grid; grid-template-columns: 0.85fr 1.15fr; gap: clamp(28px, 4vw, 60px);
  align-items: center;
}
.case-copy .client-tag {
  display: inline-flex; align-items: center; gap: 10px; padding: 7px 14px; border-radius: 999px;
  background: rgba(232,40,63,.12); color: var(--red-bright); font-weight: 700; font-size: .85rem;
  margin-bottom: 18px;
}
.case-copy h3 { font-family: var(--font-display); font-size: clamp(1.8rem, 3.4vw, 2.6rem); line-height: 1.15; margin-bottom: 16px; }
.case-copy p { margin-bottom: 22px; }
.case-points { list-style: none; margin: 0 0 30px; padding: 0; display: grid; gap: 12px; }
.case-points li {
  display: flex; gap: 12px; align-items: flex-start; color: var(--off-white); font-weight: 600; font-size: .98rem;
}
.case-points li::before {
  content: ''; flex: none; margin-top: 9px; width: 8px; height: 8px; border-radius: 50%;
  background: var(--red-bright); box-shadow: 0 0 0 4px rgba(232,40,63,.18);
}
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips span {
  font-size: .78rem; font-weight: 700; padding: 6px 13px; border-radius: 999px;
  border: 1px solid var(--grey-line); color: var(--grey);
}

.case-mosaic {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px;
  align-items: start;
}
.case-mosaic .col { display: grid; gap: 14px; }
.case-mosaic .col:nth-child(2) { margin-top: 48px; }
.case-mosaic .col:nth-child(3) { margin-top: 18px; }
.case-mosaic .tile { aspect-ratio: 4/5; }

@media (max-width: 960px) {
  .case-feature { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
  .case-mosaic { gap: 8px; }
  .case-mosaic .col { gap: 8px; }
}

/* ---------- Bento work grid ---------- */
.bento {
  display: grid; grid-template-columns: repeat(12, 1fr); grid-auto-rows: 120px; gap: 16px;
}
.bento-card {
  position: relative; overflow: hidden; border-radius: var(--radius);
  border: 1px solid var(--grey-line); background: var(--black-card);
  display: block; isolation: isolate;
}
.bento-card img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  transition: transform 1s var(--ease);
}
.bento-card::after {
  content: ''; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(180deg, transparent 45%, rgba(8,6,7,.92) 100%);
}
.bento-card:hover img { transform: scale(1.05); }
.bento-meta {
  position: absolute; inset-inline: 0; bottom: 0; z-index: 2;
  padding: clamp(16px, 2vw, 24px);
  display: flex; align-items: flex-end; justify-content: space-between; gap: 12px;
}
.bento-meta h3 { font-size: clamp(1.1rem, 1.8vw, 1.45rem); }
.bento-meta span { display: block; color: var(--red-bright); font-size: .8rem; font-weight: 700; margin-bottom: 4px; }
.bento-meta .go {
  flex: none; width: 40px; height: 40px; border-radius: 50%;
  display: grid; place-items: center; background: var(--off-white); color: var(--black);
  transform: scale(.85); opacity: 0; transition: transform .3s var(--ease), opacity .3s var(--ease);
}
[dir="rtl"] .bento-meta .go svg { transform: scaleX(-1); }
.bento-card:hover .go { transform: scale(1); opacity: 1; }

.b-a { grid-column: span 5; grid-row: span 4; }
.b-b { grid-column: span 7; grid-row: span 2; }
.b-c { grid-column: span 4; grid-row: span 2; }
.b-d { grid-column: span 3; grid-row: span 2; }
.b-e { grid-column: span 4; grid-row: span 3; }
.b-f { grid-column: span 4; grid-row: span 3; }
.b-g { grid-column: span 4; grid-row: span 3; }

@media (max-width: 960px) {
  .bento { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 200px; }
  .b-a, .b-b, .b-c, .b-d, .b-e, .b-f, .b-g { grid-column: span 1; grid-row: span 2; }
  .b-b { grid-column: span 2; grid-row: span 1; }
}
@media (max-width: 560px) {
  .bento { grid-template-columns: 1fr; grid-auto-rows: 240px; }
  .b-a, .b-b, .b-c, .b-d, .b-e, .b-f, .b-g { grid-column: span 1; grid-row: span 1; }
  .b-a { grid-row: span 2; }
}

/* ---------- Reels / phones ---------- */
.reels {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(14px, 2vw, 26px);
  align-items: center;
}
.phone {
  position: relative; aspect-ratio: 9/16; border-radius: 30px; overflow: hidden;
  background: #000; border: 6px solid #1d1719;
  box-shadow: 0 30px 60px -30px rgba(0,0,0,.8), 0 0 0 1px var(--grey-line);
}
.phone::before {
  content: ''; position: absolute; top: 9px; left: 50%; transform: translateX(-50%);
  width: 34%; height: 18px; border-radius: 999px; background: #000; z-index: 3;
}
.phone video, .phone img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.phone .reel-cap {
  position: absolute; inset-inline: 0; bottom: 0; z-index: 2; padding: 40px 14px 14px;
  background: linear-gradient(transparent, rgba(0,0,0,.85));
  font-size: .82rem; font-weight: 700;
}
.phone .reel-cap .rc-tag { color: var(--red-bright); font-size: .72rem; margin-bottom: 2px; }
.phone .sound {
  position: absolute; top: 34px; inset-inline-end: 12px; z-index: 3;
  width: 34px; height: 34px; border-radius: 50%; border: none;
  background: rgba(0,0,0,.55); color: #fff; display: grid; place-items: center;
  backdrop-filter: blur(6px);
}
.phone .sound .on { display: none; }
.phone.unmuted .sound .on { display: block; }
.phone.unmuted .sound .off { display: none; }
.reels .phone:nth-child(even) { transform: translateY(36px); }

@media (max-width: 900px) {
  .reels { grid-template-columns: repeat(2, 1fr); }
  .reels .phone:nth-child(even) { transform: translateY(24px); }
}

/* ---------- About mosaic (replaces logo box) ---------- */
.about-mosaic {
  position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: 12px;
}
.about-mosaic .tile { aspect-ratio: 4/5; }
.about-mosaic .tile:nth-child(2) { transform: translateY(36px); }
.about-mosaic .tile:nth-child(4) { transform: translateY(36px); }
.about-mosaic .badge {
  position: absolute; z-index: 2; top: 50%; left: 50%; transform: translate(-50%, -30%);
  width: 118px; height: 118px; border-radius: 50%;
  background: var(--black); border: 1px solid var(--grey-line);
  display: grid; place-items: center; box-shadow: 0 20px 40px -10px rgba(0,0,0,.7);
}
.about-mosaic .badge img { width: 70%; }
.about-mosaic .badge::before {
  content: ''; position: absolute; inset: -6px; border-radius: 50%;
  border: 2px dashed rgba(232,40,63,.55);
  animation: spin 18s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Lightbox ---------- */
.lightbox {
  position: fixed; inset: 0; z-index: 300; display: none;
  background: rgba(6,5,5,.94); backdrop-filter: blur(10px);
  align-items: center; justify-content: center; padding: 60px 70px;
}
.lightbox.is-open { display: flex; }
.lightbox img { max-width: 100%; max-height: 100%; border-radius: 10px; box-shadow: 0 30px 80px rgba(0,0,0,.6); }
.lightbox button {
  position: absolute; border: 1px solid var(--grey-line); background: rgba(20,16,19,.8); color: var(--off-white);
  width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center; font-size: 1.3rem;
}
.lightbox .lb-close { top: 18px; inset-inline-end: 18px; }
.lightbox .lb-prev { left: 16px; top: 50%; transform: translateY(-50%); }
.lightbox .lb-next { right: 16px; top: 50%; transform: translateY(-50%); }
.lightbox .lb-count {
  position: absolute; bottom: 20px; left: 50%; transform: translateX(-50%);
  color: var(--grey); font-size: .85rem; font-weight: 700; direction: ltr;
}
@media (max-width: 620px) {
  .lightbox { padding: 70px 12px; }
  .lightbox .lb-prev, .lightbox .lb-next { top: auto; bottom: 10px; transform: none; }
}

/* ---------- Portfolio case studies ---------- */
.case {
  padding-block: clamp(50px, 7vw, 90px);
  border-top: 1px solid var(--grey-line);
  scroll-margin-top: 90px;
}
.case-head {
  display: grid; grid-template-columns: 1fr 1fr; gap: clamp(20px, 4vw, 60px);
  align-items: end; margin-bottom: clamp(26px, 3vw, 40px);
}
.case-head .idx { color: var(--grey); font-weight: 700; font-size: .85rem; direction: ltr; display: inline-block; }
.case-head h2 { margin-top: 6px; }
.case-head h2 small { display: block; font-size: .42em; color: var(--red-bright); font-weight: 700; margin-top: 8px; }
.case-head .chips { margin-top: 16px; }
@media (max-width: 860px) { .case-head { grid-template-columns: 1fr; } }

.gallery { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.gallery .tile { aspect-ratio: 4/5; }
.gallery .tile.wide { grid-column: span 2; aspect-ratio: auto; }
.gallery .tile.sq { aspect-ratio: 1; }
.gallery .tile.wide img { aspect-ratio: 16/9.6; height: 100%; }
.gallery.cols-3 { grid-template-columns: repeat(3, 1fr); }
.gallery.cols-5 { grid-template-columns: repeat(5, 1fr); }
@media (max-width: 960px) {
  .gallery, .gallery.cols-5 { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 620px) {
  .gallery, .gallery.cols-3, .gallery.cols-5 { grid-template-columns: repeat(2, 1fr); gap: 10px; }
}

.sub-label {
  display: flex; align-items: center; gap: 12px;
  font-weight: 700; color: var(--off-white); font-size: .95rem;
  margin: 34px 0 16px;
}
.sub-label::after { content: ''; flex: 1; height: 1px; background: var(--grey-line); }

.case-reels { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
@media (max-width: 860px) { .case-reels { grid-template-columns: repeat(2, 1fr); } }

/* Portfolio jump nav */
.case-nav {
  position: sticky; top: 64px; z-index: 50;
  background: rgba(10,9,9,.86); backdrop-filter: blur(14px);
  border-block: 1px solid var(--grey-line);
  padding-block: 12px; margin-bottom: 10px;
}
.case-nav .container { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; }
.case-nav .container::-webkit-scrollbar { display: none; }
.case-nav a {
  flex: none; padding: 8px 16px; border-radius: 999px; border: 1px solid var(--grey-line);
  font-weight: 700; font-size: .85rem; color: var(--grey); transition: border-color .25s var(--ease), background-color .25s var(--ease), color .25s var(--ease);
}
.case-nav a:hover, .case-nav a.is-active { border-color: var(--red-bright); color: var(--off-white); background: rgba(232,40,63,.1); }

/* ---------- Services visual ---------- */
.service-row.has-visual { grid-template-columns: 1fr 1.2fr 0.8fr; }
.service-visual { position: relative; height: 210px; }
.service-visual .tile { position: absolute; width: 58%; aspect-ratio: 4/5; box-shadow: 0 20px 40px -18px rgba(0,0,0,.8); }
.service-visual .tile:nth-child(1) { inset-inline-start: 0; top: 0; transform: rotate(-6deg); }
.service-visual .tile:nth-child(2) { inset-inline-end: 0; top: 14px; transform: rotate(6deg); }
.service-visual .tile.land { aspect-ratio: 16/10; width: 80%; }
.service-row.has-visual:hover .service-visual .tile:nth-child(1) { transform: rotate(-9deg) translateY(-6px); }
.service-row.has-visual:hover .service-visual .tile:nth-child(2) { transform: rotate(9deg) translateY(-6px); }
.service-visual .tile { transition: transform .6s var(--ease); }
@media (max-width: 960px) {
  .service-row.has-visual { grid-template-columns: 1fr 1.4fr; }
  .service-visual { display: none; }
}
@media (max-width: 760px) {
  .service-row.has-visual { grid-template-columns: 1fr; }
}
.phone .reel-cap b { display: block; font-weight: 700; }
.case-reels .phone { border-width: 4px; border-radius: 22px; }
@media (min-width: 861px) { .case-reels { grid-template-columns: repeat(6, 1fr); } }

/* [data-i18n] forces display:revert, so spacing lives on wrappers/siblings */
.case-head h2 small { display: inline; }
.case-head .case-sub { font-size: 1.05rem; color: var(--red-bright); font-weight: 700; margin-top: 8px; line-height: 1.4; }
.case-head .case-sub small { font-size: 1em; }
.stat strong { margin-bottom: 10px; }
.section-head h2 { margin-top: 12px; }
.bento-meta h3 { margin-top: 4px; }

/* Marquee tracks are laid out LTR so the -50% loop stays on-screen in RTL */
.strip { direction: ltr; }
.gallery.solo { grid-template-columns: minmax(0, 460px); }
