/* Hand-over documents: the group on the files page, and the print (PDF) layout of one document. */
.formal-docs { margin-top: 28px; }
.formal-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 14px; }
.formal-head h2 { margin: 0 0 4px; font-size: 1.15rem; }
.formal-head .lead-sm { margin: 0; max-width: 62ch; }
.doc-cover { display: none; }

@media print {
  @page { size: A4; margin: 18mm 16mm; }
  html, body { background: #fff !important; }
  header.topbar, header.nav, .hnav, .admin-nav, .app-side, .side, .footer, .project-tabs, .toast, .announce, .back-link, .files-head, .panel-toolbar, .toc, .uikit-extra, #source { display: none !important; }
  .shell, .shell-content, .page, .page-wide, .viewer, .panel { display: block !important; margin: 0 !important; padding: 0 !important; max-width: none !important; width: auto !important; border: 0 !important; box-shadow: none !important; background: none !important; }
  .doc-cover { display: flex; flex-direction: column; justify-content: center; min-height: 240mm; break-after: page; }
  .doc-cover img { width: 150px; height: auto; margin-bottom: 60mm; }
  .doc-cover-project { font-size: 15pt; color: var(--aura-color-text-muted); margin: 0 0 6px; }
  .doc-cover-title { font-size: 32pt; font-weight: 700; color: var(--aura-color-text-heading); line-height: 1.15; margin: 0 0 14px; padding-bottom: 14px; border-bottom: 3px solid var(--aura-color-brand-solid); }
  .doc-cover-meta { font-size: 11pt; color: var(--aura-color-text-muted); margin: 0; }
  .shell-content, main, .markdown { background: #fff !important; border-radius: 0 !important; }
  #rendered { display: block !important; font-size: 10.5pt; color: #111; padding: 0 !important; }
  #rendered td, #rendered th { word-break: normal; overflow-wrap: normal; hyphens: none; }
  #rendered[hidden] { display: block !important; }
  #rendered > h1:first-child { display: none; }
  #rendered h2, #rendered h3 { break-after: avoid; color: var(--aura-color-text-heading); }
  #rendered table { width: 100%; border-collapse: collapse; font-size: 9pt; break-inside: auto; }
  #rendered th, #rendered td { border: 1px solid var(--aura-color-border-strong); padding: 4px 6px; vertical-align: top; }
  #rendered thead { display: table-header-group; }
  #rendered tr { break-inside: avoid; }
  #rendered pre { white-space: pre-wrap; border: 1px solid var(--aura-color-border-strong); font-size: 8.5pt; }
  #rendered a { color: inherit; text-decoration: none; }
}

/* What this level includes, on the unlock page. */
.pay-gets-list { list-style: none; margin: 10px 0 14px; padding: 0; display: grid; gap: 6px; font-size: .86rem; color: var(--aura-color-text-muted); }
.pay-gets-list li { display: flex; gap: 8px; align-items: flex-start; }
.pay-gets-list .icon { flex: none; width: 16px; height: 16px; margin-top: 2px; color: var(--aura-color-status-healthy-fg); }

.assist-left { display: block; margin-top: 6px; color: var(--aura-color-text-muted); font-size: 13px; }

/* Admin › Studio lab: the progress pop-up (same look as "Making your plan"). */
#studio-pop .overlay-card { background: var(--aura-color-bg-surface); border-radius: var(--r-surface, 18px); box-shadow: var(--md-shadow, 0 12px 32px -8px rgba(0, 0, 0, .18)); padding: 32px 28px 26px; max-width: 520px; width: 100%; }
#studio-pop h2 { color: var(--aura-color-text-heading); }
#studio-pop .making-steps li:not(.active):not(.done) .tick { border: 1.5px solid var(--aura-color-border-strong); }
#studio-pop .making-meter { display: flex; align-items: center; gap: 12px; margin: 18px 0 0; }
#studio-pop .making-meter .making-bar { flex: 1; margin: 0; max-width: none; height: 8px; }
#studio-pop .making-bar span { width: 100%; background: linear-gradient(90deg, var(--aura-color-brand-highlight), var(--aura-color-brand-solid)); position: relative; overflow: hidden; }
#studio-pop .making-bar span::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .55), transparent); animation: studio-sweep 1.6s linear infinite; }
@keyframes studio-sweep { from { transform: translateX(-100%); } to { transform: translateX(100%); } }
#studio-pop .making-clock { flex: none; min-width: 60px; text-align: right; font: 600 12.5px var(--aura-font-family-mono); color: var(--aura-color-brand-fg); }
.studio-pop-foot { margin: 18px 0 0; font-size: 13px; color: var(--aura-color-text-subtle); }
.studio-result { margin-top: 18px; text-align: left; font-size: 14.5px; color: var(--aura-color-text-default); }
.studio-result p { margin: 0 0 8px; }
#studio-actions { margin-top: 18px; }
@media (max-width: 640px) { #studio-pop .overlay-card { margin: 0 16px; width: auto; padding: 26px 18px 22px; } }
@media (prefers-reduced-motion: reduce) { #studio-pop .making-bar span::after { animation: none; } }

/* AI App Studio (pilot) */
.studio-page { max-width: 1100px; }
.studio-starters { margin-bottom: 18px; }
.studio-closed p { max-width: 62ch; }
.studio-bar { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; margin-bottom: 14px; }
.studio-bar .card-title { margin: 0 0 4px; }
.studio-stage { margin: 0 0 16px; }
.studio-frame { border-radius: 16px; overflow: hidden; border: 1px solid var(--hairline); background: #fff; box-shadow: var(--md-shadow, 0 8px 24px -12px rgba(0, 0, 0, .2)); }
.studio-frame iframe { display: block; width: 100%; height: min(720px, 78vh); min-height: 420px; border: 0; background: #fff; }
.studio-label { display: flex; gap: 8px; align-items: flex-start; margin: 10px 4px 0; font-size: 13px; color: var(--aura-color-text-muted); }
.studio-label .icon { flex: none; width: 16px; height: 16px; margin-top: 2px; }
.studio-versions { list-style: none; margin: 0 0 10px; padding: 0; display: grid; gap: 4px; }
.studio-versions li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 4px; border-bottom: 1px solid var(--hairline); }
.studio-versions li:last-child { border-bottom: 0; }
.studio-foot-card { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
.studio-foot-card p { margin: 0; max-width: 64ch; }
.studio-wait p { max-width: 58ch; }
.notice-line { display: flex; gap: 8px; align-items: flex-start; margin: 12px 0 16px; font-size: 14px; color: var(--aura-color-text-muted); }
.notice-line .icon { flex: none; width: 17px; height: 17px; margin-top: 2px; }
#studio-wait-pop .overlay-card { background: var(--aura-color-bg-surface); border-radius: var(--r-surface, 18px); box-shadow: var(--md-shadow, 0 12px 32px -8px rgba(0, 0, 0, .18)); padding: 32px 28px 26px; max-width: 520px; width: 100%; }
#studio-wait-pop h2 { color: var(--aura-color-text-heading); }
#studio-wait-pop .making-steps li:not(.active):not(.done) .tick { border: 1.5px solid var(--aura-color-border-strong); }
#studio-wait-pop .making-meter { display: flex; align-items: center; gap: 12px; margin: 18px 0 0; }
#studio-wait-pop .making-meter .making-bar { flex: 1; margin: 0; max-width: none; height: 8px; }
#studio-wait-pop .making-bar span { width: 100%; background: linear-gradient(90deg, var(--aura-color-brand-highlight), var(--aura-color-brand-solid)); position: relative; overflow: hidden; }
#studio-wait-pop .making-bar span::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .55), transparent); animation: studio-sweep 1.6s linear infinite; }
#studio-wait-pop .making-clock { flex: none; min-width: 60px; text-align: right; font: 600 12.5px var(--aura-font-family-mono); color: var(--aura-color-brand-fg); }
#studio-wait-pop .actions { margin-top: 18px; }
@media (max-width: 640px) { #studio-wait-pop .overlay-card { margin: 0 16px; width: auto; padding: 26px 18px 22px; } .studio-frame iframe { height: 70vh; } }
@media (prefers-reduced-motion: reduce) { #studio-wait-pop .making-bar span::after { animation: none; } }
.check-row { display: grid; gap: 8px; }

/* AI App Studio: tabs, change box, code editor */
.studio-tabs { margin: 0 0 12px; }
.studio-tabs .admin-nav-link { cursor: pointer; border: 0; font: inherit; }
.studio-change { margin: 0 0 16px; }
.studio-change textarea { width: 100%; }
.studio-files { list-style: none; display: flex; gap: 6px; flex-wrap: wrap; margin: 0 0 10px; padding: 0; }
.studio-textarea { display: block; width: 100%; min-height: 460px; resize: vertical; padding: 14px 16px; border: 1px solid var(--hairline); border-radius: 12px; background: var(--surface-ink); color: var(--on-ink); font: 13px/1.55 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; tab-size: 2; white-space: pre; overflow: auto; }
.studio-textarea:focus-visible { outline: 2px solid var(--aura-color-brand-fg); outline-offset: 2px; }
.studio-code .actions { margin-top: 12px; align-items: center; }
.studio-code-problems { margin: 12px 0 0; }
.studio-code-narrow { display: none; }
@media (max-width: 900px) { .studio-code-wide { display: none; } .studio-code-narrow { display: flex; gap: 8px; align-items: flex-start; } .studio-tabs .studio-code-tab { display: none; } }

.studio-source { align-items: end; }
.studio-feedback summary { cursor: pointer; list-style: none; }
.studio-feedback summary::-webkit-details-marker { display: none; }
.studio-feedback form { margin-top: 12px; }
.studio-feedback .check-row { margin: 8px 0 14px; }
.studio-rating { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; margin: 6px 0 14px; }
.studio-rating label { display: inline-flex; gap: 6px; align-items: center; }

/* Studio: the three starting points as cards */
.studio-starters { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin: 0 0 22px; }
.studio-starters .studio-card { display: flex; gap: 12px; align-items: flex-start; padding: 16px; border: 1.5px solid var(--hairline); border-radius: 14px; background: var(--aura-color-bg-surface); cursor: pointer; transition: border-color .15s, background-color .15s; }
.studio-starters .studio-card:hover { border-color: var(--aura-color-border-strong); }
.studio-starters .studio-card input { flex: none; margin: 3px 0 0; width: 18px; height: 18px; accent-color: var(--aura-color-brand-solid); }
.studio-starters .studio-card-body { display: grid; gap: 4px; }
.studio-starters .studio-card-body b { font-size: 16px; color: var(--aura-color-text-heading); }
.studio-starters .studio-card-body small { font-size: 13px; color: var(--aura-color-text-muted); line-height: 1.45; }
.studio-starters .studio-card:has(input:checked) { border-color: var(--aura-color-brand-solid); background: var(--aura-color-brand-subtle); box-shadow: 0 0 0 3px color-mix(in srgb, var(--aura-color-brand-solid) 14%, transparent); }
.studio-starters .studio-card:has(input:focus-visible) { outline: 2px solid var(--aura-color-brand-fg); outline-offset: 2px; }
@media (max-width: 760px) { .studio-starters { grid-template-columns: 1fr; } }

.studio-terms { margin: 0 0 14px; }
.studio-terms summary { cursor: pointer; list-style: none; }
.studio-terms summary::-webkit-details-marker { display: none; }
.studio-terms ul { margin: 10px 0 0; padding-left: 20px; display: grid; gap: 6px; color: var(--aura-color-text-default); font-size: 14px; }
