/* Approvals: the cards a cloud workspace is waiting on, answered from the phone (approvals.js, and in a chat chats.js), on top of app.css, in the desktop app's
   approval card: an icon tile, the title and one line of why in the head; the facts; Allow (the dark contrast button) and Deny (white); and the "without asking me"
   row (Always) as the footer. Colors from tokens.css only; new classes start with ax-. */

.si[data-view="approvals"] { place-items: start center; grid-template-columns: minmax(0, 1fr); padding-bottom: calc(88px + env(safe-area-inset-bottom)); }
.si[data-view="approvals"] .si-card { width: min(640px, 100%); align-self: start; padding: 0; background: none; border: 0; box-shadow: none; text-align: left; }
.si[data-view="approvals"] .brand-logo { display: none; }
.si[data-view="approvals"] .si-foot { margin-top: 20px; margin-bottom: 0; }
.si-view[data-v="approvals"] { min-width: 0; }
.si-view[data-v="approvals"] p[hidden], .ax-list[hidden] { display: none; }

.ax-list { display: flex; flex-direction: column; gap: 12px; }
.ax-card { text-align: left; }
.ax-t { margin: 0; font-size: 15px; font-weight: 600; line-height: 1.3; }

/* A card that waits: head, facts, answers, footer. */
.ax-perm { display: flex; flex-direction: column; padding: 0; gap: 0; }
.ax-head { display: grid; grid-template-columns: 28px minmax(0, 1fr); column-gap: 10px; align-items: center; padding: 12px 16px; border-bottom: .5px solid var(--sep); }
.ax-head .ax-t { grid-column: 2; font-size: 14px; }
.ax-tile { grid-column: 1; grid-row: 1 / span 2; align-self: start; width: 28px; height: 28px; border-radius: 7px; background-color: var(--accent-fill); background-repeat: no-repeat; background-position: center; background-size: 16px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 3.500 5 6.200v5.300c0 4.300 2.900 7.400 7 9 4.100-1.600 7-4.700 7-9V6.200z'/%3E%3Cpath d='m9 12 2.200 2.200L15.200 10'/%3E%3C/svg%3E"); }
.ax-tile.q { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='8.500'/%3E%3Cpath d='M9.700 9.500a2.400 2.400 0 1 1 3.400 2.200c-.7.400-1.100.9-1.100 1.700M12 16.500v.01'/%3E%3C/svg%3E"); }
.ax-why { grid-column: 2; margin: 2px 0 0; color: var(--warn-t); font-size: 12.5px; line-height: 1.4; }
.ax-body { display: flex; flex-direction: column; gap: 10px; padding: 12px 16px 4px; }
.ax-body > :last-child { margin-bottom: 8px; }
.ax-body > .ax-text, .ax-body > .ax-fold .ax-text { padding: 10px 12px; border-radius: var(--r-s); background: var(--raise); font-family: var(--font-mono); font-size: 13px; }
.ax-body > .ax-fold { margin: 0; }
.ax-act { padding: 8px 16px 14px; }
.ax-foot { padding: 4px 8px; border-top: .5px solid var(--sep); background: var(--page); }
.ax-foot .btn { width: 100%; justify-content: flex-start; padding: 0 8px; color: var(--accent); font-size: 13px; font-weight: 600; }
.ax-foot .btn:hover { color: var(--accent); }
.ax-body:empty { display: none; }

.ax-field { display: grid; grid-template-columns: minmax(64px, 22%) minmax(0, 1fr); column-gap: 12px; align-items: baseline; }
.ax-label { margin: 0; }
/* A command, an address or a text: shown whole, in the page's own words, with line breaks kept and no side scrolling. */
.ax-text { margin: 0; padding: 0; border: 0; background: none; color: var(--fg); font: inherit; font-size: 14px; line-height: 1.45; white-space: pre-wrap; overflow-wrap: anywhere; max-height: 50vh; overflow: auto; }
.ax-fold summary { min-height: 44px; display: flex; align-items: center; color: var(--muted); font-size: 13px; font-weight: 600; cursor: pointer; }
.ax-fold[open] summary { min-height: 32px; }
.ax-btns { display: flex; gap: 8px; }
.ax-btns .btn { flex: 1; min-height: 44px; }
.ax-q { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.ax-q li { display: flex; flex-direction: column; gap: 2px; }
.ax-rule { white-space: pre-wrap; }

@media (min-width: 900px) {
  .si[data-view="approvals"] { padding: 48px 32px 48px calc(232px + 32px); }
}

/* Let a Mac approve (enroll.js): the fingerprint to compare with the Mac's own card. */
.ax-fp { margin: 4px 0; padding: 12px; border-radius: var(--r-s); background: var(--raise); font-size: 28px; font-weight: 600; letter-spacing: .08em; font-variant-numeric: tabular-nums; text-align: center; }

/* The technical reason under a passkey message (approvals.js): small, plain text, there so a screenshot says what failed on a phone. */
.ap-detail { margin: -4px 0 0; font-size: 12px; color: var(--muted); text-align: left; overflow-wrap: anywhere; }
.ap-detail[hidden] { display: none; }

/* One look (app.css): a waiting card is a group like any other on the chat screens, its title the size of a row's. */
.ax-card { border-radius: 12px; }
.ax-head .ax-t { font-size: 15px; font-weight: 600; }
.ax-body .ax-label { font-size: 13px; }
.ax-text { font-size: 14px; line-height: 20px; }
