/* Sales Target Management page redesign.
   Overrides are page-scoped so no shared page or component is changed. */
.tm-page {
  --tm-blue: #2c67f2;
  --tm-cyan: #62cff4;
  --tm-deep: #061a35;
}

.tm-page .tm-hero {
  background-color: var(--tm-deep);
  background-image: linear-gradient(180deg, #061a35 0%, #0b3a68 33%, #165e9e 66%, #3284ce 100%);
}

/* Keep the shared Products dropdown aligned with the Lead Management page.
   The base navigation leaves these links as block elements, which makes the
   icon/text rows expand and pushes the final product group out of the menu. */
.tm-page .ffm-nav-shell .sub-menu.triple .box .menu-items {
  display: flex;
  align-items: center;
}

.tm-page .ffm-nav-shell .sub-menu.triple .box .menu-items img {
  display: inline-block;
  flex: 0 0 auto;
}

/* Stabilize the Target Management header without changing the shared header.
   The legacy dropdown animates clip-path and every property at once, which can
   flash during compositing while the page's hero animation is also running. */
.tm-page .ffm-nav-shell .header-container,
.tm-page .ffm-nav-shell .header-container-box,
.tm-page .ffm-nav-shell .sub-menu.triple {
  backface-visibility: hidden;
}

.tm-page .ffm-nav-shell .menu-item .sub-menu.triple {
  visibility: hidden;
  clip-path: none;
  opacity: 0;
  pointer-events: none;
  transform: translate3d(0, 4px, 0);
  transition: opacity 160ms ease, transform 160ms ease, visibility 0s linear 160ms;
  will-change: opacity, transform;
}

.tm-page .ffm-nav-shell .menu-item:hover .sub-menu.triple,
.tm-page .ffm-nav-shell .menu-item:focus-within .sub-menu.triple {
  visibility: visible;
  opacity: 1;
  pointer-events: auto;
  transform: translate3d(0, 0, 0);
  transition-delay: 0s;
}

.tm-page .ffm-nav-shell #product-div::after {
  bottom: -18px;
  height: 20px;
}

.tm-page main .tm-hero h1 {
  max-width: 1400px;
  text-wrap: balance;
}

.tm-page main .tm-hero .ffm-hero-eyebrow {
  font-size: 18px !important;
}

.tm-page main .tm-hero-inner > p:not(.ffm-hero-eyebrow) {
  font-size: 16px !important;
}

.tm-page .tm-hero-cycle-line {
  height: 1.2em;
  flex-wrap: nowrap;
  gap: 0.22em;
  justify-content: center;
  font-size: 0.88em;
  line-height: inherit;
  text-align: center;
  white-space: nowrap;
}

.tm-page .tm-hero-cycle-rotator {
  width: 3.75em;
  min-width: 3.75em;
  flex: 0 0 3.75em;
}

.tm-page .tm-hero-cycle-rotator .ffm-hero-rotating-text {
  min-width: 100%;
  text-align: left;
}

.tm-page .tm-hero-title-gradient {
  display: inline-block;
  height: auto;
  color: var(--tm-cyan);
  background: linear-gradient(90deg, #62cff4 0%, #2c67f2 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  white-space: normal;
}

.tm-page .tm-hero-image-frame {
  position: relative;
  z-index: 1;
  width: min(100%, 700px);
  aspect-ratio: 3879 / 2390;
  margin: 48px auto -15.4%;
  padding: 0;
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  backface-visibility: hidden;
  transform: translateZ(0);
}

.tm-page .tm-hero-image-surface {
  position: relative;
  z-index: 1;
  display: grid;
  width: 100%;
  height: 100%;
  min-height: 0;
  padding: clamp(12px, 1.25vw, 24px);
  place-items: center;
  overflow: hidden;
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 24px 48px rgba(2, 22, 48, 0.18);
  backface-visibility: hidden;
  contain: paint;
  transform: translateZ(0);
}

.tm-page .tm-hero-image {
  display: block;
  width: 100%;
  height: 100%;
  max-height: none;
  object-fit: contain;
  background: #fff;
  backface-visibility: hidden;
  transform: translateZ(0);
}

.tm-page .ffm-logo-section .company-logo-heading-text {
  font-size: 16px !important;
  font-weight: 500;
}

.tm-page .ffm-logo-section .company-logo-image {
  width: calc(100% - 24px);
  max-width: 164px;
  height: 64px;
}

.tm-page .tm-challenge .ffm-challenge-copy h2,
.tm-page .tm-challenge .ffm-accent-copy {
  max-width: 780px;
}

.tm-page main .tm-challenge .ffm-worldwide-trust {
  margin-top: 18px;
  font-size: 14px !important;
  line-height: 1.3 !important;
}

.tm-page .tm-challenge .ffm-demo-card h3 {
  text-align: left;
}

.tm-page main .tm-challenge .tm-form-supporting {
  margin: 12px 0 18px;
  font-size: 16px !important;
  line-height: 1.4 !important;
}

/* Keep the target workflow visually identical to the shared Field Force layout. */
.tm-page main .tm-how .ffm-section-heading h2 {
  color: #111;
  background: none;
  -webkit-text-fill-color: currentColor;
}

.tm-page main .tm-how .ffm-section-heading > p {
  max-width: 960px;
  margin: 20px auto 0;
  font-size: clamp(18px, 1.5vw, 22px) !important;
  line-height: 1.35 !important;
  text-align: center;
  white-space: normal;
}

.tm-page .tm-how .ffm-how-grid {
  align-items: center;
}

.tm-page .tm-how .ffm-how-copy,
.tm-page .tm-how .ffm-how-visual {
  align-self: center;
}

.tm-page .tm-how .ffm-how-copy {
  position: relative;
}

.tm-page .tm-powered-by {
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  margin: 20px 0 0 !important;
  color: #536b81 !important;
  font-size: 14px !important;
  line-height: 1.5 !important;
}

.tm-page .tm-powered-by a {
  color: var(--tm-blue);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.tm-page main .ffm-mid-cta > .ffm-container {
  width: min(100%, 1440px);
}

.tm-page main .ffm-mid-cta h2 {
  max-width: 1440px;
  font-weight: 600 !important;
  white-space: normal;
  text-wrap: wrap;
}

.tm-page main .tm-mid-cta-lead {
  display: block;
  font-size: clamp(32px, 2.9vw, 44px);
  line-height: 1.08;
}

@media (min-width: 1200px) {
  .tm-page main .tm-mid-cta-lead {
    white-space: nowrap;
  }
}

.tm-page main .ffm-mid-cta p {
  max-width: 1260px;
  margin: 34px auto 48px;
  font-size: 16px !important;
  line-height: 1.5 !important;
  text-align: center;
  text-wrap: wrap;
}

.tm-page .tm-mid-cta-review {
  display: flex;
  margin: 18px auto 0;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: var(--ffm-orange);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.25;
}

.tm-page .tm-mid-cta-review-stars {
  font-size: 15px;
  letter-spacing: 3px;
  line-height: 1;
}

.tm-page .tm-standout {
  background: #fff;
}

.tm-page .tm-standout .ffm-feature-card p,
.tm-page .tm-products .ffm-feature-card p {
  display: block;
  overflow: visible;
  -webkit-line-clamp: unset;
}

.tm-page .tm-comparison {
  background: #eaf6fb;
}

.tm-comparison-wrap {
  overflow-x: auto;
  border: 1px solid rgba(44, 103, 242, 0.14);
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 18px 42px rgba(7, 63, 112, 0.08);
}

.tm-comparison-table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
}

.tm-comparison-table th,
.tm-comparison-table td {
  padding: 20px 24px;
  border-bottom: 1px solid #dce8f3;
  color: #21384e;
  font-size: 16px;
  line-height: 1.5;
  text-align: left;
  vertical-align: top;
}

.tm-comparison-table th {
  color: #fff;
  background: linear-gradient(90deg, #0b3a68 0%, #165e9e 60%, #3284ce 100%);
  font-weight: 600;
}

.tm-comparison-table tr:last-child td {
  border-bottom: 0;
}

.tm-page .tm-industries,
.tm-page .tm-products {
  background: #fff;
}

/* These sections are now adjacent, so avoid stacking both full section gaps. */
.tm-page .tm-industries {
  padding-bottom: clamp(36px, 3.125vw, 60px);
}

.tm-page .tm-products {
  padding-top: clamp(36px, 3.125vw, 60px);
}

.tm-page .tm-industry-card {
  min-height: 464px;
}

@media (min-width: 992px) {
  .tm-page main .ffm-industries .ffm-section-heading h2 {
    font-size: clamp(28px, 3vw, 38px) !important;
    white-space: nowrap;
  }
}

.tm-page .tm-products .ffm-feature-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 22px;
}

.tm-page .tm-products .ffm-feature-card {
  min-height: 316px;
  padding: 28px 24px;
  border-radius: 14px;
}

.tm-page .tm-products .ffm-feature-card h3 {
  font-weight: 700 !important;
}

.tm-page .ffm-faq-accordion .accordion-button {
  font-weight: 400 !important;
}

.tm-page footer .website-footer {
  margin-top: 0;
}

@media (hover: hover) {
  .tm-page .tm-products .ffm-feature-card:hover .ffm-feature-cta,
  .tm-page .tm-standout .ffm-feature-card:hover .ffm-feature-cta {
    color: var(--tm-cyan);
  }
}

@media (max-width: 1199px) {
  .tm-page .tm-hero .ffm-hero-second-line {
    height: auto;
    flex-wrap: wrap;
    white-space: normal;
  }

  .tm-page .tm-hero .tm-hero-cycle-line {
    height: auto;
    flex-wrap: wrap;
    white-space: normal;
  }

  .tm-page .tm-products .ffm-feature-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

}

@media (max-width: 991px) {
  .tm-page .tm-products .ffm-feature-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 767px) {
  .tm-page .tm-hero {
    padding-right: 20px;
    padding-left: 20px;
  }

  .tm-page .tm-hero .ffm-hero-inner {
    width: 100%;
  }

  .tm-page main .tm-hero .ffm-hero-eyebrow {
    font-size: 16px !important;
  }

  .tm-page main .tm-hero-inner > p:not(.ffm-hero-eyebrow) {
    font-size: 14px !important;
  }

  .tm-page .tm-hero .ffm-hero-title-fixed,
  .tm-page .tm-hero .ffm-hero-second-line {
    height: auto;
    white-space: normal;
  }

  .tm-page .tm-hero .ffm-hero-second-line {
    flex-wrap: wrap;
  }

  .tm-page .tm-powered-by {
    position: static;
    width: auto;
    margin-top: 20px !important;
  }

  .tm-page main .ffm-mid-cta h2 {
    font-size: clamp(28px, 7vw, 34px) !important;
  }

  .tm-page main .tm-mid-cta-lead {
    font-size: clamp(32px, 8vw, 38px);
  }

  .tm-page main .ffm-mid-cta p {
    max-width: 34ch;
    margin: 24px auto 32px;
    font-size: 15px !important;
    line-height: 1.45 !important;
  }

  .tm-page .tm-mid-cta-review {
    flex-wrap: wrap;
    gap: 8px;
    font-size: 12px;
  }

  .tm-page .tm-mid-cta-review-stars {
    font-size: 14px;
    letter-spacing: 2px;
  }

}

@media (max-width: 640px) {
  .tm-page .tm-products .ffm-feature-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .tm-page .tm-products .ffm-feature-card {
    min-height: 300px;
  }

  .tm-page .tm-hero .tm-hero-cycle-line {
    height: auto;
    flex-wrap: wrap;
    white-space: normal;
  }

  .tm-page .tm-hero .tm-hero-cycle-line .ffm-hero-title-prefix {
    width: 100%;
  }

  .tm-page .tm-hero-cycle-rotator {
    margin-right: auto;
  }

  .tm-page .tm-hero-cycle-suffix {
    margin-left: auto;
  }

  .tm-page .tm-hero-image-frame {
    width: 100%;
    margin: 42px 0 -20%;
  }

  .tm-page .tm-hero-image-surface {
    padding: 8px;
    border-radius: 14px;
    box-shadow: 0 18px 36px rgba(2, 22, 48, 0.16);
  }
}

@media (prefers-reduced-motion: reduce) {
  .tm-page [data-tm-reveal] {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
}
