/* Install page: the main action on a sheet, the three steps as cards on the desk,
   and the preview build tucked in a manila folder. */
.btn-big { min-height: 56px; padding: 0 28px; font-size: 18px; }

.store { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px 32px; margin-top: 34px; padding-top: 26px; border-top: 1.5px solid var(--rule); }
.store p { max-width: 52ch; margin-top: 8px; color: var(--ink-soft); }

/* The steps, numbered in gold by the list itself */
.steps { list-style: none; grid-template-columns: repeat(3, minmax(0, 1fr)); padding: 0; counter-reset: step; }
.steps li { counter-increment: step; }
.steps h3 { display: flex; align-items: baseline; gap: 12px; font: 700 22px/1.2 var(--display); }
.steps h3::before { content: counter(step); font: 700 34px/1 var(--display); color: var(--gold-ink); }
.steps p { font-size: 15px; }

/* The preview build, in a folder that opens */
.folder { position: relative; width: min(1000px, calc(100% - 2 * var(--m))); margin: 72px auto 0; background: #e3c98f; box-shadow: var(--shadow); }
.folder > summary { position: relative; display: flex; align-items: center; gap: 16px; padding: 22px 26px; list-style: none; cursor: pointer; }
.folder > summary::-webkit-details-marker { display: none; }
.folder-tab { position: absolute; left: 28px; bottom: 100%; padding: 7px 20px 5px; background: #e3c98f; font-size: 13px; font-weight: 700; clip-path: polygon(10px 0, calc(100% - 10px) 0, 100% 100%, 0 100%); }
.folder-title { flex: 1; font: 700 24px/1.2 var(--display); }
.folder-title small { display: block; margin-top: 4px; font: 600 14px/1.3 var(--body); color: #5c4a22; }
.folder-mark { font: 700 30px/1 var(--display); color: var(--ink); transition: transform 220ms cubic-bezier(0.23, 1, 0.32, 1); }
.folder[open] .folder-mark { transform: rotate(45deg); }
.folder > summary:hover .folder-title { text-decoration: underline; text-decoration-color: var(--ink-soft); text-underline-offset: 5px; }
.folder-body { margin: 0 14px 14px; padding: clamp(22px, 4vw, 40px); background: var(--sheet); }
.preview-intro h2 { font: 700 26px/1.2 var(--display); }
.preview-intro > p { margin-top: 12px; font-size: 15px; }
.preview-intro .small { color: var(--ink-soft); font-size: 14px; }
.preview-intro .btn { margin-top: 18px; }
.manual-steps { display: grid; gap: 0; margin-top: 28px; padding-left: 26px; }
.manual-steps li { padding: 14px 0 14px 6px; border-bottom: 1.5px solid var(--rule); }
.manual-steps li::marker { font: 700 20px var(--display); color: var(--gold-ink); }
.manual-steps h3 { font: 700 19px/1.3 var(--display); }
.manual-steps p { margin-top: 4px; font-size: 15px; }
.copy-address { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin-top: 10px; }
.copy-address code { padding: 6px 10px; font-size: 15px; overflow-wrap: anywhere; }
.copy-address .btn { min-height: 36px; padding: 0 14px; font-size: 14px; }
.copy-status { font-size: 14px; color: var(--ink-soft); }
.install-note { margin-top: 22px; font-size: 14px; color: var(--ink-soft); }
.install-note strong { color: var(--ink); }

.install-help { width: min(1000px, calc(100% - 2 * var(--m))); margin: 40px auto 0; color: var(--paper); font-weight: 600; }
.install-help a { color: var(--paper); text-decoration-color: var(--gold); text-decoration-thickness: 2px; }

@media (max-width: 900px) {
  .steps { grid-template-columns: 1fr; gap: 40px; }
}
@media (max-width: 760px) {
  .folder > summary { padding: 18px; }
  .folder-title { font-size: 20px; }
}

/* Tick a step off in pencil */
.steps li { position: relative; padding-right: 64px; }
.tick { position: absolute; top: 16px; right: 16px; width: 38px; height: 38px; padding: 4px; border: 2px solid rgba(27, 23, 18, 0.4); border-radius: 4px 6px 5px 7px; background: transparent; cursor: pointer; transition: border-color 160ms ease, transform 140ms cubic-bezier(0.23, 1, 0.32, 1); }
.tick:active { transform: scale(0.94); }
.tick svg { width: 100%; height: 100%; overflow: visible; fill: none; stroke: #3b3530; stroke-width: 3.2; stroke-linecap: round; stroke-linejoin: round; }
.tick path { stroke-dasharray: 1; stroke-dashoffset: 1; opacity: 0; transition: stroke-dashoffset 420ms cubic-bezier(0.23, 1, 0.32, 1), opacity 0ms 420ms; }
.is-done .tick path { stroke-dashoffset: 0; opacity: 1; transition: stroke-dashoffset 420ms cubic-bezier(0.23, 1, 0.32, 1), opacity 0ms; }
.is-done .tick { border-color: #3b3530; }
.is-done h3, .is-done p { color: var(--ink-soft); }
@media (hover: hover) and (pointer: fine) { .tick:hover { border-color: var(--ink); } }

/* The folder's tab lifts when you reach for it */
.folder-tab { transition: transform 220ms cubic-bezier(0.23, 1, 0.32, 1); }
.folder[open] .folder-tab { transform: translateY(-5px); }
@media (hover: hover) and (pointer: fine) { .folder > summary:hover .folder-tab { transform: translateY(-5px); } }
@media (prefers-reduced-motion: reduce) { .folder-tab, .tick path { transition: none !important; } }

/* Phone visitors can keep the install link for their computer. */
.install-choices { display: flex; flex-direction: column; gap: 24px; }
.handoff { padding: 22px 24px; background: var(--note); color: var(--ink); }
.handoff summary { cursor: pointer; font: 700 24px/1.2 var(--display); }
.handoff summary small { display: block; margin-top: 8px; font: 400 16px/1.5 var(--body); }
.handoff-body > p:first-child { margin-top: 18px; max-width: 48ch; }
#install-email-form, #email-app-option { margin-top: 20px; }
#install-email-form[hidden], #share-install[hidden] { display: none; }
#install-email-form label { display: block; font-weight: 600; margin-bottom: 8px; }
.email-row { display: flex; gap: 10px; flex-wrap: wrap; }
.email-row input { flex: 1 1 200px; min-width: 0; width: 100%; border: 1px solid var(--ink-soft); border-radius: 2px; background: var(--sheet); color: var(--ink); padding: 12px; font: 400 16px/1.4 var(--body); }
.handoff .btn { min-height: 48px; line-height: 1.3; touch-action: manipulation; }
.handoff .btn:disabled { opacity: .65; cursor: wait; }
.handoff-note { margin-top: 10px; font-size: 14px; line-height: 1.5; }
.handoff-alternatives { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; margin-top: 20px; }
.install-link { overflow-wrap: anywhere; }
.handoff-status { margin-top: 16px; font-weight: 600; line-height: 1.5; }
.handoff-status:empty { display: none; }
.handoff[data-email-ready] #email-app-option { margin-top: 14px; }
.handoff[data-email-ready] #email-myself { min-height: 44px; background: transparent; color: var(--ink); padding: 0; text-decoration: underline; }
.handoff[data-email-ready] #email-app-help { display: none; }
.handoff :focus-visible { outline: 3px solid var(--ink); outline-offset: 4px; }
@media (max-width: 760px) {
  .handoff { order: -1; margin-top: 24px; padding: 20px; }
  .install-choices { gap: 0; }
  .email-row { flex-direction: column; }
  .email-row input { flex-basis: auto; }
  .email-row .btn, #email-myself { width: 100%; }
  .handoff summary { font-size: 25px; }
  .store { margin-top: 24px; }
}

/* Preview changelog: the latest release, then earlier ones folded away */
.changes { margin: -4px 0 14px; }
.changes > summary { cursor: pointer; font-size: 14px; font-weight: 600; }
.changes ul { display: grid; gap: 8px; margin: 10px 0 0; padding-left: 18px; font-size: 14px; line-height: 1.5; }
