/*
Theme Name: Pam Stobodzian — Sitio completo estable
Theme URI: https://www.stobodzian.com/
Author: OpenAI para Pam Stobodzian
Description: Tema WordPress estable para Inicio, Ebooks y la página del ebook, con reparación automática de imágenes heredadas de versiones anteriores.
Version: 1.7.0
Requires at least: 6.4
Requires PHP: 7.4
Text Domain: pam-stobodzian
*/

:root {
  --stb-bg: hsl(36 43% 96%);
  --stb-card: hsl(44 60% 99%);
  --stb-text: hsl(30 10% 22%);
  --stb-heading: hsl(30 18% 16%);
  --stb-muted: hsl(30 8% 43%);
  --stb-pink: hsl(358 41% 75%);
  --stb-pink-dark: hsl(353 33% 68%);
  --stb-gold: hsl(33 42% 54%);
  --stb-border: hsl(33 20% 84%);
  --stb-shadow: 0 24px 60px -34px rgba(63, 56, 51, .42);
  --stb-radius: 1.5rem;
  --stb-content: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  overflow-x: clip;
  background: var(--stb-bg);
  color: var(--stb-text);
  font-family: "Nunito Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
body.admin-bar .stb-site-header { top: 32px; }
@media (max-width: 782px) { body.admin-bar .stb-site-header { top: 46px; } }

h1, h2, h3, h4, h5, h6,
.stb-serif,
.wp-block-heading {
  color: var(--stb-heading);
  font-family: "Cormorant Garamond", Georgia, serif;
  line-height: 1.08;
  text-wrap: balance;
}
a { color: inherit; }
img { display: block; max-width: 100%; height: auto; }
button, input, textarea, select { font: inherit; }

.screen-reader-text {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0);
  white-space: nowrap; border: 0;
}
.screen-reader-text:focus {
  z-index: 100000;
  top: 5px; left: 5px;
  width: auto; height: auto;
  padding: 15px 23px;
  clip: auto !important;
  background: #fff;
  color: #111;
}

/* Header */
.stb-site-header {
  position: sticky;
  z-index: 1000;
  top: 0;
  border-bottom: 1px solid color-mix(in srgb, var(--stb-border) 65%, transparent);
  background: color-mix(in srgb, var(--stb-bg) 88%, transparent);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
}
.stb-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: min(var(--stb-content), calc(100% - 40px));
  min-height: 70px;
  margin: 0 auto;
  gap: 24px;
}
.stb-brand {
  flex: 0 0 auto;
  color: var(--stb-heading);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(1.25rem, 2vw, 1.55rem);
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
  letter-spacing: -.02em;
}
.stb-main-nav { display: flex; align-items: center; gap: 24px; }
.stb-main-nav ul {
  display: flex;
  align-items: center;
  gap: 26px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.stb-main-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  color: color-mix(in srgb, var(--stb-text) 82%, transparent);
  font-size: .88rem;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;
  letter-spacing: .02em;
  transition: color .2s ease, background .2s ease, transform .2s ease;
}
.stb-main-nav a:hover,
.stb-main-nav .current-menu-item > a,
.stb-main-nav .current_page_item > a { color: var(--stb-gold); }
.stb-main-nav .menu-store > a,
.stb-nav-store {
  min-height: 40px;
  padding: 0 17px;
  border: 1px solid color-mix(in srgb, var(--stb-gold) 60%, transparent);
  border-radius: 999px;
  background: color-mix(in srgb, var(--stb-gold) 8%, transparent);
  color: var(--stb-heading) !important;
}
.stb-main-nav .menu-store > a:hover,
.stb-nav-store:hover { background: color-mix(in srgb, var(--stb-gold) 15%, transparent); transform: translateY(-1px); }
.stb-main-nav .menu-instagram > a {
  min-height: 40px;
  padding: 0 16px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--stb-pink) 18%, transparent);
  color: var(--stb-pink-dark) !important;
}
.stb-menu-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--stb-heading);
  cursor: pointer;
}
.stb-menu-toggle svg { width: 25px; height: 25px; }

/* Generic layout */
.site-main { min-height: 65vh; }
.entry-content { margin: 0; }
.entry-content > * { margin-block-start: 0; margin-block-end: 0; }
.stb-section {
  position: relative;
  margin: 0 !important;
  padding: clamp(4rem, 8vw, 6.4rem) 20px;
}
.stb-section-compact { padding-block: clamp(3.2rem, 6vw, 5rem); }
.stb-container {
  width: min(var(--stb-content), 100%);
  max-width: var(--stb-content) !important;
  margin-inline: auto !important;
}
.stb-container-narrow {
  width: min(780px, 100%);
  max-width: 780px !important;
  margin-inline: auto !important;
}
.stb-container-medium {
  width: min(980px, 100%);
  max-width: 980px !important;
  margin-inline: auto !important;
}
.stb-card-bg { background: var(--stb-card); }
.stb-pink-bg { background: color-mix(in srgb, var(--stb-pink) 13%, var(--stb-bg)); }
.stb-store-bg {
  overflow: hidden;
  background:
    radial-gradient(circle at 15% 15%, color-mix(in srgb, var(--stb-gold) 16%, transparent), transparent 36%),
    radial-gradient(circle at 85% 80%, color-mix(in srgb, var(--stb-pink) 23%, transparent), transparent 38%),
    var(--stb-card);
}
.stb-centered { text-align: center; }
.stb-centered > * { margin-inline: auto; }
.stb-max-text { max-width: 720px; }
.stb-eyebrow {
  margin: 0 0 1.25rem !important;
  color: var(--stb-gold);
  font-size: .82rem;
  font-weight: 700;
  line-height: 1.4;
  letter-spacing: .22em;
  text-transform: uppercase;
}
.stb-lead {
  max-width: 670px;
  color: var(--stb-muted);
  font-size: clamp(1.05rem, 2vw, 1.2rem);
  line-height: 1.72;
}
.stb-title-xl {
  margin: 0 !important;
  font-size: clamp(3.25rem, 7.2vw, 5.4rem) !important;
  font-weight: 700;
  letter-spacing: -.04em;
}
.stb-title-lg {
  margin: 0 !important;
  font-size: clamp(2.55rem, 5.8vw, 4.3rem) !important;
  font-weight: 700;
  letter-spacing: -.035em;
}
.stb-title-md {
  margin: 0 !important;
  font-size: clamp(2.1rem, 4.5vw, 3.15rem) !important;
  font-weight: 600;
}
.stb-title-sm {
  margin: 0 !important;
  font-size: clamp(1.75rem, 3vw, 2.25rem) !important;
  font-weight: 600;
}
.stb-ornament {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 1.4rem;
  color: var(--stb-gold);
}
.stb-ornament::before,
.stb-ornament::after { content: ""; width: 42px; height: 1px; background: color-mix(in srgb, var(--stb-gold) 45%, transparent); }
.stb-ornament span { font-size: .95rem; line-height: 1; }

/* Hero */
.stb-hero {
  overflow: hidden;
  padding-top: clamp(3.6rem, 7vw, 5.4rem);
  padding-bottom: clamp(4rem, 8vw, 6.6rem);
}
.stb-hero::before,
.stb-hero::after {
  position: absolute;
  z-index: -1;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  filter: blur(55px);
  content: "";
  pointer-events: none;
}
.stb-hero::before { top: -120px; right: -70px; background: color-mix(in srgb, var(--stb-pink) 25%, transparent); }
.stb-hero::after { bottom: -170px; left: -100px; background: color-mix(in srgb, var(--stb-gold) 14%, transparent); }
.stb-hero .wp-block-columns { align-items: center !important; gap: clamp(2.5rem, 6vw, 5rem); }
.stb-hero-copy > * + * { margin-top: 1.4rem; }
.stb-hero-copy .stb-eyebrow { margin-top: 0; }
.stb-hero .wp-block-image { margin: 0; }
.stb-portrait img,
.stb-ebook-hero img {
  width: min(100%, 500px);
  margin-inline: auto;
  border-radius: var(--stb-radius);
  box-shadow: 0 34px 70px -34px rgba(63, 56, 51, .48);
}
.stb-portrait { display: flex; justify-content: center; }
.stb-portrait img {
  width: min(100%, 500px);
  height: auto !important;
  aspect-ratio: auto;
  object-fit: contain;
}
.stb-ebook-hero img { aspect-ratio: 4 / 5; object-fit: cover; }

/* Buttons */
.stb-buttons { gap: 14px !important; margin-top: 2rem !important; }
.wp-block-button.stb-button-primary .wp-block-button__link,
.wp-block-button.stb-button-secondary .wp-block-button__link,
.wp-block-button.stb-button-store .wp-block-button__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 54px;
  padding: 14px 28px;
  border-radius: 999px;
  font-weight: 800;
  line-height: 1.2;
  text-decoration: none;
  transition: background .2s ease, color .2s ease, border-color .2s ease, transform .2s ease, box-shadow .2s ease;
}
.wp-block-button.stb-button-primary .wp-block-button__link {
  border: 1px solid var(--stb-pink);
  background: var(--stb-pink);
  color: #fff;
  box-shadow: 0 14px 30px -16px rgba(200, 143, 148, .85);
}
.wp-block-button.stb-button-primary .wp-block-button__link:hover {
  border-color: var(--stb-pink-dark);
  background: var(--stb-pink-dark);
  transform: translateY(-2px);
}
.wp-block-button.stb-button-secondary .wp-block-button__link {
  border: 1px solid color-mix(in srgb, var(--stb-gold) 62%, transparent);
  background: transparent;
  color: var(--stb-heading);
}
.wp-block-button.stb-button-secondary .wp-block-button__link:hover {
  background: color-mix(in srgb, var(--stb-gold) 11%, transparent);
  transform: translateY(-2px);
}
.wp-block-button.stb-button-store .wp-block-button__link {
  border: 1px solid var(--stb-gold);
  background: var(--stb-gold);
  color: #fff;
  box-shadow: 0 14px 30px -18px color-mix(in srgb, var(--stb-gold) 85%, transparent);
}
.wp-block-button.stb-button-store .wp-block-button__link:hover {
  background: color-mix(in srgb, var(--stb-gold) 85%, #6d4b28);
  transform: translateY(-2px);
}

/* Cards */
.stb-card-grid { gap: 22px !important; margin-top: 3rem !important; }
.stb-card,
.stb-benefit-card {
  height: 100%;
  padding: clamp(1.5rem, 3vw, 2rem);
  border: 1px solid color-mix(in srgb, var(--stb-border) 72%, transparent);
  border-radius: 1.25rem;
  background: var(--stb-bg);
  box-shadow: 0 15px 36px -30px rgba(63, 56, 51, .44);
}
.stb-card > * + *, .stb-benefit-card > * + * { margin-top: .9rem; }
.stb-icon-circle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  margin: 0;
  border-radius: 50%;
  background: color-mix(in srgb, var(--stb-pink) 20%, transparent);
  color: var(--stb-pink-dark);
  font-family: Georgia, serif;
  font-size: 1.35rem;
}
.stb-card h3, .stb-benefit-card h3 { margin: 1.1rem 0 .6rem !important; font-size: 1.75rem !important; }
.stb-card p, .stb-benefit-card p { margin: 0 !important; color: var(--stb-muted); }

/* Featured ebook */
.stb-feature-card {
  padding: clamp(1.6rem, 4vw, 3.4rem);
  border: 1px solid color-mix(in srgb, var(--stb-gold) 28%, transparent);
  border-radius: 2rem;
  background: var(--stb-card);
  box-shadow: var(--stb-shadow);
}
.stb-feature-card .wp-block-columns { align-items: center !important; gap: clamp(2.2rem, 5vw, 4.2rem); }
.stb-feature-image img {
  width: min(100%, 350px);
  margin-inline: auto;
  border-radius: 1.45rem;
  box-shadow: 0 28px 58px -30px rgba(63, 56, 51, .5);
}
.stb-price-row { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px; margin-top: 1.25rem; }
.stb-price {
  margin: 0 !important;
  color: var(--stb-heading);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(2.1rem, 4vw, 3rem);
  font-weight: 600;
  line-height: 1;
}
.stb-price-note { margin: 0 !important; color: var(--stb-muted); font-size: .9rem; }

/* Store */
.stb-store-card {
  overflow: hidden;
  padding: clamp(2rem, 5vw, 4rem);
  border: 1px solid color-mix(in srgb, var(--stb-gold) 30%, transparent);
  border-radius: 2rem;
  background: color-mix(in srgb, var(--stb-card) 86%, transparent);
  box-shadow: var(--stb-shadow);
}
.stb-store-card .wp-block-columns { align-items: center !important; gap: clamp(2rem, 6vw, 5rem); }
.stb-store-mark {
  display: grid;
  place-items: center;
  min-height: 330px;
  padding: 2rem;
  border-radius: 1.5rem;
  background:
    linear-gradient(145deg, rgba(255,255,255,.78), rgba(255,255,255,.3)),
    radial-gradient(circle at 25% 20%, color-mix(in srgb, var(--stb-pink) 40%, transparent), transparent 48%),
    radial-gradient(circle at 80% 80%, color-mix(in srgb, var(--stb-gold) 32%, transparent), transparent 50%);
  text-align: center;
}
.stb-store-mark strong {
  display: block;
  color: var(--stb-heading);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(2.4rem, 5vw, 4.2rem);
  font-weight: 600;
  line-height: .95;
}
.stb-store-mark span { display: block; margin-top: 1rem; color: var(--stb-gold); font-size: .85rem; font-weight: 800; letter-spacing: .22em; text-transform: uppercase; }

/* Ebooks archive card */
.stb-ebook-grid { margin-top: 3.2rem !important; }
.stb-ebook-card {
  overflow: hidden;
  max-width: 480px;
  margin-inline: auto;
  border: 1px solid color-mix(in srgb, var(--stb-border) 70%, transparent);
  border-radius: 2rem;
  background: var(--stb-card);
  box-shadow: var(--stb-shadow);
}
.stb-ebook-card-media { padding: 2.4rem; background: color-mix(in srgb, var(--stb-pink) 13%, transparent); }
.stb-ebook-card-media img { width: min(100%, 250px); margin-inline: auto; border-radius: 1.35rem; box-shadow: 0 25px 50px -30px rgba(63,56,51,.56); }
.stb-ebook-card-body { padding: 2rem; }
.stb-ebook-card-body > * + * { margin-top: 1rem; }

/* Ebook landing page */
.stb-breadcrumb {
  padding: .75rem 20px;
  border-bottom: 1px solid color-mix(in srgb, var(--stb-border) 50%, transparent);
  background: var(--stb-card);
  color: var(--stb-muted);
  font-size: .85rem;
}
.stb-breadcrumb p { width: min(var(--stb-content), 100%); margin: 0 auto !important; }
.stb-breadcrumb a { text-decoration: none; }
.stb-breadcrumb a:hover { color: var(--stb-heading); }
.stb-emotional-quote {
  max-width: 850px;
  margin: 1.7rem auto 0 !important;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(2rem, 5vw, 3.25rem);
  font-style: italic;
  font-weight: 500;
  line-height: 1.18;
}
.stb-problem-copy { max-width: 720px; margin-inline: auto; text-align: center; }
.stb-problem-copy p { font-size: 1.08rem; line-height: 1.9; }
.stb-prayer-pivot {
  margin: 3rem auto !important;
  color: var(--stb-gold);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(2.35rem, 5vw, 3.6rem);
  font-style: italic;
  line-height: 1;
}
.stb-check-list,
.stb-heart-list { padding: 0; list-style: none; }
.stb-check-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 34px; margin-top: 2.4rem !important; }
.stb-check-list li { position: relative; padding: 15px 0 15px 31px; border-bottom: 1px solid color-mix(in srgb, var(--stb-border) 60%, transparent); color: var(--stb-muted); }
.stb-check-list li::before { position: absolute; top: 15px; left: 3px; color: var(--stb-gold); content: "✓"; font-weight: 900; }
.stb-benefit-grid { margin-top: 2.5rem !important; }
.stb-heart-list { max-width: 760px; margin: 2.3rem auto 0 !important; }
.stb-heart-list li { position: relative; margin: .75rem 0; padding: 16px 20px 16px 50px; border-radius: .9rem; background: var(--stb-card); color: var(--stb-muted); }
.stb-heart-list li::before { position: absolute; top: 15px; left: 20px; color: var(--stb-pink-dark); content: "♡"; font-size: 1.25rem; font-weight: 700; }
.stb-preview-grid { margin-top: 2.5rem !important; }
.stb-preview-grid img { width: 100%; aspect-ratio: 3 / 2; border-radius: 1.25rem; object-fit: cover; box-shadow: 0 24px 50px -30px rgba(63,56,51,.48); }
.stb-author .wp-block-columns { align-items: center !important; gap: clamp(2.5rem, 6vw, 5rem); }
.stb-author img { width: min(100%, 350px); margin-inline: auto; border-radius: var(--stb-radius); box-shadow: 0 28px 55px -32px rgba(63,56,51,.48); }
.stb-faith-note { max-width: 820px; margin-inline: auto; padding: clamp(1.7rem, 4vw, 2.7rem); border: 1px solid color-mix(in srgb, var(--stb-gold) 34%, transparent); border-radius: 1.5rem; background: var(--stb-card); }
.stb-price-section .stb-price { font-size: clamp(4rem, 10vw, 6.6rem); }
.stb-security-note { color: var(--stb-muted); font-size: .87rem; }
.stb-faq-wrap { max-width: 820px; margin: 2.2rem auto 0 !important; }
details.stb-faq { border-bottom: 1px solid color-mix(in srgb, var(--stb-border) 72%, transparent); }
details.stb-faq summary {
  position: relative;
  padding: 1.4rem 2.25rem 1.4rem 0;
  color: var(--stb-heading);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(1.35rem, 3vw, 1.75rem);
  cursor: pointer;
  list-style: none;
}
details.stb-faq summary::-webkit-details-marker { display: none; }
details.stb-faq summary::after { position: absolute; top: 50%; right: .2rem; color: var(--stb-gold); content: "+"; font-family: sans-serif; font-size: 1.3rem; transform: translateY(-50%); }
details.stb-faq[open] summary::after { content: "−"; }
details.stb-faq > p { margin: 0 0 1.4rem !important; color: var(--stb-muted); }

/* Generic WordPress content */
.stb-standard-page { width: min(900px, calc(100% - 40px)); margin: 0 auto; padding: 4rem 0; }
.stb-standard-page .entry-title { font-size: clamp(2.5rem, 6vw, 4.4rem); }
.stb-standard-page .entry-content > * + * { margin-top: 1.2rem; }
.wp-block-separator { border: 0; border-top: 1px solid var(--stb-border); }
.wp-block-quote { border-left: 3px solid var(--stb-gold); padding-left: 1.5rem; }

/* Footer */
.stb-site-footer { border-top: 1px solid color-mix(in srgb, var(--stb-border) 65%, transparent); background: var(--stb-bg); }
.stb-footer-inner { width: min(980px, calc(100% - 40px)); margin: 0 auto; padding: 3.4rem 0; text-align: center; }
.stb-footer-brand { margin: 0; color: var(--stb-heading); font-family: "Cormorant Garamond", Georgia, serif; font-size: 1.55rem; font-weight: 600; }
.stb-footer-tagline { margin: .35rem 0 0; color: var(--stb-muted); font-size: .88rem; }
.stb-footer-nav ul { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px 24px; margin: 1.35rem 0 0; padding: 0; list-style: none; }
.stb-footer-nav a { color: var(--stb-muted); font-size: .86rem; text-decoration: none; }
.stb-footer-nav a:hover { color: var(--stb-heading); }
.stb-footer-social { display: inline-flex; margin-top: 1.15rem; color: var(--stb-gold); font-size: .88rem; font-weight: 700; text-decoration: none; }
.stb-copyright { margin: 1.4rem 0 0; color: color-mix(in srgb, var(--stb-muted) 72%, transparent); font-size: .73rem; }

/* Reveal */
.stb-reveal { opacity: 0; transform: translateY(16px); transition: opacity .7s ease, transform .7s ease; }
.stb-reveal.is-visible { opacity: 1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .stb-reveal { opacity: 1; transform: none; transition: none; }
}

/* Admin/editor parity */
.editor-styles-wrapper { background: var(--stb-bg); color: var(--stb-text); font-family: "Nunito Sans", sans-serif; }
.editor-styles-wrapper .wp-block { max-width: var(--stb-content); }
.editor-styles-wrapper .wp-block[data-align="full"] { max-width: none; }

@media (max-width: 900px) {
  .stb-menu-toggle { display: inline-flex; }
  .stb-main-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    display: none;
    padding: 16px 20px 22px;
    border-top: 1px solid var(--stb-border);
    background: var(--stb-bg);
    box-shadow: 0 20px 35px -28px rgba(63,56,51,.45);
  }
  .stb-main-nav.is-open { display: block; }
  .stb-main-nav ul { align-items: stretch; flex-direction: column; gap: 5px; }
  .stb-main-nav a { width: 100%; min-height: 46px; padding-inline: 10px; }
  .stb-main-nav .menu-store > a,
  .stb-main-nav .menu-instagram > a { justify-content: center; margin-top: 5px; }
  .stb-check-list { grid-template-columns: 1fr; }
}

@media (max-width: 781px) {
  .stb-section { padding-inline: 18px; }
  .stb-hero { text-align: center; }
  .stb-hero .stb-lead, .stb-hero .stb-buttons { margin-inline: auto !important; }
  .stb-hero .stb-buttons { justify-content: center; }
  .stb-feature-card, .stb-store-card { padding: 1.5rem; }
  .stb-store-mark { min-height: 240px; }
  .stb-card-grid > .wp-block-column + .wp-block-column { margin-top: 0; }
}

@media (max-width: 520px) {
  body { font-size: 16px; }
  .stb-header-inner { width: min(100% - 28px, var(--stb-content)); min-height: 64px; }
  .stb-section { padding-block: 3.7rem; }
  .stb-title-xl { font-size: 3.1rem !important; }
  .stb-title-lg { font-size: 2.75rem !important; }
  .stb-buttons { width: 100%; }
  .stb-buttons .wp-block-button { width: 100%; }
  .stb-buttons .wp-block-button__link { width: 100%; }
  .stb-portrait img, .stb-ebook-hero img { max-width: 330px; }
  .stb-emotional-quote { font-size: 2rem; }
  .stb-price-section .stb-price { font-size: 4rem; }
}


/* WordPress block editor: keep animated sections visible while editing.
   The public site still uses the entrance animations normally. */
.editor-styles-wrapper .stb-reveal,
.block-editor-writing-flow .stb-reveal {
  opacity: 1 !important;
  visibility: visible !important;
  transform: none !important;
}

/* Give the editor a faithful, usable canvas for full-width sections. */
.editor-styles-wrapper .stb-section {
  min-height: auto !important;
}
.editor-styles-wrapper .stb-portrait img {
  width: min(100%, 500px) !important;
  height: auto !important;
}


/* --------------------------------------------------------------------------
   Inicio renovado v1.5
   -------------------------------------------------------------------------- */
.stb-home-v15-hero {
  overflow: hidden;
  padding: 0 20px !important;
  background:
    radial-gradient(circle at 18% 22%, rgba(205, 161, 101, .09), transparent 34%),
    linear-gradient(90deg, var(--stb-bg) 0%, var(--stb-bg) 53%, #f4ece9 100%);
}
.stb-home-v15-hero::before,
.stb-home-v15-hero::after { display: none; }
.stb-home-v15-hero .stb-container {
  width: min(1320px, 100%);
  max-width: 1320px !important;
}
.stb-home-v15-hero-grid {
  min-height: 650px;
  align-items: stretch !important;
  gap: clamp(2rem, 4vw, 4.5rem) !important;
}
.stb-home-v15-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(3.7rem, 7vw, 6.2rem) 0;
}
.stb-home-v15-copy > * + * { margin-top: 1.35rem; }
.stb-home-v15-copy .stb-eyebrow { margin-top: 0 !important; }
.stb-home-v15-title {
  max-width: 720px;
  margin: 0 !important;
  font-size: clamp(4rem, 6.25vw, 6rem) !important;
  font-weight: 600;
  line-height: .94;
  letter-spacing: -.047em;
  text-wrap: balance;
}
.stb-home-v15-copy .stb-lead {
  position: relative;
  max-width: 650px;
  margin-top: 2rem !important;
  padding-top: 1.45rem;
}
.stb-home-v15-copy .stb-lead::before {
  position: absolute;
  top: 0;
  left: 0;
  width: 78px;
  height: 1px;
  background: var(--stb-gold);
  content: "";
}
.stb-home-v15-photo-column {
  position: relative;
  display: flex;
  align-items: stretch;
  min-width: 0;
}
.stb-home-v15-main-photo,
.stb-home-v15-main-photo figure {
  width: 100%;
  height: 100%;
  margin: 0 !important;
}
.stb-home-v15-main-photo img {
  width: 100% !important;
  max-width: none !important;
  height: 100% !important;
  min-height: 650px;
  border-radius: 0 0 2rem 2rem;
  object-fit: cover;
  object-position: 50% 48%;
  box-shadow: 0 34px 74px -42px rgba(44, 35, 30, .58);
}

.stb-purpose-section {
  padding-top: clamp(2.2rem, 5vw, 4rem) !important;
  background:
    radial-gradient(circle at 100% 100%, rgba(224, 176, 180, .12), transparent 35%),
    var(--stb-bg);
}
.stb-purpose-card {
  overflow: hidden;
  padding: clamp(1.3rem, 3vw, 2.4rem);
  border: 1px solid color-mix(in srgb, var(--stb-gold) 22%, transparent);
  border-radius: 2rem;
  background: rgba(255, 252, 248, .9);
  box-shadow: 0 28px 70px -46px rgba(63, 56, 51, .52);
}
.stb-purpose-card .wp-block-columns {
  align-items: stretch !important;
  gap: clamp(1.8rem, 4vw, 3.7rem) !important;
}
.stb-purpose-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(1rem, 3vw, 2.2rem);
}
.stb-purpose-copy > * + * { margin-top: 1.2rem; }
.stb-purpose-copy .stb-title-md { max-width: 390px; }
.stb-purpose-copy .stb-lead { font-size: 1.05rem; }
.stb-purpose-photo,
.stb-purpose-photo figure {
  width: 100%;
  height: 100%;
  margin: 0 !important;
}
.stb-purpose-photo img {
  width: 100% !important;
  max-width: none !important;
  height: clamp(360px, 34vw, 465px) !important;
  border-radius: 1.45rem;
  object-fit: cover;
  object-position: center;
}
.stb-purpose-benefits {
  margin-top: 1.4rem !important;
  padding: 1.25rem clamp(1rem, 3vw, 2rem);
  border-radius: 1.35rem;
  background: color-mix(in srgb, var(--stb-pink) 10%, #fff);
}
.stb-purpose-benefits .wp-block-columns {
  gap: 0 !important;
}
.stb-purpose-benefit {
  position: relative;
  padding: .35rem clamp(1rem, 3vw, 2rem);
  text-align: center;
}
.stb-purpose-benefit + .stb-purpose-benefit {
  border-left: 1px solid color-mix(in srgb, var(--stb-gold) 25%, transparent);
}
.stb-purpose-benefit .stb-feature-symbol {
  margin: 0 0 .35rem !important;
  color: var(--stb-gold);
  font-family: Georgia, serif;
  font-size: 1.35rem;
  line-height: 1;
}
.stb-purpose-benefit h3 {
  margin: 0 !important;
  font-size: 1.45rem !important;
  font-weight: 600;
}
.stb-purpose-benefit p:last-child {
  margin: .2rem 0 0 !important;
  color: var(--stb-muted);
  font-size: .82rem;
  line-height: 1.4;
}

/* Editor: render the redesigned blocks exactly as visible content. */
.editor-styles-wrapper .stb-home-v15-main-photo img {
  min-height: 560px !important;
  object-fit: cover !important;
}
.editor-styles-wrapper .stb-purpose-photo img {
  height: 420px !important;
  object-fit: cover !important;
}

@media (max-width: 1024px) {
  .stb-home-v15-hero-grid { min-height: 570px; gap: 2rem !important; }
  .stb-home-v15-title { font-size: clamp(3.45rem, 6.8vw, 4.8rem) !important; }
  .stb-home-v15-main-photo img { min-height: 570px; }
}

@media (max-width: 781px) {
  .stb-home-v15-hero { padding: 0 18px 3.8rem !important; text-align: left; }
  .stb-home-v15-hero-grid { min-height: 0; gap: 1rem !important; }
  .stb-home-v15-copy { padding: 3.7rem 0 1.2rem; }
  .stb-home-v15-copy .stb-buttons { justify-content: flex-start; margin-inline: 0 !important; }
  .stb-home-v15-copy .stb-lead { margin-inline: 0 !important; }
  .stb-home-v15-title { font-size: clamp(3.25rem, 14vw, 4.65rem) !important; }
  .stb-home-v15-main-photo img {
    min-height: 0;
    height: auto !important;
    aspect-ratio: 1 / 1;
    border-radius: 1.6rem;
  }
  .stb-purpose-card { padding: 1rem; }
  .stb-purpose-copy { padding: 1.25rem .75rem .5rem; }
  .stb-purpose-photo img { height: auto !important; aspect-ratio: 1 / 1; }
  .stb-purpose-benefits { padding: .55rem 1rem; }
  .stb-purpose-benefit { padding: 1rem .5rem; }
  .stb-purpose-benefit + .stb-purpose-benefit {
    border-top: 1px solid color-mix(in srgb, var(--stb-gold) 25%, transparent);
    border-left: 0;
  }
}

@media (max-width: 520px) {
  .stb-home-v15-copy .stb-buttons { width: 100%; }
  .stb-home-v15-title { font-size: clamp(3rem, 15vw, 3.75rem) !important; }
  .stb-home-v15-copy .stb-eyebrow { font-size: .72rem; letter-spacing: .18em; }
}

/* ========================================================================== 
   Inicio estable v1.6 — layout propio, sin depender de Columnas de Gutenberg
   ========================================================================== */
.stb-v16-hero,
.stb-v16-purpose,
.stb-v16-section,
.stb-v16-final {
  width: 100%;
}

.stb-v16-hero {
  padding: 0 28px;
  background:
    radial-gradient(circle at 13% 22%, rgba(193, 146, 89, .10), transparent 31%),
    linear-gradient(90deg, #faf7f1 0%, #faf7f1 47%, #f2e9e5 100%);
}
.stb-v16-hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 47%) minmax(0, 53%);
  width: min(1380px, 100%);
  min-height: 660px;
  margin: 0 auto;
}
.stb-v16-hero-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
  padding: 76px clamp(32px, 5vw, 78px) 76px 0;
}
.stb-v16-eyebrow {
  margin: 0 0 22px;
  color: #b98248;
  font-size: 13px;
  font-weight: 800;
  line-height: 1.4;
  letter-spacing: .22em;
  text-transform: uppercase;
}
.stb-v16-hero h1 {
  max-width: 680px;
  margin: 0;
  color: #302720;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(58px, 5.35vw, 84px);
  font-weight: 600;
  line-height: .98;
  letter-spacing: -.045em;
  text-wrap: balance;
}
.stb-v16-rule {
  width: 78px;
  height: 1px;
  margin: 28px 0 0;
  background: #b98248;
}
.stb-v16-lead {
  max-width: 630px;
  margin: 24px 0 0;
  color: #756b63;
  font-size: clamp(17px, 1.35vw, 20px);
  line-height: 1.72;
}
.stb-v16-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 30px;
}
.stb-v16-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 54px;
  padding: 14px 28px;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 800;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  transition: transform .2s ease, background .2s ease, border-color .2s ease;
}
.stb-v16-btn:hover { transform: translateY(-2px); }
.stb-v16-btn-primary {
  border: 1px solid #dda4a8;
  background: #dda4a8;
  color: #fff;
  box-shadow: 0 14px 30px -18px rgba(166, 96, 103, .65);
}
.stb-v16-btn-primary:hover { border-color: #c78e94; background: #c78e94; color: #fff; }
.stb-v16-btn-outline {
  border: 1px solid rgba(185, 130, 72, .62);
  background: rgba(255,255,255,.34);
  color: #342c26;
}
.stb-v16-btn-outline:hover { background: rgba(185, 130, 72, .10); }
.stb-v16-hero-media {
  min-width: 0;
  min-height: 660px;
  overflow: hidden;
  border-radius: 0 0 32px 32px;
  box-shadow: 0 36px 70px -45px rgba(43, 31, 24, .72);
}
.stb-v16-hero-media img {
  width: 100%;
  height: 100%;
  min-height: 660px;
  object-fit: cover;
  object-position: 51% 44%;
}

.stb-v16-purpose {
  padding: clamp(38px, 6vw, 76px) 28px;
  background:
    radial-gradient(circle at 100% 100%, rgba(224, 176, 180, .12), transparent 36%),
    #faf7f1;
}
.stb-v16-purpose-card {
  display: grid;
  grid-template-columns: minmax(280px, 35%) minmax(0, 65%);
  width: min(1180px, 100%);
  margin: 0 auto;
  padding: clamp(20px, 2.5vw, 34px);
  overflow: hidden;
  border: 1px solid rgba(185, 130, 72, .22);
  border-radius: 30px;
  background: rgba(255, 252, 248, .94);
  box-shadow: 0 30px 68px -48px rgba(60, 45, 35, .58);
}
.stb-v16-purpose-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(22px, 4vw, 50px);
}
.stb-v16-purpose h2,
.stb-v16-section h2,
.stb-v16-final h2 {
  margin: 0;
  color: #302720;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -.035em;
}
.stb-v16-purpose h2 { max-width: 390px; font-size: clamp(40px, 4vw, 58px); }
.stb-v16-purpose-copy > p:not(.stb-v16-eyebrow) {
  max-width: 430px;
  margin: 22px 0 0;
  color: #756b63;
  font-size: 17px;
  line-height: 1.65;
}
.stb-v16-purpose-copy .stb-v16-btn { align-self: flex-start; margin-top: 28px; }
.stb-v16-purpose-media {
  min-width: 0;
  height: 470px;
  overflow: hidden;
  border-radius: 24px;
}
.stb-v16-purpose-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}
.stb-v16-benefits {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 22px;
  padding: 18px 14px;
  border-radius: 20px;
  background: #fbefee;
}
.stb-v16-benefit {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  min-width: 0;
  padding: 7px 24px;
  text-align: left;
}
.stb-v16-benefit + .stb-v16-benefit { border-left: 1px solid rgba(185, 130, 72, .24); }
.stb-v16-benefit > span { color: #b98248; font-size: 28px; line-height: 1; }
.stb-v16-benefit h3 {
  margin: 0;
  color: #302720;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 23px;
  font-weight: 600;
  line-height: 1.05;
}
.stb-v16-benefit p { margin: 4px 0 0; color: #756b63; font-size: 13px; line-height: 1.35; }

.stb-v16-section { padding: clamp(68px, 8vw, 110px) 28px; }
.stb-v16-narrow { width: min(800px, 100%); margin: 0 auto; text-align: center; }
.stb-v16-symbol { margin: 0 0 14px; color: #b98248; font-size: 24px; }
.stb-v16-section h2 { font-size: clamp(43px, 5vw, 66px); }
.stb-v16-section-lead { max-width: 760px; margin: 22px auto 0; color: #756b63; font-size: 18px; line-height: 1.72; }
.stb-v16-mission { background: #fffdfa; }
.stb-v16-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
  width: min(1180px, 100%);
  margin: 48px auto 0;
}
.stb-v16-cards article {
  padding: 34px;
  border: 1px solid rgba(185,130,72,.18);
  border-radius: 24px;
  background: #faf7f1;
}
.stb-v16-cards article > span { color: #b98248; font-size: 27px; }
.stb-v16-cards h3 { margin: 18px 0 0; font-family: "Cormorant Garamond", Georgia, serif; font-size: 30px; line-height: 1.05; }
.stb-v16-cards p { margin: 14px 0 0; color: #756b63; }

.stb-v16-feature { background: #faf7f1; }
.stb-v16-feature-card {
  display: grid;
  grid-template-columns: minmax(300px, 42%) minmax(0, 58%);
  align-items: center;
  gap: clamp(40px, 7vw, 90px);
  width: min(1080px, 100%);
  margin: 0 auto;
}
.stb-v16-feature-media img {
  width: min(100%, 440px);
  margin: 0 auto;
  border-radius: 26px;
  box-shadow: 0 32px 66px -40px rgba(45, 31, 23, .65);
}
.stb-v16-feature-copy h2 { max-width: 560px; font-size: clamp(46px, 5vw, 70px); }
.stb-v16-feature-copy > p:not(.stb-v16-eyebrow):not(.stb-v16-price):not(.stb-v16-note) { max-width: 600px; margin: 22px 0 0; color: #756b63; font-size: 18px; }
.stb-v16-price { margin: 28px 0 0; color: #302720; font-family: "Cormorant Garamond", Georgia, serif; font-size: 48px; font-weight: 600; line-height: 1; }
.stb-v16-note { margin: 8px 0 0; color: #887d74; font-size: 14px; }
.stb-v16-feature-copy .stb-v16-btn { margin-top: 28px; }

.stb-v16-instagram { background: #fffdfa; text-align: center; }
.stb-v16-instagram .stb-v16-btn { margin-top: 28px; }
.stb-v16-final {
  padding: clamp(70px, 10vw, 130px) 28px;
  background: linear-gradient(135deg, #f5dfdd, #f7eee8 58%, #efe3d6);
  text-align: center;
}
.stb-v16-final > div { width: min(880px, 100%); margin: 0 auto; }
.stb-v16-final p { margin: 0 0 15px; color: #b98248; font-size: 24px; }
.stb-v16-final h2 { font-size: clamp(45px, 5vw, 68px); }
.stb-v16-final .stb-v16-btn { margin-top: 30px; }

@media (max-width: 1050px) {
  .stb-v16-hero-inner { grid-template-columns: minmax(0, 52%) minmax(0, 48%); min-height: 600px; }
  .stb-v16-hero-media, .stb-v16-hero-media img { min-height: 600px; }
  .stb-v16-hero h1 { font-size: clamp(52px, 6vw, 70px); }
  .stb-v16-purpose-card { grid-template-columns: minmax(250px, 40%) minmax(0, 60%); }
  .stb-v16-benefit { padding-inline: 14px; }
}

@media (max-width: 820px) {
  .stb-v16-hero { padding: 0 18px 54px; background: #faf7f1; }
  .stb-v16-hero-inner { display: flex; flex-direction: column; min-height: 0; }
  .stb-v16-hero-copy { order: 1; padding: 56px 0 38px; text-align: center; }
  .stb-v16-hero h1 { max-width: 680px; margin-inline: auto; font-size: clamp(50px, 10vw, 70px); }
  .stb-v16-rule { margin-inline: auto; }
  .stb-v16-lead { margin-inline: auto; }
  .stb-v16-actions { justify-content: center; }
  .stb-v16-hero-media { order: 2; min-height: 0; aspect-ratio: 1 / 1; border-radius: 26px; }
  .stb-v16-hero-media img { min-height: 0; aspect-ratio: 1 / 1; }
  .stb-v16-purpose { padding-inline: 18px; }
  .stb-v16-purpose-card { display: block; padding: 18px; }
  .stb-v16-purpose-copy { padding: 28px 20px 34px; text-align: center; }
  .stb-v16-purpose h2, .stb-v16-purpose-copy > p:not(.stb-v16-eyebrow) { margin-inline: auto; }
  .stb-v16-purpose-copy .stb-v16-btn { align-self: center; }
  .stb-v16-purpose-media { height: auto; aspect-ratio: 1.14 / 1; }
  .stb-v16-benefits { grid-template-columns: 1fr; }
  .stb-v16-benefit { justify-content: flex-start; max-width: 430px; width: 100%; margin: 0 auto; }
  .stb-v16-benefit + .stb-v16-benefit { border-top: 1px solid rgba(185,130,72,.22); border-left: 0; }
  .stb-v16-cards { grid-template-columns: 1fr; max-width: 680px; }
  .stb-v16-feature-card { grid-template-columns: 1fr; text-align: center; }
  .stb-v16-feature-copy h2, .stb-v16-feature-copy > p { margin-inline: auto !important; }
}

@media (max-width: 520px) {
  .stb-v16-hero-copy { padding-top: 42px; }
  .stb-v16-eyebrow { font-size: 11px; letter-spacing: .16em; }
  .stb-v16-hero h1 { font-size: 47px; }
  .stb-v16-actions { flex-direction: column; width: 100%; }
  .stb-v16-actions .stb-v16-btn { width: 100%; }
  .stb-v16-purpose h2 { font-size: 42px; }
  .stb-v16-section { padding-inline: 18px; }
  .stb-v16-section h2, .stb-v16-final h2 { font-size: 44px; }
  .stb-v16-cards article { padding: 28px; }
  .stb-v16-feature-copy h2 { font-size: 46px; }
  .stb-v16-purpose-media { aspect-ratio: 1 / 1; }
}


/* v1.7 — Imágenes de Ebooks: proporción estable y compatibilidad */
.page-slug-ebooks .stb-ebook-card-media figure,
.page-slug-oraciones-de-una-madre .stb-ebook-hero,
.page-slug-oraciones-de-una-madre .stb-preview-grid figure,
.page-slug-oraciones-de-una-madre .stb-author figure {
  margin: 0;
}
.stb-ebook-card-media img,
.stb-ebook-hero img,
.stb-preview-grid img,
.stb-author img {
  height: auto !important;
}
.stb-ebook-hero img {
  width: min(100%, 520px);
  aspect-ratio: auto;
  object-fit: contain;
}
.stb-ebook-card-media img {
  aspect-ratio: auto;
  object-fit: contain;
}
@media (max-width: 781px) {
  .stb-ebook-card-media { padding: 1.5rem; }
  .stb-ebook-hero img { width: min(100%, 390px); }
}
