.vet-panel {
    min-width: 0;
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 14px;
    box-shadow: 0 3px 14px rgba(29, 78, 216, .06);
}
.vet-stack, .vet-columns { display: grid; gap: 14px; }
.vet-columns { grid-template-columns: minmax(260px, .88fr) minmax(0, 1.12fr); align-items: start; }
.vet-form { max-width: 820px; }
.vet-wide { grid-column: 1 / -1; }
.vet-form > label + label { display: block; margin-top: 10px; }
.vet-form textarea {
    display: block; width: 100%; margin-top: 5px; padding: 8px 9px; resize: vertical;
    font: inherit; color: var(--ink); border: 1px solid #cbd5e1; border-radius: 7px;
}
.vet-table { max-width: 100%; overflow: auto; }
.vet-table td, .vet-table th { white-space: normal; }
.vet-table td { overflow-wrap: anywhere; }
.vet-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.vet-form > .vet-actions, .vet-pay { margin-top: 14px; }
.vet-form > .vet-tabs { margin: 0 0 14px; }
.vet-muted, .vet-meta { color: var(--muted); font-size: 13px; }
.vet-badge { display: inline-flex; align-items: center; border-radius: 999px; padding: 3px 10px; background: #e0f2fe; color: #0369a1; font-size: 12px; font-weight: 650; white-space: nowrap; }
.vet-badge.vencido, .vet-badge.cancelado, .vet-badge.alerta { background: #fee2e2; color: #b91c1c; }
.vet-badge.atendido, .vet-badge.ok { background: #dbeafe; color: #1d4ed8; }
.vet-badge.vacuna { background: #e0e7ff; color: #3730a3; }
.vet-badge.ctacte { background: #fef3c7; color: #92400e; }
.vet-wa { display: inline-flex; align-items: center; gap: 5px; padding: 4px 10px; border-radius: 999px; background: #e8eeff; color: #1d4ed8; font-size: 12px; font-weight: 650; text-decoration: none; border: 1px solid #bfdbfe; white-space: nowrap; }
.vet-wa:hover { background: #dbeafe; }
.vet-facts { display: flex; flex-wrap: wrap; gap: 10px 24px; margin: 0; }
.vet-facts dt { font-size: 12px; color: var(--muted); }
.vet-facts dd { margin: 2px 0 0; font-weight: 650; overflow-wrap: anywhere; }
.vet-alert-box { margin-top: 12px; padding: 9px 12px; border-radius: 9px; background: #fef2f2; border: 1px solid #fecaca; color: #991b1b; font-size: 13px; }
.vet-history, .vet-person { padding: 14px 0; border-top: 1px solid var(--line); }
.vet-history h3, .vet-history p { margin: 5px 0; }
.vet-history h3 { font-size: 16px; }
.vet-note { white-space: pre-wrap; overflow-wrap: anywhere; }
.vet-meta { display: flex; flex-wrap: wrap; gap: 7px; align-items: center; font-size: 13px; }
.vet-person { display: flex; flex-wrap: wrap; gap: 8px; justify-content: space-between; align-items: center; }
.vet-enmienda { margin: 8px 0 0 14px; padding: 8px 12px; border-left: 3px solid #2563eb; background: #f8fafc; border-radius: 0 8px 8px 0; font-size: 13px; }
.vet-enmienda-form { margin-top: 10px; padding: 10px 12px; border: 1px dashed #cbd5e1; border-radius: 9px; background: #f8fafc; }
.vet-total { display: grid; gap: 3px; }
.vet-total strong { font-size: 21px; color: #1d4ed8; }
.vet-money-neg { color: #b91c1c; font-weight: 700; }
.vet-money-pos { color: #1d4ed8; font-weight: 700; }
.vet-sr { position: absolute; clip-path: inset(50%); width: 1px; height: 1px; overflow: hidden; }
.vet-print main { max-width: 820px; margin: 0 auto; padding: 20px; }
.vet-print-nav { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; }
.vet-portal-wrap { max-width: 780px; margin: 0 auto; padding: 18px 14px 44px; display: grid; gap: 14px; }
.vet-portal-hero { background: linear-gradient(135deg, #1d4ed8 0%, #2563eb 60%, #38bdf8 100%); color: #fff; border-radius: 16px; padding: 20px; }
.vet-portal-hero h1 { margin: 4px 0 6px; font-size: 22px; color: #fff; }
.vet-portal-hero p { margin: 0; opacity: .94; font-size: 14px; }
.vet-rx-box { border: 2px solid #1d4ed8; border-radius: 12px; padding: 28px 32px; background: #fff; }
.vet-rx-sign { margin-top: 40px; display: flex; justify-content: flex-end; }
.vet-rx-sign > div { min-width: 220px; border-top: 1px solid #94a3b8; padding-top: 8px; text-align: center; font-size: 13px; }

@media (max-width: 760px) {
    .vet-columns { grid-template-columns: 1fr; }
    .panel-title, .page-head { flex-wrap: wrap; }
    .vet-table table { min-width: 540px; }
}
@media print {
    body.vet-print { background: #fff; color: #000; }
    .vet-print .vet-panel, .vet-print .panel { border: 0; box-shadow: none; }
    .vet-print-nav { display: none; }
}
