/* Frontend-only refinements kept separate from the pending admin workspace. */

.article-page {
  max-width: 1240px;
}

.article-page h1,
.article-body h2,
.article-body h3 {
  width: 100%;
  max-width: none;
  text-wrap: wrap;
  word-break: normal;
  overflow-wrap: normal;
  hyphens: none;
}

.share-status {
  align-self: center;
  min-height: 1.5em;
  color: var(--green);
  font-size: 15px;
  font-weight: 800;
}

@media (max-width: 720px) {
  .resource-strip {
    gap: 10px;
    overflow: visible;
    background: transparent;
    border: 0;
    box-shadow: none;
  }

  .resource-strip a {
    isolation: isolate;
    min-height: 136px;
    padding: 22px 24px;
    overflow: hidden;
    border: 1px solid rgba(18, 48, 37, 0.1);
    border-radius: 24px;
    box-shadow: 0 16px 34px rgba(18, 48, 37, 0.09);
  }

  .resource-strip a:nth-child(1) {
    background: linear-gradient(135deg, #fff7d9, #e9f7e8);
  }

  .resource-strip a:nth-child(2) {
    background: linear-gradient(135deg, #e5f6fa, #eef8f0);
  }

  .resource-strip a:nth-child(3) {
    background: linear-gradient(135deg, #ffe8e1, #fff4d6);
  }

  .resource-strip a:nth-child(4) {
    background: linear-gradient(135deg, #f7efc9, #dff4df);
  }

  .resource-strip a::before {
    height: 5px;
    transform: scaleX(1);
  }

  .resource-strip a::after {
    position: absolute;
    z-index: -1;
    right: -24px;
    bottom: -34px;
    width: 112px;
    height: 112px;
    content: "";
    background: rgba(255, 255, 255, 0.48);
    border-radius: 999px;
  }

  .resource-strip.reveal a {
    opacity: 0;
    transform: translateY(18px) scale(0.985);
  }

  .resource-strip.reveal.is-visible a {
    animation: resource-card-enter 560ms cubic-bezier(0.16, 1, 0.3, 1) forwards;
  }

  .resource-strip.reveal.is-visible a:nth-child(2) { animation-delay: 70ms; }
  .resource-strip.reveal.is-visible a:nth-child(3) { animation-delay: 140ms; }
  .resource-strip.reveal.is-visible a:nth-child(4) { animation-delay: 210ms; }

  .resource-strip a:active {
    transform: scale(0.985);
  }

  .gallery-copy {
    width: 100%;
    padding-left: 0;
  }

  .gallery-copy h2 {
    display: flex;
    gap: 0.18em;
    width: max-content;
    max-width: 100%;
    font-size: clamp(36px, 11vw, 48px);
    line-height: 1;
    white-space: nowrap;
    text-wrap: nowrap;
  }

  .gallery-copy h2 span {
    display: inline;
    white-space: nowrap;
  }

  .article-page {
    width: calc(100vw - 40px);
    max-width: calc(100vw - 40px);
  }

  .article-page h1 {
    font-size: clamp(38px, 10.5vw, 46px);
  }

  .article-body h2,
  .article-body h3 {
    font-size: clamp(27px, 8vw, 36px);
  }

  .article-tools {
    align-items: center;
  }

  .share-status {
    flex-basis: 100%;
  }
}

@keyframes resource-card-enter {
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@media (prefers-reduced-motion: reduce) {
  .resource-strip.reveal a,
  .resource-strip.reveal.is-visible a {
    opacity: 1;
    transform: none;
    animation: none;
  }
}
