/* =============================================
   Portfolio Page — Klover
   Prefix: portfolio__
   ============================================= */

/* ── Hero ──────────────────────────────────── */
.portfolio__hero {
  position: relative;
  height: 719px;
  display: flex;
  align-items: center;
  overflow: hidden;
  background-size: cover;
  background-position: center;
  text-align: center;
}

.portfolio__hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  z-index: 1;
}

.portfolio__hero > .wrap {
  position: relative;
  z-index: 2;
}

.portfolio__hero-content {
  max-width: 820px;
  margin: 0 auto;
}

.portfolio__pill {
  display: inline-block;
  font-family: 'Work Sans', Arial, sans-serif;
  font-size: 26px;
  font-weight: 700;
  line-height: 1.2;
  color: #94bf58;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-bottom: 11px solid #5DEB3C;
  padding-bottom: 6px;
  margin-bottom: 24px;
}

.portfolio__hero-title {
  font-family: 'Work Sans', Arial, sans-serif;
  font-size: clamp(32px, 4vw + 0.5rem, 58px);
  line-height: 1.1;
  color: #ffffff;
  margin: 0 0 20px;
}

.portfolio__hero-title-light {
  font-weight: 300;
}

.portfolio__hero-title-bold {
  font-weight: 700;
}

.portfolio__hero-sub {
  font-family: 'Work Sans', Arial, sans-serif;
  font-size: 19px;
  font-weight: 700;
  line-height: 1.4;
  color: #ffffff;
  max-width: 680px;
  margin: 0 auto;
}

/* ── Hero overlay negative margin for first row ── */
.portfolio__projects-wrap {
  margin-top: -145px;
  position: relative;
  z-index: 3;
}

/* ── Projects Grid ─────────────────────────── */
.portfolio__projects {
  padding: 40px 0 153px;
  background: #1A1A2D;
}

.portfolio__projects-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

/* ── Project Card ──────────────────────────── */
.portfolio__project-card {
  background: #ffffff;
  border: 2px solid #5DEB3C;
  border-radius: 23px;
  overflow: hidden;
  box-shadow: 11px 11px 22px rgba(0, 0, 0, 0.16);
  transition: box-shadow 0.3s ease, transform 0.3s ease;
  display: flex;
  flex-direction: column;
  position: relative;
}

.portfolio__project-card:hover {
  transform: translateY(-4px);
}

.portfolio__project-card-image {
  width: 100%;
  aspect-ratio: 389 / 256;
  overflow: hidden;
  border-radius: 23px 23px 0 0;
}

.portfolio__project-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.portfolio__project-card-body {
  padding: 20px 24px 23px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.portfolio__project-card-tag {
  font-family: 'Work Sans', Arial, sans-serif;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.4;
  color: #43B02A;
  margin: 0 0 12px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.portfolio__project-card-details {
  font-family: 'Work Sans', Arial, sans-serif;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.3;
  margin: 0 0 12px;
}

.portfolio__card-label {
  color: #37579E;
}

.portfolio__card-value {
  color: #1A1A2D;
}

.portfolio__project-card-desc {
  font-family: 'Work Sans', Arial, sans-serif;
  font-size: 13px;
  font-weight: 400;
  line-height: 1.4;
  color: #000000;
  margin: 0 0 54px;
  flex: 1;
}

/* ── Award Badge ──────────────────────────── */
.portfolio__card-bottom {
  margin-top: auto;
}

.portfolio__card-award {
  width: 99px;
  height: 99px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  border: 2px solid #ffffff;
  /* box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25); */
  position: absolute;
  right: 27px;
  bottom: 10px;
}

.portfolio__card-award img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.portfolio__project-card-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #43B02A;
  color: #ffffff;
  font-family: 'Work Sans', Arial, sans-serif;
  font-size: 15px;
  font-weight: 700;
  line-height: 1;
  width: 140px;
  height: 41px;
  border-radius: 11px;
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  transition: background 0.3s ease;
  align-self: flex-start;
}

.portfolio__project-card-btn:hover {
  background: #379a22;
}

/* ── Video Section ─────────────────────────── */
.portfolio__video {
  background: #37579E;
  padding: 100px 8%;
  font-family: 'Work Sans', Arial, sans-serif;
  text-align: center;
  box-shadow: 0 22px 33px rgba(0, 0, 0, 0.2824);
}

.portfolio__video .wrap {
  max-width: 1200px;
  margin: 0 auto;
}

.portfolio__video-title {
  color: #ffffff;
  font-size: 37px;
  font-weight: 300;
  line-height: 1.2;
  margin: 0 0 40px;
}

.portfolio__video-delivered {
  color: #ffffff;
  position: relative;
  display: inline-block;
  font-weight: 600;
}

.portfolio__video-delivered::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -10px;
  width: 100%;
  height: 10px;
  background-color: #5DEB3C;
  border-radius: 2px;
}

.portfolio__video-row {
  margin-top: 0;
}

.portfolio__video-thumb {
  max-width: 1266px;
  margin: 0 auto;
  cursor: pointer;
  position: relative;
  padding: 0 20px;
}

.portfolio__video-thumb img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 8px;
}

/* ── CTA / Contact Section ─────────────────── */
.portfolio__cta {
  background-color: #122E6A;
  padding: 100px 8%;
  font-family: 'Work Sans', Arial, sans-serif;
  position: relative;
}

.portfolio__cta .wrap {
  max-width: 1200px;
  margin: 0 auto;
}

.portfolio__cta-grid {
  display: flex;
  align-items: center;
  gap: 60px;
}

.portfolio__cta-content {
  flex: 1;
  color: #ffffff;
}

.portfolio__cta-title {
  font-size: 62px;
  line-height: 1.1;
  margin: 0 0 0.4em;
}

.portfolio__cta-title-light {
  font-weight: 300;
  color: #ffffff;
}

.portfolio__cta-title-green {
  font-weight: 700;
  color: #5deb3c;
}

.portfolio__cta-content p {
  font-size: 19px;
  line-height: 1.5;
  color: white;
  font-weight: 400;
  max-width: 372px;
  margin-bottom: 34px;
}

.portfolio__cta-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 1em;
}

.portfolio__cta-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 175px;
  height: 51px;
  background: #43B02A;
  color: white;
  font-family: 'Work Sans', Arial, sans-serif;
  font-size: 19px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border: none;
  border-radius: 11px;
  text-decoration: none;
  transition: background 0.3s ease, color 0.3s ease;
}

.portfolio__cta-btn:hover {
  background: white;
  color: #1a1a2e;
}

.portfolio__cta-form {
  flex: 1;
  background: #1A1A2D;
  border-radius: 18px;
  padding: 33px 52px 25px 46px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

.portfolio__cta-form label {
  color: #5DEB3C;
  font-weight: 600;
  font-size: 11px;
  display: block;
  margin-bottom: 0.25em;
}

.portfolio__cta-form .wpcf7 {
  margin: 0;
}

.portfolio__cta-form .wpcf7-form {
  display: flex;
  flex-direction: column;
  gap: 1em;
}

.portfolio__cta-form .wpcf7-form p {
  margin: 0;
  display: flex;
  flex-direction: column;
}

.portfolio__cta-form .wpcf7-form p br {
  display: none;
}

.portfolio__cta-form .wpcf7-form-control-wrap {
  width: 100%;
}

.portfolio__cta-form .wpcf7-form-control {
  width: 100%;
  padding: 0.75em 1em;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 12px;
  background: #f9f9f9;
  color: #41B9C0;
  font-weight: 600;
}

.portfolio__cta-form #contact input,
.portfolio__cta-form #contact select {
  height: 36px;
}

.portfolio__cta-form .wpcf7-form-control:focus {
  outline: none;
  border-color: #379a22;
  background: #1a1a2e;
}

.portfolio__cta-form .wpcf7-submit {
  background: #43B02A;
  color: white;
  border: none;
  height: 35px;
  font-weight: 700;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.3s ease;
  width: 100%;
  margin-top: 0.5em;
  border-radius: 11px;
  max-width: none;
  font-size: 12px;
}

.portfolio__cta-form .wpcf7-submit:hover {
  background: #1a1a2e;
}

/* ── Video Lightbox ──────────────────────────── */
.portfolio__video-lightbox {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 999999;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: lb-fadein 0.25s ease;
}

@keyframes lb-fadein {
  from { opacity: 0; }
  to { opacity: 1; }
}

.portfolio__video-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.88);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.portfolio__video-container {
  position: relative;
  width: 90%;
  max-width: 1200px;
  z-index: 1;
  animation: lb-scalein 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes lb-scalein {
  from { transform: scale(0.92); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

.portfolio__video-close {
  position: absolute;
  top: -44px;
  right: 0;
  width: 36px;
  height: 36px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 50%;
  color: #fff;
  font-size: 20px;
  cursor: pointer;
  z-index: 999999;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease, transform 0.2s ease;
}

.portfolio__video-close:hover {
  background: rgba(255, 255, 255, 0.25);
  transform: scale(1.1);
}

.portfolio__video-container video {
  width: 100%;
  display: block;
  border-radius: 8px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

/* ── Parallax Image ───────────────────────── */
.portfolio__parallax {
  height: 1003px;
  background-image: url('/wp-content/themes/klover/img/projects-image-parallax.webp');
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  background-repeat: no-repeat;
}

/* ── Responsive ────────────────────────────── */
@media screen and (max-width: 1199px) {
  .portfolio__hero {
    padding: 7em 0 5em;
  }

  .portfolio__hero-title {
    font-size: 42px;
  }

  .portfolio__projects-grid {
    gap: 24px;
  }

  .portfolio__cta-title {
    font-size: 48px;
  }
}

@media screen and (max-width: 991px) {
  .portfolio__hero {
    padding: 5em 0 4em;
  }

  .portfolio__parallax {
    height: 500px;
    background-attachment: scroll;
    background-image: url('/wp-content/themes/klover/img/projects-image-parallax-1024.webp');
  }

  .portfolio__hero-title {
    font-size: clamp(28px, 3.5vw, 34px);
  }

  .portfolio__hero-sub {
    font-size: 17px;
  }

  .portfolio__pill {
    font-size: 22px;
  }

  .portfolio__projects-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .portfolio__projects-wrap {
    margin-top: -40px;
  }

  .portfolio__cta-grid {
    flex-direction: column;
    gap: 40px;
  }

  .portfolio__cta-content {
    text-align: center;
  }

  .portfolio__cta-content p {
    max-width: none;
    margin-left: auto;
    margin-right: auto;
  }

  .portfolio__cta-buttons {
    justify-content: center;
  }

  .portfolio__cta-title {
    font-size: 40px;
  }

  .portfolio__video {
    padding: 60px 4%;
  }
}

@media screen and (max-width: 767px) {
  .portfolio__hero {
    padding: 3em 0 2em;
    height: auto;
    min-height: 400px;
  }

  .portfolio__parallax {
    height: 300px;
    background-image: url('/wp-content/themes/klover/img/projects-image-parallax-768.webp');
  }

  .portfolio__hero-title {
    font-size: 1.6em;
  }

  .portfolio__hero-sub {
    font-size: 16px;
  }

  .portfolio__pill {
    font-size: 18px;
    border-bottom-width: 8px;
  }

  .portfolio__projects-grid {
    grid-template-columns: 1fr;
  }

  .portfolio__projects-wrap {
    margin-top: 0;
  }

  .portfolio__cta {
    padding: 60px 5%;
  }

  .portfolio__cta-title {
    font-size: 32px;
  }

  .portfolio__cta-form {
    padding: 24px 20px;
  }

  .portfolio__video {
    padding: 60px 0;
  }

  .portfolio__video-title {
    font-size: 24px;
  }

  .portfolio__video-thumb {
    padding: 0;
  }
}
