/* letter-of-recommendation-template (build_letter_of_recommendation_template.py). Every rule starts with .tj-rec.
   Centrepiece: the letter drawn on headed paper with its four paragraphs named in the margin and the signature block. */
.tj-rec .lr-in{max-width:1220px;margin:0 auto;padding:0 28px}
.tj-rec section[class^="lr-"] h2{font-size:clamp(1.6rem,2.4vw,2.1rem);font-weight:700;letter-spacing:-.03em;line-height:1.14;margin:0;max-width:none}
.tj-rec .lr-ln{display:block;height:7px;border-radius:2px;background:var(--line);margin-top:9px}
.tj-rec .lr-ln.s{width:58%}
.tj-rec .lr-ln.m{width:82%}
.tj-rec .tpl{border:2px solid var(--ink);border-radius:14px;overflow:hidden;margin:0}
.tj-rec .tplbar{display:none}
.tj-rec .tpl:has(.tpldoc:not(.hidden-guide)) .tplbar{display:flex}
.tj-rec .tplcta .btn{white-space:normal}
.tj-rec .tpldfy form{display:grid;grid-template-columns:1fr;gap:10px}
.tj-rec .tpldfy>p{margin-left:0;max-width:none}

/* subscription box: the plan on plum, the drafting form on a white sheet inside it */
.tj-rec .lr-get{padding:72px 0}
.tj-rec .tpl{border-color:var(--plum)}
.tj-rec .tplgate{display:grid;grid-template-columns:minmax(0,7fr) minmax(0,5fr);column-gap:56px;align-content:start;text-align:left;padding:44px 44px 46px;background:var(--plum)}
.tj-rec .tplgate>*{grid-column:1}
.tj-rec .tplgate>h3{font-size:1.6rem;color:#fff}
.tj-rec .tplgate>p{max-width:none;margin-left:0;color:#f6e3ea}
.tj-rec .tplgate>p.tplnote{color:#f6e3ea}
.tj-rec .tplcta{justify-content:flex-start;gap:16px}
.tj-rec .tplcta .btn{background:var(--cfield);border-color:var(--cfield);color:var(--ink)}
.tj-rec .tpl .tplcta a:not(.btn){color:#fff;text-decoration:underline;font-weight:700}
.tj-rec .tplgate>.tpldfy{grid-column:2;grid-row:1/span 4;margin:0;max-width:none;background:#fff;border:0;border-radius:10px;padding:28px 28px 30px;text-align:left;align-self:start}
@media (max-width:900px){
.tj-rec .tplgate{grid-template-columns:1fr;padding:32px 22px 28px}
.tj-rec .tplgate>.tpldfy{grid-column:1;grid-row:auto;margin:28px 0 0}
}

/* questions: a framed panel */
.tj-rec .lr-faq{padding:0 0 72px}
.tj-rec .lr-qs{margin-top:24px;border:2px solid var(--ink);border-radius:14px;padding:6px 28px 8px}
.tj-rec .lr-qs details.fq:last-child{border-bottom:0}
@media (max-width:620px){.tj-rec .lr-qs{padding:4px 16px 6px}}

/* related templates: four columns under one rule */
.tj-rec .art-rel{padding-block:0 72px}
.tj-rec .art-rel-grid{gap:0;border-top:2px solid var(--ink)}
.tj-rec .art-rel-grid a,.tj-rec .art-rel-grid a:first-child{min-height:120px;padding:20px 24px 20px 0;border:0;border-radius:0;background:none}
.tj-rec .art-rel-grid a+a{padding-left:24px;border-left:1px solid var(--ink)}
.tj-rec .art-rel-grid a:hover{transform:none;box-shadow:none;color:var(--c)}
@media (max-width:900px){
.tj-rec .art-rel-grid{grid-template-columns:1fr 1fr}
.tj-rec .art-rel-grid a,.tj-rec .art-rel-grid a:first-child,.tj-rec .art-rel-grid a+a{min-height:0;padding:16px 0;border-left:0;border-bottom:1px solid var(--ink);flex-direction:row}
}
@media (max-width:620px){.tj-rec .art-rel-grid{grid-template-columns:1fr}}

/* closing band on plum */
.tj-rec .close{background:var(--plum)}
.tj-rec .close .closein{flex-direction:row;align-items:flex-end;justify-content:space-between;text-align:left;gap:48px;flex-wrap:nowrap}
.tj-rec .close h2{max-width:16ch}
.tj-rec .close .r{align-items:flex-start;max-width:520px}
.tj-rec .close .r a{background:var(--cfield);color:var(--ink)}
.tj-rec .close .r a:hover{background:#fff;color:var(--ink)}
@media (max-width:900px){.tj-rec .close .closein{flex-direction:column;align-items:flex-start;gap:20px}}

/* this page's own sections */
/* the letter on headed paper, with how to fill it in beside it */
.tj-rec .lr-doc{background:var(--ink);color:#fff;padding:64px 0 88px}
.tj-rec .lr-doc .lr-in{display:grid;grid-template-columns:minmax(0,5fr) minmax(0,7fr);gap:64px;align-items:start}
.tj-rec .lr-doc h2{color:#fff}
.tj-rec .lr-lede{margin:10px 0 0;color:#e9e4e6;font-size:1.05rem}
.tj-rec .lr-fill{margin-top:48px;padding-top:28px;border-top:2px solid #fff}
.tj-rec .lr-fill>p{margin:14px 0 0;font-size:1.08rem;line-height:1.7;color:#e9e4e6}
.tj-rec .lr-pairs{margin-top:28px}
.tj-rec .lr-pairs p{display:grid;grid-template-columns:minmax(0,1fr) 44px minmax(0,1fr);align-items:center;margin:10px 0 0}
.tj-rec .lr-pairs span{padding:12px 14px;border-radius:8px;font-family:var(--head);font-weight:700;font-size:.95rem;letter-spacing:-.012em;line-height:1.25;background:#fff;color:var(--ink)}
.tj-rec .lr-pairs span:first-child{background:var(--cfield)}
.tj-rec .lr-pairs i{border-top:2px solid #fff}
.tj-rec .lr-letter{background:#fff;color:var(--ink);border-radius:3px;padding:44px 52px 48px;box-shadow:14px 14px 0 var(--cfield)}
.tj-rec .lr-letter p{margin:0}
.tj-rec .lr-top{display:flex;justify-content:space-between;align-items:flex-start;padding-bottom:26px;border-bottom:3px solid var(--ink)}
.tj-rec .lr-mark{width:120px;height:44px;border-radius:6px;background:var(--cfield)}
.tj-rec .lr-from{width:170px}
.tj-rec .lr-from i{display:block;height:7px;border-radius:2px;background:var(--line);margin:0 0 9px auto}
.tj-rec .lr-from i+i{width:78%}
.tj-rec .lr-from i+i+i{width:56%;margin-bottom:0}
.tj-rec .lr-title{margin-top:30px;font-family:var(--head);font-weight:700;font-size:clamp(1.4rem,2.4vw,1.8rem);letter-spacing:-.03em;line-height:1.15}
.tj-rec .lr-paras{list-style:none;margin:18px 0 0;padding:0;counter-reset:lr}
.tj-rec .lr-paras li{counter-increment:lr;display:grid;grid-template-columns:190px minmax(0,1fr);gap:24px;padding:18px 0;border-top:1px solid var(--line)}
.tj-rec .lr-paras b{font-family:var(--head);font-weight:700;font-size:1rem;letter-spacing:-.012em;line-height:1.3}
.tj-rec .lr-paras b:before{content:counter(lr) ". ";color:var(--c)}
.tj-rec .lr-paras .lr-ln:first-child{margin-top:6px}
.tj-rec .lr-sign{margin:22px 0 0 214px;max-width:300px}
.tj-rec .lr-sig{display:block;height:46px;border-bottom:2px solid var(--ink);background:radial-gradient(ellipse 60px 16px at 70px 30px,rgba(255,255,255,0) 92%,var(--c) 93% 100%,rgba(255,255,255,0) 101%),radial-gradient(ellipse 44px 11px at 150px 31px,rgba(255,255,255,0) 90%,var(--c) 92% 100%,rgba(255,255,255,0) 101%)}
.tj-rec .lr-sign p{display:flex;align-items:flex-end;gap:12px;margin-top:14px;font-size:.9rem;font-weight:700}
.tj-rec .lr-sign p i{flex:1;border-bottom:2px dotted var(--ink)}

/* the two notes */
.tj-rec .lr-law{padding:76px 0 0}
.tj-rec .lr-law .lr-in{display:grid;grid-template-columns:minmax(0,7fr) minmax(0,5fr);gap:64px;align-items:start}
.tj-rec .lr-law h2{font-size:1.3rem}
.tj-rec .lr-law p{margin:12px 0 0;font-size:1.04rem;line-height:1.72;color:#2f2b2e}
.tj-rec .lr-law-tx{border-top:6px solid var(--ink);padding-top:20px}
.tj-rec .lr-b4{background:#fff0f4;border-radius:12px;padding:24px 28px 26px}

@media (max-width:900px){
.tj-rec .lr-doc .lr-in,.tj-rec .lr-law .lr-in{grid-template-columns:1fr;gap:40px}
}
@media (max-width:620px){
.tj-rec .lr-letter{padding:30px 20px 32px;box-shadow:8px 8px 0 var(--cfield)}
.tj-rec .lr-paras li{grid-template-columns:1fr;gap:4px}
.tj-rec .lr-sign{margin-left:0}
.tj-rec .lr-pairs p{grid-template-columns:minmax(0,1fr) 16px minmax(0,1fr)}
.tj-rec .lr-mark{width:84px}
.tj-rec .lr-from{width:120px}
}
