/* Perfectionism lesson. All rules scoped under .pfx-* */

.pfx-sc { position: relative; width: 100%; display: flex; flex-direction: column; align-items: center; gap: 12px; }
.pfx-hero { width: min(80%, 320px); }
.pfx-hero img { width: 100%; display: block; }

/* the circle */
.pfx-pad { width: 240px; height: 240px; border-radius: 20px; background: #F3EBDD; box-shadow: inset 0 0 0 2px rgba(0, 0, 0, .06); }
.pfx-cv { display: block; width: 240px; height: 240px; touch-action: none; cursor: crosshair; }
.pfx-pad canvas { filter: drop-shadow(0 1px 0 rgba(0, 0, 0, .25)); }
.pfx-read { display: flex; gap: 12px; align-items: baseline; justify-content: center; min-height: 26px; font-size: 13px; font-weight: 700; color: var(--dim); }
.pfx-read b { font: 800 20px var(--serif); color: var(--gold); }
.pfx-read.pfx-warn .pfx-hint { color: #F07A7E; }

/* Maya's 40 tries */
.pfx-grid { display: grid; grid-template-columns: repeat(10, minmax(0, 24px)); gap: 7px; justify-content: center; margin-top: 8px; }
.pfx-grid i { display: block; height: 24px; border-radius: 50%; border: 2px dashed var(--line-strong); transition: background .15s, border-color .15s; }
.pfx-grid i.pfx-fail { border: 2px solid rgba(229, 72, 77, .7); background: rgba(229, 72, 77, .18); }
.pfx-grid i.pfx-pass { border: 2px solid var(--gold); background: var(--gold); box-shadow: 0 0 10px rgba(252, 192, 80, .6); }

/* two halves */
.pfx-halves { width: 100%; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 8px; }
.pfx-half { display: flex; flex-direction: column; gap: 6px; align-items: center; justify-content: center; text-align: center; min-height: 130px; padding: 14px 10px; border-radius: 18px; background: rgba(252, 192, 80, .1); border: 2px solid var(--gold); }
.pfx-half b { font: 700 18px var(--serif); line-height: 1.15; }
.pfx-half span { font-size: 14px; color: var(--dim); line-height: 1.3; }
.pfx-half.pfx-fear { background: rgba(229, 72, 77, .1); border-color: var(--red); }

/* first try */
.pfx-first { width: 100%; display: flex; justify-content: center; padding: 8px 0; }
.pfx-draft { width: 220px; display: flex; flex-direction: column; gap: 9px; padding: 16px 18px; border-radius: 12px; background: #F3EBDD; color: #2A2216; transform: rotate(-2deg); box-shadow: 0 6px 16px rgba(0, 0, 0, .35); }
.pfx-draft b { font: 700 17px var(--serif); }
.pfx-draft i { display: block; height: 6px; border-radius: 3px; background: #B9AC95; }
.pfx-draft i:nth-of-type(2) { width: 80%; }
.pfx-draft i:nth-of-type(4) { width: 90%; }
.pfx-draft i.pfx-bad { background: #D0383E; width: 70%; }
.pfx-draft span { font-size: 13px; font-weight: 700; color: #B0343A; }

.pfx-q { width: 100%; display: flex; flex-direction: column; gap: 6px; align-items: center; text-align: center; padding: 18px 16px; margin-top: 8px; border-radius: 18px; background: var(--surface); border: 2px solid var(--line); }
.pfx-q b { font: 700 19px var(--serif); }
.pfx-q span { font-size: 14px; color: var(--dim); }

@media (max-height: 700px) {
  .pfx-hero { width: min(62%, 240px); }
  .pfx-pad, .pfx-cv { width: 210px; height: 210px; }
  .pfx-half { min-height: 110px; }
  .pfx-first { margin-top: 0; }
  .pfx-draft { gap: 7px; padding: 12px 16px; }
}
