@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&display=swap');

* { margin:0; padding:0; box-sizing:border-box; }
body { font-family:'Inter','Segoe UI',system-ui,-apple-system,sans-serif; background:#f1f5f9; color:#334155; line-height:1.6; -webkit-font-smoothing:antialiased; }
a { color:#2563eb; text-decoration:none; }
a:hover { text-decoration:underline; }
h1,h2,h3,h4,h5 { color:#0f172a; font-weight:700; }
img { max-width:100%; }

/* ── Layout helpers ── */
.container { max-width:1200px; margin:0 auto; padding:28px 20px; }
.row { display:flex; gap:16px; }
.col { flex:1; }
.text-center { text-align:center; }
.text-muted { color:#64748b; }
.mt-2 { margin-top:12px; }
.small { font-size:.8rem; }
.flex-between { display:flex; align-items:center; justify-content:space-between; gap:12px; flex-wrap:wrap; }
.flex-center { display:flex; align-items:center; gap:10px; }
.flex-wrap { flex-wrap:wrap; }

/* ── Navbar ── */
.navbar { position:sticky; top:0; z-index:1000; background:linear-gradient(90deg,#0f172a,#1e293b 60%,#1e3a5f); box-shadow:0 4px 20px rgba(15,23,42,.18); }
.nav-container { max-width:1200px; margin:0 auto; display:flex; justify-content:space-between; align-items:center; min-height:60px; padding:0 20px; gap:12px; }
.nav-brand { font-weight:800; font-size:1.05rem; color:#fff; letter-spacing:.2px; display:flex; align-items:center; gap:8px; }
.nav-brand::before { content:''; width:10px; height:10px; border-radius:50%; background:linear-gradient(135deg,#38bdf8,#818cf8); box-shadow:0 0 10px rgba(56,189,248,.7); }
.nav-right { display:flex; gap:8px; align-items:center; flex-wrap:wrap; justify-content:flex-end; }
.nav-user { font-size:.85rem; color:rgba(255,255,255,.85); font-weight:600; padding:4px 10px; background:rgba(255,255,255,.08); border-radius:8px; }
.navbar .btn { color:#fff; }

/* ── Buttons ── */
.btn { display:inline-block; padding:10px 20px; border:none; border-radius:10px; font-size:.9rem; font-weight:600; cursor:pointer; text-align:center; transition:all .2s; background:#e2e8f0; color:#475569; text-decoration:none !important; line-height:1.4; }
.btn:hover { transform:translateY(-1px); box-shadow:0 4px 12px rgba(15,23,42,.12); filter:brightness(1.03); }
.btn:active { transform:translateY(0); }
.btn-primary { background:linear-gradient(135deg,#2563eb,#4f46e5); color:#fff; box-shadow:0 4px 14px rgba(37,99,235,.28); }
.btn-primary:hover { background:linear-gradient(135deg,#1d4ed8,#4338ca); box-shadow:0 6px 18px rgba(37,99,235,.35); color:#fff; }
.btn-danger { background:#dc2626; color:#fff; }
.btn-danger:hover { background:#b91c1c; color:#fff; }
.btn-success { background:#16a34a; color:#fff; }
.btn-success:hover { background:#15803d; color:#fff; }
.btn-sm { padding:7px 14px; font-size:.8rem; border-radius:8px; }
.btn-full { width:100%; }
.btn2 { background:#16a34a; color:#fff; }
.btn2:hover { background:#15803d; color:#fff; }
.btn-green { background:#16a34a; color:#fff; }
.btn-green:hover { background:#15803d; color:#fff; }

/* ── Forms ── */
.form-group { position:relative; margin-bottom:16px; }
.form-group label { display:block; margin-bottom:6px; font-weight:600; font-size:.85rem; color:#1e293b; }
.form-group input,.form-group textarea,.form-group select { width:100%; padding:10px 14px; border:1px solid #cbd5e1; border-radius:10px; font-size:.95rem; font-family:inherit; background:#fff; color:#1e293b; transition:border-color .2s, box-shadow .2s; }
.form-group input:focus,.form-group textarea:focus,.form-group select:focus { outline:none; border-color:#2563eb; box-shadow:0 0 0 4px rgba(37,99,235,.12); }
.form-group textarea { resize:vertical; min-height:80px; }
.form-group input[type="file"] { padding:8px; background:#f8fafc; border-style:dashed; cursor:pointer; }
.form-group input[type="checkbox"], .form-group input[type="radio"] { width:auto; }
.form-row { display:grid; grid-template-columns:1fr 1fr; gap:16px; }
.form-row .full { grid-column:1 / -1; }
.add-form { display:flex; flex-wrap:wrap; gap:12px; align-items:flex-end; }

/* ── Alerts ── */
.alert { padding:14px 18px; border-radius:12px; margin-bottom:16px; font-size:.9rem; line-height:1.5; border:1px solid transparent; }
.alert-error { background:#fef2f2; color:#991b1b; border-color:#fecaca; }
.alert-error::first-line { font-weight:600; }
.alert-success { background:#f0fdf4; color:#166534; border-color:#bbf7d0; }
.alert-success a { color:#166534; font-weight:600; }
.alert-info { background:#eff6ff; color:#1e40af; border-color:#bfdbfe; }

/* ── Cards & sections ── */
.card { background:#fff; border-radius:14px; padding:24px; margin-bottom:18px; box-shadow:0 1px 3px rgba(15,23,42,.06),0 8px 24px rgba(15,23,42,.05); border:1px solid rgba(226,232,240,.7); }
.card h3 { margin-bottom:16px; font-size:1.05rem; color:#0f172a; }
.card h3:not(:first-child) { margin-top:4px; }
.section { margin-bottom:32px; }
.section h2 { font-size:1.2rem; font-weight:800; color:#0f172a; margin-bottom:16px; display:flex; align-items:center; gap:10px; letter-spacing:.2px; }
.section h2::before { content:''; width:5px; height:22px; border-radius:4px; background:linear-gradient(180deg,#2563eb,#7c3aed); flex-shrink:0; }
.section > h3 { font-size:1.05rem; margin-bottom:14px; }
.dashboard-header { margin-bottom:24px; }
.medico-info-card { background:#fff; border-radius:14px; padding:24px; box-shadow:0 1px 3px rgba(15,23,42,.06),0 8px 24px rgba(15,23,42,.05); border:1px solid rgba(226,232,240,.7); max-width:900px; margin:0 auto; }
.medico-info-card h2 { margin-bottom:14px; font-size:1.15rem; color:#0f172a; display:flex; align-items:center; gap:10px; }
.medico-info-card h2::before { content:''; width:5px; height:20px; border-radius:4px; background:linear-gradient(180deg,#2563eb,#7c3aed); }
.dashboard-actions { display:flex; gap:8px; flex-wrap:wrap; margin-top:12px; }
.folio-config { margin-top:14px; border:1px solid #e2e8f0; border-radius:12px; padding:14px 18px; background:#f8fafc; }
.folio-config summary { cursor:pointer; font-weight:700; color:#4f46e5; list-style:none; display:flex; align-items:center; gap:8px; }
.folio-config summary::-webkit-details-marker { display:none; }
.folio-config summary::before { content:'▸'; transition:transform .2s; font-size:.9rem; }
.folio-config[open] summary::before { transform:rotate(90deg); }

/* ── Tables ── */
.table-responsive { overflow-x:auto; border-radius:12px; }
.table { width:100%; border-collapse:separate; border-spacing:0; background:#fff; border-radius:12px; overflow:hidden; box-shadow:0 1px 3px rgba(15,23,42,.06),0 6px 18px rgba(15,23,42,.05); border:1px solid #e2e8f0; }
.table th,.table td { padding:12px 16px; text-align:left; border-bottom:1px solid #eef2f7; font-size:.9rem; }
.table th { background:#f8fafc; font-weight:700; color:#475569; font-size:.75rem; text-transform:uppercase; letter-spacing:.6px; }
.table tbody tr:last-child td { border-bottom:none; }
.table tbody tr { transition:background .15s; }
.table tbody tr:hover { background:#f8fafc; }
.table td strong { color:#0f172a; }
.info-table { width:100%; max-width:620px; margin:0 auto; border-collapse:collapse; }
.info-table th,.info-table td { text-align:left; padding:9px 12px; border-bottom:1px solid #f1f5f9; font-size:.9rem; }
.info-table th { width:150px; font-weight:600; color:#475569; }
.info-table tr:last-child th, .info-table tr:last-child td { border-bottom:none; }
.folio-destacado { font-size:1.25rem; font-weight:800; color:#2563eb; }

/* ── Login ── */
.login-body { display:flex; align-items:center; justify-content:center; min-height:100vh; padding:20px; background:linear-gradient(135deg,#0f172a 0%,#1e3a5f 55%,#7c3aed 130%); position:relative; overflow:hidden; }
.login-body::before { content:''; position:absolute; top:-30%; right:-15%; width:700px; height:700px; background:radial-gradient(circle,rgba(56,189,248,.18) 0%,transparent 70%); border-radius:50%; }
.login-body::after { content:''; position:absolute; bottom:-25%; left:-10%; width:600px; height:600px; background:radial-gradient(circle,rgba(139,92,246,.16) 0%,transparent 70%); border-radius:50%; }
.login-container { width:100%; max-width:520px; position:relative; z-index:1; }
.login-card { background:#fff; padding:40px; border-radius:18px; box-shadow:0 20px 60px rgba(0,0,0,.25); border:1px solid rgba(255,255,255,.4); }
.login-card h1 { text-align:center; margin-bottom:6px; font-size:1.6rem; color:#0f172a; }
.subtitle { text-align:center; color:#64748b; margin-bottom:26px; font-size:.9rem; }

/* ── Receta paper ── */
.receta-form { max-width:880px; margin:0 auto; }
.container:has(.receta-form) { max-width:920px; }
.receta-paper { background:#fff; border-radius:12px; padding:30px; box-shadow:0 2px 12px rgba(15,23,42,.1),0 12px 32px rgba(15,23,42,.06); border:1px solid #e2e8f0; position:relative; overflow:hidden; margin:0 auto 20px; max-width:820px; }
.receta-diseno-bg { position:absolute; top:0;left:0;right:0;bottom:0; opacity:.08; z-index:0; pointer-events:none; overflow:hidden; border-radius:12px; }
.diseno-bg-img { width:100%; height:100%; object-fit:cover; }
.receta-header { display:flex; flex-direction:column; align-items:center; text-align:center; position:relative; z-index:1; gap:16px; }
.receta-medico-info h2 { font-size:1.3rem; color:#0f172a; margin-bottom:8px; }
.receta-medico-info p { font-size:.85rem; color:#475569; margin-bottom:2px; }
.receta-medico-info p strong { color:#334155; }
.receta-folio { text-align:center; flex-shrink:0; }
.folio-box { background:linear-gradient(135deg,#0f172a,#1e293b); color:#fff; padding:16px 22px; border-radius:12px; min-width:130px; box-shadow:0 6px 18px rgba(15,23,42,.25); }
.folio-label { display:block; font-size:.72rem; text-transform:uppercase; letter-spacing:1.2px; opacity:.75; }
.folio-numero { display:block; font-size:2rem; font-weight:900; line-height:1.2; }
.receta-divider { border-top:2px dashed #cbd5e1; margin:22px 0; position:relative; z-index:1; }
.receta-seccion { margin-bottom:16px; position:relative; z-index:1; }
.receta-seccion h3,.receta-paciente h3,.receta-contenido h3 { font-size:1rem; color:#0f172a; margin-bottom:8px; }
.receta-seccion .contenido-texto { min-height:auto; padding:10px 12px; }
.receta-paciente { display:flex; flex-direction:column; align-items:center; text-align:center; gap:6px; position:relative; z-index:1; }
.receta-paciente p { font-size:.85rem; margin-bottom:2px; }
.contenido-texto { min-height:120px; padding:14px 16px; background:#f8fafc; border-radius:10px; font-size:.9rem; line-height:1.7; white-space:pre-wrap; border:1px solid #eef2f7; }
.receta-footer { display:flex; flex-direction:column; align-items:center; text-align:center; margin-top:24px; position:relative; z-index:1; gap:16px; }
.receta-firma { text-align:center; }
.linea-firma { width:200px; border-top:2px solid #475569; margin-bottom:6px; }
.receta-firma p { font-size:.8rem; color:#64748b; }
.receta-publica { margin-bottom:24px; }
.receta-marca-agua { position:absolute; inset:0; display:flex; align-items:center; justify-content:center; z-index:0; opacity:.06; pointer-events:none; font-size:3rem; font-weight:900; color:#334155; text-transform:uppercase; letter-spacing:6px; }

.print-actions { display:flex; gap:10px; justify-content:center; margin-top:20px; flex-wrap:wrap; }
.print-actions form { display:inline; }

/* ── Search / results ── */
.folio-info { font-size:1.1rem; margin-bottom:4px; color:#0f172a; }
.folio-info strong { color:#2563eb; font-size:1.4rem; }
.diseno-preview { margin-top:16px; padding-top:16px; border-top:1px solid #e2e8f0; }
.diseno-preview h3 { font-size:.9rem; margin-bottom:8px; color:#475569; }
.diseno-img { max-width:300px; max-height:200px; border:1px solid #e2e8f0; border-radius:8px; }
.busqueda-form { margin-bottom:24px; }
.recetas-encontradas { margin-top:24px; }
.recetas-encontradas h2 { font-size:1.2rem; margin-bottom:4px; color:#0f172a; }

/* ── Badges ── */
.badge, .badge-estado { display:inline-block; padding:4px 12px; border-radius:999px; font-size:.75rem; font-weight:700; line-height:1.5; background:#e2e8f0; color:#334155; white-space:nowrap; }
.badge-ges { display:inline-block; padding:3px 10px; border-radius:999px; font-size:.72rem; font-weight:700; background:#dbeafe; color:#1d4ed8; border:1px solid #bfdbfe; }
.badge-activa,.badge-confirmada { background:#dcfce7; color:#166534; }
.badge-cerrada,.badge-no_asistio { background:#f1f5f9; color:#475569; }
.badge-derivada,.badge-pendiente { background:#fef3c7; color:#92400e; }
.badge-en_consulta { background:#dbeafe; color:#1e40af; }
.badge-completada { background:#dcfce7; color:#166534; }
.badge-cancelada { background:#fee2e2; color:#991b1b; }

/* ── Pagination ── */
.pagination { display:flex; gap:6px; justify-content:center; flex-wrap:wrap; }
.pagination a { display:inline-block; padding:8px 14px; border-radius:8px; font-size:.85rem; font-weight:600; color:#334155; background:#fff; border:1px solid #e2e8f0; text-decoration:none; transition:all .2s; }
.pagination a:hover { border-color:#2563eb; color:#2563eb; background:#eff6ff; }

/* ── Utility components ── */
.actions, .action-buttons { display:flex; gap:10px; flex-wrap:wrap; }
.back-link a { font-weight:600; }
.success-box { text-align:center; padding:24px; }
.success-icon { width:72px; height:72px; border-radius:50%; background:linear-gradient(135deg,#16a34a,#22c55e); color:#fff; font-size:2rem; font-weight:900; display:flex; align-items:center; justify-content:center; margin:0 auto 16px; box-shadow:0 8px 24px rgba(22,163,74,.35); }
.success-details { max-width:480px; margin:0 auto; }
.codigo-box { background:#f8fafc; border:2px dashed #cbd5e1; border-radius:12px; padding:16px; margin-top:16px; }
.codigo-label { font-size:.75rem; text-transform:uppercase; letter-spacing:1px; color:#64748b; font-weight:600; }
.error-msg { color:#dc2626; font-size:.8rem; font-weight:600; margin-top:4px; }
.loading { text-align:center; color:#64748b; font-size:.85rem; padding:16px; }
.qr-info { background:#eff6ff; border:1px solid #bfdbfe; color:#1e40af; border-radius:10px; padding:10px 14px; font-size:.85rem; margin-top:8px; }
.valido { background:#f0fdf4; border:1px solid #86efac; color:#166534; border-radius:12px; padding:20px; font-size:1.05rem; font-weight:700; text-align:center; }
.invalido { background:#fef2f2; border:1px solid #fecaca; color:#991b1b; border-radius:12px; padding:20px; font-weight:600; text-align:center; }
.policy-body { max-width:820px; margin:0 auto; line-height:1.8; font-size:.95rem; }
.policy-body h1 { font-size:1.8rem; margin-bottom:8px; }
.policy-body .meta { color:#64748b; font-size:.8rem; margin-bottom:16px; }
.policy-body .highlight { background:#eff6ff; border-left:4px solid #2563eb; padding:14px 18px; border-radius:8px; margin:16px 0; }
.policy-body .essential { background:#fef3c7; border-left:4px solid #f59e0b; padding:14px 18px; border-radius:8px; margin:16px 0; }
.policy-body .rights-box { background:#f8fafc; border:1px solid #e2e8f0; padding:18px; border-radius:12px; margin:16px 0; }
.notas-box { background:#fffbeb; border:1px solid #fde68a; border-radius:10px; padding:12px 14px; font-size:.9rem; color:#92400e; }
.ficha-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(220px,1fr)); gap:10px 16px; }
.ficha-field { background:#f8fafc; border:1px solid #eef2f7; border-radius:10px; padding:10px 14px; }
.ficha-field label { display:block; font-size:.72rem; font-weight:700; text-transform:uppercase; letter-spacing:.5px; color:#64748b; margin-bottom:2px; }
.ficha-field span { font-size:.9rem; color:#0f172a; font-weight:600; }
.ficha-section { margin-bottom:24px; }
.ficha-section h3 { margin-bottom:12px; font-size:1rem; }
.ficha-text { background:#f8fafc; border:1px solid #eef2f7; border-radius:10px; padding:14px 16px; font-size:.9rem; white-space:pre-wrap; }
.detail-group { margin-bottom:16px; }
.detail-group h4 { font-size:.95rem; margin-bottom:8px; }
.detail-full { grid-column:1/-1; }
.detail-row { display:flex; gap:8px; padding:6px 0; border-bottom:1px dashed #e2e8f0; font-size:.9rem; }
.detail-row .label { width:140px; color:#64748b; font-weight:600; flex-shrink:0; }
.detail-row .value { color:#0f172a; font-weight:500; }
.disenos-grid, .disenos-miniatura { display:grid; grid-template-columns:repeat(auto-fill,minmax(140px,1fr)); gap:12px; }
.diseno-thumb, .diseno-mini { background:#fff; border:2px solid #e2e8f0; border-radius:10px; padding:8px; cursor:pointer; text-align:center; transition:all .2s; }
.diseno-thumb:hover, .diseno-mini:hover { border-color:#93c5fd; transform:translateY(-2px); }
.diseno-thumb.selected, .diseno-mini.selected { border-color:#2563eb; box-shadow:0 0 0 3px rgba(37,99,235,.15); }
.diseno-thumb img, .diseno-mini img { width:100%; height:90px; object-fit:cover; border-radius:6px; margin-bottom:6px; }
.diseno-thumb span, .diseno-mini span { font-size:.75rem; font-weight:600; color:#334155; }
.diseno-actions { display:flex; gap:8px; flex-wrap:wrap; margin-top:10px; }
.box { background:#fff; border-radius:12px; padding:20px; box-shadow:0 2px 8px rgba(15,23,42,.08); }
.ok { color:#16a34a; }
.err { color:#dc2626; }
.warn { background:#fffbeb; border:1px solid #fde68a; color:#92400e; padding:12px 16px; border-radius:10px; }
.steps { display:flex; align-items:center; gap:6px; }
.summary { padding:14px 18px; border-radius:10px; font-weight:700; }
.summary.ok { background:#f0fdf4; border:1px solid #bbf7d0; }
.summary.err { background:#fef2f2; border:1px solid #fecaca; }
.med-row { display:flex; gap:6px; margin-bottom:6px; flex-wrap:wrap; }
.nav-buttons { display:flex; gap:8px; align-items:center; }

/* ── Voice Dictation ── */
.vd-wrapper { position:relative; display:flex; align-items:center; gap:8px; margin-top:4px; }
.vd-btn {
    display:inline-flex; align-items:center; justify-content:center;
    width:36px; height:36px; border-radius:50%; border:2px solid #e2e8f0;
    background:#fff; color:#64748b; cursor:pointer; transition:all .2s; flex-shrink:0;
}
.vd-btn:hover { border-color:#93c5fd; color:#2563eb; background:#eff6ff; }
.vd-btn.vd-recording {
    border-color:#ef4444; color:#fff; background:#ef4444;
    animation:vd-pulse 1s ease-in-out infinite;
    box-shadow:0 0 0 4px rgba(239,68,68,.15);
}
.vd-btn.vd-unsupported { opacity:.4; cursor:not-allowed; border-color:#fde68a; color:#d97706; }
.vd-btn.vd-unsupported:hover { background:#fffbeb; }
@keyframes vd-pulse { 0%,100%{transform:scale(1);box-shadow:0 0 0 4px rgba(239,68,68,.15)} 50%{transform:scale(1.08);box-shadow:0 0 0 8px rgba(239,68,68,.08)} }
.vd-status { font-size:.75rem; color:#ef4444; font-weight:600; white-space:nowrap; }
.vd-status:empty { display:none; }
.vd-toast {
    position:fixed; bottom:24px; left:50%; transform:translateX(-50%) translateY(20px);
    padding:12px 24px; border-radius:12px; font-size:.85rem; font-weight:500;
    z-index:9999; opacity:0; transition:all .3s; pointer-events:none;
    box-shadow:0 8px 30px rgba(0,0,0,.15);
}
.vd-toast-show { opacity:1; transform:translateX(-50%) translateY(0); }
.vd-toast-info { background:#0f172a; color:#fff; }
.vd-toast-warning { background:#f59e0b; color:#fff; }
.vd-toast-error { background:#ef4444; color:#fff; }

/* ── Cookie Consent Banner (Ley 21.719) ── */
.cc-banner {
    position:fixed; bottom:0; left:0; right:0; z-index:10000;
    background:#fff; border-top:2px solid #2563eb;
    box-shadow:0 -4px 20px rgba(0,0,0,.12);
    padding:16px 20px; display:flex; justify-content:center;
}
.cc-banner-content {
    max-width:1200px; width:100%; display:flex; align-items:center;
    gap:16px; flex-wrap:wrap;
}
.cc-banner-text { flex:1; min-width:300px; }
.cc-banner-text strong { display:block; font-size:1rem; color:#0f172a; margin-bottom:4px; }
.cc-banner-text p { font-size:.82rem; color:#475569; line-height:1.5; margin:0; }
.cc-banner-text a { color:#2563eb; font-weight:600; }
.cc-banner-actions { display:flex; gap:8px; flex-shrink:0; }
.cc-btn {
    padding:10px 20px; border:none; border-radius:10px; font-size:.85rem;
    font-weight:700; cursor:pointer; transition:all .2s; white-space:nowrap;
}
.cc-btn-accept { background:#2563eb; color:#fff; }
.cc-btn-accept:hover { background:#1d4ed8; transform:translateY(-1px); }
.cc-btn-reject { background:#f1f5f9; color:#475569; border:1px solid #e2e8f0; }
.cc-btn-reject:hover { background:#e2e8f0; }
.cc-btn-config { background:transparent; color:#2563eb; text-decoration:underline; font-weight:600; }
.cc-btn-config:hover { color:#1d4ed8; }
.cc-preferences {
    position:fixed; bottom:0; left:0; right:0; z-index:10001;
    background:#fff; border-top:2px solid #2563eb;
    box-shadow:0 -4px 20px rgba(0,0,0,.12); padding:24px 20px;
    max-height:80vh; overflow-y:auto;
}
.cc-prefs-header { display:flex; justify-content:space-between; align-items:center; margin-bottom:16px; }
.cc-prefs-header h3 { font-size:1.1rem; color:#0f172a; margin:0; }
.cc-prefs-close { background:none; border:none; font-size:1.5rem; cursor:pointer; color:#64748b; padding:0 8px; }
.cc-prefs-close:hover { color:#ef4444; }
.cc-prefs-body { max-width:700px; }
.cc-pref-item {
    display:flex; justify-content:space-between; align-items:center;
    padding:12px 0; border-bottom:1px solid #f1f5f9; gap:16px;
}
.cc-pref-info { flex:1; }
.cc-pref-info strong { display:block; font-size:.9rem; color:#1e293b; margin-bottom:2px; }
.cc-pref-info p { font-size:.8rem; color:#64748b; margin:0; line-height:1.4; }
.cc-pref-toggle { display:flex; align-items:center; gap:6px; flex-shrink:0; }
.cc-pref-toggle label { font-size:.8rem; color:#475569; }
.cc-pref-toggle input[type="checkbox"] { width:16px; height:16px; accent-color:#2563eb; }
.cc-prefs-footer { margin-top:16px; text-align:right; }

/* ── Print ── */
@media print {
    body { background:#fff; }
    .navbar,.print-actions { display:none !important; }
    .receta-paper { box-shadow:none; border:1px solid #ddd; break-inside:avoid; }
}

/* ── Responsive ── */
@media(max-width:900px) {
    .nav-container { flex-wrap:wrap; justify-content:center; padding:10px 16px; gap:8px; }
    .nav-right { justify-content:center; }
}
@media(max-width:640px) {
    .row { flex-direction:column; gap:0; }
    .form-row { grid-template-columns:1fr; }
    .login-card { padding:28px 22px; }
    .receta-header { flex-direction:column; }
    .receta-paciente { flex-direction:column; gap:8px; }
    .receta-folio { margin-top:12px; align-self:center; }
    .receta-footer { flex-direction:column; align-items:center; gap:16px; }
    .folio-box { min-width:110px; padding:12px 16px; }
    .linea-firma { width:150px; }
    .cc-banner-content { flex-direction:column; text-align:center; }
    .cc-banner-actions { justify-content:center; width:100%; }
    .cc-btn { flex:1; min-width:80px; }
    .cc-pref-item { flex-direction:column; align-items:flex-start; }
}
