/* ── Embed (iframe) block ──
   Width is responsive (fills the section's max-width). Height is
   either ratio-based (16:9 / 4:3 / 1:1) or a fixed pixel value.
   Caption flows below. */
.block-embed {
  background: var(--color-bg);
  padding: var(--space-section-y) var(--space-section-x);
}
.block-embed .embed-inner {
  max-width: 960px;
  margin: 0 auto;
}
.block-embed .embed-wrap {
  position: relative;
  width: 100%;
  background: var(--color-surface);
  margin-top: 32px;
  overflow: hidden;
}
.block-embed .embed-wrap iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}
.block-embed .embed-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  min-height: 240px;
  font-family: var(--font-eyebrow);
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-muted);
  padding: 40px 20px;
  text-align: center;
}
.block-embed .embed-caption {
  margin-top: 16px;
  font-size: 14px;
  color: var(--color-muted);
  font-style: italic;
  text-align: center;
}

/* Editor-only configuration panel: appears below the iframe in edit
   mode, holds the URL/ratio/height fields. Hidden on the public site. */
.block-embed .embed-edit-fields { display: none; }
body.cms-edit.cms-authed .block-embed .embed-edit-fields {
  display: block;
  margin-top: 18px;
  padding: 16px 20px;
  background: var(--color-surface);
  border: 1px dashed var(--color-border);
  border-radius: 4px;
}
.block-embed .embed-edit-row {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 8px;
  font-family: var(--font-eyebrow);
  font-size: 12px;
}
.block-embed .embed-edit-row:last-of-type { margin-bottom: 0; }
.block-embed .embed-edit-label {
  flex: 0 0 60px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-muted);
}
.block-embed .embed-edit-value {
  flex: 1 1 auto;
  font-family: monospace;
  font-size: 13px;
  background: var(--color-bg);
  padding: 6px 10px;
  border: 1px solid var(--color-border);
  word-break: break-all;
  letter-spacing: normal;
  text-transform: none;
  color: var(--color-fg);
  /* Don't let the global pre-line rule turn one long URL into a
     visual line break — these are single-line values. */
  white-space: nowrap;
  overflow-x: auto;
}
.block-embed .embed-edit-hint {
  flex: 0 0 auto;
  font-size: 11px;
  font-style: italic;
  letter-spacing: normal;
  text-transform: none;
  color: var(--color-muted);
}
.block-embed .embed-edit-tip {
  margin-top: 12px;
  font-size: 11px;
  font-style: italic;
  color: var(--color-muted);
  letter-spacing: normal;
  text-transform: none;
}
.block-embed .embed-edit-tip code {
  font-family: monospace;
  background: var(--color-bg);
  padding: 1px 5px;
  border: 1px solid var(--color-border);
  font-size: 0.92em;
}

@media (max-width: 480px) {
  .block-embed { padding: 56px 20px; }
}
