/* ReliabilityX — shared styles */

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: 'IBM Plex Sans', ui-sans-serif, system-ui, sans-serif;
  background: #FBFAF8;
  color: #323639;
  -webkit-font-smoothing: antialiased;
  line-height: 1.5;
}

::selection { background: #D26317; color: #fff; }

/* Animations */
@keyframes v3-up {
  from { opacity: 0; transform: translateY(26px); }
  to { opacity: 1; transform: none; }
}

@keyframes v3-fade {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes v3-draw {
  to { stroke-dashoffset: 0; }
}

@keyframes v3-grow {
  from { transform: scaleX(0); }
  to { transform: scaleX(1); }
}

@keyframes v3-marq {
  from { transform: translateX(0); }
  to { transform: translateX(calc(-1 * var(--marquee-distance, 50%))); }
}

@keyframes cs-row-in {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
    scroll-behavior: auto !important;
  }
}

/* Page shell */
.rx-page {
  background: #FFFFFF;
  color: #323639;
  overflow-x: hidden;
  position: relative;
}

.rx-container {
  max-width: 1200px;
  margin: 0 auto;
  padding-left: 40px;
  padding-right: 40px;
}

/* Image placeholders */
.rx-ph {
  display: block;
  position: relative;
  overflow: hidden;
  background: #E7E3DC;
  cursor: pointer;
  border: none;
  padding: 0;
  font: inherit;
  text-align: inherit;
  width: 100%;
}

.rx-ph:focus-visible {
  outline: 2px solid #357FC2;
  outline-offset: 2px;
}

.rx-ph img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  pointer-events: none;
}

.rx-ph::after {
  content: attr(data-placeholder);
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  text-align: center;
  color: #9AA3AC;
  font: 500 13px/1.45 'IBM Plex Sans', ui-sans-serif, system-ui, sans-serif;
  pointer-events: none;
  transition: background .2s, color .2s;
}

.rx-ph::before {
  content: 'Choose image';
  position: absolute;
  left: 50%;
  bottom: 14px;
  transform: translateX(-50%);
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(2, 48, 79, 0.88);
  color: #fff;
  font: 600 11px/1 'IBM Plex Sans', ui-sans-serif, system-ui, sans-serif;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s;
  z-index: 1;
  white-space: nowrap;
}

.rx-ph:hover::before,
.rx-ph:focus-visible::before {
  opacity: 1;
}

.rx-ph:hover::after,
.rx-ph:focus-visible::after {
  background: rgba(255, 255, 255, 0.35);
}

.rx-ph.has-image::after {
  content: 'Change image';
  opacity: 0;
  color: #fff;
  background: rgba(2, 48, 79, 0.55);
}

.rx-ph.has-image:hover::after,
.rx-ph.has-image:focus-visible::after {
  opacity: 1;
}

.rx-ph.has-image::before {
  opacity: 0;
}

.rx-ph--light { background: #F2F3F4; }
.rx-ph--blue { background: #E2EBF3; }

/* Header */
.rx-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(13, 29, 45, 0.1);
}

.rx-header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 40px;
  height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
}

.rx-logo-link {
  display: flex;
  align-items: center;
  text-decoration: none;
  color: #0D1D2D;
  flex: none;
}

.rx-logo {
  height: 38px;
  width: auto;
}

.rx-nav {
  display: flex;
  align-items: center;
  gap: 2px;
}

.nav-btn,
.rx-nav-link {
  background: none;
  border: none;
  cursor: pointer;
  font-family: 'IBM Plex Sans', sans-serif;
  color: #3D4A57;
  font-size: 14px;
  font-weight: 500;
  padding: 10px 14px;
  border-radius: 25px;
  transition: color .15s;
  text-decoration: none;
}

.nav-btn:hover,
.rx-nav-link:hover {
  color: #357FC2;
}

.rx-btn-cta {
  text-decoration: none;
  background: #D26317;
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  padding: 12px 22px;
  border-radius: 25px;
  flex: none;
  transition: background .2s, transform .12s;
  border: none;
  cursor: pointer;
  font-family: 'IBM Plex Sans', sans-serif;
}

.rx-btn-cta:hover { background: #bb5512; }
.rx-btn-cta:active { transform: translateY(1px); }

/* Mega menu */
.rx-mega {
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  background: #FFFFFF;
  border-bottom: 1px solid rgba(13, 29, 45, 0.1);
  box-shadow: 0 34px 60px -34px rgba(2, 48, 79, 0.3);
  animation: v3-up .18s ease-out;
  display: none;
}

.rx-mega.is-open { display: block; }

.rx-mega-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 44px 40px 48px;
  display: grid;
  grid-template-columns: 0.9fr 1.5fr;
  gap: 60px;
}

.rx-mega-intro {
  padding-right: 52px;
  border-right: 1px solid rgba(13, 29, 45, 0.1);
}

.rx-mega-tag {
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #357FC2;
  font-weight: 600;
  margin-bottom: 16px;
}

.rx-mega-title {
  font-family: 'IBM Plex Serif', serif;
  font-weight: 500;
  font-size: 26px;
  line-height: 1.16;
  letter-spacing: -0.01em;
  margin: 0 0 12px;
  color: #0D1D2D;
  text-wrap: balance;
}

.rx-mega-desc {
  font-size: 14px;
  line-height: 1.6;
  color: #5A6570;
  margin: 0 0 24px;
}

.rx-mega-cta {
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: #D26317;
  font-size: 13.5px;
  font-weight: 600;
  transition: gap .2s;
}

.rx-mega-cta:hover { gap: 14px; }

.rx-mega-items {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2px;
}

.rx-mega-item {
  text-decoration: none;
  display: flex;
  gap: 16px;
  padding: 18px 20px;
  border-radius: 25px;
  transition: background .14s;
}

.rx-mega-item:hover { background: #F6F7F8; }

.rx-mega-item-idx {
  font-family: 'IBM Plex Serif', serif;
  font-size: 15px;
  color: #C3CDD6;
  padding-top: 1px;
}

.rx-mega-item-title {
  display: block;
  font-weight: 600;
  font-size: 15px;
  color: #0D1D2D;
  margin-bottom: 5px;
}

.rx-mega-item-desc {
  display: block;
  font-size: 13px;
  line-height: 1.5;
  color: #5A6570;
}

/* Buttons */
.rx-btn-dark {
  text-decoration: none;
  background: #02304F;
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  padding: 16px 30px;
  border-radius: 25px;
  transition: background .18s, transform .18s;
  display: inline-block;
  border: none;
  cursor: pointer;
  font-family: 'IBM Plex Sans', sans-serif;
}

.rx-btn-dark:hover {
  background: #0D1D2D;
  transform: translateY(-2px);
}

.rx-btn-outline {
  text-decoration: none;
  color: #02304F;
  font-size: 15px;
  font-weight: 600;
  padding: 16px 14px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  border-bottom: 2px solid rgba(13, 29, 45, 0.12);
  transition: border-color .18s;
}

.rx-btn-outline:hover { border-color: #D26317; }

.rx-btn-orange {
  text-decoration: none;
  text-align: center;
  background: #D26317;
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  padding: 17px 28px;
  border-radius: 25px;
  transition: background .18s, transform .18s;
  border: none;
  cursor: pointer;
  font-family: 'IBM Plex Sans', sans-serif;
}

.rx-btn-orange:hover {
  background: #ef7a22;
  transform: translateY(-2px);
}

.rx-btn-ghost {
  text-decoration: none;
  text-align: center;
  background: rgba(255, 255, 255, 0.07);
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  padding: 17px 28px;
  border-radius: 25px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: background .18s;
}

.rx-btn-ghost:hover { background: rgba(255, 255, 255, 0.14); }

/* Marquee */
.rx-marquee-wrap {
  position: relative;
  border-top: 1px solid rgba(13, 29, 45, 0.1);
  background: #fff;
  overflow: hidden;
}

.rx-marquee-fade-l,
.rx-marquee-fade-r {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 90px;
  z-index: 2;
  pointer-events: none;
}

.rx-marquee-fade-l {
  left: 0;
  background: linear-gradient(90deg, #fff, rgba(255, 255, 255, 0));
}

.rx-marquee-fade-r {
  right: 0;
  background: linear-gradient(270deg, #fff, rgba(255, 255, 255, 0));
}

.rx-marquee-track {
  display: flex;
  width: max-content;
  flex-shrink: 0;
  will-change: transform;
  animation: v3-marq 48s linear infinite;
}

.rx-marquee-group {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.rx-marquee-item {
  display: inline-flex;
  align-items: center;
  gap: 26px;
  padding: 15px 26px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #5A6570;
  white-space: nowrap;
}

.rx-marquee-dot {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #D4D8DC;
}

/* Footer */
.rx-footer {
  background: linear-gradient(180deg, #02304F, #021F33);
  color: #9FB6CC;
}

.rx-footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 76px 40px 0;
}

.rx-footer-grid {
  display: grid;
  grid-template-columns: 1.7fr 1fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 54px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.rx-footer-col-title {
  font-size: 11.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #5C7C97;
  margin-bottom: 18px;
}

.rx-footer-link {
  text-decoration: none;
  color: #C2D3E1;
  font-size: 14px;
  transition: color .15s;
}

.rx-footer-link:hover { color: #fff; }

.rx-footer-links {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.rx-footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 0 30px;
  flex-wrap: wrap;
  gap: 12px;
}

.rx-footer-meta {
  font-size: 12.5px;
  color: #5C7C97;
}

.rx-footer-legal {
  display: flex;
  gap: 26px;
}

.rx-footer-legal a {
  text-decoration: none;
  color: #5C7C97;
  font-size: 12.5px;
  transition: color .15s;
}

.rx-footer-legal a:hover { color: #fff; }

.rx-footer-logo { height: 32px; width: auto; margin-bottom: 18px; }

/* Newsletter */
.rx-newsletter-form input[type="email"] {
  flex: 1;
  min-width: 220px;
  background: transparent;
  border: none;
  color: #0D1D2D;
  font-size: 15px;
  font-family: 'IBM Plex Sans', sans-serif;
  padding: 17px;
  outline: none;
}

.rx-newsletter-form input::placeholder { color: #9AA3AC; }

.rx-newsletter-thanks { display: none; }
.rx-newsletter-thanks.is-visible { display: flex; }
.rx-newsletter-form.is-hidden { display: none; }

/* Case studies */
.cs-row {
  transition: background .25s ease;
}

.cs-row:hover .cs-num { color: #D26317 !important; }
.cs-row:hover .cs-img-overlay { opacity: 1 !important; }

.cs-btn {
  transition: background .2s ease, color .2s ease, border-color .2s ease, transform .12s ease;
}

.cs-btn:hover {
  background: #0D1D2D !important;
  color: #fff !important;
  border-color: #0D1D2D !important;
  transform: translateY(-1px);
}

.cs-btn:active { transform: translateY(0); }

input:focus {
  border-color: rgba(13, 29, 45, 0.4) !important;
  outline: none;
}
