/* Shared finish of the founder-approved composition. Calendar structure stays in agenda.css. */
:root {
  --content-surface: var(--finish-card);
  --overlay-surface: #fffdf9;
  --overlay-line: #d4cec3;
  --overlay-shadow: 0 20px 64px rgb(36 35 31 / 17%), 0 3px 12px rgb(36 35 31 / 7%);
}
html[data-theme=dark] {
  --overlay-surface: #36332d;
  --overlay-line: #5d574c;
  --overlay-shadow: 0 20px 64px rgb(0 0 0 / 35%), 0 3px 12px rgb(0 0 0 / 20%);
}
.toolbar { border-bottom-color: var(--finish-line); }
.panel, .op-panel, .xp-step, .op-metrics, .cx-metrics {
  background-color: var(--content-surface);
  border-color: var(--finish-line);
}
.cx-panel { background: transparent; border-color: var(--finish-line); }
.button, .heading-actions .button, .pcrm-button, .pt-button { border-radius: 14px; }
.icon-button { border-radius: 50%; }
.button:not(.text):not(:disabled), .pcrm-button:not(:disabled), .pt-button:not(:disabled) {
  transition: background-color 160ms var(--finish-ease), border-color 160ms var(--finish-ease), box-shadow 160ms var(--finish-ease);
}
.button:not(.primary):not(.text):not(:disabled):hover,
.pcrm-button:not(.primary):not(:disabled):hover, .pt-button:not(.primary):not(:disabled):hover {
  background-color: var(--finish-hover);
  border-color: var(--control-border);
  box-shadow: 0 1px 2px rgb(36 35 31 / 5%);
}
.button:not(.text):not(:disabled):active, .pcrm-button:not(:disabled):active, .pt-button:not(:disabled):active {
  box-shadow: inset 0 1px 2px rgb(36 35 31 / 10%);
}
/* Signature belongs to entry into creation, never every primary confirmation. */
[data-action="op-form"]:is([data-kind="product-create"], [data-kind="service-create"], [data-kind="title-create"], [data-kind="account-create"], [data-kind="recurring-create"]),
[data-action="cx-form"]:is([data-kind="decision-create"], [data-kind="client"], [data-kind="opportunity"]),
[data-action="pcrm-new-person"], [data-action="pcrm-create-funnel"], [data-action="pcrm-temporal-new"].primary {
  border-radius: 5px 15px 15px 15px;
}
.record-save .button.primary { border-radius: 14px; }
.sheet:not(.agenda-dialog), .modal {
  background: var(--overlay-surface);
  border-color: var(--overlay-line);
  box-shadow: var(--overlay-shadow);
}
.sheet:not(.agenda-dialog) .sheet-header, .modal-header {
  background: var(--overlay-surface);
  border-bottom-color: var(--finish-line);
}
.sheet::backdrop, .modal::backdrop { background: rgb(36 35 31 / 24%); backdrop-filter: blur(2px); }
.sheet:not(.agenda-dialog) .form-actions, .sheet:not(.agenda-dialog) .op-form-actions {
  background: var(--overlay-surface);
}
.numeric-cell { text-align: right; font-variant-numeric: tabular-nums; }
.numeric-cell .sort-column { justify-content: flex-end; }
.numeric-cell .text-button { text-align: right; }
.data-table tr:focus-within { background: var(--finish-hover); }
.data-table tbody tr:hover { background: color-mix(in srgb, var(--finish-hover) 65%, transparent); }
.hint, .cx-muted, .sales-footnote, .sales-source, .record-origin, .table-mobile-hint, .work-identity,
.agenda-caption, .agenda-scroll-hint, .agenda-record-origin, .record-time-summary, .record-subtitle {
  font-size: max(12px, .8125rem);
}
#main:focus-visible { outline: none; }
#main h1 { width: fit-content; max-width: 100%; }
#main h1:focus-visible { outline-offset: 5px; border-radius: 4px; }
.agenda-record-undo { margin: 4px 0 12px; font-size: 12px; }
.agenda-record-undo .agenda-button { min-height: 32px; }
@media (prefers-reduced-motion: reduce) {
  .button, .pcrm-button, .pt-button { transition: none; }
}
[data-motion=reduced] :is(.button, .pcrm-button, .pt-button) { transition: none; }
@media (max-width:720px) {
  .sheet:not(.agenda-dialog) { border-radius: 0; }
  .numeric-cell { white-space: nowrap; }
}

.ai-decision>div>span:last-child, .ai-decision footer { font-size: 12px; }

@media (max-width:720px) { .first-setup>summary { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; } .first-setup>summary span { margin: 0; float: none; } }
