/* App-style components for the website and print. Needs tokens.css first. */

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 44px; padding: 0 20px;
  border-radius: var(--r); font: 600 15px/1 var(--font-sans); text-decoration: none; border: 1px solid transparent; cursor: pointer; white-space: nowrap; }
.btn-primary { background: var(--green); color: #fff; box-shadow: var(--shadow-button); }
.btn-primary:hover { background: var(--green-deep); }
.btn-secondary { background: var(--card); color: var(--ink); border-color: var(--line-strong); }
.btn-secondary:hover { background: var(--sand); }
.btn-ghost { color: var(--green); padding: 0 8px; }
.btn-small { height: 32px; padding: 0 14px; font-size: 13px; }

.badge { display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 10px; border-radius: var(--r-pill);
  font-size: 12.5px; font-weight: 500; white-space: nowrap; font-variant-numeric: tabular-nums; }
.badge i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge-ok { background: var(--green-wash); color: var(--green-deep); }
.badge-ok i { background: var(--green-mid); }
.badge-soon { background: var(--amber-soft); color: var(--amber-text); }
.badge-soon i { background: var(--amber); }
.badge-late { background: var(--red-soft); color: var(--red); }
.badge-neutral { background: var(--sand); color: var(--ink-2); border: 1px solid var(--line); }
.badge-green { background: var(--green); color: #fff; }
.chip { display: inline-flex; align-items: center; height: 24px; padding: 0 9px; border-radius: var(--r-sm);
  background: var(--sand); border: 1px solid var(--line); font-size: 12.5px; color: var(--ink-2); }

.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-card); padding: 20px; }
.card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.card-head h3 { margin: 0; font-size: 16px; font-weight: 600; letter-spacing: -0.01em; }
.card-head p { margin: 2px 0 0; font-size: 13px; color: var(--muted); }
.count { min-width: 28px; height: 28px; border-radius: var(--r-pill); background: var(--green-soft); color: var(--green-deep);
  display: grid; place-items: center; font-weight: 600; font-size: 13px; }

.list { list-style: none; margin: 0; padding: 0; }
.list li { display: grid; grid-template-columns: 36px 1fr auto; gap: 12px; align-items: center; padding: 10px 0; border-top: 1px solid var(--line); }
.list li:first-child { border-top: 0; }
.list b, .forms b { display: block; font-size: 14px; font-weight: 600; }
.list small, .forms small { display: block; font-size: 12.5px; color: var(--muted); }
.list.compact li { padding: 8px 0; }
.avatar { width: 36px; height: 36px; border-radius: 50%; background: var(--green-soft); color: var(--green-deep);
  display: grid; place-items: center; font-size: 12px; font-weight: 600; }

.progress-label { font-size: 13px; font-weight: 600; color: var(--green-deep); font-variant-numeric: tabular-nums; }
.progress { height: 6px; border-radius: var(--r-pill); background: var(--sand); overflow: hidden; margin: -4px 0 12px; }
.progress i { display: block; height: 100%; background: var(--green-mid); border-radius: inherit; }
.checks { list-style: none; margin: 0; padding: 0; }
.checks li { display: flex; align-items: center; gap: 10px; padding: 7px 0; font-size: 14px; color: var(--ink); }
.checks .tick { flex: none; width: 18px; height: 18px; border-radius: 5px; border: 1.5px solid var(--line-strong); background: #fff; }
.checks li.done { color: var(--ink-2); }
.checks li.done .tick { background: var(--green) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4 8.5l2.5 2.5L12 5.5' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/14px no-repeat; border-color: var(--green); }

.forms { list-style: none; margin: 0; padding: 0; }
.forms li { display: grid; grid-template-columns: 32px 1fr auto; gap: 12px; align-items: center; padding: 10px 0; border-top: 1px solid var(--line); }
.forms li:first-child { border-top: 0; }
.doc { width: 28px; height: 34px; border-radius: 4px; background: var(--green-wash); border: 1px solid var(--green-soft); position: relative; }
.doc::before, .doc::after { content: ''; position: absolute; left: 6px; right: 6px; height: 2px; border-radius: 2px; background: var(--green-mid); }
.doc::before { top: 10px; } .doc::after { top: 16px; right: 10px; }

.paper-form { position: relative; overflow: hidden; background: #fff; font-size: 12px; }
.pf-title { font-weight: 700; font-size: 13px; text-transform: uppercase; letter-spacing: .04em; padding-bottom: 10px; margin-bottom: 8px; border-bottom: 2px solid var(--ink); }
.pf-row { display: grid; grid-template-columns: 96px 1fr; gap: 10px; align-items: center; padding: 5px 0; }
.pf-row label { color: var(--muted); }
.pf-box { min-height: 24px; border: 1px solid var(--line-strong); border-radius: 2px; padding: 3px 8px; display: flex; align-items: center;
  font-family: ui-monospace, 'SF Mono', Menlo, monospace; font-size: 12px; letter-spacing: .03em; }
.pf-box.filled { color: #1a3fa0; background: #F7F9FE; border-color: #C9D3EC; }
.pf-seal { position: absolute; right: -18px; bottom: -22px; width: 128px; opacity: .85; transform: rotate(-14deg); }

.facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 0 0 12px; }
.facts div { background: var(--sand); border-radius: var(--r); padding: 10px 12px; }
.facts dt { font-size: 12px; color: var(--muted); }
.facts dd { margin: 2px 0 0; font-size: 16px; font-weight: 600; font-variant-numeric: tabular-nums; }

.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.stats div { border-left: 3px solid var(--green-soft); padding: 4px 0 4px 12px; }
.stats b { display: block; font-size: 30px; font-weight: 700; letter-spacing: -0.02em; color: var(--ink); font-variant-numeric: tabular-nums; }
.stats span { font-size: 12.5px; color: var(--muted); }
