/* =========================================================
   SHADOW · COMPONENTS PREVIEW
   assets/css/pages/shadow-builder/preview/components-preview.css
   =========================================================
   A unified component showcase. Real UI sits directly on one canvas
   (no boxed-off demo tiles); each element wears its var(--sh-<component>)
   token, so the whole board responds to style/intensity/surface. Colours
   come from the themed --sh-surface-* vars + existing --color-primary;
   no new colours.
   ========================================================= */

.sh-cmp {
    align-content: start;
}

/* ── Section cell + label ───────────────────────────────── */
.sh-cmp-cell {
    display: flex;
    flex-direction: column;
    gap: 9px;
}

.sh-cmp-cell-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 8px;
}

.sh-cmp-cell-label {
    font-size: 12px;
    font-weight: 600;
    letter-spacing: -0.01em;
    color: var(--sh-surface-fg, #0f172a);
}

.sh-cmp-cell-token {
    font-size: 9.5px;
    font-family: ui-monospace, monospace;
    color: var(--sh-surface-muted, #64748b);
    opacity: 0.85;
    word-break: break-word;
}

/* Stage — a soft tile that frames each section's components evenly. */
.sh-cmp-stage {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 16px;
    padding: 22px;
    border-radius: 12px;
    background: var(--sh-surface-bg, #eef2f7);
    border: 1px solid var(--sh-surface-border, rgba(15, 23, 42, 0.06));
}

.sh-cmp-itemwrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.sh-cmp-cap {
    font-size: 10.5px;
    font-weight: 500;
    color: var(--sh-surface-muted, #64748b);
}

/* Smoothly animate every shadowed element as the sliders move. */
.sh-cmp-card,
.sh-cmp-btn,
.sh-cmp-input,
.sh-cmp-dropdown,
.sh-cmp-tooltip,
.sh-cmp-modal {
    transition: box-shadow 0.18s ease, transform 0.18s ease;
}

/* ── Realistic mini card ────────────────────────────────── */
.sh-cmp-card {
    width: 168px;
    box-sizing: border-box;
    border-radius: 12px;
    background: var(--sh-surface-panel, #fff);
    border: 1px solid var(--sh-surface-border, rgba(15, 23, 42, 0.06));
    padding: 13px 14px;
}

.sh-cmp-card:hover {
    transform: translateY(-2px);
}

.sh-cmp-card-row {
    display: flex;
    align-items: center;
    gap: 11px;
}

.sh-cmp-card-avatar {
    flex: 0 0 auto;
    width: 34px;
    height: 34px;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-primary-soft, #eef2ff);
    color: var(--color-primary, #6366f1);
}

.sh-cmp-card-text {
    min-width: 0;
}

.sh-cmp-card-title {
    font-size: 12.5px;
    font-weight: 600;
    line-height: 1.2;
    color: var(--sh-surface-fg, #0f172a);
}

.sh-cmp-card-meta {
    font-size: 10.5px;
    color: var(--sh-surface-muted, #64748b);
    margin-top: 2px;
}

/* ── Dropdown item hover ────────────────────────────────── */
.sh-cmp-dropdown-item {
    transition: background 0.14s ease;
    cursor: default;
}

.sh-cmp-dropdown-item:hover {
    background: var(--sh-surface-bg, #eef2f7) !important;
}

/* =========================================================
   MOBILE — single column, tighter stages
   ========================================================= */

.sh-preview-area--mobile .sh-cmp {
    grid-template-columns: 1fr !important;
}

.sh-preview-area--mobile .sh-cmp-stage {
    padding: 18px;
    gap: 14px;
}
