/* Sections 03 and 04 (12 Nov).
   03 "Public and private credit": the two source panels (answers.js) on paper, with one big word under each.
   04 "Easy to use, works where you work": two dark panels, each a title, one line of text (05's style) and a graphic.
     Left: the platform window, a cursor clicking through its tabs.
     Right: CreditGPT and the firm's AI on a cable. The plug slides over and snaps home against CreditGPT, which
     flashes, a charge runs down the cable, and the AI wakes: its "Credit expertise" meter fills. Holds with a charge
     every so often, unplugs, repeats. Cable, plug and charge are an SVG over the stage, drawn by use-or-connect.js;
     phones stack the stage (CreditGPT above, the AI below).
   (Earlier versions of 04 are in snapshots/.) */
.pp2 .pp-side h3 { font-size: 40px; margin-bottom: 6px; }
.pp2 .pp-side p { max-width: 480px; }

.uc-sec { background: var(--soft); }
.uc-sec .sec-head { margin-bottom: 64px; }
.uc-slot { flex: 1; display: flex; min-width: 0; }
.uc-slot > * { flex: 1; min-width: 0; }

/* ---------- the two dark panels: title, one line, graphic ---------- */
.uc-split { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; } /* = 05's gap */
.uc-card { position: relative; display: flex; flex-direction: column; padding: 48px 48px 56px; border-radius: 6px; color: var(--paper);
  /* 05's sides and top; the bottom is 05's 40px plus the 12-16px its closing list rows add, since 04 ends on the window's hard edge */
  /* muted navy: the same grain as 05's cards, re-tinted (luminosity blend: the texture's light and dark, this colour's
     hue), so 04 is its own colour beside 05's slate and umber cards */
  background: #323a4c center / cover; background-blend-mode: luminosity; }
/* the texture loads only as the panel comes near the screen (app.js adds .near), as in 05 */
.uc-card.near { background-image: url(img/tex-cool-1200.webp); }
@media (max-width: 700px) { .uc-card.near { background-image: url(img/tex-cool-720.webp); } }
.uc-card h3 { font: 400 clamp(32px, 2.7vw, 38px)/1.08 var(--serif); letter-spacing: -.02em; margin-bottom: 14px; text-wrap: balance; }
.uc-card > p { font-size: 17px; line-height: 1.55; color: rgba(243,242,239,.86); margin-bottom: 32px; } /* = 05's card text */

/* ---------- left: the platform window ---------- */
.uc-app { position: relative; z-index: 3; background: #fbfaf7; color: var(--ink); border-radius: 4px; overflow: hidden; display: flex; flex-direction: column; box-shadow: 0 18px 40px rgba(0,0,0,.35); }
.uc-bar { display: flex; align-items: center; gap: 12px; height: 38px; padding: 0 14px; border-bottom: 1px solid var(--rule); background: #f0efeb; font: 500 12px var(--sans); color: var(--text-2); }
.uc-dots { display: flex; gap: 6px; }
.uc-dots i { width: 10px; height: 10px; border-radius: 50%; box-shadow: inset 0 0 0 .5px rgba(0,0,0,.12); }
.uc-dots i:nth-child(1) { background: #ff5f57; } /* macOS close, minimise, zoom */
.uc-dots i:nth-child(2) { background: #febc2e; }
.uc-dots i:nth-child(3) { background: #28c840; }
.uc-main { flex: 1; display: grid; grid-template-columns: 152px 1fr; min-height: 290px; }
.uc-side { list-style: none; padding: 14px 0; border-right: 1px solid var(--rule); background: #f6f5f2; }
.uc-side li { font: 400 12.5px/1.2 var(--sans); color: var(--text-2); padding: 8px 14px; border-left: 2px solid transparent; transition: background .3s, color .3s, border-color .3s; }
.uc-side li.on { background: #fbfaf7; color: var(--ink); font-weight: 500; border-left-color: var(--ink); }
.uc-views { position: relative; }
.uc-view { position: absolute; inset: 0; padding: 20px 22px; opacity: 0; transform: translateY(6px); transition: opacity .3s, transform .3s; display: flex; flex-direction: column; }
.uc-view.on { opacity: 1; transform: none; transition-delay: .3s; }
.uc-h { font: 400 20px/1.2 var(--serif); margin-bottom: 14px; }
.uc-t { width: 100%; border-collapse: collapse; font: 400 13px var(--sans); }
.uc-t th { font: 600 9.5px var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--text-2); text-align: right; padding: 0 0 8px; border-bottom: 1px solid var(--ink); }
.uc-t th:first-child, .uc-t td:first-child { text-align: left; }
.uc-t td { text-align: right; padding: 10px 0; border-bottom: 1px solid var(--rule); font-variant-numeric: tabular-nums; }
.uc-bars > div { margin-bottom: 14px; }
.uc-bars p { display: flex; justify-content: space-between; font: 400 13px var(--sans); margin-bottom: 6px; }
.uc-bars b { font-weight: 500; font-variant-numeric: tabular-nums; }
.uc-bars i { display: block; height: 8px; background: var(--ink); width: 0; transition: width .9s cubic-bezier(.3,.7,.2,1) .5s; }
.uc-view.on .uc-bars i { width: var(--w); }
.uc-moves { list-style: none; }
.uc-moves li { display: flex; justify-content: space-between; align-items: center; gap: 10px; font: 400 13px var(--sans); padding: 7px 0; border-bottom: 1px solid var(--rule); }
.uc-moves em { flex: none; font: 500 10.5px var(--sans); font-style: normal; padding: 3px 8px; border: 1px solid var(--rule-strong); color: var(--text-2); border-radius: 2px; }
.uc-moves em.open { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.uc-moves em.vote { border-color: var(--ink); color: var(--ink); }
.uc-cite { margin-top: auto; padding-top: 12px; display: flex; flex-wrap: wrap; gap: 6px; }
.uc-cite span { font: 500 10.5px/1 var(--mono); padding: 5px 8px; border: 1px solid var(--ink); border-radius: 2px; }
.uc-cursor { position: absolute; z-index: 3; left: 0; top: 0; width: 18px; height: 22px; pointer-events: none; transition: transform .7s cubic-bezier(.4,0,.2,1); filter: drop-shadow(0 2px 3px rgba(0,0,0,.25)); }
.uc-cursor svg { display: block; width: 100%; height: 100%; transition: transform .12s; transform-origin: 3px 3px; }
.uc-cursor.click svg { transform: scale(.82); }

/* ---------- right: CreditGPT | cable | the firm's AI ---------- */
.uc3-stage { position: relative; flex: 1; display: grid; grid-template-columns: 104px minmax(130px, 1fr) minmax(0, 260px); align-items: center; min-height: 290px; }
.uc3-wires { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; z-index: 2; }
.uc3-wires .cable { fill: none; stroke: #8f8e8a; stroke-width: 3; stroke-linecap: round; transition: stroke .4s; }
.uc3-wires .cable.live { stroke: #c9c8c4; }
.uc3-wires .charge { fill: none; stroke: #fbfaf7; stroke-width: 5; stroke-linecap: round; filter: drop-shadow(0 0 4px rgba(251,250,247,.9)); }
.uc3-wires .relief { fill: #c9c8c4; stroke: var(--ink); stroke-width: .8; }
.uc3-wires .plug-body { fill: #fbfaf7; stroke: var(--ink); stroke-width: 1.2; }
.uc3-wires .grip { stroke: #b4b3af; stroke-width: 1.4; stroke-linecap: round; }
.uc3-wires .prong { fill: #d6d5d1; stroke: var(--ink); stroke-width: .8; }

/* CreditGPT: the plug seats against its rim, prongs tucked under */
.uc3-hub { grid-column: 1; position: relative; z-index: 3; width: 104px; height: 104px; border-radius: 50%; background: var(--paper); color: var(--ink);
  display: grid; place-items: center; font: 400 17px var(--serif); box-shadow: 0 0 0 8px rgba(243,242,239,.08), 0 0 0 8px rgba(243,242,239,0);
  transition: box-shadow 1.1s cubic-bezier(.2,.7,.3,1); }
/* connected: the glow eases up from the moment the plug lands and eases back down when it is pulled (one transition,
   no hand-off between animations), and a faint halo breathes around it while it stays plugged in */
.uc3-hub.live { box-shadow: 0 0 0 8px rgba(243,242,239,.16), 0 0 0 22px rgba(243,242,239,.06); }
.uc3-hub::before, .uc3-hub::after { content: ""; position: absolute; inset: 0; border-radius: 50%; pointer-events: none; }
.uc3-hub::before { inset: -30px; border: 1px solid rgba(243,242,239,.2); opacity: 0; transition: opacity 1.2s ease; animation: uc3-breathe 3.2s ease-in-out infinite alternate; }
.uc3-hub.live::before { opacity: 1; }
@keyframes uc3-breathe { from { transform: scale(.94); } to { transform: scale(1.06); } }
/* the snap: one ring bursts out from the rim and fades to nothing, then rests invisible */
.uc3-hub::after { border: 2px solid rgba(243,242,239,.75); opacity: 0; }
.uc3-hub.snap::after { animation: uc3-burst 1.2s cubic-bezier(.15,.6,.3,1) forwards; }
@keyframes uc3-burst { from { opacity: .9; transform: scale(1); } to { opacity: 0; transform: scale(1.75); } }

/* the firm's AI: name, the models, and its credit expertise */
.uc3-ai { grid-column: 3; position: relative; z-index: 3; display: flex; flex-direction: column; gap: 4px; background: #fbfaf7; color: var(--ink); border-radius: 4px; padding: 22px 22px 20px;
  box-shadow: 0 18px 40px rgba(0,0,0,.35); opacity: .8; transition: opacity .5s, box-shadow .6s; }
.uc3-ai.on { opacity: 1; box-shadow: 0 18px 40px rgba(0,0,0,.35), 0 0 0 3px rgba(243,242,239,.22); }
.uc3-ai b { font: 400 23px/1.15 var(--serif); margin-bottom: 10px; }
.uc3-badges { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 18px; }
.uc3-badges span { font: 500 12px/1 var(--sans); padding: 6px 10px; border-radius: 999px; background: #ecebe7; color: var(--ink); }
.uc3-meter { display: flex; flex-direction: column; gap: 8px; }
.uc3-bar { display: block; height: 8px; border-radius: 4px; background: #e3e2de; overflow: hidden; }
.uc3-bar i { display: block; height: 100%; width: 14%; border-radius: 4px; background: #9b9a96; transition: width 1.2s cubic-bezier(.3,.7,.2,1), background .4s; }
.uc3-ai.on .uc3-bar i { width: 100%; background: var(--ink); }
.uc3-lvl { font: 600 10.5px/1 var(--sans); font-style: normal; letter-spacing: .1em; text-transform: uppercase; color: #9b9a96; transition: color .3s; }
.uc3-ai.on .uc3-lvl { color: var(--ink); }

@media (max-width: 1240px) { .uc-main { grid-template-columns: 146px 1fr; } }
/* below 1080px two panels side by side are too narrow for the graphics at 05's padding: the panels stack */
@media (max-width: 1080px) {
  .uc-split { grid-template-columns: 1fr; }
  .uc-main { grid-template-columns: 150px 1fr; }
  .uc3-stage { grid-template-columns: 112px minmax(150px, 1fr) minmax(0, 280px); }
  .uc3-hub { width: 112px; height: 112px; font-size: 18px; }
}
@media (max-width: 900px) {
  .uc-br { display: none; }
  .pp2 .pp-side h3 { font-size: 32px; }
}
@media (max-width: 560px) {
  .uc-card { padding: 32px 24px 36px; } /* 05's phone padding, plus its list rows' space at the bottom */
  .uc-card h3 { font-size: 30px; }
  .uc-card > p { font-size: 16px; margin-bottom: 24px; }
  .uc-main { grid-template-columns: 1fr; min-height: 0; }
  .uc-side { display: flex; overflow: hidden; padding: 0; border-right: 0; border-bottom: 1px solid var(--rule); }
  .uc-side li { flex: none; padding: 10px 12px; border-left: 0; border-bottom: 2px solid transparent; }
  .uc-side li:not([data-v]) { display: none; }
  .uc-side li.on { border-bottom-color: var(--ink); }
  .uc-views { min-height: 290px; }
  /* phone: the stage stacks, CreditGPT above the AI, the cable running up between them */
  .uc3-stage { grid-template-columns: 1fr; grid-template-rows: auto 128px auto; justify-items: center; min-height: 0; }
  .uc3-hub { grid-column: 1; grid-row: 1; }
  .uc3-ai { grid-column: 1; grid-row: 3; width: 100%; }
}
