/* ==========================================================================
   Blogul: pagina unui articol, lista de articole, categoriile și profilul
   autorului de pe „Despre NEDAVI". Se încarcă doar acolo (ContentProvider::
   styles()), după chofu.css și theme.css. chofu.css rămâne neschimbat.

   Pagina articolului folosește toată lățimea .wrap, la cererea
   proprietarului: antetul (titlu, introducere, semnătură, imagine) pe toată
   lățimea, apoi cuprinsul lipit în stânga și textul în tot restul coloanei,
   fără limită de măsură. Lizibilitatea vine din tipografie: rând de 1,75 și
   literă ceva mai mare de la 1280 px. Sub articol, pe toată lățimea: caseta
   autorului, pasul următor și trei articole de citit.

     ≥ 980 px   cuprins (~15 rem, lipit) | text
     < 980 px   o coloană; cuprinsul strâns sus, sub „Cuprins"
   ========================================================================== */


/* --- Semnătura, sub titlu -------------------------------------------------- */
.byline { display: grid; gap: .4rem; margin: 1.25rem 0 0; }
.byline__who { margin: 0; font-size: var(--fs-small); color: var(--text); line-height: 1.5; }
.byline__who a { font-weight: 600; color: var(--ink); text-decoration: underline;
                 text-decoration-color: var(--line); text-decoration-thickness: 1px;
                 text-underline-offset: .22em; }
.byline__who a:hover { text-decoration-color: currentColor; opacity: 1; }
.byline__role { color: var(--text-muted); }
.byline__role::before { content: "·"; margin: 0 .55em; color: var(--divider); }
@media (max-width: 639px) {
  .byline__role { display: block; margin-top: .15rem; }
  .byline__role::before { content: none; }
}
.byline .byline__when { margin: 0; gap: .35rem .9rem; }
.byline__when > span { gap: .35em; }
.byline__when > span:not(:last-child)::after { margin-left: .55em; }
.byline__when time { font-variant-numeric: tabular-nums; }

/* --- Antetul pe toată lățimea --------------------------------------------- */
.art .art__headin { max-width: none; }
.art .art__t { max-width: none; text-wrap: pretty; }
.art .art__lead { max-width: none; }

/* --- Grila: cuprins | text ------------------------------------------------- */
.art .art__grid { grid-template-columns: minmax(0, 1fr); align-items: start; }
.art .art__rail { position: static; }

/* Fără limită de măsură în corp: textul, listele, titlurile, întrebările,
   tabelele și figurile iau toată coloana. */
.art .art__body > * { max-width: none; }
.art .art__body { line-height: 1.75; }

@media (min-width: 980px) {
  .art--toc .art__grid { grid-template-columns: minmax(12rem, 15rem) minmax(0, 1fr); }
  .art .art__rail { position: sticky; top: calc(var(--navh) + 1.25rem);
                    max-height: calc(100vh - var(--navh) - 2.5rem); overflow-y: auto;
                    overscroll-behavior: contain; }
  /* chofu.css desenează cuprinsul ca o casetă sub 1000 px; în coloană, nu. */
  .art__rail .toc { padding: 0; border: 0; background: none; }
  /* O singură bară de derulare: derulează coloana (.art__rail), nu și cuprinsul din ea. */
  .art__rail .toc { position: static; max-height: none; overflow: visible; }
}

@media (min-width: 1280px) {
  .art .art__body { font-size: 1.125rem; }
}

@media (min-width: 1680px) {
  .art .art__body { font-size: 1.1875rem; }
}

/* --- Cuprinsul ------------------------------------------------------------- */
.toc__d > summary { list-style: none; }
.toc__d > summary::-webkit-details-marker { display: none; }

@media (max-width: 979px) {
  .art .toc { padding: 0 clamp(1rem, 3vw, 1.25rem); }
  .toc__d > summary.toc__t { display: flex; align-items: center; justify-content: space-between;
    gap: 1rem; min-height: 48px; margin: 0; cursor: pointer; }
  .toc__d > summary.toc__t::after { content: ""; width: .55rem; height: .55rem; flex: none;
    border-right: 2px solid currentColor; border-bottom: 2px solid currentColor;
    transform: translateY(-25%) rotate(45deg); transition: transform .18s var(--quad); }
  .toc__d[open] > summary.toc__t::after { transform: translateY(15%) rotate(-135deg); }
  .toc__d > summary.toc__t:focus-visible { outline: 2px solid var(--chofu-navy); outline-offset: 2px; }
  .toc__d[open] > .toc__l { padding-bottom: 1rem; }
}

@media (min-width: 980px) {
  .toc__d > summary.toc__t { cursor: default; pointer-events: none; }
}

@media (prefers-reduced-motion: reduce) {
  .toc__d > summary.toc__t::after { transition: none; }
}

/* --- Sub articol: autorul, pasul următor, alte articole ------------------ */
.art__after { display: grid; gap: clamp(2rem, 4vw, 3.5rem); padding-block: clamp(2.5rem, 5vw, 4.5rem) var(--section); }
.art__meet { display: grid; gap: 1rem; align-items: stretch; }
@media (min-width: 980px) {
  .art__meet { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: clamp(1rem, 2vw, 1.5rem); }
  .art__meet--solo { grid-template-columns: minmax(0, 1fr); }
}

.sidecard { min-width: 0; padding: clamp(1.1rem, 2vw, 1.6rem); border: 1px solid var(--divider);
            border-radius: var(--r-card); background: var(--tint-1); display: flex; flex-direction: column; }
.sidecard__k { margin: 0 0 .55rem; font-size: var(--fs-micro); font-weight: 700;
               letter-spacing: .09em; text-transform: uppercase; color: var(--text-muted); }
.sidecard__t { margin: 0; font-size: var(--fs-h3); font-weight: 700; line-height: 1.25;
               letter-spacing: -.015em; color: var(--ink); }
.sidecard__p { margin: .45rem 0 1.1rem; font-size: var(--fs-small); line-height: 1.5; color: var(--text-muted); }
.sidecard__acts { display: grid; gap: .6rem; margin-top: auto; }
.sidecard .sidecard__go { justify-content: center; min-height: 48px; padding: .8em 1.1em;
                          font-size: var(--fs-small); line-height: 1.3; text-align: center;
                          white-space: normal; text-decoration: none; }

.art__relt { margin: 0 0 1.1rem; font-size: var(--fs-h3); letter-spacing: -.015em; }
.art__rel .card__title { font-size: var(--fs-h3); line-height: 1.25; letter-spacing: -.015em; margin: 0; }
.art__rel .card__ex { margin: 0; font-size: var(--fs-small); line-height: 1.55; color: var(--text-muted); }

/* --- Caseta autorului, sub articol ----------------------------------------- */
.abox { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 1rem 1.5rem; align-items: start;
        margin: 0; padding: clamp(1.1rem, 2vw, 1.6rem); border: 1px solid var(--divider);
        border-radius: var(--r-card); background: #fff; line-height: 1.6; }
/* Semnul NEDAVI în locul unui portret (nu există o fotografie reală). */
.abox__mark { display: block; width: 5.5rem; padding-top: .15rem; }
.abox__mark img { display: block; width: 100%; height: auto; }
.abox__tx { min-width: 0; }
.abox p { margin: 0; }
.abox .abox__k { font-size: var(--fs-micro); font-weight: 700; letter-spacing: .09em;
                 text-transform: uppercase; color: var(--text-muted); }
.abox .abox__name { margin-top: .3rem; font-size: var(--fs-lead); font-weight: 700; line-height: 1.3; }
.abox__name a { color: var(--ink); text-decoration: none; }
.abox__name a:hover { text-decoration: underline; text-underline-offset: .2em; opacity: 1; }
.abox .abox__role { margin-top: .2rem; font-size: var(--fs-small); color: var(--text-muted); }
.abox .abox__bio { margin-top: .8rem; font-size: var(--fs-small); max-width: 90ch; }
.abox .abox__more { margin-top: .8rem; font-size: var(--fs-small); font-weight: 600; }

@media (max-width: 479px) {
  .abox { grid-template-columns: minmax(0, 1fr); }
  .abox__mark { width: 4.5rem; }
}

/* --- Sursele de la final (Content\ArticleOutline: .art-src) ---------------
   O bibliografie, nu o listă de conținut: text mic, numerotat, cu adresele
   care se pot rupe oriunde. Apare doar dacă articolul are propria listă. */
.art__body h2[data-src-head] { font-size: var(--fs-h3); }
.art__body .art-src { margin: .6rem 0 0; padding: 1rem 0 0 1.4em; border-top: 1px solid var(--divider);
                      font-size: var(--fs-small); line-height: 1.55; color: var(--text-muted); }
.art__body .art-src li { margin: 0 0 .55rem; padding-left: .2em; overflow-wrap: anywhere; }
.art__body .art-src li::marker { font-variant-numeric: tabular-nums; color: var(--text-muted); }
.art__body .art-src a { color: var(--text); }

/* --- Profilul autorului, pe „Despre NEDAVI" ------------------------------- */
.aprof { padding: clamp(2rem, 4.5vw, 3.75rem) 0; border-top: 1px solid var(--divider);
         scroll-margin-top: calc(var(--navh) + 1rem); }
.aprof .aprof__t { margin: .45rem 0 0; }
.aprof .aprof__role { margin: .35rem 0 1.1rem; font-size: var(--fs-small); color: var(--text-muted); }
.aprof__links { margin: 1rem 0 0; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: .5rem 1.25rem; }
.aprof__links a, .aprof__more a { display: inline-flex; align-items: center; min-height: 44px; font-weight: 600; }
.aprof__more { margin: .5rem 0 0; }
.aprof__more a, .aprof__links a { text-decoration: underline; text-underline-offset: .2em; }

/* --- Lista de articole și categoriile ------------------------------------
   Trei coloane pe ecran lat (șase articole = două rânduri pline), aliniate la
   .wrap. Titlurile nu mai sunt echilibrate („balance" le rupea la ~220 px
   într-un card de 308 px); se rup normal, fără văduve. */
@media (min-width: 1000px) {
  .grid--3.blog-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
.blog-grid .card__title { max-width: none; text-wrap: pretty; }
.blog-grid .card__body > p:not(.card__meta) { max-width: 60ch; }
