/* Tema claro y limpio (crema + blanco + dorado, títulos serif). Se carga DESPUÉS de app.css y sobrescribe variables y componentes. */
:root {
  --bg: #faf7f3; --surface: #ffffff; --ink: #2b2420; --muted: #7a6d63; --line: #ebe0d3;
  --brand: #9a6a1b; --brand-ink: #ffffff; --brand-soft: #f8efe0; --accent: #c9973f;
  --ok: #2d7a4f; --ok-bg: #e6f4ec; --bad: #b3372c; --bad-bg: #fcebe8; --warn: #8a5a00; --warn-bg: #fdf1d8; --info: #3a6a8c; --info-bg: #e8f1f8;
  --side: #ffffff; --side-ink: #4a3f37; --radius: 16px;
  --shadow: 0 1px 2px rgba(80, 55, 20, .05), 0 10px 28px rgba(80, 55, 20, .06);
  --serif: Georgia, "Palatino Linotype", Palatino, "Times New Roman", serif;
}
body { background: var(--bg); color: var(--ink); }
h1, h2 { font-family: var(--serif); font-weight: 500; letter-spacing: -.01em; }
h1 { font-size: 2.05rem; line-height: 1.1; }
h2 { font-size: 1.3rem; }
h3 { font-family: var(--serif); font-weight: 600; }
.eyebrow { margin: 0 0 4px; font-size: .72rem; letter-spacing: .22em; text-transform: uppercase; color: var(--brand); font-weight: 700; }

/* Barra lateral blanca */
.side { background: var(--side); color: var(--side-ink); border-right: 1px solid var(--line); padding: 22px 14px 28px; }
.side .brand { flex-direction: column; align-items: center; text-align: center; gap: 2px; padding: 6px 8px 22px; color: var(--ink); }
.side .brand .bn { font-family: var(--serif); font-size: 1.25rem; line-height: 1.15; color: var(--ink); }
.side .brand .bc { font-size: .62rem; letter-spacing: .26em; color: var(--brand); font-weight: 700; margin-top: 4px; }
.side .brand .mk { width: 46px; height: 46px; border-radius: 50%; background: var(--accent); color: #fff; display: grid; place-items: center; font-family: var(--serif); font-size: 1.1rem; margin-bottom: 8px; }
.side .grp { color: var(--muted); opacity: 1; font-size: .68rem; padding: 18px 14px 6px; }
.side a { color: var(--side-ink); border-radius: 12px; padding: 10px 14px; font-weight: 500; }
.side a:hover { background: #f7f0e8; }
.side a.on { background: #f5ece3; color: var(--ink); font-weight: 600; box-shadow: inset 3px 0 0 var(--accent); }
.side .cnt { background: var(--accent); }
.top { background: rgba(255, 255, 255, .88); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }

/* Tarjetas y KPI */
.card { border-radius: var(--radius); box-shadow: var(--shadow); border-color: var(--line); padding: 20px; }
.card > h2:first-child { margin-bottom: 14px; }
.kpi { border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px 20px; border-color: var(--line); transition: transform .15s, border-color .15s; }
.kpi:hover { transform: translateY(-2px); border-color: var(--accent); }
.kpi .n { font-family: var(--serif); font-weight: 500; font-size: 2rem; }
.kpi .l { font-size: .82rem; }

/* Botones, campos y tablas */
.btn { border-radius: 10px; font-weight: 600; }
.btn:not(.ghost):not(.secondary):not(.danger) { box-shadow: 0 6px 16px rgba(154, 106, 27, .22); }
.btn.ghost { background: #fff; color: var(--ink); border-color: var(--line); } .btn.ghost:hover { background: var(--brand-soft); border-color: var(--accent); }
.btn.secondary { background: var(--brand-soft); color: var(--brand); }
input, select, textarea { border-radius: 10px; border-color: var(--line); background: #fff; }
input:focus, select:focus, textarea:focus { border-color: var(--accent); outline: 2px solid rgba(201, 151, 63, .35); outline-offset: 0; }
.tbl th { color: var(--muted); font-size: .72rem; border-bottom: 1px solid var(--line); background: transparent; }
.tbl td { border-bottom-color: #f2eadf; }
.tbl tr:hover td { background: #fdf9f3; }
.tabs { border-bottom-color: var(--line); } .tabs a.on { border-color: var(--line); color: var(--brand); }
.pg { border-radius: 10px; }
.bubble { background: var(--brand-soft); } .bubble.out { background: var(--brand); }
.appt { background: var(--brand-soft); border-left: 3px solid var(--accent); }
.cal .day.today { border-color: var(--accent); box-shadow: 0 0 0 3px var(--brand-soft); }
.banner.warn { background: var(--warn-bg); } .flash { border-radius: 12px; }

/* Acceso */
.login { background: radial-gradient(circle at 20% 10%, #fffaf2, #f7ecdc 60%, #efe0c9); }
.login .card { box-shadow: 0 24px 60px rgba(80, 55, 20, .14); }
.login .brand-mark { background: var(--accent); }
.login h1 { font-family: var(--serif); }

/* Filtros de pacientes: campos y botones en la misma línea */
.filter-card { padding: 14px 16px; }
.filter-row { margin: 0; flex-wrap: wrap; align-items: flex-end; gap: 10px; }
.filter-row .field { margin: 0; }
.filter-row .field.grow { flex: 1 1 240px; max-width: 360px; }
.filter-actions { display: flex; gap: 8px; align-items: flex-end; flex-wrap: wrap; margin-left: auto; }
.filter-actions .btn { min-height: 40px; }
.more-filters { margin: 12px 0 0; padding-top: 12px; border-top: 1px solid var(--line); }
.more-filters[hidden] { display: none; }
.segments { margin-top: 10px; display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
@media (max-width: 640px) { .filter-actions { margin-left: 0; width: 100%; } .filter-actions .btn { flex: 1; } .filter-row .field.grow { max-width: none; } }
.filter-actions .btn { white-space: nowrap; }

/* Selector de iconos */
.emoji-bar .emoji-row { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 6px; }
.emoji-chip { width: 40px; height: 40px; font-size: 1.3rem; line-height: 1; background: #fff; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; transition: transform .1s, background .1s; }
.emoji-chip:hover { background: var(--brand-soft); transform: scale(1.12); }

/* Evita desbordes horizontales por textos largos sin espacios (JSON, URLs) */
.grid > *, .form-grid > * { min-width: 0; }
dl.kv dd, .card { overflow-wrap: anywhere; }

/* Barras de desplazamiento integradas al diseño */
.side { scrollbar-width: thin; scrollbar-color: #e3d3bb transparent; overscroll-behavior: contain; }
.side::-webkit-scrollbar { width: 8px; }
.side::-webkit-scrollbar-track { background: transparent; }
.side::-webkit-scrollbar-thumb { background: #eadcc6; border-radius: 999px; border: 2px solid transparent; background-clip: content-box; transition: background .2s; }
.side:hover::-webkit-scrollbar-thumb { background: #d9bd8a; background-clip: content-box; }
.side::-webkit-scrollbar-thumb:hover { background: var(--accent); background-clip: content-box; }
html { scrollbar-width: thin; scrollbar-color: #dcc7a3 var(--bg); }
html::-webkit-scrollbar { width: 12px; height: 12px; }
html::-webkit-scrollbar-track { background: var(--bg); }
html::-webkit-scrollbar-thumb { background: #e2d2b8; border-radius: 999px; border: 3px solid var(--bg); }
html::-webkit-scrollbar-thumb:hover { background: var(--accent); }
.table-wrap { scrollbar-width: thin; scrollbar-color: #dcc7a3 transparent; }
.table-wrap::-webkit-scrollbar { height: 8px; }
.table-wrap::-webkit-scrollbar-thumb { background: #e2d2b8; border-radius: 999px; }
/* Ventanas de confirmación */
.modal-backdrop { position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center; padding: 20px; background: rgba(47, 38, 32, .42); backdrop-filter: blur(3px); animation: mdlFade .16s ease both; }
.modal-backdrop.out { opacity: 0; transition: opacity .16s; }
.modal { width: min(440px, 100%); background: #fff; border-radius: 20px; padding: 28px 26px 22px; text-align: center; box-shadow: 0 30px 80px rgba(47, 38, 32, .28); border: 1px solid var(--line); animation: mdlPop .2s cubic-bezier(.2, .9, .3, 1.2) both; }
.modal-icon { width: 54px; height: 54px; border-radius: 50%; margin: 0 auto 14px; display: grid; place-items: center; font: 600 1.6rem var(--serif); background: var(--brand-soft); color: var(--brand); box-shadow: 0 0 0 8px #fcf6ea; }
.modal-icon.danger { background: var(--bad-bg); color: var(--bad); box-shadow: 0 0 0 8px #fdf3f1; }
.modal h2 { margin: 0 0 8px; font-size: 1.35rem; }
.modal p { margin: 0 0 22px; color: var(--muted); line-height: 1.5; }
.modal-actions { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.modal-actions .btn { min-width: 130px; }
@keyframes mdlFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes mdlPop { from { opacity: 0; transform: translateY(10px) scale(.96); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .modal-backdrop, .modal { animation: none; } }
@media (max-width: 480px) { .modal { padding: 24px 18px 18px; } .modal-actions .btn { flex: 1; min-width: 0; } }
.send-form { display: inline-flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.send-wa { display: inline-flex; align-items: center; gap: 6px; font-size: .88rem; color: var(--muted); cursor: pointer; }
.send-wa input { margin: 0; width: auto; min-height: 0; }

/* Selector de vista (Día / Semana / Mes) */
.seg { display: inline-flex; background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 3px; gap: 2px; }
.seg a { padding: 7px 16px; border-radius: 9px; color: var(--muted); font-weight: 600; text-decoration: none; min-height: 34px; display: inline-flex; align-items: center; }
.seg a:hover { background: var(--brand-soft); }
.seg a.on { background: var(--brand); color: #fff; box-shadow: 0 4px 12px rgba(154, 106, 27, .25); }

/* Agenda mensual */
.cal-head { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 8px; margin-bottom: 6px; }
.cal-head span { text-align: center; font-size: .72rem; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); font-weight: 700; }
.cal.month { grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 8px; }
.cal.month .day { min-height: 118px; padding: 8px; border-radius: 14px; display: flex; flex-direction: column; gap: 4px; transition: border-color .15s, box-shadow .15s; }
.cal.month .day:hover { border-color: var(--accent); }
.cal.month .day.other { background: transparent; border-style: dashed; opacity: .55; }
.cal.month .day h4 { display: flex; align-items: center; gap: 6px; margin: 0 0 2px; }
.cal.month .dn { font-family: var(--serif); font-size: 1.1rem; color: var(--ink); text-decoration: none; width: 28px; height: 28px; display: grid; place-items: center; border-radius: 50%; }
.cal.month .dn:hover { background: var(--brand-soft); }
.cal.month .day.today .dn { background: var(--brand); color: #fff; }
.cal.month .dname { display: none; font-size: .8rem; color: var(--muted); }
.cal.month .dcount { margin-left: auto; font-size: .7rem; font-weight: 700; background: var(--brand-soft); color: var(--brand); border-radius: 999px; padding: 1px 8px; }
.cal.month .appt { margin: 0; padding: 3px 6px; font-size: .74rem; line-height: 1.25; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; border-left-width: 3px; }
.cal.month .appt strong { font-variant-numeric: tabular-nums; }
.cal.month .more { font-size: .74rem; font-weight: 600; color: var(--brand); padding: 1px 6px; text-decoration: none; }
.appt.st-pending_confirm { background: #fdf1d8; border-left-color: #d9a441; }
.appt.st-confirmed { background: #e6f4ec; border-left-color: #2d7a4f; }
.appt.st-attended { background: #eef0f2; border-left-color: #8a949c; }
.appt.st-no_show { background: #fcebe8; border-left-color: #b3372c; }
.cal-legend { display: flex; gap: 14px; flex-wrap: wrap; align-items: center; margin-top: 12px; font-size: .8rem; }
.dot { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 4px; }
.dot.st-pending_confirm { background: #d9a441; } .dot.st-confirmed { background: #2d7a4f; } .dot.st-attended { background: #8a949c; } .dot.st-no_show { background: #b3372c; }
@media (max-width: 960px) { .cal.month { grid-template-columns: repeat(7, minmax(0, 1fr)); } .cal.month .day { min-height: 96px; padding: 6px; } .cal.month .dname { display: none; } }
@media (max-width: 640px) {
  /* En teléfono el mes se muestra como lista de los días con citas */
  .cal-head { display: none; }
  .cal.month { grid-template-columns: 1fr; }
  .cal.month .day.none, .cal.month .day.other { display: none; }
  .cal.month .day { min-height: 0; }
  .cal.month .dname { display: inline; }
  .cal.month .appt { white-space: normal; font-size: .85rem; padding: 6px 8px; }
}

/* Tableros */
.board-filters { display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: center; margin: 4px 0 6px; }
.seg.wrapseg { flex-wrap: wrap; }
.range-form { display: inline-flex; gap: 8px; align-items: center; flex-wrap: wrap; font-size: .85rem; color: var(--muted); }
.range-form input[type=date] { width: auto; min-height: 36px; padding: 5px 8px; }
.board-sub { margin: 0 0 14px; }
.bkpis { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-bottom: 16px; }
.bkpi { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.bk-l { font-size: .72rem; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); font-weight: 700; }
.bk-v { font: 500 1.9rem/1.1 var(--serif); color: var(--ink); }
.bk-f { min-height: 20px; }
.delta { display: inline-block; font-size: .78rem; font-weight: 700; padding: 1px 8px; border-radius: 999px; }
.delta.up { background: var(--ok-bg); color: var(--ok); } .delta.down { background: var(--bad-bg); color: var(--bad); } .delta.flat { background: #f3ede4; color: var(--muted); font-weight: 600; }
svg.chart { width: 100%; height: auto; display: block; }
svg.chart .grid { stroke: #efe6d8; stroke-width: 1; }
svg.chart .ax { fill: var(--muted); font: 11px system-ui, sans-serif; }
.c1 { fill: #c9973f; background: #c9973f; stroke: #c9973f; } .c2 { fill: #7d9f87; background: #7d9f87; stroke: #7d9f87; } .c3 { fill: #6f9bbd; background: #6f9bbd; stroke: #6f9bbd; }
.c4 { fill: #d4837a; background: #d4837a; stroke: #d4837a; } .c5 { fill: #8a5c14; background: #8a5c14; stroke: #8a5c14; } .c6 { fill: #cdb892; background: #cdb892; stroke: #cdb892; }
svg.chart .bar { stroke: none; } svg.chart .bar:hover { filter: brightness(1.08); }
.legend { display: flex; gap: 16px; flex-wrap: wrap; margin-top: 8px; font-size: .82rem; color: var(--muted); }
.sw { display: inline-block; width: 11px; height: 11px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; stroke: none; }
.hbars { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.hb-top { display: flex; justify-content: space-between; gap: 10px; font-size: .9rem; }
.hb-l { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hb-track { height: 9px; background: #f3ede4; border-radius: 999px; overflow: hidden; margin: 4px 0 2px; }
.hb-fill { height: 100%; border-radius: 999px; stroke: none; }
.donut-wrap { display: flex; gap: 22px; align-items: center; flex-wrap: wrap; }
svg.donut { width: 170px; height: 170px; flex: none; }
svg.donut circle { fill: none; stroke-width: 5.2; } svg.donut .ring-bg { stroke: #f3ede4; } svg.donut .seg { stroke-linecap: butt; }
svg.donut .dc { font: 500 4.6px var(--serif); fill: var(--ink); } svg.donut .dc2 { font: 2.6px system-ui, sans-serif; fill: var(--muted); }
.dlegend { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; flex: 1; min-width: 180px; font-size: .88rem; }
.dlegend li { display: flex; gap: 8px; align-items: center; } .dlegend li span { flex: 1; } .dlegend small { color: var(--muted); width: 34px; text-align: right; }
.stack { display: flex; height: 22px; border-radius: 999px; overflow: hidden; background: #f3ede4; margin-bottom: 14px; }
.stack div { height: 100%; }
@media (max-width: 960px) { .bkpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .bkpis { grid-template-columns: 1fr; } .bk-v { font-size: 1.6rem; } svg.donut { width: 140px; height: 140px; } }
@media print { .bkpi, .card { break-inside: avoid; } .seg, .range-form { display: none; } }
/* Fotos antes / después */
.compare { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 14px; }
.compare figure { margin: 0; text-align: center; }
.compare .ph { width: 100%; aspect-ratio: 4 / 5; border-radius: 16px; overflow: hidden; border: 1px solid var(--line); padding: 0; background: #f3ede4; cursor: zoom-in; }
.compare img { width: 100%; height: 100%; object-fit: cover; display: block; }
.compare figcaption { margin-top: 6px; font-size: .88rem; color: var(--muted); }
.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; margin: 8px 0 14px; }
.photo { margin: 0; }
.photo .ph { width: 100%; aspect-ratio: 1; border-radius: 14px; overflow: hidden; border: 1px solid var(--line); padding: 0; background: #f3ede4; cursor: zoom-in; display: block; }
.photo .ph:hover { border-color: var(--accent); box-shadow: 0 6px 18px rgba(80, 55, 20, .15); }
.photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.photo figcaption { font-size: .8rem; color: var(--muted); margin-top: 4px; }
.ph-rm summary { cursor: pointer; font-size: .78rem; color: var(--muted); } .ph-rm form { margin-top: 6px; }
.photo-preview { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; } .photo-preview .pv { width: 78px; height: 78px; object-fit: cover; border-radius: 10px; border: 1px solid var(--line); }
.modal-backdrop.viewer { background: rgba(30, 22, 16, .86); padding: 14px; }
.viewer-box { position: relative; max-width: min(96vw, 900px); max-height: 94vh; display: grid; }
.viewer-box img { max-width: 100%; max-height: 88vh; border-radius: 14px; box-shadow: 0 30px 80px rgba(0, 0, 0, .5); background: #fff; margin: auto; display: block; }
.viewer-x { position: absolute; top: -6px; right: -6px; background: #fff; }
@media (max-width: 520px) { .compare { gap: 8px; } .photo-grid { grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); } }
/* ===== Escala de las vistas al 90 % (sistema; no afecta la página pública) ===== */
@supports (zoom: 1) {
  html { zoom: .9; }
  /* con zoom, las unidades de viewport se miden sin escalar: se compensan para ocupar toda la pantalla */
  .shell { min-height: calc(100vh / .9); }
  .side { height: calc(100vh / .9); }
  .login { min-height: calc(100vh / .9); }
  @media (max-width: 960px) { .side { height: calc(100vh / .9); } }
}
@media print { html { zoom: 1; } }

/* ===== Panel de trabajo: tarjetas pequeñas en una sola línea ===== */
.kpi-row { display: flex; gap: 10px; margin-bottom: 14px; overflow-x: auto; padding: 2px 2px 6px; scrollbar-width: thin; }
.kpi-row .kpi { flex: 1 1 0; min-width: 132px; padding: 9px 12px; border-radius: 12px; box-shadow: 0 1px 2px rgba(80, 55, 20, .05); display: flex; align-items: center; gap: 10px; }
.kpi-row .kpi .n { font-size: 1.45rem; line-height: 1; min-width: 1ch; }
.kpi-row .kpi .l { font-size: .74rem; line-height: 1.2; color: var(--muted); }
.kpi-row .kpi:hover { transform: none; }
/* ===== Botón ☰: ocultar / mostrar el menú ===== */
.menu-btn { display: inline-flex !important; align-items: center; justify-content: center; width: 42px; padding: 0; font-size: 1.15rem; }
@media (min-width: 961px) {
  .shell { transition: grid-template-columns .22s ease; }
  body.side-collapsed .shell { grid-template-columns: 0 minmax(0, 1fr); }
  body.side-collapsed .side { visibility: hidden; opacity: 0; padding-left: 0; padding-right: 0; overflow: hidden; border-right-color: transparent; transition: opacity .15s ease, visibility 0s linear .2s; }
  body.side-collapsed .content { max-width: 1480px; }
}
@media print { .menu-btn { display: none !important; } }
/* ===== Acceso (login) a dos paneles ===== */
body.lg-body { margin: 0; background: #fbf7f1; }
.lg { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); min-height: 100vh; color: #2b2622; }
.lg-brand { position: relative; overflow: hidden; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 48px; color: #b8862f;
  background: radial-gradient(circle at 25% 15%, #fffdf9, #faf3e9 55%, #f6ebdd); border-right: 1px solid #ecdfc9; }
.lg-brand::before, .lg-brand::after { content: ""; position: absolute; border: 1px solid #e9d9b8; border-radius: 50%; pointer-events: none; }
.lg-brand::before { width: 640px; height: 640px; top: -420px; left: -80px; }
.lg-brand::after { width: 760px; height: 760px; bottom: -520px; right: -200px; }
.lg-brand > * { position: relative; }
.lg-name { font-family: var(--serif); font-weight: 400; font-size: clamp(2.4rem, 4.4vw, 4rem); line-height: 1.1; color: #26211d; margin: 22px 0 6px; letter-spacing: -.01em; }
.lg-sub { font-family: var(--serif); font-size: clamp(1.1rem, 1.8vw, 1.6rem); color: #b8862f; margin: 0; }
.lg-orn { display: flex; align-items: center; justify-content: center; gap: 14px; color: #b8862f; margin: 22px 0 6px; }
.lg-orn i { display: block; width: 84px; height: 1px; background: #d8bf8a; }
.lg-tag { color: #6e625a; max-width: 30ch; margin: 10px auto 0; font-size: 1rem; line-height: 1.5; }
.lg-panel { display: flex; align-items: center; justify-content: center; padding: 36px 28px; position: relative; overflow: hidden; }
.lg-card { width: min(470px, 100%); background: #fff; border: 1px solid #f0e6d6; border-radius: 28px; padding: 38px 40px 28px; box-shadow: 0 24px 60px rgba(120, 85, 30, .12); position: relative; }
.lg-head { display: none; text-align: center; color: #b8862f; }
.lg-hi { font-family: var(--serif); font-weight: 400; font-size: 2.6rem; text-align: center; margin: 4px 0 6px; color: #26211d; }
.lg-lead { text-align: center; color: #5c5148; margin: 0 0 22px; }
.lg-label { display: block; font-weight: 700; font-size: .84rem; margin: 14px 0 7px; color: #1f1b18; }
.lg-input { display: flex; align-items: center; gap: 10px; background: #fff; border: 1px solid #e6dccd; border-radius: 14px; padding: 0 14px; height: 52px; color: #7a6e64; transition: border-color .15s, box-shadow .15s; }
.lg-input:focus-within { border-color: #c9973f; box-shadow: 0 0 0 3px rgba(201, 151, 63, .18); }
.lg-input input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; font: inherit; color: #26211d; padding: 0; height: 100%; box-shadow: none; }
.lg-eye { border: 0; background: transparent; color: #5c5148; cursor: pointer; padding: 6px; border-radius: 8px; display: grid; place-items: center; }
.lg-eye:hover, .lg-eye[aria-pressed="true"] { color: #b8862f; }
.lg-btn { width: 100%; margin-top: 24px; height: 52px; border: 0; border-radius: 14px; background: #bd8a31; color: #fff; font: inherit; font-weight: 700; font-size: 1rem; cursor: pointer; box-shadow: 0 10px 22px rgba(189, 138, 49, .32); transition: transform .12s, background .15s; }
.lg-btn:hover { background: #a9791f; transform: translateY(-1px); }
.lg-btn:focus-visible { outline: 3px solid rgba(201, 151, 63, .45); outline-offset: 2px; }
.lg-foot { border-top: 1px solid #efe6d8; margin-top: 24px; padding-top: 16px; text-align: center; font-size: .86rem; color: #5c5148; }
.lg-foot p { margin: 0 0 8px; display: flex; align-items: center; justify-content: center; gap: 6px; }
.lg-foot a { color: #9a6a1b; text-decoration: none; font-weight: 600; }
.lg-foot a:hover { text-decoration: underline; }
.lg-card .flash { margin: 0 0 8px; border-radius: 12px; }
@media (max-width: 900px) {
  .lg { grid-template-columns: 1fr; }
  .lg-brand { display: none; }
  .lg-panel { background: radial-gradient(circle at 25% 10%, #fffdf9, #f8efe2); min-height: 100vh; padding: 20px 16px; }
  .lg-card { padding: 28px 22px 22px; border-radius: 24px; }
  .lg-head { display: block; margin-bottom: 8px; }
  .lg-name.sm { font-size: 1.7rem; margin: 8px 0 2px; }
  .lg-sub.sm { font-size: 1rem; }
  .lg-hi { font-size: 2.1rem; }
}
@supports (zoom: 1) { body.lg-body .lg { min-height: calc(100vh / .9); } }