:root {
  --primary: #1e40af;
  --primary-hover: #1d4ed8;
  --primary-light: #eff6ff;
  --primary-border: #bfdbfe;
  --secondary: #0f766e;
  --secondary-light: #f0fdfa;
  --accent: #d97706;
  --accent-light: #fffbeb;
  --danger: #b91c1c;
  --danger-light: #fef2f2;
  --success: #15803d;
  --success-light: #f0fdf4;
  --text-main: #1e293b;
  --text-muted: #64748b;
  --text-light: #94a3b8;
  --bg-page: #f8fafc;
  --bg-card: #ffffff;
  --bg-sidebar: #0f172a;
  --sidebar-text: #e2e8f0;
  --sidebar-muted: #94a3b8;
  --sidebar-hover: #1e293b;
  --sidebar-active: #3b82f6;
  --border-color: #e2e8f0;
  --border-subtle: #f1f5f9;
  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Segoe UI', system-ui, -apple-system, BlinkMacSystemFont, Roboto, sans-serif;
  background-color: var(--bg-page);
  color: var(--text-main);
  line-height: 1.6;
  display: flex;
  min-height: 100vh;
}

/* Sidebar */
.sidebar {
  width: 280px;
  background-color: var(--bg-sidebar);
  color: var(--sidebar-text);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  z-index: 50;
  overflow-y: auto;
  box-shadow: 2px 0 10px rgba(0, 0, 0, 0.15);
}

.sidebar-header {
  padding: 20px 18px;
  background-color: #0b1120;
  border-bottom: 1px solid #1e293b;
}

.sidebar-header .brand-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: #ffffff;
  display: flex;
  align-items: center;
  gap: 8px;
}

.sidebar-header .brand-badge {
  background-color: #2563eb;
  color: #ffffff;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 20px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.sidebar-header .brand-subtitle {
  font-size: 0.8rem;
  color: var(--sidebar-muted);
  margin-top: 4px;
}

.sidebar-nav {
  padding: 12px 8px 30px;
  flex: 1;
}

.nav-category {
  font-size: 0.7rem;
  font-weight: 700;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  padding: 14px 12px 6px;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  color: var(--sidebar-muted);
  text-decoration: none;
  font-size: 0.88rem;
  font-weight: 500;
  border-radius: var(--radius-sm);
  transition: all 0.15s ease;
  margin-bottom: 2px;
}

.nav-link:hover {
  background-color: var(--sidebar-hover);
  color: #ffffff;
  transform: translateX(2px);
}

.nav-link.active {
  background-color: var(--sidebar-active);
  color: #ffffff;
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.4);
}

.nav-link .nav-num {
  font-size: 0.75rem;
  opacity: 0.7;
  min-width: 18px;
}

/* Main Container */
.main-wrapper {
  margin-left: 280px;
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

/* Top Bar */
.topbar {
  background: var(--bg-card);
  border-bottom: 1px solid var(--border-color);
  padding: 12px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 40;
}

.breadcrumbs {
  font-size: 0.85rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 8px;
}

.breadcrumbs a {
  color: var(--primary);
  text-decoration: none;
  font-weight: 500;
}

.breadcrumbs a:hover {
  text-decoration: underline;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.btn-print {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  border-radius: var(--radius-sm);
  color: var(--text-main);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
}

.btn-print:hover {
  background: #e2e8f0;
}

/* Content Area */
.content-body {
  padding: 32px;
  max-width: 1060px;
  width: 100%;
}

/* Header Sections */
.page-header {
  margin-bottom: 28px;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 20px;
}

.page-header .section-tag {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 4px;
}

.page-header h1 {
  font-size: 2rem;
  color: #0f172a;
  font-weight: 800;
  line-height: 1.25;
}

.page-header .lead {
  font-size: 1.05rem;
  color: var(--text-muted);
  margin-top: 8px;
}

/* Content Cards */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 24px;
  margin-bottom: 24px;
  box-shadow: var(--shadow-sm);
}

.card-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.card-subtitle {
  font-size: 1.05rem;
  font-weight: 600;
  color: #1e293b;
  margin: 18px 0 10px 0;
}

/* Typography & Lists */
p {
  margin-bottom: 12px;
}

ul, ol {
  margin-bottom: 16px;
  padding-left: 24px;
}

li {
  margin-bottom: 6px;
}

/* Keyboards / Badges */
kbd {
  display: inline-block;
  padding: 2px 6px;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 0.82rem;
  font-weight: 700;
  line-height: 1;
  color: #1e293b;
  background-color: #f1f5f9;
  border: 1px solid #cbd5e1;
  border-bottom: 2px solid #94a3b8;
  border-radius: 4px;
  box-shadow: 0 1px 1px rgba(0,0,0,0.1);
  margin: 0 2px;
}

.badge {
  display: inline-block;
  padding: 3px 8px;
  font-size: 0.75rem;
  font-weight: 700;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.badge-required {
  background-color: #fee2e2;
  color: #991b1b;
  border: 1px solid #fecaca;
}

.badge-optional {
  background-color: #f1f5f9;
  color: #475569;
  border: 1px solid #e2e8f0;
}

.badge-auto {
  background-color: #e0f2fe;
  color: #0369a1;
  border: 1px solid #bae6fd;
}

/* Alerts / Callouts */
.alert {
  padding: 16px 18px;
  border-radius: var(--radius-sm);
  margin: 18px 0;
  display: flex;
  gap: 12px;
  font-size: 0.92rem;
  border-left: 4px solid;
}

.alert-tip {
  background-color: var(--primary-light);
  border-color: var(--primary);
  color: #1e3a8a;
}

.alert-warning {
  background-color: var(--accent-light);
  border-color: var(--accent);
  color: #92400e;
}

.alert-danger {
  background-color: var(--danger-light);
  border-color: var(--danger);
  color: #991b1b;
}

.alert-success {
  background-color: var(--success-light);
  border-color: var(--success);
  color: #166534;
}

.alert-icon {
  font-size: 1.25rem;
  line-height: 1;
}

.alert-content strong {
  display: block;
  font-size: 0.95rem;
  margin-bottom: 2px;
}

/* Steps / Workflow */
.step-container {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin: 20px 0;
}

.step-item {
  display: flex;
  gap: 16px;
  background: #f8fafc;
  border: 1px solid var(--border-color);
  padding: 16px;
  border-radius: var(--radius-sm);
}

.step-number {
  background: var(--primary);
  color: #ffffff;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.95rem;
  flex-shrink: 0;
}

.step-content {
  flex: 1;
}

.step-content h4 {
  font-size: 1rem;
  color: #0f172a;
  margin-bottom: 4px;
}

/* Tables */
.table-responsive {
  overflow-x: auto;
  margin: 16px 0 24px;
}

table.manual-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
  text-align: left;
}

table.manual-table th {
  background-color: #f1f5f9;
  color: #334155;
  font-weight: 700;
  padding: 10px 14px;
  border: 1px solid var(--border-color);
}

table.manual-table td {
  padding: 10px 14px;
  border: 1px solid var(--border-color);
  vertical-align: top;
}

table.manual-table tr:nth-child(even) td {
  background-color: #f8fafc;
}

/* Footer Navigation */
.page-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid var(--border-color);
}

.nav-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  color: var(--primary);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 600;
  box-shadow: var(--shadow-sm);
  transition: all 0.15s;
}

.nav-button:hover {
  background: var(--primary-light);
  border-color: var(--primary-border);
  transform: translateY(-1px);
}

.nav-button-primary {
  background: var(--primary);
  color: #ffffff;
  border-color: var(--primary);
}

.nav-button-primary:hover {
  background: var(--primary-hover);
  color: #ffffff;
}

/* Grid Dashboard */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
  margin: 16px 0;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
  margin: 16px 0;
}

.module-box {
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 18px;
  text-decoration: none;
  color: inherit;
  box-shadow: var(--shadow-sm);
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
}

.module-box:hover {
  border-color: var(--primary-border);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.module-icon {
  font-size: 1.8rem;
  margin-bottom: 10px;
}

.module-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 6px;
}

.module-desc {
  font-size: 0.85rem;
  color: var(--text-muted);
  flex: 1;
}

/* Search bar on index */
.search-box {
  margin: 20px 0 28px;
  position: relative;
}

.search-input {
  width: 100%;
  padding: 12px 16px 12px 42px;
  font-size: 0.98rem;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  background: #ffffff;
  color: var(--text-main);
  outline: none;
  transition: border-color 0.15s;
}

.search-input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-light);
  font-size: 1.1rem;
}

@media print {
  .sidebar, .topbar, .page-nav, .btn-print {
    display: none !important;
  }
  .main-wrapper {
    margin-left: 0 !important;
  }
  .content-body {
    padding: 0 !important;
    max-width: 100% !important;
  }
}

/* Screenshot Figures & Captions */
.screenshot-container {
  margin: 20px 0 24px;
  background: #f8fafc;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}
.screenshot-header {
  background: #f1f5f9;
  padding: 8px 14px;
  border-bottom: 1px solid var(--border-color);
  font-size: 0.8rem;
  font-weight: 600;
  color: #475569;
  display: flex;
  align-items: center;
  gap: 6px;
}
.screenshot-body {
  padding: 12px;
  text-align: center;
  background: #ffffff;
}
.screenshot-img {
  max-width: 100%;
  height: auto;
  border-radius: 4px;
  border: 1px solid #e2e8f0;
  box-shadow: 0 2px 4px rgba(0,0,0,0.06);
  display: inline-block;
}
.screenshot-caption {
  padding: 8px 14px 12px;
  font-size: 0.84rem;
  color: var(--text-muted);
  text-align: center;
  border-top: 1px solid var(--border-subtle);
}

/* Ajustes de la guía Centralizador Plus Web */
html { scroll-behavior: smooth; }
[hidden] { display: none !important; }
a:focus-visible, button:focus-visible, input:focus-visible { outline: 3px solid #2563eb; outline-offset: 3px; }
.sidebar-header .brand-title { font-size: 1.02rem; }
.content-body { max-width: 1180px; }
.grid-3 { display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px; }
.chapter-number { color:var(--primary);font-weight:800;font-size:1.4rem;margin-bottom:12px; }
.read-more { margin-top:16px;font-size:.86rem;font-weight:600;color:var(--primary); }
.quick-links { display:grid;grid-template-columns:1fr 1fr;gap:12px; }
.quick-links a { background:var(--primary-light);border:1px solid var(--primary-border);padding:15px;border-radius:8px;text-decoration:none;font-weight:600;color:var(--primary); }
.quick-links a:hover { background:#dbeafe; }
.search-label { font-weight:600; }
.search-box { margin-top:8px; }
.steps { padding-left:26px; }
.steps li { padding-left:6px;margin-bottom:14px; }
.manual-table { width:100%;border-collapse:collapse;font-size:.92rem; }
.manual-table th,.manual-table td { border:1px solid #e2e8f0;padding:12px;text-align:left;vertical-align:top; }
.manual-table th { background:#eff6ff; }
.table-responsive { overflow-x:auto; }
.screenshot-open { display:block;cursor:zoom-in;border:0;background:none;width:100%;padding:0; }
.screenshot-img { width:100%;height:auto;display:block; }
.screenshot-caption span { display:block;margin-top:4px;font-size:.78rem; }
.page-nav { display:flex;justify-content:space-between;gap:20px;margin:32px 0; }
.page-nav a { color:var(--primary); }
.guide-footer { border-top:1px solid #e2e8f0;padding:24px 32px;font-size:.8rem;color:#64748b;margin-top:auto; }
.image-dialog { width:96vw;max-width:1700px;max-height:96vh;border:0;border-radius:10px;padding:16px;overflow:auto;margin:auto; }
.image-dialog::backdrop { background:rgba(15,23,42,.85); }
.image-dialog img { display:block;width:100%;height:auto; }
.image-dialog p { margin:12px 0 0;color:#475569; }
.close-image { display:block;margin:0 0 12px auto;cursor:pointer;padding:8px 14px;border:1px solid #cbd5e1;border-radius:6px;background:white; }
.skip-link { position:fixed;top:-100px;left:15px;z-index:200;background:white;padding:12px; }
.skip-link:focus { top:10px; }
.menu-button { display:none; }
.chapter-heading { font-size:1.8rem;margin:35px 0 12px;color:#1e40af; }
@media (max-width:1000px) { .sidebar { width:240px; }.main-wrapper { margin-left:240px; }.content-body { padding:24px; }.grid-3,.quick-links { grid-template-columns:1fr; }.topbar { padding:12px 24px; }.breadcrumbs span { display:none; } }
@media (max-width:720px) { .sidebar { transform:translateX(-100%);width:280px;transition:transform .2s;top:60px; }.sidebar.is-open { transform:translateX(0); }.main-wrapper { margin-left:0;width:100%; }.menu-button { display:inline-flex; }.topbar { min-height:60px;padding:10px 14px;gap:12px; }.breadcrumbs { display:none; }.content-body { padding:24px 16px; }.page-header h1 { font-size:1.75rem; }.card { padding:20px 16px; }.page-nav { flex-direction:column; }.guide-footer { padding:20px 16px; }.image-dialog { width:98vw;padding:8px; }.image-dialog img { min-width:900px; }.screenshot-body { padding:6px; } }
@media print { body { display:block;background:white;color:black; }.sidebar,.topbar,.page-nav,.image-dialog,.skip-link,.search-box,.search-label,#searchCount,.guide-footer { display:none!important; }.main-wrapper { margin-left:0!important;display:block; }.content-body { padding:0!important;max-width:none!important; }.card { box-shadow:none;break-inside:auto; }.screenshot-container { break-inside:avoid;box-shadow:none; }.screenshot-img { max-height:165mm;object-fit:contain; }.screenshot-caption span { display:none; }h2,h3 { break-after:avoid; }.print-chapter { break-before:page; }.print-chapter:first-of-type { break-before:auto; }a { color:inherit; }.alert { break-inside:avoid; } }
