/**
 * VetHogar - Doctor Portal Styles (/mi-agenda/)
 */

/* Login View */
.vh-login-wrapper { max-width: 520px; margin: 40px auto; padding: 0 20px; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; color: #1e293b; }
.vh-login-card { background: #ffffff; border: 1px solid #e2e8f0; border-radius: 20px; padding: 36px 30px; box-shadow: 0 10px 30px rgba(12, 35, 64, 0.08); }
.vh-login-header { text-align: center; margin-bottom: 24px; }
.vh-login-icon { width: 56px; height: 56px; background: #e0f2fe; color: #0284c7; font-size: 28px; display: flex; align-items: center; justify-content: center; border-radius: 16px; margin: 0 auto 12px auto; }
.vh-login-badge { background: #f0fdf4; color: #166534; font-size: 11px; font-weight: 700; padding: 4px 10px; border-radius: 12px; text-transform: uppercase; letter-spacing: 0.5px; border: 1px solid #bbf7d0; }
.vh-login-title { font-size: 22px; font-weight: 800; color: #0c2340; margin: 12px 0 6px 0; }
.vh-login-desc { font-size: 13px; color: #64748b; margin: 0; line-height: 1.5; }
.vh-login-error { background: #fee2e2; border: 1px solid #fca5a5; color: #b91c1c; padding: 10px 14px; border-radius: 8px; font-size: 13px; margin-bottom: 18px; display: flex; align-items: center; gap: 8px; }
.vh-login-form .vh-form-group { margin-bottom: 16px; }
.vh-login-form label { display: block; font-size: 13px; font-weight: 600; color: #334155; margin-bottom: 6px; }
.vh-login-form input[type="text"],
.vh-login-form input[type="password"] { width: 100%; box-sizing: border-box; padding: 12px 14px; border: 1.5px solid #cbd5e1; border-radius: 10px; font-size: 14px; background: #f8fafc; transition: all 0.2s; }
.vh-login-form input:focus { outline: none; border-color: #0284c7; background: #fff; box-shadow: 0 0 0 3px rgba(2, 132, 199, 0.15); }
.vh-form-row { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; font-size: 12px; color: #64748b; }
.vh-remember-label { display: flex; align-items: center; gap: 6px; cursor: pointer; }
.vh-btn-login { width: 100%; background: #0284c7; color: #ffffff; border: none; padding: 14px; border-radius: 10px; font-size: 15px; font-weight: 700; cursor: pointer; box-shadow: 0 4px 12px rgba(2, 132, 199, 0.3); transition: all 0.2s; }
.vh-btn-login:hover { background: #0369a1; transform: translateY(-1px); }
.vh-login-footer { margin-top: 24px; padding-top: 18px; border-top: 1px solid #e2e8f0; font-size: 12px; color: #64748b; }
.vh-login-demo-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; margin: 6px 0 12px 0; font-size: 11px; }
.vh-login-footer code { background: #f1f5f9; padding: 2px 5px; border-radius: 4px; color: #0f172a; font-weight: 600; }

/* Main Portal View */
.vh-agenda-wrapper { max-width: 1080px; margin: 30px auto; padding: 0 20px; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; color: #1e293b; }

/* Barra de Usuario */
.vh-user-topbar { background: #0c2340; color: #fff; padding: 14px 22px; border-radius: 12px; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; margin-bottom: 20px; box-shadow: 0 4px 15px rgba(12, 35, 64, 0.1); }
.vh-user-left { display: flex; align-items: center; gap: 12px; }
.vh-user-avatar { font-size: 24px; background: rgba(255,255,255,0.1); width: 38px; height: 38px; display: flex; align-items: center; justify-content: center; border-radius: 8px; }
.vh-user-left strong { font-size: 15px; color: #fff; display: block; }
.vh-user-left small { color: #93c5fd; font-size: 12px; }
.vh-user-right { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.vh-mem-pill { font-size: 12px; font-weight: 700; padding: 4px 12px; border-radius: 20px; }
.vh-mem-pill-active { background: #dcfce7; color: #15803d; }
.vh-mem-pill-warn { background: #fef3c7; color: #b45309; }
.vh-mem-pill-danger { background: #fee2e2; color: #b91c1c; }
.vh-mem-pill-none { background: #f1f5f9; color: #64748b; }
.vh-btn-logout { background: rgba(255,255,255,0.15); color: #fff; text-decoration: none; padding: 5px 12px; border-radius: 6px; font-size: 12px; font-weight: 600; transition: background 0.2s; }
.vh-btn-logout:hover { background: rgba(255,255,255,0.25); }

/* Banners de Alerta */
.vh-banner-alert { display: flex; gap: 16px; align-items: center; border-radius: 12px; padding: 18px 22px; margin-bottom: 24px; }
.vh-banner-warning { background: #fffbeb; border: 1.5px solid #fde68a; color: #92400e; }
.vh-banner-danger { background: #fef2f2; border: 1.5px solid #fecaca; color: #991b1b; }
.vh-alert-icon { font-size: 28px; }
.vh-alert-body strong { font-size: 15px; display: block; margin-bottom: 4px; }
.vh-alert-body p { margin: 0 0 10px 0; font-size: 13px; line-height: 1.4; }
.vh-alert-btn { background: #0c2340; color: #fff; border: none; padding: 7px 14px; border-radius: 6px; font-weight: 700; font-size: 12px; cursor: pointer; }
.vh-alert-btn:hover { background: #1e3a8a; }

/* Header */
.vh-agenda-header { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 20px; background: #ffffff; border: 1px solid #e2e8f0; border-radius: 16px; padding: 24px; box-shadow: 0 4px 20px rgba(12, 35, 64, 0.04); margin-bottom: 20px; }
.vh-agenda-badge { background: #e0f2fe; color: #0284c7; font-weight: 700; font-size: 12px; padding: 4px 12px; border-radius: 20px; text-transform: uppercase; letter-spacing: 0.5px; }
.vh-agenda-title { font-size: 22px; font-weight: 800; color: #0c2340; margin: 8px 0 4px 0; }
.vh-agenda-subtitle { color: #64748b; font-size: 13px; margin: 0; }
.vh-agenda-select-box label { font-weight: 700; font-size: 12px; color: #0f172a; display: block; margin-bottom: 4px; }
.vh-agenda-select-box select { padding: 8px 12px; border: 2px solid #0284c7; border-radius: 8px; font-size: 13px; font-weight: 600; color: #0c2340; background: #fff; min-width: 220px; }

/* Tabs */
.vh-portal-tabs { display: flex; gap: 10px; margin-bottom: 24px; border-bottom: 2px solid #e2e8f0; padding-bottom: 1px; }
.vh-tab-btn { background: none; border: none; padding: 12px 20px; font-size: 15px; font-weight: 700; color: #64748b; cursor: pointer; position: relative; border-bottom: 3px solid transparent; margin-bottom: -3px; display: flex; align-items: center; gap: 8px; }
.vh-tab-btn:hover { color: #0284c7; }
.vh-tab-btn.active { color: #0284c7; border-bottom-color: #0284c7; }
.vh-tab-dot { width: 8px; height: 8px; background: #f59e0b; border-radius: 50%; }
.vh-tab-content { display: none; }
.vh-tab-content.active { display: block; }

/* Google Sync Card */
.vh-agenda-sync-card { background: linear-gradient(135deg, #0c2340, #1e3a8a); color: #fff; border-radius: 12px; padding: 20px; margin-bottom: 26px; box-shadow: 0 4px 15px rgba(12, 35, 64, 0.12); }
.vh-sync-left { display: flex; gap: 16px; align-items: center; }
.vh-sync-icon { font-size: 30px; }
.vh-sync-left strong { font-size: 15px; color: #ffffff; display: block; margin-bottom: 4px; }
.vh-sync-left p { margin: 0 0 10px 0; color: #93c5fd; font-size: 13px; }
.vh-sync-link-wrap { display: flex; gap: 8px; max-width: 600px; }
.vh-sync-link-wrap input { flex: 1; padding: 8px 12px; border-radius: 6px; border: none; font-size: 12px; background: rgba(255,255,255,0.15); color: #fff; }
.vh-sync-link-wrap button { background: #38bdf8; color: #0c2340; font-weight: 700; border: none; border-radius: 6px; padding: 8px 16px; cursor: pointer; font-size: 12px; }

/* Citas Cards */
.vh-agenda-list-title { font-size: 18px; font-weight: 800; color: #0c2340; margin-bottom: 18px; }
.vh-agenda-cards-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 20px; }
.vh-c-card { background: #ffffff; border: 1px solid #e2e8f0; border-radius: 14px; padding: 20px; box-shadow: 0 2px 10px rgba(0,0,0,0.03); display: flex; flex-direction: column; justify-content: space-between; }
.vh-c-card-completed { opacity: 0.7; background: #f8fafc; }
.vh-c-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
.vh-c-slot { background: #e0f2fe; color: #0369a1; font-weight: 700; font-size: 12px; padding: 4px 10px; border-radius: 20px; }
.vh-c-status { font-size: 11px; font-weight: 700; padding: 3px 8px; border-radius: 10px; }
.vh-c-status-pending { background: #fef3c7; color: #b45309; }
.vh-c-status-confirmed { background: #dcfce7; color: #15803d; }
.vh-c-status-completed { background: #f1f5f9; color: #475569; }

.vh-c-patient { display: flex; gap: 12px; align-items: center; margin-bottom: 12px; }
.vh-c-paw { font-size: 24px; background: #f1f5f9; width: 42px; height: 42px; display: flex; align-items: center; justify-content: center; border-radius: 10px; }
.vh-c-pname { margin: 0; font-size: 16px; font-weight: 700; color: #0f172a; }
.vh-c-pname small { color: #64748b; font-weight: 500; font-size: 12px; }
.vh-c-tname { margin: 2px 0 0 0; font-size: 13px; color: #475569; }
.vh-c-loc { display: flex; gap: 8px; font-size: 13px; color: #334155; margin-bottom: 10px; background: #f8fafc; padding: 8px 10px; border-radius: 8px; }
.vh-c-addons { font-size: 12px; color: #0284c7; background: #f0fdf4; padding: 6px 10px; border-radius: 6px; margin-bottom: 10px; }
.vh-c-price { display: flex; justify-content: space-between; font-size: 13px; padding-top: 8px; border-top: 1px dashed #cbd5e1; margin-bottom: 14px; }
.vh-c-price strong { color: #0c2340; font-size: 15px; }

.vh-c-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.vh-btn-act { text-align: center; padding: 8px; border-radius: 8px; text-decoration: none; font-weight: 700; font-size: 12px; display: flex; align-items: center; justify-content: center; gap: 4px; }
.vh-btn-wa { background: #25d366; color: #fff; }
.vh-btn-wa:hover { background: #1eb855; }
.vh-btn-maps { background: #0284c7; color: #fff; }
.vh-btn-maps:hover { background: #0369a1; }
.vh-empty-agenda { background: #f8fafc; border: 2px dashed #cbd5e1; border-radius: 12px; padding: 40px; text-align: center; color: #64748b; font-size: 15px; }

/* Tab 2: Membresía */
.vh-metrics-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; margin-bottom: 24px; }
.vh-metric-box { background: #fff; border: 1px solid #e2e8f0; border-radius: 14px; padding: 20px; box-shadow: 0 2px 10px rgba(0,0,0,0.02); }
.vh-m-label { font-size: 12px; font-weight: 600; color: #64748b; text-transform: uppercase; letter-spacing: 0.5px; }
.vh-m-val { font-size: 22px; font-weight: 800; margin: 8px 0 4px 0; }
.vh-metric-box small { color: #64748b; font-size: 12px; }

.vh-history-card { background: #ffffff; border: 1px solid #e2e8f0; border-radius: 14px; padding: 24px; margin-bottom: 24px; box-shadow: 0 2px 10px rgba(0,0,0,0.02); }
.vh-history-title { font-size: 17px; font-weight: 800; color: #0c2340; margin: 0 0 4px 0; }
.vh-table-responsive { overflow-x: auto; }
.vh-portal-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.vh-portal-table th { background: #f8fafc; padding: 10px 12px; text-align: left; font-size: 12px; color: #475569; border-bottom: 2px solid #e2e8f0; }
.vh-portal-table td { padding: 12px; border-bottom: 1px solid #e2e8f0; vertical-align: middle; }
.vh-pill-period { background: #e0f2fe; color: #0369a1; padding: 3px 8px; border-radius: 10px; font-weight: 700; font-size: 11px; }
.vh-portal-table code { background: #f1f5f9; padding: 3px 6px; border-radius: 4px; font-size: 12px; }
.vh-status-verified { background: #dcfce7; color: #166534; padding: 3px 8px; border-radius: 10px; font-weight: 700; font-size: 11px; }

.vh-renewal-card { background: #f8fafc; border: 1.5px dashed #cbd5e1; border-radius: 14px; padding: 24px; display: grid; grid-template-columns: 1fr 340px; gap: 24px; align-items: center; }
@media (max-width: 800px) { .vh-renewal-card { grid-template-columns: 1fr; } }
.vh-renewal-info h4 { margin: 0 0 6px 0; font-size: 16px; color: #0c2340; }
.vh-renewal-info p { margin: 0 0 14px 0; font-size: 13px; color: #475569; }
.vh-bank-details { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; font-size: 12px; background: #fff; padding: 12px; border-radius: 8px; border: 1px solid #e2e8f0; }
.vh-b-item span { color: #64748b; }
.vh-renewal-action { text-align: center; }
.vh-btn-notify-pay { display: inline-block; width: 100%; box-sizing: border-box; background: #25d366; color: #fff; text-decoration: none; padding: 14px 18px; border-radius: 10px; font-weight: 800; font-size: 14px; box-shadow: 0 4px 12px rgba(37, 211, 102, 0.3); }
.vh-btn-notify-pay:hover { background: #1eb855; }
.vh-renewal-action small { display: block; margin-top: 8px; font-size: 11px; color: #64748b; }

/* Acciones operativas médicas en terreno */
.vh-c-clinical-notes { background: #f0fdf4; border: 1px solid #bbf7d0; border-radius: 8px; padding: 10px 14px; margin: 12px 0; font-size: 13px; color: #166534; }
.vh-c-clinical-notes strong { display: block; margin-bottom: 4px; font-size: 12px; color: #14532d; }
.vh-c-clinical-notes p { margin: 0; white-space: pre-wrap; font-size: 12px; }

.vh-doctor-ops { margin-top: 14px; padding-top: 12px; border-top: 1px dashed #e2e8f0; }
.vh-ops-btns { display: flex; gap: 8px; flex-wrap: wrap; }
.vh-btn-op { flex: 1; min-width: 140px; padding: 10px 14px; border: none; border-radius: 8px; font-weight: 700; font-size: 13px; cursor: pointer; transition: all 0.2s; display: inline-flex; align-items: center; justify-content: center; }
.vh-btn-op-complete { background: #10b981; color: #ffffff; }
.vh-btn-op-complete:hover { background: #059669; }
.vh-btn-op-cancel { background: #f1f5f9; color: #64748b; border: 1px solid #cbd5e1; }
.vh-btn-op-cancel:hover { background: #fee2e2; color: #b91c1c; border-color: #fca5a5; }

.vh-status-drawer { background: #f8fafc; border: 1px solid #e2e8f0; border-radius: 8px; padding: 12px; margin-top: 10px; }
.vh-status-drawer label { display: block; font-size: 12px; font-weight: 700; color: #334155; margin-bottom: 6px; }
.vh-status-drawer textarea { width: 100%; box-sizing: border-box; border: 1.5px solid #cbd5e1; border-radius: 6px; padding: 8px; font-family: inherit; font-size: 13px; resize: vertical; }
.vh-status-drawer textarea:focus { outline: none; border-color: #0284c7; }
.vh-drawer-actions { display: flex; gap: 8px; margin-top: 8px; justify-content: flex-end; }
.vh-btn-confirm-save { background: #0284c7; color: #ffffff; border: none; padding: 8px 16px; border-radius: 6px; font-weight: 700; font-size: 13px; cursor: pointer; }
.vh-btn-confirm-save:hover { background: #0369a1; }
.vh-btn-close-drawer { background: #e2e8f0; color: #475569; border: none; padding: 8px 12px; border-radius: 6px; font-size: 13px; cursor: pointer; }
.vh-btn-close-drawer:hover { background: #cbd5e1; }

.vh-ops-finished { padding: 8px 12px; background: #f0fdf4; border-radius: 6px; font-size: 12px; font-weight: 700; color: #166534; text-align: center; }
.vh-ops-cancelled { background: #fef2f2; color: #991b1b; }

.vh-c-status-completed { background: #dcfce7; color: #15803d; }
.vh-c-status-cancelled { background: #fee2e2; color: #991b1b; }
.vh-c-status-pending { background: #fef3c7; color: #b45309; }

.vh-status-completed { border-left: 4px solid #10b981; }
.vh-status-cancelled { opacity: 0.7; border-left: 4px solid #ef4444; }

/* ==========================================================================
   EXPEDIENTE CLÍNICO ELECTRÓNICO (FICHA MÉDICA VETERINARIA)
   ========================================================================== */

/* Botón en Tarjeta de Cita */
.vh-c-record-btn-wrap { margin-top: 10px; }
.vh-btn-record-main { width: 100%; box-sizing: border-box; padding: 11px 14px; border-radius: 10px; border: none; font-size: 13px; font-weight: 800; cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 8px; transition: all 0.2s; }
.vh-btn-record-main.vh-cr-status-completed { background: #dcfce7; color: #15803d; border: 1.5px solid #86efac; }
.vh-btn-record-main.vh-cr-status-completed:hover { background: #bbf7d0; }
.vh-btn-record-main.vh-cr-status-draft { background: #fef3c7; color: #b45309; border: 1.5px solid #fde68a; }
.vh-btn-record-main.vh-cr-status-draft:hover { background: #fde68a; }
.vh-btn-record-main.vh-cr-status-none { background: #e0f2fe; color: #0369a1; border: 1.5px solid #bae6fd; }
.vh-btn-record-main.vh-cr-status-none:hover { background: #0284c7; color: #ffffff; }

/* Modal Overlay & Container */
.vh-cr-overlay { position: fixed; top: 0; left: 0; right: 0; bottom: 0; background: rgba(12, 35, 64, 0.75); backdrop-filter: blur(4px); z-index: 999999; display: flex; align-items: center; justify-content: center; padding: 12px; }
.vh-cr-container { background: #f8fafc; width: 100%; max-width: 860px; height: 92vh; border-radius: 20px; box-shadow: 0 20px 50px rgba(0,0,0,0.3); display: flex; flex-direction: column; overflow: hidden; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; }

/* Header Fijo */
.vh-cr-header { background: #0c2340; color: #ffffff; padding: 14px 20px; display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-shrink: 0; }
.vh-cr-patient-summary { display: flex; align-items: center; gap: 12px; }
.vh-cr-patient-avatar { font-size: 26px; width: 44px; height: 44px; background: rgba(255,255,255,0.12); border-radius: 12px; display: flex; align-items: center; justify-content: center; }
.vh-cr-header-line1 { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.vh-cr-header-line1 strong { font-size: 16px; color: #ffffff; }
.vh-cr-tag-species { background: #0284c7; color: #ffffff; font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 10px; }
.vh-cr-status-badge { font-size: 11px; font-weight: 700; padding: 3px 8px; border-radius: 10px; }
.vh-cr-badge-draft { background: #fef3c7; color: #b45309; }
.vh-cr-badge-completed { background: #dcfce7; color: #15803d; }
.vh-cr-header-line2 { font-size: 12px; color: #93c5fd; margin-top: 2px; }
.vh-cr-close-btn { background: rgba(255,255,255,0.15); color: #fff; border: none; width: 34px; height: 34px; border-radius: 50%; font-size: 16px; font-weight: 700; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: background 0.2s; }
.vh-cr-close-btn:hover { background: rgba(255,255,255,0.3); }

/* Pestañas de Navegación Táctil */
.vh-cr-nav { display: flex; background: #ffffff; border-bottom: 1.5px solid #e2e8f0; overflow-x: auto; flex-shrink: 0; scrollbar-width: none; }
.vh-cr-nav::-webkit-scrollbar { display: none; }
.vh-cr-tab { flex: 1; min-width: 120px; padding: 12px 10px; background: none; border: none; border-bottom: 3px solid transparent; cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 6px; font-size: 13px; font-weight: 700; color: #64748b; white-space: nowrap; transition: all 0.2s; }
.vh-cr-tab:hover { color: #0284c7; background: #f1f5f9; }
.vh-cr-tab.active { color: #0284c7; border-bottom-color: #0284c7; background: #f0fdf4; }
.vh-cr-tab.vh-tab-complete .vh-cr-tab-num { background: #16a34a; color: #fff; }
.vh-cr-tab-num { width: 20px; height: 20px; border-radius: 50%; background: #e2e8f0; color: #475569; font-size: 11px; display: inline-flex; align-items: center; justify-content: center; }
.vh-cr-tab.active .vh-cr-tab-num { background: #0284c7; color: #fff; }
.vh-req-star { color: #dc2626; font-weight: 800; }

/* Contenido / Cuerpo con Scroll */
.vh-cr-body { flex: 1; overflow-y: auto; padding: 18px; }
.vh-cr-step { display: none; }
.vh-cr-step.active { display: block; animation: vhFadeIn 0.2s ease-in-out; }
@keyframes vhFadeIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: translateY(0); } }

.vh-cr-card-section { background: #ffffff; border: 1px solid #e2e8f0; border-radius: 14px; padding: 22px; box-shadow: 0 2px 8px rgba(0,0,0,0.02); }
.vh-cr-sec-head { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 18px; }
.vh-cr-sec-head-actions { justify-content: space-between; flex-wrap: wrap; gap: 12px; align-items: center; }
.vh-cr-sec-icon { font-size: 26px; }
.vh-cr-sec-head h4 { margin: 0 0 4px 0; font-size: 17px; color: #0c2340; font-weight: 800; }
.vh-cr-sec-head p { margin: 0; font-size: 13px; color: #64748b; line-height: 1.4; }
.vh-cr-sub-title { font-size: 14px; font-weight: 800; color: #0f172a; margin: 18px 0 10px 0; }
.vh-cr-divider { height: 1px; background: #e2e8f0; margin: 18px 0; }

/* Grids de Inputs */
.vh-cr-form-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.vh-cr-form-grid-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 14px; }
.vh-cr-field label { display: block; font-size: 12px; font-weight: 700; color: #334155; margin-bottom: 6px; }
.vh-cr-field input, .vh-cr-field select, .vh-cr-field textarea { width: 100%; box-sizing: border-box; border: 1.5px solid #cbd5e1; border-radius: 8px; padding: 10px 12px; font-size: 13px; color: #0f172a; font-family: inherit; background: #fff; }
.vh-cr-field input:focus, .vh-cr-field select:focus, .vh-cr-field textarea:focus { outline: none; border-color: #0284c7; box-shadow: 0 0 0 3px rgba(2, 132, 199, 0.12); }
.vh-cr-readonly-box { background: #f8fafc; border: 1.5px dashed #cbd5e1; padding: 10px 12px; border-radius: 8px; font-size: 13px; color: #475569; font-style: italic; }

/* Banner de Obligatoriedad */
.vh-cr-notice-mandatory { background: #fef2f2; border: 1.5px solid #fecaca; border-radius: 10px; padding: 12px 14px; display: flex; align-items: center; gap: 12px; margin-bottom: 18px; color: #991b1b; }
.vh-cr-notice-mandatory span { font-size: 22px; }
.vh-cr-notice-mandatory strong { font-size: 13px; display: block; margin-bottom: 2px; }
.vh-cr-notice-mandatory p { margin: 0; font-size: 12px; }

/* Tarjetas Biométricas Grandes para Móviles */
.vh-cr-biometrics-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 14px; }
.vh-cr-bio-card { background: #f8fafc; border: 1.5px solid #e2e8f0; border-radius: 12px; padding: 14px; display: flex; flex-direction: column; justify-content: space-between; transition: border-color 0.2s; }
.vh-cr-bio-card:focus-within { border-color: #0284c7; background: #fff; }
.vh-cr-bio-card-wide { grid-column: 1 / -1; }
.vh-cr-bio-header { display: flex; gap: 8px; align-items: flex-start; margin-bottom: 10px; }
.vh-cr-bio-icon { font-size: 20px; }
.vh-cr-bio-header label { font-size: 13px; font-weight: 800; color: #0c2340; margin: 0; display: block; }
.vh-cr-bio-header small { font-size: 11px; color: #64748b; }
.vh-cr-input-with-unit { display: flex; align-items: center; background: #fff; border: 2px solid #cbd5e1; border-radius: 8px; overflow: hidden; }
.vh-cr-input-with-unit input { flex: 1; border: none; padding: 10px 12px; font-size: 18px; font-weight: 800; color: #0c2340; width: 100%; box-sizing: border-box; }
.vh-cr-input-with-unit input:focus { outline: none; }
.vh-cr-unit { background: #f1f5f9; color: #475569; font-weight: 700; font-size: 13px; padding: 10px 14px; border-left: 1px solid #e2e8f0; }
.vh-cr-bio-hint { font-size: 11px; color: #64748b; margin-top: 6px; display: block; }

/* Selector Segmentado TLLC */
.vh-cr-segmented-toggle { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 8px; margin-top: 8px; }
.vh-cr-seg-btn { background: #fff; border: 1.5px solid #cbd5e1; border-radius: 8px; padding: 10px; font-size: 12px; font-weight: 700; color: #475569; cursor: pointer; transition: all 0.2s; text-align: center; }
.vh-cr-seg-btn.active { background: #0c2340; color: #fff; border-color: #0c2340; box-shadow: 0 2px 6px rgba(12, 35, 64, 0.25); }

/* Examen por Sistemas (10 Sistemas) */
.vh-btn-all-normal { background: #10b981; color: #fff; border: none; padding: 9px 16px; border-radius: 8px; font-weight: 800; font-size: 13px; cursor: pointer; transition: all 0.2s; box-shadow: 0 2px 8px rgba(16, 185, 129, 0.3); }
.vh-btn-all-normal:hover { background: #059669; }
.vh-cr-systems-list { display: flex; flex-direction: column; gap: 10px; margin-top: 14px; }
.vh-cr-sys-row { background: #f8fafc; border: 1.5px solid #e2e8f0; border-radius: 12px; padding: 14px; transition: border-color 0.2s; }
.vh-cr-sys-main { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; }
.vh-cr-sys-info { display: flex; align-items: center; gap: 10px; flex: 1; min-width: 200px; }
.vh-cr-sys-icon { font-size: 22px; width: 36px; height: 36px; background: #fff; border-radius: 8px; display: flex; align-items: center; justify-content: center; border: 1px solid #e2e8f0; }
.vh-cr-sys-info strong { font-size: 13px; color: #0f172a; display: block; }
.vh-cr-sys-info small { font-size: 11px; color: #64748b; line-height: 1.3; display: block; }
.vh-cr-sys-pills { display: flex; gap: 6px; }
.vh-sys-pill { border: 1.5px solid #cbd5e1; background: #fff; padding: 7px 12px; border-radius: 20px; font-size: 12px; font-weight: 700; color: #475569; cursor: pointer; transition: all 0.2s; }
.vh-pill-normal.active { background: #dcfce7; color: #15803d; border-color: #86efac; }
.vh-pill-abnormal.active { background: #fee2e2; color: #b91c1c; border-color: #fca5a5; }
.vh-pill-ne.active { background: #e2e8f0; color: #475569; border-color: #94a3b8; }
.vh-cr-sys-notes-wrap { margin-top: 10px; padding-top: 10px; border-top: 1px dashed #cbd5e1; }
.vh-cr-sys-notes-wrap textarea { width: 100%; box-sizing: border-box; border: 1.5px solid #f87171; border-radius: 8px; padding: 8px 10px; font-size: 12px; font-family: inherit; background: #fff; }

/* Barra Inferior Fija (Footer de Acciones) */
.vh-cr-footer { background: #ffffff; border-top: 1.5px solid #e2e8f0; padding: 12px 20px; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px; flex-shrink: 0; }
.vh-cr-footer-right { display: flex; gap: 8px; flex-wrap: wrap; }
.vh-btn-cr-draft { background: #f1f5f9; color: #334155; border: 1px solid #cbd5e1; padding: 11px 18px; border-radius: 10px; font-weight: 700; font-size: 13px; cursor: pointer; }
.vh-btn-cr-draft:hover { background: #e2e8f0; }
.vh-btn-cr-finalize { background: #16a34a; color: #ffffff; border: none; padding: 11px 20px; border-radius: 10px; font-weight: 800; font-size: 13px; cursor: pointer; box-shadow: 0 4px 12px rgba(22, 163, 74, 0.3); transition: all 0.2s; }
.vh-btn-cr-finalize:hover { background: #15803d; }
.vh-btn-cr-print { background: #0284c7; color: #ffffff; border: none; padding: 11px 14px; border-radius: 10px; font-weight: 700; font-size: 13px; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; }
.vh-btn-cr-print:hover { background: #0369a1; }
.vh-btn-cr-wa { background: #25d366; color: #ffffff; border: none; padding: 11px 14px; border-radius: 10px; font-weight: 700; font-size: 13px; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; }
.vh-btn-cr-wa:hover { background: #1eb855; }

/* Toast flotante */
.vh-cr-toast { position: fixed; bottom: 30px; left: 50%; transform: translateX(-50%); background: #0c2340; color: #ffffff; padding: 10px 20px; border-radius: 30px; font-weight: 700; font-size: 13px; box-shadow: 0 10px 25px rgba(0,0,0,0.3); z-index: 1000000; animation: vhFadeIn 0.2s; }

/* Banner de Modo Solo Lectura / Atención Bloqueada */
.vh-cr-locked-banner { background: #fffbeb; border-bottom: 2px solid #fef08a; padding: 12px 18px; display: flex; align-items: flex-start; gap: 12px; }
.vh-cr-locked-icon { font-size: 22px; flex-shrink: 0; line-height: 1; margin-top: 2px; }
.vh-cr-locked-body strong { color: #92400e; font-size: 13px; display: block; margin-bottom: 3px; font-weight: 800; }
.vh-cr-locked-body p { margin: 0; font-size: 12px; color: #b45309; line-height: 1.45; }
.vh-cr-locked-body span { font-weight: 700; color: #78350f; }

/* Indicador visual de campos bloqueados por inmutabilidad */
.vh-cr-field-locked { background-color: #f1f5f9 !important; border-color: #cbd5e1 !important; color: #475569 !important; cursor: not-allowed !important; opacity: 0.85; }
.vh-cr-field-locked:focus { outline: none !important; border-color: #cbd5e1 !important; }

/* Historial Longitudinal de Paciente (Timeline) */
.vh-cr-history-list { display: flex; flex-direction: column; gap: 14px; margin-top: 14px; }
.vh-cr-history-item { background: #ffffff; border: 1.5px solid #e2e8f0; border-radius: 12px; padding: 16px; box-shadow: 0 2px 6px rgba(0,0,0,0.03); transition: border-color 0.2s, box-shadow 0.2s; }
.vh-cr-history-item:hover { border-color: #0c2340; box-shadow: 0 4px 12px rgba(12, 35, 64, 0.08); }
.vh-cr-history-top { display: flex; justify-content: space-between; align-items: flex-start; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; border-bottom: 1px dashed #e2e8f0; padding-bottom: 10px; }
.vh-cr-history-date { font-weight: 800; font-size: 14px; color: #0c2340; display: flex; align-items: center; gap: 6px; }
.vh-cr-history-vet { font-size: 12px; color: #64748b; font-weight: 600; margin-top: 2px; }
.vh-cr-history-badge { font-size: 11px; font-weight: 700; padding: 4px 10px; border-radius: 12px; }
.vh-cr-history-badge-completed { background: #dcfce7; color: #166534; }
.vh-cr-history-badge-draft { background: #fef3c7; color: #92400e; }

.vh-cr-history-bio { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.vh-cr-history-bio-tag { background: #f8fafc; border: 1px solid #e2e8f0; border-radius: 6px; padding: 4px 8px; font-size: 11px; font-weight: 700; color: #334155; }

.vh-cr-history-details { font-size: 12px; color: #334155; line-height: 1.5; margin-bottom: 12px; }
.vh-cr-history-details strong { color: #0c2340; }
.vh-cr-history-details p { margin: 4px 0 0 0; }

.vh-cr-history-actions { display: flex; justify-content: flex-end; }
.vh-cr-history-btn-view { background: #0c2340; color: #ffffff; border: none; padding: 8px 14px; border-radius: 8px; font-size: 12px; font-weight: 700; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; transition: background 0.2s; }
.vh-cr-history-btn-view:hover { background: #1e3a8a; }

.vh-cr-empty-history { text-align: center; padding: 30px 20px; background: #f8fafc; border: 2px dashed #cbd5e1; border-radius: 12px; color: #64748b; font-size: 14px; }
.vh-cr-empty-history p { margin: 0; }

/* Estilos de Impresión */
@media print {
    body * { visibility: hidden !important; }
    #vh-cr-print-view, #vh-cr-print-view * { visibility: visible !important; }
    #vh-cr-print-view { position: absolute; left: 0; top: 0; width: 100%; display: block !important; padding: 20px; background: #fff !important; }
}

/* Responsivo Móvil */
@media (max-width: 680px) {
    .vh-cr-overlay { padding: 0; }
    .vh-cr-container { height: 100vh; max-height: 100vh; border-radius: 0; }
    .vh-cr-form-grid-2, .vh-cr-form-grid-3 { grid-template-columns: 1fr; }
    .vh-cr-biometrics-grid { grid-template-columns: 1fr 1fr; }
    .vh-cr-footer { flex-direction: column; }
    .vh-cr-footer-left, .vh-cr-footer-right { width: 100%; }
    .vh-btn-cr-draft, .vh-btn-cr-finalize, .vh-btn-cr-print, .vh-btn-cr-wa { width: 100%; justify-content: center; }
}