.gsp{
  --gsp-max: 1280px;
  --gsp-pad: clamp(18px, 14.67px + 0.926vw, 28px);
  --gsp-col-gap: 2.1%;
  --gsp-row-gap: clamp(19px, 23px - 0.278vw, 22px);
  --gsp-card-bg: #FFFFFF;
  --gsp-active-bg: #8EB1F2;
  --gsp-ink: #040404;
  --gsp-card-radius: clamp(20px, 25.33px - 0.370vw, 24px);
  --gsp-media-radius: 20px;
  --gsp-chip-bg: rgba(255,255,255,0.05);
  --gsp-chip-ink: #FFFFFF;
  --gsp-badge-border: #CBCBCB;
  --gsp-badge-bg: #FFFFFF;
  --gsp-font: "Noto Sans Hebrew", system-ui, Arial, sans-serif;
  inline-size: 100%;
  max-inline-size: var(--gsp-max);
  margin-inline: auto;
  padding-inline: var(--gsp-pad);
  font-family: var(--gsp-font);
  color: var(--gsp-ink);
}

.gsp__head{
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  row-gap: 10px;
  margin-block-end: clamp(24px, 16.67px + 2.037vw, 46px);
}

.gsp__head-badge{
  order: 1;
  justify-self: start;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  min-block-size: 28px;
  padding-block: 4px;
  padding-inline: clamp(16px, 10.67px + 1.48vw, 33px);
  border: 1px solid var(--gsp-badge-border);
  border-radius: 10px;
  background-color: var(--gsp-badge-bg);
  font-size: clamp(10px, 7.67px + 0.648vw, 17px);
  line-height: 1.4;
  color: var(--gsp-ink);
}

.gsp__head-title{
  margin: 0;
  order: 2;
  font-family: var(--gsp-font);
  font-weight: 500;
  font-size: clamp(38px, 26.67px + 3.148vw, 72px);
  line-height: clamp(45px, 33.67px + 3.148vw, 79px);
  letter-spacing: 0;
  color: var(--gsp-ink);
}

.gsp__head-sub{
  margin: 0;
  order: 3;
  font-size: clamp(15px, 14.67px + 0.093vw, 16px);
  line-height: clamp(20px, 18.33px + 0.463vw, 25px);
  opacity: .7;
}

/* Tablet: each card sits on top of its image, per the Figma mobile frame. The
   card keeps all four rounded corners and the image tucks under it by the card
   radius, so the photo shows through the corner curves. On a phone the image is
   dropped entirely - see the block at the foot of this file. */
.gsp__split{
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  row-gap: 0;
  align-items: start;
}

/* Every card is white on touch. The blue is a hover state and there is no hover
   on touch, so highlighting the first item there means nothing. */
.gsp__card{
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 12px;
  min-inline-size: 0;
  min-block-size: clamp(217px, 254.33px - 2.593vw, 245px);
  padding-block: clamp(20px, 25.33px - 0.370vw, 24px);
  padding-inline: clamp(18px, 16px + 0.556vw, 24px);
  border-radius: var(--gsp-card-radius);
  background-color: var(--gsp-card-bg);
  box-shadow: 0 4px 54px 1px rgba(0,0,0,0.03);
  color: var(--gsp-ink);
  text-decoration: none;
  transition: background-color .3s ease, box-shadow .3s ease;
}

.gsp__card-text{
  display: flex;
  flex-direction: column;
  gap: clamp(10px, 8px + 0.556vw, 16px);
  flex: 1 1 auto;
  min-inline-size: 0;
  text-align: start;
}
/* The text column stops short of the card's inline end, per the Figma mobile
   card (2:14604). The Figma ratio was set on the shortest project title and
   pushed the longer ones to five lines, so the inset is held at 10% — the
   widest inset that keeps every real title at three lines or fewer. */
.gsp__card-title{
  max-inline-size: 90%;
  font-weight: 500;
  font-size: clamp(38px, 35.67px + 0.648vw, 45px);
  line-height: clamp(45px, 42.33px + 0.463vw, 50px);
  letter-spacing: 0;
  color: inherit;
  overflow-wrap: break-word;
}
.gsp__card-year{ unicode-bidi: isolate; }
.gsp__card-desc{
  margin: 0;
  max-inline-size: 90%;
  font-weight: 400;
  font-size: clamp(15px, 14.67px + 0.093vw, 16px);
  line-height: clamp(20px, 18.33px + 0.463vw, 25px);
  color: inherit;
  opacity: .7;
  overflow-wrap: break-word;
}

.gsp__card-meta{
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: flex-end;
  align-self: flex-end;
}
.gsp__card-logos{ display: none; }
.gsp .gsp__card-logos img{
  display: block;
  width: auto;
  height: 20px;
  max-width: none;
  object-fit: contain;
}
.gsp__arrow{
  display: inline-flex;
  color: inherit;
  font-size: 24px;
}
.gsp__arrow svg{ display: block; width: 24px; height: 24px; fill: currentColor; }

/* The media box only has absolutely positioned children, so its height must come
   from somewhere. aspect-ratio alone collapses to 0 on WebKit when the box is a
   grid item, so a padding-top pseudo element carries the ratio on small screens. */
.gsp__media{
  position: relative;
  z-index: 0;
  overflow: hidden;
  min-inline-size: 0;
  width: 100%;
  margin-block-start: calc(-1 * var(--gsp-card-radius));
  margin-block-end: var(--gsp-row-gap);
  border-radius: var(--gsp-media-radius);
  background-color: #040404;
}
.gsp__media:last-child{ margin-block-end: 0; }
.gsp__media::before{
  content: "";
  display: block;
  width: 100%;
  padding-top: 167.541%;
}

/* The <picture> exists only to carry the breakpoint on its <source>; it must not
   become a box of its own between the media block and the image. */
.gsp__media-pic{ display: contents; }

/* Hello Elementor reset.css sets img{height:auto}. It beats a logical block-size
   declaration on the same computed property, so the fill is written physically
   and with enough specificity to survive the theme reset.
   Written as a descendant rather than a child: display:contents does not remove
   the <picture> from the tree, so the child combinator would no longer match. */
.gsp .gsp__media .gsp__media-img{
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  object-position: center;
  display: block;
}

.gsp__chips{
  position: absolute;
  z-index: 2;
  inset-inline: clamp(20px, 16.67px + 0.926vw, 30px);
  inset-block-end: clamp(24px, 11.33px + 3.519vw, 62px);
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: flex-end;
  gap: 14px 16px;
}
.gsp__chip-group{ display: flex; align-items: center; justify-content: center; gap: 16px; }
.gsp__chip-group:empty{ display: none; }
.gsp__chip{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-inline-size: 94px;
  min-block-size: 33px;
  padding-inline: 15px;
  border-radius: 10px;
  background-color: var(--gsp-chip-bg);
  backdrop-filter: blur(6.5px);
  -webkit-backdrop-filter: blur(6.5px);
  color: var(--gsp-chip-ink);
  font-weight: 500;
  font-size: clamp(14px, 13.33px + 0.185vw, 16px);
  line-height: 1.25;
  white-space: nowrap;
}
.gsp .gsp__chip img{
  display: block;
  width: auto;
  height: 19px;
  max-width: none;
  object-fit: contain;
}

/* Phone: the photographs come off ---------------------------------------
   Each one is 167% of the screen width, so four of them are most of what a
   visitor scrolls through in this section, and nothing in them is information
   the card does not already carry. The cards alone read as a list, which is
   what they are.

   This rule only takes the space back. The download is prevented in the markup,
   by a <source> gated at the same 768px and an <img> holding an inline pixel -
   because display:none on its own does not stop the fetch. That was measured on
   the live page: with the block hidden, the browser still pulled all four
   photographs. The empty blocks are then taken out of the DOM by projects.js. */
@media (max-width: 767px){
  .gsp__media{ display: none; }

  /* The space between cards used to come from the image's bottom margin. */
  .gsp__split{ row-gap: var(--gsp-row-gap); }
}

@media (min-width: 1280px){
  /* Figma 1:1770 — badge pill on its own row at the inline start,
     title and sub share the row below, aligned to the top of that row. */
  .gsp__head{
    grid-template-columns: minmax(0, 49%) minmax(0, 1fr);
    column-gap: 20px;
    row-gap: 20px;
    align-items: start;
  }
  .gsp__head-badge{ grid-column: 1 / -1; grid-row: 1; justify-self: start; order: 0; }
  .gsp__head-title{ grid-column: 1; grid-row: 2; order: 0; }
  .gsp__head-sub{ grid-column: 2; grid-row: 2; order: 0; justify-self: start; max-inline-size: 335px; }

  .gsp__split{ grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); grid-template-rows: var(--gsp-rows); column-gap: var(--gsp-col-gap); row-gap: var(--gsp-row-gap); align-items: stretch; }

  .gsp__card{ grid-column: 1; flex-direction: row; align-items: center; gap: 10px; z-index: auto; }
  /* The desktop card is a row, so the text column is already narrowed by the
     meta column beside it and the mobile inset would double up. */
  .gsp__card-title{ max-inline-size: none; }
  .gsp__card-desc{ max-inline-size: 81%; }
  .gsp__card-meta{ align-self: stretch; flex: 0 0 146px; min-block-size: 151px; }
  .gsp__card-logos{ display: flex; align-items: flex-start; align-self: flex-start; gap: 16px; }

  /* Desktop only: the first card carries the resting state so the image on the
     left has a visible owner before anything is hovered. */
  .gsp__card:first-child{ background-color: var(--gsp-active-bg); box-shadow: none; }

  /* Desktop: the four images stack in one cell and take their height from the
     card rows, so the ratio spacer, the overlap and the bottom margin go. */
  .gsp__media{ grid-column: 2; grid-row: 1 / -1; align-self: stretch; margin-block-start: 0; margin-block-end: 0; opacity: 0; transition: opacity .4s ease; }
  .gsp__media::before{ display: none; }
  .gsp__card:first-child + .gsp__media{ opacity: 1; }
  .gsp__split:has(.gsp__card:hover) .gsp__card:first-child:not(:hover) + .gsp__media{ opacity: 0; }
  .gsp__card:hover + .gsp__media{ opacity: 1; }

  .gsp__split:has(.gsp__card:hover) .gsp__card:first-child:not(:hover){ background-color: var(--gsp-card-bg); box-shadow: 0 4px 54px 1px rgba(0,0,0,0.03); }
  .gsp__card:hover{ background-color: var(--gsp-active-bg); box-shadow: none; }

  .gsp__chips{ flex-wrap: nowrap; justify-content: space-between; }
}

@media (prefers-reduced-motion: reduce){
  .gsp__card, .gsp__media{ transition-duration: .01ms; }
}
