/* =========================================
   YFP Article Layout (clean, consistent)
   ========================================= */

body.yfp-style-article {
  --yfp-max: 1100px;
  --yfp-border: #e5e7eb;
  --yfp-muted: #475569;
}

body.yfp-style-article .container {
  max-width: var(--yfp-max);
  margin-inline: auto;
  padding-inline: 1rem;
}

/* Title band / breadcrumb */
.yfp-titleband {
  border-bottom: none;
}

.yfp-titleband .container {
  padding-top: 18px;
  padding-bottom: 18px;
}

.yfp-breadcrumb {
  font-size: 0.92rem;
  color: var(--yfp-muted);
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
  align-items: center;
}

.yfp-breadcrumb a {
  color: inherit;
  text-decoration: none;
}
.yfp-breadcrumb a:hover {
  text-decoration: underline;
}

.yfp-breadcrumb .sep {
  opacity: .6;
}

.yfp-article-title {
  margin: 10px 0 8px;
  letter-spacing: -0.02em;
  line-height: 1.15;
  font-size: clamp(1.9rem, 3.2vw, 2.5rem);
}

.yfp-article-meta {
  color: var(--yfp-muted);
  font-size: 0.95rem;
  display: flex;
  gap: .5rem;
  align-items: center;
}

/* Layout grid */
.yfp-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 28px;
  padding-top: 26px;
  padding-bottom: 56px;
}

@media (max-width: 980px) {
  .yfp-layout {
    grid-template-columns: 1fr;
  }
}

/* Article */
.yfp-article {
  min-width: 0;
}

.yfp-hero-figure {
  margin: 0 0 18px;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--yfp-border);
  background: #fff;
}

.yfp-hero-figure img {
  width: 100%;
  height: auto;
  display: block;
}

/* Body typography */
.yfp-article-body {
  font-size: 0.99rem;
  line-height: 1.75;
  color: #334155; /* Now slate-700, previous body font color #0f172a;*/
}

.yfp-article-body p {
  margin: 0 0 1rem;
  color: #334155;
}

.yfp-article-body h2 {
  margin: 1.8rem 0 .75rem;
  font-size: 1.4rem;
  letter-spacing: -0.01em;
}

.yfp-article-body h3 {
  margin: 1.4rem 0 .6rem;
  font-size: 1.15rem;
}

/* Sidebar */
.yfp-sidebar {
  min-width: 0;
}

.yfp-sidebar-stack {
  display: grid;
  gap: 35px;
}

.yfp-sidebox ul {
  margin: 0;
  padding-left: 1.1rem;
}

.yfp-sidebox li {
  margin: .35rem 0;
}

.yfp-sidebox a {
  text-decoration: none;
}
.yfp-sidebox a:hover {
  text-decoration: underline;
}

.yfp-sidebox-more {
  margin-top: .6rem;
}

/* Disclaimer */
.yfp-disclaimer {
  margin-top: 30px;
  padding: 16px 16px;
  border: 1px solid var(--yfp-border);
  border-radius: 16px;
  background: #f8fafc;
}

.yfp-disclaimer h2 {
  margin: 0 0 8px;
  font-size: 0.9rem;
  letter-spacing: -0.01em;
}

.yfp-disclaimer p {
  margin: 0;
  color: #475569;
  line-height: 1.35;
  font-size: 0.98rem;
}


/***Sticky sidebar***/
@media (min-width: 981px) {
  .yfp-sidebar { position: sticky; top: 92px; align-self: start; }
}

/* ===== Sidebar module (publishing-style) ===== */
/*This was the original look of the sidebar block but below we are changing it*/
.yfp-sideblock{
  border: 1px solid var(--yfp-border);
  border-radius: 16px;
  background: #f8fafc; /*#fff;*/
  overflow: hidden;

  /* subtle lift so it feels intentional */
  box-shadow: 0 6px 22px rgba(2, 6, 23, 0.06);
}

/*This is the new warm updated look of the sidebar boxes*/
/* Sidebar box style to match Latest Science warm look */
body.yfp-style-article .yfp-sideblock{
  background: #f8fafc;                 /* #fbf7f1; warm tint */
  border: 1px solid #e2e8f0;           /* #efe5d7; warm border */
  box-shadow: none;                    /* LS look is flatter */
}




/* Header row */
.yfp-sideblock__head{
  display:flex;
  align-items:baseline;
  justify-content:space-between;
  padding: 14px 14px 10px;
  border-bottom: none;
  background: #f8fafc; /*linear-gradient(to bottom, #ffffff, #fbfdff);*/
}

/* Sidebar section heading (editorial label style) */
.yfp-sideblock__title{
  margin: 0;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #0f172a;   /* slate-900 */
}



.yfp-sideblock__all{
  font-size:.9rem;
  text-decoration:none;
  color:#334155;
  padding: 4px 8px;
  border-radius: 999px;
}
.yfp-sideblock__all:hover{
  background:#f1f5f9;
}

/* Sidebar: remove the "All →" link */
body.yfp-style-article .yfp-sideblock__all{
  display: none !important;
}


/* List rows */
.yfp-sidelist{ display:grid; }

.yfp-sidelist__item{
  display:grid;
  grid-template-columns: 66px 1fr; /* bigger thumb column */
  gap: 10px;
  align-items:center;
  padding: 12px 14px;
  text-decoration:none;
  color: inherit;
  transition: background .15s ease, transform .15s ease;
}

/* Thin separators (clean publishing look) But remove the top line between box title and first thumbnail */
.yfp-sidelist__item + .yfp-sidelist__item{
  border-top: none;
}





/* Hover: slightly darker + micro-lift (micro lift was removed) */
.yfp-sidelist__item:hover{
  background: #f1f5f9; /*#f8fafc; #eaf0f6; also #f1f5f9*/
  transform: none;
}

/* Thumbs */
.yfp-sidelist__thumb{
  width: 66px;
  height: 66px;
  border-radius: 12px;
  object-fit: cover;
  display:block;
  border: 1px solid #e9dccb;
  background:#fff;
}

.yfp-sidelist__thumb--ph{
  background:#f1f5f9;
}

/* Sidebar item titles (supporting, compact editorial style) */
.yfp-sidelist__text{
  font-size: 0.9rem;
  font-weight: 500;
  line-height: 1.15;
  color: #1f2937;              /* slate-800 */
  letter-spacing: -0.01em;

  /* 3-line clamp */
  max-height: calc(1.15em * 3);
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}


/* 3) Inset dividers aligned with thumbnail edges */

/* draw an inset divider inside each item (except the first) */
body.yfp-style-article .yfp-sidelist__item{
  position: relative; /* anchor for ::before divider */
}

body.yfp-style-article .yfp-sidelist__item + .yfp-sidelist__item::before{
  content: "";
  position: absolute;
  top: 0;
  left: 24px; /* calc(14px + 58px + 10px); left padding + thumb width + gap */
  right: 24px;                    /* match item right padding */
  height: 1px;
  background: #e2e8f0; /*#e7d7c3;*/
  opacity: 1;
}


/* Pull sidebar upward on desktop so it starts near the title area */
@media (min-width: 981px){
  body.yfp-style-article .yfp-sidebar{
    margin-top: -96px;  /* tune: -40, -60, -72, -90 */
  }
}


/*Subtle hover without dramatic darkening*/
body.yfp-style-article .yfp-sidelist__item:hover .yfp-sidelist__text{
  text-decoration: underline;
  text-underline-offset: 2px;
}

/*Sidebar All link if it is ever re-enabled*/
body.yfp-style-article .yfp-sideblock__all{
  font-size: 0.85rem;
  color: #64748b;
}

/*Gap between the main text and sidebar*/
@media (min-width: 981px){
  body.yfp-style-article .yfp-layout{
    gap: 34px; /* try 28–40 */
  }
}


/* ==============================
   References: compact appendix
   ============================== */

body.yfp-style-article section.reference{
  margin-top: 24px;
  padding: 14px 16px;
  border: 1px solid var(--yfp-border, #e5e7eb);
  border-radius: 16px;
  background: #f8fafc;
}

body.yfp-style-article section.reference p{
  margin: 0 0 8px;          /* tighter spacing between refs */
  font-size: 0.9rem;        /* smaller text */
  line-height: 1.35;        /* compact but readable */
  color: #334155;           /* slate-700 */
}

/* last item no extra space */
body.yfp-style-article section.reference p:last-child{
  margin-bottom: 0;
}

/* links: compact + don’t dominate */
body.yfp-style-article section.reference a{
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* Long URLs: allow wrap without huge height */
body.yfp-style-article section.reference a{
  overflow-wrap: anywhere;  /* breaks long links nicely */
  word-break: break-word;
}

body.yfp-style-article section.reference::before{
  content: "References";
  display: block;
  margin-bottom: 10px;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: .08em;
  /*text-transform: uppercase;*/
  color: #0f172a;
}
