/*
  RDS v2 Selected Work visual refresh
*/

.portfolio-studio {
  position: relative;
  overflow: hidden;
  scroll-margin-top: 6rem;
  padding-block: clamp(4rem, 7vw, 6.5rem);
  background:
    radial-gradient(
      circle at 92% 12%,
      rgba(0, 174, 239, 0.08),
      transparent 26%
    ),
    linear-gradient(180deg, #f2f6fa 0%, #edf3f8 100%);
}

.portfolio-studio::before {
  position: absolute;
  top: 5rem;
  right: -9rem;
  width: 24rem;
  height: 24rem;
  content: "";
  border: 1px solid rgba(0, 113, 143, 0.1);
  border-radius: 50%;
  pointer-events: none;
}

.portfolio-studio__header {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(19rem, 0.85fr);
  align-items: end;
  gap: clamp(2rem, 5vw, 5rem);
  margin-bottom: clamp(2.5rem, 5vw, 4rem);
}

.portfolio-studio__header h2 {
  max-width: 15ch;
  margin: 0;
  color: #071323;
  font-size: clamp(2.7rem, 4.6vw, 4.5rem);
  line-height: 0.98;
  letter-spacing: -0.05em;
}

.portfolio-studio__intro {
  max-width: 31rem;
  padding-left: 1.35rem;
  border-left: 4px solid #e0a51d;
}

.portfolio-studio__intro p {
  margin-top: 0;
  color: #4f6077;
  line-height: 1.6;
}

.portfolio-studio__intro span {
  color: #00718f;
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.portfolio-studio__layout {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(22rem, 0.88fr);
  gap: 1.35rem;
}

.portfolio-studio__secondary {
  display: grid;
  gap: 1.35rem;
}

.work-card {
  position: relative;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.97);
  border: 1px solid rgba(7, 19, 35, 0.11);
  border-radius: 1.4rem;
  box-shadow: 0 1.5rem 3.5rem rgba(7, 19, 35, 0.1);
}

.work-card--rayrey {
  display: grid;
  grid-template-rows: minmax(24rem, 1fr) auto;
}

.work-card__visual {
  position: relative;
  overflow: hidden;
}

.work-card__visual--rayrey {
  display: grid;
  min-height: 27rem;
  place-items: center;
  padding: clamp(1.5rem, 4vw, 3rem);
  background:
    radial-gradient(
      circle at 80% 20%,
      rgba(115, 193, 75, 0.24),
      transparent 30%
    ),
    linear-gradient(145deg, #102c22, #184733);
}

.project-browser {
  overflow: hidden;
  width: min(100%, 38rem);
  background: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: 1rem;
  box-shadow: 0 2rem 4rem rgba(0, 0, 0, 0.3);
  transform: rotate(-1.3deg);
}

.project-browser__bar {
  display: flex;
  align-items: center;
  gap: 0.38rem;
  min-height: 2.1rem;
  padding-inline: 0.8rem;
  color: #68778a;
  background: #edf2f5;
  border-bottom: 1px solid #d5dee5;
}

.project-browser__bar span {
  width: 0.52rem;
  height: 0.52rem;
  background: #edb129;
  border-radius: 50%;
}

.project-browser__bar span:nth-child(2) {
  background: #52b971;
}

.project-browser__bar span:nth-child(3) {
  background: #2ba9d4;
}

.project-browser__bar small {
  margin-left: 0.45rem;
  font-size: 0.66rem;
  font-weight: 800;
}

.rayrey-preview {
  min-height: 19rem;
  padding: 1rem;
  color: #ffffff;
  background:
    linear-gradient(
      135deg,
      rgba(10, 42, 29, 0.94),
      rgba(25, 83, 54, 0.9)
    );
}

.rayrey-preview__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: 0.8rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.16);
}

.rayrey-preview__header img {
  width: 4rem;
  height: 4rem;
  object-fit: contain;
}

.rayrey-preview__header span {
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.58rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.rayrey-preview__hero {
  display: grid;
  grid-template-columns: 1.25fr 0.75fr;
  align-items: center;
  gap: 1.2rem;
  padding-top: 1.3rem;
}

.rayrey-preview__hero > div:first-child {
  display: grid;
  gap: 0.6rem;
}

.rayrey-preview__hero small {
  color: #9fd87d;
  font-size: 0.6rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.rayrey-preview__hero strong {
  max-width: 13ch;
  font-size: clamp(1.5rem, 3vw, 2.5rem);
  line-height: 0.98;
}

.rayrey-preview__hero span {
  max-width: 28rem;
  color: rgba(255, 255, 255, 0.68);
  font-size: 0.68rem;
  line-height: 1.5;
}

.rayrey-preview__hero b {
  display: inline-flex;
  justify-self: start;
  padding: 0.48rem 0.7rem;
  color: #102c22;
  background: #a7d780;
  border-radius: 999px;
  font-size: 0.62rem;
}

.rayrey-preview__services {
  display: grid;
  gap: 0.55rem;
}

.rayrey-preview__services span {
  padding: 0.65rem;
  color: #163f2c;
  background: rgba(255, 255, 255, 0.9);
  border-radius: 0.55rem;
  font-weight: 900;
}

.work-card__floating-label {
  position: absolute;
  right: 1.1rem;
  bottom: 1.1rem;
  display: grid;
  padding: 0.65rem 0.8rem;
  color: #071323;
  background: rgba(255, 255, 255, 0.96);
  border-radius: 0.8rem;
  box-shadow: 0 1rem 2rem rgba(0, 0, 0, 0.2);
}

.work-card__floating-label span {
  color: #00718f;
  font-size: 0.59rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.work-card__floating-label strong {
  font-size: 0.78rem;
}

.work-card__visual--pillars {
  min-height: 15rem;
  background: #1b1710;
}

.work-card__visual--pillars img {
  width: 100%;
  height: 17rem;
  object-fit: cover;
  object-position: center;
  transition: transform 600ms ease;
}

.work-card--pillars:hover .work-card__visual--pillars img {
  transform: scale(1.035);
}

.work-card__image-overlay {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  display: grid;
  gap: 0.2rem;
  padding: 2.5rem 1.25rem 1rem;
  color: #ffffff;
  background: linear-gradient(transparent, rgba(8, 9, 8, 0.92));
}

.work-card__image-overlay span {
  color: #efbd48;
  font-size: 0.62rem;
  font-weight: 900;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.work-card__image-overlay strong {
  font-size: 1rem;
}

.work-card__content {
  position: relative;
  padding: clamp(1.4rem, 3vw, 2rem);
}

.work-card__topline {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  margin-bottom: 0.8rem;
}

.work-card__topline span {
  color: #d99700;
  font-size: 0.72rem;
  font-weight: 900;
}

.work-card__topline small {
  color: #00718f;
  font-size: 0.67rem;
  font-weight: 900;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.work-card h3 {
  margin: 0 0 0.8rem;
  color: #071323;
  font-size: clamp(1.45rem, 2.2vw, 2.1rem);
  line-height: 1.07;
}

.work-card p {
  color: #4f6077;
  font-size: 0.9rem;
  line-height: 1.6;
}

.work-card__facts {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  padding: 0;
  margin: 1.15rem 0 1.4rem;
  list-style: none;
}

.work-card__facts li {
  padding: 0.4rem 0.6rem;
  color: #17334b;
  background: #edf4f7;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 900;
}

.work-card a {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: #00718f;
  font-weight: 900;
  text-decoration: none;
}

.work-card a:hover {
  color: #071323;
}

.work-card__status {
  display: inline-flex;
  margin-top: 0.5rem;
  padding: 0.45rem 0.65rem;
  color: #775000;
  background: #fff1c6;
  border-radius: 999px;
  font-size: 0.65rem;
  font-weight: 900;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.work-card--system {
  display: grid;
  grid-template-columns: 0.82fr 1.18fr;
  min-height: 17rem;
  color: #ffffff;
  background:
    radial-gradient(
      circle at 15% 20%,
      rgba(31, 197, 232, 0.16),
      transparent 32%
    ),
    linear-gradient(145deg, #071323, #0b2948);
  border-color: rgba(255, 255, 255, 0.09);
}

.work-card--system .work-card__content {
  align-self: center;
}

.work-card--system h3 {
  color: #ffffff;
}

.work-card--system p {
  color: rgba(255, 255, 255, 0.7);
}

.work-card--system a {
  color: #efbd48;
}

.work-card__system-visual {
  position: relative;
  min-height: 17rem;
}

.system-node {
  position: absolute;
  z-index: 2;
  display: grid;
  place-items: center;
  color: #dcebf4;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(94, 218, 244, 0.3);
  border-radius: 0.7rem;
  font-size: 0.54rem;
  font-weight: 900;
  text-transform: uppercase;
}

.system-node--core {
  top: 50%;
  left: 50%;
  width: 4rem;
  height: 4rem;
  color: #071323;
  background: #efbd48;
  border-color: #efbd48;
  border-radius: 50%;
  font-size: 0.8rem;
  transform: translate(-50%, -50%);
}

.system-node--one {
  top: 1.4rem;
  left: 1rem;
  padding: 0.55rem;
}

.system-node--two {
  top: 1.4rem;
  right: 0.7rem;
  padding: 0.55rem;
}

.system-node--three {
  bottom: 1.4rem;
  left: 1rem;
  padding: 0.55rem;
}

.system-node--four {
  right: 0.7rem;
  bottom: 1.4rem;
  padding: 0.55rem;
}

.system-line {
  position: absolute;
  z-index: 1;
  width: 1px;
  height: 4.5rem;
  background: rgba(94, 218, 244, 0.35);
  transform-origin: bottom;
}

.system-line--one {
  top: 3rem;
  left: 42%;
  transform: rotate(-47deg);
}

.system-line--two {
  top: 3rem;
  right: 41%;
  transform: rotate(47deg);
}

.system-line--three {
  bottom: 3rem;
  left: 42%;
  transform: rotate(47deg);
}

.system-line--four {
  right: 41%;
  bottom: 3rem;
  transform: rotate(-47deg);
}

.portfolio-studio__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  margin-top: 1.5rem;
  padding: 1.1rem 1.25rem;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(7, 19, 35, 0.09);
  border-radius: 1rem;
}

.portfolio-studio__footer p {
  max-width: 42rem;
  margin: 0;
  color: #4f6077;
  font-size: 0.85rem;
}

.button--portfolio {
  color: #ffffff;
  background: #00718f;
  white-space: nowrap;
}

.button--portfolio:hover {
  color: #071323;
  background: #efbd48;
}

@media (max-width: 1050px) {
  .portfolio-studio__layout {
    grid-template-columns: 1fr;
  }

  .portfolio-studio__secondary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .work-card--system {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 800px) {
  .portfolio-studio__header {
    grid-template-columns: 1fr;
  }

  .portfolio-studio__secondary {
    grid-template-columns: 1fr;
  }

  .portfolio-studio__footer {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (max-width: 560px) {
  .portfolio-studio {
    padding-block: 3.5rem;
  }

  .portfolio-studio__header h2 {
    max-width: none;
    font-size: clamp(2.4rem, 11vw, 3.5rem);
  }

  .work-card__visual--rayrey {
    min-height: 23rem;
    padding: 1rem;
  }

  .rayrey-preview__hero {
    grid-template-columns: 1fr;
  }

  .rayrey-preview__services {
    grid-template-columns: repeat(3, 1fr);
  }

  .rayrey-preview__services span {
    padding: 0.45rem;
    font-size: 0.55rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .work-card__visual--pillars img {
    transition: none;
  }
}
