/*
 * Father's House — Documentary Recovery, Story single-column layout 0.1.7.
 * Foundation: theme.json Raleway + site gutters + named colour presets.
 * No article text, media, patient data, or language metadata is stored here.
 * Story visuals use the editorial axis; Gutenberg alignment selects media scale.
 */
.fh-story-shell {
  --fh-story-width: 720px;
  --fh-page-gutter: clamp(1.25rem, 4vw, 2.5rem);
  box-sizing: border-box;
  padding-block: clamp(2.5rem, 5vw, 5rem) clamp(4rem, 7vw, 6rem);
}

.fh-story-heading,
.fh-story-body,
.fh-story-end {
  box-sizing: border-box;
  width: min(100%, var(--fh-story-width));
  max-width: var(--fh-story-width);
  margin-inline: auto;
}

.fh-story-heading {
  margin-bottom: clamp(2.25rem, 4vw, 3.5rem);
}

.fh-story-heading .wp-block-post-title {
  margin: 0;
  color: var(--fh-navy);
  font-size: clamp(2.25rem, 3.4vw, 3.25rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.032em;
  overflow-wrap: break-word;
  text-wrap: balance;
}

.fh-story-heading .wp-block-post-excerpt {
  width: 100%;
  max-width: none;
  margin: 1.25rem 0 0;
  color: var(--fh-text-muted);
  font-size: clamp(1.06rem, 1.4vw, 1.19rem);
  line-height: 1.55;
}

.fh-story-heading .wp-block-post-excerpt__excerpt {
  margin: 0;
}

/* Verified publication date and optional registered region; no invented locality. */
.fh-story-meta {
  width: 100%;
  max-width: var(--fh-story-width);
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 1rem;
  color: var(--fh-text-muted);
  font-size: 0.875rem;
  line-height: 1.5;
}
.fh-story-meta .wp-block-post-date,
.fh-story-meta .wp-block-post-terms {
  margin: 0;
}
.fh-story-meta .wp-block-post-terms:not(:empty)::before {
  content: "·";
  margin-inline-end: 0.35rem;
}
.fh-story-meta a {
  color: var(--fh-brand);
  text-underline-offset: 0.18em;
}

.fh-story-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  justify-items: stretch;
  color: var(--fh-navy);
  font-size: clamp(1.0625rem, 1rem + 0.3vw, 1.125rem);
  font-weight: 400;
  line-height: 1.7;
  overflow-wrap: break-word;
}

.fh-story-body > * {
  box-sizing: border-box;
  min-width: 0;
  max-width: 100%;
  justify-self: start;
}

.fh-story-body > p,
.fh-story-body > ul,
.fh-story-body > ol,
.fh-story-body > blockquote {
  width: 100%;
  margin: 0 0 1.1em;
}

.fh-story-body > p strong,
.fh-story-body > blockquote strong {
  font-weight: 700;
}

.fh-story-body > h2,
.fh-story-body > h3 {
  width: 100%;
  color: var(--fh-navy);
  font-weight: 700;
  text-wrap: balance;
  overflow-wrap: break-word;
}

.fh-story-body > h2 {
  margin: clamp(2.25rem, 2rem + 1vw, 2.75rem) 0 0.75rem;
  font-size: clamp(1.5rem, 2vw, 1.875rem);
  letter-spacing: -0.015em;
  line-height: 1.24;
}

.fh-story-body > h3 {
  margin: 2rem 0 0.5rem;
  font-size: 1.25rem;
  line-height: 1.35;
  letter-spacing: -0.012em;
}

.fh-story-body a {
  color: var(--fh-brand);
  text-decoration: underline;
  text-underline-offset: 0.16em;
  overflow-wrap: anywhere;
}

.fh-story-body a:hover,
.fh-story-back a:hover {
  text-decoration-thickness: 2px;
}

.fh-story-body a:focus-visible,
.fh-story-back a:focus-visible {
  outline: 2px solid var(--fh-brand);
  outline-offset: 2px;
}

.fh-story-body > figure.wp-block-image,
.fh-story-body > .wp-block-embed,
.fh-story-body > .fh-story-video {
  margin-block: 2.5rem;
}

.fh-story-body > figure.wp-block-image {
  width: 100%;
  margin-inline: 0;
}

/* The first documentary frame follows the header without a second media gap. */
.fh-story-body > figure.fh-story-lead-image {
  margin-block-start: 0;
}


/* Single-column Story: every standard block aligns with the reading axis.
   The portrait-only exception is explicit and never changes the text width. */
.fh-story-body > figure.wp-block-image,
.fh-story-body > .wp-block-embed,
.fh-story-body > .fh-story-video,
.fh-story-body > .alignfull,
.fh-story-body > .alignwide {
  box-sizing: border-box;
  width: 100%;
  max-width: var(--fh-story-width);
  justify-self: stretch;
  margin-inline: 0;
}

/* Default landscape images fill the 720px column and keep their source crop. */
.fh-story-body figure.wp-block-image img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  object-fit: contain;
  margin-inline: auto;
}

/* Editor-visible class applied only to actual portrait/detail photographs. */
.fh-story-body .wp-element-caption,
.fh-story-body figcaption {
  margin-top: 0.7rem;
  color: var(--fh-text-muted);
  font-size: 0.875rem;
  line-height: 1.55;
  text-align: start;
}

.fh-story-body > .fh-story-video,
.fh-story-body > .wp-block-embed.is-provider-vimeo .wp-block-embed__wrapper {
  aspect-ratio: 16 / 9;
  background: var(--fh-navy);
}

.fh-story-body > .fh-story-video iframe,
.fh-story-body > .wp-block-embed.is-provider-vimeo iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
}

.fh-story-body > blockquote,
.fh-story-body > .wp-block-quote {
  width: 100%;
  margin: 2.5rem 0;
  padding: 0.35rem 0 0.35rem clamp(1rem, 2.5vw, 1.5rem);
  border-left: 3px solid var(--fh-yellow);
  background: transparent;
  color: var(--fh-navy);
  font-size: clamp(1.25rem, 1.7vw, 1.375rem);
  font-weight: 500;
  line-height: 1.5;
}

.fh-story-body > blockquote p,
.fh-story-body > .wp-block-quote p {
  margin: 0;
}

.fh-story-end {
  margin-top: clamp(3rem, 5vw, 4.5rem);
}

.fh-story-end .wp-block-separator {
  width: 100%;
  max-width: 100%;
  border-color: var(--fh-border);
  opacity: 1;
}

.fh-story-back {
  margin-top: 1.25rem;
  font-size: 0.94rem;
  font-weight: 700;
}

.fh-story-back a {
  color: var(--fh-brand);
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

html:lang(uk) .fh-story-back--en,
html:lang(en) .fh-story-back--uk {
  display: none !important;
}

@media (max-width: 781px) {
  .fh-story-shell {
    --fh-page-gutter: clamp(1.25rem, 4vw, 2.5rem);
    padding-block: 2.5rem 4rem;
    padding-inline: var(--fh-page-gutter);
  }

  .fh-story-body > figure.wp-block-image,
  .fh-story-body > .fh-story-video,
  .fh-story-body > .wp-block-embed {
    margin-block: 1.75rem;
  }
}

@media (max-width: 480px) {
  .fh-story-shell {
    padding-block: 2.25rem 3.5rem;
  }

  .fh-story-heading .wp-block-post-title {
    font-size: clamp(2.12rem, 8vw, 2.5rem);
    letter-spacing: -0.027em;
  }

  .fh-story-heading {
    margin-bottom: 2rem;
  }

  .fh-story-body > blockquote,
  .fh-story-body > .wp-block-quote {
    padding-left: 1rem;
  }
}
