:root {
	--bg: #f4f6fa;
	--surface: #ffffff;
	--border: #dfe4ec;
	--text: #1c2330;
	--muted: #66707f;
	--primary: #2447c7;
	--primary-dark: #1b36a0;
	--primary-soft: #e8edfb;
	--danger: #b42318;
	--danger-soft: #fde8e6;
	--success: #087a4b;
	--success-soft: #e3f5ec;
	--warn: #8a5a00;
	--warn-soft: #fff4d6;
	--radius: 10px;
	--sidebar: 232px;
	--font: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
	--mono: ui-monospace, "Cascadia Mono", Consolas, monospace;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body { font-family: var(--font); font-size: 14px; color: var(--text); background: var(--bg); line-height: 1.45; }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
h1 { font-size: 24px; margin: 0 0 4px; font-weight: 650; }
h2 { font-size: 16px; margin: 0 0 12px; font-weight: 650; }
h3 { font-size: 14px; margin: 14px 0 6px; font-weight: 650; }
p { margin: 0 0 8px; }
code { font-family: var(--mono); font-size: 12px; background: #eef1f6; padding: 1px 5px; border-radius: 4px; }
.muted { color: var(--muted); }
.small { font-size: 12px; }
.mono { font-family: var(--mono); font-size: 12.5px; }
.right { text-align: right; }
.center { text-align: center; }
.req { color: var(--danger); margin-left: 2px; }

/* --- Shell --- */
.shell { display: flex; min-height: 100vh; }
.sidebar { width: var(--sidebar); flex: 0 0 var(--sidebar); background: #121a2e; color: #cfd6e6; display: flex; flex-direction: column; padding: 20px 14px; position: sticky; top: 0; height: 100vh; }
.brand { display: flex; align-items: center; gap: 10px; color: #fff; font-weight: 700; font-size: 18px; padding: 4px 8px 18px; }
.brand:hover { text-decoration: none; }
.brand-mark { display: inline-flex; width: 30px; height: 30px; border-radius: 8px; background: var(--primary); color: #fff; align-items: center; justify-content: center; font-weight: 800; }
.brand-lg { justify-content: center; font-size: 22px; }
.nav { display: flex; flex-direction: column; gap: 2px; }
.nav a { color: #cfd6e6; padding: 9px 12px; border-radius: 8px; font-weight: 500; }
.nav a:hover { background: rgba(255,255,255,.06); text-decoration: none; }
.nav a.active { background: var(--primary); color: #fff; }
.sidebar-footer { margin-top: auto; padding: 12px 8px 0; border-top: 1px solid rgba(255,255,255,.1); display: flex; flex-direction: column; gap: 8px; }
.user-name { color: #fff; font-weight: 600; }
.user-meta { font-size: 12px; color: #9aa5bd; }
.link-muted { color: #9aa5bd; font-size: 12.5px; }
.main { flex: 1; min-width: 0; padding: 28px 36px 60px; max-width: 1400px; }

/* --- Page --- */
.page-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 20px; margin-bottom: 20px; flex-wrap: wrap; }
.page-head .actions, .actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.crumbs { font-size: 12.5px; color: var(--muted); margin-bottom: 2px; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px 20px; margin-bottom: 16px; }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 8px; }
.card-head h2 { margin: 0; }
.card-info { background: var(--primary-soft); border-color: #c9d4f5; }
.card-warn { background: var(--warn-soft); border-color: #f1ddA0; }
.card-link { display: block; color: inherit; }
.card-link:hover { border-color: var(--primary); text-decoration: none; }
.card-link h3 { margin-top: 0; }
.narrow { max-width: 560px; }
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.grid-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 16px; }
.stat { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px 20px; }
.stat-value { font-size: 28px; font-weight: 700; }
.stat-label { color: var(--muted); font-size: 12.5px; }
.list { list-style: none; margin: 0; padding: 0; }
.list li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 0; border-top: 1px solid var(--border); }
.list li:first-child { border-top: 0; }
.list li .muted { display: block; font-size: 12.5px; }
.steps { padding-left: 18px; }
.steps li { margin-bottom: 8px; }
.dl { display: grid; grid-template-columns: 160px 1fr; gap: 4px 12px; margin: 0 0 8px; }
.dl dt { color: var(--muted); }
.dl dd { margin: 0; }
.notes { white-space: pre-wrap; font-family: inherit; margin: 6px 0 0; font-size: 13px; }
.pager { display: flex; gap: 12px; align-items: center; margin-top: 12px; }

/* --- Flash --- */
.flash { padding: 10px 14px; border-radius: 8px; margin-bottom: 16px; }
.flash-success { background: var(--success-soft); color: var(--success); }
.flash-error { background: var(--danger-soft); color: var(--danger); }

/* --- Forms --- */
.stack { display: flex; flex-direction: column; gap: 12px; }
label { display: flex; flex-direction: column; gap: 4px; font-weight: 500; font-size: 13px; }
label.check { flex-direction: row; align-items: center; gap: 8px; }
label .muted { font-weight: 400; }
input[type=text], input[type=email], input[type=password], input[type=number], input[type=file], select, textarea {
	font: inherit; padding: 8px 10px; border: 1px solid var(--border); border-radius: 7px; background: #fff; color: var(--text); width: 100%;
}
input:focus, select:focus, textarea:focus { outline: 2px solid var(--primary-soft); border-color: var(--primary); }
textarea { resize: vertical; }
textarea.code { font-family: var(--mono); font-size: 12px; min-height: 520px; height: 100%; white-space: pre; line-height: 1.4; }
input.short { width: 90px; }
.form-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px 16px; }
.form-grid .span-2 { grid-column: span 2; }
.inline-form { display: flex; gap: 8px; align-items: center; }
.inline-form input { width: 360px; max-width: 100%; }
.actions-row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.sticky-actions { position: sticky; bottom: 0; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 12px 16px; display: flex; gap: 14px; align-items: center; box-shadow: 0 -4px 16px rgba(0,0,0,.04); margin-bottom: 16px; }

/* --- Buttons --- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; font: inherit; font-weight: 550; padding: 8px 14px; border-radius: 8px; border: 1px solid var(--border); background: #fff; color: var(--text); cursor: pointer; white-space: nowrap; }
.btn:hover { background: #f2f4f8; text-decoration: none; }
.btn-primary { background: var(--primary); border-color: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); }
.btn-danger { color: var(--danger); border-color: #efc3bf; }
.btn-danger:hover { background: var(--danger-soft); }
.btn-ghost { background: transparent; border-color: rgba(255,255,255,.2); color: #cfd6e6; }
.btn-ghost:hover { background: rgba(255,255,255,.08); }
.btn-sm { padding: 5px 10px; font-size: 12.5px; }
.btn-icon { padding: 3px 8px; }
.btn-block { width: 100%; }
.btn:disabled { opacity: .6; cursor: progress; }

/* --- Tables --- */
.table { width: 100%; border-collapse: collapse; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.table th, .table td { text-align: left; padding: 10px 12px; border-top: 1px solid var(--border); vertical-align: middle; }
.table thead th { border-top: 0; background: #f7f8fb; font-size: 12px; text-transform: uppercase; letter-spacing: .03em; color: var(--muted); }
.table-compact th, .table-compact td { padding: 6px 8px; }
.table-compact input, .table-compact select { padding: 5px 8px; font-size: 13px; }
.table td.idx, .table th.idx { width: 36px; color: var(--muted); }
.table-scroll { overflow-x: auto; }
.badge { display: inline-block; padding: 2px 9px; border-radius: 999px; font-size: 12px; font-weight: 600; }
.badge-draft { background: var(--warn-soft); color: var(--warn); }
.badge-published { background: var(--success-soft); color: var(--success); }
.badge-archived { background: #e9ecf2; color: var(--muted); }

/* --- Editor --- */
.editor-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.mock-preview { border: 1px solid var(--border); border-radius: 8px; overflow: auto; max-height: 420px; background: #eef1f6; }
.mock-preview img { display: block; width: 100%; height: auto; }
.table-block { border: 1px solid var(--border); border-radius: 8px; padding: 12px; margin-bottom: 12px; }
.table-block-head { display: flex; gap: 12px; align-items: flex-end; flex-wrap: wrap; margin-bottom: 10px; }
.table-block-head label { flex-direction: column; }
.table-block-head label input { width: 180px; }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; min-height: 560px; }
.split-pane { min-width: 0; display: flex; flex-direction: column; }
.split-pane-wide { grid-column: 1; }
.preview-frame { width: 100%; flex: 1; min-height: 560px; border: 1px solid var(--border); border-radius: 8px; background: #fff; }
.pdf-frame { width: 100%; min-height: 80vh; border: 1px solid var(--border); border-radius: 8px; background: #555; }

/* --- Login --- */
.login-body { display: flex; align-items: center; justify-content: center; min-height: 100vh; }
.login-card { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 32px; width: 380px; max-width: 92vw; text-align: center; }
.login-card .brand { color: var(--text); }
.login-card form { text-align: left; margin-top: 16px; }

@media (max-width: 1100px) {
	.editor-grid, .split, .two-col { grid-template-columns: 1fr; }
	.stats { grid-template-columns: 1fr; }
}
@media (max-width: 800px) {
	.shell { flex-direction: column; }
	.sidebar { width: auto; flex: none; height: auto; position: static; }
	.main { padding: 20px; }
}

/* --- Pestanas --- */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--border); margin-bottom: 16px; }
.tab { font: inherit; font-weight: 550; padding: 9px 16px; border: 1px solid transparent; border-bottom: 0; border-radius: 8px 8px 0 0; background: transparent; color: var(--muted); cursor: pointer; margin-bottom: -1px; }
.tab:hover { color: var(--text); }
.tab.active { background: var(--surface); border-color: var(--border); color: var(--text); }
.tab-panel { margin-bottom: 16px; }

/* --- Editor visual --- */
.designer { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.designer-bar { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 8px 12px; border-bottom: 1px solid var(--border); background: #fafbfd; flex-wrap: wrap; }
.designer-bar .sep { width: 1px; height: 20px; background: var(--border); }
.designer-body { display: grid; grid-template-columns: 220px 1fr 260px; min-height: 640px; }
.designer-side, .designer-props { padding: 12px; overflow-y: auto; max-height: 78vh; }
.designer-side { border-right: 1px solid var(--border); }
.designer-props { border-left: 1px solid var(--border); background: #fafbfd; }
.designer-side h3, .designer-props h3 { margin: 14px 0 6px; font-size: 12px; text-transform: uppercase; letter-spacing: .03em; color: var(--muted); }
.designer-side h3:first-child { margin-top: 0; }
.designer-canvas { overflow: auto; background: #e9ecf2; padding: 12px; max-height: 78vh; }
#canvas { display: flex; flex-direction: column; gap: 12px; align-items: flex-start; }

.cv-page { position: relative; background: #fff; box-shadow: 0 1px 6px rgba(0,0,0,.18); overflow: hidden; flex: none; }
.cv-el { position: absolute; box-sizing: border-box; }
.cv-text { white-space: nowrap; line-height: 1; overflow: visible; }
.cv-el:hover { outline: 1px solid rgba(36,71,199,.45); }
.cv-el.sel { outline: 1.5px solid var(--primary); }
.cv-el.cv-inrow { outline: 1px dashed rgba(36,71,199,.4); }
.cv-cell { position: absolute; white-space: nowrap; line-height: 1; }
.cv-cell:hover { outline: 1px dotted var(--primary); }
.cv-cell.sel { outline: 1.5px solid var(--primary); background: rgba(36,71,199,.08); }
.cv-table { outline: 1px dashed #b9c0cd; }
.cv-table-tag { position: absolute; top: -15px; left: 0; opacity: 0; transition: opacity .12s; font: 10px/1.4 var(--font); color: var(--primary); background: var(--primary-soft); padding: 0 5px; border-radius: 3px; white-space: nowrap; }
.cv-table:hover .cv-table-tag, .cv-table.sel .cv-table-tag { opacity: 1; }
.mk { background: rgba(36,71,199,.13); border-radius: 2px; box-shadow: inset 0 -1px 0 rgba(36,71,199,.5); }
.mk.empty { color: var(--muted); font-style: italic; }
.mk.plain { background: transparent; box-shadow: none; }
.cv-handle { position: absolute; width: 9px; height: 9px; background: #fff; border: 1.5px solid var(--primary); border-radius: 2px; }
.cv-handle-e { right: -5px; top: 50%; margin-top: -4px; cursor: ew-resize; }
.cv-handle-s { bottom: -5px; left: 50%; margin-left: -4px; cursor: ns-resize; }
.cv-handle-se { right: -5px; bottom: -5px; cursor: nwse-resize; }
.cv-guide { position: absolute; display: none; background: #e8590c; z-index: 50; pointer-events: none; }
.cv-guide-v { top: 0; bottom: 0; width: 1px; }
.cv-guide-h { left: 0; right: 0; height: 1px; }
body.dragging { user-select: none; cursor: grabbing; }

.chips { list-style: none; margin: 0 0 10px; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.chip { display: flex; align-items: center; gap: 6px; padding: 5px 8px; border: 1px solid var(--border); border-radius: 7px; background: #fff; cursor: grab; font-size: 12.5px; }
.chip:hover { border-color: var(--primary); }
.chip.placed { opacity: .55; }
.chip-label { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chip-key { color: var(--muted); font-size: 11px; }

.prop { display: flex; flex-direction: column; gap: 3px; font-size: 12px; font-weight: 500; margin-bottom: 8px; }
.prop.check { flex-direction: row; align-items: center; gap: 6px; }
.prop input, .prop select, .prop textarea { padding: 5px 7px; font-size: 12.5px; }
.prop input[type=color] { padding: 1px; height: 28px; }
.prop-row { display: flex; gap: 8px; }
.prop-row .prop { flex: 1; }
.prop-buttons { margin-bottom: 8px; }
.prop-buttons .btn { flex: 1; }
.prop-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; padding-bottom: 8px; margin-bottom: 10px; border-bottom: 1px solid var(--border); }
.prop-text { font-family: var(--mono); font-size: 12px; }

@media (max-width: 1250px) {
	.designer-body { grid-template-columns: 180px 1fr 230px; }
}

.text-danger { color: var(--danger); }

/* --- Selector de organizacion --- */
.org-switcher { margin: 0 0 14px; position: relative; }
.org-switcher summary { list-style: none; cursor: pointer; padding: 9px 11px; border-radius: 9px; background: rgba(255,255,255,.07); display: block; }
.org-switcher summary::-webkit-details-marker { display: none; }
.org-switcher summary:hover { background: rgba(255,255,255,.12); }
.org-label { display: block; font-size: 10.5px; text-transform: uppercase; letter-spacing: .06em; color: #8b95ab; }
.org-name { display: block; color: #fff; font-weight: 600; font-size: 14px; line-height: 1.25; margin-top: 2px; }
.org-role { display: block; font-size: 11.5px; color: #9aa5bd; }
.org-menu { position: absolute; z-index: 30; left: 0; right: 0; top: calc(100% + 4px); background: var(--surface); border: 1px solid var(--border); border-radius: 9px; box-shadow: 0 8px 24px rgba(0,0,0,.25); padding: 5px; max-height: 340px; overflow-y: auto; }
.org-menu form { margin: 0; }
.org-option { width: 100%; text-align: left; background: none; border: 0; border-radius: 6px; padding: 7px 9px; cursor: pointer; font: inherit; color: var(--text); }
.org-option:hover { background: var(--surface-2, #f2f4f8); }
.org-option small { display: block; color: var(--muted); font-size: 11.5px; }
.org-option.current { background: var(--primary-soft); color: var(--primary); font-weight: 600; }
.org-menu-foot { border-top: 1px solid var(--border); margin-top: 5px; padding: 7px 9px 3px; display: flex; flex-direction: column; gap: 5px; }
.org-menu-foot a { font-size: 12.5px; }
.org-empty { padding: 8px 9px; }

.nav-platform { margin-top: 18px; padding-top: 12px; border-top: 1px solid rgba(255,255,255,.1); }
.nav-heading { font-size: 10.5px; text-transform: uppercase; letter-spacing: .07em; color: #8b95ab; padding: 0 12px 6px; display: block; }

.banner-admin { background: var(--primary-soft); color: var(--primary-dark); border: 1px solid #c9d4f5; border-radius: 8px; padding: 9px 14px; margin-bottom: 16px; font-size: 13.5px; }
.banner-warn { background: var(--warn-soft); color: var(--warn); border-color: #f1dda0; }
.flash code { display: block; margin-top: 6px; font-size: 12px; word-break: break-all; }

.scope-switch { display: inline-flex; border: 1px solid var(--border); border-radius: 8px; overflow: hidden; background: var(--surface); }
.scope-switch a { padding: 6px 13px; font-size: 13px; font-weight: 550; color: var(--muted); }
.scope-switch a:hover { background: #f2f4f8; text-decoration: none; }
.scope-switch a.active { background: var(--primary); color: #fff; }

.role-pill { font-size: 11.5px; font-weight: 600; padding: 2px 9px; border-radius: 999px; background: var(--surface-2, #eef1f6); color: var(--muted); }
.role-pill.director { background: var(--primary-soft); color: var(--primary); }
.roles-help { list-style: none; padding: 0; margin: 12px 0 0; font-size: 12.5px; color: var(--muted); display: flex; flex-direction: column; gap: 4px; }
.roles-help b { color: var(--text); }

/* ============================================================ Facturacion */

/* --- Paginas publicas: tarifa y registro --- */
.public-body { background: var(--bg); }
.public-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 32px; background: var(--surface); border-bottom: 1px solid var(--border); }
.public-head .brand { display: inline-flex; align-items: center; gap: 9px; color: var(--text); }
.public-nav { display: flex; align-items: center; gap: 18px; font-size: 13.5px; }
.public-main { max-width: 1060px; margin: 0 auto; padding: 40px 24px 64px; }
.public-foot { max-width: 1060px; margin: 0 auto; padding: 20px 24px 40px; display: flex; gap: 18px; justify-content: space-between; font-size: 12.5px; }
.pricing-intro { text-align: center; max-width: 620px; margin: 0 auto 36px; }
.pricing-intro h1 { font-size: 30px; }

.pricing-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(258px, 1fr)); gap: 16px; align-items: start; }
.plan-card { position: relative; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 22px 20px; display: flex; flex-direction: column; gap: 10px; }
.plan-card.plan-popular { border-color: var(--primary); box-shadow: 0 6px 22px rgba(36,71,199,.12); }
.plan-card.plan-current { border-color: var(--success); }
.plan-tag { position: absolute; top: -10px; left: 20px; background: var(--primary); color: #fff; font-size: 11px; font-weight: 600; padding: 3px 9px; border-radius: 999px; }
.plan-card.plan-current .plan-tag { background: var(--success); }
.plan-card h2 { margin: 0; font-size: 19px; }
.plan-tagline { margin: 0; font-size: 12.5px; min-height: 34px; }
.plan-price { margin: 6px 0 4px; display: flex; align-items: baseline; gap: 5px; flex-wrap: wrap; }
.plan-amount { font-size: 30px; font-weight: 700; letter-spacing: -.01em; }
.plan-currency { font-size: 13px; font-weight: 600; color: var(--muted); }
.plan-period { font-size: 12.5px; color: var(--muted); }
.plan-features { list-style: none; padding: 0; margin: 4px 0 12px; display: flex; flex-direction: column; gap: 6px; font-size: 13px; flex: 1; }
.plan-features li { padding-left: 20px; position: relative; }
.plan-features li::before { content: ""; position: absolute; left: 4px; top: 7px; width: 5px; height: 9px; border-right: 2px solid var(--success); border-bottom: 2px solid var(--success); transform: rotate(40deg); }
.plan-note { margin: 6px 0 0; text-align: center; }

.pricing-table, .pricing-faq { margin-top: 40px; }
.table-scroll { overflow-x: auto; }
.faq-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; }
.faq-grid h3 { margin-top: 0; }

.register-main { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 24px; align-items: start; }
.register-form { padding: 26px 24px; }
.register-plans { display: flex; flex-direction: column; gap: 10px; }
.plan-mini { background: var(--surface); border: 1px solid var(--border); border-radius: 9px; padding: 11px 13px; }
.plan-mini.selected { border-color: var(--primary); background: var(--primary-soft); }
.plan-mini-head { display: flex; justify-content: space-between; gap: 10px; font-size: 13.5px; }
.plan-mini p { margin: 3px 0 0; }
.check { display: flex; align-items: flex-start; gap: 9px; font-size: 13px; }
.check input { margin-top: 2px; }
.login-links { margin-top: 14px; text-align: center; }

/* --- Suscripcion --- */
.billing-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 16px; align-items: start; margin-bottom: 16px; }
.billing-plan-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 8px; }
.billing-plan-head h2 { margin: 2px 0 0; }
.card-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }

.data-list { margin: 14px 0 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.data-list > div { display: flex; justify-content: space-between; gap: 14px; border-bottom: 1px dashed var(--border); padding-bottom: 7px; }
.data-list dt { color: var(--muted); font-size: 12.5px; margin: 0; }
.data-list dd { margin: 0; font-size: 13.5px; font-weight: 550; text-align: right; }

.usage-count { margin: 4px 0 8px; }
.usage-used { font-size: 30px; font-weight: 700; line-height: 1; }
.usage-bar { height: 9px; border-radius: 999px; background: #e6eaf2; overflow: hidden; }
.usage-bar-sm { height: 6px; }
.usage-fill { height: 100%; background: var(--primary); border-radius: 999px; transition: width .2s; }
.usage-fill.over { background: var(--warn); }

.notice { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; background: var(--primary-soft); border: 1px solid #c9d4f5; color: var(--primary-dark); border-radius: 8px; padding: 10px 13px; margin-top: 14px; font-size: 13px; }
.notice-warn { background: var(--warn-soft); border-color: #f1dda0; color: var(--warn); }
.notice form.inline { margin: 0; }

.checkout-summary { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.checkout-summary h2 { margin: 2px 0 2px; }
.checkout-amount { text-align: right; display: flex; flex-direction: column; gap: 2px; align-items: flex-end; }
.checkout-amount strong { font-size: 26px; font-weight: 700; }

.method-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(236px, 1fr)); gap: 14px; margin-bottom: 16px; }
.method-card { display: flex; flex-direction: column; gap: 8px; }
.method-card h3 { margin: 0; }
.method-card button { margin-top: auto; }
.method-detail { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 3px; word-break: break-all; }

.list-compact li { padding: 7px 0; }
.small-heading { font-size: 11px; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); margin: 18px 0 6px; font-weight: 650; }
.table-compact td, .table-compact th { padding: 6px 9px; font-size: 12.5px; }
.code-block { background: #f5f7fb; border: 1px solid var(--border); border-radius: 7px; padding: 10px; font-family: var(--mono); font-size: 11.5px; overflow-x: auto; white-space: pre-wrap; word-break: break-all; }

.timeline { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.timeline li { display: grid; grid-template-columns: 130px 150px 1fr; gap: 10px; align-items: baseline; border-left: 2px solid var(--border); padding-left: 12px; }
.timeline-when { color: var(--muted); font-size: 12px; }
.timeline-what { font-weight: 600; font-size: 13px; }

.pager { display: flex; align-items: center; gap: 14px; justify-content: center; margin: 16px 0; font-size: 13px; color: var(--muted); }

.sidebar-usage { margin-top: auto; padding: 12px; border-radius: 9px; background: rgba(255,255,255,.07); display: flex; flex-direction: column; gap: 6px; }
.sidebar-usage-head { display: flex; justify-content: space-between; gap: 8px; font-size: 12px; color: #cfd6e6; }
.sidebar-usage .usage-bar { background: rgba(255,255,255,.16); }
.sidebar-usage a { color: #9aa5bd; }
.nav-count { display: inline-block; min-width: 18px; text-align: center; background: var(--warn); color: #3a2600; border-radius: 999px; font-size: 11px; font-weight: 700; padding: 0 5px; margin-left: 6px; }

/* Estados de pago y suscripcion */
.badge-warn { background: var(--warn-soft); color: var(--warn); }
.pay-pending, .sub-pending_payment { background: #eef1f6; color: var(--muted); }
.pay-pending_review, .pay-info_requested, .sub-pending_review { background: var(--warn-soft); color: var(--warn); }
.pay-approved, .sub-active { background: var(--success-soft); color: var(--success); }
.pay-rejected, .pay-cancelled, .pay-expired, .sub-cancelled, .sub-expired, .sub-suspended { background: var(--danger-soft); color: var(--danger); }
.pay-refunded { background: var(--primary-soft); color: var(--primary); }

@media (max-width: 860px) {
	.register-main { grid-template-columns: 1fr; }
	.timeline li { grid-template-columns: 1fr; gap: 2px; }
}
