/* =====================================================================
   memories.css — styles for rendered memories.
   Additive only. Each page already defines its own .weave; these rules
   add what the renderer needs on top, so a memory looks native to
   whichever page it lands on (cream or forest green).
   ===================================================================== */

/* ---- pull-quote woven into a page ---- */
.weave q{
  quotes:none;display:block;font-style:italic;
  font-size:15.5px;line-height:1.55;color:var(--ink-soft);
}
.weave cite{
  display:block;font-family:var(--mono);font-style:normal;font-size:11px;
  letter-spacing:.05em;color:var(--moss-soft);margin-top:10px;line-height:1.7;
}
.weave cite a{color:var(--madder);font-style:normal;text-decoration:none;border-bottom:1px solid rgba(168,68,46,.4)}
.weave cite a:hover{color:var(--madder-deep,#8A3423)}
.weave + .weave{margin-top:16px}
/* The way through to the full memory, where the language buttons live.
   Deliberately quiet: it is a footnote on a page about his life, not a
   call to action. */
.weave-more{
  display:inline-block;margin-top:7px;font-family:var(--mono);font-size:11px;
  letter-spacing:.05em;color:var(--madder,#A8442E);text-decoration:none;
  border-bottom:1px solid rgba(168,68,46,.35);
}
.weave-more:hover{color:var(--madder-deep,#8A3423);border-bottom-color:var(--madder-deep,#8A3423)}

/* ---- the collected list ---- */
.memories{margin-top:10px;border-top:1px solid var(--rule)}
.memory{padding:30px 0;border-bottom:1px solid var(--rule);scroll-margin-top:24px}
.memory .head{display:flex;gap:14px;align-items:baseline;flex-wrap:wrap;margin-bottom:10px}
.memory .who{font-family:var(--display);font-weight:600;font-size:1.16rem;color:var(--ink)}
.memory .who.anon{font-style:italic;font-weight:500;color:var(--moss-soft)}
.memory .rel{font-size:14.5px;color:var(--moss-soft);font-style:italic}
.memory .route{
  margin-left:auto;font-family:var(--mono);font-size:10.5px;letter-spacing:.1em;
  text-transform:uppercase;color:var(--gold-deep);border:1px solid var(--gold);padding:3px 9px;
}
.memory .text{max-width:38em;color:var(--ink-soft)}
.memory .text p{margin:0 0 .9em}
.memory .text p:last-child{margin-bottom:0}
.memory figure{margin:18px 0 0;max-width:340px}
.memory figure img{
  display:block;width:100%;border:5px solid #FCF8EE;
  box-shadow:0 10px 26px -16px rgba(90,60,30,.5);background:#EDE4CF;
}
.memory figcaption{font-family:var(--mono);font-size:11px;color:var(--moss-soft);margin-top:8px;letter-spacing:.04em}
.memory:target{background:linear-gradient(90deg,rgba(181,132,46,.10),transparent 60%)}

/* ---- language switcher on a memory ---- */
[data-lang]{display:none}
[data-lang].on{display:block}
.langs{
  display:flex;align-items:center;gap:9px;flex-wrap:wrap;margin-top:12px;
  font-family:var(--mono);font-size:11.5px;letter-spacing:.05em;
}
.langs .sep{color:var(--rule)}
.langs button{
  background:none;border:0;padding:0;cursor:pointer;font:inherit;
  color:var(--madder);border-bottom:1px solid rgba(168,68,46,.45);line-height:1.7;
}
.langs button:hover{color:var(--madder-deep,#8A3423);border-bottom-color:var(--madder-deep,#8A3423)}
.langs button[aria-pressed="true"]{color:var(--ink);border-bottom-color:transparent;cursor:default}
.langs button em{font-style:normal;color:var(--moss-soft);font-size:10.5px}
.langs button:focus-visible{outline:2px solid var(--madder);outline-offset:3px}
.tflag{
  font-family:var(--mono);font-size:10.5px;letter-spacing:.11em;text-transform:uppercase;
  color:var(--moss-soft);margin:9px 0 0;
}

/* on the forest-green pages the woven quote sits on a dark ground */
.lineage .weave q,section.alt .weave q{color:var(--ink-soft)}

@media(max-width:640px){
  .memory .route{margin-left:0}
}

/* =====================================================================
   Added for WordPress: the submission form, and the small differences
   between a memory rendered from JSON and one rendered from a post.
   Everything above this line is the static site's file, unchanged, so a
   memory looks the same in both builds.
   ===================================================================== */

/* the rendered memory's text blocks (WP uses .mtext where the static
   build used .text — the static one had one language per page, this one
   holds all of them and shows one) */
.memory .mtext{max-width:38em;color:var(--ink-soft)}
.memory .mtext p{margin:0 0 .9em}
.memory .mtext p:last-child{margin-bottom:0}
.memory .mtext{display:none}
.memory .mtext.on{display:block}
.memory .tlabel{
  font-family:var(--mono);font-size:10.5px;letter-spacing:.11em;text-transform:uppercase;
  color:var(--moss-soft);margin:0 0 8px;
}
.memory .mphoto{margin:18px 0 0;max-width:340px}
.memory .mphoto img{
  display:block;width:100%;height:auto;border:5px solid #FCF8EE;
  box-shadow:0 10px 26px -16px rgba(90,60,30,.5);background:#EDE4CF;
}
.langs button.on{color:var(--ink);border-bottom-color:transparent;cursor:default}

/* ---------------------------------------------------------- the form */
.rm-form{max-width:38em}
.rm-field{margin:0 0 22px}
.rm-field label,.rm-perm legend,.rm-rel legend{
  display:block;font-family:var(--display,Georgia,serif);font-weight:600;
  font-size:1.02rem;color:var(--ink);margin-bottom:7px;
}
.rm-field input[type=text],.rm-field input[type=email],
.rm-field select,.rm-field textarea{
  width:100%;font-family:var(--serif,Georgia,serif);font-size:16.5px;color:var(--ink);
  background:var(--card,#FBF7EC);border:1px solid var(--rule,#DFD4BB);
  border-left:3px solid var(--frame,#CDB27B);padding:11px 13px;
}
.rm-field textarea{line-height:1.6;resize:vertical;min-height:210px}
.rm-field input:focus,.rm-field select:focus,.rm-field textarea:focus{
  outline:none;border-left-color:var(--madder,#A8442E);
  box-shadow:0 0 0 3px rgba(168,68,46,.10);
}
.rm-field input[type=file]{font-family:var(--mono,monospace);font-size:13px}
.rm-help{font-size:14px;color:var(--moss-soft,#5D6E5F);font-style:italic;margin:7px 0 0;line-height:1.5}

/* A <legend> in a bordered <fieldset> straddles the top border by browser
   default, which reads as a mistake rather than a heading. So the fieldset
   carries no border of its own and the border goes on .rm-box inside it.
   <legend> still names the group for a screen reader; it simply sits on its
   own line above the box, like every other label on this form. */
.rm-perm,.rm-rel{border:0;padding:0;margin:0 0 22px}
.rm-box{border:1px solid var(--rule,#DFD4BB);background:var(--card,#FBF7EC);padding:16px 18px}

.rm-perm label{
  display:flex;gap:9px;align-items:flex-start;font-family:var(--serif,Georgia,serif);
  font-weight:400;font-size:16px;color:var(--ink-soft);margin:0 0 9px;cursor:pointer;
}
.rm-perm label:last-child{margin-bottom:0}

/* "How did you know him?" — tick as many as apply. Two columns where there
   is room, one on a phone. The help line sits above the boxes, so it is
   read before they are answered rather than after. */
.rm-rel .rm-help{margin:0 0 12px}
.rm-rel label{
  display:flex;gap:9px;align-items:flex-start;font-family:var(--serif,Georgia,serif);
  font-weight:400;font-size:16px;color:var(--ink-soft);margin:0 0 9px;cursor:pointer;
}
@media (min-width:560px){
  .rm-rel label{display:inline-flex;width:calc(50% - 14px);margin-right:10px;vertical-align:top}
}

/* The note above "I agree to the above" — what they are agreeing to. */
.rm-privacy{margin:0 0 12px}
.rm-consent label{
  display:flex;gap:9px;align-items:flex-start;font-family:var(--serif,Georgia,serif);
  font-weight:400;font-size:15.5px;color:var(--ink-soft);cursor:pointer;
}

.rm-submit{
  font-family:var(--mono,monospace);font-size:12.5px;letter-spacing:.14em;text-transform:uppercase;
  background:var(--moss-deep,#2E4038);color:#F4F2E8;border:0;padding:15px 30px;cursor:pointer;
  transition:.2s;
}
.rm-submit:hover{background:var(--madder,#A8442E)}

/* the honeypot: off-screen rather than display:none, because some bots
   skip anything hidden and this one is meant to be filled in */
.rm-hp{position:absolute;left:-9999px;width:1px;height:1px;overflow:hidden}

.rm-error{
  background:#F6E9E4;border-left:3px solid var(--madder,#A8442E);
  padding:12px 16px;font-size:15px;color:var(--ink-soft);margin:0 0 20px;
}
.rm-thanks{
  background:var(--card,#FBF7EC);border:1px solid var(--rule,#DFD4BB);
  border-left:3px solid var(--gold,#B5842E);padding:28px 30px;max-width:38em;
}
.rm-thanks h3{margin:0 0 12px;font-size:1.35rem}
.rm-thanks p{color:var(--ink-soft);margin:0 0 .8em}
.rm-thanks p:last-child{margin-bottom:0}
