/* Plant Daily — Encyclopedia · Collection · Living Garden (PHASE COMPLETE-1). Tokens only (tokens.css). Mobile first (375 px). */

/* ---------- images with credit (U) */
.pic { position: relative; margin: 0; background: var(--surface-muted); border-radius: var(--radius); overflow: hidden; }
.pic img { display: block; width: 100%; height: 100%; object-fit: cover; }
.pic .credit { position: absolute; left: 0; right: 0; bottom: 0; padding: 14px 10px 6px; font-size: 11px; line-height: 1.3; color: #fff; background: linear-gradient(transparent, rgba(0,0,0,.55)); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pic .credit a { color: #fff; text-decoration: none; }
.pic .credit.k { color: var(--text-secondary); background: linear-gradient(transparent, rgba(251,248,242,.92)); }
.pic .fellnote { display: none; position: absolute; left: 8px; top: 8px; font-size: 11px; padding: 2px 8px; border-radius: var(--radius-pill); background: rgba(251,248,242,.92); color: var(--text-secondary); }
.pic.fell .credit { display: none; } .pic.fell .fellnote { display: block; }
.pic.k-illustration img, .pic.k-character img { object-fit: contain; background: #F6F2EA; }
.pic.hero { height: 260px; margin: var(--s-2) 0 var(--s-3); box-shadow: var(--shadow-card); }
img.is-ph { object-fit: contain !important; background: var(--surface-muted); }

/* ---------- search + lists (S) */
.wksearch input { font-size: 17px; }
.wkrow .t { flex: 1; min-width: 0; } .wkrow .sci, .sci { font-size: 14px; color: var(--text-secondary); } .sci i { font-style: italic; }
.wkrow .meta { margin-top: 2px; } .wkrow .cr, .wktile .cr { font-size: 11px; color: var(--text-secondary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.wkcats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s-2); }
.wkcat { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 10px 6px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); text-decoration: none; color: inherit; text-align: center; min-height: 112px; }
.wkcat img { width: 56px; height: 56px; object-fit: cover; border-radius: 14px; background: var(--surface-muted); }
.wkcat span { display: flex; flex-direction: column; } .wkcat b { font-size: 14px; }
.wkgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s-3); }
.wktile { display: block; text-decoration: none; color: inherit; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.wktile .pic { border-radius: 0; aspect-ratio: 1 / 1; }
.wktile .pic .credit { font-size: 10px; padding: 12px 6px 4px; }
.wktile .m { padding: 8px 10px 10px; } .wktile b { display: block; font-size: 15px; line-height: 1.3; } .wktile .sci { font-size: 12px; margin: 2px 0 4px; }
.hstrip { display: flex; gap: var(--s-3); overflow-x: auto; padding: 4px 0 8px; scroll-snap-type: x mandatory; }
.hstrip > * { flex: 0 0 150px; scroll-snap-align: start; }
.hstrip.gal > .pic { flex-basis: 220px; height: 160px; }
.wkfilter { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 4px; } .wkfilter .btn { white-space: nowrap; }
.btn.small, a.btn.small { min-height: 36px; padding: 4px 10px; font-size: 14px; }
.btn.sel, a.btn.sel { border-color: var(--accent); background: var(--accent-soft); font-weight: 700; }
.wkguide { display: flex; gap: var(--s-3); align-items: center; } .wkguide img { width: 64px; height: 64px; border-radius: 16px; object-fit: cover; background: var(--surface-muted); }

/* ---------- species page (Q) */
.wkhead h1 { margin-bottom: 0; } .wkhead .sci { font-size: 16px; margin: 2px 0 4px; }
a.pill { text-decoration: none; }
.wkact { margin-top: var(--s-3); } .wkact .btn, .wkact button { flex: 1 1 calc(50% - 8px); }
.wkbanner b { display: block; margin-bottom: 4px; }
.qf { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s-2); }
.qf .q { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 10px 12px; display: flex; flex-direction: column; gap: 4px; min-height: 96px; }
.qf .q:last-child:nth-child(odd) { grid-column: 1 / -1; }
.qf .qk { font: var(--type-caption); color: var(--text-secondary); } .qf .qv { font-size: 15px; line-height: 1.45; }
.qf .q.unk .qv { color: var(--text-secondary); font-size: 14px; } .qf .q.fb { border-style: dashed; }
.hint { display: inline-block; font-size: 11.5px; line-height: 1.3; padding: 2px 8px; border-radius: var(--radius-pill); background: var(--surface-muted); color: var(--text-secondary); align-self: flex-start; }
.hint.strong { background: var(--care-positive-soft); color: var(--care-positive); } .hint.ok { background: var(--accent-soft); color: var(--accent); }
.hint.warn { background: var(--care-attention-soft); color: var(--care-attention); } .hint.fallback { background: transparent; border: 1px dashed var(--border-strong); }
.wklegend { margin: 6px 2px 0; }
.wksec h3 { display: flex; align-items: center; gap: 6px; }
.fact { display: grid; grid-template-columns: 88px 1fr; gap: 2px 10px; padding: 8px 0; border-bottom: 1px solid var(--border); }
.fact:last-of-type { border-bottom: none; } .fact .fk { font: var(--type-caption); color: var(--text-secondary); padding-top: 2px; }
.fact .fv { font-size: 15px; line-height: 1.5; } .fact .fh { grid-column: 2; } .fact.fb .fv { color: var(--text-secondary); }
.unk { font-size: 13.5px; color: var(--text-secondary); padding: 6px 0 0; } .unk::before { content: "○ "; }
.prose { margin-top: 8px; padding-top: 8px; border-top: 1px dashed var(--border); } .prose p { margin: 0 0 6px; font-size: 15px; line-height: 1.65; }
.srcs { margin: 4px 0 0; padding-left: 20px; font-size: 14px; line-height: 1.6; } .srcs a { color: var(--accent); word-break: break-word; }
.wkguidecard { display: flex; gap: var(--s-3); align-items: flex-start; background: var(--surface-muted); box-shadow: none; }
.wkguidecard img.guide { width: 56px; height: 56px; border-radius: 14px; object-fit: cover; flex: 0 0 56px; }
.pcredit { position: absolute; left: 10px; top: 8px; font-size: 10.5px; color: #fff; background: rgba(0,0,0,.38); padding: 2px 8px; border-radius: var(--radius-pill); max-width: 70%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.credit-ov { position: absolute; left: 8px; top: 8px; font-size: 10.5px; color: #fff; background: rgba(0,0,0,.38); padding: 2px 8px; border-radius: var(--radius-pill); max-width: 60%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.list .cr { font-size: 11px; color: var(--text-secondary); }

/* ---------- Collection cards (W): subtle foil · tilt ≤ 7° · parallax 2–5 px · matte face, gloss highlight; no rarity colours */
.ctabs { margin: 10px 0; flex-wrap: nowrap; overflow-x: auto; } .ctabs .btn { white-space: nowrap; }
.cgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s-3); perspective: 900px; }
.ccard { --rx: 0deg; --ry: 0deg; --mx: 50%; --my: 50%; --px: 0px; --py: 0px; position: relative; display: block; text-decoration: none; color: inherit; border-radius: 14px; transform: rotateX(var(--rx)) rotateY(var(--ry)); transform-style: preserve-3d; transition: transform var(--motion-base) var(--ease), box-shadow var(--motion-base) var(--ease); box-shadow: 0 1px 2px rgba(31,30,27,.06), 0 8px 22px rgba(31,30,27,.08); }
.ccard.live { transition: none; box-shadow: 0 2px 4px rgba(31,30,27,.08), 0 14px 30px rgba(31,30,27,.12); }
.ccard .face { position: relative; border-radius: 14px; overflow: hidden; background: #1B1A16; border: 1px solid #3A3628; }
.ccard .face::after { content: ""; position: absolute; inset: 5px; border: 1px solid rgba(47,74,58,.18); border-radius: 10px; pointer-events: none; }
.ccard .img { position: relative; aspect-ratio: 4 / 5; overflow: hidden; background: var(--surface-muted); }
.ccard .img img { width: calc(100% + 12px); height: calc(100% + 12px); margin: -6px; object-fit: cover; transform: translate(var(--px), var(--py)); transition: transform var(--motion-base) var(--ease); display: block; }
.ccard.live .img img { transition: none; }
.ccard .img img.phc { object-fit: contain; opacity: .9; }
.ccard .img .badge { position: absolute; right: 8px; bottom: 8px; width: 34px !important; height: 34px !important; margin: 0 !important; border-radius: 10px; border: 2px solid #1B1A16; object-fit: cover; transform: none !important; }
.ccard .nophoto { position: absolute; left: 8px; top: 8px; font-size: 11px; background: rgba(251,248,242,.92); padding: 2px 8px; border-radius: var(--radius-pill); color: var(--text-secondary); }
.ccard .cap { display: flex; flex-direction: column; padding: 8px 10px 10px; gap: 1px; } .ccard .cap b { font-size: 15px; letter-spacing: .01em; }
.ccard .cap .sp { font-size: 12px; color: var(--text-secondary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .ccard .cap .foot { font: 500 10.5px/1.4 var(--font-numeric); color: var(--archive-ink); opacity: .75; margin-top: 3px; letter-spacing: .04em; }
.ccard .foil { position: absolute; inset: 0; border-radius: 14px; pointer-events: none; mix-blend-mode: soft-light; opacity: .55;
  background: radial-gradient(circle at var(--mx) var(--my), rgba(255,255,255,.75), rgba(255,255,255,0) 42%), repeating-linear-gradient(115deg, rgba(196,214,203,.0) 0 7px, rgba(196,214,203,.35) 7px 8px, rgba(235,220,190,.0) 8px 15px); }
.ccard.past .face { filter: saturate(.55); }
.ccard.creature .img.char { background: radial-gradient(circle at 50% 40%, #25231C, #121210); } .ccard.creature .img.char img { object-fit: contain; width: 100%; height: 100%; margin: 0; }
.ccard.space .img { aspect-ratio: 5 / 4; } .ccard.moment .face { background: #1B1A16; }
@media (prefers-reduced-motion: reduce) { .ccard, .ccard .img img { transform: none !important; transition: none !important; } .ccard .foil { background: repeating-linear-gradient(115deg, rgba(196,214,203,.0) 0 7px, rgba(196,214,203,.3) 7px 8px); } }

/* ---------- Living Garden (X) */
.garden { margin-top: var(--s-4); } .ghead { display: flex; align-items: baseline; gap: 8px; } .ghead h2 { margin: 0; color: var(--text-primary); } .ghead .btn { margin-left: auto; }
.shelf { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s-2); margin-top: var(--s-2); padding: 14px 10px 6px; border-radius: var(--radius); background: linear-gradient(#F6F1E8, #EFE7DA); border: 1px solid var(--border); position: relative; }
.shelf.empty { display: block; text-align: center; padding: 24px; }
.gchar { display: flex; flex-direction: column; align-items: center; gap: 2px; background: transparent; border: none; padding: 4px 2px 8px; min-height: 140px; cursor: pointer; border-radius: var(--radius-sm); font: inherit; color: inherit; }
.gchar .stage img { width: 84px; height: 84px; object-fit: cover; border-radius: 20px; background: #EFE7D8; box-shadow: 0 6px 14px rgba(0,0,0,.45); position: relative; z-index: 1; transition: transform var(--motion-base) var(--ease); }
.gchar:hover .stage img, .gchar:focus-visible .stage img { transform: translateY(-3px); }
.gchar .stage { display: flex; flex-direction: column; align-items: center; } .gchar .stage::after { content: ""; display: block; width: 72px; height: 8px; margin-top: 4px; border-radius: 50%; background: radial-gradient(ellipse, rgba(110,90,60,.22), rgba(110,90,60,0) 70%); }
.gchar .n { font-size: 13px; margin-top: 4px; z-index: 1; } .gchar .n b { font-family: var(--font-numeric); }
.gchar .st { font-size: 11px; color: var(--text-secondary); }
.gchar.focus { background: var(--accent-soft); }
.gchar.st-HOT .st, .gchar.st-COLD .st, .gchar.st-THIRSTY .st, .gchar.st-TOO_WET .st { color: var(--care-attention); }
.gsheet { display: flex; gap: 12px; align-items: center; margin-bottom: 8px; } .gsheet img { width: 64px; height: 64px; border-radius: 16px; object-fit: cover; }
.gstrip { display: flex; align-items: center; justify-content: space-between; gap: 8px; text-decoration: none; color: inherit; }
.gstrip .chars { display: flex; gap: 8px; flex-wrap: wrap; } .gstrip .chars span { display: inline-flex; align-items: center; gap: 2px; font: 600 12px/1 var(--font-numeric); }
.gstrip > .muted { white-space: nowrap; } .gstrip .chars img { width: 32px; height: 32px; border-radius: 9px; object-fit: cover; background: var(--surface-muted); }
.sheet .opts a.btn { text-decoration: none; }
@media (prefers-reduced-motion: reduce) { .gchar .stage img { transition: none; } }
@media (min-width: 768px) { .wkgrid, .cgrid { grid-template-columns: repeat(3, 1fr); } .wkcats { grid-template-columns: repeat(4, 1fr); } .shelf { grid-template-columns: repeat(4, 1fr); } }
@media (max-width: 340px) { .wkcats { grid-template-columns: 1fr 1fr; } .qf { grid-template-columns: 1fr; } .fact { grid-template-columns: 1fr; } }

/* ---------- 375 px polish for existing screens (COMPLETE-1 Y) */
.hero { flex-wrap: wrap; } .hero .tools { flex-wrap: wrap; justify-content: flex-end; } .hero .tools .btn { white-space: nowrap; font-size: 14px; padding: 6px 10px; }
.list .row > div { min-width: 0; } .list .cr, .cr { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 11px; color: var(--text-secondary); }
/* D203 care mode */
.cmode b { display: block; margin-bottom: 6px; } .cmode .cm-row { margin-top: 6px; } .cmode .chips { margin-top: 4px; gap: 6px; } .cmode.partial { border-left: 4px solid var(--accent); }
/* FINAL-1 F: conflicts said honestly; source details; legend */
.conf-note { font-size: 13px; color: var(--care-attention); margin-top: 4px; } .srcd { display: inline-block; margin-left: 6px; } .srcd summary { cursor: pointer; display: inline; } .wklegend { margin: 6px 2px 0; } .wklegend summary { cursor: pointer; }
/* FINAL-1 B/9: state in words next to every character state image */
.stcap { display: flex; align-items: flex-start; gap: 6px; font-size: 13px; line-height: 1.45; color: var(--text-secondary); margin-top: 6px; }
.stcap .dot { flex: 0 0 8px; height: 8px; margin-top: 6px; border-radius: 50%; background: var(--care-positive); }
.stcap.st-HOT .dot, .stcap.st-COLD .dot, .stcap.st-THIRSTY .dot, .stcap.st-TOO_WET .dot { background: var(--care-attention); } .stcap.st-RAIN .dot { background: #6E8FA8; } .stcap.st-SLEEPING .dot { background: var(--care-neutral); }
.calm figure { margin: 0; display: inline-flex; flex-direction: column; align-items: center; width: 44px; } .calm figure figcaption { font-size: 10px; color: var(--text-secondary); line-height: 1.2; text-align: center; }
.phero .stover { position: absolute; right: var(--s-3); bottom: calc(var(--s-3) + 60px); background: rgba(251,248,242,.94); color: var(--text-primary); font-size: 12px; padding: 2px 8px; border-radius: var(--radius-pill); }
.gstrip .chars span small { font: 400 10px/1 var(--font); color: var(--text-secondary); margin-left: 2px; }
/* FINAL-1 J: the capture box is never an empty black block */
.shot .shotguide { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; padding: 16px; text-align: center; color: #EDE7DC; font-size: 14px; background: radial-gradient(circle at 50% 40%, #2C3A31, #1F1E1B 70%); }
.shot .shotguide b { font-size: 16px; } .shot .shotguide span:not(.frame) { opacity: .8; }
.shot .shotguide .frame { width: 38%; aspect-ratio: 1; border: 2px dashed rgba(237,231,220,.55); border-radius: 18px; margin-bottom: 8px; }
.phero img.char ~ .over { padding-right: 78px; }
.ccard .noimg { display: flex; align-items: center; justify-content: center; height: 100%; font-size: 40px; background: radial-gradient(circle at 50% 40%, #25231C, #121210); }
.shot { max-height: 58vh; }
