/* Moonlight-Web — Hosts view */

.hosts-view { width: 100%; }

.hosts-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--space-5);
}
.hosts-header h2 {
    font-size: var(--fs-xl);
    font-weight: 700;
}
.hosts-actions {
    display: flex;
    gap: var(--space-2);
}

.hosts-list {
    display: flex;
    flex-direction: column;
    gap: var(--space-3);
}

.hosts-empty,
.hosts-error {
    text-align: center;
    padding: var(--space-8) var(--space-5);
    color: var(--text-2);
    background-color: var(--surface-2);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-1);
}
.empty-icon {
    display: block;
    font-size: 2.5rem;
    margin-bottom: var(--space-3);
    opacity: 0.7;
}

/* ── Host card ─────────────────────────────────────────────────────────── */
.host-card {
    display: flex;
    align-items: center;
    gap: var(--space-4);
    padding: var(--space-4) var(--space-5);
    transition: border-color 0.2s, box-shadow 0.2s, transform 0.15s;
}
.host-card:hover {
    box-shadow: var(--edge-accent), var(--glass-highlight);
    filter: var(--glow-accent);
    transform: translateY(-1px);
}
.host-card.offline { opacity: 0.55; }

.host-card-icon { flex-shrink: 0; }
.status-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    font-size: 1.25rem;
    background-color: var(--surface-3);
}
.status-icon.ready   { color: var(--c-success); background-color: var(--c-success-soft); }
.status-icon.locked  { color: var(--c-warning); background-color: var(--c-warning-soft); }
.status-icon.offline { color: var(--c-danger);  background-color: var(--c-danger-soft); }

.host-card-info { flex: 1; min-width: 0; }
.host-name {
    font-weight: 600;
    font-size: var(--fs-md);
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.host-address {
    font-size: var(--fs-xs);
    color: var(--text-2);
    font-family: var(--font-mono);
}
.host-gpu,
.host-resolution {
    font-size: var(--fs-xs);
    color: var(--text-3);
    margin-top: 1px;
}

.host-card-status { flex-shrink: 0; }
.host-card-actions { flex-shrink: 0; }
.host-card-remove { flex-shrink: 0; }
.host-unreachable {
    font-size: var(--fs-xs);
    color: var(--text-3);
}

@media (max-width: 600px) {
    .host-card {
        flex-wrap: wrap;
        padding: var(--space-3) var(--space-4);
        gap: var(--space-3);
    }
    .host-card-actions,
    .host-card-remove {
        width: 100%;
        margin-left: 0;
    }
    .host-card-actions .btn,
    .btn-remove {
        width: 100%;
    }
}
