/* Плашки, ярлыки, модалка, тост, тултип. */
.am-badge{display:inline-flex;align-items:center;gap:var(--space-3);padding:4px 10px;border-radius:var(--radius-sm);font:var(--fw-semibold) var(--fs-caption) / 1.25 var(--font-text);white-space:nowrap}
.am-badge--neutral{background:var(--sand-100);color:var(--text-body)}
.am-badge--brand{background:var(--orange-500);color:var(--sand-50)}
.am-badge--brandSoft{background:var(--orange-50);color:var(--orange-700)}
.am-badge--ok{background:var(--status-ok-bg);color:var(--status-ok-fg)}
.am-badge--warn{background:var(--status-warn-bg);color:var(--status-warn-fg)}
.am-badge--error{background:var(--status-error-bg);color:var(--status-error-fg)}
.am-badge--info{background:var(--status-info-bg);color:var(--status-info-fg)}
.am-badge--outline{background:transparent;color:var(--text-body);box-shadow:inset 0 0 0 1px var(--border-default)}
.am-badge--onBrand{background:rgba(255,249,241,.18);color:var(--sand-50)}
.am-badge--pill{border-radius:var(--radius-pill);padding-left:12px;padding-right:12px}
.am-tag{display:inline-flex;align-items:center;gap:var(--space-4);padding:9px 16px;border-radius:var(--radius-pill);border:1px solid var(--border-default);background:var(--surface-card);color:var(--text-body);font:var(--fw-medium) var(--fs-body-sm) / 1 var(--font-text);cursor:pointer;transition:var(--transition-control);white-space:nowrap}
.am-tag:hover{border-color:var(--sand-900);color:var(--text-strong)}
.am-tag:focus-visible{outline:none;box-shadow:var(--focus-ring)}
.am-tag--selected{background:var(--sand-900);border-color:var(--sand-900);color:var(--sand-50)}
.am-tag--selected:hover{background:#2f2a25;color:var(--sand-50)}
.am-tag--static{cursor:default}
.am-tag--static:hover{border-color:var(--border-default);color:var(--text-body)}
.am-overlay{position:fixed;inset:0;background:var(--surface-overlay);display:flex;align-items:center;justify-content:center;padding:var(--space-8);z-index:60;animation:am-fade var(--dur-base) var(--ease-out)}
.am-dialog{background:var(--surface-card);border-radius:var(--radius-modal);width:100%;max-width:520px;max-height:88%;overflow:auto;box-shadow:var(--shadow-lg);animation:am-rise var(--dur-base) var(--ease-out)}
.am-dialog--wide{max-width:720px}
.am-dialog__head{display:flex;align-items:flex-start;gap:var(--space-6);padding:var(--space-9) var(--space-9) 0}
.am-dialog__titles{flex:1;display:flex;flex-direction:column;gap:var(--space-3)}
.am-dialog__title{font:var(--type-h3);color:var(--text-strong);letter-spacing:var(--ls-heading)}
.am-dialog__sub{font:var(--type-body-sm);color:var(--text-muted)}
.am-dialog__body{padding:var(--space-8) var(--space-9);display:flex;flex-direction:column;gap:var(--space-6)}
.am-dialog__foot{display:flex;gap:var(--space-5);padding:0 var(--space-9) var(--space-9);flex-wrap:wrap}
@keyframes am-fade{from{opacity:0}to{opacity:1}}
@keyframes am-rise{from{opacity:0;transform:translateY(12px)}to{opacity:1;transform:none}}
.am-toast{display:flex;align-items:flex-start;gap:var(--space-5);padding:var(--space-6) var(--space-7);border-radius:var(--radius-md);background:var(--sand-900);color:var(--sand-50);box-shadow:var(--shadow-lg);max-width:420px;animation:am-rise var(--dur-base) var(--ease-out)}
.am-toast__icon{flex:none;margin-top:1px}
.am-toast__body{flex:1;display:flex;flex-direction:column;gap:2px}
.am-toast__title{font:var(--fw-semibold) var(--fs-body-sm) / 1.35 var(--font-text)}
.am-toast__text{font:var(--type-caption);color:rgba(255,249,241,.72)}
.am-toast--ok .am-toast__icon{color:#7fd6a4}
.am-toast--error .am-toast__icon{color:#f09a91}
.am-toast--info .am-toast__icon{color:var(--orange-300)}
.am-toast__close{flex:none;background:none;border:none;color:rgba(255,249,241,.6);cursor:pointer;padding:0;display:flex;transition:color var(--dur-fast) var(--ease-out)}
.am-toast__close:hover{color:var(--sand-50)}
.am-tooltip{position:relative;display:inline-flex}
.am-tooltip__bubble{position:absolute;bottom:calc(100% + 8px);left:50%;transform:translateX(-50%);background:var(--sand-900);color:var(--sand-50);font:var(--type-caption);padding:7px 11px;border-radius:var(--radius-sm);white-space:nowrap;opacity:0;pointer-events:none;transition:opacity var(--dur-fast) var(--ease-out),transform var(--dur-fast) var(--ease-out);z-index:40}
.am-tooltip__bubble--wrap{white-space:normal;width:240px}
.am-tooltip:hover .am-tooltip__bubble,.am-tooltip:focus-within .am-tooltip__bubble{opacity:1;transform:translateX(-50%) translateY(-2px)}
