/* Tree & Tale site. Design system "Tree & Tale" (Garden theme): a calm cream page, forest ink, one line-drawn oak.
   Tokens below carry the design system's names and values; the old names (wall, mat, rule, dot) are kept as aliases
   so the markup built by app.js keeps working.
   Scale: the chart maker is a little denser than the design system's Easy sizes (16 px text, 48 px controls),
   so the step, the preview and Back / Continue fit one screen. */
:root {
  /* colour: Tree & Tale, Garden */
  --page: #fbf3e0; --band: #f1e4c0; --card: #fffaf0; --hairline: #e3d3a8;
  --ink: #17352a; --ink-soft: #4d6458;
  --brand: #1f4d3a; --on-brand: #fbf3e0; --accent: #b83f25; --on-accent: #fffaf0;
  --saffron: #f2b134; --on-saffron: #17352a; --leaf: #6aa56a; --on-leaf: #17352a;
  --control-border: #1f4d3a; --focus: #b83f25; --positive: #1f4d3a; --danger: #b83f25;
  --disabled-bg: #e9dfc6; --disabled-ink: #5f7368;
  --chart-paper: #fffaf0; --chart-ink: #1f4d3a; --frame-forest: #1f4d3a; --frame-walnut: #4a3426;
  /* type */
  --font-display: 'Fraunces', Georgia, 'Heebo', serif;
  --font-text: 'DM Sans', 'Heebo', system-ui, sans-serif;
  --font-logo: 'Marcellus', Georgia, serif;
  --font-tag: 'Jost', 'DM Sans', sans-serif;
  /* space, radius, size */
  --space-1: 4px; --space-2: 8px; --space-3: 12px; --space-4: 16px; --space-card: 22px; --space-5: 24px; --space-6: 32px; --space-7: 48px; --space-8: 64px;
  --radius-frame: 6px; --radius-input: 14px; --radius-card: 20px; --radius-pill: 999px;
  --content-max: 1120px; --read-max: 640px; --frame-pad: 14px;
  --shadow-frame: 0 16px 28px #00000030; --shadow-card: 0 1px 2px #17352a26;
  /* the site's density: controls 48 px (52 px for the one primary action) */
  --target: 48px; --target-primary: 52px;
  /* aliases for the class names app.js writes */
  --wall: var(--page); --wall-alt: var(--band); --mat: var(--card); --rule: var(--hairline); --rule-strong: var(--control-border);
  --dot: var(--brand); --on-dot: var(--on-brand); --dot-soft: var(--band);
  --display: var(--font-display); --serif: var(--font-display); --text: var(--font-text); --brandface: var(--font-logo); --mono: var(--font-text);
  --r: var(--radius-input);
  --card-shadow: var(--shadow-card); --frame-shadow: var(--shadow-frame);
  color-scheme: light;
}
* { box-sizing: border-box }
[hidden] { display: none !important }
body { margin: 0; background: var(--page); color: var(--ink); font: 400 1rem/1.5 var(--font-text); padding: 0 max(20px, env(safe-area-inset-right)) 40px max(20px, env(safe-area-inset-left)) }
a { color: var(--brand) }
a:hover { color: var(--accent) }
p { margin: 0 }
h1 { font: 600 clamp(36px, 5vw, 56px)/1.06 var(--font-display); letter-spacing: -0.01em; margin: 10px 0 16px; color: var(--ink) }
h2 { margin: 0; font: 600 1.25rem/1.3 var(--font-display); display: flex; align-items: center; gap: 12px }
.kicker { font: 700 0.875rem/1.25rem var(--font-text); letter-spacing: .14em; text-transform: uppercase; color: var(--accent) }
.lead { font-size: 1.125rem; line-height: 1.6; color: var(--ink-soft); max-width: 36em }
.muted { color: var(--ink-soft) } .small { font-size: 0.9375rem; line-height: 1.5 }
.data { font: 400 0.9375rem/1.4rem var(--font-text); color: var(--ink) }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0) }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px }

/* header: the horizontal logo lockup, a quiet line under it */
.top { display: flex; align-items: center; justify-content: space-between; gap: 12px 16px; flex-wrap: wrap; padding: 14px 0 12px; max-width: 1400px; margin: 0 auto 8px; border-bottom: 1px solid var(--hairline) }
.brand { display: flex; align-items: center; gap: 10px; color: var(--brand); text-decoration: none }
.brand:hover { color: var(--brand) }
.mk { width: 40px; height: 40px; flex: none }
.wm { font: 400 1.125rem/1 var(--font-logo); letter-spacing: .24em; white-space: nowrap; color: var(--brand) }
.pill { display: inline-flex; align-items: center; gap: 8px; font: 700 0.875rem/1.2 var(--font-text); color: var(--ink); padding: 6px 14px; border: 2px solid var(--leaf); border-radius: var(--radius-pill); background: var(--card) }
.pill::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--leaf); flex: none }
.navLink { display: inline-flex; align-items: center; min-height: 40px; padding: 0 2px; border: 0; background: none; color: var(--ink); font: 700 0.9375rem/1.2 var(--font-text); text-decoration: none; cursor: pointer }
.navLink:hover { color: var(--accent); text-decoration: underline; text-underline-offset: 4px }
.topnav { display: flex; align-items: center; gap: 18px; margin-left: auto }

/* buttons: pills. primary = forest fill, one per screen; secondary (.quiet) = outlined; .ink = forest fill for a secondary step */
.primary, .ink, .quiet { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: var(--target); padding: 0 22px; border-radius: var(--radius-pill); border: 2px solid var(--brand); font: 700 1rem/1.2 var(--font-text); cursor: pointer; text-decoration: none; white-space: nowrap }
.primary { background: var(--brand); color: var(--on-brand); min-height: var(--target-primary); padding: 0 28px; font-size: 1.0625rem }
.primary:hover { background: #17352a; border-color: #17352a; color: var(--on-brand) }
.ink { background: var(--brand); color: var(--on-brand) }
.ink:hover { background: #17352a; border-color: #17352a; color: var(--on-brand) }
.quiet { background: transparent; color: var(--brand); position: relative }
.quiet:hover { background: var(--card); color: var(--brand) }
.quiet.sm { min-height: 40px; padding: 0 16px; font-size: 0.9375rem }
.primary:disabled, .ink:disabled { background: var(--disabled-bg); border-color: var(--disabled-bg); color: var(--disabled-ink); cursor: not-allowed }
.quiet:disabled { border-color: var(--disabled-ink); color: var(--disabled-ink); cursor: not-allowed }
.wide { width: 100% }
.ic { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round }
button.link { background: none; border: 0; padding: 6px 2px; color: var(--brand); font: 700 0.9375rem/1.2 var(--font-text); cursor: pointer; text-decoration: underline; text-underline-offset: 4px }
.link { font-weight: 700; text-underline-offset: 4px }
.link:hover, button.link:hover { color: var(--accent) }

/* landing (the upload, also step 1 of the maker) */
.hero { max-width: 760px; margin: 0 auto; padding: 6vh 0 4vh }
/* the upload zone: a dashed saffron panel with the oak */
.drop { position: relative; display: grid; justify-items: center; gap: 6px; border: 3px dashed var(--saffron); border-radius: var(--radius-card); padding: 28px 24px 26px; margin: 28px 0 14px; cursor: pointer; text-align: center; background: var(--card) }
.drop::before { content: ''; width: 56px; height: 56px; margin-bottom: 4px; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='18 26 164 164'%3E%3Cg transform='translate(0 -6)' fill='none' stroke='%231f4d3a' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M97 134C88 126 72 128 60 121C52 116 48 110 46 102'/%3E%3Cpath d='M99 126C93 113 82 106 74 97C69 91 67 85 67 77'/%3E%3Cpath d='M100 127C100 112 105 99 103 86C102 78 99 72 97 64'/%3E%3Cpath d='M101 123C108 111 118 104 126 94C130 88 132 82 131 75'/%3E%3Cpath d='M103 134C114 126 130 127 142 121C150 117 155 111 157 104'/%3E%3Cpath d='M118 104C126 105 134 101 140 94'/%3E%3Cpath d='M86 158C93 154 96 147 97 134'/%3E%3Cpath d='M114 158C107 154 104 147 103 134'/%3E%3Cpath d='M97 134C98 131 99 129 100 127'/%3E%3Cpath d='M103 134C102 131 101 129 100 127'/%3E%3Cpath d='M74 158H128'/%3E%3C/g%3E%3C/svg%3E") no-repeat center / contain }
.drop strong { display: inline-flex; align-items: center; min-height: var(--target-primary); padding: 0 28px; margin: 4px 0; border-radius: var(--radius-pill); background: var(--brand); color: var(--on-brand); font: 700 1.0625rem/1.2 var(--font-text) }
.drop span { color: var(--ink-soft) }
.drop.over, .drop:hover { border-style: solid; background-color: #fff6df }
.drop:hover strong, .drop.over strong { background: #17352a }
.drop:focus-within { outline: 3px solid var(--focus); outline-offset: 3px }
.drop input, .quiet input { position: absolute; width: 1px; height: 1px; opacity: 0; overflow: hidden }
.samples { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 18px 0 14px; color: var(--ink-soft); font-size: 1rem }
.chip { min-height: 44px; padding: 0 18px; border: 2px solid var(--control-border); border-radius: var(--radius-pill); background: var(--card); color: var(--ink); font: 700 0.9375rem/1 var(--font-text); cursor: pointer }
.chip:hover { background: var(--brand); color: var(--on-brand) }
.hero > .small { margin-top: 8px }
.resume { display: flex; align-items: center; justify-content: space-between; gap: 16px 24px; flex-wrap: wrap; margin: 28px 0 -12px; padding: 16px var(--space-card); background: var(--card); border: 1px solid var(--hairline); border-top: 6px solid var(--leaf); border-radius: var(--radius-card) }
.resume .ltitle { margin-top: 2px }
/* On a computer the whole home page fits one screen: the vertical spacing shrinks with the window's height. */
@media (min-width: 821px) {
  body:not(.app) { padding-bottom: clamp(12px, 3vh, 40px) }
  body:not(.app):has(> #appView) { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column }
  body:not(.app) > #appView:not([hidden]) { flex: 1 0 auto; display: flex; flex-direction: column; justify-content: center; padding-bottom: max(0px, calc(10vh - 70px)) }
  body:not(.app) > .top, body:not(.app) > main > .hero { width: 100% }
  body:not(.app) .top { padding: clamp(10px, 2vh, 16px) 0 clamp(10px, 1.8vh, 14px) }
  .hero { padding: clamp(10px, 4vh, 56px) 0 clamp(6px, 2vh, 28px) }
  .hero h1 { font-size: clamp(36px, min(5.5vw, 8vh), 56px); margin: clamp(4px, 1vh, 10px) 0 clamp(8px, 2vh, 16px) }
  .hero .lead { line-height: 1.5 }
  .drop { padding: clamp(14px, 3vh, 28px) 24px; margin: clamp(14px, 3vh, 28px) 0 12px }
  .resume { margin: clamp(14px, 3vh, 28px) 0 clamp(-12px, -1vh, -4px); padding: clamp(10px, 1.8vh, 16px) var(--space-card) }
  .samples { margin: clamp(10px, 2vh, 18px) 0 clamp(6px, 1.4vh, 14px) }
}

/* workspace: one screen, no page scroll. The settings scroll; the preview always fits. */
body.app { height: 100vh; height: 100dvh; overflow: hidden; display: flex; flex-direction: column; padding: 0 }
body.app .top { flex: none; width: calc(100% - 40px); padding: 8px 0 8px; margin: 0 auto }
body.app .mk { width: 34px; height: 34px }
body.app .wm { font-size: 1rem }
body.app #appView { flex: 1 1 auto; min-height: 0; display: flex }
.work { flex: 1 1 auto; min-height: 0; width: 100%; max-width: 1440px; margin: 0 auto; padding: 0 20px; display: grid; grid-template-columns: minmax(320px, 420px) minmax(0, 1fr); grid-template-rows: minmax(0, 1fr) auto; grid-template-areas: "panel stage" "panel cta"; column-gap: 28px }
.panel, .panel * { overflow-wrap: anywhere }
.panel .step > *, .plist [role=option] > * { min-width: 0 }
.panel { grid-area: panel; min-height: 0; min-width: 0; overflow-y: auto; overscroll-behavior: contain; padding: 0 14px 24px 4px; scrollbar-gutter: stable }
.stage { grid-area: stage; min-height: 0; min-width: 0; display: flex; flex-direction: column; padding-top: 12px }
.step { padding-block: 20px; border-bottom: 1px solid var(--hairline); display: grid; gap: 10px }
.step.last { border-bottom: 0 }
.lbl { font: 700 0.9375rem/1.25rem var(--font-text); color: var(--ink); display: flex; justify-content: space-between; align-items: baseline }
.lbl b { font: 700 0.9375rem/1 var(--font-text); color: var(--ink) }
select, textarea { width: 100%; font: 1rem/1.4 var(--font-text); color: var(--ink); background: var(--card); border: 2px solid var(--control-border); border-radius: var(--radius-input); padding: 10px 14px; min-height: var(--target) }
input[type=text], input[type=search], input[type=email] { width: 100%; font: 1rem/1.4 var(--font-text); color: var(--ink); background: var(--card); border: 2px solid var(--control-border); border-radius: var(--radius-input); padding: 10px 14px; min-height: var(--target) }
::placeholder { color: #5f7368; opacity: 1 }
/* the people list: our own list, not a native one, so the chosen name always reads clearly */
.plist { position: relative; list-style: none; margin: 0; padding: 4px; max-height: 284px; overflow-y: auto; overscroll-behavior: contain; background: var(--card); border: 2px solid var(--control-border); border-radius: var(--radius-input) }
.plist:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px }
.plist .pg { font: 700 0.75rem/1.4 var(--font-text); letter-spacing: .14em; text-transform: uppercase; color: var(--ink-soft); padding: 10px 10px 4px }
.plist [role=option] { display: flex; align-items: baseline; gap: 4px 10px; flex-wrap: wrap; min-height: 44px; padding: 9px 12px; border-radius: 10px; cursor: pointer; color: var(--ink) }
.plist [role=option]:hover { background: var(--band) }
.plist [role=option][aria-selected=true] { background: var(--brand); color: var(--on-brand); font-weight: 700 }
.plist [role=option][aria-selected=true] .pm { color: var(--on-brand) }
.plist .pm { font: 400 0.875rem/1.3 var(--font-text); color: var(--ink-soft) }
.plist .none { padding: 12px 10px; color: var(--ink-soft) }
input[type=range] { width: 100%; accent-color: var(--brand); min-height: 36px }
.focus { background: var(--card); border: 1px solid var(--hairline); border-top: 6px solid var(--saffron); border-radius: var(--radius-card); padding: 12px 16px; display: grid; gap: 2px }
.focus strong { font: 600 1.25rem/1.3 var(--font-display) }
.note { margin: 8px 0 0; font-size: 0.9375rem; color: var(--ink); border-top: 1px solid var(--hairline); padding-top: 8px }
.photos { display: grid; gap: 10px; justify-items: start }
progress { width: 100%; height: 6px; accent-color: var(--brand) }
.cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px }
/* choices are tiles; the chosen one has a forest border and a check badge */
.card { position: relative; text-align: left; background: var(--card); border: 2px solid var(--control-border); border-radius: var(--radius-card); padding: 12px; font: inherit; color: var(--ink); cursor: pointer; display: grid; gap: 4px; align-content: start; min-height: var(--target) }
.card:hover { box-shadow: var(--shadow-card); background: #fffdf6 }
.card:disabled { opacity: .5; cursor: default; box-shadow: none }
.card.on { border: 4px solid var(--brand); padding: 10px }
.card.on::after { content: ''; position: absolute; top: -11px; right: -11px; width: 28px; height: 28px; border-radius: var(--radius-pill); background: var(--brand) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fbf3e0' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") no-repeat center / 18px }
.cn { font: 700 1rem/1.3 var(--font-text); display: flex; gap: 6px; flex-wrap: wrap; align-items: center; padding-right: 18px }
.cn em { font: 700 0.75rem/1 var(--font-text); letter-spacing: .06em; text-transform: uppercase; font-style: normal; color: var(--ink); border: 1.5px solid var(--ink); padding: 3px 7px; border-radius: 99px }
.cb { font-size: 0.875rem; color: var(--ink-soft); line-height: 1.4 }
.theme .sw { position: relative; aspect-ratio: 1.414; display: flex; align-items: flex-end; gap: 5px; padding: 8px; border-radius: 10px; overflow: hidden; background: var(--band) }
.theme .sw img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block }
.theme .sw i { width: 16px; height: 16px; border-radius: 50% }
.theme .sw img ~ i { display: none }
.theme .tn { font: 700 1rem/1.25 var(--font-text); padding-right: 18px }
/* the chosen chart's options sit open under the list of charts */
.opts { display: grid; gap: 10px; background: var(--card); border: 1px solid var(--hairline); border-top: 6px solid var(--leaf); border-radius: var(--radius-card); padding: 14px 16px 14px }
.optsH { font: 600 1.125rem/1.3 var(--font-display) }
.opts .check { padding-block: 2px }
.opts .row2 { grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)) }
.row2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px }
.row2 > div { display: grid; gap: 6px; min-width: 0 }
.check { display: flex; gap: 10px; align-items: flex-start; cursor: pointer; padding-block: 4px }
.check input { width: 22px; height: 22px; accent-color: var(--brand); flex: none; margin-top: 1px }
.forget { margin: 8px 0 4px }
.forget button.link { font-size: inherit; padding: 0 }
/* errors say so in words, with the warning colour as a frame, never colour alone */
.error { color: var(--ink); font-weight: 700; background: var(--card); border: 2px solid var(--danger); border-radius: var(--radius-input); padding: 10px 14px }
.warn { margin: 0 0 12px; background: var(--card); color: var(--ink); padding: 12px 16px; border: 1px solid var(--hairline); border-radius: var(--radius-input) }

/* the preview: a framed chart on the wall, sized by app.js to fit the space whatever its shape */
.wall { position: relative; flex: 1 1 auto; min-height: 0; display: grid; place-items: center; overflow: hidden; background: var(--band); padding: 24px; border-radius: var(--radius-card) }
.frame { --mat-pad: 12px; position: relative; overflow: hidden; background: var(--chart-paper); border: var(--frame-pad) solid var(--frame-forest); border-radius: var(--radius-frame); padding: var(--mat-pad); box-shadow: var(--shadow-frame); max-width: 100%; max-height: 100% }
.frame { transform-origin: 0 0 } .frame.glide { transition: transform .25s ease }
.sheetBox { position: relative }
.frame img { display: block; width: 100%; height: auto; user-select: none; -webkit-user-drag: none; -webkit-touch-callout: none }
.frame #hires { position: absolute; pointer-events: none }
.wall { touch-action: none; cursor: default; user-select: none; -webkit-user-select: none }
.wall.zoomed { cursor: grab } .wall.dragging { cursor: grabbing }
.wall:focus-visible { outline-offset: -3px }
.zbar { position: absolute; right: 12px; bottom: 12px; display: flex; background: var(--card); border: 2px solid var(--control-border); border-radius: var(--radius-pill); overflow: hidden; box-shadow: var(--shadow-card); z-index: 2 }
.zbar button { min-width: 48px; min-height: 44px; border: 0; background: none; color: var(--ink); font: 700 1.25rem/1 var(--font-text); cursor: pointer; padding: 0 10px }
.zbar button + button { border-left: 1px solid var(--hairline) }
.zbar .zfit { font: 700 0.9375rem/1 var(--font-text); min-width: 60px }
.zbar button:disabled { color: var(--disabled-ink); cursor: default }
.zbar button:not(:disabled):hover { background: var(--band) }
.zhint { position: absolute; left: 12px; bottom: 12px; max-width: calc(100% - 210px); font: 400 0.875rem/1.3 var(--font-text); color: var(--ink-soft); background: #fffaf0e0; padding: 6px 12px; border-radius: var(--radius-pill); pointer-events: none; z-index: 2 }
@media (hover: none) { .zhint { font-size: 0.8125rem } }
.zhint { transition: opacity .6s ease } .zhint.gone { opacity: 0 }
@media (prefers-reduced-motion: reduce) { .frame.glide { transition: none } }
.busy { position: absolute; inset: 0; display: grid; place-items: center; background: #fffaf0a0 }
.ltitle { font: 600 1.5rem/1.2 var(--font-display) }
.spinner { width: 36px; height: 36px; border-radius: 50%; border: 3px solid var(--hairline); border-top-color: var(--brand); animation: spin 0.9s linear infinite; margin: 16px auto }
@keyframes spin { to { transform: rotate(360deg) } }

/* the small loader: the Line oak draws itself, then fades, and starts again */
.mkload { width: 72px; height: 72px; overflow: visible; color: var(--brand) }
.mkload path { stroke-dasharray: 1; stroke-dashoffset: 1; animation: oakLoop 2.4s ease-in-out infinite }
.mkload .lf { animation-name: leafLoop }
@keyframes oakLoop { 0% { stroke-dashoffset: 1; opacity: 1 } 45%, 80% { stroke-dashoffset: 0; opacity: 1 } 100% { stroke-dashoffset: 0; opacity: 0 } }
@keyframes leafLoop { 0%, 35% { stroke-dashoffset: 1; opacity: 1 } 60%, 80% { stroke-dashoffset: 0; opacity: 1 } 100% { stroke-dashoffset: 0; opacity: 0 } }

/* fixing a person: highlight on the chart, the editor card, the check-names list */
.stage { position: relative }
.hl { position: absolute; pointer-events: none; border: 2px solid var(--brand); border-radius: 6px; background: #1f4d3a10 }
.hl.sel { border: 2.5px solid var(--accent); background: #b83f2512; box-shadow: 0 0 0 3px #fffaf0cc }
.wall.overPerson:not(.dragging) { cursor: pointer }
.checkBtn { position: absolute; top: 12px; right: 12px; z-index: 2; display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 16px; background: var(--card); color: var(--brand); border: 2px solid var(--control-border); border-radius: var(--radius-pill); box-shadow: var(--shadow-card); font: 700 0.9375rem/1 var(--font-text); cursor: pointer }
.checkBtn:hover { background: #fffdf6 }
.checkBtn b { min-width: 24px; height: 24px; padding: 0 7px; border-radius: 99px; background: var(--accent); color: var(--on-accent); font: 700 0.875rem/1.5rem var(--font-text); text-align: center }
.toast { position: absolute; left: 50%; bottom: 68px; transform: translateX(-50%); z-index: 30; display: flex; align-items: center; gap: 14px; max-width: calc(100% - 24px); padding: 10px 18px; background: var(--ink); color: var(--page); border-radius: var(--radius-input); box-shadow: 0 8px 24px #17352a40; font-size: 0.9375rem }
.toast button.link { color: var(--saffron); padding: 4px 2px }
.card2 { position: absolute; z-index: 5; top: 24px; right: 14px; width: min(400px, calc(100% - 28px)); max-height: calc(100% - 40px); overflow-y: auto; overscroll-behavior: contain; display: grid; gap: 10px; padding: 16px 18px 18px; background: var(--page); border: 1px solid var(--hairline); border-radius: var(--radius-card); box-shadow: 0 18px 48px #17352a40 }
.c2head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: -6px -8px -4px 0 }
.c2head .x { position: static; width: 44px; height: 44px }
.c2title { font: 600 1.5rem/1.2 var(--font-display) }
.note2 { font-size: 0.9375rem; line-height: 1.45; color: var(--ink); background: var(--card); border: 2px solid var(--danger); border-radius: var(--radius-input); padding: 8px 12px }
.editor .row2 > div { gap: 4px }
.card2 > *, .c2btns > * { min-width: 0 } .c2title, #edFile, .note2 { overflow-wrap: anywhere }
input[aria-invalid=true] { border-color: var(--danger); border-width: 3px }
.c2btns { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin-top: 4px }
.c2btns .ink { min-width: 120px }
.clList { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px }
.clList button { width: 100%; text-align: left; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 12px; padding: 10px 14px; min-height: 48px; background: var(--card); border: 2px solid var(--hairline); border-radius: var(--radius-input); color: var(--ink); font: inherit; cursor: pointer }
.clList button:hover { border-color: var(--control-border) }
.cln { font-weight: 700; overflow-wrap: anywhere } .cln em { font: 700 0.6875rem/1 var(--font-text); font-style: normal; text-transform: uppercase; letter-spacing: .06em; border: 1.5px solid var(--positive); color: var(--positive); padding: 2px 6px; border-radius: 99px; margin-left: 6px; vertical-align: 2px }
.cly { font: 400 0.875rem/1.5 var(--font-text); color: var(--ink-soft) }
.clf { grid-column: 1 / -1; font-size: 0.875rem; color: var(--accent); font-weight: 700 }
@media (max-width: 820px) {
  .card2 { position: fixed; top: auto; left: 0; right: 0; bottom: 0; width: auto; max-height: 74vh; max-height: 74dvh; z-index: 20; border-radius: var(--radius-card) var(--radius-card) 0 0; padding: 14px 16px calc(18px + env(safe-area-inset-bottom)) }
  .checkBtn { top: 8px; right: 8px; min-height: 40px; font-size: 0.875rem }
  .toast { bottom: 64px; font-size: 0.875rem }
}

.terms { font-size: 0.8125rem; line-height: 1.45; color: var(--ink-soft) }
.terms a { color: var(--brand); font-weight: 700 }
@media (max-width: 820px) {
  body.app .top { width: auto; margin: 0; padding: 6px 14px; flex-wrap: nowrap } body.app .pill { display: none }
  body.app .wm { font-size: 0.9375rem; letter-spacing: .2em }
  body.app #coffeeTop { display: none }
  .top, .topnav { min-width: 0 } .topnav { gap: 12px }
  .work { padding: 0; grid-template-columns: minmax(0, 1fr); grid-template-rows: minmax(0, 1fr) auto auto; grid-template-areas: "stage" "panel" "cta" }
  .stage { padding: 0 } .wall { border-radius: 0; padding: 14px } .warn { margin: 0; border-width: 0 0 1px; border-radius: 0; font-size: 0.9375rem }
  dialog.get, dialog.fb { padding: 28px 18px 22px } dialog.get h2 { font-size: 1.625rem }
}

/* dialogs: a card on the page colour, round corners, a quiet shadow */
dialog.get, dialog.fb { width: min(540px, calc(100vw - 24px)); max-height: calc(100vh - 24px); border: 1px solid var(--hairline); border-radius: var(--radius-card); padding: 30px 28px 26px; background: var(--page); color: var(--ink); box-shadow: 0 30px 80px #17352a59 }
dialog::backdrop { background: #17352a99 }
dialog.get h2, dialog.fb h2 { font: 600 1.875rem/1.15 var(--font-display); margin: 4px 0 8px }
.pane { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px }
.pane .primary, .pane .ink { white-space: normal; text-align: center; line-height: 1.25; padding-block: 8px }
.x { position: absolute; top: 10px; right: 10px; width: 44px; height: 44px; border: 0; border-radius: var(--radius-pill); background: none; font: 400 1.75rem/1 var(--font-text); color: var(--ink); cursor: pointer; z-index: 1 }
.x:hover { background: var(--band) }
.x.light { background: var(--card); top: 14px; right: 14px }
.box { border-top: 1px solid var(--hairline); padding-top: 14px; display: grid; gap: 10px; margin-top: 4px }
.bh { display: flex; align-items: center; gap: 10px; font: 600 1.125rem/1.3 var(--font-display) }
.bh .ic { color: var(--brand) }
.inl { display: flex; gap: 8px }
.inl input { flex: 1 1 auto; min-width: 0 }
.shares { display: flex; flex-wrap: wrap; gap: 8px }
.shares .quiet { min-height: 44px; padding: 0 16px; font-size: 0.9375rem }
.thanks { display: grid; gap: 8px; border-top: 1px solid var(--hairline); padding-top: 14px }
.thH { font: 600 1.125rem/1.3 var(--font-display) }
.thBtns { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 4px }
.thBtns .quiet { text-decoration: none; display: inline-flex; align-items: center; font-weight: 700 }
.ok { color: var(--positive); font-weight: 700 }
.ok::before { content: '✓ ' }

/* the making animation: the Line oak draws itself, line by line, then its leaves */
.making-pane { justify-items: center; text-align: center; padding-top: 8px }
.making { width: min(200px, 60%); height: auto; overflow: visible; color: var(--brand) }
.making path { stroke-dasharray: 1; stroke-dashoffset: 1; animation: oakLoop 3.6s ease-in-out infinite }
.making .lf { animation-name: leafLoop }
.status { font: 700 1.0625rem/1.5 var(--font-text); min-height: 1.5em }
@media (prefers-reduced-motion: reduce) {
  .making path, .mkload path { stroke-dashoffset: 0; animation: none }
  .spinner { animation-duration: 3s }
}

/* order page, feedback, privacy and terms */
.order { max-width: 680px; margin: 10vh auto; display: grid; gap: 14px }
dialog.fb textarea, dialog.fb input { margin: 6px 0 12px }
.fbBtns { display: flex; justify-content: flex-end; gap: 16px; align-items: center }
.fbBtns .primary { min-height: var(--target) }
.fbDone { font-size: 1.0625rem; margin: 8px 0 }
.doc { max-width: 720px; margin: 0 auto; padding: 5vh 0 }
.doc h1 { font-size: clamp(36px, 5vw, 52px) }
.doc h2 { font: 600 1.375rem/1.3 var(--font-display); margin: 32px 0 10px }
.doc p, .doc ul { margin: 0 0 12px }
.doc li { margin: 6px 0 }
.doc li::marker { color: var(--leaf) }

/* "Delete my file" asks in the site's own dialog */
dialog.ask { width: min(460px, calc(100vw - 24px)); border: 1px solid var(--hairline); border-radius: var(--radius-card); padding: 26px 24px 22px; background: var(--page); color: var(--ink); box-shadow: 0 30px 80px #17352a59 }
dialog.ask h2 { font: 600 1.625rem/1.2 var(--font-display); margin: 0 0 8px }
dialog.ask .askBtns { display: flex; flex-wrap: wrap; justify-content: flex-end; align-items: center; gap: 12px 18px; margin-top: 18px }
.plist .more { padding: 10px 12px; font-size: 0.875rem; color: var(--ink-soft); cursor: default }
.resume .forgetHere { grid-column: 1 / -1; justify-self: start; font-size: 0.875rem; padding: 2px 0 }

/* step 2: the chosen person, with Change; the list only while choosing */
#focusBox { grid-template-columns: minmax(0, 1fr) auto; align-items: start; column-gap: 12px }
#focusBox #focus { display: grid; gap: 2px; min-width: 0 }
#focusBox #pickChange { padding-top: 2px }
.picker { display: grid; gap: 10px }
/* kinds of chart: a drawing and a name, three to a row */
.cards:has(.kind) { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px }
.card.kind { justify-items: center; text-align: center; gap: 4px; padding: 10px 6px 10px; border-radius: 16px }
.card.kind.on { padding: 8px 4px 8px }
.card.kind .cn { font-size: 0.9375rem; padding: 0; justify-content: center }
.kic { width: 44px; height: 32px; fill: var(--brand); stroke: var(--brand); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round }
.kic path { fill: none }
.card.kind.on .kic { fill: var(--accent); stroke: var(--accent) }
.sug { font: 700 0.75rem/1 var(--font-text); color: var(--accent); letter-spacing: .02em }
/* design: the picture and the name; Customize below */
.custom { border-top: 1px solid var(--hairline); padding-top: 10px }
.custom summary { cursor: pointer; font: 700 0.9375rem/1.3 var(--font-text); color: var(--brand); padding: 6px 0; list-style-position: inside }
.custom[open] { display: grid; gap: 10px }
.cgH { font: 600 1rem/1.3 var(--font-display); margin-top: 6px }
@media (max-width: 820px) { .cards:has(.kind) { grid-template-columns: repeat(3, minmax(0, 1fr)) } }

/* generations: a ladder with the person in the middle */
.gens { display: grid; gap: 10px; min-width: 0 }
.gens .kicker { display: block; font: 700 0.75rem/1.125rem var(--font-text); letter-spacing: .14em }
.gens .ct { font: 400 0.875rem/1.375rem var(--font-text); color: var(--ink-soft); white-space: nowrap }
.gens .pm { display: inline-flex; gap: 8px; flex: none }
.gens .sb { flex: none; width: 44px; height: 44px; border: 2px solid var(--control-border); border-radius: 99px; background: var(--card); color: var(--brand); font: 700 1.375rem/1 var(--font-text); cursor: pointer; display: inline-flex; align-items: center; justify-content: center; padding: 0 0 2px }
.gens .sb:hover:not(:disabled) { background: var(--band) }
.gens .sb:disabled { opacity: .35; cursor: default }
.gens .av { width: 40px; height: 40px; box-sizing: border-box; border-radius: 99px; border: 2px solid var(--brand); background: var(--card); color: var(--brand); display: flex; align-items: center; justify-content: center; font: 700 0.875rem/1 var(--font-text); letter-spacing: .04em }
.gsum { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 12px; padding-top: 12px; border-top: 1px solid var(--hairline); font: 400 1rem/1.5rem var(--font-text) }
.gsum b { font-weight: 700 }
.gf { display: grid; gap: 6px; min-width: 0 }
.gfLbl { margin-top: 6px; font-size: 0.9375rem; line-height: 22px; color: var(--ink-soft) }
.gfLbl:first-child { margin-top: 0 }
.gfRow { display: grid; grid-template-columns: minmax(0, 1fr) 84px; align-items: center; gap: 12px; min-width: 0 }
.gfStep { display: flex; align-items: center; min-width: 0; min-height: 50px; padding: 2px; box-sizing: border-box; border: 2px solid var(--control-border); border-radius: var(--radius-pill); background: var(--card) }
.gens .gfStep .sb { border: 0; background: none }
.gens .gfStep .sb:hover:not(:disabled) { background: var(--band) }
.gfStep b { flex: 1; min-width: 0; text-align: center; font: 700 0.9375rem/1.25rem var(--font-text); text-wrap: balance; overflow-wrap: anywhere }
.gfDots { display: grid; gap: 4px; min-width: 0 }
.gfDots > span:first-child { display: flex; flex-wrap: wrap; gap: 3px }
.gfDots i { width: 9px; height: 9px; box-sizing: border-box; border-radius: 99px; border: 1.5px solid var(--control-border) }
.gfDots i.on { background: var(--leaf); border-color: var(--brand) }
.gens .gfDots .ct { font-size: 0.8125rem; line-height: 16px }
.gfMe { display: flex; align-items: center; gap: 10px; min-width: 0; min-height: 50px; padding: 3px 16px 3px 3px; border: 2px solid var(--brand); border-radius: 99px; background: var(--brand); color: var(--on-brand); font: inherit; text-align: left }
.gens .gfMe .av { flex: none; background: var(--card) }
.gfMe b { flex: 1; min-width: 0; font: 700 1rem/1.375rem var(--font-text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis }
.gfRow.gfWho { grid-template-columns: minmax(0, 1fr) auto }
.gens .gfChange { min-height: 50px; padding: 0 18px }
.gfList .more { padding: 10px 12px; font-size: 0.875rem; color: var(--ink-soft) }
.gfPick { display: grid; gap: 6px; margin: 4px 0 0; padding: 10px; border: 2px solid var(--control-border); border-radius: var(--radius-input); background: var(--card); box-shadow: var(--shadow-card) }
.gfPick input { height: 44px; min-height: 44px }
.gfList { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; max-height: 300px; overflow-y: auto }
.gfList button { width: 100%; display: flex; align-items: baseline; gap: 8px; min-height: 44px; padding: 8px 10px; border: 0; border-radius: 10px; background: none; color: var(--ink); font: inherit; font-size: 0.9375rem; line-height: 22px; text-align: left; cursor: pointer }
.gfList button:hover { background: var(--band) }
.gfList button[aria-current=true] { background: var(--brand); color: var(--on-brand); font-weight: 700 }
.gfList button[aria-current=true] .yr, .gfList button[aria-current=true] .rel { color: var(--on-brand) }
.gfList .nm { min-width: 0; overflow-wrap: anywhere }
.gfList .yr { flex: none; font: 400 0.8125rem/1.3 var(--font-text); color: var(--ink-soft) }
.gfList .rel { margin-left: auto; flex: none; font-size: 0.8125rem; color: var(--ink-soft) }
.gfList .none { padding: 8px; color: var(--ink-soft) }
.gens .glEnd { padding: 6px 0 0; font-size: 0.9375rem; color: var(--ink-soft) }
@media (max-width: 820px) { .gfRow { grid-template-columns: minmax(0, 1fr) 72px; gap: 10px } .gfDots > span:first-child { gap: 2px } .gfDots i { width: 8px; height: 8px } .gfList { max-height: 240px } }
.glEnd { padding: 4px 0 4px 52px; font-size: 0.9375rem; line-height: 24px; color: var(--ink-soft) }

/* compare mode (?compare): watermark on/off, beside "Review names & dates" */
.wmToggle { right: auto !important; left: 12px }
.wmToggle[aria-pressed=true] { background: var(--brand); color: var(--on-brand); border-color: var(--brand) }

/* ---------- the maker: Tree → Person → Chart → Look, the preview on the right ---------- */
body.wz .work { grid-template-columns: minmax(360px, 480px) minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr) auto; grid-template-areas: "head stage" "panel stage" "foot stage"; column-gap: 28px }
body.wz .stage { padding-bottom: 14px }

/* the step's title and lead */
.wzHead { grid-area: head; display: grid; gap: 4px; padding-top: 12px; min-width: 0 }
.wzTitle { font: 600 1.75rem/1.2 var(--font-display) }
.wzLead { font-size: 1rem; line-height: 1.5; color: var(--ink-soft) }
body.wz[data-wz=done] .wzTitle, body.wz[data-wz=done] .wzLead { display: none }

/* one step at a time; Look holds Design and Size together */
body.wz .panel { padding-top: 8px }
body.wz .panel [data-tab], body.wz .panel .wzTree, body.wz .panel .wzDone { display: none }
body.wz[data-wz=person] .panel .step[data-tab=person], body.wz[data-wz=chart] .panel .step[data-tab=chart],
body.wz[data-wz=look] .panel .step[data-tab=design], body.wz[data-wz=look] .panel .step[data-tab=size] { display: grid }
body.wz[data-wz=look] .panel p.forget { display: block }
body.wz[data-wz=tree] .panel .wzTree { display: grid; gap: 12px }
body.wz[data-wz=done] .panel .wzDone { display: grid; gap: 16px }
body.wz .panel .step { border-bottom: 0; padding-block: 4px 18px }
body.wz[data-wz=look] .panel .step[data-tab=size] { border-top: 1px solid var(--hairline); padding-top: 16px }
.wzSub { font: 600 1.125rem/1.3 var(--font-display) }

/* step 1: the home page's upload, inside the panel; once a file is in, it shows as a card */
body.wz #hero[hidden] { display: block !important }
body.wz .wzTree .hero { max-width: none; margin: 0; padding: 0 }
body.wz .wzTree .hero > .kicker, body.wz .wzTree .hero > h1, body.wz .wzTree .hero > .lead { display: none }
body.wz .wzTree .drop { margin: 0 0 10px; padding: 22px 20px }
body.wz .wzTree .resume { margin: 0 0 14px }
body.wz .wzTree .samples { margin: 8px 0 10px }
body.wz:not(.noproj) .wzTree:not(.swap) .drop, body.wz:not(.noproj) .wzTree:not(.swap) .samples, body.wz:not(.noproj) #resume { display: none !important }
.wzFile { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 2px 14px; padding: 14px 18px; background: var(--card); border: 1px solid var(--hairline); border-top: 6px solid var(--leaf); border-radius: var(--radius-card) }
.wzFile .tick { grid-row: span 2; width: 34px; height: 34px; border-radius: 99px; background: var(--brand); display: flex; align-items: center; justify-content: center }
.wzFile .tick svg { width: 18px; height: 18px; fill: none; stroke: var(--on-brand); stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round }
.wzFile strong { font: 700 1rem/1.35 var(--font-text); min-width: 0; overflow-wrap: anywhere }
.wzFile .data { grid-column: 2; color: var(--ink-soft) }
.wzFile .link { grid-column: 3; grid-row: 1 / span 2 }

/* step 2: the list stays open beside the chosen person */
body.wz #picker[hidden] { display: grid !important }
body.wz #pickChange { display: none !important }
body.wz #focusBox { grid-template-columns: minmax(0, 1fr); order: -1 }
body.wz .plist { max-height: max(220px, calc(100vh - 500px)); max-height: max(220px, calc(100dvh - 500px)) }

/* the finished chart, in the panel instead of a dialog */
body.wz .wzDone h2 { font: 600 1.875rem/1.15 var(--font-display); margin: 2px 0 4px }
body.wz .wzDone .pane { gap: 12px }
body.wz .wzDone .inl .ink { white-space: nowrap; flex: none }
.wzDoneLinks { display: flex; flex-wrap: wrap; gap: 6px 20px; border-top: 1px solid var(--hairline); padding-top: 12px }
.wzDoneLinks button.link { padding: 4px 0 }

/* Back and Continue, always at the bottom of the panel */
.wzFoot { grid-area: foot; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; border-top: 1px solid var(--hairline); padding: 12px 0 14px; margin-top: 4px; min-width: 0 }
.wzFacts { flex: 1 1 0; min-width: 0; text-align: right; font: 400 0.9375rem/1.5rem var(--font-text); color: var(--ink-soft); white-space: nowrap; overflow: hidden; text-overflow: ellipsis }
.wzFoot .primary:disabled { cursor: not-allowed }
.wzFoot .terms { flex-basis: 100%; text-align: right; font-size: 0.8125rem }
body.wz[data-wz=done] .wzFoot { display: none }

/* before a file is in: an empty space where the chart will be */
.wzEmpty { max-width: 380px; padding: 36px 30px; border: 3px dashed var(--saffron); border-radius: var(--radius-card); text-align: center; font: 400 1rem/1.55 var(--font-text); color: var(--ink-soft) }
body.wz:not(.noproj) .wzEmpty, body.wz.noproj .frame, body.wz.noproj .zbar, body.wz.noproj .checkBtn, body.wz.noproj .zhint { display: none !important }

@media (max-height: 760px) and (min-width: 821px) {
  .wzTitle { font-size: 1.5rem } .wzLead { display: none }
  .wzFoot { padding: 8px 0 10px }
}

/* phone: the title, then the chart, then the step, then Back / Continue */
@media (max-width: 820px) {
  body.wz .work { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto minmax(170px, 32vh) minmax(0, 1fr) auto; grid-template-areas: "head" "stage" "panel" "foot"; column-gap: 0 }
  body.wz .wzHead { padding: 8px 14px 4px }
  body.wz .wzTitle { font-size: 1.375rem } body.wz .wzLead { display: none }
  body.wz .stage { padding-bottom: 0 }
  body.wz .panel { display: block; height: auto; padding: 8px 14px 16px; background: none; border: 0; box-shadow: none }
  body.wz .wzFoot { margin: 0; padding: 8px 14px calc(8px + env(safe-area-inset-bottom)); background: var(--page) }
  body.wz .wzFacts { display: none } body.wz .wzFoot .primary { flex: 1 1 auto } body.wz .wzFoot .terms { text-align: center }
  body.wz.typing .wzFoot { display: none }
  body.wz .plist { max-height: 260px }
}

/* ---------- Easy layout (always on): plain words, a full-screen chart, the chosen card says so in words ---------- */
body.ez .lbl { font: 700 0.9375rem/1.375rem var(--font-text); color: var(--ink) }
body.ez .check input { width: 24px; height: 24px }
body.ez .card.on .cn::after, body.ez .card.on .tn::after { content: 'Chosen'; display: inline-block; white-space: nowrap; margin-left: 8px; font: 700 0.75rem/1 var(--font-text); color: var(--on-brand); background: var(--brand); padding: 4px 9px; border-radius: 99px }
body.ez .card.kind.on .cn::after { display: none }
body.ez #custom { display: none }
body.ez #themes:not(.open) .card:nth-child(n+5):not(.on) { display: none }
body.ez #ezAllThemes { margin-top: 10px; justify-self: start }

/* the step counter: the design system's Stepper (numbered dots, done ones show a check, the current one is filled) */
.ezProg { display: grid; gap: 8px; margin-bottom: 10px }
.ezStep { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0) }
.ezSegs { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 20px; counter-reset: st }
.ezSegs li { counter-increment: st; display: flex; align-items: center; gap: 8px; font: 400 0.9375rem/1.2 var(--font-text); color: var(--ink-soft) }
.ezSegs li::before { content: counter(st); width: 30px; height: 30px; flex: none; box-sizing: border-box; border-radius: 99px; border: 2px solid var(--control-border); display: inline-flex; align-items: center; justify-content: center; font: 700 0.875rem/1 var(--font-text); color: var(--ink) }
.ezSegs li.cur { color: var(--ink); font-weight: 700 }
.ezSegs li.cur::before { background: var(--brand); border-color: var(--brand); color: var(--on-brand) }
.ezSegs li.done { color: var(--ink) }
.ezSegs li.done::before { content: ''; background: var(--brand) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fbf3e0' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") no-repeat center / 18px; border-color: var(--brand) }

/* how to get the file */
.ezHow { margin: 12px 0 0; padding: 14px var(--space-card); background: var(--card); border: 1px solid var(--hairline); border-radius: var(--radius-card) }
.ezHow p { margin: 0 0 6px; font: 600 1.125rem/1.3 var(--font-display) }
.ezHow ol { margin: 0; padding-left: 24px; font-size: 0.9375rem; line-height: 1.55; color: var(--ink-soft) }
.ezHow ol li::marker { color: var(--accent); font-weight: 700 }
body.wz:not(.noproj) .wzTree:not(.swap) .ezHow { display: none !important }

/* big zoom buttons, and the chart on a full screen */
#ezBig { position: absolute; left: 12px; top: 12px; z-index: 3; min-height: 44px; background: var(--card); box-shadow: var(--shadow-card) }
body.wz.noproj #ezBig { display: none !important }
body.ezfull { overflow: hidden }
body.ezfull .stage { position: fixed; inset: 0; z-index: 60; background: var(--page); padding: 12px; margin: 0 }
body.ezfull .wall { border-radius: var(--radius-card) }
body.ezfull #ezBig { background: var(--brand); border-color: var(--brand); color: var(--on-brand) }
body.ezfull #ezBig:hover { background: #17352a; border-color: #17352a }
body.ezfull .zbar { right: 20px; bottom: 20px }
@media (max-width: 820px) { body.ez .zhint { max-width: calc(100% - 24px); bottom: 76px } body.ez .zbar, body.ezfull .zbar { left: 50%; right: auto; transform: translateX(-50%) } }

/* Easy on a computer: the chart is already beside the steps, and there is nothing to continue to before a file is chosen */
body.ez .ezSee { display: none !important }
body.ez.noproj .wzFoot { display: none }
body.ezfull .stage { padding-top: max(12px, env(safe-area-inset-top)); padding-bottom: max(12px, env(safe-area-inset-bottom)) }

/* Easy on a phone: one question at a time; the chart opens full screen from "See my chart" */
@media (max-width: 820px) {
  body.ez.app .top { flex-wrap: wrap; gap: 8px 12px; padding: 8px 14px 6px }
  body.ez .topnav { flex-wrap: wrap; justify-content: flex-end; gap: 8px }
  body.ez #fbOpen, body.ez #coffeeTop { display: none }
  body.ez #ezHelp { min-height: 40px; padding: 0 14px; font-size: 0.9375rem }
  body.ez .work { grid-template-rows: auto minmax(0, 1fr) auto; grid-template-areas: "head" "panel" "foot" }
  body.ez .stage { display: none }
  body.ezfull .stage { display: flex }
  body.ez:not(.noproj) .ezSee { display: inline-flex !important; flex: 1 1 100%; order: -1 }
  body.ez .wzHead { padding: 8px 14px 6px }
  body.ez .wzTitle { font-size: 1.5rem }
  body.ez .wzFoot { gap: 10px }
  body.ez .plist { max-height: 52vh; max-height: 52dvh }
  body.ez #charts { grid-template-columns: repeat(2, minmax(0, 1fr)) }
  body.ez #themes { grid-template-columns: 1fr }
  body.ez #themes .card { grid-template-columns: 112px minmax(0, 1fr); column-gap: 14px; align-items: center }
  body.ez #themes .sw { grid-row: 1 / span 2 }
  body.ez #themes .tn, body.ez #themes .cb { grid-column: 2 }
  body.ez #themes .tn { align-self: end } body.ez #themes .cb { align-self: start }
  .ezSegs { gap: 6px 12px } .ezSegs li { font-size: 0.8125rem; gap: 6px } .ezSegs li::before { width: 26px; height: 26px }
}

/* ---------- wizard and Easy: Tree → Chart → Family → Look ---------- */
.gfLead { font-size: 0.9375rem; line-height: 22px; color: var(--ink-soft); margin: -4px 0 6px }
.card.kind .kb { display: none }
/* Tree and Person: no preview, the step takes the whole width. Chart and Look: the step on the left, the preview on the right. */
body.wz[data-wz=tree] .work, body.wz[data-wz=person] .work { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr) auto; grid-template-areas: "head" "panel" "foot" }
body.wz[data-wz=tree] .stage, body.wz[data-wz=person] .stage { display: none !important }
body.wz[data-wz=tree] .wzHead, body.wz[data-wz=tree] .panel, body.wz[data-wz=tree] .wzFoot,
body.wz[data-wz=person] .wzHead, body.wz[data-wz=person] .panel, body.wz[data-wz=person] .wzFoot { width: 100%; max-width: 860px; justify-self: center; box-sizing: border-box }
body.wz[data-wz=person] .panel .step[data-tab=person] { max-width: 640px }
body.wz[data-wz=chart] .card.kind { align-content: start; padding-bottom: 10px }
body.wz[data-wz=chart] .card.kind:disabled .kb { display: block; font-size: 0.8125rem; line-height: 18px; color: var(--ink-soft); text-align: center; margin-top: 2px }
body.wz[data-wz=chart] .opts { margin-top: 16px }
@media (max-width: 820px) {
  body.wz[data-wz=tree] .work, body.wz[data-wz=person] .work { grid-template-rows: auto minmax(0, 1fr) auto }
}
/* phones: the header links wrap instead of pushing the header off the screen */
@media (max-width: 820px) {
  .topnav { flex-wrap: wrap; justify-content: flex-end; gap: 4px 14px; min-width: 0 }
  .navLink { font-size: 0.875rem; min-height: 36px }
  #demo { display: none }
}
@media (max-width: 820px) {
  body.ez[data-wz=tree]:not(.noproj) .ezSee, body.ez[data-wz=person]:not(.noproj) .ezSee { display: none !important }
}

.clList .hit { outline: 3px solid var(--accent); outline-offset: -3px; background: var(--band) }

/* A short screen (a small laptop, or the browser zoomed to 200%): the page scrolls as a whole */
@media (max-height: 620px) {
  body.app { height: auto; min-height: 100vh; min-height: 100dvh; overflow: visible }
  body.app #appView { display: block }
  .work { display: grid; height: auto }
  body.wz .panel, .panel { overflow: visible; height: auto; max-height: none }
  body.wz .plist { max-height: 70vh }
  .stage { min-height: 70vh }
  body.wz:not(.ezfull) .wzFoot { position: static }
}
