/* Página /commands: encabezado con Shiru a un lado, categorías a la izquierda y las tarjetas
   de comandos (.command-card, de style.css) a la derecha. */
.cm-wrap { position: relative; z-index: 1; max-width: 1180px; margin: 0 auto; padding: 36px 20px 70px; }

/* ── Encabezado ── */
.cm-hero { position: relative; overflow: hidden; display: grid; grid-template-columns: minmax(0, 1fr) 340px; align-items: center; gap: 24px; padding: 40px 44px; margin-bottom: 28px;
    border-radius: 28px; border: 1px solid rgba(122, 214, 255, 0.22);
    background:
        radial-gradient(ellipse 560px 300px at 8% 0%, rgba(122, 214, 255, 0.16), transparent 70%),
        radial-gradient(ellipse 480px 320px at 100% 100%, rgba(168, 136, 255, 0.20), transparent 70%),
        rgba(13, 19, 32, 0.82);
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35); }
.cm-title { margin: 12px 0 10px; display: flex; flex-wrap: wrap; gap: 0 0.3em; font-family: 'Baloo 2', sans-serif; font-size: clamp(2.2rem, 4.6vw, 3.3rem); font-weight: 800; line-height: 1.05; }
.cm-sub { margin: 0; max-width: 520px; font-size: 1.02rem; line-height: 1.6; color: #c9d4e3; }
.cm-search { display: flex; align-items: center; gap: 10px; max-width: 520px; margin-top: 22px; padding: 6px 16px; border-radius: 16px; background: rgba(5, 9, 18, 0.65); border: 1px solid var(--border); transition: border-color 0.15s ease, box-shadow 0.15s ease; }
.cm-search:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.cm-search svg { width: 20px; height: 20px; flex-shrink: 0; fill: none; stroke: var(--text-muted); stroke-width: 2; stroke-linecap: round; }
.cm-search input { flex: 1; min-width: 0; background: none; border: none; outline: none; color: var(--text); font: 1rem 'Inter', sans-serif; padding: 11px 0; }
.cm-facts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; min-height: 34px; }
.cm-fact { padding: 6px 13px; border-radius: 999px; background: rgba(5, 9, 18, 0.6); border: 1px solid var(--border); font-size: 0.86rem; color: #c9d4e3; }
.cm-fact strong { color: var(--moon); font-family: 'Baloo 2', sans-serif; font-size: 1.05rem; margin-right: 2px; }

/* Shiru */
.cm-hero-art { position: relative; height: 290px; display: grid; place-items: center; }
.cm-avatar-ring { position: relative; width: 220px; height: 220px; border-radius: 50%; padding: 6px;
    background: conic-gradient(from 210deg, #7ad6ff, #a888ff, #f9b6ff, #7ad6ff);
    box-shadow: 0 0 0 10px rgba(122, 214, 255, 0.07), 0 0 70px rgba(122, 214, 255, 0.35); animation: cm-bob 6s ease-in-out infinite; }
.cm-avatar-ring img { display: block; width: 100%; height: 100%; border-radius: 50%; object-fit: cover; background: #0d1320; border: 4px solid #0d1320; }
.cm-float { position: absolute; padding: 7px 13px; border-radius: 12px; font: 600 0.84rem 'Inter', sans-serif; color: var(--text); white-space: nowrap;
    background: rgba(13, 19, 32, 0.92); border: 1px solid rgba(122, 214, 255, 0.3); box-shadow: 0 10px 26px rgba(0, 0, 0, 0.4); animation: cm-bob 5s ease-in-out infinite; }
.cm-float b { color: var(--accent); font-weight: 700; margin-right: 1px; }
.cm-float-1 { top: 18px; right: -4px; animation-delay: -1.2s; }
.cm-float-2 { bottom: 34px; left: -6px; animation-delay: -2.6s; }
.cm-float-3 { bottom: 6px; right: 22px; animation-delay: -3.8s; }
.cm-spark { position: absolute; color: var(--moon); opacity: 0.75; animation: cm-twinkle 3.2s ease-in-out infinite; }
.cm-spark-1 { top: 10px; left: 26px; font-size: 1.3rem; }
.cm-spark-2 { top: 96px; right: 8px; font-size: 1rem; animation-delay: -1s; }
.cm-spark-3 { bottom: 76px; left: 4px; font-size: 1.5rem; color: #f9b6ff; animation-delay: -2s; }
@keyframes cm-bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-9px); } }
@keyframes cm-twinkle { 0%, 100% { opacity: 0.25; transform: scale(0.85); } 50% { opacity: 0.9; transform: scale(1.1); } }

/* ── Cuerpo ── */
.cm-layout { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 26px; align-items: start; }
.cm-side { position: sticky; top: 16px; padding: 18px 14px; border-radius: 20px; background: rgba(17, 24, 38, 0.86); border: 1px solid var(--border); }
.cm-side-title { margin: 0 0 10px; padding: 0 10px; font-size: 0.76rem; font-weight: 700; letter-spacing: 0.8px; text-transform: uppercase; color: var(--text-muted); }
.cm-empty { margin: 30px 0; text-align: center; color: var(--text-muted); }
.command-usage.is-match { border-left: 3px solid var(--accent); padding-left: 12px; }
.command-card { scroll-margin-top: 16px; }

@media (prefers-reduced-motion: reduce) { .cm-avatar-ring, .cm-float, .cm-spark { animation: none; } }
@media (max-width: 980px) {
    .cm-hero { grid-template-columns: minmax(0, 1fr); padding: 30px 24px; text-align: center; }
    .cm-hero-art { order: -1; height: 210px; }
    .cm-avatar-ring { width: 160px; height: 160px; }
    .cm-title { justify-content: center; }
    .cm-sub, .cm-search { margin-left: auto; margin-right: auto; }
    .cm-facts { justify-content: center; }
    .cm-float-1 { right: 8%; } .cm-float-2 { left: 8%; } .cm-float-3 { right: 16%; }
}
@media (max-width: 860px) {
    .cm-layout { grid-template-columns: minmax(0, 1fr); }
    .cm-side { position: static; padding: 10px; }
    .cm-side-title { display: none; }
    .cm-cats { flex-direction: row; overflow-x: auto; gap: 8px; }
    .cm-cats .category-btn { flex-shrink: 0; width: auto; gap: 10px; white-space: nowrap; }
}
@media (max-width: 520px) { .cm-float { font-size: 0.74rem; padding: 5px 10px; } .cm-hero { padding: 24px 16px; } }
