@property --idp-cat-overlay-left-alpha {
  syntax: "<number>";
  inherits: false;
  initial-value: 0.45;
}

@property --idp-cat-overlay-center-alpha {
  syntax: "<number>";
  inherits: false;
  initial-value: 0.10;
}

@property --idp-cat-overlay-right-alpha {
  syntax: "<number>";
  inherits: false;
  initial-value: 0.45;
}

/* Hide Elementor's related-project wrapper when its shortcode renders no cards. */
body:not(.elementor-editor-active) #reletedpad:not(:has(.idp-related-card, .idp-sps-test-card)) {
  display: none !important;
}

/* -----------------------------
   Site presentation migrated from the child theme.
   Keep before the plugin defaults to preserve the original cascade.
------------------------------ */
@media only screen and (min-width: 320px) {
  .idp-project-meta {
    display: inline-block !important;
    border-top: 1px solid #d9d9d9;
    padding-top: 5px !important;
    margin-top: 1px !important;
    line-height: 1.3 !important;
    letter-spacing: .3px !important;
  }

  .idp-info-row {
    display: block;
  }

  .idp-info-label,
  .idp-info-value {
    display: inline;
    color: #d9d9d9;
  }

  .idp-info-label::after {
    content: ": ";
    font-weight: 600;
  }

  .idp-info-value {
    margin-left: 5px;
  }

  .idp-info-label {
    font-weight: 400;
    color: #C99846;
    text-transform: uppercase;
  }

  .idp-info-label::after {
    content: ":";
    margin-left: 1.5px;
  }

  .idp-info {
    font-size: .85rem;
  }

  .colonspace {
    margin-left: 1.5px;
  }

  .idp-cat-title {
    bottom: 14px !important;
    top: auto !important;
    color: #fff;
    font-weight: 700;
    font-size: 16px !important;
    padding: 0 15px;
    text-transform: uppercase;
    letter-spacing: -.5px;
    border-radius: 5px;
  }

  .idp-breadcrumb {
    font-size: .57rem;
    text-transform: uppercase;
    font-style: italic;
    letter-spacing: .7px;
  }

  .idp-breadcrumb-inner {
    color: #fff;
  }

  .idp-breadcrumb-link {
    font-weight: 600;
    color: #C99846;
  }

  .idp-breadcrumb-link:hover {
    font-weight: 600;
    color: #fff;
  }

  .idp-breadcrumb-inner a,
  .idp-breadcrumb-link {
    text-decoration: none !important;
  }

  .idp-breadcrumb-inner a:hover,
  .idp-breadcrumb-inner a:focus,
  .idp-breadcrumb-link:hover,
  .idp-breadcrumb-link:focus {
    text-decoration: none !important;
  }

  .idp-projects-grid {
    justify-content: center !important;
  }

  .idp-related-heading {
    text-align: left;
    font-size: 16px;
    font-weight: 700;
    line-height: 0.7;
    padding-bottom: 15px;
    border-bottom: 1px solid #4a4a4a6e;
    color: #fff;
    letter-spacing: .3px;
  }

  .idp-project-card {
    position: relative;
    overflow: hidden;
    background-position: center !important;
    background-size: cover !important;
    background-repeat: no-repeat !important;
    display: block;
  }

  .idp-project-card::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    background: linear-gradient(
      to top,
      rgba(0,0,0,.75) 0%,
      rgba(0,0,0,.35) 55%,
      rgba(0,0,0,0) 100%
    ) !important;
  }

  .idp-project-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: inherit;
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    transform: scale(1.05);
    transition: transform .45s ease;
    will-change: transform;
    z-index: 0;
    pointer-events: none;
  }

  .idp-project-overlay {
    position: relative;
    z-index: 2;
  }

  .idp-project-card:hover::after {
    transform: scale(1.10);
  }
}

@media only screen and (min-width: 480px) {
  .idp-related-grid {
    display: flex;
    justify-content: center;
    padding-top: 30px;
    padding-bottom: 30px;
  }

  .idp-related-card {
    max-height: 225px;
    border-radius: 7px !important;
  }

  .idp-related--oceanwp .related-posts-title,
  .idp-related--oceanwp .idp-related-heading {
    margin-bottom: 0px !important;
  }

  .idp-related--oceanwp {
    text-align: center;
  }

  .idp-related-heading {
    display: inline-block;
    text-align: center;
  }

  .idp-related-title {
    text-align: left !important;
  }
}

@media only screen and (min-width: 768px) {
  .idp-related-heading {
    text-align: center;
  }
}

.idp-categories {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.idp-cat-card {
  display: block;
  position: relative;
  min-height: 250px;
  border-radius: 7px;
  overflow: hidden;
  text-decoration: none;
  background: #111;
  background-size: cover;
  background-position: center;
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.10);
}


.idp-cat-card::before {
  --idp-cat-overlay-left-alpha: 0.45;
  --idp-cat-overlay-center-alpha: 0.10;
  --idp-cat-overlay-right-alpha: 0.45;
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.60), rgba(0, 0, 0, 0.18));
}

.idp-cat-card::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(to right,
      rgba(0, 0, 0, var(--idp-cat-overlay-left-alpha)),
      rgba(0, 0, 0, var(--idp-cat-overlay-center-alpha)),
      rgba(0, 0, 0, var(--idp-cat-overlay-right-alpha)));
  transition:
      --idp-cat-overlay-left-alpha 0.4s ease,
      --idp-cat-overlay-center-alpha 0.4s ease,
      --idp-cat-overlay-right-alpha 0.4s ease;
}

.idp-cat-image {
  display: block;
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100% !important;
  height: 100% !important;
  max-width: none !important;
  pointer-events: none;
  object-fit: cover;
  object-position: center;
  filter: grayscale(1);
  transition: filter 0.4s ease;
  image-rendering: auto;
}

.idp-cat-card:hover::before {
  --idp-cat-overlay-left-alpha: 0.70;
  --idp-cat-overlay-center-alpha: 0;
  --idp-cat-overlay-right-alpha: 0;
}

.idp-cat-card:hover .idp-cat-image {
  filter: grayscale(0);
}


.idp-cat-title {
  position: absolute;
  left: 18px;
  bottom: 14px;
  z-index: 2;
  color: #fff;
  font-weight: 700;
  font-size: 22px;
  letter-spacing: .2px;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.35);
  top: auto;
}

.idp-projects-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  min-height: 400px;
  align-items: stretch;
  align-content: flex-start;
}

.idp-project-card {
  border-radius: 7px !important;
  background-size: cover;
  background-position: center;
  transition: all 5s ease-in-out;
}




.idp-project-card {
  flex: 0 0 100%;
  min-height: 250px;
  position: relative;
}




/* Project text overlay container */
.idp-project-overlay {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 12px;
  z-index: 2;
  color: #fff;
}

/* Project title text */
.idp-project-title {
  font-weight: 800;
  font-size: 14px;
  line-height: 1.15;
  margin-bottom: 6px;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.35);
}

/* Project meta text */
.idp-project-meta {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 11px;
  line-height: 1;
  opacity: 0.95;
}

.idp-meta-label {
  font-weight: 700;
  margin-right: 6px;
}


.idp-categories a,
.idp-projects-grid a,
.idp-project-title,
.idp-project-meta,
.idp-cat-title {
  text-decoration: none !important;
}

.idp-project-card {
  position: relative;
}

.idp-project-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top,
      rgba(0, 0, 0, 0.75),
      rgba(0, 0, 0, 0.30),
      rgba(0, 0, 0, 0.20));
  border-radius: 7px;
  opacity: 0.8;
  transition: opacity 0.5s ease;
}

.idp-project-card:hover::before {
  opacity: 1;
  /* reduce intensity */
}


@media only screen and (min-width:480px) {}

@media only screen and (min-width:767px) {

  .idp-project-card {
    flex: 0 0 calc((100% - 7px) / 1);
  }




}

@media only screen and (min-width:991px) {

  .idp-project-card {
    flex: 0 0 calc((100% - 14px) / 3);
  }
.idp-cat-title {
  position: absolute;
  left: 18px;
  top: 14px;
  z-index: 2;
  color: #fff;
  font-weight: 700;
  font-size: 22px;
  letter-spacing: .2px;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.35);
  transform: translateX(-120%);
  opacity: 0;
  transition: transform 0.4s ease, opacity 0.4s ease;
}

.idp-cat-card:hover .idp-cat-title {
  transform: translateX(0);
  opacity: 1;
}

.idp-project-card {
  border-radius: 7px !important;
  background-size: 135%;
  background-position: center;
  transition: all 5s ease-in-out;
  height: 400px;
}

.idp-project-card:hover {
  background-size: 137%;
  transition: all 5s ease-in-out;
}

.idp-project-card::before {
  opacity: 0;
  transition: opacity 0.4s ease;
}

.idp-project-card:hover::before {
  opacity: 1;
}

.idp-cat-card {
  display: block;
  position: relative;
  min-height: 250px;
  border-radius: 7px;
  overflow: hidden;
  text-decoration: none;
  background: #111;
  background-size: 105%;
  background-position: center;
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.10);
}

.idp-project-overlay {
  transform: translateX(-10%);
  opacity: 0;
  transition: transform 0.4s ease, opacity 0.4s ease;
}

.idp-project-card:hover .idp-project-overlay {
  transform: translateX(0);
  opacity: .85;
}
.idp-project-card {
  position: relative;
  overflow: hidden; /* hides sliding content outside */
}

}

@media only screen and (min-width:1080px) {}

@media only screen and (min-width:1200px) {}

@media only screen and (min-width:1400px) {}

@media only screen and (min-width:1600px) {}

/* -------------------------
   Active menu item (Main menu)
   - Only affects the CURRENT item (and its ancestors)
   - Leaves default and hover colors untouched
-------------------------- */
[id^="menu-main-menu"] .current-menu-item > a,
[id^="menu-main-menu"] .current-menu-ancestor > a,
[id^="menu-main-menu"] .current-menu-parent > a,
[id^="menu-main-menu"] .current_page_item > a,
[id^="menu-main-menu"] .current_page_ancestor > a {
  color: #ffffff !important;
}

/* Some themes wrap link text in a span */
[id^="menu-main-menu"] .current-menu-item > a span,
[id^="menu-main-menu"] .current-menu-ancestor > a span,
[id^="menu-main-menu"] .current-menu-parent > a span,
[id^="menu-main-menu"] .current_page_item > a span,
[id^="menu-main-menu"] .current_page_ancestor > a span {
  color: #ffffff !important;
}

/* -----------------------------
   Related Projects (OceanWP style wrapper)
   - Mobile first
------------------------------ */
.idp-related--oceanwp {
  margin-top: 30px;
}

.idp-related--oceanwp .related-posts-title,
.idp-related--oceanwp .idp-related-heading {
  margin-bottom: 15px;
}

/* Related grid/cards */
.idp-related-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.idp-related-grid .idp-related-card {
  display: block;
  box-sizing: border-box;
  flex: 0 0 calc((100% - 12px) / 2);
  max-width: calc((100% - 12px) / 2);
}

.idp-related-card {
  position: relative;
  border-radius: 7px;
  overflow: hidden;
  background: #111;
  background-size: cover;
  background-position: center;
  text-decoration: none;
}

.idp-related-card::after {
  content: "";
  display: block;
  padding-top: 100%;
}

.idp-related-card::before {
  content: "";
  position: absolute;
  inset: 0;
  /* background: linear-gradient(180deg, rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.75)); */
}

.idp-related-title {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 10px;
  z-index: 2;
  color: #fff;
  font-weight: 800;
  font-size: 14px;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.35);
}

/* Tablet+ */
@media only screen and (min-width: 767px) {
  .idp-related-grid .idp-related-card {
    flex: 0 0 calc((100% - 24px) / 3);
    max-width: calc((100% - 24px) / 3);
  }
}

/* Strong overrides to ensure OceanWP/Elementor doesn't flatten IDP related cards */
.idp-related.idp-related--oceanwp .idp-related-grid{
  display:flex !important;
  flex-wrap:wrap !important;
  gap:12px !important;
}
.idp-related.idp-related--oceanwp .idp-related-card{
  display:block !important;
  position:relative !important;
  overflow:hidden !important;
  border-radius:7px !important;
  background-size:cover !important;
  background-position:center !important;
  text-decoration:none !important;
}
.idp-related.idp-related--oceanwp .idp-related-card::after{
  content:"" !important;
  display:block !important;
  padding-top:100% !important;
}
.idp-related.idp-related--oceanwp .idp-related-card::before{
  content:"" !important;
  position:absolute !important;
  inset:0 !important;
  background:linear-gradient(180deg, rgba(0,0,0,0.05), rgba(0,0,0,0.75)) !important;
}
.idp-related.idp-related--oceanwp .idp-related-title{
  position:absolute !important;
  left:12px !important;
  right:12px !important;
  bottom:10px !important;
  z-index:2 !important;
  color:#fff !important;
  font-weight:800 !important;
  font-size:14px !important;
  text-shadow:0 2px 12px rgba(0,0,0,0.35) !important;
}
