/* Factory Mag Front — completely scoped to prevent altering theme typography/layout. */
.factory-mag{--fm-accent:#5b5ce2;--fm-background:#f6f7fb;--fm-text:#172033;--fm-radius:16px;--fm-gap:20px;--fm-container:1340px;box-sizing:border-box;width:100%;background:var(--fm-background);color:var(--fm-text);padding:clamp(24px,4vw,60px) 16px;line-height:1.45;font-family:system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif}
.factory-mag,.factory-mag *{box-sizing:border-box}
.factory-mag a{text-decoration:none;color:inherit}
.factory-mag a:hover{color:var(--fm-accent)}
.factory-mag .fm-magazine-inner{max-width:var(--fm-container);margin:0 auto}
.factory-mag .fm-layout-grid{display:grid;grid-template-columns:repeat(12,minmax(0,1fr));gap:clamp(22px,3vw,40px) var(--fm-gap);align-items:start}
.factory-mag .fm-section{grid-column:span var(--fm-span);min-width:0}
.factory-mag .fm-section__header{display:flex;justify-content:space-between;align-items:center;gap:16px;border-bottom:1px solid color-mix(in srgb,var(--fm-text) 16%,transparent);padding-bottom:14px;margin-bottom:20px}
.factory-mag .fm-section__title{font-size:clamp(20px,2vw,29px);font-weight:800;letter-spacing:-.035em;line-height:1.18;margin:0;color:var(--fm-text)}
.factory-mag .fm-section__title a{color:inherit;text-decoration:none;transition:color .18s ease}
.factory-mag .fm-section__title a:hover,.factory-mag .fm-section__title a:focus-visible{color:var(--fm-accent)}
.factory-mag .fm-section__title:before{content:"";display:inline-block;width:5px;height:20px;background:var(--fm-accent);border-radius:8px;margin-right:11px;vertical-align:-3px}
.factory-mag .fm-section__more{font-size:13px;font-weight:700;white-space:nowrap;color:var(--fm-accent)}
.factory-mag .fm-section__posts{display:grid;gap:var(--fm-gap);min-width:0}
.factory-mag .fm-section--grid .fm-section__posts{grid-template-columns:repeat(2,minmax(0,1fr))}
.factory-mag .fm-section--grid[style*="--fm-span:12"] .fm-section__posts{grid-template-columns:repeat(4,minmax(0,1fr))}
.factory-mag .fm-section--grid[style*="--fm-span:3"] .fm-section__posts,.factory-mag .fm-section--grid[style*="--fm-span:4"] .fm-section__posts{grid-template-columns:1fr}
.factory-mag .fm-section--hero .fm-section__posts{grid-template-columns:repeat(4,minmax(0,1fr))}
.factory-mag .fm-section--hero .fm-post:first-child{grid-column:span 2;grid-row:span 2}
.factory-mag .fm-section--list .fm-section__posts{grid-template-columns:1fr}
.factory-mag .fm-post{min-width:0;background:#fff;border-radius:var(--fm-radius);overflow:hidden;box-shadow:0 8px 28px rgb(18 26 45 / 5%);transition:box-shadow .18s ease}
.factory-mag .fm-post:hover{box-shadow:0 12px 32px rgb(18 26 45 / 9%)}
.factory-mag .fm-post__media{display:block;position:relative;aspect-ratio:16/10;overflow:hidden;background:color-mix(in srgb,var(--fm-accent) 13%,#dae1ec)}
.factory-mag .fm-post__image{display:block;width:100%;height:100%;object-fit:cover;transition:none}

.factory-mag .fm-post__media--empty{display:flex;align-items:center;justify-content:center;background:linear-gradient(135deg,color-mix(in srgb,var(--fm-accent) 20%,#edf2f8),#dfe6ee)}
.factory-mag .fm-post__placeholder{font-size:50px;opacity:.22;color:var(--fm-accent)}
.factory-mag .fm-post__body{padding:17px 18px 20px}
.factory-mag .fm-post__category{display:inline-block;color:var(--fm-accent);font-size:11px;font-weight:800;text-transform:uppercase;letter-spacing:.09em;margin-bottom:7px}
.factory-mag .fm-post__title{font-size:clamp(15px,1.4vw,19px);font-weight:800;line-height:1.34;letter-spacing:-.025em;margin:0 0 9px;overflow-wrap:anywhere;color:var(--fm-text)}
.factory-mag .fm-post__excerpt{font-size:13px;color:color-mix(in srgb,var(--fm-text) 70%,#fff);line-height:1.65;margin:0 0 11px}
.factory-mag .fm-post__date{display:block;font-size:12px;color:color-mix(in srgb,var(--fm-text) 55%,#fff);margin-top:9px}
.factory-mag .fm-section--hero .fm-post--featured .fm-post__media{aspect-ratio:16/10}
.factory-mag .fm-section--hero .fm-post--featured .fm-post__title{font-size:clamp(21px,2.2vw,31px);line-height:1.16}
.factory-mag .fm-section--hero .fm-post:not(.fm-post--featured) .fm-post__media{aspect-ratio:16/9}
.factory-mag .fm-section--hero .fm-post:not(.fm-post--featured) .fm-post__body{padding:12px 13px 14px}
.factory-mag .fm-section--hero .fm-post:not(.fm-post--featured) .fm-post__excerpt{display:none}
.factory-mag .fm-section--hero .fm-post:not(.fm-post--featured) .fm-post__title{font-size:14px}
.factory-mag .fm-section--list .fm-post{display:grid;grid-template-columns:minmax(90px,34%) minmax(0,1fr);min-height:110px}
.factory-mag .fm-section--list .fm-post__media{aspect-ratio:auto;height:100%;min-height:110px}
.factory-mag .fm-section--list .fm-post__body{padding:13px 15px}
.factory-mag .fm-section--list .fm-post__title{font-size:15px;margin-bottom:5px}
.factory-mag .fm-section--list .fm-post__category{font-size:10px;margin-bottom:5px}
.factory-mag .fm-section--list .fm-post__date{font-size:11px}
@media(max-width:1050px){.factory-mag .fm-section{grid-column:span 12}.factory-mag .fm-section--grid[style*="--fm-span:12"] .fm-section__posts{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:760px){.factory-mag .fm-section--hero .fm-section__posts{grid-template-columns:repeat(2,minmax(0,1fr))}.factory-mag .fm-section--hero .fm-post:first-child{grid-column:span 2;grid-row:auto}.factory-mag .fm-section--grid .fm-section__posts{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:520px){.factory-mag{padding:24px 12px}.factory-mag .fm-layout-grid{gap:30px}.factory-mag .fm-section--grid .fm-section__posts,.factory-mag .fm-section--grid[style*="--fm-span:12"] .fm-section__posts{grid-template-columns:1fr}.factory-mag .fm-section--hero .fm-section__posts{grid-template-columns:1fr}.factory-mag .fm-section--hero .fm-post:first-child{grid-column:auto}.factory-mag .fm-post__body{padding:14px 15px}.factory-mag .fm-section__title{font-size:22px}}
@media(prefers-reduced-motion:reduce){.factory-mag .fm-post,.factory-mag .fm-post__image{transition:none}}

/* Hero text-only alternative. Isolated from the classic four-column hero. */
.factory-mag .fm-section--hero .fm-section__posts.fm-hero-text-grid{
  display:grid;
  grid-template-columns:minmax(0,1.6fr) minmax(0,1fr);
  align-items:stretch;
  gap:clamp(16px,2vw,28px);
  width:100%;
}
.factory-mag .fm-hero-text-main,.factory-mag .fm-hero-text-rest{min-width:0}
.factory-mag .fm-hero-text-main>.fm-post{display:flex;flex-direction:column;height:100%;grid-column:auto;grid-row:auto}
.factory-mag .fm-hero-text-main>.fm-post .fm-post__media{aspect-ratio:16/9;width:100%}
.factory-mag .fm-hero-text-main>.fm-post .fm-post__body{flex:1;padding:20px 22px 23px}
.factory-mag .fm-hero-text-rest{display:flex;flex-direction:column;gap:clamp(12px,1.3vw,20px);min-width:0}
.factory-mag .fm-hero-text-rest>.fm-post{display:flex;flex:1 1 0;align-items:center;min-height:96px;grid-column:auto;grid-row:auto}
.factory-mag .fm-hero-text-rest>.fm-post .fm-post__body{width:100%;padding:18px 22px}
.factory-mag .fm-hero-text-rest>.fm-post .fm-post__category{margin-bottom:9px}
.factory-mag .fm-hero-text-rest>.fm-post .fm-post__title{font-size:clamp(15px,1.2vw,19px);line-height:1.4;margin:0 0 9px}
.factory-mag .fm-hero-text-rest>.fm-post .fm-post__date{margin-top:10px}
.factory-mag .fm-hero-text-rest>.fm-post .fm-post__excerpt{display:none}
@media(max-width:760px){
 .factory-mag .fm-section--hero .fm-section__posts.fm-hero-text-grid{grid-template-columns:minmax(0,1fr)}
 .factory-mag .fm-hero-text-rest>.fm-post{flex:auto;min-height:96px}
}

/* v3.1: classic explicitly shows secondary thumbnails; text variation never outputs them. */
.factory-mag .fm-section--hero.fm-section--hero .fm-section__posts:not(.fm-hero-text-grid) .fm-post:not(.fm-post--featured) .fm-post__media{display:block!important}
.factory-mag .fm-section--hero_text .fm-hero-text-rest .fm-post__media{display:none!important}

/* v3.3 — Per-block excerpt preferences override old presentation defaults. */
.factory-mag .fm-section--hero.fm-excerpts--all .fm-post:not(.fm-post--featured) .fm-post__excerpt{display:block}
.factory-mag .fm-section--hero_text.fm-excerpts--all .fm-hero-text-rest>.fm-post .fm-post__excerpt{display:block}

/* v3.5: per-row sticky blocks; the row bounds the sticky travel distance. */
.factory-mag .fm-layout-grid{display:block}
.factory-mag .fm-layout-row{grid-column:1 / -1;width:100%;display:grid;grid-template-columns:repeat(12,minmax(0,1fr));column-gap:var(--fm-gap);align-items:start;margin-bottom:clamp(22px,3vw,40px);min-width:0}
.factory-mag .fm-layout-row:last-child{margin-bottom:0}
.factory-mag .fm-layout-row>.fm-section--sticky{position:sticky;top:90px;z-index:2;align-self:start}
@media(max-width:1050px){.factory-mag .fm-layout-row{row-gap:clamp(22px,3vw,40px)}.factory-mag .fm-layout-row>.fm-section--sticky{position:static;top:auto}}

/* v3.6: row wrapper must span the entire 12-column grid even if legacy CSS is cached. */
.factory-mag .fm-layout-grid > .fm-layout-row{grid-column:1 / -1;width:100%;min-width:0}

/* v3.8: JavaScript sets inline fixed positioning; placeholder preserves original grid column. */
.factory-mag .fm-layout-row>.fm-sticky-placeholder{min-width:0;pointer-events:none}

/* v3.9: section stays in-grid; scrolling translation is handled by sticky.js. */
.factory-mag .fm-layout-row>.fm-section--sticky{position:relative!important;top:auto!important;align-self:start}
@media(max-width:1050px){.factory-mag .fm-layout-row>.fm-section--sticky{transform:none!important}}


/* v4.4 — Bento editorial system. Scoped: no change to Voyage/editorial/minimal. */
.factory-mag .fm-section--bento .fm-section__posts.fm-bento-grid{
  display:grid!important;grid-template-columns:repeat(12,minmax(0,1fr))!important;
  grid-auto-rows:minmax(185px,auto);grid-auto-flow:row dense;
  gap:clamp(12px,1.45vw,22px);align-items:stretch;
}
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post{
  position:relative;display:flex;flex-direction:column;min-width:0;
  grid-column:span 3;grid-row:span 1;height:100%;min-height:190px;
  isolation:isolate;overflow:hidden;background:#fff;
  border:0;border-radius:clamp(14px,1.5vw,24px);
  box-shadow:0 14px 40px rgb(24 28 45 / 8%);
}
/* Hero: immersive image with an accessible gradient and overlaid text. */
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post:first-child{
  grid-column:span 6;grid-row:span 2;min-height:440px;background:#172033;
}
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post:first-child .fm-post__media{
  position:absolute;inset:0;display:block;width:100%;height:100%;aspect-ratio:auto!important;
}
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post:first-child .fm-post__media::after{
  content:"";position:absolute;inset:0;pointer-events:none;
  background:linear-gradient(to bottom,rgba(8,13,24,.04) 20%,rgba(8,13,24,.25) 48%,rgba(8,13,24,.90) 100%);
}
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post:first-child .fm-post__body{
  position:relative;z-index:1;margin-top:auto;padding:clamp(22px,3vw,40px);
  background:none;display:block;color:#fff;
}
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post:first-child .fm-post__title{
  font-size:clamp(25px,2.9vw,45px);line-height:1.12;letter-spacing:-.035em;
  margin-bottom:14px;color:#fff;
}
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post:first-child .fm-post__title a,
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post:first-child .fm-post__category,
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post:first-child .fm-post__excerpt,
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post:first-child .fm-post__date{color:#fff}
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post:first-child .fm-post__category{opacity:.85}
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post:first-child .fm-post__date{opacity:.7}
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post:first-child .fm-post__excerpt{opacity:.88;max-width:52ch}
/* Secondary editorial cards: tactile mix of photo and typographic panels. */
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post:not(:first-child) .fm-post__media{
  aspect-ratio:16/9;min-height:105px;flex:0 0 auto;
}
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post:not(:first-child) .fm-post__body{
  flex:1;display:flex;flex-direction:column;align-items:flex-start;
  padding:clamp(14px,1.4vw,22px);
}
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post:not(:first-child) .fm-post__title{
  font-size:clamp(15px,1.25vw,19px);line-height:1.27;margin-bottom:8px;
}
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post:not(:first-child) .fm-post__date{margin-top:auto;padding-top:7px}
/* Image-free typographic tiles make the overall mosaic unlike the Voyage hero. */
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post:nth-child(3),
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post:nth-child(4){
  justify-content:center;background:color-mix(in srgb,var(--fm-accent) 11%,#fff);
}
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post:nth-child(4){background:color-mix(in srgb,var(--fm-text) 8%,#fff)}
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post:nth-child(3) .fm-post__media,
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post:nth-child(4) .fm-post__media{display:none}
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post:nth-child(3) .fm-post__body,
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post:nth-child(4) .fm-post__body{justify-content:center;flex:1}
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post:nth-child(3) .fm-post__title,
.factory-mag .fm-section--bento .fm-bento-grid>.fm-post:nth-child(4) .fm-post__title{
  font-size:clamp(17px,1.65vw,24px);line-height:1.22;
}
/* Count-sensitive composition: no accidental orphan on the following row. */
.factory-mag .fm-section--bento .fm-bento-count-1>.fm-post:first-child{grid-column:1/-1;min-height:420px;grid-row:span 2}
.factory-mag .fm-section--bento .fm-bento-count-2>.fm-post:first-child{grid-column:span 8;grid-row:span 2}
.factory-mag .fm-section--bento .fm-bento-count-2>.fm-post:nth-child(2){grid-column:span 4;grid-row:span 2}
.factory-mag .fm-section--bento .fm-bento-count-3>.fm-post:first-child{grid-column:span 8;grid-row:span 2}
.factory-mag .fm-section--bento .fm-bento-count-3>.fm-post:nth-child(n+2){grid-column:span 4}
.factory-mag .fm-section--bento .fm-bento-count-4>.fm-post:first-child{grid-column:span 6;grid-row:span 2}
.factory-mag .fm-section--bento .fm-bento-count-4>.fm-post:nth-child(2){grid-column:span 6}
.factory-mag .fm-section--bento .fm-bento-count-4>.fm-post:nth-child(n+3){grid-column:span 3}
.factory-mag .fm-section--bento .fm-bento-count-5>.fm-post:nth-child(n+2){grid-column:span 3}
/* On six posts, the sixth is a deliberate wide horizontal feature. */
.factory-mag .fm-section--bento .fm-bento-count-6>.fm-post:nth-child(6){
  grid-column:1/-1;grid-row:auto;display:grid;grid-template-columns:minmax(0,4fr) minmax(0,8fr);
  min-height:210px;
}
.factory-mag .fm-section--bento .fm-bento-count-6>.fm-post:nth-child(6) .fm-post__media{
  height:100%;min-height:210px;aspect-ratio:auto;
}
.factory-mag .fm-section--bento .fm-bento-count-6>.fm-post:nth-child(6) .fm-post__body{justify-content:center}
.factory-mag .fm-section--bento .fm-bento-count-6>.fm-post:nth-child(6) .fm-post__title{font-size:clamp(19px,2vw,29px)}
/* Narrow page-grid sections use two equal columns, never 3px-wide fragments. */
.factory-mag .fm-section--bento[style*="--fm-span:3"] .fm-bento-grid,
.factory-mag .fm-section--bento[style*="--fm-span:4"] .fm-bento-grid,
.factory-mag .fm-section--bento[style*="--fm-span:6"] .fm-bento-grid{
  grid-template-columns:repeat(2,minmax(0,1fr))!important;grid-auto-rows:auto;
}
.factory-mag .fm-section--bento[style*="--fm-span:3"] .fm-bento-grid>.fm-post,
.factory-mag .fm-section--bento[style*="--fm-span:4"] .fm-bento-grid>.fm-post,
.factory-mag .fm-section--bento[style*="--fm-span:6"] .fm-bento-grid>.fm-post{grid-column:span 2!important;grid-row:auto!important;min-height:170px}
.factory-mag .fm-section--bento[style*="--fm-span:3"] .fm-bento-grid>.fm-post:first-child,
.factory-mag .fm-section--bento[style*="--fm-span:4"] .fm-bento-grid>.fm-post:first-child,
.factory-mag .fm-section--bento[style*="--fm-span:6"] .fm-bento-grid>.fm-post:first-child{min-height:330px}
/* Entire Bento preset has distinct section rhythm; other layouts unaffected. */
.factory-mag.fm-layout-bento .fm-section__header{padding-bottom:14px;margin-bottom:20px;border-bottom:1px solid color-mix(in srgb,var(--fm-text) 13%,transparent)}
.factory-mag.fm-layout-bento .fm-section__title{font-size:clamp(24px,2vw,33px);letter-spacing:-.025em}
.factory-mag.fm-layout-bento .fm-section--grid .fm-post{border-radius:clamp(14px,1.5vw,24px)}
.factory-mag.fm-layout-bento .fm-section--list .fm-post{border-radius:16px;box-shadow:0 9px 24px rgb(24 28 45 / 5%)}
@media(max-width:1050px){
 .factory-mag .fm-section--bento .fm-section__posts.fm-bento-grid{grid-template-columns:repeat(6,minmax(0,1fr))!important;grid-auto-rows:auto}
 .factory-mag .fm-section--bento .fm-bento-grid>.fm-post,
 .factory-mag .fm-section--bento .fm-bento-grid>.fm-post:nth-child(n){grid-column:span 3;grid-row:auto;min-height:220px}
 .factory-mag .fm-section--bento .fm-bento-grid>.fm-post:first-child{grid-column:span 6;min-height:440px}
 .factory-mag .fm-section--bento .fm-bento-count-6>.fm-post:nth-child(6){display:flex;grid-column:span 3;min-height:220px}
 .factory-mag .fm-section--bento .fm-bento-count-6>.fm-post:nth-child(6) .fm-post__media{height:auto;min-height:0;aspect-ratio:16/9}
}
@media(max-width:650px){
 .factory-mag .fm-section--bento .fm-section__posts.fm-bento-grid{grid-template-columns:minmax(0,1fr)!important;grid-auto-rows:auto}
 .factory-mag .fm-section--bento .fm-bento-grid>.fm-post,
 .factory-mag .fm-section--bento .fm-bento-grid>.fm-post:nth-child(n){grid-column:1/-1!important;grid-row:auto!important;min-height:180px}
 .factory-mag .fm-section--bento .fm-bento-grid>.fm-post:first-child{min-height:420px}
 .factory-mag .fm-section--bento .fm-bento-grid>.fm-post:nth-child(3),
 .factory-mag .fm-section--bento .fm-bento-grid>.fm-post:nth-child(4){min-height:180px}
}

/* v4.23 — Decorative background bands for selected sections.
   Full-width blocks receive a page-spanning band; narrower blocks stay
   within their grid cell to avoid covering adjacent sections.
   Only the background layer rotates, never article content. */
.factory-mag .fm-layout-row > .fm-section--custom-bg {
  position: relative;
  isolation: isolate;
  overflow: visible;
  padding: clamp(24px, 3vw, 42px) clamp(14px, 2vw, 28px);
  background: transparent;
}
.factory-mag .fm-layout-row > .fm-section--custom-bg::before {
  content: "";
  position: absolute;
  inset: -14px -8px;
  z-index: -1;
  pointer-events: none;
  background-color: var(--fm-background);
  transform: rotate(var(--fm-bg-rotation, 0deg));
  transform-origin: center center;
}
/* A full-width row can carry a broader editorial colour band. */
.factory-mag .fm-layout-row > .fm-section--custom-bg[style*="--fm-span:12"]::before {
  left: 50%;
  right: auto;
  width: 116vw;
  max-width: none;
  transform: translateX(-50%) rotate(var(--fm-bg-rotation, 0deg));
}
.factory-mag .fm-layout-row > .fm-section--custom-bg > * {
  position: relative;
  z-index: 1;
}
@media (max-width: 760px) {
  .factory-mag .fm-layout-row > .fm-section--custom-bg { padding: 18px 12px; }
  .factory-mag .fm-layout-row > .fm-section--custom-bg[style*="--fm-span:12"]::before {
    width: 100vw;
    transform: translateX(-50%);
  }
}

/* v4.24 — Full-bleed decorative background: viewport width is independent
   from the configured magazine content width (--fm-container).
   The section remains in the 12-column grid; only its pseudo-element bleeds.
   The extra width on angled bands prevents white gaps at the viewport edges. */
.factory-mag .fm-layout-row > .fm-section--custom-bg[style*="--fm-span:12"]::before {
  left: 50%;
  right: auto;
  width: 116vw;
  max-width: none;
  transform: translateX(-50%) rotate(var(--fm-bg-rotation, 0deg));
}
@media (max-width: 760px) {
  .factory-mag .fm-layout-row > .fm-section--custom-bg[style*="--fm-span:12"]::before {
    width: 100vw;
    transform: translateX(-50%);
  }
}

/* v4.26 — Reserve enough space for both slanted edges at all viewport widths.
   Instead of rotating a very wide rectangle (which covers previous posts),
   the rotation angle defines the slope of a clipped quadrilateral.
   The padding reserves real space for both slanted edges. */
.factory-mag .fm-layout-row > .fm-section--custom-bg[style*="--fm-span:12"] {
  padding-top: calc(var(--fm-bg-safe, 24px) + var(--fm-bg-safe, 24px) + 25px) !important;
  padding-bottom: calc(var(--fm-bg-safe, 24px) + var(--fm-bg-safe, 24px) + 25px) !important;
  padding-left: 0;
  padding-right: 0;
  overflow: visible;
  isolation: isolate;
}
.factory-mag .fm-layout-row > .fm-section--custom-bg[style*="--fm-span:12"]::before {
  content: "";
  position: absolute;
  left: 50%;
  right: auto;
  top: 0;
  bottom: 0;
  width: 100vw;
  max-width: none;
  height: 100%;
  background: var(--fm-background);
  pointer-events: none;
  z-index: -1;
  transform: translateX(-50%) !important;
  transform-origin: center;
  clip-path: polygon(
    0 calc(var(--fm-bg-safe, 24px) - var(--fm-bg-rise, 0px)),
    100% calc(var(--fm-bg-safe, 24px) + var(--fm-bg-rise, 0px)),
    100% calc(100% - var(--fm-bg-safe, 24px) + var(--fm-bg-rise, 0px)),
    0 calc(100% - var(--fm-bg-safe, 24px) - var(--fm-bg-rise, 0px))
  );
}
@media (max-width: 760px) {
  .factory-mag .fm-layout-row > .fm-section--custom-bg[style*="--fm-span:12"] {
    padding-top: 32px !important;
    padding-bottom: 32px !important;
  }
  .factory-mag .fm-layout-row > .fm-section--custom-bg[style*="--fm-span:12"]::before {
    clip-path: none;
    transform: translateX(-50%) !important;
  }
}

/* Factory Mag 4.27 — reusable editorial content blocks */
.factory-mag .fm-section--custom_hero,.factory-mag .fm-section--text_image,.factory-mag .fm-section--custom_text,.factory-mag .fm-section--category_tiles{min-width:0}
.factory-mag .fm-content-module{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));align-items:stretch;min-height:300px;background:#fff;border-radius:var(--fm-radius);overflow:hidden;isolation:isolate}
.factory-mag .fm-content-module--left .fm-content-module__visual{order:0}
.factory-mag .fm-content-module--right .fm-content-module__visual{order:2}
.factory-mag .fm-content-module--top{display:flex;flex-direction:column}
.factory-mag .fm-content-module--top .fm-content-module__visual{height:clamp(220px,32vw,430px)}
.factory-mag .fm-content-module--top .fm-content-module__body{flex:1}
.factory-mag .fm-content-module__visual{position:relative;min-height:260px;overflow:hidden}
.factory-mag .fm-content-module__image{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;transform:none!important;transition:none!important}
.factory-mag .fm-content-module__body{padding:clamp(24px,4vw,64px);display:flex;flex-direction:column;align-items:flex-start;justify-content:center;gap:15px;min-width:0}
.factory-mag .fm-content-module__title{font-size:clamp(26px,3vw,46px);font-weight:800;line-height:1.13;letter-spacing:-.025em;color:var(--fm-text);margin:0}
.factory-mag .fm-content-module__copy{font-size:16px;line-height:1.75;color:var(--fm-text);max-width:65ch;overflow-wrap:anywhere}
.factory-mag .fm-content-module__copy p{margin:0 0 12px}.factory-mag .fm-content-module__copy p:last-child{margin-bottom:0}
.factory-mag .fm-content-module__button{display:inline-flex;align-items:center;gap:14px;background:var(--fm-accent);color:#fff!important;padding:12px 22px;border-radius:6px;text-decoration:none!important;font-weight:700;margin-top:8px}
.factory-mag .fm-content-module--custom_text{display:block;min-height:auto}.factory-mag .fm-content-module--custom_text .fm-content-module__body{align-items:initial}
.factory-mag .fm-content-module--background{position:relative;display:flex;min-height:400px;color:white}
.factory-mag .fm-content-module--background .fm-content-module__visual{position:absolute;inset:0;z-index:-2;min-height:0}
.factory-mag .fm-content-module--background:before{content:"";position:absolute;inset:0;background:rgba(0,0,0,.52);z-index:-1}
.factory-mag .fm-content-module--background .fm-content-module__body{width:100%;z-index:1}
.factory-mag .fm-content-module--background .fm-content-module__title,.factory-mag .fm-content-module--background .fm-content-module__copy{color:#fff}
.factory-mag .fm-content-module--custom_hero{min-height:380px}
.factory-mag .fm-content-category-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,215px),1fr));gap:var(--fm-gap)}
.factory-mag .fm-content-category{position:relative;display:flex;align-items:flex-end;min-height:220px;border-radius:var(--fm-radius);overflow:hidden;background:linear-gradient(125deg,var(--fm-accent),#25334e);text-decoration:none!important;color:white!important;isolation:isolate}
.factory-mag .fm-content-category:before{content:"";position:absolute;inset:0;background:linear-gradient(transparent,rgba(0,0,0,.68));z-index:0}
.factory-mag .fm-content-category__img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;z-index:-1;transform:none!important}
.factory-mag .fm-content-category__body{display:grid;gap:5px;padding:22px;position:relative;z-index:1}
.factory-mag .fm-content-category__body strong{font-size:20px;color:#fff}.factory-mag .fm-content-category__body small{font-size:13px;color:#fff}
@media(max-width:760px){.factory-mag .fm-content-module{grid-template-columns:1fr}.factory-mag .fm-content-module .fm-content-module__visual{order:0;min-height:230px}.factory-mag .fm-content-module .fm-content-module__body{order:1;padding:25px}.factory-mag .fm-content-module--background .fm-content-module__visual{position:absolute;inset:0}.factory-mag .fm-content-module--background .fm-content-module__body{position:relative;z-index:1}}

.factory-mag .fm-content-module--no-image{display:block;min-height:220px}.factory-mag .fm-content-module--no-image .fm-content-module__body{min-height:220px}.factory-mag .fm-content-module--no-image.fm-content-module--background{background:var(--fm-accent)}


/* v4.36 — Le texte libre utilise toute la largeur intérieure de son bloc.
   Le plafond de 65ch reste valable pour les autres composants. */
.factory-mag .fm-content-module.fm-content-module--custom_text .fm-content-module__copy {
  width:100%;max-width:none;min-width:0;
}
.factory-mag .fm-content-module.fm-content-module--custom_text .fm-content-module__copy > * {
  max-width:none;
}
/* Alignement du titre uniquement, sans déplacer le paragraphe ni le bouton. */
.factory-mag .fm-content-module.fm-content-module--title-left .fm-content-module__title,
.factory-mag .fm-content-module.fm-content-module--title-center .fm-content-module__title,
.factory-mag .fm-content-module.fm-content-module--title-right .fm-content-module__title {
  width:100%;max-width:100%;
}
.factory-mag .fm-content-module.fm-content-module--title-left .fm-content-module__title {text-align:left!important}
.factory-mag .fm-content-module.fm-content-module--title-center .fm-content-module__title {text-align:center!important}
.factory-mag .fm-content-module.fm-content-module--title-right .fm-content-module__title {text-align:right!important}

/* v4.39 — Les boutons conservent la largeur du libellé et s'alignent
   indépendamment du titre et des paragraphes. Contourne les styles de thème
   qui étirent les liens sur toute la largeur du parent flex. */
.factory-mag .fm-content-module .fm-content-module__button {
  display:inline-flex!important;
  box-sizing:border-box;
  width:max-content!important;
  max-width:100%;
  flex:0 0 auto;
  align-self:center;
  justify-content:center;
  text-align:center;
  white-space:normal;
}
.factory-mag .fm-content-module.fm-content-module--button-left .fm-content-module__button {align-self:flex-start!important}
.factory-mag .fm-content-module.fm-content-module--button-center .fm-content-module__button {align-self:center!important}
.factory-mag .fm-content-module.fm-content-module--button-right .fm-content-module__button {align-self:flex-end!important}

/* v4.41 — Liste sans images : la zone de texte utilise toute la carte. */
.factory-mag .fm-section--list_text .fm-section__posts{grid-template-columns:minmax(0,1fr)}
.factory-mag .fm-section--list_text .fm-post{display:block;min-height:0;grid-template-columns:none}
.factory-mag .fm-section--list_text .fm-post__media{display:none!important}
.factory-mag .fm-section--list_text .fm-post__body{width:100%;min-width:0;padding:15px 18px}
/* Partir Voyager possède ses propres cartes : ne réserver aucune colonne aux images. */
.factory-mag.fm-layout-partir .fm-section--list_text .fm-pv-feed>.fm-pv-story--text{display:block;grid-template-columns:none;min-width:0}
.factory-mag.fm-layout-partir .fm-section--list_text .fm-pv-feed>.fm-pv-story--text .fm-pv-story__content{width:100%;min-width:0}


/* v4.43 — Liste sans images : aucune colonne fantôme pour les vignettes.
   Les styles "Liste" historiques / du thème ne doivent pas limiter le texte
   à la largeur de la colonne de droite (environ 66 %). */
.factory-mag .fm-section.fm-section--list_text .fm-section__posts {
  display: grid;
  grid-template-columns: minmax(0, 1fr) !important;
  width: 100%;
  min-width: 0;
}
.factory-mag .fm-section.fm-section--list_text .fm-post.fm-post--text-only {
  display: block !important;
  grid-template-columns: minmax(0, 1fr) !important;
  width: 100%;
  min-width: 0;
}
.factory-mag .fm-section.fm-section--list_text .fm-post.fm-post--text-only .fm-post__media {
  display: none !important;
}
.factory-mag .fm-section.fm-section--list_text .fm-post.fm-post--text-only .fm-post__body {
  display: block !important;
  width: 100% !important;
  max-width: none !important;
  min-width: 0;
  padding: 18px 20px;
}
.factory-mag .fm-section.fm-section--list_text .fm-post.fm-post--text-only .fm-post__title,
.factory-mag .fm-section.fm-section--list_text .fm-post.fm-post--text-only .fm-post__excerpt {
  width: 100% !important;
  max-width: none !important;
}
/* Partir Voyager : préserver sa grille éditoriale, sans réserver
   de colonne d'image dans les cartes textuelles. */
.factory-mag.fm-layout-partir .fm-section--list_text .fm-pv-feed > .fm-pv-story--text {
  display: block !important;
  grid-template-columns: minmax(0, 1fr) !important;
  width: 100%;
}
.factory-mag.fm-layout-partir .fm-section--list_text .fm-pv-feed > .fm-pv-story--text .fm-pv-story__content {
  width: 100% !important;
  max-width: none !important;
}

/* v4.47: article titles truncated visually, without altering their actual text. */
.factory-mag .fm-post__title,.factory-mag .fm-bento-tile__title,.factory-mag .fm-pv-story__title{display:-webkit-box!important;-webkit-box-orient:vertical;-webkit-line-clamp:2;line-clamp:2;overflow:hidden!important;overflow-wrap:anywhere}
.factory-mag .fm-section--hero .fm-post--featured .fm-post__title,.factory-mag .fm-hero-text-main .fm-post__title,.factory-mag .fm-section--bento .fm-bento-tile--lead .fm-bento-tile__title,.factory-mag.fm-layout-partir .fm-pv-opening>.fm-pv-story:nth-child(-n+2) .fm-pv-story__title,.factory-mag.fm-layout-partir .fm-pv-topic>.fm-pv-story:first-child .fm-pv-story__title{-webkit-line-clamp:3;line-clamp:3}


/* v4.54 — CES 2021: single large featured cover over three compact editorial cards. */
.factory-mag .fm-section--ces_feature .fm-section__posts.fm-ces-feature{display:block!important;width:100%;}
.factory-mag .fm-ces-feature__lead{margin-bottom:30px;}
.factory-mag .fm-ces-feature__lead>.fm-post{position:relative;display:block!important;isolation:isolate;overflow:hidden;border:0;border-radius:0;box-shadow:none;min-height:0;height:clamp(300px,35vw,475px);}
.factory-mag .fm-ces-feature__lead .fm-post__media{position:absolute;inset:0;width:100%;height:100%;aspect-ratio:auto!important;border-radius:0;z-index:-2;overflow:hidden;}
.factory-mag .fm-ces-feature__lead .fm-post__media img{display:block;width:100%;height:100%;object-fit:cover;}
.factory-mag .fm-ces-feature__lead>.fm-post:after{content:"";position:absolute;inset:0;z-index:-1;pointer-events:none;background:linear-gradient(to top,rgba(0,0,0,.73),rgba(0,0,0,.02) 62%);}
.factory-mag .fm-ces-feature__lead .fm-post__body{position:absolute;bottom:0;left:0;right:0;padding:26px!important;z-index:1;}
.factory-mag .fm-ces-feature__lead .fm-post__title,.factory-mag .fm-ces-feature__lead .fm-post__title a{color:#fff!important;font-size:clamp(21px,2.2vw,30px);line-height:1.2;}
.factory-mag .fm-ces-feature__lead .fm-post__date,.factory-mag .fm-ces-feature__lead .fm-post__excerpt{color:rgba(255,255,255,.85)!important;}
.factory-mag .fm-ces-feature__lead .fm-post__category{color:#fff;background:var(--fm-tech2-accent,#f91169);padding:4px 7px;font-size:10px;text-transform:uppercase;}
.factory-mag .fm-ces-feature__secondary{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr));gap:32px;}
.factory-mag .fm-ces-feature__secondary>.fm-post{display:block!important;min-width:0;box-shadow:none;border:0;border-radius:0;}
.factory-mag .fm-ces-feature__secondary .fm-post__media{display:block;aspect-ratio:1.77;overflow:hidden;border-radius:0;}
.factory-mag .fm-ces-feature__secondary .fm-post__media img{width:100%;height:100%;object-fit:cover;display:block;}
.factory-mag .fm-ces-feature__secondary .fm-post__body{padding:12px 0 0!important;}
.factory-mag .fm-ces-feature__secondary .fm-post__title{font-weight:750;font-size:17px;line-height:1.35;}
.factory-mag .fm-ces-feature__secondary .fm-post__category{display:none;}
.factory-mag .fm-ces-feature__secondary .fm-post__date{display:block;margin-top:9px;color:#999;font-size:11px;}
@media(max-width:760px){.factory-mag .fm-ces-feature__lead>.fm-post{height:340px;}.factory-mag .fm-ces-feature__secondary{gap:18px;grid-template-columns:repeat(2,minmax(0,1fr));}}
@media(max-width:520px){.factory-mag .fm-ces-feature__lead>.fm-post{height:290px;}.factory-mag .fm-ces-feature__lead .fm-post__body{padding:18px!important;}.factory-mag .fm-ces-feature__secondary{grid-template-columns:1fr;gap:24px;}}

/* v4.60 — Grille de trois articles: trois colonnes sur un bloc 12/12.
   Les blocs de quatre articles et plus restent à quatre colonnes. */
@media (min-width:1051px) {
  .factory-mag .fm-section--grid.fm-grid-count-three[style*="--fm-span:12"] .fm-section__posts {
    grid-template-columns:repeat(3,minmax(0,1fr));
  }
}

/* v4.61: the configured article count determines desktop column count.
   This rule is included on every layout and is more specific than the 4-column baseline. */
@media(min-width:1051px){
 .factory-mag .fm-layout-row .fm-section.fm-section--grid.fm-grid-count-three[style*="--fm-span:12"] .fm-section__posts{
  grid-template-columns:repeat(3,minmax(0,1fr)) !important;
 }
}
