/* Published-project previews */
.project-card.smart .project-art:before {
  background: linear-gradient(135deg, rgba(14, 38, 30, .2), rgba(18, 83, 72, .18)), repeating-linear-gradient(90deg, #243f34 0 2px, #416557 2px 42px);
}

.article-preview {
  position: absolute;
  z-index: 2;
  inset: 54px 30px 30px;
  background: rgba(255, 255, 255, .94);
  padding: 22px 24px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  box-shadow: 0 18px 35px rgba(16, 30, 22, .24);
  transition: .25s;
}

.project-card:hover .article-preview {
  transform: translateY(-3px);
  box-shadow: 0 22px 42px rgba(16, 30, 22, .3);
}

.article-preview .publication {
  display: inline-flex;
  align-items: center;
  min-height: 25px;
  padding: 4px 8px;
  background: #183f39;
  color: white;
  font: 700 9px Manrope;
  letter-spacing: .04em;
}

.article-preview .publication.bbc {
  background: #b80000;
  text-transform: uppercase;
  letter-spacing: .08em;
}

.article-preview > small {
  margin-top: 16px;
  font-size: 8px;
  text-transform: uppercase;
  letter-spacing: .14em;
  color: #7c8580;
}

.article-preview > strong {
  margin-top: 9px;
  max-width: 95%;
  font: 600 15px/1.34 Manrope;
  color: #16231c;
}

.article-cta {
  margin-top: auto;
  font-size: 9px;
  font-weight: 700;
  color: #4f5e56;
}

.project-card:has(.article-preview) .project-arrow {
  display: none;
}

/* RDM family monogram */
.logo-mark {
  width: 58px;
  height: 46px;
  border-radius: 0;
  transform: none;
  padding: 0;
  background: #fff;
}

.logo-mark img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
}

.footer-brand .logo-mark {
  background: #fff;
}

.family-line > span {
  width: 46px;
  height: 46px;
  font: 700 11px Manrope, sans-serif;
  letter-spacing: .02em;
}

.contact-options a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Give the primary brand more presence in the top navigation. */
.nav-wrap > .logo {
  gap: 13px;
}

.nav-wrap > .logo .logo-mark {
  width: 92px;
  height: 62px;
}

.nav-wrap > .logo .logo-copy b {
  font-size: 25px;
}

@media (max-width: 760px) {
  .nav-wrap > .logo {
    gap: 9px;
  }

  .nav-wrap > .logo .logo-mark {
    width: 78px;
    height: 54px;
  }

  .nav-wrap > .logo .logo-copy b {
    font-size: 22px;
  }

  .article-preview {
    inset: 52px 24px 24px;
    padding: 20px;
  }

  .article-preview > strong {
    font-size: 16px;
  }
}

/* Brand-mark sizing refinements */
.credential-mark {
  overflow: hidden;
  background: #fff;
}

.credential-mark img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
}

.protocol-logo img[alt="Modbus"] {
  max-width: none;
  width: 100%;
  height: 100%;
  object-fit: fill;
  transform: scale(1.18, 1.65);
}

.protocol-logo img[alt="UniFi"] {
  max-width: none;
  width: 100%;
  height: 100%;
  object-fit: fill;
  transform: scale(1.05, 1.18);
}

.protocol-logo:has(img[alt="Modbus"]) {
  padding: 0;
  overflow: hidden;
}

.protocol-logo:has(img[alt="UniFi"]) {
  padding: 5px;
  overflow: hidden;
}

/* Service photography */
.service-card {
  min-height: 500px;
  overflow: hidden;
}

.service-image {
  height: 138px;
  margin: 18px -26px 0;
  overflow: hidden;
  background: #dfe7e0;
}

.service-image img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  transition: transform .45s ease;
}

.service-card:hover .service-image img {
  transform: scale(1.04);
}

.service-card h3 {
  margin-top: 22px;
}

.audience-image.business {
  background-image: linear-gradient(135deg, rgba(39,67,50,.05), rgba(12,27,19,.1)), url("/service-images/business-section.webp");
  background-position: 52% center;
  filter: saturate(.82);
}

@media (max-width: 760px) {
  .service-card {
    min-height: 470px;
  }

  .service-image {
    height: 165px;
  }
}

/* First improvement batch: robust content, faster imagery and clearer contact routes. */
.hero-image {
  background-image: url("/rdm-hero.webp");
}

.audience-image {
  background-image: linear-gradient(135deg, rgba(39,67,50,.05), rgba(12,27,19,.1)), url("/rdm-hero.webp");
}

.skip-link {
  position: fixed;
  z-index: 3000;
  top: 12px;
  left: 12px;
  padding: 10px 14px;
  background: #fff;
  color: #12231b;
  transform: translateY(-160%);
  transition: transform .15s ease;
}

.skip-link:focus {
  transform: translateY(0);
}

.phone-link {
  white-space: nowrap;
}

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

.service-area-note {
  margin: 24px 0 26px;
  padding: 18px 20px;
  border-left: 3px solid #a6c1ad;
  background: rgba(255, 255, 255, .08);
}

.service-area-note strong,
.service-area-note span {
  display: block;
}

.service-area-note strong {
  margin-bottom: 6px;
  color: #fff;
  font: 700 11px/1.3 Manrope, sans-serif;
  letter-spacing: .09em;
  text-transform: uppercase;
}

.service-area-note span {
  color: rgba(255, 255, 255, .86);
  font-size: 13px;
  line-height: 1.6;
}

.contact-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.contact-call {
  border: 1px solid rgba(255, 255, 255, .65);
  color: #fff;
}

.form-status {
  margin: 0;
  color: #8b382f;
  font-size: 12px;
  line-height: 1.5;
}

.form-status.success {
  color: #2f6848;
}

.check a,
.footer-bottom a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.legal-entity {
  margin-top: 10px !important;
  font-size: 9px !important;
}

.whatsapp-float {
  position: fixed;
  right: 24px;
  bottom: 96px;
  z-index: 1000;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 52px;
  padding: 0 20px;
  border: 2px solid rgba(255, 255, 255, .7);
  border-radius: 999px;
  background: #25d366;
  color: #082b1a;
  box-shadow: 0 12px 30px rgba(8, 43, 26, .28);
  font: 700 15px/1 Manrope, sans-serif;
  text-decoration: none;
  transition: transform .16s ease, box-shadow .16s ease, background .16s ease;
}

.whatsapp-float:hover {
  transform: translateY(-2px);
  background: #31df73;
  box-shadow: 0 15px 34px rgba(8, 43, 26, .34);
}

.whatsapp-float:focus-visible {
  outline: 3px solid #fff;
  outline-offset: 3px;
}

.whatsapp-float svg {
  width: 25px;
  height: 25px;
  flex: 0 0 auto;
}

.cookie-notice {
  position: fixed;
  left: 20px;
  bottom: 20px;
  z-index: 1100;
  width: min(520px, calc(100vw - 40px));
  padding: 18px 20px;
  border: 1px solid rgba(255, 255, 255, .22);
  border-radius: 10px;
  background: #12231b;
  color: #fff;
  box-shadow: 0 18px 50px rgba(0, 0, 0, .32);
  font-size: 13px;
  line-height: 1.55;
}

.cookie-notice strong {
  display: block;
  margin-bottom: 5px;
  font-size: 15px;
}

.cookie-notice p {
  margin: 0;
  color: rgba(255, 255, 255, .82);
}

.cookie-actions {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 13px;
}

.cookie-actions a {
  color: #fff;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.cookie-actions button {
  min-height: 38px;
  margin-left: auto;
  padding: 0 17px;
  border: 0;
  border-radius: 999px;
  background: #f4f0e8;
  color: #12231b;
  font: 700 13px/1 Manrope, sans-serif;
  cursor: pointer;
}

@media (max-width: 760px) {
  .published-projects {
    grid-template-columns: 1fr;
  }

  .phone-link {
    font-size: 10px;
  }

  .hero-actions .button {
    width: 100%;
  }

  .whatsapp-float {
    right: 14px;
    bottom: calc(14px + env(safe-area-inset-bottom));
    min-height: 48px;
    padding: 0 17px;
    font-size: 14px;
  }

  .cookie-notice {
    left: 12px;
    bottom: 72px;
    width: calc(100vw - 24px);
    padding: 16px;
  }
}
