.ingot-story,
.ingot-story * {
  box-sizing: border-box;
}

.ingot-story {
  display: block;
  width: 100%;
  overflow: hidden;
  background: var(--ingot-story-background);
}

.ingot-story__content {
  width: 100%;
  max-width: var(--ingot-story-max-width);
  margin: 0 auto;
}

.ingot-story__picture {
  display: block;
  width: 100%;
  margin: 0 0 var(--ingot-story-gap);
}

.ingot-story__image {
  display: block;
  width: 100%;
  height: auto;
  margin: 0;
  object-fit: contain;
  object-position: center;
  background: var(--ingot-story-background);
}

.ingot-story__image:last-of-type {
  margin-bottom: 0;
}

.ingot-story--has-floating-cta .ingot-story__content {
  padding-bottom: 110px;
}

.ingot-story__floating-cta {
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: 16px;
  z-index: 40;
  display: flex;
  justify-content: center;
  pointer-events: none;
}

.ingot-story__floating-button {
  pointer-events: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: min(100%, 440px);
  min-height: 56px;
  padding: 16px 24px;
  border-radius: 16px;
  background: var(--ingot-cta-bg, #FF9F0A);
  color: var(--ingot-cta-text, #111111) !important;
  text-decoration: none;
  font-size: 15px;
  line-height: 1.1;
  font-weight: 900;
  letter-spacing: 0.15px;
  box-shadow: 0 14px 36px rgba(255, 159, 10, 0.28), 0 6px 18px rgba(0, 0, 0, 0.18);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.ingot-story__floating-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 42px rgba(255, 159, 10, 0.34), 0 8px 20px rgba(0, 0, 0, 0.22);
}

.ingot-story__floating-button span {
  font-size: 17px;
  line-height: 1;
}

@media (min-width: 769px) {
  .ingot-story__floating-cta {
    bottom: 24px;
  }
}

@media (max-width: 768px) {
  .ingot-story__image {
    width: 100%;
    max-width: none;
  }

  .ingot-story--has-floating-cta .ingot-story__content {
    padding-bottom: 94px;
  }

  .ingot-story__floating-cta {
    left: 12px;
    right: 12px;
    bottom: 12px;
  }

  .ingot-story__floating-button {
    width: 100%;
    min-height: 54px;
    font-size: 14px;
    border-radius: 14px;
  }
}


/* Floating CTA visibility hardening */
.ingot-story__floating-button {
  -webkit-appearance: none !important;
  appearance: none !important;
  opacity: 1 !important;
  background: #FF9F0A !important;
  background-color: #FF9F0A !important;
  color: #111111 !important;
  border: 1px solid #E98C00 !important;
  box-shadow: 0 10px 28px rgba(255, 159, 10, .38), 0 4px 12px rgba(0, 0, 0, .16) !important;
  text-shadow: none !important;
  filter: none !important;
  isolation: isolate;
}

.ingot-story__floating-button::before,
.ingot-story__floating-button::after {
  display: none !important;
  content: none !important;
  opacity: 0 !important;
  background: transparent !important;
}

.ingot-story__floating-button:hover {
  background: #F09400 !important;
  background-color: #F09400 !important;
  color: #111111 !important;
  border-color: #D98200 !important;
}

.ingot-story__floating-button:focus,
.ingot-story__floating-button:focus-visible {
  background: #FF9F0A !important;
  color: #111111 !important;
  outline: 2px solid rgba(17, 17, 17, .22) !important;
  outline-offset: 2px;
}

/* Floating CTA attention animation: subtle bounce every 7 seconds */
.ingot-story__floating-button {
  animation: ingot-cta-attention 7s ease-in-out 1.5s infinite;
  transform-origin: center bottom;
  will-change: transform, box-shadow;
}

.ingot-story__floating-button:hover,
.ingot-story__floating-button:active,
.ingot-story__floating-button:focus-visible {
  animation-play-state: paused;
}

@keyframes ingot-cta-attention {
  0%, 16%, 100% {
    transform: translateY(0) scale(1);
    box-shadow: 0 10px 28px rgba(255, 159, 10, .38), 0 4px 12px rgba(0, 0, 0, .16);
  }
  4% {
    transform: translateY(-5px) scale(1.015);
    box-shadow: 0 16px 34px rgba(255, 159, 10, .48), 0 8px 18px rgba(0, 0, 0, .18);
  }
  8% {
    transform: translateY(0) scale(1);
  }
  11% {
    transform: translateY(-2px) scale(1.006);
  }
}

@media (prefers-reduced-motion: reduce) {
  .ingot-story__floating-button {
    animation: none !important;
    transition: none !important;
  }
}

/* CTA placement: part of page content, directly above footer */
.ingot-story--has-floating-cta .ingot-story__content {
  padding-bottom: 0 !important;
}
.ingot-story__floating-cta {
  position: relative !important;
  left: auto !important;
  right: auto !important;
  bottom: auto !important;
  z-index: auto !important;
  width: 100%;
  padding: 26px 16px 30px;
  margin: 0;
  display: flex;
  justify-content: center;
  background: var(--ingot-story-background, #000000);
  pointer-events: auto !important;
}
@media (max-width: 768px) {
  .ingot-story--has-floating-cta .ingot-story__content {
    padding-bottom: 0 !important;
  }
  .ingot-story__floating-cta {
    left: auto !important;
    right: auto !important;
    bottom: auto !important;
    padding: 20px 12px 24px;
  }
  .ingot-story__floating-button {
    width: 100%;
    max-width: 420px;
  }
}


/* CTA boundary behavior: floats only while the real bottom CTA is still below the viewport */
.ingot-story--has-floating-cta .ingot-story__content,
.ingot-story--has-floating-cta .ingot-story__story {
  padding-bottom: 0 !important;
}

.ingot-story__inline-cta {
  position: relative !important;
  z-index: 2;
  width: 100%;
  padding: 26px 16px 30px;
  margin: 0;
  display: flex;
  justify-content: center;
  background: transparent;
  pointer-events: auto !important;
}

.ingot-story__inline-button {
  width: min(100%, 440px);
}

.ingot-story__floating-cta {
  position: fixed !important;
  left: 16px !important;
  right: 16px !important;
  bottom: 16px !important;
  z-index: 60 !important;
  width: auto !important;
  padding: 0 !important;
  margin: 0 !important;
  display: flex !important;
  justify-content: center;
  background: transparent !important;
  pointer-events: none !important;
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: opacity .22s ease, transform .22s ease, visibility .22s ease;
}

.ingot-story__floating-cta.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.ingot-story__floating-cta.is-visible .ingot-story__floating-button {
  pointer-events: auto !important;
}

@media (min-width: 769px) {
  .ingot-story__floating-cta { bottom: 24px !important; }
}

@media (max-width: 768px) {
  .ingot-story__inline-cta { padding: 20px 12px 24px; }
  .ingot-story__inline-button { width: 100%; max-width: 420px; }
  .ingot-story__floating-cta { left: 12px !important; right: 12px !important; bottom: 12px !important; }
  .ingot-story__floating-cta .ingot-story__floating-button { width: 100%; max-width: 420px; }
}
