/* ============ Panel de administración ============ */
:root {
  --p: #6d28d9; --p-soft: #6d28d914; --p-dark: #5b21b6;
  --bg: #f4f4f7; --card: #fff; --text: #17161c; --muted: #6e6d7a; --line: #e8e7ee; --soft: #f7f7fa;
  --ok: #10b981; --warn: #f59e0b; --danger: #ef4444; --info: #3b82f6;
  --side: #17151f; --side-text: #c9c7d6;
  --radius: 14px; --shadow: 0 1px 2px rgba(20,18,30,.04), 0 4px 16px rgba(20,18,30,.05);
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { font-family: 'Plus Jakarta Sans', system-ui, -apple-system, Segoe UI, Roboto, sans-serif; background: var(--bg); color: var(--text); font-size: 14px; -webkit-font-smoothing: antialiased; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; }
input, select, textarea { font: inherit; color: inherit; }
a { color: var(--p); }
[hidden] { display: none !important; }
svg.lucide { width: 18px; height: 18px; stroke-width: 2; flex: none; }
.muted { color: var(--muted); } .small { font-size: 12px; }
.mobile-only { display: none !important; }

/* ---------- Login ---------- */
.login { min-height: 100vh; display: grid; place-items: center; padding: 16px; background: radial-gradient(circle at 20% 10%, var(--p-soft), transparent 50%), var(--bg); }
.login-card { width: 100%; max-width: 380px; background: var(--card); padding: 32px; border-radius: 20px; box-shadow: var(--shadow); display: grid; gap: 12px; text-align: center; }
.login-card h1 { margin: 6px 0 0; font-size: 22px; }
.login-card p { margin: 0; }
.brand-mark { width: 56px; height: 56px; border-radius: 16px; background: var(--p); display: grid; place-items: center; font-size: 28px; margin: 0 auto; }

/* ---------- Estructura ---------- */
.shell { display: flex; min-height: 100vh; }
.side { width: 248px; background: var(--side); color: var(--side-text); display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; flex: none; z-index: 40; }
.side-brand { display: flex; gap: 10px; align-items: center; padding: 18px 16px; border-bottom: 1px solid #ffffff12; }
.side-brand b { color: #fff; display: block; font-size: 14px; max-width: 160px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.side-brand small { font-size: 12px; }
.side-logo { width: 38px; height: 38px; border-radius: 10px; background: var(--p) center/cover; display: grid; place-items: center; color: #fff; font-weight: 800; flex: none; }
#nav { flex: 1; overflow-y: auto; padding: 10px 8px; }
.nav-group { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: #7d7a8f; padding: 14px 10px 6px; }
.navlink { display: flex; align-items: center; gap: 12px; width: 100%; padding: 9px 10px; border-radius: 10px; color: var(--side-text); text-decoration: none; font-weight: 500; }
.navlink:hover { background: #ffffff0d; color: #fff; }
.navlink.active { background: var(--p); color: #fff; }
.navlink .count { margin-left: auto; background: var(--danger); color: #fff; border-radius: 999px; font-size: 11px; padding: 1px 7px; font-weight: 700; }
.side-foot { padding: 8px; border-top: 1px solid #ffffff12; }
.content { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.top { position: sticky; top: 0; z-index: 30; background: var(--bg); display: flex; align-items: center; gap: 12px; padding: 14px 24px; border-bottom: 1px solid var(--line); }
.top h1 { margin: 0; font-size: 20px; letter-spacing: -.01em; }
.top-right { margin-left: auto; display: flex; gap: 8px; align-items: center; }
.main { padding: 22px 24px 60px; }
.store-toggle { display: inline-flex; align-items: center; gap: 8px; padding: 8px 12px; border-radius: 10px; font-weight: 700; font-size: 13px; }
.store-toggle.open { background: #10b98120; color: #047857; }
.store-toggle.closed { background: #ef444420; color: #b91c1c; }
.store-toggle .dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.mode-pill { font-size: 11px; font-weight: 700; padding: 4px 8px; border-radius: 6px; background: var(--line); color: var(--muted); }
.icon-btn { width: 36px; height: 36px; border-radius: 10px; display: inline-grid; place-items: center; background: var(--card); border: 1px solid var(--line); }
.icon-btn:hover { border-color: var(--p); color: var(--p); }
.icon-btn.sm { width: 30px; height: 30px; border-radius: 8px; }
.icon-btn.off { color: var(--muted); }
.side-backdrop { display: none; }

@media (max-width: 900px) {
  .mobile-only { display: inline-grid !important; }
  .side { position: fixed; left: 0; transform: translateX(-100%); transition: transform .2s; }
  .side.open { transform: none; }
  .side-backdrop.open { display: block; position: fixed; inset: 0; background: rgba(0,0,0,.4); z-index: 35; }
  .top { padding: 12px 16px; } .main { padding: 16px 16px 60px; }
  .mode-pill { display: none; }
}

/* ---------- Componentes ---------- */
.card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px; }
.card + .card { margin-top: 16px; }
.card h2 { margin: 0 0 4px; font-size: 16px; }
.card h3 { margin: 0 0 10px; font-size: 14px; }
.card-head { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; flex-wrap: wrap; }
.card-head h2 { margin: 0; }
.card-head .spacer { flex: 1; }
.grid { display: grid; gap: 16px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 1100px) { .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .g3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .g2, .g3, .g4 { grid-template-columns: 1fr; } }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 38px; padding: 0 14px; border-radius: 10px; font-weight: 600; background: var(--card); border: 1px solid var(--line); white-space: nowrap; text-decoration: none; color: var(--text); }
.btn:hover { border-color: #cfcdd9; }
.btn.primary { background: var(--p); border-color: var(--p); color: #fff; }
.btn.primary:hover { background: var(--p-dark); }
.btn.ok { background: var(--ok); border-color: var(--ok); color: #fff; }
.btn.danger { background: var(--danger); border-color: var(--danger); color: #fff; }
.btn.ghost-danger { color: var(--danger); }
.btn.sm { height: 32px; padding: 0 10px; font-size: 13px; border-radius: 8px; }
.btn.lg { height: 48px; font-size: 15px; padding: 0 20px; }
.btn.block { width: 100%; }
.btn:disabled { opacity: .5; cursor: not-allowed; }

input[type=text], input[type=number], input[type=password], input[type=email], input[type=tel], input[type=url], input[type=time], input[type=date], input[type=datetime-local], input:not([type]), select, textarea {
  width: 100%; height: 40px; border: 1px solid var(--line); border-radius: 10px; padding: 0 12px; background: var(--card); outline: 0;
}
textarea { height: auto; padding: 10px 12px; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--p); box-shadow: 0 0 0 3px var(--p-soft); }
input[type=color] { width: 48px; height: 40px; border: 1px solid var(--line); border-radius: 10px; padding: 3px; background: var(--card); }
input[type=checkbox], input[type=radio] { accent-color: var(--p); width: 17px; height: 17px; }
.field { display: grid; gap: 6px; margin-bottom: 14px; }
.field > label, .lbl { font-size: 13px; font-weight: 600; }
.field small, .help { color: var(--muted); font-size: 12px; }
.inline { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }

/* Interruptor */
.switch { position: relative; display: inline-flex; align-items: center; gap: 10px; cursor: pointer; font-weight: 600; }
.switch input { position: absolute; opacity: 0; width: 0; height: 0; }
.switch .tr { width: 40px; height: 22px; border-radius: 999px; background: #d4d3dc; position: relative; transition: .15s; flex: none; }
.switch .tr::after { content: ''; position: absolute; width: 18px; height: 18px; border-radius: 50%; background: #fff; top: 2px; left: 2px; transition: .15s; box-shadow: 0 1px 3px rgba(0,0,0,.2); }
.switch input:checked + .tr { background: var(--p); }
.switch input:checked + .tr::after { left: 20px; }
.set-row { display: flex; align-items: center; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.set-row:last-child { border-bottom: 0; }
.set-row > div:first-child { flex: 1; }
.set-row b { display: block; }
.set-row small { color: var(--muted); }

/* Tablas */
.table-wrap { overflow-x: auto; }
table.t { width: 100%; border-collapse: collapse; }
table.t th { text-align: left; font-size: 12px; color: var(--muted); font-weight: 600; padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; background: var(--soft); }
table.t td { padding: 11px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.t tr:hover td { background: var(--soft); }
table.t .num { text-align: right; white-space: nowrap; }
.thumb { width: 44px; height: 44px; border-radius: 10px; background: var(--soft) center/cover; display: grid; place-items: center; font-size: 22px; flex: none; }

.tag { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 700; padding: 3px 9px; border-radius: 999px; background: var(--line); color: var(--muted); white-space: nowrap; }
.tag.ok { background: #10b9811f; color: #047857; } .tag.warn { background: #f59e0b24; color: #b45309; }
.tag.bad { background: #ef44441f; color: #b91c1c; } .tag.info { background: #3b82f61f; color: #1d4ed8; } .tag.p { background: var(--p-soft); color: var(--p); }

.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 18px; overflow-x: auto; }
.tab { padding: 10px 14px; font-weight: 600; color: var(--muted); border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; }
.tab.active { color: var(--p); border-bottom-color: var(--p); }
.seg { display: inline-flex; background: var(--line); border-radius: 10px; padding: 3px; gap: 2px; flex-wrap: wrap; }
.seg button { padding: 6px 12px; border-radius: 8px; font-weight: 600; font-size: 13px; color: var(--muted); }
.seg button.active { background: var(--card); color: var(--text); box-shadow: var(--shadow); }

/* KPIs */
.kpi { display: flex; gap: 14px; align-items: center; }
.kpi .ic { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: var(--p-soft); color: var(--p); flex: none; }
.kpi b { font-size: 22px; display: block; letter-spacing: -.02em; }
.kpi span { color: var(--muted); font-size: 13px; }
.bars { display: flex; align-items: flex-end; gap: 10px; height: 180px; padding-top: 10px; }
.bars .bar { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; height: 100%; justify-content: flex-end; }
.bars .bar i { display: block; width: 100%; max-width: 46px; background: var(--p); border-radius: 8px 8px 3px 3px; min-height: 3px; }
.bars .bar small { font-size: 11px; color: var(--muted); }
.bars .bar em { font-style: normal; font-size: 11px; font-weight: 700; }
.hbar { display: grid; grid-template-columns: 1fr auto; gap: 4px 10px; margin-bottom: 10px; }
.hbar .track { grid-column: 1 / -1; height: 8px; background: var(--line); border-radius: 99px; overflow: hidden; }
.hbar .track i { display: block; height: 100%; background: var(--p); border-radius: 99px; }

/* ---------- Pedidos (Kanban) ---------- */
.board { display: grid; grid-template-columns: repeat(5, minmax(250px, 1fr)); gap: 14px; overflow-x: auto; padding-bottom: 10px; align-items: start; }
.col { background: #ebeaf0; border-radius: 14px; padding: 10px; min-height: 300px; }
.col-head { display: flex; align-items: center; gap: 8px; padding: 4px 6px 10px; font-weight: 700; }
.col-head .dot { width: 10px; height: 10px; border-radius: 50%; }
.col-head .n { margin-left: auto; background: var(--card); border-radius: 999px; padding: 1px 9px; font-size: 12px; }
.ocard { background: var(--card); border-radius: 12px; padding: 12px; margin-bottom: 10px; box-shadow: var(--shadow); cursor: pointer; border-left: 4px solid transparent; }
.ocard:hover { outline: 2px solid var(--p-soft); }
.ocard.new { animation: pulse 1.2s ease-in-out 3; }
@keyframes pulse { 50% { box-shadow: 0 0 0 6px #f59e0b55; } }
.ocard .row { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.ocard .num { font-weight: 800; font-size: 15px; }
.ocard ul { margin: 8px 0; padding: 0; list-style: none; color: var(--muted); font-size: 13px; }
.ocard .actions { display: flex; gap: 6px; margin-top: 8px; }
.ocard .actions .btn { flex: 1; }

/* ---------- POS ---------- */
.pos { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 16px; height: calc(100vh - 110px); }
.pos-left { display: flex; flex-direction: column; min-height: 0; min-width: 0; }
.pos-cats { display: flex; gap: 6px; overflow-x: auto; padding: 10px 0; flex: none; }
.pos-cats button { padding: 8px 14px; border-radius: 10px; background: var(--card); border: 1px solid var(--line); font-weight: 600; white-space: nowrap; }
.pos-cats button.active { background: var(--p); color: #fff; border-color: var(--p); }
.pos-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; overflow-y: auto; align-content: start; padding: 2px; }
.pitem { background: var(--card); border-radius: 12px; padding: 10px; text-align: left; box-shadow: var(--shadow); border: 2px solid transparent; display: flex; flex-direction: column; gap: 8px; }
.pitem:hover { border-color: var(--p); }
.pitem .thumb { width: 100%; height: 90px; font-size: 36px; }
.pitem b { font-size: 13px; line-height: 1.3; }
.pitem span { font-weight: 800; color: var(--p); }
.pitem.out { opacity: .45; pointer-events: none; }
.ticket { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); display: flex; flex-direction: column; min-height: 0; }
.ticket-head { padding: 14px; border-bottom: 1px solid var(--line); display: grid; gap: 10px; }
.ticket-items { flex: 1; overflow-y: auto; padding: 4px 14px; }
.titem { display: grid; grid-template-columns: auto 1fr auto; gap: 10px; padding: 10px 0; border-bottom: 1px dashed var(--line); align-items: start; }
.titem .q { display: flex; align-items: center; gap: 4px; }
.titem small { display: block; color: var(--muted); }
.titem.sent { opacity: .75; }
.ticket-foot { padding: 14px; border-top: 1px solid var(--line); display: grid; gap: 8px; }
.ticket-foot .line { display: flex; justify-content: space-between; }
.ticket-foot .total { font-size: 20px; font-weight: 800; }
@media (max-width: 1000px) { .pos { grid-template-columns: minmax(0, 1fr); height: auto; } .pos-grid { max-height: 60vh; } }

/* ---------- Mesas ---------- */
.tables { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 12px; }
.tbl { aspect-ratio: 1.15; border-radius: 16px; background: var(--card); border: 2px solid var(--line); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; box-shadow: var(--shadow); }
.tbl b { font-size: 16px; }
.tbl.busy { border-color: var(--warn); background: #fffbeb; }
.tbl.ready { border-color: var(--ok); background: #ecfdf5; }
.tbl .amt { font-weight: 800; }

/* ---------- Cocina ---------- */
.kds { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.kcard { background: var(--card); border-radius: 14px; box-shadow: var(--shadow); overflow: hidden; display: flex; flex-direction: column; }
.kcard header { padding: 12px 14px; color: #fff; display: flex; justify-content: space-between; align-items: center; }
.kcard header b { font-size: 17px; }
.kcard .body { padding: 8px 14px; flex: 1; }
.kitem { display: flex; gap: 10px; padding: 8px 0; border-bottom: 1px dashed var(--line); cursor: pointer; align-items: flex-start; }
.kitem.done { text-decoration: line-through; color: var(--muted); }
.kitem b { font-size: 15px; }
.kitem small { display: block; color: var(--muted); }
.kitem .nt { color: #b45309; font-weight: 600; }
.kcard footer { padding: 10px 14px; }

/* ---------- Modal ---------- */
.modal { position: fixed; inset: 0; z-index: 60; display: grid; place-items: center; padding: 16px; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(15,13,25,.5); }
.modal-box { position: relative; background: var(--card); border-radius: 18px; width: 100%; max-width: 560px; max-height: calc(100vh - 32px); display: flex; flex-direction: column; box-shadow: 0 20px 60px rgba(0,0,0,.3); }
.modal-box.wide { max-width: 820px; }
.m-head { display: flex; align-items: center; gap: 10px; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.m-head h2 { margin: 0; font-size: 17px; flex: 1; }
.m-body { padding: 18px 20px; overflow-y: auto; }
.m-foot { padding: 14px 20px; border-top: 1px solid var(--line); display: flex; gap: 10px; justify-content: flex-end; flex-wrap: wrap; }

.toasts { position: fixed; right: 16px; bottom: 16px; z-index: 90; display: grid; gap: 8px; }
.toast { background: #17161c; color: #fff; padding: 12px 16px; border-radius: 12px; font-weight: 600; box-shadow: 0 10px 30px rgba(0,0,0,.25); animation: tin .2s; max-width: 340px; }
.toast.ok { background: #047857; } .toast.bad { background: #b91c1c; }
@keyframes tin { from { transform: translateY(10px); opacity: 0; } }

.empty { text-align: center; padding: 40px 16px; color: var(--muted); }
.empty svg.lucide { width: 36px; height: 36px; margin-bottom: 6px; }
.img-up { display: flex; align-items: center; gap: 12px; }
.img-up .prev { width: 84px; height: 84px; border-radius: 12px; background: var(--soft) center/cover; border: 1px dashed var(--line); display: grid; place-items: center; color: var(--muted); flex: none; }
.img-up.wide .prev { width: 200px; height: 84px; }
.qrbox { display: grid; place-items: center; padding: 16px; background: #fff; border-radius: 12px; border: 1px solid var(--line); }
.list-row { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.list-row:last-child { border-bottom: 0; }
.list-row .grow { flex: 1; min-width: 0; }
.opt-row { display: grid; grid-template-columns: 1fr 110px auto auto; gap: 8px; align-items: center; margin-bottom: 8px; }
.alert { padding: 12px 14px; border-radius: 12px; background: var(--p-soft); display: flex; gap: 10px; align-items: flex-start; margin-bottom: 16px; }
.alert.warn { background: #f59e0b1f; }
/* Formas de cobro del delivery */
.modes { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; }
.mode { position: relative; display: grid; gap: 4px; padding: 14px; border: 2px solid var(--line); border-radius: 14px; cursor: pointer; background: var(--card); }
.mode input { position: absolute; opacity: 0; }
.mode svg.lucide { color: var(--p); width: 22px; height: 22px; }
.mode small { color: var(--muted); font-size: 12px; line-height: 1.4; }
.mode.active { border-color: var(--p); background: var(--p-soft); }
.mode:hover { border-color: var(--p); }
.dmap { height: 440px; border-radius: 12px; border: 1px solid var(--line); overflow: hidden; z-index: 0; background: var(--soft); }
.dot-c { width: 14px; height: 14px; border-radius: 50%; display: inline-block; }
@media (max-width: 900px) { #dGrid { grid-template-columns: minmax(0, 1fr) !important; } .dmap { height: 340px; } }

/* Plan y suscripción */
.plan-bar { display: flex; align-items: center; gap: 10px; padding: 10px 24px; background: var(--p-soft); font-size: 13px; border-bottom: 1px solid var(--line); }
.plan-bar a { margin-left: auto; font-weight: 700; white-space: nowrap; }
.plan-bar.warn { background: #f59e0b24; } .plan-bar.bad { background: #ef44441f; } .plan-bar.info { background: #3b82f61f; }
.plan-card { border: 2px solid var(--line); box-shadow: none; display: flex; flex-direction: column; gap: 8px; }
.plan-card.current { border-color: var(--p); }
.plan-card .btn { margin-top: auto; }
.plan-price { font-size: 28px; font-weight: 800; letter-spacing: -.02em; }
.plan-price small { font-size: 13px; color: var(--muted); font-weight: 500; }
.plan-list { list-style: none; padding: 0; margin: 4px 0 8px; display: grid; gap: 6px; font-size: 13px; }
.plan-list li::before { content: '✓'; color: var(--ok); font-weight: 800; margin-right: 8px; }
.plan-list li.off { color: var(--muted); text-decoration: line-through; opacity: .6; }
.plan-list li.off::before { content: '✕'; color: var(--muted); }
.navlink .lock { width: 14px; height: 14px; margin-left: auto; opacity: .5; }
.step { display: flex; gap: 8px; align-items: center; padding: 10px 12px; border-radius: 10px; background: var(--soft); color: var(--text); text-decoration: none; font-weight: 600; font-size: 13px; }
.step svg.lucide { color: var(--muted); }
.step.ok { color: var(--muted); text-decoration: line-through; }
.step.ok svg.lucide { color: var(--ok); }
.step:hover { background: var(--p-soft); }

.kbd {font-family: ui-monospace, monospace; font-size: 11px; background: var(--line); padding: 2px 6px; border-radius: 5px; }

.bad-t { color: var(--danger) !important; font-weight: 700; }

/* ================= Editor de menú ================= */
.me-top { display: flex; align-items: flex-end; gap: 12px; }
.me-top .tabs { flex: 1; }
.save-state { font-size: 12px; color: var(--muted); padding-bottom: 12px; white-space: nowrap; }
.me { display: grid; grid-template-columns: minmax(0, 1fr) 420px; gap: 16px; align-items: start; }
.me-toolbar { display: flex; gap: 8px; margin-bottom: 12px; flex-wrap: wrap; }
.me-search { flex: 1; min-width: 180px; display: flex; align-items: center; gap: 8px; background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 0 10px; }
.me-search input { border: 0 !important; box-shadow: none !important; padding: 0; }
.me-cat { background: var(--card); border-radius: 14px; box-shadow: var(--shadow); margin-bottom: 12px; }
.me-cat.off .me-cname { color: var(--muted); text-decoration: line-through; }
.me-cat-h { display: flex; align-items: center; gap: 6px; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.me-cat-h .spacer { flex: 1; }
.me-cimg { width: 54px; height: 38px; border-radius: 8px; border: 1px dashed var(--line); background: var(--soft) center/cover; display: grid; place-items: center; color: var(--muted); cursor: pointer; flex: none; }
.me-cimg.has { border-style: solid; }
.me-cimg:hover { border-color: var(--p); color: var(--p); }
.me-emoji { width: 42px !important; text-align: center; padding: 0 !important; font-size: 18px; }
.me-cname { font-weight: 800; font-size: 15px; border-color: transparent !important; max-width: 340px; }
.me-cname:hover, .me-emoji:hover { border-color: var(--line) !important; }
.icon-btn.ghost { border-color: transparent; background: transparent; }
.icon-btn.ghost:hover { background: var(--soft); }
.me-prods { padding: 4px 8px 8px; }
.me-row { display: flex; align-items: center; gap: 10px; padding: 8px; border-radius: 12px; cursor: pointer; border: 2px solid transparent; }
.me-row:hover { background: var(--soft); }
.me-row.sel { border-color: var(--p); background: var(--p-soft); }
.me-row.off { opacity: .55; }
.me-row .thumb { width: 48px; height: 48px; }
.me-name { flex: 1; min-width: 0; }
.me-name b { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.me-name small { color: var(--muted); font-size: 12px; }
.me-move { display: flex; flex-direction: column; }
.me-move button { font-size: 9px; color: var(--muted); line-height: 1; padding: 2px 4px; }
.me-move button:hover { color: var(--p); }
.me-price-in { display: flex; align-items: center; border: 1px solid var(--line); border-radius: 10px; padding-left: 8px; background: var(--card); }
.me-price-in span { font-size: 12px; color: var(--muted); }
.me-price-in input { width: 84px !important; border: 0 !important; box-shadow: none !important; height: 34px; text-align: right; }
.me-price { font-size: 13px; white-space: nowrap; }
.me-empty { padding: 14px; color: var(--muted); font-size: 13px; }
.link { color: var(--p); font-weight: 700; }
.dd { position: relative; }
.dd-menu { display: none; position: absolute; right: 0; top: 100%; z-index: 20; background: var(--card); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 12px 30px rgba(0,0,0,.15); padding: 6px; min-width: 210px; }
.dd-menu.open { display: block; }
.dd-menu button { display: flex; gap: 10px; align-items: center; width: 100%; padding: 9px 10px; border-radius: 8px; text-align: left; font-weight: 600; font-size: 13px; }
.dd-menu button:hover { background: var(--soft); }
.dd-menu button.danger { color: var(--danger); }
.me-right { position: sticky; top: 76px; background: var(--card); border-radius: 16px; box-shadow: var(--shadow); max-height: calc(100vh - 96px); display: flex; flex-direction: column; overflow: hidden; }
.me-placeholder { display: grid; place-items: center; text-align: center; gap: 8px; padding: 60px 24px; color: var(--muted); }
.me-placeholder svg.lucide { width: 40px; height: 40px; color: var(--p); }
.me-placeholder b { color: var(--text); font-size: 16px; }
.me-ehead { display: flex; align-items: center; gap: 6px; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.me-ehead h2 { margin: 0; font-size: 16px; }
.me-ehead .spacer { flex: 1; }
.me-close { display: none; }
.me-ebody { padding: 16px; overflow-y: auto; }
.me-photos { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }
.me-ph { position: relative; width: 92px; height: 92px; border-radius: 12px; background: var(--soft) center/cover; border: 1px solid var(--line); }
.me-ph .tag { position: absolute; left: 4px; bottom: 4px; font-size: 10px; }
.me-ph-del, .me-ph-main { position: absolute; top: 4px; width: 22px; height: 22px; border-radius: 50%; background: #000a; color: #fff; font-size: 11px; display: grid; place-items: center; }
.me-ph-del { right: 4px; } .me-ph-main { left: 4px; }
.me-ph.add { display: grid; place-items: center; align-content: center; gap: 4px; cursor: pointer; border-style: dashed; color: var(--muted); font-size: 11px; font-weight: 700; }
.me-ph.add:hover { border-color: var(--p); color: var(--p); }
.cnt { float: right; color: var(--muted); font-weight: 500; }
.me-sec { border-top: 1px solid var(--line); padding-top: 14px; margin-top: 6px; margin-bottom: 10px; }
.me-sec-h { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.me-vhead, .me-vrow { display: grid; grid-template-columns: 1fr 86px 86px auto auto; gap: 6px; align-items: center; margin-bottom: 6px; }
.me-vhead { font-size: 11px; color: var(--muted); font-weight: 700; }
.me-extras { display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0; }
.chip-btn { padding: 6px 10px; border-radius: 99px; border: 1px dashed var(--line); font-size: 12px; font-weight: 700; color: var(--muted); }
.chip-btn:hover { border-color: var(--p); color: var(--p); }
.chip-btn.on { border-style: solid; border-color: var(--p); background: var(--p-soft); color: var(--p); }
.me-mod { display: flex; gap: 10px; align-items: center; padding: 10px; border-radius: 10px; background: var(--soft); margin-bottom: 8px; }
.me-mod .grow { flex: 1; min-width: 0; }
.me-ohead, .me-orow { display: grid; grid-template-columns: auto 1fr 90px auto; gap: 6px; align-items: center; margin-bottom: 6px; }
.me-ohead.many, .me-orow.many { grid-template-columns: auto 1fr 84px 70px auto; }
.me-ohead { font-size: 11px; color: var(--muted); font-weight: 700; }
.me-orow.off input { opacity: .5; }
@media (max-width: 1100px) {
  .me { grid-template-columns: minmax(0, 1fr); }
  .me-right { position: fixed; inset: 0; top: 0; max-height: none; border-radius: 0; z-index: 45; display: none; }
  .me-right.show { display: flex; }
  .me-close { display: inline-grid; }
}

/* Reseñas */
.stars { color: #f59e0b; letter-spacing: 1px; }
.rev-row { display: flex; gap: 12px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.rev-row .grow { flex: 1; min-width: 0; }
.rev-row.off { opacity: .55; }
@media (max-width: 600px) { .hide-sm { display: none; } .top h1 { font-size: 17px; } }
.danger-zone { border: 1.5px solid #ef444455; }
.danger-zone h2 { color: var(--danger); }
.improve-card { border-left: 4px solid var(--warn); }
.probs { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; }
.prob { display: grid; grid-template-columns: auto 1fr; gap: 4px 10px; align-items: center; padding: 10px 12px; border-radius: 12px; background: var(--soft); }
.prob b { font-size: 20px; color: var(--warn); }
.prob span { font-weight: 600; font-size: 13px; }
.prob .track { grid-column: 1 / -1; height: 6px; background: var(--line); border-radius: 99px; overflow: hidden; }
.prob .track i { display: block; height: 100%; background: var(--warn); }
.rev-row.low { background: #f59e0b0d; margin: 0 -18px; padding: 14px 18px; }
.rev-row.low.done { background: transparent; opacity: .7; }
.g-dot { display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; color: #fff; font-weight: 800; font-size: 14px; vertical-align: -5px; margin-right: 4px;
  background: conic-gradient(#ea4335 0 25%, #fbbc05 0 50%, #34a853 0 75%, #4285f4 0); }
.g-2-1 { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); }
.rev-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.3fr); }
@media (max-width: 900px) { .g-2-1, .rev-grid { grid-template-columns: minmax(0, 1fr); } }
.me-video { margin-bottom: 14px; }
.me-vid-wrap video { width: 100%; max-height: 260px; border-radius: 12px; background: #000; display: block; }
.me-ph.add.wide { width: 100%; height: 64px; display: flex; justify-content: center; gap: 8px; margin-bottom: 6px; }
